windows-once: Improve comments.
[gnulib.git] / ChangeLog
blob67b0ea66ef356861417cbc14c85f40054385e4fe
1 2024-05-31  Bruno Haible  <bruno@clisp.org>
3         windows-once: Improve comments.
4         * lib/windows-once.c (glwthread_once): Mention the 'started' field in
5         the comments.
7         windows-once: Fix race (regression yesterday).
8         * lib/windows-once.h (glwthread_once_t): Change type of inited to LONG.
9         * lib/windows-once.c (glwthread_once): Increment inited from 1 to 2, to
10         ensure that DeleteCriticalSection gets invoked only once.
12         windows-once: Simplify.
13         * lib/windows-once.c (glwthread_once): Use InterlockedCompareExchange
14         instead of InterlockedIncrement.
16 2024-05-31  Bruno Haible  <bruno@clisp.org>
18         pthread-once: Fix race in Cygwin workaround implementation.
19         * lib/pthread-once.c (pthread_once): Test the 'done' word after
20         incrementing num_threads. Make sure to invoke pthread_mutex_destroy
21         only once.
23         pthread-once: Simplify Cygwin workaround implementation.
24         * lib/pthread-once.c (pthread_once): Use separate 16-bit words to store
25         the parts of the state.
27         pthread-once: Simplify Cygwin workaround implementation.
28         * lib/pthread-once.c (pthread_once): Use _Atomic instead of __sync_*
29         gcc primitives.
31 2024-05-30  Bruno Haible  <bruno@clisp.org>
33         assert-h, verify: Fix compilation error with g++ (4.8.5) -std=gnu++11.
34         Reported by Harmen <harmen@stoppels.ch> at
35         <https://savannah.gnu.org/bugs/index.php?65811>.
36         * lib/verify.h (static_assert): In C++ mode with g++ < 6 and
37         -std=gnu++11, define in a way that supports also the 1-argument
38         invocations and the invocations inside C++ struct and class.
40 2024-05-30  Collin Funk  <collin.funk1@gmail.com>
42         endian: Unquote variables that are always defined.
43         * m4/endian.m4 (gl_ENDIAN_H): Unquote $ac_cv_header_endian_h and
44         $GL_GENERATE_ENDIAN_H.
46 2024-05-30  Bruno Haible  <bruno@clisp.org>
48         attribute: Try harder to avoid syntax errors.
49         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define
50         _GL_ATTRIBUTE_REPRODUCIBLE and _GL_ATTRIBUTE_UNSEQUENCED to empty if
51         _GL_BRACKET_BEFORE_ATTRIBUTE is defined.
53 2024-05-30  Bruno Haible  <bruno@clisp.org>
55         attribute: Improve comments.
56         * m4/gnulib-common.m4 (gl_COMMON_BODY): Mention each macro name at the
57         beginning of its commentary.
59 2024-05-30  Collin Funk  <collin.funk1@gmail.com>
61         endian: Quote variables that may be undefined (regr. 2024-05-18).
62         * m4/endian_h.m4 (gl_ENDIAN_H): Quote variables that are undefined on
63         some systems or may be defined by the user.
65 2024-05-30  Bruno Haible  <bruno@clisp.org>
67         call_once: Work around Cygwin 3.5.3 bug.
68         * m4/call_once.m4 (gl_FUNC_CALL_ONCE): Require AC_CANONICAL_HOST.
69         On Cygwin, set REPLACE_CALL_ONCE to 1.
70         * lib/call_once.c (call_once): On Cygwin, use a cast, to avoid a
71         compiler warning.
72         * modules/call_once (Depends-on): Add pthread-once.
73         * doc/posix-functions/call_once.texi: Mention the Cygwin bug.
75 2024-05-30  Bruno Haible  <bruno@clisp.org>
77         windows-once: Free allocated resources when done.
78         Based on an observation regarding Cygwin's pthread_once implementation
79         by Takashi Yano <takashi.yano@nifty.ne.jp> at
80         <https://cygwin.com/pipermail/cygwin/2024-January/255182.html> and
81         <https://cygwin.com/pipermail/cygwin-patches/2024q1/012600.html>
82         * lib/windows-once.h (glwthread_once_t): Add field 'num_threads'.
83         (GLWTHREAD_ONCE_INIT): Initialize it to zero.
84         * lib/windows-once.c (glwthread_once): Increment num_threads while the
85         thread uses the lock. Let the last thread that uses the lock destroy it.
87 2024-05-29  Bruno Haible  <bruno@clisp.org>
89         call_once tests: Fix link error on mingw.
90         * modules/call_once-tests (Depends-on): Add mtx.
92 2024-05-29  Bruno Haible  <bruno@clisp.org>
94         mbfile tests: Avoid test failure on mingw.
95         * tests/test-mbfile.c: Include <string.h>, localcharset.h.
96         (main): Verify that setlocale() has installed an UTF-8 locale.
97         * modules/mbfile-tests (Depends-on): Add localcharset.
99 2024-05-29  Bruno Haible  <bruno@clisp.org>
101         pthread-once tests: Fix crash on mingw.
102         * modules/pthread-once-tests (Depends-on): Add pthread-rwlock.
104 2024-05-29  Bruno Haible  <bruno@clisp.org>
106         lock: Work around Cygwin 3.5.3 bug.
107         * modules/lock (Depends-on): Add pthread-once.
109 2024-05-29  Collin Funk  <collin.funk1@gmail.com>
111         gnulib-tool.py: Don't emit non-ASCII shell output (regr. yesterday).
112         Reported by Bruno Haible in
113         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00441.html>.
114         * pygnulib/GLModuleSystem.py (GLModule.shell_id_chars): Use the re.ASCII
115         flag for the regular expression.
117 2024-05-28  Collin Funk  <collin.funk1@gmail.com>
119         gnulib-tool.py: Add missing docstring.
120         * pygnulib/GLModuleSystem.py (GLModule.getShellId): Add docstring
121         forgotten in the previous commit.
123         gnulib-tool.py: Simplify creation of module shell ids.
124         * pygnulib/GLModuleSystem.py (GLModule.shell_id_chars): Remove class
125         variable.
126         (GLModule.shell_id_pattern): New class variable.
127         (GLModule.getShellId): New function.
128         (GLModule.getShellFunc, GLModule.getShellVar)
129         (GLModule.getConditionalName): Use it.
131 2024-05-28  Bruno Haible  <bruno@clisp.org>
133         pthread-once: Work around Cygwin 3.5.3 bug.
134         * m4/pthread-once.m4 (gl_PTHREAD_ONCE): On Cygwin, set
135         REPLACE_PTHREAD_ONCE to 1.
136         * lib/pthread-once.c (pthread_once): Add an implementation for Cygwin.
137         * doc/posix-functions/pthread_once.texi: Mention the Cygwin bug.
139 2024-05-28  Paul Eggert  <eggert@cs.ucla.edu>
141         attribute: const/pure defaults to unsequenced/reproducible
142         Also, update the commentary to reflect the fact that unsequenced
143         and reproducible functions can inspect and update storage
144         addressed by their arguments, and clarify the business about
145         returning once, and about REPRODUCIBLE and UNSEQUENCED applying to
146         pointers to functions and to function types.  It’s not clear that
147         we should encourage the use of REPRODUCIBLE and UNSEQUENCED yet,
148         as the support is not there and the likely benefits are small.
149         * m4/gnulib-common.m4 (_GL_ATTRIBUTE_CONST): Default to
150         _GL_ATTRIBUTE_UNSEQUENCED if the const attribute is lacking,
151         as every const function is also unsequenced.
152         (_GL_ATTRIBUTE_PURE): Similarly, default to _GL_ATTRIBUTE_REPRODUCIBLE
153         as every pure function is reproducible.
155 2024-05-27  Collin Funk  <collin.funk1@gmail.com>
157         maint.mk: Update system header list for #include syntax checks.
158         * top/maint.mk (gl_prefer_angle_bracket_headers_): Add byteswap.h,
159         endian.h, and stdbit.h.
161         doc: Mention byteswap.h as a system header.
162         * doc/gnulib-tool.texi (Style of #include statements): Add byteswap.h.
164 2024-05-27  Bruno Haible  <bruno@clisp.org>
166         nstrftime, c-nstrftime tests: Avoid test failures on native Windows.
167         * doc/posix-functions/tzset.texi: Add a reference.
168         * tests/test-nstrftime.h (TZ): Use time zone names that are supported by
169         native Windows.
170         (LT): Disable a test of New Zealand DST.
172 2024-05-27  Bruno Haible  <bruno@clisp.org>
174         nstrftime, c-nstrftime tests: Avoid some failures on native Windows.
175         * tests/test-nstrftime.h (tzalloc_test): On native Windows, ignore
176         differences in the way the time zone is printed.
178 2024-05-27  Bruno Haible  <bruno@clisp.org>
180         nstrftime, c-nstrftime: Make %r work on native Windows.
181         * doc/posix-functions/strftime.texi: Mention the %r problem.
182         * lib/strftime.c (__strftime_internal): On native Windows, for %r, use
183         the English AM/PM format.
185 2024-05-27  Bruno Haible  <bruno@clisp.org>
187         nstrftime, c-nstrftime: Make %h work on native Windows.
188         * doc/posix-functions/strftime.texi: Mention the %h problem.
189         * lib/strftime.c (__strftime_internal): On native Windows, for %h, do a
190         %b directive.
192 2024-05-27  Bruno Haible  <bruno@clisp.org>
194         nstrftime, c-nstrftime: Make %c work on native Windows.
195         * doc/posix-functions/strftime.texi: Mention the %c problem.
196         * lib/strftime.c: Include <locale.h> always. Include hard-locale.h.
197         (__strftime_internal): For %c, use a subformat that contains the weekday
198         name (or abbrev.) and the month name (or abbrev.).
199         * modules/nstrftime (Depends-on): Add hard-locale.
200         (Link): New section.
201         * modules/nstrftime-tests (Makefile.am): Link test-nstrftime with
202         $(HARD_LOCALE_LIB).
204 2024-05-27  Bruno Haible  <bruno@clisp.org>
206         tests: Fix internationalization problems on native Windows.
207         * doc/posix-functions/setlocale.texi: Clarify the deficiency of
208         setlocale() on native Windows.
209         * modules/c-nstrftime-tests (Depends-on): Add setlocale.
210         * modules/dfa-tests (Depends-on): Likewise.
211         * modules/hard-locale-tests (Depends-on): Likewise.
212         * modules/localcharset-tests (Depends-on): Likewise.
213         * modules/nstrftime-tests (Depends-on): Likewise.
215 2024-05-27  Bruno Haible  <bruno@clisp.org>
217         nstrftime, c-nstrftime tests: Improve debuggability.
218         * tests/test-nstrftime.h (posixtm_test, tzalloc_test, quarter_test,
219         errno_test, locales_test): Flush output after every printf invocation.
221 2024-05-27  Bruno Haible  <bruno@clisp.org>
223         parse-datetime tests: Avoid failure on native Windows.
224         * tests/test-parse-datetime.c (SOME_TIMEPOINT): New macro.
225         (main): Use it. On native Windows, use Windows time zone names.
226         Invoke tzset() after setting TZ.
227         * doc/posix-functions/gmtime.texi: Mention the native Windows problem.
228         * doc/posix-functions/localtime.texi: Likewise.
230 2024-05-27  Bruno Haible  <bruno@clisp.org>
232         tests: Don't test on the broken NetBSD 10.0 zh_CN.GB18030 locale.
233         * tests/test-mbrtowc.c (main): Add tests for one-by-one input in the
234         UTF-8 and GB18030 encodings.
235         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Add a sanity check with mbrtowc.
237 2024-05-27  Bruno Haible  <bruno@clisp.org>
239         attribute: Support ISO C 23 [[reproducible]] and [[unsequenced]].
240         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _GL_ATTR_reproducible,
241         _GL_ATTR_unsequenced, _GL_ATTRIBUTE_REPRODUCIBLE,
242         _GL_ATTRIBUTE_UNSEQUENCED.
243         * lib/attribute.h (UNSEQUENCED, REPRODUCIBLE): New macros.
245 2024-05-25  Bruno Haible  <bruno@clisp.org>
247         euidaccess: Fix test failure on native Windows.
248         * lib/euidaccess.c: Don't include <io.h>.
249         (euidaccess): On native Windows, invoke access, not _access.
251 2024-05-25  Bruno Haible  <bruno@clisp.org>
253         mcel tests: Avoid test failures due to broken GB18030 converter.
254         * tests/test-mcel.c (main): Skip most GB18030 tests on platforms where
255         the GB18030 converter is known to be broken.
257 2024-05-25  Bruno Haible  <bruno@clisp.org>
259         mcel tests: Fix typo.
260         * tests/test-mcel.c (main): Increment j instead of i.
262 2024-05-25  Bruno Haible  <bruno@clisp.org>
264         uchar-c23: Speed up mbrtoc32 on Solaris 11.4.
265         * lib/lc-charset-unicode.c (get_converters): Cache the return value.
267 2024-05-25  Bruno Haible  <bruno@clisp.org>
269         tests: Refactor.
270         * tests/test-inttostr.c (main): Report SKIP in the 'if' branch.
271         * tests/test-quotearg.c (main): Likewise.
273 2024-05-25  Bruno Haible  <bruno@clisp.org>
275         tests: Before declaring a SKIP, test if there were ASSERT failures.
276         * HACKING: Document idiom to use with test_exit_status.
277         * tests/test-c32isalnum.c (main): If there were ASSERT failures, report
278         them instead of declaring SKIP.
279         * tests/test-c32isalpha.c (main): Likewise.
280         * tests/test-c32isblank.c (main): Likewise.
281         * tests/test-c32iscntrl.c (main): Likewise.
282         * tests/test-c32isdigit.c (main): Likewise.
283         * tests/test-c32isgraph.c (main): Likewise.
284         * tests/test-c32islower.c (main): Likewise.
285         * tests/test-c32isprint.c (main): Likewise.
286         * tests/test-c32ispunct.c (main): Likewise.
287         * tests/test-c32isspace.c (main): Likewise.
288         * tests/test-c32isupper.c (main): Likewise.
289         * tests/test-c32isxdigit.c (main): Likewise.
290         * tests/test-c32rtomb.c (main): Likewise.
291         * tests/test-c32rtomb-w32.c (main): Likewise.
292         * tests/test-c32snrtombs.c (main): Likewise.
293         * tests/test-c32srtombs.c (main): Likewise.
294         * tests/test-c32stombs.c (main): Likewise.
295         * tests/test-c32tolower.c (main): Likewise.
296         * tests/test-c32toupper.c (main): Likewise.
297         * tests/test-canonicalize.c (main): Likewise.
298         * tests/test-canonicalize-lgpl.c (main): Likewise.
299         * tests/test-duplocale.c (main): Likewise.
300         * tests/test-fbufmode.c (main): Likewise.
301         * tests/test-fenv-except-state-3.c (main): Likewise.
302         * tests/test-fenv-except-trapping-1.c (main): Likewise.
303         * tests/test-fenv-except-trapping-2.c (main): Likewise.
304         * tests/test-fnmatch.c (main): Likewise.
305         * tests/test-fnmatch-w32.c (main): Likewise.
306         * tests/test-fpurge.c (main): Likewise.
307         * tests/test-freadable.c (main): Likewise.
308         * tests/test-fseek.c (main): Likewise.
309         * tests/test-fseeko.c (main): Likewise.
310         * tests/test-ftell.c (main): Likewise.
311         * tests/test-ftell3.c (main): Likewise.
312         * tests/test-ftello.c (main): Likewise.
313         * tests/test-ftello3.c (main): Likewise.
314         * tests/test-fwritable.c (main): Likewise.
315         * tests/test-fwriting.c (main): Likewise.
316         * tests/test-getrandom.c (main): Likewise.
317         * tests/test-mbrlen-w32.c (main): Likewise.
318         * tests/test-mbrtoc16.c (main): Likewise.
319         * tests/test-mbrtoc16-w32.c (main): Likewise.
320         * tests/test-mbrtoc32.c (main): Likewise.
321         * tests/test-mbrtoc32-w32.c (main): Likewise.
322         * tests/test-mbrtowc-w32.c (main): Likewise.
323         * tests/test-mbsnrtoc32s.c (main): Likewise.
324         * tests/test-mbsrtoc32s.c (main): Likewise.
325         * tests/test-mbstoc32s.c (main): Likewise.
326         * tests/test-nl_langinfo2.c (main): Likewise.
327         * tests/test-nstrftime.c (main): Likewise.
328         * tests/test-passfd.c (main): Likewise.
329         * tests/test-posix_spawn-script.c (main): Likewise.
330         * tests/test-posix_spawnp-script.c (main): Likewise.
331         * tests/test-ptsname.c (main): Likewise.
332         * tests/test-ptsname_r.c (main): Likewise.
333         * tests/test-remove.c (main): Likewise.
334         * tests/test-strfmon_l.c (main): Likewise.
335         * tests/test-utime.c (main): Likewise.
336         * tests/test-wcrtomb-w32.c (main): Likewise.
337         * tests/test-execute-script.c (main): Obey CONTINUE_AFTER_ASSERT better.
338         * tests/test-spawn-pipe-script.c (main): Likewise.
339         * tests/test-linkat.c (main): Use the common idiom.
341 2024-05-25  Collin Funk  <collin.funk1@gmail.com>
343         byteswap tests: Verify header can be used from C++.
344         * modules/byteswap-c++-tests: New file.
345         * tests/test-byteswap-c++.cc: New file.
346         * modules/byteswap-tests (Depends-on): Add byteswap-c++-tests.
348 2024-05-24  Collin Funk  <collin.funk1@gmail.com>
350         readutmp: Fix dependencies.
351         * modules/readutmp (Depends-on): Add gettimeofday.
353         boot-time, readutmp: Add a Native Windows boot time fallback.
354         * lib/boot-time-aux.h (initialize, get_windows_boot_time_fallback): New
355         functions.
356         * lib/boot-time.c [_WIN32 && !__CYGWIN__]: Include Windows headers and
357         <sys/time.h>.
358         (get_boot_time_uncached): Use the fallback.
359         * lib/readutmp.c [_WIN32 && !__CYGWIN__]: Include Windows headers and
360         <sys/time.h>.
361         (read_utmp_from_file): Use the fallback.
362         * modules/boot-time (Depends-on): Add gettimeofday.
364 2024-05-24  Bruno Haible  <bruno@clisp.org>
366         putenv tests: Put the putenv() argument strings into writable memory.
367         * tests/test-putenv.c (main): Declare static variables of type 'char[]',
368         not 'char *'.
370 2024-05-24  Bruno Haible  <bruno@clisp.org>
372         mbrtoc32 tests: Avoid failure on Solaris 11.4 (regression yesterday).
373         * tests/test-mbrtoc32.c (main): Conditionalize an assertion with
374         GL_CHAR32_T_IS_UNICODE.
376 2024-05-23  Collin Funk  <collin.funk1@gmail.com>
378         putenv tests: Silence -Wanalyzer-putenv-of-auto-var.
379         * tests/test-putenv.c (main): Declare static variables to pass to
380         putenv.
382 2024-05-23  Paul Eggert  <eggert@cs.ucla.edu>
384         POSIX.1-2024 has been approved
385         It hasn’t been published yet, so just fix documentation talking
386         about “draft” POSIX, about particular POSIX versions, etc.
387         More work will need to be done once it’s published on the web,
388         to update URLs, and better document new and changed interfaces.
390 2024-05-23  Bruno Haible  <bruno@clisp.org>
392         mbrtoc32: Strengthen tests.
393         * tests/test-mbrtoc32.c (main): Add tests for one-by-one input in the
394         UTF-8 and GB18030 encodings.
396         mbrtoc32: Work around bug in Cygwin 3.5.3.
397         * m4/mbrtoc32.m4 (gl_MBRTOC32_UTF8_LOCALE): New macro.
398         (gl_FUNC_MBRTOC32): Invoke it. If mbrtoc32 has this bug, define
399         MBRTOC32_MULTIBYTE_LOCALE_BUG and reset LOCALE_ZH_CN to 'none'.
400         * lib/mbrtoc32.c (mbrtoc32): Test MBRTOC32_MULTIBYTE_LOCALE_BUG.
401         * doc/posix-functions/mbrtoc32.texi: Mention the Cygwin bug.
403 2024-05-23  Bruno Haible  <bruno@clisp.org>
405         sethostname tests: Avoid test failure on Cygwin.
406         * tests/test-sethostname2.c (main): On Cygwin, skip the "too long
407         hostname" test.
408         * doc/glibc-functions/sethostname.texi: Mention the Cygwin problem.
410 2024-05-23  Bruno Haible  <bruno@clisp.org>
412         access, euidaccess tests: Avoid test failures on Cygwin.
413         * tests/test-access.h (test_access): On Cygwin, don't test for the
414         absence of the W_OK permission.
416 2024-05-23  Bruno Haible  <bruno@clisp.org>
418         c32is*, c32toupper tests: Avoid test failures on Cygwin.
419         * tests/test-c32isalpha.c (main): Disable tests that fail on
420         Cygwin 3.5.3.
421         * tests/test-c32iscntrl.c (main): Likewise.
422         * tests/test-c32isgraph.c (main): Likewise.
423         * tests/test-c32islower.c (main): Likewise.
424         * tests/test-c32isprint.c (main): Likewise.
425         * tests/test-c32ispunct.c (main): Likewise.
426         * tests/test-c32toupper.c (main): Likewise.
428 2024-05-23  Bruno Haible  <bruno@clisp.org>
430         poll tests: Avoid test failure on Cygwin.
431         * tests/test-poll.c (test_pipe): Disable the POLLHUP check also on
432         Cygwin.
433         * doc/posix-functions/poll.texi: Mention also Cygwin w.r.t. POLLHUP.
435 2024-05-23  Bruno Haible  <bruno@clisp.org>
437         passfd tests: Mark as expected failure on Cygwin.
438         * tests/test-passfd.c (main): Always fail on Cygwin.
439         * modules/passfd-tests (Depends-on): Add test-xfail.
440         (Makefile.am): Expect that test-passfd fails on Cygwin.
442 2024-05-23  Bruno Haible  <bruno@clisp.org>
444         renameatu: Work around Cygwin 3.4.6 bug.
445         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Test whether renameat2 works, and
446         define HAVE_WORKING_RENAMEAT2 if so.
447         * lib/renameatu.c (renameatu): Test HAVE_WORKING_RENAMEAT2 instead of
448         HAVE_RENAMEAT2.
449         * doc/glibc-functions/renameat2.texi: Mention the Cygwin bug.
451 2024-05-23  Bruno Haible  <bruno@clisp.org>
453         readlinkat, areadlinkat: Avoid test failures on Cygwin 3.4.6.
454         * tests/test-readlink.h (test_readlink): For an empty file name, allow
455         errno == EBADF.
456         * tests/test-areadlink.h (test_areadlink): Likewise.
458 2024-05-23  Bruno Haible  <bruno@clisp.org>
460         doc: Small updates regarding Cygwin.
461         * doc/glibc-functions/fallocate.texi: Update for Cygwin 3.5.x.
462         * doc/posix-functions/c8rtomb.texi: Likewise.
463         * doc/posix-functions/c16rtomb.texi: Likewise.
464         * doc/posix-functions/c32rtomb.texi: Likewise.
465         * doc/posix-functions/lseek.texi: Likewise.
466         * doc/posix-functions/mbrtoc8.texi: Likewise.
467         * doc/posix-functions/mbrtoc16.texi: Likewise.
468         * doc/posix-functions/mbrtoc32.texi: Likewise.
469         * doc/posix-functions/posix_spawnp.texi: Likewise.
471 2024-05-22  Bruno Haible  <bruno@clisp.org>
473         iconv: Reject the broken macOS 14.4 iconv implementation.
474         Reported by Daniel Collins <solemnwarning@solemnwarning.net> at
475         <https://savannah.gnu.org/bugs/?65686>.
476         * m4/iconv.m4 (AM_ICONV_LINK): In the test "for working iconv", test
477         against the macOS 14.4 iconv bug.
478         * doc/posix-functions/iconv.texi: Document the bug.
480 2024-05-22  Bruno Haible  <bruno@clisp.org>
482         stdlib: Handle glibc special invocation conventions correctly.
483         * lib/stdlib.in.h: Undefine __need_malloc_and_calloc after doing the
484         #include_next <stdlib.h>.
486 2024-05-21  Paul Eggert  <eggert@cs.ucla.edu>
488         c-strtod: include <stdio.h>
489         * lib/c-strtod.c: Include <stdio.h>, since we call sprintf.
490         Problem found by Oracle Developer Studio 12.6 on Solaris 10.
492 2024-05-21  Collin Funk  <collin.funk1@gmail.com>
494         getusershell: Split file by lines instead of spaces.
495         * lib/getusershell.c: Include string.h and filename.h
496         (GNULIB_GETUSERSHELL_SINGLE_THREAD): Remove conditional to include
497         unlocked stdio functions that are no longer used.
498         (readname): Remove function.
499         (getusershell): Use getline and process the string instead of using
500         readname. Return the first absolute file name.
501         * modules/getusershell (Depends-on): Remove unlocked-io-internal.
502         Add getline and filename.
503         * doc/multithread.texi (Multithreading Optimizations): Don't mention
504         GNULIB_GETUSERSHELL_SINGLE_THREAD.
506 2024-05-21  Paul Eggert  <eggert@cs.ucla.edu>
508         boot-time: port to Alpine 3.20.0_rc2
509         * lib/boot-time-aux.h (get_openbsd_boot_time):
510         Port to Alpine Linux, which had bogus timestamps on /var/run/utmp.
512 2024-05-21  Bruno Haible  <bruno@clisp.org>
514         trim tests: Avoid test failure on Solaris 11 OmniOS.
515         * tests/test-trim.c (main): Skip the failing test on Illumos.
517 2024-05-21  Bruno Haible  <bruno@clisp.org>
519         mcel tests: Run the test in several locales.
520         * tests/test-mcel-1.sh: New file, based on tests/test-mbrtowc-1.sh.
521         * tests/test-mcel-2.sh: New file, based on tests/test-mbrtowc-2.sh.
522         * tests/test-mcel-3.sh: New file, based on tests/test-mbrtowc-3.sh.
523         * tests/test-mcel-4.sh: New file, based on tests/test-mbrtowc-4.sh.
524         * tests/test-mcel-5.sh: New file, based on tests/test-mbrtowc-5.sh.
525         * modules/mcel-tests (Files): Add them. Add tests/macros.h,
526         m4/locale-fr.m4, m4/locale-ja.m4, m4/locale-zh.m4, m4/codeset.m4.
527         (Depends-on): Remove assert-h.
528         (configure.ac, Makefile.am): Essentially copy from
529         modules/mbrtowc-tests.
531 2024-05-21  Bruno Haible  <bruno@clisp.org>
533         flock tests: Mark as expected failure on Solaris 11.
534         * modules/flock-tests (Makefile.am): Expect that test-flock fails with
535         the Gnulib fallback.
537 2024-05-21  Bruno Haible  <bruno@clisp.org>
539         Fix "'gl_CHECK_HEADER_SYS_CDEFS_H' was expanded before it was required".
540         * m4/sys_cdefs_h.m4 (gl_CHECK_HEADER_SYS_CDEFS_H): Define through
541         AC_DEFUN_ONCE.
543 2024-05-21  Bruno Haible  <bruno@clisp.org>
545         access, euidaccess tests: Avoid test failure for root user on Solaris.
546         * tests/test-access.h (test_access): On Solaris, for the root user,
547         don't expect X_OK permissions to be absent.
548         * doc/posix-functions/access.texi: Mention the Solaris problem.
549         * doc/glibc-functions/euidaccess.texi: Likewise.
551 2024-05-21  Collin Funk  <collin.funk1@gmail.com>
553         fnmatch tests: Avoid test failure on OmniOS.
554         Using the GB18030 locale OmniOS doesn't match U+00D7 MULTIPLICATION SIGN
555         as a punctuation character.
556         * tests/test-fnmatch.c (main): Skip the test. Discovered by CI test
557         using OmniOS r151048 and reproduced on OmniOS r151050.
559 2024-05-20  Bruno Haible  <bruno@clisp.org>
561         vasnprintf: Don't abort for pseudo-denormal arguments on macOS 12.
562         Reported by Gaëtan Herfray <g.herfray@gahfy.io> via Erik Blake in
563         <https://lists.gnu.org/archive/html/bug-m4/2022-03/msg00002.html>
564         <https://lists.gnu.org/archive/html/bug-gnulib/2022-03/msg00066.html>.
565         * lib/vasnprintf.c (safe_frexpl): New function.
566         (decode_long_double, floorlog10l): Invoke it instead of frexpl.
568 2024-05-20  Paul Eggert  <eggert@cs.ucla.edu>
570         getopt-posix: port better to Alpine 3.20.0_rc1
571         Alpine’s <sys/cdefs.h> is a stub that issues a deprecation #warning.
572         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER):
573         * m4/sched_h.m4 (gl_SCHED_H): Use the new macro
574         gl_CHECK_HEADER_SYS_CDEFS_H instead of checking independently.
575         * m4/sys_cdefs_h.m4: New file.
576         * modules/getopt-posix, modules/sched (Files): Add m4/sys_cdefs_h.m4.
578 2024-05-20  Collin Funk  <collin.funk1@gmail.com>
580         tests: Update expected tests results on NetBSD.
581         These tests were fixed by the previous commit.
582         * modules/fdutimensat-tests (Depends-on): Remove test-xfail.
583         (Makefile.am): Expect that test-fdutimensat succeeds on NetBSD.
584         * modules/futimens-tests (Depends-on): Remove test-xfail.
585         (Makefile.am): Expect that test-futimens succeeds on NetBSD.
586         * modules/utimens-tests (Depends-on): Remove test-xfail.
587         (Makefile.am): Expect that test-utimens succeeds on NetBSD.
588         * modules/utimensat-tests (Depends-on): Remove test-xfail.
589         (Makefile.am): Expect that test-utimensat succeeds on NetBSD.
591         utimensat, utimens: Work around NetBSD 10.0 bugs.
592         * lib/utimens.c (fdutimens): Work around a NetBSD 10.0 UTIME_OMIT bug in
593         the same way as Linux kernel 2.6.32 and Solaris 11.1.
594         (lutimens): Likewise.
595         * lib/utimensat.c (rpl_utimensat): Likewise. Workaround a NetBSD 10.0
596         bug where invalid tv_nsec values are not rejected in the same way as
597         Linux kernel 2.6.22.19 on hppa.
598         * doc/posix-functions/utimensat.texi: Document the invalid tv_nsec bug.
600 2024-05-20  Paul Eggert  <eggert@cs.ucla.edu>
602         byteswap: fix problem on macOS
603         * m4/byteswap.m4 (gl_BYTESWAP): Quote a variable that might not
604         be defined (or the user may have defined it to something with spaces!).
605         Problem reported by Mattias Engdegård for Emacs on macOS.
607         linkat-tests: fix up assertion-failure changes
608         * tests/test-linkat.c (main): Don’t lose the failure results of
609         earlier tests.  Problem found by Coverity.
611         dfa: attempt to pacify Coverity
612         * lib/dfa.c (lex): Use ‘assume’ rather than ‘abort’,
613         to try to pacify Coverity.
614         (maybe_disable_superset_dfa): Use ‘assume’ here too, for consistency.
615         Using ‘assume’ should make the code a tiny bit faster, though
616         at the cost of having undefined behavior instead of nicely aborting.
618 2024-05-20  Bruno Haible  <bruno@clisp.org>
620         Make it easy to generate debug info for libbacktrace on macOS.
621         * build-aux/macos-compile: New file.
623 2024-05-20  Bruno Haible  <bruno@clisp.org>
625         stdint: Verify the width of 'long long' before using it as int64_t.
626         Suggested by Paul Eggert in
627         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00315.html>.
628         * lib/stdint.in.h (gl_int64_t): Verify that the number of bits of
629         'long long' is 64 before using it.
630         (gl_uint64_t): Verify that the number of bits of 'unsigned long long'
631         is 64 before using it.
633 2024-05-19  Collin Funk  <collin.funk1@gmail.com>
635         getusershell: Work around musl bugs.
636         Reported by Bruno Haible in
637         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00261.html>.
638         * doc/glibc-functions/getusershell.texi: Mention the musl bug.
639         * lib/unistd.in.h (getusershell, setusershell, endusershell): Allow the
640         functions to be declared with the rpl_ prefix.
641         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): Prepare functions to be
642         replaced on musl systems.
643         (gl_PREREQ_GETUSERSHELL): New macro.
644         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
645         REPLACE_GETUSERSHELL.
646         * modules/getusershell (Depends-on): Update module conditions to account
647         for the function being available but replaced by Gnulib.
648         (configure.ac): Likewise. Invoke gl_PREREQ_GETUSERSHELL.
650 2024-05-18  Bruno Haible  <bruno@clisp.org>
652         abort-debug: Prefer libbacktrace to execinfo.
653         * lib/abort-debug.c: Include <backtrace.h>.
654         (state): New variable.
655         (print_stack_trace): Add another implementation.
656         (_gl_pre_abort, rpl_abort): Also test HAVE_LIBBACKTRACE.
657         * m4/abort-debug.m4 (gl_ABORT_DEBUG_EARLY): Check for libbacktrace.
658         Set LIBS, not LDFLAGS.
660 2024-05-18  Bruno Haible  <bruno@clisp.org>
662         mkfifoat: Work around a macOS 14 bug.
663         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Also test the case of a dangling
664         symlink.
665         * doc/posix-functions/mkfifoat.texi: Mention the macOS bug.
667 2024-05-18  Paul Eggert  <eggert@cs.ucla.edu>
669         sha512-buffer: port back to 32-bit-only hosts
670         Port to platforms lacking 64-bit integers (something that Emacs
671         still attempts to do, in theory) by adding an u64bswap primitive
672         to u64.h and using that, instead of using bswap_64.  This fixes a
673         bug I made in commit 0d45ec7c033c165ad73a6509c7fa84aa67edf4ea
674         dated Sun Jun 17 14:35:37 2018 -0700.
675         * lib/sha512.c (SWAP): Use u64bswap, not bswap_64, to port
676         to older platforms lacking 64-bit integers.
677         * lib/u64.h: Include stddef.h, for size_t.
678         Include byteswap.h, for bswap_64 (on platforms with 64-bit int),
679         bswap_32.
680         (u64rol): Now a function, not a macro, so that it evaluates
681         its args only once.
682         (u64uint32): New typedef.
683         (u64, u64hilo, u64lo): Use it.
684         (_GL_U64_MASK32): New macro.
685         (u64size, u64plus, u64shl, u64shr, u64plus): Use it as needed for
686         odd platforms where unsigned int is wider than 32 bits.
687         (u64lt): Return bool, not int.
688         * modules/u64 (Depends-on): Add byteswap, stdbool.
689         * tests/test-u64.c (main): Test u64bswap.
691 2024-05-18  Collin Funk  <collin.funk1@gmail.com>
693         dup3: Update documentation and expected test results.
694         * doc/glibc-functions/dup3.texi: Mention NetBSD bug fixed by the Gnulib
695         implementation after the previous commit.
696         * modules/dup3-tests (Depends-on): Remove test-xfail.
697         (Makefile.am): Don't expect test-dup3 to fail on NetBSD.
699         dup3: Fix behavior for equal file descriptors on NetBSD.
700         * lib/dup3.c (dup3) [__NetBSD__]: Check for equal file descriptors upon
701         a successful call to dup3. If they are equal fail with errno == EINVAL.
703 2024-05-18  Collin Funk  <collin.funk1@gmail.com>
705         endian: Make sure system headers can be included.
706         Reported by Bruno Haible in
707         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00290.html>.
708         * lib/endian.in.h (be16toh, be32toh, be64toh, htobe16, htobe32, htobe64)
709         (le16toh, le32toh, le64toh, htole16, htole32, htole64): Don't define
710         functions if the system has working versions.
711         * m4/endian_h.m4 (gl_ENDIAN_H): Separate checks for stdint types and
712         proper macro/function definitions.
713         * modules/endian (Depends-on): Add include_next. Update module
714         dependency conditions.
715         (Makefile.am): Perform sed replacements on the header substitute.
717 2024-05-18  Bruno Haible  <bruno@clisp.org>
719         abort-debug: Integrate with CONTINUE_AFTER_ASSERT.
720         * lib/stdlib.in.h (_gl_pre_abort): New declaration.
721         * lib/abort-debug.c (_gl_pre_abort): New function.
722         * tests/macros.h (ASSERT, ASSERT_NO_STDIO): If CONTINUE_AFTER_ASSERT
723         is 1 and the assertion fails, invoke _gl_pre_abort.
725 2024-05-18  Bruno Haible  <bruno@clisp.org>
727         tests: Support showing all assertion failures, not just the first one.
728         * tests/macros.h (CONTINUE_AFTER_ASSERT): New macro.
729         (test_exit_status): New variable.
730         (ASSERT, ASSERT_NO_STDIO): If CONTINUE_AFTER_ASSERT is 1, set
731         test_exit_status instead of aborting.
732         * tests/**/test-*.{c,h,cc} (main): Instead of exiting with exit code 0,
733         exit with exit code test_exit_status.
734         * tests/test-spawn-pipe-child.c: Undefine CONTINUE_AFTER_ASSERT.
735         * tests/uninorm/test-nf*.c: Include macros.h.
736         * tests/uninorm/test-u32-nf*-big.c: Likewise.
737         * tests/random*.c: Define NO_MAIN_HERE.
739 2024-05-18  Paul Eggert  <eggert@cs.ucla.edu>
741         byteswap: pacify GCC 4.4.7 and older
742         Problem reported by Bruno Haible in:
743         https://lists.gnu.org/r/bug-gnulib/2024-05/msg00277.html
744         * lib/byteswap.in.h (bswap_16, bswap_32, bswap_64):
745         Compute the mask rather than using long constants like
746         0xff00000000000000 that may generate bogus warnings.
748 2024-05-18  Bruno Haible  <bruno@clisp.org>
750         endian tests: Verify that it can be used from C++.
751         * tests/test-endian-c++.cc: New file.
752         * modules/endian-c++-tests: New file.
753         * modules/endian-tests (Depends-on): Add endian-c++-tests.
755 2024-05-18  Bruno Haible  <bruno@clisp.org>
757         endian: Update doc and strengthen tests.
758         * doc/glibc-headers/endian.texi: Reference LSB and future POSIX
759         specifications. Update platforms list.
760         * tests/test-endian.c: Verify that BYTE_ORDER, LITTLE_ENDIAN, BIG_ENDIAN
761         can be used in #if.
763 2024-05-18  Collin Funk  <collin.funk1@gmail.com>
765         endian: Add tests.
766         * tests/test-endian.c: New file.
767         * modules/endian-tests: New file.
769         endian: New module.
770         * doc/glibc-headers/endian.texi, doc/gnulib-tool.texi: Mention it.
771         * lib/endian.c: New file.
772         * lib/endian.in.h: New file.
773         * m4/endian_h.m4: New file.
774         * modules/endian: New file.
776 2024-05-17  Bruno Haible  <bruno@clisp.org>
778         tests: Fix link errors (regression today).
779         * tests/test-execute-child.c (abort): Undefine.
780         * tests/test-spawn-pipe-child.c (abort): Likewise.
782 2024-05-17  Collin Funk  <collin.funk1@gmail.com>
784         getusershell tests: Fail if empty lines are returned.
785         * tests/test-getusershell.c (first_pass): Check the result of malloc.
786         Make sure '\0' isn't returned from getusershell when there is an empty
787         line in /etc/shells.
789 2024-05-17  Bruno Haible  <bruno@clisp.org>
791         unistd: Fix compilation error with MSVC in C++ mode.
792         * lib/unistd.in.h (read, write): Use _GL_CXXALIAS_MDA_CAST instead of
793         _GL_CXXALIAS_MDA.
795 2024-05-17  Bruno Haible  <bruno@clisp.org>
797         stdbit-h: Fix compilation error with MSVC in C++ mode.
798         * lib/stdbit.in.h (_BitScanReverse, _BitScanReverse64, _BitScanForward,
799         _BitScanForward64, __cpuid, __popcnt, __popcnt64): Declare with a
800         prototype.
801         * lib/count-leading-zeros.h (_BitScanReverse, _BitScanReverse64):
802         Likewise.
803         * lib/count-trailing-zeros.h (_BitScanForward, _BitScanForward64):
804         Likewise.
805         * lib/count-one-bits.h (__cpuid, __popcnt, __popcnt64): Likewise.
807 2024-05-17  Paul Eggert  <eggert@cs.ucla.edu>
809         byteswap: port better to limited platforms
810         POSIX does not require uint64_t, and the C standard
811         does not require uint16_t or uint32_t either, so port
812         to platforms that lack these types.  The POSIX limitation
813         is the only significant one in practice.  I ran into this
814         issue when updating Emacs, which still ports to platforms
815         lacking 64-bit types.
816         * lib/byteswap.in.h (bswap_16, bswap_32, bswap_64):
817         Accept and return uint_leastN_t instead of uintN_t,
818         for portability to non-POSIX hosts that lack uintN_t.
819         Almost no platforms these days lack the types, but
820         it’s easy to port so let’s do that.  Also, redo to avoid
821         unnecssary parentheses, as these are now functions not macros.
822         (bswap_64): Define only if UINT_LEAST64_MAX, for benefit
823         of not-quite-C99 platforms.  This is similar to what
824         bitrotate.h does.
825         * tests/test-byteswap.c (test_bswap_constant)
826         (test_bswap_eval_once, test_bswap_double) [!UINT_LEAST64_MAX]:
827         Do not test 64-bit swaps.
829 2024-05-17  Bruno Haible  <bruno@clisp.org>
831         stdbit-h: Fix leading-zeros/ones functions on 64-bit MSVC.
832         * lib/stdbit.in.h (__gl_stdbit_clzll) [_MSC_VER]: On x86_64, use
833         _BitScanReverse64.
835 2024-05-17  Bruno Haible  <bruno@clisp.org>
837         getusershell tests: Fix link error on MSVC.
838         * modules/getusershell-tests (Makefile.am): Link test-getusershell with
839         $(LIBINTL).
841 2024-05-17  Bruno Haible  <bruno@clisp.org>
843         tests: Mark tests that fail on NetBSD as expected failures.
844         * modules/dup3-tests (Depends-on): Add test-xfail.
845         (Makefile.am): Expect that test-dup3 fails on NetBSD.
846         * modules/fdutimensat-tests (Depends-on): Add test-xfail.
847         (Makefile.am): Expect that test-fdutimensat fails on NetBSD.
848         * modules/futimens-tests (Depends-on): Add test-xfail.
849         (Makefile.am): Expect that test-futimens fails on NetBSD.
850         * modules/utimens-tests (Depends-on): Add test-xfail.
851         (Makefile.am): Expect that test-utimens fails on NetBSD.
852         * modules/utimensat-tests (Depends-on): Add test-xfail.
853         (Makefile.am): Expect that test-utimensat fails on NetBSD.
855 2024-05-17  Bruno Haible  <bruno@clisp.org>
857         New module 'test-xfail'.
858         * modules/test-xfail: New file.
860 2024-05-17  Bruno Haible  <bruno@clisp.org>
862         New module 'abort-debug'.
863         * lib/stdlib.in.h (abort): New declaration.
864         * lib/abort-debug.c: New file.
865         * m4/abort-debug.m4: New file.
866         * modules/abort-debug: New file.
867         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize
868         GNULIB_ABORT_DEBUG.
869         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_ABORT.
870         * modules/stdlib (Makefile.am): Substitute GNULIB_ABORT_DEBUG,
871         REPLACE_ABORT.
873 2024-05-17  Bruno Haible  <bruno@clisp.org>
875         execinfo: Update doc.
876         * doc/glibc-headers/execinfo.texi: Mention musl libc.
877         * doc/glibc-functions/backtrace.texi: Likewise.
878         * doc/glibc-functions/backtrace_symbols.texi: Likewise.
879         * doc/glibc-functions/backtrace_symbols_fd.texi: Likewise.
881 2024-05-17  Bruno Haible  <bruno@clisp.org>
883         tests: Fix dependencies to test-framework-sh.
884         * modules/argp-tests (Depends-on): Add test-framework-sh.
885         * modules/argp-version-etc-tests (Depends-on): Likewise.
886         * modules/dfa-tests (Depends-on): Likewise.
887         * modules/error-tests (Depends-on): Likewise.
888         * modules/readtokens-tests (Depends-on): Likewise.
889         * modules/string-desc-tests (Depends-on): Likewise.
890         * modules/verror-tests (Depends-on): Likewise.
891         * modules/xstdopen-tests (Depends-on): Remove test-framework-sh.
893 2024-05-17  Bruno Haible  <bruno@clisp.org>
895         stdbit-h: Fix syntax error.
896         * lib/stdbit.in.h (__gl_stdbit_ctzll) [_MSC_VER]: Fix syntax error.
898 2024-05-17  Bruno Haible  <bruno@clisp.org>
900         sys_select: Fix compilation error in C++ mode on macOS 13, 14.
901         * lib/sys_select.in.h (select): Disable _GL_CXXALIASWARN invocation on
902         non-glibc systems.
904 2024-05-17  Bruno Haible  <bruno@clisp.org>
906         putenv-gnu: Update documentation.
907         * doc/posix-functions/putenv.texi: Refer also to the glibc
908         documentation. Use the usual doc structure.
910 2024-05-17  Collin Funk  <collin.funk1@gmail.com>
912         doc: Update outdated module name.
913         * doc/ld-version-script.texi (LD Version Scripts): Refer to
914         'lib-symbol-visibility' instead of 'visibility'.
916 2024-05-16  Collin Funk  <collin.funk1@gmail.com>
918         byteswap: Use __has_builtin portably.
919         Reported by Paul Eggert in
920         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00249.html>.
921         * lib/byteswap.in.h (_GL_BYTESWAP_HAS_BUILTIN_BSWAP16)
922         (_GL_BYTESWAP_HAS_BUILTIN_BSWAP32)
923         (_GL_BYTESWAP_HAS_BUILTIN_BSWAP64): Define using the GCC version or
924         __has_builtin after checking that it is defined.
925         (bswap_16, bswap_32, bswap_64): Use the macros.
926         * modules/byteswap (Depends-on): Add stdbool as a conditional
927         dependency.
929 2024-05-16  Paul Eggert  <eggert@cs.ucla.edu>
931         putenv-tests: pacify gcc -Wdiscarded-qualifiers
932         * tests/test-putenv.c (main): Don’t pass a string literal
933         to a function expecting ‘char *’.
935         alloca-opt-tests: add a ‘volatile’
936         * tests/test-alloca-opt.c (func) [HAVE_ALLOCA]:
937         Now volatile, to foil whole-program optimization.
939 2024-05-16  Collin Funk  <collin.funk1@gmail.com>
941         byteswap tests: Strengthen tests.
942         * modules/byteswap-tests (Depends-on): Add stdint.
943         * tests/test-byteswap.c (test_bswap_constant, test_bswap_eval_once)
944         (test_bswap_double): New functions.
945         (main): Use them.
947 2024-05-16  Collin Funk  <collin.funk1@gmail.com>
949         byteswap: Use inline functions instead of macros.
950         * lib/byteswap.c: New file.
951         * lib/byteswap.in.h (bswap_16, bswap_32, bswap_64): Use inline functions
952         instead of macros.
953         * m4/byteswap.m4 (gl_BYTESWAP): Check that bswap functions can be used
954         on double values.
955         * modules/byteswap (Files): Add lib/byteswap.c.
956         (Depends-on): Add extern-inline and stdint as conditional dependencies.
957         (Makefile.am): Add lib/byteswap.c to lib_SOURCES.
959 2024-05-16  Collin Funk  <collin.funk1@gmail.com>
961         gnulib-tool.py: Fix return value when exiting with Ctrl-C.
962         * pygnulib/main.py (main_with_exception_handling): Catch
963         KeyboardInterrupts and exit with a return code of 1.
965 2024-05-16  Collin Funk  <collin.funk1@gmail.com>
967         unsetenv tests: Update module dependencies.
968         * modules/unsetenv-tests (Depends-on): Depend on 'putenv-gnu' instead of
969         the deprecated 'putenv'.
971 2024-05-16  Collin Funk  <collin.funk1@gmail.com>
973         Rename module 'putenv' to 'putenv-gnu'.
974         * modules/putenv-gnu: Renamed from modules/putenv.
975         (Description): Mention the removal of environment variables.
976         * modules/putenv-gnu-tests: Renamed from modules/putenv-tests.
977         * modules/putenv: New file, an indirection to the new module.
978         * doc/posix-functions/putenv.texi: Mention the new module name.
979         * NEWS: Mention the change.
981 2024-05-16  Collin Funk  <collin.funk1@gmail.com>
983         putenv: Add tests.
984         * tests/test-putenv.c: New file.
985         * modules/putenv-tests: New file.
987 2024-05-15  Collin Funk  <collin.funk1@gmail.com>
989         gnulib-tool.py: Don't print tracebacks when Ctrl-C is pressed.
990         Suggested by Pádraig Brady in
991         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00200.html>.
992         * pygnulib/main.py (cli_exception): New function.
993         (main_with_exception_handling): Use it.
995 2024-05-15  Bruno Haible  <bruno@clisp.org>
997         stdbit-h: Add tests.
998         * tests/test-stdbit-h.c: New file.
999         * tests/test-stdbit-h-c++.cc: New file.
1000         * modules/stdbit-h-tests: New file.
1001         * modules/stdbit-h-c++-tests: New file.
1003 2024-05-15  Bruno Haible  <bruno@clisp.org>
1005         stdbit-h: Make it work in C++ mode.
1006         * lib/stdbit.in.h: Remove extraneous 'extern "C" {' marker.
1008 2024-05-15  Bruno Haible  <bruno@clisp.org>
1010         stdbit-h, stdc_*: New modules, part of the stdbit module.
1011         * lib/stdbit.in.h (_GL_STDC_*_INLINE): New macros.
1012         Enclose function definitions in #if @GL_STDC_*@ conditionals.
1013         * lib/stdc_leading_zeros.c: New file.
1014         * lib/stdc_leading_ones.c: New file.
1015         * lib/stdc_trailing_zeros.c: New file.
1016         * lib/stdc_trailing_ones.c: New file.
1017         * lib/stdc_first_leading_zero.c: New file.
1018         * lib/stdc_first_leading_one.c: New file.
1019         * lib/stdc_first_trailing_zero.c: New file.
1020         * lib/stdc_first_trailing_one.c: New file.
1021         * lib/stdc_count_zeros.c: New file.
1022         * lib/stdc_count_ones.c: New file, based on lib/stdbit.c.
1023         * lib/stdc_has_single_bit.c: New file.
1024         * lib/stdc_bit_width.c: New file.
1025         * lib/stdc_bit_floor.c: New file.
1026         * lib/stdc_bit_ceil.c: New file.
1027         * lib/stdbit.c (__gl_stdbit_popcount_support): Remove variable.
1028         * m4/stdbit_h.m4 (gl_STDBIT_H): Initialize GL_STDC_* variables.
1029         * modules/stdbit-h: New file, based on modules/stdbit.
1030         (Depends-on): Add gen-header.
1031         (Makefile.am): Substitute GL_STDC_* variables.
1032         * modules/stdc_leading_zeros: New file.
1033         * modules/stdc_leading_ones: New file.
1034         * modules/stdc_trailing_zeros: New file.
1035         * modules/stdc_trailing_ones: New file.
1036         * modules/stdc_first_leading_zero: New file.
1037         * modules/stdc_first_leading_one: New file.
1038         * modules/stdc_first_trailing_zero: New file.
1039         * modules/stdc_first_trailing_one: New file.
1040         * modules/stdc_count_zeros: New file.
1041         * modules/stdc_count_ones: New file.
1042         * modules/stdc_has_single_bit: New file.
1043         * modules/stdc_bit_width: New file.
1044         * modules/stdc_bit_floor: New file.
1045         * modules/stdc_bit_ceil: New file.
1046         * modules/stdbit: Change to a pure composition module.
1047         * modules/stdc_leading_zeros-tests: New file, based on
1048         modules/stdbit-tests.
1049         * modules/stdc_leading_ones-tests: New file, based on
1050         modules/stdbit-tests.
1051         * modules/stdc_trailing_zeros-tests: New file, based on
1052         modules/stdbit-tests.
1053         * modules/stdc_trailing_ones-tests: New file, based on
1054         modules/stdbit-tests.
1055         * modules/stdc_first_leading_zero-tests: New file, based on
1056         modules/stdbit-tests.
1057         * modules/stdc_first_leading_one-tests: New file, based on
1058         modules/stdbit-tests.
1059         * modules/stdc_first_trailing_zero-tests: New file, based on
1060         modules/stdbit-tests.
1061         * modules/stdc_first_trailing_one-tests: New file, based on
1062         modules/stdbit-tests.
1063         * modules/stdc_count_zeros-tests: New file, based on
1064         modules/stdbit-tests.
1065         * modules/stdc_count_ones-tests: New file, based on
1066         modules/stdbit-tests.
1067         * modules/stdc_has_single_bit-tests: New file, based on
1068         modules/stdbit-tests.
1069         * modules/stdc_bit_width-tests: New file, based on modules/stdbit-tests.
1070         * modules/stdc_bit_floor-tests: New file, based on modules/stdbit-tests.
1071         * modules/stdc_bit_ceil-tests: New file, based on modules/stdbit-tests.
1072         * modules/stdbit-tests: Remove file.
1073         * doc/posix-functions/stdc_leading_zeros.texi: Update.
1074         * doc/posix-functions/stdc_leading_ones.texi: Likewise.
1075         * doc/posix-functions/stdc_trailing_zeros.texi: Likewise.
1076         * doc/posix-functions/stdc_trailing_ones.texi: Likewise.
1077         * doc/posix-functions/stdc_first_leading_zero.texi: Likewise.
1078         * doc/posix-functions/stdc_first_leading_one.texi: Likewise.
1079         * doc/posix-functions/stdc_first_trailing_zero.texi: Likewise.
1080         * doc/posix-functions/stdc_first_trailing_one.texi: Likewise.
1081         * doc/posix-functions/stdc_count_zeros.texi: Likewise.
1082         * doc/posix-functions/stdc_count_ones.texi: Likewise.
1083         * doc/posix-functions/stdc_has_single_bit.texi: Likewise.
1084         * doc/posix-functions/stdc_bit_width.texi: Likewise.
1085         * doc/posix-functions/stdc_bit_floor.texi: Likewise.
1086         * doc/posix-functions/stdc_bit_ceil.texi: Likewise.
1088 2024-05-15  Paul Eggert  <eggert@cs.ucla.edu>
1090         stdbit: tweak first_leading for GCC
1091         * lib/stdbit.in.h (stdc_first_leading_zero)
1092         (stdc_first_leading_one, stdc_first_trailing_zero_uc)
1093         (stdc_first_trailing_one_uc): Redo to avoid the need for a
1094         conditional branch, at least on x86-64 with GCC 14.
1096         * lib/stdbit.in.h (__gl_stdbit_clz, __gl_stdbit_clzl)
1097         (__gl_stdbit_clzll, __gl_stdbit_ctz, __gl_stdbit_ctzl)
1098         (__gl_stdbit_ctzll): Work even if the argument is zero.
1099         All callers changed.  This should help avoid branches
1100         on non-GCC-like platforms.
1102 2024-05-15  Bruno Haible  <bruno@clisp.org>
1104         vasnprintf: Avoid a dummy memory allocation.
1105         * lib/vasnprintf.c (NOMEM_PTR): New macro.
1106         (multiply, divide): Return it instead of NULL in case of memory
1107         allocation failure.
1108         (scale10_round_decimal_decoded): Update.
1110 2024-05-15  Bruno Haible  <bruno@clisp.org>
1112         getusershell tests: Verify the function declarations.
1113         * tests/test-getusershell.c: Include signature.h.
1114         (getusershell, setusershell, endusershell): Check the signatures.
1115         * modules/getusershell-tests (Files): Add tests/signature.h.
1117 2024-05-15  Collin Funk  <collin.funk1@gmail.com>
1119         getusershell: Add tests.
1120         * modules/getusershell-tests: New file.
1121         * tests/test-getusershell.c: New file.
1123 2024-05-14  Collin Funk  <collin.funk1@gmail.com>
1125         gnulib-tool.sh: Don't continue creating testdirs when destdir exists.
1126         * gnulib-tool.sh (create-testdir, create-megatestdir): Fail if the
1127         destination directory exists instead of creating files and failing to
1128         patch test driver.
1130 2024-05-14  Paul Eggert  <eggert@cs.ucla.edu>
1132         stdbit: fix dependency
1133         * modules/stdbit (Depends-on): Add extern-inline.
1135 2024-05-14  Bruno Haible  <bruno@clisp.org>
1137         gnulib-tool.py: Fix formatting of error message in last commit.
1138         * pygnulib/main.py (main_with_exception_handling): Use the usual
1139         formatting of error messages.
1141 2024-05-13  Collin Funk  <collin.funk1@gmail.com>
1143         gnulib-tool.py: Don't continue creating testdirs when destdir exists.
1144         * pygnulib/GLError.py (GLError.__init__, GLError.__repr__): Add a new
1145         error number for destination directories that already exist.
1146         * pygnulib/main.py (main_with_exception_handling): Print the message.
1147         * pygnulib/GLTestDir.py (GLTestDir.__init__, GLMegaTestdir.__init__):
1148         Fail if the destination directory exists instead of creating files and
1149         failing to patch test driver.
1151 2024-05-13  Paul Eggert  <eggert@cs.ucla.edu>
1153         stdbit: redo clzll without lookup table
1154         * lib/stdbit.c (__gl_stdbit_clztab):
1155         * lib/stdbit.in.h (__gl_stdbit_clzll):
1156         [!_GL_STDBIT_HAS_BUILTIN_CLZ && !_MSC_VER]: Rewrite to avoid the
1157         need for a lookup table in memory, and remove the lookup table.
1158         Do this by shrinking the table to 64 bits and putting it in a 64-bit
1159         constant.  Although this needs another round of shifts, it avoids
1160         the need for a multiplication and memory access a la de Bruijn,
1161         and is probably a win.
1163 2024-05-13  Bruno Haible  <bruno@clisp.org>
1165         stdbit tests: Adhere better to Gnulib naming conventions.
1166         * tests/from-glibc/tst-stdc_bit_ceil.c: Renamed from
1167         tests/tst-stdc_bit_ceil.c.
1168         * tests/from-glibc/tst-stdc_bit_floor.c: Renamed from
1169         tests/tst-stdc_bit_floor.c.
1170         * tests/from-glibc/tst-stdc_bit_width.c: Renamed from
1171         tests/tst-stdc_bit_width.c.
1172         * tests/from-glibc/tst-stdc_count_ones.c: Renamed from
1173         tests/tst-stdc_count_ones.c.
1174         * tests/from-glibc/tst-stdc_count_zeros.c: Renamed from
1175         tests/tst-stdc_count_zeros.c.
1176         * tests/from-glibc/tst-stdc_first_leading_one.c: Renamed from
1177         tests/tst-stdc_first_leading_one.c.
1178         * tests/from-glibc/tst-stdc_first_leading_zero.c: Renamed from
1179         tests/tst-stdc_first_leading_zero.c.
1180         * tests/from-glibc/tst-stdc_first_trailing_one.c: Renamed from
1181         tests/tst-stdc_first_trailing_one.c.
1182         * tests/from-glibc/tst-stdc_first_trailing_zero.c: Renamed from
1183         tests/tst-stdc_first_trailing_zero.c.
1184         * tests/from-glibc/tst-stdc_has_single_bit.c: Renamed from
1185         tests/tst-stdc_has_single_bit.c.
1186         * tests/from-glibc/tst-stdc_leading_ones.c: Renamed from
1187         tests/tst-stdc_leading_ones.c.
1188         * tests/from-glibc/tst-stdc_leading_zeros.c: Renamed from
1189         tests/tst-stdc_leading_zeros.c.
1190         * tests/from-glibc/tst-stdc_trailing_ones.c: Renamed from
1191         tests/tst-stdc_trailing_ones.c.
1192         * tests/from-glibc/tst-stdc_trailing_zeros.c: Renamed from
1193         tests/tst-stdc_trailing_zeros.c.
1194         * tests/from-glibc/tst-stdbit.h: Renamed from tests/tst-stdbit.h.
1195         * tests/from-glibc/support/test-driver.c: Renamed from
1196         tests/support/test-driver.c.
1197         * modules/stdbit-tests (Files, Makefile.am): Update.
1198         * config/srclist.txt: Update.
1200 2024-05-13  Bruno Haible  <bruno@clisp.org>
1202         config: Clarify which destination files have a different basename.
1203         * config/srclist.txt: Specify the gnulib-side basename in the third
1204         column of a few entries.
1206         config: Document the update script better.
1207         * config/srclist-update: Improve comments.
1209 2024-05-13  Bruno Haible  <bruno@clisp.org>
1211         doc: Document our conventions for *.m4 files.
1212         Suggested by Paul Eggert in
1213         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00156.html>.
1214         * doc/gnulib.texi (Autoconf macros): Document the structure of our *.m4
1215         files.
1217 2024-05-13  Paul Eggert  <eggert@cs.ucla.edu>
1219         stdbit: fix typo in MS-Windows port
1220         Problem reported by Mattias Engdegård <https://bugs.gnu.org/70898#8>.
1221         * lib/stdbit.in.h (__gl_stdbit_popcount_support) [_MSC_VER]:
1222         Fix misspelling in decl.
1224 2024-05-13  Bruno Haible  <bruno@clisp.org>
1226         doc: Document <stdbit.h> function-like macros.
1227         * doc/posix-headers/stdbit.texi: Reference ISO C 23 as the
1228         documentation. Update platforms list.
1229         * doc/posix-functions/stdc_leading_zeros.texi: New file.
1230         * doc/posix-functions/stdc_leading_ones.texi: New file.
1231         * doc/posix-functions/stdc_trailing_zeros.texi: New file.
1232         * doc/posix-functions/stdc_trailing_ones.texi: New file.
1233         * doc/posix-functions/stdc_first_leading_zero.texi: New file.
1234         * doc/posix-functions/stdc_first_leading_one.texi: New file.
1235         * doc/posix-functions/stdc_first_trailing_zero.texi: New file.
1236         * doc/posix-functions/stdc_first_trailing_one.texi: New file.
1237         * doc/posix-functions/stdc_count_zeros.texi: New file.
1238         * doc/posix-functions/stdc_count_ones.texi: New file.
1239         * doc/posix-functions/stdc_has_single_bit.texi: New file.
1240         * doc/posix-functions/stdc_bit_width.texi: New file.
1241         * doc/posix-functions/stdc_bit_floor.texi: New file.
1242         * doc/posix-functions/stdc_bit_ceil.texi: New file.
1243         * doc/gnulib.texi (Function Substitutes): Include them all.
1245 2024-05-13  Paul Eggert  <eggert@cs.ucla.edu>
1247         stdbit: port to theoretical platforms
1248         Port to theoretical platforms that C and POSIX allow but are not
1249         likely to ever exist.  This is mostly just to document the existing
1250         source code: when optimizing, the machine code should be largely
1251         unchanged even on platforms lacking __builtin_clz etc.
1252         * lib/stdbit.in.h: Omit static_assert that checks for 8-bit bits.
1253         stdbit-tests checks for this, and omitting the static_assert here
1254         removes a module dependency.
1255         (__gl_stdbit_clzll): Do not limit word size to 128 bits.
1256         (__gl_stdbit_popcount255): Rename from __gl_stdbit_popcount255.
1257         All uses changed.  Do not limit word size to 255 bits.  Correct
1258         bugs on odd theoretical platforms where the word size is not a
1259         power of 2.
1260         * modules/stdbit (Depends-on): Remove assert-h.
1262 2024-05-12  Paul Eggert  <eggert@cs.ucla.edu>
1264         stdbit-tests: make GNULIB_TEST_STDBIT work standalone
1265         * modules/stdbit-tests (GNULIB_TEST_STDBIT):
1266         Do not define in config.h, since config.h is conditionally
1267         included depending on this macro.
1268         Instead, specify -DGNULIB_TEST_STDBIT in the CPPFLAGS
1269         of each test.
1271 2024-05-12  Simon Josefsson  <simon@josefsson.org>
1273         maintainer-makefile: Silence announce-gen error with GNULIB_REVISION.
1274         * top/maint.mk (gnulib-version): Silence git describe on failure.
1276 2024-05-12  Bruno Haible  <bruno@clisp.org>
1278         execinfo: Document known bugs.
1279         * doc/glibc-functions/backtrace.texi: Mention the various bugs on
1280         FreeBSD, NetBSD, OpenBSD.
1281         * doc/glibc-functions/backtrace_symbols_fd.texi: Mention the glibc bug.
1283 2024-05-12  Bruno Haible  <bruno@clisp.org>
1285         execinfo tests: Strengthen tests.
1286         * tests/test-execinfo.c (test_backtrace): Add an argument. Check the
1287         return value of backtrace(). Check that backtrace_symbols_fd is defined.
1288         Check the return value of backtrace_symbols().
1289         (main): Test also the case of a short buffer.
1290         * modules/execinfo-tests (Makefile.am): Verify that LIB_EXECINFO is
1291         defined.
1293 2024-05-11  Paul Eggert  <eggert@cs.ucla.edu>
1295         stdbit: don’t assume -DHAVE_CONFIG_H
1296         This is needed for diffutils, which doesn’t define HAVE_CONFIG_H.
1297         There needs to be some way for a test shared with glibc to discover
1298         whether it should use the Gnulib or the glibc testing framework,
1299         and I guess this is it.
1300         * modules/stdbit-tests (GNULIB_TEST_STDBIT): Define.
1301         * tests/tst-stdbit.h: Use GNULIB_TEST_STDBIT, not HAVE_CONFIG_H.
1303 2024-05-11  Collin Funk  <collin.funk1@gmail.com>
1305         gnulib-tool.py: Filter out dependencies that cannot be found.
1306         Reported by Paul Eggert in
1307         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00136.html>.
1308         * pygnulib/GLModuleSystem.py (GLModule.getDependenciesWithConditions):
1309         Reorder conditionals to avoid duplicate checks. Filter out None from the
1310         gathered dependencies when gathering module dependencies. Let
1311         GLModuleSystem.find() warn instead of crashing.
1313 2024-05-11  Collin Funk  <collin.funk1@gmail.com>
1315         execinfo: Add tests.
1316         * modules/execinfo-tests: New file.
1317         * tests/test-execinfo.c (test_backtrace): New function. Simply test that
1318         the symbols defined in execinfo.h can be used.
1319         (main): Use it.
1321 2024-05-11  Bruno Haible  <bruno@clisp.org>
1323         Continue to use spaces for indentation, not tabs.
1324         * lib/strftime.c: Untabify. Correct indentation.
1325         * tests/test-posix_memalign.c: Untabify.
1327 2024-05-11  Bruno Haible  <bruno@clisp.org>
1329         error-h: Avoid namespace pollution on mingw.
1330         * lib/error.in.h: Don't include mingw's <error.h>.
1332 2024-05-11  Paul Eggert  <eggert@cs.ucla.edu>
1334         stdbit: clean up namespace and simplify
1335         Fix namespace pollution in substitute stdbit.h.
1336         Clean up and simplify some of the non-GCC code, by preferring
1337         inline functions to macros and substituting something
1338         more straightforward than a de Bruijn hash (possibly faster?).
1339         The non-GCC non-C23 substitutes should all compile to
1340         branch-free code, if the compiler is good.
1341         * lib/stdbit.c (COUNT_LEADING_ZEROS_INLINE)
1342         (COUNT_TRAILING_ZEROS_INLINE, COUNT_ONE_BITS_INLINE): Remove.
1343         (__gl_stdbit_clztab) [!_GL_STDBIT_HAS_BUILTIN_CLZ && !_MSC_VER]:
1344         New constant array.
1345         (__gl_stdbit_popcount_support): Adjust to stdbit.in.h changes.
1346         * lib/stdbit.in.h: Do not include <limits.h> or <stdlib.h>.
1347         Check that bytes are 8 bits.
1348         (COUNT_LEADING_ZEROS_INLINE, COUNT_TRAILING_ZEROS_INLINE)
1349         (COUNT_ONE_BITS_INLINE, COUNT_LEADING_ZEROS)
1350         (count_leading_zeros_32, count_leading_zeros)
1351         (count_leading_zeros_l, count_leading_zeros_ll)
1352         (COUNT_TRAILING_ZEROS, count_trailing_zeros_32)
1353         (count_trailing_zeros, count_trailing_zeros_l)
1354         (count_trailing_zeros_ll, COUNT_ONE_BITS, count_one_bits_32)
1355         (COUNT_ONE_BITS_GENERIC, count_one_bits, count_one_bits_l)
1356         (count_one_bits_ll): Remove, replacing all uses with ...
1357         (_GL_STDBIT_HAS_BUILTIN_CLZ)
1358         (_GL_STDBIT_HAS_BUILTIN_CTZ, _GL_STDBIT_HAS_BUILTIN_POPCOUNT)
1359         (__gl_stdbit_clz, __gl_stdbit_clzl, __gl_stdbit_clzll)
1360         (__gl_stdbit_ctz, __gl_stdbit_ctzl, __gl_stdbit_ctzll)
1361         (__gl_stdbit_popcount, __gl_stdbit_popcountl, __gl_stdbit_popcountll)
1362         (__gl_stdbit_popcount255): ... these new functions and macros.
1363         (__popcnt64): Omit unnecessary casts.
1364         (__gl_stdbit_popcount_support): Rename from popcount_support
1365         and make it a signed char since that’s all we need.
1366         (__gl_stdbit_popcount_supported): Rename from popcount_supported.
1367         All uses changed.
1368         * modules/stdbit (Depends-on): Add assert-h, for static_assert.
1370         stdbit: remove most module dependence
1371         Remove dependence of stdbit on the modules count-leading-zeros,
1372         count-trailing-zeros, and count-one-bits.  stdbit is part of C23
1373         and in the long run is more likely to be more portable, so code
1374         should start preferring it.
1375         * lib/stdbit.c (popcount_support): New var, if needed.
1376         * lib/stdbit.in.h: Contain contents of count-leading-zeros.h,
1377         count-trailing-zeros.h, and count-one-bits.h instead of including
1378         those files.  In the long run those files should be stubs that are
1379         implemented via stdbit.
1380         * modules/stdbit (Depends-on): Do not depend on count-leading-zeros,
1381         count-trailing-zeros, count-one-bits.
1383         stdbit-tests: new module
1384         * config/srclist.txt: Add files containing stdbit test cases
1385         shared with glibc.
1386         * modules/stdbit-tests: New file.
1387         * tests/support/test-driver.c, tests/tst-stdbit.h:
1388         New files, copied from glibc with changes.
1389         * tests/tst-stdc_bit_ceil.c:
1390         * tests/tst-stdc_bit_floor.c, tests/tst-stdc_bit_width.c:
1391         * tests/tst-stdc_count_ones.c, tests/tst-stdc_count_zeros.c:
1392         * tests/tst-stdc_first_leading_one.c:
1393         * tests/tst-stdc_first_leading_zero.c:
1394         * tests/tst-stdc_first_trailing_one.c:
1395         * tests/tst-stdc_first_trailing_zero.c:
1396         * tests/tst-stdc_has_single_bit.c, tests/tst-stdc_leading_ones.c:
1397         * tests/tst-stdc_leading_zeros.c, tests/tst-stdc_trailing_ones.c:
1398         * tests/tst-stdc_trailing_zeros.c:
1399         New files, copied verbatim from glibc.
1401         stdbit: new module
1402         * doc/gnulib-tool.texi, doc/gnulib.texi: Mention it.
1403         * doc/posix-headers/stdbit.texi, lib/stdbit.c, lib/stdbit.in.h:
1404         * m4/stdbit_h.m4, modules/stdbit:
1405         New files.
1407 2024-05-11  Bruno Haible  <bruno@clisp.org>
1409         doc: Mention module execinfo.
1410         * doc/glibc-headers/execinfo.texi: Mention module execinfo.
1411         * doc/glibc-functions/backtrace.texi: Likewise.
1412         * doc/glibc-functions/backtrace_symbols.texi: Likewise.
1413         * doc/glibc-functions/backtrace_symbols_fd.texi: LIkewise.
1415 2024-05-11  Bruno Haible  <bruno@clisp.org>
1417         doc: Update regarding backtrace functions on *BSD.
1418         * doc/glibc-functions/backtrace.texi: Mention in which *BSD releases
1419         this function was missing.
1420         * doc/glibc-functions/backtrace_symbols.texi: Likewise.
1421         * doc/glibc-functions/backtrace_symbols_fd.texi: LIkewise.
1422         * doc/glibc-headers/execinfo.texi: Update *BSD versions.
1424 2024-05-11  Collin Funk  <collin.funk1@gmail.com>
1426         doc: Mention backtrace functions supported on BSD.
1427         * doc/glibc-functions/backtrace.texi (backtrace): Mention that FreeBSD
1428         supports this function from 10.0 onwards. Mention that NetBSD and
1429         OpenBSD support this function from 7.0 onwards.
1430         * doc/glibc-functions/backtrace_symbols.texi (backtrace_symbols):
1431         Likewise.
1432         * doc/glibc-functions/backtrace_symbols_fd.texi (backtrace_symbols_fd):
1433         Likewise.
1435 2024-05-09  Bruno Haible  <bruno@clisp.org>
1437         unistr/u8-strstr tests: Avoid test failure with ASAN.
1438         * tests/unistr/test-u8-strstr.c (main): Increase timeout to 50 sec.
1439         * tests/unistr/test-u16-strstr.c (main): Likewise.
1440         * tests/unistr/test-u32-strstr.c (main): Likewise.
1442 2024-05-09  Bruno Haible  <bruno@clisp.org>
1444         free tests: Avoid test failure with ASAN.
1445         * tests/test-free.c (main): Skip mmap/munmap based test if ASAN is
1446         enabled.
1448 2024-05-09  Bruno Haible  <bruno@clisp.org>
1450         explicit_bzero, memset_explicit tests: Avoid test failures with ASAN.
1451         * tests/test-explicit_bzero.c (test_heap, test_stack): Define to empty
1452         if ASAN is enabled.
1453         * tests/test-memset_explicit.c (test_heap, test_stack): Likewise.
1455 2024-05-09  Bruno Haible  <bruno@clisp.org>
1457         dprintf-posix, fprintf-posix tests: Avoid test failures with ASAN.
1458         * tests/test-dprintf-posix2.c (main): Skip the test if ASAN is enabled.
1459         * tests/test-fprintf-posix3.c (main): Likewise.
1460         * tests/test-dprintf-posix2.sh: Update.
1461         * tests/test-fprintf-posix3.sh: Likewise.
1463 2024-05-09  Bruno Haible  <bruno@clisp.org>
1465         unistdio/*printf: Fix %n handling with module 'printf-with-n-directive'.
1466         * m4/libunistring-base.m4 (gl_LIBUNISTRING_VERSION_CMP): Optimize the
1467         case of VERSION = 999.9.
1468         * modules/unistdio/u8-asnprintf (configure.ac): If module
1469         'printf-with-n-directive' is in use, don't use an installed libunistring
1470         for this module.
1471         * modules/unistdio/u8-asprintf (configure.ac): Likewise.
1472         * modules/unistdio/u8-snprintf (configure.ac): Likewise.
1473         * modules/unistdio/u8-sprintf (configure.ac): Likewise.
1474         * modules/unistdio/u8-vasnprintf (configure.ac): Likewise.
1475         * modules/unistdio/u8-vasprintf (configure.ac): Likewise.
1476         * modules/unistdio/u8-vsnprintf (configure.ac): Likewise.
1477         * modules/unistdio/u8-vsprintf (configure.ac): Likewise.
1478         * modules/unistdio/u8-u8-asnprintf (configure.ac): Likewise.
1479         * modules/unistdio/u8-u8-asprintf (configure.ac): Likewise.
1480         * modules/unistdio/u8-u8-snprintf (configure.ac): Likewise.
1481         * modules/unistdio/u8-u8-sprintf (configure.ac): Likewise.
1482         * modules/unistdio/u8-u8-vasnprintf (configure.ac): Likewise.
1483         * modules/unistdio/u8-u8-vasprintf (configure.ac): Likewise.
1484         * modules/unistdio/u8-u8-vsnprintf (configure.ac): Likewise.
1485         * modules/unistdio/u8-u8-vsprintf (configure.ac): Likewise.
1486         * modules/unistdio/u16-asnprintf (configure.ac): Likewise.
1487         * modules/unistdio/u16-asprintf (configure.ac): Likewise.
1488         * modules/unistdio/u16-snprintf (configure.ac): Likewise.
1489         * modules/unistdio/u16-sprintf (configure.ac): Likewise.
1490         * modules/unistdio/u16-vasnprintf (configure.ac): Likewise.
1491         * modules/unistdio/u16-vasprintf (configure.ac): Likewise.
1492         * modules/unistdio/u16-vsnprintf (configure.ac): Likewise.
1493         * modules/unistdio/u16-vsprintf (configure.ac): Likewise.
1494         * modules/unistdio/u16-u16-asnprintf (configure.ac): Likewise.
1495         * modules/unistdio/u16-u16-asprintf (configure.ac): Likewise.
1496         * modules/unistdio/u16-u16-snprintf (configure.ac): Likewise.
1497         * modules/unistdio/u16-u16-sprintf (configure.ac): Likewise.
1498         * modules/unistdio/u16-u16-vasnprintf (configure.ac): Likewise.
1499         * modules/unistdio/u16-u16-vasprintf (configure.ac): Likewise.
1500         * modules/unistdio/u16-u16-vsnprintf (configure.ac): Likewise.
1501         * modules/unistdio/u16-u16-vsprintf (configure.ac): Likewise.
1502         * modules/unistdio/u32-asnprintf (configure.ac): Likewise.
1503         * modules/unistdio/u32-asprintf (configure.ac): Likewise.
1504         * modules/unistdio/u32-snprintf (configure.ac): Likewise.
1505         * modules/unistdio/u32-sprintf (configure.ac): Likewise.
1506         * modules/unistdio/u32-vasnprintf (configure.ac): Likewise.
1507         * modules/unistdio/u32-vasprintf (configure.ac): Likewise.
1508         * modules/unistdio/u32-vsnprintf (configure.ac): Likewise.
1509         * modules/unistdio/u32-vsprintf (configure.ac): Likewise.
1510         * modules/unistdio/u32-u32-asnprintf (configure.ac): Likewise.
1511         * modules/unistdio/u32-u32-asprintf (configure.ac): Likewise.
1512         * modules/unistdio/u32-u32-snprintf (configure.ac): Likewise.
1513         * modules/unistdio/u32-u32-sprintf (configure.ac): Likewise.
1514         * modules/unistdio/u32-u32-vasnprintf (configure.ac): Likewise.
1515         * modules/unistdio/u32-u32-vasprintf (configure.ac): Likewise.
1516         * modules/unistdio/u32-u32-vsnprintf (configure.ac): Likewise.
1517         * modules/unistdio/u32-u32-vsprintf (configure.ac): Likewise.
1518         * modules/unistdio/ulc-asnprintf (configure.ac): Likewise.
1519         * modules/unistdio/ulc-asprintf (configure.ac): Likewise.
1520         * modules/unistdio/ulc-fprintf (configure.ac): Likewise.
1521         * modules/unistdio/ulc-snprintf (configure.ac): Likewise.
1522         * modules/unistdio/ulc-sprintf (configure.ac): Likewise.
1523         * modules/unistdio/ulc-vasnprintf (configure.ac): Likewise.
1524         * modules/unistdio/ulc-vasprintf (configure.ac): Likewise.
1525         * modules/unistdio/ulc-vfprintf (configure.ac): Likewise.
1526         * modules/unistdio/ulc-vsnprintf (configure.ac): Likewise.
1527         * modules/unistdio/ulc-vsprintf (configure.ac): Likewise.
1529 2024-05-08  Collin Funk  <collin.funk1@gmail.com>
1531         ftello: Prefer stdckdint to intprops.
1532         * lib/ftello.c (ftello): Include stdckdint.h instead of intprops.h.
1533         Prefer ckd_add to INT_ADD_OK.
1534         * modules/ftello (Depends-on): Depend on stdckdint instead of intprops.
1536 2024-05-08  Bruno Haible  <bruno@clisp.org>
1538         sigsegv, c-stack tests: Avoid test failures with ASAN.
1539         * tests/test-sigsegv-catch-stackoverflow1.c
1540         (HAVE_STACK_OVERFLOW_RECOVERY): Undefine if ASAN is enabled.
1541         * tests/test-sigsegv-catch-stackoverflow2.c
1542         (HAVE_STACK_OVERFLOW_RECOVERY): Likewise.
1543         * tests/test-c-stack.c (main): Skip the test if ASAN is enabled.
1545 2024-05-08  Bruno Haible  <bruno@clisp.org>
1547         argp: Fix test failure with clang's ASAN.
1548         Reported in
1549         <https://lists.gnu.org/archive/html/bug-gnulib/2023-12/msg00035.html>.
1550         * m4/argp.m4 (gl_ARGP): Rename argp_parse to rpl_argp_parse.
1552 2024-05-08  Bruno Haible  <bruno@clisp.org>
1554         gnulib-tool.py: Make --megatest behaviour more similar to shell impl.
1555         * pygnulib/main.py (main) [megatest]: Remove space from the testdir
1556         name.
1558 2024-05-08  Bruno Haible  <bruno@clisp.org>
1560         gnulib-tool: In --megatestdir mode, stop when there is an error.
1561         * gnulib-tool.sh (megatest): Fail when one of the 'configure' or 'make'
1562         steps fails.
1563         * pygnulib/main.py (main): Likewise.
1565 2024-05-08  Collin Funk  <collin.funk1@gmail.com>
1567         gnulib-tool.py: Fix behavior of --test when a subprocess fails.
1568         Reported by Bruno Haible in
1569         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00101.html>.
1570         * pygnulib/main.py (main): Use sp.run with check=True so that an
1571         exception is thrown when a process fails. Simply exit if an exception
1572         occurs.
1574 2024-05-07  Collin Funk  <collin.funk1@gmail.com>
1576         base32, base64: Prefer stdckdint to intprops.
1577         * lib/base32.c (base32_encode_alloc): Include stdckdint.h. Prefer
1578         ckd_mul to INT_MULTIPLY_OK.
1579         * lib/base64.c (base64_encode_alloc): Likewise.
1580         * modules/base32 (Depends-on): Add stdckdint.
1581         * modules/base64 (Depends-on): Likewise.
1583 2024-05-07  Collin Funk  <collin.funk1@gmail.com>
1585         gnulib-tool.py: Handle module dependencies that cannot be found.
1586         * pygnulib/GLModuleSystem.py
1587         (GLModule.getDependenciesWithoutConditions): Filter out None from the
1588         module dependencies. An appropriate warning will already be printed by
1589         GLModuleSystem.find().
1591 2024-05-07  Paul Eggert  <eggert@cs.ucla.edu>
1593         nstrftime: use clearer code for padding
1594         This also works around GCC bug 114965
1595         <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114965>.
1596         * lib/strftime.c (enum pad_style): New type.
1597         (width_add, my_strftime, __strftime_internal):
1598         Use it instead of checking the raw chars.
1599         * tests/test-nstrftime.h (T): Test for the GCC bug.
1601 2024-05-06  Simon Josefsson  <simon@josefsson.org>
1603         maintainer-makefile: Prohibit BSD4.3/SysV u_char etc types.
1604         * top/maint.mk (sc_unsigned_char, sc_unsigned_short)
1605         (sc_unsigned_int, sc_unsigned_long): Add.
1607 2024-05-06  Simon Josefsson  <simon@josefsson.org>
1609         inet-ntop, inet-pton: Avoid obsolete u_char type.
1610         * lib/inet_pton.c (inet_pton6): Use unsigned char instead of u_char.
1611         * lib/inet_ntop.c: Doc fix.
1613 2024-05-05  Bruno Haible  <bruno@clisp.org>
1615         gnulib-tool.py: Regenerate aclocal.m4 before using 'autoconf -t ...'.
1616         Reported by Paul Eggert in
1617         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00065.html>.
1618         * pygnulib/GLImport.py (GLImport): New field m4dirs.
1619         (GLImport.__init__): Accept an additional m4dirs argument.
1620         (GLImport.execute): Regenerate aclocal.m4 before creating the library
1621         Makefile.
1622         * pygnulib/main.py (main): Pass the guessed_m4dirs to GLImport.
1624 2024-05-04  Collin Funk  <collin.funk1@gmail.com>
1626         gnulib-tool: Ignore autom4te.cache when using GNULIB_TOOL_IMPL=sh+py.
1627         Reported by Paul Eggert in:
1628         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00061.html>.
1629         * gnulib-tool: Don't compare the autom4te.cache directory since requests
1630         are not sorted in Autoconf version 2.71 and below.
1632 2024-05-04  Bruno Haible  <bruno@clisp.org>
1634         readutmp, boot-time: Work around a Cygwin 3.5.3 bug.
1635         Reported by Ken Brown <kbrown@cornell.edu> in
1636         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00035.html>.
1637         * lib/boot-time-aux.h (get_windows_boot_time): On Cygwin, ignore
1638         pagefile.sys if it appears to be a directory, and use another file as
1639         a fallback.
1641 2024-05-03  Collin Funk  <collin.funk1@gmail.com>
1643         gnulib-tool.py: Fix an undefined function name (regression 2024-05-02).
1644         * pygnulib/main.py (main_with_exception_handling): Use the tempfile
1645         module prefix when calling mkdtemp(). Use the 'glpy' prefix for the
1646         temporary directory that exists for the entirety of the program.
1648 2024-05-03  Simon Josefsson  <simon@josefsson.org>
1650         maint.mk: Don't fail on ~/.indent.pro, reported by Collin Funk.
1651         * top/maint.mk (indent_args): Use --ignore-profile.
1653 2024-05-02  Collin Funk  <collin.funk1@gmail.com>
1655         gnulib-tool.sh: Fix program name in error message.
1656         * gnulib-tool.sh: Use 'gnulib-tool' instead of 'gnulib' as the program
1657         name in the error message.
1659 2024-05-02  Collin Funk  <collin.funk1@gmail.com>
1661         DEPENDENCIES: Add Cygwin as supported platform.
1662         * DEPENDENCIES: Mention Cygwin as a supported platform for building
1663         Windows binaries.
1665 2024-05-02  Bruno Haible  <bruno@clisp.org>
1667         doc: Add appendix about Gnulib history.
1668         * doc/gnulib-history.texi: New file.
1669         * doc/gnulib.texi: Include it.
1671 2024-05-02  Collin Funk  <collin.funk1@gmail.com>
1673         gnulib-tool.py: Don't leave temporary directories on exit.
1674         * pygnulib/main.py (main_with_exception_handling): Use
1675         tempfile.TemporaryDirectory as a context manager so it is removed before
1676         the program exits.
1677         (main): Expect a temporary directory to be passed as an argument.
1678         * pygnulib/GLConfig.py (GLConfig.__init__): Accept an optional temporary
1679         directory parameter instead of creating one.
1680         * pygnulib/GLImport.py (GLImport.__init__): Don't remove the cache's
1681         temporary directory since it doesn't create one anymore.
1682         (GLImport.execute): Don't remove the temporary directory explicitly. It
1683         is handled by the usage of a context manager.
1684         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
1685         Likewise.
1687 2024-05-01  Collin Funk  <collin.funk1@gmail.com>
1689         gnulib-tool.py: Quote file names passed to 'patch'.
1690         * pygnulib/GLTestDir.py (_patch_test_driver): Import shlex and cleanup
1691         unused imports. Use shlex.quote() on the file names passed to 'patch'.
1692         * pygnulib/GLFileSystem.py (GLFileSystem.lookup): Likewise. Perform
1693         redirection using sp.call() arguments instead of using the shell.
1695 2024-05-01  Bruno Haible  <bruno@clisp.org>
1697         readutmp, boot-time: Improve for some Cygwin installations.
1698         Reported by Ken Brown <kbrown@cornell.edu> in
1699         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00008.html>.
1700         * lib/boot-time-aux.h (get_windows_boot_time): Use /proc/cygdrive/
1701         instead of /cygdrive/.
1703 2024-05-01  Bruno Haible  <bruno@clisp.org>
1705         stddef: A better workaround against GCC bug 114870.
1706         * lib/stddef.in.h: If STDDEF_NOT_IDEMPOTENT is 1, disable the special
1707         invocation convention.
1708         * m4/stddef_h.m4 (gl_STDDEF_H): Set STDDEF_NOT_IDEMPOTENT.
1709         (gl_STDDEF_H_DEFAULTS): Initialize STDDEF_NOT_IDEMPOTENT.
1710         * modules/stddef (Makefile.am): Substitute STDDEF_NOT_IDEMPOTENT.
1712 2024-05-01  Bruno Haible  <bruno@clisp.org>
1714         stddef: Fix <stddef.h> behaviour on Cygwin (regression 2024-04-27).
1715         Reported by Markus Mützel <markus.muetzel@gmx.de> in
1716         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00522.html>.
1717         * lib/stddef.in.h: Don't test _@GUARD_PREFIX@_STDDEF_H. Fix comments.
1719 2024-05-01  Bruno Haible  <bruno@clisp.org>
1721         doc: Reference a gcc bug.
1722         * doc/posix-headers/stddef.texi: Reference a gcc bug.
1724 2024-05-01  Bruno Haible  <bruno@clisp.org>
1726         sprintf-posix, snprintf-posix tests: Add comment.
1727         Suggested by Collin Funk in
1728         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00546.html>.
1729         * tests/test-sprintf-posix.h (test_function): Add comment about known
1730         failures.
1732 2024-05-01  Collin Funk  <collin.funk1@gmail.com>
1734         gnulib-tool.py: Fix mistake in previous commit.
1735         * pygnulib/GLModuleSystem.py (GLModuleSystem.exists)
1736         (GLModuleSystem.find): Rename 'module' argument to 'module_name' so it
1737         is clear they are not a GLModule object. Treat them as such.
1739 2024-05-01  Collin Funk  <collin.funk1@gmail.com>
1741         gnulib-tool.py: Use the GLModule's name variable directly.
1742         * pygnulib/GLModuleSystem.py (GLModule.getName): Remove function.
1743         (GLModule.__str__, GLModule.__repr__, GLModule.isNonTests)
1744         (GLModule.repeatModuleInTests, GLModule.getDependenciesRecursively)
1745         (GLModule.getShellFunc, GLModule.getShellVar)
1746         (GLModule.getConditionalName, GLModule.getApplicability)
1747         (GLModule.getDependencies, GLModule.getAutomakeSnippet_Unconditional)
1748         (GLModule.getLicense, GLModuleSystem.find)
1749         (GLModuleTable.transitive_closure): Use the GLModule's name instance
1750         variable instead of using str() or removed getName() function.
1751         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet)
1752         (GLEmiter.preEarlyMacros, GLEmiter.lib_Makefile_am)
1753         (GLEmiter.tests_Makefile_am): Likewise.
1754         * pygnulib/GLImport.py (GLImport.gnulib_comp, GLImport.prepare):
1755         Likewise.
1756         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
1757         Likewise.
1759 2024-04-30  Paul Eggert  <eggert@cs.ucla.edu>
1761         intprops: document fix for GCC bug 68193
1762         * lib/intprops-internal.h (_GL__GENERIC_BOGUS):
1763         GCC bug 68193 is fixed in GCC 14.  This is just for documentation,
1764         as _GL__GENERIC_BOGUS is not consulted in GCC 14.
1766 2024-04-30  Bruno Haible  <bruno@clisp.org>
1768         *printf: Don't invoke gl_PRINTF_DIRECTIVE_N when it's not needed.
1769         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): Don't require
1770         gl_PRINTF_DIRECTIVE_N if gl_PRINTF_SUPPORT_N_DIRECTIVE is not defined.
1771         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
1772         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): Likewise.
1773         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
1774         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Likewise.
1775         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
1776         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
1777         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
1778         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
1779         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
1780         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX): Likewise.
1782 2024-04-30  Bruno Haible  <bruno@clisp.org>
1784         *printf: Avoid a dialog during 'configure' with MSVC in debug mode.
1785         Suggested by Paul Harris <harris.pc@gmail.com> in
1786         <https://lists.gnu.org/archive/html/bug-gettext/2024-04/msg00005.html>.
1787         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): In the test program, include
1788         <crtdbg.h> and disable the MSVC reporting for assertion failures.
1790 2024-04-30  Collin Funk  <collin.funk1@gmail.com>
1792         gnulib-tool.py: Remove remaining unused instance variables.
1793         * pygnulib/GLModuleSystem.py (GLModule.__init__)
1794         (GLModuleTable.__init__): Remove the unused GLFileSystem variable. These
1795         classes perform lookups with a GLModuleSystem.
1796         * pygnulib/GLTestDir.py (GLTestDir.__init__): Remove the unused
1797         GLFileAssistant variable. The transformations it performs are not needed
1798         in testdirs.
1800 2024-04-29  Collin Funk  <collin.funk1@gmail.com>
1802         gnulib-tool.py: Add type hints to classes.
1803         * pygnulib/*.py: Add type hints for all instance and class variables.
1804         * pygnulib/GLMakefileTable.py (GLMakefileTable.__getitem__): Fix return
1805         type hint since the dictionary has str values.
1807 2024-04-29  Collin Funk  <collin.funk1@gmail.com>
1809         gnulib-tool.py: Emit libtests in testdirs generated Makefile.am.
1810         Reported by Bruno Haible in
1811         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00463.html>.
1812         * pygnulib/GLTestDir.py (GLTestDir.execute): Modify the GLEmiter's
1813         config variable instead of the GLTestDir's so that it can be accessed
1814         when emitting the Makefile.am.
1816 2024-04-28  Collin Funk  <collin.funk1@gmail.com>
1818         doc: Update macro list in gnulib-cache.m4 documentation.
1819         * doc/gnulib-tool.texi (Modified imports): Add missing macros from the
1820         sed invocation in func_import of gnulib-tool.sh.
1822 2024-04-28  Collin Funk  <collin.funk1@gmail.com>
1824         doc: Mention AC_CONFIG_MACRO_DIRS in configure.ac.
1825         Document the following gnulib-tool change:
1826         2021-12-19  Bruno Haible  <bruno@clisp.org>
1827         gnulib-tool: Don't insist on ACLOCAL_AMFLAGS.
1828         * doc/gnulib-tool.texi (Initial import): Update the example gnulib-tool
1829         invocation. Document the use of AC_CONFIG_MACRO_DIRS as an alternative
1830         to ACLOCAL_AMFLAGS.
1832 2024-04-28  Bruno Haible  <bruno@clisp.org>
1834         bootstrap: Support checking out a recent GNULIB_REVISION, part 2.
1835         Reported by Markus Mützel <markus.muetzel@gmx.de> in
1836         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00507.html>.
1837         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): If using a submodule
1838         and the 'git checkout' command fails, fetch the newer commits and then
1839         retry it.
1840         * build-aux/bootstrap: Regenerated.
1842 2024-04-27  Collin Funk  <collin.funk1@gmail.com>
1844         gnulib-tool.py: Preserve module ordering in --create-megatestdir.
1845         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Use a separate set to
1846         remove duplicates from the original list without sorting.
1848 2024-04-27  Bruno Haible  <bruno@clisp.org>
1850         gnulib-tool: Simplify the Python version test.
1851         Suggested by Pádraig Brady in
1852         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00469.html>.
1853         * gnulib-tool: Use Python's sys.version_info, not --version.
1854         * gnulib-tool.py: Use the same version test here. Use --version only to
1855         produce a specific error message.
1857 2024-04-27  Bruno Haible  <bruno@clisp.org>
1859         fcntl-h, stdio, unistd: Ensure off64_t is defined on all platforms.
1860         * lib/fcntl.in.h: Update comment regarding off64_t.
1861         * lib/stdio.in.h: Likewise.
1862         * lib/unistd.in.h: Likewise.
1863         * tests/test-fcntl-h.c: Verify that off64_t is defined.
1864         * tests/test-stdio.c: Likewise.
1865         * tests/test-unistd.c: Likewise.
1866         * doc/posix-headers/fcntl.texi: Mention the off64_t workaround.
1867         * doc/posix-headers/stdio.texi: Likewise.
1868         * doc/posix-headers/unistd.texi: Likewise.
1869         * doc/posix-headers/aio.texi: Mention the problem with off64_t.
1871         sys_types: Ensure off64_t is defined on all platforms.
1872         * m4/off64_t.m4: New file.
1873         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Require gl_TYPE_OFF64_T.
1874         * lib/sys_types.in.h (off64_t): New type.
1875         (GNULIB_defined_off64_t): New macro.
1876         * modules/sys_types (Files): Add m4/off64_t.m4.
1877         (configure.ac-early): Require AC_USE_SYSTEM_EXTENSIONS.
1878         (Makefile.am): Substitute HAVE_OFF64_T.
1879         * tests/test-sys_types.c: Verify that off64_t is defined.
1880         * doc/posix-headers/sys_types.texi: Mention the off64_t workaround.
1882 2024-04-27  Paul Eggert  <eggert@cs.ucla.edu>
1884         nullptr: work around GCC nullptr sentinel bug
1885         * m4/nullptr.m4 (gl_NULLPTR): Work around GCC bug 114780.
1887         stddef: work around GCC stddef.h bugs
1888         * lib/stddef.in.h: Do nothing if _@GUARD_PREFIX@_STDDEF_H is
1889         defined, as stddef.h has already been included.  This works
1890         around GCC bug 114870.
1891         (_GCC_NULLPTR_T): Define if needed to work around GCC bug 114869.
1892         * m4/stddef_h.m4 (gl_STDDEF_H, gl_STDDEF_H_DEFAULTS):
1893         * modules/stddef (stddef.h):
1894         Detect the two bugs.
1895         * doc/posix-headers/stddef.texi: Mention one of the two bugs.
1897 2024-04-27  Bruno Haible  <bruno@clisp.org>
1899         bootstrap: Support checking out a recent GNULIB_REVISION.
1900         Reported by Markus Mützel <markus.muetzel@gmx.de> in
1901         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00462.html>.
1902         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): If the
1903         'git checkout' command fails, fetch the newer commits and then retry it.
1904         * build-aux/bootstrap: Regenerated.
1906 2024-04-27  Bruno Haible  <bruno@clisp.org>
1908         ctime, localtime, tzset, wcsftime: Fix env access (regr. 2024-02-09).
1909         Reported by Markus Mützel <markus.muetzel@gmx.de> in
1910         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00457.html>.
1911         * lib/ctime.c (rpl_ctime): Fix logic of environment traversal.
1912         * lib/localtime.c (rpl_localtime): Likewise.
1913         * lib/tzset.c (rpl_tzset): Likewise.
1914         * lib/wcsftime.c (rpl_wcsftime): Likewise.
1916 2024-04-26  Bruno Haible  <bruno@clisp.org>
1918         login_tty tests: Avoid gcc warnings.
1919         * tests/test-login_tty.c: Include ignore-value.h.
1920         (main): Ignore the results of the freopen calls.
1921         * modules/login_tty-tests (Depends-on): Add ignore-value.
1923 2024-04-26  Bruno Haible  <bruno@clisp.org>
1925         Document prerequisite for gnulib-tool.
1926         Suggested by Collin Funk in
1927         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00450.html>.
1928         * DEPENDENCIES: Add Python 3.7 as "recommended".
1930 2024-04-26  Bruno Haible  <bruno@clisp.org>
1932         gnulib-tool: Use the Python implementation by default.
1933         * gnulib-tool: If GNULIB_TOOL_IMPL is not set: Use the Python
1934         implementation if a suitable 'python3' program is found in $PATH;
1935         otherwise print a warning and use the shell implementation.
1937 2024-04-26  Collin Funk  <collin.funk1@gmail.com>
1939         gnulib-tool.py: Remove some unused instance variables.
1940         * pygnulib/GLTestDir.py (GLMegaTestDir.__init__): Don't define instance
1941         variables that are never used.
1943 2024-04-25  Collin Funk  <collin.funk1@gmail.com>
1945         gnulib-tool.py: Reduce code duplication in file name transformations.
1946         * pygnulib/functions.py: New file for shared functions between modules.
1947         Add a function based on functions removed from GLImport and GLTestDir.
1948         Accepts a single file name instead of a list.
1949         * pygnulib/GLImport.py (GLImport.prepare): Use the new function.
1950         (GLImport.rewrite_new_files, GLImport.rewrite_old_files): Remove
1951         functions.
1952         * pygnulib/GLTestDir.py (GLTestDir.execute): Use the new function.
1953         (GLTestDir.rewrite_files): Remove functions.
1954         * pygnulib/main.py (main): Remove unused function import. Use the new
1955         function.
1957 2024-04-25  Bruno Haible  <bruno@clisp.org>
1959         doc: Remove documentation of IRIX as supported platform.
1960         * doc/posix-headers/netdb.texi: Don't mention IRIX specific workarounds.
1961         * doc/posix-headers/pthread.texi: Likewise.
1962         * doc/posix-headers/sys_socket.texi: Likewise.
1963         * doc/posix-headers/wctype.texi: Likewise.
1964         * doc/posix-functions/btowc.texi: Likewise.
1965         * doc/posix-functions/cbrtf.texi: Likewise.
1966         * doc/posix-functions/cbrtl.texi: Likewise.
1967         * doc/posix-functions/copysignf.texi: Likewise.
1968         * doc/posix-functions/exp2.texi: Likewise.
1969         * doc/posix-functions/exp2f.texi: Likewise.
1970         * doc/posix-functions/exp2l.texi: Likewise.
1971         * doc/posix-functions/expm1f.texi: Likewise.
1972         * doc/posix-functions/expm1l.texi: Likewise.
1973         * doc/posix-functions/fabsl.texi: Likewise.
1974         * doc/posix-functions/isnan.texi: Likewise.
1975         * doc/posix-functions/iswblank.texi: Likewise.
1976         * doc/posix-functions/link.texi: Likewise.
1977         * doc/posix-functions/log10l.texi: Likewise.
1978         * doc/posix-functions/log1pf.texi: Likewise.
1979         * doc/posix-functions/log2.texi: Likewise.
1980         * doc/posix-functions/log2f.texi: Likewise.
1981         * doc/posix-functions/log2l.texi: Likewise.
1982         * doc/posix-functions/lseek.texi: Likewise.
1983         * doc/posix-functions/nl_langinfo.texi: Likewise.
1984         * doc/posix-functions/pthread_sigmask.texi: Likewise.
1985         * doc/posix-functions/remainderf.texi: Likewise.
1986         * doc/posix-functions/remainderl.texi: Likewise.
1987         * doc/posix-functions/rintf.texi: Likewise.
1988         * doc/posix-functions/sigaltstack.texi: Likewise.
1989         * doc/posix-functions/strtod.texi: Likewise.
1990         * doc/posix-functions/strtold.texi: Likewise.
1991         * doc/posix-functions/vscanf.texi: Likewise.
1992         * doc/posix-functions/wctob.texi: Likewise.
1993         * doc/**/*.texi: Update.
1995 2024-04-25  Collin Funk  <collin.funk1@gmail.com>
1997         HACKING: Fix a typo.
1998         * HACKING: Add missing 't' to platforms.
2000 2024-04-25  Bruno Haible  <bruno@clisp.org>
2002         relocatable-lib-lgpl: Allow unconditional use of set_relocation_prefix.
2003         Reported by Reuben Thomas <rrt@sc3d.org> in
2004         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00384.html>.
2005         * lib/relocatable.h (set_relocation_prefix): Define in a dummy way if
2006         ENABLE_RELOCATABLE is not defined.
2008 2024-04-25  Bruno Haible  <bruno@clisp.org>
2010         doc: Update target platforms list.
2011         * doc/gnulib-intro.texi (Supported Platforms): Mention FreeBSD 14
2012         instead of 13. Mention AIX 7.3 instead of 7.2. Mention Cygwin 3.4.
2013         Don't mention IRIX.
2014         (Formerly Supported Platforms): Add IRIX.
2016 2024-04-25  Bruno Haible  <bruno@clisp.org>
2018         largefile: Update documentation.
2019         * doc/largefile.texi: Remove mention of IRIX.
2021 2024-04-24  Collin Funk  <collin.funk1@gmail.com>
2023         gnulib-tool.py: Add a new GLFileTable class.
2024         * pygnulib/GLFileTable.py: New file. Define the GLFileTable class with
2025         five attributes which can be individually typed.
2026         * pygnulib/GLTestDir.py (GLTestDir.execute): Use the GLFileTable class.
2027         * pygnulib/GLImport.py (GLImport.gnulib_comp, GLImport.prepare)
2028         (GLImport.execute): Likewise. Update type hints and doc strings.
2030 2024-04-24  Paul Eggert  <eggert@cs.ucla.edu>
2032         largefile: port to C++
2033         This patch is mostly taken from Autoconf master.
2034         * m4/largefile.m4 (AC_SYS_YEAR2038_RECOMMENDED):
2035         Undefine if unpatched Autoconf 2.72 or earlier, so that
2036         later code will redefine it.
2037         The remaining part of this patch is from Autoconf master.
2038         (_AC_SYS_YEAR2038_PROBE, _AC_SYS_LARGEFILE_PROBE):
2039         Put "$CCFLAGS" in diagnostics, not "$CC".
2040         (_AC_SYS_LARGEFILE_OPTIONS): Omit -n32.
2041         (AC_SYS_LARGEFILE_PROBE): Fiddle with CPPFLAGS, not CC.
2042         Do not worry about -n32.
2044         c32srtombs,mbsrtoc32s,mbsrtowcs,wcsrtombs: pacify GCC 14
2045         * lib/c32srtombs-state.c (_gl_c32srtombs_state):
2046         * lib/mbsrtoc32s-state.c (_gl_mbsrtoc32s_state):
2047         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state):
2048         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state):
2049         Add an extern decl for a “private” extern symbol, to pacify GCC
2050         14’s -Wmissing-variable-declarations option.
2052 2024-04-24  Bruno Haible  <bruno@clisp.org>
2054         physmem: Port better to Linux.
2055         * lib/physmem.h (physmem_total, physmem_available): Add documentation.
2056         (physmem_claimable): New declaration.
2057         * lib/physmem.c: Include <fcntl.h>, <stdio.h>, full-read.h.
2058         (get_meminfo): New function.
2059         (physmem_claimable): Renamed from physmem_available. Add logic for
2060         aggressivity > 0.
2061         (physmem_available): New function.
2062         * modules/physmem (Depends-on): Add full-read.
2064 2024-04-24  Bruno Haible  <bruno@clisp.org>
2066         Fix warnings triggered by including <config.h> twice (regr. 2024-04-19).
2067         Reported by Collin Funk in
2068         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00398.html>.
2069         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use AH_VERBATIM instead
2070         of AC_DEFINE.
2072 2024-04-23  Paul Eggert  <eggert@cs.ucla.edu>
2074         manywarnings: update C warnings for GCC 14
2075         Adjust for C programs compiled by GCC 14.
2076         (A C++ expert still needs to look at manywarnings-c++.m4.)
2077         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 14.
2078         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
2079         Add -Wflex-array-member-not-at-end, -Wmissing-variable-declarations.
2081 2024-04-23  Bruno Haible  <bruno@clisp.org>
2083         Update HACKING.
2084         Suggested by Paul Eggert in
2085         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00388.html>.
2086         * HACKING: Mention an alternative to gitk.
2088 2024-04-23  Collin Funk  <collin.funk1@gmail.com>
2090         gnulib-tool.py: Make better use of imports.
2091         * pygnulib/*.py: Import functions from constants.py directly instead of
2092         assigning them to module-specific variable. Keep the module prefix for
2093         standard library functions.
2095 2024-04-23  Bruno Haible  <bruno@clisp.org>
2097         Update HACKING.
2098         * HACKING: Mention the linear git history, how to work with ChangeLog,
2099         how to run a testdir, where to find the gnulib-tool tests, and where are
2100         the continuous integrations.
2102 2024-04-22  Bruno Haible  <bruno@clisp.org>
2104         gnulib-tool: Fix trouble caused by Python's bytecode cache.
2105         Reported by Paul Eggert in
2106         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00367.html>.
2107         * gnulib-tool: In sh+py mode, ignore the __pycache__ directory during
2108         comparison.
2110 2024-04-22  Bruno Haible  <bruno@clisp.org>
2112         gnulib-tool.py: Fix trouble caused by Python's bytecode cache.
2113         Reported by Paul Eggert in
2114         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00367.html>.
2115         * gnulib-tool.py: Set PYTHONPYCACHEPREFIX, so as to avoid creating a
2116         __pycache__ directory in the developer's gnulib checkout (only effective
2117         with Python ≥ 3.8).
2119 2024-04-21  Collin Funk  <collin.funk1@gmail.com>
2121         gnulib-tool.py: Make temporary directories recognizable.
2122         * pygnulib/GLConfig.py (GLConfig.__init__): Pass the 'glpy' prefix to
2123         mkdtemp.
2125 2024-04-21  Bruno Haible  <bruno@clisp.org>
2127         gnulib-tool.sh: In --create-testdir, just warn about a bad module name.
2128         * gnulib-tool.sh (func_create_testdir): Validate the modules list.
2130 2024-04-21  Collin Funk  <collin.funk1@gmail.com>
2132         gnulib-tool.py: Don't fail when given a bad module name.
2133         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't include None in the
2134         list of GLModule objects.
2135         * pygnulib/GLModuleSystem.py (GLModuleSystem.find): Document the meaning
2136         of the None return.
2138 2024-04-21  Collin Funk  <collin.funk1@gmail.com>
2140         gnulib-tool.py: Update type hints and docstring.
2141         * pygnulib/GLImport.py (GLImport.execute): Update transformer type hint
2142         to reflect change from sed expressions to re.sub() arguments.
2143         (GLImport.prepare): Likewise. Don't reference sed or license
2144         replacements in docstring.
2146 2024-04-20  Bruno Haible  <bruno@clisp.org>
2148         signed-snan: Relicense under LGPLv2+.
2149         * modules/signed-snan (License): Change to LGPLv2+.
2150         * lib/signed-snan.h: Update license notice.
2152         snan: Relicense under LGPLv2+.
2153         * modules/snan (License): Change to LGPLv2+.
2154         * lib/snan.h: Update license notice.
2156         signed-nan: Relicense under LGPLv2+.
2157         * modules/signed-nan (License): Change to LGPLv2+.
2158         * lib/signed-nan.h: Update license notice.
2160         nan: Relicense under LGPLv2+.
2161         Eric Blake's approval is in
2162         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00290.html>.
2163         Paul Eggert's approval is in
2164         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00324.html>.
2165         Daniel Richard G.'s approval was given in private email.
2166         * modules/nan (License): Change to LGPLv2+.
2167         * lib/nan.h: Update license notice.
2169 2024-04-20  Bruno Haible  <bruno@clisp.org>
2171         gnulib-tool: In sh+py mode, don't fail because of dangling symlinks.
2172         Reported by Paul Eggert in
2173         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00318.html>
2174         and Pádraig Brady in
2175         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00321.html>.
2176         * gnulib-tool: In sh+py mode, use diff option '--no-dereference' if
2177         available.
2179 2024-04-20  Collin Funk  <collin.funk1@gmail.com>
2181         gnulib-tool.py: Remove duplicate per-module definitions.
2182         * pygnulib/constants.py: Remove duplicate __authors__, __license__, and
2183         __copyright__ definitions.
2184         * pygnulib/GLInfo.py: Use the value of __authors__ and __copyright__
2185         from __init__.py for output.
2186         * pygnulib/*.py: Remove unused references to the constant.py
2187         definitions.
2189 2024-04-20  Bruno Haible  <bruno@clisp.org>
2191         gnulib-tool.py: Fix a bug in removed / added files handling.
2192         * pygnulib/GLImport.py (GLImport.execute): When looking for files that
2193         are in both filetable['old'] and filetable['new'], consider only the
2194         first element of each tuple, not the entire tuple.
2196 2024-04-20  Bruno Haible  <bruno@clisp.org>
2198         gnulib-tool.py: Sort file lists case-sensitively.
2199         * pygnulib/GLImport.py (GLImport.prepare, GLImport.execute): Omit
2200         .lower() call in sort key computation.
2202 2024-04-20  Bruno Haible  <bruno@clisp.org>
2204         gnulib-tool.py: Fix output of --create-megatestdir.
2205         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Remove stray backslash
2206         from output.
2208 2024-04-19  Bruno Haible  <bruno@clisp.org>
2210         wcsstr: Update doc.
2211         * doc/posix-functions/wcsstr.texi: Update glibc version.
2213 2024-04-19  Bruno Haible  <bruno@clisp.org>
2215         getlogin_r tests: Fix compilation error on some OpenSolaris derivatives.
2216         * tests/test-getlogin_r.c (getlogin_r): Don't check the signature on
2217         Solaris.
2219 2024-04-19  Bruno Haible  <bruno@clisp.org>
2221         memset_explicit: Fix compilation error on some OpenSolaris derivatives.
2222         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Arrange to define
2223         __STDC_WANT_LIB_EXT1__ to 1.
2224         * modules/memset_explicit (Depends-on): Add extensions.
2225         * m4/memset_explicit.m4 (gl_FUNC_MEMSET_EXPLICIT): Require
2226         gl_USE_SYSTEM_EXTENSIONS.
2227         * lib/memset_explicit.c (__STDC_WANT_LIB_EXT1__): Remove definition.
2229 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
2231         gnulib-tool.py: Make use of GLModule's __hash__ method.
2232         * pygnulib/GLModuleSystem.py (GLModuleTable.addUnconditional)
2233         (GLModuleTable.isConditional): Use the GLModule object instead of the
2234         module name directly.
2235         (GLModuleTable.addConditional, GLModuleTable.getCondition): Likewise.
2236         Use a tuple of two GLModule objects as a key for the conditionals
2237         dictionary.
2239 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
2241         gnulib-tool.py: Simplify data structures for dependencies.
2242         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Use a defaultdict
2243         for dependers to remove the base initialization case.
2244         (GLModuleTable.addConditional): Use a set to disallow duplicates instead
2245         of performing list lookups.
2247 2024-04-19  Bruno Haible  <bruno@clisp.org>
2249         gnulib-tool.py: Simplify running some commands in a given directory.
2250         * pygnulib/GLImport.py (GLImport.execute): Use sp.call with a cwd
2251         argument, instead of calling chdir twice.
2252         * pygnulib/GLModuleSystem.py (GLModuleSystem.list): Likewise.
2253         * pygnulib/main.py (mode=='find'): Likewise.
2255 2024-04-19  Bruno Haible  <bruno@clisp.org>
2257         gnulib-tool.py: Update authors list.
2258         * pygnulib/constants.py (__author__): Add Collin Funk.
2259         * pygnulib/__init__.py (__copyright__, __author__): Include years and
2260         authors of the gnulib-tool shell script.
2262 2024-04-19  Bruno Haible  <bruno@clisp.org>
2264         getpayload* tests: Don't assume that '-' works as expected on NaN.
2265         * tests/test-getpayload.c: Include signed-nan.h.
2266         (main): Use minus_NaNd.
2267         * tests/test-getpayloadf.c: Include signed-nan.h.
2268         (main): Use minus_NaNf.
2269         * tests/test-getpayloadl.c: Include signed-nan.h.
2270         (main): Use minus_NaNl.
2271         * modules/getpayload-tests (Depends-on): Add signed-nan.
2272         * modules/getpayloadf-tests (Depends-on): Likewise.
2273         * modules/getpayloadl-tests (Depends-on): Likewise.
2275         signed-nan: Don't assume that '-' works as expected on NaN values.
2276         * lib/signed-nan.h (minus_NaNf): New function.
2277         (positive_NaNf, negative_NaNf): Use it.
2278         (minus_NaNd): New function.
2279         (positive_NaNd, negative_NaNd): Use it.
2280         (minus_NaNl): New function.
2281         (positive_NaNl, negative_NaNl): Use it.
2282         * tests/test-totalorder.c (TOTALORDER_MINUS): New macro.
2283         * tests/test-totalorderf.c (TOTALORDER_MINUS): New macro.
2284         * tests/test-totalorderl.c (TOTALORDER_MINUS): New macro.
2285         * tests/test-totalorder.h (negative_NaN_with_payload): Use it.
2286         * tests/test-totalordermag.c (TOTALORDER_MINUS): New macro.
2287         * tests/test-totalordermagf.c (TOTALORDER_MINUS): New macro.
2288         * tests/test-totalordermagl.c (TOTALORDER_MINUS): New macro.
2289         * tests/test-totalordermag.h (negative_NaN_with_payload): Use it.
2291 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
2293         gnulib-tool.py: Add a comment about coding style.
2294         * pygnulib/main.py: Add a note about the common convention of using an
2295         underscore prefix to mark a function/variable as private.
2297 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
2299         gnulib-tool.py: Remove some unused instance variables.
2300         * pygnulib/GLModuleSystem.py (GLModuleSystem.__init__)
2301         (GLModule.__init__): Remove unused 'args' instance variable.
2303 2024-04-19  Paul Eggert  <eggert@cs.ucla.edu>
2305         fstatat, stat: document macOS st_ino pipe bug
2306         * doc/posix-functions/fstatat.texi (fstatat):
2307         * doc/posix-functions/stat.texi (stat):
2308         Document macOS bug (see <https://bugs.gnu.org/70411>).
2310 2024-04-18  Bruno Haible  <bruno@clisp.org>
2312         totalordermagl: Add tests.
2313         * tests/test-totalordermagl.c: New file, based on
2314         tests/test-totalorderl.c.
2315         * modules/totalordermagl-tests: New file, based on
2316         modules/totalorderl-tests.
2318         totalordermagl: New module.
2319         * lib/math.in.h (totalordermagl): New declaration.
2320         * lib/totalordermagl.c: New file, based on lib/totalorderl.c.
2321         * m4/math_h.m4 (gl_MATH_H): Test whether totalordermagl is declared.
2322         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_TOTALORDERMAGL.
2323         (gl_MATH_H_DEFAULTS): Initialize HAVE_TOTALORDERMAGL,
2324         REPLACE_TOTALORDERMAGL.
2325         * modules/math (Makefile.am): Substitute GNULIB_TOTALORDERMAGL,
2326         HAVE_TOTALORDERMAGL, REPLACE_TOTALORDERMAGL.
2327         * modules/totalordermagl: New file, based on modules/totalorderl.
2328         * doc/posix-functions/totalordermagl.texi: Mention the new module.
2330 2024-04-18  Bruno Haible  <bruno@clisp.org>
2332         totalordermagf: Add tests.
2333         * tests/test-totalordermagf.c: New file, based on
2334         tests/test-totalorderf.c.
2335         * modules/totalordermagf-tests: New file, based on
2336         modules/totalorderf-tests.
2338         totalordermagf: New module.
2339         * lib/math.in.h (totalordermagf): New declaration.
2340         * lib/totalordermagf.c: New file, based on lib/totalorderf.c.
2341         * m4/math_h.m4 (gl_MATH_H): Test whether totalordermagf is declared.
2342         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_TOTALORDERMAGF.
2343         (gl_MATH_H_DEFAULTS): Initialize HAVE_TOTALORDERMAGF,
2344         REPLACE_TOTALORDERMAGF.
2345         * modules/math (Makefile.am): Substitute GNULIB_TOTALORDERMAGF,
2346         HAVE_TOTALORDERMAGF, REPLACE_TOTALORDERMAGF.
2347         * modules/totalordermagf: New file, based on modules/totalorderf.
2348         * doc/posix-functions/totalordermagf.texi: Mention the new module.
2350 2024-04-18  Bruno Haible  <bruno@clisp.org>
2352         totalordermag: Add tests.
2353         * tests/test-totalordermag.c: New file, based on
2354         tests/test-totalorder.c.
2355         * tests/test-totalordermag.h: New file, based on
2356         tests/test-totalorder.h.
2357         * modules/totalordermag-tests: New file, based on
2358         modules/totalorder-tests.
2360         totalordermag: New module.
2361         * lib/math.in.h (totalordermag): New declaration.
2362         * lib/totalordermag.c: New file, based on lib/totalorder.c.
2363         * m4/totalordermag.m4: New file, based on m4/totalorder.m4.
2364         * m4/math_h.m4 (gl_MATH_H): Test whether totalordermag is declared.
2365         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_TOTALORDERMAG.
2366         (gl_MATH_H_DEFAULTS): Initialize HAVE_TOTALORDERMAG,
2367         REPLACE_TOTALORDERMAG.
2368         * modules/math (Makefile.am): Substitute GNULIB_TOTALORDERMAG,
2369         HAVE_TOTALORDERMAG, REPLACE_TOTALORDERMAG.
2370         * modules/totalordermag: New file, based on modules/totalorder.
2371         * doc/posix-functions/totalordermag.texi: Mention the new module.
2373 2024-04-18  Bruno Haible  <bruno@clisp.org>
2375         setpayloadsig*: Support newer MIPS CPUs.
2376         * lib/setpayloadsig.c (setpayloadsig): On MIPS CPUs with MIPS_NAN2008_DOUBLE,
2377         reject a zero payload.
2378         * lib/setpayloadsigf.c (setpayloadsigf): On MIPS CPUs with MIPS_NAN2008_FLOAT,
2379         reject a zero payload.
2380         * lib/setpayloadsigl.c (setpayloadsigl): On MIPS CPUs with
2381         MIPS_NAN2008_LONG_DOUBLE, reject a zero payload.
2383 2024-04-18  Bruno Haible  <bruno@clisp.org>
2385         setpayload*: Support newer MIPS CPUs.
2386         * lib/setpayload.c (setpayload): On MIPS CPUs with MIPS_NAN2008_DOUBLE,
2387         accept a zero payload.
2388         * lib/setpayloadf.c (setpayloadf): On MIPS CPUs with MIPS_NAN2008_FLOAT,
2389         accept a zero payload.
2390         * lib/setpayloadl.c (setpayloadl): On MIPS CPUs with
2391         MIPS_NAN2008_LONG_DOUBLE, accept a zero payload.
2392         * m4/setpayload.m4 (gl_FUNC_SETPAYLOADF, gl_FUNC_SETPAYLOAD,
2393         gl_FUNC_SETPAYLOADL): Invoke gl_NAN_MIPS.
2394         * modules/setpayload (Files): Add m4/nan-mips.m4.
2395         * modules/setpayloadf (Files): Likewise.
2396         * modules/setpayloadl (Files): Likewise.
2398 2024-04-18  Bruno Haible  <bruno@clisp.org>
2400         totalorder*: Support newer MIPS CPUs.
2401         * lib/totalorder.c (totalorder): On MIPS CPUs with MIPS_NAN2008_DOUBLE,
2402         don't invert the most significant bit of the mantissa field.
2403         * lib/totalorderf.c (totalorderf): On MIPS CPUs with MIPS_NAN2008_FLOAT,
2404         don't invert the most significant bit of the mantissa field.
2405         * lib/totalorderl.c (totalorderl): On MIPS CPUs with
2406         MIPS_NAN2008_LONG_DOUBLE, don't invert the most significant bit of the
2407         mantissa field.
2408         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF, gl_FUNC_TOTALORDER,
2409         gl_FUNC_TOTALORDERL): Invoke gl_NAN_MIPS.
2410         * modules/totalorder (Files): Add m4/nan-mips.m4.
2411         * modules/totalorderf (Files): Likewise.
2412         * modules/totalorderl (Files): Likewise.
2414 2024-04-18  Bruno Haible  <bruno@clisp.org>
2416         snan: Add support for m68k.
2417         * lib/snan.h (construct_memory_SNaNl): Handle m68k specially.
2419 2024-04-18  Bruno Haible  <bruno@clisp.org>
2421         totalorderl: Simplify on MSVC.
2422         * lib/totalorderl.c (totalorderl): If 'long double' is the same as
2423         'double', just invoke totalorder. Otherwise, drop the optimized code
2424         for small 'long double' since it does not occur on any platform.
2425         * m4/totalorder.m4 (gl_FUNC_TOTALORDERL): Require
2426         gl_LONG_DOUBLE_VS_DOUBLE. If 'long double' is the same as 'double', use
2427         TOTALORDER_LIBM.
2428         * modules/totalorderl (Depends-on): Add totalorder.
2430 2024-04-18  Bruno Haible  <bruno@clisp.org>
2432         signbit: Fix typos.
2433         * lib/signbitd.c: Fix typo in comment.
2434         * lib/signbitf.c: Likewise.
2436 2024-04-18  Collin Funk  <collin.funk1@gmail.com>
2438         gnulib-tool.py: Ignore 'attribute-defined-outside-init' warnings.
2439         * pygnulib/.pylintrc: Add W0201 to the disabled warnings.
2440         See discussion here:
2441         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00275.html>
2443 2024-04-17  Bruno Haible  <bruno@clisp.org>
2445         totalorder* tests: Strengthen tests.
2446         * tests/test-totalorder.h: Include <math.h>.
2447         (positive_NaN_with_payload, negative_NaN_with_payload): New functions.
2448         (main): Test quiet NaNs of each sign with different payload.
2449         * tests/test-totalorder.c (TOTALORDER_POSITIVE_NAN,
2450         TOTALORDER_NEGATIVE_NAN): Remove macros.
2451         (TOTALORDER_SETPAYLOAD): New macro.
2452         * tests/test-totalorderf.c (TOTALORDER_POSITIVE_NAN,
2453         TOTALORDER_NEGATIVE_NAN): Remove macros.
2454         (TOTALORDER_SETPAYLOAD): New macro.
2455         * tests/test-totalorderl.c (TOTALORDER_POSITIVE_NAN,
2456         TOTALORDER_NEGATIVE_NAN): Remove macros.
2457         (TOTALORDER_SETPAYLOAD): New macro.
2458         * modules/totalorder-tests (Depends-on): Add setpayload.
2459         (Makefile.am): Link test-totalorder with $(SETPAYLOAD_LIBM).
2460         * modules/totalorderf-tests (Depends-on): Add setpayloadf.
2461         (Makefile.am): Link test-totalorderf with $(SETPAYLOADF_LIBM).
2462         * modules/totalorderl-tests (Depends-on): Add setpayloadl.
2463         (Makefile.am): Link test-totalorderl with $(SETPAYLOADL_LIBM).
2465 2024-04-17  Bruno Haible  <bruno@clisp.org>
2467         gnulib-tool.py: Use same warning style as gnulib-tool.sh.
2468         * pygnulib/GLTestDir.py (GLTestDir.execute): Prefix the
2469         "incompatible license" message with "gnulib-tool: warning: ".
2471 2024-04-17  Bruno Haible  <bruno@clisp.org>
2473         stdio, utime-h: Fix more linkage errors when using C++.
2474         * lib/stdio.in.h (rpl_fwrite, rpl_fwrite_unlocked): Use _GL_EXTERN_C
2475         instead of extern.
2476         * lib/utime.in.h (_gl_utimens_windows): Likewise.
2478 2024-04-17  Bruno Haible  <bruno@clisp.org>
2480         Fix linkage errors when using C++.
2481         Reported by Miro Palmu <email@miropalmu.cc> in
2482         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00274.html>.
2483         * lib/acl.h: Add 'extern "C" {' / '}' boilerplate.
2484         * lib/alignalloc.h: Likewise.
2485         * lib/aligned-malloc.h: Likewise.
2486         * lib/allocator.h: Likewise.
2487         * lib/arcfour.h: Likewise.
2488         * lib/arctwo.h: Likewise.
2489         * lib/areadlink.h: Likewise.
2490         * lib/argv-iter.h: Likewise.
2491         * lib/argz.in.h: Likewise.
2492         * lib/binary-io.h: Likewise.
2493         * lib/bitrotate.h: Likewise.
2494         * lib/bitset.h: Likewise.
2495         * lib/bitsetv.h: Likewise.
2496         * lib/c-strcaseeq.h: Likewise.
2497         * lib/canon-host.h: Likewise.
2498         * lib/careadlinkat.h: Likewise.
2499         * lib/chdir-long.h: Likewise.
2500         * lib/check-version.h: Likewise.
2501         * lib/classpath.h: Likewise.
2502         * lib/cloexec.h: Likewise.
2503         * lib/close-stream.h: Likewise.
2504         * lib/crc.h: Likewise.
2505         * lib/csharpcomp.h: Likewise.
2506         * lib/csharpexec.h: Likewise.
2507         * lib/cycle-check.h: Likewise.
2508         * lib/des.h: Likewise.
2509         * lib/dev-ino.h: Likewise.
2510         * lib/di-set.h: Likewise.
2511         * lib/eealloc.h: Likewise.
2512         * lib/exclude.h: Likewise.
2513         * lib/execinfo.in.h: Likewise.
2514         * lib/execute.h: Likewise.
2515         * lib/exitfail.h: Likewise.
2516         * lib/fcntl-safer.h: Likewise.
2517         * lib/file-set.h: Likewise.
2518         * lib/file-type.h: Likewise.
2519         * lib/filenamecat.h: Likewise.
2520         * lib/filevercmp.h: Likewise.
2521         * lib/fpending.h: Likewise.
2522         * lib/fprintftime.h: Likewise.
2523         * lib/fpucw.h: Likewise.
2524         * lib/fsusage.h: Likewise.
2525         * lib/ftoastr.h: Likewise.
2526         * lib/full-read.h: Likewise.
2527         * lib/gc.h: Likewise.
2528         * lib/getndelim2.h: Likewise.
2529         * lib/getnline.h: Likewise.
2530         * lib/getugroups.h: Likewise.
2531         * lib/glthread/tls.h: Likewise.
2532         * lib/hamt.h: Likewise.
2533         * lib/hard-locale.h: Likewise.
2534         * lib/hash-pjw-bare.h: Likewise.
2535         * lib/hash-pjw.h: Likewise.
2536         * lib/hash-triple.h: Likewise.
2537         * lib/hmac.h: Likewise.
2538         * lib/human.h: Likewise.
2539         * lib/i-ring.h: Likewise.
2540         * lib/idcache.h: Likewise.
2541         * lib/idx.h: Likewise.
2542         * lib/ino-map.h: Likewise.
2543         * lib/inttostr.h: Likewise.
2544         * lib/isapipe.h: Likewise.
2545         * lib/javacomp.h: Likewise.
2546         * lib/javaexec.h: Likewise.
2547         * lib/jit/cache.h: Likewise.
2548         * lib/linebuffer.h: Likewise.
2549         * lib/localeinfo.h: Likewise.
2550         * lib/long-options.h: Likewise.
2551         * lib/mbchar.h: Likewise.
2552         * lib/mbfile.h: Likewise.
2553         * lib/mbiter.h: Likewise.
2554         * lib/mbiterf.h: Likewise.
2555         * lib/mbuiter.h: Likewise.
2556         * lib/mbuiterf.h: Likewise.
2557         * lib/mcel.h: Likewise.
2558         * lib/memcasecmp.h: Likewise.
2559         * lib/memcoll.h: Likewise.
2560         * lib/memxor.h: Likewise.
2561         * lib/mgetgroups.h: Likewise.
2562         * lib/mkdir-p.h: Likewise.
2563         * lib/modechange.h: Likewise.
2564         * lib/mountlist.h: Likewise.
2565         * lib/mpsort.h: Likewise.
2566         * lib/msvc-nothrow.h: Likewise.
2567         * lib/nan.h: Likewise.
2568         * lib/openat-priv.h: Likewise.
2569         * lib/openat.h: Likewise.
2570         * lib/opendirat.h: Likewise.
2571         * lib/pagealign_alloc.h: Likewise.
2572         * lib/parse-datetime.h: Likewise.
2573         * lib/parse-duration.h: Likewise.
2574         * lib/physmem.h: Likewise.
2575         * lib/posixtm.h: Likewise.
2576         * lib/posixver.h: Likewise.
2577         * lib/printf-frexp.h: Likewise.
2578         * lib/printf-frexpl.h: Likewise.
2579         * lib/priv-set.h: Likewise.
2580         * lib/quote.h: Likewise.
2581         * lib/quotearg.h: Likewise.
2582         * lib/read-file.h: Likewise.
2583         * lib/readline.h: Likewise.
2584         * lib/readtokens.h: Likewise.
2585         * lib/readtokens0.h: Likewise.
2586         * lib/regex-quote.h: Likewise.
2587         * lib/renameatu.h: Likewise.
2588         * lib/rijndael-alg-fst.h: Likewise.
2589         * lib/rijndael-api-fst.h: Likewise.
2590         * lib/safe-alloc.h: Likewise.
2591         * lib/safe-write.h: Likewise.
2592         * lib/same-inode.h: Likewise.
2593         * lib/same.h: Likewise.
2594         * lib/save-cwd.h: Likewise.
2595         * lib/savedir.h: Likewise.
2596         * lib/savewd.h: Likewise.
2597         * lib/selinux-at.h: Likewise.
2598         * lib/signed-nan.h: Likewise.
2599         * lib/signed-snan.h: Likewise.
2600         * lib/snan.h: Likewise.
2601         * lib/sockets.h: Likewise.
2602         * lib/stdio-safer.h: Likewise.
2603         * lib/stdlib-safer.h: Likewise.
2604         * lib/streq.h: Likewise.
2605         * lib/strerror-override.h: Likewise.
2606         * lib/tmpdir.h: Likewise.
2607         * lib/trim.h: Likewise.
2608         * lib/u64.h: Likewise.
2609         * lib/unicase/casefold.h: Likewise.
2610         * lib/unicase/caseprop.h: Likewise.
2611         * lib/unicase/invariant.h: Likewise.
2612         * lib/unicase/special-casing.in.h: Likewise.
2613         * lib/unicase/unicasemap.h: Likewise.
2614         * lib/unicodeio.h: Likewise.
2615         * lib/unilbrk/lbrktables.h: Likewise.
2616         * lib/unilbrk/ulc-common.h: Likewise.
2617         * lib/uninorm/decompose-internal.h: Likewise.
2618         * lib/unistd-safer.h: Likewise.
2619         * lib/unitypes.in.h: Likewise.
2620         * lib/uniwbrk/wbrktable.h: Likewise.
2621         * lib/unlinkdir.h: Likewise.
2622         * lib/userspec.h: Likewise.
2623         * lib/utimecmp.h: Likewise.
2624         * lib/utimens.h: Likewise.
2625         * lib/windows-spawn.h: Likewise.
2626         * lib/write-any-file.h: Likewise.
2627         * lib/xbinary-io.h: Likewise.
2628         * lib/xgetcwd.h: Likewise.
2629         * lib/xgetdomainname.h: Likewise.
2630         * lib/xgethostname.h: Likewise.
2631         * lib/xmemcoll.h: Likewise.
2632         * lib/xprintf.h: Likewise.
2633         * lib/xreadlink.h: Likewise.
2634         * lib/xsize.h: Likewise.
2635         * lib/xstrndup.h: Likewise.
2636         * lib/xstrtod.h: Likewise.
2637         * lib/xstrtol.h: Likewise.
2638         * lib/yesno.h: Likewise.
2639         * lib/isnand-nolibm.h (isnand): Declare with C linkage.
2640         * lib/isnanf-nolibm.h (isnanf): Likewise.
2641         * lib/isnanl-nolibm.h (isnanl): Likewise.
2643 2024-04-17  Collin Funk  <collin.funk1@gmail.com>
2645         gnulib-tool.py: Make an instance variable local to a function.
2646         * pygnulib/GLImport.py (GLImport.execute): Define the GLFileAssistant as
2647         local to this function because it is unused elsewhere.
2649 2024-04-17  Collin Funk  <collin.funk1@gmail.com>
2651         gnulib-tool.py: Remove an unused instance attribute.
2652         * pygnulib/GLImport.py (GLImport.__init__): Remove the unused
2653         GLFileSystem object.
2655 2024-04-17  Collin Funk  <collin.funk1@gmail.com>
2657         gnulib-tool.py: Fix a pylint 'attribute-defined-outside-init' warning.
2658         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Don't
2659         define a 'modules' attribute since it is never used.
2661 2024-04-17  Bruno Haible  <bruno@clisp.org>
2663         getpayloadl: Add tests.
2664         * tests/test-getpayloadl.c: New file.
2665         * modules/getpayloadl-tests: New file.
2667         getpayloadl: New module.
2668         * lib/math.in.h (getpayloadl): New declaration.
2669         * lib/getpayloadl.c: New file.
2670         * m4/math_h.m4 (gl_MATH_H): Test whether getpayloadl is declared.
2671         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPAYLOADL.
2672         (gl_MATH_H_DEFAULTS): Initialize HAVE_GETPAYLOADL, REPLACE_GETPAYLOADL.
2673         * modules/math (Makefile.am): Substitute GNULIB_GETPAYLOADL,
2674         HAVE_GETPAYLOADL, REPLACE_GETPAYLOADL.
2675         * modules/getpayloadl: New file.
2676         * doc/posix-functions/getpayloadl.texi: Mention the new module and the
2677         glibc bug.
2679 2024-04-17  Bruno Haible  <bruno@clisp.org>
2681         getpayloadf: Add tests.
2682         * tests/test-getpayloadf.c: New file.
2683         * modules/getpayloadf-tests: New file.
2685         getpayloadf: New module.
2686         * lib/math.in.h (getpayloadf): New declaration.
2687         * lib/getpayloadf.c: New file.
2688         * m4/math_h.m4 (gl_MATH_H): Test whether getpayloadf is declared.
2689         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPAYLOADF.
2690         (gl_MATH_H_DEFAULTS): Initialize HAVE_GETPAYLOADF, REPLACE_GETPAYLOADF.
2691         * modules/math (Makefile.am): Substitute GNULIB_GETPAYLOADF,
2692         HAVE_GETPAYLOADF, REPLACE_GETPAYLOADF.
2693         * modules/getpayloadf: New file.
2694         * doc/posix-functions/getpayloadf.texi: Mention the new module and the
2695         glibc bug.
2697 2024-04-17  Bruno Haible  <bruno@clisp.org>
2699         getpayload: Add tests.
2700         * tests/test-getpayload.c: New file.
2701         * modules/getpayload-tests: New file.
2703         getpayload: New module.
2704         * lib/math.in.h (getpayload): New declaration.
2705         * lib/getpayload.c: New file.
2706         * m4/getpayload.m4: New file.
2707         * m4/math_h.m4 (gl_MATH_H): Test whether getpayload is declared.
2708         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPAYLOAD.
2709         (gl_MATH_H_DEFAULTS): Initialize HAVE_GETPAYLOAD, REPLACE_GETPAYLOAD.
2710         * modules/math (Makefile.am): Substitute GNULIB_GETPAYLOAD,
2711         HAVE_GETPAYLOAD, REPLACE_GETPAYLOAD.
2712         * modules/getpayload: New file.
2713         * doc/posix-functions/getpayload.texi: Mention the new module and the
2714         glibc bug.
2716 2024-04-16  Sam James  <sam@gentoo.org>
2718         wchar: Fix serial number.
2719         * m4/wchar_h.m4: Remove duplicate serial number specification and
2720         increment serial.
2722 2024-04-16  Collin Funk  <collin.funk1@gmail.com>
2724         gnulib-tool.py: Make GLModule's __eq__ and __hash__ method agree.
2725         * pygnulib/GLModuleSystem.py (GLModuleTable.__hash__): Only use the
2726         module name in hash computations.
2728 2024-04-16  Bruno Haible  <bruno@clisp.org>
2730         setpayloadsigl: Add tests.
2731         * tests/test-setpayloadsigl.c: New file, based on
2732         tests/test-setpayloadl.c.
2733         * modules/setpayloadsigl-tests: New file.
2735         setpayloadsigl: New module.
2736         * lib/math.in.h (setpayloadsigl): New declaration.
2737         * lib/setpayloadsigl.c: New file, based on lib/setpayloadl.c.
2738         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadsigl is declared.
2739         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADSIGL.
2740         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADSIGL.
2741         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADSIGL,
2742         HAVE_SETPAYLOADSIGL.
2743         * modules/setpayloadsigl: New file.
2744         * doc/posix-functions/setpayloadsigl.texi: Mention the new module.
2746 2024-04-16  Bruno Haible  <bruno@clisp.org>
2748         setpayloadsigf: Add tests.
2749         * tests/test-setpayloadf.c (PAYLOAD_BITS): New macro.
2750         (main): Use it.
2751         * tests/test-setpayloadsigf.c: New file, based on
2752         tests/test-setpayloadf.c.
2753         * modules/setpayloadsigf-tests: New file.
2755         setpayloadsigf: New module.
2756         * lib/math.in.h (setpayloadsigf): New declaration.
2757         * lib/setpayloadsigf.c: New file, based on lib/setpayloadf.c.
2758         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadsigf is declared.
2759         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADSIGF.
2760         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADSIGF.
2761         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADSIGF,
2762         HAVE_SETPAYLOADSIGF.
2763         * modules/setpayloadsigf: New file.
2764         * doc/posix-functions/setpayloadsigf.texi: Mention the new module.
2766 2024-04-16  Bruno Haible  <bruno@clisp.org>
2768         setpayloadsig: Add tests.
2769         * tests/test-setpayload.c (PAYLOAD_BITS): New macro.
2770         (main): Use it.
2771         * tests/test-setpayloadsig.c: New file, based on
2772         tests/test-setpayload.c.
2773         * modules/setpayloadsig-tests: New file.
2775         setpayloadsig: New module.
2776         * lib/math.in.h (setpayloadsig): New declaration.
2777         * lib/setpayloadsig.c: New file, based on lib/setpayload.c.
2778         * m4/setpayloadsig.m4: New file, based on m4/setpayload.m4.
2779         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadsig is declared.
2780         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADSIG.
2781         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADSIG.
2782         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADSIG,
2783         HAVE_SETPAYLOADSIG.
2784         * modules/setpayloadsig: New file.
2785         * doc/posix-functions/setpayloadsig.texi: Mention the new module.
2787 2024-04-16  Bruno Haible  <bruno@clisp.org>
2789         setpayloadl: Fix platform-specific bugs.
2790         * lib/setpayloadl.c (setpayloadl): On m68k, consider the actual memory
2791         layout of a 'long double'. On platforms with quadruple-precision
2792         'long double', store 111 bits of payload, not only 110 bits.
2794 2024-04-16  Collin Funk  <collin.funk1@gmail.com>
2796         gnulib-tool.py: Prefer 'not in' over 'not ... in'.
2797         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Change conditional.
2798         * pygnulib/GLModuleSystem.py (GLModuleTable.addConditional): Likewise.
2800 2024-04-16  Collin Funk  <collin.funk1@gmail.com>
2802         gnulib-tool.py: Make data structures more clear.
2803         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Use a set to
2804         represent the unconditional modules instead of a dictionary. Remove
2805         redundant comments.
2806         (GLModuleTable.addUnconditional): Add the module to a set instead of
2807         using it as a key to the dictionary.
2809 2024-04-16  Bruno Haible  <bruno@clisp.org>
2811         setpayloadl: Add tests.
2812         * tests/test-setpayloadl.c: New file.
2813         * modules/setpayloadl-tests: New file.
2815         setpayloadl: New module.
2816         * lib/math.in.h (setpayloadl): New declaration.
2817         * lib/setpayloadl.c: New file.
2818         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadl is declared.
2819         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADL.
2820         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADL.
2821         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADL,
2822         HAVE_SETPAYLOADL.
2823         * modules/setpayloadl: New file.
2824         * doc/posix-functions/setpayloadl.texi: Mention the new module.
2826 2024-04-16  Bruno Haible  <bruno@clisp.org>
2828         setpayloadf: Add tests.
2829         * tests/test-setpayloadf.c: New file.
2830         * modules/setpayloadf-tests: New file.
2832         setpayloadf: New module.
2833         * lib/math.in.h (setpayloadf): New declaration.
2834         * lib/setpayloadf.c: New file.
2835         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadf is declared.
2836         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADF.
2837         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADF.
2838         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADF,
2839         HAVE_SETPAYLOADF.
2840         * modules/setpayloadf: New file.
2841         * doc/posix-functions/setpayloadf.texi: Mention the new module.
2843 2024-04-16  Bruno Haible  <bruno@clisp.org>
2845         setpayload: Add tests.
2846         * tests/test-setpayload.c: New file.
2847         * modules/setpayload-tests: New file.
2849         setpayload: New module.
2850         * lib/math.in.h (setpayload): New declaration.
2851         * lib/setpayload.c: New file.
2852         * m4/setpayload.m4: New file.
2853         * m4/math_h.m4 (gl_MATH_H): Test whether setpayload is declared.
2854         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOAD.
2855         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOAD.
2856         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOAD,
2857         HAVE_SETPAYLOAD.
2858         * modules/setpayload: New file.
2859         * doc/posix-functions/setpayload.texi: Mention the new module.
2861 2024-04-15  Collin Funk  <collin.funk1@gmail.com>
2863         gnulib-tool.py: Optimize directory creation.
2864         * pygnulib/GLTestDir.py (GLTestDir.execute): Use a list of possible
2865         subdirectories and create them upfront instead of checking every file.
2867 2024-04-15  Simon Josefsson  <simon@josefsson.org>
2869         gitlog-to-changelog: Revert 2024-04-12 fix and add documentation.
2870         * build-aux/gitlog-to-changelog: Use localtime.
2871         * doc/gitlog-to-changelog.texi: Add.
2872         * doc/gnulib.texi (Build Infrastructure Modules): Add.
2874 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
2876         gnulib-tool.py: Fix incorrect type hint.
2877         * pygnulib/constants.py (filter_filelist): Correct the type hint on the
2878         'filelist' argument. It is a list of strings, not a string.
2880 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
2882         gnulib-tool.py: Write newlines consistently.
2883         * pygnulib/constants.py (NL): Remove variable.
2884         * pygnulib/GLImport.py (GLImport.gnulib_comp): Use '\n' instead of
2885         constants.NL.
2886         * pygnulib/GLModuleSystem.py
2887         (GLModule.getAutomakeSnippet_Unconditional): Likewise.
2888         * pygnulib/main.py (main_with_exception_handling): Likewise.
2890 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
2892         gnulib-tool.py: Don't perform newline conversions.
2893         * pygnulib/constants.py (nlconvert): Remove function. Remove unused
2894         platform import.
2895         * pygnulib/GLImport.py (GLImport.gnulib_cache): Remove calls to
2896         nlconvert().
2897         * pygnulib/GLModuleSystem.py
2898         (GLModule.getAutomakeSnippet_Unconditional): Likewise.
2899         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
2900         Likewise.
2902 2024-04-14  Bruno Haible  <bruno@clisp.org>
2904         users.txt: Update some more entries.
2905         * users.txt: Remove cvsps, gpg, gtkreindeer, libvirt, mailfromd, msmtp,
2906         OPeNDAP. Update some existing entries.
2908 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
2910         gnulib-tool.py: Remove some unused variable assignments.
2911         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Remove unused
2912         variable.
2913         * pygnulib/GLInfo.py (GLInfo.date, GLInfo.version): Remove assignments
2914         to variables unconditionally set in try, except blocks.
2915         * pygnulib/GLModuleSystem.py (GLModule.getConditionalName)
2916         (GLModule.getShellFunc, GLModule.getShellVar): Likewise.
2918 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
2920         gnulib-tool.py: Don't use mutable default arguments.
2921         * pygnulib/GLFileSystem.py (GLFileAssistant.__init__): Set the default
2922         argument for 'transformers' to None. If it is None then set it to an
2923         empty dictionary in the body.
2925 2024-04-13  Bruno Haible  <bruno@clisp.org>
2927         bootstrap: Implement phase 1 as documented in the --help output.
2928         Reported by Simon Josefsson as bug #1 in
2929         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00152.html>.
2930         * top/bootstrap: Correct indentation.
2931         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): Implement as
2932         documented:
2933         If GNULIB_SRCDIR and GNULIB_REVISION are set and there is a 'gnulib'
2934         submodule, checkout the revision GNULIB_REVISION.
2935         If GNULIB_SRCDIR and GNULIB_REVISION are set and --no-git is specified,
2936         don't checkout the revision GNULIB_REVISION.
2938 2024-04-13  Bruno Haible  <bruno@clisp.org>
2940         bootstrap: Simplify git submodule initialization.
2941         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): Err out if git is
2942         older than version 1.6.4. Remove fallback code for older versions.
2943         * build-aux/bootstrap: Regenerated.
2945 2024-04-13  Collin Funk  <collin.funk1@gmail.com>
2947         Improve 'git diff' of Python files.
2948         * .gitattributes: Add a rule for *.py files.
2950 2024-04-13  Collin Funk  <collin.funk1@gmail.com>
2952         gnulib-tool.py: Fix extra arguments to function call.
2953         * pygnulib/GLImport.py (GLImport.execute): Add the missing joinpath call
2954         on two file name components before calling isfile().
2956 2024-04-13  Bruno Haible  <bruno@clisp.org>
2958         bootstrap: Fix --help messages.
2959         Reported by Simon Josefsson in
2960         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00162.html>.
2961         * top/bootstrap (usage): Fix the description of GNULIB_SRCDIR. Document
2962         GNULIB_REFDIR. Use full-sentences style. Tweak wording.
2963         * top/bootstrap-funclib.sh (autopull_usage): Clarify the phase. Don't
2964         mention nonexistent options --gnulib-srcdir and --gnulib-refdir. Use
2965         full-sentences style.
2966         (autogen_usage): Clarify the phase. Use full-sentences style.
2967         * build-aux/bootstrap: Regenerated.
2969 2024-04-13  Bruno Haible  <bruno@clisp.org>
2971         gnulib-tool.py: Code tweak.
2972         * pygnulib/main.py (main): Move file contents analysis out of a 'with'
2973         statement.
2975 2024-04-13  Bruno Haible  <bruno@clisp.org>
2977         gnulib-tool.py: Stop using codecs.open.
2978         * pygnulib/*.py: To open a file, consistently use
2979         open(..., mode='[rwa]', newline='\n', encoding='utf-8').
2981 2024-04-13  Bruno Haible  <bruno@clisp.org>
2983         gnulib-tool.py: Refactor directory tree removals.
2984         * pygnulib/constants.py (rmtree): New function.
2985         * pygnulib/GLImport.py (GLImport.execute): Use it instead of calling
2986         'rm -rf' directly or shutil.rmtree.
2987         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
2988         Likewise.
2989         * pygnulib/main.py (main): Likewise.
2991 2024-04-12  Collin Funk  <collin.funk1@gmail.com>
2993         gnulib-tool.py: Fix --copy-file directory creation.
2994         Reported by Bruno Haible in
2995         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00140.html>
2996         * pygnulib/main.py (main): Make sure that destdir is set in the GLConfig
2997         object before copying files.
2999 2024-04-12  Bruno Haible  <bruno@clisp.org>
3001         gnulib-tool.py: Implement --add-import --with-*-tests correctly.
3002         * pygnulib/GLConfig.py (GLConfig.update): Use list-merging for the test
3003         categories.
3004         * pygnulib/GLImport.py (GLImport.__init__): Don't merge back those
3005         values which were already considered by taking the union.
3007 2024-04-12  Bruno Haible  <bruno@clisp.org>
3009         gnulib-tool.py: Implement --add-import --avoid correctly.
3010         * pygnulib/GLConfig.py (GLConfig.update): Don't test for the unused key
3011         'tests'.
3012         (GLConfig.default): Likewise.
3013         * pygnulib/GLImport.py (GLImport.__init__): Don't merge back those
3014         values which were already considered by taking the union.
3016 2024-04-12  Bruno Haible  <bruno@clisp.org>
3018         gnulib-tool.py: Refactor.
3019         * pygnulib/GLConfig.py (GLConfig.update, GLConfig.update_key): Improve
3020         variable names and comments.
3021         * pygnulib/GLImport.py (GLImport.__init__): Improve comments.
3023 2024-04-12  Bruno Haible  <bruno@clisp.org>
3025         gnulib-tool.py: Optimize.
3026         * pygnulib/GLConfig.py (GLConfig.update, GLConfig.update_key): Avoid
3027         useless cloning of dictionaries.
3029 2024-04-12  Bruno Haible  <bruno@clisp.org>
3031         gnulib-tool.py: Implement --no-conditional-dependencies correctly.
3032         * pygnulib/GLConfig.py (GLConfig.default): For 'conddeps', return None,
3033         not False.
3034         (GLConfig.checkCondDeps): Update result type.
3035         (resetCondDeps): Reset to return None, not False.
3036         * pygnulib/GLImport.py (GLImport.actioncmd): Update.
3038 2024-04-12  Bruno Haible  <bruno@clisp.org>
3040         gnulib-tool.py: Implement --no-libtool option correctly.
3041         * pygnulib/GLConfig.py (GLConfig.default): For 'libtool', return None,
3042         not False.
3043         (GLConfig.checkLibtool): Update result type.
3044         (resetLibtool): Reset to return None, not False.
3045         * pygnulib/GLImport.py (GLImport.actioncmd): Update.
3047 2024-04-12  Bruno Haible  <bruno@clisp.org>
3049         gnulib-tool.py: Accept conditional dependencies with tests.
3050         * pygnulib/GLImport.py (GLImport.__init__): Don't reject the combination
3051         of gl_CONDITIONAL_DEPENDENCIES and gl_WITH_TESTS.
3052         * pygnulib/GLError.py (GLError.__repr__): Remove error 10.
3053         * pygnulib/main.py (main_with_exception_handling): Likewise.
3055 2024-04-12  Bruno Haible  <bruno@clisp.org>
3057         gnulib-tool.py: Fix handling of --with-obsolete.
3058         * pygnulib/constants.py (TESTS): Remove 'obsolete' category.
3059         * pygnulib/GLConfig.py (GLConfig.__init__): Add optional incobsolete
3060         parameter.
3061         (GLConfig.default): Handle 'incobsolete'.
3062         (GLConfig.checkIncObsolete, GLConfig.setIncObsolete,
3063         GLConfig.resetIncObsolete): New methods.
3064         * pygnulib/GLModuleSystem.py (GLModuleSystem.transitive_closure): For
3065         incobsolete, use new GLConfig methods.
3066         * pygnulib/GLImport.py (GLImport.__init__, GLImport.actioncmd,
3067         GLImport.gnulib_cache): Likewise.
3068         * pygnulib/main.py (main): Pass the incobsolete value to the GLConfig
3069         constructor.
3071 2024-04-12  Simon Josefsson  <simon@josefsson.org>
3073         gitlog-to-changelog: Make output reproducible.
3074         * build-aux/gitlog-to-changelog: Use gmtime instead of localtime.
3076 2024-04-12  Bruno Haible  <bruno@clisp.org>
3078         gnulib-tool.py: Fix parsing of gl_LGPL in gnulib-cache.m4.
3079         * pygnulib/GLImport.py (GLImport.__init__): Search for gl_LGPL in
3080         gnulib-cache.m4 more carefully.
3082         gnulib-tool.py: Fix parsing of gnulib-cache.m4.
3083         * pygnulib/GLImport.py (GLImport.__init__): While parsing
3084         gnulib-cache.m4, stop parsing the identifier starting with 'gl_' when
3085         encountering a character that is not a uppercase letter, digit, or
3086         underscore.
3088 2024-04-12  Bruno Haible  <bruno@clisp.org>
3090         gnulib-tool.py: Fix misspelled option in output.
3091         * pygnulib/GLImport.py (GLImport.actioncmd): Fix typo.
3093 2024-04-12  Bruno Haible  <bruno@clisp.org>
3095         gnulib-tool.py: Persist the --with-longrunning-tests option.
3096         * pygnulib/GLImport.py (GLImport.gnulib_cache): Conditionally add
3097         gl_WITH_LONGRUNNING_TESTS to gnulib-cache.m4.
3099 2024-04-12  Bruno Haible  <bruno@clisp.org>
3101         gnulib-tool.py: Print warnings just like gnulib-tool.sh.
3102         * pygnulib/main.py (main): When printing a warning, print just
3103         "gnulib-tool" instead of the absolute file name.
3105 2024-04-12  Bruno Haible  <bruno@clisp.org>
3107         gnulib-tool.sh: Accept conditional dependencies with tests.
3108         * gnulib-tool.sh (func_import): Don't reject the combination of
3109         gl_CONDITIONAL_DEPENDENCIES and gl_WITH_TESTS.
3111 2024-04-11  Bruno Haible  <bruno@clisp.org>
3113         gnulib-tool.py: Optimize module set lookups.
3114         * gnulib-tool.py (profiler_args): New variable.
3115         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Turn
3116         handledmodules into a set.
3117         (GLModuleTable.transitive_closure_separately): For the 'in' test, use
3118         a set variable main_modules_set.
3120 2024-04-11  Collin Funk  <collin.funk1@gmail.com>
3122         gnulib-tool.py: Remove redundant backslashes from regexps.
3123         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't backslash ']' when it
3124         is outside of a set.
3125         * pygnulib/GLImport.py (GLImport.__init__): Don't use a backslash when
3126         ']' is at the start of a '[...]' set. Don't backslash special characters
3127         in a '[...]' set since they have their meaning dropped.
3128         * pygnulib/main.py (main): Likewise.
3130 2024-04-11  Collin Funk  <collin.funk1@gmail.com>
3132         gnulib-tool.py: Simplify regular expressions.
3133         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
3134         (GLEmiter.tests_Makefile_am): Change occurrences of '[A-Z][A-Z]*' to
3135         '[A-Z]+'.
3137 2024-04-11  Bruno Haible  <bruno@clisp.org>
3139         users.txt: Correct some entries.
3140         * users.txt: Update some existing entries.
3142 2024-04-11  Bruno Haible  <bruno@clisp.org>
3144         gnulib-tool.sh: Improve sort order of directories.
3145         * gnulib-tool.sh (func_import): In file fileset-changes, store directory
3146         names without a trailing slash.
3148 2024-04-11  Bruno Haible  <bruno@clisp.org>
3150         gnulib-tool.sh: Remove './' prefix from file names to update or remove.
3151         * gnulib-tool.sh (func_import): Don't let rewritten file names start
3152         with './'.
3154 2024-04-11  Collin Funk  <collin.funk1@gmail.com>
3156         gnulib-tool.py: Fix sorting of the LINGUAS file.
3157         * pygnulib/GLImport.py (GLImport.execute): Sort the list of locales
3158         before writing them into the LINGUAS file.
3160 2024-04-10  Bruno Haible  <bruno@clisp.org>
3162         gnulib-tool.sh: Handle .gitignore files that do not end in a newline.
3163         * gnulib-tool.sh (func_import): If the .gitignore file ends with a
3164         character other than a newline, add a newline before adding more lines.
3166 2024-04-10  Bruno Haible  <bruno@clisp.org>
3168         gnulib-tool.py: Skip nonexistent modules instead of failing.
3169         * pygnulib/GLModuleSystem.py (GLModuleSystem.find): Use the same warning
3170         wording as gnulib-tool.sh.
3171         * pygnulib/GLImport.py (GLImport.gnulib_cache): Print the specified
3172         modules, not the base modules.
3173         (GLImport.prepare): Don't put None elements into base_modules.
3175 2024-04-10  Collin Funk  <collin.funk1@gmail.com>
3177         gnulib-tool.py: Use function arguments instead of magic numbers.
3178         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Remove the
3179         'verifier' integer flag argument. Add the 'module_filter' function
3180         argument. Use it to determine if Autoconf snippets should be printed for
3181         each module.
3182         * pygnulib/GLImport.py (GLImport.gnulib_comp): Update call to use a
3183         lambda function.
3184         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
3186 2024-04-10  Collin Funk  <collin.funk1@gmail.com>
3188         gnulib-tool: Fix a typo.
3189         * gnulib-tool.sh: Fix a typo in comment.
3190         * pygnulib/main.py (main): Likewise.
3192 2024-04-09  Collin Funk  <collin.funk1@gmail.com>
3194         gnulib-tool.py: Change the avoid list to a set for lookups.
3195         * pygnulib/GLModuleSystem.py (GLModuleSystem.__init__): Store the
3196         avoided modules in a set instead of a list. This is used only for
3197         membership checks when computing the transitive closure of the given
3198         modules, therefore prefer the O(1) average case over O(n).
3200 2024-04-09  Collin Funk  <collin.funk1@gmail.com>
3202         gnulib-tool.py: Remove unused setter and getter functions.
3203         * pygnulib/GLModuleSystem.py (GLModuleTable.getAvoids)
3204         (GLModuleTable.setAvoids): Remove these unused functions.
3206 2024-04-09  Bruno Haible  <bruno@clisp.org>
3208         totalorder, totalorderf: Avoid miscompilation by gcc on NetBSD/i386.
3209         * lib/totalorder.c (totalorder): Use the a compiler optimization barrier
3210         also for GCC.
3211         * lib/totalorderf.c (totalorderf): Likewise.
3213 2024-04-09  Collin Funk  <collin.funk1@gmail.com>
3215         gnulib-tool.py: Simplify use of GLModuleTable accessors.
3216         * pygnulib/GLModuleSystem.py (GLModuleTable.__getitem__): Remove
3217         function.
3218         * pygnulib/GLImport.py (GLImport.gnulib_cache, GLImport.gnulib_comp)
3219         (GLImport.execute): Use function calls on the GLModuleTable to access
3220         module lists instead of using keys to emulate a dictionary.
3222 2024-04-09  Bruno Haible  <bruno@clisp.org>
3224         totalorder, totalorderf: Avoid miscompilation by clang on OpenBSD/i386.
3225         * lib/totalorder.c (totalorder): Insert a compiler optimization barrier.
3226         * lib/totalorderf.c (totalorderf): Likewise.
3228 2024-04-09  Bruno Haible  <bruno@clisp.org>
3230         totalorder, totalorderf: Fix handling of SNaN on i386 and x86_64 CPUs.
3231         * lib/totalorder.c: Include <string.h>.
3232         (totalorder): Use memcpy to copy the 'double' values into the union.
3233         Drop 'volatile'.
3234         * lib/totalorderf.c: Include <string.h>.
3235         (totalorderf): Use memcpy to copy the 'float' values into the union.
3236         Drop 'volatile'.
3238 2024-04-09  Bruno Haible  <bruno@clisp.org>
3240         totalorder tests: Fix signature test.
3241         * tests/test-totalorder.c: Test the signature of totalorder, not
3242         totalorderf.
3244 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
3246         gnulib-tool.py: Use single-quotes for strings, part 2.
3247         * pygnulib/GLEmiter.py (GLEmiter.po_Makevars): Change a double-quoted
3248         string to single-quotes missed by the previous commit.
3250 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
3252         gnulib-tool.py: Use single-quotes for strings.
3253         * pygnulib/*.py: Change double-quoted strings to use single-quotes
3254         unless doing so would require adding backslashes.
3256 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
3258         gnulib-tool.py: Prefer 'list.append(item)' over 'list += [item]'.
3259         * pygnulib/*.py: Change occurrences '+= [item]' to use '.append(item)'
3260         where item is a single element added to the list.
3261         See discussion here:
3262         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00091.html>
3264 2024-04-08  Bruno Haible  <bruno@clisp.org>
3266         ptsname_r: Work around ptsname_r bug on NetBSD 10.0.
3267         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): On NetBSD, arrange to override
3268         ptsname_r.
3269         * lib/ptsname_r.c (ptsname_r): Add workaround for NetBSD bug.
3270         * doc/glibc-functions/ptsname_r.texi: Mention the NetBSD bug.
3272 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
3274         gnulib-tool.py: Fix incomplete type hint.
3275         * pygnulib/GLModuleSystem.py (GLModuleTable.getCondition): Add None to
3276         the return type hint. This is the return value when the module is not a
3277         conditional dependency.
3279 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
3281         gnulib-tool.py: Remove unnecessary conditional.
3282         * pygnulib/GLModuleSystem.py (GLModuleTable.__getitem__): Don't check if
3283         the key is valid twice.
3285 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
3287         gnulib-tool.py: Remove an unused and incorrect function.
3288         * pygnulib/GLFileSystem.py (GLFileAssistant.removeFile): Remove this
3289         unused function. The correct method of removing an element from a list
3290         is to use the remove() function, not pop() which takes an index.
3292 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
3294         gnulib-tool.py: Omit some unnecessary list() calls around sorted().
3295         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Remove the list()
3296         call in the argument to sorted. The sorted() function works on any
3297         iterable and always returns a list.
3298         * pygnulib/GLImport.py (GLImport.rewrite_old_files)
3299         (GLImport.rewrite_new_files): Likewise.
3300         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure)
3301         (GLModuleTable.transitive_closure_separately): Likewise.
3302         * pygnulib/GLTestDir.py (GLTestDir.rewrite_files): Likewise.
3304 2024-04-08  Bruno Haible  <bruno@clisp.org>
3306         pthread-h: Fix configuration (regression 2024-03-28).
3307         Reported by Collin Funk in
3308         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00036.html>.
3309         * m4/pthread_h.m4 (gl_PTHREAD_H_PART1): New macro, extracted from
3310         gl_PTHREAD_H.
3311         (gl_PTHREAD_H): Require it. Define using AC_DEFUN.
3312         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Require gl_PTHREAD_H_PART1,
3313         not only gl_PTHREAD_H_DEFAULTS.
3315 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
3317         gnulib-tool.py: Don't remove duplicate avoided modules.
3318         * pygnulib/GLConfig.py (GLConfig.addAvoid): Don't remove duplicates from
3319         the modules passed with --avoid.
3321 2024-04-07  Bruno Haible  <bruno@clisp.org>
3323         sigsegv tests: Avoid a crash on NetBSD 10.0/i386.
3324         * tests/test-sigsegv-catch-stackoverflow1.c
3325         (stackoverflow_handler_continuation): On NetBSD/i386, align the stack
3326         pointer before calling longjmp.
3328 2024-04-07  Bruno Haible  <bruno@clisp.org>
3330         gnulib-tool.py: Add comment.
3331         * pygnulib/constants.py (joinpath): Document a limitation.
3333 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
3335         gnulib-tool.py: Don't allow path normalization to delete a variable.
3336         * pygnulib/GLModuleSystem.py
3337         (GLModule.getAutomakeSnippet_Unconditional): Use os.path.join() on the
3338         Makefile variable so it isn't deleted by a following '..' from
3339         os.path.norm().
3341 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
3343         gnulib-tool.py: Use auxdir as given by AC_CONFIG_AUX_DIR.
3344         * pygnulib/GLImport.py (GLImport.__init__): Don't modify the path given
3345         by AC_CONFIG_AUX_DIR by prefixing it with destdir. Use a more strict
3346         regular expression instead of cleaner().
3348 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
3350         gnulib-tool.py: Locate configure.ac correctly when --dir is given.
3351         * pygnulib/GLConfig.py (GLConfig.setAutoconfFile): Don't combine the
3352         given file name argument with destdir.
3353         * pygnulib/main.py (main): Use os.path.join() instead of joinpath() when
3354         constructing the path to the configure.ac file. The latter normalizes
3355         paths which causes the test suite to fail when printed in files.
3357 2024-04-06  Bruno Haible  <bruno@clisp.org>
3359         expm1l: Work around a NetBSD 10.0/i386 bug.
3360         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Test the value of
3361         expm1l(2^LDBL_MIN_EXP).
3362         * doc/posix-functions/expm1l.texi: Mention the NetBSD 10.0/i386 bug.
3363         * tests/test-expm1.h (test_function): Allow more deviation on
3364         NetBSD/i386.
3366 2024-04-05  Bruno Haible  <bruno@clisp.org>
3368         exp2l: Work around a NetBSD 10.0/i386 bug.
3369         * m4/exp2l.m4 (gl_FUNC_EXP2L): Test the value of exp2l(LDBL_MAX_EXP-1).
3370         * doc/posix-functions/exp2l.texi: Mention the NetBSD 10.0/i386 bug.
3372 2024-04-05  Bruno Haible  <bruno@clisp.org>
3374         roundl: Fix a link error on Linux/powerpc64le.
3375         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Accept an additional TYPE
3376         argument.
3377         * m4/isfinite.m4 (gl_ISFINITE): Use the type 'double'.
3378         * m4/isinf.m4 (gl_ISINF): Likewise.
3379         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
3380         * m4/roundf.m4 (gl_FUNC_ROUNDF): Use the type 'float'.
3381         * m4/roundl.m4 (gl_FUNC_ROUNDL): Use the type 'long double'.
3383 2024-04-05  Bruno Haible  <bruno@clisp.org>
3385         exp2l tests: Enable a test for glibc versions >= 2.16.
3386         * tests/test-exp2.h (test_function): Disable a glibc bug workaround for
3387         glibc versions >= 2.16.
3389 2024-04-05  Bruno Haible  <bruno@clisp.org>
3391         expl tests: Avoid test failure on NetBSD 10.0/i386.
3392         * tests/test-exp.h (test_function): Allow more deviation on NetBSD/i386.
3394 2024-04-05  Collin Funk  <collin.funk1@gmail.com>
3396         gnulib-tool.py: Use 'Any' instead of type unions in GLConfig.
3397         * pygnulib/GLConfig.py (GLConfig.__getitem__, GLConfig.dictionary)
3398         (GLConfig.default, GLConfig.isdefault, GLConfig.values): Use 'Any' from
3399         the typing module instead of large type unions. This silences unhelpful
3400         warnings from type checkers.
3402 2024-04-05  Collin Funk  <collin.funk1@gmail.com>
3404         gnulib-tool.py: Fix 'consider-using-set-comprehension' warnings.
3405         * pygnulib/GLImport.py (GLImport.prepare): Create a set directly instead
3406         of creating a list and passing it to a call of set().
3407         (GLImport.__init__): Likewise. Use max() instead of getting the last
3408         element of a sorted list.
3410 2024-04-05  Collin Funk  <collin.funk1@gmail.com>
3412         gnulib-tool.py: Fix 'consider-using-with' pylint warnings.
3413         * pygnulib/GLModuleSystem.py (GLModuleSystem.list): Use run() instead of
3414         Popen() from the subprocess module. This function handles cleanup
3415         internally instead of as a context manager via the 'with' statement.
3417 2024-04-05  Bruno Haible  <bruno@clisp.org>
3419         Update for NetBSD 9.3 and 10.0.
3420         * doc/*/*.texi: Update for NetBSD 9.3 and 10.0.
3421         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Update comments and cross-compilation
3422         guess.
3423         * m4/log1pl.m4 (gl_FUNC_LOG1PL_WORKS): Likewise.
3424         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Likewise.
3425         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LA): Likewise.
3426         * m4/remainderl.m4 (gl_FUNC_REMAINDERL_WORKS): Likewise.
3427         * m4/fcntl.m4: Update comments.
3428         * m4/fenv-environment.m4: Likewise.
3429         * m4/fenv-exceptions-trapping.m4: Likewise.
3430         * m4/fnmatch.m4: Likewise.
3431         * m4/getcwd-abort-bug.m4: Likewise.
3432         * m4/iswdigit.m4: Likewise.
3433         * m4/iswxdigit.m4: Likewise.
3434         * m4/modfl.m4: Likewise.
3435         * m4/wcscmp.m4: Likewise.
3436         * m4/wcsncmp.m4: Likewise.
3437         * m4/wctrans.m4: Likewise.
3438         * m4/wcwidth.m4: Likewise.
3440 2024-04-04  Collin Funk  <collin.funk1@gmail.com>
3442         posix-modules, all-modules: Fix --version output using git options.
3443         * all-modules (func_version): Pass --format and --date options to git
3444         so the output does not depend on the user's configuration. Pass
3445         '-n 1' to speed up the operation, since we only need the first entry.
3446         * posix-modules (func_version): Likewise.
3448 2024-04-04  Bruno Haible  <bruno@clisp.org>
3450         all-modules: Fix errors during './all-modules --version' execution.
3451         Reported by Collin Funk in
3452         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00050.html>.
3453         * all-modules (func_exit, func_fatal_error, func_readlink,
3454         func_gnulib_dir): Include auxiliary functions from gnulib-tool.sh.
3456 2024-04-04  Bruno Haible  <bruno@clisp.org>
3458         posix-modules: Sync auxiliary functions from gnulib-tool.sh.
3459         * posix-modules (func_exit, func_fatal_error, func_readlink,
3460         func_gnulib_dir): Move before func_usage and func_version. Incorporate
3461         improvements from gnulib-tool.sh.
3463 2024-04-04  Collin Funk  <collin.funk1@gmail.com>
3465         gnulib-tool.py: Ignore 'use-dict-literal' warnings.
3466         * pygnulib/.pylintrc: Don't emit warning messages suggesting that
3467         'dict()' be converted to '{}'. This literal can be mistaken for sets,
3468         see discussion here:
3469         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00054.html>
3470         * pygnulib/main.py: Document this convention in coding style section.
3471         * pygnulib/GLFileSystem.py (GLFileAssistant.__init__): Convert an
3472         occurrence of '{}' to 'dict()'.
3474 2024-04-04  Collin Funk  <collin.funk1@gmail.com>
3476         gnulib-tool.py: Fix pylint 'raise-missing-from' warnings.
3477         * pygnulib/*.py: Use explicit exception chaining so that stack trace
3478         messages do not seem like bugs. See examples in:
3479         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00056.html>
3481 2024-04-04  Bruno Haible  <bruno@clisp.org>
3483         Add serial numbers to *.m4 files that did not have them.
3484         * m4/*.m4: Ensure the usual file header with file name and serial
3485         number.
3487         Make the file header of *.m4 files consistent:
3488         1. The file name.
3489         2. The serial number.
3490         3. The copyright and license header.
3491         * m4/*.m4: Adjust file headers.
3493         Make the serial numbers in *.m4 files effective.
3494         Reported by Sam James in
3495         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00051.html>.
3496         * m4/*.m4: Apply sed -e '1s|^# \(.*[.]m4\) serial |# \1\n# serial |'.
3498 2024-04-03  Bruno Haible  <bruno@clisp.org>
3500         gnulib-tool.sh: Reduce code duplication in last commit.
3501         * gnulib-tool.sh (func_get_automake_snippet_unconditional): Refactor
3502         computation of sed_prepend_auxdir.
3504 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
3506         gnulib-tool.sh: Don't emit an unnecessary './' path component.
3507         * gnulib-tool.sh (func_get_automake_snippet_unconditional): Only prefix
3508         build-aux files with '$(top_srcdir)/' when $auxdir is the top level
3509         directory.
3511 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
3513         gnulib-tool.py: Modernize class declarations to Python 3.
3514         * pygnulib/GLConfig.py: Remove the explicit object inheritance from
3515         class declarations. This is previously required in Python 2.
3516         * pygnulib/GLEmiter.py: Likewise.
3517         * pygnulib/GLFileSystem.py: Likewise.
3518         * pygnulib/GLImport.py: Likewise.
3519         * pygnulib/GLInfo.py: Likewise.
3520         * pygnulib/GLMakefileTable.py: Likewise.
3521         * pygnulib/GLModuleSystem.py: Likewise.
3522         * pygnulib/GLTestDir.py: Likewise.
3524 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
3526         gnulib-tool.py: Ignore pylint 'unidiomatic-typecheck' warnings.
3527         * pygnulib/.pylintrc: Disable warning C0123 since we don't mind using
3528         'type() is' instead of 'isinstance'.
3530 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
3532         gnulib-tool.py: Don't ignore the argument to --doc-base.
3533         * pygnulib/main.py (main): Check for the argument to --doc-base before
3534         creating the GLConfig object.
3536 2024-04-03  Pádraig Brady  <P@draigBrady.com>
3538         quotearg: fix shell-escape quoting with single quotes
3539         With shell-escape quoting, we misquoted strings
3540         where the first and last characters required escaping,
3541         while the string also contained single quotes.
3543         * lib/quotearg.c (quotearg_buffer_restyled): Ensure that
3544         pending_shell_escape_end is reset to the initial state
3545         when reprocessing input due to single quotes.
3546         * tests/test-quotearg-simple.c: Add a minimal test case.
3547         * tests/test-quotearg.c: Likewise.
3548         * tests/test-quotearg.h: Likewise.
3549         Reported by Grisha Levit
3551 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
3553         gnulib-tool.py: Use [] instead of list() to initialize empty lists.
3554         * pygnulib/*.py: Change occurrences of list() to [].
3556 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
3558         gnulib-tool.py: Fix determination whether to add the dummy module.
3559         * pygnulib/GLModuleSystem.py (GLModuleSystem.add_dummy): Only match the
3560         'lib_SOURCES' variable; stop at end-of-line.
3562 2024-04-02  Pádraig Brady  <P@draigBrady.com>
3564         renameatu: handle ENOSYS from renameatx_np
3565         * lib/renameatu.c(): Fall back to renameat() without RENAME_EXCL
3566         if "Function not implemented" is returned.  This was seen with macFUSE.
3567         Reported at https://github.com/coreutils/coreutils/issues/79
3569 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
3571         gnulib-tool.py: Accept valid make syntax for escaped newlines.
3572         * pygnulib/GLModuleSystem.py (GLModuleTable.add_dummy): Use
3573         combine_lines instead of remove remove_backslash_newline so spaces are
3574         added between each combined line.
3575         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
3576         * pygnulib/constants.py (remove_backslash_newline): Remove unused
3577         function.
3579 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
3581         gnulib-tool.py: Don't default to 'build-aux' for --auxdir.
3582         * pygnulib/GLConfig.py (GLConfig.__getitem__): Don't map '' to
3583         'build-aux' for the 'auxdir' key.
3584         * pygnulib/GLImport.py (GLImport.__init__): Change conditional to use an
3585         empty string instead of None since this is returned when --auxdir is not
3586         used.
3588 2024-04-02  Bruno Haible  <bruno@clisp.org>
3590         gnulib-tool: Remove unused variables.
3591         * pygnulib/GLConfig.py: Remove unused variables.
3592         * pygnulib/GLEmiter.py: Likewise.
3593         * pygnulib/GLFileSystem.py: Likewise.
3594         * pygnulib/GLImport.py: Likewise.
3595         * pygnulib/GLInfo.py: Likewise.
3596         * pygnulib/GLModuleSystem.py: Likewise.
3597         * pygnulib/GLTestDir.py: Likewise.
3598         * pygnulib/main.py: Likewise.
3599         * gnulib-tool.sh (func_emit_tests_Makefile_am): Remove unused variable
3600         perhapsLT.
3602         gnulib-tool.py: Remove no-op statements.
3603         * pygnulib/GLConfig.py (GLConfig.update): Remove no-op statement.
3605         gnulib-tool.py: Remove unused imports.
3606         * pygnulib/GLFileSystem.py: Remove unused imports.
3607         * pygnulib/GLEmiter.py: Likewise.
3608         (GLEmiter.autoconfSnippets): Fix type assertion message.
3610         gnulib-tool.py: Fix some IDE warnings.
3611         * HACKING: Update configuration of warnings.
3613 2024-04-01  Bruno Haible  <bruno@clisp.org>
3615         gnulib-tool.py: Add developer documentation.
3616         * HACKING: New section "Debugging the Python implementation of
3617         gnulib-tool".
3619 2024-04-01  Bruno Haible  <bruno@clisp.org>
3621         gnulib-tool.py: Use a standard Python program directory structure.
3622         * pygnulib/main.py (main_with_exception_handling): New function for
3623         existing code.
3624         * .gnulib-tool.py: New file.
3625         * pygnulib/constants.py: Update the computation of APP['root'].
3626         * gnulib-tool.py: Don't set PYTHONPATH.
3628 2024-04-01  Bruno Haible  <bruno@clisp.org>
3630         gnulib-tool.py: Simplify imports.
3631         * pygnulib/enums.py: New file, extracted from pygnulib/GLFileSystem.py.
3632         * pygnulib/classes.py: Remove file.
3633         * pygnulib/GLFileSystem.py: Remove class CopyAction. Update imports.
3634         * pygnulib/GLTestDir.py: Update imports.
3635         * pygnulib/GLConfig.py: Update imports and remove 'classes.' prefix.
3636         * pygnulib/main.py: Likewise.
3638 2024-04-01  Collin Funk  <collin.funk1@gmail.com>
3640         gnulib-tool.py: Only check existence for --extract-tests-module.
3641         * pygnulib/main.py (main): Check that the test module exists instead of
3642         looking it up and patching it if diff's are found.
3644 2024-04-01  Collin Funk  <collin.funk1@gmail.com>
3646         gnulib-tool.py: Fix --extract-tests-module with a test module.
3647         * pygnulib/GLModuleSystem.py (GLModule.getTestsName): Return the module
3648         name with '-tests' appended to it unconditionally.
3650 2024-04-01  Collin Funk  <collin.funk1@gmail.com>
3652         gnulib-tool.py: Use case-sensitive sorting for file names.
3653         * pygnulib/GLImport.py (GLImport.prepare): Remove the str.lower key from
3654         the call to sorted().
3656 2024-04-01  Paul Eggert  <eggert@cs.ucla.edu>
3658         getcwd: port better to buggy file systems
3659         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
3660         Time out after 5 seconds.
3662 2024-03-31  Collin Funk  <collin.funk1@gmail.com>
3664         gnulib-tool.py: Add missing quotation mark to reminder.
3665         * pygnulib/GLImport.py (GLImport.execute): Add missing end quote around
3666         file name in AC_CONFIG_FILES reminder.
3668 2024-03-31  Bruno Haible  <bruno@clisp.org>
3670         quotearg: Improve documentation.
3671         * lib/quotearg.h: Refer to specification of $'...' syntax. Document a
3672         limitation of QA_ELIDE_OUTER_QUOTES.
3674 2024-03-31  Bruno Haible  <bruno@clisp.org>
3676         canonicalize[-lgpl] tests: Fix test failure on musl libc.
3677         Reported by Adept's Lab <adeptslab@gmail.com> via Pádraig Brady at
3678         <https://lists.gnu.org/archive/html/bug-coreutils/2024-03/msg00086.html>.
3679         * tests/test-canonicalize-lgpl.c (main): Don't special-case "//"
3680         handling for musl libc.
3681         * tests/test-canonicalize.c (main): Likewise.
3682         * modules/canonicalize-lgpl-tests (Files): Remove m4/musl.m4.
3683         (configure.ac): Don't invoke gl_MUSL_LIBC.
3685 2024-03-31  Collin Funk  <collin.funk1@gmail.com>
3687         gnulib-tool.py: Fix output of 'po/LINGUAS'.
3688         * pygnulib/GLImport.py (GLImport.execute): Only use PO files when
3689         determining the output for po/LINGUAS.
3691 2024-03-31  Collin Funk  <collin.funk1@gmail.com>
3693         gnulib-tool.py: Fix sorting of modules when --local-dir is used.
3694         * pygnulib/GLModuleSystem.py (GLModule.__eq__, GLModule.__ne__)
3695         (GLModule.__ge__, GLModule.__gt__, GLModule.__hash__, GLModule.__le__)
3696         (GLModule.__lt__): Use module names as identifiers instead of paths.
3698 2024-03-31  Bruno Haible  <bruno@clisp.org>
3700         gnulib-tool.py: Make a module's name immediately accessible.
3701         * pygnulib/GLModuleSystem.py (GLModuleSystem.find): Pass the module name
3702         to the GLModule constructor.
3703         (GLModule.__init__): Accept the module's name as argument and store it.
3704         (GLModule.getName): Simplify.
3706 2024-03-30  Collin Funk  <collin.funk1@gmail.com>
3708         gnulib-tool.py: Don't discard the 'dummy' module.
3709         * pygnulib/GLImport.py (GLImport.prepare): Don't set modules stored in
3710         the GLModuleTable until after the 'dummy' module is added.
3711         * pygnulib/GLModuleSystem.py (GLImport.setBaseModules)
3712         (GLImport.setFinalModules, GLImport.setMainModules)
3713         (GLImport.setTestsModules): Don't sort modules since the 'dummy' module
3714         should be placed last in the Makefiles.
3716 2024-03-30  Collin Funk  <collin.funk1@gmail.com>
3718         gnulib-tool.py: Fix reading of 'gl_VC_FILES' in gnulib-cache.m4.
3719         * pygnulib/GLImport.py (GLImport.__init__): Check for an empty string
3720         explicitly in conditional so False is not ignored.
3722 2024-03-30  Bruno Haible  <bruno@clisp.org>
3724         time_r tests: Avoid misleading skip message on native Windows.
3725         * tests/test-localtime_r.c (main): Use the macro FRENCH_TZ.
3726         * tests/test-localtime_r-mt.c (main): Likewise.
3728 2024-03-30  Paul Eggert  <eggert@cs.ucla.edu>
3730         time_r-tests: skip French tests if no Europe/Paris
3731         * tests/test-localtime_r.c (main):
3732         * tests/test-localtime_r-mt.c (main):
3733         If TZ='Europe/Paris' does not work, skip these tests.
3735 2024-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3737         intprops: pacify GCC < 10 -Wsign-compare
3738         Problem reported by Martin Dorey in:
3739         https://savannah.gnu.org/bugs/index.php?65537
3740         * lib/intprops-internal.h (_GL_INT_MULTIPLY_WRAPV):
3741         When working around GCC bug 91450, pacify -Wsign-compare by
3742         casting 0 to the result type.
3744 2024-03-29  Bruno Haible  <bruno@clisp.org>
3746         gnulib-tool: Use bold output on Linux, NetBSD, OpenBSD, OmniOS consoles.
3747         Reported by Pádraig Brady in
3748         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00399.html>.
3749         * gnulib-tool.sh (func_show_module_list): Use 'tput' to determine the
3750         "bold" capability of terminal types other than xterm*.
3751         * pygnulib/constants.py (get_terminfo_string, bold_escapes): New
3752         functions.
3753         * pygnulib/GLTestDir.py (GLTestDir.execute): Invoke
3754         constants.bold_escapes.
3755         * pygnulib/GLImport.py (GLImport.prepare): Likewise.
3757 2024-03-29  Collin Funk  <collin.funk1@gmail.com>
3759         gnulib-tool.py: Display specified modules in bold.
3760         * pygnulib/GLImport.py (GLImport.prepare): Detect terminals starting
3761         with 'xterm'. Change hexadecimal numbers to octal, matching
3762         gnulib-tool.sh.
3763         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
3765 2024-03-29  Bruno Haible  <bruno@clisp.org>
3767         attribute: Work around compiler bug of Oracle cc 12.6.
3768         * m4/gnulib-common.m4 (gl_COMMON_BODY): Expand _GL_ATTRIBUTE_PACKED to
3769         empty on SunPRO C.
3771 2024-03-29  Bruno Haible  <bruno@clisp.org>
3773         gnulib-tool.py: Don't print Makefile.am edits that are already done.
3774         * pygnulib/GLMakefileTable.py (GLMakefileTable): Improve comments.
3775         (GLMakefileTable.__getitem__): Do not clone the result.
3776         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am, tests_Makefile_am):
3777         Avoid a KeyError when testing for 'var'.
3778         Use 'del' to remove a dictionary entry.
3779         * pygnulib/GLImport.py (GLImport.execute): Avoid a KeyError when
3780         testing for 'var'. Simplify loop over makefiletable.
3782 2024-03-28  Bruno Haible  <bruno@clisp.org>
3784         fenv-exceptions-state-c99: Fix test failures with Oracle cc 12.6.
3785         * lib/fenv-except-state-set.c (mask387cw): New function.
3786         (fesetexceptflag): Use it on glibc.
3788 2024-03-28  Bruno Haible  <bruno@clisp.org>
3790         mcel tests: Fix test failure with Oracle cc 12.6.
3791         * tests/test-mcel.c (main): Explicitly return 0 at the end.
3793 2024-03-28  Bruno Haible  <bruno@clisp.org>
3795         gnulib-tool: Drop workarounds for Automake < 1.14.
3796         Reported by Collin Funk in
3797         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00384.html>.
3798         * gnulib-tool.sh (func_emit_lib_Makefile_am): Emit pkgdata_DATA
3799         initialization always.
3800         (func_emit_tests_Makefile_am): Likewise.
3801         (func_import): Don't emit 'AC_REQUIRE([AM_PROG_CC_C_O])' into
3802         gnulib-comp.m4.
3803         (func_create_testdir): Don't emit AM_PROG_CC_C_O into configure.ac.
3804         Bump required Automake version to 1.14.
3805         (func_create_megatestdir): Bump required Automake version to 1.14.
3806         * pygnulib/constants.py: Update comments.
3807         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Emit pkgdata_DATA
3808         initialization always. Don't return uses_subdirs.
3809         (GLEmiter.tests_Makefile_am): Likewise.
3810         * pygnulib/GLImport.py (GLImport.gnulib_comp): Don't emit
3811         'AC_REQUIRE([AM_PROG_CC_C_O])'.
3812         (GLImport.execute): Update.
3813         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't emit AM_PROG_CC_C_O
3814         into configure.ac. Bump required Automake version to 1.14.
3815         (GLMegaTestDir.execute): Bump required Automake version to 1.14.
3817 2024-03-28  Bruno Haible  <bruno@clisp.org>
3819         pthread-h: Fix override of pthread_spinlock_t with non-GNU compilers.
3820         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Define through AC_DEFUN_ONCE.
3821         Require gl_PTHREAD_H_DEFAULTS, not gl_PTHREAD_H.
3822         * m4/pthread_h.m4 (gl_PTHREAD_H): Invoke gl_PTHREAD_SPIN.
3823         * lib/pthread.in.h (pthread_spinlock_t,
3824         GNULIB_defined_pthread_spin_types): Don't define if
3825         HAVE_PTHREAD_SPIN_INIT && !REPLACE_PTHREAD_SPIN_INIT.
3826         * modules/pthread-h (Files): Add m4/pthread-spin.m4.
3828 2024-03-28  Bruno Haible  <bruno@clisp.org>
3830         havelib: Recognize ELF platform despite SunPRO C on Linux.
3831         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Recognize Linux as an ELF
3832         platform, even with the SunPRO C compiler that does not define __ELF__.
3834 2024-03-28  Collin Funk  <collin.funk1@gmail.com>
3836         gnulib-tool.py: Fix missing 'gnulib-cache.m4' in EXTRA_DIST.
3837         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Fix the loop
3838         condition so that it matches gnulib-tool.sh.
3840 2024-03-28  Collin Funk  <collin.funk1@gmail.com>
3842         gnulib-tool.py: Fix whitespace in gnulib-comp.m4.
3843         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Prefix each line with
3844         the indentation string instead of using regular expressions.
3846 2024-03-27  Collin Funk  <collin.funk1@gmail.com>
3848         gnulib-tool.py: Inline 'sed' invocations used on library files.
3849         * pygnulib/GLFileSystem.py (GLFileAssistant.__init__): Update type hints
3850         and docstrings to reflect changes necessary for using re.sub() instead
3851         of 'sed'.
3852         (GLFileAssistant.add_or_update): Use re.sub() instead of invoking 'sed'.
3853         * pygnulib/GLImport.py (GLImport.prepare): Update transformation
3854         variables to reflect changes to GLFileAssistant.
3856 2024-03-27  Bruno Haible  <bruno@clisp.org>
3858         obstack: Work around ICE with Oracle cc 12.6 (regr. 2023-12-01).
3859         * lib/obstack.in.h (__PTR_ALIGN): Use SMALL_PTRDIFF_T, instead of
3860         testing sizeof (ptrdiff_t) < sizeof (void *) at compile time.
3861         * m4/obstack.m4 (gl_FUNC_OBSTACK): Set SMALL_PTRDIFF_T.
3862         * modules/obstack (Makefile.am): Substitute SMALL_PTRDIFF_T.
3864 2024-03-27  Collin Funk  <collin.funk1@gmail.com>
3866         gnulib-tool.py: Add type hints to all functions.
3867         * pygnulib/*.py: Add type hints and remove duplicate function signatures
3868         from docstrings.
3870 2024-03-26  Collin Funk  <collin.funk1@gmail.com>
3872         gnulib-tool.py: Allow the use of both configure.ac and configure.in.
3873         * pygnulib/GLImport.py (GLImport.__init__): Remove redundant checks for
3874         configure.ac and configure.in.
3875         * pygnulib/main.py (main): Check for configure.ac and configure.in
3876         before reading it. Pass it to GLImport using the GLConfig object.
3878 2024-03-26  Bruno Haible  <bruno@clisp.org>
3880         gettime-res: Fix test failure on Solaris 11.4/SPARC.
3881         * lib/gettime-res.c (gettime_res): On Solaris/SPARC, just return 1 ns.
3883 2024-03-25  Bruno Haible  <bruno@clisp.org>
3885         jit/cache: Fix a compilation error on Solaris 11.4/SPARC.
3886         * lib/jit/cache.h: On Solaris, include <stddef.h>.
3888 2024-03-25  Bruno Haible  <bruno@clisp.org>
3890         gnulib-tool.py: Print "executing mkdir ..." messages.
3891         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
3892         Print a message before creating a 'build-aux' directory.
3894 2024-03-25  Bruno Haible  <bruno@clisp.org>
3896         gnulib-tool.py: Tweak last change.
3897         * pygnulib/GLImport.py (GLImport.execute): Recognize #if also at the
3898         beginning of an Include snippet.
3900 2024-03-25  Collin Funk  <collin.funk1@gmail.com>
3902         gnulib-tool.py: Fix output of #include directive advice.
3903         * pygnulib/GLImport.py (GLImport.execute): Copy comment from
3904         gnulib-tool.sh with modified variable names. Search the 'Include:' as a
3905         whole instead of each individual line.
3907 2024-03-25  Bruno Haible  <bruno@clisp.org>
3909         gnulib-tool.py: Simplify last change.
3910         * pygnulib/GLImport.py (GLImport.execute): Remove unnecessary list to
3911         set and set to list conversion.
3913 2024-03-25  Collin Funk  <collin.funk1@gmail.com>
3915         gnulib-tool.py: Fix "Creating directory" output.
3916         * pygnulib/GLImport.py (GLImport.execute): Reorder directories. Use
3917         os.path.join instead of joinpath to avoid path normalization.
3919 2024-03-25  Bruno Haible  <bruno@clisp.org>
3921         gnulib-tool.py: Tweak last change.
3922         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Rename some local
3923         variables. Use rstrip built-in function.
3925 2024-03-25  Collin Funk  <collin.funk1@gmail.com>
3927         gnulib-tool.py: Handle removed files in the vc ignore files.
3928         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Handle removed
3929         files. Check whether the original lines should be removed too.
3931 2024-03-24  Collin Funk  <collin.funk1@gmail.com>
3933         gnulib-tool.py: Fix filetable construction for ignorelist.
3934         * pygnulib/GLImport.py (GLImport.execute): Fix typo in dictionary key
3935         that overwrites removed files. Sort ignorelist by directory.
3937 2024-03-24  Bruno Haible  <bruno@clisp.org>
3939         gnulib-tool.py: Use Python raw strings for regular expressions.
3940         * pygnulib/*.py: Use raw string syntax for regular expression pattern
3941         strings and repl strings.
3943 2024-03-24  Bruno Haible  <bruno@clisp.org>
3945         gnulib-tool.py: Bring the output into the right order.
3946         * pygnulib/constants.py (force_output): New function.
3947         (execute): Flush stdout after printing the "executing ..." line.
3948         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
3949         Invoke force_output.
3950         * pygnulib/main.py (test, megatest): Likewise.
3952 2024-03-24  Bruno Haible  <bruno@clisp.org>
3954         nstrtime, c-nstrftime: Fix %c directive's result on glibc ≤ 2.30.
3955         * lib/strftime.c (__strftime_internal): On glibc ≤ 2.30, like on NetBSD
3956         and Solaris, remove the last word of the %c directive's result if it
3957         looks like a time zone.
3958         * doc/posix-functions/strftime.texi: Update platforms list.
3960 2024-03-24  Bruno Haible  <bruno@clisp.org>
3962         gnulib-tool.py: Fix output of notices.
3963         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't print notices if the
3964         verbosity is < -1. Strip newlines from each notice.
3965         * pygnulib/GLImport.py (GLImport.prepare): Don't print notices if the
3966         verbosity is < -1. Strip only newlines, not spaces.
3968 2024-03-23  Bruno Haible  <bruno@clisp.org>
3970         gnulib-tool.py: Fix the modules indentation in --create-testdir' output.
3971         * pygnulib/GLTestDir.py (GLTestDir.execute): Use specified_modules
3972         instead of self.config.getModules(), since the latter may be empty.
3974 2024-03-23  Bruno Haible  <bruno@clisp.org>
3976         gnulib-tool.sh: Use a default auxdir in --extract-automake-snippet.
3977         * gnulib-tool.sh (extract-automake-snippet): Set auxdir to 'build-aux'
3978         if it is not set.
3980 2024-03-23  Bruno Haible  <bruno@clisp.org>
3982         gnulib-tool.py: Don't unnecessarily sort an EXTRA_DIST augmentation.
3983         * pygnulib/GLModuleSystem.py
3984         (GLModule.getAutomakeSnippet_Unconditional): Don't remove duplicates or
3985         sort the filenames in the EXTRA_lib_SOURCES augmentation or the
3986         EXTRA_DIST augmentation for build-aux.
3988 2024-03-23  Collin Funk  <collin.funk1@gmail.com>
3990         gnulib-tool.py: Don't print Python bools in gnulib-cache.m4.
3991         * pygnulib/GLImport.py (GLImport.gnulib_cache): Convert Python bools to
3992         lowercase before printing.
3994 2024-03-23  Bruno Haible  <bruno@clisp.org>
3996         gnulib-tool.py: Don't unnecessarily run configure && make in testdirs.
3997         * pygnulib/GLTestDir.py (GLTestDir.execute): Correct the value of
3998         tests_distributed_built_sources.
4000 2024-03-23  Bruno Haible  <bruno@clisp.org>
4002         gnulib-tool.py: Fix autoconf snippets inclusion if --single-configure.
4003         * pygnulib/GLTestDir.py (GLTestDir.execute): Correct the arguments
4004         passed to autoconfSnippets.
4006 2024-03-23  Bruno Haible  <bruno@clisp.org>
4008         gnulib-tool.py: Produce same diagnostics regardless of Automake version.
4009         * pygnulib/GLTestDir.py (_patch_test_driver): Suppress the diagnostics
4010         from 'patch', and instead provide our own diagnostics.
4012 2024-03-23  Bruno Haible  <bruno@clisp.org>
4014         gnulib-tool.py: Print "executing touch config.h.in".
4015         * pygnulib/GLTestDir.py (GLTestDir.execute): Print
4016         "executing touch config.h.in", like gnulib-tool.sh does.
4018 2024-03-23  Bruno Haible  <bruno@clisp.org>
4020         gnulib-tool.py: Refactor.
4021         * pygnulib/GLImport.py (GLImport._done_dir_,
4022         GLImport._update_ignorelist_, GLImport.execute): Rename some variables.
4023         (GLImport._update_ignorelist_): Use constants.substart.
4025 2024-03-23  Collin Funk  <collin.funk1@gmail.com>
4027         gnulib-tool.py: Follow gnulib-tool changes, part 69.
4028         Follow gnulib-tool change
4029         2012-08-19  Bruno Haible  <bruno@clisp.org>
4030         gnulib-tool: Remove old file names from .cvsignore, .gitignore.
4031         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Add
4032         gnulib-comp.m4 to the added file list.
4033         (GLImport.execute): Remove unused variables. Use sets to match the
4034         'join' invocations in gnulib-tool.sh.
4036 2024-03-22  Collin Funk  <collin.funk1@gmail.com>
4038         gnulib-tool.py: Don't remove newlines in testdir's Automake snippets.
4039         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't strip newlines from
4040         Automake snippets.
4042 2024-03-22  Collin Funk  <collin.funk1@gmail.com>
4044         gnulib-tool.py: Fix empty newline output in test directories.
4045         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
4046         Match newlines printed by gnulib-tool.sh.
4048 2024-03-22  Collin Funk  <collin.funk1@gmail.com>
4050         gnulib-tool.py: Fix unconditional Automake snippets for non-tests.
4051         * pygnulib/GLModuleSystem.py
4052         (GLModule.getAutomakeSnippet_Unconditional): Fix the file lookups used
4053         to determine the EXTRA_DIST and EXTRA_lib_SOURCES Automake variables.
4054         Update comment to match gnulib-tool.sh.
4055         * pygnulib/constants.py (filter_filelist): Fix misleading return type in
4056         docstring. Return an empty string if no files were found.
4058 2024-03-22  Bruno Haible  <bruno@clisp.org>
4060         gnulib-tool.sh: Produce same diagnostics regardless of Automake version.
4061         * gnulib-tool.sh (func_create_testdir, func_create_megatestdir):
4062         Suppress the diagnostics from 'patch', and instead provide our own
4063         diagnostics.
4065 2024-03-22  Bruno Haible  <bruno@clisp.org>
4067         gnulib-tool: Remove test-driver.{orig,rej} if patching succeeded.
4068         * gnulib-tool.sh (func_create_testdir, func_create_megatestdir): After
4069         a 'patch' command failed, remove the leftover files test-driver.orig and
4070         test-driver.rej.
4071         * pygnulib/GLTestDir.py (_patch_test_driver): Likewise.
4073 2024-03-22  Bruno Haible  <bruno@clisp.org>
4075         gnulib-tool.py: Fix an error in --create-testdir.
4076         * pygnulib/GLTestDir.py (GLTestDir.execute): Fix chdir calls at the end.
4078 2024-03-21  Collin Funk  <collin.funk1@gmail.com>
4080         gnulib-tool.sh: Avoid a redundant space in gl_AVOID in gnulib-cache.m4.
4081         * gnulib-tool.sh (avoidlist): Don't add a space before the first module
4082         name.
4084 2024-03-21  Collin Funk  <collin.funk1@gmail.com>
4086         gnulib-tool.py: Fix --extract-recursive-link-directive.
4087         * pygnulib/GLModuleSystem.py (GLModule.getLinkDirectiveRecursively):
4088         Check the 'Link:' section of each individual module. Use sets instead of
4089         lists to remove duplicates.
4091 2024-03-21  Collin Funk  <collin.funk1@gmail.com>
4093         gnulib-tool.py: Make --extract-filelist match gnulib-tool.sh.
4094         * pygnulib/GLModuleSystem.py (GLModule.getFiles_Raw): New function which
4095         returns the 'Files:' section from a module unchanged.
4096         (GLModule.getFiles): Use it.
4097         * pygnulib/main.py (main): Use it and match the output of gnulib-tool.sh
4098         for --extract-filelist.
4100 2024-03-21  Bruno Haible  <bruno@clisp.org>
4102         gnulib-tool: Make the .gitignore files handling more consistent.
4103         * gnulib-tool.sh (func_done_dir): Ignore the presence or absence of a
4104         .git directory if there is a .gitignore file in the same place.
4105         * pygnulib/GLImport.py (GLImport._done_dir_): Likewise.
4107 2024-03-20  Bruno Haible  <bruno@clisp.org>
4109         gnulib-tool.sh: Undocument the --[no-]cache-modules options.
4110         Reported by Collin Funk in
4111         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00234.html>.
4112         Rationale:
4113         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00243.html>.
4114         * gnulib-tool.sh (func_usage): Don't mention --cache-modules,
4115         --no-cache-modules.
4117 2024-03-20  Collin Funk  <collin.funk1@gmail.com>
4119         gnulib-tool.py: Don't print empty Automake snippets.
4120         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
4121         (GLEmiter.tests_Makefile_am): Handle empty strings when checking if the
4122         snippet should be printed.
4124 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
4126         gnulib-tool.py: Follow gnulib-tool changes, part 68.
4127         Follow gnulib-tool change
4128         2022-07-31  Akim Demaille  <akim@lrde.epita.fr>
4129         gnulib-tool: add support for --automake-subdir-tests
4130         * pygnulib/main.py (main): Add support for --automake-subdir-tests.
4131         * pygnulib/GLInfo.py (GLInfo.usage): Add --automake-subdir-tests to the
4132         help message.
4133         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'automake_subdir_tests'
4134         to the parameter list. Initialize it.
4135         (GLConfig.default): Default --automake-subdir-tests to False.
4136         (GLConfig.resetAutomakeSubdir): Fix misleading docstring.
4137         (GLConfig.getAutomakeSubdirTests, GLConfig.setAutomakeSubdirTests)
4138         (GLConfig.resetAutomakeSubdirTests): New functions to manipulate and
4139         access whether --automake-subdir-tests is in use.
4140         * pygnulib/GLEmiter.py (GLEmiter.shellvars_init)
4141         (GLEmiter.initmacro_end): Use sourcebase when handling tests and
4142         --automake-subdir-tests is given.
4143         * pygnulib/GLError.py (GLError.__repr__): Update error message to
4144         include --automake-subdir-tests.
4145         * pygnulib/GLImport.py (GLImport.__init__): Check for the
4146         'subdir-objects' Automake option when --automake-subdir-tests is in use.
4147         (GLImport.actioncmd): Add --automake-subdir-tests to the actioncmd
4148         printed in generated files.
4150 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
4152         gnulib-tool.py: Fix incorrect assignment operator.
4153         * pygnulib/GLImport.py (GLImport.actioncmd): Use '+=' instead of '=' to
4154         append the string to the actioncmd instead of overwriting it.
4156 2024-03-19  Bruno Haible  <bruno@clisp.org>
4158         gnulib-tool: Make it work in the test suite.
4159         * gnulib-tool.sh (gnulib_dir): Make absolute.
4160         (func_create_megatestdir): If .git/refs/heads/master does not exist, use
4161         ChangeLog instead.
4162         * pygnulib/main.py (main): Make gnulib_dir absolute.
4163         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): If
4164         .git/refs/heads/master does not exist, use ChangeLog instead.
4166 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
4168         gnulib-tool.py: Make sure temporary files are removed.
4169         * pygnulib/GLImport.py (GLImport.execute): Fix nesting of statement so
4170         that both temporary files are removed.
4172 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
4174         gnulib-tool.py: Follow gnulib-tool changes, part 67.
4175         Follow gnulib-tool change
4176         2022-03-01  Paul Eggert  <eggert@cs.ucla.edu>
4177         Create lib/Makefile.am after gnulib-comp.m4
4178         * pygnulib/GLImport.py (GLImport.execute): Create library makefile after
4179         creating gnulib-comp.m4.
4181 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
4183         gnulib-tool.py: Follow gnulib-tool changes, part 66.
4184         Follow gnulib-tool change
4185         2021-12-25  Bruno Haible  <bruno@clisp.org>
4186         gnulib-tool: Fix handling of module libtextstyle-optional.
4187         * pygnulib/GLModuleSystem.py (GLModule.repeatModuleInTests): New function.
4188         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Use it for creating
4189         the tests/Makefile.am.
4190         * pygnulib/GLTestDir.py (GLTestDir.execute): Use it when creating the
4191         file list.
4193 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
4195         gnulib-tool.py: Follow gnulib-tool changes, part 65.
4196         Follow gnulib-tool change
4197         2021-12-19  Bruno Haible  <bruno@clisp.org>
4198         gnulib-tool: Don't insist on ACLOCAL_AMFLAGS.
4199         * pygnulib/GLImport.py (GLImport.execute): Don't add extra '-I' before
4200         m4 directory in ACLOCAL_AMFLAGS. Prefer '0' instead of 'int()'. Mention
4201         the use of AC_CONFIG_MACRO_DIRS in configure.ac as an alternative to
4202         augmenting ACLOCAL_AMFLAGS.
4203         * pygnulib/main.py (main): To find the m4 directories, look also for
4204         AC_CONFIG_MACRO_DIR and AC_CONFIG_MACRO_DIRS invocations in
4205         configure.ac. Remove unnecessary call to 'joinpath' since it accepts a
4206         variable length of arguments.
4208 2024-03-18  Bruno Haible  <bruno@clisp.org>
4210         gnulib-tool.py: Tweak last change.
4211         * pygnulib/GLModuleSystem.py (GLModule.isTests, GLModule.isNonTests):
4212         Update comments.
4214 2024-03-18  Collin Funk  <collin.funk1@gmail.com>
4216         gnulib-tool.py: Follow gnulib-tool changes, part 64.
4217         Follow gnulib-tool change
4218         2021-12-25  Bruno Haible  <bruno@clisp.org>
4219         gnulib-tool: Respect applicability 'all' without --single-configure.
4220         * pygnulib/GLModuleSystem.py (GLModule.isTests): Treat modules with
4221         applicability 'all' like 'tests' modules, not like 'main' modules.
4222         (GLModule.isNonTests): Treat all modules not ending in '-tests' as
4223         non-test modules.
4224         (GLModule.getApplicability): Don't use GLModule.isTests(). Because it
4225         depends on the result of this function, using it would cause a
4226         RecursionError exception.
4227         (GLModule.getDependencies): Respect the difference between
4228         module.isTests(), module.isNonTests(), and
4229         module.getName().endswith('-tests').
4230         (GLModule.getAutomakeSnippet_Unconditional, GLModule.getLicense)
4231         (GLModuleTable.add_dummy): Likewise.
4232         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Likewise.
4234 2024-03-17  Bruno Haible  <bruno@clisp.org>
4236         gnulib-tool.py: Handle empty lists of lines consistently.
4237         * pygnulib/constants.py (lines_to_multiline): New function.
4238         (nlremove): Remove unused function.
4239         * pygnulib/GLEmiter.py (_eliminate_NMD): Use lines_to_multiline instead
4240         of the '\n'.join idiom.
4241         (GLEmiter.autoconfSnippet, GLEmiter.autoconfSnippets,
4242         GLEmiter.lib_Makefile_am): Likewise.
4243         * pygnulib/GLImport.py (GLImport._update_ignorelist_, GLImport.execute):
4244         Likewise.
4245         * pygnulib/GLModuleSystem.py (GLModule.getDependenciesRecursively,
4246         GLModule.getLinkDirectiveRecursively, GLModuleTable.remove_if_blocks):
4247         Likewise.
4248         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
4249         * pygnulib/main.py (main): Likewise.
4251 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
4253         gnulib-tool.py: Follow gnulib-tool changes, part 63.
4254         Follow gnulib-tool change
4255         2020-12-28  Bruno Haible  <bruno@clisp.org>
4256         gnulib-tool: Fix logic whether to add a dummy.c.
4257         * pygnulib/GLModuleSystem.py (GLModuleTable.remove_if_blocks): New
4258         function.
4259         (GLModuleTable.add_dummy): Use it to eliminate all conditional
4260         statements from the automake snippet.
4262 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
4264         gnulib-tool.py: Don't print extra newlines.
4265         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Don't print extra
4266         newline that are not printed by gnulib-tool.sh.
4268 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
4270         gnulib-tool.py: Follow gnulib-tool changes, part 62.
4271         Follow gnulib-tool change
4272         2020-02-22  Bruno Haible  <bruno@clisp.org>
4273         gnulib-tool: Ensure copied files are writable.
4274         * pygnulib/constants.py (ensure_writable): New function. Make sure files
4275         are writable.
4276         (symlink_relative, hardlink): Use it.
4277         * pygnulib/GLFileSystem.py (GLFileSystem.lookup)
4278         (GLFileAssistant.add_or_update): Likewise.
4279         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
4280         * pygnulib/main.py (main): Likewise.
4282 2024-03-17  Bruno Haible  <bruno@clisp.org>
4284         gnulib-tool: Add undocumented option --gnulib-dir.
4285         * gnulib-tool.sh: Accept --gnulib-dir=... option.
4286         * pygnulib/constants.py (init_DIRS): New function.
4287         * pygnulib/main.py (main): Accept --gnulib-dir=... option. Invoke
4288         init_DIRS. Expect .git directory to be present in DIRS['root'], not
4289         APP['root'].
4290         * pygnulib/GLImport.py (GLImport.execute): Use DIRS['root'], not
4291         APP['root'].
4293 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
4295         gnulib-tool.py: Follow gnulib-tool changes, part 61.
4296         Follow gnulib-tool change
4297         2022-01-09  Bruno Haible  <bruno@clisp.org>
4298         Remove influence of Automake conditionals on conditional dependencies.
4299         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Don't
4300         inhibit conditional dependencies processing on a module that uses an
4301         Automake conditional.
4303 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
4305         gnulib-tool.py: Follow gnulib-tool changes, part 60.
4306         Follow gnulib-tool change
4307         2019-11-18  Bruno Haible  <bruno@clisp.org>
4308         gnulib-tool: Fix build error on macOS with --conditional-dependencies.
4309         * pygnulib/GLModuleSystem.py (GLModuleTable.add_dummy): Ignore modules
4310         that are conditionally enabled.
4312 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
4314         gnulib-tool.py: Don't try to remove files that don't exist.
4315         * pygnulib/GLFileSystem.py (GLFileSystem.add_or_update): Check if the
4316         temporary file exists before trying to remove it.
4318 2024-03-16  Paul Eggert  <eggert@cs.ucla.edu>
4320         renameatu: support RENAME_EXCHANGE on macOS
4321         * lib/renameatu.c (renameat2ish, renameatu) [RENAME_SWAP]:
4322         Use macOS RENAME_SWAP to implement GNU/Linux RENAME_EXCHANGE.
4323         * tests/test-renameatu.c (main): Add a test for RENAME_EXCHANGE.
4325 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
4327         gnulib-tool.py: Follow gnulib-tool changes, part 59.
4328         Follow gnulib-tool change
4329         2017-10-29  Bruno Haible  <bruno@clisp.org>
4330         gnulib-tool: Avoid unnecessary config.h.in remaking in testdirs.
4331         * pygnulib/GLTestDir.py (GLTestDir.execute): Touch the 'config.h.in'
4332         file after executing 'autoheader' to update it's timestamps.
4334 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
4336         gnulib-tool.py: Fix 'git update-index' call when using hard links.
4337         * pygnulib/main.py: Fix conditional used to check whether 'git
4338         update-index' should be called. Only catch FileNotFoundError exceptions
4339         thrown when no 'git' program exists.
4341 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
4343         gnulib-tool.py: Coding style: Avoid not().
4344         * pygnulib/GLModuleSystem.py (isNonTests): Avoid not(). Write
4345         'not condition' instead of 'not(condition)'.
4347 2024-03-16  Bruno Haible  <bruno@clisp.org>
4349         gnulib-tool.py: Coding style: Avoid bool().
4350         * pygnulib/GLModuleSystem.py (GLModule): Write False instead of bool().
4352 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
4354         gnulib-tool.py: Follow gnulib-tool changes, part 58.
4355         Follow gnulib-tool change
4356         2017-05-21  Bruno Haible  <bruno@clisp.org>
4357         gnulib-tool: Add options to create hard links.
4358         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'copymode' and
4359         'lcopymode' to the parameter list. Initialize them.
4360         (GLConfig.default): Don't use symbolic or hard links by default.
4361         (GLConfig.checkCopyMode, GLConfig.setCopyMode, GLConfig.resetCopyMode):
4362         New functions to modify and check the method for copying non --local-dir
4363         files.
4364         (GLConfig.checkLCopyMode, GLConfig.setLCopyMode)
4365         (GLConfig.resetLCopyMode): New functions to modify and check the method
4366         for copying --local-dir files.
4367         (GLConfig.checkSymbolic, GLConfig.resetSymbolic, GLConfig.setSymbolic)
4368         (GLConfig.checkLSymbolic, GLConfig.resetLSymbolic)
4369         (GLConfig.setLSymbolic): Remove unused functions. The functionality of
4370         these are now implemented in the *CopyMode() and *LCopyMode() variants.
4371         * pygnulib/GLFileSystem.py (CopyAction.Hardlink): New Enum value to
4372         describe hard links.
4373         (GLFileSystem.shouldLink): Check if hard links should be used.
4374         (GLFileAssistant.add, GLFileAssistant.update): Try to hard link if
4375         enabled. Copy the file if linking fails.
4376         (GLFileAssistant.add_or_update): Remove temporary files unconditionally.
4377         * pygnulib/GLInfo.py (GLInfo.usage): Document new options in the usage
4378         message.
4379         * pygnulib/GLTestDir.py (GLTestDir.execute): Try to hard link if
4380         enabled. Copy the file if linking fails.
4381         * pygnulib/classes.py: Importy the CopyAction Enum.
4382         * pygnulib/constants.py (hardlink): New function based on
4383         symlink_relative.
4384         * pygnulib/main.py (main): Add new options --hardlink and
4385         --local-hardlink. Invoke 'git update-index --refresh' to mitigate the
4386         effects of the hard links on git.
4388 2024-03-16  Bruno Haible  <bruno@clisp.org>
4390         gnulib-tool.sh: Make --local-dir options in gnulib-cache.m4 look nicer.
4391         * gnulib-tool.sh (func_import): Append the --local-dir=... options
4392         through func_append_actionarg.
4394 2024-03-16  Bruno Haible  <bruno@clisp.org>
4396         gnulib-tool.py: Don't lose the gl_LGPL value from gnulib-cache.m4.
4397         Reported by Simon Josefsson in
4398         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00152.html>.
4399         * pygnulib/GLConfig.py (GLConfig.default): For the 'lgpl' property,
4400         return None, not False.
4402 2024-03-15  Bruno Haible  <bruno@clisp.org>
4404         gnulib-tool.py: Don't lose the gl_LOCAL_DIR value from gnulib-cache.m4.
4405         Reported by Simon Josefsson in
4406         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00152.html>.
4407         * pygnulib/GLConfig.py (GLConfig.default): For the 'localpath' property,
4408         return [], not ''.
4410 2024-03-15  Bruno Haible  <bruno@clisp.org>
4412         gnulib-tool: Enhance last patch.
4413         * gnulib-tool: If gnulib-tool.sh failed but gnulib-tool.py succeeded,
4414         report that and don't erase the outputs and log files.
4416 2024-03-14  Collin Funk  <collin.funk1@gmail.com>
4418         gnulib-tool.py: Follow gnulib-tool changes, part 57.
4419         Follow gnulib-tool change
4420         2019-01-04  Bruno Haible  <bruno@clisp.org>
4421         gnulib-tool: New option --extract-recursive-link-directive.
4422         * pygnulib/GLModuleSystem.py (GLModule.getDependenciesRecursively): New
4423         function. Implements the --extract-recursive-dependencies option.
4424         (GLModule.getLinkDirectiveRecursively): New function. Implements the
4425         --extract-recursive-link-directive.
4426         * pygnulib/main.py (main): Add the --extract-recursive-dependencies and
4427         --extract-recursive-link-directive options.
4428         * pygnulib/GLInfo.py (GLInfo.usage): Add new options to help message.
4430 2024-03-14  Bruno Haible  <bruno@clisp.org>
4432         gnulib-tool: Obey environment variable GNULIB_TOOL_IMPL.
4433         * gnulib-tool.sh: Renamed from gnulib-tool.
4434         * gnulib-tool: New file, based on gnulib-tool.sh.
4435         * gnulib-tool.py: Check the Python version.
4437 2024-03-14  Collin Funk  <collin.funk1@gmail.com>
4439         gnulib-tool.py: Fix write failure due to bad sourcebase.
4440         * pygnulib/constants.py (cleaner): Only call strip() on string objects.
4441         * pygnulib/main.py (main): Fix parsing of AMLOCAL_AMFLAGS from
4442         Makefile.am. Add some comments from gnulib-tool.
4444 2024-03-13  Bruno Haible  <bruno@clisp.org>
4446         sig2str tests: Refactor.
4447         * tests/test-sig2str.c (test_sig2str, test_str2sig): New functions,
4448         extracted from main.
4449         (main): Invoke them.
4451 2024-03-13  Collin Funk  <collin.funk1@gmail.com>
4453         sig2str: Add tests.
4454         * tests/test-sig2str.c: New file.
4455         * modules/sig2str-tests: New file.
4457 2024-03-12  Collin Funk  <collin.funk1@gmail.com>
4459         gnulib-tool.py: Follow gnulib-tool changes, part 56.
4460         Follow gnulib-tool change
4461         2021-04-26  Paul Eggert  <eggert@cs.ucla.edu>
4462         gnulib-tool: port better to current Autoconf
4463         * pygnulib/GLImport.py (GLImport.execute): Remove exit() call before
4464         printing reminders. Suggest replacing AC_PROG_CC_STDC and
4465         AC_PROG_CC_C99, as per current Autoconf.
4467 2024-03-12  Collin Funk  <collin.funk1@gmail.com>
4469         gnulib-tool.py: Fix last commit.
4470         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Silence Python
4471         warnings about invalid escape. Make sure to escape the backslash
4472         character we want to print.
4474 2024-03-12  Collin Funk  <collin.funk1@gmail.com>
4476         gnulib-tool.py: Follow gnulib-tool changes, part 55.
4477         Follow gnulib-tool changes
4478         2022-01-05  Bruno Haible  <bruno@clisp.org>
4479         gnulib-tool: Avoid known warnings that reflect Gnulib's coding style.
4480         2022-01-08  Bruno Haible  <bruno@clisp.org>
4481         gnulib-tool: Remove all *.Po files upon distclean (regr. 2022-01-05).
4482         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Collect the *.Po or
4483         *.Plo files to remove into an AC_SUBSTed variable gl_LIBOBJDEPS. Use
4484         Python f-strings instead of string replacements.
4485         (GLEmiter.lib_Makefile_am): Add the GL_CFLAG_GNULIB_WARNINGS to the
4486         CFLAGS of all the compilation units of the library. Extend the distclean
4487         and maintainer-clean rules.
4488         (GLEmiter.tests_Makefile_am): Add the GL_CFLAG_GNULIB_WARNINGS to the
4489         CFLAGS.
4490         * pygnulib/GLImport.py (GLImport.gnulib_comp): Emit an invocation of
4491         gl_CC_GNULIB_WARNINGS.
4493 2024-03-11  Collin Funk  <collin.funk1@gmail.com>
4495         gnulib-tool.py: Follow gnulib-tool changes, part 54.
4496         Follow gnulib-tool change
4497         2021-12-24  Paul Eggert  <eggert@cs.ucla.edu>
4498         maint: avoid empty lines in recipes
4499         * pygnulib/GLEmiter.py (_eliminate_NMD_from_line): Eliminate occurrences
4500         of @!NMD@ too. Document parameters in docstring.
4501         (_eliminate_NMD): Update docstring to reflect changes. Document
4502         parameters.
4504 2024-03-11  Bruno Haible  <bruno@clisp.org>
4506         gnulib-tool.py: Tweak last commit.
4507         * pygnulib/GLEmiter.py (_eliminate_NMD): Don't add an extra newline when
4508         the result should be empty.
4510 2024-03-11  Collin Funk  <collin.funk1@gmail.com>
4512         gnulib-tool.py: Follow gnulib-tool changes, part 53.
4513         Follow gnulib-tool change
4514         2021-12-21  Bruno Haible  <bruno@clisp.org>
4515         Optimize redundant 'mkdir -p .' invocations.
4516         * pygnulib/GLEmiter.py (_eliminate_NMD_from_line): New private function
4517         to remove @NMD@ occurrences from the line of an Automake snippet.
4518         (_eliminate_NMD): New private function which uses
4519         _eliminate_NMD_from_line on each line of the Automake snippet.
4520         (GLEmiter.lib_Makefile_am, GLEmiter.tests_Makefile_am): Use
4521         _eliminate_NMD on the Automake snippet.
4523 2024-03-11  Bruno Haible  <bruno@clisp.org>
4525         gnulib-tool.py: Make some code more straightforward.
4526         * pygnulib/GLImport.py (GLImport.__init__): Reorder assignments and
4527         conditions slightly.
4529 2024-03-11  Collin Funk  <collin.funk1@gmail.com>
4531         gnulib-tool.py: Follow gnulib-tool changes, part 52.
4532         Follow gnulib-tool change
4533         2021-12-15  Bruno Haible  <bruno@clisp.org>
4534         automake-subdir support: Look for 'subdir-objects' also in configure.ac.
4535         * pygnulib/GLImport.py (GLImport.__init__): Check for 'subdir-objects'
4536         in the AM_INIT_AUTOMAKE macro of configure.ac.
4538 2024-03-10  Bruno Haible  <bruno@clisp.org>
4540         gnulib-tool.py: Tweak last commit.
4541         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Avoid an implicit str
4542         to bool conversion.
4543         * pygnulib/GLImport.py (GLImport.__init__): Add a comment. Don't allow
4544         a '|' in place of whitespace. Don't emit redundant gl_source_base
4545         assignments.
4547 2024-03-10  Collin Funk  <collin.funk1@gmail.com>
4549         gnulib-tool.py: Follow gnulib-tool changes, part 51.
4550         Follow gnulib-tool change
4551         2021-12-15  Bruno Haible  <bruno@clisp.org>
4552         Accommodate non-recursive Automake in a less hacky way.
4553         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'automake_subdir' to the
4554         parameter list.
4555         (GLConfig.default): Set the default value of automake_subdir to a
4556         boolean False.
4557         (GLConfig.getAutomakeSubdir, GLConfig.setAutomakeSubdir)
4558         (GLConfig.resetAutomakeSubdir): New functions to access and manipulate
4559         the automake_subdir option.
4560         * pygnulib/GLEmiter.py (GLEmiter.shellvars_init): New function.
4561         (GLEmiter.initmacro_end): Add second parameter 'gentests'. Use it to prefix each
4562         object file name in *_LIBOBJS and *_LTLIBOBJS.
4563         * pygnulib/GLError.py (GLError.__init__, GLError.__repr__): Add new
4564         error for if --automake-subdir is used without the 'subdir-objects'
4565         Automake option.
4566         * pygnulib/GLImport.py (GLImport.__init__): Check for 'subdir-objects'
4567         in Makefile.am.
4568         (GLImport.actioncmd): Emit --automake-subdir in actioncmd.
4569         (GLImport.gnulib_cache): Add gl_AUTOMAKE_SUBDIR to gnulib-cache.m4 if
4570         --automake-subdir is used.
4571         (GLImport.gnulib_comp): Update calls to GLEmiter.initmacro_end. Call
4572         GLEmiter.shellvars_init.
4573         (GLImport.execute): Likewise. Use the build-aux/prefix-gnulib-mk script.
4574         * pygnulib/GLInfo.py (GLInfo.usage): Add --automake-subdir to the usage
4575         message.
4576         * pygnulib/GLTestDir.py (GLTestDir.execute): Update calls to
4577         GLEmiter.initmacro_end. Call GLEmiter.shellvars_init.
4578         * pygnulib/main.py (main): Add support for --automake-subdir.
4580 2024-03-10  Collin Funk  <collin.funk1@gmail.com>
4582         gnulib-tool: Don't remove comments referencing @NMD@, part 2.
4583         * gnulib-tool (func_emit_tests_Makefile_am): Replace lines that start
4584         with @NMD@ or @!NMD@ instead of lines that contain them.
4586 2024-03-10  Bruno Haible  <bruno@clisp.org>
4588         gnulib-tool.py: One more comment regarding coding style.
4589         * pygnulib/main.py: Add comment regarding conditional expressions.
4591 2024-03-09  Collin Funk  <collin.funk1@gmail.com>
4593         gnulib-tool.py: Follow gnulib-tool changes, part 50.
4594         Follow gnulib-tool changes
4595         2021-12-12  Bruno Haible  <bruno@clisp.org>
4596         gnulib-tool: Try to support non-recursive-gnulib-prefix-hack with tests.
4597         2021-12-13  Bruno Haible  <bruno@clisp.org>
4598         gnulib-tool: Fix mistake in last commit.
4599         * pygnulib/GLImport.py (GLImport.gnulib_comp): Expect the filetable as a
4600         parameter instead of a list of all files. Add type checks. Invoke
4601         AC_CONFIG_LIBOBJ_DIR based on the location of alloca.c.
4602         (GLImport.execute): Adjust call to GLImport.gnulib_comp to reflect
4603         parameter changes.
4605 2024-03-09  Collin Funk  <collin.funk1@gmail.com>
4607         gnulib-tool.py: Follow gnulib-tool changes, part 49.
4608         Follow gnulib-tool change
4609         2021-08-07  Bruno Haible  <bruno@clisp.org>
4610         gnulib-tool: Add support for Automake 1.16.4.
4611         * pygnulib/GLTestDir.py (_patch_test_driver): If patching
4612         build-aux/test-driver fails with build-aux/test-driver.diff try again
4613         with build-aux/test-driver-1.16.3.diff.
4615 2024-03-09  Bruno Haible  <bruno@clisp.org>
4617         unistr/u16-to-u32: Relicense under LGPLv2+.
4618         * modules/unistr/u16-to-u32 (License): Change to LGPLv2+.
4619         * lib/unistr/u16-to-u32.c: Update license notice.
4621         unistr/u16-mbtoucr: Relicense under LGPLv2+.
4622         * modules/unistr/u16-mbtoucr (License): Change to LGPLv2+.
4623         * lib/unistr/u16-mbtoucr.c: Update license notice.
4625         unistr/u16-strlen: Relicense under LGPLv2+.
4626         * modules/unistr/u16-strlen (License): Change to LGPLv2+.
4627         * lib/unistr/u16-strlen.c: Update license notice.
4629 2024-03-09  Bruno Haible  <bruno@clisp.org>
4631         parse-datetime: Simplify.
4632         * modules/parse-datetime (Makefile.am): Don't generate
4633         parse-datetime-gen.h.
4635 2024-03-09  Bruno Haible  <bruno@clisp.org>
4637         parse-datetime: Simplify.
4638         * lib/parse-datetime.y (yyerror): Change return type to 'void'.
4640 2024-03-09  Collin Funk  <collin.funk1@gmail.com>
4642         gnulib-tool.py: Follow gnulib-tool changes, part 48.
4643         Follow gnulib-tool change
4644         2019-01-23  Bruno Haible  <bruno@clisp.org>
4645         gnulib-tool: Support running testdirs on Android.
4646         * pygnulib/GLError.py (GLError.__init__, GLError.__repr__): Add errno 20
4647         to print an error if patching build-aux/test-driver fails.
4648         * pygnulib/main.py (main): Likewise.
4649         * pygnulib/GLTestDir.py (_patch_test_driver): New private function which
4650         runs patch on build-aux/test-driver with build-aux/test-driver.diff.
4651         (GLTestDir.execute, GLMegaTestDir.execute): Check for
4652         build-aux/test-driver in each testdir and patch it after running
4653         automake.
4655 2024-03-08  Collin Funk  <collin.funk1@gmail.com>
4657         gnulib-tool: Don't remove comments referencing @NMD@.
4658         * gnulib-tool (func_emit_lib_Makefile_am): Replace lines that start with
4659         @NMD@ or @!NMD@ instead of lines that contain them.
4661 2024-03-08  Collin Funk  <collin.funk1@gmail.com>
4663         gnulib-tool.py: Follow gnulib-tool changes, part 47.
4664         Follow gnulib-tool changes
4665         2021-12-15  Bruno Haible  <bruno@clisp.org>
4666         Fix creation of build directories with non-recursive-gnulib-prefix-hack.
4667         2021-12-18  Bruno Haible  <bruno@clisp.org>
4668         Fix support for --gnu-make in tests (regression 2021-12-15).
4669         * pygnulib/GLEmiter.py (_CONVERT_TO_GNU_MAKE): New variable which is a
4670         list of tuples which are used with re.sub.
4671         (_convert_to_gnu_make): New function which converts an input snippet
4672         from Automake to GNU Make syntax using the regular expressions stored in
4673         _CONVERT_TO_GNU_MAKE.
4674         (GLEmiter.lib_Makefile_am): Use _convert_to_gnu_make. Replace '%reldir%'
4675         tokens.
4676         (GLEmiter.tests_Makefile_am): Likewise.
4678 2024-03-07  Collin Funk  <collin.funk1@gmail.com>
4680         gnulib-tool.py: Fix errors when executing --create-megatestdir.
4681         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Create a testdir for
4682         each module in its own subdirectory. Create a testdir with all modules
4683         in 'ALL'. Add missing join call on str object. Don't emit 'configure.ac'
4684         into 'Makefile.am'. Make sure commands are executed in the proper
4685         directory.
4687 2024-03-07  Collin Funk  <collin.funk1@gmail.com>
4689         gnulib-tool.py: Follow gnulib-tool changes, part 46.
4690         Follow gnulib-tool change
4691         2022-02-22  Simon Josefsson  <simon@josefsson.org>
4692         gnulib-tool: Bump automake dependency.
4693         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
4694         (GLEmiter.tests_Makefile_am): Require Automake >= 1.14, for %reldir%
4695         support.
4697 2024-03-07  Collin Funk  <collin.funk1@gmail.com>
4699         gnulib-tool.py: Follow gnulib-tool changes, part 45.
4700         Follow gnulib-tool changes
4701         2021-12-12  Bruno Haible  <bruno@clisp.org>
4702         gnulib-tool: Support different basenames for the lib/,tests/ Makefiles.
4703         2022-01-08  Bruno Haible  <bruno@clisp.org>
4704         gnulib-tool: Fix "Don't forget" messages (regression 2021-12-12).
4705         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'tests_makefile_name'
4706         argument.
4707         (GLConfig.getMakefileName, GLConfig.setMakefileName)
4708         (GLConfig.resetMakefileName): Remove references to tests Makefile.am in
4709         doc strings.
4710         (GLConfig.getTestsMakefileNamem, GLConfig.setTestsMakefileName)
4711         (GLConfig.resetTestsMakefileName): New methods used to access value
4712         passed with the '--tests-makefile-name' option.
4713         * pygnulib/GLImport.py (GLImport.__init__): Check for
4714         'gl_TESTS_MAKEFILE_NAME' in cache.
4715         (GLImport.actioncmd): Output --tests-makefile-name when describing
4716         gnulib-tool invocation.
4717         (GLImport.gnulib_cache): Output 'gl_TESTS_MAKEFILE_NAME' to cache.
4718         (GLImport.execute): Use two local variables, source_makefile_am and
4719         tests_makefile_am, which are passed to gnulib-tool.py or given default
4720         values.
4721         * pygnulib/GLInfo.py (GLInfo.usage): Add '--tests-makefile-name' to
4722         usage message.
4723         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Reduce code
4724         duplication by expecting Makefile names passed as arguments.
4725         * pygnulib/main.py (main): Add support for '--tests-makefile-name'.
4727 2024-03-06  Bruno Haible  <bruno@clisp.org>
4729         gnulib-tool: Search for a working 'join' program.
4730         Reported by Reuben Thomas <rrt@sc3d.org> in
4731         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00044.html>.
4732         * gnulib-tool (JOIN): New variable. Use it everywhere instead of 'join'.
4734 2024-03-06  Bruno Haible  <bruno@clisp.org>
4736         c-strtof, c-strtod, c-strtold: Comment.
4737         * lib/c-strtod.c: Mention me as co-author.
4739 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
4741         gnulib-tool.py: Fix value of LDADD for libtests.
4742         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Fix value of LDADD
4743         to match gnulib-tool.
4745 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
4747         gnulib-tool.py: Follow gnulib-tool changes, part 44.
4748         Follow gnulib-tool changes
4749         2021-06-10  Bruno Haible  <bruno@clisp.org>
4750         Clarify where to report test failures from Gnulib tests.
4751         2021-06-11  Bruno Haible  <bruno@clisp.org>
4752         Make message in last commit more precise.
4753         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Emit a dependency
4754         of 'check-am' on 'check-notice' that prints a notice describing where to
4755         report test failures.
4757 2024-03-06  Bruno Haible  <bruno@clisp.org>
4759         gnulib-tool.py: Tweak comment location.
4760         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Move a comment.
4762 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
4764         gnulib-tool.py: Follow gnulib-tool changes, part 43.
4765         Follow gnulib-tool change
4766         2021-06-10  Bruno Haible  <bruno@clisp.org>
4767         Clarify that compiler warnings in the Gnulib tests can be ignored.
4768         * pygnulib/GLEmiter.py (GLEmiter.initmacro_start): Add boolean argument
4769         to control whether gl_CC_ALLOW_WARNINGS and gl_CXX_ALLOW_WARNINGS should
4770         be required.
4771         (GLEmiter.tests_Makefile_am): Emit overrides for CFLAGS and CXXFLAGS.
4772         Emit a dependency of 'all' on 'all-notice' that prints a warning that
4773         compiler warnings can be ignored for tests.
4774         * pygnulib/GLImport.py (GLImport.gnulib_comp): Add boolean argument to
4775         tell whether a tests Makefile.am is being emitted. Update calls to
4776         GLEmiter.initmacro_start.
4777         (GLImport.execute): Update calls to GLEmiter.initmacro_start.
4778         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
4780 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
4782         gnulib-tool.py: Fix gnulib-cache.m4 output.
4783         * pygnulib/GLImport.py (GLImport.gnulib_cache): Don't emit an extra '#'
4784         to start the actioncmd comment.
4786 2024-03-06  Bruno Haible  <bruno@clisp.org>
4788         gnulib-tool.py: Tweak comment.
4789         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Tweak 'gentests'
4790         description.
4792 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
4794         gnulib-tool.py: Follow gnulib-tool changes, part 42.
4795         Follow gnulib-tool change
4796         2019-02-15  Bruno Haible  <bruno@clisp.org>
4797         gnulib-tool: Support --import with just a few tests, not --with-tests.
4798         * pygnulib/GLImport.py (GLImport.execute): Use 'gentests' instead of
4799         'inctests' when generating files.
4800         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Add 'gentests'
4801         argument and use it instead of 'inctests'.
4803 2024-03-05  Collin Funk  <collin.funk1@gmail.com>
4805         gnulib-tool.py: Follow gnulib-tool changes, part 41.
4806         Follow gnulib-tool change
4807         2018-09-03  Bruno Haible  <bruno@clisp.org>
4808         gnulib-tool: Fix build order when $testsbase is a subdir of $sourcebase.
4809         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Consider the dotfirst
4810         flag.
4811         (GLEmiter.tests_Makefile_am): Don't consider the dotfirst flag.
4812         * pygnulib/GLImport.py (GLImport.execute): Set the dotfirst for tests.
4813         * pygnulib/GLMakefileTable.py (GLMakefileTable.editor): Add optional
4814         dotfirst flag to fix build order when $testsbase is a subdir of
4815         $sourcebase.
4817 2024-03-05  Collin Funk  <collin.funk1@gmail.com>
4819         gnulib-tool.py: Follow gnulib-tool changes, part 40.
4820         Follow gnulib-tool change
4821         2021-12-18  Bruno Haible  <bruno@clisp.org>
4822         stdint: Fix handling of limits.h (regression 2021-12-16).
4823         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
4824         (GLEmiter.tests_Makefile_am): If --gnu-make is used, assume that
4825         AC_SUBSTed variables for conditionals are constructed by appending the
4826         suffix '_CONDITION'.
4828 2024-03-05  Collin Funk  <collin.funk1@gmail.com>
4830         gnulib-tool.py: Fix incorrect tests Makefile.am generation.
4831         * pygnulib/GLImport.py: Call GLEmiter.tests_Makefile_am instead of
4832         GLEmiter.lib_Makefile_am when creating the tests Makefile. Replace
4833         incorrect actioncmd argument with witness_macro.
4835 2024-03-05  Bruno Haible  <bruno@clisp.org>
4837         doc: Update info about fopencookie.
4838         Reported by Michael Ford <fanquake@gmail.com>.
4839         * doc/glibc-functions/fopencookie.texi: Update platforms list.
4841 2024-03-05  Bruno Haible  <bruno@clisp.org>
4843         doc: Fix a typo.
4844         Reported by Tim Rice in
4845         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00023.html>.
4846         * doc/build-automation.texi (Building gnulib): Fix typo.
4848 2024-03-05  Bruno Haible  <bruno@clisp.org>
4850         c-strtof, c-strtod, c-strtold: Make multithread-safe.
4851         * lib/c-strtod.c: Include <langinfo.h>, c-ctype.h.
4852         (decimal_point_char): New function, copied from lib/vasnprintf.c.
4853         (C_STRTOD): On platforms that don't have STRTOD_L nor a working
4854         uselocale(), pre-parse the number and call STRTOD after having replaced
4855         the '.' with the locale-dependent decimal point character.
4856         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOF, gl_C_STRTOLD): Test for
4857         nl_langinfo().
4858         * modules/c-strtof (Depends-on): Add c-ctype. Remove strdup-posix.
4859         * modules/c-strtod (Depends-on): Likewise.
4860         * modules/c-strtold (Depends-on): Likewise.
4862 2024-03-05  Bruno Haible  <bruno@clisp.org>
4864         c-strtold: Add multithread-safety test.
4865         * tests/test-c-strtold-mt.c: New file.
4866         * tests/test-c-strtold-mt.sh: New file, based on
4867         tests/test-c-strtold1.sh.
4868         * modules/c-strtold-tests (Files): Add them.
4869         (Depends-on): Add thread, nanosleep.
4870         (Makefile.am): Arrange to build test-c-strtold-mt and run
4871         test-c-strtold-mt.sh.
4873 2024-03-05  Bruno Haible  <bruno@clisp.org>
4875         c-strtod: Add multithread-safety test.
4876         * tests/test-c-strtod-mt.c: New file.
4877         * tests/test-c-strtod-mt.sh: New file, based on tests/test-c-strtod1.sh.
4878         * modules/c-strtod-tests (Files): Add them.
4879         (Depends-on): Add thread, nanosleep.
4880         (Makefile.am): Arrange to build test-c-strtod-mt and run
4881         test-c-strtod-mt.sh.
4883 2024-03-05  Bruno Haible  <bruno@clisp.org>
4885         c-strtof: Add multithread-safety test.
4886         * tests/test-c-strtof-mt.c: New file.
4887         * tests/test-c-strtof-mt.sh: New file, based on tests/test-c-strtof1.sh.
4888         * modules/c-strtof-tests (Files): Add them.
4889         (Depends-on): Add thread, nanosleep.
4890         (Makefile.am): Arrange to build test-c-strtof-mt and run
4891         test-c-strtof-mt.sh.
4893 2024-03-05  Bruno Haible  <bruno@clisp.org>
4895         locale-*.m4: Update comments.
4896         * m4/locale-ar.m4: Update comments for Solaris 10.
4897         * m4/locale-fr.m4: Likewise.
4898         * m4/locale-ja.m4: Likewise.
4899         * m4/locale-tr.m4: Likewise.
4901 2024-03-05  Bruno Haible  <bruno@clisp.org>
4903         c-strtold: Add tests.
4904         * tests/test-strtold.h: New file, extracted from tests/test-strtold.c.
4905         * tests/test-strtold.c: Include test-strtold.h.
4906         (FABSL): Remove unused macro.
4907         (main): Just invoke test_function.
4908         * tests/test-strtold1.c: Add comment.
4909         * modules/strtold-tests (Files): Add tests/test-strtold.h.
4910         * tests/test-c-strtold.c: New file, based on tests/test-strtold.c.
4911         * tests/test-c-strtold1.c: New file, based on tests/test-strtold1.c.
4912         * tests/test-c-strtold1.sh: New file, based on tests/test-strtold1.sh.
4913         * modules/c-strtold-tests: New file, based on modules/strtold-tests.
4915 2024-03-05  Bruno Haible  <bruno@clisp.org>
4917         c-strtod: Add tests.
4918         * tests/test-strtod.h: New file, extracted from tests/test-strtod.c.
4919         * tests/test-strtod.c: Include test-strtod.h.
4920         (FABS): Remove unused macro.
4921         (main): Just invoke test_function.
4922         * tests/test-strtod1.c: Add comment.
4923         * modules/strtod-tests (Files): Add tests/test-strtod.h.
4924         * tests/test-c-strtod.c: New file, based on tests/test-strtod.c.
4925         * tests/test-c-strtod1.c: New file, based on tests/test-strtod1.c.
4926         * tests/test-c-strtod1.sh: New file, based on tests/test-strtod1.sh.
4927         * modules/c-strtod-tests: New file, based on modules/strtod-tests.
4929 2024-03-05  Bruno Haible  <bruno@clisp.org>
4931         c-strtof: Add tests.
4932         * tests/test-strtof.h: New file, extracted from tests/test-strtof.c.
4933         * tests/test-strtof.c: Include test-strtof.h.
4934         (FABS): Remove unused macro.
4935         (main): Just invoke test_function.
4936         * tests/test-strtof1.c: Add comment.
4937         * modules/strtof-tests (Files): Add tests/test-strtof.h.
4938         * tests/test-c-strtof.c: New file, based on tests/test-strtof.c.
4939         * tests/test-c-strtof1.c: New file, based on tests/test-strtof1.c.
4940         * tests/test-c-strtof1.sh: New file, based on tests/test-strtof1.sh.
4941         * modules/c-strtof-tests: New file, based on modules/strtof-tests.
4943 2024-03-04  Collin Funk  <collin.funk1@gmail.com>
4945         gnulib-tool.py: Follow gnulib-tool changes, part 39.
4946         Follow gnulib-tool change
4947         2017-12-28  Bruno Haible  <bruno@clisp.org>
4948         gnulib-tool: Make --conditional-dependencies work better.
4949         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Add argument
4950         referenceable_modules. Use referencable_modules for dependencies.
4951         * pygnulib/GLImport.py (GLImport.__init__): Don't reject the combination
4952         of --conditional-dependencies with --with-tests when mode is 'import'.
4953         (GLImport.gnulib_comp): Pass it.
4954         * pygnulib/GLTestDir.py (GLTestDir.execute): Pass it.
4956 2024-03-04  Bruno Haible  <bruno@clisp.org>
4958         doc: Tweak last commit.
4959         * doc/gnulib-tool.texi (Style of #include statements): Use
4960         @itemize @asis{}. Recommended by Patrice Dumas.
4962 2024-03-04  Collin Funk  <collin.funk1@gmail.com>
4964         doc: Fix build errors.
4965         * doc/gnulib-tool.texi (Style of #include statements): Use @itemize w{}
4966         instead of the incorrect @itemize @asis.
4968 2024-03-04  Collin Funk  <collin.funk1@gmail.com>
4970         gnulib-tool.py: Adjust construction of configure.ac path.
4971         * pygnulib/GLConfig.py (GLConfig.setAutoconfFile): Join destdir and
4972         configure.ac instead of using relativize.
4974 2024-03-03  Collin Funk  <collin.funk1@gmail.com>
4975             Bruno Haible  <bruno@clisp.org>
4977         gnulib-tool.py: Fix output of gnulib-comp.m4.
4978         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Fix indentation.
4979         Don't print nonstring values into gnulib-comp.m4.
4981 2024-03-03  Collin Funk  <collin.funk1@gmail.com>
4983         gnulib-tool.py: Make output of test Makefile.am match gnulib-tool.
4984         * pygnulib/GLModuleSystem.py
4985         (GLModule.getAutomakeSnippet_Unconditional): Don't sort EXTRA_DIST file
4986         names for test modules.
4988 2024-03-03  Bruno Haible  <bruno@clisp.org>
4990         gnulib-tool.py: Fix last commit.
4991         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Ignore libname and
4992         libext here.
4994 2024-03-03  Collin Funk  <collin.funk1@gmail.com>
4996         gnulib-tool.py: Follow gnulib-tool changes, part 38.
4997         Follow gnulib-tool change
4998         2020-12-26  Bruno Haible  <bruno@clisp.org>
4999         gnulib-tool: Make --conditional-dependencies work with --with-tests.
5000         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Add missing
5001         moduletable argument. Handle conditional dependencies like
5002         GLEmiter.lib_Makefile_am.
5003         * pygnulib/GLTestDir.py (GLTestDir.execute): Adjust arguments.
5005 2024-03-03  Bruno Haible  <bruno@clisp.org>
5007         doc: Update regarding --create-megatestdir.
5008         Reported by Alexei Sholomitskiy <asholomitskiy84@gmail.com> in
5009         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00071.html>
5010         and by Collin Funk <collin.funk1@gmail.com> in
5011         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00007.html>.
5012         * doc/build-automation.texi (Building gnulib): Discourage the use of
5013         --create-megatestdir with all modules.
5015 2024-03-01  Bruno Haible  <bruno@clisp.org>
5017         gnulib-tool.py: Clarify minimum supported Python version.
5018         * pygnulib/main.py: Add comment regarding the Python version.
5020 2024-03-01  Collin Funk  <collin.funk1@gmail.com>
5022         gnulib-tool.py: Follow gnulib-tool changes, part 37.
5023         Follow gnulib-tool change
5024         2018-10-22  Bruno Haible  <bruno@clisp.org>
5025         Assume Automake >= 1.11.
5026         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
5027         (GLEmiter.tests_Makefile_am): Emit a Makefile.am that requires Automake
5028         >= 1.11.
5029         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
5030         Likewise.
5031         * pygnulib/constants.py: Update comment.
5033 2024-03-01  Collin Funk  <collin.funk1@gmail.com>
5035         gnulib-tool.py: Fix GNU Make conversion regular expressions.
5036         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Reduce code
5037         duplication. Use re.MULTILINE so '^' matches the start of each line
5038         instead of only the start of a string.
5040 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
5042         gnulib-tool.py: Follow gnulib-tool changes, part 36.
5043         Follow gnulib-tool change
5044         2017-03-14  Mathieu Lirzin  <mthl@gnu.org>
5045         gnulib-tool: don't automatically distribute files from top/
5046         * pygnulib/GLModuleSystem.py
5047         (GLModule.getAutomakeSnippet_Unconditional): Don't distribute files from
5048         top/ automatically.
5050 2024-02-29  Bruno Haible  <bruno@clisp.org>
5052         xalloc: Don't use identifier 'nonnull'.
5053         * lib/xmalloc.c (check_nonnull): Renamed from nonnull.
5055 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
5057         gnulib-tool.py: Follow gnulib-tool changes, part 35.
5058         Follow gnulib-tool change
5059         2023-05-28  Bruno Haible  <bruno@clisp.org>
5060         warnings, manywarnings: Assume autoconf >= 2.64.
5061         * pygnulib/GLConfig.py (GLConfig.default, GLConfig.getAutoconfVersion)
5062         (GLConfig.setAutoconfVersion, resetAutoconfVersion): Set required
5063         Autoconf version to 2.64.
5064         * pygnulib/GLError.py (GLError.__init__, GLError.__repr__): Likewise.
5065         * pygnulib/GLImport.py (GLImport.__init__): Likewise.
5066         * pygnulib/constants.py (DEFAULT_AUTOCONF_MINVERSION): Likewise.
5067         * pygnulib/main.py: Likewise.
5069 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
5071         gnulib-tool.py: Follow gnulib-tool changes, part 34.
5072         Follow gnulib-tool change
5073         2017-05-15  Bruno Haible  <bruno@clisp.org>
5074         gnulib-tool: Fix generated code when libtests contains module 'alloca'.
5075         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Use @ALLOCA@ for
5076         libtests.a instead of @LTALLOCA@.
5078 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
5080         gnulib-tool.py: Follow gnulib-tool changes, part 33.
5081         Follow gnulib-tool change
5082         2017-03-14  Bruno Haible  <bruno@clisp.org>
5083         gnulib-tool: Don't produce a tests directory with only snippet .h files.
5084         * pygnulib/GLModuleSystem.py
5085         (GLModuleTable.transitive_closure_separately): Don't create a test
5086         directory if all test related modules have applicability 'all'.
5088 2024-02-28  Collin Funk  <collin.funk1@gmail.com>
5090         gnulib-tool.py: Follow gnulib-tool changes, part 32.
5091         Follow gnulib-tool change
5092         2018-10-22  Bruno Haible  <bruno@clisp.org>
5093         Fix failure of 'gnulib-tool --create-testdir' with all modules.
5094         * pygnulib/GLTestDir.py (GLTestDir.execute): Exclude the 'timevar'
5095         module from --create-testdir with all modules. Update comment.
5097 2024-02-28  Collin Funk  <collin.funk1@gmail.com>
5099         gnulib-tool.py: Emit year range on file copyright notices.
5100         * pygnulib/GLInfo.py (GLInfo.copyright_range): New function. Return a
5101         copyright string with a year range.
5102         * pygnulib/GLEmiter.py (GLEmiter.copyright_notice): Use the new function
5103         for file copyright headers.
5105 2024-02-28  Collin Funk  <collin.funk1@gmail.com>
5107         gnulib-tool.py: Make module sorting more similar to gnulib-tool.
5108         * pygnulib/GLImport.py (GLImport.__init__): Sort modules when mode is
5109         'import'.
5110         (GLImport.actioncmd): Don't sort modules while creating actioncmd. Use
5111         preferred quoting style.
5113 2024-02-28  Bruno Haible  <bruno@clisp.org>
5115         gnulib-tool: Make --version output independent of git's configuration.
5116         Reported by Collin Funk <collin.funk1@gmail.com> in
5117         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00268.html>.
5118         * pygnulib/GLInfo.py (GLInfo.date): Pass --format and --date options, to
5119         override the user's git configuration.
5120         * gnulib-tool (func_version): Likewise. Also pass options '-n 1', to
5121         speed up the operation.
5123 2024-02-28  Bruno Haible  <bruno@clisp.org>
5125         gnulib-tool.py: Avoid exception when 'git log' output is unexpected.
5126         * pygnulib/GLInfo.py (GLInfo.date): When the 'git log' output does not
5127         contain a line with the expected 'Date:' pattern, pass the empty string
5128         to GNU date.
5130 2024-02-28  Bruno Haible  <bruno@clisp.org>
5132         gnulib-tool: Avoid references to functions that get defined later.
5133         * gnulib-tool (func_fatal_error, func_warning, func_readlink): Move
5134         before func_gnulib_dir.
5136 2024-02-27  Bruno Haible  <bruno@clisp.org>
5138         isnan: Fix compilation error in C++ mode on OpenBSD 7.5-beta.
5139         Reported by Christian Weisgerber <naddy@mips.inka.de> in
5140         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00261.html>.
5141         * lib/math.in.h (GNULIB_NAMESPACE_LACKS_ISNAN): Define on all platforms
5142         with clang ≥ 14.
5144 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
5146         gnulib-tool.py: Fix configure.ac output.
5147         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Fix backslash escapes
5148         in raw string.
5150 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
5152         gnulib-tool.py: Follow gnulib-tool changes, part 31.
5153         Follow gnulib-tool change
5154         2021-06-04  Bruno Haible  <bruno@clisp.org>
5155         gnulib-tool: Stop doing license notice replacements.
5156         * pygnulib/GLConfig.py (GLConfig.default): Remove 'copyrights' key.
5157         (checkCopyrights): Remove function.
5158         (setSymbolic, resetSymbolic): Remove 'copyrights' key.
5159         * pygnulib/GLImport.py (GLImport.prepare): Remove copyrights variable.
5160         Don't modify license notice on source files.
5161         (GLImport.execute): Remove copyrights variable.
5163 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
5165         gnulib-tool.py: Small fix of part 27.
5166         * pygnulib/GLConfig.py (GLConfig.default): Add 'gnu_make' key which
5167         returns False.
5169 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
5171         gnulib-tool.py: Follow gnulib-tool changes, part 30.
5172         Follow gnulib-tool change
5173         2021-05-30  Bruno Haible  <bruno@clisp.org>
5174         Write 'LGPLv3+ or GPLv2+' instead of 'LGPLv3+ or GPLv2'.
5175         * pygnulib/GLImport.py (GLImport.prepare): Change.
5176         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
5178 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
5180         gnulib-tool.py: Follow gnulib-tool changes, part 29.
5181         Follow gnulib-tool change
5182         2021-03-06  Paul Eggert  <eggert@cs.ucla.edu>
5183         parse-datetime2: fix licensing
5184         * pygnulib/GLModuleSystem.py (GLModule.getLicense): Handle the special
5185         licensing case for parse-datetime2 or any other module starting with
5186         "parse-datetime". Update comment.
5188 2024-02-26  Bruno Haible  <bruno@clisp.org>
5190         gnulib-tool.py: Add more comments.
5191         * pygnulib/main.py: Add comments regarding code style. Mention the
5192         pycodestyle and pylint configurations.
5194 2024-02-26  Collin Funk  <collin.funk1@gmail.com>
5196         gnulib-tool.py: Add configuration files for Python tools.
5197         * pygnulib/.pylintrc: New file, used by pylintrc.
5198         * pygnulib/setup.cfg: New file, currently only used for pycodestyle
5199         options.
5201 2024-02-26  Collin Funk  <collin.funk1@gmail.com>
5203         gnulib-tool.py: Fix undefined variable access.
5204         * pygnulib/main.py (main): Don't use gnu_make before it is defined.
5206 2024-02-26  Bruno Haible  <bruno@clisp.org>
5208         gnulib-tool.py: Reorganize code.
5209         * pygnulib/main.py: New file, moved here from gnulib-tool.py.
5210         * pygnulib/constants.py: Change the way APP['name'] and DIRS['root'] are
5211         computed.
5212         * gnulib-tool.py: New file, based on gnulib-tool.
5214 2024-02-25  Bruno Haible  <bruno@clisp.org>
5216         bitset: Don't access errno when it's not set.
5217         * lib/bitset/stats.c (bitset_stats_read): Don't use errno after neither
5218         fread() nor ferror() has set it. On native Windows, don't use errno
5219         after fclose().
5221 2024-02-25  Bruno Haible  <bruno@clisp.org>
5223         bitset: Avoid newlines at the end of translatable strings.
5224         * lib/bitset/stats.c (bitset_percent_histogram_print,
5225         bitset_log_histogram_print): Print a newline after msg.
5226         (bitset_stats_print_1): Don't include a newline in the argument of
5227         bitset_percent_histogram_print or bitset_log_histogram_print.
5228         (bitset_stats_print): Move newlines outside of translatable strings.
5230 2024-02-24  Collin Funk  <collin.funk1@gmail.com>
5232         gnulib-tool.py: Follow gnulib-tool changes, part 28.
5233         Follow gnulib-tool change
5234         2018-07-17  Paul Eggert  <eggert@cs.ucla.edu>
5235         gnulib-tool: limit line length for git send-email
5236         * pygnulib/GLImport.py (GLImport.actioncmd): Break actioncmd into
5237         multiple lines. Reorder emitting of arguments to match gnulib-tool. Emit
5238         "--witness-c-macro" instead of "--witness_c_macro". Emit "--po-domain"
5239         instead of "--podomain". Document ordering of unimplemented options. Add
5240         updated comments documenting line length limitations of git send-email
5241         and some implementations of AWK.
5242         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Remove comment which
5243         was moved to pygnulib/GLImport.py. Remove length limitation on actioncmd
5244         since it now spans multiple lines.
5246 2024-02-24  Bruno Haible  <bruno@clisp.org>
5248         gnulib-tool.py: Further fix last commit.
5249         * gnulib-tool.py (main): Make the mode test match for 'create-testdir',
5250         'create-megatestdir', 'test', 'megatest'.
5252 2024-02-24  Collin Funk  <collin.funk1@gmail.com>
5254         gnulib-tool.py: Fix conditional checking the incorrect variable.
5255         Reported by Bruno Haible <bruno@clisp.org> in
5256         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00207.html>.
5257         * gnulib-tool.py (main): Fix incorrect conditional. Check that mode, not
5258         modules, is not None before treating it as a string.
5260 2024-02-24  Bruno Haible  <bruno@clisp.org>
5262         striconveha tests: Avoid test failure on macOS 12.5.
5263         * tests/test-striconveha.c (main): Skip transliteration tests when using
5264         Apple's modified GNU libiconv or the bastard Apple iconv.
5266 2024-02-23  Bruno Haible  <bruno@clisp.org>
5268         DEPENDENCIES: Update entry about gperf.
5269         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
5270         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00201.html>.
5271         * DEPENDENCIES (gperf): Mention some more modules which require 'gperf'.
5273 2024-02-23  Bruno Haible  <bruno@clisp.org>
5275         unictype/mirror: Update to Unicode 15.1.0.
5276         Reported by Daurnimator <quae@daurnimator.com> in
5277         <https://lists.gnu.org/archive/html/bug-libunistring/2016-11/msg00010.html>.
5278         * lib/gen-uni-tables.c (struct mirror_pair): New type.
5279         (mirror_pairs): Don't initialize statically.
5280         (mirror_pairs_count): New variable.
5281         (fill_mirror): New function.
5282         (get_mirror_value): Update.
5283         (main): Expect the file name of BidiMirroring.txt as command-line
5284         argument. Invoke fill_mirror.
5285         * lib/unictype/mirror.h: Regenerated.
5286         * modules/unictype/mirror (configure.ac): Bump required libunistring
5287         version.
5289 2024-02-23  Bruno Haible  <bruno@clisp.org>
5291         gen-uni-tables: Keep line number better up-to-date.
5292         * lib/gen-uni-tables.c (fill_width, fill_org_lbp): Increase lineno by 1
5293         when reading a blank line.
5295 2024-02-23  Collin Funk  <collin.funk1@gmail.com>
5297         gnulib-tool.py: Follow gnulib-tool changes, part 27.
5298         Follow gnulib-tool changes
5299         2017-03-12  Paul Eggert  <eggert@cs.ucla.edu>
5300         gnulib-tool: new option --gnu-make
5301         2017-03-13  Paul Eggert  <eggert@cs.ucla.edu>
5302         gnulib-tool: minor --gnu-make fixups
5303         2017-03-14  Paul Eggert  <eggert@cs.ucla.edu>
5304         gnulib-tool: fix typo in comment output
5305         2017-05-14  Paul Eggert  <eggert@cs.ucla.edu>
5306         gnulib-tool: improve GNU Make debugging
5307         2018-07-04  Paul Eggert  <eggert@cs.ucla.edu>
5308         gnulib-tool: minor tweaks for --gnu-make
5309         * gnulib-tool.py (main): Add --gnu-make option. Do not allow --gnu-make
5310         in test modes, since they all require Automake.
5311         * pygnulib/GLConfig.py: Add gnu_make argument to constructor.
5312         (getGnuMake, setGnuMake, resetGnuMake): New methods for accessing the
5313         gnu_make instance variable.
5314         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Use the "+=" operator
5315         with GNU Make and Automake. Transform conditionals to GNU Make syntax if
5316         --gnu-make is in use. Use a Autoconf subprocess to define values and
5317         check the return code for errors.
5318         (GLEmiter.tests_Makefile_am): Likewise.
5319         * pygnulib/GLImport.py (GLImport.actioncmd): Add "--gnu-make" to the
5320         output comment if it is in use.
5321         (GLImport.gnulib_comp): Don't require "AM_PROG_CC_C_O" when using GNU
5322         Make.
5323         * pygnulib/GLInfo.py (GLInfo.usage): Update help message to reflect
5324         addition of --gnu-make.
5325         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Don't
5326         add Automake snippets as unconditional dependencies when using
5327         --gnu-make.
5329 2024-02-23  Bruno Haible  <bruno@clisp.org>
5331         unistdio/*printf tests: Update expected test results regarding %n.
5332         * tests/unistdio/test-u8-printf1.h (test_xfunction): If
5333         NEED_PRINTF_WITH_N_DIRECTIVE is not defined, expect a NULL result in the
5334         %n test.
5335         * tests/unistdio/test-u16-printf1.h (test_xfunction): Likewise.
5336         * tests/unistdio/test-u32-printf1.h (test_xfunction): Likewise.
5337         * tests/unistdio/test-ulc-printf1.h (test_xfunction): Likewise.
5339 2024-02-22  Collin Funk  <collin.funk1@gmail.com>
5341         gnulib-tool.py: Follow gnulib-tool changes, part 26.
5342         Follow gnulib-tool change
5343         2017-04-20  Bruno Haible  <bruno@clisp.org>
5344         verify tests: Fix spurious failure with parallel make.
5345         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Emit initialization
5346         of EXTRA_PROGRAMS so that the verify-tests module does not cause
5347         Automake to warn about the use of "+=" instead of "=".
5349 2024-02-22  Collin Funk  <collin.funk1@gmail.com>
5351         gnulib-tool.py: Follow gnulib-tool changes, part 25.
5352         Follow gnulib-tool change
5353         2017-06-11  Bruno Haible  <bruno@clisp.org>
5354         gnulib-tool: Clean up after autotools.
5355         * pygnulib/GLTestDir.py (GLTestDir.execute): Remove
5356         unnessecary autom4te.cache directory generated by Autotools.
5357         (GLMegaTestDir.execute): Likewise.
5359 2024-02-21  Bruno Haible  <bruno@clisp.org>
5361         c-strtof: New module.
5362         * lib/c-strtod.h (c_strtof): New declaration.
5363         * lib/c-strtod.c: Support FLOAT.
5364         * lib/c-strtof.c: New file.
5365         * m4/c-strtod.m4 (gl_C_STRTOF): New macro.
5366         * modules/c-strtof: New file.
5368 2024-02-21  Bruno Haible  <bruno@clisp.org>
5370         c-strtold: Use strtold_l when available (regr. 2019-01-31).
5371         * lib/c-strtod.c: Fix typo: HAVE_GOOD_STRTOLD_L was never defined.
5373 2024-02-21  Bruno Haible  <bruno@clisp.org>
5375         strtof: Add tests.
5376         * tests/test-strtof.c: New file, based on tests/test-strtod.c.
5377         * tests/test-strtof1.sh: New file, based on tests/test-strtod1.sh.
5378         * tests/test-strtof1.c: New file, based on tests/test-strtod1.c.
5379         * modules/strtof-tests: New file, based on modules/strtod-tests.
5381         strtof: New module.
5382         * lib/stdlib.in.h (strtof): New declaration.
5383         * lib/strtod.c: Support USE_FLOAT.
5384         * lib/strtof.c: New file.
5385         * m4/strtof.m4: New file, based on m4/strtod.m4.
5386         * m4/ldexpf.m4 (gl_CHECK_LDEXPF_NO_LIBM): New macro, based on
5387         m4/ldexp.m4.
5388         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize
5389         GNULIB_STRTOF.
5390         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOF, HAVE_STRTOF,
5391         REPLACE_STRTOF.
5392         * modules/strtof: New file.
5393         * tests/test-stdlib-c++.cc (strtof): Check signature.
5394         * doc/posix-functions/strtof.texi: Mention the new module and the bugs
5395         that it fixes.
5396         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_STRTOF, REPLACE_STRTOF.
5398 2024-02-21  Bruno Haible  <bruno@clisp.org>
5400         strtod, strtold tests: Avoid a test failure on native Windows.
5401         * modules/strtod-tests (Depends-on): Add setlocale.
5402         * modules/strtold-tests (Depends-on): Likewise.
5404 2024-02-21  Collin Funk  <collin.funk1@gmail.com>
5406         gnulib-tool.py: Fix undefined variable while emitting testdir.
5407         * pygnulib/GLTestDir.py (GLTestDir.execute): Fix undefined
5408         variable refrence caused by commit
5409         01cd78f9d682ff75cc5ab1c2d21b911bdd9215b8.
5410         Restore the previous auxdir when finished writing the
5411         configure.ac file in the test directory.
5413 2024-02-21  Bruno Haible  <bruno@clisp.org>
5415         *printf-posix: Disable support for the 'n' directive by default.
5416         * m4/printf-with-n-directive.m4: New file.
5417         * modules/printf-with-n-directive: New file.
5418         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): If
5419         gl_PRINTF_SUPPORT_N_DIRECTIVE is not defined, ignore the value of the
5420         gl_cv_func_printf_directive_n variable.
5421         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
5422         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX): Likewise.
5423         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
5424         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Likewise.
5425         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
5426         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
5427         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
5428         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
5429         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): If
5430         gl_PRINTF_SUPPORT_N_DIRECTIVE is not defined, ignore the values of the
5431         gl_cv_func_printf_directive_n and gl_cv_func_snprintf_directive_n
5432         variables.
5433         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
5434         * lib/printf-parse.c (PRINTF_PARSE): If NEED_PRINTF_WITH_N_DIRECTIVE is
5435         not defined, treat the 'n' directive like an unknown directive.
5436         * lib/vasnprintf.c (VASNPRINTF): If NEED_PRINTF_WITH_N_DIRECTIVE is not
5437         defined, disable the processing of the 'n' directive.
5438         * tests/test-snprintf-posix.h (test_function): If
5439         NEED_PRINTF_WITH_N_DIRECTIVE is not defined, skip the %n test.
5440         * tests/test-sprintf-posix.h (test_function): Likewise.
5441         * tests/test-vasnprintf-posix.c (test_function): Likewise.
5442         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
5443         * tests/test-vasprintf-posix.c (test_function): Likewise.
5444         * doc/posix-functions/dprintf.texi: Mention that support for the 'n'
5445         directive is only enabled together with the module
5446         'printf-with-n-directive'.
5447         * doc/posix-functions/fprintf.texi: Likewise.
5448         * doc/posix-functions/printf.texi: Likewise.
5449         * doc/posix-functions/snprintf.texi: Likewise.
5450         * doc/posix-functions/sprintf.texi: Likewise.
5451         * doc/posix-functions/vdprintf.texi: Likewise.
5452         * doc/posix-functions/vfprintf.texi: Likewise.
5453         * doc/posix-functions/vprintf.texi: Likewise.
5454         * doc/posix-functions/vsnprintf.texi: Likewise.
5455         * doc/posix-functions/vsprintf.texi: Likewise.
5456         * doc/glibc-functions/obstack_printf.texi: Likewise.
5457         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
5458         * NEWS: Mention the change.
5460 2024-02-21  Bruno Haible  <bruno@clisp.org>
5462         *printf-posix: Avoid crash in another configure test.
5463         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): In the test program, catch the
5464         SIGABRT signal, so that the program does not dump core.
5466 2024-02-20  Bruno Haible  <bruno@clisp.org>
5468         unimetadata/u-version: Add tests.
5469         * tests/unimetadata/test-u-version.c: New file.
5470         * modules/unimetadata/u-version-tests: New file.
5472         unimetadata/u-version: New module.
5473         * lib/gen-uni-tables.c (output_version): New function.
5474         (main): Invoke it.
5475         * lib/unimetadata/u-version.c: New generated file.
5476         * modules/unimetadata/u-version: New file.
5478         unimetadata/base: New module.
5479         * lib/unimetadata.in.h: New file.
5480         * m4/unimetadata_h.m4: New file.
5481         * modules/unimetadata/base: New file.
5483 2024-02-20  Collin Funk  <collin.funk1@gmail.com>
5485         maint.mk: Fix include header typo.
5486         * top/maint.mk: Change arpa_inet.h to arpa/inet.h.
5488 2024-02-20  Bruno Haible  <bruno@clisp.org>
5490         *printf-posix: Avoid crash in a configure test.
5491         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): In the test program, catch the
5492         SIGABRT signal, so that the program does not dump core.
5494 2024-02-18  Jim Meyering  <meyering@meta.com>
5496         maint.mk: improve new syntax-check rule
5497         * top/maint.mk (sc_prefer_angle_bracket_headers): Rename from
5498         sc_verify_absolute_include_headers.  Simplify to run a single
5499         invocation of grep, rather than usually many.  Derive a regular
5500         expression matching the selected headers, and warn about any
5501         offending matches via what is usually a single grep invocation.
5503 2024-02-18  Collin Funk  <collin.funk1@gmail.com>
5505         gnulib-tool.py: Fix function call on incorrect object.
5506         * pygnulib/GLImport.py: Call checkInclTestCategory on the
5507         GLConfig member instead of the GLImport object itself.
5508         * pygnulib/__init__.py: Update copyright dates.
5509         * pygnulib/constants.py: Update copyright dates.
5511 2024-02-18  Bruno Haible  <bruno@clisp.org>
5513         maint.mk: Add more comments.
5514         * top/maint.mk: Reference the Gnulib documentation where suitable.
5516 2024-02-18  Collin Funk  <collin.funk1@gmail.com>
5518         maint.mk: Add syntax-check rule to check for #include syntax.
5519         * top/maint.mk (sc_verify_absolute_include_headers): New rule
5520         to check for #includes that might cause
5521         -Winclude-next-absolute-path warnings.
5523 2024-02-18  Bruno Haible  <bruno@clisp.org>
5525         doc: Mention requirement regarding #include syntax.
5526         * doc/gnulib-tool.texi (-I options, Include <config.h>,
5527         Style of #include statements): New subsections.
5529 2024-02-17  Paul Eggert  <eggert@cs.ucla.edu>
5531         qsort_r-tests: minor visibility cleanup
5532         * tests/test-qsort_r.c (cmp): Now static.
5534         savedir: work around GCC bug 113963
5535         * lib/savedir.c: Ignore -Wanalyzer-malloc-leak and
5536         -Wanalyzer-null-dereference.
5538         Solaris EOL update
5539         * doc/solaris-versions: Solaris 11.4 EOL update.  Also mention 11.3.
5541 2024-02-17  Collin Funk  <collin.funk1@gmail.com>
5543         math: More clang -Winclude-next-absolute-path silencing.
5544         * lib/math.c: Write #include <math.h> instead of #include "math.h".
5546 2024-02-17  Bruno Haible  <bruno@clisp.org>
5548         error: More clang -Winclude-next-absolute-path silencing.
5549         * modules/error-h (Include): Suggest <error.h>, not "error.h".
5550         * m4/error_h.m4: Write #include <error.h>.
5552 2024-02-15  Bruno Haible  <bruno@clisp.org>
5554         nstrftime: Optimize module dependencies.
5555         * modules/nstrftime (Depends-on): Remove localename-unsafe. Add
5556         localename-unsafe-limited.
5558 2024-02-15  Bruno Haible  <bruno@clisp.org>
5560         localename-unsafe-limited: New module.
5561         * m4/localename.m4 (gl_LOCALENAME_UNSAFE_LIMITED): New macro.
5562         * modules/localename-unsafe-limited: New file.
5563         * modules/localename-unsafe (Depends-on): Add localename-unsafe-limited.
5564         (Makefile.am): Compile localename-unsafe.c only if the module
5565         localename-unsafe-limited does not already do it.
5567 2024-02-15  Bruno Haible  <bruno@clisp.org>
5569         nstrftime, fprintftime: Optimize.
5570         * lib/strftime.c (should_remove_ampm): Call gl_locale_name_unsafe
5571         instead of gl_locale_name.
5572         * modules/nstrftime (Depends-on): Remove localename. Add
5573         localename-unsafe.
5575 2024-02-15  Bruno Haible  <bruno@clisp.org>
5577         localename-unsafe: Optimize.
5578         * lib/localename-unsafe.c (gl_locale_name_posix_unsafe): Call
5579         setlocale_null_unlocked instead of setlocale_null.
5580         * modules/localename-unsafe (Depends-on): Add setlocale-null-unlocked.
5582 2024-02-15  Bruno Haible  <bruno@clisp.org>
5584         setlocale_null-unlocked: Add tests.
5585         * tests/test-setlocale_null-unlocked.c: New file, based on
5586         tests/test-setlocale_null.c.
5587         * modules/setlocale-null-unlocked-tests: New file.
5589         setlocale_null-unlocked: New module.
5590         * lib/setlocale_null.h (setlocale_null_r_unlocked,
5591         setlocale_null_unlocked): New declarations.
5592         * lib/setlocale_null-unlocked.c: New file, based on
5593         lib/setlocale_null.c.
5594         * lib/setlocale_null.c: Don't include <wchar.h>.
5595         (setlocale_null_unlocked, setlocale_null_r_unlocked): Remove functions.
5596         * modules/setlocale-null-unlocked: New file.
5597         * modules/setlocale-null (Depends-on): Add setlocale-null-unlocked.
5599 2024-02-15  Bruno Haible  <bruno@clisp.org>
5601         setlocale-null: Refactor.
5602         * lib/setlocale_null.c
5603         (setlocale_null_r_with_lock): Renamed from setlocale_null_with_lock.
5604         (setlocale_null_r_unlocked): Renamed from setlocale_null_unlocked.
5605         (setlocale_null_unlocked): Renamed from setlocale_null_androidfix.
5607 2024-02-15  Bruno Haible  <bruno@clisp.org>
5609         localename-unsafe: New module.
5610         * lib/localename.h (gl_locale_name_unsafe, gl_locale_name_thread_unsafe,
5611         gl_locale_name_posix_unsafe): New declarations.
5612         * lib/localename-unsafe.c: New file, based on lib/localename.c.
5613         (gl_locale_name_thread_unsafe): Renamed from gl_locale_name_thread.
5614         (gl_locale_name_posix_unsafe): Renamed from gl_locale_name_posix.
5615         (gl_locale_name_unsafe): Renamed from gl_locale_name.
5616         (struniq): Define only on platforms that need it.
5617         * lib/localename.c: Remove code that was moved to
5618         lib/localename-unsafe.c.
5619         (gl_locale_name_thread): Just call gl_locale_name_thread_unsafe and
5620         struniq.
5621         (gl_locale_name_posix): Just call gl_locale_name_posix_unsafe and
5622         struniq.
5623         * lib/locale.in.h: Test @GNULIB_LOCALENAME_UNSAFE@ instead of
5624         @GNULIB_LOCALENAME@.
5625         * m4/locale_h.m4 (gl_LOCALE_H_REQUIRE_DEFAULTS): Initialize
5626         GNULIB_LOCALENAME_UNSAFE instead of GNULIB_LOCALENAME.
5627         * modules/locale (Makefile.am): Substitute GNULIB_LOCALENAME_UNSAFE
5628         instead of GNULIB_LOCALENAME.
5629         * m4/localename.m4 (gl_LOCALENAME_UNSAFE): Renamed from gl_LOCALENAME.
5630         * modules/localename-unsafe: New file, based on modules/localename.
5631         * modules/localename: Greatly simplify.
5632         (Depends-on): Add localename-unsafe.
5634 2024-02-15  Bruno Haible  <bruno@clisp.org>
5636         localename: Refactor.
5637         * lib/struniq.h: New file, extracted from lib/localename.c.
5638         * lib/localename.c: Include it.
5639         * modules/localename (Files): Add lib/struniq.h.
5641 2024-02-15  Bruno Haible  <bruno@clisp.org>
5643         localename: Speed up lookup of the LC_MESSAGES name on AIX ≥ 7.2.
5644         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): On AIX, test
5645         for the 'locale_name' member.
5646         * lib/localename.c (get_locale_t_name): For the LC_MESSAGES category,
5647         use the 'locale_name' member if available.
5649 2024-02-15  Bruno Haible  <bruno@clisp.org>
5651         localename: Add more comments.
5652         * m4/intl-thread-locale.m4: Document expected configuration results.
5653         * doc/posix-functions/uselocale.texi: Update platforms list.
5654         * lib/localename.c: Likewise.
5656 2024-02-15  Bruno Haible  <bruno@clisp.org>
5658         localename: Add parameter validation.
5659         * lib/localename.c (get_locale_t_name, gl_locale_name_thread_unsafe,
5660         gl_locale_name_thread, gl_locale_name_posix, gl_locale_name): Verify
5661         that the category argument is not LC_ALL.
5663 2024-02-14  Bruno Haible  <bruno@clisp.org>
5665         localename: Notice setlocale() invocations on more platforms.
5666         * lib/localename.c (HAVE_LOCALE_NULL): Define also on musl, FreeBSD,
5667         NetBSD, Solaris, Haiku.
5668         * modules/localename (Files): Add m4/musl.m4.
5669         (configure.ac): Invoke gl_MUSL_LIBC.
5670         * tests/test-localename.c (C_CANONICALIZED): New macro, for Haiku.
5671         (is_default): New function, for musl libc and Haiku.
5672         (test_locale_name, test_locale_name_posix): Use these definitions.
5673         * modules/localename-tests (Files): Add m4/musl.m4.
5674         (configure.ac): Invoke gl_MUSL_LIBC.
5676 2024-02-14  Bruno Haible  <bruno@clisp.org>
5678         Don't treat Apple's new Citrus/FreeBSD-based iconv like GNU libiconv.
5679         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Don't treat the bastard Apple
5680         iconv like GNU libiconv.
5681         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Likewise.
5682         * lib/striconveh.c (iconv_carefully, iconv_carefully_1,
5683         mem_cd_iconveh_internal): Likewise.
5684         * lib/propername.c (proper_name_utf8): Likewise.
5685         * lib/unicodeio.c (unicode_to_mb): Likewise.
5686         * lib/uniconv/u16-conv-from-enc.c (UTF16_NAME): Likewise.
5687         * lib/uniconv/u16-conv-to-enc.c (UTF16_NAME): Likewise.
5688         * lib/uniconv/u16-strconv-to-enc.c (UTF16_NAME): Likewise.
5689         * lib/uniconv/u32-conv-from-enc.c (UTF32_NAME): Likewise.
5690         * lib/uniconv/u32-conv-to-enc.c (UTF32_NAME): Likewise.
5691         * lib/uniconv/u32-strconv-to-enc.c (UTF32_NAME): Likewise.
5692         * tests/test-striconveh.c (main): Likewise.
5693         * tests/test-striconveha.c (main): Likewise.
5694         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
5695         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
5696         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
5697         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
5698         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
5699         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
5701 2024-02-14  Bruno Haible  <bruno@clisp.org>
5703         Improve support of Citrus/FreeBSD iconv.
5704         * lib/striconveh.c (iconveh_open): Use //TRANSLIT with all iconv
5705         implementations that support it.
5706         * lib/striconveha.c (mem_iconveha, str_iconveha): Likewise.
5707         * lib/propername.c (proper_name_utf8): Likewise.
5709 2024-02-14  Bruno Haible  <bruno@clisp.org>
5711         isnan: Fix compilation error in C++ mode on macOS 14.4 / Xcode 15.2.
5712         Reported by Paul E Reimer <reimer@anl.gov> in
5713         <https://lists.gnu.org/archive/html/bug-gettext/2024-02/msg00002.html>.
5714         * lib/math.in.h (GNULIB_NAMESPACE_LACKS_ISNAN): Define also on macOS
5715         with clang ≥ 14.
5717 2024-02-13  Paul Eggert  <eggert@cs.ucla.edu>
5719         nstrftime: allow opt-out of AM/PM adjustment
5720         For Emacs I would rather avoid bringing in the Gnulib locking code,
5721         since Emacs has its own idea about locks and its main engine is
5722         single-threaded anyway.
5723         Provide a way to use the nstrftime module while avoiding its
5724         recently-added localename dependency, which entails locking code.
5725         (It’s not clear to me that the locking code is needed for nstrftime,
5726         as NetBSD has strftime_z and Solaris locales could be inspected in
5727         some thread-safe way, e.g., by probing strftime month names.
5728         Anyway, all that’s more hassle than I want to put up with right now
5729         for the trivial matter of AM/PM behavior.)
5730         * lib/strftime.c (REQUIRE_GNUISH_STRFTIME_AM_PM):
5731         New macro, which can be overridden by config.h.
5732         (should_remove_ampm, __strftime_internal):
5733         Use it instead of !USE_C_LOCALE when deciding to
5734         implement Gnuish AM/PM behavior.
5736 2024-02-13  Bruno Haible  <bruno@clisp.org>
5738         uniwidth/width tests: Update unit test for last commit.
5739         * tests/uniwidth/test-uc_width2.sh: Update expected test result.
5741 2024-02-12  Bruno Haible  <bruno@clisp.org>
5743         uniwidth/width: Assign width 1 to prepended concatenation marks.
5744         Suggested by Jules Bertholet <julesbertholet@quoi.xyz> in
5745         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00093.html>.
5746         * lib/gen-uni-tables.c (is_nonspacing): For characters with property
5747         Prepended_Concatenation_Mark, return false instead of true.
5748         * lib/uniwidth/width0.h: Regenerated. This assigns width 1 to the
5749         characters U+0600..U+0605, U+06DD, U+070F, U+0890..U+0891, U+08E2,
5750         U+110BD, U+110CD.
5751         * modules/uniwidth/width (configure.ac): Bump required libunistring
5752         version.
5753         * modules/uniwidth/u8-width (configure.ac): Likewise.
5754         * modules/uniwidth/u8-strwidth (configure.ac): Likewise.
5755         * modules/uniwidth/u16-width (configure.ac): Likewise.
5756         * modules/uniwidth/u16-strwidth (configure.ac): Likewise.
5757         * modules/uniwidth/u32-width (configure.ac): Likewise.
5758         * modules/uniwidth/u32-strwidth (configure.ac): Likewise.
5760 2024-02-12  Bruno Haible  <bruno@clisp.org>
5762         Implement a new property, added by Unicode 9.0.0.
5763         * lib/gen-uni-tables.c (is_property_prepended_concatenation_mark): New
5764         function.
5765         (output_properties): Output also the property
5766         prepended_concatenation_mark.
5767         * lib/unictype.in.h (UC_PROPERTY_PREPENDED_CONCATENATION_MARK,
5768         uc_is_property_prepended_concatenation_mark): New declarations.
5769         * m4/unictype_h.m4 (gl_UNICTYPE_H_REQUIRE_DEFAULTS): Initialize
5770         GNULIB_UNICTYPE_PROPERTY_PREPENDED_CONCATENATION_MARK.
5771         * modules/unictype/base (Makefile.am): Substitute
5772         GNULIB_UNICTYPE_PROPERTY_PREPENDED_CONCATENATION_MARK.
5773         * lib/unictype/pr_prepended_concatenation_mark.c: New file.
5774         * lib/unictype/pr_prepended_concatenation_mark.h: New generated file.
5775         * modules/unictype/property-prepended-concatenation-mark: New file.
5776         * tests/unictype/test-pr_prepended_concatenation_mark.c: New generated
5777         file.
5778         * modules/unictype/property-prepended-concatenation-mark-tests: New
5779         file.
5780         * lib/unictype/pr_byname.gperf: Add prepended_concatenation_mark.
5781         * lib/unictype/pr_byname.c
5782         (UC_PROPERTY_INDEX_PREPENDED_CONCATENATION_MARK): New enum item.
5783         (uc_property_byname): Handle it.
5784         * modules/unictype/property-byname (Depends-on): Add
5785         unictype/property-prepended-concatenation-mark.
5786         * modules/unictype/property-all (Depends-on): Likewise.
5787         * MODULES.html.sh (func_all_modules): Add
5788         unictype/property-prepended-concatenation-mark.
5790 2024-02-12  Bruno Haible  <bruno@clisp.org>
5792         posixtm tests: Fix reference to undefined module (regr. 2024-02-09).
5793         * modules/posixtm-tests (Depends-on): Remove strftime. Add
5794         strftime-fixes.
5796 2024-02-12  Bruno Haible  <bruno@clisp.org>
5798         limits-h: Fix BOOL_MAX value.
5799         * lib/limits.in.h (BOOL_MAX): Define to 1, not to 2^BOOL_WIDTH-1.
5800         * tests/test-limits-h.c (main): Change expected value of BOOL_MAX.
5802 2024-02-12  Bruno Haible  <bruno@clisp.org>
5804         stdalign: Document a clang 17 bug.
5805         * doc/posix-headers/stdalign.texi: Mention a clang 17 bug.
5807 2024-02-12  Bruno Haible  <bruno@clisp.org>
5809         getcwd, getcwd-lgpl: Fix configure test.
5810         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Don't redeclare getcwd().
5812 2024-02-12  Florian Weimer  <fweimer@redhat.com>
5814         pthread_mutex_timedlock, pthread-spin: Fix configure test.
5815         * m4/pthread_mutex_timedlock.m4 (gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK): Pass
5816         a pointer of the correct type to pthread_mutex_timedlock.
5817         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Pass a pointer of the correct
5818         type to pthread_spin_init.
5820 2024-02-11  Bruno Haible  <bruno@clisp.org>
5822         Fulfil the obligations of the Unicode license.
5823         * lib/gen-uni-tables.c: Prepend the Unicode license when copying
5824         NameAliases.txt, UnicodeData.txt, NormalizationTest.txt,
5825         GraphemeBreakTest.txt, WordBreakTest.txt.
5826         * tests/unigbrk/GraphemeBreakTest.txt: Prepend the Unicode license.
5827         * tests/uniname/NameAliases.txt: Likewise.
5828         * tests/uniname/UnicodeData.txt: Likewise.
5829         * tests/uninorm/NormalizationTest.txt: Likewise.
5830         * tests/uniwbrk/WordBreakTest.txt: Likewise.
5831         * tests/uniname/HangulSyllableNames.txt: Add public-domain notice.
5833 2024-02-11  Bruno Haible  <bruno@clisp.org>
5835         time_r: Add tests.
5836         * lib/time_r.c: Add comment.
5837         * tests/test-gmtime_r.c: New file.
5838         * tests/test-gmtime_r-mt.c: New file, based on
5839         tests/test-nl_langinfo-mt.c.
5840         * tests/test-localtime_r.c: New file.
5841         * tests/test-localtime_r-mt.c: New file, based on
5842         tests/test-nl_langinfo-mt.c.
5843         * modules/time_r-tests: New file.
5845 2024-02-10  Paul Eggert  <eggert@cs.ucla.edu>
5847         doc: improve warnings about ctime etc.
5848         * doc/posix-functions/asctime.texi (asctime):
5849         * doc/posix-functions/asctime_r.texi (asctime_r):
5850         Say why these functions are typically used mistakenly.
5851         * doc/posix-functions/ctime.texi (ctime):
5852         * doc/posix-functions/ctime_r.texi (ctimef):
5853         Say that they can dump core due to an internal null pointer, too.
5854         * doc/posix-functions/ctime.texi (ctime):
5855         Don’t recommend ctime_r.
5857 2024-02-10  Bruno Haible  <bruno@clisp.org>
5859         havelib: Add support for NetBSD/sparc64.
5860         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On NetBSD/sparc64 in
5861         32-bit mode, search for libraries in /usr/lib/sparc.
5863 2024-02-09  Bruno Haible  <bruno@clisp.org>
5865         ctime, localtime, tzset, wcsftime: Make multithread-safe.
5866         * lib/ctime.c: Include <wchar.h>.
5867         (rpl_ctime): Modify _environ and _wenviron without using _putenv.
5868         * lib/localtime.c: Include <wchar.h>.
5869         (rpl_localtime): Modify _environ and _wenviron without using _putenv.
5870         * lib/tzset.c: Include <wchar.h>.
5871         (rpl_tzset): Modify _environ and _wenviron without using _putenv.
5872         * lib/wcsftime.c (rpl_wcsftime): Likewise.
5874 2024-02-09  Bruno Haible  <bruno@clisp.org>
5876         strftime: Remove module, deprecated in 2017.
5877         * modules/strftime: Remove file.
5878         * NEWS: Mention it.
5880 2024-02-09  Bruno Haible  <bruno@clisp.org>
5882         Avoid suboptimal definition of _GL_HAS_ATTRIBUTE on FreeBSD/sparc64.
5883         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _GL_HAS_ATTRIBUTE only
5884         once.
5886 2024-02-08  Bruno Haible  <bruno@clisp.org>
5888         nstrtime, c-nstrftime tests: Strengthen the tests.
5889         * tests/test-nstrftime.h (FUNC_CHECKED): New function.
5890         (posixtm_test, tzalloc_test, quarter_test, errno_test, locales_test):
5891         Invoke FUNC_CHECKED instead of FUNC.
5893 2024-02-08  Bruno Haible  <bruno@clisp.org>
5895         nstrtime: Fix %p, %P, %r directives' results on NetBSD, Solaris.
5896         * lib/strftime.c: Include <locale.h>, localename.h.
5897         (should_remove_ampm): New function.
5898         (__strftime_internal): On NetBSD and Solaris, remove the AM/PM indicator
5899         from the %p, %r directives' results in specific locales.
5900         * modules/nstrftime (Depends-on): Add localename.
5901         * tests/test-nstrftime.h (locales_test): Update the expected result of
5902         the %r directive.
5903         * doc/posix-functions/strftime.texi: Mention the problem of the %p and
5904         %r directives on NetBSD and Solaris.
5906 2024-02-08  Bruno Haible  <bruno@clisp.org>
5908         nstrtime, c-nstrftime: Fix %c directive's result on NetBSD, Solaris.
5909         * lib/strftime.c (__strftime_internal): On NetBSD and Solaris, remove
5910         the last word of the %c directive's result if it looks like a time zone.
5911         * doc/posix-functions/strftime.texi: Mention this as a restriction of
5912         strftime.
5914 2024-02-07  Bruno Haible  <bruno@clisp.org>
5916         c-nstrftime: Add tests.
5917         * tests/test-c-nstrftime.c: New file, based on tests/test-nstrftime.c.
5918         * tests/test-c-nstrftime-1.sh: New file, based on
5919         tests/test-nstrftime-1.sh.
5920         * tests/test-c-nstrftime-2.sh: New file, based on
5921         tests/test-nstrftime-2.sh.
5922         * modules/c-nstrftime-tests: New file.
5924         c-nstrftime: New module.
5925         Suggested by Paul Eggert.
5926         * lib/strftime.h (c_nstrftime): New declaration.
5927         * lib/c-nstrftime.c: New file.
5928         * lib/strftime.c (FPRINTFTIME): Move fallback definition before its
5929         first use.
5930         (USE_C_LOCALE): Add fallback definition.
5931         If USE_C_LOCALE is set, include c-ctype.h instead of <ctype.h>.
5932         Conditionally include <locale.h>.
5933         (TOUPPER, TOLOWER): Define differently if USE_C_LOCALE is set.
5934         (c_locale_cache, c_locale): New definitions, copied from lib/c-strtod.c.
5935         (c_weekday_names, c_month_names): New variables, based on
5936         glibc/time/strftime_l.c.
5937         (__strftime_internal): Define a_wkday, aw_len, f_wkday, a_month, am_len,
5938         f_month, ampm, ap_len differently for USE_C_LOCALE. Avoid a
5939         'goto underlying_strftime' if USE_C_LOCALE && !HAVE_STRFTIME_L. If
5940         USE_C_LOCALE, use strftime_l() with the C locale object instead of
5941         strftime().
5942         * m4/c-nstrftime.m4: New file, based on m4/nstrftime.m4.
5943         * modules/c-nstrftime: New file, based on modules/nstrftime.
5945 2024-02-07  Bruno Haible  <bruno@clisp.org>
5947         nstrftime: Add tests of all directives, also in non-trivial locales.
5948         * tests/test-nstrftime.h (language_t): New type.
5949         (locales_test): New function.
5950         * tests/test-nstrftime.c: Include <locale.h>, <stdlib.h>.
5951         (main): Invoke setlocale and locales_test.
5952         * tests/test-nstrftime-1.sh: New file.
5953         * tests/test-nstrftime-2.sh: New file, based on tests/test-strtod1.sh.
5954         * modules/nstrftime-tests (Files): Add them. Add m4/locale-fr.m4,
5955         m4/codeset.m4, m4/musl.m4.
5956         (configure.ac): Invoke gt_LOCALE_FR, gt_LOCALE_FR_UTF8, gl_MUSL_LIBC.
5957         (Makefile.am): Link test-nstrftime with $(SETLOCALE_LIB). Test
5958         test-nstrftime-*.sh instead of test-nstrftime.
5960 2024-02-07  Bruno Haible  <bruno@clisp.org>
5962         nstrftime: Work around strftime bug with %r on macOS and FreeBSD.
5963         * lib/strftime.c (__strftime_internal): For %r, don't use the underlying
5964         strftime() directly.
5965         * doc/posix-functions/strftime.texi: Mention the %r bug.
5967 2024-02-07  Paul Eggert  <eggert@cs.ucla.edu>
5969         Assume ‘long long’ support
5970         * modules/strtoimax, modules/strtoumax (Depends-on):
5971         Assume the compiler supports ‘long long’.
5972         This was overlooked in the 2019-12-22 patch
5973         <https://lists.gnu.org/r/bug-gnulib/2019-12/msg00190.html>.
5975 2024-02-07  Bruno Haible  <bruno@clisp.org>
5977         nstrftime: Fix typo in documentation.
5978         Reported by Tim Rice <tim@multitalents.net>.
5979         * lib/strftime.h (nstrftime): Fix typo in comment.
5981 2024-02-07  Bruno Haible  <bruno@clisp.org>
5983         nstrftime tests: Avoid test failures on DragonFly BSD.
5984         * tests/test-nstrftime.h (LT): Disable specific test cases also on
5985         DragonFly BSD.
5987 2024-02-07  Bruno Haible  <bruno@clisp.org>
5989         nstrftime: Modernize.
5990         * lib/strftime.c (__strftime_internal): Make the strftime fallback
5991         declaration ISO C 23 compliant.
5993 2024-02-07  Bruno Haible  <bruno@clisp.org>
5995         nstrftime tests: Avoid test failures on FreeBSD, NetBSD, Android.
5996         * tests/test-nstrftime.h (LT): Disable specific test cases on FreeBSD,
5997         NetBSD, Android.
5999 2024-02-07  Bruno Haible  <bruno@clisp.org>
6001         nstrftime tests: Allow reuse with another function.
6002         * tests/test-nstrftime.h: New file, extracted from
6003         tests/test-nstrftime.c.
6004         (FUNC_NAME, STRINGIFY): New macros.
6005         (posixtm_test, tzalloc_test, quarter_test, errno_test): Use FUNC or
6006         FUNC_NAME instead of nstrftime.
6007         (quarter_test): Rename local variable 'result' to 'fail'.
6008         * tests/test-nstrftime.c: Remove code that moved to test-nstrftime.h.
6009         Include test-nstrftime.h.
6010         (STREQ): Remove redundant macro.
6011         * modules/nstrftime-tests (Files): Add tests/test-nstrftime.h.
6013 2024-02-07  Bruno Haible  <bruno@clisp.org>
6015         nstrftime: Document the nstrftime function.
6016         * lib/strftime.h (nstrftime): Add more comments.
6018 2024-02-06  Bruno Haible  <bruno@clisp.org>
6020         nl_langinfo: Fix fallback list of month names (regression 2014-07-07).
6021         * lib/nl_langinfo.c (nl_langinfo): In the implementation for native
6022         Windows, fix the results for MON_8..MON_12, ALTMON_8..ALTMON_12,
6023         ABMON_8..ABMON_12.
6025 2024-02-06  Bruno Haible  <bruno@clisp.org>
6027         nstrftime: Merge glibc strftime changes.
6028         This incorporates:
6029         2023-02-07 Use 64-bit time_t interfaces in strftime and strptime
6030         * lib/strftime.c [_LIBC] (time_t, __gmtime_r, mktime): Define as macros.
6031         * config/srclist.txt: Update comment regarding glibc/time/strftime_l.c.
6033 2024-02-06  Bruno Haible  <bruno@clisp.org>
6035         nstrftime, fprintftime: Simplify.
6036         * lib/strftime.c: Renamed from lib/nstrftime.c.
6037         (my_strftime): Don't define here.
6038         * lib/nstrftime.c: New file.
6039         * lib/fprintftime.c (my_strftime): New macro.
6040         Include strftime.c, not nstrftime.c.
6041         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Don't define my_strftime in
6042         config.h.
6043         * modules/nstrftime (Files): Add lib/strftime.c.
6044         * modules/fprintftime (Files): Likewise.
6045         * config/srclist.txt: Update comment regarding glibc/time/strftime.c.
6047 2024-02-06  Bruno Haible  <bruno@clisp.org>
6049         Further improve cross-compilation for midipix.
6050         Reported by Ørjan Malde <red@foxi.me>.
6051         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Improve cross-compilation guess
6052         for midipix.
6054 2024-02-05  Paul Eggert  <eggert@cs.ucla.edu>
6056         ctime: improve doc
6057         * doc/posix-functions/asctime.texi (asctime):
6058         * doc/posix-functions/asctime_r.texi (asctime_r):
6059         * doc/posix-functions/ctime_r.texi (ctime_r):
6060         * doc/posix-functions/ctime.texi (ctime):
6061         Mention locale problem of strftime more consistently.  Improve
6062         wording.  For ctime and ctime_r, mention that localtime_r can
6063         fail.
6064         * doc/posix-functions/ctime.texi (ctime): Move history section
6065         to end and spiff up a bit.
6066         * doc/posix-functions/ctime_r.texi (ctime_r): Omit commentary that
6067         assumes traditional SunOS ctime_r API; it was confusing and not
6068         useful for Gnulib apps, which assume the POSIX API.
6070 2024-02-05  Bruno Haible  <bruno@clisp.org>
6072         Further improve cross-compilation for midipix.
6073         Based on patch by Ørjan Malde <red@foxi.me> from
6074         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00004.html>.
6075         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Add cross-compilation guess for
6076         midipix.
6077         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
6078         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Likewise.
6079         * m4/utime.m4 (gl_FUNC_UTIME): Likewise.
6080         * m4/utimens.m4 (gl_UTIMENS): Likewise.
6081         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
6083 2024-02-05  Paul Eggert  <eggert@cs.ucla.edu>
6085         doc: Extend doc of *ctime functions.
6086         * doc/posix-functions/ctime.texi (ctime): Document why we got into
6087         this mess.
6088         * doc/posix-functions/asctime.texi (asctime):
6089         * doc/posix-functions/asctime_r.texi (asctime_r):
6090         * doc/posix-functions/ctime_r.texi (ctime_r):
6091         Refer to ctime’s buffer overflow doc.
6093 2024-02-05  Bruno Haible  <bruno@clisp.org>
6095         snippet/warn-on-use: Add comment.
6096         * lib/warn-on-use.h: Document a restriction of _GL_WARN_ON_USE.
6098 2024-02-03  Paul Eggert  <eggert@cs.ucla.edu>
6100         xalloc-oversized: omit unnecessary cast
6101         * lib/xalloc-oversized.h (__xalloc_oversized): Omit unnecessary
6102         cast of a positive in-range value to size_t.  This seems to be
6103         left over from an older version of the code.
6105         glob: port better to C23
6106         * lib/glob.c: Include <stdckdint.h>.
6107         (size_add_wrapv): Remove.  All uses replaced by ckd_add.
6108         * modules/glob: Depend on stdckdint.
6110         ctime: fix false positive
6111         Problem reported by Bjarni Ingi Gislason in:
6112         https://lists.gnu.org/r/bug-gnulib/2024-02/msg00006.html
6113         * lib/time.in.h (ctime): Do not warn about ctime portability,
6114         as there is a more serious warning about it crashing,
6115         and the two warning directives can cause false alarms.
6117 2024-01-31  Bruno Haible  <bruno@clisp.org>
6119         Implement 3 new properties, added by Unicode 15.1.0.
6120         * lib/gen-uni-tables.c (is_property_id_compat_math_start,
6121         is_property_id_compat_math_continue, is_property_ids_unary_operator):
6122         New functions.
6123         (output_properties): Output also the properties id_compat_math_start,
6124         id_compat_math_continue, ids_unary_operator.
6125         * lib/unictype.in.h (UC_PROPERTY_ID_COMPAT_MATH_START,
6126         UC_PROPERTY_ID_COMPAT_MATH_CONTINUE, UC_PROPERTY_IDS_UNARY_OPERATOR,
6127         uc_is_property_id_compat_math_start,
6128         uc_is_property_id_compat_math_continue,
6129         uc_is_property_ids_unary_operator): New declarations.
6130         * m4/unictype_h.m4 (gl_UNICTYPE_H_REQUIRE_DEFAULTS): Initialize
6131         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_START_DLL_VARIABLE,
6132         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_CONTINUE_DLL_VARIABLE,
6133         GNULIB_UNICTYPE_PROPERTY_IDS_UNARY_OPERATOR_DLL_VARIABLE.
6134         * modules/unictype/base (Makefile.am): Substitute
6135         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_START_DLL_VARIABLE,
6136         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_CONTINUE_DLL_VARIABLE,
6137         GNULIB_UNICTYPE_PROPERTY_IDS_UNARY_OPERATOR_DLL_VARIABLE.
6138         * lib/unictype/pr_id_compat_math_continue.c: New file.
6139         * lib/unictype/pr_id_compat_math_continue.h: New generated file.
6140         * lib/unictype/pr_id_compat_math_start.c: New file.
6141         * lib/unictype/pr_id_compat_math_start.h: New generated file.
6142         * lib/unictype/pr_ids_unary_operator.c: New file.
6143         * modules/unictype/property-id-compat-math-continue: New file.
6144         * modules/unictype/property-id-compat-math-start: New file.
6145         * modules/unictype/property-ids-unary-operator: New file.
6146         * tests/unictype/test-pr_id_compat_math_continue.c: New generated file.
6147         * tests/unictype/test-pr_id_compat_math_start.c: New generated file.
6148         * tests/unictype/test-pr_ids_unary_operator.c: New generated file.
6149         * modules/unictype/property-id-compat-math-continue-tests: New file.
6150         * modules/unictype/property-id-compat-math-start-tests: New file.
6151         * modules/unictype/property-ids-unary-operator-tests: New file.
6152         * lib/unictype/pr_byname.gperf: Add id_compat_math_start,
6153         id_compat_math_continue, ids_unary_operator.
6154         * lib/unictype/pr_byname.c (UC_PROPERTY_INDEX_ID_COMPAT_MATH_START,
6155         UC_PROPERTY_INDEX_ID_COMPAT_MATH_CONTINUE,
6156         UC_PROPERTY_INDEX_IDS_UNARY_OPERATOR): New enum items.
6157         (uc_property_byname): Handle them.
6158         * modules/unictype/property-byname (Depends-on): Add
6159         unictype/property-id-compat-math-continue,
6160         unictype/property-id-compat-math-start,
6161         unictype/property-ids-unary-operator.
6162         * modules/unictype/property-all (Depends-on): Likewise.
6163         * MODULES.html.sh (func_all_modules): Add
6164         unictype/property-id-compat-math-continue,
6165         unictype/property-id-compat-math-start,
6166         unictype/property-ids-unary-operator.
6168 2024-01-30  Bruno Haible  <bruno@clisp.org>
6170         Update to Unicode 15.1.0.
6172         * lib/gen-uni-tables.c (PROP_SENTENCE_TERMINAL): Renamed from
6173         PROP_STERM.
6174         (PROP_IDS_UNARY_OPERATOR, PROP_ID_COMPAT_MATH_CONTINUE,
6175         PROP_ID_COMPAT_MATH_START): New enum items.
6176         (UC_INDIC_CONJUNCT_BREAK_*): New enum items.
6177         (unicode_indic_conjunct_break): New variable.
6178         (fill_properties): Rename local variable propvalue to propcode. Handle
6179         the properties IDS_Unary_Operator, ID_Compat_Math_Continue,
6180         ID_Compat_Math_Start. Parse the InCB values from file
6181         DerivedCoreProperties.txt.
6182         (indic_conjunct_break_as_c_identifier,
6183         output_indic_conjunct_break_test): New functions.
6184         (indic_conjunct_break_table): New variable.
6185         (output_indic_conjunct_break): New function.
6186         (fill_width): Accept spaces at the end of field0 and at the start and
6187         end of field1.
6188         (LBP_QU1, LBP_QU2, LBP_QU3): New enum items, for Unicode TR #14 rules
6189         (LB15a) and (LB15b).
6190         (LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF): New enum items, for Brahmic
6191         scripts.
6192         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
6193         (debug_output_lbp): Print either LBP_QU1 or LBP_QU2 or LBP_QU3 as
6194         LBP_QU. Handle LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
6195         (fill_org_lbp): Accept spaces at the end of field0 and at the start and
6196         end of field1. Recognize LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
6197         (debug_output_org_lbp): Handle LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
6198         (lbp_value_to_string): Handle LBP_QU1, LBP_QU2, LBP_QU3 instead of
6199         LBP_QU. Handle LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
6200         (output_lbrk_rules_as_tables): Treat LBP_QU as macro that maps to three
6201         table rows/columns. Replace rule (LB15) with rules (LB15b) and (LB15a).
6202         (get_wbp): Update such that uniwbrk/wbrkprop.txt comes out as expected.
6203         (main): Invoke output_indic_conjunct_break_test and
6204         output_indic_conjunct_break.
6206         * All generated files under lib/uni* and tests/uni*: Regenerate.
6207         * tests/uniname/NameAliases.txt: Update.
6208         * tests/uniname/UnicodeData.txt: Update.
6209         * tests/uninorm/NormalizationTest.txt: Update.
6210         * tests/unigbrk/GraphemeBreakTest.txt: Update.
6211         * tests/uniwbrk/WordBreakTest.txt: Update.
6213         * lib/unilbrk/lbrktables.h (LBP_QU1, LBP_QU2, LBP_QU3): New enum items,
6214         for Unicode TR #14 rules (LB15a) and (LB15b).
6215         (LBP_QU): Remove enum item.
6216         (LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF): New enum items, for Brahmic
6217         scripts.
6218         (unilbrk_table): Update array bounds.
6219         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks_loop):
6220         Conditionally replace LBP_QU2 with LBP_QU1, for rule (LB15a).
6221         Conditionally replace LBP_QU3 with LBP_QU1, for rule (LB15b).
6222         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks_loop):
6223         Likewise.
6224         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks_loop):
6225         Likewise.
6227         * lib/unictype.in.h (UC_INDIC_CONJUNCT_BREAK_*): New enum values.
6228         (uc_indic_conjunct_break_name, uc_indic_conjunct_break_byname,
6229         uc_indic_conjunct_break): New declarations.
6230         * lib/unictype/incb_byname.c: New file.
6231         * lib/unictype/incb_byname.gperf: New file.
6232         * lib/unictype/incb_name.c: New file.
6233         * lib/unictype/incb_name.h: New file.
6234         * lib/unictype/incb_of.c: New file.
6235         * lib/unictype/incb_of.h: New generated file.
6236         * modules/unictype/incb-all: New file.
6237         * modules/unictype/incb-byname: New file.
6238         * modules/unictype/incb-name: New file.
6239         * modules/unictype/incb-of: New file.
6240         * tests/unictype/test-incb_byname.c: New file.
6241         * tests/unictype/test-incb_name.c: New file.
6242         * tests/unictype/test-incb_of.c: New file.
6243         * tests/unictype/test-incb_of.h: New generated file.
6244         * modules/unictype/incb-byname-tests: New file.
6245         * modules/unictype/incb-name-tests: New file.
6246         * modules/unictype/incb-of-tests: New file.
6248         * lib/unigbrk.in.h (uc_is_grapheme_break, u*_grapheme_next,
6249         u*_grapheme_prev): Add comments.
6250         * lib/unigbrk/u-grapheme-breaks.h (FUNC): Add local variables
6251         incb_consonant_extended, incb_consonant_extended_linker,
6252         incb_consonant_extended_linker_extended. Implement rule (GB9c).
6253         * modules/unigbrk/u8-grapheme-breaks (Depends-on): Add unictype/incb-of.
6254         * modules/unigbrk/u16-grapheme-breaks (Depends-on): Likewise.
6255         * modules/unigbrk/u32-grapheme-breaks (Depends-on): Likewise.
6256         * modules/unigbrk/uc-grapheme-breaks (Depends-on): Likewise.
6257         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Add local variables
6258         incb_consonant_extended, incb_consonant_extended_linker,
6259         incb_consonant_extended_linker_extended. Skip test cases that match rule
6260         (GB9c).
6261         * modules/unigbrk/uc-is-grapheme-break-tests (Depends-on): Add
6262         unictype/incb-of.
6264         * All the affected modules: Bump required libunistring version.
6266 2024-01-30  Bruno Haible  <bruno@clisp.org>
6268         unigbrk/uc-is-grapheme-break tests: Reduce verbosity.
6269         * tests/unigbrk/test-uc-is-grapheme-break.c
6270         (graphemebreakproperty_to_string): Don't print gbp to stdout.
6272 2024-01-30  Bruno Haible  <bruno@clisp.org>
6274         gen-uni-tables: Update copyright year in output.
6275         * lib/gen-uni-tables.c (output_predicate_test, output_predicate,
6276         output_category, output_combclass, output_bidi_category,
6277         output_decimal_digit_test, output_decimal_digit, output_digit_test,
6278         output_digit, output_numeric_test, output_numeric, output_mirror,
6279         output_joining_type_test, output_joining_type,
6280         output_joining_group_test, output_joining_group, output_scripts,
6281         output_scripts_byname, output_blocks, output_ident_category,
6282         output_nonspacing_property, output_lbrk_tables,
6283         output_lbrk_rules_as_tables, output_wbrk_tables, output_gbp_test,
6284         output_gbp_table, output_decomposition_tables,
6285         output_composition_tables, output_simple_mapping_test,
6286         output_simple_mapping, output_casing_rules): Bump copyright year in
6287         output.
6288         * lib/uniname/gen-uninames.lisp (main): Likewise.
6290 2024-01-30  Bruno Haible  <bruno@clisp.org>
6292         gen-uni-tables: Refactor, based on UAX #14 version 49.
6293         * lib/gen-uni-tables.c (get_lbp): Reorder, based on
6294         <https://www.unicode.org/reports/tr14/tr14-49.html#DescriptionOfProperties>.
6295         For LBP_EB, use the "emoji modifier base" property.
6297 2024-01-30  Bruno Haible  <bruno@clisp.org>
6299         unigbrk tests: Tweak error reporting.
6300         * tests/unigbrk/test-ulc-grapheme-breaks.c (main): Print byte values in
6301         upper-case hexadecimal.
6302         * tests/unigbrk/test-u8-grapheme-breaks.c (test_u8_grapheme_breaks):
6303         Print unit values in upper-case hexadecimal.
6304         * tests/unigbrk/test-u16-grapheme-breaks.c (test_u16_grapheme_breaks):
6305         Print unit values with at least 4 hexadecimal digits.
6306         * tests/unigbrk/test-u32-grapheme-breaks.c (test_u32_grapheme_breaks):
6307         Likewise.
6308         * tests/unigbrk/test-uc-grapheme-breaks.c (test_uc_grapheme_breaks):
6309         Print characters with at least 4 hexadecimal digits.
6311 2024-01-30  Bruno Haible  <bruno@clisp.org>
6313         Update copyright year in tests/unictype/*.
6314         * tests/unictype/*: Bump copyright years range to include 2024.
6315         * Makefile (update-copyright): Don't exclude the tests/unictype
6316         directory.
6318 2024-01-29  Patrice Dumas  <pertusus@free.fr>
6320         gendocs: get only targetted manual source and includes, when possible
6321         * build-aux/gendocs.sh: if makeinfo, based on version, has the
6322         --trace-includes option, gather only the targetted manual srcfile and
6323         the included files obtained with makeinfo --trace-includes. In that
6324         case output include files to tar stdin and use -T-. Bruno Haible for
6325         the version comparison and use of tar.
6327 2024-01-29  Bruno Haible  <bruno@clisp.org>
6329         Port FALLTHROUGH to Mac OS X 10.9.
6330         Report and fix by Ryan Carsten Schmidt <gnulib@ryandesign.com>
6331         at <https://savannah.gnu.org/bugs/?63866>.
6332         * m4/gnulib-common.m4 (gl_COMMON_BODY): For _GL_HAS_ATTRIBUTE, don't use
6333         __has_attribute for Apple clang versions < 7000000.
6334         * lib/cdefs.h (__glibc_has_attribute): Don't use __has_attribute for
6335         Apple clang versions < 7000000.
6337 2024-01-29  Bruno Haible  <bruno@clisp.org>
6339         libc-config: Apply lesson learned on 2023-01-13.
6340         * lib/cdefs.h (__glibc_has_attribute): On non-Apple platforms, don't
6341         use __has_attribute for clang versions < 5.0.
6343 2024-01-28  Bruno Haible  <bruno@clisp.org>
6345         host-cpu-c-abi: Let gl_HOST_CPU_C_ABI_32BIT never return 'unknown'.
6346         Reported by Mohammad-Reza Nabipoor <mnabipoor@gnu.org>.
6347         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): Use the list of
6348         always-32-bit CPUs and the list of always-64-bit CPUs also when
6349         gl_HOST_CPU_C_ABI has already been run. As a fallback, use a test of
6350         'sizeof (void *)' to always return 'yes' or 'no', never 'unknown'.
6352 2024-01-27  Paul Eggert  <eggert@cs.ucla.edu>
6354         gendocs: allow other chars in source file names
6355         * build-aux/gendocs.sh: Generalize to also allow leading ‘-’
6356         and newlines (!) in source file names.  Exit if there
6357         is an error creating the tarball.
6359 2024-01-27  Patrice Dumas  <pertusus@free.fr>
6361         gendocs: allow spaces, metacharacters and quotes in source file names
6362         * build-aux/gendocs.sh: output files to tar stdin and use -T- to allow
6363         spaces, metacharacters and quotes in file names.  Bruno Haible
6364         solution.
6366 2024-01-27  Patrice Dumas  <pertusus@free.fr>
6368         gendocs: fix --no-html
6369         * build-aux/gendocs.sh: fix typo in variable name set by --no-html.
6371 2024-01-25  Bruno Haible  <bruno@clisp.org>
6373         execute tests: Avoid test failure on macOS 14.
6374         Reported by Guangyu Li <gl343@cornell.edu> in
6375         <https://lists.gnu.org/archive/html/bug-gettext/2024-01/msg00006.html>.
6376         * tests/test-execute-main.c (main): In the tests 17, 18, 19, 20, use the
6377         file descriptors 15, 16 instead of 10, 11, respectively.
6378         * tests/test-execute-child.c (main): Likewise.
6380 2024-01-25  Bruno Haible  <bruno@clisp.org>
6382         Resolve conflicts for functions introduced in Android API level 35.
6384         * lib/time.in.h (timespec_getres): Consider REPLACE_TIMESPEC_GETRES.
6385         * m4/time_h.m4 (gl_TIME_H_DEFAULTS): Initialize REPLACE_TIMESPEC_GETRES.
6386         * modules/time-h (Makefile.am): Substitute REPLACE_TIMESPEC_GETRES.
6387         * m4/timespec_getres.m4 (gl_FUNC_TIMESPEC_GETRES): Test for
6388         timespec_getres using gl_CHECK_FUNCS_ANDROID instead of
6389         AC_CHECK_FUNCS_ONCE. Conditionally set REPLACE_TIMESPEC_GETRES.
6390         * modules/timespec_getres (Depends-on, configure.ac): Consider
6391         REPLACE_TIMESPEC_GETRES.
6392         * m4/gettime.m4 (gl_GETTIME_RES): Test for timespec_getres using
6393         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
6394         * doc/posix-functions/timespec_getres.texi: Mention the Android API
6395         levels.
6397 2024-01-25  Bruno Haible  <bruno@clisp.org>
6399         Resolve conflicts for functions introduced in Android API level 34.
6401         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE): On platforms without
6402         glibc, test for copy_file_range using gl_CHECK_FUNCS_ANDROID instead of
6403         AC_CHECK_FUNCS_ONCE. Conditionally set REPLACE_COPY_FILE_RANGE.
6404         * doc/glibc-functions/copy_file_range.texi: Mention the Android API
6405         levels.
6407         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test for
6408         posix_spawn_file_actions_addchdir_np and
6409         posix_spawn_file_actions_addfchdir_np using gl_CHECK_FUNCS_ANDROID
6410         instead of AC_CHECK_FUNCS_ONCE.
6411         * m4/posix_spawn_faction_addchdir.m4
6412         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR): Test for
6413         posix_spawn_file_actions_addchdir_np using gl_CHECK_FUNCS_ANDROID
6414         instead of AC_CHECK_FUNCS_ONCE.
6415         * m4/posix_spawn_faction_addfchdir.m4
6416         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR): Test for
6417         posix_spawn_file_actions_addfchdir_np using gl_CHECK_FUNCS_ANDROID
6418         instead of AC_CHECK_FUNCS_ONCE.
6419         * doc/glibc-functions/posix_spawn_file_actions_addchdir_np.texi: Mention
6420         the Android API levels.
6421         * doc/glibc-functions/posix_spawn_file_actions_addfchdir_np.texi:
6422         Likewise.
6424         * lib/string.in.h (memset_explicit): Consider REPLACE_MEMSET_EXPLICIT.
6425         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize
6426         REPLACE_MEMSET_EXPLICIT.
6427         * modules/string (Makefile.am): Substitute REPLACE_MEMSET_EXPLICIT.
6428         * m4/memset_explicit.m4 (gl_FUNC_MEMSET_EXPLICIT): Test for
6429         memset_explicit using gl_CHECK_FUNCS_ANDROID instead of
6430         AC_CHECK_FUNCS_ONCE. Conditionally set REPLACE_MEMSET_EXPLICIT.
6431         * modules/memset_explicit (configure.ac): Consider
6432         REPLACE_MEMSET_EXPLICIT.
6433         * doc/posix-functions/memset_explicit.texi: Mention the Android API
6434         levels.
6436         * m4/freadahead.m4 (gl_FUNC_FREADAHEAD): Test for __freadahead using
6437         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
6438         * lib/freadahead.h: Update comment.
6440 2024-01-25  Bruno Haible  <bruno@clisp.org>
6442         Doc regarding functions introduced in Android API level 33.
6443         * doc/glibc-functions/backtrace.texi: Mention the Android API levels.
6444         * doc/glibc-functions/backtrace_symbols.texi: Likewise.
6445         * doc/glibc-functions/backtrace_symbols_fd.texi: Likewise.
6446         * doc/glibc-functions/preadv2.texi: Likewise.
6447         * doc/glibc-functions/pwritev2.texi: Likewise.
6449 2024-01-25  Bruno Haible  <bruno@clisp.org>
6451         Resolve conflicts for functions introduced in Android API level 30.
6453         * doc/glibc-functions/memfd_create.texi: Mention the Android API levels.
6454         * doc/glibc-functions/mlock2.texi: Likewise.
6455         * doc/glibc-functions/pthread_cond_clockwait.texi: Likewise.
6456         * doc/glibc-functions/pthread_mutex_clocklock.texi: Likewise.
6457         * doc/glibc-functions/pthread_rwlock_clockrdlock.texi: Likewise.
6458         * doc/glibc-functions/pthread_rwlock_clockwrlock.texi: Likewise.
6459         * doc/glibc-functions/renameat2.texi: Likewise.
6460         * doc/glibc-functions/sem_clockwait.texi: Likewise.
6461         * doc/glibc-functions/statx.texi: Likewise.
6463         * lib/threads.in.h (thrd_sleep): Consider REPLACE_THRD_SLEEP.
6464         (thrd_yield): Consider REPLACE_THRD_YIELD.
6465         (mtx_init): Consider REPLACE_MTX_INIT.
6466         (mtx_lock): Consider REPLACE_MTX_LOCK.
6467         (mtx_trylock): Consider REPLACE_MTX_TRYLOCK.
6468         (mtx_timedlock): Consider REPLACE_MTX_TIMEDLOCK.
6469         (mtx_unlock): Consider REPLACE_MTX_UNLOCK.
6470         (mtx_destroy): Consider REPLACE_MTX_DESTROY.
6471         (call_once): Consider REPLACE_CALL_ONCE. Fix warning message.
6472         (cnd_init): Consider REPLACE_CND_INIT.
6473         (cnd_wait): Consider REPLACE_CND_WAIT.
6474         (cnd_timedwait): Consider REPLACE_CND_TIMEDWAIT.
6475         (cnd_signal): Consider REPLACE_CND_SIGNAL.
6476         (cnd_broadcast): Consider REPLACE_CND_BROADCAST.
6477         (cnd_destroy): Consider REPLACE_CND_DESTROY.
6478         (tss_create): Consider REPLACE_TSS_CREATE.
6479         (tss_set): Consider REPLACE_TSS_SET.
6480         (tss_get): Consider REPLACE_TSS_GET.
6481         (tss_delete): Consider REPLACE_TSS_DELETE.
6482         * m4/threads_h.m4 (gl_THREADS_H_DEFAULTS): Initialize REPLACE_CALL_ONCE,
6483         REPLACE_CND_BROADCAST, REPLACE_CND_DESTROY, REPLACE_CND_INIT,
6484         REPLACE_CND_SIGNAL, REPLACE_CND_TIMEDWAIT, REPLACE_CND_WAIT,
6485         REPLACE_MTX_DESTROY, REPLACE_MTX_INIT, REPLACE_MTX_LOCK,
6486         REPLACE_MTX_TIMEDLOCK, REPLACE_MTX_TRYLOCK, REPLACE_MTX_UNLOCK,
6487         REPLACE_THRD_SLEEP, REPLACE_THRD_YIELD, REPLACE_TSS_CREATE,
6488         REPLACE_TSS_DELETE, REPLACE_TSS_GET, REPLACE_TSS_SET.
6489         * modules/threads-h (Makefile.am): Substitute REPLACE_CALL_ONCE,
6490         REPLACE_CND_BROADCAST, REPLACE_CND_DESTROY, REPLACE_CND_INIT,
6491         REPLACE_CND_SIGNAL, REPLACE_CND_TIMEDWAIT, REPLACE_CND_WAIT,
6492         REPLACE_MTX_DESTROY, REPLACE_MTX_INIT, REPLACE_MTX_LOCK,
6493         REPLACE_MTX_TIMEDLOCK, REPLACE_MTX_TRYLOCK, REPLACE_MTX_UNLOCK,
6494         REPLACE_THRD_SLEEP, REPLACE_THRD_YIELD, REPLACE_TSS_CREATE,
6495         REPLACE_TSS_DELETE, REPLACE_TSS_GET, REPLACE_TSS_SET.
6496         * m4/thrd.m4 (gl_FUNC_THRD_CREATE): New macro.
6497         * modules/thrd (configure.ac): Invoke gl_FUNC_THRD_CREATE.
6498         * m4/call_once.m4: New file.
6499         * modules/call_once (Files): Add m4/call_once.m4.
6500         (configure.ac): Invoke gl_FUNC_CALL_ONCE. Consider REPLACE_CALL_ONCE.
6501         * m4/cnd.m4: New file.
6502         * modules/cnd (Files): Add m4/cnd.m4.
6503         (configure.ac): Invoke gl_FUNC_CND_INIT. Consider REPLACE_CND_INIT.
6504         * m4/mtx.m4: New file.
6505         * modules/mtx (Files): Add m4/mtx.m4.
6506         (configure.ac): Invoke gl_FUNC_MTX_INIT. Consider REPLACE_MTX_INIT.
6507         * m4/tss.m4: New file.
6508         * modules/tss (Files): Add m4/tss.m4.
6509         (configure.ac): Invoke gl_FUNC_TSS_CREATE. Consider REPLACE_TSS_CREATE.
6510         * doc/posix-functions/call_once.texi: Mention the Android API levels.
6511         * doc/posix-functions/cnd_broadcast.texi: Likewise.
6512         * doc/posix-functions/cnd_destroy.texi: Likewise.
6513         * doc/posix-functions/cnd_init.texi: Likewise.
6514         * doc/posix-functions/cnd_signal.texi: Likewise.
6515         * doc/posix-functions/cnd_timedwait.texi: Likewise.
6516         * doc/posix-functions/cnd_wait.texi: Likewise.
6517         * doc/posix-functions/mtx_destroy.texi: Likewise.
6518         * doc/posix-functions/mtx_init.texi: Likewise.
6519         * doc/posix-functions/mtx_lock.texi: Likewise.
6520         * doc/posix-functions/mtx_timedlock.texi: Likewise.
6521         * doc/posix-functions/mtx_trylock.texi: Likewise.
6522         * doc/posix-functions/mtx_unlock.texi: Likewise.
6523         * doc/posix-functions/thrd_create.texi: Likewise.
6524         * doc/posix-functions/thrd_current.texi: Likewise.
6525         * doc/posix-functions/thrd_detach.texi: Likewise.
6526         * doc/posix-functions/thrd_equal.texi: Likewise.
6527         * doc/posix-functions/thrd_exit.texi: Likewise.
6528         * doc/posix-functions/thrd_join.texi: Likewise.
6529         * doc/posix-functions/thrd_sleep.texi: Likewise.
6530         * doc/posix-functions/thrd_yield.texi: Likewise.
6531         * doc/posix-functions/tss_create.texi: Likewise.
6532         * doc/posix-functions/tss_delete.texi: Likewise.
6533         * doc/posix-functions/tss_get.texi: Likewise.
6534         * doc/posix-functions/tss_set.texi: Likewise.
6536 2024-01-21  Bruno Haible  <bruno@clisp.org>
6538         readutmp, boot-time: Port to Android NDK r26.
6539         Reported by Po Lu <luangruo@yahoo.com> in
6540         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00063.html>.
6541         * lib/readutmp.h: Update comments.
6542         (UTMP_NAME_FUNCTION): Define as a no-op for Android with HAVE_UTMPX_H.
6544 2024-01-21  Bruno Haible  <bruno@clisp.org>
6546         asyncsafe-spin: Fix link error on various platforms.
6547         * m4/atomic-cas.m4: New file.
6548         * lib/asyncsafe-spin.c: Test HAVE_ATOMIC_COMPARE_AND_SWAP_GCC41 instead
6549         of a condition that considers only __sparc__, __ANDROID__, __ibmxl__.
6550         * lib/pthread-spin.c: Likewise.
6551         * lib/simple-atomic.c: Likewise.
6552         * modules/asyncsafe-spin (Files): Add m4/atomic-cas.m4.
6553         (configure.ac): Require gl_ATOMIC_COMPARE_AND_SWAP.
6554         * modules/pthread-spin: Likewise.
6555         * modules/simple-atomic: Likewise.
6557 2024-01-19  Bruno Haible  <bruno@clisp.org>
6559         fenv-environment: Fix for NetBSD/powerpc.
6560         * m4/fenv-environment.m4 (gl_FENV_ENVIRONMENT): For feupdateenv, use
6561         the same configure test on NetBSD/powerpc as on glibc/hppa.
6562         * doc/posix-functions/feupdateenv.texi: Mention the NetBSD/powerpc bug.
6564         fenv-exceptions-trapping: Avoid a test failure on *BSD/powerpc*.
6565         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests also on
6566         FreeBSD/powerpc* and NetBSD/powerpc*.
6568         fenv-exceptions-state-c99: Fix for FreeBSD/powerpc64 and NetBSD/powerpc.
6569         * m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): On
6570         FreeBSD/powerpc64 and NetBSD/powerpc, set REPLACE_FESETEXCEPTFLAG.
6571         * doc/posix-functions/fesetexceptflag.texi: Mention the FreeBSD and
6572         NetBSD bug.
6574         fenv-*: Avoid test failures on FreeBSD/powerpc64 and NetBSD/powerpc.
6575         On these platforms, FE_ALL_EXCEPT contains additional bits.
6576         * tests/test-fenv-except-tracking-1.c (FE_VXSOFT, FE_VXZDZ): Define
6577         fallbacks.
6578         (main): Allow fetestexcept(FE_ALL_EXCEPT) to contain FE_VXSOFT or
6579         FE_VXZDZ in addition to FE_INVALID.
6580         * tests/test-fenv-except-tracking-4.c (FE_VXSOFT): Define fallback.
6581         (main): Allow fetestexcept(FE_ALL_EXCEPT) to contain FE_VXSOFT in
6582         addition to FE_INVALID.
6583         * tests/test-fenv-env-2.c: Likewise.
6584         * tests/test-fenv-env-3.c: Likewise.
6585         * tests/test-fenv-env-4.c: Likewise.
6586         * tests/test-fenv-env-5.c: Likewise.
6588 2024-01-19  Bruno Haible  <bruno@clisp.org>
6590         fenv-*: Fix test failures on NetBSD 9.3/arm64.
6591         * m4/fenv-exceptions-trapping.m4 (gl_FENV_EXCEPTIONS_TRAPPING): Override
6592         feenableexcept() also on NetBSD/arm64.
6593         * doc/glibc-functions/feenableexcept.texi: Update platforms list.
6595 2024-01-19  Bruno Haible  <bruno@clisp.org>
6597         fenv-*: Avoid test failures on OpenBSD/sparc64.
6598         * tests/test-fenv-except-tracking-2.c (main): On OpenBSD/sparc64, skip
6599         the 'long double' test.
6600         * tests/test-fenv-except-trapping-2.c (main): Skip the 'long double'
6601         tests also on OpenBSD/sparc64.
6603 2024-01-18  Bruno Haible  <bruno@clisp.org>
6605         fenv-rounding: Avoid a test failure on OpenBSD/arm64.
6606         * tests/test-fenv-round.c (test_towardzero, test_upward, test_downward):
6607         Skip the 'long double' tests on OpenBSD/arm64.
6608         * doc/posix-functions/fesetround.texi: Update platforms list.
6610 2024-01-18  Bruno Haible  <bruno@clisp.org>
6612         Avoid test failures in FreeBSD's GB18030 locale.
6613         The FreeBSD 14.0 iconv converter (GB18030 → UTF-8) cannot convert e.g.
6614         0x94 0x32 0xBB 0x34 to U+1D100.
6615         * tests/test-c32isalnum.c (main): Skip the GB18030 locale tests on
6616         FreeBSD, if GL_CHAR32_T_IS_UNICODE (or, equivalently,
6617         GL_CHAR32_T_VS_WCHAR_T_NEEDS_CONVERSION) is defined.
6618         * tests/test-c32isalpha.c (main): Likewise.
6619         * tests/test-c32isblank.c (main): Likewise.
6620         * tests/test-c32iscntrl.c (main): Likewise.
6621         * tests/test-c32isdigit.c (main): Likewise.
6622         * tests/test-c32islower.c (main): Likewise.
6623         * tests/test-c32ispunct.c (main): Likewise.
6624         * tests/test-c32isspace.c (main): Likewise.
6625         * tests/test-c32isupper.c (main): Likewise.
6626         * tests/test-c32isxdigit.c (main): Likewise.
6627         * tests/test-c32rtomb.c (main): Likewise.
6628         * tests/test-c32snrtombs.c (main): Likewise.
6629         * tests/test-c32srtombs.c (main): Likewise.
6630         * tests/test-c32stombs.c (main): Likewise.
6631         * tests/test-c32tolower.c (main): Likewise.
6632         * tests/test-c32toupper.c (main): Likewise.
6633         * tests/test-mbrtoc16.c (main): Likewise.
6634         * tests/test-mbrtoc32.c (main): Likewise.
6635         * tests/test-mbsnrtoc32s.c (main): Likewise.
6636         * tests/test-mbsrtoc32s.c (main): Likewise.
6637         * tests/test-mbstoc32s.c (main): Likewise.
6639 2024-01-18  Bruno Haible  <bruno@clisp.org>
6641         get-rusage-data: Avoid test failure on NetBSD 9.3.
6642         * tests/test-get-rusage-data.c (main): Don't expect a strict increase on
6643         NetBSD systems.
6645 2024-01-18  Bruno Haible  <bruno@clisp.org>
6647         log10l: Work around bug on NetBSD 9.3/arm64.
6648         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Add another test case, taken from
6649         the unit test.
6651 2024-01-18  Bruno Haible  <bruno@clisp.org>
6653         doc: Update regarding <math.h> *l functions on NetBSD 9.3.
6654         * doc/posix-functions/acoshl.texi: Mention the buggy implementation on
6655         NetBSD.
6656         * doc/posix-functions/acosl.texi: Likewise.
6657         * doc/posix-functions/asinhl.texi: Likewise.
6658         * doc/posix-functions/asinl.texi: Likewise.
6659         * doc/posix-functions/atan2l.texi: Likewise.
6660         * doc/posix-functions/atanhl.texi: Likewise.
6661         * doc/posix-functions/atanl.texi: Likewise.
6662         * doc/posix-functions/coshl.texi: Likewise.
6663         * doc/posix-functions/cosl.texi: Likewise.
6664         * doc/posix-functions/erfcl.texi: Likewise.
6665         * doc/posix-functions/erfl.texi: Likewise.
6666         * doc/posix-functions/powl.texi: Likewise.
6667         * doc/posix-functions/sinhl.texi: Likewise.
6668         * doc/posix-functions/sinl.texi: Likewise.
6669         * doc/posix-functions/tanhl.texi: Likewise.
6670         * doc/posix-functions/tanl.texi: Likewise.
6671         * doc/posix-functions/expl.texi: Update NetBSD version info.
6672         * doc/posix-functions/exp2l.texi: Likewise.
6673         * doc/posix-functions/hypotl.texi: Likewise.
6674         * doc/posix-functions/logl.texi: Likewise.
6675         * doc/posix-functions/log10l.texi: Likewise.
6676         * m4/expl.m4 (gl_FUNC_EXPL): Update comments.
6677         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
6678         * m4/hypotl.m4 (gl_FUNC_HYPOTL_WORKS): Likewise.
6679         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
6680         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Likewise.
6682 2024-01-18  Bruno Haible  <bruno@clisp.org>
6684         modfl: Work around bug on NetBSD 9.3/arm64.
6685         * m4/modfl.m4 (gl_FUNC_MODFL): Add test whether modfl basically works.
6686         * doc/posix-functions/modfl.texi: Mention the NetBSD bug.
6688 2024-01-18  Bruno Haible  <bruno@clisp.org>
6690         isnanl: Avoid autoconf warning.
6691         * m4/isnanl.m4 (gl_FUNC_ISNANL): Declare through AC_DEFUN_ONCE.
6693 2024-01-18  Bruno Haible  <bruno@clisp.org>
6695         fmaf, fma, fmal: Work around bugs on OpenBSD 7.4/arm64.
6696         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Use a volatile function pointer
6697         variable to disable clang's inlining.
6698         * m4/fma.m4 (gl_FUNC_FMA_WORKS): Likewise.
6699         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Likewise.
6700         * doc/posix-functions/fmaf.texi: Mention the OpenBSD bug.
6701         * doc/posix-functions/fma.texi: Likewise.
6702         * doc/posix-functions/fmal.texi: Likewise.
6704 2024-01-18  Bruno Haible  <bruno@clisp.org>
6706         doc: Update regarding stable branches.
6707         * doc/gnulib-readme.texi (Stable Branches): Mention new branch
6708         stable-202401. Mention that stable-202301 is no longer updated.
6710 2024-01-17  Bruno Haible  <bruno@clisp.org>
6712         getopt-gnu: Fix out-of-bounds access (regression 2023-12-11).
6713         * lib/getopt.c (process_long_option): Don't set ambig_set[option_index]
6714         if ambig_set is &ambig_fallback.
6716 2024-01-17  Bruno Haible  <bruno@clisp.org>
6718         Improve naming of local variables.
6719         * gnulib-tool, posix-modules, build-aux/relocatable.sh.in,
6720         build-aux/reloc-ldflags, build-aux/install-reloc, tests/init.sh,
6721         m4/argz.m4: Rename save_IFS to saved_IFS.
6722         * m4/*.m4: Rename save_LIBS to saved_LIBS.
6723         * m4/00gnulib.m4, m4/gnulib-common.m4, m4/warn-on-use.m4, m4/wchar_h.m4:
6724         Rename save_ac_compile to saved_ac_compile.
6725         * m4/00gnulib.m4: Rename ac_save_ac_compile to ac_saved_ac_compile.
6726         * m4/gnulib-common.m4: Rename save_ac_compile_for_check_decl to
6727         saved_ac_compile_for_check_decl.
6728         * m4/assert_h.m4, m4/manywarnings.m4, m4/stdalign.m4, m4/visibility.m4:
6729         Rename gl_save_CFLAGS to gl_saved_CFLAGS.
6730         * m4/dirfd.m4: Rename dirfd_save_CFLAGS to gl_saved_CFLAGS.
6731         * m4/include_next.m4, m4/pread.m4, m4/pwrite.m4, m4/termcap.m4,
6732         m4/terminfo.m4: Rename gl_save_CPPFLAGS to gl_saved_CPPFLAGS.
6733         * m4/lib-link.m4: Rename ac_save_CPPFLAGS to acl_save_CPPFLAGS.
6734         * m4/iconv.m4, m4/readline.m4: Rename am_save_CPPFLAGS to
6735         gl_saved_CPPFLAGS.
6736         * m4/gettext.m4: Rename gt_save_CPPFLAGS to gt_saved_CPPFLAGS.
6737         * m4/ansi-c++.m4: Rename gl_save_CXX to gl_saved_CXX.
6738         * m4/manywarnings-c++.m4: Rename gl_save_CXXFLAGS to gl_saved_CXXFLAGS.
6739         * m4/lib-link.m4: Rename acl_save_ifs to acl_saved_IFS.
6740         * m4/lib-prefix.m4: Rename acl_save_IFS to acl_saved_IFS.
6741         * m4/progtest.m4: Rename ac_save_IFS to gt_saved_IFS.
6742         * m4/lib-link.m4: Rename save_libdir to saved_libdir, acl_save_libdir to
6743         acl_saved_libdir.
6744         * m4/ld-version-script.m4: Rename save_LDFLAGS to saved_LDFLAGS.
6745         * m4/acl.m4, m4/getgroups.m4: Rename ac_save_LIBS to gl_saved_LIBS.
6746         * m4/lib-link.m4: Rename ac_save_LIBS to acl_saved_LIBS.
6747         * m4/getdomainname.m4, m4/gethostname.m4, m4/getloadavg.m4,
6748         m4/hostent.m4, m4/inet_ntop.m4, m4/inet_pton.m4,
6749         m4/pthread_mutex_timedlock.m4, m4/pthread_sigmask.m4,
6750         m4/pthread-spin.m4, m4/readutmp.m4, m4/selinux-selinux-h.m4,
6751         m4/servent.m4, m4/socketlib.m4, m4/termcap.m4, m4/terminfo.m4,
6752         m4/thread.m4: Rename gl_save_LIBS to gl_saved_LIBS.
6753         * m4/getaddrinfo.m4, m4/iconv.m4, m4/readline.m4: Rename am_save_LIBS to
6754         gl_saved_LIBS.
6755         * m4/gettext.m4, m4/intlmacosx.m4: Rename gt_save_LIBS to gt_saved_LIBS.
6756         * m4/libunistring.m4: Rename glus_save_LIBS to glus_saved_LIBS.
6757         * m4/nanosleep.m4: Rename nanosleep_save_libs to gl_saved_LIBS.
6758         * m4/lib-prefix.m4: Rename acl_save_prefix to acl_saved_prefix,
6759         acl_save_exec_prefix to acl_saved_exec_prefix.
6760         * m4/configmake.m4: Rename gl_save_<variable> to gl_saved_<variable>.
6761         * m4/terminfo.m4: Likewise.
6762         * m4/gettext.m4: Rename gt_save_<variable> to gt_saved_<variable>.
6763         * m4/javaexec.m4: Rename save_CLASSPATH to gt_saved_CLASSPATH.
6764         * m4/warnings.m4: Rename gl_save_compiler_FLAGS to
6765         gl_saved_compiler_FLAGS.
6766         * lib/pread.c, lib/pwrite.c, lib/read-file.c, lib/tempname.c: Rename
6767         save_errno to saved_errno.
6768         * lib/read-file.c: Rename save_alloc to saved_alloc.
6769         * lib/strptime.c: Rename save_wday to saved_wday, save_mday to
6770         saved_mday, save_mon to saved_mon.
6772 2024-01-16  Paul Eggert  <eggert@cs.ucla.edu>
6774         posixtm: pacify clang 18
6775         Problem reported by Khem Raj in:
6776         https://lists.gnu.org/r/bug-gnulib/2024-01/msg00045.html
6777         * lib/posixtm.c (posixtime): Pacify clang 18 by converting bool to int.
6778         Arguably this is a bug in draft C2x, since the non-pointer args to
6779         ckd_add should promote just like any other expressions do;
6780         but that’s not clang’s fault.
6782 2024-01-07  Jim Meyering  <meyering@meta.com>
6784         update-copyright: handle more cases
6785         * build-aux/update-copyright: Handle cases like gunzip.in
6786         with its two copyright lines.
6787         Making it work required two changes: don't stop upon first match.
6788         And then, when continuing, a little trickiness: knowing that the
6789         final substitution would reset m{}g's "pos()", so save and restore
6790         that, to avoid an infinite loop in some cases.
6791         * tests/test-update-copyright.sh: Add a test for this.
6793 2024-01-15  Paul Eggert  <eggert@cs.ucla.edu>
6795         test-framework-sh: fix spelling typo
6796         * tests/init.sh (setup_): Name local var consistently with
6797         elsewhere in Gnulib, fixing a typo.
6799 2024-01-15  Bruno Haible  <bruno@clisp.org>
6801         test-framework-sh: Improve portability to native Windows and OS/2.
6802         Reported by KO Myung-Hun <komh78@gmail.com> in
6803         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00037.html>.
6804         * tests/init.sh (setup_): Test for an absolute directory name like
6805         Autoconf does.
6807         test-framework-sh: Improve portability to native Windows and OS/2.
6808         Reported by KO Myung-Hun <komh78@gmail.com> in
6809         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00037.html>.
6810         * tests/init.sh (setup_): In new_PATH, use $PATH_SEPARATOR instead of
6811         ':'.
6813         test-framework-sh: Improve portability to native Windows and OS/2.
6814         Reported by KO Myung-Hun <komh78@gmail.com> in
6815         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00037.html>.
6816         * tests/init.sh (setup_): Set IFS, like in Autoconf's _AS_PATH_WALK and
6817         in build-aux/relocatable.sh.in.
6819 2024-01-12  Bruno Haible  <bruno@clisp.org>
6821         jit/cache tests: Fix link error.
6822         * modules/jit/cache-tests (Makefile.am): Link test-cache with
6823         $(LIBINTL).
6825 2024-01-12  Bruno Haible  <bruno@clisp.org>
6827         qsort_r: Fix compilation error in C++ mode on FreeBSD 14.0/powerpc64.
6828         * lib/stdlib.in.h (qsort_r): Enable the C++ alias warning only on glibc
6829         systems.
6831 2024-01-11  Bruno Haible  <bruno@clisp.org>
6833         time: Fix test failure on FreeBSD 12.2/sparc64.
6834         * m4/time.m4 (gl_FUNC_TIME): Guess that it does not work on
6835         FreeBSD/sparc.
6836         * doc/posix-functions/time.texi: Mention the bug on FreeBSD/sparc.
6838 2024-01-11  Bruno Haible  <bruno@clisp.org>
6840         gnulib-tool: Reject broken 'join' program as seen in macOS, FreeBSD etc.
6841         Reported by Avinash Sonawane <rootkea@gmail.com> in
6842         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00028.html>.
6843         * gnulib-tool: Move the func_gnulib_dir and func_tmpdir invocations
6844         ahead. If the 'join' program exists but does not handle missing fields,
6845         bail out.
6847 2024-01-10  Bruno Haible  <bruno@clisp.org>
6849         jit/cache tests: Fix for powerpc64le CPUs.
6850         * tests/jit/test-cache.c: Treat Linux/powerpc64le *not* like AIX.
6852 2024-01-10  Bruno Haible  <bruno@clisp.org>
6854         jit/cache tests: Avoid gcc -Wstrict-aliasing warning on Linux/powerpc64.
6855         * tests/jit/test-cache.c (funcptr_to_structptr): Turn into an inline
6856         function.
6858 2024-01-10  Bruno Haible  <bruno@clisp.org>
6860         jit/cache tests: Fix for arm CPUs with GCC target arm-linux-gnueabihf.
6861         * tests/jit/test-cache.c (CODE): Define differently on arm.
6862         (SET_CODE, IS, SET_IS): New macros.
6863         (main): New variables is_of_return1, is_of_return2. Use the SET_CODE and
6864         SET_IS macros.
6866 2024-01-10  Bruno Haible  <bruno@clisp.org>
6868         jit/cache tests: Avoid compiler warnings on OpenBSD.
6869         * tests/jit/test-cache.c (main): New variables size_of_return1,
6870         size_of_return2.
6872 2024-01-09  Bruno Haible  <bruno@clisp.org>
6874         jit/cache: Fix for ia64 CPUs.
6875         * lib/jit/cache.h (clear_cache): On ia64 CPUs, use the 'fc', 'sync',
6876         'srlz' instructions.
6878 2024-01-09  Bruno Haible  <bruno@clisp.org>
6880         jit/cache: Fix for hppa CPUs.
6881         * lib/jit/cache.h (clear_cache): On hppa CPUs, use the 'fdc' and 'fic'
6882         instructions.
6884         jit/cache tests: Avoid test failure on OpenBSD.
6885         * tests/jit/test-cache.c (return1_code, return2_code): New constants.
6886         (main): On OpenBSD, use return1_code and return2_code instead of
6887         CODE (return1) and CODE (return2), since the latter may not be in a
6888         readable memory area.
6890         jit/cache tests: Avoid test failure on hppa CPUs.
6891         * tests/jit/test-cache.c (FUNCPTR_BIAS): New macro.
6892         (structptr_to_funcptr, funcptr_to_structptr): New functions/macros.
6893         (xcopy_structptr): Renamed from xcopy_funcptr. Mark as inline.
6894         (COPY_FUNCPTR, CODE): Use structptr_to_funcptr, funcptr_to_structptr.
6895         * modules/jit/cache-tests (configure.ac): Require AC_C_INLINE.
6897 2024-01-08  Bruno Haible  <bruno@clisp.org>
6899         jit/cache tests: Fix for powerpc*, ia64, hppa* CPUs.
6900         * modules/jit/cache-tests (Depends-on): Add xalloc.
6901         * tests/jit/test-cache.c: Include xalloc.h.
6902         (FUNCPTR_POINTS_TO_CODE, COPY_FUNCPTR): New macros.
6903         (xcopy_funcptr): New function.
6904         (main): Create a copy of the function pointer return1, so as not to
6905         destructively modify return1. Fix memcpy argument.
6907 2024-01-08  Bruno Haible  <bruno@clisp.org>
6909         jit/cache tests: Port to native Windows.
6910         * tests/jit/test-cache.c (main): On native Windows, use VirtualAlloc
6911         instead of mmap.
6913 2024-01-08  Bruno Haible  <bruno@clisp.org>
6915         jit/cache tests: Avoid test failure on OpenBSD.
6916         * modules/jit/cache-tests (Files): Add m4/warnings.m4.
6917         (configure.ac): Set and substitute DISABLE_OPENBSD_RETGUARD.
6918         (Makefile.am): Set test_cache_CFLAGS.
6919         * tests/jit/test-cache.c (main): If the compiler defines _RET_PROTECTOR,
6920         skip the test.
6922 2024-01-08  Bruno Haible  <bruno@clisp.org>
6924         jit/cache tests: Avoid test failure on CentOS, *BSD, macOS.
6925         * tests/jit/test-cache.c: Include <fcntl.h>, <stdio.h>, <stdlib.h>.
6926         Don't include pagealign_alloc.h. Include clean-temp-simple.h. Don't test
6927         HAVE_MPROTECT.
6928         (struct func): Fix #if conditions.
6929         (main): Don't invoke pagealign_xalloc and mprotect. Instead, invoke mmap,
6930         using a temporary file if needed.
6931         * modules/jit/cache-tests (Files): Add m4/mmap-anon.m4.
6932         (Depends-on): Add clean-temp-simple. Remove pagealign_alloc.
6933         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Don't test for mprotect.
6935 2024-01-07  Paul Eggert  <eggert@cs.ucla.edu>
6937         doc: adjust to texinfo 7.1
6938         * doc/Makefile (MAKEINFO): Adjust to texinfo 7.1, where makeinfo
6939         by default outputs ASCII approximations to characters.
6941 2024-01-02  Bruno Haible  <bruno@clisp.org>
6943         strverscmp: Work around bug in musl libc 1.2.3 and in Cygwin.
6944         Reported by Dmitry Bogatov <KAction@gnu.org> via Simon Josefsson in
6945         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00002.html>.
6946         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize REPLACE_STRVERSCMP.
6947         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Test whether strverscmp works
6948         and set REPLACE_STRVERSCMP if not.
6949         * lib/string.in.h (strverscmp): Consider REPLACE_STRVERSCMP.
6950         * modules/strverscmp (Depends-on, configure.ac): Likewise.
6951         * modules/string (Makefile.am): Substitute REPLACE_STRVERSCMP.
6952         * tests/test-strverscmp.c (main): Add test cases suggested by Dmitry
6953         Bogatov and by Simon Josefsson.
6954         * doc/glibc-functions/strverscmp.texi: Mention the musl and Cygwin bug.
6955         Update version info regarding FreeBSD.
6957 2024-01-01  Paul Eggert  <eggert@cs.ucla.edu>
6959         update-copyright-tests: immunize against self
6960         Problem reported by Bernhard Voelker in:
6961         https://lists.gnu.org/r/bug-gnulib/2024-01/msg00003.html
6962         * tests/test-update-copyright.sh (ight): New var.
6963         Use it in tests, to prevent update-copyright from
6964         messing with the test data.
6966 2023-12-29  Paul Eggert  <eggert@cs.ucla.edu>
6968         tests: don’t skip if LONG_MAX < pid
6969         * modules/pthread_sigmask-tests, modules/sigprocmask-tests:
6970         (Depends-on): Add inttypes.
6971         * tests/test-pthread_sigmask1.c, tests/test-sigprocmask.c:
6972         Include inttypes.h.
6973         (main): Don’t skip test if pid exceeds LONG_MAX.
6975         Omit no-longer-needed pragmas
6976         * lib/anytostr.c, lib/poll.c, lib/regex.c:
6977         Omit pragmas that should no longer be needed.
6979         gnulib-common: suppress -Wtautological-constant-out-of-range-compare
6980         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Pass
6981         -Wno-tautological-constant-out-of-range-compare to clang, as it’s
6982         the warning is enabled by default and in portable code where type
6983         ranges are platform dependent it is generally more trouble than
6984         it’s worth.
6986 2023-12-29  Simon Josefsson  <simon@josefsson.org>
6988         announce-gen: Improve links.
6989         * build-aux/announce-gen: Use https:// URLs.
6991 2023-12-29  Bruno Haible  <bruno@clisp.org>
6993         error: More clang -Winclude-next-absolute-path silencing.
6994         * modules/error (Include): Suggest <error.h>, not "error.h".
6995         * tests/test-error.c: Write #include <error.h>.
6996         * tests/test-exclude.c: Likewise.
6997         * tests/test-verror.c: Likewise.
6998         * tests/test-xstrtol.c: Likewise.
7000 2023-12-28  Paul Eggert  <eggert@cs.ucla.edu>
7002         include_next: pacify clang -Winclude-next-absolute-path
7003         Without this change, Ubuntu clang version 16.0.6 (15) issues
7004         warnings like this: “In file included from xalloc-die.c:25:
7005         ./error.h:28:3: warning: #include_next in file found relative to
7006         primary source file or found by absolute path; will search from
7007         start of include path [-Winclude-next-absolute-path]”.
7008         And sure enough, each file includes itself rather than the
7009         next include file and it’s only the subsidiary include that
7010         gets around to including the next include file.
7011         * lib/argmatch.c, lib/chdir-long.c, lib/clean-temp-simple.c:
7012         * lib/clean-temp.c, lib/closein.c, lib/closeout.c, lib/copy-acl.c:
7013         * lib/copy-file.c, lib/creat.c, lib/csharpcomp.c:
7014         * lib/csharpexec.c, lib/error.c, lib/exclude.c, lib/execute.c:
7015         * lib/faccessat.c, lib/fopen.c, lib/freopen.c, lib/getopt.c:
7016         * lib/getopt1.c, lib/git-merge-changelog.c, lib/javacomp.c:
7017         * lib/javaexec.c, lib/javaversion.c, lib/mkdir-p.c, lib/open.c:
7018         * lib/openat-die.c, lib/openat.c, lib/os2-spawn.c:
7019         * lib/pagealign_alloc.c, lib/pipe-filter-gi.c:
7020         * lib/pipe-filter-ii.c, lib/same.c, lib/set-acl.c:
7021         * lib/sigpipe-die.c, lib/spawn-pipe.c, lib/sys_socket.c, lib/truncate.c:
7022         * lib/unistd.c, lib/verror.c, lib/wait-process.c, lib/wctype-h.c:
7023         * lib/xalloc-die.c, lib/xfreopen.c, lib/xmemcoll.c, lib/xprintf.c:
7024         * lib/xsetenv.c, lib/xstdopen.c, lib/xstrtol-error.c:
7025         Use ‘#include <foo.h>’ instead of ‘#include "foo.h"’ if foo.h
7026         possibly uses #include_next.  (However, don’t do this on OSF/1
7027         which has its own problems.)
7029         stat-time: fix macOS bug with negative file times
7030         macOS has a bug similar (but not identical) to Solaris when
7031         file timestamps are negative: tv_nsec might go negative.
7032         Problem reported on Darwin 8.11.0 for GNU Tar by Gordon Steemson in:
7033         https://lists.gnu.org/r/bug-tar/2023-12/msg00001.html
7034         This was evidently Mac OS X 10.4.11; I reproduced it on
7035         Darwin 21.6.0 (macOS 12.6 build 21G115).
7036         * lib/stat-time.h (STAT_TIMESPEC_OFFSETOF): New macro.
7037         (stat_time_normalize): Also normalize timestamps on macOS.
7038         * m4/fstat.m4 (gl_FUNC_FSTAT):
7039         * m4/fstatat.m4 (gl_FUNC_FSTATAT):
7040         * m4/lstat.m4 (gl_FUNC_LSTAT):
7041         * m4/stat.m4 (gl_FUNC_STAT):
7042         Also replace on macOS.
7044 2023-12-19  Bruno Haible  <bruno@clisp.org>
7046         jit/cache: Fix compilation error on m68k, sparc, etc.
7047         * lib/jit/cache.h: Include <stdint.h>.
7048         * modules/jit/cache (Depends-on): Add stdint.
7050 2023-12-19  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
7052         jit/cache tests: Make more portable.
7053         * tests/jit/test-cache.c (CODE): New macro.
7054         (struct func): New type.
7055         (main): Initialize f more carefully.
7056         * modules/jit/cache-tests (Depends-on): Add host-cpu-c-abi.
7058 2023-12-19  Christian Göttsche  <cgzones@googlemail.com>
7060         selinux-h: add stubs and wrappers for raw counterparts
7061         Add stubs and wrappers of already covered libselinux interfaces for
7062         their `raw` counterparts.  These counterparts perform the same
7063         operation except for context translation.  Context translation is used
7064         to convert SELinux labels to human readable form, see mcstransd(8).
7065         * lib/se-selinux.in.h: Add declarations for raw variants.
7066         * lib/se-label.in.h: Likewise.
7067         * lib/getfilecon.c: Add wrappers for problematic raw variants.
7068         * m4/selinux-selinux-h.m4: Use wrappers for problematic raw variants.
7070 2023-12-14  Paul Eggert  <eggert@cs.ucla.edu>
7072         mcel-tests: fix thinko in test
7073         * tests/test-mcel.c (main): Fix typo in mcel_scanz test.
7074         Problem reported by Bruno Haible in:
7075         https://lists.gnu.org/r/bug-gnulib/2023-12/msg00034.html
7077 2023-12-11  Paul Eggert  <eggert@cs.ucla.edu>
7079         savedir: scale better when sorting by name
7080         * lib/savedir.c: Include attribute.h.
7081         (direntry_t): The ‘name’ member is now idx_t, not char *,
7082         so that it survives name_space relocation.
7083         (direntry_cmp_name, direntry_cmp_inode, comparison_function):
7084         Adjust to qsort_r API, and to direntry_t layout change.
7085         (streamsavedir): Redo to avoid need for xstrdup on each directory
7086         entry.  Instead, copy the string data into name_space; this
7087         typically scales better as the memory allocator is called O(log N)
7088         rather than O(N) times.  Use qsort_r so that name_space can be
7089         passed to the comparison functions.  Simplify calls to ‘free’ so
7090         that lack of leakage is more obvious.
7091         * modules/savedir (Depends-on): Add attribute, qsort_r.
7093         getopt: pacify gcc -Wanalyzer-null-dereference
7094         * lib/getopt.c (process_long_option): Simplify logic slightly.
7095         This pacifies gcc -flto -Wanalyzer-null-dereference when compiling
7096         GNU tar on x86-64 with gcc 13.2.1 20231205 (Red Hat 13.2.1-6).
7098 2023-12-10  Pádraig Brady  <P@draigBrady.com>
7100         bootstrap: fix option propagation with --bootstrap-sync
7101         * top/bootstrap: Ensure options are propagated through
7102         upgrade_bootstrap().
7103         * top/bootstrap-funclib.sh: Likewise.
7104         * build-aux/bootstrap: Auto generated with `make build-aux/bootstrap`.
7105         Fixes https://bugs.gnu.org/67731
7107 2023-12-01  Paul Eggert  <eggert@cs.ucla.edu>
7109         frexp, frexpf: pacify clang re address-of-volatile
7110         Problem reported by Sam James in:
7111         https://lists.gnu.org/r/bug-gnulib/2023-12/msg00013.html
7112         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Don’t try to convert
7113         ‘double volatile *’ to ‘void const *’ as the C standard
7114         doesn’t allow accessing volatile variables through
7115         pointer-to-nonvolatile.
7116         * m4/frexpf.m4 (gl_FUNC_FREXPF_WORKS): Likewise.
7118         Update portability doc for CHERI, C23
7119         * doc/gnulib-readme.texi:
7120         Prefer “null pointer” to “@code{NULL}” since C23 has nullptr.
7121         (Portability guidelines): Mention C99 instead of C89 for what
7122         Gnulib assumes of headers.
7123         (C99 features avoided): Mention CHERI issue with intptr_t etc.
7124         (Other portability assumptions): Say that C23 requires two’s
7125         complement.  Mention CHERI’s holes.
7127 2023-12-01  Bruno Haible  <bruno@clisp.org>
7129         obstack: Avoid undefined behaviour.
7130         Reported by Alexey Palienko <Alexey.Palienko@cma.se> in
7131         <https://lists.gnu.org/archive/html/bug-m4/2023-02/msg00000.html>.
7132         * lib/obstack.in.h: Include <stdint.h>.
7133         (__BPTR_ALIGN): Remove macro.
7134         (__PTR_ALIGN): For the optimized case, compute the alignment through
7135         uintptr_t, instead of computing NULL + something.
7137 2023-12-01  Bruno Haible  <bruno@clisp.org>
7139         doc: Update for FreeBSD 14.0.
7140         * doc/posix-headers/*.texi: Update.
7141         * doc/glibc-headers/*.texi: Likewise.
7142         * doc/posix-functions/*.texi: Likewise.
7143         * doc/pastposix-functions/*.texi: Likewise.
7144         * doc/glibc-functions/*.texi: Likewise.
7145         * m4/printf.m4: Update comments.
7147 2023-12-01  Bruno Haible  <bruno@clisp.org>
7149         sethostname tests: Fix a compilation error on FreeBSD 14.0.
7150         * tests/test-sethostname1.c: Skip the SIGNATURE_CHECK on some platforms.
7151         * doc/glibc-functions/sethostname.texi: Update platforms list.
7153 2023-11-27  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
7155         stack: Fix documentation in header file.
7156         * lib/stack.h: Correct documentation on `stack_current_base'.
7158 2023-11-27  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
7160         jit/cache-tests: Fix include guard.
7161         * tests/jit/test-cache.c (main): Extend range of include guard.
7163 2023-11-25  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
7165         jit/cache-tests: New module.
7166         * tests/jit/test-cache.c: New file.
7167         * modules/jit/cache-tests: New file.  Mark the test as unportable
7168         for now.
7170 2023-11-25  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
7172         jit/cache: Fix configure error.
7173         * m4/valgrind-helper.m4: Unconditionally set support_valgrind.
7175 2023-11-24  Bruno Haible  <bruno@clisp.org>
7177         floorf, ceilf tests: Strengthen against compiler optimizations.
7178         Reported by René Rebe <rene@t2-project.org>.
7179         * tests/test-floorf1.c (main): Mark my_floorf as 'volatile'.
7180         * tests/test-floorf-ieee.c (main): Likewise.
7181         * tests/test-ceilf1.c (main): Mark my_ceilf as 'volatile'.
7182         * tests/test-ceilf-ieee.c (main): Likewise.
7184 2023-11-21  Bruno Haible  <bruno@clisp.org>
7186         strerrorname_np: Work around glibc bug on HPPA systems.
7187         * m4/strerrorname_np.m4 (gl_FUNC_STRERRORNAME_NP): Test also
7188         strerrorname_np (ENOSYM).
7189         * lib/strerrorname_np.c (strerrorname_np): Update comments.
7190         * tests/test-strerrorname_np.c (main): Likewise.
7191         * doc/glibc-functions/strerrorname_np.texi: Mention that glibc 2.37
7192         still needs a workaround.
7194 2023-11-21  Bruno Haible  <bruno@clisp.org>
7196         rand: Use the usual patterns for overriding a function.
7197         * lib/stdlib.in.h (RAND_MAX): Override also if module 'rand' is present.
7198         (rand): New declaration.
7199         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_RAND.
7200         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_RAND.
7201         * modules/stdlib (Makefile.am): Substitute GNULIB_RAND and REPLACE_RAND.
7203 2023-11-18  Bruno Haible  <bruno@clisp.org>
7205         nan, snan tests: Don't include these tests by default.
7206         * modules/nan-tests (Status): Mark the test as unportable.
7207         * modules/snan-tests (Status): Likewise.
7209 2023-11-17  Bruno Haible  <bruno@clisp.org>
7211         realloc-gnu: Fix wrong configure test result with optimizing ibm-clang.
7212         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Use 'volatile', to defeat an
7213         ibm-clang optimization.
7214         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Likewise.
7216 2023-11-17  Bruno Haible  <bruno@clisp.org>
7218         mbrtowc, mbrtoc32, nl_langinfo, setlocale-null: Obey --disable-threads.
7219         Reported by David Edelsohn <dje.gcc@gmail.com> in
7220         <https://gcc.gnu.org/pipermail/gcc-patches/2023-November/636830.html>,
7221         <https://gcc.gnu.org/pipermail/gcc-patches/2023-November/636843.html>.
7222         * m4/threadlib.m4 (gl_THREADLIB_BODY): If --disable-threads was
7223         specified, define AVOID_ANY_THREADS to 1.
7224         * lib/mbtowc-lock.c: Omit all code if --disable-threads was specified.
7225         * lib/nl_langinfo-lock.c: Likewise.
7226         * lib/setlocale-lock.c: Likewise.
7227         * lib/mbtowc-lock.h: Omit locking code if --disable-threads was
7228         specified.
7229         * lib/nl_langinfo.c: Likewise.
7230         * lib/setlocale_null.c: Likewise.
7231         * lib/mbrtowc.c: Don't include any multithreading headers if
7232         --disable-threads was specified.
7233         * lib/mbrtoc32.c: Likewise.
7235 2023-11-17  Bruno Haible  <bruno@clisp.org>
7237         gettext: Recognize a statically built libintl on macOS and AIX.
7238         Reported by David Edelsohn <dje.gcc@gmail.com> in
7239         <https://gcc.gnu.org/pipermail/gcc-patches/2023-November/636558.html>.
7240         * m4/gettext.m4 (AM_GNU_GETTEXT): In the
7241         "checking for GNU gettext in libintl..." test, add also the special
7242         system library dependencies needed on macOS and AIX.
7244 2023-11-16  Bruno Haible  <bruno@clisp.org>
7246         boot-time: Make it work on Adélie Linux.
7247         * lib/boot-time.c (get_boot_time_uncached): Invoke Linux fallbacks also
7248         on Linux systems that have neither <utmp.h> nor <utmpx.h>.
7250 2023-11-15  Bruno Haible  <bruno@clisp.org>
7252         obstack: Modernize, fixing several problems.
7253         * lib/obstack.in.h: Renamed from lib/obstack.h. Add reference to the
7254         glibc documentation.
7255         (_OBSTACK_INTERFACE_VERSION): Remove macro.
7256         (_OBSTACK_SIZE_T, _CHUNK_SIZE_T, _OBSTACK_CAST): Mark old values with
7257         _LIBC.
7258         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
7259         _obstack_memory_used, _obstack_allocated_p): Override if REPLACE_OBSTACK
7260         is 1.
7261         * lib/obstack.c: Don't include <gnu-versions.h>.
7262         (_OBSTACK_ELIDE_CODE): Remove macro.
7263         * m4/obstack.m4 (gl_FUNC_OBSTACK): Test whether obstack.h exists. Don't
7264         define HAVE_OBSTACK any more. Set HAVE_OBSTACK, REPLACE_OBSTACK,
7265         GL_GENERATE_OBSTACK_H.
7266         * modules/obstack (Files): Remove obstack.h. Add obstack.in.h.
7267         (Depends-on): Add gen-header. Add conditions.
7268         (configure.ac): Consider HAVE_OBSTACK, REPLACE_OBSTACK. Invoke
7269         gl_CONDITIONAL_HEADER and AC_PROG_MKDIR_P.
7270         (Makefile.am): Generate obstack.h. Augment BUILT_SOURCES and
7271         MOSTLYCLEANFILES.
7273 2023-11-15  Paul Eggert  <eggert@cs.ucla.edu>
7275         striconveha: pacify gcc -Wcast-align
7276         * lib/striconveha.c (uniconv_register_autodetect): Rewrite to
7277         avoid the need to cast from char * to a pointer to a more strictly
7278         aligned type.  Use decls after statements to avoid some repetition.
7280 2023-11-14  Bruno Haible  <bruno@clisp.org>
7282         doc: Mention a 'random' limitation on OpenBSD.
7283         Reported by Corinna Vinschen <vinschen@redhat.com>.
7284         * doc/posix-functions/random.texi: Mention the OpenBSD limitation.
7286 2023-11-14  Bruno Haible  <bruno@clisp.org>
7288         rand: Mark as obsolete.
7289         * modules/rand (Status, Notice): New sections.
7291 2023-11-14  Bruno Haible  <bruno@clisp.org>
7293         *printf-posix: Revert expectations of %lc of 0.
7294         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LC): Expect a NUL byte in the
7295         output.
7296         * lib/vasnprintf.c (VASNPRINTF): In the %lc implementation, don't
7297         special-case the NUL wide character.
7298         * tests/test-vasnprintf-posix.c (test_function): Change expected result
7299         for %lc of L'\0'.
7300         * tests/test-vasprintf-posix.c (test_function): Likewise.
7301         * tests/test-snprintf-posix.h (test_function): Likewise.
7302         * tests/test-sprintf-posix.h (test_function): Likewise.
7303         * doc/posix-functions/dprintf.texi: Update platform list regarding %lc
7304         of 0 bug.
7305         * doc/posix-functions/fprintf.texi: Likewise.
7306         * doc/posix-functions/printf.texi: Likewise.
7307         * doc/posix-functions/snprintf.texi: Likewise.
7308         * doc/posix-functions/sprintf.texi: Likewise.
7309         * doc/posix-functions/vdprintf.texi: Likewise.
7310         * doc/posix-functions/vfprintf.texi: Likewise.
7311         * doc/posix-functions/vprintf.texi: Likewise.
7312         * doc/posix-functions/vsnprintf.texi: Likewise.
7313         * doc/posix-functions/vsprintf.texi: Likewise.
7314         * doc/glibc-functions/asprintf.texi: Likewise.
7315         * doc/glibc-functions/vasprintf.texi: Likewise.
7316         * doc/glibc-functions/obstack_printf.texi: Likewise.
7317         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
7319 2023-11-13  Bruno Haible  <bruno@clisp.org>
7321         doc: Add a note.
7322         * doc/posix-headers/stdatomic.texi: Add a note about the memory model.
7324 2023-11-13  Bruno Haible  <bruno@clisp.org>
7326         Don't use CHERI facilities with CC="clang -march=morello".
7327         Suggested by Jessica Clarke <jrtc27@jrtc27.com> in
7328         <https://lists.gnu.org/archive/html/bug-gnulib/2023-11/msg00116.html>.
7329         * lib/alignalloc.h (alignalloc): Test __CHERI_PURE_CAPABILITY__, not
7330         __CHERI__.
7331         * lib/eealloc.h (eemalloc, eerealloc): Likewise.
7332         * lib/ialloc.h (irealloc, ireallocarray): Likewise.
7333         * lib/malloca.h (malloca): Likewise.
7334         * lib/malloca.c (small_t, mmalloca, freea): Likewise.
7335         * lib/rawmemchr.c (rawmemchr): Likewise.
7336         * lib/safe-alloc.h (safe_alloc_realloc_n): Likewise.
7337         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): Likewise.
7338         * lib/ssfmalloc.h (struct dissected_page_header, init_small_block_page,
7339         init_medium_block_page, free_block_from_pool, allocate_block): Likewise.
7340         * tests/test-stdint.c: Likewise.
7342 2023-11-13  Bruno Haible  <bruno@clisp.org>
7344         jit/cache: Fix configure test.
7345         * m4/valgrind-helper.m4 (gl_VALGRIND_HELPER): Check already at configure
7346         time whether <valgrind/valgrind.h> exists. Fix AC_DEFINE_UNQUOTED
7347         invocation.
7349 2023-11-12  Paul Eggert  <eggert@cs.ucla.edu>
7351         rawmemchr: speed up, particularly on CHERI
7352         * lib/rawmemchr.c (rawmemchr) [__CHERI__]: Use memchr instead of
7353         one-byte reads.  This sped up a simple benchmark (rawmemchr on
7354         100,000 bytes) by 6x on a Research Morello SoC r0p0 on CheriBSD 14.
7355         [!__CHERI__]: Use sizeof, not alignof, as better alignment
7356         should help performance a bit on some platforms.
7357         * modules/rawmemchr (Depends-on): Remove alignasof.
7359 2023-11-12  Bruno Haible  <bruno@clisp.org>
7361         jit/cache: New module.
7362         * lib/jit/cache.h: New file.
7363         * m4/valgrind-helper.m4: New file.
7364         * modules/jit/cache: New file.
7366 2023-11-11  Bruno Haible  <bruno@clisp.org>
7368         ssfmalloc: Take advantage of CHERI bounds-checking.
7369         * lib/ssfmalloc.h: Include <cheri.h>.
7370         (struct dissected_page_header) [CHERI]: Add field 'whole_page'.
7371         (init_small_block_page, init_medium_block_page) [CHERI]: Initialize it.
7372         (free_block_from_pool) [CHERI]: Use this field to initialize
7373         pool->freeable_page.
7374         (allocate_block) [CHERI]: Return a pointer with a tight upper bound.
7376 2023-11-11  Johannes Schindelin  <johannes.schindelin@gmx.de>
7378         vasnprintf: Re-enable parsing of directive with I64 (regr. 2023-03-24).
7379         * lib/printf-parse.c (PRINTF_PARSE): When parsing a size specifier
7380         "I64", increment cp by 3, not 1.
7382 2023-11-11  Bruno Haible  <bruno@clisp.org>
7384         malloca: Take advantage of CHERI bounds-checking.
7385         * lib/malloca.h: Include <cheri.h>.
7386         (malloca) [CHERI]: In the stack-allocation case, return a pointer with
7387         a tight lower bound and a tight upper bound.
7388         * lib/malloca.c: Include <cheri.h>.
7389         (small_t) [CHERI]: Define as uintptr_t.
7390         (mmalloca) [CHERI]: Return a pointer with a tight upper bound.
7391         (freea) [CHERI]: Update.
7393 2023-11-11  Bruno Haible  <bruno@clisp.org>
7395         safe-alloc: Take advantage of CHERI bounds-checking.
7396         * lib/safe-alloc.h: Include <cheri.h>.
7397         (safe_alloc_realloc_n): When count or size is 0, return a pointer whose
7398         bounds are of size 0, not 1.
7400 2023-11-11  Bruno Haible  <bruno@clisp.org>
7402         ialloc: Take advantage of CHERI bounds-checking.
7403         * lib/ialloc.h: Include <cheri.h>.
7404         (irealloc): When s is 0, return a pointer whose bounds are of size 0,
7405         not 1.
7406         (ireallocarray): When n or s is 0, return a pointer whose bounds are of
7407         size 0, not 1.
7409 2023-11-11  Bruno Haible  <bruno@clisp.org>
7411         eealloc: Take advantage of CHERI bounds-checking.
7412         * lib/eealloc.h: Include <cheri.h>.
7413         (eemalloc): When n is 0, return a pointer whose bounds are of size 0,
7414         not 1.
7415         (eerealloc): Likewise.
7417 2023-11-11  Bruno Haible  <bruno@clisp.org>
7419         alignalloc: Take advantage of CHERI bounds-checking.
7420         * lib/alignalloc.h: Include <cheri.h>.
7421         (alignalloc): When size is 0, return a pointer whose bounds are of
7422         size 0, not 1.
7424 2023-11-11  Bruno Haible  <bruno@clisp.org>
7426         rawmemchr tests: Add test case for last commit.
7427         * tests/test-rawmemchr.c (main): Add test case for aligned oversized
7428         read.
7430 2023-11-11  Paul Eggert  <eggert@cs.ucla.edu>
7432         rawmemchr: port better to CHERI
7433         * lib/rawmemchr.c (rawmemchr): Use unsigned char for longword,
7434         since CHERI doesn’t allow the aligned-word trick to speed up
7435         performance.
7437 2023-11-10  Paul Eggert  <eggert@cs.ucla.edu>
7439         di-set: port better to CHERI-64
7440         * lib/di-set.c: Include stdint.h.
7441         (hashint): Make it uintptr_t, not size_t, since it’s for use
7442         when converting to pointer and back again.  This suppresses
7443         a false positive on CHERI-64.
7444         * modules/di-set (Depends-on): Add stdint.
7446         stdio: fix port to older macOS
7447         * lib/stdio.in.h: It’s pre macOS 13, not pre macOS 10.13.
7448         Problem reported by Sevan Janiyan in:
7449         https://lists.gnu.org/r/bug-gnulib/2023-11/msg00066.html
7450         et seq.
7452 2023-11-10  Bruno Haible  <bruno@clisp.org>
7454         doc: Mention rand and srand limitations.
7455         * doc/posix-functions/rand.texi: Mention multithread-safety problem.
7456         * doc/posix-functions/srand.texi: Mention a Cygwin bug.
7458 2023-11-10  Bruno Haible  <bruno@clisp.org>
7460         tests: In multithreaded tests, use random() instead of rand().
7461         * tests/test-asyncsafe-spin2.c (random_account, lock_mutator_thread):
7462         Use random() instead of rand().
7463         * tests/test-lock.c (random_account, lock_mutator_thread,
7464         rwlock_mutator_thread, recshuffle): Likewise.
7465         * tests/test-mtx.c (random_account, lock_mutator_thread, recshuffle):
7466         Likewise.
7467         * tests/test-pthread-mutex.c (random_account, lock_mutator_thread,
7468         recshuffle): Likewise.
7469         * tests/test-pthread-rwlock.c (random_account, rwlock_mutator_thread):
7470         Likewise.
7471         * tests/test-pthread-spin.c (random_account, lock_mutator_thread):
7472         Likewise.
7473         * tests/test-pthread-tss.c (perhaps_yield, worker_thread,
7474         racecheck_thread): Likewise.
7475         * tests/test-thread_local.c (perhaps_yield, worker_thread): Likewise.
7476         * tests/test-tls.c (perhaps_yield, worker_thread, racecheck_thread):
7477         Likewise.
7478         * tests/test-tss.c (perhaps_yield, worker_thread, racecheck_thread):
7479         Likewise.
7480         * asyncsafe-spin-tests (Depends-on): Add random.
7481         * lock-tests (Depends-on): Likewise.
7482         * mtx-tests (Depends-on): Likewise.
7483         * pthread-mutex-tests (Depends-on): Likewise.
7484         * pthread-rwlock-tests (Depends-on): Likewise.
7485         * pthread-spin-tests (Depends-on): Likewise.
7486         * pthread-tss-tests (Depends-on): Likewise.
7487         * threads-h-tests (Depends-on): Likewise.
7488         * tls-tests (Depends-on): Likewise.
7489         * tss-tests (Depends-on): Likewise.
7491 2023-11-10  Bruno Haible  <bruno@clisp.org>
7493         doc: Mention an srandom limitation on OpenBSD.
7494         * doc/posix-functions/srandom.texi: Mention the OpenBSD limitation.
7496 2023-11-10  Bruno Haible  <bruno@clisp.org>
7498         random tests: Add multithread-safety test.
7499         * tests/test-random-mt.c: New file.
7500         * modules/random-tests (Files): Add it.
7501         (Depends-on): Add xalloc, thread, yield.
7502         (Makefile.am): Also build and test test-random-mt.
7504         random: Fix multithread-safety bug in general.
7505         * m4/random.m4 (gl_FUNC_RANDOM): Override also macOS, FreeBSD, Solaris,
7506         Cygwin, Haiku.
7507         * doc/posix-functions/random.texi: Mention the wider scope of the
7508         multithread-safety bug.
7510 2023-11-09  Bruno Haible  <bruno@clisp.org>
7512         sigsegv: Improve port to CHERI.
7513         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): Define also on CheriBSD.
7515         sigsegv: Port to CHERI.
7516         * lib/sigsegv.c: Treat __aarch64__ like __arm64__.
7517         (SIGSEGV_FOR_ALL_SIGNALS): Treat SIGPROT like SIGSEGV and SIGBUS.
7519 2023-11-09  Paul Eggert  <eggert@cs.ucla.edu>
7521         stdio: port better to older macOS
7522         * lib/stdio.in.h: Do not define _POSIX_C_SOURCE on older macOS,
7523         as it is not needed and defining it causes other problems.
7524         Problem reported by Sevan Janiyan in:
7525         https://mail.gnu.org/r/bug-gnulib/2023-11/msg00039.html
7527 2023-11-09  Bruno Haible  <bruno@clisp.org>
7529         rand: Add tests.
7530         * tests/test-rand.c: New file.
7531         * modules/rand-tests: New file.
7533         rand: New module.
7534         * lib/rand.c: New file, based on glibc/stdlib/rand.c.
7535         * m4/rand.m4: New file.
7536         * modules/rand: New file.
7537         * doc/posix-functions/rand.texi: Mention the new module.
7539 2023-11-09  Bruno Haible  <bruno@clisp.org>
7541         random: Fix multithread-safety bug on CheriBSD.
7542         * m4/random.m4 (gl_FUNC_RANDOM): Override on CheriBSD.
7543         * lib/random.c: Include glthread/lock.h.
7544         (__libc_lock_define_initialized, __libc_lock_lock, __libc_lock_unlock):
7545         Define to do real locking.
7546         * modules/random (Depends-on): Add lock.
7547         * doc/posix-functions/random.texi: Mention the multithread-safety
7548         problem.
7550 2023-11-09  Bruno Haible  <bruno@clisp.org>
7552         host-cpu-c-abi: Port to CHERI.
7553         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): Treat aarch64c like
7554         aarch64.
7556 2023-11-08  Bruno Haible  <bruno@clisp.org>
7558         pthread-rwlock: Port to Mac OS X 10.4.
7559         Reported by Sevan Janiyan <venture37@geeklan.co.uk>.
7560         * m4/pthread-rwlock.m4 (gl_PTHREAD_RWLOCK): On macOS, test for the
7561         presence of PTHREAD_RWLOCK_INITIALIZER. If it is not defined, don't
7562         attempt to use pthread_rwlock_init.
7564 2023-11-07  Bruno Haible  <bruno@clisp.org>
7566         fenv-environment tests: Add a test of the link dependencies.
7567         * tests/test-fenv-env-6.c: Renamed from tests/test-fenv-env-5.c.
7568         * tests/test-fenv-env-5.c: Renamed from tests/test-fenv-env-4.c.
7569         * tests/test-fenv-env-4.c: Renamed from tests/test-fenv-env-3.c.
7570         * tests/test-fenv-env-3.c: Renamed from tests/test-fenv-env-2.c.
7571         * tests/test-fenv-env-2.c: Renamed from tests/test-fenv-env-1.c.
7572         * tests/test-fenv-env-1.c: New file.
7573         * tests/test-fenv-env-6.sh: Renamed from tests/test-fenv-env-5.sh. Update.
7574         * modules/fenv-environment-tests: Update. Add test-fenv-env-1 unit test.
7576 2023-11-07  Bruno Haible  <bruno@clisp.org>
7578         fenv-exceptions-state-c99 tests: Add a test of the link dependencies.
7579         * tests/test-fenv-except-state-4.c: Renamed from
7580         tests/test-fenv-except-state-3.c.
7581         * tests/test-fenv-except-state-3.c: Renamed from
7582         tests/test-fenv-except-state-2.c.
7583         * tests/test-fenv-except-state-2.c: Renamed from
7584         tests/test-fenv-except-state-1.c.
7585         * tests/test-fenv-except-state-1.c: New file.
7586         * modules/fenv-exceptions-state-c23-tests: Update.
7587         * modules/fenv-exceptions-state-c99-tests: Update. Add
7588         test-fenv-except-state-1 unit test.
7590 2023-11-07  Bruno Haible  <bruno@clisp.org>
7592         fenv-exceptions-trapping tests: Comments.
7593         * tests/test-fenv-except-trapping-1.c (main): Add a comment.
7595 2023-11-07  Paul Eggert  <eggert@cs.ucla.edu>
7597         malloca: pacify -Wcheri-provenance
7598         This shouldn’t affect generated code when optimizing.
7599         * lib/malloca.c (mmalloca): Pacify -Wcheri-provenance on CHERI-64 cc.
7600         (freea): Assign to temporaries to simplify debugging and avoid casts.
7602 2023-11-07  Bruno Haible  <bruno@clisp.org>
7604         rawmemchr: Port to CHERI.
7605         * lib/rawmemchr.c (rawmemchr): Use 'unsigned long' instead of uintptr_t.
7607 2023-11-06  Paul Eggert  <eggert@cs.ucla.edu>
7609         stdint: port intptr_t to CHERI
7610         * lib/stdint.in.h: Do not redefine intptr_t/uintptr_t
7611         if __INTPTR_WIDTH__ says otherwise.  This is needed on CHERI.
7613         stdint-tests: port to CHERI etc
7614         * tests/test-stdint.c: Test intptr_t only if INTPTR_MAX is
7615         defined, since the type is optional.  Similarly for uintptr_t.
7616         If CHERI, don’t assume TYPE_MINIMUM and TYPE_MAXIMUM works on
7617         intptr_t, and similarly for TYPE_MAXIMUM and uintptr_t.
7619         posix_memalign-tests: port to CHERI-64
7620         * tests/test-posix_memalign.c (main):
7621         Don’t assume sizeof (void *) <= 8.
7623         mcel-tests: fix read overrun in test case
7624         * tests/test-mcel.c (main): Don’t overrun test input buffer.
7625         Problem reported by Bruno Haible; found on CHERI-64.
7627 2023-11-06  Bruno Haible  <bruno@clisp.org>
7629         fenv-exceptions-tracking-c99 tests: Fix typo.
7630         Found by coverity.
7631         * tests/test-fenv-except-tracking-1.c (main): Write & ~, not & !.
7633 2023-11-06  Bruno Haible  <bruno@clisp.org>
7635         snan: Avoid test failures on OpenBSD/mips64.
7636         * tests/test-snan-1.c (main): Skip the 'long double' test on
7637         OpenBSD/mips64.
7638         * tests/test-snan-2.c (main): Likewise.
7640         fenv-*: Avoid test failures on OpenBSD/mips64.
7641         * tests/test-fenv-round.c (test_towardzero, test_upward, test_downward):
7642         Skip the 'long double' tests on OpenBSD/mips64.
7643         * tests/test-fenv-except-tracking-2.c (main): On OpenBSD/mips64, skip
7644         the 'long double' test.
7645         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests and the
7646         'long double' tests also on OpenBSD/mips64.
7647         * doc/posix-functions/fesetround.texi: Mention OpenBSD/mips64 here too.
7649         fenv-exceptions-tracking-c99: Fix test failures on OpenBSD/mips64.
7650         * m4/fenv-exceptions-tracking.m4 (gl_FENV_EXCEPTIONS_TRACKING): On
7651         OpenBSD/mips, set REPLACE_FECLEAREXCEPT to 1.
7652         * doc/posix-functions/feclearexcept.texi: Mention the OpenBSD/mips64
7653         bug.
7654         * m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): No need to set
7655         gl_cv_func_fesetexceptflag_works1 to 'no' on OpenBSD/mips.
7657 2023-11-06  Bruno Haible  <bruno@clisp.org>
7659         nan: Defeat clang's incorrect -O2 optimization on mips64.
7660         * lib/nan.h (NaNf, NaNd, NaNl): Use 'volatile' to disable a clang
7661         optimization.
7663 2023-11-06  Bruno Haible  <bruno@clisp.org>
7665         nan: Work around clang's incorrect constant-folding on mips64.
7666         * lib/nan.h (NaNf, NaNd, NaNl): On mips platforms, avoid the compiler's
7667         constant-folding for 0.0f/0.0f, 0.0/0.0, 0.0L/0.0L.
7669 2023-11-06  Bruno Haible  <bruno@clisp.org>
7671         snan: Add more info for mips-based platforms.
7672         * m4/nan-mips.m4: New file.
7673         * lib/snan.h: Add comments regarding mips.
7674         * modules/snan (Files): Add m4/nan-mips.m4.
7675         (configure.ac): Invoke gl_NAN_MIPS.
7676         * m4/snan.m4: Update comment.
7678 2023-11-06  Bruno Haible  <bruno@clisp.org>
7680         fenv-exceptions-state-c99: Update doc regarding Minix.
7681         * doc/posix-functions/fesetexceptflag.texi: Mention the Minix bug.
7683 2023-11-05  Bruno Haible  <bruno@clisp.org>
7685         fenv-exceptions-trapping: Avoid test failure on Minix.
7686         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests also on
7687         Minix.
7689         fenv-exceptions-tracking-c99: Fix test failures on Minix.
7690         * m4/fenv-exceptions-tracking.m4 (gl_FENV_EXCEPTIONS_TRACKING): On
7691         Minix, set REPLACE_FECLEAREXCEPT and REPLACE_FETESTEXCEPT to 1.
7692         * doc/posix-functions/feclearexcept.texi: Mention the Minix bug.
7693         * doc/posix-functions/fetestexcept.texi: Likewise.
7695 2023-11-05  Bruno Haible  <bruno@clisp.org>
7697         fenv-exceptions-trapping: Avoid test failure on Haiku/i386.
7698         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests also on
7699         Haiku/i386.
7701         fenv-exceptions-state: Fix test failure on Haiku/i386 and Haiku/x86_64.
7702         * m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): Arrange to
7703         override fesetexceptflag() on Haiku.
7704         * doc/posix-functions/fesetexceptflag.texi: Mention the Haiku bug.
7706 2023-11-05  Bruno Haible  <bruno@clisp.org>
7708         fenv: Add C++ tests.
7709         * tests/test-fenv-c++.cc: New file.
7710         * modules/fenv-c++-tests: New file.
7711         * modules/fenv-tests (Depends-on): Add it.
7713 2023-11-05  Bruno Haible  <bruno@clisp.org>
7715         fenv-environment: Add tests.
7716         * tests/test-fenv-env-1.c: New file.
7717         * tests/test-fenv-env-2.c: New file.
7718         * tests/test-fenv-env-3.c: New file.
7719         * tests/test-fenv-env-4.c: New file.
7720         * tests/test-fenv-env-5.sh: New file.
7721         * tests/test-fenv-env-5.c: New file.
7722         * modules/fenv-environment-tests: New file.
7724         fenv-environment: New module.
7725         * lib/fenv.in.h (fenv_t) [hppa]: Remove the __exception field.
7726         (FE_DFL_ENV): Override if <fenv.h> exists but HAVE_FE_DFL_ENV is not
7727         defined.
7728         (fegetenv, fesetenv, feupdateenv, feholdexcept): New declarations.
7729         * lib/fenv-env.c: New file, based on glibc.
7730         * lib/fenv-env-hold.c: New file.
7731         * lib/fenv-env-update.c: New file.
7732         * m4/fenv-environment.m4: New file.
7733         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the 'fenv_t *' type.
7734         * m4/fenv_h.m4 (gl_FENV_H_DEFAULTS): Initialize REPLACE_FEGETENV,
7735         REPLACE_FEHOLDEXCEPT, REPLACE_FESETENV, REPLACE_FEUPDATEENV.
7736         * modules/fenv (Makefile.am): Substitute REPLACE_FEGETENV,
7737         REPLACE_FEHOLDEXCEPT, REPLACE_FESETENV, REPLACE_FEUPDATEENV.
7738         * modules/fenv-environment: New file.
7739         * doc/posix-functions/fegetenv.texi: Mention the new module and the bugs
7740         on glibc, macOS, AIX.
7741         * doc/posix-functions/feholdexcept.texi: Mention the new module and the
7742         bugs on glibc, musl libc, FreeBSD, AIX, mingw, MSVC.
7743         * doc/posix-functions/fesetenv.texi: Mention the new module and the bugs
7744         on musl libc, FreeBSD, NetBSD, AIX, Solaris, Cygwin, mingw, MSVC.
7745         * doc/posix-functions/feupdateenv.texi: Mention the new module and the
7746         bugs on glibc, musl libc, macOS, FreeBSD, AIX, Solaris, mingw, MSVC.
7748 2023-11-05  Bruno Haible  <bruno@clisp.org>
7750         fenv-exceptions-tracking-c99 tests: Enhance tests.
7751         * tests/test-fenv-except-tracking-3.sh: Test not only FE_INVALID, but
7752         also FE_DIVBYZERO, FE_OVERFLOW, FE_UNDERFLOW, FE_INEXACT.
7753         * tests/test-fenv-except-tracking-3.c: Include <stdlib.h>, <string.h>.
7754         Don't include fpe-trapping.h. Assume HAVE_FPE_TRAPPING is 1.
7755         (main): Receive the exception to test as first argument.
7757 2023-11-05  Bruno Haible  <bruno@clisp.org>
7759         fpe-trapping: Simplify.
7760         * lib/fpe-trapping.h (sigfpe_on_invalid): Remove all platform specific
7761         code. Just rely on feclearexcept and feenableexcept.
7762         * m4/fpe-trapping.m4: Renamed from m4/fpe.m4.
7763         (gl_FPE_TRAPPING): Greatly simplify.
7764         * modules/fpe-trapping (Files): Use m4/fpe-trapping.m4 instead of
7765         m4/fpe.m4. Remove m4/mathfunc.m4, m4/musl.m4.
7766         (Depends-on): Add fenv-exceptions-trapping.
7767         * tests/test-fenv-except-state-2.c (main): Update skip message.
7768         * tests/test-fenv-except-tracking-2.c (main): Likewise.
7769         * tests/test-fenv-except-tracking-3.c (main): Likewise.
7770         * tests/test-fenv-except-tracking-5.c (main): Likewise.
7771         * tests/test-nan-2.c (main): Likewise.
7772         * tests/test-snan-2.c (main): Likewise.
7774 2023-11-05  Bruno Haible  <bruno@clisp.org>
7776         fpe-tracking: Remove module.
7777         * modules/fpe-tracking: Remove file.
7778         * m4/fpe.m4 (gl_FPE_TRACKING): Remove macro.
7779         (gl_FPE_TRAPPING): Require gl_FENV_EXCEPTIONS_TRACKING instead of
7780         gl_FPE_TRACKING. Use FENV_EXCEPTIONS_TRACKING_LIBM instead of
7781         FPE_TRACKING_LIBM.
7782         * modules/nan-tests (Depends-on): Add fenv-exceptions-tracking-c99.
7783         Remove fpe-tracking.
7784         (Makefile.am): Use FENV_EXCEPTIONS_TRACKING_LIBM instead of
7785         FPE_TRACKING_LIBM.
7786         * modules/snan-tests (Depends-on): Add fenv-exceptions-tracking-c99.
7787         Remove fpe-tracking.
7788         (Makefile.am): Use FENV_EXCEPTIONS_TRACKING_LIBM instead of
7789         FPE_TRACKING_LIBM.
7790         * tests/test-nan-1.c: Assume HAVE_FE_INVALID is 1.
7791         * tests/test-snan-1.c: Likewise.
7793 2023-11-05  Bruno Haible  <bruno@clisp.org>
7795         fenv-exceptions-trapping: Avoid test failure on NetBSD/sparc.
7796         * tests/test-fenv-except-trapping-2.c (main): Skip the 'long double'
7797         tests also on NetBSD/sparc.
7799 2023-11-05  Bruno Haible  <bruno@clisp.org>
7801         fenv-exceptions-trapping: Update documentation.
7802         * doc/glibc-functions/feenableexcept.texi: Document the Linux/hppa
7803         problem.
7805 2023-11-05  Bruno Haible  <bruno@clisp.org>
7807         fenv-exceptions-trapping: Avoid test failure on older systems.
7808         * tests/test-fenv-except-trapping-2.c (main): Skip the test also on x86
7809         systems with gcc < 8.
7811 2023-11-04  Bruno Haible  <bruno@clisp.org>
7813         fenv-exceptions-trapping: Fix for powerpc* platforms.
7814         * lib/fenv-except-trapping.c (feenableexcept, fedisableexcept)
7815         [powerpc]: Use the correct bit mask for the trap bits.
7816         * tests/test-fenv-except-trapping-2.c (main): Reenable the '9' tests on
7817         powerpc platforms.
7819 2023-11-04  Bruno Haible  <bruno@clisp.org>
7821         fenv-exceptions-state-c99: Fix compilation error on FreeBSD.
7822         * lib/fenv.in.h (fegetexceptflag, fesetexceptflag): On FreeBSD, use an
7823         rpl_ prefix, to avoid a conflict with an inline definition in FreeBSD's
7824         <fenv.h>.
7826 2023-11-04  Bruno Haible  <bruno@clisp.org>
7828         doc: Update info about Cygwin feraiseexcept bug.
7829         * doc/posix-functions/feraiseexcept.texi: Update info regarding Cygwin.
7831 2023-11-04  Bruno Haible  <bruno@clisp.org>
7833         fenv-exceptions-tracking-c99 tests: Avoid test failure on NetBSD/sparc.
7834         * tests/test-fenv-except-tracking-2.c (main): On NetBSD/sparc, skip the
7835         'long double' test.
7837 2023-11-04  Bruno Haible  <bruno@clisp.org>
7839         fenv-exceptions-tracking-c99: Fix fetestexcept() override for AIX.
7840         * lib/fenv-except-tracking-test.c (fetestexcept): On AIX, use
7841         fp_read_flag() rather than the fpscr register.
7843 2023-11-04  Bruno Haible  <bruno@clisp.org>
7845         fenv-exceptions-tracking-c99: Work around a NetBSD/x86_64 bug.
7846         * m4/fenv-exceptions-tracking.m4 (gl_FENV_EXCEPTIONS_TRACKING): On
7847         NetBSD/x86_64, set REPLACE_FETESTEXCEPT to 1.
7848         * doc/posix-functions/fetestexcept.texi: Document the NetBSD bug.
7850 2023-11-04  Bruno Haible  <bruno@clisp.org>
7852         fenv-rounding: Avoid a test failure on NetBSD/sparc64.
7853         * tests/test-fenv-round.c (test_towardzero, test_upward, test_downward):
7854         Skip the 'long double' tests on NetBSD/sparc64.
7855         * doc/posix-functions/fesetround.texi: Mention the problem with
7856         'long double' operations on some platforms.
7858 2023-11-04  Bruno Haible  <bruno@clisp.org>
7860         fenv-rounding: Improve code for MSVC.
7861         * lib/fenv-round.c (fegetround) [MSVC]: Use the rounding direction from
7862         the SSE unit. Don't assume stable values for FE_UPWARD and FE_DOWNWARD.
7863         (fesetround) [MSVC]: Set the rounding direction only in the SSE unit.
7864         Don't assume stable values for FE_UPWARD and FE_DOWNWARD.
7866 2023-11-04  Bruno Haible  <bruno@clisp.org>
7868         fenv-rounding et al.: Require AC_CANONICAL_HOST before accessing $host.
7869         * m4/fenv-rounding.m4 (gl_FENV_ROUNDING): Require AC_CANONICAL_HOST.
7870         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Likewise.
7871         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
7872         * m4/iswdigit.m4 (gl_FUNC_ISWDIGIT): Likewise.
7873         * m4/iswpunct.m4 (gl_FUNC_ISWPUNCT): Likewise.
7874         * m4/iswxdigit.m4 (gl_FUNC_ISWXDIGIT): Likewise.
7875         * m4/strerrorname_np.m4 (gl_FUNC_STRERRORNAME_NP): Likewise.
7876         * m4/strfmon_l.m4 (gl_FUNC_STRFMON_L): Likewise.
7877         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
7878         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Likewise.
7879         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Likewise.
7880         * m4/wcsncmp.m4 (gl_FUNC_WCSNCMP): Likewise.
7882 2023-11-04  Bruno Haible  <bruno@clisp.org>
7884         fenv: Document an ABI break on MSVC.
7885         * doc/posix-headers/fenv.texi: Document why fegetround and fesetround
7886         are seemingly broken on MSVC.
7888 2023-10-31  Bruno Haible  <bruno@clisp.org>
7890         fenv-exceptions-trapping: Add tests.
7891         * tests/test-fenv-except-trapping-1.c: New file.
7892         * tests/test-fenv-except-trapping-2.sh: New file.
7893         * tests/test-fenv-except-trapping-2.c: New file.
7894         * modules/fenv-exceptions-trapping-tests: New file.
7896         fenv-exceptions-trapping: New module.
7897         * lib/fenv.in.h (feenableexcept, fedisableexcept, fegetexcept): New
7898         declarations.
7899         * lib/fenv-except-trapping.c: New file, based on glibc.
7900         * m4/fenv_h.m4 (gl_FENV_H): Test also whether fegetexcept is declared.
7901         * m4/fenv-exceptions-trapping.m4: New file.
7902         * modules/fenv-exceptions-trapping: New file.
7903         * doc/glibc-functions/fegetexcept.texi: Mention the new module.
7904         * doc/glibc-functions/fedisableexcept.texi: Likewise.
7905         * doc/glibc-functions/feenableexcept.texi: Likewise. Mention the glibc,
7906         macOS, FreeBSD bugs.
7908 2023-10-30  Bruno Haible  <bruno@clisp.org>
7910         fenv-exceptions-state-c99: Fix the x86_64 and i386 case.
7911         * lib/fenv-except-state-set.c (fesetexceptflag): Make sure to restore
7912         the exception trap bits in all cases.
7914 2023-10-30  Bruno Haible  <bruno@clisp.org>
7916         fenv-exceptions-state-c23: Add tests.
7917         * tests/test-fenv-except-state-3.c: New file.
7918         * modules/fenv-exceptions-state-c23-tests: New file.
7920         fenv-exceptions-state-c23: New module.
7921         * lib/fenv.in.h (fetestexceptflag): New declaration.
7922         * lib/fenv-except-state-test.c: New file, based on glibc.
7923         * m4/fenv-exceptions-state-c23.m4: New file.
7924         * modules/fenv-exceptions-state-c23: New file.
7925         * doc/posix-functions/fetestexceptflag.texi: Mention the new module.
7927 2023-10-30  Bruno Haible  <bruno@clisp.org>
7929         fenv-exceptions-state-c99: Add tests.
7930         * tests/test-fenv-except-state-1.c: New file.
7931         * tests/test-fenv-except-state-2.c: New file.
7932         * modules/fenv-exceptions-state-c99-tests: New file.
7934         fenv-exceptions-state-c99: New module.
7935         * lib/fenv.in.h (fegetexceptflag, fesetexceptflag): New declarations.
7936         * lib/fenv-except-state-get.c: New file, based on glibc.
7937         * lib/fenv-except-state-set.c: New file, based on glibc.
7938         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the 'fexcept_t *' type.
7939         * m4/fenv-exceptions-state.m4: New file.
7940         * modules/fenv-exceptions-state-c99: New file.
7941         * doc/posix-functions/fegetexceptflag.texi: Mention the new module.
7942         * doc/posix-functions/fesetexceptflag.texi: Mention the new module and
7943         the glibc, musl libc, macOS, AIX, mingw bugs.
7945 2023-10-30  Bruno Haible  <bruno@clisp.org>
7947         fenv-exceptions-tracking-{c99,c23}: Fix the x86_64 and i386 case.
7948         * lib/fenv-except-tracking-clear.c (feclearexcept): Make sure to restore
7949         the exception trap bits in all cases.
7950         * lib/fenv-except-tracking-raise.c (feraiseexcept): Likewise.
7951         * lib/fenv-except-tracking-set.c (fesetexcept): Likewise.
7953 2023-10-29  Bruno Haible  <bruno@clisp.org>
7955         fenv-exceptions-tracking-c23: Add tests.
7956         * tests/test-fenv-except-tracking-4.c: New file.
7957         * tests/test-fenv-except-tracking-5.c: New file.
7958         * modules/fenv-exceptions-tracking-c23-tests: New file.
7960         fenv-exceptions-tracking-c23: New module.
7961         * lib/fenv.in.h (fesetexcept): New declaration.
7962         * lib/fenv-except-tracking-set.c: New file, based on glibc.
7963         * lib/fenv-private.h (_GETMSR, _SETMSR, MSR_FP_EXC_MASK, PR_SET_FPEXC,
7964         PR_FP_EXC_DISABLED, PR_FP_EXC_NONRECOV, PR_FP_EXC_ASYNC,
7965         PR_FP_EXC_PRECISE, prctl) [NetBSD/powerpc]: New macros.
7966         * m4/fenv-exceptions-tracking-c23.m4: New file.
7967         * modules/fenv-exceptions-tracking-c23: New file.
7968         * doc/posix-functions/fesetexcept.texi: Mention the new module and the
7969         glibc bugs.
7971 2023-10-28  Bruno Haible  <bruno@clisp.org>
7973         fenv-exceptions-tracking-c99: Fix feraiseexcept (FE_OVERFLOW) on MSVC.
7974         * lib/fenv-except-tracking-raise.c (feraiseexcept): Use the generic
7975         approach for all exceptions.
7977 2023-10-28  Bruno Haible  <bruno@clisp.org>
7979         fpe-trapping: Always clear the FE_INVALID exception flag first.
7980         * lib/fpe-trapping.h: Include <fenv.h> on all platforms.
7981         (sigfpe_on_invalid) [AIX, HP-UX, IRIX, Solaris] : Clear the FE_INVALID
7982         exception flag first.
7983         * modules/fpe-trapping (Depends-on): Add fenv-exceptions-tracking-c99.
7985 2023-10-28  Bruno Haible  <bruno@clisp.org>
7987         fenv-exceptions-tracking-c99: Add tests.
7988         * tests/test-fenv-except-tracking-1.c: New file.
7989         * tests/test-fenv-except-tracking-2.sh: New file.
7990         * tests/test-fenv-except-tracking-2.c: New file.
7991         * tests/test-fenv-except-tracking-3.sh: New file.
7992         * tests/test-fenv-except-tracking-3.c: New file.
7993         * modules/fenv-exceptions-tracking-c99-tests: New file.
7995         fenv-exceptions-tracking-c99: New module.
7996         * lib/fenv.in.h (feclearexcept, feraiseexcept, fetestexcept): New
7997         declarations.
7998         * lib/fenv-except-tracking-clear.c: New file, based on glibc.
7999         * lib/fenv-except-tracking-raise.c: New file, based on glibc.
8000         * lib/fenv-except-tracking-test.c: New file, based on glibc.
8001         * m4/fenv-exceptions-tracking.m4: New file.
8002         * m4/fenv-exceptions.m4: New file.
8003         * modules/fenv-exceptions-tracking-c99: New file.
8004         * doc/posix-functions/feclearexcept.texi: Mention the new module.
8005         * doc/posix-functions/fetestexcept.texi: Likewise.
8006         * doc/posix-functions/feraiseexcept.texi: Likewise. Mention the glibc
8007         and Cygwin bugs.
8009 2023-10-27  Bruno Haible  <bruno@clisp.org>
8011         fenv-rounding: Add tests.
8012         * tests/test-fenv-round.c: New file.
8013         * modules/fenv-rounding-tests: New file.
8015         fenv-rounding: New module.
8016         * lib/fenv.in.h (fegetround, fesetround): New declarations.
8017         * lib/fenv-private.h: New file, based on glibc.
8018         * lib/fenv-round.c: New file, based on glibc.
8019         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the type fp_rnd.
8020         * m4/fenv-rounding.m4: New file.
8021         * modules/fenv (Depends-on): Add snippet/c++defs.
8022         (Makefile.am): Substitute $(CXXDEFS_H) into fenv.h.
8023         * modules/fenv-rounding: New file.
8024         * doc/posix-functions/fegetround.texi: Mention the new module.
8025         * doc/posix-functions/fesetround.texi: Likewise.
8027 2023-10-27  Bruno Haible  <bruno@clisp.org>
8029         tests: Use C99 initializer syntax for memory_long_double.
8030         * tests/test-isfinite.c (test_isfinitel): Use '.word = ...' syntax when
8031         initializing memory_long_double variables.
8032         * tests/test-isinf.c (test_isinfl): Likewise.
8033         * tests/test-isnan.c (test_long_double): Likewise.
8034         * tests/test-snprintf-posix.h (test_function): Likewise.
8035         * tests/test-sprintf-posix.h (test_function): Likewise.
8036         * tests/test-vasnprintf-posix.c (test_function): Likewise.
8037         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
8038         * tests/test-vasprintf-posix.c (test_function): Likewise.
8039         * modules/isfinite-tests (Depends-on): Add c99.
8040         * modules/isinf-tests (Depends-on): Likewise.
8041         * modules/isnan-tests (Depends-on): Likewise.
8042         * modules/isnanl-nolibm-tests (Depends-on): Likewise.
8043         * modules/isnanl-tests (Depends-on): Likewise.
8044         * modules/pipe-filter-gi-tests (Depends-on): Likewise.
8045         * modules/pipe-filter-ii-tests (Depends-on): Likewise.
8046         * modules/snprintf-posix-tests (Depends-on): Likewise.
8047         * modules/sprintf-posix-tests (Depends-on): Likewise.
8048         * modules/vasnprintf-posix-tests (Depends-on): Likewise.
8049         * modules/vasnwprintf-posix-tests (Depends-on): Likewise.
8050         * modules/vasprintf-posix-tests (Depends-on): Likewise.
8051         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
8052         * modules/vsprintf-posix-tests (Depends-on): Likewise.
8054 2023-10-26  Pádraig Brady  <P@draigBrady.com>
8056         base32, base64: disallow non-canonical encodings
8057         * lib/base32.c: Check that discarded bits in the encoding are zero.
8058         * lib/base64.c: Likewise.
8059         * tests/test-base32.c: Add test cases.
8060         * tests/test-base64.c: Likewise.
8062 2023-10-26  Bruno Haible  <bruno@clisp.org>
8064         fenv: Add tests.
8065         * tests/test-fenv.c: New file.
8066         * modules/fenv-tests: New file.
8068         fenv: New module.
8069         * lib/fenv.in.h: New file, based on glibc.
8070         * m4/fenv_h.m4: New file.
8071         * modules/fenv: New file.
8072         * doc/posix-headers/fenv.texi: Mention the new module.
8074 2023-10-25  Paul Eggert  <eggert@cs.ucla.edu>
8076         base32: new function isubase32; also, tune.
8077         * lib/base32.c (BASE32_INLINE): Define.
8078         (base32_to_int): Rename from b32 and make it extern.  All uses changed.
8079         (uchar_in_range): Remove.  All uses removed.
8080         (isbase32, base32_decode_ctx_init):
8081         Move to lib/base32.h and make inline.
8082         * lib/base32.h: Ignore -Wtype-limits, so that we needn’t
8083         worry about uchar_in_range.
8084         (BASE32_INLINE): Define, and use _GL_INLINE_HEADER_BEGIN.
8085         (isubase32): New function, useful as it as a different signature.
8086         (isbase32): Define in terms of isubase32.
8087         * modules/base32 (Depends-on): Add extern-inline.
8089         base64: new function isubase64; also, tune.
8090         * lib/base64.c (BASE64_INLINE): Define.
8091         (base64_to_int): Rename from b64 and make it extern.  All uses changed.
8092         (uchar_in_range): Remove.  All uses removed.
8093         (isbase64, base64_decode_ctx_init):
8094         Move to lib/base64.h and make inline.
8095         * lib/base64.h: Ignore -Wtype-limits, so that we needn’t
8096         worry about uchar_in_range.
8097         (BASE64_INLINE): Define, and use _GL_INLINE_HEADER_BEGIN.
8098         (isubase64): New function, useful as it as a different signature.
8099         (isbase64): Define in terms of isubase64.
8100         * modules/base64 (Depends-on): Add extern-inline.
8102 2023-10-24  Paul Eggert  <eggert@cs.ucla.edu>
8104         tests/unistr/u16-chr-tests: pacify -Wcast-align
8105         * tests/unistr/test-chr.h (main): Redo types to pacify
8106         gcc -Wcast-align.
8108         isnanl-tests, stdio-tests: pacify GCC -Wshadow
8109         * tests/test-isnanl.h (NWORDS): Remove.
8110         (memory_long_double): Do not redefine in an inner scope.
8111         All uses changed to use the snan.h memory_long_double.
8112         * tests/test-stdio.c (NWORDS): Remove.
8113         (memory_long_double): Do not redefine in an inner scope.
8114         The snan.h memory_long_double is fine here.
8116         explicit_bzero-tests: pacify GCC 13.2.1
8117         * tests/test-explicit_bzero.c:
8118         * tests/test-memset_explicit.c:
8119         Ignore -Wdangling pointer.
8121 2023-10-22  Bruno Haible  <bruno@clisp.org>
8123         memset_explicit, explicit_bzero tests: Fix test failures with new gcc.
8124         Reported by Sam James <sam@gentoo.org> in
8125         <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111904>.
8126         Fix by Alexandre Oliva <aoliva@gcc.gnu.org>.
8127         * tests/test-memset_explicit.c (do_secret_stuff): Declare with
8128         attributes 'noclone' and 'noipa'.
8129         * tests/test-explicit_bzero.c (do_secret_stuff): Likewise.
8131 2023-10-15  Bruno Haible  <bruno@clisp.org>
8133         net_if tests: Fix gcc warning.
8134         * tests/test-net_if.c: Include <string.h>.
8136 2023-10-15  Bruno Haible  <bruno@clisp.org>
8138         mbspbrk: Fix gcc warning (regression 2023-09-26).
8139         * lib/mbspbrk.c (mbspbrk): Fix gcc warning in GNULIB_MCEL_PREFER mode.
8141 2023-10-15  Bruno Haible  <bruno@clisp.org>
8143         pthread-spin: Fix warnings on FreeBSD 5.2.1/i386.
8144         * lib/pthread.in.h (pthread_spinlock_t): Override if <pthread.h> defines
8145         pthread_spinlock_t but we need to approximate spinlocks with mutexes.
8146         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): When the pthread_spin_*
8147         functions are declared but don't exist, mark them as REPLACEd.
8149         pthread-spin: Fix link errors on FreeBSD 5.2.1/i386.
8150         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Test not only whether
8151         <pthread.h> defines the pthread_spinlock_t type, but also whether the
8152         function pthread_spin_init is actually defined.
8154 2023-10-15  Bruno Haible  <bruno@clisp.org>
8156         pthread_mutex_timedlock: Fix link errors on FreeBSD 5.2.1/i386.
8157         * m4/pthread_mutex_timedlock.m4 (gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK): Test
8158         not only whether pthread_mutex_timedlock is declared, but also whether
8159         it is actually defined.
8161 2023-10-15  Bruno Haible  <bruno@clisp.org>
8163         threadlib: Fix link errors on FreeBSD 5.2.1/i386.
8164         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): When pthread_kill could not be
8165         found in -lpthread, try -lthr.
8167 2023-10-15  Bruno Haible  <bruno@clisp.org>
8169         lock: Make Autoconf macro more robust.
8170         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
8171         Require gl_THREADLIB, not gl_THREADLIB_EARLY. Needed to get the value of
8172         LIBMULTITHREAD.
8174 2023-10-15  Bruno Haible  <bruno@clisp.org>
8176         totalorder-bench-tests: New module.
8177         * tests/bench-totalorder.c: New file, based on tests/test-totalorder.h.
8178         * modules/totalorder-bench-tests: New file.
8180 2023-10-15  Bruno Haible  <bruno@clisp.org>
8182         snan: Simplify a type.
8183         * lib/snan.h (memory_long_double): Put the 'value' field first.
8184         * tests/test-totalorder.h (main): No need for designated initializer
8185         syntax any more.
8187 2023-10-15  Bruno Haible  <bruno@clisp.org>
8189         vma-iter: Fix compilation error on FreeBSD 5.2.1.
8190         * lib/vma-iter.c [FreeBSD]: Include <sys/param.h>.
8192 2023-10-14  Bruno Haible  <bruno@clisp.org>
8194         totalorder*: Document glibc bug on SH4.
8195         * doc/posix-functions/totalorder.texi: Mention the glibc bug on SH4.
8196         * doc/posix-functions/totalorderf.texi: Likewise.
8197         * doc/posix-functions/totalorderl.texi: Likewise.
8199         totalorder*: Fix test failures on SH4.
8200         * lib/snan.h: Update comment.
8201         * lib/totalorderf.c (totalorderf): On sh4, invert bit 22 before
8202         comparing two NaNs.
8203         * lib/totalorder.c (totalorder): On sh4, invert bit 51 before comparing
8204         two NaNs.
8205         * lib/totalorderl.c (totalorderl): On sh4, invert bit 51 or 47 of the
8206         xhi, yhi parts before comparing two NaNs.
8208         totalorder*: Fix test failures on PA-RISC and MIPS CPUs.
8209         * lib/totalorderf.c (totalorderf): On hppa and mips, invert bit 22
8210         before comparing two NaNs.
8211         * lib/totalorder.c (totalorder): On hppa and mips, invert bit 51 before
8212         comparing two NaNs.
8213         * lib/totalorderl.c: Include <float.h>.
8214         (totalorderl): On hppa and mips, invert bit 51 or 47 of the xhi, yhi
8215         parts before comparing two NaNs.
8216         * modules/totalorderl (Depends-on): Add 'float'.
8218 2023-10-14  Bruno Haible  <bruno@clisp.org>
8220         totalorder* tests: Test also the signalling NaNs.
8221         * tests/test-totalorder.h: Include signed-snan.h.
8222         (main): Change the array initializer to contain memory_* objects rather
8223         than floating-point numbers. This is needed for i386 and x86_64 CPUs.
8224         * tests/test-totalorder.c (TOTALORDER_TYPE): Use memory_double.
8225         (TOTALORDER_HAVE_SNAN, TOTALORDER_POSITIVE_SNAN,
8226         TOTALORDER_NEGATIVE_SNAN): New macros.
8227         * tests/test-totalorderf.c (TOTALORDER_TYPE): Use memory_float.
8228         (TOTALORDER_HAVE_SNAN, TOTALORDER_POSITIVE_SNAN,
8229         TOTALORDER_NEGATIVE_SNAN): New macros.
8230         * tests/test-totalorderl.c (TOTALORDER_TYPE): Use memory_long_double.
8231         (TOTALORDER_HAVE_SNAN, TOTALORDER_POSITIVE_SNAN,
8232         TOTALORDER_NEGATIVE_SNAN): New macros.
8233         * modules/totalorder-tests (Depends-on): Add signed-snan.
8234         * modules/totalorderf-tests (Depends-on): Likewise.
8235         * modules/totalorderl-tests (Depends-on): Likewise.
8237 2023-10-14  Bruno Haible  <bruno@clisp.org>
8239         totalorder* tests: Make it easier to debug failures.
8240         * tests/test-totalorder.h: Include <stdio.h>.
8241         (main): Print array indices of all failures.
8243 2023-10-14  Bruno Haible  <bruno@clisp.org>
8245         totalorder* tests: Verify also the function signatures.
8246         * tests/test-totalorder.h: New file, based on tests/test-totalorder.c.
8247         * tests/test-totalorder.c: Check the signature. Include
8248         test-totalorder.h for the rest.
8249         * tests/test-totalorderf.c: Include <config.h>, <math.h>. Check the
8250         signature. Include test-totalorder.h instead of test-totalorder.c.
8251         * tests/test-totalorderl.c: Likewise.
8252         * modules/totalorder-tests (Files): Add test-totalorder.h, signature.h.
8253         * modules/totalorderf-tests (Files): Add test-totalorder.h, signature.h.
8254         Remove test-totalorder.c.
8255         * modules/totalorderl-tests (Files): Likewise.
8257 2023-10-14  Bruno Haible  <bruno@clisp.org>
8259         totalorder*: Improve documentation.
8260         * doc/posix-functions/totalorder.texi: Reference the specification.
8261         * doc/posix-functions/totalorderf.texi: Likewise.
8262         * doc/posix-functions/totalorderl.texi: Likewise.
8264 2023-10-14  Bruno Haible  <bruno@clisp.org>
8266         snan, signed-snan: Add API that works also on x86 and x86_64 CPUs.
8267         * lib/snan.h (memory_float, memory_double, memory_long_double): New
8268         types.
8269         (construct_memory_SNaNf, memory_SNaNf, construct_memory_SNaNd,
8270         memory_SNaNd, construct_memory_SNaNl, memory_SNaNl): New functions.
8271         * lib/signed-snan.h (memory_positive_SNaNf, memory_negative_SNaNf,
8272         memory_positive_SNaNd, memory_negative_SNaNd, memory_positive_SNaNl,
8273         memory_negative_SNaNl): New functions.
8275 2023-10-14  Bruno Haible  <bruno@clisp.org>
8277         snan tests: Fix "unused variable" warnings on i386.
8278         * tests/test-snan-1.c (main): Mark nanf, nand, nanl as possibly unused.
8279         * tests/test-snan-2.c (main): Likewise.
8281 2023-10-14  Bruno Haible  <bruno@clisp.org>
8283         snan: Avoid test failures with CC="gcc -mfpmath=387".
8284         * tests/test-snan-1.c (main): Treat x86_64 CPU with
8285         __FLT_EVAL_METHOD__ == 2 like i386 CPU. Update comments.
8286         * tests/test-snan-2.c (main): Likewise.
8288 2023-10-14  Bruno Haible  <bruno@clisp.org>
8290         snan: Fix the value of SNaNl() on i386, x86_64, ia64 CPUs.
8291         * lib/snan.h (construct_SNaNl): On i386, x86_64, ia64 CPUs, invert
8292         bit 62, not bit 63, of the mantissa.
8293         * m4/snan.m4 (gl_SNAN): Require gl_LONG_DOUBLE_VS_DOUBLE.
8294         * modules/snan (Files): Add m4/math_h.m4.
8296 2023-10-13  Bruno Haible  <bruno@clisp.org>
8298         tests: Make use of signed signalling NaNs.
8299         * tests/test-signbit.c: Include signed-snan.h instead of snan.h.
8300         (test_signbitf): Test positive_SNaNf, negative_SNaNf, instead of only
8301         SNaNf.
8302         (test_signbitd): Test positive_SNaNd, negative_SNaNd, instead of only
8303         SNaNd.
8304         (test_signbitl): Test positive_SNaNl, negative_SNaNl, instead of only
8305         SNaNl.
8306         * tests/test-stdio.c: Include signed-snan.h instead of snan.h.
8307         (main): Test positive_SNaNd, negative_SNaNd, instead of only SNaNd.
8308         Also, test positive_NaNd, negative_NaNd, instead of NaNd.
8309         * modules/signbit-tests (Depends-on): Add signed-snan. Remove snan.
8310         * modules/stdio-tests (Depends-on): Likewise.
8312 2023-10-13  Bruno Haible  <bruno@clisp.org>
8314         signed-snan: New module.
8315         * lib/snan.h (construct_SNaNf): New function, extracted from SNaNf.
8316         (SNaNf): Use it.
8317         (construct_SNaNd): New function, extracted from SNaNd.
8318         (SNaNd): Use it.
8319         (construct_SNaNl): New function, extracted from SNaNl.
8320         (SNaNl): Use it.
8321         * lib/signed-snan.h: New file.
8322         * modules/signed-snan: New file.
8324 2023-10-13  Bruno Haible  <bruno@clisp.org>
8326         signed-nan: New module, renamed from qnan.
8327         * lib/signed-nan.h: Renamed from lib/qnan.h. Update double-inclusion
8328         guard.
8329         * modules/signed-nan: Renamed from modules/qnan. Update.
8330         * tests/test-signbit.c: Update.
8331         * tests/test-stdio.c: Likewise.
8332         * tests/test-totalorder.c: Likewise.
8333         * modules/*-tests: Update.
8335 2023-10-13  Bruno Haible  <bruno@clisp.org>
8337         access: Fix test failure on native Windows.
8338         * lib/access.c (access): Do the trailing slash workaround also on
8339         native Windows.
8340         * modules/access (Depends-on): Add stat.
8342 2023-10-13  Bruno Haible  <bruno@clisp.org>
8344         isnanf, isnand: Fix conflict with Solaris <ieeefp.h>.
8345         * lib/math.in.h (isnanf, isnand): On Solaris and IRIX, declare this
8346         function, instead of defining it as a macro.
8348 2023-10-12  Bruno Haible  <bruno@clisp.org>
8350         *printf tests: Test printing of signalling NaNs.
8351         These tests run without sigfpe_on_invalid(), therefore they won't crash.
8352         * tests/test-vasnprintf-posix.c: Include snan.h.
8353         (test_function): For each test case that uses NaNd or NaNl, add a test
8354         case with SNaNd or SNaNl, respectively.
8355         * tests/test-vasprintf-posix.c: Likewise.
8356         * tests/test-snprintf-posix.h: Likewise.
8357         * tests/test-sprintf-posix.h: Likewise.
8358         * tests/test-vasnwprintf-posix.c: Likewise.
8359         * modules/vasnprintf-posix-tests (Depends-on): Add snan.
8360         * modules/vasprintf-posix-tests (Depends-on): Likewise.
8361         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
8362         * modules/snprintf-posix-tests (Depends-on): Likewise.
8363         * modules/vsprintf-posix-tests (Depends-on): Likewise.
8364         * modules/sprintf-posix-tests (Depends-on): Likewise.
8365         * modules/vasnwprintf-posix-tests (Depends-on): Likewise.
8366         * modules/pipe-filter-gi-tests (Depends-on): Likewise.
8367         * modules/pipe-filter-ii-tests (Depends-on): Likewise.
8369 2023-10-12  Bruno Haible  <bruno@clisp.org>
8371         nan, snan tests: Avoid test failures.
8372         * tests/test-nan-1.c (main): Special handling of arm CPUs with software
8373         floating-point emulation.
8374         * tests/test-snan-1.c (main): Likewise. Disable tests that are known to
8375         fail.
8376         * tests/test-snan-2.c (main): Skip tests that are known to fail.
8377         * modules/snan-tests (Files): Add m4/math_h.m4.
8378         (configure.ac): Require gl_LONG_DOUBLE_VS_DOUBLE.
8379         * m4/math_h.m4 (gl_LONG_DOUBLE_VS_DOUBLE): Mention also NetBSD/sparc32.
8381 2023-10-12  Bruno Haible  <bruno@clisp.org>
8383         snan: Add tests.
8384         * tests/test-snan-1.c: New file.
8385         * tests/test-snan-2.sh: New file.
8386         * tests/test-snan-2.c: New file.
8387         * modules/snan-tests: New file.
8389 2023-10-12  Bruno Haible  <bruno@clisp.org>
8391         nan: Add tests.
8392         * tests/test-nan-1.c: New file.
8393         * tests/test-nan-2.c: New file.
8394         * modules/nan-tests: New file.
8396 2023-10-12  Bruno Haible  <bruno@clisp.org>
8398         fpe-tracking, fpe-trapping: New modules.
8399         * lib/fpe-trapping.h: New file.
8400         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the type fp_except_t.
8401         * m4/fpe.m4: New file.
8402         * modules/fpe-tracking: New file.
8403         * modules/fpe-trapping: New file.
8405 2023-10-12  Bruno Haible  <bruno@clisp.org>
8407         snan: Comments.
8408         * lib/snan.h: Add more comments.
8410 2023-10-12  Bruno Haible  <bruno@clisp.org>
8412         snan: New module.
8413         * lib/snan.h: Renamed from tests/snan.h. Add double-inclusion guard.
8414         * m4/snan.m4: New file.
8415         * modules/snan: New file.
8416         * isfinite-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
8417         (Depends-on): Add snan.
8418         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
8419         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
8420         * isinf-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
8421         (Depends-on): Add snan.
8422         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
8423         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
8424         * isnan-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
8425         (Depends-on): Add snan.
8426         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
8427         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
8428         * isnanf-nolibm-tests (Files): Remove tests/snan.h, m4/exponentf.m4.
8429         (Depends-on): Add snan.
8430         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION.
8431         * isnanf-tests (Files): Remove tests/snan.h, m4/exponentf.m4.
8432         (Depends-on): Add snan.
8433         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION.
8434         * isnand-nolibm-tests (Files): Remove tests/snan.h, m4/exponentd.m4.
8435         (Depends-on): Add snan.
8436         (configure.ac): Don't invoke gl_DOUBLE_EXPONENT_LOCATION.
8437         * isnand-tests (Files): Remove tests/snan.h, m4/exponentd.m4.
8438         (Depends-on): Add snan.
8439         (configure.ac): Don't invoke gl_DOUBLE_EXPONENT_LOCATION.
8440         * isnanl-nolibm-tests (Files): Remove tests/snan.h, m4/exponentl.m4.
8441         (Depends-on): Add snan.
8442         (configure.ac): Don't invoke gl_LONG_DOUBLE_EXPONENT_LOCATION.
8443         * isnanl-tests (Files): Remove tests/snan.h, m4/exponentl.m4.
8444         (Depends-on): Add snan.
8445         (configure.ac): Don't invoke gl_LONG_DOUBLE_EXPONENT_LOCATION.
8446         * signbit-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
8447         (Depends-on): Add snan.
8448         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
8449         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
8450         * stdio-tests (Files): Remove tests/snan.h
8451         (Depends-on): Add snan.
8453 2023-10-12  Bruno Haible  <bruno@clisp.org>
8455         qnan: New module.
8456         * lib/qnan.h: Renamed from tests/qnan.h. Add double-inclusion guard.
8457         * modules/qnan: New file.
8458         * modules/signbit-tests (Files): Remove tests/qnan.h.
8459         (Depends-on): Add qnan. Remove nan.
8460         * modules/stdio-tests (Files): Remove tests/qnan.h.
8461         (Depends-on): Add qnan. Remove nan.
8462         * modules/totalorder-tests (Files): Remove tests/qnan.h.
8463         (Depends-on): Add qnan. Remove nan, signbit.
8464         * modules/totalorderf-tests (Files): Remove tests/qnan.h.
8465         (Depends-on): Add qnan. Remove nan, signbit.
8466         * modules/totalorderl-tests (Files): Remove tests/qnan.h.
8467         (Depends-on): Add qnan. Remove nan, signbit.
8469 2023-10-12  Bruno Haible  <bruno@clisp.org>
8471         nan: New module.
8472         * lib/nan.h: Renamed from tests/nan.h. Change double-inclusion guard.
8473         * modules/nan: New file.
8474         * modules/*-tests: Depend on this module instead of embedding
8475         tests/nan.h.
8477 2023-10-11  Bruno Haible  <bruno@clisp.org>
8479         unictype/category-and-not: Add more tests.
8480         Suggested by Arindam Sharma <arindam.sharma@imperial.ac.uk>.
8481         * tests/unictype/test-categ_and_not.c (main): Add two more test cases.
8482         * modules/unictype/category-and-not-tests (Depends-on): Add
8483         unictype/category-Cc.
8485 2023-10-09  Bruno Haible  <bruno@clisp.org>
8487         tests: Refactor functions for signalling NaNs.
8488         * tests/snan.h: New file, based on tests/test-isnanf.h,
8489         tests/test-isnand.h, tests/test-isnanl.h.
8490         * tests/test-isfinite.c: Include snan.h.
8491         (test_isfinitef, test_isfinited, test_isfinitel): Simplify.
8492         * tests/test-isinf.c: Include snan.h.
8493         (test_isinff, test_isinfd, test_isinfl): Simplify.
8494         * tests/test-isnan.c: Include snan.h.
8495         (test_float, test_double, test_long_double): Simplify.
8496         * tests/test-isnanf.h: Include snan.h.
8497         (main): Simplify.
8498         * tests/test-isnand.h: Include snan.h.
8499         (main): Simplify.
8500         * tests/test-isnanl.h: Include snan.h.
8501         (main): Simplify.
8502         * tests/test-signbit.c: Include snan.h.
8503         (test_signbitf, test_signbitd, test_signbitl): Simplify.
8504         * tests/test-stdio.c: Include qnan.h, snan.h instead of nan.h.
8505         (main): Test quiet NaNs always. Also test a signalling NaN.
8506         * modules/isfinite-tests (Files): Add tests/nan.h, tests/snan.h.
8507         * modules/isinf-tests (Files): Likewise.
8508         * modules/isnan-tests (Files): Add tests/snan.h.
8509         * modules/isnanf-tests (Files): Likewise.
8510         * modules/isnanf-nolibm-tests (Files): Likewise.
8511         * modules/isnand-tests (Files): Likewise.
8512         * modules/isnand-nolibm-tests (Files): Likewise.
8513         * modules/isnanl-tests (Files): Likewise.
8514         * modules/isnanl-nolibm-tests (Files): Likewise.
8515         * modules/signbit-tests (Files): Likewise.
8516         * modules/stdio-tests (Files): Add tests/qnan.h, tests/snan.h.
8518 2023-10-08  Bruno Haible  <bruno@clisp.org>
8520         isfinite: Work around a bug with 'long double' in glibc 2.5/ia64.
8521         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Require
8522         gl_LONG_DOUBLE_EXPONENT_LOCATION. Test also another NaN value.
8523         * modules/isfinite (Files): Add m4/exponentl.m4.
8524         * doc/posix-functions/isfinite.texi: Mention also a 'long double'
8525         problem on ia64.
8527 2023-10-07  Bruno Haible  <bruno@clisp.org>
8529         tests: Refactor functions for quiet NaNs.
8530         * tests/qnan.h: New file, based on tests/totalorder.c.
8531         * tests/nan.h: Add double-inclusion guard.
8532         * tests/test-signbit.c: Include qnan.h.
8533         (test_signbitf, test_signbitd, test_signbitl): Simplify.
8534         * tests/test-totalorder.c: Include qnan.h instead of NaN.h.
8535         (TOTALORDER_NAN): Remove macro.
8536         (TOTALORDER_POSITIVE_NAN, TOTALORDER_NEGATIVE_NAN): New macros.
8537         (positive_nan, negative_nan): Remove functions.
8538         (main): Update.
8539         * tests/test-totalorderf.c (TOTALORDER_NAN): Remove macro.
8540         (TOTALORDER_POSITIVE_NAN, TOTALORDER_NEGATIVE_NAN): New macros.
8541         * tests/test-totalorderl.c (TOTALORDER_NAN): Remove macro.
8542         (TOTALORDER_POSITIVE_NAN, TOTALORDER_NEGATIVE_NAN): New macros.
8543         * modules/signbit-tests (Files): Add tests/nan.h, tests/qnan.h.
8544         * modules/totalorder-tests (Files): Add tests/qnan.h.
8545         (Depends-on): Add signbit.
8546         * modules/totalorderf-tests (Files): Add tests/qnan.h.
8547         (Depends-on): Add signbit.
8548         * modules/totalorderl-tests (Files): Add tests/qnan.h.
8549         (Depends-on): Add signbit.
8551 2023-10-07  Bruno Haible  <bruno@clisp.org>
8553         totalorder*: Fix compilation error on glibc 2.25..2.30.
8554         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF): Test whether <math.h> has an
8555         incompatible declaration of totalorderf, and set REPLACE_TOTALORDERF
8556         to 1 if so.
8557         (gl_FUNC_TOTALORDER): Test whether <math.h> has an incompatible
8558         declaration of totalorder, and set REPLACE_TOTALORDER to 1 if so.
8559         (gl_FUNC_TOTALORDERL): Test whether <math.h> has an incompatible
8560         declaration of totalorderl, and set REPLACE_TOTALORDERL to 1 if so.
8562 2023-10-07  Bruno Haible  <bruno@clisp.org>
8564         isnan: Avoid dangerous shell coding pattern.
8565         * m4/isnand.m4 (gl_FUNC_ISNAND): Use 'test -n "$arg"', not
8566         'test "$arg"'.
8567         * m4/isnanf.m4 (gl_FUNC_ISNANF): Likewise.
8568         * m4/isnanl.m4 (gl_FUNC_ISNANL): Likewise.
8570 2023-10-05  Bruno Haible  <bruno@clisp.org>
8572         doc: Mention xstrerror.
8573         * doc/posix-functions/strerror_r.texi: Mention xstrerror.
8575         xstrerror: Add tests.
8576         * tests/test-xstrerror.c: New file.
8577         * modules/xstrerror-tests: New file.
8579         xstrerror: New module.
8580         * lib/xstrerror.h: New file.
8581         * lib/xstrerror.c: New file.
8582         * modules/xstrerror: New file.
8583         * modules/strerror_r-posix (configure.ac): Update comment.
8585 2023-10-05  Paul Eggert  <eggert@cs.ucla.edu>
8587         isnan: slightly simplify configuration
8588         * m4/isnand.m4 (gl_FUNC_ISNAND):
8589         * m4/isnanf.m4 (gl_FUNC_ISNANF):
8590         * m4/isnanl.m4 (gl_FUNC_ISNANL):
8591         Slightly simplify shell ‘if’.  This should simplify future changes.
8593         totalorder: speed up configuration
8594         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF, gl_FUNC_TOTALORDER)
8595         (gl_FUNC_TOTALORDERL): Avoid unnecessary call to AC_SEARCH_LIBS,
8596         since the information is already available in shell vars.
8598         totalorderl: minor porting fixes
8599         * lib/totalorderl.c (LDBL_SIGNBIT_WORD): Define to -1 if not defined.
8600         (totalorderl): Avoid unused local zu by preferring ‘if’ to ‘ifdef’.
8601         Don’t assume sizeof (unsigned long long) == 2 * sizeof (unsigned).
8603 2023-10-04  Bruno Haible  <bruno@clisp.org>
8605         totalorder* tests: Refactor.
8606         * tests/test-totalorder.c (positive_nan, negative_nan): New functions,
8607         extracted from main.
8608         (main): Use them when initializing the array.
8610 2023-10-04  Bruno Haible  <bruno@clisp.org>
8612         totalorderl: Optimize.
8613         * modules/totalorderl (Files): Add m4/signbit.m4.
8614         * m4/totalorder.m4 (gl_FUNC_TOTALORDERL): Invoke
8615         gl_LONG_DOUBLE_SIGN_LOCATION.
8616         * lib/totalorderl.c (totalorderl): If LDBL_SIGNBIT_WORD is known,
8617         use it, so that 'bigendian' becomes a constant.
8619 2023-10-04  Bruno Haible  <bruno@clisp.org>
8621         totalorderl: Work around Solaris cc bug.
8622         * lib/totalorderl.c (totalorderl): Initialize xu, yu, zu using a
8623         different syntax.
8625 2023-10-04  Bruno Haible  <bruno@clisp.org>
8627         signbit tests: Strengthen tests.
8628         * tests/test-signbit.c (test_signbitf, test_signbitd, test_signbitl):
8629         Test the sign bit both of a NaN value and of its negative.
8631 2023-10-03  Bruno Haible  <bruno@clisp.org>
8633         doc: Document portability of __VA_ARGS__.
8634         * doc/gnulib-readme.texi (C99 features assumed): Add a note about
8635         __VA_ARGS__.
8637 2023-10-03  Bruno Haible  <bruno@clisp.org>
8639         ilogb: Document a Mac OS X bug.
8640         * doc/posix-functions/ilogb.texi: Mention a bug that affects Mac OS X.
8641         * m4/ilogb.m4 (gl_FUNC_ILOGB): Update comments.
8643 2023-10-03  Bruno Haible  <bruno@clisp.org>
8645         *printf-posix: Work around bug with %#.0x on Mac OS X 10.6.
8646         * lib/vasnprintf.c (VASNPRINTF): Enable NEED_PRINTF_UNBOUNDED_PRECISION-
8647         guarded code also for NEED_PRINTF_FLAG_ALT_PRECISION_ZERO. Set
8648         prec_ourselves to 1 if NEED_PRINTF_FLAG_ALT_PRECISION_ZERO, precision is
8649         0, and the directive is 'x' or 'X'. If prec_ourselves, remove the "0"
8650         output if required.
8651         * m4/printf.m4 (gl_PRINTF_FLAG_ALT_PRECISION_ZERO): New macro.
8652         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ALT_PRECISION_ZERO): New
8653         macro.
8654         (gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS): Invoke it.
8655         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): Require
8656         gl_PRINTF_FLAG_ALT_PRECISION_ZERO and test its result.
8657         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
8658         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX):
8659         Likewise.
8660         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): Likewise.
8661         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
8662         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Likewise.
8663         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
8664         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
8665         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
8666         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
8667         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
8668         * doc/glibc-functions/asprintf.texi: Mention the %#.0x bug.
8669         * doc/glibc-functions/obstack_printf.texi: Likewise.
8670         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
8671         * doc/glibc-functions/vasprintf.texi: Likewise.
8672         * doc/posix-functions/dprintf.texi: Likewise.
8673         * doc/posix-functions/fprintf.texi: Likewise.
8674         * doc/posix-functions/fwprintf.texi: Likewise.
8675         * doc/posix-functions/printf.texi: Likewise.
8676         * doc/posix-functions/snprintf.texi: Likewise.
8677         * doc/posix-functions/sprintf.texi: Likewise.
8678         * doc/posix-functions/swprintf.texi: Likewise.
8679         * doc/posix-functions/vdprintf.texi: Likewise.
8680         * doc/posix-functions/vfprintf.texi: Likewise.
8681         * doc/posix-functions/vfwprintf.texi: Likewise.
8682         * doc/posix-functions/vprintf.texi: Likewise.
8683         * doc/posix-functions/vsnprintf.texi: Likewise.
8684         * doc/posix-functions/vsprintf.texi: Likewise.
8685         * doc/posix-functions/vswprintf.texi: Likewise.
8686         * doc/posix-functions/vwprintf.texi: Likewise.
8687         * doc/posix-functions/wprintf.texi: Likewise.
8689 2023-10-03  Bruno Haible  <bruno@clisp.org>
8691         faccessat tests: Strengthen tests.
8692         * tests/test-faccessat.c (main): Test other modes than F_OK. Check errno
8693         values.
8695 2023-10-03  Bruno Haible  <bruno@clisp.org>
8697         euidaccess: Reject trailing slashes on symlinks to non-directories.
8698         * modules/euidaccess (Depends-on): Add access.
8700         euidaccess: Add tests.
8701         * tests/test-access.h: New file, extracted from tests/test-access.c.
8702         * tests/test-access.c: Moved most code to tests/test-access.h.
8703         Include test-access.h.
8704         (main): Invoke test_access.
8705         * tests/test-euidaccess.c: New file, based on tests/test-access.c.
8706         * modules/access-tests (Files): Add tests/test-access.h.
8707         * modules/euidaccess-tests: New file, based on modules/access-tests.
8709 2023-10-03  Bruno Haible  <bruno@clisp.org>
8711         access: Make last change work also when module 'stat' is in use.
8712         * lib/access.c (access): When stat() returns -1 with errno != EOVERFLOW,
8713         fail.
8715         access: Work around trailing slash bug on Mac OS X 10.5.
8716         * m4/access.m4 (gl_FUNC_ACCESS): Test whether access honors a trailing
8717         slash. Set REPLACE_ACCESS to 1 and define ACCESS_TRAILING_SLASH_BUG if
8718         not.
8719         * lib/access.c (access): Add an implementation for Unix-like platforms.
8720         * tests/test-access.c (main): Test for result if the argument has a
8721         trailing slash.
8722         * modules/access-tests (Depends-on): Add 'symlink'.
8723         * doc/posix-functions/access.texi: Mention the Mac OS X bug.
8725 2023-10-03  Bruno Haible  <bruno@clisp.org>
8727         update-copyright tests: Fix test failure (regression 2023-06-18).
8728         * build-aux/update-copyright: Add "use re 'eval';" declaration.
8730 2023-10-03  Bruno Haible  <bruno@clisp.org>
8732         Update re *-*-windows*-gnu* config triplets, withdrawn on 2023-09-19.
8733         * m4/*.m4: Don't recognize windows*-gnu* as equivalent to mingw*.
8735 2023-10-03  Bruno Haible  <bruno@clisp.org>
8737         string-c++-tests, uchar-c++-tests: Fix link errors on Mac OS X.
8738         * modules/string-c++-tests (Makefile.am): Link test-string-c++ with
8739         $(LIBC32CONV).
8740         * modules/uchar-c++-tests (Makefile.am): Link test-uchar-c++ with
8741         $(LIBC32CONV).
8743 2023-10-03  Bruno Haible  <bruno@clisp.org>
8745         mcel tests: Fix link error.
8746         * modules/mcel-tests (Makefile.am): Link test-mcel with $(LIBUNISTRING)
8747         $(SETLOCALE_LIB) $(MBRTOWC_LIB) $(LIBC32CONV).
8749 2023-10-03  Bruno Haible  <bruno@clisp.org>
8751         mcel: Fix compilation error in tests.
8752         * lib/mcel.h (mcel_scan): Undefine 'mbs' after use.
8754 2023-10-02  Bruno Haible  <bruno@clisp.org>
8756         localename, gettext: Avoid crash on macOS 14.
8757         Reported by Shupeng Xue <dspxue@gmail.com> at
8758         <https://lists.gnu.org/archive/html/bug-gettext/2023-10/msg00001.html>.
8759         Cf <https://github.com/aria2/aria2/issues/2083#issuecomment-1694662007>.
8760         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Link with the CoreServices
8761         framework in addition to the CoreFoundation framework.
8763 2023-10-02  Bruno Haible  <bruno@clisp.org>
8765         localcharset: Avoid internal compiler error with -Wextra on macOS 10.5.
8766         * lib/localcharset.c (locale_charset): Use an empty compound statement
8767         instead of a null statement.
8769 2023-10-02  KO Myung-Hun  <komh78@gmail.com>
8771         fchdir: Fix a compilation error on OS/2 kLIBC (regression 2023-09-29).
8772         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Define REPLACE_FCHDIR macro to 1 if
8773         REPLACE_FCHDIR is 1.
8775 2023-10-02  Bruno Haible  <bruno@clisp.org>
8777         totalorder, totalorderf, totalorderl: Fix some typos.
8778         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF): Assign TOTALORDERF_LIBM, not
8779         TOTALORDER_LIBM.
8780         * modules/totalorder (Description): Fix copy&paste mistake.
8781         (Depends-on): Fix conditions.
8782         * modules/totalorderf (Depends-on): Likewise.
8783         * modules/totalorderl (Depends-on): Likewise.
8785 2023-10-01  Paul Eggert  <eggert@cs.ucla.edu>
8787         totalorder, totalorderf, totalorderl: new modules
8788         * lib/math.in.h: Declare totalorderf, totalorder, totalorderl.
8789         * lib/totalorder.c, lib/totalorderf.c, lib/totalorderl.c:
8790         * m4/totalorder.m4, modules/totalorder, modules/totalorder-tests:
8791         * modules/totalorderf, modules/totalorderf-tests:
8792         * modules/totalorderl, modules/totalorderl-tests:
8793         * tests/test-totalorder.c, tests/test-totalorderf.c:
8794         * tests/test-totalorderl.c: New files.
8795         * m4/math_h.m4 (gl_MATH_H, gl_MATH_H_REQUIRE_DEFAULTS)
8796         (gl_MATH_H_DEFAULTS):
8797         * modules/math (math.h): Set up totalorder, totalorderf, totalorderl.
8798         * m4/mathfunc.m4 (gl_MATHFUNC): Also support pointer-to-const.
8800 2023-09-30  Paul Eggert  <eggert@cs.ucla.edu>
8802         regex-quote: fix recently-introduced typo
8803         Problem reported by Bruno Haible in:
8804         https://lists.gnu.org/r/bug-gnulib/2023-09/msg00146.html
8805         * lib/regex-quote.c (regex_quote_copy): Add missing #endif.
8807 2023-09-30  Bruno Haible  <bruno@clisp.org>
8809         wgetcwd-lgpl: Add tests.
8810         * tests/test-wgetcwd-lgpl.c: New file, based on
8811         tests/test-getcwd-lgpl.c.
8812         * modules/wgetcwd-lgpl-tests: New file, based on
8813         modules/getcwd-lgpl-tests.
8815         wgetcwd-lgpl: New module.
8816         * lib/wchar.in.h (wgetcwd): New declaration.
8817         * lib/wgetcwd-lgpl.c: New file, based on lib/getcwd-lgpl.c.
8818         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Initialize
8819         GNULIB_WGETCWD.
8820         * modules/wchar (Makefile.am): Substitute GNULIB_WGETCWD.
8821         * modules/wgetcwd-lgpl: New file.
8823 2023-09-30  Bruno Haible  <bruno@clisp.org>
8825         getcwd-lgpl: Tweaks.
8826         * lib/unistd.in.h (getcwd): Mention the module 'getcwd-lgpl'.
8827         * lib/getcwd-lgpl.c (rpl_getcwd): Minimize scope of local variables.
8828         * tests/test-getcwd-lgpl.c (main): Use GNU coding style.
8830 2023-09-29  Bruno Haible  <bruno@clisp.org>
8832         Allow different --libtool options from multiple gnulib-tool invocations.
8833         * modules/crypto/gc (Makefile.am): Don't test GL_COND_LIBTOOL, since
8834         gnulib-tool already eliminates lib_LDFLAGS augmentations for non-libtool
8835         libraries.
8836         * modules/striconv (Makefile.am): Likewise.
8837         * modules/striconveh (Makefile.am): Likewise.
8838         * modules/termcap (Makefile.am): Likewise.
8839         * modules/terminfo (Makefile.am): Likewise.
8841 2023-09-29  KO Myung-Hun  <komh78@gmail.com>
8843         stdlib: Cast putenv() on OS/2 kLIBC
8844         * lib/stdlib.in.h (putenv) [kLIBC]: Cast with _GL_CXXALIAS_SYS_CAST().
8846 2023-09-29  Bruno Haible  <bruno@clisp.org>
8848         fchdir: Override properly on OS/2 kLIBC.
8849         * lib/unistd.in.h (fchdir): Override if REPLACE_FCHDIR is 1.
8850         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_FCHDIR.
8851         * modules/unistd (Makefile.am): Substitute REPLACE_FCHDIR.
8852         * modules/fchdir (Depends-on, configure.ac): Test REPLACE_FCHDIR.
8853         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Instead of setting HAVE_FCHDIR to 0,
8854         set REPLACE_FCHDIR to 1.
8856 2023-09-29  KO Myung-Hun  <komh78@gmail.com>
8858         fdopendir: Use Windows code path on OS/2 kLIBC
8859         * lib/closedir.c (closedir): Use Windows code path.
8860         * lib/dirent.in.h (_gl_register_dirp_fd, _gl_unregister_dirp_fd):
8861         Remove.
8862         * lib/dirfd.c (_gl_register_dirp_fd, _gl_unregister_dirp_fd): Remove.
8863         (dirfd): Use Windows code path.
8864         * lib/fdopendir.c (fdopendir): Use Windows code path.
8865         * lib/opendir.c (opendir): Use Windows code path.
8866         * m4/closedir.m4 (REPLACE_CLOSEDIR): Use Windows code path.
8867         * m4/dirent_h.m4 (DIR_HAS_FD_MEMBER): Use Windows code path.
8868         * m4/dirfd.m4 (REPLACE_DIRFD): Use Windows code path.
8869         * m4/fchdir.m4 (HAVE_FCHDIR): Replace fchdir() if dirfd() does not work.
8870         * m4/opendir.m4 (REPLACE_OPENDIR): Use Windows code path.
8871         * m4/readdir.m4 (REPLACE_READDIR): Use Windows code path.
8872         * m4/rewinddir.m4 (REPLACE_REWINDDIR): Use Windows code path.
8873         * modules/fchdir (Depends-on): Include dirent always.
8875 2023-09-26  Paul Eggert  <eggert@cs.ucla.edu>
8877         mcel-bench-tests: fix typo
8878         * tests/bench-mcel.c (main): Fix typo in usage message.
8880         Remaining support for GNULIB_MCEL_PREFER
8881         Support mcel API in remaining modules where this might matter,
8882         for apps that prefer it.
8883         * lib/mbmemcasecmp.c, lib/mbscspn.c, lib/mbsncasecmp.c, lib/mbsnlen.c:
8884         * lib/mbspbrk.c, lib/mbspcasecmp.c, lib/mbssep.c, lib/mbsspn.c:
8885         * lib/regex-quote.c:
8886         Include mcel.h instead of mbiterf.h or mbuiterf.h,
8887         if GNULIB_MCEL_PREFER.
8888         * lib/mbmemcasecmp.c (mbmemcasecmp), lib/mbscspn.c (mbscspn):
8889         * lib/mbsncasecmp.c (mbsncasecmp), lib/mbsnlen.c (mbsnlen):
8890         * lib/mbspbrk.c (mbspbrk), lib/mbspcasecmp.c (mbspcasecmp):
8891         * lib/mbssep.c (mbssep), lib/mbsspn.c (mbsspn):
8892         * lib/regex-quote.c (regex_quote_length, regex_quote_copy):
8893         Use mcel API, if GNULIB_MCEL_PREFER.
8894         * lib/mbscspn.c, lib/mbspbrk.c, lib/mbspcasecmp.c, lib/mbsspn.c:
8895         Include stdlib.h, for MB_CUR_MAX.
8896         * modules/mbmemcasecmp, modules/mbsncasecmp, modules/mbspcasecmp:
8897         Depend on c32tolower.
8898         * modules/regex-quote: Depend on mempcpy.
8900 2023-09-25  Paul Eggert  <eggert@cs.ucla.edu>
8902         mbscasestr: support GNULIB_MCEL_PREFER
8903         Support mcel API for apps that prefer it.
8904         This mirrors the recent changes to mbsstr.
8905         * lib/mbscasestr.c [GNULIB_MCEL_PREFER]: Include mcel.h not mbuiter.h.
8906         (mbchar_t, mb_equal) [GNULIB_MCEL_PREFER]: New type and function,
8907         to make it easier to use common code.
8908         (knuth_morris_pratt_multibyte): Don't assume mbchar_t's alignment
8909         is at least that of size_t.
8910         (knuth_morris_pratt_multibyte, mbscasestr) [GNULIB_MCEL_PREFER]:
8911         Use mcel API.
8912         * modules/mbscasestr (Depends-on): Add alignasof.
8914 2023-09-24  Bernhard Voelker  <mail@bernhard-voelker.de>
8916         maintainer-makefile: Fix syntax-check rules wrt README.
8917         * top/maint.mk (sc_readme_link_install): Change the value of the
8918         variable in_vc_files to contain a pattern for the README file.
8919         (sc_readme_link_copying): Likewise.
8920         Previously, the above rules always passed, because the generated
8921         list of files was empty.  Bug introduced when adding the rules
8922         in commit 53b4bf3018.
8924 2023-09-22  Bruno Haible  <bruno@clisp.org>
8926         striconveh, *vasnprintf, vasnwprintf: Make more virtual-memory friendly.
8927         * lib/striconveh.c (mem_cd_iconveh_internal): Mark hex as 'const'.
8928         * lib/vasnprintf.c (wctomb_fallback): Likewise.
8930 2023-09-21  Paul Eggert  <eggert@cs.ucla.edu>
8932         mbschr, mbsrchr: support GNULIB_MCEL_PREFER
8933         Support mcel API for apps that prefer it.
8934         The following changes are in effect only if GNULIB_MCEL_PREFER.
8935         * lib/mbschr.c, lib/mbsrchr.c: Include stdlib.h, for MB_CUR_MAX.
8936         [GNULIB_MCEL_PREFER]: Include mcel.h instead of mbuiterf.h.
8937         (mbschr, mbsrchr) [GNULIB_MCEL_PREFER]: Use mcel API.
8939         gnulib-common: don’t suppress -Wpedantic
8940         Problem reported by Pádraig Brady in:
8941         https://lists.gnu.org/r/bug-gnulib/2023-09/msg00130.html
8942         * m4/gnulib-common.m4 (_GL_HAVE___HAS_C_ATTRIBUTE): New macro.
8943         Use it instead of ‘defined __has_c_attribute’.
8945         crypto/sm3: rename gl_cv_* variable for clarity
8946         * m4/gc-sm3.m4 (gl_cv_libgcrypt_md_sm3):
8947         Rename from gl_cv_libcrypt_md_sm3 since this is unrelated to libcrypt.
8949 2023-09-17  Paul Eggert  <eggert@cs.ucla.edu>
8951         intprops: pacify GCC -Wtype-limits
8952         * lib/intprops-internal.h: Pacify gcc (GCC) 13.2.1 20230728 (Red
8953         Hat 13.2.1-1) x86-64 -Wtype-limits on bleeding-edge diffutils.
8955 2023-09-16  Bruno Haible  <bruno@clisp.org>
8957         lib-symbol-visibility: Fix a misnomer.
8958         * doc/lib-symbol-visibility.texi: Rename LIBFOO_DLL_EXPORTED to
8959         LIBFOO_SHLIB_EXPORTED. Prefer the term "shared library", since the term
8960         "DLL" applies only to Windows.
8961         * lib/relocatable.h (RELOCATABLE_SHLIB_EXPORTED): Renamed from
8962         RELOCATABLE_DLL_EXPORTED. Prefer the term "shared library", since the
8963         term "DLL" applies only to Windows.
8964         * lib/mbtowc-lock.c (SHLIB_EXPORTED): Renamed from DLL_EXPORTED.
8965         * lib/nl_langinfo-lock.c (SHLIB_EXPORTED): Likewise.
8966         * lib/setlocale-lock.c (SHLIB_EXPORTED): Likewise.
8968 2023-09-15  Bruno Haible  <bruno@clisp.org>
8970         acl-permissions: Fix compilation error on Solaris 11 (regr. 2023-09-04).
8971         * lib/set-permissions.c: Include minmax.h.
8972         * modules/acl-permissions (Depends-on): Add minmax.
8974 2023-09-15  Bruno Haible  <bruno@clisp.org>
8976         readutmp: Fix crash when gdm is in use.
8977         Reported by Thorsten Kukuk <kukuk@suse.com> in
8978         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00093.html>.
8979         * lib/readutmp.c (read_utmp_from_systemd): Don't use the value returned
8980         by sd_session_get_display if it is NULL.
8982 2023-09-14  Bruno Haible  <bruno@clisp.org>
8984         doc: Mention libucontext.
8985         * doc/pastposix-functions/getcontext.texi: Mention libucontext.
8986         * doc/pastposix-functions/makecontext.texi: Likewise.
8987         * doc/pastposix-functions/setcontext.texi: Likewise.
8988         * doc/pastposix-functions/swapcontext.texi: Likewise.
8990 2023-09-13  Bruno Haible  <bruno@clisp.org>
8992         mbfile: Add tests.
8993         * tests/test-mbfile.sh: New file.
8994         * tests/test-mbfile.c: New file.
8995         * modules/mbfile-tests: New file.
8997         mbfile: Fix major bug (regression 2023-07-04).
8998         Reported by Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org> in
8999         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00088.html>.
9000         * lib/mbfile.h (mbfile_multi_getc): If bytes != -1, -2, -3, add the
9001         previous mbf->bufcount to bytes.
9003 2023-09-11  Pádraig Brady  <P@draigBrady.com>
9005         gnu-web-doc-update: fix updating of manual directory
9006         * build-aux/gnu-web-doc-update: Change to the 'manual' directory,
9007         since $tmp is a relative path.  This avoids removing files
9008         outside of the 'manual' directory.
9010 2023-09-10  Bruno Haible  <bruno@clisp.org>
9012         Fix clang errors "different exception specifier" (regr. 2023-09-04).
9013         * lib/malloc.in.h (memalign): Don't use _GL_ATTRIBUTE_NOTHROW on
9014         platforms other than glibc systems.
9015         * lib/stdio.in.h (fdopen): Likewise.
9016         * lib/stdlib.in.h (aligned_alloc, calloc, canonicalize_file_name,
9017         malloc, realloc): Likewise.
9018         * lib/string.in.h (strdup, strndup): Likewise.
9019         * lib/sys_stat.in.h (getumask): Likewise.
9020         * lib/wchar.in.h (wcsdup): Likewise.
9022 2023-09-09  Paul Eggert  <eggert@cs.ucla.edu>
9024         propername: support GNULIB_MCEL_PREFER
9025         Support mcel API for apps that prefer it.
9026         The following changes are in effect only if GNULIB_MCEL_PREFER.
9027         * lib/propername.c: Include mcel.h, not mbchar.h and mbuiter.h.
9028         (mbsstr_trimmed_wordbounded): Use mcel API.
9029         * modules/propername (Depends-on): Add c32isalnum.
9031         trim: support GNULIB_MCEL_PREFER
9032         Support mcel API for apps that prefer it.
9033         The following changes are in effect only if GNULIB_MCEL_PREFER.
9034         * lib/trim.c: Include mcel.h, not mbchar.h and mbuiterf.h.
9035         (trim2): Use mcel API.
9036         * modules/trim (Depends-on): Add c32isspace.
9038         mbsstr: support GNULIB_MCEL_PREFER
9039         Support mcel API for apps that prefer it.
9040         * lib/mbsstr.c [GNULIB_MCEL_PREFER]: Include mcel.h not mbuiter.h.
9041         (mbchar_t, mb_equal) [GNULIB_MCEL_PREFER]: New type and function,
9042         to make it easier to use common code.
9043         (knuth_morris_pratt_multibyte): Don't assume mbchar_t's alignment
9044         is at least that of size_t.
9045         (knuth_morris_pratt_multibyte, mbsstr) [GNULIB_MCEL_PREFER]:
9046         Use mcel API.
9047         * modules/mbsstr (Depends-on): Add alignasof.
9049         mbslen: support GNULIB_MCEL_PREFER
9050         Support mcel API for apps that prefer it.
9051         The following changes are in effect only if GNULIB_MCEL_PREFER.
9052         * lib/mbslen.c: Include mcel.h instead of mbuiterf.h.
9053         (mbslen): Use mcel API.
9055         chown: work around symlink issues on odd platforms
9056         Problem reported by Jordi Sanfeliu in:
9057         https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00116.html
9058         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
9059         Do not declare unused locals st, stat_valid.
9060         Redo to just call chown if arg is a symlink.
9061         This induces a race but is perhaps the best we can do easily
9062         on oddball platforms where chown does not follow symlinks.
9064 2023-09-09  Bruno Haible  <bruno@clisp.org>
9066         chown, lchown: Revisit platforms.
9067         * doc/posix-functions/chown.texi: Update platforms list.
9068         * doc/posix-functions/lchown.texi: Likewise.
9069         * lib/chown.c (rpl_chown): Add platform comments.
9070         * lib/lchown.c: Likewise.
9072 2023-09-07  Paul Eggert  <eggert@cs.ucla.edu>
9074         mbscasecmp: support GNULIB_MCEL_PREFER
9075         * lib/mbscasecmp.c: Include stdlib.h, since we use MB_CUR_MAX.
9076         Include uchar.h, for c32tolower.
9077         (GNULIB_MCEL_PREFER): Include mcel.h instead of mbuiterf.h.
9078         (mbscasecmp) [GNULIB_MCEL_PREFER]: Use mcel instead of mbuiterf.
9079         * modules/mbscasecmp (Depends-on): Add c32tolower, stdlib, uchar.
9080         Depend on mbuiterf only if not preferring mcel.
9082         exclude: support GNULIB_MCEL_PREFER
9083         Support mcel API for apps that prefer it.
9084         The following changes are in effect only if GNULIB_MCEL_PREFER.
9085         * lib/exclude.c: Include mcel.h instead of mbuiter.h.
9086         (string_hasher_ci): Use mcel_scanz instead of mbui_init,
9087         mbui_avail, mbui_cur, and mbui_advance.
9088         * modules/exclude: Do not depend on mbuiter.
9090         mcel-prefer: new module
9091         * modules/mcel-prefer: New file.
9093         mcel-bench-tests: new module
9094         * modules/mcel-bench-tests, tests/bench-mcel.c: New files.
9095         * tests/bench-multibyte.h (TEXT_LATIN_ASCII_LINE1)
9096         (TEXT_FRENCH_UTF8_LINE1, TEXT_GREEK_UTF8_LINE1)
9097         (TEXT_CHINESE_UTF8_LINE1): New macros.
9098         (text_random_bytes): New constant.
9099         * tests/bench.h (timing_output): Mark with _GL_UNUSED,
9100         since bench-mcel.c does not use it.
9102         mcel-tests: new module
9103         * modules/mcel-tests, tests/test-mcel.c: New files
9105         mcel: new module
9106         * lib/mcel.c, lib/mcel.h, modules/mcel: New files.
9108 2023-09-07  Bruno Haible  <bruno@clisp.org>
9110         Don't use 'throw ()' in C++ 11 or newer.
9111         * lib/stddef.in.h (_GL_ATTRIBUTE_NOTHROW):  Provide fallback definition.
9112         (abort): Declare with _GL_ATTRIBUTE_NOTHROW instead of throw().
9113         * lib/malloc.in.h (rpl_free, free): Likewise.
9114         * lib/stdlib.in.h (free): Likewise.
9115         * lib/string.in.h (rpl_free, free, memchr, memrchr, rawmemchr,
9116         strchrnul, strpbrk, strstr, strcasestr): Likewise.
9117         * lib/wchar.in.h (rpl_free, free): Likewise.
9118         * lib/getopt-cdefs.in.h (__THROW): Define to noexcept(true) for C++ 11
9119         or newer.
9120         * lib/md5.h (__THROW): Likewise.
9122 2023-09-07  Bruno Haible  <bruno@clisp.org>
9124         Add info about recommended warning options with clang.
9125         * HACKING (Warning Options): Add info regarding clang.
9127 2023-09-07  Bruno Haible  <bruno@clisp.org>
9129         uchar: Fix references to overridden functions with GNULIB_NAMESPACE.
9130         * lib/uchar.in.h (btoc32, c32isalnum, c32isalpha, c32isblank,
9131         c32iscntrl, c32isdigit, c32isgraph, c32islower, c32isprint, c32ispunct,
9132         c32isspace, c32isupper, c32isxdigit, c32tolower, c32toupper, c32width,
9133         c32snrtombs, c32srtombs, c32swidth, c32tob, mbsnrtoc32s, mbsrtoc32s,
9134         c32_get_type_test, c32_apply_type_test, c32_get_mapping,
9135         c32_apply_mapping): Use GNULIB_NAMESPACE:: prefix to refer to the gnulib
9136         overridden function.
9137         * modules/uchar (Depends-on): Add wctype-h.
9138         (Makefile.am): Substitute GNULIB_BTOWC, GNULIB_ISWDIGIT,
9139         GNULIB_ISWXDIGIT, GNULIB_WCWIDTH, GNULIB_WCSNRTOMBS, GNULIB_WCSRTOMBS,
9140         GNULIB_WCSWIDTH, GNULIB_WCTOB, GNULIB_MBSNRTOWCS, GNULIB_MBSRTOWCS,
9141         GNULIB_WCTYPE, GNULIB_ISWCTYPE, GNULIB_WCTRANS, GNULIB_TOWCTRANS.
9143 2023-09-07  Bruno Haible  <bruno@clisp.org>
9145         tests: Fix some clang -Wimplicit-fallthrough warnings.
9146         * tests/test-execute-main.c (main): Add 'break' statement.
9147         * tests/test-sys_file.c (main): Likewise.
9149         unictype/category-none: Fix clang -Wpedantic warning.
9150         * lib/unictype/categ_none.c (_UC_CATEGORY_NONE): Use ISO C designated
9151         initializer syntax to initialize the intended field of the union.
9153         c-*snprintf: Fix some clang -Wmissing-prototypes warnings.
9154         * lib/c-snprintf.c: Include c-snprintf.h instead of <stdio.h>.
9155         * lib/c-vsnprintf.c: Include c-vsnprintf.h instead of <stdio.h>.
9156         * lib/c-vasnprintf.c: Include c-vasnprintf.h.
9158 2023-09-06  Bruno Haible  <bruno@clisp.org>
9160         argp: Fix clang -Wextra-semi-stmt warning.
9161         * lib/argp-help.c (SKIPWS): Remove trailing semicolon.
9163 2023-09-06  Bruno Haible  <bruno@clisp.org>
9165         doc: Refine documentation of MSVC support for shared libraries.
9166         * doc/lib-symbol-visibility.texi (Exported Symbols of Shared Libraries):
9167         Recommend to define BUILDING_SHARED as an Autoconf variable. Recommend
9168         to test DLL_EXPORT.
9170 2023-09-06  Bruno Haible  <bruno@clisp.org>
9172         doc: Fix syntax error (regression 2023-09-03).
9173         * doc/posix-headers/sys_stat.texi: Correct @itemize / @end itemize
9174         nesting.
9176 2023-09-05  Bruno Haible  <bruno@clisp.org>
9178         relocatable-lib-lgpl: Don't export symbols from static MSVC .obj files.
9179         Reported by Dmitry Bely <dmitry.bely@gmail.com> in
9180         <https://lists.gnu.org/archive/html/bug-gnu-libiconv/2023-08/msg00002.html>.
9181         * lib/relocatable.h (RELOCATABLE_DLL_EXPORTED): Don't use
9182         __declspec(dllexport) when creating static .obj files with MSVC.
9184 2023-09-05  Bruno Haible  <bruno@clisp.org>
9186         unigbrk/u8-grapheme-{next,prev} tests: Fix gcc -Wformat warnings.
9187         * tests/unigbrk/test-u8-grapheme-next.c (test_u8_grapheme_next): Use
9188         %tu, not %zu, to print a pointer difference.
9189         * tests/unigbrk/test-u16-grapheme-next.c (test_u16_grapheme_next):
9190         Likewise.
9191         * tests/unigbrk/test-u32-grapheme-next.c (test_u32_grapheme_next):
9192         Likewise.
9193         * tests/unigbrk/test-u8-grapheme-prev.c (test_u8_grapheme_prev):
9194         Likewise.
9195         * tests/unigbrk/test-u16-grapheme-prev.c (test_u16_grapheme_prev):
9196         Likewise.
9197         * tests/unigbrk/test-u32-grapheme-prev.c (test_u32_grapheme_prev):
9198         Likewise.
9200 2023-09-05  Bruno Haible  <bruno@clisp.org>
9202         stdint, *printf: Update doc about MSVC.
9203         * doc/posix-headers/stdint.texi: MSVC 14 has <stdint.h>.
9204         * doc/posix-functions/*printf.texi: Current mingw and MSVC 14 support
9205         the j, t, z size specifiers.
9206         * doc/glibc-functions/obstack_*printf.texi: Likewise.
9208 2023-09-05  Bruno Haible  <bruno@clisp.org>
9210         tests: Ensure stderr output is displayed before abort().
9211         * tests/atomic-int-gnulib.h (init_atomic_int): Call fflush(stderr)
9212         before abort().
9213         * tests/atomic-int-isoc.h (init_atomic_int): Likewise.
9214         * tests/atomic-int-posix.h (init_atomic_int): Likewise.
9215         * tests/unigbrk/test-u8-grapheme-breaks.c (test_u8_grapheme_breaks):
9216         Likewise.
9217         * tests/unigbrk/test-u16-grapheme-breaks.c (test_u16_grapheme_breaks):
9218         Likewise.
9219         * tests/unigbrk/test-u32-grapheme-breaks.c (test_u32_grapheme_breaks):
9220         Likewise.
9221         * tests/unigbrk/test-uc-grapheme-breaks.c (test_uc_grapheme_breaks):
9222         Likewise.
9223         * tests/unigbrk/test-ulc-grapheme-breaks.c (main): Likewise.
9224         * tests/unigbrk/test-u8-grapheme-next.c (test_u8_grapheme_next):
9225         Likewise.
9226         * tests/unigbrk/test-u16-grapheme-next.c (test_u16_grapheme_next):
9227         Likewise.
9228         * tests/unigbrk/test-u32-grapheme-next.c (test_u32_grapheme_next):
9229         Likewise.
9230         * tests/unigbrk/test-u8-grapheme-prev.c (test_u8_grapheme_prev):
9231         Likewise.
9232         * tests/unigbrk/test-u16-grapheme-prev.c (test_u16_grapheme_prev):
9233         Likewise.
9234         * tests/unigbrk/test-u32-grapheme-prev.c (test_u32_grapheme_prev):
9235         Likewise.
9237 2023-09-05  Bruno Haible  <bruno@clisp.org>
9239         threads-h: Modernize configure test.
9240         * m4/threads_h.m4 (gl_THREADS_H): In the test program, put the
9241         '_Thread_local' storage class specifier before the type.
9243 2023-09-05  Bruno Haible  <bruno@clisp.org>
9245         Add info about recommended warning options.
9246         * HACKING: New section "Warning Options".
9248 2023-09-04  Bruno Haible  <bruno@clisp.org>
9250         string-buffer tests: Fix a compilation error (regression from today).
9251         * tests/test-string-buffer.c: Include <wchar.h>.
9253         unistr/u{8,16,32}-strtok tests: Fix -Wanalyzer-allocation-size warnings.
9254         * tests/unistr/test-u-strtok.h (test_u_strtok): Correct values of
9255         input_len and delim_len.
9257         sigpipe tests: Fix -Wanalyzer-unsafe-call-within-signal-handler warning.
9258         * tests/test-sigpipe.c (handler): Invoke _exit, not exit.
9259         * tests/test-raise.c (handler): Update comments after 2020-11-25 change.
9261         argp: Distinguish NULL and '\0' from 0.
9262         * lib/argp-pin.c: Include <stddef.h>.
9263         (program_invocation_short_name, program_invocation_name): Use NULL
9264         instead of 0.
9265         * lib/argp-parse.c (convert_options, __argp_parse, __argp_input):
9266         Likewise.
9267         * lib/argp-fmtstream.c (__argp_make_fmtstream): Likewise.
9268         * lib/argp-help.c (make_hol, hol_entry_first_long, hol_find_entry,
9269         hol_append, hol_entry_help, argp_doc, _help): Likewise.
9270         (hol_usage): Use '\0' instead of 0.
9272         argp: Fix gcc -Wanalyzer-use-of-uninitialized-value warning.
9273         * lib/argp-help.c (hol_find_entry): Access hol->entries only after
9274         having verified that hol->num_entries > 0.
9276         unictype/category-byname tests: Fix gcc -Wunused-value warning.
9277         * tests/unictype/test-categ_byname.c (main): Add some tests for category
9278         Nl.
9280         unigbrk/uc-grapheme-breaks tests: Fix gcc -Wunused-function warning.
9281         * tests/unigbrk/test-uc-grapheme-breaks.c
9282         (graphemebreakproperty_to_string): Mark as possibly unused.
9284         bitset, nonblocking-* tests: Fix gcc -Wunused-but-set-variable warnings.
9285         * tests/test-bitset.c (check_zero): Mark 'i' as possibly unused.
9286         * tests/test-nonblocking-reader.h (full_read): Mark 'spent_time' as
9287         possibly unused.
9289 2023-09-04  Bruno Haible  <bruno@clisp.org>
9291         Use statement-expressions without warnings, even in strict ISO C mode.
9292         Suggested by Eric Blake <eblake@redhat.com> in
9293         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00025.html>.
9294         * lib/error.in.h (__gl_error_call): Use the variant with obvious control
9295         flow also with clang. Use '__extension__' to avoid -Wpedantic warnings.
9296         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Define as
9297         macros even when __STRICT_ANSI__ is defined. But use '__extension__' to
9298         avoid -Wpedantic warnings.
9299         * lib/setenv.c (KNOWN_VALUE): Use '__extension__' to avoid -Wpedantic
9300         warnings.
9301         * lib/xalloc-oversized.h (xalloc_oversized): Use optimized variant even
9302         when __STRICT_ANSI__ is defined. But use '__extension__' to avoid
9303         -Wpedantic warnings.
9305 2023-09-04  Bruno Haible  <bruno@clisp.org>
9307         Fix some g++ warnings "has a different exception specifier".
9308         * m4/gnulib-common.m4 (gl_COMMON_BODY): Make _GL_ATTRIBUTE_NOTHROW
9309         effective in C++ mode.
9310         * lib/attribute.h (ATTRIBUTE_NOTHROW): Add a comment.
9311         * lib/malloc.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
9312         (memalign): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
9313         * lib/stdio.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
9314         (fdopen): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
9315         * lib/stdlib.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
9316         (aligned_alloc, calloc, canonicalize_file_name, malloc, realloc): Invoke
9317         _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
9318         * lib/string.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
9319         (strdup, strndup): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
9320         * lib/sys_stat.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback
9321         definition.
9322         (getumask): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
9323         * lib/wchar.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
9324         (wcsdup): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
9326 2023-09-04  Bruno Haible  <bruno@clisp.org>
9328         unistr/u{8,16,32}-strchr tests: Fix some gcc -Wshadow warnings.
9329         * tests/unistr/test-strchr.h (test_strchr): Reduce of scope of local
9330         variable 'i'.
9332         unistr/u{8,16,32}-chr tests: Fix some gcc -Wshadow warnings.
9333         * tests/unistr/test-chr.h (main): Reduce of scope of local variables
9334         'i' and 'page_boundary'.
9336         pipe-filter-gi, pipe-filter-ii tests: Fix some gcc -Wshadow warnings.
9337         * tests/test-pipe-filter-gi1.c (main): Rename local variable 'argv' to
9338         'tr_argv'.
9339         * tests/test-pipe-filter-ii1.c (main): Likewise.
9341         argv-iter tests: Avoid gcc -Wanalyzer-out-of-bounds warning.
9342         * tests/test-argv-iter.c (main): Simplify logic.
9344         crypto/{gc-rijndael,rijndael} tests: Fix some gcc -Wshadow warnings.
9345         * tests/test-gc-rijndael.c (main): Rename local variable 'i' to 'round'.
9346         * tests/test-rijndael.c (main): Likewise.
9348         threads-h tests: Fix gcc -Wold-style-declaration warning.
9349         * tests/test-thread_local.c (value0, value1, value2, value3): Put the
9350         'thread_local' storage class specifier before the type.
9352         ieee754-h tests: Fix some gcc -Wmissing-field-initializers warnings.
9353         * tests/test-ieee754-h.c (float_tests): Use float literals.
9354         (double_tests): Use double literals. Initialize frac_lo.
9356         string-buffer tests: Fix a gcc -Wformat warning.
9357         * tests/test-string-buffer.c: Don't assume that wint_t has the same size
9358         as 'int'.
9360         crypto/* tests: Fix some gcc -Wdiscarded-qualifiers warnings.
9361         * tests/test-gc-hmac-md5.c (main): Change type of variables with a
9362         string literal initializer to 'const char *'.
9363         * tests/test-gc-hmac-sha1.c (main): Likewise.
9364         * tests/test-gc-hmac-sha256.c (main): Likewise.
9365         * tests/test-gc-hmac-sha512.c (main): Likewise.
9366         * tests/test-gc-md2.c (main): Likewise.
9367         * tests/test-gc-md5.c (main): Likewise.
9368         * tests/test-gc-sha1.c (main): Likewise.
9369         * tests/test-gc-sha256.c (main): Likewise.
9370         * tests/test-gc-sha512.c (main): Likewise.
9371         * tests/test-hmac-md5.c (main): Likewise.
9372         * tests/test-hmac-sha1.c (main): Likewise.
9373         * tests/test-hmac-sha256.c (main): Likewise.
9374         * tests/test-hmac-sha512.c (main): Likewise.
9376         file-has-acl: Avoid gcc warning.
9377         * lib/acl-internal.h (MIN): Remove definition.
9379 2023-09-03  Paul Eggert  <eggert@cs.ucla.edu>
9381         same-inode, stat-size: support pointers too
9382         Add functions and macros so that we can test pointers to struct
9383         stat as well as plain struct stat.  This lets coreutils deal with
9384         structs that are only partly initialized, without relying on
9385         undefined behavior.
9386         * NEWS: Mention this.
9387         * doc/posix-headers/sys_stat.texi, doc/stat-size.texi:
9388         Mention this and modernize.
9389         * lib/at-func2.c (at_func2):
9390         * lib/fts.c (same_fd):
9391         * lib/rename.c (rpl_rename) [RENAME_HARD_LINK_BUG]:
9392         * lib/same-inode.c: New file.
9393         * lib/same.c (same_nameat):
9394         * lib/term-style-control.c (activate_term_style_controller):
9395         Prefer psame_inode (a, b) to SAME_INODE (*a, *b).
9396         * lib/hash-triple-simple.c (triple_compare_ino_str):
9397         * lib/hash-triple.c (triple_compare):
9398         Prefer PSAME_INODE (a, b) to SAME_INODE (*a, *b).
9399         psame_inode is not suitable since the args are not struct stat *.
9400         * lib/same-inode.h: Check that config.h is included first.
9401         (SAME_INODE_INLINE, PSAME_INODE): New macros.
9402         (SAME_INODE): Reimplement in terms of PSAME_INODE.
9403         (psame_inode): New function.
9404         * lib/stat-size.h (STP_BLKSIZE, STP_NBLOCKS): New macros.
9405         (ST_BLKSIZE, ST_NBLOCKS): Use them.
9406         * lib/term-style-control.c (log_signal_handler_called):
9407         Always define as a function, to pacify -Wunused*.
9408         * modules/canonicalize-lgpl-tests (Files): Add m4/musl.m4.
9409         (Depends-on): Call gl_MUSL_LIBC.
9410         * modules/same-inode (Files): Add same-inode.c.
9411         (Depends-on): Add extern-inline, stdbool.
9412         (lib_SOURCES): New macro.
9413         * tests/test-binary-io.c, tests/test-canonicalize-lgpl.c:
9414         * tests/test-canonicalize.c, tests/test-cloexec.c:
9415         * tests/test-dup-safer.c, tests/test-dup2.c, tests/test-error.c:
9416         * tests/test-fcntl.c, tests/test-fdopendir.c, tests/test-fgetc.c:
9417         * tests/test-fputc.c, tests/test-fread.c, tests/test-fstat.c:
9418         * tests/test-fstatat.c, tests/test-ftruncate.c:
9419         * tests/test-fwrite.c, tests/test-getcwd.c:
9420         * tests/test-getdtablesize.c, tests/test-isblank.c:
9421         * tests/test-linkat.c, tests/test-lock.c, tests/test-lstat.h:
9422         * tests/test-malloc-gnu.c, tests/test-openat.c:
9423         * tests/test-pthread-thread.c, tests/test-pthread_sigmask1.c:
9424         * tests/test-pthread_sigmask2.c, tests/test-ptsname.c:
9425         * tests/test-ptsname_r.c, tests/test-raise.c:
9426         * tests/test-realloc-gnu.c, tests/test-rwlock1.c:
9427         * tests/test-sigprocmask.c, tests/test-snprintf.c:
9428         * tests/test-stat.h, tests/test-term-style-control-hello.c:
9429         * tests/test-term-style-control-yes.c, tests/test-thread_create.c:
9430         * tests/test-unlinkat.c, tests/test-vasnprintf.c:
9431         * tests/test-xalloc-die.c:
9432         Adjust to these changes, and fix some warnings elicited by
9433         -Wall -Wextra that I ran into while testing.
9434         * top/maint.mk (sc_prohibit_stat_st_blocks): Mention STP_NBLOCKS.
9436 2023-09-02  Bruno Haible  <bruno@clisp.org>
9438         alignalloc: Fix license header.
9439         Suggested by Paul Eggert in
9440         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00170.html>.
9441         * lib/alignalloc.h: Make license header consistent with module
9442         description.
9443         * lib/alignalloc.c: Likewise.
9445 2023-09-01  Bruno Haible  <bruno@clisp.org>
9447         crypto/{sha*,md5}-buffer: Add comment.
9448         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Add comment regarding license.
9450 2023-09-01  Bruno Haible  <bruno@clisp.org>
9452         crypto/{sha*,md5,sm3}-buffer: Fix --with-openssl (regr. 2023-08-26).
9453         Reported by Agostino Sarubbo via Sam James <sam@gentoo.org> in
9454         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00000.html>.
9455         * lib/sha1.h: Test the OpenSSL major version before attempting to
9456         include <openssl/configuration.h>.
9457         * lib/sha256.h: Likewise.
9458         * lib/sha512.h: Likewise.
9459         * lib/md5.h: Likewise.
9460         * lib/sm3.h: Likewise.
9462 2023-08-31  Bruno Haible  <bruno@clisp.org>
9464         readutmp: Fix memory leak introduced by last commit.
9465         * lib/readutmp.c (read_utmp_from_systemd): If num_sessions == 0 and
9466         sessions != NULL, do call free (sessions).
9468 2023-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9470         readutmp: fix core dump if --enable-systemd
9471         Problem reported by Thorsten Kukuk <https://bugs.gnu.org/65617>.
9472         * lib/readutmp.c (read_utmp_from_systemd):
9473         Don’t assume session_ptr != NULL if num_sessions == 0.
9474         In practice it can be null, and the man page OKs this behavior.
9476 2023-08-30  Bruno Haible  <bruno@clisp.org>
9478         doc: Mention the module 'wchar-single'.
9479         * doc/multithread.texi: Mention the module 'wchar-single'.
9481 2023-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9483         wchar-single: fix module broken since 2021
9484         Adjust to 2021-03-07 change “Rename GNULIB_WCHAR_SINGLE to
9485         GNULIB_WCHAR_SINGLE_LOCALE”.  Apparently nobody noticed that
9486         the module was broken.  Perhaps we should obsolete the module?
9487         * modules/wchar-single (GNULIB_WCHAR_SINGLE_LOCALE): Define.
9489 2023-08-29  Bruno Haible  <bruno@clisp.org>
9491         wctype: Rely on module iswpunct.
9492         * m4/wctype.m4 (gl_FUNC_WCTYPE): Also test whether the "punct" class
9493         works.
9494         * modules/wctype (Depends-on): Add iswpunct.
9495         * tests/test-iswctype.c (main): Add more tests of the "punct" class.
9496         * doc/posix-functions/wctype.texi: Mention the Android problem.
9498         c32ispunct: Rely on module iswpunct.
9499         * modules/c32ispunct (Depends-on): Add iswpunct.
9500         * tests/test-c32ispunct.c (main): Add a few more tests in the "C"
9501         locale.
9503         iswpunct: Add tests.
9504         * tests/test-iswpunct.c: New file, based on tests/test-iswdigit.c and
9505         tests/test-c32ispunct.c.
9506         * tests/test-iswpunct.sh: New file, based on tests/test-iswdigit.sh.
9507         * modules/iswpunct-tests: New file.
9509         iswpunct: New module.
9510         * lib/wctype.in.h (iswpunct): New declaration.
9511         * lib/iswpunct.c: New file.
9512         * m4/iswpunct.m4: New file.
9513         * m4/wctype_h.m4 (gl_WCTYPE_H_REQUIRE_DEFAULTS): Initialize
9514         GNULIB_ISWPUNCT.
9515         (gl_WCTYPE_H_DEFAULTS): Initialize REPLACE_ISWPUNCT.
9516         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWPUNCT,
9517         REPLACE_ISWPUNCT.
9518         * modules/iswpunct: New file.
9519         * doc/posix-functions/iswpunct.texi: Mention the new module.
9521         wctype-h tests: Add more tests.
9522         * tests/test-wctype-h.c (main): Add a sanity check of iswpunct.
9524 2023-08-29  Bruno Haible  <bruno@clisp.org>
9526         iswdigit, iswxdigit: Fix documentation.
9527         * doc/posix-functions/iswdigit.texi: Mention the module 'iswdigit'.
9528         * doc/posix-functions/iswxdigit.texi: Mention the module 'iswxdigit'.
9530 2023-08-29  Bruno Haible  <bruno@clisp.org>
9532         wctype: Fix documentation (mistake 2023-07-26).
9533         * doc/posix-functions/wctype.texi: The "blank" argument problem on mingw
9534         is now worked around by Gnulib.
9536 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
9538         trim: do not over-allocate result
9539         * lib/trim.c: Include mbuiterf.h, not mbiterf.h, since we no
9540         longer compute strlen at first.
9541         (trim2): Do not over-allocate result and then trim the parts we
9542         don’t want.  Instead, skip unwanted input before allocating,
9543         so that the result is just the right size.  Use mempcpy
9544         instead of memmove.  Simplify.
9545         * modules/trim (Depends-on): Remove mbiterf, memmove, strdup, xalloc.
9546         Add mbuiterf, mempcpy, xalloc-die.
9548 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
9550         propername: tune single-byte code
9551         * lib/propername.c (mbsstr_trimmed_wordbounded): Cache MB_CUR_MAX.
9552         Simplify word boundary detection in single-byte code.
9554 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
9556         Tune single-byte code involving tolower
9557         * lib/mbmemcasecmp.c (mbmemcasecmp):
9558         * lib/mbscasecmp.c (mbscasecmp):
9559         * lib/mbscasestr.c (mbscasestr):
9560         * lib/mbsncasecmp.c (mbsncasecmp):
9561         * lib/mbspcasecmp.c (mbspcasecmp):
9562         Avoid some unnecessary calls to tolower.  For example, if the two
9563         single-byte characters are equal before downcasing there is no
9564         need to call tolower on either character.
9566 2023-08-26  Bruno Haible  <bruno@clisp.org>
9568         c32width tests: Avoid failure on FreeBSD 12.
9569         * tests/test-c32width.c (main): Skip two tests on FreeBSD < 13.
9571 2023-08-26  Bruno Haible  <bruno@clisp.org>
9573         crypto/{sha*,md5,sm3}-buffer: Ignore too old OpenSSL versions.
9574         * lib/sha1.h: If <openssl/macros.h> would give a compile-time error,
9575         undefine HAVE_OPENSSL_SHA1.
9576         * lib/sha256.h: If <openssl/macros.h> would give a compile-time error,
9577         undefine HAVE_OPENSSL_SHA256.
9578         * lib/sha512.h: If <openssl/macros.h> would give a compile-time error,
9579         undefine HAVE_OPENSSL_SHA512.
9580         * lib/md5.h: If <openssl/macros.h> would give a compile-time error,
9581         undefine HAVE_OPENSSL_MD5.
9582         * lib/sm3.h: If <openssl/macros.h> would give a compile-time error,
9583         undefine HAVE_OPENSSL_SM3.
9585 2023-08-26  Bruno Haible  <bruno@clisp.org>
9587         selinux-h: Add a comment.
9588         * lib/se-selinux.in.h: Clarify which #endif belongs to the
9589         double-inclusion guard.
9591 2023-08-26  Bruno Haible  <bruno@clisp.org>
9593         sys_utsname: Make double-inclusion guard more robust.
9594         * lib/sys_utsname.in.h: Test the guard symbol a second time.
9596 2023-08-26  Bruno Haible  <bruno@clisp.org>
9598         sys_times: Make double-inclusion guard more robust.
9599         * lib/sys_times.in.h: Test the guard symbol a second time.
9601 2023-08-26  Bruno Haible  <bruno@clisp.org>
9603         uchar: Make #include_next work right.
9604         * lib/uchar.in.h: Use a split double-inclusion guard.
9606 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
9608         utimens: update FIXME date
9609         * lib/utimens.c (fdutimens): Change FIXME date to agree with
9610         similar FIXME in utimensat.c.
9612 2023-08-24  Paul Eggert  <eggert@cs.ucla.edu>
9614         exclude: refactor for more-modern style
9615         * lib/exclude.c: Sort include directives.
9616         (fnmatch_pattern_has_wildcards, file_name_matches):
9617         Prefer ‘true’ to ‘1’.
9618         (string_hasher, string_compare, string_compare_ci):
9619         Avoid unnecessary locals.
9620         (string_free): Remove.  All callers changed to just use ‘free’.
9621         (new_exclude_segment): Prefer xmalloc to xzalloc when it’s
9622         clearer to initialize ourselves.
9623         (new_exclude_segment, exclude_patopts, add_exclude_fp):
9624         Prefer nullptr to NULL.
9625         (free_exclude_segment, file_pattern_matches):
9626         Avoid unnecessary nesting.
9627         (free_exclude, fnmatch_no_wildcards, exclude_fnmatch)
9628         (excluded_file_name, add_exclude, add_exclude_fp):
9629         Assume C99 decl syntax.
9630         (fnmatch_no_wildcards): Prefer idx_t to size_t.
9631         (exclude_fnmatch, add_exclude_fp): Prefer ‘f (x)’ to ‘(*f) (x)’.
9632         (add_exclude): Help compiler by refactoring search for
9633         trailing slashes.  Avoid unnecessary cast to char *.
9634         * modules/exclude (Depends-on): Add nullptr.
9636 2023-08-21  Paul Eggert  <eggert@cs.ucla.edu>
9638         unlocked-io: fix getc_unlocked typo
9639         * lib/unlocked-io.h (getc): Fix misspelling of ‘getc_unlocked’.
9641 2023-08-21  Bruno Haible  <bruno@clisp.org>
9643         alignasof, stdalign: Fix a compilation error in C++ mode on FreeBSD 12.
9644         * m4/stdalign.m4 (gl_ALIGNASOF): In C++ mode, prefer __builtin_offsetof
9645         over offsetof when possible, since __builtin_offsetof works also when
9646         <stddef.h> has not been fully included yet.
9648 2023-08-21  Bruno Haible  <bruno@clisp.org>
9650         wcsstr: Relicense under LGPLv2+.
9651         * modules/wcsstr (License): Change to LGPLv2+.
9653         wcsstr-simple: Relicense under LGPLv2+.
9654         * modules/wcsstr-simple (License): Change to LGPLv2+.
9655         * lib/wcsstr.c: Update license notice.
9656         * lib/wcsstr-impl.h: Update license notice. The code added here on
9657         2023-03-27 was under LGPLv2+.
9659         wmemcmp: Relicense under LGPLv2+.
9660         * modules/wmemcmp (License): Change to LGPLv2+.
9661         * lib/wmemcmp.c: Update license notice.
9662         * lib/wmemcmp-impl.h: Likewise.
9664         wcschr: Relicense under LGPLv2+.
9665         * modules/wcschr (License): Change to LGPLv2+.
9666         * lib/wcschr.c: Update license notice.
9667         * lib/wcschr-impl.h: Likewise.
9669 2023-08-21  Bruno Haible  <bruno@clisp.org>
9671         unistr/u32-strlen: Complete license change from 2023-07-23.
9672         * lib/unistr/u-strlen.h: Update license notice.
9674 2023-08-21  Bruno Haible  <bruno@clisp.org>
9676         isnanl: Relicense under LGPLv2+.
9677         * modules/isnanl (License): Change to LGPLv2+.
9679 2023-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9681         ldexp: port to non-two’s complement
9682         * lib/ldexp.c (FUNC): Don’t assume two’s-complement.
9684 2023-08-20  Bruno Haible  <bruno@clisp.org>
9686         readutmp, boot-time: Fix the result on runit and s6 init systems.
9687         * lib/boot-time-aux.h (get_linux_boot_time_fallback): Try also
9688         /var/lib/urandom/random-seed. Try /var/run/utmp last.
9690 2023-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9692         ldexp: fix INT_MIN infloop
9693         * lib/ldexp.c (FUNC): Instead of converting EXP to unsigned,
9694         work on it directly.  This simplifies the code and avoids
9695         an infinite loop when EXP == INT_MIN.
9696         * modules/ldexp, modules/ldexpl: Depend on stdbool.
9697         * tests/test-ldexp.h: Include <limits.h> for INT_MIN.
9698         (test_function): Test for infloop.
9700 2023-08-20  Bruno Haible  <bruno@clisp.org>
9702         ldexp: Fix compilation error in C++ mode.
9703         * lib/math.in.h (ldexp): Use _GL_CXXALIASWARN1, not _GL_CXXALIASWARN.
9705 2023-08-19  Bruno Haible  <bruno@clisp.org>
9707         ldexp: Work around OpenBSD/mips64 bug.
9708         * lib/math.in.h (ldexp): New declaration.
9709         * lib/ldexp.c: New file, based on lib/ldexpl.c.
9710         * lib/ldexpl.c: Moved the implementation to lib/ldexp.c. Just include
9711         it.
9712         * m4/math_h.m4 (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_LDEXP.
9713         (gl_MATH_H_DEFAULTS): Initialize REPLACE_LDEXP.
9714         * m4/ldexp.m4 (gl_FUNC_LDEXP): Require gl_MATH_H_DEFAULTS and
9715         gl_FUNC_ISNAND. Invoke gl_FUNC_LDEXP_WORKS. Set REPLACE_LDEXP. Consider
9716         it when setting LDEXP_LIBM.
9717         (gl_FUNC_LDEXP_WORKS): New macro.
9718         * modules/math (Makefile.am): Substitute GNULIB_LDEXP, REPLACE_LDEXP.
9719         * modules/ldexp (Files): Add lib/ldexp.c.
9720         (Depends-on): Add math, isnand.
9721         (configure.ac): Set GL_COND_OBJ_LDEXP. Invoke gl_MATH_MODULE_INDICATOR.
9722         (Makefile.am): Conditionally compile ldexp.c.
9723         * modules/ldexpl (Files): Add lib/ldexp.c.
9724         * doc/posix-functions/ldexp.texi: Mention the OpenBSD bug.
9726 2023-08-19  Bruno Haible  <bruno@clisp.org>
9728         ldexpl: Relicense under LGPLv2+.
9729         * modules/ldexpl (License): Change to LGPLv2+.
9730         * lib/ldexpl.c: Update license notice.
9732 2023-08-19  Bruno Haible  <bruno@clisp.org>
9734         isnand: Relicense under LGPLv2+.
9735         * modules/isnand (License): Change to LGPLv2+.
9737 2023-08-19  Bruno Haible  <bruno@clisp.org>
9739         ldexpl: Avoid possible -Wshadow warning.
9740         * lib/ldexpl.c (exp): Locally rename to 'exponent'.
9742         ldexpl: Fix signed integer overflow.
9743         * lib/ldexpl.c (ldexpl): Use an 'unsigned int' variable to represent the
9744         absolute value of exp without overflow.
9746 2023-08-19  Bruno Haible  <bruno@clisp.org>
9748         logbl: Work around endless loop on OpenBSD 7.3/mips64.
9749         * m4/logbl.m4 (gl_FUNC_LOGBL_WORKS): Terminate the test program if it
9750         takes longer than 5 seconds.
9751         * doc/posix-functions/logbl.texi: Mention the OpenBSD bug.
9753 2023-08-18  Bruno Haible  <bruno@clisp.org>
9755         thrd: Work around thrd_join bug on AIX 7.3.1.
9756         * m4/threads_h.m4 (gl_THREADS_H): Test against AIX 7 thrd_join bug. Set
9757         BROKEN_THRD_JOIN.
9758         (gl_THREADS_H_DEFAULTS): Initialize BROKEN_THRD_JOIN.
9759         * m4/thrd.m4 (gl_FUNC_THRD_JOIN): Set REPLACE_THRD_* to 1 also if
9760         BROKEN_THRD_JOIN is 1. Define BROKEN_THRD_START_T_OR_JOIN instead of
9761         BROKEN_THRD_START_T.
9762         * modules/threads-h (Makefile.am): Substitute BROKEN_THRD_JOIN.
9763         * lib/threads.in.h (rpl_thrd_t, thrd_t): Define also if BROKEN_THRD_JOIN
9764         is 1.
9765         * lib/thrd.c: Test BROKEN_THRD_START_T_OR_JOIN instead of
9766         BROKEN_THRD_START_T.
9767         * doc/posix-functions/thrd_join.texi: Update.
9768         * doc/posix-functions/thrd_exit.texi: Likewise.
9770         thrd: Refactor.
9771         * m4/thrd.m4 (gl_FUNC_THRD_JOIN): Define BROKEN_THRD_JOIN_NULL, not
9772         BROKEN_THRD_JOIN. Rename gl_cv_func_thrd_join_works to
9773         gl_cv_func_thrd_join_null_works.
9774         * lib/thrd.c: Test BROKEN_THRD_JOIN_NULL instead of BROKEN_THRD_JOIN.
9776 2023-08-18  Bruno Haible  <bruno@clisp.org>
9778         thrd tests: Add unit test for thrd_exit.
9779         * tests/test-thrd_exit.c: New file, based on tests/test-thrd_create.c.
9780         * modules/thrd-tests (Files): Add it.
9781         (Makefile.am): Compile and run it.
9783         thrd: On AIX 7.1 and 7.2, override also thrd_exit.
9784         * lib/threads.in.h (thrd_exit): Consider REPLACE_THRD_EXIT.
9785         * lib/thrd.c (rpl_thrd_exit): New function.
9786         * m4/threads_h.m4 (gl_THREADS_H_DEFAULTS): Initialize REPLACE_THRD_EXIT.
9787         * m4/thrd.m4 (gl_FUNC_THRD_JOIN): Set also REPLACE_THRD_EXIT and adjust
9788         LIBSTDTHREAD.
9789         * modules/threads-h (Makefile.am): Substitute REPLACE_THRD_EXIT.
9790         * doc/posix-functions/thrd_exit.texi: Mention the AIX thrd_join problem
9791         also here.
9793 2023-08-18  Bruno Haible  <bruno@clisp.org>
9795         aligned_alloc: Fix test failure on AIX 7.3 with ibm-clang.
9796         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Use 'volatile', to
9797         disable optimization of ibm-clang -O2.
9798         * doc/posix-functions/aligned_alloc.texi: Update version info.
9800 2023-08-18  Bruno Haible  <bruno@clisp.org>
9802         sys_socket: Fix compilation errors in C++ mode on AIX 7.3 with gcc.
9803         * lib/sys_socket.in.h (accept, getpeername, getsockname, recvfrom):
9804         Disable _GL_CXXALIASWARN invocation on non-glibc systems.
9806 2023-08-18  Bruno Haible  <bruno@clisp.org>
9808         stddef: Don't unnecessarily override max_align_t on AIX 7.3 with gcc.
9809         * lib/stddef.in.h (max_align_t, GNULIB_defined_max_align_t): Don't
9810         define or override if HAVE_MAX_ALIGN_T is 1.
9812 2023-08-18  Bruno Haible  <bruno@clisp.org>
9814         uptime: Deprecate.
9815         Suggested by Paul Eggert in
9816         <https://lists.gnu.org/archive/html/bug-coreutils/2023-08/msg00070.html>.
9817         * modules/uptime (Status, Notice): New sections.
9819 2023-08-17  Bruno Haible  <bruno@clisp.org>
9821         Recognize the *-*-windows* config triplets introduced on 2023-06-26.
9822         * m4/*.m4: Treat windows* as equivalent to mingw*.
9823         * modules/*: Likewise.
9825 2023-08-16  Bruno Haible  <bruno@clisp.org>
9827         mbrtoc32-regular: Make it work as expected on glibc 2.12.
9828         * lib/mbrtoc32.c (mbrtoc32): If necessary, clear the mbstate_t after
9829         mbrtowc() returned.
9831 2023-08-16  Bruno Haible  <bruno@clisp.org>
9833         fnmatch: Override fnmatch from glibc versions < 2.22.
9834         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Force REPLACE_FNMATCH=1 in
9835         glibc versions < 2.22.
9837 2023-08-16  Bruno Haible  <bruno@clisp.org>
9839         tests: Avoid some test failures on Slackware 13.37.
9840         * tests/test-c32isalnum.c (main): Disable GB18030 tests on
9841         glibc 2.13..2.15.
9842         * tests/test-c32isalpha.c (main): Likewise.
9843         * tests/test-c32isblank.c (main): Likewise.
9844         * tests/test-c32iscntrl.c (main): Likewise.
9845         * tests/test-c32isdigit.c (main): Likewise.
9846         * tests/test-c32isgraph.c (main): Likewise.
9847         * tests/test-c32islower.c (main): Likewise.
9848         * tests/test-c32isprint.c (main): Likewise.
9849         * tests/test-c32ispunct.c (main): Likewise.
9850         * tests/test-c32isspace.c (main): Likewise.
9851         * tests/test-c32isupper.c (main): Likewise.
9852         * tests/test-c32isxdigit.c (main): Likewise.
9853         * tests/test-c32rtomb.c (main): Likewise.
9854         * tests/test-c32snrtombs.c (main): Likewise.
9855         * tests/test-c32srtombs.c (main): Likewise.
9856         * tests/test-c32stombs.c (main): Likewise.
9857         * tests/test-c32tolower.c (main): Likewise.
9858         * tests/test-c32toupper.c (main): Likewise.
9859         * tests/test-fnmatch.c (main): Likewise.
9860         * tests/test-mbrtoc16.c (main): Likewise.
9861         * tests/test-mbrtoc32.c (main): Likewise.
9862         * tests/test-mbsnrtoc32s.c (main): Likewise.
9863         * tests/test-mbsrtoc32s.c (main): Likewise.
9864         * tests/test-mbstoc32s.c (main): Likewise.
9866 2023-08-15  Bruno Haible  <bruno@clisp.org>
9868         readutmp tests: Add test against today's bug.
9869         * tests/test-readutmp.c (main): Verify that there is exactly one
9870         BOOT_TIME entry.
9872         readutmp: Fix for platforms without ut_type (regression 2023-08-08).
9873         * lib/readutmp.h (UT_TYPE_BOOT_TIME, UT_TYPE_USER_PROCESS): Don't use
9874         UT_TYPE_EQ macro.
9875         (IS_USER_PROCESS): Don't use UT_USER, UT_TYPE_NOT_DEFINED macros.
9876         * lib/readutmp.c (IS_USER_PROCESS): Don't override.
9878 2023-08-14  Bruno Haible  <bruno@clisp.org>
9880         readutmp, boot-time: Don't use __UT_* symbols (regression 2023-08-11).
9881         * lib/readutmp.h (_GL_UT_USER_SIZE, _GL_UT_ID_SIZE, _GL_UT_LINE_SIZE,
9882         _GL_UT_HOST_SIZE): New macros.
9883         (struct utmpx32): Use them.
9885 2023-08-14  Bruno Haible  <bruno@clisp.org>
9887         readutmp, boot-time: Fix build on 32-bit glibc (regression 2023-08-11).
9888         Reported by Andreas Schwab <schwab@suse.de> in
9889         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00125.html>.
9890         * lib/readutmp.h (struct utmpx32): Reference __UT_NAMESIZE, not
9891         __UT_USERSIZE.
9893 2023-08-13  Bruno Haible  <bruno@clisp.org>
9895         stdint: Fix configure test result with gcc 4.7 or 4.8.
9896         * m4/stdint.m4 (gl_STDINT_H): Don't assume that _Generic works with
9897         GCC versions < 4.9 with -std=gnu11.
9899 2023-08-13  Bruno Haible  <bruno@clisp.org>
9901         Fix some test module descriptions.
9902         * modules/boot-time-tests (Files): Add tests/macros.h.
9903         * modules/dprintf-gnu-tests (Files): Likewise.
9904         * modules/fclose-tests (Files): Likewise.
9905         * modules/getcwd-tests (Files): Likewise.
9906         * modules/lock-tests (Files): Likewise.
9907         * modules/nullptr-c++-tests (Files): Likewise.
9908         * modules/posix_spawn-tests (Files): Likewise.
9909         * modules/posix_spawnp-tests (Files): Likewise.
9910         * modules/readutmp-tests (Files): Likewise.
9911         * modules/sh-quote-tests (Files): Likewise.
9912         * modules/unigbrk/u16-grapheme-breaks-tests (Files): Likewise.
9913         * modules/unigbrk/u16-grapheme-next-tests (Files): Likewise.
9914         * modules/unigbrk/u16-grapheme-prev-tests (Files): Likewise.
9915         * modules/unigbrk/u32-grapheme-breaks-tests (Files): Likewise.
9916         * modules/unigbrk/u32-grapheme-next-tests (Files): Likewise.
9917         * modules/unigbrk/u32-grapheme-prev-tests (Files): Likewise.
9918         * modules/unigbrk/u8-grapheme-breaks-tests (Files): Likewise.
9919         * modules/unigbrk/u8-grapheme-next-tests (Files): Likewise.
9920         * modules/unigbrk/u8-grapheme-prev-tests (Files): Likewise.
9921         * modules/unigbrk/uc-grapheme-breaks-tests (Files): Likewise.
9923 2023-08-13  Bruno Haible  <bruno@clisp.org>
9925         nproc, physmem: Use sysctl() as a fallback on GNU/kFreeBSD.
9926         * lib/nproc.c: Do include <sys/sysctl.h> on GNU/kFreeBSD.
9927         (num_processors_ignoring_omp): Call sysctl on GNU/kFreeBSD.
9928         * lib/physmem.c: Do include <sys/sysctl.h> on GNU/kFreeBSD.
9929         (physmem_total, physmem_available): Call sysctl on GNU/kFreeBSD.
9931 2023-08-13  Bruno Haible  <bruno@clisp.org>
9933         physmem: Add tests.
9934         * tests/test-physmem.c: New file.
9935         * modules/physmem-tests: New file.
9937 2023-08-13  Bruno Haible  <bruno@clisp.org>
9939         readutmp, boot-time: Fix warning on glibc 2.30..2.31 on Linux.
9940         Reported by Pádraig Brady in
9941         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00110.html>.
9942         * lib/readutmp.c: Don't include <sys/sysctl.h> on glibc/Linux.
9943         * lib/boot-time.c: Likewise.
9945 2023-08-13  Paul Eggert  <eggert@cs.ucla.edu>
9947         fts: improve memory-allocation errno handling
9948         * lib/fts.c (fts_read, fts_build): When enter_dir or setup_dir
9949         fails, report its errno value back to the user.
9950         (internal_function): Preserve errno.
9951         * modules/fts (Depends-on): Add calloc-posix, free-posix,
9952         malloc-posix, and realloc-posix, for better errno handling
9953         on allocation failures.
9955         hash: set errno on failure
9956         * lib/hash.c: Include errno.h.
9957         (compute_bucket_size, hash_initialize, hash_rehash)
9958         (hash_insert_if_absent): Set errno reliably on failure.
9959         (hash_free): Preserve errno, like plain 'free'.
9960         * modules/hash (Depends-on): Depend on calloc-posix,
9961         free-posix, malloc-posix, so that errno is set reliably.
9963 2023-08-13  Bruno Haible  <bruno@clisp.org>
9965         readutmp, boot-time: Fix compilation error on old Android.
9966         Reported by Po Lu in
9967         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00108.html>.
9968         * lib/readutmp.h (BOOT_TIME): Add fallback.
9970 2023-08-13  Bruno Haible  <bruno@clisp.org>
9972         readutmp, boot-time: Fix compilation error on Android API 8.
9973         Reported by Po Lu in
9974         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00108.html>.
9975         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test whether sysinfo is
9976         declared.
9977         * lib/boot-time-aux.h (get_linux_uptime): Invoke sysinfo only if it is
9978         declared.
9979         * doc/glibc-functions/sysinfo.texi: Mention the Android problem.
9981 2023-08-13  Bruno Haible  <bruno@clisp.org>
9983         readutmp, boot-time: Fix compilation error on old Android.
9984         Reported by Po Lu in
9985         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00108.html>.
9986         * lib/readutmp.c (endutent): New fallback declaration, for Android.
9987         (getutent): Remove Ultrix workaround from 2000-04-05.
9988         * lib/boot-time.c: Likewise.
9989         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test whether endutent is
9990         declared, not getutent.
9991         * doc/glibc-functions/endutent.texi: Mention the Android bug.
9993 2023-08-12  Paul Eggert  <eggert@cs.ucla.edu>
9995         boot-time,readutmp: do not depend on c-strtod
9996         * lib/boot-time-aux.h (get_linux_uptime): Compute struct timespec
9997         using integer arithmetic rather than double.
9998         * lib/boot-time.c, lib/readutmp.c: Don’t include c-strtod.h.
9999         * modules/boot-time, modules/readutmp (Depends-on): Remove c-strtod.
10001         boot-time,readutmp: remove -lrt usage
10002         This code uses clock-relevant functions only on platforms
10003         that do not need -lrt.
10004         * m4/readutmp.m4 (gl_READUTMP): Do not require gl_CLOCK_TIME
10005         or add CLOCK_TIME_LIB to READUTMP_LIB.
10006         * modules/boot-time (Link): No need to link with CLOCK_TIME_LIB.
10008         boot-time,readutmp: do not depend on fopen-gnu
10009         These modules should work well enough even if fopen is not fixed
10010         to conform to fopen-gnu standards.  The only gotcha I can see is
10011         older fopen implementations that lack support for "e", and
10012         a potential O_CLOEXEC leak is not worth worrying about.
10013         * modules/boot-time (Depends-on):
10014         * modules/readutmp (Depends-on):
10015         Remove fopen-gnu.
10017         readutmp: do not depend on timespec_get
10018         boot-time code no longer needs it.
10019         * modules/readutmp (Depends-on): Remove timespec_get.
10021         boot-time: do not depend on timespec_get
10022         This is for Emacs, which does not use timespec_get now
10023         and which likes to minimize dependencies.
10024         Also, treat musl libc like recent glibc,
10025         and fix a timespec_get return value typo.
10026         * lib/boot-time-aux.h (get_linux_uptime):
10027         Assume musl libc supports CLOCK_BOOTTIME.
10028         (get_linux_boot_time_final_fallback):
10029         Likewise for musl libc and CLOCK_REALTIME.
10030         Do not rely on the timespec_get module, to break the dependency.
10031         Consider 0 to be a failure return from timespec_get.
10032         Fall back on gettimeofday if timespec_get does not exist.
10033         * modules/boot-time (Depends-on): Remove timespec_get.
10035 2023-08-12  Bruno Haible  <bruno@clisp.org>
10037         readutmp, boot-time: Fix parsing of /proc/uptime.
10038         * lib/boot-time-aux.h (get_linux_uptime): Use c_strtod, not strtod.
10039         * lib/readutmp.c: Include c-strtod.h.
10040         * lib/boot-time.c: Likewise.
10041         * modules/readutmp (Depends-on): Add c-strtod.
10042         * modules/boot-time (Depends-on): Likewise.
10044 2023-08-12  Bruno Haible  <bruno@clisp.org>
10046         readutmp: On Linux, don't fail if /var/run/utmp is not accessible.
10047         * lib/boot-time-aux.h (get_linux_boot_time_final_fallback): Don't test
10048         NEED_BOOT_TIME_FINAL_FALLBACK.
10049         * lib/boot-time.c (NEED_BOOT_TIME_FINAL_FALLBACK): Remove macro.
10050         * lib/readutmp.c (NEED_BOOT_TIME_FINAL_FALLBACK): Remove macro.
10051         (read_utmp_from_file): As a fallback on Linux, invoke
10052         get_linux_boot_time_final_fallback.
10053         (get_boot_time_uncached): Don't do it here.
10054         * m4/readutmp.m4 (gl_READUTMP): Add $CLOCK_TIME_LIB to READUTMP_LIB.
10056 2023-08-12  Bruno Haible  <bruno@clisp.org>
10058         readutmp, boot-time: On Haiku, return the boot time.
10059         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test whether <OS.h> exists.
10060         * lib/boot-time-aux.h (get_haiku_boot_time,
10061         get_haiku_boot_time_final_fallback): New functions.
10062         * lib/readutmp.c: Include <OS.h>.
10063         (read_utmp_from_file): If opening UTMP_FILE fails, continue processing
10064         instead of failing. Invoke get_haiku_boot_time and
10065         get_haiku_boot_time_final_fallback.
10066         * lib/boot-time.c: Include <OS.h>.
10067         (get_boot_time_uncached): Invoke get_haiku_boot_time and
10068         get_haiku_boot_time_final_fallback.
10070 2023-08-12  Bruno Haible  <bruno@clisp.org>
10072         readutmp: Reduce code duplication.
10073         * lib/readutmp.c (have_boot_time): New function.
10074         (read_utmp_from_file): Invoke it, instead of duplicating the same loop.
10076 2023-08-12  Paul Eggert  <eggert@cs.ucla.edu>
10078         c-file-type: new module
10079         * lib/c-file-type.c: New file, containing all of the
10080         old file-type except for the gettext call.
10081         * lib/file-type.c (_): Remove; no longer used.
10082         (file_type): Call c_file_type for most of the work.
10083         * modules/c-file-type: New module.
10084         * modules/file-type (Depends-on): Add c-file-type.
10086 2023-08-12  Bruno Haible  <bruno@clisp.org>
10088         readutmp, boot-time: Use the BSD sysctl as fallback.
10089         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test for <sys/param.h>,
10090         <sys/sysctl.h>, sysctl.
10091         * lib/boot-time-aux.h (get_bsd_boot_time_final_fallback): New function.
10092         * lib/readutmp.c: Include <sys/param.h> and <sys/sysctl.h>.
10093         (read_utmp_from_file): Invoke get_bsd_boot_time_final_fallback as a
10094         fallback.
10095         * lib/boot-time.c: Include <sys/param.h> and <sys/sysctl.h>.
10096         (get_boot_time_uncached): Invoke get_bsd_boot_time_final_fallback as a
10097         fallback.
10099 2023-08-12  Bruno Haible  <bruno@clisp.org>
10101         readutmp: Fix compilation error on OpenBSD (regression 2023-08-11).
10102         * lib/readutmp.c (read_utmp_from_file): Remove extraneous 'break'
10103         statement.
10105 2023-08-11  Bruno Haible  <bruno@clisp.org>
10107         boot-time: Add comment about multithread-safety.
10108         * lib/boot-time.h (get_boot_time): Add comment, same as in readutmp.h.
10110 2023-08-11  Bruno Haible  <bruno@clisp.org>
10112         boot-time: Simplify execution.
10113         * lib/boot-time.c: Include <stdio.h>, <string.h>, <sys/types.h>,
10114         <sys/stat.h>, <sys/sysinfo.h>, <time.h>, stat-time.h, unlocked-io.h,
10115         boot-time-aux.h.
10116         (UT_USER): New macro, from lib/readutmp.c.
10117         (getutent): New declaration.
10118         (get_boot_time_uncached): New function, containing a simplified code
10119         from lib/readutmp.c.
10120         (get_boot_time): Don't invoke read_utmp. Instead, invoke
10121         get_boot_time_uncached and cache the result.
10122         * modules/boot-time (Files): Add lib/boot-time-aux.h, lib/readutmp.h,
10123         m4/readutmp.m4.
10124         (Depends-on): Remove readutmp. Add extensions, fopen-gnu, stat-time,
10125         stdbool, time-h, timespec_get, unlocked-io-internal.
10126         (configure.ac): Invoke gl_PREREQ_READUTMP_H.
10127         (Link): Remove $(READUTMP_LIB). Add $(CLOCK_TIME_LIB).
10128         * modules/boot-time-tests (Makefile.am): Link test-boot-time with
10129         $(CLOCK_TIME_LIB), not with $(READUTMP_LIB).
10131 2023-08-11  Bruno Haible  <bruno@clisp.org>
10133         readutmp: Refactor boot time determination code.
10134         * lib/boot-time-aux.h: New file, extracted from lib/readutmp.c.
10135         * lib/readutmp.c: On Linux, include <sys/sysinfo.h> even if
10136         !READUTMP_USE_SYSTEMD.
10137         Include boot-time-aux.h.
10138         (SIZEOF): Remove macro, moved to boot-time-aux.h.
10139         (get_linux_uptime): Remove function, moved to boot-time-aux.h.
10140         (read_utmp_from_file): Invoke get_linux_boot_time_fallback,
10141         get_android_boot_time, get_openbsd_boot_time, get_windows_boot_time.
10142         Code moved to boot-time-aux.h.
10143         (get_boot_time_uncached: Invoke get_linux_boot_time_final_fallback.
10144         Code moved to boot-time-aux.h.
10145         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): New macro, extracted from
10146         gl_READUTMP.
10147         (gl_READUTMP): Invoke it.
10148         * modules/readutmp (Files): Add lib/boot-time-aux.h.
10150 2023-08-11  Bruno Haible  <bruno@clisp.org>
10152         readutmp: Make 'struct utmpx32' usable by other code.
10153         * lib/readutmp.h (struct utmpx32): Moved to here from lib/readutmp.c.
10154         (UTMP_STRUCT_NAME): Define as utmpx32 if needed.
10155         * lib/readutmp.c (read_utmp_from_file): Simply use UTMP_STRUCT_NAME.
10157 2023-08-11  Bruno Haible  <bruno@clisp.org>
10159         readutmp tests: Fix link error.
10160         * modules/readutmp-tests (Makefile.am): Link test-readutmp with
10161         $(LIBINTL).
10163 2023-08-11  Bruno Haible  <bruno@clisp.org>
10165         readutmp: Fix the boot time returned on Minix.
10166         * lib/readutmp.c (read_utmp_from_file): [__minix] When the time of the
10167         BOOT_TIME entry is very close to the Epoch, replace it with the time
10168         from the "run-level m" entry.
10170 2023-08-11  Bruno Haible  <bruno@clisp.org>
10172         readutmp: On Cygwin and Windows, return the boot time.
10173         * lib/readutmp.h (READ_UTMP_SUPPORTED): Define also on native Windows.
10174         * lib/readutmp.c (desirable_utmp_entry): Ignore READ_UTMP_CHECK_PIDS on
10175         Windows.
10176         (read_utmp_from_file): Add a BOOT_TIME entry on Windows.
10178 2023-08-11  Bruno Haible  <bruno@clisp.org>
10180         clock-time: On mingw, avoid buggy clock_gettime from libwinpthread.
10181         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_CANONICAL_HOST. On
10182         native Windows, avoid using clock_getres clock_gettime clock_settime
10183         from mingw's libwinpthread.
10184         * doc/posix-functions/clock_gettime.texi: Mention the mingw bug.
10186 2023-08-10  Bruno Haible  <bruno@clisp.org>
10188         readutmp: Make the header file includable from C++.
10189         * lib/readutmp.h: Add extern "C" block.
10191 2023-08-10  Bruno Haible  <bruno@clisp.org>
10193         readutmp: Tweak the Android specific addition.
10194         * lib/readutmp.c (read_utmp_from_file) [__ANDROID__]: Don't fake a
10195         BOOT_TIME entry if the options request to omit it or if a BOOT_TIME
10196         entry is already present.
10198 2023-08-10  Bruno Haible  <bruno@clisp.org>
10200         readutmp: Fix the boot time returned on Raspbian.
10201         * lib/readutmp.c (read_utmp_from_file): When the time of the BOOT_TIME
10202         entry is very close to the Epoch, replace it with the time from the
10203         "runlevel"/"~" entry.
10205 2023-08-10  Bruno Haible  <bruno@clisp.org>
10207         boot-time: Add tests.
10208         * tests/test-boot-time.c: New file.
10209         * modules/boot-time-tests: New file.
10211         boot-time: New module.
10212         * lib/boot-time.h: New file.
10213         * lib/boot-time.c: New file.
10214         * modules/boot-time: New file.
10216 2023-08-10  Bruno Haible  <bruno@clisp.org>
10218         readutmp: Return a boot time also on Android.
10219         * lib/readutmp.c (get_linux_uptime): New function, extracted from
10220         get_boot_time_uncached.
10221         (read_utmp_from_file): Don't look for file time stamps on Android.
10222         Instead, use get_linux_uptime.
10223         (get_boot_time_uncached): Use get_linux_uptime.
10225 2023-08-09  Bruno Haible  <bruno@clisp.org>
10227         readutmp: Fix a mistake (regression 2023-08-08).
10228         * lib/readutmp.c (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED): Fix a typo.
10230         readutmp: Return a boot time also on OpenBSD.
10231         * lib/readutmp.h (BOOT_TIME, USER_PROCESS): Provide fallback
10232         definitions.
10233         * lib/readutmp.c (read_utmp_from_file) [__OpenBSD__]: Fake a BOOT_TIME
10234         entry by looking at the time stamp of a specific file.
10236         readutmp: Return a boot time also on Alpine Linux.
10237         * lib/readutmp.c: Include stat-time.h.
10238         (SIZEOF): New macro.
10239         (read_utmp_from_file) [__linux__]: Fake a BOOT_TIME entry by looking
10240         at the time stamp of a specific file.
10241         * modules/readutmp (Depends-on): Add stat-time.
10243         readutmp: Fix boot time in VMs after sleep state and date update.
10244         * lib/readutmp.c (read_utmp_from_file): New function, extracted from
10245         read_utmp.
10246         (get_boot_time_uncached): Before all other approaches, try to find the
10247         boot time in the /var/run/utmp file.
10248         (read_utmp): Invoke read_utmp_from_file.
10250         readutmp: Make it easier to filter for/against the boot-time entry.
10251         * lib/readutmp.h (READ_UTMP_BOOT_TIME, READ_UTMP_NO_BOOT_TIME): New
10252         enum items.
10253         * lib/readutmp.c (desirable_utmp_entry, read_utmp_from_systemd):
10254         Implement them.
10255         (read_utmp): If no entries can match the given options, return
10256         immediately.
10258 2023-08-08  Paul Eggert  <eggert@cs.ucla.edu>
10260         readutmp: omit pragma
10261         * lib/readutmp.c: Omit -Wstringop-overread pragma.
10262         It’s no longer needed now that extract_trimmed_name
10263         no longer calls strnlen.
10265 2023-08-08  Bruno Haible  <bruno@clisp.org>
10267         readutmp: Use classical implementation for files != /var/run/utmp.
10268         * lib/readutmp.c (read_utmp_from_systemd): Renamed from read_utmp
10269         [READUTMP_USE_SYSTEMD]. Remove file argument.
10270         (read_utmp): Call it when the file argument is "/var/run/utmp".
10272 2023-08-08  Bruno Haible  <bruno@clisp.org>
10274         readutmp: Get the boot time with higher precision.
10275         Suggested by Thorsten Kukuk <kukuk@suse.com> in
10276         <https://github.com/thkukuk/utmpx/blob/main/utmp-to-logind.md#determine-boot-time>.
10277         * lib/readutmp.c (get_boot_time_uncached): Try clock_gettime first.
10279 2023-08-08  Bruno Haible  <bruno@clisp.org>
10281         readutmp: Add comment about multithread-safety.
10282         * lib/readutmp.h (read_utmp): Add comment.
10284 2023-08-08  Bruno Haible  <bruno@clisp.org>
10286         readutmp: Return entries with unbounded strings on all platforms.
10287         Suggested  by Paul Eggert in
10288         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00165.html>.
10289         * m4/readutmp.m4 (gl_READUTMP): Test also whether struct utmp has an
10290         ut_tv member, and whether struct utmp and struct utmpx have an
10291         ut_session member.
10292         * lib/readutmp.h (struct gl_utmp): Define always. Add ut_exit field.
10293         (HAVE_GL_UTMP): Remove macro.
10294         (UT_USER, UT_TIME_MEMBER, UT_PID, UT_TYPE_EQ, UT_TYPE_NOT_DEFINED,
10295         UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT, STRUCT_UTMP): Define w.r.t.
10296         struct gl_utmp.
10297         (UT_USER_SIZE, UT_ID_SIZE, UT_LINE_SIZE, UT_HOST_SIZE): Define to -1
10298         always.
10299         (getutent): Remove declaration.
10300         (HAVE_STRUCT_XTMP_UT_EXIT): Remove unused macro.
10301         (HAVE_STRUCT_XTMP_UT_ID, HAVE_STRUCT_XTMP_UT_PID,
10302         HAVE_STRUCT_XTMP_UT_HOST): Change to match the way coreutils uses these
10303         macros.
10304         * lib/readutmp.c (UT_USER, UT_TIME_MEMBER, UT_PID, UT_TYPE_EQ,
10305         UT_TYPE_NOT_DEFINED, IS_USER_PROCESS, UT_EXIT_E_TERMINATION,
10306         UT_EXIT_E_EXIT, UT_USER_SIZE, UT_ID_SIZE, UT_LINE_SIZE, UT_HOST_SIZE):
10307         Define w.r.t. struct utmpx or struct utmp.
10308         (extract_trimmed_name): Don't use UT_USER or UT_USER_SIZE here.
10309         (desirable_utmp_entry): Don't use UT_TIME_MEMBER or UT_USER here.
10310         (struct utmp_alloc): Define always.
10311         (add_utmp): Likewise. Add user_len, id_len, line_len, host_len,
10312         termination, exit arguments. Don't require that user, id, line, host are
10313         NUL-terminated. Assume user and host are non-NULL.
10314         (finish_utmp): New function, extracted from read_utmp.
10315         (read_utmp) [READUTMP_USE_SYSTEMD]: Update add_utmp invocations. Pass a
10316         non-NULL user and a non-NULL host. Call finish_utmp.
10317         (getutent): Move declaration from readutmp.h to here.
10318         (copy_utmp_entry): Remove function.
10319         (read_utmp) [UTMP_NAME_FUNCTION]: Replace variables n_read, n_alloc,
10320         utmp with a 'struct utmp_alloc'. Use 'struct utmpx32' from
10321         copy_utmp_entry here. Invoke add_utmp and finish_utmp.
10322         (read_utmp) [!UTMP_NAME_FUNCTION]: Replace variables n_read, n_alloc,
10323         utmp with a 'struct utmp_alloc'. Invoke add_utmp and finish_utmp.
10324         * NEWS: Mention the API change.
10326 2023-08-08  Bruno Haible  <bruno@clisp.org>
10328         readutmp: Fix compilation error on OpenBSD and AIX (regr. 2023-08-03).
10329         * lib/readutmp.h (UT_TIME_MEMBER) [HAVE_UTMP_H]: Revert last change.
10331 2023-08-08  Bruno Haible  <bruno@clisp.org>
10333         readutmp: Fix compilation error on OpenBSD (regr. 2023-08-02).
10334         * lib/readutmp.h (UT_ID_SIZE): Define to a dummy if there is no ut_id
10335         field.
10337 2023-08-07  Paul Eggert  <eggert@cs.ucla.edu>
10339         quotearg: fix obsolete comment
10340         * lib/quotearg.h: Fix comment to match behavior.
10341         This fixes a commentary bug introduced in
10342         commit 1a43a982c927eaf26bbc2701a872009d9be4b33b
10343         "quotearg: do not use grave accent for left quote"
10344         dated 2011-12-18 15:44:17+01, where the comment
10345         was not updated to match the changed behavior.
10347 2023-08-06  Paul Eggert  <eggert@cs.ucla.edu>
10349         readutmp: fix comment bug ID
10350         * lib/readutmp.c: Fix comment (thanks to Bruno Haible).
10352         doc: Document lack of printf "%n" on Android, OpenBSD.
10353         * doc/posix/functions/*printf.texi: Document that the POSIX-specified
10354         printf functions do not support the %n format on Android and OpenBSD.
10355         This lack of support is deliberate, as %n is a common target of attacks
10356         on security.
10358 2023-08-05  Paul Eggert  <eggert@cs.ucla.edu>
10360         readutmp: anticipate Y2038 hack for utmp
10361         * lib/readutmp.c (struct utmpx32): Use unsigned int for tv_sec,
10362         not int, as that is more likely to work after 2038.
10363         Suggested by Andreas Schwab in:
10364         https://sourceware.org/pipermail/libc-alpha/2023-August/150661.html
10366         diffseq: simplify lint removal
10367         * lib/diffseq.h (IF_LINT): Remove.
10368         Instead, always ignore the diagnostic, as that’s simpler
10369         now that we have the pragma change installed in May.
10370         This removes the last IF_LINT from diffutils, though not
10371         the last use of GCC_LINT.
10373 2023-08-04  Bruno Haible  <bruno@clisp.org>
10375         unistr/{u8-mbtouc,u8-mbsnlen}: Fix test failures (regr. 2023-07-25).
10376         * modules/unistr/u8-mbtouc (configure.ac): Compile this code if the
10377         preinstalled libunistring version is >= 0.9.4, < 1.2.
10378         * modules/unistr/u8-mbsnlen (configure.ac): Likewise.
10380         unistr/*-pcpy: Fix compilation errors (regression 2023-07-21).
10381         * modules/unistr/base (configure.ac): Generate unistr.h if the
10382         preinstalled libunistring version is >= 0.9.11, < 1.2.
10384 2023-08-04  Bruno Haible  <bruno@clisp.org>
10386         readutmp: In systemd mode, fix the ut_host contents (regr. yesterday).
10387         * lib/readutmp.c (add_utmp): Fix ut_host contents.
10388         * tests/test-readutmp.c (main): Show also the contents of the ut_host
10389         field.
10391 2023-08-04  Bruno Haible  <bruno@clisp.org>
10393         readutmp: Ensure multithread-safety.
10394         * lib/readutmp.c (get_boot_time): Initialize 'cached' after 'boot_time',
10395         not before. Also declare both as volatile.
10397 2023-08-04  Bruno Haible  <bruno@clisp.org>
10399         readutmp tests: Fix gcc warning (regression from yesterday).
10400         * tests/test-readutmp.c: Include idx.h.
10401         (main): Use idx_t instead of size_t.
10403 2023-08-03  Paul Eggert  <eggert@cs.ucla.edu>
10405         readutmp: systemd supports only UTMP_FILE
10406         * lib/readutmp.c (read_utmp): Fail if not UTMP_FILE.
10407         * m4/systemd.m4 (gl_SYSTEMD_CHOICE): Default to no for now,
10408         since yes means "who /var/log/wtmp" stops working.
10410         readutmp: switch new struct to struct timespec
10411         * lib/readutmp.c (get_boot_time_uncached, get_boot_time)
10412         (add_utmp, read_utmp):
10413         Use struct timespec, not struct timeval.
10414         * lib/readutmp.h: Always include <time.h>, for struct timespec.
10415         Simplify when utmp.h and utmpx.h are included.
10416         (struct gl_utmp): Use the same struct for both the
10417         systemd and the dummy version.  Reorder members, and
10418         use proper pid_t type for ut_session.  Rename ut_tv to ut_ts
10419         and make it a struct timespec.  All uses changed.
10420         (HAVE_GL_UTMP): New macro.  Use it where appropriate, instead
10421         of READUTMP_USE_SYSTEMD.
10422         (UT_USER, HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID)
10423         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_HOST):
10424         Simplify.
10425         * modules/readutmp (Depends-on): Add time-h, timespec_get.
10426         Remove sys_type.  Sort.
10428         readutmp: fix # indentation
10429         * lib/readutmp.h: Change # indentation to standard Gnulib style.
10431         readutmp: pacify -Wstrict-prototypes
10432         * lib/readutmp.c (get_boot_time_uncached, get_boot_time):
10433         Pacify gcc 13 -Wstrict-prototypes.
10435         readutmp: fix idx_t FIXME in API
10436         * lib/readutmp.c (read_utmp): 2nd arg is now idx_t *, not
10437         size_t *.
10438         * lib/readutmp.h: Include idx.h, for idx_t.
10439         * modules/readutmp (Depends-on): Add idx.
10441         readutmp: go back to simple ‘free’
10442         Omit the new free_utmp function.  Instead, allocate storage
10443         in one block, so that using code can still just call ‘free’.
10444         * lib/readutmp.c (struct utmp_alloc) [READUTMP_USE_SYSTEMD]: New type.
10445         (add_utmp) [READUTMP_USE_SYSTEMD]: New function.
10446         (read_utmp) [READUTMP_USE_SYSTEMD]: Use it.
10447         Also, use malloc a bit less heavily.
10448         (free_utmp): Remove.
10449         * tests/test-readutmp.c (main): Call free, not free_utmp.
10451         readutmp: simplify extract_trimmed_name via ximemdup0
10452         * lib/readutmp.c (extract_trimmed_name): Simplify.
10453         * modules/readutmp (Depends-on):
10454         Add strnlen, which was a missing dependency.
10456 2023-08-03  Bruno Haible  <bruno@clisp.org>
10458         alignasof, stdalign: Avoid some -Wundef warnings from config.h.
10459         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
10460         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00012.html>.
10461         * m4/stdalign.m4 (gl_ALIGNASOF): Test whether __cplusplus is defined
10462         before evaluating it. Assume HAVE_STDALIGN_H, _GL_STDALIGN_NEEDS_STDDEF
10463         are never defined to 0.
10465 2023-08-03  Bruno Haible  <bruno@clisp.org>
10467         doc: More platform detail.
10468         * doc/posix-functions/fnmatch.texi: Mention Solaris OpenIndiana here,
10469         since it behaves differently than Solaris 11.4.
10471 2023-08-03  Bruno Haible  <bruno@clisp.org>
10473         doc: Add references to FreeBSD bugs.
10474         * doc/posix-functions/fnmatch.texi: Add commented reference to FreeBSD
10475         bug.
10476         * doc/posix-functions/wcscmp.texi: Likewise.
10477         * doc/posix-functions/wcsncmp.texi: Likewise.
10479 2023-08-02  Bruno Haible  <bruno@clisp.org>
10481         readutmp: In systemd mode, put the X11 display into the ut_host field.
10482         * lib/readutmp.c (read_utmp): In sessions of type "x11", use the X11
10483         display as host.
10485 2023-08-02  Bruno Haible  <bruno@clisp.org>
10487         readutmp: Small change to reduce the code size on the coreutils side.
10488         * lib/readutmp.h (UT_ID_SIZE): New constant and macro.
10490 2023-08-01  Bruno Haible  <bruno@clisp.org>
10492         readutmp: Small changes to reduce the code size on the coreutils side.
10493         * m4/readutmp.m4 (gl_READUTMP): Test also for the ut_host field in
10494         'struct utmpx' and 'struct utmp'.
10495         * lib/readutmp.h (HAVE_STRUCT_XTMP_UT_HOST): New macro.
10496         (UT_USER_SIZE): Define also as a macro. Set to -1 if
10497         READUTMP_USE_SYSTEMD.
10498         (UT_LINE_SIZE, UT_HOST_SIZE): New constants and macros.
10500 2023-08-01  Bruno Haible  <bruno@clisp.org>
10502         readutmp: For year-2038 safety on Linux/{x86,arm}, use systemd APIs.
10503         Suggested by Thorsten Kukuk <kukuk@suse.com> in
10504         <https://www.thkukuk.de/blog/Y2038_glibc_utmp_64bit/> and
10505         <https://github.com/thkukuk/utmpx/blob/main/utmp-to-logind.md>.
10506         * m4/systemd.m4: New file.
10507         * m4/readutmp.m4 (gl_READUTMP): Require gl_SYSTEMD_CHOICE. Set
10508         READUTMP_LIB. Conditionally define READUTMP_USE_SYSTEMD.
10509         * lib/readutmp.h: For READUTMP_USE_SYSTEMD, include <sys/time.h> and
10510         <utmpx.h>.
10511         (struct gl_utmp): New type.
10512         (UTMP_STRUCT_NAME, UT_TIME_MEMBER, UT_EXIT_E_TERMINATION,
10513         UT_EXIT_E_EXIT, UT_USER, HAVE_STRUCT_XTMP_UT_EXIT,
10514         HAVE_STRUCT_XTMP_UT_ID, HAVE_STRUCT_XTMP_UT_PID): Define differently for
10515         READUTMP_USE_SYSTEMD.
10516         (UT_USER_SIZE): Don't define for READUTMP_USE_SYSTEMD.
10517         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, READ_UTMP_SUPPORTED): Define also for
10518         READUTMP_USE_SYSTEMD.
10519         (free_utmp): New declaration.
10520         * lib/readutmp.c: Add new includes for READUTMP_USE_SYSTEMD.
10521         (extract_trimmed_name): Adapt to READUTMP_USE_SYSTEMD.
10522         (get_boot_time_uncached, get_boot_time, guess_pty_name): New functions.
10523         (read_utmp): New implementation for READUTMP_USE_SYSTEMD.
10524         (free_utmp): New function.
10525         * tests/test-readutmp.c (main): At the end, invoke free_utmp.
10526         * modules/readutmp (Files): Add m4/systemd.m4.
10527         (Link): New section.
10528         * modules/readutmp-tests (Makefile.am): Link test-readutmp with
10529         READUTMP_LIB.
10530         * NEWS: Mention the free_utmp function and the READUTMP_LIB link
10531         requirement.
10533 2023-08-01  Bruno Haible  <bruno@clisp.org>
10535         readutmp: Trivial simplification.
10536         * lib/readutmp.c (extract_trimmed_name): Use constant UT_USER_SIZE.
10538 2023-07-31  Bruno Haible  <bruno@clisp.org>
10540         readutmp tests: Show also the ut_line field.
10541         * tests/test-readutmp.c (main): Add a "Device" column to the table.
10542         Adjust the column widths. Flush stdout before possibly calling abort().
10544 2023-07-31  Bruno Haible  <bruno@clisp.org>
10546         readutmp: Fix test failure on OpenBSD.
10547         * lib/readutmp.c (desirable_utmp_entry): On OpenBSD, eliminate entirely
10548         empty entries.
10550 2023-07-31  Bruno Haible  <bruno@clisp.org>
10552         readutmp: Revisit portability.
10553         * m4/readutmp.m4 (gl_READUTMP): Don't test for struct utmp.ut_exit.ut_*,
10554         since no platform has these.
10555         * lib/readutmp.h (UT_EXIT_E_TERMINATION): Don't test
10556         HAVE_STRUCT_UTMP_UT_EXIT_UT_TERMINATION.
10557         (UT_EXIT_E_EXIT): Don't test HAVE_STRUCT_UTMP_UT_EXIT_UT_EXIT.
10558         * doc/posix-headers/utmpx.texi: Update platforms list. Mention
10559         portability problems of specific 'struct utmpx' fields.
10560         * doc/glibc-headers/utmp.texi: Update platforms list. Mention
10561         portability problems of specific 'struct utmp' fields.
10563 2023-07-31  Bruno Haible  <bruno@clisp.org>
10565         readutmp: Make argument names consistent.
10566         * lib/readutmp.h (UT_TIME_MEMBER, UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT,
10567         UT_USER, UT_PID, UT_TYPE_EQ, UT_TYPE_BOOT_TIME, UT_TYPE_USER_PROCESS,
10568         IS_USER_PROCESS): Rename parameter to 'UT'.
10569         * lib/readutmp.c (desirable_utmp_entry, read_utmp): Rename local
10570         variable 'u' to 'ut'.
10572 2023-07-31  Bruno Haible  <bruno@clisp.org>
10574         readutmp: Make the header file and function usable on all platforms.
10575         * lib/readutmp.h (struct gl_utmp, UTMP_STRUCT_NAME, UT_TIME_MEMBER,
10576         UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT, UT_USER): Provide fallback
10577         definitions.
10578         (READ_UTMP_SUPPORTED): New macro.
10579         * lib/readutmp.c (read_utmp) [!READ_UTMP_SUPPORTED]: Provide a dummy
10580         definition.
10581         * modules/readutmp (Depends-on): Add sys_time.
10582         (configure.ac): Remove conditional.
10583         (Makefile.am): Compile readutmp.c on all platforms.
10584         (Include): Include readutmp.h on all platforms.
10585         * tests/test-readutmp.c: Include readutmp.h on all platforms.
10586         (main): Invoke read_utmp on all platforms.
10588 2023-07-30  Bruno Haible  <bruno@clisp.org>
10590         readutmp: Add tests.
10591         * tests/test-readutmp.c: New file.
10592         * modules/readutmp-tests: New file.
10594         readutmp: Improve comments. Fix module description.
10595         * lib/readutmp.h (extract_trimmed_name): Add specification comment.
10596         (read_utmp): Move specification comment from lib/readutmp.c to here.
10597         Mention also UTMP_FILE and READ_UTMP_USER_PROCESS.
10598         * lib/readutmp.c (extract_trimmed_name): Fix comment.
10599         * modules/readutmp (Include): Only include the .h file if
10600         HAVE_UTMPX_H || HAVE_UTMP_H.
10602 2023-07-29  Paul Eggert  <eggert@cs.ucla.edu>
10604         readutmp: work around glibc utmpx bug
10605         When compiled with _TIME_BITS=64, glibc <utmpx.h> does not work,
10606         because the files use 32-bit time_t and the code passes this to
10607         the user unmodified, but <utmpx.h> defines a struct with 64-bit
10608         time_t.  Work around this compatibility bug.
10609         * lib/readutmp.c (copy_utmp_entry): New function.
10610         (read_utmp): Use it.
10612 2023-07-29  Bruno Haible  <bruno@clisp.org>
10614         wcsrtombs tests: Renumber tests.
10615         * tests/test-wcsrtombs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
10616         * tests/test-wcsrtombs.c: Update.
10617         * modules/wcsrtombs-tests: Update.
10619         wcsnrtombs tests: Renumber tests.
10620         * tests/test-wcsnrtombs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
10621         * tests/test-wcsnrtombs.c: Update.
10622         * modules/wcsnrtombs-tests: Update.
10624         wcrtomb tests: Renumber tests.
10625         * tests/test-wcrtomb.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10626         * tests/test-wcrtomb.c: Update.
10627         * tests/test-wcrtomb-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
10628         -> 8.
10629         * tests/test-wcrtomb-w32.c: Update.
10630         * modules/wcrtomb-tests: Update.
10632         mbstoc32s tests: Renumber tests.
10633         * tests/test-mbstoc32s-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10634         * tests/test-mbstoc32s.c: Update.
10636         mbsrtoc32s tests: Renumber tests.
10637         * tests/test-mbsrtoc32s-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10638         * tests/test-mbsrtoc32s.c: Update.
10640         mbsnrtoc32s tests: Renumber tests.
10641         * tests/test-mbsnrtoc32s-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10642         * tests/test-mbsnrtoc32s.c: Update.
10644         mbstowcs tests: Renumber tests.
10645         * tests/test-mbstowcs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10646         * tests/test-mbstowcs.c: Update.
10647         * modules/mbstowcs-tests: Update.
10649         mbsrtowcs tests: Renumber tests.
10650         * tests/test-mbsrtowcs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10651         * tests/test-mbsrtowcs.c: Update.
10652         * modules/mbsrtowcs-tests: Update.
10654         mbsnrtowcs tests: Renumber tests.
10655         * tests/test-mbsnrtowcs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10656         * tests/test-mbsnrtowcs.c: Update.
10657         * modules/mbsnrtowcs-tests: Update.
10659         mbrtoc16 tests: Renumber tests.
10660         * tests/test-mbrtoc16-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10661         * tests/test-mbrtoc16.c: Update.
10662         * tests/test-mbrtoc16-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
10663         -> 8.
10664         * tests/test-mbrtoc16-w32.c: Update.
10665         * modules/mbrtoc16-tests: Update.
10667         mbrtoc32 tests: Renumber tests.
10668         * tests/test-mbrtoc32-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10669         * tests/test-mbrtoc32.c: Update.
10670         * tests/test-mbrtoc32-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
10671         -> 8.
10672         * tests/test-mbrtoc32-w32.c: Update.
10673         * modules/mbrtoc32-tests: Update.
10675         mbrtowc tests: Renumber tests.
10676         * tests/test-mbrtowc*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10677         * tests/test-mbrtowc.c: Update.
10678         * tests/test-mbrtowc-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
10679         -> 8.
10680         * tests/test-mbrtowc-w32.c: Update.
10681         * modules/mbrtowc-tests: Update.
10683         mbrlen tests: Renumber tests.
10684         * tests/test-mbrlen*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10685         * tests/test-mbrlen.c: Update.
10686         * tests/test-mbrlen-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
10687         -> 8.
10688         * tests/test-mbrlen-w32.c: Update.
10689         * modules/mbrlen-tests: Update.
10691         mbmemcasecoll tests: Renumber tests.
10692         * tests/test-mbmemcasecoll*.sh: Renamed 1 -> 2 -> 3 -> 4.
10693         * tests/test-mbmemcasecoll.c: Update.
10694         * modules/mbmemcasecoll-tests: Update.
10696         mbmemcasecmp tests: Renumber tests.
10697         * tests/test-mbmemcasecmp*.sh: Renamed 1 -> 2 -> 3 -> 4.
10698         * tests/test-mbmemcasecmp.c: Update.
10699         * modules/mbmemcasecmp-tests: Update.
10701         fnmatch tests: Renumber tests.
10702         * tests/test-fnmatch-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
10703         -> 8.
10704         * tests/test-fnmatch-w32.c: Update.
10705         * modules/fnmatch-tests: Update.
10707         c32stombs tests: Renumber tests.
10708         * tests/test-c32stombs-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
10709         * tests/test-c32stombs.c: Update.
10710         * modules/c32stombs-tests: Update.
10712         c32srtombs tests: Renumber tests.
10713         * tests/test-c32srtombs-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
10714         * tests/test-c32srtombs.c: Update.
10715         * modules/c32srtombs-tests: Update.
10717         c32snrtombs tests: Renumber tests.
10718         * tests/test-c32snrtombs-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
10719         * tests/test-c32snrtombs.c: Update.
10720         * modules/c32snrtombs-tests: Update.
10722         c32rtomb tests: Renumber tests.
10723         * tests/test-c32rtomb.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
10724         * tests/test-c32rtomb.c: Update.
10725         * tests/test-c32rtomb-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
10726         -> 8.
10727         * tests/test-c32rtomb-w32.c: Update.
10728         * modules/c32rtomb-tests: Update.
10730         btoc32 tests: Renumber tests.
10731         * tests/test-btoc32-*.sh: Renamed 1 -> 2 -> 3 -> 1.
10732         * tests/test-btoc32.c: Update.
10734         btowc tests: Renumber tests.
10735         * tests/test-btowc*.sh: Renamed 1 -> 2 -> 3 -> 1.
10736         * tests/test-btowc.c: Update.
10737         * modules/btowc-tests: Update.
10739 2023-07-29  Bruno Haible  <bruno@clisp.org>
10741         time-h: Simplify after 2017-05-01 change.
10742         * m4/time_h.m4 (gl_TIME_H_DEFAULTS): Don't provide a default value for
10743         GNULIB_GETTIMEOFDAY.
10745         time-h: Obey GNULIB_POSIXCHECK, not GNULIB_PORTCHECK.
10746         * lib/time.in.h (timespec_get, timespec_getres, time, nanosleep, tzset,
10747         mktime, localtime_r, gmtime_r, localtime, strptime, ctime, strftime,
10748         timegm): Add _GL_WARN_ON_USE invocation.
10749         (asctime, ctime): Don't assume that these functions are declared, since
10750         POSIX obsoletes them.
10751         * m4/time_h.m4 (gl_TIME_H): Test for the declarations of asctime, ctime,
10752         gmtime_r, localtime, localtime_r, mktime, nanosleep, strftime, strptime,
10753         time, timegm, timespec_get, timespec_getres, tzset.
10754         (gl_TIME_H_DEFAULTS): Initialize REPLACE_CTIME, REPLACE_LOCALTIME_R,
10755         REPLACE_MKTIME, REPLACE_NANOSLEEP, REPLACE_STRFTIME, REPLACE_TIMEGM,
10756         REPLACE_TIMESPEC_GET, REPLACE_TZSET with 0 instead of GNULIB_PORTCHECK.
10757         * m4/ctime.m4 (gl_FUNC_CTIME): Don't re-initialize REPLACE_CTIME.
10758         * m4/time_r.m4 (gl_TIME_R): Don't re-initialize REPLACE_LOCALTIME_R.
10759         * m4/mktime.m4 (gl_FUNC_MKTIME): Don't re-initialize REPLACE_MKTIME.
10760         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Don't re-initialize
10761         REPLACE_NANOSLEEP.
10762         * m4/strftime-fixes.m4 (gl_FUNC_STRFTIME): Don't re-initialize
10763         REPLACE_STRFTIME.
10764         * m4/timegm.m4 (gl_FUNC_TIMEGM): Don't re-initialize REPLACE_TIMEGM.
10765         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET): Don't re-initialize
10766         REPLACE_TIMESPEC_GET.
10767         * m4/tzset.m4 (gl_FUNC_TZSET: Don't re-initialize REPLACE_TZSET.
10769 2023-07-28  Bruno Haible  <bruno@clisp.org>
10771         fnmatch: Ensure that on Cygwin ≥ 3.5.0, Cygwin's native fnmatch is used.
10772         Tested by Corinna Vinschen in
10773         <https://cygwin.com/pipermail/cygwin/2023-July/254036.html>.
10774         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): On Cygwin, don't force
10775         REPLACE_FNMATCH to 1 just because wchar_t is small.
10777 2023-07-28  Bruno Haible  <bruno@clisp.org>
10779         posixcheck: Fix dependencies.
10780         * modules/posixcheck (Depends-on): Add malloc-h, pthread-h, sched,
10781         sys_random, threads-h, uchar, utmp.
10783 2023-07-28  Bruno Haible  <bruno@clisp.org>
10785         uchar: Include the necessary snippets.
10786         * lib/uchar.in.h: Add insertion points for _GL_ARG_NONNULL and
10787         _GL_WARN_ON_USE.
10788         * modules/uchar (Depends-on): Add snippet/arg-nonnull,
10789         snippet/warn-on-use.
10790         (Makefile.am): In uchar.h, include the ARG_NONNULL_H and WARN_ON_USE_H
10791         snippets.
10793 2023-07-28  Bruno Haible  <bruno@clisp.org>
10795         mbmemcasecmp, mbmemcasecoll: Avoid test failure on MSVC.
10796         * tests/test-mbmemcasecmp.h (test_utf_8): Disable two tests on platforms
10797         that don't have the upper/lower mappings for 'ü'/'Ü'.
10798         * tests/test-mbmemcasecmp.c: Include <wchar.h>, <wctype.h>.
10799         * tests/test-mbmemcasecoll.c: Likewise.
10800         * modules/mbmemcasecmp-tests (Depends-on): Add mbrtowc, wctype-h.
10801         * modules/mbmemcasecoll-tests (Depends-on): Likewise.
10803 2023-07-27  Bruno Haible  <bruno@clisp.org>
10805         gnulib-tool: Include ftruncate in testdirs.
10806         * gnulib-tool (func_create_testdir): Don't exclude module 'ftruncate'
10807         from testdirs by default.
10808         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
10810 2023-07-27  Bruno Haible  <bruno@clisp.org>
10812         fnmatch-h, glob-h tests: Fix link errors (regression 2023-07-24).
10813         * modules/fnmatch-h-c++-tests (Makefile.am): Link test-fnmatch-h-c++
10814         with $(LIBUNISTRING).
10815         * modules/glob-h-c++-tests (Makefile.am): Link test-glob-h-c++ with
10816         $(LIBUNISTRING).
10818         fnmatch, glob tests: Fix link errors (regression 2023-07-24).
10819         * modules/fnmatch-tests (Makefile.am): Link test-fnmatch-w32 with the
10820         same libraries as test-fnmatch.
10821         * modules/glob (Link): Add $(LIBUNISTRING).
10822         * modules/glob-tests (Makefile.am): Link test-glob with $(LIBUNISTRING).
10824 2023-07-26  Bruno Haible  <bruno@clisp.org>
10826         wctrans: Work around bug on NetBSD.
10827         * lib/wctype.in.h (rpl_wctrans_t, wctrans_t, GNULIB_defined_wctrans_t):
10828         Define if REPLACE_WCTRANS is 1.
10829         (wctrans): Consider REPLACE_WCTRANS.
10830         (towctrans): Override if REPLACE_WCTRANS is 1.
10831         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize REPLACE_WCTRANS.
10832         * m4/wctrans.m4 (gl_FUNC_WCTRANS): Define through AC_DEFUN_ONCE. Test
10833         whether wctrans supports the "tolower" character mapping. Set
10834         REPLACE_WCTRANS if not.
10835         * m4/towctrans.m4 (gl_FUNC_TOWCTRANS): Require gl_FUNC_WCTRANS.
10836         * modules/wctrans (Depends-on): Add towctrans.
10837         (configure.ac): Consider REPLACE_WCTRANS.
10838         * modules/towctrans (Files): Add m4/wctrans.m4.
10839         (configure.ac): Override also if REPLACE_WCTRANS is 1.
10840         * modules/wctype-h (Makefile.am): Substitute REPLACE_WCTRANS.
10841         * doc/posix-functions/wctrans.texi: Mention the NetBSD bug.
10843 2023-07-26  Bruno Haible  <bruno@clisp.org>
10845         towctrans: Add tests.
10846         * tests/test-towctrans.c: New file, based on
10847         tests/test-c32_apply_mapping.c.
10848         * modules/towctrans-tests: New file.
10850         wctrans: Add tests.
10851         * tests/test-wctrans.c: New file, based on tests/test-c32_get_mapping.c.
10852         * modules/wctrans-tests: New file.
10854 2023-07-26  Bruno Haible  <bruno@clisp.org>
10856         fnmatch: Update dependencies.
10857         * modules/fnmatch (Depends-on): Add wctype.
10859 2023-07-26  Bruno Haible  <bruno@clisp.org>
10861         wctype: Work around wctype+iswctype bug on MSVC.
10862         * m4/wctype.m4 (gl_FUNC_WCTYPE): In the test program, test also for the
10863         MSVC bug. Update cross-compilation guess.
10864         * doc/posix-functions/wctype.texi: Mention the MSVC bug.
10866 2023-07-26  Bruno Haible  <bruno@clisp.org>
10868         wctype: Work around wctype bug on mingw.
10869         * lib/wctype.in.h (rpl_wctype_t, wctype_t, GNULIB_defined_wctype_t):
10870         Define if REPLACE_WCTYPE is 1.
10871         (wctype): Consider REPLACE_WCTYPE.
10872         (iswctype): Override also if REPLACE_WCTYPE is 1.
10873         * lib/iswctype.c: If GNULIB_defined_wctype_t is defined, use the
10874         function-pointer based implementation.
10875         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize REPLACE_WCTYPE.
10876         * m4/wctype.m4 (gl_FUNC_WCTYPE): Define through AC_DEFUN_ONCE. Test
10877         whether wctype supports the "blank" character class. Set REPLACE_WCTYPE
10878         if not.
10879         * m4/iswctype.m4 (gl_FUNC_ISWCTYPE): Require gl_FUNC_WCTYPE.
10880         * modules/wctype (Status, Notice): Remove.
10881         (Depends-on): Add iswctype. Consider REPLACE_WCTYPE.
10882         (configure.ac): Consider REPLACE_WCTYPE.
10883         * modules/iswctype (Status, Notice): Remove.
10884         (Files): Add m4/wctype.m4.
10885         (configure.ac): Override also if REPLACE_WCTYPE is 1.
10886         * modules/wctype-h (Makefile.am): Substitute REPLACE_WCTYPE.
10887         * doc/posix-functions/wctype.texi: Mention the mingw bug.
10889 2023-07-26  Bruno Haible  <bruno@clisp.org>
10891         wctype-h: Work around iswprint bug on mingw.
10892         * lib/wctype.in.h (rpl_iswprint): On mingw, don't use the system's
10893         iswprint function.
10894         * tests/test-wctype-h.c (main): Verify that this character class
10895         contains the ASCII space but not tab and newline.
10896         * tests/test-c32isprint.c (main): For tab, \v, \f, expect the same value
10897         on native Windows as on other platforms.
10898         * doc/posix-functions/iswprint.texi: Mention the mingw bug.
10900 2023-07-26  Bruno Haible  <bruno@clisp.org>
10902         iswblank tests: Add more tests.
10903         * tests/test-iswblank.c (main): Verify that this character class
10904         contains the ASCII space and tab, but not newline.
10906 2023-07-26  Bruno Haible  <bruno@clisp.org>
10908         wctype, wctrans: Require a non-NULL argument.
10909         * lib/wctype.in.h: Add placeholder for definition of _GL_ARG_NONNULL.
10910         (wctype, wctrans): Mark with _GL_ARG_NONNULL ((1)).
10911         * modules/wctype-h (Depends-on): Add snippet/arg-nonnull.
10912         (Makefile.am): Substitute $(ARG_NONNULL_H) into wctype.h.
10914 2023-07-25  Bruno Haible  <bruno@clisp.org>
10916         iswctype: Add tests.
10917         * tests/test-iswctype.c: New file, based on
10918         tests/test-c32_apply_type_test.c.
10919         * tests/test-c32_apply_type_test.c (main): Update accordingly.
10920         * modules/iswctype-tests: New file.
10922         wctype: Add tests.
10923         * tests/test-wctype.c: New file, based on
10924         tests/test-c32_get_type_test.c.
10925         * modules/wctype-tests: New file.
10927 2023-07-25  Bruno Haible  <bruno@clisp.org>
10929         Compile benchmark programs without assertions.
10930         * modules/mbiter-bench-tests (Makefile.am): Compile bench-mbiter with
10931         -DNDEBUG.
10932         * modules/mbiterf-bench-tests (Makefile.am): Compile bench-mbiterf with
10933         -DNDEBUG.
10934         * modules/mbuiter-bench-tests (Makefile.am): Compile bench-mbuiter with
10935         -DNDEBUG.
10936         * modules/mbuiterf-bench-tests (Makefile.am): Compile bench-mbuiterf
10937         with -DNDEBUG.
10938         * modules/mbswidth-bench-tests (Makefile.am): Compile bench-mbswidth
10939         with -DNDEBUG.
10940         * modules/crypto/md5-buffer-tests (Makefile.am): Compile bench-md5 with
10941         -DNDEBUG.
10942         * modules/crypto/sha1-buffer-tests (Makefile.am): Compile bench-sha1
10943         with -DNDEBUG.
10944         * modules/crypto/sha256-buffer-tests (Makefile.am): Compile bench-sha224
10945         and bench-sha256 with -DNDEBUG.
10946         * modules/crypto/sha512-buffer-tests (Makefile.am): Compile bench-sha384
10947         and bench-sha512 with -DNDEBUG.
10949 2023-07-25  Bruno Haible  <bruno@clisp.org>
10951         unistr/u8-*: Make Unicode decoder more Unicode Standard compliant.
10952         Based on a remark by Paul Eggert in
10953         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00120.html>.
10954         * tests/unistr/test-u8-mbtouc.c (test_safe_function): Change expected
10955         results for "non-shortest form" or out-of-range byte sequences. Add new
10956         test cases of incomplete well-formed byte sequences.
10957         * tests/unistr/test-u8-mbsnlen.c (main): Likewise.
10958         * lib/unistr/u8-mbtouc-aux.c (u8_mbtouc_aux): Reject a first byte in the
10959         range 0xF5..0xF7 as invalid. Distinguish incomplete from invalid byte
10960         sequences correctly. For the former, return only the number of bytes in
10961         the maximal well-formed subpart.
10962         * lib/unistr/u8-mbtouc.c (u8_mbtouc): Likewise.
10963         * lib/unistr/u8-check.c (u8_check): Reject a first byte in the range
10964         0xF5..0xF7 as invalid.
10965         * lib/unistr/u8-mblen.c (u8_mblen): Likewise.
10966         * lib/unistr/u8-mbtoucr.c (u8_mbtoucr): Likewise.
10967         * lib/unistr/u8-strmbtouc.c (u8_strmbtouc): Likewise.
10968         * lib/unistr/u8-strmblen.c (u8_strmblen): Likewise.
10969         * lib/unistr/u8-prev.c (u8_prev): Likewise.
10971 2023-07-24  Bruno Haible  <bruno@clisp.org>
10973         fnmatch: Overcome wchar_t limitations.
10974         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Set REPLACE_FNMATCH to 1 on
10975         AIX in 32-bit mode.
10976         * lib/fnmatch.c: Include <uchar.h>. Conditionally include unistr.h.
10977         (UCHAR_TO_WCHAR): Renamed from BTOWC.
10978         (WCHAR_T, WINT_T, BTOWC, MBSRTOWCS, WCSLEN, WCSCAT, WMEMPCPY, WMEMCHR,
10979         TOWLOWER, WCTYPE_T, WCTYPE, ISWCTYPE): New macros.
10980         (IS_CHAR_CLASS): Use WCTYPE instead of wctype.
10981         (UCHAR_TO_WCHAR): Use BTOWC instead of btowc.
10982         (FOLD): Use TOWLOWER instead of towlower.
10983         (CHAR): Use WCHAR_T instead of wchar_t.
10984         (UCHAR, INT): Use WINT_T instead of wint_t.
10985         (STRLEN): Use WCSLEN instead of wcslen.
10986         (STRCAT): Use WCSCAT instead of wcscat.
10987         (MEMPCPY): Use WMEMPCPY instead of wmempcpy.
10988         (MEMCHR): Use WMEMCHR instead of wmemchr.
10989         (is_char_class): Use WCTYPE_T instead of wctype_t, WCHAR_T instead of
10990         wchar_t, WCTYPE instead of wctype.
10991         (fnmatch): Use WCHAR_T instead of wchar_t, MBSRTOWCS instead of
10992         mbsrtowcs.
10993         * lib/fnmatch_loop.c (FCT): Use WCTYPE_T instead of wctype_t, ISWCTYPE
10994         instead of iswctype. Update for renamed BTOWC.
10995         * modules/fnmatch (Depends-on): Add btoc32, c32tolower,
10996         c32_get_type_test, c32_apply_type_test, mbsrtoc32s, unistr/u32-chr,
10997         unistr/u32-pcpy, unistr/u32-strcat, unistr/u32-strlen.
10998         (Link): Add $(LIBUNISTRING).
10999         * modules/fnmatch-tests (Makefile.am): Link test-fnmatch with
11000         $(LIBUNISTRING).
11001         * doc/posix-functions/fnmatch.texi: Move the Cygwin, mingw, MSVC, AIX
11002         bug descriptions to the "fixed by Gnulib" section.
11004 2023-07-24  Bruno Haible  <bruno@clisp.org>
11006         fnmatch: Update doc regarding Solaris 10.
11007         * doc/posix-functions/fnmatch.texi: Move the Solaris 10 bug description
11008         to the "fixed by Gnulib" section.
11010 2023-07-23  Paul Eggert  <eggert@cs.ucla.edu>
11012         timespec_get: port to Ubuntu 23.04
11013         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET):
11014         Default REPLACE_TIMESPEC_GET to 0, fixing a typo.
11016 2023-07-23  Bruno Haible  <bruno@clisp.org>
11018         unistr/u32-strcat: Relicense under LGPLv2+.
11019         * modules/unistr/u32-strcat (License): Change to LGPLv2+.
11020         * lib/unistr/u32-strcat.c: Update license notice.
11021         * lib/unistr/u-strcat.h: Likewise.
11023 2023-07-23  Bruno Haible  <bruno@clisp.org>
11025         unistr/u32-strlen: Relicense under LGPLv2+.
11026         * modules/unistr/u32-strlen (License): Change to LGPLv2+.
11027         * lib/unistr/u32-strlen.c: Update license notice.
11029 2023-07-23  Bruno Haible  <bruno@clisp.org>
11031         unistr/u32-chr: Relicense under LGPLv2+.
11032         * modules/unistr/u32-chr (License): Change to LGPLv2+.
11033         * lib/unistr/u32-chr.c: Update license notice.
11035 2023-07-23  Paul Eggert  <eggert@cs.ucla.edu>
11037         utimecmp: clean up old spare1 cruft
11038         * lib/utimecmp.c: Remove a ‘defined HAVE_STRUCT_STAT_ST_SPARE1’
11039         that has been false since 2007.
11041 2023-07-23  Bruno Haible  <bruno@clisp.org>
11043         fnmatch tests: Avoid a test failure on FreeBSD.
11044         * tests/test-fnmatch.c (main): In a GB18030 locale, test the towupper()
11045         mapping of 'ö', not of 'ü'.
11047 2023-07-23  Bruno Haible  <bruno@clisp.org>
11049         fnmatch: Work around bugs on FreeBSD, NetBSD, Solaris, Cygwin, Android.
11050         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Add three more test cases to
11051         the test program. Reorganize its return values.
11052         * tests/test-fnmatch.c (main): Reflect the changes done in fnmatch.m4.
11053         * doc/posix-functions/fnmatch.texi: Move the corresponding bug
11054         descriptions to the "fixed by Gnulib" section.
11056 2023-07-23  Bruno Haible  <bruno@clisp.org>
11058         fnmatch, fnmatch-gnu: Document known bugs.
11059         * doc/posix-headers/fnmatch.texi: Mention the macros FNM_LEADING_DIR,
11060         FNM_CASEFOLD, FNM_EXTMATCH, FNM_FILE_NAME.
11061         * doc/posix-functions/fnmatch.texi: Reference the glibc documentation
11062         and the Linux man page. Document the effects of the two modules and all
11063         the known bugs in detail.
11065 2023-07-22  Bruno Haible  <bruno@clisp.org>
11067         fnmatch tests: Add many more test cases.
11068         * lib/fnmatch.in.h (GNULIB_defined_fnmatch_function): New macro.
11069         * tests/test-fnmatch.c: Add many more test cases.
11070         * tests/test-fnmatch-1.sh: New file, based on tests/test-mbrtoc32-5.sh.
11071         * tests/test-fnmatch-2.sh: New file, based on tests/test-mbrtoc32-1.sh.
11072         * tests/test-fnmatch-3.sh: New file, based on tests/test-mbrtoc32-2.sh.
11073         * tests/test-fnmatch-4.sh: New file, based on tests/test-mbrtoc32-3.sh.
11074         * tests/test-fnmatch-5.sh: New file, based on tests/test-mbrtoc32-4.sh.
11075         * tests/test-fnmatch-w32.c: New file, based on tests/test-mbrtoc32-w32.c
11076         and tests/test-fnmatch.c.
11077         * tests/test-fnmatch-w32-1.sh: New file, based on
11078         tests/test-mbrtoc32-w32-1.sh.
11079         * tests/test-fnmatch-w32-2.sh: New file, based on
11080         tests/test-mbrtoc32-w32-2.sh.
11081         * tests/test-fnmatch-w32-3.sh: New file, based on
11082         tests/test-mbrtoc32-w32-3.sh.
11083         * tests/test-fnmatch-w32-4.sh: New file, based on
11084         tests/test-mbrtoc32-w32-4.sh.
11085         * tests/test-fnmatch-w32-5.sh: New file, based on
11086         tests/test-mbrtoc32-w32-5.sh.
11087         * tests/test-fnmatch-w32-6.sh: New file, based on
11088         tests/test-mbrtoc32-w32-6.sh.
11089         * tests/test-fnmatch-w32-7.sh: New file, based on
11090         tests/test-mbrtoc32-w32-7.sh.
11091         * modules/fnmatch-tests: Add the new program and shell scripts.
11093 2023-07-22  Bruno Haible  <bruno@clisp.org>
11095         doc: Mention a wctype bug.
11096         * doc/posix-functions/wctype.texi: Mention a bug on mingw.
11098 2023-07-21  Bruno Haible  <bruno@clisp.org>
11100         unistr/u8-pcpy, unistr/u16-pcpy, unistr/u32-pcpy: Add tests.
11101         * tests/unistr/test-pcpy.h: New file, based on tests/unistr/test-cpy.h.
11102         * tests/unistr/test-u8-pcpy.c: New file, based on
11103         tests/unistr/test-u8-cpy.c.
11104         * tests/unistr/test-u16-pcpy.c: New file, based on
11105         tests/unistr/test-u16-cpy.c.
11106         * tests/unistr/test-u32-pcpy.c: New file, based on
11107         tests/unistr/test-u32-cpy.c.
11108         * modules/unistr/u8-pcpy-tests: New file, based on
11109         modules/unistr/u8-cpy-tests.
11110         * modules/unistr/u16-pcpy-tests: New file, based on
11111         modules/unistr/u16-cpy-tests.
11112         * modules/unistr/u32-pcpy-tests: New file, based on
11113         modules/unistr/u32-cpy-tests.
11115         unistr/u8-pcpy, unistr/u16-pcpy, unistr/u32-pcpy: New modules.
11116         * lib/unistr.in.h (u8_pcpy, u16_pcpy, u32_pcpy): New declarations.
11117         * lib/unistr/u-pcpy.h: New file, based on lib/wmempcpy.c.
11118         * lib/unistr/u8-pcpy.c: New file, based on lib/unistr/u8-cpy.c.
11119         * lib/unistr/u16-pcpy.c: New file, based on lib/unistr/u16-cpy.c.
11120         * lib/unistr/u32-pcpy.c: New file, based on lib/unistr/u32-cpy.c.
11121         * modules/unistr/u8-pcpy: New file, based on modules/unistr/u8-cpy.
11122         * modules/unistr/u16-pcpy: New file, based on modules/unistr/u16-cpy.
11123         * modules/unistr/u32-pcpy: New file, based on modules/unistr/u32-cpy.
11125 2023-07-20  Bruno Haible  <bruno@clisp.org>
11127         error-h: Fix dependencies.
11128         Reported by <cbh34680@gmail.com> in
11129         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00111.html>.
11130         * modules/error-h (Depends-on): Add include_next.
11132 2023-07-20  Pádraig Brady  <P@draigBrady.com>
11134         fts: fix compilation errors with fts_cross_check()
11135         * lib/fts.c: Fix printf format chars.
11136         * lib/fts_.h: Provide a declaration for users.
11138 2023-07-19  Bruno Haible  <bruno@clisp.org>
11140         Document migration path for obsolescent functions.
11141         * doc/glibc-functions/timespec_get.texi: Add reference to ISO C.
11142         * doc/posix-functions/_tolower.texi: Recommend use of tolower.
11143         * doc/posix-functions/_toupper.texi: Recommend use of toupper.
11144         * doc/posix-functions/asctime.texi: Recommend use of strftime.
11145         * doc/posix-functions/asctime_r.texi: Likewise.
11146         * doc/posix-functions/ctime.texi: Recommend use of localtime_r and
11147         strftime.
11148         * doc/posix-functions/ctime_r.texi: Likewise.
11149         * doc/posix-functions/ftw.texi: Recommend use of fts.
11150         * doc/posix-functions/getitimer.texi: Recommend use of timer_gettime.
11151         * doc/posix-functions/gets.texi: Recommend use of fgets.
11152         * doc/posix-functions/gettimeofday.texi: Recommend use of gettime or
11153         timespec_get.
11154         * doc/posix-functions/inet_addr.texi: Recommend use of inet_pton.
11155         * doc/posix-functions/inet_ntoa.texi: Recommend use of inet_ntop.
11156         * doc/posix-functions/pthread_getconcurrency.texi: Recommend no-op.
11157         * doc/posix-functions/pthread_setconcurrency.texi: Recommend no-op.
11158         * doc/posix-functions/rand_r.texi: Recommend use of random_r.
11159         * doc/posix-functions/setitimer.texi: Recommend use of timer_create and
11160         timer_settime.
11161         * doc/posix-functions/setpgrp.texi: Recommend use of setpgid or setsid.
11162         * doc/posix-functions/sighold.texi: Recommend use of sigprocmask.
11163         * doc/posix-functions/sigignore.texi: Recommend use of sigaction.
11164         * doc/posix-functions/siginterrupt.texi: Recommend use of sigaction.
11165         * doc/posix-functions/sigpause.texi: Recommend use of sigsuspend.
11166         * doc/posix-functions/sigrelse.texi: Recommend use of sigprocmask.
11167         * doc/posix-functions/sigset.texi: Recommend use of sigaction.
11168         * doc/posix-functions/tempnam.texi: Recommend use of mkstemp.
11169         * doc/posix-functions/ulimit.texi: Recommend use of getrlimit and
11170         setrlimit.
11171         * doc/posix-functions/utime.texi: Recommend use of utimens.
11173 2023-07-19  Paul Eggert  <eggert@cs.ucla.edu>
11175         Document POSIX obsolescence
11176         * doc/posix-functions/_longjmp.texi, doc/posix-functions/_setjmp.texi:
11177         * doc/posix-functions/_tolower.texi, doc/posix-functions/_toupper.texi:
11178         * doc/posix-functions/asctime.texi, doc/posix-functions/asctime_r.texi:
11179         * doc/posix-functions/ctime.texi, doc/posix-functions/ctime_r.texi:
11180         * doc/posix-functions/encrypt.texi, doc/posix-functions/ftw.texi:
11181         * doc/posix-functions/getitimer.texi, doc/posix-functions/gets.texi:
11182         * doc/posix-functions/gettimeofday.texi:
11183         * doc/posix-functions/inet_addr.texi:
11184         * doc/posix-functions/inet_ntoa.texi, doc/posix-functions/isascii.texi:
11185         * doc/posix-functions/pthread_getconcurrency.texi:
11186         * doc/posix-functions/pthread_setconcurrency.texi:
11187         * doc/posix-functions/rand_r.texi, doc/posix-functions/setitimer.texi:
11188         * doc/posix-functions/setkey.texi, doc/posix-functions/setpgrp.texi:
11189         * doc/posix-functions/sighold.texi, doc/posix-functions/sigignore.texi:
11190         * doc/posix-functions/siginterrupt.texi:
11191         * doc/posix-functions/sigpause.texi, doc/posix-functions/sigrelse.texi:
11192         * doc/posix-functions/sigset.texi, doc/posix-functions/tempnam.texi:
11193         * doc/posix-functions/toascii.texi, doc/posix-functions/ulimit.texi:
11194         * doc/posix-functions/utime.texi:
11195         Update as per draft 3 of POSIX 10003.1-202x.
11197 2023-07-19  Paul Eggert  <eggert@cs.ucla.edu>
11199         Don’t worry about Version 7 tolower
11200         Some code ported back to pre-C89 libraries where tolower (C) had
11201         undefined behavior if C is not an upper case character.
11202         Nowadays that function is _tolower which is itself obsolete,
11203         and much Gnulib code already assumes this part of C89 anyway.
11204         Assume C89 or better tolower, which simplifies the code
11205         and should improve performance slightly.
11206         * lib/mbmemcasecmp.c, lib/mbmemcasecoll.c, lib/mbscasecmp.c:
11207         * lib/mbscasestr.c, lib/mbsncasecmp.c, lib/mbspcasecmp.c:
11208         * lib/strcasecmp.c, lib/strcasestr.c, lib/strncasecmp.c:
11209         (TOLOWER): Remove.  All uses replaced by tolower.
11211 2023-07-19  Bruno Haible  <bruno@clisp.org>
11213         c32swidth, mbszero: Fix file list.
11214         * modules/c32swidth (Files): Add locale-ja.m4, locale-zh.m4, codeset.m4.
11215         * modules/mbszero (Files): Likewise.
11217 2023-07-19  Bruno Haible  <bruno@clisp.org>
11219         wcsnrtombs: Fix file list.
11220         * modules/wcsnrtombs (Files): Add locale-fr.m4.
11222 2023-07-19  Bruno Haible  <bruno@clisp.org>
11224         mbsnrtowcs: Fix file list.
11225         * modules/mbsnrtowcs (Files): Add locale-fr.m4, codeset.m4.
11227 2023-07-19  Bruno Haible  <bruno@clisp.org>
11229         mbrtoc16: Fix file list.
11230         * modules/mbrtoc16 (Files): Add locale-zh.m4.
11232 2023-07-19  Bruno Haible  <bruno@clisp.org>
11234         mbrlen: Fix file list.
11235         * modules/mbrlen (Files): Add locale-fr.m4, locale-ja.m4, locale-zh.m4,
11236         codeset.m4.
11238 2023-07-18  Paul Eggert  <eggert@cs.ucla.edu>
11240         mbiterf, mbuiterf: port to strict C17
11241         I ran into this problem on NetBSD 9.3.
11242         * lib/mbiterf.h (mbiterf_next) [!GNULIB_MBRTOC32_REGULAR]:
11243         * lib/mbuiterf.h (mbuiterf_next) [!GNULIB_MBRTOC32_REGULAR]:
11244         Don’t label a declaration.
11246 2023-07-18  Bruno Haible  <bruno@clisp.org>
11248         mbiter, mbiterf, mbuiter, mbuiterf: Force inlining with clang.
11249         * lib/mbiter.h (MBITER_INLINE): Use _GL_ATTRIBUTE_ALWAYS_INLINE.
11250         * lib/mbiterf.h (MBITERF_INLINE): Likewise.
11251         * lib/mbuiter.h (MBUITER_INLINE): Likewise.
11252         * lib/mbuiterf.h (MBUITERF_INLINE): Likewise.
11254 2023-07-18  Bruno Haible  <bruno@clisp.org>
11256         mbsspn: Optimize.
11257         * lib/mbsspn.c: Include mbuiterf.h instead of mbuiter.h.
11258         (mbsspn): Use mbuif_* macros instead of mbui_* macros.
11259         * modules/mbsspn (Depends-on): Add mbuiterf. Remove mbuiter.
11261         mbscspn: Optimize.
11262         * lib/mbscspn.c: Include mbuiterf.h instead of mbuiter.h.
11263         (mbscspn): Use mbuif_* macros instead of mbui_* macros.
11264         * modules/mbscspn (Depends-on): Add mbuiterf. Remove mbuiter.
11266         mbspbrk: Optimize.
11267         * lib/mbspbrk.c: Include mbuiterf.h instead of mbuiter.h.
11268         (mbspbrk): Use mbuif_* macros instead of mbui_* macros.
11269         * modules/mbspbrk (Depends-on): Add mbuiterf. Remove mbuiter.
11271         mbspcasecmp: Optimize.
11272         * lib/mbspcasecmp.c: Include mbuiterf.h instead of mbuiter.h.
11273         (mbspcasecmp): Use mbuif_* macros instead of mbui_* macros.
11274         * modules/mbspcasecmp (Depends-on): Add mbuiterf. Remove mbuiter.
11276         mbsncasecmp: Optimize.
11277         * lib/mbsncasecmp.c: Include mbuiterf.h instead of mbuiter.h.
11278         (mbsncasecmp): Use mbuif_* macros instead of mbui_* macros.
11279         * modules/mbsncasecmp (Depends-on): Add mbuiterf. Remove mbuiter.
11281         mbscasecmp: Optimize.
11282         * lib/mbscasecmp.c: Include mbuiterf.h instead of mbuiter.h.
11283         (mbscasecmp): Use mbuif_* macros instead of mbui_* macros.
11284         * modules/mbscasecmp (Depends-on): Add mbuiterf. Remove mbuiter.
11286         mbssep: Optimize.
11287         * lib/mbssep.c: Include mbuiterf.h instead of mbuiter.h.
11288         (mbssep): Use mbuif_* macros instead of mbui_* macros.
11289         * modules/mbssep (Depends-on): Add mbuiterf. Remove mbuiter.
11291         mbsrchr: Optimize.
11292         * lib/mbsrchr.c: Include mbuiterf.h instead of mbuiter.h.
11293         (mbsrchr): Use mbuif_* macros instead of mbui_* macros.
11294         * modules/mbsrchr (Depends-on): Add mbuiterf. Remove mbuiter.
11296         mbschr: Optimize.
11297         * lib/mbschr.c: Include mbuiterf.h instead of mbuiter.h.
11298         (mbschr): Use mbuif_* macros instead of mbui_* macros.
11299         * modules/mbschr (Depends-on): Add mbuiterf. Remove mbuiter.
11301         mbslen: Optimize.
11302         * lib/mbslen.c: Include mbuiterf.h instead of mbuiter.h.
11303         (mbslen): Use mbuif_* macros instead of mbui_* macros.
11304         * modules/mbslen (Depends-on): Add mbuiterf. Remove mbuiter.
11306         mbuiterf: Add a benchmark.
11307         * tests/bench-mbuiterf.c: New file, based on tests/bench-mbuiter.c.
11308         * modules/mbuiterf-bench-tests: New file, based on
11309         modules/mbuiter-bench-tests.
11311         mbuiterf: New module.
11312         * lib/mbuiterf.h: New file, based on lib/mbuiter.h.
11313         * lib/mbuiterf.c: New file, based on lib/mbuiter.c.
11314         * modules/mbuiterf: New file, based on modules/mbuiter.
11316 2023-07-18  Bruno Haible  <bruno@clisp.org>
11318         mbiterf: Fix compiler warnings.
11319         * lib/mbiterf.h (mbiterf_next): Use C99 designated initializer syntax.
11320         * tests/bench-mbiterf.c (do_test): Use a 'const char *' pointer.
11322         trim: Optimize.
11323         * lib/trim.c: Include mbiterf.h instead of mbiter.h.
11324         (trim2): Use mbif_* macros instead of mbi_* macros.
11325         * modules/trim (Depends-on): Add mbiterf. Remove mbiter.
11327         mbmemcasecmp: Optimize.
11328         * lib/mbmemcasecmp.c: Include mbiterf.h instead of mbiter.h.
11329         (mbmemcasecmp): Use mbif_* macros instead of mbi_* macros.
11330         * modules/mbmemcasecmp (Depends-on): Add mbiterf. Remove mbiter.
11332         mbsnlen: Optimize.
11333         * lib/mbsnlen.c: Include mbiterf.h instead of mbiter.h.
11334         (mbsnlen): Use mbif_* macros instead of mbi_* macros.
11335         * modules/mbsnlen (Depends-on): Add mbiterf. Remove mbiter.
11337         mbiterf: Add a benchmark.
11338         * tests/bench-mbiterf.c: New file, based on tests/bench-mbiter.c.
11339         * modules/mbiterf-bench-tests: New file, based on
11340         modules/mbiter-bench-tests.
11342         mbiterf: New module.
11343         * lib/mbiterf.h: New file, based on lib/mbiter.h.
11344         * lib/mbiterf.c: New file, based on lib/mbiter.c.
11345         * modules/mbiterf: New file, based on modules/mbiter.
11347 2023-07-18  Bruno Haible  <bruno@clisp.org>
11349         mbstok_r: Simplify dependencies.
11350         * lib/mbstok_r.c: Include <stdlib.h> instead of mbuiter.h.
11351         * modules/mbstok_r (Depends-on): Remove mbuiter.
11353 2023-07-17  Simon Josefsson  <simon@josefsson.org>
11355         announce-gen: Allow using local git user.name.
11356         * build-aux/announce-gen (readable_interval): Remove --global
11357         parameter to 'git config' call.
11359 2023-07-17  Bruno Haible  <bruno@clisp.org>
11361         mbuiter: Optimize.
11362         * lib/mbuiter.h (struct mbuiter_multi): Add cur_max field.
11363         (mbui_init): Initialize it.
11364         (mbuiter_multi_next): Use it instead of MB_CUR_MAX.
11365         (mbuiter_multi_copy): Update.
11367 2023-07-17  Bruno Haible  <bruno@clisp.org>
11369         mbchar: Reduce size of 'struct mbchar'.
11370         * modules/mbfile (configure.ac): Define GNULIB_MBFILE as an indicator.
11371         * lib/mbchar.h (MBCHAR_BUF_SIZE): Set to 4.
11372         (struct mbchar): Disable member 'buf' if the module 'mbfile' is not in
11373         use.
11374         (mb_setascii): Disable if the module 'mbfile' is not in use.
11375         (mb_copy): Update.
11377 2023-07-17  Bruno Haible  <bruno@clisp.org>
11379         mbszero: Fix for Minix.
11380         * lib/wchar.in.h: (_GL_MBSTATE_INIT_SIZE): Don't define on Minix.
11381         (_GL_MBSTATE_ZERO_SIZE): Define to 4 on Minix.
11383 2023-07-17  Bruno Haible  <bruno@clisp.org>
11385         mbszero: Source code tweaks.
11386         Suggested by Paul Eggert in
11387         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00084.html>.
11388         * lib/wchar.in.h: Comment changes.
11389         (_GL_MBSTATE_INIT_SIZE): Don't define on NetBSD, Solaris, native
11390         Windows. Use a safe default at the end.
11391         (_GL_MBSTATE_ZERO_SIZE): Don't define on AIX, IRIX, Solaris, native
11392         Windows. Use a safe default at the end.
11393         * lib/mbrtoc16.c: Update comments accordingly.
11395 2023-07-16  Bruno Haible  <bruno@clisp.org>
11397         dfa: Optimize clearing an mbstate_t.
11398         * lib/dfa.c (mbszero) [GAWK]: Add fallback definition.
11399         (mbs_to_wchar, lex, addtok_wc, dfaexec_main): Use mbszero.
11400         * modules/dfa (Depends-on): Add mbszero.
11402 2023-07-16  Bruno Haible  <bruno@clisp.org>
11404         uchar-c23: Optimize clearing an mbstate_t.
11405         * lib/lc-charset-unicode.c (locale_encoding_to_unicode,
11406         unicode_to_locale_encoding): Use mbszero.
11407         * modules/uchar-c23 (Depends-on): Add mbszero.
11409 2023-07-16  Bruno Haible  <bruno@clisp.org>
11411         quotearg: Optimize clearing an mbstate_t.
11412         * lib/quotearg.c: Include <wchar.h>.
11413         (quotearg_buffer_restyled): Use mbszero.
11414         * modules/quotearg (Depends-on): Add mbszero.
11416 2023-07-16  Bruno Haible  <bruno@clisp.org>
11418         vasnprintf, vasnwprintf: Optimize clearing an mbstate_t.
11419         * lib/vasnprintf.c (VASNPRINTF): Use mbszero.
11420         * modules/vasnprintf (Depends-on): Add mbszero.
11421         * modules/vasnwprintf (Depends-on): Likewise.
11422         * modules/c-vasnprintf (Depends-on): Likewise.
11423         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
11424         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
11425         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
11426         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
11427         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
11428         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
11429         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
11431 2023-07-16  Bruno Haible  <bruno@clisp.org>
11433         mbmemcasecoll: Optimize clearing an mbstate_t.
11434         * lib/mbmemcasecoll.c (apply_c32tolower): Use mbszero.
11435         * modules/mbmemcasecoll (Depends-on): Add mbszero.
11437 2023-07-16  Bruno Haible  <bruno@clisp.org>
11439         mbswidth: Optimize clearing an mbstate_t.
11440         * lib/mbswidth.c (mbsnwidth): Use mbszero.
11441         * modules/mbswidth (Depends-on): Add mbszero.
11443 2023-07-16  Bruno Haible  <bruno@clisp.org>
11445         mbfile: Optimize clearing an mbstate_t.
11446         * lib/mbfile.h (mbfile_multi_getc, mbf_init): Use mbszero.
11447         * modules/mbfile (Depends-on): Add mbszero.
11449 2023-07-16  Bruno Haible  <bruno@clisp.org>
11451         mbuiter: Optimize clearing an mbstate_t.
11452         * lib/mbuiter.h: Include <wchar.h>.
11453         (mbuiter_multi_next, mbuiter_multi_copy, mbui_init): Use mbszero.
11454         * modules/mbuiter (Depends-on): Add mbszero.
11456 2023-07-16  Bruno Haible  <bruno@clisp.org>
11458         mbiter: Optimize clearing an mbstate_t.
11459         * lib/mbiter.h: Include <wchar.h>.
11460         (mbiter_multi_next, mbiter_multi_copy, mbi_init): Use mbszero.
11461         * modules/mbiter (Depends-on): Add mbszero.
11463 2023-07-16  Bruno Haible  <bruno@clisp.org>
11465         c32stombs: Optimize clearing an mbstate_t.
11466         * lib/c32stombs.c (c32stombs): Use mbszero.
11467         * lib/uchar.in.h (c32stombs): Likewise.
11468         * modules/c32stombs (Depends-on): Add mbszero.
11470 2023-07-16  Bruno Haible  <bruno@clisp.org>
11472         mbstoc32s: Optimize clearing an mbstate_t.
11473         * lib/mbstoc32s.c (mbstoc32s): Use mbszero.
11474         * lib/uchar.in.h (mbstoc32s): Likewise.
11475         * modules/mbstoc32s (Depends-on): Add mbszero.
11477 2023-07-16  Bruno Haible  <bruno@clisp.org>
11479         mbstowcs: Optimize clearing an mbstate_t.
11480         * lib/mbstowcs.c (mbstowcs): Use mbszero.
11481         * modules/mbstowcs (Depends-on): Add mbszero.
11483 2023-07-16  Bruno Haible  <bruno@clisp.org>
11485         c32tob: Optimize clearing an mbstate_t.
11486         * lib/c32tob.c (c32tob): Use mbszero.
11487         * modules/c32tob (Depends-on): Add mbszero.
11489 2023-07-16  Bruno Haible  <bruno@clisp.org>
11491         wctomb: Optimize clearing an mbstate_t.
11492         * lib/wctomb-impl.h (wctomb): Use mbszero.
11493         * modules/wctomb (Depends-on): Add mbszero.
11495 2023-07-16  Bruno Haible  <bruno@clisp.org>
11497         btoc32: Optimize clearing an mbstate_t.
11498         * lib/btoc32.c: Include <wchar.h>.
11499         (btoc32): Use mbszero.
11500         * modules/btoc32 (Depends-on): Add mbszero.
11502 2023-07-16  Bruno Haible  <bruno@clisp.org>
11504         btowc: Optimize clearing an mbstate_t.
11505         * lib/btowc.c (btowc): Use mbszero.
11506         * modules/btowc (Depends-on): Add mbszero.
11508 2023-07-16  Bruno Haible  <bruno@clisp.org>
11510         mbrtoc32: Optimize clearing an mbstate_t.
11511         * lib/mbrtoc32.c (mbrtoc32): Use mbszero.
11512         * modules/mbrtoc32 (Depends-on): Add mbsinit, mbszero.
11514 2023-07-16  Bruno Haible  <bruno@clisp.org>
11516         mbtowc: Optimize clearing an mbstate_t.
11517         * lib/mbtowc-impl.h (mbtowc): Use mbszero.
11518         * modules/mbtowc (Depends-on): Add mbszero.
11520 2023-07-16  Bruno Haible  <bruno@clisp.org>
11522         mbszero: New module.
11523         * lib/wchar.in.h: Include <string.h>.
11524         (_GL_MBSTATE_INIT_SIZE, _GL_MBSTATE_ZERO_SIZE): New macros.
11525         (mbszero): New declaration.
11526         * lib/mbrtoc16.c: Update comments.
11527         * lib/mbszero.c: New file.
11528         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Initialize
11529         GNULIB_MBSZERO.
11530         * modules/wchar (Depends-on): Add extern-inline.
11531         (Makefile.am): Substitute GNULIB_MBSZERO.
11532         * modules/mbszero: New file.
11534 2023-07-15  Bruno Haible  <bruno@clisp.org>
11536         mbsinit: Fix module description.
11537         * modules/mbsinit (Files): Add m4/mbrtowc.m4.
11539 2023-07-15  Bruno Haible  <bruno@clisp.org>
11541         c32_apply_type_test: Fix compilation error with GCC < 9.
11542         * lib/uchar.in.h (c32_apply_type_test) [_GL_WCHAR_T_IS_UCS4]: Remove
11543         _GL_ARG_NONNULL attribute.
11545 2023-07-13  Bruno Haible  <bruno@clisp.org>
11547         mbchar: Optimize is_basic.
11548         * lib/mbchar.h (is_basic_table): Remove declaration.
11549         (is_basic) [IS_BASIC_ASCII]: Define through a simple range test.
11550         * lib/mbchar.c (is_basic_table): Remove array.
11552         localcharset: Clean up locale encodings used by glibc.
11553         * lib/localcharset.h: Remove VISCII from the list, since never supported
11554         in glibc/localedata/SUPPORTED. JOHAB is not supported by glibc any more
11555         since 2000-09-25. TCVN5712-1 is not supported by glibc any more since
11556         2012-05-21.
11558 2023-07-13  Bruno Haible  <bruno@clisp.org>
11560         doc: Mention c32_get_mapping, c32_apply_mapping.
11561         * doc/posix-functions/wctrans.texi: Mention c32_get_mapping.
11562         * doc/posix-functions/towctrans.texi: Mention c32_apply_mapping.
11563         * doc/strings.texi (Comparison of character APIs): Mention both.
11565         c32_apply_mapping: Add tests.
11566         * tests/test-c32_apply_mapping.c: New file.
11567         * modules/c32_apply_mapping-tests: New file.
11569         c32_apply_mapping: New module.
11570         * lib/uchar.in.h (c32_apply_mapping): New declaration.
11571         * lib/c32_apply_mapping.c: New file.
11572         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
11573         GNULIB_C32_APPLY_MAPPING.
11574         * modules/uchar (Makefile.am): Substitute GNULIB_C32_APPLY_MAPPING.
11575         * modules/c32_apply_mapping: New file.
11577         c32_get_mapping: Add tests.
11578         * tests/test-c32_get_mapping.c: New file.
11579         * modules/c32_get_mapping-tests: New file.
11581         c32_get_mapping: New module.
11582         * lib/uchar.in.h (c32_mapping_t): New type.
11583         (c32_get_mapping): New declaration.
11584         * lib/c32_get_mapping.c: New file, based on lib/wctrans-impl.h.
11585         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
11586         GNULIB_C32_GET_MAPPING.
11587         * modules/uchar (Makefile.am): Substitute GNULIB_C32_GET_MAPPING.
11588         * modules/c32_get_mapping: New file.
11590         towctrans: Relax license.
11591         * modules/towctrans (License): Change to LGPLv2+.
11592         * lib/towctrans.c: Update license notice.
11593         * lib/towctrans-impl.h: Likewise.
11595         wctrans: Relax license.
11596         * modules/wctrans (License): Change to LGPLv2+.
11597         * lib/wctrans.c: Update license notice.
11598         * lib/wctrans-impl.h: Likewise.
11600 2023-07-12  Bruno Haible  <bruno@clisp.org>
11602         doc: Mention c32_get_type_test, c32_apply_type_test.
11603         * doc/posix-functions/wctype.texi: Mention c32_get_type_test.
11604         * doc/posix-functions/iswctype.texi: Mention c32_apply_type_test.
11605         * doc/strings.texi (Comparison of character APIs): Mention both.
11607         c32_apply_type_test: Add tests.
11608         * tests/test-c32_apply_type_test.c: New file.
11609         * modules/c32_apply_type_test-tests: New file.
11611         c32_apply_type_test: New module.
11612         * lib/uchar.in.h (c32_apply_type_test): New declaration.
11613         * lib/c32_apply_type_test.c: New file.
11614         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
11615         GNULIB_C32_APPLY_TYPE_TEST.
11616         * modules/uchar (Makefile.am): Substitute GNULIB_C32_APPLY_TYPE_TEST.
11617         * modules/c32_apply_type_test: New file.
11619         c32_get_type_test: Add tests.
11620         * tests/test-c32_get_type_test.c: New file.
11621         * modules/c32_get_type_test-tests: New file.
11623         c32_get_type_test: New module.
11624         * lib/uchar.in.h (c32_type_test_t): New type.
11625         (c32_get_type_test): New declaration.
11626         * lib/c32_get_type_test.c: New file, based on lib/wctype-impl.h.
11627         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
11628         GNULIB_C32_GET_TYPE_TEST.
11629         * modules/uchar (Makefile.am): Substitute GNULIB_C32_GET_TYPE_TEST.
11630         * modules/c32_get_type_test: New file.
11632         iswctype: Relax license.
11633         * modules/iswctype (License): Change to LGPLv2+.
11634         * lib/iswctype.c: Update license notice.
11635         * lib/iswctype-impl.h: Likewise.
11637         wctype: Relax license.
11638         * modules/wctype (License): Change to LGPLv2+.
11639         * lib/wctype.c: Update license notice.
11640         * lib/wctype-impl.h: Likewise.
11642 2023-07-12  Bruno Haible  <bruno@clisp.org>
11644         mbiter, mbuiter: Small optimization.
11645         * lib/mbiter.h: Optimize away the in_shift field when the module
11646         'mbrtoc32-regular' is in use.
11647         * lib/mbuiter.h: Likewise.
11649 2023-07-12  Gavin Smith  <gavinsmith0123@gmail.com>
11651         gendocs: support chapter- and section-level split
11652         * doc/gendocs_template: Add lines to mark parts of file to output
11653         only when splitting HTML by node.
11654         Remove obsolete comment about ranges of years in copyright notice
11655         (as per Karl).
11656         * build-aux/gendocs.sh
11657         [!texi2html]: Strip out parts of the template depending on --split.
11658         [texi2html] Include all of the template as before.
11660 2023-07-11  Bruno Haible  <bruno@clisp.org>
11662         mbsrtoc32s, mbsnrtoc32s: Small optimization.
11663         * lib/mbsrtoc32s.c (USES_C32): Set to 0 when the module
11664         'mbrtoc32-regular' is in use.
11665         * lib/mbsnrtoc32s.c (USES_C32): Likewise.
11667 2023-07-11  Bruno Haible  <bruno@clisp.org>
11669         mbswidth: Add a benchmark.
11670         * tests/bench-mbswidth.c: New file, based on tests/bench-mbiter.c.
11671         * modules/mbswidth-bench-tests: New file.
11673         mbuiter: Add a benchmark.
11674         * tests/bench-mbuiter.c: New file, based on tests/bench-mbiter.c.
11675         * modules/mbuiter-bench-tests: New file.
11677         mbiter: Add a benchmark.
11678         * tests/bench-mbiter.c: New file.
11679         * tests/bench-multibyte.h: New file.
11680         * modules/mbiter-bench-tests: New file.
11682         tests: Create new file bench.h.
11683         * tests/bench.h: New file, extracted from tests/bench-digest.h.
11684         * tests/bench-digest.h: Include it.
11685         * modules/crypto/md5-buffer-tests (Files): Add tests/bench.h.
11686         * modules/crypto/sha1-buffer-tests (Files): Likewise.
11687         * modules/crypto/sha256-buffer-tests (Files): Likewise.
11688         * modules/crypto/sha512-buffer-tests (Files): Likewise.
11690 2023-07-11  Bruno Haible  <bruno@clisp.org>
11692         Optimize away some mbsinit calls.
11693         * lib/mbiter.h (mbiter_multi_next): When the module 'mbrtoc32-regular'
11694         is in use, don't invoke mbsinit and don't compare the mbrtoc32 result
11695         against (size_t)(-3).
11696         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
11697         * lib/mbfile.h (mbfile_multi_getc): Likewise.
11698         * lib/mbswidth.c (mbsnwidth): Likewise.
11699         * lib/mbmemcasecoll.c (apply_c32tolower): Likewise.
11700         * lib/quotearg.c (quotearg_buffer_restyled): Likewise.
11702 2023-07-11  Bruno Haible  <bruno@clisp.org>
11704         Fix build errors on Linux/hppa.
11705         * modules/math (Makefile.am): Split long pipe command into several
11706         smaller commands.
11707         * modules/pthread-h (Makefile.am): Likewise.
11708         * modules/stdio (Makefile.am): Likewise.
11709         * modules/stdlib (Makefile.am): Likewise.
11710         * modules/string (Makefile.am): Likewise.
11711         * modules/unictype/base (Makefile.am): Likewise.
11712         * modules/unistd (Makefile.am): Likewise.
11713         * modules/wchar (Makefile.am): Likewise.
11715 2023-07-11  Paul Eggert  <eggert@cs.ucla.edu>
11717         quotearg: update Solaris-related comments
11718         * doc/solaris-versions: Modernize.
11719         * lib/quotearg.c: Update comments.
11721 2023-07-10  Bruno Haible  <bruno@clisp.org>
11723         dfa: Overcome wchar_t limitations.
11724         * lib/localeinfo.h: Include <uchar.h>. Add special definitions for GAWK.
11725         (case_folded_counterparts): Change array element type to char32_t.
11726         * lib/localeinfo.c: Include <uchar.h>. Add special definitions for GAWK.
11727         (is_using_utf8, init_localeinfo): Use mbrtoc32 instead of mbrtowc.
11728         (lonesome_lower): Change element type to 'unsigned short'.
11729         (case_folded_counterparts): Change array element type to char32_t. Use
11730         c32toupper instead of towupper. Use c32tolower instead of towlower.
11731         * lib/dfa.c: Include <uchar.h>. Add special definitions for GAWK.
11732         (struct mb_char_classes): Change element type of 'chars' to char32_t.
11733         (mbs_to_wchar): Use mbrtoc32 instead of mbrtowc.
11734         (setbit_wc): Change type of first argument to char32_t. Use c32tob
11735         instead of wctob.
11736         (parse_bracket_exp): Update.
11737         (lex): Use c32isprint instead of iswprint. Use c32isspace instead of
11738         iswspace. Use c32rtomb instead of a %lc directive.
11739         (addtok_wc): Use c32rtomb instead of wcrtomb.
11740         (atom): Update.
11741         * modules/dfa (Depends-on): Remove wctype-h. Add uchar,
11742         mbrtoc32-regular, c32rtomb, c32tob, c32tolower, c32toupper, c32isprint,
11743         c32isspace.
11744         (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11745         * modules/dfa-tests (Makefile.am): Link test-dfa-match-aux with
11746         $(LIBUNISTRING) $(LIBC32CONV).
11747         * NEWS: Mention the change.
11749 2023-07-10  Bruno Haible  <bruno@clisp.org>
11751         mbrtoc32-regular: Add tests.
11752         * tests/test-mbrtoc32-regular.c: New file.
11753         * modules/mbrtoc32-regular-tests: New file.
11755         mbrtoc32-regular: New module.
11756         * modules/mbrtoc32-regular: New file.
11757         * lib/mbrtoc32.c (mbrtoc32): If the module 'mbrtoc32-regular' is present
11758         and the system's mbrtoc32 returned a char32_t, clear the mbstate_t.
11759         * doc/posix-functions/mbrtoc32.texi: Mention the new module.
11761 2023-07-10  Bruno Haible  <bruno@clisp.org>
11763         Apply the last change to all locale-*.m4 files.
11764         * m4/locale-ar.m4 (gt_LOCALE_AR): Reject locale name that might cause
11765         trouble with sh or make.
11766         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
11768 2023-07-09  Paul Eggert  <eggert@cs.ucla.edu>
11770         c32width: protect against bad configure args
11771         Avoid ‘test’ misuse with ‘./configure gt_cv_locale_fr=""’.
11772         Possible problem of this sort reported by Angelo Graziosi in:
11773         https://lists.gnu.org/r/emacs-devel/2023-07/msg00329.html
11774         * m4/locale-fr.m4 (gt_LOCALE_FR_UTF8, gt_LOCALE_FR_UTF8):
11775         * m4/locale-ja.m4 (gt_LOCALE_JA):
11776         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN):
11777         Reject locale names that might cause trouble with sh or make.
11779 2023-07-06  Bruno Haible  <bruno@clisp.org>
11781         wcscmp: Work around a glibc bug.
11782         Reported by مصعب الزعبي (Mosab Al-Zoubi) <moceap@hotmail.com> in
11783         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00029.html>.
11784         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Test against a glibc/arm* bug.
11785         * doc/posix-functions/wcscmp.texi: Mention the glibc/arm* bug.
11787 2023-07-04  Bruno Haible  <bruno@clisp.org>
11789         mbiter, mbfile, mbmemcasecoll: Improve handling of mbrtoc32 result.
11790         * lib/mbiter.h (mbi_avail): If cur.ptr has reached the limit but
11791         in_shift is true, call mbiter_multi_next.
11792         (mbiter_multi_next): Set in_shift to false after an incomplete multibyte
11793         character.
11794         * lib/mbfile.h (mbfile_multi_getc): Pass the input bytes incrementally
11795         into mbrtoc32. When mbf->state is not in the initial state, call
11796         mbrtoc32 again.
11797         * lib/mbmemcasecoll.c (apply_c32tolower): When the state is not in the
11798         initial state, call mbrtoc32 again.
11800 2023-07-04  Bruno Haible  <bruno@clisp.org>
11802         mbiter, mbuiter, mbfile: Improve state handling after invalid input.
11803         * lib/mbiter.h (mbiter_multi_next): After an invalid multibyte sequence
11804         was encountered, clear the state.
11805         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
11806         * lib/mbfile.h (mbfile_multi_getc): Likewise.
11808 2023-07-04  Bruno Haible  <bruno@clisp.org>
11810         mbchar: Optimize all chars from the POSIX "portable character set".
11811         * lib/mbchar.h (is_basic): Include all the characters from the POSIX
11812         "portable character set".
11813         * lib/mbchar.c (is_basic_table): Likewise.
11814         * lib/mbiter.h (mbiter_multi_next): Update comment.
11815         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
11816         * lib/mbfile.h (mbfile_multi_getc): Likewise.
11818 2023-07-04  Paul Eggert  <eggert@cs.ucla.edu>
11820         mbchar: treat @, $, ` as basic
11821         The C standard says that @, $, ` must have a single-byte
11822         representation so they count as basic as far as multibyte
11823         character processing goes.
11824         * lib/mbchar.c (is_basic_table):
11825         * lib/mbchar.h (is_basic):
11826         * lib/mbswidth.c (mbsnwidth):
11827         Treat @, $, ` as basic too.
11829 2023-07-03  Bruno Haible  <bruno@clisp.org>
11831         mbrtoc32: Document another glibc bug.
11832         * doc/posix-functions/mbrtoc32.texi: Reference the glibc bug in
11833         BIG5-HKSCS locales.
11835 2023-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11837         mbrtoc32: document (size_t) -3 issue
11838         * doc/posix-functions/mbrtoc32.texi (mbrtoc32):
11839         Say (size_t) -3 might not be worth bothering about.
11841 2023-07-02  Bruno Haible  <bruno@clisp.org>
11843         mbsrtoc32s: Accommodate a difference between mbrtowc and mbrtoc32.
11844         * lib/mbsrtoc32s.c (USES_C32): New macro.
11845         * lib/mbsrtowcs.c (USES_C32): New macro.
11846         * lib/mbsrtowcs-impl.h (FUNC): If USES_C32 and mbrtoc32 returned
11847         (size_t)(-3), don't increment the pointer.
11849 2023-07-02  Bruno Haible  <bruno@clisp.org>
11851         mbsnrtoc32s: Accommodate a difference between mbrtowc and mbrtoc32.
11852         * lib/mbsnrtoc32s.c (USES_C32): New macro.
11853         * lib/mbsnrtowcs.c (USES_C32): New macro.
11854         * lib/mbsnrtowcs-impl.h (FUNC): If USES_C32 and mbrtoc32 returned
11855         (size_t)(-3), don't increment the pointer.
11857 2023-07-02  Bruno Haible  <bruno@clisp.org>
11859         mbmemcasecoll: Overcome wchar_t limitations.
11860         * lib/mbmemcasecoll.c: Include <uchar.h> instead of <wctype.h>.
11861         (apply_c32tolower): Renamed from apply_towlower. Use mbrtoc32 instead of
11862         mbrtowc. Use c32tolower instead of towlower. Use c32rtomb instead of
11863         wcrtomb.
11864         * modules/mbmemcasecoll (Depends-on): Remove mbrtowc, wcrtomb. Add
11865         uchar, mbrtoc32, c32rtomb, c32tolower.
11866         (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11867         * modules/mbmemcasecoll-tests (Makefile.am): Link test-mbmemcasecoll
11868         with $(LIBUNISTRING) $(LIBC32CONV).
11870 2023-07-02  Bruno Haible  <bruno@clisp.org>
11872         mbswidth: Overcome wchar_t limitations.
11873         * lib/mbswidth.c: Include <uchar.h> instead of <wctype.h>.
11874         (mbsnwidth): Use mbrtoc32 instead of mbrtowc. Use c32width instead of
11875         wcwidth. Use c32iscntrl instead of iswcntrl.
11876         * modules/mbswidth (Depends-on): Remove wctype-h, mbrtowc, wcwidth. Add
11877         uchar, mbrtoc32, c32width, c32iscntrl.
11878         (Link): Add $(LIBC32CONV).
11880 2023-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11882         Fix long bootstrap lines
11883         * top/bootstrap:
11884         * top/bootstrap-funclib.sh: Reformat to fit into 80 columns,
11885         for coreutils ‘make syntax-check’.
11887 2023-07-01  Bruno Haible  <bruno@clisp.org>
11889         doc: Update regarding stable branches.
11890         * doc/gnulib-readme.texi (Stable Branches): Mention new branch
11891         stable-202307. Mention that stable-202207 is no longer updated.
11893 2023-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11895         maint.mk: Modernize stddef.h checks for C23
11896         * top/maint.mk (_stddef_syms_re): Modernize for C23.
11898 2023-07-01  Bruno Haible  <bruno@clisp.org>
11900         quotearg: Overcome wchar_t limitations.
11901         * lib/quotearg.c: Include <uchar.h> instead of <wchar.h>, <wctype.h>.
11902         (quotearg_buffer_restyled): Use mbrtoc32, c32isprint instead of mbrtowc,
11903         iswprint.
11904         * modules/quotearg (Files): Remove m4/mbstate_t.m4, m4/mbrtowc.m4
11905         (redundant).
11906         (Depends-on): Add uchar, mbrtoc32, c32isprint. Remove wchar, wctype-h,
11907         mbrtowc.
11908         (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11909         * modules/quotearg-tests (Makefile.am): Link test-quotearg with
11910         $(LIBUNISTRING) $(LIBC32CONV).
11911         * modules/quotearg-simple (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11912         * modules/quotearg-simple-tests (Makefile.am): Link test-quotearg-simple
11913         with $(LIBUNISTRING) $(LIBC32CONV).
11914         --
11915         * modules/quote (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11916         --
11917         * modules/acl (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11918         * modules/acl-tests (Makefile.am): Link test-set-mode-acl and
11919         test-copy-acl with $(LIBUNISTRING) $(LIBC32CONV).
11920         * modules/copy-file (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11921         * modules/copy-file-tests (Makefile.am): Link test-copy-file with
11922         $(LIBUNISTRING) $(LIBC32CONV).
11923         --
11924         * modules/argmatch (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11925         * modules/argmatch-tests (Makefile.am): Link test-argmatch with
11926         $(LIBUNISTRING) $(LIBC32CONV).
11927         * modules/backup-rename (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11928         * modules/backupfile (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11929         * modules/human (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11930         --
11931         * modules/sh-quote (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11932         * modules/sh-quote-tests (Makefile.am): Link test-sh-quote with
11933         $(LIBUNISTRING) $(LIBC32CONV).
11934         * modules/system-quote (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11935         * modules/system-quote-tests (Makefile.am): Link test-system-quote-main
11936         with $(LIBUNISTRING) $(LIBC32CONV).
11937         * modules/csharpcomp (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11938         * modules/csharpexec (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11939         * modules/javacomp (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11940         * modules/javaexec (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11941         --
11942         * modules/string-desc-quotearg (Link): New section.
11943         * modules/string-desc-quotearg-tests (Makefile.am): Link
11944         test-string-desc-quotearg with $(LIBUNISTRING) $(LIBC32CONV).
11945         --
11946         * modules/xmemcoll (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11947         --
11948         * modules/closeout (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11949         * modules/readtokens-tests (Makefile.am): Link test-readtokens with
11950         $(LIBUNISTRING) $(LIBC32CONV).
11951         --
11952         * modules/closein (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
11953         * modules/closein-tests (Makefile.am): Link test-closein with
11954         $(LIBUNISTRING) $(LIBC32CONV).
11955         * modules/yesno-tests (Makefile.am): Link test-yesno with
11956         $(LIBUNISTRING) $(LIBC32CONV).
11958 2023-06-30  Bruno Haible  <bruno@clisp.org>
11960         Accommodate a difference between mbrtowc and mbrtoc32.
11961         * lib/mbiter.h (mbiter_multi_next): Handle the mbrtoc32 return value
11962         (size_t)(-3).
11963         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
11964         * lib/mbfile.h (mbfile_multi_getc): Likewise.
11966 2023-06-30  Bruno Haible  <bruno@clisp.org>
11968         doc: Reference some reported bugs (in comments).
11969         * doc/posix-functions/mbrlen.texi: Add references to bug reports.
11970         * doc/posix-functions/mbrtoc16.texi: Likewise.
11971         * doc/posix-functions/mbrtoc32.texi: Likewise.
11972         * doc/posix-functions/mbrtowc.texi: Likewise.
11973         * doc/posix-functions/mbsnrtowcs.texi: Likewise.
11974         * doc/posix-functions/mbsrtowcs.texi: Likewise.
11975         * doc/posix-functions/mbstowcs.texi: Likewise.
11977 2023-06-29  Paul Eggert  <eggert@cs.ucla.edu>
11979         assert-tests: pacify gcc -Wunused-function
11980         * tests/test-assert.c (main): Call f, so that the test
11981         works even if NDEBUG is defined.
11983         stddef-tests: pacify gcc -Wshadow
11984         * tests/test-stddef.c (mat): Rename from ‘x’.
11986         nullptr-tests: pacify gcc -Wmissing-declarations
11987         * tests/test-nullptr.c (varargs_callee): Now static.
11989 2023-06-29  Bruno Haible  <bruno@clisp.org>
11991         libtextstyle-optional: Update to gettext 0.22.
11992         * lib/textstyle.in.h: Declare all functions that were added in
11993         textstyle.h from gettext-0.22.
11995         libtextstyle-optional: Update to gettext 0.21.
11996         * lib/textstyle.in.h: Declare all functions that exist in textstyle.h
11997         from gettext-0.21, independently of iconv.
11999 2023-06-28  Bruno Haible  <bruno@clisp.org>
12001         doc: Mention c8rtomb and mbrtoc8 from ISO C 23.
12002         * doc/posix-functions/c8rtomb.texi: New file.
12003         * doc/posix-functions/mbrtoc8.texi: New file.
12004         * doc/gnulib.texi (Function Substitutes): Include them.
12006 2023-06-28  Bruno Haible  <bruno@clisp.org>
12008         mbrtoc16: Add tests.
12009         * tests/test-mbrtoc16.c: New file, based on tests/test-mbrtoc32.c.
12010         * tests/test-mbrtoc16-1.sh: New file, based on tests/test-mbrtoc32-1.sh.
12011         * tests/test-mbrtoc16-2.sh: New file, based on tests/test-mbrtoc32-2.sh.
12012         * tests/test-mbrtoc16-3.sh: New file, based on tests/test-mbrtoc32-3.sh.
12013         * tests/test-mbrtoc16-4.sh: New file, based on tests/test-mbrtoc32-4.sh.
12014         * tests/test-mbrtoc16-5.sh: New file, based on tests/test-mbrtoc32-5.sh.
12015         * tests/test-mbrtoc16-w32.c: New file, based on
12016         tests/test-mbrtoc32-w32.c.
12017         * tests/test-mbrtoc16-w32-1.sh: New file, based on
12018         tests/test-mbrtoc32-w32-1.sh.
12019         * tests/test-mbrtoc16-w32-2.sh: New file, based on
12020         tests/test-mbrtoc32-w32-2.sh.
12021         * tests/test-mbrtoc16-w32-3.sh: New file, based on
12022         tests/test-mbrtoc32-w32-3.sh.
12023         * tests/test-mbrtoc16-w32-4.sh: New file, based on
12024         tests/test-mbrtoc32-w32-4.sh.
12025         * tests/test-mbrtoc16-w32-5.sh: New file, based on
12026         tests/test-mbrtoc32-w32-5.sh.
12027         * tests/test-mbrtoc16-w32-6.sh: New file, based on
12028         tests/test-mbrtoc32-w32-6.sh.
12029         * tests/test-mbrtoc16-w32-7.sh: New file, based on
12030         tests/test-mbrtoc32-w32-7.sh.
12031         * modules/mbrtoc16-tests: New file, based on modules/mbrtoc32-tests.
12033         mbrtoc16: New module.
12034         * lib/uchar.in.h (mbrtoc16): New declaration.
12035         * lib/mbrtoc16.c: New file.
12036         * m4/mbrtoc16.m4: New file, based on m4/mbrtoc32.m4.
12037         * modules/mbrtoc16: New file.
12038         * m4/uchar_h.m4 (gl_UCHAR_H): Test whether mbrtoc16 is declared.
12039         (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize GNULIB_MBRTOC16.
12040         (gl_UCHAR_H_DEFAULTS): Initialize HAVE_MBRTOC16, REPLACE_MBRTOC16.
12041         * modules/uchar (Makefile.am): Substitute GNULIB_MBRTOC16,
12042         HAVE_MBRTOC16, REPLACE_MBRTOC16.
12043         * doc/posix-functions/mbrtoc16.texi: Mention the mbrtoc16 module and the
12044         mbsinit related limitation.
12045         * doc/posix-functions/mbsinit.texi: Mention the mbrtoc16 related
12046         limitation.
12048 2023-06-28  Bruno Haible  <bruno@clisp.org>
12050         c32*: Update comment.
12051         * lib/c32is-impl.h (FUNC): Add comment regarding Android.
12052         * lib/c32to-impl.h (FUNC): Likewise.
12053         * lib/c32width.c (c32width): Likewise.
12055 2023-06-28  Bruno Haible  <bruno@clisp.org>
12057         mbrtoc32: Doc tweak.
12058         * doc/posix-functions/mbrtoc32.texi: Mention that mingw and Android have
12059         the empty input bug.
12060         * m4/mbrtoc32.m4 (gl_MBRTOC32_EMPTY_INPUT): Update cross-compilation
12061         guess.
12063 2023-06-28  Bruno Haible  <bruno@clisp.org>
12065         mbrtowc: Doc tweak.
12066         * doc/posix-functions/mbrtowc.texi: Mention that MSVC has the empty
12067         input bug and the return value bug. Mention that Android has the empty
12068         input bug.
12069         * m4/mbrtowc.m4 (gl_MBRTOC32_EMPTY_INPUT): Update cross-compilation
12070         guess.
12072 2023-06-28  Bruno Haible  <bruno@clisp.org>
12074         mbrtowc, mbrtoc32: Simplify autoconf macros.
12075         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT, gl_MBRTOWC_C_LOCALE): Put
12076         cross-compilation guess at the usual place.
12077         * m4/mbrtoc32.m4 (gl_MBRTOC32_EMPTY_INPUT, gl_MBRTOC32_C_LOCALE):
12078         Likewise.
12080 2023-06-27  Bruno Haible  <bruno@clisp.org>
12082         c32*: Optionally enforce ISO C 23 semantics of char32_t.
12083         * lib/lc-charset-unicode.h: New file.
12084         * lib/lc-charset-unicode.c: New file.
12085         * modules/uchar-c23: New file.
12086         * lib/uchar.in.h (char32_t): Add comment.
12087         * lib/mbrtoc32.c: Include lc-charset-unicode.h.
12088         (mbrtoc32): If char32_t is Unicode and wchar_t is not, invoke
12089         locale_encoding_to_unicode.
12090         * lib/btoc32.c: Include lc-charset-unicode.h.
12091         (btoc32): If char32_t is Unicode and wchar_t is not, invoke
12092         locale_encoding_to_unicode.
12093         * lib/c32rtomb.c: Include lc-charset-unicode.h.
12094         (c32rtomb): If char32_t is Unicode and wchar_t is not, invoke
12095         unicode_to_locale_encoding.
12096         * lib/c32tob.c: Include lc-charset-unicode.h.
12097         (c32tob): If char32_t is Unicode and wchar_t is not, invoke
12098         unicode_to_locale_encoding.
12099         * lib/mbsnrtoc32s.c: If char32_t is Unicode and wchar_t is not, don't
12100         use mbsnrtowcs.
12101         * lib/mbsrtoc32s.c: If char32_t is Unicode and wchar_t is not, don't use
12102         mbsrtowcs.
12103         * lib/c32snrtombs.c: If char32_t is Unicode and wchar_t is not, don't
12104         use wcsnrtombs.
12105         * lib/c32srtombs.c: If char32_t is Unicode and wchar_t is not, don't use
12106         wcsrtombs.
12107         * lib/c32is-impl.h: Include lc-charset-unicode.h.
12108         (FUNC): If char32_t is Unicode and wchar_t is not, use UCS_FUNC.
12109         * lib/c32to-impl.h: Include lc-charset-unicode.h.
12110         (FUNC): If char32_t is Unicode and wchar_t is not, use UCS_FUNC.
12111         * lib/c32width.c: Include lc-charset-unicode.h.
12112         (c32width): If char32_t is Unicode and wchar_t is not, use uc_width.
12113         * tests/test-mbrtoc32.c: Include <wchar.h>.
12114         (main): Skip GB18030 tests on NetBSD and Solaris. If
12115         GL_CHAR32_T_IS_UNICODE, expect Unicode encoding for the char32_t values.
12116         * tests/test-mbrtoc32-w32.c: Include <wchar.h>.
12117         (test_one_locale): Simplify.
12118         * tests/test-c32rtomb.c (main): Skip GB18030 tests on NetBSD and
12119         Solaris.
12120         * tests/test-c32rtomb.sh: Update.
12121         * tests/test-mbsnrtoc32s.c: Include <wchar.h>.
12122         (main): Skip GB18030 tests on NetBSD and Solaris.
12123         * tests/test-mbsrtoc32s.c: Include <wchar.h>.
12124         (main): Skip GB18030 tests on NetBSD and Solaris.
12125         * tests/test-mbstoc32s.c (main): Skip GB18030 tests on NetBSD and
12126         Solaris.
12127         * tests/test-c32snrtombs.c (main): Skip GB18030 tests on NetBSD and
12128         Solaris.
12129         * tests/test-c32srtombs.c (main): Skip GB18030 tests on NetBSD and
12130         Solaris.
12131         * tests/test-c32stombs.c (main): Skip GB18030 tests on NetBSD and
12132         Solaris.
12133         * tests/test-c32isalnum.c (main): Skip GB18030 tests on NetBSD and
12134         Solaris.
12135         * tests/test-c32isalnum.sh: Update.
12136         * tests/test-c32isalpha.c (main): Skip GB18030 tests on NetBSD and
12137         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
12138         Solaris.
12139         * tests/test-c32isalpha.sh: Update.
12140         * tests/test-c32isblank.c (main): Skip GB18030 tests on NetBSD and
12141         Solaris.
12142         * tests/test-c32isblank.sh: Update.
12143         * tests/test-c32iscntrl.c (main): Skip GB18030 tests on NetBSD and
12144         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
12145         Solaris.
12146         * tests/test-c32iscntrl.sh: Update.
12147         * tests/test-c32isdigit.c (main): Skip GB18030 tests on NetBSD and
12148         Solaris.
12149         * tests/test-c32isdigit.sh: Update.
12150         * tests/test-c32isgraph.c (main): Skip GB18030 tests on NetBSD and
12151         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
12152         Solaris.
12153         * tests/test-c32isgraph.sh: Update.
12154         * tests/test-c32islower.c (main): Skip GB18030 tests on NetBSD and
12155         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
12156         Solaris.
12157         * tests/test-c32islower.sh: Update.
12158         * tests/test-c32isprint.c (main): Skip GB18030 tests on NetBSD and
12159         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
12160         Solaris.
12161         * tests/test-c32isprint.sh: Update.
12162         * tests/test-c32ispunct.c (main): Skip GB18030 tests on NetBSD and
12163         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
12164         Solaris.
12165         * tests/test-c32ispunct.sh: Update.
12166         * tests/test-c32isspace.c (main): Skip GB18030 tests on NetBSD and
12167         Solaris.
12168         * tests/test-c32isspace.sh: Update.
12169         * tests/test-c32isupper.c (main): Skip GB18030 tests on NetBSD and
12170         Solaris.
12171         * tests/test-c32isupper.sh: Update.
12172         * tests/test-c32isxdigit.c (main): Skip GB18030 tests on NetBSD and
12173         Solaris.
12174         * tests/test-c32isxdigit.sh: Update.
12175         * tests/test-c32tolower.c (main): Skip GB18030 tests on NetBSD and
12176         Solaris.
12177         * tests/test-c32tolower.sh: Update.
12178         * tests/test-c32toupper.c (main): Skip GB18030 tests on NetBSD and
12179         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
12180         Solaris.
12181         * tests/test-c32toupper.sh: Update.
12182         * modules/mbrtoc32 (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
12183         * modules/mbrtoc32-tests (Makefile.am): Link test-mbrtoc32 with
12184         $(LIBUNISTRING) $(LIBC32CONV).
12185         * modules/btoc32 (Link): New section.
12186         * modules/btoc32-tests (Makefile.am): Link test-btoc32 with
12187         $(LIBUNISTRING) $(LIBC32CONV).
12188         * modules/c32rtomb (Link): New section.
12189         * modules/c32rtomb-tests (Makefile.am): Link test-c32rtomb with
12190         $(LIBUNISTRING) $(LIBC32CONV).
12191         * modules/c32tob (Link): New section.
12192         * modules/mbsnrtoc32s (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
12193         * modules/mbsnrtoc32s-tests (Makefile.am): Link test-mbsnrtoc32s with
12194         $(LIBUNISTRING) $(LIBC32CONV).
12195         * modules/mbsrtoc32s (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
12196         * modules/mbsrtoc32s-tests (Makefile.am): Link test-mbsrtoc32s with
12197         $(LIBUNISTRING) $(LIBC32CONV).
12198         * modules/mbstoc32s (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
12199         * modules/mbstoc32s-tests (Makefile.am): Link test-mbstoc32s with
12200         $(LIBUNISTRING) $(LIBC32CONV).
12201         * modules/c32snrtombs (Link): New section.
12202         * modules/c32snrtombs-tests (Makefile.am): Link test-c32snrtombs with
12203         $(LIBUNISTRING) $(LIBC32CONV).
12204         * modules/c32srtombs (Link): New section.
12205         * modules/c32srtombs-tests (Makefile.am): Link test-c32srtombs with
12206         $(LIBUNISTRING) $(LIBC32CONV).
12207         * modules/c32stombs (Link): New section.
12208         * modules/c32stombs-tests (Makefile.am): Link test-c32stombs with
12209         $(LIBUNISTRING) $(LIBC32CONV).
12210         * modules/c32isalnum (Link): Add $(LIBC32CONV).
12211         * modules/c32isalnum-tests (Makefile.am): Link test-c32isalnum with
12212         $(LIBC32CONV).
12213         * modules/c32isalpha (Link): Add $(LIBC32CONV).
12214         * modules/c32isalpha-tests (Makefile.am): Link test-c32isalpha with
12215         $(LIBC32CONV).
12216         * modules/c32isblank (Link): Add $(LIBC32CONV).
12217         * modules/c32isblank-tests (Makefile.am): Link test-c32isblank with
12218         $(LIBC32CONV).
12219         * modules/c32iscntrl (Link): Add $(LIBC32CONV).
12220         * modules/c32iscntrl-tests (Makefile.am): Link test-c32iscntrl with
12221         $(LIBC32CONV).
12222         * modules/c32isdigit (Link): Add $(LIBC32CONV).
12223         * modules/c32isdigit-tests (Makefile.am): Link test-c32isdigit with
12224         $(LIBC32CONV).
12225         * modules/c32isgraph (Link): Add $(LIBC32CONV).
12226         * modules/c32isgraph-tests (Makefile.am): Link test-c32isgraph with
12227         $(LIBC32CONV).
12228         * modules/c32islower (Link): Add $(LIBC32CONV).
12229         * modules/c32islower-tests (Makefile.am): Link test-c32islower with
12230         $(LIBC32CONV).
12231         * modules/c32isprint (Link): Add $(LIBC32CONV).
12232         * modules/c32isprint-tests (Makefile.am): Link test-c32isprint with
12233         $(LIBC32CONV).
12234         * modules/c32ispunct (Link): Add $(LIBC32CONV).
12235         * modules/c32ispunct-tests (Makefile.am): Link test-c32ispunct with
12236         $(LIBC32CONV).
12237         * modules/c32isspace (Link): Add $(LIBC32CONV).
12238         * modules/c32isspace-tests (Makefile.am): Link test-c32isspace with
12239         $(LIBC32CONV).
12240         * modules/c32isupper (Link): Add $(LIBC32CONV).
12241         * modules/c32isupper-tests (Makefile.am): Link test-c32isupper with
12242         $(LIBC32CONV).
12243         * modules/c32isxdigit (Link): Add $(LIBC32CONV).
12244         * modules/c32isxdigit-tests (Makefile.am): Link test-c32isxdigit with
12245         $(LIBC32CONV).
12246         * modules/c32tolower (Link): Add $(LIBC32CONV).
12247         * modules/c32tolower-tests (Makefile.am): Link test-c32tolower with
12248         $(LIBC32CONV).
12249         * modules/c32toupper (Link): Add $(LIBC32CONV).
12250         * modules/c32toupper-tests (Makefile.am): Link test-c32toupper with
12251         $(LIBC32CONV).
12252         * modules/c32width (Link): Add $(LIBC32CONV).
12253         * modules/c32width-tests (Makefile.am): Link test-c32width with
12254         $(LIBC32CONV).
12255         * modules/c32swidth (Link): Add $(LIBC32CONV).
12256         * modules/c32swidth-tests (Makefile.am): Link test-c32swidth with
12257         $(LIBC32CONV).
12258         * modules/mbchar (Link): Add $(LIBC32CONV).
12259         * modules/mbiter (Link): Add $(LIBC32CONV).
12260         * modules/mbuiter (Link): Add $(LIBC32CONV).
12261         * modules/mbfile (Link): Add $(LIBC32CONV).
12262         * modules/mbmemcasecmp (Link): Add $(LIBC32CONV).
12263         * modules/mbmemcasecmp-tests (Makefile.am): Link test-mbmemcasecmp with
12264         $(LIBC32CONV).
12265         * modules/mbscasecmp (Link): Add $(LIBC32CONV).
12266         * modules/mbscasecmp-tests (Makefile.am): Link test-mbscasecmp with
12267         $(LIBC32CONV).
12268         * modules/mbscasestr (Link): Add $(LIBC32CONV).
12269         * modules/mbscasestr-tests (Makefile.am): Link test-mbscasestr1,
12270         test-mbscasestr2, test-mbscasestr3, test-mbscasestr4 with $(LIBC32CONV).
12271         * modules/mbschr (Link): Add $(LIBC32CONV).
12272         * modules/mbschr-tests (Makefile.am): Link test-mbschr with
12273         $(LIBC32CONV).
12274         * modules/mbscspn (Link): Add $(LIBC32CONV).
12275         * modules/mbscspn-tests (Makefile.am): Link test-mbscspn with
12276         $(LIBC32CONV).
12277         * modules/mbslen (Link): Add $(LIBC32CONV).
12278         * modules/mbsncasecmp (Link): Add $(LIBC32CONV).
12279         * modules/mbsncasecmp-tests (Makefile.am): Link test-mbsncasecmp with
12280         $(LIBC32CONV).
12281         * modules/mbsnlen (Link): Add $(LIBC32CONV).
12282         * modules/mbspbrk (Link): Add $(LIBC32CONV).
12283         * modules/mbspbrk-tests (Makefile.am): Link test-mbspbrk with
12284         $(LIBC32CONV).
12285         * modules/mbspcasecmp (Link): Add $(LIBC32CONV).
12286         * modules/mbspcasecmp-tests (Makefile.am): Link test-mbspcasecmp with
12287         $(LIBC32CONV).
12288         * modules/mbsrchr (Link): Add $(LIBC32CONV).
12289         * modules/mbsrchr-tests (Makefile.am): Link test-mbsrchr with
12290         $(LIBC32CONV).
12291         * modules/mbssep (Link): Add $(LIBC32CONV).
12292         * modules/mbsspn (Link): Add $(LIBC32CONV).
12293         * modules/mbsspn-tests (Makefile.am): Link test-mbsspn with
12294         $(LIBC32CONV).
12295         * modules/mbsstr (Link): Add $(LIBC32CONV).
12296         * modules/mbsstr-tests (Makefile.am): Link test-mbsstr1, test-mbsstr2,
12297         test-mbsstr3 with $(LIBC32CONV).
12298         * modules/mbstok_r (Link): Add $(LIBC32CONV).
12299         * modules/propername (Link): Add $(LIBC32CONV).
12300         * modules/regex-quote (Link): Add $(LIBC32CONV).
12301         * modules/regex-quote-tests (Makefile.am): Link test-regex-quote with
12302         $(LIBC32CONV).
12303         * modules/trim (Link): Add $(LIBC32CONV).
12304         * modules/trim-tests (Makefile.am): Link test-trim with $(LIBC32CONV).
12305         * modules/exclude (Link): Add $(LIBC32CONV).
12306         * modules/exclude-tests (Makefile.am): Link test-exclude with
12307         $(LIBC32CONV).
12308         * doc/posix-headers/uchar.texi: Mention the uchar-c23 module.
12309         * doc/posix-functions/mbrtoc32.texi: Likewise.
12310         * doc/strings.texi (The char32_t type): Likewise.
12312 2023-06-27  Bruno Haible  <bruno@clisp.org>
12314         striconveh: Fix module description.
12315         * modules/striconveh (Link): Add $(LIBUNISTRING).
12316         * modules/striconveha (Link): New section.
12317         * modules/xstriconveh (Link): New section.
12319 2023-06-25  Bruno Haible  <bruno@clisp.org>
12321         strncat: Update doc regarding Solaris 11.4.
12322         * doc/posix-functions/strncat.texi: Mention that the bug still exists on
12323         Solaris 11.4.
12324         * m4/strncat.m4 (gl_FUNC_STRNCAT): Update comments.
12326 2023-06-25  Bruno Haible  <bruno@clisp.org>
12328         thread: Avoid compiler warnings on Solaris.
12329         * lib/glthread/thread.h: Include <stdint.h>.
12330         (gl_thread_self_pointer): Do the cast from pthread_t to 'void *' via
12331         intptr_t.
12332         * modules/thread (Depends-on): Add stdint.
12334 2023-06-25  Bruno Haible  <bruno@clisp.org>
12336         strerrorname_np: Add support for Solaris 11.4/sparc.
12337         * lib/strerrorname_np.c (strerrorname_np): Consider ECKSUM, EFRAGS.
12338         Allow ENOANO to be overloaded to another value.
12339         * tests/test-strerrorname_np.c (main): Likewise.
12341 2023-06-25  Jim Meyering  <meyering@meta.com>
12343         doc: correct doubled "on on"
12344         * doc/glibc-functions/initstate_r.texi: As above.
12345         * doc/posix-functions/initstate.texi: As above.
12347 2023-06-25  Bruno Haible  <bruno@clisp.org>
12349         sigdescr_np tests: Avoid test failure on glibc/sparc.
12350         * tests/test-sigdescr_np.c (main): Accept the glibc result for SIGEMT.
12351         * doc/glibc-functions/sigdescr_np.texi: Mention two glibc deficiencies.
12353 2023-06-25  Bruno Haible  <bruno@clisp.org>
12355         strerrorname_np: Work around glibc bug on PowerPC, SPARC systems.
12356         * m4/strerrorname_np.m4 (gl_FUNC_STRERRORNAME_NP): Test also
12357         strerrorname_np (EDEADLOCK).
12358         * doc/glibc-functions/strerrorname_np.texi: Mention that glibc 2.36
12359         still needs a workaround.
12361 2023-06-25  Bruno Haible  <bruno@clisp.org>
12363         doc: Mention glibc initstate, initstate_r bug.
12364         * doc/posix-functions/initstate.texi: Mention glibc bug.
12365         * doc/glibc-functions/initstate_r.texi: Likewise.
12366         * tests/test-random_r.c: Add a comment.
12368 2023-06-25  Bruno Haible  <bruno@clisp.org>
12370         doc: Update doc regarding 'setstate'.
12371         * doc/posix-functions/setstate.texi: Mention also Solaris 11.4.
12373 2023-06-25  Bruno Haible  <bruno@clisp.org>
12375         doc: Update doc regarding <ieee754.h>.
12376         * doc/glibc-headers/ieee754.texi: Mention that it's not present on
12377         glibc/sparc64 in 32-bit mode.
12379 2023-06-25  Bruno Haible  <bruno@clisp.org>
12381         exclude: Complete last change.
12382         * lib/exclude.c: Include <uchar.h> instead of <wctype.h>.
12384 2023-06-24  Bruno Haible  <bruno@clisp.org>
12386         mbchar, mbiter, mbuiter: Overcome wchar_t limitations.
12387         * lib/mbchar.h: Include <uchar.h> instead of <wchar.h>, <wctype.h>.
12388         (struct mbchar): Use char32_t instead of wchar_t.
12389         (mb_casecmp, mb_caseequal): Use c32tolower instead of towlower.
12390         (mb_isalnum): Use c32isalnum instead of iswalnum.
12391         (mb_isalpha): Use c32isalpha instead of iswalpha.
12392         (mb_isblank): Use c32isblank instead of iswblank.
12393         (mb_iscntrl): Use c32iscntrl instead of iswcntrl.
12394         (mb_isdigit): Use c32isdigit instead of iswdigit.
12395         (mb_isgraph): Use c32isgraph instead of iswgraph.
12396         (mb_islower): Use c32islower instead of iswlower.
12397         (mb_isprint): Use c32isprint instead of iswprint.
12398         (mb_ispunct): Use c32ispunct instead of iswpunct.
12399         (mb_isspace): Use c32isspace instead of iswspace.
12400         (mb_isupper): Use c32isupper instead of iswupper.
12401         (mb_isxdigit): Use c32isxdigit instead of iswxdigit.
12402         (mb_width_aux): Use c32width, c32iscntrl instead of wcwidth, iswcntrl.
12403         * lib/mbiter.h: Include <uchar.h> instead of <wchar.h>.
12404         (mbiter_multi_next): Use mbrtoc32 instead of mbrtowc.
12405         * lib/mbuiter.h: Include <uchar.h> instead of <wchar.h>.
12406         (mbuiter_multi_next): Use mbrtoc32 instead of mbrtowc.
12407         * lib/mbfile.h (mbfile_multi_getc): Use mbrtoc32 instead of mbrtowc.
12408         * lib/mbscasestr.c (knuth_morris_pratt_multibyte, mbscasestr): Use
12409         c32tolower instead of towlower.
12410         * lib/exclude.c (string_hasher_ci): Use char32_t, c32tolower instead of
12411         wchar_t, towlower.
12412         * modules/mbchar (Depends-on): Add uchar, c32isalnum, c32isalpha,
12413         c32isblank, c32iscntrl, c32isdigit, c32isgraph, c32islower, c32isprint,
12414         c32ispunct, c32isspace, c32isupper, c32isxdigit, c32tolower, c32width.
12415         Remove wchar, wctype-h, iswblank, iswdigit, iswxdigit, wcwidth.
12416         * modules/mbiter (Depends-on): Add mbrtoc32, uchar. Remove mbrtowc,
12417         wchar.
12418         * modules/mbuiter (Depends-on): Likewise.
12419         * modules/mbscasestr (Depends-on): Add c32tolower.
12420         * modules/exclude (Depends-on): Add c32tolower.
12421         * doc/strings.texi (C strings): Fix typo.
12423 2023-06-22  Bruno Haible  <bruno@clisp.org>
12425         doc: Use makeinfo option to check menu structure.
12426         Trick revealed by Patrice Dumas <pertusus@free.fr> in
12427         <https://lists.gnu.org/archive/html/bug-texinfo/2023-06/msg00015.html>.
12428         * doc/Makefile (MAKEINFO): Enforce checking of menu structure.
12430 2023-06-22  Bruno Haible  <bruno@clisp.org>
12432         doc: Correct info menu structure.
12433         Reported by Elijah Zarezky <elijah@zarezky.spb.ru> in
12434         <https://lists.gnu.org/archive/html/bug-gnulib/2023-06/msg00105.html>.
12435         * doc/strings.texi (Strings): Add missing @menu item.
12437 2023-06-20  Paul Eggert  <eggert@cs.ucla.edu>
12439         doc: INSTALL uses UTF-8 now
12440         * doc/Makefile (INSTALL.ISO, INSTALL.UTF-8):
12441         Adjust to the fact that INSTALL now uses UTF-8.
12442         INSTALL.UTF-8 is now obsolescent since it is identical.
12443         (INSTALL.ISO): Transliterate all non-ASCII characters,
12444         not just single quotes.
12445         * doc/INSTALL.ISO: Regenerate.
12447 2023-06-19  Paul Eggert  <eggert@cs.ucla.edu>
12449         largefile: port to GNU/Linux s390x and alpha
12450         This patch syncs from Autoconf master.
12451         Problem reported by Matoro <https://bugs.gnu.org/64123>.
12452         * lib/autoconf/specific.m4 (_AC_SYS_LARGEFILE_TEST_CODE):
12453         New overridable macro FTYPE, to test types other than off_t.
12454         (_AC_SYS_LARGEFILE_TEST_CODE): Test ino_t for
12455         -D_FILE_OFFSETBITS=64 too, if no flags are needed for off_t.
12456         Needed for GNU/Linux on alpha and s390x.
12458 2023-06-19  Bruno Haible  <bruno@clisp.org>
12460         doc: Corrections to the "Strings and Characters" chapter.
12461         Suggested by Paul Eggert.
12462         * doc/strings.texi: Corrections: GB18030 is rarely used nowadays.
12463         <ctype.h> functions can be useful for specific data.
12465 2023-06-19  Bruno Haible  <bruno@clisp.org>
12467         doc: Use "spaced en dash" style instead of "spaced em dash" style.
12468         Suggested by Paul Eggert.
12469         * doc/gnulib.texi: At sentence level, use "spaced en dash" style instead
12470         of "spaced em dash" style.
12471         * doc/gnulib-intro.texi: Likewise.
12472         * doc/multithread.texi: Likewise.
12473         * doc/strings.texi: Likewise.
12475 2023-06-19  Bruno Haible  <bruno@clisp.org>
12477         setenv: Simplify m4 requires.
12478         * m4/setenv.m4 (gl_PREREQ_SETENV): Don't require AC_FUNC_ALLOCA.
12480 2023-06-18  Bruno Haible  <bruno@clisp.org>
12482         configmake: Bypass the unusable 'echo' command of some shells.
12483         Reported by Brian Inglis <Brian.Inglis@Shaw.ca> in
12484         <https://lists.gnu.org/archive/html/bug-gettext/2023-06/msg00054.html>.
12485         * m4/build-to-host.m4 (gl_BUILD_TO_HOST): Use 'printf' instead of
12486         'echo', because the "dash" shell has a SystemV compatible 'echo'
12487         command. Also, be sure to remove trailing CRs.
12489 2023-06-18  Paul Eggert  <eggert@cs.ucla.edu>
12491         update-copyright tests: fix to match behavior
12492         * tests/test-update-copyright.sh: Change tests to match new behavior.
12494 2023-06-18  Bruno Haible  <bruno@clisp.org>
12496         update-copyright tests: Add tests for man pages.
12497         * tests/test-update-copyright.sh: Add 4 tests that use man page syntax.
12499 2023-06-18  Bruno Haible  <bruno@clisp.org>
12501         gettext: Clarify the purpose of this module.
12502         Suggested by Paul Eggert in
12503         <https://lists.gnu.org/archive/html/bug-gnulib/2023-06/msg00089.html>.
12504         * modules/gettext (Description): Clarify the purpose.
12505         (Makefile.am): Remove outdated comment. "gettextize --intl" is no longer
12506         possible since 2019.
12508 2023-06-18  Paul Eggert  <eggert@cs.ucla.edu>
12510         Update \(en in copyright notices
12511         * build-aux/update-copyright (ndash_re): New var, matching \(en too.
12512         (stmt_remainder_re, stmt): Use it.
12513         (stmt): Match year in constructs like "\(en2023".
12514         (ndash): Now \(en in man pages.
12516 2023-06-17  Bruno Haible  <bruno@clisp.org>
12518         gettext: Update to gettext 0.22.
12519         * modules/gettext (Files): Add m4/build-to-host.m4.
12520         (configure.ac): Request infrastructure compatible with gettext 0.22.
12521         * m4/gettext.m4: Update from gettext 0.22.
12522         * m4/po.m4: Likewise.
12524 2023-06-15  Bruno Haible  <bruno@clisp.org>
12526         aligned-malloc, rmdir-errno: Sanitize configuration test result.
12527         * m4/malloc-align.m4 (gl_MALLOC_ALIGNMENT): Don't put a newline at the
12528         end of the conftest.out file.
12529         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Don't put a newline at the
12530         end of the confdir2/errno file.
12532 2023-06-13  Bruno Haible  <bruno@clisp.org>
12534         Make internationalization tests stricter on musl systems.
12535         --
12536         * m4/locale-fr.m4 (gt_LOCALE_FR): On musl systems, set LOCALE_FR_UTF8 to
12537         "fr_FR.UTF-8" instead of "none". Set and substitute
12538         LC_COLLATE_IMPLEMENTED, LC_NUMERIC_IMPLEMENTED, LC_TIME_IMPLEMENTED,
12539         LC_MONETARY_IMPLEMENTED.
12540         * m4/iswdigit.m4 (gl_FUNC_ISWDIGIT): Skip testing a certain locale if
12541         that locale is "none".
12542         * m4/iswxdigit.m4 (gl_FUNC_ISWXDIGIT): Likewise.
12543         * m4/mbrlen.m4 (gl_MBRLEN_RETVAL): Likewise.
12544         * m4/mbrtowc.m4 (gl_MBRTOWC_RETVAL): Likewise.
12545         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Likewise.
12546         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
12547         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
12548         --
12549         * tests/test-c32isalpha.c (main): On musl libc, disable tests that fail.
12550         * tests/test-c32iscntrl.c (main): Likewise.
12551         * tests/test-c32isgraph.c (main): Likewise.
12552         * tests/test-c32islower.c (main): Likewise.
12553         * tests/test-c32isprint.c (main): Likewise.
12554         * tests/test-c32toupper.c (main): Likewise.
12555         * tests/test-nl_langinfo1.c (main): Likewise.
12556         * tests/test-nl_langinfo2.c (main): Likewise.
12557         * modules/c32isalpha-tests (Files): Add musl.m4.
12558         (configure.ac): Invoke gl_MUSL_LIBC.
12559         * modules/c32iscntrl-tests (Files): Add musl.m4.
12560         (configure.ac): Invoke gl_MUSL_LIBC.
12561         * modules/c32isgraph-tests (Files): Add musl.m4.
12562         (configure.ac): Invoke gl_MUSL_LIBC.
12563         * modules/c32islower-tests (Files): Add musl.m4.
12564         (configure.ac): Invoke gl_MUSL_LIBC.
12565         * modules/c32isprint-tests (Files): Add musl.m4.
12566         (configure.ac): Invoke gl_MUSL_LIBC.
12567         * modules/c32toupper-tests (Files): Add musl.m4.
12568         (configure.ac): Invoke gl_MUSL_LIBC.
12569         * modules/nl_langinfo-tests (Files): Add musl.m4.
12570         (configure.ac): Invoke gl_MUSL_LIBC.
12571         --
12572         * tests/test-strtod1.sh: Skip the test if LC_NUMERIC_IMPLEMENTED is
12573         false.
12574         * tests/test-strtold1.sh: Likewise.
12575         * tests/test-vasnprintf-posix2.sh: Likewise.
12576         * tests/test-vasnwprintf-posix2.sh: Likewise.
12577         * modules/strtod-tests (Makefile.am): Set LC_NUMERIC_IMPLEMENTED in the
12578         tests environment.
12579         * modules/strtold-tests (Makefile.am): Likewise.
12580         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
12581         * modules/vasnwprintf-posix-tests (Makefile.am): Likewise.
12583 2023-06-12  Bruno Haible  <bruno@clisp.org>
12585         vasnwprintf-posix: Work around another musl libc bug.
12586         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LC): New macro.
12587         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke it, and set
12588         NEED_WPRINTF_DIRECTIVE_LC if the %lc test failed.
12589         * lib/vasnprintf.c (VASNPRINTF): If NEED_WPRINTF_DIRECTIVE_LC is set, do
12590         the processing for %lc and %ls ourselves.
12591         (local_wcslen): Update condition.
12592         * doc/posix-functions/swprintf.texi: Mention the %lc problem.
12594 2023-06-12  Bruno Haible  <bruno@clisp.org>
12596         vasnwprintf-posix: Work around a musl libc bug.
12597         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Test also whether swprintf
12598         in the C locale is free of encoding errors, and set
12599         NEED_WPRINTF_DIRECTIVE_C if not.
12600         * doc/posix-functions/swprintf.texi: Clarify the list of platforms for
12601         the %c problem.
12603 2023-06-12  Bruno Haible  <bruno@clisp.org>
12605         vasnwprintf: Fix some cross-compilation results.
12606         * m4/printf.m4 (gl_SWPRINTF_WORKS): Fix cross-compilation result for
12607         musl.
12608         (gl_SWPRINTF_DIRECTIVE_LA): Fix cross-compilation result for Android.
12610 2023-06-12  Bruno Haible  <bruno@clisp.org>
12612         warnings: Save memory and CPU time when inhibiting all warnings.
12613         * m4/warnings.m4 (gl_WARN_ADD): Improve comments.
12614         (gl_CC_INHIBIT_WARNINGS): Add also '-fno-analyzer' to
12615         GL_CFLAG_INHIBIT_WARNINGS.
12616         (gl_CXX_INHIBIT_WARNINGS): Add also '-fno-analyzer' to
12617         GL_CXXFLAG_INHIBIT_WARNINGS.
12619 2023-06-11  Bruno Haible  <bruno@clisp.org>
12621         javacomp-script, javacomp: Document effects of yesterday's change.
12622         * NEWS: Mention yesterday's change.
12624 2023-06-11  Bruno Haible  <bruno@clisp.org>
12626         javacomp-script, javacomp: Silence javac warnings regarding [options].
12627         * m4/javacomp.m4 (gt_JAVACOMP): Use option '-Xlint:-options' by default
12628         and omit it only when it does not work.
12629         * lib/javacomp.c (compile_using_javac): Add nowarn_option parameter.
12630         (is_envjavac_usable): Add nowarn_option_out parameter. Use option
12631         '-Xlint:-options' by default and omit it only when it does not work.
12632         (is_javac_usable): Likewise.
12633         (compile_java_class): Store the nowarn_option returned from
12634         is_envjavac_usable and use it when invoking compile_using_envjavac.
12635         Store the nowarn_option returned from is_javac_usable and use it when
12636         invoking compile_using_javac.
12638 2023-06-10  Bruno Haible  <bruno@clisp.org>
12640         javacomp-script, javacomp: Add support for javac versions > 11.
12641         Reported by Adrian Bunk <bunk-gnu@fs.tum.de> in
12642         <https://savannah.gnu.org/bugs/?63385>.
12643         * m4/javacomp.m4 (gt_JAVACOMP): When the java version is > 11, use that
12644         version as target_version, not 11. When the java version is > 17, don't
12645         warn. Remove goodcode, failcode variables. Don't bail out if the
12646         source-version argument or the target-version argument is in the range
12647         12..99. Use a heuristic that works with javac versions 11..20 at least.
12648         Update comments.
12649         * lib/javacomp.h (compile_java_class): State that source-version and
12650         target-version may be larger than 11.
12651         * lib/javacomp.c (default_target_version): Accommodate versions up to
12652         99.
12653         (SOURCE_VERSION_BOUND): Increase to 94.
12654         (source_version_index): Accept versions up to 99.
12655         (get_goodcode_snippet, get_failcode_snippet): Remove functions.
12656         (TARGET_VERSION_BOUND): Increase to 94.
12657         (target_version_index): Accept versions up to 99.
12658         (corresponding_classfile_version): Remove function.
12659         (execute_and_read_line): New function, based on lib/javaversion.c.
12660         (get_compiler_version): New function.
12661         (is_envjavac_usable): Add parameters source_option_out,
12662         target_option_out. Use a heuristic that works with javac versions 11..20
12663         at least. Call cleanup_temp_dir.
12664         (is_javac_usable): Likewise.
12665         (compile_java_class): Update.
12667 2023-06-10  Bruno Haible  <bruno@clisp.org>
12669         javacomp-script, javacomp: Remove support for javac versions < 1.6.
12670         * m4/javacomp.m4 (gt_JAVACOMP): State that the minimum source_version
12671         and the minimum target_version are 1.6. Map smaller values to 1.6.
12672         Complain if the java version is < 1.6. Use 1.6 as default, instead of
12673         1.1. Don't bother trying the -target option alone.
12674         * lib/javacomp.h (compile_java_class): State that the minimum
12675         source_version and the minimum target_version are 1.6.
12676         * lib/javacomp.c (default_target_version): Complain if the java version
12677         is < 1.6. Use 1.6 as default, instead of 1.1.
12678         (SOURCE_VERSION_BOUND, source_version_index, get_goodcode_snippet,
12679         get_failcode_snippet): Adjust to the new minimum source_version = 1.6.
12680         (TARGET_VERSION_BOUND, target_version_index,
12681         corresponding_classfile_version): Adjust to the new minimum
12682         target_version = 1.6.
12683         (get_source_version_for_javac): Remove function.
12684         (is_envjavac_usable): Remove source_version_for_javac parameter. Don't
12685         bother trying the -target option alone.
12686         (is_javac_usable): Likewise.
12687         (compile_java_class): Map source_version < 1.6 to 1.6. Map
12688         target_version < 1.6 to 1.6. Use source_version instead of calling
12689         get_source_version_for_javac.
12691 2023-06-10  Bruno Haible  <bruno@clisp.org>
12693         javacomp: Simplify after gcj support was removed.
12694         * m4/javacomp.m4 (gt_JAVACOMP): Don't create conftestlib.java.
12695         * lib/javacomp.c (compile_java_class): Remove local variables
12696         no_assert_option, fsource_option, ftarget_option.
12698 2023-06-09  Bruno Haible  <bruno@clisp.org>
12700         doc: Document <stdatomic.h>.
12701         * doc/posix-headers/stdatomic.texi: New file.
12702         * doc/gnulib.texi (Header File Substitutes): Include it.
12704 2023-06-09  Jim Meyering  <meyering@meta.com>
12706         maint.mk: sc_prohibit_xalloc_without_use: also match alloc_die
12707         * top/maint.mk (sc_prohibit_xalloc_without_use):
12708         Adjust in-comment command's regexp so it also finds alloc_die,
12709         whose declaration has a prefix of "_Noreturn ".
12710         Also delete some now-obsolete commentary.
12711         (_xa1): Regenerate the regexp using that command.
12712         Reported by Pádraig Brady in
12713         <https://lists.gnu.org/r/bug-gnulib/2023-06/msg00062.html>.
12715 2023-06-09  Paul Eggert  <eggert@cs.ucla.edu>
12717         xalloc-die: omit /*extern*/
12718         * lib/xalloc.h (xalloc_die): Omit leading "/*extern*/".
12719         It complicates syntax checking; see:
12720         https://lists.gnu.org/r/bug-gnulib/2023-06/msg00062.html
12721         Plus, it’s inconsistent style: the other function declarations in
12722         xalloc.h don’t use ‘extern’. (I’m not a fan of using ‘extern’ when
12723         it’s just noise, as is the case here.)
12725 2023-06-09  Bruno Haible  <bruno@clisp.org>
12727         javaversion: Update comments.
12728         * lib/javaversion.h (javaexec_version): Document the possible results up
12729         to OpenJDK 20.
12731 2023-06-09  Bruno Haible  <bruno@clisp.org>
12733         javacomp: Remove support for 'jikes'.
12734         * lib/javacomp.c (compile_using_jikes, is_jikes_present): Remove
12735         functions.
12736         (compile_java_class): Remove jikes related code.
12738         javacomp-script: Remove support for 'jikes'.
12739         * build-aux/javacomp.sh.in: Don't test HAVE_JIKES.
12740         * m4/javacomp.m4 (gt_JAVACOMP): Don't set HAVE_JIKES. Don't set
12741         CONF_JAVAC to 'jikes'. Update comment.
12742         (gt_JAVACOMP_DISABLED): Don't set HAVE_JIKES.
12744 2023-06-09  Bruno Haible  <bruno@clisp.org>
12746         javacomp: Remove support for 'gcj'.
12747         * lib/javacomp.h: Update comment.
12748         * lib/javacomp.c (compile_using_gcj, is_envjavac_gcj, is_envjavac_gcj43,
12749         is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
12750         is_envjavac_oldgcj_14_13_usable, is_gcj_present, is_gcj_43,
12751         is_gcj43_usable, is_oldgcj_14_14_usable, is_oldgcj_14_13_usable): Remove
12752         functions.
12753         (is_envjavac_usable): Renamed from is_envjavac_nongcj_usable.
12754         (compile_java_class): Remove gcj related code.
12756         javacomp-script: Remove support for 'gcj'.
12757         * build-aux/javacomp.sh.in: Don't test HAVE_GCJ_C.
12758         * m4/javacomp.m4 (gt_JAVACOMP): Don't set HAVE_GCJ_C. Don't test whether
12759         $JAVAC is gcj. Don't set CONF_JAVAC to 'gcj -C'. Update comment.
12760         (gt_JAVACOMP_DISABLED): Don't set HAVE_GCJ_C.
12762         javaexec: Remove support for 'gij'.
12763         * lib/javaexec.c (execute_java_class): Don't test for gij.
12765         javaexec-script: Remove support for 'gij'.
12766         * build-aux/javaexec.sh.in: Don't test HAVE_GIJ.
12767         * m4/javaexec.m4 (gt_JAVAEXEC): Don't set HAVE_GIJ. Don't set CONF_JAVA
12768         to 'gij'.
12769         * m4/javacomp.m4: Update comment.
12771 2023-06-09  Bruno Haible  <bruno@clisp.org>
12773         javaexec: Remove support for 'jview'.
12774         * lib/javaexec.c (execute_java_class): Don't test for jview.
12776         javaexec-script: Remove support for 'jview'.
12777         * build-aux/javaexec.sh.in: Don't test HAVE_JVIEW.
12778         * m4/javaexec.m4 (gt_JAVAEXEC): Don't set HAVE_JVIEW. Don't set
12779         CONF_JAVA to 'jview'.
12780         (gt_JAVAEXEC_DISABLED): Don't set HAVE_JVIEW.
12781         * m4/javacomp.m4: Update comment.
12783 2023-06-06  Jim Meyering  <meyering@meta.com>
12785         maint.mk: regenerate regex to reflect new functions in xalloc.h
12786         * top/maint.mk (sc_prohibit_xalloc_without_use) [_xa1]:
12787         Regenerate using the command listed in the comment.
12789 2023-06-06  Paul Eggert  <eggert@cs.ucla.edu>
12791         propername: pacify po_check
12792         Problem reported by Bruno Haible <https://bugs.gnu.org/63933>.
12793         * lib/propername.h: Change comment.
12795         Put "/" at end of .gitignore directory names
12796         * build-aux/bootstrap: Regenerate.
12797         * top/bootstrap-funclib.sh (symlink_to_dir, autogen):
12798         Put slashes after .gitignore entries that name directories.
12800 2023-06-06  Jose E. Marchesi  <jemarch@gnu.org>
12802         maintainer-makefile: Enforce the GNU Coding Standards in the README.
12803         * top/maint.mk (sc_readme_link_install): New rule.
12804         (sc_readme_link_copying): Likewise.
12806 2023-06-05  Paul Eggert  <eggert@cs.ucla.edu>
12808         copy-file-range: support building for older kernels
12809         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE):
12810         Remove static check, to support the dubious practice of
12811         building for platforms that predate the build platform.
12812         On working kernels this adds an extra syscall the first time
12813         that copy_file_range is used.  Problem reported for Gentoo by
12814         Sam James <https://bugs.gnu.org/63850>.
12816         manywarnings: more nuance about optimization
12817         * doc/manywarnings.texi (manywarnings): Suggest compiling with the
12818         optimization flags commonly used, as opposed to -O2 and -O0
12819         specifically.  -ggdb shouldn’t affect warnings so don’t mention it.
12821 2023-06-05  Bruno Haible  <bruno@clisp.org>
12823         posix_spawn-internal: Fix a warning (regression 2022-11-20).
12824         * lib/spawni.c: Don't use this particular #pragma for gcc < 4.2.
12826 2023-06-05  Bruno Haible  <bruno@clisp.org>
12828         file-has-acl: Fix compilation error on Slackware 13 (regr. 2023-05-12).
12829         * lib/file-has-acl.c (XATTR_NAME_POSIX_ACL_ACCESS,
12830         XATTR_NAME_POSIX_ACL_DEFAULT): Add fallback definitions.
12832 2023-06-05  Bruno Haible  <bruno@clisp.org>
12834         Fix bugs on mingw when module dirfd is in use (regression 2023-04-26).
12835         * lib/getcwd.c: When GNULIB_defined_DIR, revert to the system's
12836         definitions of opendir, closedir, readdir, rewinddir.
12837         * lib/mountlist.c: When GNULIB_defined_DIR, revert to the system's
12838         definitions of opendir, closedir, readdir.
12839         * lib/scandir.c: Likewise.
12840         * lib/glob.c: Fix comment. When GNULIB_defined_DIR, don't undefine
12841         opendir, closedir.
12843 2023-06-04  Bruno Haible  <bruno@clisp.org>
12845         manywarnings: Overhaul documentation.
12846         * doc/manywarnings.texi: In the example, put all unwanted warning
12847         options into 'nw', and use a second gl_MANYWARN_COMPLEMENT invocation to
12848         sort out how these options need to get added to WARN_FLAGS.
12849         Describe the first-time use in more detail: Recommend a new GCC.
12850         Recommend to test builds with -O2 and with -O0. Suggest to sort the
12851         warning by warning option. Add reference to the GCC pragma's
12852         documentation.
12854 2023-06-04  Bruno Haible  <bruno@clisp.org>
12856         error: Fix support for library namespacing (regression 2023-05-27).
12857         * lib/error.in.h (error): If error is defined as a macro, define a
12858         static inline function _gl_inline_error that invokes it, and let the
12859         new error macro invoke that function.
12860         (error_at_line): If error_at_line is defined as a macro, define a static
12861         inline function _gl_inline_error_at_line that invokes it, and let the
12862         new error_at_line macro invoke that function.
12864 2023-06-04  Bruno Haible  <bruno@clisp.org>
12866         terminfo, termcap: Fix "discards 'const' qualifier" warnings.
12867         * lib/tparm.c (tparm): Change type of 'fmt'. New local variable 'fmtp'.
12869 2023-06-04  Bruno Haible  <bruno@clisp.org>
12871         uniname/uniname: Add comments.
12872         * modules/uniname/uniname (Makefile.am): Explain how to work around a
12873         GCC bug.
12875 2023-06-04  Bruno Haible  <bruno@clisp.org>
12877         uniname/uniname: Fix -Wformat-signedness warning.
12878         * lib/uniname/uniname.c (unicode_character_name): Use %u instead of %d
12879         in format string.
12881 2023-06-04  Bruno Haible  <bruno@clisp.org>
12883         uniname/uniname: Improve comments.
12884         * lib/uniname/uniname.c (unicode_character_name): Fix comments.
12886 2023-06-03  Bruno Haible  <bruno@clisp.org>
12888         classpath, csharpexec: Avoid "candidate for attribute 'malloc'" warning.
12889         * lib/classpath.h (set_classpath): Mark with attribute 'malloc'.
12891 2023-06-03  Bruno Haible  <bruno@clisp.org>
12893         propername-lite: Improve documentation.
12894         * lib/propername.h: Describe functional differences between
12895         proper_name_lite and proper_name_utf8.
12897 2023-06-03  Bruno Haible  <bruno@clisp.org>
12899         gnulib-tool: Keep in sync with last change to gnulib-tool.py.
12900         * gnulib-tool (func_emit_po_Makevars): Treat proper_name_lite like
12901         proper_name_utf8.
12903 2023-06-03  Bruno Haible  <bruno@clisp.org>
12905         error: Improve comments.
12906         * lib/error.in.h (__gl_error_call): Add more comments.
12908 2023-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12910         error: do not evaluate status twice
12911         Do this in a different way, so that the status is evaluated
12912         once even when not optimizing and when using GCC.
12913         * lib/error.in.h (__gl_error_call1) [__GNUC__]: New macro.
12914         (__gl_error_call) [__GNUC__]: Use it.
12916 2023-06-02  Bruno Haible  <bruno@clisp.org>
12918         warnings: Add ability to inhibit all warnings.
12919         * m4/warnings.m4 (gl_CC_INHIBIT_WARNINGS, gl_CXX_INHIBIT_WARNINGS): New
12920         macros, based on gl_CC_ALLOW_WARNINGS and gl_CXX_ALLOW_WARNINGS in
12921         m4/gnulib-common.m4.
12923 2023-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12925         propername-lite: new module
12926         propername_lite acts like propername_utf8 but needs less
12927         infrastructure, e.g., it does not worry about memory allocation.
12928         * MODULES.html.sh (func_all_modules): Mention it.
12929         * lib/propername.h (proper_name_lite): New decl.
12930         * lib/propername-lite.c, modules/propername-lite: New files.
12931         * pygnulib/GLEmiter.py (GLEmiter.po_Makevars):
12932         Treat proper_name_lite like proper_name_utf8.
12934 2023-06-02  Bruno Haible  <bruno@clisp.org>
12936         openmp-init: Silence "no previous prototype for 'openmp_init'" warning.
12937         * lib/omp.in.h: Test _OPENMP.
12938         * lib/omp-init.c: Include <omp.h> always.
12939         * modules/openmp-init (Include): Allow <omp.h> to be included always.
12941 2023-06-02  Bruno Haible  <bruno@clisp.org>
12943         term-style-control: Silence -Wshadow warning.
12944         * lib/term-style-control.c (continuing_signal_handler): Rename
12945         parameter.
12947 2023-06-02  Bruno Haible  <bruno@clisp.org>
12949         pipe-filter-gi, pipe-filter-ii: Silence -Wunused-macro warning.
12950         * lib/pipe-filter-aux.c: Remove many unnecessary includes.
12951         (_): Remove macro.
12953 2023-06-02  Bruno Haible  <bruno@clisp.org>
12955         javacomp: Silence -Wanalyzer-possible-null-argument warning.
12956         * lib/javacomp.c: Include verify.h.
12957         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_13_usable,
12958         is_envjavac_nongcj_usable, compile_java_class): Assert that the
12959         xasprintf results are non-NULL. This is possible since all involved
12960         format strings are valid and don't use %ls, and all argument strings
12961         are small compared to INT_MAX.
12962         * modules/javacomp (Depends-on): Add verify.
12964 2023-06-02  Bruno Haible  <bruno@clisp.org>
12966         striconveha: Don't crash if malloc() returns NULL.
12967         * lib/striconveha.c (mem_iconveha, str_iconveha): Check malloca() return
12968         value.
12970 2023-06-02  Bruno Haible  <bruno@clisp.org>
12972         setenv: Don't crash if malloc() returns NULL.
12973         * lib/setenv.c (rpl_setenv): Check malloca() return value.
12975 2023-06-02  Bruno Haible  <bruno@clisp.org>
12977         error: Avoid implicit-fallthrough warnings with -O0 (regr. 2023-05-30).
12978         * lib/error.in.h (__gl_error_call): Parenthesize status. When not
12979         optimizing, expand to code without compound statements.
12981 2023-06-01  Bruno Haible  <bruno@clisp.org>
12983         getprogname: Add support for ASCII-compatible environments in z/OS.
12984         Reported by Mike Fulton <mikefultonpersonal@gmail.com> in
12985         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00198.html>.
12986         * lib/getprogname.c (getprogname): On z/OS, when compiling for an
12987         ASCII-compatible environment, convert the result from EBCDIC to ASCII.
12989 2023-06-01  Mitch Capper  <mitch.capper@gmail.com>
12991         gnulib-tool.py: Fix a format string mistake.
12992         * pygnulib/GLImport.py (GLImport.execute): Fix a typo in a format
12993         string.
12994         Copyright-paperwork-exempt: Yes
12996 2023-06-01  Bruno Haible  <bruno@clisp.org>
12998         Add info for maintainers and contributors.
12999         * HACKING: New file.
13001 2023-05-30  Nick Bowler  <nbowler@draconx.ca>
13003         readline: fix memory leak in replacement readline.
13004         * lib/readline.c (readline): Free memory after getline failure.
13005         Copyright-paperwork-exempt: true
13007 2023-05-30  Paul Eggert  <eggert@cs.ucla.edu>
13009         error: don’t call ‘exit’
13010         Let the underlying functions call ‘exit’, instead of having the
13011         Gnulib replacement macros do it.  Use ‘unreachable’ to tell the
13012         compiler that those functions exit when the status is nonzero.
13013         This saves a function call.
13014         * lib/error.in.h: Include stddef.h, not stdlib.h.
13015         (__gl_error_call): Rely on the function to exit, using
13016         ‘unreachable’ to tell the compiler that the function does not return.
13017         * modules/error (Depends-on): Add stddef.
13019         error: don’t evaluate status arg twice
13020         This avoids potential issues if the first argument has a side effect.
13021         * lib/error.in.h (__gl_error_call): New macro, which evaluates its
13022         status arg only once, by using a statement expression if GNU C -
13023         the only platform we need to worry about pacifying - and by simply
13024         calling ‘error’ otherwise.
13025         (error, error_at_line): Use it.
13027 2023-05-28  Bruno Haible  <bruno@clisp.org>
13029         warnings, manywarnings: Assume autoconf >= 2.64.
13030         * m4/warnings.m4 (gl_AS_VAR_APPEND): Remove macro.
13031         (gl_COMPILER_OPTION_IF, gl_WARN_ADD): Use AS_VAR_APPEND instead of
13032         gl_AS_VAR_APPEND.
13033         * m4/manywarnings.m4: Likewise.
13035 2023-05-28  Jim Meyering  <meyering@fb.com>
13037         file-has-acl: avoid warning from bleeding-edge GCC
13038         * lib/file-has-acl.c: Include attribute.h.
13039         (have_xattr): Declare with ATTRIBUTE_PURE,
13040         to avoid new warning from GCC14-to-be.
13041         * modules/file-has-acl (Depends-on): Add attribute.
13042         Spotted while building coreutils with this:
13043         gcc version 14.0.0 20230526 (experimental)
13045 2023-05-28  Bruno Haible  <bruno@clisp.org>
13047         error: Avoid -Wint-in-bool-context warning.
13048         Reported by Pádraig Brady in
13049         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00178.html>.
13050         * lib/error.in.h (error, error_at_line): Use 'status != 0', since status
13051         is expected to be an int, not a bool value.
13053 2023-05-27  Bruno Haible  <bruno@clisp.org>
13055         error: Support the compiler's control flow analysis better.
13056         * lib/error.in.h: Remove @PRAGMA_SYSTEM_HEADER@. Include <stdlib.h>.
13057         (error): Define as a macro that explicitly invokes exit().
13058         (error_at_line): Likewise.
13059         * lib/error.c (_GL_NO_INLINE_ERROR): Define before including error.h.
13060         * modules/error-h (configure.ac): Don't invoke gl_CONDITIONAL_HEADER.
13061         (Makefile.am): Generate error.h always. Don't substitute
13062         PRAGMA_SYSTEM_HEADER.
13063         * m4/error_h.m4 (gl_ERROR_H): Set COMPILE_ERROR_C instead of
13064         GL_GENERATE_ERROR_H.
13065         * modules/error (configure.ac, Depends-on): Test COMPILE_ERROR_C instead
13066         of GL_GENERATE_ERROR_H.
13067         * lib/copy-file.c: Revert the last change.
13069 2023-05-26  Bruno Haible  <bruno@clisp.org>
13071         flexmember: Make it easier to use.
13072         * lib/flexmember.h (FLEXNSIZEOF): New macro.
13073         * lib/hamt.c (alloc_bucket, alloc_subtrie): Fix FLEXSIZEOF invocation.
13074         Use FLEXNSIZEOF instead of FLEXSIZEOF.
13075         * lib/ssfmalloc.h (init_small_block_page_pool): Use FLEXNSIZEOF instead
13076         of FLEXSIZEOF.
13078 2023-05-26  Bruno Haible  <bruno@clisp.org>
13080         diffseq: Silence another gcc warning.
13081         * lib/diffseq.h (compareseq): Move into the scope of the '#pragma GCC
13082         diagnostic'.
13084 2023-05-26  Bruno Haible  <bruno@clisp.org>
13086         copy-file: Silence gcc warnings.
13087         * lib/copy-file.c: Add #pragma GCC diagnostic.
13089 2023-05-26  Bruno Haible  <bruno@clisp.org>
13091         diffseq: Silence gcc warning.
13092         * lib/diffseq.h: Add #pragma GCC diagnostic.
13094 2023-05-24  Paul Eggert  <eggert@cs.ucla.edu>
13096         manywarnings: speed up nomfi test
13097         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Simplify and speed up
13098         on current platforms, by seeing first whether
13099         -Wno-missing-field-initializers is needed (it isn’t), so that
13100         later we don’t need to determine whether it’s supported.
13102         Simplify -Wno-missing-field-initializers checking
13103         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Don’t worry about
13104         -Wmissing-field-initializers, as this is no longer needed now that
13105         gl_MANYWARN_ALL_GCC is fixed.
13107         manywarnings: port better to GCC 11.2 and earlier
13108         Problem reported by Bruno Haible in:
13109         https://lists.gnu.org/r/bug-diffutils/2023-05/msg00015.html
13110         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
13111         Also test for GCC bug 82283
13112         <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82283>.
13114 2023-05-24  Bruno Haible  <bruno@clisp.org>
13116         asyncsafe-spin, simple-atomic: Don't use -mcpu-v9 on NetBSD/sparc.
13117         Reported by Brandon Applegate in
13118         <https://lists.gnu.org/archive/html/bug-gettext/2023-05/msg00042.html>.
13119         * lib/asyncsafe-spin.c: Limit the SPARC workaround to Solaris.
13120         * lib/simple-atomic.c: Likewise.
13121         * m4/sparcv8+.m4 (gl_SPARC_V8PLUS): Likewise.
13123 2023-05-23  Paul Eggert  <eggert@cs.ucla.edu>
13125         nstrftime: wmemmove → __wmemmove in glibc part
13126         https://sourceware.org/pipermail/libc-alpha/2023-May/148435.html
13127         * lib/nstrftime.c (__strftime_internal) [COMPILE_WIDE]:
13128         Use __wmemmove, not wmemmove, to keep in better sync with draft glibc.
13130 2023-05-22  Bruno Haible  <bruno@clisp.org>
13132         git-merge-changelog: Code style changes.
13133         * lib/git-merge-changelog.c: Don't make side effects to variables
13134         inside parenthesized expressions. Write (size_t)(-1), for consistency
13135         with gl_list.h.
13136         (compute_mapping): Rename variable in2 to jrev.
13138 2023-05-21  Paul Eggert  <eggert@cs.ucla.edu>
13140         strtol: match 'configure' to 'make check'
13141         Inferred from report by Tomasz Kłoczko <https://bugs.gnu.org/63632>.
13142         * m4/strtol.m4 (gl_FUNC_STRTOL):
13143         * m4/strtoll.m4 (gl_FUNC_STRTOLL):
13144         Also test "0b", since the test cases check it.
13146         git-merge-changelog: port to size_t padding
13147         * lib/git-merge-changelog (entry_hashcode):
13148         As a nicety, Prefer SIZE_WIDTH to computing it ourselves.
13150         git-merge-changelog: prefer idx_t
13151         * lib/git-merge-changelog.c: Include idx.h.
13152         (struct entry, entry_create, entry_hashcode)
13153         (struct changelog_file, read_changelog_file)
13154         (entries_mapping_get, entries_mapping_reverse_get)
13155         (compute_mapping, struct edit, struct differences)
13156         (compute_differences, find_paragraph_end)
13157         (try_split_merged_entry, struct conflict, conflict_write, main):
13158         Prefer idx_t to ptrdiff_t and size_t when the value is a
13159         nonnegative index or size.  Change a few for-loops so that
13160         the index never goes negative.
13161         * modules/git-merge-changelog (Depends-on): Add idx.
13163         git-merge-changelog: ssize_t → ptrdiff_t
13164         Prefer ptrdiff_t to ssize_t, as per
13165         <https://lists.gnu.org/archive/html/emacs-devel/2014-10/msg00019.html>.
13166         * lib/git-merge-changelog.c (struct entries_mapping)
13167         (entries_mapping_get, entries_mapping_reverse_get)
13168         (compute_mapping, struct edit, struct differences, OFFSET)
13169         (OFFSET_MAX, EXTRA_CONTEXT_FIELDS, compute_differences, main):
13170         Use ptrdiff_t, not ssize_t.
13171         * modules/git-merge-changelog (Depends-on): Add stdint for PTRDIFF_MAX.
13173         git-merge-changelog: port to ssize_t padding
13174         * lib/git-merge-changelog.c (OFFSET_MAX): New macro, as a nicety.
13176 2023-05-21  Bruno Haible  <bruno@clisp.org>
13178         limits-h tests: Check the value of SSIZE_MAX.
13179         * tests/test-limits-h.c (limits12): New variable.
13180         Include <sys/types.h> and check the value of SSIZE_MAX.
13181         * modules/limits-h-tests (Depends-on): Add sys_types.
13183 2023-05-21  Bruno Haible  <bruno@clisp.org>
13185         ssize_t: Fix replacement on 64-bit Windows.
13186         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Use prefix 'gl_' instead of 'gt_'.
13187         Define ssize_t to 'long long' or 'long', depending on the width of
13188         'size_t'.
13190 2023-05-20  Paul Eggert  <eggert@cs.ucla.edu>
13192         limits-h: other modules can rely on SSIZE_MAX
13193         * lib/areadlink-with-size.c, lib/areadlinkat-with-size.c:
13194         * lib/careadlinkat.c, lib/getdelim.c, lib/getndelim2.c:
13195         * lib/regex_internal.h:
13196         (SSIZE_MAX): Do not define.
13197         * modules/areadlink-with-size, modules/areadlinkat-with-size:
13198         * modules/careadlinkat, modules/getdelim, modules/getndelim2:
13199         * modules/regex:
13200         (Depends-on) Add limits-h.
13202         limits-h: define SSIZE_MAX
13203         * doc/posix-headers/limits.texi (limits.h): Document this.
13204         * lib/limits.in.h (SSIZE_MAX): Define if not already defined.
13205         * m4/limits-h.m4 (gl_LIMITS_H): Also generate limits.h
13206         if <limits.h> does not define SSIZE_MAX.
13208         diffseq: backward compatibility for OFFSET_MAX
13209         * lib/diffseq.h (OFFSET_MAX): Define only if not already defined.
13211 2023-05-19  Bruno Haible  <bruno@clisp.org>
13213         careadlinkat: Silence gcc warning for GCC ≥ 12.
13214         * lib/careadlinkat.c: For GCC 12 or newer, use
13215         "#pragma GCC diagnostic ignored" to silence the warning.
13217 2023-05-19  Pádraig Brady  <P@draigBrady.com>
13219         modechange: pacify gcc -Wsuggest-attribute=pure
13220         * lib/modechange.h (mode_adjust): Add _GL_ATTRIBUTE_PURE
13221         suggested with GCC 12 with -flto.
13223 2023-05-19  Paul Eggert  <eggert@cs.ucla.edu>
13225         diffseq: don’t assume integers lack padding
13226         * NEWS: Mention this.
13227         * lib/diffseq.h (OFFSET_MAX): Don’t define;
13228         this is now the user’s responsibility.
13229         * lib/fstrcmp.c (OFFSET_MAX): Define to PTRDIFF_MAX.
13231 2023-05-18  Bruno Haible  <bruno@clisp.org>
13233         getndelim2: Silence gcc warning.
13234         * lib/getndelim2.c: Add #pragma GCC diagnostic.
13235         (IF_LINT): Remove macro.
13236         (getndelim2): Remove use of IF_LINT.
13238 2023-05-18  Bruno Haible  <bruno@clisp.org>
13240         canonicalize: Silence gcc warning.
13241         * lib/canonicalize.c: Add #pragma GCC diagnostic.
13242         (IF_LINT): Remove macro.
13243         (canonicalize_filename_mode_stk): Remove use of IF_LINT.
13245 2023-05-18  Bruno Haible  <bruno@clisp.org>
13247         vasnprintf, c-vasnprintf: Silence gcc warning.
13248         * lib/vasnprintf.c: Add #pragma GCC diagnostic.
13250 2023-05-18  Bruno Haible  <bruno@clisp.org>
13252         nstrftime: Silence gcc warning.
13253         * lib/nstrftime.c: Add #pragma GCC diagnostic.
13255 2023-05-18  Bruno Haible  <bruno@clisp.org>
13257         astrxfrm: Silence gcc warning.
13258         * lib/astrxfrm.c: Add #pragma GCC diagnostic.
13260 2023-05-18  Bruno Haible  <bruno@clisp.org>
13262         vasnprintf, c-vasnprintf: Silence gcc warnings.
13263         * lib/vasnprintf.c (scale10_round_decimal_decoded): Remove memory==NULL
13264         test.
13265         (scale10_round_decimal_long_double, scale10_round_decimal_double): Test
13266         for memory==NULL here. Remove use of IF_LINT.
13268 2023-05-18  Bruno Haible  <bruno@clisp.org>
13270         bitset: Silence gcc warning.
13271         * lib/bitset/list.c (lbitset_copy_): Remove redundant test from the
13272         loop's first iteration.
13274 2023-05-18  Bruno Haible  <bruno@clisp.org>
13276         stack: Silence gcc warning in tests.
13277         * lib/stack.h (init, destroy, empty, current_base, push, pop, discard,
13278         top, size): Mark as possibly unused.
13280 2023-05-18  Bruno Haible  <bruno@clisp.org>
13282         hamt: Silence gcc warning.
13283         * lib/hamt.c (init_element): Mark as possibly unused.
13285 2023-05-18  Bruno Haible  <bruno@clisp.org>
13287         get-rusage-data: Silence gcc warning.
13288         * lib/get-rusage-data.c (get_rusage_data_via_iterator): Mark as possibly
13289         unused.
13291 2023-05-18  Bruno Haible  <bruno@clisp.org>
13293         astrxfrm: Fix use-after-free bug.
13294         * lib/astrxfrm.c (astrxfrm): Don't use memcpy after realloc succeeded.
13296 2023-05-18  Bruno Haible  <bruno@clisp.org>
13298         gnulib-tool: Ignore .orig and .rej files under modules/.
13299         * gnulib-tool (func_sanitize_modulelist): Exclude also files whose name
13300         ends in .orig or .rej.
13301         * pygnulib/GLModuleSystem.py (GLModuleSystem.file_is_module): Likewise.
13303 2023-05-18  Bruno Haible  <bruno@clisp.org>
13305         uchar: Fix error when <uchar.h> is included twice.
13306         * lib/uchar.in.h: Fix double-inclusion guard.
13308 2023-05-17  Paul Eggert  <eggert@cs.ucla.edu>
13310         stdckdint: use in more modules
13311         * lib/nstrftime.c (__strftime_internal):
13312         * lib/parse-datetime.y (apply_relative_time, zone, date)
13313         (iso_8601_date, relunit, relunit_snumber, time_zone_hhmm)
13314         (to_tm_year, yylex, parse_datetime_body):
13315         * lib/timespec-add.c (timespec_add):
13316         * lib/timespec-sub.c (timespec_sub):
13317         * lib/xstrtol.c (bkm_scale):
13318         Prefer ckd_add to INT_ADD_WRAPV etc., and include stdckdint.h.
13319         * modules/nstrftime, modules/parse-datetime:
13320         * modules/timespec-add, modules/timespec-sub, modules/xstrtol:
13321         (Depends-on): Add stdckdint.
13323         nstrftime: suggest to glibc how to avoid alloca
13324         * lib/nstrftime.c (widen) [COMPILE_WIDE]: Remove.
13325         (__strftime_internal) [COMPILE_WIDE): Instead of converting the
13326         multibyte time zone abbreviation into a potentially unbounded
13327         alloca buffer, convert it directly into the output buffer.
13328         Although this code is not used in Gnulib, this can help the glibc
13329         developers avoid the problem on the glibc side.
13331 2023-05-15  Bruno Haible  <bruno@clisp.org>
13333         doc: New chapter "Strings and Characters".
13334         * doc/strings.texi: New file.
13335         * doc/gnulib.texi (POSIXURL): New variable.
13336         (posixheader, posixfunc, func): New macros, from GNU libunistring's
13337         documentation.
13338         Include strings.texi.
13339         (Particular Modules): Don't include c-locale.texi here.
13340         * doc/c-locale.texi: Sections become subsections, subsections become
13341         subsubsections.
13342         * doc/posix-functions/isalnum.texi: Mention c32isalnum.
13343         * doc/posix-functions/isalpha.texi: Mention c32isalpha.
13344         * doc/posix-functions/isblank.texi: Mention c32isblank.
13345         * doc/posix-functions/iscntrl.texi: Mention c32iscntrl.
13346         * doc/posix-functions/isdigit.texi: Mention c32isdigit.
13347         * doc/posix-functions/isgraph.texi: Mention c32isgraph.
13348         * doc/posix-functions/islower.texi: Mention c32islower.
13349         * doc/posix-functions/isprint.texi: Mention c32isprint.
13350         * doc/posix-functions/ispunct.texi: Mention c32ispunct.
13351         * doc/posix-functions/isspace.texi: Mention c32isspace.
13352         * doc/posix-functions/isupper.texi: Mention c32isupper.
13353         * doc/posix-functions/isxdigit.texi: Mention c32isxdigit.
13354         * doc/posix-functions/tolower.texi: Mention alternative APIs.
13355         * doc/posix-functions/toupper.texi: Likewise.
13356         * doc/posix-functions/towlower.texi: Mention c32tolower.
13357         * doc/posix-functions/towupper.texi: Mention c32toupper.
13358         * doc/posix-functions/wcswidth.texi: Mention c32swidth.
13359         * doc/posix-functions/wcwidth.texi: Mention c32width.
13361 2023-05-15  Bruno Haible  <bruno@clisp.org>
13363         sigsegv: Add tentative support for Hurd/x86_64.
13364         Based on explanations by Sergey Bugaev <bugaevc@gmail.com>.
13365         * lib/sigsegv.c: Update from libsigsegv/src/fault-hurd-i386-old.h.
13367 2023-05-15  Paul Eggert  <eggert@cs.ucla.edu>
13369         file-has-acl: improve port to Fedora 39
13370         Problem reported by Ondrej Valousek in:
13371         https://lists.gnu.org/r/bug-gnulib/2023-05/msg00078.html
13372         * lib/file-has-acl.c: Include minmax.h.
13373         [USE_ACL && HAVE_LINUX_XATTR_H && HAVE_LISTXATTR]: Include stdckdint.h.
13374         (file_has_acl) [USE_ACL && HAVE_LINUX_XATTR_H && HAVE_LISTXATTR]:
13375         If the file has NFSv4 ACLs, ignore any POSIX ACLs, for Fedora 39.
13376         Return a bit faster when listxattr returns 0.
13377         Don’t loop forever if an attacker is fiddling with ACLs.
13378         * modules/file-has-acl (Depends-on): Add minmax, stdckdint.
13380 2023-05-15  Bruno Haible  <bruno@clisp.org>
13382         Work around https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82283 .
13383         Reported by Pádraig Brady <P@draigBrady.com> in
13384         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00077.html>.
13385         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Add
13386         -Wno-missing-field-initializers for GCC < 11.
13388 2023-05-15  Bruno Haible  <bruno@clisp.org>
13390         gettimeofday, pthread-*, thread, thrd: Don't omit intended initializers.
13391         * lib/gettimeofday.c (gettimeofday): List the initializers of both
13392         tv_sec and tv_usec.
13393         * lib/glthread/thread.c (gl_thread_self): List the initializers of both
13394         tv_sec and tv_nsec.
13395         * lib/pthread-cond.c (pthread_cond_wait): Likewise.
13396         * lib/thrd.c (rpl_thrd_current): Likewise.
13397         * lib/pthread-rwlock.c (MIN): New macro.
13398         (pthread_rwlock_timedrdlock, pthread_rwlock_timedwrlock): List the
13399         initializers of both tv_sec and tv_nsec. Don't modify the duration after
13400         having initialized it.
13401         * lib/pthread_mutex_timedlock.c (MIN): New macro.
13402         (pthread_mutex_timedlock): List the initializers of both tv_sec and
13403         tv_nsec. Don't modify the duration after having initialized it.
13405         select: Fix compilation error (regression from yesterday).
13406         * lib/select.c (rpl_select): Revert last change.
13408         poll: Fix syntax error (regression from yesterday).
13409         * lib/poll.c (poll): Remove semicolon inside braces.
13411 2023-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13413         timespec: fill in other members
13414         This problem was found when compiling GNU Emacs with
13415         --enable-gcc-warnings on a platform where tv_sec is 64 bits and
13416         tv_nsec is 32 bits, and struct timespec has padding.  GCC
13417         -Wuse-of-uninitialized-value complained when a struct timespec
13418         initialized only via assigning to tv_sec and tv_nsec was copied
13419         via assignment (this was in lib/timespec.h’s make_timespec).
13420         Although behavior is well-defined on this platform, the warning is
13421         annoying and the behavior might not be well-defined on theoretical
13422         platforms where struct timespec has other members.  To work around
13423         this, initialize all the struct’s members.
13424         * lib/getsockopt.c (rpl_getsockopt):
13425         * lib/gettime.c (gettime):
13426         * lib/gettimeofday.c (gettimeofday):
13427         * lib/glthread/thread.c (gl_thread_self):
13428         * lib/nanosleep.c (nanosleep):
13429         * lib/parse-datetime.y (digits_to_date_time, set_hhmmss)
13430         (signed_seconds, unsigned_seconds, yylex, parse_datetime_body):
13431         * lib/poll.c (poll):
13432         * lib/pselect.c (pselect):
13433         * lib/pthread-cond.c (endlessly, pthread_cond_timedwait):
13434         * lib/pthread-rwlock.c (pthread_rwlock_timedrdlock)
13435         (pthread_rwlock_timedwrlock):
13436         * lib/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
13437         * lib/select.c (rpl_select):
13438         * lib/settime.c (settime):
13439         * lib/stat-time.h (get_stat_atime, get_stat_ctime)
13440         (get_stat_mtime, get_stat_birthtime):
13441         * lib/thrd.c (rpl_thrd_current):
13442         * lib/timespec.h (make_timespec):
13443         * lib/timespec_getres.c (timespec_getres):
13444         * lib/utimecmp.c (utimecmpat):
13445         * lib/utimens.c (fdutimens):
13446         When filling in a struct timespec or similar time-related structure
13447         that might be copied elsewhere, also assign to any storage other
13448         than tv_sec and tv_nsec, to avoid undefined behavior on (likely
13449         theoretical) platforms where struct timespec has other members,
13450         and also to avoid warnings from GCC and/or valgrind.
13452         year2038-recommended: Improve failure diagnostic.
13453         * m4/largefile.m4 (AC_SYS_YEAR2038_RECOMMENDED): Sync from Autoconf.
13455 2023-05-13  Paul Eggert  <eggert@cs.ucla.edu>
13457         stdio: use _GL_ATTRIBUTE_MALLOC
13458         * lib/stdio.in.h (fdopen, fopen, popen, tmpfile): Declare with
13459         _GL_ATTRIBUTE_MALLOC, for consistency with glibc, and so that
13460         building the fopen module with ‘gcc -O2 -Wsuggest-attribute=malloc
13461         -Wsystem-headers -Werror’ does not fail with “stdio.h: In function
13462         ‘rpl_fopen’: stdio.h:970:1: error: function might be candidate for
13463         attribute ‘malloc’ [-Werror=suggest-attribute=malloc]”, a problem
13464         I noticed on both Fedora 38 and Ubuntu 23.04.
13466 2023-05-12  Bruno Haible  <bruno@clisp.org>
13468         sigsegv: Add tentative support for Hurd/x86_64.
13469         Reported by Samuel Thibault <samuel.thibault@ens-lyon.org>.
13470         * lib/sigsegv.c: Update from libsigsegv/src/fault-hurd-i386.h.
13472 2023-05-12  Paul Eggert  <eggert@cs.ucla.edu>
13474         file-has-acl: port to Fedora 39
13475         Fedora 39 getxattr with XATTR_NAME_POSIX_ACL_ACCESS either
13476         succeeds or fails with ENODATA, so it is no longer possible to
13477         detect from its failure that the filesystem might support NFSv4 ACLs.
13478         Problem reported by Ondrej Valousek in:
13479         https://lists.gnu.org/r/bug-gnulib/2023-04/msg00228.html
13480         Instead, use listxattr to determine whether NFSv4 ACLs are in play.
13481         This typically saves syscalls anyway.
13482         * lib/file-has-acl.c: In #if, use (HAVE_LINUX_XATTR_H &&
13483         HAVE_LISTXATTR) instead of GETXATTR_WITH_POSIX_ACLS.
13484         The following changes apply when (USE_ACL && HAVE_LINUX_XATTR_H &&
13485         HAVE_LISTXATTR):
13486         Include minmax.h.
13487         (have_xattr): New function.
13488         (file_has_acl): Try listxattr first; typically this means we need
13489         to do no other syscall.  Call getxattr only if there are NFSv4
13490         ACLs but not POSIX ACLs.
13491         * m4/acl.m4 (gl_FILE_HAS_ACL): Simplify by merely testing for
13492         linux/xattr.h and listxattr.  All uses changed.
13494 2023-05-10  Josh Soref  <jsoref@gmail.com>
13496         bootstrap: spelling/grammar fix in comment
13497         * build-aux/bootstrap: As above.
13499 2023-05-07  Paul Eggert  <eggert@cs.ucla.edu>
13501         Warn against bogus TZ settings
13502         * doc/parse-datetime.texi (Specifying time zone rules):
13503         Warn against TZ="UTC=5".
13505 2023-05-05  Bruno Haible  <bruno@clisp.org>
13507         dirfd: Add tests.
13508         * tests/test-dirfd.c: New file.
13509         * modules/dirfd-tests: New file.
13511 2023-05-05  Bruno Haible  <bruno@clisp.org>
13513         dirfd: Fix bogus override (regression 2023-04-26).
13514         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
13515         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00040.html>.
13516         * m4/dirfd.m4 (gl_FUNC_DIRFD): Fix mistake in last change.
13518 2023-05-04  Bruno Haible  <bruno@clisp.org>
13520         c32swidth: Add tests.
13521         * tests/test-c32swidth.c: New file, based on tests/test-c32width.c.
13522         * modules/c32swidth-tests: New file.
13524         c32swidth: New module.
13525         * lib/uchar.in.h (c32swidth): New declaration.
13526         * lib/wcswidth-impl.h: Use macros FUNC, UNIT, CHARACTER_WIDTH.
13527         * lib/wcswidth.c: Define FUNC, UNIT, CHARACTER_WIDTH before including
13528         wcswidth-impl.h.
13529         * lib/c32swidth.c: New file.
13530         * modules/c32swidth: New file.
13531         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
13532         GNULIB_C32SWIDTH.
13533         * modules/uchar (Makefile.am): Substitute GNULIB_C32SWIDTH.
13535 2023-05-04  Bruno Haible  <bruno@clisp.org>
13537         wcswidth: Fix result in case of overflow.
13538         * lib/wcswidth-impl.h (wcswidth): Continue searching for a non-printing
13539         wide character after the total width has become > INT_MAX.
13541 2023-05-04  Bruno Haible  <bruno@clisp.org>
13543         wcswidth: Relax license.
13544         * modules/wcswidth (License): Change to LGPLv2+.
13545         * lib/wcswidth.c: Update license notice.
13546         * lib/wcswidth-impl.h: Likewise.
13548 2023-05-04  Bruno Haible  <bruno@clisp.org>
13550         c32width: Relax license.
13551         * modules/c32width (License): Change to LGPLv2+.
13552         * lib/c32width.c: Update license notice.
13554 2023-05-04  Bruno Haible  <bruno@clisp.org>
13556         c32to*: Relax license.
13557         * modules/c32tolower (License): Change to LGPLv2+.
13558         * modules/c32toupper (License): Likewise.
13559         * lib/c32tolower.c: Update license notice.
13560         * lib/c32toupper.c: Likewise.
13561         * lib/c32to-impl.h: Likewise.
13563         unicase/tolower, unicase/toupper: Relax license.
13564         * lib/gen-uni-tables.c (output_simple_mapping): Bump copyright year. For
13565         unicase/tolower.h and unicase/toupper.h, use the LGPLv2+.
13566         * lib/unicase/tolower.h: Regenerated.
13567         * lib/unicase/toupper.h: Likewise.
13568         * lib/unicase/simple-mapping.h: Update license notice.
13569         * lib/unicase/tolower.c: Likewise.
13570         * lib/unicase/toupper.c: Likewise.
13571         * modules/unicase/tolower (License): Change to LGPLv2+.
13572         * modules/unicase/toupper (License): Likewise.
13574         unicase/base: Relax license.
13575         * modules/unicase/base (License): Change to LGPLv2+.
13576         * lib/unicase.in.h: Update license notice.
13578 2023-05-04  Bruno Haible  <bruno@clisp.org>
13580         c32is*: Relax license.
13581         * modules/c32isalnum (License): Change to LGPLv2+.
13582         * modules/c32isalpha (License): Likewise.
13583         * modules/c32isblank (License): Likewise.
13584         * modules/c32iscntrl (License): Likewise.
13585         * modules/c32isdigit (License): Likewise.
13586         * modules/c32isgraph (License): Likewise.
13587         * modules/c32islower (License): Likewise.
13588         * modules/c32isprint (License): Likewise.
13589         * modules/c32ispunct (License): Likewise.
13590         * modules/c32isspace (License): Likewise.
13591         * modules/c32isupper (License): Likewise.
13592         * modules/c32isxdigit (License): Likewise.
13593         * lib/c32isalnum.c: Update license notice.
13594         * lib/c32isalpha.c: Likewise.
13595         * lib/c32isblank.c: Likewise.
13596         * lib/c32iscntrl.c: Likewise.
13597         * lib/c32isdigit.c: Likewise.
13598         * lib/c32isgraph.c: Likewise.
13599         * lib/c32islower.c: Likewise.
13600         * lib/c32isprint.c: Likewise.
13601         * lib/c32ispunct.c: Likewise.
13602         * lib/c32isspace.c: Likewise.
13603         * lib/c32isupper.c: Likewise.
13604         * lib/c32isxdigit.c: Likewise.
13605         * lib/c32is-impl.h: Likewise.
13607         unictype/ctype-*: Relax license.
13608         * lib/gen-uni-tables.c (output_predicate): Bump copyright year. For
13609         unictype/ctype_*, use the LGPLv2+.
13610         * lib/unictype/ctype_*.h: Regenerated.
13611         * lib/unictype/ctype_*.c: Update license notice.
13612         * modules/unictype/ctype-alnum (License): Change to LGPLv2+.
13613         * modules/unictype/ctype-alpha (License): Likewise.
13614         * modules/unictype/ctype-blank (License): Likewise.
13615         * modules/unictype/ctype-cntrl (License): Likewise.
13616         * modules/unictype/ctype-digit (License): Likewise.
13617         * modules/unictype/ctype-graph (License): Likewise.
13618         * modules/unictype/ctype-lower (License): Likewise.
13619         * modules/unictype/ctype-print (License): Likewise.
13620         * modules/unictype/ctype-punct (License): Likewise.
13621         * modules/unictype/ctype-space (License): Likewise.
13622         * modules/unictype/ctype-upper (License): Likewise.
13623         * modules/unictype/ctype-xdigit (License): Likewise.
13625 2023-05-04  Bruno Haible  <bruno@clisp.org>
13627         c32width: Add tests.
13628         * tests/test-c32width.c: New file, based on tests/test-wcwidth.c.
13629         * modules/c32width-tests: New file.
13631         c32width: New module.
13632         * lib/uchar.in.h (c32width): New declaration.
13633         * lib/c32width.c: New file, based on lib/c32is-impl.h.
13634         * modules/c32width: New file.
13635         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
13636         GNULIB_C32WIDTH.
13637         * modules/uchar (Makefile.am): Substitute GNULIB_C32WIDTH.
13639 2023-05-04  Bruno Haible  <bruno@clisp.org>
13641         doc: Mention macOS wcwidth bug.
13642         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Mention macOS bugs.
13643         * doc/posix-functions/wcwidth.texi: Update regarding macOS.
13645 2023-05-03  Bruno Haible  <bruno@clisp.org>
13647         vasnprintf, vasnwprintf: Make '0' flag handling more ISO C compliant.
13648         * lib/vasnprintf.c (VASNPRINTF): When doing the padding ourselves,
13649         ignore the '0' flag if a precision is specified and the conversion is
13650         one of d, i, o, u, x, X, b, B.
13651         * tests/test-vasnprintf-posix.c (test_function): Update expected results
13652         accordingly.
13653         * tests/test-vasprintf-posix.c (test_function): Likewise.
13654         * tests/test-snprintf-posix.h (test_function): Likewise.
13655         * tests/test-sprintf-posix.h (test_function): Likewise.
13656         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
13658 2023-05-02  Paul Eggert  <eggert@cs.ucla.edu>
13660         mktime: include <intprops.h>
13661         * lib/mktime.c: Include <intprops.h> again,
13662         fixing a typo noted by Bruno Haible in:
13663         https://lists.gnu.org/r/bug-gnulib/2023-05/msg00014.html
13665 2023-05-02  Bruno Haible  <bruno@clisp.org>
13667         fopen: Silence a gcc warning.
13668         * lib/fopen.c (rpl_fopen): Mark open_direction as used.
13670 2023-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13672         extern-inline: port to pcc
13673         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Port to pcc
13674         1.2.0.DEVEL 20220331, which doesn’t support extern inline
13675         even though it claims to be GCC 4.3 and to support C11.
13677         regex: prefer C23 style overflow checking
13678         * lib/regex_internal.h: Include stdckdint.h.
13679         * lib/regexec.c (re_search_2_stub):
13680         * modules/regex (Depends-on): Add stdckdint.
13681         Prefer stdckdint.h to intprops.h macros.
13683         dynarray: prefer C23 style overflow checking
13684         * lib/malloc/dynarray_emplace_enlarge.c, lib/malloc/dynarray_resize.c:
13685         Include stdckdint.h, not intprops.h.
13686         * lib/malloc/dynarray_emplace_enlarge.c:
13687         (__libc_dynarray_emplace_enlarge):
13688         * lib/malloc/dynarray_resize.c (__libc_dynarray_resize):
13689         Prefer stdckdint.h to intprops.h macros.
13690         * modules/glibc-internal/dynarray (Depends-on):
13691         Depend on stdckdint, not intprops.
13693         mktime: prefer C23 style overflow checking
13694         Prefer stdckdint.h macros to intprops.h macros where either will do,
13695         as this is the C23 standard.  Also, it ports around a pcc bug.
13696         * config/srclist.txt: Comment out mktime.c.
13697         * lib/mktime.c: Include stdckdint.h, not intprops.h.
13698         (__mktime_internal): Prefer stdckdint.h to intprops.h macros.
13699         * modules/mktime (Depends-on): Add stdckdint.
13701         limits-h: port to pcc
13702         * doc/posix-headers/limits.texi: Document the issue.
13703         * lib/limits.in.h (MB_LEN_MAX): New macro, if not already defined.
13704         * m4/limits-h.m4 (gl_LIMITS_H): Test for MB_LEN_MAX.
13705         * tests/test-limits-h.c: Check that it’s positive.
13707 2023-04-28  Paul Eggert  <eggert@cs.ucla.edu>
13709         year2038-recommended: new module
13710         Remove year2038-required and largefile-required, replacing
13711         the former with year2038-recommended and simply removing
13712         the latter.  This syncs with Autoconf master.
13713         * MODULES.html.sh, NEWS, doc/largefile.texi:
13714         * all-modules (exclude): Exclude year2038-recommended, not -required.
13715         * doc/posix-headers/sys_types.texi, doc/posix-headers/time.texi:
13716         * doc/year2038.texi: Mention this.
13717         * m4/largefile.m4: Sync from Autoconf.  Override existing macros
13718         if AC_SYS_YEAR2038_RECOMMENDED is not defined, rather than if
13719         AC_SYS_LARGEFILE_REQUIRED is not defined.
13720         * modules/largefile-required, modules/year2038-required: Removed.
13721         * modules/year2038: Do not depend on largefile; simply
13722         use m4/largefile.m4, since we shouldn’t need the extra goodies
13723         largefile supplies.
13724         * modules/year2038-recommended: New module.
13726 2023-04-28  Bruno Haible  <bruno@clisp.org>
13728         stdio: Avoid different configure results in different testdirs.
13729         * m4/stdio_h.m4 (gl_STDIO_H_EARLY): New macro, extracted from
13730         gl_STDIO_H.
13731         (gl_STDIO_H): Move the code that sets __USE_MINGW_ANSI_STDIO to
13732         gl_STDIO_H_EARLY.
13733         * modules/stdio (configure.ac-early): New section.
13735 2023-04-28  Bruno Haible  <bruno@clisp.org>
13737         stdbool tests: Avoid compilation error with Sun C on Solaris 10.
13738         * tests/test-stdbool.c (WORKING_BOOL): Set to 0 on Sun C.
13740 2023-04-28  Bruno Haible  <bruno@clisp.org>
13742         hamt tests: Fix test failure with Sun C on Solaris 10/SPARC.
13743         * tests/test-hamt.c (main): Finish with exit code 0.
13745 2023-04-27  Bruno Haible  <bruno@clisp.org>
13747         localeconv: Work around a mingw bug.
13748         * m4/localeconv.m4 (gl_FUNC_LOCALECONV): Test whether fields of type
13749         'char' are filled correctly.
13750         (gl_PREREQ_LOCALECONV): Test whether 'struct lconv' has the int_{p,n}_*
13751         members.
13752         * lib/localeconv.c (FIX_CHAR_VALUE): New macro.
13753         (localeconv): Replace negative field values with CHAR_MAX.
13754         * doc/posix-functions/localeconv.texi: Mention the mingw bug.
13756 2023-04-27  Bruno Haible  <bruno@clisp.org>
13758         stdlib: Fix error when cross-compiling (regression 2023-04-04).
13759         Reported by Pierre Labastie <pierre.labastie@neuf.fr> in
13760         <https://lists.gnu.org/archive/html/bug-gnulib/2023-04/msg00220.html>.
13761         * m4/stdlib_h.m4 (gl_STDLIB_H): Provide a 4th argument to AC_RUN_IFELSE.
13763 2023-04-26  Paul Eggert  <eggert@cs.ucla.edu>
13765         freopen-safer: pacify GCC 13
13766         * lib/freopen-safer.c: Ignore -Wanalyzer-fd-leak.
13768 2023-04-26  Bruno Haible  <bruno@clisp.org>
13770         fdopendir: Fix fd leak and test failure on native Windows.
13771         --
13772         * lib/dirent-private.h: On mingw, define 'struct gl_directory' as a
13773         wrapper around the original DIR. On MSVC, add an 'fd_to_close' field to
13774         'struct gl_directory'.
13775         * lib/dirent.in.h (DIR): Define when DIR_HAS_FD_MEMBER is 0, i.e. on
13776         both mingw and MSVC.
13777         (GNULIB_defined_DIR): New macro.
13778         (opendir): Avoid incompatible redeclaration.
13779         (readdir): Consider REPLACE_READDIR.
13780         (rewinddir): Consider REPLACE_REWINDDIR.
13781         * m4/dirent_h.m4 (gl_DIRENT_DIR): New macro.
13782         (gl_DIRENT_H): Invoke it.
13783         (gl_DIRENT_H_DEFAULTS): Initialize REPLACE_READDIR, REPLACE_REWINDDIR.
13784         * modules/dirent (Makefile.am): Substitute DIR_HAS_FD_MEMBER,
13785         REPLACE_READDIR, REPLACE_REWINDDIR.
13786         --
13787         * lib/dirfd.c (dirfd): If GNULIB_defined_DIR, just use the
13788         'fd_to_close' field.
13789         * m4/dirfd.m4 (gl_FUNC_DIRFD): Set HAVE_DIRFD. Don't set REPLACE_DIRFD
13790         to 1 if HAVE_DIRFD is 0. If DIR_HAS_FD_MEMBER is 0, ensure dirfd.c gets
13791         compiled.
13792         * modules/dirfd (Files): Add lib/dirent-private.h.
13793         (Depends-on, configure.ac): Simplify conditions.
13794         --
13795         * lib/closedir.c: Include <stdlib.h> always, for free().
13796         (closedir): If GNULIB_defined_DIR, arrange to call close(dirfd(dirp)) at
13797         the end. On mingw, call free() of dirp. Prefer testing HAVE_DIRENT_H,
13798         for consistency with dirent.h.
13799         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Don't set REPLACE_CLOSEDIR to 1 if
13800         HAVE_CLOSEDIR is 0. If DIR_HAS_FD_MEMBER is 0, ensure closedir.c gets
13801         compiled.
13802         --
13803         * lib/opendir.c: Include <stdlib.h> always. Include <string.h>.
13804         (opendir): On mingw, allocate the 'struct gl_directory' through malloc.
13805         If GNULIB_defined_DIR, set the 'fd_to_close' field to -1. Prefer
13806         testing HAVE_DIRENT_H, for consistency with dirent.h.
13807         * m4/opendir.m4 (gl_FUNC_OPENDIR): Don't set REPLACE_OPENDIR to 1 if
13808         HAVE_OPENDIR is 0. If DIR_HAS_FD_MEMBER is 0, ensure opendir.c gets
13809         compiled.
13810         --
13811         * lib/fdopendir.c (fdopendir): If GNULIB_defined_DIR, use a simple
13812         implementation based on opendir and the fchdir module. If __KLIBC__,
13813         don't define unused auxiliary functions.
13814         * modules/fdopendir (Files): Add lib/dirent-private.h.
13815         --
13816         * lib/readdir.c (readdir): On mingw, redirect to the original readdir
13817         function. Prefer testing HAVE_DIRENT_H, for consistency with dirent.h.
13818         * m4/readdir.m4 (gl_FUNC_READDIR): If DIR_HAS_FD_MEMBER is 0, ensure
13819         readdir.c gets compiled.
13820         * modules/readdir (configure.ac): Consider REPLACE_READDIR.
13821         --
13822         * lib/rewinddir.c (rewinddir): On mingw, redirect to the original
13823         rewinddir function. Prefer testing HAVE_DIRENT_H, for consistency with
13824         dirent.h.
13825         * m4/rewinddir.m4 (gl_FUNC_REWINDDIR): If DIR_HAS_FD_MEMBER is 0, ensure
13826         rewinddir.c gets compiled.
13827         * modules/rewinddir (configure.ac): Consider REPLACE_REWINDDIR.
13828         --
13829         * lib/fchdir.c (dir_info_t): Remove a FIXME.
13831 2023-04-26  Bruno Haible  <bruno@clisp.org>
13833         fchdir tests: Fix test failure on native Windows.
13834         * modules/fchdir-tests (Depends-on): Add dup.
13836 2023-04-26  Bruno Haible  <bruno@clisp.org>
13838         fclose: Make last change more maintainable.
13839         * m4/fclose.m4 (gl_FUNC_FCLOSE): Define through AC_DEFUN_ONCE. Don't
13840         modify REPLACE_FOPEN.
13841         * modules/fclose (Depends-on): Add comment.
13842         (configure.ac): Don't modify REPLACE_FOPEN. Don't duplicate actions of
13843         module 'fopen'.
13844         * m4/fopen.m4 (gl_FUNC_FOPEN_ITSELF): Renamed from gl_FUNC_FOPEN.
13845         (gl_FUNC_FOPEN): New macro.
13846         * modules/fopen (Files): Add m4/fclose.m4, m4/fflush.m4.
13847         * m4/close.m4 (gl_FUNC_CLOSE): Define through AC_DEFUN_ONCE.
13849 2023-04-26  Po Lu  <luangruo@yahoo.com>  (tiny change)
13850             Bruno Haible  <bruno@clisp.org>
13852         gnulib-tool: For conditional dependencies, generate portable sh code.
13853         * gnulib-tool (func_emit_autoconf_snippets): Avoid sh syntax
13854         'if ! variable', that does not work with Solaris /bin/sh.
13855         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Likewise.
13857 2023-04-25  Bruno Haible  <bruno@clisp.org>
13859         expm1 tests: Avoid test failure on 32-bit mingw.
13860         * tests/test-expm1.h (test_function): Mark y as 'volatile'.
13862 2023-04-25  Bruno Haible  <bruno@clisp.org>
13864         poll tests: Avoid test failure on native Windows.
13865         * tests/test-poll.c (test_pipe): Disable the POLLHUP check also on
13866         native Windows.
13867         * doc/posix-functions/poll.texi: Mention also native Windows w.r.t.
13868         POLLHUP.
13870 2023-04-25  Bruno Haible  <bruno@clisp.org>
13872         dfa tests: Fix compilation error (regression 2023-04-22).
13873         * tests/test-dfa-match-aux.c: Include unistd.h.
13874         * modules/dfa-tests (Depends-on): Add unistd.
13876 2023-04-24  Bruno Haible  <bruno@clisp.org>
13878         tests: Suppress ‘#pragma GCC diagnostic’ warnings with GCC < 13.
13879         * tests/test-localename.c: Disable #pragma for GCC < 12.
13880         * tests/test-dup2.c: Disable #pragma for GCC < 13.
13881         * tests/test-fcntl.c: Likewise.
13882         * tests/test-getdtablesize.c: Likewise.
13883         * tests/test-listen.c: Likewise.
13884         * tests/test-open.h: Likewise.
13885         * tests/test-perror2.c: Likewise.
13886         * tests/test-select.h: Likewise.
13888 2023-04-24  Bruno Haible  <bruno@clisp.org>
13890         select, pselect: Fix test failure on native Windows.
13891         * lib/select.c (rpl_select): Fail if nfds is out-of-range.
13892         * lib/pselect.c (pselect): Likewise.
13894 2023-04-24  Paul Eggert  <eggert@cs.ucla.edu>
13896         fclose: pacify gcc -Wanalyzer-file-leak
13897         Without this patch, building coreutils with
13898         --enable-gcc-checking=expensive would fail with a message like
13899         “lib/exclude.c:682:6: error: leak of FILE 'in' [CWE-775]
13900         [-Werror=analyzer-file-leak]”, because Gnulib replaced fclose but
13901         not fopen, and GCC saw a call to fopen followed by a call to
13902         rpl_fclose.  The patch causes GCC to instead see a call to
13903         rpl_fopen followed by rpl_fclose.
13904         * m4/fclose.m4 (gl_FUNC_FCLOSE): Replace fopen when replacing
13905         fclose.
13906         * modules/fclose (Depends-on): Add fopen.
13907         (configure.ac): Replace fopen when replacing fclose.
13909         unsetenv-tests: pacify -Wanalyzer-putenv-of-auto-var
13910         * tests/test-unsetenv.c (main): Make entry static.  Even with this
13911         change, it’s unclear whether this test is portable POSIX code, but
13912         that’s a different matter.
13914         tests: suppress some unwanted -fanalyzer checking
13915         * tests/test-dup2.c, tests/test-fcntl.c, tests/test-fopen.h:
13916         * tests/test-getdtablesize.c, tests/test-listen.c:
13917         * tests/test-localename.c, tests/test-open.h, tests/test-perror2.c:
13918         * tests/test-select.h:
13919         Add pragmas to disable unwanted -fanalyzer checking.
13921 2023-04-24  Bruno Haible  <bruno@clisp.org>
13923         ftell, ftello: Fix recognition of pipes on native Windows.
13924         * m4/lseek.m4 (gl_FUNC_LSEEK): Update comment.
13925         * m4/ftello.m4 (gl_FUNC_FTELLO): On native Windows, set REPLACE_FTELLO=1
13926         always.
13927         * doc/posix-functions/ftello.texi: Mention the behaviour on pipes.
13928         * doc/posix-functions/ftell.texi: Likewise.
13929         * doc/posix-functions/fgetpos.texi: Likewise.
13931 2023-04-24  Bruno Haible  <bruno@clisp.org>
13933         lseek: Fix module dependencies (regression 2021-11-15).
13934         * modules/lseek (Depends-on): Re-enable the msvc-nothrow dependency
13935         also when WINDOWS_64_BIT_OFF_T is 0.
13937 2023-04-24  Bruno Haible  <bruno@clisp.org>
13939         system-quote: Fix memory overrun bug on native Windows.
13940         * lib/system-quote.c (system_quote): Allocate enough space for the
13941         result.
13943 2023-04-24  Bruno Haible  <bruno@clisp.org>
13945         unicodeio tests: Avoid test failures on native Windows.
13946         * tests/test-unicodeio.c: Include localcharset.h.
13947         (main): Handle C locales whose encoding is CP1252 or similar.
13948         * modules/unicodeio-tests (Depends-on): Add localcharset.
13950 2023-04-24  Bruno Haible  <bruno@clisp.org>
13952         *sprintf tests: Avoid test failures on mingw 10.
13953         * tests/test-vasnprintf-posix.c (test_function): On newer mingw, expect
13954         the de-facto standard result.
13955         * tests/test-vasprintf-posix.c (test_function): Likewise.
13956         * tests/test-snprintf-posix.h (test_function): Likewise.
13957         * tests/test-sprintf-posix.h (test_function): Likewise.
13959 2023-04-23  Bruno Haible  <bruno@clisp.org>
13961         Improve quoting of AS_HELP_STRING's first argument.
13962         * m4/acl.m4 (gl_FUNC_ACL_ARG): Don't underquote AS_HELP_STRING's first
13963         argument.
13964         * m4/assert.m4 (gl_ASSERT): Likewise.
13965         * m4/gc.m4 (gl_GC): Likewise.
13966         * m4/gnulib-common.m4 (gl_COMMON_BODY): Likewise.
13967         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT): Likewise.
13968         * m4/lib-ld.m4 (AC_LIB_PROG_LD): Likewise.
13969         * m4/libgmp.m4 (gl_LIBGMP): Likewise.
13970         * m4/regex.m4 (gl_REGEX): Likewise.
13971         * m4/relocatable-lib.m4 (gl_RELOCATABLE_NOP): Likewise.
13972         * m4/selinux-selinux-h.m4 (gl_LIBSELINUX): Likewise.
13973         * m4/sigsegv.m4 (gl_SIGSEGV): Likewise.
13974         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Likewise.
13975         * m4/valgrind-tests.m4 (gl_VALGRIND_TESTS): Likewise.
13976         * m4/version-etc.m4 (gl_VERSION_ETC_FLAG): Likewise.
13977         * m4/xattr.m4 (gl_FUNC_XATTR): Likewise.
13978         * doc/manywarnings.texi (manywarnings): Likewise. This avoids the use of
13979         quadrigraphs.
13981 2023-04-23  Bruno Haible  <bruno@clisp.org>
13983         category-none: Fix link errors on MSVC, when libunistring is installed.
13984         * modules/unictype/category-none (configure.ac): Remove
13985         gl_LIBUNISTRING_MODULE invocation.
13986         (Makefile.am): Compile unictype/categ_none.c always.
13988 2023-04-23  Paul Eggert  <eggert@cs.ucla.edu>
13990         manywarnings: use AS_IF
13991         * m4/manywarnings.m4 (gl_MANYWARN_COMPLEMENT):
13992         Use AS_IF when the body contains Autoconf macros that could
13993         conceivably require something.
13995         manywarnings: update C warnings for GCC 13
13996         Adjust for C programs compiled by GCC 13.
13997         (A C++ expert still needs to look at manywarnings-c++.m4.)
13998         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 13.
13999         * doc/manywarnings.texi (manywarnings): Document flex arrays.
14000         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add
14001         -fstrict-flex-arrays and -Wstrict-flex-arrays as these should be
14002         suitable for Gnulib-using code.
14004         manywarnings: bring doc up to date
14005         * doc/manywarnings.texi: Bring doc up to date for GCC 12.
14007         manywarnings: omit -fno-common in GCC 10+
14008         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Omit -fno-common
14009         in GCC 10 and later, as it is the default there.
14010         Check exit status of ‘gcc --version’.
14012 2023-04-23  Bruno Haible  <bruno@clisp.org>
14014         libunistring: Fix build on Windows, when a libunistring is installed.
14015         * lib/unicase.in.h: Include <unistring/woe32dll.h>.
14016         (unicase_empty_prefix_context, unicase_empty_suffix_context): Declare
14017         with GNULIB_UNICASE_..._DLL_VARIABLE.
14018         * lib/unictype.in.h: Include <unistring/woe32dll.h>.
14019         (UC_CATEGORY_*, UC_PROPERTY_*): Declare with
14020         GNULIB_UNICTYPE_..._DLL_VARIABLE.
14021         * lib/uninorm.in.h: Include <unistring/woe32dll.h>.
14022         (unicode_normalization_form uninorm_nf*): Declare with
14023         GNULIB_UNINORM_..._DLL_VARIABLE.
14024         * m4/libunistring-base.m4 (gl_LIBUNISTRING_MODULE_WITH_VARIABLE): New
14025         macro.
14026         (gl_LIBUNISTRING_LIB_PREPARE): Set HAVE_UNISTRING_WOE32DLL_H.
14027         * m4/unicase_h.m4: New file.
14028         * m4/unictype_h.m4: New file.
14029         * m4/uninorm_h.m4: New file.
14030         * modules/unicase/base (Files): Add m4/unicase_h.m4.
14031         (configure.ac): Bump version number. Invoke gl_UNICASE_H,
14032         gl_UNICASE_H_REQUIRE_DEFAULTS.
14033         (Makefile.am): Substitute all GNULIB_UNICASE_*_DLL_VARIABLE.
14034         * modules/unicase/empty-*-context (configure.ac): Invoke
14035         gl_UNICASE_H_REQUIRE_DEFAULTS. Use gl_LIBUNISTRING_MODULE_WITH_VARIABLE.
14036         * modules/unictype/base (Files): Add m4/unictype_h.m4.
14037         (configure.ac): Bump version number. Invoke gl_UNICTYPE_H,
14038         gl_UNICTYPE_H_REQUIRE_DEFAULTS.
14039         (Makefile.am): Substitute all GNULIB_UNICTYPE_*_DLL_VARIABLE.
14040         * modules/unictype/category-* (configure.ac): Invoke
14041         gl_UNICTYPE_H_REQUIRE_DEFAULTS. Use
14042         gl_LIBUNISTRING_MODULE_WITH_VARIABLE.
14043         * modules/unictype/property-* (configure.ac): Likewise.
14044         * modules/uninorm/base (Files): Add m4/uninorm_h.m4.
14045         (configure.ac): Bump version number. Invoke gl_UNINORM_H,
14046         gl_UNINORM_H_REQUIRE_DEFAULTS.
14047         (Makefile.am): Substitute all GNULIB_UNINORM_*_DLL_VARIABLE.
14048         * modules/uninorm/nf* (configure.ac): Invoke
14049         gl_UNINORM_H_REQUIRE_DEFAULTS. Use gl_LIBUNISTRING_MODULE_WITH_VARIABLE.
14051 2023-04-22  Bruno Haible  <bruno@clisp.org>
14053         Avoid some Autoconf "was expanded before it was required" warnings.
14054         * m4/locale-ar.m4 (gt_LOCALE_AR): Define through AC_DEFUN_ONCE.
14055         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
14056         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
14057         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
14058         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
14060 2023-04-22  Bruno Haible  <bruno@clisp.org>
14062         string-desc tests: Avoid test failure on native Windows.
14063         * tests/test-string-desc.c: Include <fcntl.h>, <unistd.h>.
14064         (main): Expect a file name argument. Write to this file, instead of to
14065         fd 3.
14066         * tests/test-string-desc.sh: Pass a file name as argument, instead of
14067         using '3>'.
14068         * modules/string-desc-tests (Depends-on): Add close.
14070 2023-04-22  Bruno Haible  <bruno@clisp.org>
14072         threadlib, pthread-h, threads-h: Avoid mingw's libwinpthread by default.
14073         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Set
14074         gl_use_winpthreads_default to 'no' by default.
14075         (gl_AVOID_WINPTHREAD): Update comments.
14077 2023-04-22  Bruno Haible  <bruno@clisp.org>
14079         posixtm tests: Avoid test failure on native Windows.
14080         * tests/test-posixtm.c (T): On native Windows, disable test cases that
14081         would fail.
14083 2023-04-22  Bruno Haible  <bruno@clisp.org>
14085         dfa tests: Fix test failure on mingw differently.
14086         Suggested by Paul Eggert.
14087         * tests/test-dfa-invalid-char-class.sh: Revert last change.
14088         * tests/test-dfa-match-aux.c: Include binary-io.h.
14089         (main): Put stdout into binary mode.
14090         * modules/dfa-tests (Depends-on): Add binary-io.
14092 2023-04-20  Bruno Haible  <bruno@clisp.org>
14094         getumask: Make it work on native Windows.
14095         * lib/getumask.c (getumask): When TMPDIR is unset, try TMP and TEMP.
14096         * tests/test-getumask.c (ASSUME_UMASK_CONSTANT): Define to 1 on native
14097         Windows.
14099 2023-04-20  Bruno Haible  <bruno@clisp.org>
14101         posixtm tests: Fix link error.
14102         * modules/posixtm-tests (Depends-on): Add stpcpy.
14104 2023-04-20  Bruno Haible  <bruno@clisp.org>
14106         readtokens tests: Fix test failure on mingw.
14107         * tests/test-readtokens.sh: Transform CRLF to LF in the output, before
14108         comparing with the expected output.
14110         parse-duration tests: Fix test failure on mingw.
14111         * tests/test-parse-duration.sh: Transform CRLF to LF in the output,
14112         before analyzing the output.
14114         dfa tests: Fix test failure on mingw.
14115         * tests/test-dfa-invalid-char-class.sh: Transform CRLF to LF in the
14116         output, before comparing with the expected output.
14118 2023-04-20  Bruno Haible  <bruno@clisp.org>
14120         Fix uses of libwinpthread on mingw 10.
14121         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): On mingw, set the result to
14122         "guessing no".
14124 2023-04-20  Bruno Haible  <bruno@clisp.org>
14126         Move remaining call_once tests from mtx-tests to call_once-tests.
14127         * tests/test-call_once1.c: Renamed from tests/test-call_once.c.
14128         * tests/test-call_once2.c: New file, based on tests/test-mtx.c.
14129         * tests/test-mtx.c: Remove the code that was testing call_once.
14130         * modules/call_once-tests (Files): Add test-call_once1.c,
14131         test-call_once2.c. Remove test-call_once.c.
14132         (Depends-on): Add thrd, lock, stdint.
14133         (configure.ac): Check for alarm.
14134         (Makefile.am): Test test-call_once1 instead of test-call_once. Also test
14135         test-call_once2.
14137 2023-04-20  Bruno Haible  <bruno@clisp.org>
14139         execute tests: Fix compilation error on mingw (regression 2023-01-17).
14140         * tests/test-execute-main.c (main): Don't use SIGPIPE if it's not
14141         defined.
14143 2023-04-20  Bruno Haible  <bruno@clisp.org>
14145         assert-h, verify: Fix compilation error in C++ mode with MSVC 14.30.
14146         * lib/verify.h (_Static_assert): In C++ mode with MSVC 14.1 or newer,
14147         define merely to static_assert.
14148         (static_assert): In C++ mode with MSVC 14.1 or newer, don't define.
14150 2023-04-19  Bruno Haible  <bruno@clisp.org>
14152         chown, lchown tests: Fix link error on mingw 10.
14153         * modules/chown-tests (configure.ac): Test whether getgid() exists.
14154         * modules/lchown-tests (configure.ac): Likewise.
14155         * modules/fchownat-tests (configure.ac): Likewise.
14156         * tests/test-chown.h (getgid): Define a fallback.
14157         * tests/test-lchown.h (getgid): Likewise.
14159 2023-04-19  Bruno Haible  <bruno@clisp.org>
14161         ctime: Fix compilation errors in C++ mode on mingw 10.
14162         * lib/c++defs.h (_GL_FUNCDECL_RPL): Add a comment.
14163         * lib/time.in.h (ctime): Don't use _GL_ATTRIBUTE_DEPRECATED before
14164         _GL_FUNCDECL_RPL in C++ mode.
14166 2023-04-19  Bruno Haible  <bruno@clisp.org>
14168         random: Fix compilation errors in C++ mode on mingw 10.
14169         * lib/stdlib.in.h (random, srandom): Disable _GL_CXXALIASWARN invocation
14170         on non-glibc systems.
14172 2023-04-19  Bruno Haible  <bruno@clisp.org>
14174         year2038-required: Fix configure failure with MSVC.
14175         * m4/largefile.m4 (_AC_SYS_LARGEFILE_PROBE): Distinguish the results
14176         "support not detected" and "supported through gnulib". If the result is
14177         "supported through gnulib", don't fail.
14179 2023-04-19  Bruno Haible  <bruno@clisp.org>
14181         doc: Add references to changes accepted for future POSIX revisions.
14182         * doc/glibc-functions/bind_textdomain_codeset.texi: Add reference to
14183         www.austingroupbugs.net issue.
14184         * doc/glibc-functions/bindtextdomain.texi: Likewise.
14185         * doc/glibc-functions/dcgettext.texi: Likewise.
14186         * doc/glibc-functions/dcngettext.texi: Likewise.
14187         * doc/glibc-functions/dgettext.texi: Likewise.
14188         * doc/glibc-functions/dngettext.texi: Likewise.
14189         * doc/glibc-functions/getentropy.texi: Likewise.
14190         * doc/glibc-functions/getresgid.texi: Likewise.
14191         * doc/glibc-functions/getresuid.texi: Likewise.
14192         * doc/glibc-functions/gettext.texi: Likewise.
14193         * doc/glibc-functions/ngettext.texi: Likewise.
14194         * doc/glibc-functions/posix_spawn_file_actions_addchdir_np.texi:
14195         Likewise.
14196         * doc/glibc-functions/posix_spawn_file_actions_addfchdir_np.texi:
14197         Likewise.
14198         * doc/glibc-functions/setresgid.texi: Likewise.
14199         * doc/glibc-functions/setresuid.texi: Likewise.
14200         * doc/glibc-functions/textdomain.texi: Likewise.
14201         * doc/posix-functions/asctime_r.texi: Likewise.
14202         * doc/posix-functions/ctime_r.texi: Likewise.
14204 2023-04-19  Bruno Haible  <bruno@clisp.org>
14206         wcsncmp: Add tests.
14207         * tests/test-wcsncmp.c: New file, based on tests/unistr/test-strncmp.h
14208         and tests/test-wcscmp.c.
14209         * modules/wcsncmp-tests: New file.
14211         wcsncmp: Work around two ISO C compliance bugs on several platforms.
14212         * lib/wchar.in.h (wcsncmp): Consider REPLACE_WCSNCMP.
14213         * lib/wcsncmp-impl.h (wcsncmp): Don't assume that the two wide
14214         characters are in the range 0..INT_MAX.
14215         * m4/wcsncmp.m4 (gl_FUNC_WCSNCMP): Test whether wcsncmp works for all
14216         wide characters. Set REPLACE_WCSNCMP.
14217         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSNCMP.
14218         * modules/wchar (Makefile.am): Substitute REPLACE_WCSNCMP.
14219         * modules/wcsncmp (Status, Notice): Un-obsolete this module.
14220         (configure.ac): Consider REPLACE_WCSNCMP.
14221         * doc/posix-functions/wcsncmp.texi: Mention the two bugs.
14223 2023-04-18  Bruno Haible  <bruno@clisp.org>
14225         wcscmp: Add tests.
14226         * tests/test-wcscmp.c: New file, based on tests/unistr/test-strcmp.h.
14227         * modules/wcscmp-tests: New file.
14229         wcscmp: Work around two ISO C compliance bugs on several platforms.
14230         * lib/wchar.in.h (wcscmp): Consider REPLACE_WCSCMP.
14231         * lib/wcscmp-impl.h (wcscmp): Don't assume that the two wide characters
14232         are in the range 0..INT_MAX.
14233         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Test whether wcscmp works for all wide
14234         characters. Set REPLACE_WCSCMP.
14235         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSCMP.
14236         * modules/wchar (Makefile.am): Substitute REPLACE_WCSCMP.
14237         * modules/wcscmp (Status, Notice): Un-obsolete this module.
14238         (configure.ac): Consider REPLACE_WCSCMP.
14239         * doc/posix-functions/wcscmp.texi: Mention the two bugs.
14241 2023-04-18  Bruno Haible  <bruno@clisp.org>
14243         wmemcmp: Add tests.
14244         * tests/test-wmemcmp.c: New file, based on tests/unistr/test-cmp.h.
14245         * modules/wmemcmp-tests: New file.
14247         wmemcmp: Work around ISO C compliance bug on several platforms.
14248         * lib/wchar.in.h (wmemcmp): Consider REPLACE_WMEMCMP.
14249         * lib/wmemcmp-impl.h (wmemcmp): Don't assume that the two wide
14250         characters are in the range 0..INT_MAX.
14251         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Test whether wmemcmp works for all
14252         wide characters. Set REPLACE_WMEMCMP.
14253         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WMEMCMP.
14254         * modules/wchar (Makefile.am): Substitute REPLACE_WMEMCMP.
14255         * modules/wmemcmp (configure.ac): Consider REPLACE_WMEMCMP.
14256         * doc/posix-functions/wmemcmp.texi: Mention the bug.
14258 2023-04-18  Bruno Haible  <bruno@clisp.org>
14260         doc: Update platform list for posix_spawnp.
14261         * doc/posix-functions/posix_spawnp.texi: Update platform list.
14263 2023-04-18  Paul Eggert  <eggert@cs.ucla.edu>
14265         Go back to dynamic largefile, year2038 tests
14266         Problem reported by Bruno Haible in:
14267         https://lists.gnu.org/r/bug-gnulib/2023-04/msg00134.html
14268         * modules/largefile-tests, modules/year2038-tests (Depends-on):
14269         Remove assert-h.
14270         * tests/test-largefile.c, tests/test-year2038.c:
14271         Test dynamically, not via static_assert.
14273         doc: mention when O_* defaults to 0
14274         * doc/posix-headers/fcntl.texi: Document in more detail which O_*
14275         macros default to 0 in Gnulib.
14277 2023-04-18  Bruno Haible  <bruno@clisp.org>
14279         doc: Mention a Cygwin 3.4.6 bug.
14280         * doc/posix-functions/readlinkat.texi: Mention a readlinkat bug on
14281         Cygwin < 3.4.7.
14283 2023-04-18  Bruno Haible  <bruno@clisp.org>
14285         ilogbl: Work around a Cygwin 3.4.6 bug.
14286         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Also test the value of
14287         ilogbl(NaN).
14288         * doc/posix-functions/ilogbl.texi: Mention the new Cygwin bug.
14290 2023-04-18  Bruno Haible  <bruno@clisp.org>
14292         file-has-acl tests: Avoid test failures on Cygwin 3.4.6.
14293         * tests/test-file-has-acl.sh: Fix distinction between Linux setfacl and
14294         Cygwin setfacl.
14296 2023-04-18  Bruno Haible  <bruno@clisp.org>
14298         c32isgraph tests: Avoid test failure on Cygwin 3.4.6.
14299         * tests/test-c32isgraph.c (main): Skip U+00A0 test on Cygwin.
14301 2023-04-17  Paul Eggert  <eggert@cs.ucla.edu>
14303         Slightly nicer largefile, year2038 tests
14304         * modules/largefile-tests, modules/year2038-tests (Depends-on):
14305         Add assert-h, intprops.
14306         * tests/test-largefile.c, tests/test-year2038.c:
14307         Prefer compile-time to run-time tests.
14308         Don’t assume CHAR_BIT == 8.
14310 2023-04-17  Bruno Haible  <bruno@clisp.org>
14312         MODULES.html.sh: Ensure hyperlinked files are displayable.
14313         * MODULES.html.sh (repo_url_prefix): Use cgit instead of gitweb.
14315         MODULES.html.sh: Avoid a HTTP redirect.
14316         * MODULES.html.sh (repo_url_prefix): Use the unabbreviated name of the
14317         git repository server.
14319 2023-04-16  Bruno Haible  <bruno@clisp.org>
14321         year2038: Add tests.
14322         * tests/test-year2038.c: New file.
14323         * modules/year2038-tests: New file.
14325 2023-04-16  Bruno Haible  <bruno@clisp.org>
14327         largefile: Add tests.
14328         * tests/test-largefile.c: New file.
14329         * modules/largefile-tests: New file.
14331 2023-04-16  Bruno Haible  <bruno@clisp.org>
14333         year2038: Revert the added module dependencies.
14334         Suggested by Paul Eggert in
14335         <https://lists.gnu.org/archive/html/bug-gnulib/2023-04/msg00117.html>.
14336         * modules/year2038 (Depends-on): Remove sched, sys_msg, sys_select,
14337         sys_sem, sys_shm, sys_stat, sys_time, sys_types, time-h, utime-h.
14339 2023-04-16  Bruno Haible  <bruno@clisp.org>
14341         posix_spawn_file_actions_addclose tests: Avoid test failure on Cygwin.
14342         * tests/test-posix_spawn_file_actions_addclose.c (main): Skip an
14343         unportable test also on Cygwin.
14345 2023-04-15  Bruno Haible  <bruno@clisp.org>
14347         Fix compilation errors of list, set, oset, map, omap in C++ mode.
14348         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define
14349         _GL_BRACKET_BEFORE_ATTRIBUTE. In _GL_ATTRIBUTE_DEPRECATED,
14350         _GL_ATTRIBUTE_MAYBE_UNUSED, _GL_ATTRIBUTE_NODISCARD, don't use the
14351         bracket syntax if _GL_BRACKET_BEFORE_ATTRIBUTE is defined.
14353 2023-04-15  Bruno Haible  <bruno@clisp.org>
14355         Don't include module 'year2038-required' in all-of-gnulib testdirs.
14356         * all-modules (exclude): Add year2038-required.
14358 2023-04-15  Bruno Haible  <bruno@clisp.org>
14360         selinux-h: Fix compilation error (regression 2023-04-13).
14361         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Instead of
14362         defining the C macro HAVE_SELINUX_SELINUX_H to 0, set the Autoconf
14363         variable HAVE_SELINUX_SELINUX_H to 0.
14365 2023-04-14  Bruno Haible  <bruno@clisp.org>
14367         year2038: Fix configure failure on 32-bit mingw.
14368         * m4/largefile.m4 (_AC_SYS_YEAR2038_PROBE): Use the same option
14369         spelling as in _AC_SYS_YEAR2038_OPTIONS.
14371 2023-04-14  Bruno Haible  <bruno@clisp.org>
14373         isnan: Fix compilation error in C++ mode on FreeBSD 13.2.
14374         * lib/math.in.h (isnan): On FreeBSD 13.2 or newer, don't declare isnan
14375         through _GL_MATH_CXX_REAL_FLOATING_DECL_2.
14377 2023-04-14  Bruno Haible  <bruno@clisp.org>
14379         filemode: Fix double-inclusion guard.
14380         * lib/filemode.h: Make the double-inclusion guard actually work.
14382 2023-04-14  Bruno Haible  <bruno@clisp.org>
14384         year2038: Add reminder to include <config.h> before time_t gets defined.
14385         * lib/sched.in.h: Check that config.h was already included before the
14386         #include_next.
14387         * lib/sys_select.in.h: Likewise.
14388         * lib/sys_stat.in.h: Likewise.
14389         * lib/sys_time.in.h: Likewise.
14390         * lib/sys_types.in.h: Likewise.
14391         * lib/time.in.h: Likewise.
14392         * lib/utime.in.h: Likewise.
14393         * modules/year2038 (Depends-on): Add sched, sys_msg, sys_select,
14394         sys_sem, sys_shm, sys_stat, sys_time, sys_types, time-h, utime-h.
14396         sys_shm: New module.
14397         * lib/sys_shm.in.h: New file.
14398         * m4/sys_shm_h.m4: New file.
14399         * modules/sys_shm: New file.
14400         * doc/posix-headers/sys_shm.texi: Mention the new module.
14402         sys_sem: New module.
14403         * lib/sys_sem.in.h: New file.
14404         * m4/sys_sem_h.m4: New file.
14405         * modules/sys_sem: New file.
14406         * doc/posix-headers/sys_sem.texi: Mention the new module.
14408         sys_msg: New module.
14409         * lib/sys_msg.in.h: New file.
14410         * m4/sys_msg_h.m4: New file.
14411         * modules/sys_msg: New file.
14412         * doc/posix-headers/sys_msg.texi: Mention the new module.
14414 2023-04-13  Bruno Haible  <bruno@clisp.org>
14416         Add more reminders to include <config.h>.
14417         * lib/aligned-malloc.h: Check that config.h was already included.
14418         * lib/careadlinkat.h: Likewise.
14419         * lib/filemode.h: Likewise.
14420         * lib/freadptr.h: Likewise.
14421         * lib/fseterr.h: Likewise.
14422         * lib/glthread/lock.h: Likewise.
14423         * lib/glthread/tls.h: Likewise.
14424         * lib/immutable.h: Likewise.
14425         * lib/isapipe.h: Likewise.
14426         * lib/isnand-nolibm.h: Likewise.
14427         * lib/isnanf-nolibm.h: Likewise.
14428         * lib/isnanl-nolibm.h: Likewise.
14429         * lib/mbswidth.h: Likewise.
14430         * lib/md5.h: Likewise.
14431         * lib/minmax.h: Likewise.
14432         * lib/msvc-inval.h: Likewise.
14433         * lib/msvc-nothrow.h: Likewise.
14434         * lib/pathmax.h: Likewise.
14435         * lib/sha1.h: Likewise.
14436         * lib/sha256.h: Likewise.
14437         * lib/sha512.h: Likewise.
14438         * lib/size_max.h: Likewise.
14439         * lib/sm3.h: Likewise.
14440         * lib/stat-size.h: Likewise.
14441         * lib/termcap.h: Likewise.
14442         * lib/terminfo.h: Likewise.
14443         * lib/thread-optim.h: Likewise.
14444         * lib/unlocked-io.h: Likewise.
14445         * lib/vma-iter.h: Likewise.
14447 2023-04-13  Bruno Haible  <bruno@clisp.org>
14449         Adjust comments in <config.h> reminders.
14450         * lib/*.h: In the comments, mention also HAVE_*.
14452 2023-04-13  Bruno Haible  <bruno@clisp.org>
14454         Adjust comments in <config.h> reminders.
14455         * lib/*.in.h: In the comments, mention also HAVE_RAW_DECL_*.
14456         * Makefile (sc_check_config_h_reminder): Search also for HAVE_RAW_DECL_.
14458 2023-04-13  Bruno Haible  <bruno@clisp.org>
14460         utmp: Avoid using HAVE_* macros in *.in.h files.
14461         * m4/pty_h.m4 (gl_PTY_CHECK_UTIL_H): New macro, extracted from gl_PTY_H.
14462         (gl_PTY_H): Invoke it.
14463         * m4/utmp_h.m4 (gl_UTMP_H): Invoke gl_PTY_CHECK_UTIL_H and set
14464         HAVE_TERMIOS_H.
14465         (gl_UTMP_H_DEFAULTS): Require gl_PTY_H_DEFAULTS, gl_TERMIOS_H_DEFAULTS.
14466         * modules/utmp (Files): Add m4/pty_h.m4, m4/termios_h.m4.
14467         (Makefile.am): Substitute also HAVE_UTIL_H, HAVE_LIBUTIL_H,
14468         HAVE_TERMIOS_H.
14469         * lib/utmp.in.h: Test HAVE_UTIL_H, HAVE_LIBUTIL_H, HAVE_TERMIOS_H as
14470         Autoconf variables.
14472 2023-04-13  Bruno Haible  <bruno@clisp.org>
14474         getprogname: Avoid using HAVE_* macros in *.in.h files.
14475         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
14476         HAVE_DECL_PROGRAM_INVOCATION_NAME.
14477         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Require gl_STDLIB_H_DEFAULTS
14478         and gl_USE_SYSTEM_EXTENSIONS. Set HAVE_DECL_PROGRAM_INVOCATION_NAME.
14479         * modules/stdlib (Makefile.am): Substitute
14480         HAVE_DECL_PROGRAM_INVOCATION_NAME.
14481         * lib/stdlib.in.h (getprogname): Test HAVE_DECL_PROGRAM_INVOCATION_NAME
14482         as an Autoconf variable.
14484 2023-04-13  Bruno Haible  <bruno@clisp.org>
14486         selinux-h: Avoid using HAVE_* macros in *.in.h files.
14487         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Initialize
14488         HAVE_SELINUX_SELINUX_H.
14489         * modules/selinux-h (Makefile.am): Substitute HAVE_SELINUX_SELINUX_H.
14490         * lib/se-selinux.in.h: Test HAVE_SELINUX_SELINUX_H as an Autoconf
14491         variable.
14493 2023-04-13  Bruno Haible  <bruno@clisp.org>
14495         ialloc, gethrxtime: Restore GCC diagnostics options.
14496         * lib/ialloc.h: Invoke _GL_INLINE_HEADER_END.
14497         * lib/xtime.h: Likewise.
14498         * Makefile (sc_check_GL_INLINE_HEADER_use): New rule.
14500 2023-04-13  Bruno Haible  <bruno@clisp.org>
14502         flexmember: Fix module description (regression 2016-09-07).
14503         * modules/flexmember (Include): Add "flexmember.h".
14505 2023-04-12  Paul Eggert  <eggert@cs.ucla.edu>
14507         doc: year2038 MIPS o32 nudge
14508         * doc/year2038.texi: Use more-common "o32" name for
14509         32-bit MIPS ABI.
14511 2023-04-12  Bruno Haible  <bruno@clisp.org>
14513         Add more reminders to include <config.h>.
14514         * m4/gnulib-common.m4 (gl_COMMON): In config.h, define
14515         _GL_CONFIG_H_INCLUDED.
14516         * lib/acl-internal.h: Test _GL_CONFIG_H_INCLUDED instead of
14517         _GL_INLINE_HEADER_BEGIN.
14518         * lib/alignalloc.h: Likewise.
14519         * lib/argp-fmtstream.h: Likewise.
14520         * lib/argp.h: Likewise.
14521         * lib/binary-io.h: Likewise.
14522         * lib/bitrotate.h: Likewise.
14523         * lib/c-ctype.h: Likewise.
14524         * lib/count-leading-zeros.h: Likewise.
14525         * lib/count-one-bits.h: Likewise.
14526         * lib/count-trailing-zeros.h: Likewise.
14527         * lib/eealloc.h: Likewise.
14528         * lib/execinfo.in.h: Likewise.
14529         * lib/gethrxtime.h: Likewise.
14530         * lib/gl_list.h: Likewise.
14531         * lib/gl_map.h: Likewise.
14532         * lib/gl_omap.h: Likewise.
14533         * lib/gl_openssl.h: Likewise.
14534         * lib/gl_oset.h: Likewise.
14535         * lib/gl_set.h: Likewise.
14536         * lib/gl_xlist.h: Likewise.
14537         * lib/gl_xmap.h: Likewise.
14538         * lib/gl_xomap.h: Likewise.
14539         * lib/gl_xoset.h: Likewise.
14540         * lib/gl_xset.h: Likewise.
14541         * lib/gl_xsublist.h: Likewise.
14542         * lib/glthread/cond.h: Likewise.
14543         * lib/hamt.h: Likewise.
14544         * lib/ialloc.h: Likewise.
14545         * lib/math.in.h: Likewise.
14546         * lib/mbchar.h: Likewise.
14547         * lib/mbfile.h: Likewise.
14548         * lib/mbiter.h: Likewise.
14549         * lib/mbuiter.h: Likewise.
14550         * lib/openat.h: Likewise.
14551         * lib/pipe-filter-aux.h: Likewise.
14552         * lib/priv-set.h: Likewise.
14553         * lib/safe-alloc.h: Likewise.
14554         * lib/savewd.h: Likewise.
14555         * lib/se-context.in.h: Likewise.
14556         * lib/se-label.in.h: Likewise.
14557         * lib/se-selinux.in.h: Likewise.
14558         * lib/sig-handler.h: Likewise.
14559         * lib/stat-time.h: Likewise.
14560         * lib/string-desc-quotearg.h: Likewise.
14561         * lib/string-desc.h: Likewise.
14562         * lib/sys_socket.in.h: Likewise.
14563         * lib/timespec.h: Likewise.
14564         * lib/u64.h: Likewise.
14565         * lib/uchar.in.h: Likewise.
14566         * lib/unistd.in.h: Likewise.
14567         * lib/utimens.h: Likewise.
14568         * lib/wctype.in.h: Likewise.
14569         * lib/xalloc.h: Likewise.
14570         * lib/xbinary-io.h: Likewise.
14571         * lib/xsize.h: Likewise.
14572         * lib/xstring-desc.h: Likewise.
14573         * lib/xtime.h: Likewise.
14574         * lib/acl.h: Check that config.h was already included.
14575         * lib/alignof.h: Likewise.
14576         * lib/argmatch.h: Likewise.
14577         * lib/argv-iter.h: Likewise.
14578         * lib/arpa_inet.in.h: Likewise.
14579         * lib/attribute.h: Likewise.
14580         * lib/backupfile.h: Likewise.
14581         * lib/base32.h: Likewise.
14582         * lib/base64.h: Likewise.
14583         * lib/basename-lgpl.h: Likewise.
14584         * lib/bitset.h: Likewise.
14585         * lib/bitsetv.h: Likewise.
14586         * lib/c-snprintf.h: Likewise.
14587         * lib/c-stack.h: Likewise.
14588         * lib/c-strcase.h: Likewise.
14589         * lib/c-vasnprintf.h: Likewise.
14590         * lib/c-vasprintf.h: Likewise.
14591         * lib/c-vsnprintf.h: Likewise.
14592         * lib/c-xvasprintf.h: Likewise.
14593         * lib/canon-host.h: Likewise.
14594         * lib/canonicalize.h: Likewise.
14595         * lib/clean-temp.h: Likewise.
14596         * lib/concat-filename.h: Likewise.
14597         * lib/ctype.in.h: Likewise.
14598         * lib/dfa.h: Likewise.
14599         * lib/di-set.h: Likewise.
14600         * lib/dirent-safer.h: Likewise.
14601         * lib/dirent.in.h: Likewise.
14602         * lib/dirname.h: Likewise.
14603         * lib/eloop-threshold.h: Likewise.
14604         * lib/error.in.h: Likewise.
14605         * lib/exclude.h: Likewise.
14606         * lib/fatal-signal.h: Likewise.
14607         * lib/fcntl.in.h: Likewise.
14608         * lib/file-type.h: Likewise.
14609         * lib/filenamecat.h: Likewise.
14610         * lib/filevercmp.h: Likewise.
14611         * lib/flexmember.h: Likewise.
14612         * lib/fnmatch.in.h: Likewise.
14613         * lib/fpending.h: Likewise.
14614         * lib/freadable.h: Likewise.
14615         * lib/freadahead.h: Likewise.
14616         * lib/freading.h: Likewise.
14617         * lib/fts_.h: Likewise.
14618         * lib/fwritable.h: Likewise.
14619         * lib/fwriting.h: Likewise.
14620         * lib/gc.h: Likewise.
14621         * lib/get_progname_of.h: Likewise.
14622         * lib/glob.in.h: Likewise.
14623         * lib/glthread/thread.h: Likewise.
14624         * lib/hash-pjw-bare.h: Likewise.
14625         * lib/hash-pjw.h: Likewise.
14626         * lib/hash-triple.h: Likewise.
14627         * lib/hash.h: Likewise.
14628         * lib/i-ring.h: Likewise.
14629         * lib/iconv.in.h: Likewise.
14630         * lib/ino-map.h: Likewise.
14631         * lib/inttostr.h: Likewise.
14632         * lib/inttypes.in.h: Likewise.
14633         * lib/javaversion.h: Likewise.
14634         * lib/langinfo.in.h: Likewise.
14635         * lib/locale.in.h: Likewise.
14636         * lib/localename.h: Likewise.
14637         * lib/malloc.in.h: Likewise.
14638         * lib/malloca.h: Likewise.
14639         * lib/memcasecmp.h: Likewise.
14640         * lib/memchr2.h: Likewise.
14641         * lib/memcmp2.h: Likewise.
14642         * lib/modechange.h: Likewise.
14643         * lib/monetary.in.h: Likewise.
14644         * lib/mountlist.h: Likewise.
14645         * lib/netdb.in.h: Likewise.
14646         * lib/obstack.h: Likewise.
14647         * lib/opendirat.h: Likewise.
14648         * lib/pagealign_alloc.h: Likewise.
14649         * lib/pipe-filter.h: Likewise.
14650         * lib/poll.in.h: Likewise.
14651         * lib/pthread.in.h: Likewise.
14652         * lib/pty.in.h: Likewise.
14653         * lib/quotearg.h: Likewise.
14654         * lib/read-file.h: Likewise.
14655         * lib/readline.h: Likewise.
14656         * lib/readutmp.h: Likewise.
14657         * lib/regex-quote.h: Likewise.
14658         * lib/relocatable.h: Likewise.
14659         * lib/savedir.h: Likewise.
14660         * lib/sched.in.h: Likewise.
14661         * lib/search.in.h: Likewise.
14662         * lib/sh-quote.h: Likewise.
14663         * lib/signal.in.h: Likewise.
14664         * lib/sigpipe-die.h: Likewise.
14665         * lib/sockets.h: Likewise.
14666         * lib/spawn.in.h: Likewise.
14667         * lib/ssfmalloc.h: Likewise.
14668         * lib/stack.h: Likewise.
14669         * lib/stdalign.in.h: Likewise.
14670         * lib/stdarg.in.h: Likewise.
14671         * lib/stddef.in.h: Likewise.
14672         * lib/stdio-safer.h: Likewise.
14673         * lib/stdio.in.h: Likewise.
14674         * lib/stdlib.in.h: Likewise.
14675         * lib/stdnoreturn.in.h: Likewise.
14676         * lib/strerror-override.h: Likewise.
14677         * lib/striconv.h: Likewise.
14678         * lib/striconveh.h: Likewise.
14679         * lib/striconveha.h: Likewise.
14680         * lib/string-buffer.h: Likewise.
14681         * lib/string.in.h: Likewise.
14682         * lib/strings.in.h: Likewise.
14683         * lib/strnlen1.h: Likewise.
14684         * lib/sys_file.in.h: Likewise.
14685         * lib/sys_ioctl.in.h: Likewise.
14686         * lib/sys_random.in.h: Likewise.
14687         * lib/sys_resource.in.h: Likewise.
14688         * lib/sys_select.in.h: Likewise.
14689         * lib/sys_stat.in.h: Likewise.
14690         * lib/sys_time.in.h: Likewise.
14691         * lib/sys_times.in.h: Likewise.
14692         * lib/sys_utsname.in.h: Likewise.
14693         * lib/sys_wait.in.h: Likewise.
14694         * lib/system-quote.h: Likewise.
14695         * lib/term-style-control.h: Likewise.
14696         * lib/termios.in.h: Likewise.
14697         * lib/textstyle.in.h: Likewise.
14698         * lib/threads.in.h: Likewise.
14699         * lib/time.in.h: Likewise.
14700         * lib/trim.h: Likewise.
14701         * lib/utime.in.h: Likewise.
14702         * lib/utmp.in.h: Likewise.
14703         * lib/vasnprintf.h: Likewise.
14704         * lib/verror.h: Likewise.
14705         * lib/version-etc.h: Likewise.
14706         * lib/wchar.in.h: Likewise.
14707         * lib/windows-spawn.h: Likewise.
14708         * lib/windows-thread.h: Likewise.
14709         * lib/xgetcwd.h: Likewise.
14710         * lib/xgetdomainname.h: Likewise.
14711         * lib/xgethostname.h: Likewise.
14712         * lib/xmalloca.h: Likewise.
14713         * lib/xmemdup0.h: Likewise.
14714         * lib/xprintf.h: Likewise.
14715         * lib/xreadlink.h: Likewise.
14716         * lib/xstriconv.h: Likewise.
14717         * lib/xstriconveh.h: Likewise.
14718         * lib/xstrndup.h: Likewise.
14719         * lib/xstrtol-error.h: Likewise.
14720         * lib/xvasprintf.h: Likewise.
14721         * Makefile (config_h_MACROS*): New variables.
14722         (sc_check_config_h_reminder): New rule.
14724 2023-04-11  Paul Eggert  <eggert@cs.ucla.edu>
14726         doc: update year2038 list further
14727         Prompted by Adhemerval Zanella Netto’s email in:
14728         https://lists.gnu.org/r/bug-gnulib/2023-04/msg00083.html
14729         Also, mention 32-bit Android.
14730         * doc/year2038.texi: Mention Linux/ork1 and Android.
14731         Append "32" to powerpc and sparc names.
14733 2023-04-11  Bruno Haible  <bruno@clisp.org>
14735         Fix the "make sc_prohibit_AC_LIBOBJ_in_m4" findings.
14736         * Makefile (allow_AC_LIBOBJ): Update after 2023-03-24 change. Add
14737         termcap, terminfo.
14739 2023-04-11  Bruno Haible  <bruno@clisp.org>
14741         Fix some "make sc_prohibit_leading_TABs" findings.
14742         * tests/test-calloc-gnu.c: Expand tabs.
14743         * tests/test-regex.c: Likewise.
14745 2023-04-11  Bruno Haible  <bruno@clisp.org>
14747         Makefile: Fix a syntax alert.
14748         * Makefile: Indent commands with tabs, not spaces.
14750 2023-04-10  Bruno Haible  <bruno@clisp.org>
14752         alignasof: Ensure a correct _Alignas (regression 2023-01-15).
14753         * m4/stdalign.m4 (gl_ALIGNASOF): Define _Alignas also when <stdalign.h>
14754         exists.
14756 2023-04-10  Paul Eggert  <eggert@cs.ucla.edu>
14758         doc: update list of year2038 platforms
14759         * doc/year2038.texi: Update list of platforms
14760         by adding dates and version numbers and fixing some that
14761         appear to have been misfiled.  Also, list working systems
14762         and versions first, as that helps shorten the list of
14763         failing systems by saying "older versions".
14765         doc: moved year2038 para up
14766         * doc/year2038.texi: Move a paragraph up,
14767         as it’s lonely at the end.
14769         doc: document year2038 first
14770         * doc/year2038.texi: Document year2038 first, then
14771         year2038-required.
14773 2023-04-10  Bruno Haible  <bruno@clisp.org>
14775         doc: Clarify list of platforms for year2038 support.
14776         * doc/year2038.texi (Avoiding the year 2038 problem): List the platforms
14777         on which year2038-required is known to fail vs. known to succeed.
14779 2023-04-10  Bruno Haible  <bruno@clisp.org>
14781         doc: Avoid ambiguous wording.
14782         * doc/posix-headers/time.texi: Say "or" not "and".
14784 2023-04-09  Bruno Haible  <bruno@clisp.org>
14786         doc: Fix a typo.
14787         * doc/posix-headers/time.texi: Fix typo in module name.
14789 2023-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14791         largefile: sync from Autoconf master
14792         * modules/largefile-required, modules/year2038-required: New modules.
14793         * MODULES.html.sh, doc/largefile.texi, doc/posix-headers/time.texi:
14794         * doc/year2038.texi: Document this.
14795         * m4/largefile.m4: Sync from Autoconf master.
14796         Conditionalize the workaround on AC_SYS_LARGEFILE_REQUIRED rather
14797         than on AC_SYS_YEAR2038 so that we replace older but still
14798         unreleased Autoconf.
14799         (AC_SYS_LARGEFILE_REQUIRED, AC_SYS_YEAR2038_REQUIRED): New macros.
14801         year2038: configure earlier
14802         * modules/year2038: Put AC_SYS_YEAR2038 in configure.ac-early
14803         since it can affect later compilations with _TIME_BITS=64.
14805 2023-04-09  Bruno Haible  <bruno@clisp.org>
14807         c32toupper: Add tests.
14808         * tests/test-c32toupper.sh: New file.
14809         * tests/test-c32toupper.c: New file, based on tests/test-c32islower.c.
14810         * modules/c32toupper-tests: New file.
14812         c32toupper: New module.
14813         * lib/uchar.in.h (c32toupper): New declaration.
14814         * lib/c32toupper.c: New file.
14815         * modules/c32toupper: New file.
14816         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
14817         GNULIB_C32TOUPPER.
14818         * modules/uchar (Makefile.am): Substitute GNULIB_C32TOUPPER.
14820 2023-04-09  Bruno Haible  <bruno@clisp.org>
14822         c32tolower: Add tests.
14823         * tests/test-c32tolower.sh: New file.
14824         * tests/test-c32tolower.c: New file, based on tests/test-c32isupper.c.
14825         * modules/c32tolower-tests: New file.
14827         c32tolower: New module.
14828         * lib/uchar.in.h (c32tolower): New declaration.
14829         * lib/c32tolower.c: New file.
14830         * lib/c32to-impl.h: New file, based on lib/c32is-impl.h.
14831         * modules/c32tolower: New file.
14832         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
14833         GNULIB_C32TOLOWER.
14834         * modules/uchar (Makefile.am): Substitute GNULIB_C32TOLOWER.
14836 2023-04-09  Bruno Haible  <bruno@clisp.org>
14838         c32is*: Ensure GNULIB_defined_mbstate_t is defined on AIX.
14839         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN): Define through AC_DEFUN_ONCE.
14840         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32): Require it.
14841         * modules/c32isalnum (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4.
14842         (configure.ac): Require gl_MBSTATE_T_BROKEN.
14843         * modules/c32isalpha: Likewise.
14844         * modules/c32isblank: Likewise.
14845         * modules/c32iscntrl: Likewise.
14846         * modules/c32isdigit: Likewise.
14847         * modules/c32isgraph: Likewise.
14848         * modules/c32islower: Likewise.
14849         * modules/c32isprint: Likewise.
14850         * modules/c32ispunct: Likewise.
14851         * modules/c32isspace: Likewise.
14852         * modules/c32isupper: Likewise.
14853         * modules/c32isxdigit: Likewise.
14855 2023-04-09  Bruno Haible  <bruno@clisp.org>
14857         mbrtoc32: Add comments.
14858         * lib/mbrtoc32.c: Add comment regarding AIX.
14859         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32): Add comment regarding
14860         GNULIB_defined_mbstate_t.
14862 2023-04-09  Bruno Haible  <bruno@clisp.org>
14864         doc: Mention a NetBSD bug.
14865         * doc/posix-functions/towlower.texi: Mention NetBSD bug 57339.
14866         * doc/posix-functions/towupper.texi: Likewise.
14868 2023-04-09  Bruno Haible  <bruno@clisp.org>
14870         vasnwprintf-posix: More details about the glibc bug.
14871         * doc/posix-functions/swprintf.texi: Add comment.
14872         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LA): Update cross-compilation
14873         guess.
14875 2023-04-08  Bruno Haible  <bruno@clisp.org>
14877         doc: Mention another Haiku bug.
14878         * doc/posix-functions/open.texi: Mention a Haiku bug with symlinks.
14880 2023-04-08  Bruno Haible  <bruno@clisp.org>
14882         Avoid Autoconf "was expanded before it was required" warning.
14883         * m4/exponentf.m4 (gl_FLOAT_EXPONENT_LOCATION): Define through
14884         AC_DEFUN_ONCE.
14885         * m4/exponentd.m4 (gl_DOUBLE_EXPONENT_LOCATION): Likewise.
14886         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Likewise.
14888 2023-04-08  Bruno Haible  <bruno@clisp.org>
14890         striconveh tests: Avoid test failure on glibc 2.15.
14891         * tests/test-striconveh.c (main): Skip some of the GB18030 tests on
14892         glibc < 2.16.
14894 2023-04-08  Bruno Haible  <bruno@clisp.org>
14896         vasnwprintf-posix: Really work around %La bug in glibc 2.15 and Haiku.
14897         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Fix a copy&paste bug.
14899 2023-04-08  Bruno Haible  <bruno@clisp.org>
14901         login_tty: Fix compilation error in C++ mode on Solaris 11.4.
14902         * m4/login_tty.m4 (gl_FUNC_LOGIN_TTY): Test whether <termios.h> exists.
14903         Consider it when testing whether login_tty is declared.
14904         * lib/utmp.in.h: If none of <util.h> and <libutil.h> exists, include
14905         <termios.h> instead.
14906         * doc/glibc-functions/login_tty.texi: Document the Solaris 11.4 problem.
14908 2023-04-08  Bruno Haible  <bruno@clisp.org>
14910         time: Fix compilation error in C++ mode on Solaris 11.
14911         * lib/time.in.h (time): Disable _GL_CXXALIASWARN invocation on non-glibc
14912         systems.
14914 2023-04-07  Bruno Haible  <bruno@clisp.org>
14916         unistdio/*: Fix test failures (regression 2023-01-28).
14917         * modules/unistdio/*printf (configure.ac): Bump required libunistring
14918         version number.
14920 2023-04-07  Bruno Haible  <bruno@clisp.org>
14922         trim tests: Fix link error.
14923         * modules/trim-tests (Makefile.am): Link test-trim also against libintl.
14925 2023-04-07  Bruno Haible  <bruno@clisp.org>
14927         stdio: Fix the value of _PRINTF_NAN_LEN_MAX on OpenBSD.
14928         * lib/stdio.in.h (_PRINTF_NAN_LEN_MAX): Define to 4 on OpenBSD.
14930 2023-04-07  Bruno Haible  <bruno@clisp.org>
14932         vasnwprintf-posix: Work around %La bug in glibc 2.15 and Haiku.
14933         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LA): New macro.
14934         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke
14935         gl_SWPRINTF_DIRECTIVE_LA and define NEED_WPRINTF_DIRECTIVE_LA
14936         accordingly.
14937         * lib/vasnprintf.c: When compiling vasnwprintf, if
14938         NEED_WPRINTF_DIRECTIVE_LA, handle the %La and %LA directives ourselves.
14939         * doc/posix-functions/swprintf.texi: Mention the %La bug.
14941 2023-04-07  Bruno Haible  <bruno@clisp.org>
14943         stdio: Fix compilation error in C++ mode on macOS.
14944         * lib/stdio.in.h (getw, putw): Repeat the declaration even if the
14945         function is already supposed to be declared.
14947 2023-04-07  Bruno Haible  <bruno@clisp.org>
14949         vasnwprintf-posix tests: Avoid test failure on mingw.
14950         * tests/test-vasnwprintf-posix.c (test_function): For mingw, change two
14951         expected test results.
14953 2023-04-06  Bruno Haible  <bruno@clisp.org>
14955         uchar: Inline functions with C linkage in C++ mode (regr. 2023-04-04).
14956         * m4/gnulib-common.m4 (gl_COMMON_BODY): Put definitions of
14957         _GL_BEGIN_C_LINKAGE, _GL_END_C_LINKAGE into config.h.
14958         * lib/uchar.in.h: Enclose all inline functions in _GL_BEGIN_C_LINKAGE /
14959         _GL_END_C_LINKAGE.
14961 2023-04-06  Bruno Haible  <bruno@clisp.org>
14963         alignalloc: Fix link error on glibc 2.15 systems.
14964         * lib/alignalloc.h (ALIGNALLOC_VIA_ALIGNED_ALLOC): Set to 0 on
14965         glibc 2.15 systems.
14967 2023-04-05  Bruno Haible  <bruno@clisp.org>
14969         doc: Add references to registered Haiku bugs.
14970         * doc/posix-functions/call_once.texi: Mention Haiku bug.
14971         * doc/posix-functions/duplocale.texi: Likewise.
14972         * doc/posix-functions/freelocale.texi: Likewise.
14973         * doc/posix-functions/getlogin_r.texi: Likewise.
14974         * doc/posix-functions/initstate.texi: Likewise.
14975         * doc/posix-functions/mbrtoc32.texi: Likewise.
14976         * doc/posix-functions/strxfrm.texi: Likewise.
14977         * doc/posix-headers/math.texi: Update.
14979 2023-04-05  Bruno Haible  <bruno@clisp.org>
14981         string-desc-quotearg tests: Avoid a test failure on Haiku.
14982         * tests/test-string-desc-quotearg.c (main): For the
14983         clocale_quoting_style, accept also the U+2018 and U+2019 characters in
14984         UTF-8 encoding.
14986 2023-04-05  Bruno Haible  <bruno@clisp.org>
14988         random_r: Fix compilation error on Haiku.
14989         * lib/stdlib.in.h: For random_r, include <stdint.h> always.
14990         * modules/random_r (Depends-on): Depend on 'stdint' always.
14992 2023-04-05  Bruno Haible  <bruno@clisp.org>
14994         forkpty, openpty, login_tty: Fix link errors of the tests.
14995         * m4/pty.m4 (gl_PTY_LIB): On Haiku, set PTY_LIB to '-lbsd'.
14997 2023-04-05  Bruno Haible  <bruno@clisp.org>
14999         strerrorname_np: Fix compilation error on Haiku.
15000         * lib/strerrorname_np.c (strerrorname_np): Avoid conflict between
15001         EDOOFUS and EINVAL.
15002         * tests/test-strerrorname_np.c (main): Likewise.
15004 2023-04-05  Bruno Haible  <bruno@clisp.org>
15006         uchar: Fix recent change.
15007         * lib/uchar.in.h: Include <string.h>, <wctype.h>.
15009 2023-04-05  Bruno Haible  <bruno@clisp.org>
15011         localename tests: Work around a Haiku bug.
15012         * tests/test-localename.c (freelocale): New macro.
15014 2023-04-05  Bruno Haible  <bruno@clisp.org>
15016         localename: Add support for Haiku's per-thread locales.
15017         * lib/localename.c: Include <dlfcn.h>.
15018         (gl_locale_name_thread_unsafe): Add special code for Haiku.
15020 2023-04-05  Bruno Haible  <bruno@clisp.org>
15022         uchar: Work around Haiku bug.
15023         * m4/uchar_h.m4 (gl_UCHAR_H, gl_TYPE_CHAR8_T, gl_TYPE_CHAR16_T,
15024         gl_TYPE_CHAR32_T): Before including <uchar.h>, on Haiku, first include
15025         <stdint.h>.
15026         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Likewise.
15027         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32, gl_CHECK_FUNC_MBRTOC32,
15028         gl_MBRTOC32_EMPTY_INPUT, gl_MBRTOC32_C_LOCALE, gl_MBRTOC32_SANITYCHECK):
15029         Likewise.
15030         * lib/uchar.in.h: On Haiku, include <stdint.h> before the include_next.
15031         * doc/posix-headers/uchar.texi: Mention the Haiku bug.
15033 2023-04-05  Bruno Haible  <bruno@clisp.org>
15035         stdlib, btowc: Fix file lists.
15036         * modules/stdlib (Files): Add m4/codeset.m4.
15037         * modules/btowc (Files): Likewise.
15038         * modules/c-dtoastr-tests (Files): Likewise.
15039         * modules/c-ldtoastr-tests (Files): Likewise.
15040         * modules/c-snprintf-tests (Files): Likewise.
15041         * modules/c-vasprintf-tests (Files): Likewise.
15042         * modules/c-vsnprintf-tests (Files): Likewise.
15043         * modules/c-xvasprintf-tests (Files): Likewise.
15044         * modules/nl_langinfo-tests (Files): Likewise.
15046 2023-04-04  Bruno Haible  <bruno@clisp.org>
15048         duplocale: Fix compilation error on Haiku (regression 2023-01-22).
15049         * lib/locale.in.h (duplocale): If HAVE_DUPLOCALE = 0, don't declare it,
15050         even if REPLACE_DUPLOCALE = 1.
15051         * modules/duplocale (Depends-on, configure.ac): Don't compile a
15052         replacement if HAVE_DUPLOCALE = 0 and REPLACE_DUPLOCALE = 1.
15054 2023-04-04  Bruno Haible  <bruno@clisp.org>
15056         c32tob, c32is*, c32rtomb, mbrtoc32: Fix file lists.
15057         * modules/c32tob (Files): Add m4/locale-fr.m4, m4/locale-zh.m4,
15058         m4/codeset.m4.
15059         * modules/c32isalnum (Files): Likewise.
15060         * modules/c32isalpha (Files): Likewise.
15061         * modules/c32isblank (Files): Likewise.
15062         * modules/c32iscntrl (Files): Likewise.
15063         * modules/c32isdigit (Files): Likewise.
15064         * modules/c32isgraph (Files): Likewise.
15065         * modules/c32islower (Files): Likewise.
15066         * modules/c32isprint (Files): Likewise.
15067         * modules/c32ispunct (Files): Likewise.
15068         * modules/c32isspace (Files): Likewise.
15069         * modules/c32isupper (Files): Likewise.
15070         * modules/c32isxdigit (Files): Likewise.
15071         * modules/c32rtomb (Files): Likewise.
15072         * modules/mbrtoc32 (Files): Likewise.
15074 2023-04-04  Bruno Haible  <bruno@clisp.org>
15076         stdlib: Work around MB_CUR_MAX bug on Solaris 10.
15077         * lib/stdlib.in.h (gl_MB_CUR_MAX): New function.
15078         (MB_CUR_MAX, GNULIB_defined_MB_CUR_MAX): New macros.
15079         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether MB_CUR_MAX is correct.
15080         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MB_CUR_MAX.
15081         * modules/stdlib (Files): Add m4/locale-fr.m4.
15082         (Makefile.am): Substitute REPLACE_MB_CUR_MAX.
15083         * doc/posix-headers/stdlib.texi: Mention the Solaris 10 bug.
15085 2023-04-04  Bruno Haible  <bruno@clisp.org>
15087         *c32*: Inline most functions on glibc and musl libc.
15088         * lib/uchar.in.h: Invoke _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
15089         (btoc32): Inline if _GL_WCHAR_T_IS_UCS4.
15090         (c32isalnum, c32isalpha, c32isblank, c32iscntrl, c32isdigit, c32isgraph,
15091         c32islower, c32isprint, c32ispunct, c32isspace, c32isupper,
15092         c32isxdigit): Inline if
15093         _GL_WCHAR_T_IS_UCS4 && !GNULIB_defined_mbstate_t.
15094         (c32snrtombs, c32srtombs, c32stombs, c32tob, mbsnrtoc32s, mbsrtoc32s,
15095         mbstoc32s): Inline if _GL_WCHAR_T_IS_UCS4.
15096         * lib/btoc32.c: Define compilation unit marker.
15097         (btoc32): Conditionally mark as _GL_EXTERN_INLINE.
15098         * lib/c32isalnum.c: Define compilation unit marker.
15099         * lib/c32isalpha.c: Likewise.
15100         * lib/c32isblank.c: Likewise.
15101         * lib/c32iscntrl.c: Likewise.
15102         * lib/c32isdigit.c: Likewise.
15103         * lib/c32isgraph.c: Likewise.
15104         * lib/c32islower.c: Likewise.
15105         * lib/c32isprint.c: Likewise.
15106         * lib/c32ispunct.c: Likewise.
15107         * lib/c32isspace.c: Likewise.
15108         * lib/c32isupper.c: Likewise.
15109         * lib/c32isxdigit.c: Likewise.
15110         * lib/c32is-impl.h (FUNC): Conditionally mark as _GL_EXTERN_INLINE.
15111         * lib/c32snrtombs.c: Define compilation unit marker.
15112         (c32snrtombs): Conditionally mark as _GL_EXTERN_INLINE.
15113         * lib/c32srtombs.c: Define compilation unit marker.
15114         (c32srtombs): Conditionally mark as _GL_EXTERN_INLINE.
15115         * lib/c32stombs.c: Define compilation unit marker.
15116         (c32stombs): Conditionally mark as _GL_EXTERN_INLINE.
15117         * lib/c32tob.c: Define compilation unit marker.
15118         (c32tob): Conditionally mark as _GL_EXTERN_INLINE.
15119         * lib/mbsnrtoc32s.c: Define compilation unit marker.
15120         (mbsnrtoc32s): Conditionally mark as _GL_EXTERN_INLINE.
15121         * lib/mbsrtoc32s.c: Define compilation unit marker.
15122         (mbsrtoc32s): Conditionally mark as _GL_EXTERN_INLINE.
15123         * lib/mbstoc32s.c: Define compilation unit marker.
15124         (mbstoc32s): Conditionally mark as _GL_EXTERN_INLINE.
15125         * modules/uchar (Depends-on): Add extern-inline.
15127 2023-04-04  Pádraig Brady  <P@draigBrady.com>
15129         backupfile: fix bug when renaming from subdirectory
15130         * lib/backupfile.c (backup_internal): Ensure we use the
15131         appropriate offset if operating on a subdirectory,
15132         i.e., on an updated sdir.
15133         Fixes https://bugs.gnu.org/62607
15135 2023-04-04  Bruno Haible  <bruno@clisp.org>
15137         *c32*: Optimize on musl libc like on glibc.
15138         * lib/uchar.in.h (_GL_WCHAR_T_IS_UCS4): New macro.
15139         * lib/btoc32.c (btoc32): Test _GL_WCHAR_T_IS_UCS4 instead of __GLIBC__.
15140         * lib/mbsrtoc32s.c: Likewise.
15141         * lib/mbsnrtoc32s.c: Likewise.
15142         * lib/c32tob.c (c32tob): Likewise.
15143         * lib/c32srtombs.c: Likewise.
15144         * lib/c32snrtombs.c: Likewise.
15145         * lib/c32is-impl.h (FUNC): Likewise.
15147 2023-04-04  Bruno Haible  <bruno@clisp.org>
15149         uchar: Rename _GL_LARGE_CHAR32_T to _GL_SMALL_WCHAR_T.
15150         * lib/uchar.in.h (_GL_SMALL_WCHAR_T): Renamed from _GL_LARGE_CHAR32_T.
15151         * lib/mbrtoc32.c: Update.
15152         * lib/mbsrtoc32s.c: Update.
15153         * lib/mbsnrtoc32s.c: Update.
15154         * lib/c32tob.c: Update.
15155         * lib/c32rtomb.c: Update.
15156         * lib/c32srtombs.c: Update.
15157         * lib/c32snrtombs.c: Update.
15158         * lib/c32is-impl.h: Update.
15159         * tests/test-uchar.c: Update.
15161 2023-04-04  Bruno Haible  <bruno@clisp.org>
15163         c32rtomb: Fix an autoconf test.
15164         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): In a test program, include
15165         <stddef.h>, for NULL.
15167 2023-04-03  Bruno Haible  <bruno@clisp.org>
15169         tests: Set executable bit on more tests.
15170         * tests/test-c-dtoastr.sh: Make executable.
15171         * tests/test-c-ldtoastr.sh: Likewise.
15172         * tests/test-immutable.sh: Likewise.
15173         * tests/test-vasnwprintf-posix2.sh: Likewise.
15175 2023-04-03  Jim Meyering  <meyering@fb.com>
15177         tests: set executable bit in test-trim[1-3].sh
15178         This avoids a test failure for each new file.
15179         * tests/test-trim1.sh: Make this file executable.
15180         * tests/test-trim2.sh: Likewise.
15181         * tests/test-trim3.sh: Likewise.
15183 2023-04-03  Bruno Haible  <bruno@clisp.org>
15185         Use the 'extern-inline' module explicitly where needed.
15186         I found the list of affected modules through this command:
15187           for m in $(for f in `grep -Fl _GL_INLINE_HEADER_BEGIN lib/*.h | sort`
15188                      do ./gnulib-tool --find $f; done)
15189           do grep '^extern-inline' modules/$m > /dev/null || echo $m
15190           done
15191         * modules/fdutimensat (Depends-on): Add extern-inline.
15192         * modules/file-has-acl (Depends-on): Likewise.
15193         * modules/hamt (Depends-on): Likewise.
15194         * modules/relocatable-prog-wrapper (Depends-on): Likewise.
15195         * modules/safe-alloc (Depends-on): Likewise.
15196         * modules/string-desc (Depends-on): Likewise.
15197         * modules/string-desc-quotearg (Depends-on): Likewise.
15198         * modules/xstring-desc (Depends-on): Likewise.
15199         * modules/xvasprintf (Depends-on): Likewise.
15201 2023-04-03  Bruno Haible  <bruno@clisp.org>
15203         vasnprintf-posix: Fix harmless mistake (regression 2023-03-24).
15204         Found by Coverity.
15205         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Insert 'break;' statement.
15207 2023-04-03  Bruno Haible  <bruno@clisp.org>
15209         mbstoc32s tests: Check behaviour in the C locale.
15210         * tests/test-mbstoc32s.c (main): Test behaviour in the C locale. Based
15211         on tests/test-mbstowcs.c.
15212         * tests/test-mbstoc32s-5.sh: New file, based on tests/test-mbstowcs5.sh.
15213         * modules/mbstoc32s-tests (Files): Add it.
15214         (Depends-on): Add btoc32.
15215         (Makefile.am): Run test-mbstoc32s-5.sh.
15217 2023-04-03  Bruno Haible  <bruno@clisp.org>
15219         mbsnrtoc32s tests: Check behaviour in the C locale.
15220         * tests/test-mbsnrtoc32s.c (main): Test behaviour in the C locale. Based
15221         on tests/test-mbsnrtowcs.c.
15222         * tests/test-mbsnrtoc32s-5.sh: New file, based on
15223         tests/test-mbsrtowcs5.sh.
15224         * modules/mbsnrtoc32s-tests (Files): Add it.
15225         (Depends-on): Add btoc32.
15226         (Makefile.am): Run test-mbsnrtoc32s-5.sh.
15228 2023-04-03  Bruno Haible  <bruno@clisp.org>
15230         mbsrtoc32s tests: Check behaviour in the C locale.
15231         * tests/test-mbsrtoc32s.c (main): Test behaviour in the C locale. Based
15232         on tests/test-mbsrtowcs.c.
15233         * tests/test-mbsrtoc32s-5.sh: New file, based on
15234         tests/test-mbsrtowcs5.sh.
15235         * modules/mbsrtoc32s-tests (Files): Add it.
15236         (Depends-on): Add btoc32.
15237         (Makefile.am): Run test-mbsrtoc32s-5.sh.
15239 2023-04-03  Bruno Haible  <bruno@clisp.org>
15241         btoc32 tests: Check behaviour in the C locale.
15242         * tests/test-btoc32.c (main): Test behaviour in the C locale. Based on
15243         tests/test-btowc.c.
15244         * tests/test-btoc32-3.sh: New file, based on tests/test-btowc3.sh.
15245         * modules/btoc32-tests (Files): Add it.
15246         (Makefile.am): Test it.
15248 2023-04-03  Bruno Haible  <bruno@clisp.org>
15250         mbrtoc32 tests: Prefer *c32* functions.
15251         * tests/test-mbrtoc32.c (main): Use btoc32 instead of btowc.
15252         * modules/mbrtoc32-tests (Depends-on): Add btoc32.
15254 2023-04-03  Bruno Haible  <bruno@clisp.org>
15256         mbrtoc32 tests: Add comment.
15257         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): Add comment.
15258         * m4/mbrtoc32.m4 (gl_MBRTOC32_C_LOCALE): Add comment.
15259         * tests/test-mbrtoc32.c: Add comment.
15260         * tests/test-mbrtoc32-5.sh: Use symmetric coding style.
15261         * doc/posix-functions/mbrtoc32.texi: Update.
15263 2023-04-02  Bruno Haible  <bruno@clisp.org>
15265         trim: Fix trim_trailing result in multibyte locales.
15266         * lib/trim.c (trim2): Simplify algorithm for trim_trailing in multibyte
15267         locales, to use 2 instead of 3 states.
15268         (IF_LINT): Remove macro.
15270         trim: Add tests.
15271         * tests/test-trim.c: New file.
15272         * tests/test-trim1.sh: New file.
15273         * tests/test-trim2.sh: New file.
15274         * tests/test-trim3.sh: New file.
15275         * modules/trim-tests: New file.
15277 2023-04-02  Bruno Haible  <bruno@clisp.org>
15279         unistr/u8-strstr: Simplify code.
15280         * lib/unistr/u8-strstr.c: Inline the contents of lib/unistr/u-strstr.h.
15281         * lib/unistr/u-strstr.h: Remove file.
15282         * modules/unistr/u8-strstr (Files): Remove it.
15284         unistr/u{16,32}-strstr: Use two-way algorithm (no memory allocation).
15285         * lib/wcs-two-way.h: Use UNIT instead of wchar_t. Don't undefine
15286         RETURN_TYPE.
15287         * lib/wcsstr-impl.h: Move the non-linear implementation away. Use UNIT
15288         instead of wchar_t, RETURN_TYPE instead of 'wchar_t *', FUNC instead of
15289         wcsstr.
15290         (AVAILABLE): Use MEMCHR0 instead of wmemchr.
15291         (FUNC): Use STRCHR instead of wcschr.
15292         * lib/wcsstr.c: Moved the non-linear implementation to here.
15293         (FUNC, UNIT, RETURN_TYPE, MEMCHR0, STRCHR): New macros.
15294         * lib/unistr/u16-strstr.c: Don't include malloca.h, str-kmp.h,
15295         u-strstr.h. Instead, include wcsstr-impl.h.
15296         * lib/unistr/u32-strstr.c: Likewise.
15297         * modules/unistr/u16-strstr (Files): Remove u-strstr.h, str-kmp.h. Add
15298         wcsstr-impl.h, wcs-two-way.h.
15299         (Depends-on): Remove u16-strmbtouc, u16-strlen, u16-strnlen, malloca.
15300         Add u16-chr, u16-cmp.
15301         * modules/unistr/u32-strstr (Files): Remove u-strstr.h, str-kmp.h. Add
15302         wcsstr-impl.h, wcs-two-way.h.
15303         (Depends-on): Remove u32-strlen, u32-strnlen, malloca. Add u32-chr,
15304         u32-cmp.
15306 2023-04-02  Bruno Haible  <bruno@clisp.org>
15308         unistr/u*strstr tests: Add more tests.
15309         * tests/unistr/test-u-strstr.h (test_u_strstr): Add the two latest tests
15310         from tests/test-strstr.c.
15311         * tests/unistr/test-u8-strstr.c (U_SET): New macro.
15312         * tests/unistr/test-u16-strstr.c (U_SET): New macro.
15313         * tests/unistr/test-u32-strstr.c (U_SET): New macro.
15314         * modules/unistr/u8-strstr-tests (Depends-on): Add unistr/u8-set.
15315         * modules/unistr/u16-strstr-tests (Depends-on): Add unistr/u16-set.
15316         * modules/unistr/u32-strstr-tests (Depends-on): Add unistr/u32-set.
15318 2023-04-01  Bruno Haible  <bruno@clisp.org>
15320         vasnwprintf-posix: Fix behaviour in the C locale.
15321         * lib/vasnprintf.c (VASNPRINTF): If NEED_WPRINTF_DIRECTIVE_C is set,
15322         implement the 'c' directive here.
15323         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke gl_MBRTOWC_C_LOCALE.
15324         If mbrtowc is buggy in the C locale, define NEED_WPRINTF_DIRECTIVE_C.
15325         * modules/vasnwprintf (Files): Add m4/mbrtowc.m4.
15326         * tests/test-vasnwprintf-posix.c (test_function): Add tests of %s and %c
15327         in the C locale.
15328         * doc/posix-functions/fwprintf.texi: Mention the C locale behaviour bug.
15329         * doc/posix-functions/swprintf.texi: Likewise.
15330         * doc/posix-functions/vfwprintf.texi: Likewise.
15331         * doc/posix-functions/vswprintf.texi: Likewise.
15332         * doc/posix-functions/vwprintf.texi: Likewise.
15333         * doc/posix-functions/wprintf.texi: Likewise.
15335 2023-04-01  Bruno Haible  <bruno@clisp.org>
15337         vasnprintf-posix: Fix crash in narrow %lc directive (regr. 2023-03-21).
15338         * lib/vasnprintf.c (VASNPRINTF): Negative results of local_wcrtomb can
15339         now occur; handle them.
15340         * tests/test-vasnprintf-posix.c (test_function): Test %lc directive with
15341         a wint_t argument that is not a valid wide character.
15342         * tests/test-snprintf-posix.h (test_function): Likewise.
15343         * tests/test-sprintf-posix.h (test_function): Likewise.
15344         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
15345         * tests/test-vasprintf-posix.c (test_function): Likewise.
15347 2023-04-01  Bruno Haible  <bruno@clisp.org>
15349         stddef: Fix __need_wint_t handling in case of two stddef.h overrides.
15350         * lib/stddef.in.h: Replace _GL_STDDEF_WINT_T with a symbol that depends
15351         on the @GUARD_PREFIX@.
15353 2023-03-31  Bruno Haible  <bruno@clisp.org>
15355         vasnwprintf: Fix crash upon conversion failure when processing %s.
15356         * lib/vasnprintf.c (VASNPRINTF): When processing %s with !has_precision
15357         and !has_width, don't call abort() if there is a conversion failure.
15359 2023-03-30  Bruno Haible  <bruno@clisp.org>
15361         Avoid test failures on Android.
15362         * tests/test-btowc.c (main): Treat C locale like in
15363         tests/test-mbrtowc.c.
15364         * tests/test-mbsrtowcs.c (main): Likewise.
15365         * tests/test-mbsnrtowcs.c (main): Likewise.
15366         * tests/test-mbstowcs.c (main): Likewise.
15368 2023-03-30  Bruno Haible  <bruno@clisp.org>
15370         mbstowcs: Add tests.
15371         * tests/test-mbstowcs1.sh: New file, based on tests/test-mbsrtowcs1.sh.
15372         * tests/test-mbstowcs2.sh: New file, based on tests/test-mbsrtowcs2.sh.
15373         * tests/test-mbstowcs3.sh: New file, based on tests/test-mbsrtowcs3.sh.
15374         * tests/test-mbstowcs4.sh: New file, based on tests/test-mbsrtowcs4.sh.
15375         * tests/test-mbstowcs5.sh: New file, based on tests/test-mbsrtowcs5.sh.
15376         * tests/test-mbstowcs.c: New file, based on tests/test-mbsrtowcs.c.
15377         * modules/mbstowcs-tests: New file, based on modules/mbsrtowcs-tests.
15379         mbstowcs: New module.
15380         * lib/stdlib.in.h (mbstowcs): New declaration.
15381         * lib/mbstowcs.c: New file, based on lib/mbstoc32s.c.
15382         * m4/mbstowcs.m4: New file.
15383         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether mbstowcs is declared.
15384         (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_MBSTOWCS.
15385         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MBSTOWCS.
15386         * modules/stdlib (Makefile.am): Substitute GNULIB_MBSTOWCS,
15387         REPLACE_MBSTOWCS.
15388         * modules/mbstowcs: New file.
15389         * tests/test-stdlib-c++.cc (mbstowcs): Check signature.
15390         * doc/posix-functions/mbstowcs.texi: Mention the C locale behaviour bug
15391         and the new module.
15393 2023-03-30  Bruno Haible  <bruno@clisp.org>
15395         mbsnrtowcs: Fix behaviour in the C locale.
15396         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Invoke gl_MBRTOWC_C_LOCALE. If
15397         mbrtowc is buggy in the C locale, override also mbsnrtowcs.
15398         * modules/mbsnrtowcs (Files): Add m4/mbrtowc.m4.
15399         * tests/test-mbsnrtowcs.c (main): Add a test of the C locale, based on
15400         tests/test-mbsrtowcs.c.
15401         * tests/test-mbsnrtowcs5.sh: New file, based on tests/test-mbrtowc5.sh.
15402         * modules/mbsnrtowcs-tests (Files): Add it.
15403         (Makefile.am): Test it.
15404         * doc/posix-functions/mbsnrtowcs.texi: Mention the C locale behaviour
15405         bug.
15407 2023-03-30  Bruno Haible  <bruno@clisp.org>
15409         mbsrtowcs: Fix behaviour in the C locale.
15410         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Invoke gl_MBRTOWC_C_LOCALE. If
15411         mbrtowc is buggy in the C locale, override also mbsrtowcs.
15412         * modules/mbsrtowcs (Files): Add m4/mbrtowc.m4.
15413         * tests/test-mbsrtowcs.c (main): Add a test of the C locale, based on
15414         tests/test-mbrtowc.c.
15415         * tests/test-mbsrtowcs5.sh: New file, based on tests/test-mbrtowc5.sh.
15416         * modules/mbsrtowcs-tests (Files): Add it.
15417         (Makefile.am): Test it.
15418         * doc/posix-functions/mbsrtowcs.texi: Mention the C locale behaviour
15419         bug.
15421 2023-03-30  Bruno Haible  <bruno@clisp.org>
15423         mbrlen: Add tests.
15424         * tests/test-mbrlen1.sh: New file, based on tests/test-mbrtowc1.sh.
15425         * tests/test-mbrlen2.sh: New file, based on tests/test-mbrtowc2.sh.
15426         * tests/test-mbrlen3.sh: New file, based on tests/test-mbrtowc3.sh.
15427         * tests/test-mbrlen4.sh: New file, based on tests/test-mbrtowc4.sh.
15428         * tests/test-mbrlen5.sh: New file, based on tests/test-mbrtowc5.sh.
15429         * tests/test-mbrlen.c: New file, based on tests/test-mbrtowc.c.
15430         * tests/test-mbrlen-w32-1.sh: New file, based on
15431         tests/test-mbrtowc-w32-1.sh.
15432         * tests/test-mbrlen-w32-2.sh: New file, based on
15433         tests/test-mbrtowc-w32-2.sh.
15434         * tests/test-mbrlen-w32-3.sh: New file, based on
15435         tests/test-mbrtowc-w32-3.sh.
15436         * tests/test-mbrlen-w32-4.sh: New file, based on
15437         tests/test-mbrtowc-w32-4.sh.
15438         * tests/test-mbrlen-w32-5.sh: New file, based on
15439         tests/test-mbrtowc-w32-5.sh.
15440         * tests/test-mbrlen-w32-6.sh: New file, based on
15441         tests/test-mbrtowc-w32-6.sh.
15442         * tests/test-mbrlen-w32-7.sh: New file, based on
15443         tests/test-mbrtowc-w32-7.sh.
15444         * tests/test-mbrlen-w32.c: New file, based on tests/test-mbrtowc-w32.c.
15445         * modules/mbrlen-tests: New file, based on modules/mbrtowc-tests.
15446         * doc/posix-functions/mbrlen.texi: Update.
15448 2023-03-30  Bruno Haible  <bruno@clisp.org>
15450         btowc: Fix behaviour in the C locale.
15451         * lib/btowc.c: Include <string.h>
15452         (btowc): Use mbrtowc instead of mbtowc when possible.
15453         * m4/btowc.m4 (gl_FUNC_BTOWC): Test for the mingw bug in the C locale.
15454         Invoke gl_MBRTOWC_C_LOCALE. If mbrtowc is buggy in the C locale,
15455         override also btowc.
15456         (gl_PREREQ_BTOWC): Test whether mbrtowc exists.
15457         * modules/btowc (Files): Add m4/mbrtowc.m4.
15458         (Depends-on): Add mbrtowc.
15459         * tests/test-btowc.c (main): Add a test of the C locale, based on
15460         tests/test-mbrtowc.c.
15461         * tests/test-btowc3.sh: New file, based on tests/test-mbrtowc5.sh.
15462         * modules/btowc-tests (Files): Add it.
15463         (Makefile.am): Test it.
15464         * doc/posix-functions/btowc.texi: Mention the two C locale behaviour
15465         bugs and that they are worked around.
15467 2023-03-30  Bruno Haible  <bruno@clisp.org>
15469         mbrtowc tests: Add comment.
15470         * tests/test-mbrtowc.c: Add comment.
15471         * tests/test-mbrtowc5.sh: Use symmetric coding style.
15472         * doc/posix-functions/mbrtowc.texi: Update.
15474 2023-03-30  Bruno Haible  <bruno@clisp.org>
15476         stdlib tests: Check behaviour of C locale.
15477         * tests/test-stdlib.c (main): Check MB_CUR_MAX.
15479 2023-03-30  Bruno Haible  <bruno@clisp.org>
15481         string-desc tests: Fix "make distcheck" failure.
15482         * tests/test-string-desc.sh: Run the test in a subdir.
15484 2023-03-30  Bruno Haible  <bruno@clisp.org>
15486         snprintf: Avoid autoconf warning regarding gl_PRINTF_POSITIONS.
15487         * m4/printf.m4 (gl_PRINTF_POSITIONS): Define through AC_DEFUN_ONCE.
15489 2023-03-28  Bruno Haible  <bruno@clisp.org>
15491         doc: Document string-desc and related modules.
15492         * doc/string-desc.texi: New file.
15493         * doc/gnulib.texi (Particular Modules): Include it.
15495         string-desc-quotearg: Add tests.
15496         * tests/test-string-desc-quotearg.c: New file.
15497         * modules/string-desc-quotearg-tests: New file.
15499         string-desc-quotearg: New module.
15500         * lib/string-desc-quotearg.h: New file.
15501         * lib/string-desc-quotearg.c: New file.
15502         * modules/string-desc-quotearg: New file.
15504         xstring-desc: Add tests.
15505         * tests/test-xstring-desc.c: New file.
15506         * modules/xstring-desc-tests: New file.
15508         xstring-desc: New module.
15509         * lib/xstring-desc.h: New file.
15510         * lib/xstring-desc.c: New file.
15511         * modules/xstring-desc: New file.
15513         string-desc: Add tests.
15514         * tests/test-string-desc.sh: New file.
15515         * tests/test-string-desc.c: New file.
15516         * modules/string-desc-tests: New file.
15518         string-desc: New module.
15519         * lib/string-desc.h: New file.
15520         * lib/string-desc.c: New file.
15521         * lib/string-desc-contains.c: New file.
15522         * modules/string-desc: New file.
15524 2023-03-28  Bruno Haible  <bruno@clisp.org>
15526         doc: Fix placement of memset_explicit node.
15527         * doc/posix-functions/memset_explicit.texi: Define a section, not a
15528         subsection.
15530 2023-03-28  Bruno Haible  <bruno@clisp.org>
15532         doc: Update regarding linear string search.
15533         * doc/glibc-functions/memmem.texi: Update platforms list.
15534         * doc/posix-functions/strstr.texi: Likewise.
15535         * doc/glibc-functions/strcasestr.texi: Likewise.
15537 2023-03-27  Bruno Haible  <bruno@clisp.org>
15539         ialloc: Add comments.
15540         * lib/ialloc.h (imalloc, irealloc, icalloc, ireallocarray): Add
15541         comments.
15543 2023-03-27  Paul Eggert  <eggert@cs.ucla.edu>
15545         Support FALLTHROUGH macro better in glibc+clang.
15546         * lib/fnmatch.c (FALLTHROUGH): Use __attribute__ ((__fallthrough__))
15547         also in clang >= 10.
15548         * lib/fts.c (FALLTHROUGH): Likewise.
15549         * lib/regex_internal.h (FALLTHROUGH): Likewise.
15551 2023-03-27  Bruno Haible  <bruno@clisp.org>
15553         wcsstr: Ensure worst-case linear execution time.
15554         * lib/wchar.in.h (wcsstr): Consider REPLACE_WCSSTR.
15555         * lib/wcs-two-way.h: New file, based on lib/str-two-way.h.
15556         * lib/wcsstr-impl.h: If requested, use the two-way algorithm. New code
15557         based on lib/strstr.c.
15558         * m4/wcsstr.m4 (gl_FUNC_WCSSTR_SIMPLE): Renamed from gl_FUNC_WCSSTR.
15559         (gl_FUNC_WCSSTR): New macro, based on gl_FUNC_STRSTR in m4/strstr.m4.
15560         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSSTR.
15561         * modules/wchar (Makefile.am): Substitute REPLACE_WCSSTR.
15562         * modules/wcsstr-simple: New file, based on modules/wcsstr.
15563         * modules/wcsstr (Description): Document that this module now provides
15564         an efficient implementation.
15565         (Files): Add lib/wcs-two-way.h.
15566         (Depends-on): Depend on wcsstr-simple and the dependencies of the
15567         two-way implementation.
15568         (configure.ac): Use AC_LIBOBJ instead of a conditional. Don't invoke
15569         gl_WCHAR_MODULE_INDICATOR.
15570         (Makefile.am): Don't augment lib_SOURCES.
15571         * tests/test-wcsstr.c: New file, based on tests/test-strstr.c.
15572         * modules/wcsstr-tests: New file, based on modules/strstr-tests.
15573         * doc/posix-functions/wcsstr.texi: Mention the worst-case complexity.
15574         Mention the new 'wcsstr-simple' module.
15575         * doc/posix-functions/strstr.texi: Fix typo.
15577 2023-03-27  Bruno Haible  <bruno@clisp.org>
15579         Add test case from a past musl libc bug.
15580         * tests/test-strstr.c (main): Add test of periodic needle.
15581         * tests/test-strcasestr.c (main): Likewise.
15582         * tests/test-c-strstr.c (main): Likewise.
15583         * tests/test-c-strcasestr.c (main): Likewise.
15584         * tests/test-memmem.c (main): Likewise.
15586 2023-03-27  Bruno Haible  <bruno@clisp.org>
15588         uchar: ISO C 23: Define char8_t.
15589         * lib/uchar.in.h (char8_t): New type or macro.
15590         * m4/uchar_h.m4 (gl_TYPE_CHAR8_T): New macro.
15591         (gl_UCHAR_H): Invoke it. Set CXX_HAS_CHAR8_TYPE.
15592         * modules/uchar (Makefile.am): Substitute CXX_HAS_CHAR8_TYPE,
15593         GNULIBHEADERS_OVERRIDE_CHAR8_T.
15594         * tests/test-uchar.c: Add tests for char8_t.
15596 2023-03-25  Bruno Haible  <bruno@clisp.org>
15598         stdlib: ISO C 23: Document issue with once_flag and call_once.
15599         * doc/posix-headers/stdlib.texi: Document issue and workaround.
15601 2023-03-25  Bruno Haible  <bruno@clisp.org>
15603         call_once: New module, separate from mtx.
15604         * lib/threads.in.h (call_once): Declare as part of module 'call_once',
15605         not module 'mtx'.
15606         * lib/call_once.c: New file, extracted from lib/mtx.c.
15607         * lib/mtx.c (call_once): Remove function.
15608         * m4/threads_h.m4 (gl_THREADS_H_REQUIRE_DEFAULTS): Inititalize
15609         GNULIB_CALL_ONCE.
15610         * modules/threads-h (Makefile.am): Substitute GNULIB_CALL_ONCE.
15611         * modules/call_once: New file, based on modules/mtx.
15612         * modules/threads (Depends-on): Add call_once.
15613         * tests/test-threads-c++.cc: Update accordingly.
15614         * modules/call_once-tests: New file, based on modules/mtx-tests.
15615         * modules/mtx-tests (Files): Remove tests/test-call_once.c.
15616         (Makefile.am): Don't compile test-call_once.
15617         * doc/posix-functions/call_once.texi: Document that the relevant module
15618         is now 'call_once'.
15619         * NEWS: Mention the change.
15621 2023-03-25  Bruno Haible  <bruno@clisp.org>
15623         stdio: ISO C 23: Define _PRINTF_NAN_LEN_MAX.
15624         * lib/stdio.in.h (_PRINTF_NAN_LEN_MAX): New macro.
15625         * m4/stdio_h.m4 (gl_STDIO_H): Invoke gl_MUSL_LIBC.
15626         * modules/stdio (Files): Add m4/musl.m4.
15627         * tests/test-stdio.c: Check that _PRINTF_NAN_LEN_MAX is defined.
15628         Include nan.h, macros.h.
15629         (main): Check the value of _PRINTF_NAN_LEN_MAX.
15630         * modules/stdio-tests (Files): Add tests/nan.h, tests/macros.h,
15631         m4/exponentd.m4.
15632         (configure.ac): Invoke gl_DOUBLE_EXPONENT_LOCATION.
15634 2023-03-25  Bruno Haible  <bruno@clisp.org>
15636         Make some header file tests a bit stronger.
15637         * tests/test-float.c: Include fpucw.h and macros.h only after checking
15638         the macros.
15639         * tests/test-glob-h.c: Include macros.h only after checking the types
15640         and macros.
15641         * tests/test-inttypes.c: Don't include <stddef.h>.
15642         * tests/test-math.c: Include <limits.h> and macros.h only after checking
15643         the types and macros.
15644         * tests/test-stddef.c: Include <limits.h> only after checking the types
15645         and macros.
15646         * tests/test-sys_select.c: Include signature.h only after checking the
15647         types.
15648         * tests/test-sys_socket.c: Include <errno.h> only after checking the
15649         types and macros.
15650         * tests/test-wctype-h.c: Include macros.h only after checking the types.
15652 2023-03-25  Bruno Haible  <bruno@clisp.org>
15654         is* tests: Ensure needed .m4 files are packaged.
15655         * modules/isfinite-tests (Files): Add m4/exponent*.m4.
15656         * modules/isnan-tests (Files): Likewise.
15657         * modules/isnanf-tests (Files): Add m4/exponentf.m4.
15658         * modules/isnanf-nolibm-tests (Files): Likewise.
15659         * modules/isnand-tests (Files): Add m4/exponentd.m4.
15660         * modules/isnand-nolibm-tests (Files): Likewise.
15661         * modules/isnanl-tests (Files): Add m4/exponentl.m4.
15662         * modules/isnanl-nolibm-tests (Files): Likewise.
15663         * modules/isinf-tests (Files): Reorder.
15665 2023-03-24  Bruno Haible  <bruno@clisp.org>
15667         *printf-posix: ISO C 23: Support size specifiers 'wN' and 'wfN'.
15668         * lib/printf-args.h: Include <stdint.h>.
15669         (arg_type): Add TYPE_[U]INT8_T, ..., TYPE_[U]INT_FAST64_T and
15670         TYPE_COUNT_INT8_T_POINTER, ..., TYPE_COUNT_INT_FAST64_T_POINTER.
15671         (argument): Add the union members a_[u]int8_t, ..., a_[u]int_fast64_t
15672         and a_count_int8_t_pointer, ..., a_count_int_fast64_t_pointer.
15673         * lib/printf-args.c: Include <limits.h>.
15674         (PRINTF_FETCHARGS): Handle TYPE_[U]INT8_T, ..., TYPE_[U]INT_FAST64_T and
15675         TYPE_COUNT_INT8_T_POINTER, ..., TYPE_COUNT_INT_FAST64_T_POINTER.
15676         * lib/printf-parse.c (PRINTF_PARSE): Accept only one size specifier, not
15677         a sequence of size specifiers. Accept "wN" and "wfN", where N = 8, 16,
15678         32, 64.
15679         * lib/vasnprintf.c (MAX_ROOM_NEEDED, VASNPRINTF): Handle the new TYPE_*
15680         values as well.
15681         * m4/printf.m4 (gl_PRINTF_SIZES_C23): New macro.
15682         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Require
15683         gl_PRINTF_SIZES_C23. Test gl_cv_func_printf_sizes_c23.
15684         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): Likewise.
15685         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
15686         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX):
15687         Likewise.
15688         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): Likewise.
15689         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
15690         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
15691         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
15692         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
15693         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
15694         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
15695         * tests/test-vasnprintf-posix.c (test_function): Add tests for size
15696         specifiers with %d, %u, %b, %o, %x.
15697         * tests/test-snprintf-posix.h (test_function): Likewise.
15698         * tests/test-sprintf-posix.h (test_function): Likewise.
15699         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
15700         * tests/test-vasprintf-posix.c (test_function): Likewise.
15701         * modules/vasnprintf (Depends-on): Add limits-h.
15702         * modules/vasnwprintf (Depends-on): Add limits-h.
15703         * modules/c-vasnprintf (Depends-on): Add limits-h, stdint.
15704         * modules/unistdio/u-printf-args (Depends-on): Add stdint, limits-h.
15705         * doc/posix-functions/dprintf.texi: Mention the ISO C 23 size
15706         specifiers.
15707         * doc/posix-functions/fprintf.texi: Likewise.
15708         * doc/posix-functions/fwprintf.texi: Likewise.
15709         * doc/posix-functions/printf.texi: Likewise.
15710         * doc/posix-functions/snprintf.texi: Likewise.
15711         * doc/posix-functions/sprintf.texi: Likewise.
15712         * doc/posix-functions/swprintf.texi: Likewise.
15713         * doc/posix-functions/vdprintf.texi: Likewise.
15714         * doc/posix-functions/vfprintf.texi: Likewise.
15715         * doc/posix-functions/vfwprintf.texi: Likewise.
15716         * doc/posix-functions/vprintf.texi: Likewise.
15717         * doc/posix-functions/vsnprintf.texi: Likewise.
15718         * doc/posix-functions/vsprintf.texi: Likewise.
15719         * doc/posix-functions/vswprintf.texi: Likewise.
15720         * doc/posix-functions/vwprintf.texi: Likewise.
15721         * doc/posix-functions/wprintf.texi: Likewise.
15723 2023-03-24  Bruno Haible  <bruno@clisp.org>
15725         xprintf-gnu: New module.
15726         * modules/xprintf-gnu: New file, based on modules/vasnprintf-gnu and
15727         modules/xprintf-posix.
15729 2023-03-24  Bruno Haible  <bruno@clisp.org>
15731         xvasprintf-gnu: New module.
15732         * modules/xvasprintf-gnu: New file, based on modules/xvasprintf-posix.
15734 2023-03-24  Bruno Haible  <bruno@clisp.org>
15736         vasnwprintf-gnu: Add tests.
15737         * tests/test-vasnwprintf-gnu.c: New file, based on
15738         tests/test-vasnwprintf-posix.c and tests/test-vasnprintf-gnu.c.
15739         * modules/vasnwprintf-gnu-tests: New file, based on
15740         modules/vasnwprintf-posix-tests.
15742         vasnwprintf-gnu: New module.
15743         * m4/vasnwprintf-posix.m4 (gl_FUNC_VASNWPRINTF_IS_POSIX): New macro.
15744         (gl_FUNC_VASNWPRINTF_POSIX): Require it. Invoke
15745         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15746         * m4/vasnwprintf-gnu.m4: New file, based on m4/vasnprintf-gnu.m4.
15747         * modules/vasnwprintf-gnu: New file, based on modules/vasnprintf-gnu.
15749 2023-03-24  Bruno Haible  <bruno@clisp.org>
15751         obstack-printf-gnu: Add tests.
15752         * modules/obstack-printf-gnu-tests: New file, based on
15753         modules/obstack-printf-posix-tests.
15755         obstack-printf-gnu: New module.
15756         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX): New
15757         macro, extracted from gl_FUNC_OBSTACK_PRINTF_POSIX.
15758         (gl_FUNC_OBSTACK_PRINTF_POSIX): Require it. Invoke
15759         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15760         * m4/obstack-printf-gnu.m4: New file, based on
15761         m4/obstack-printf-posix.m4.
15762         * modules/obstack-printf-gnu: New file, based on modules/vasnprintf-gnu.
15763         * doc/glibc-functions/obstack_printf.texi: Mention the new module.
15764         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
15766 2023-03-24  Bruno Haible  <bruno@clisp.org>
15768         dprintf-gnu: Add tests.
15769         * tests/test-dprintf-gnu.sh: New file, based on
15770         tests/test-dprintf-posix.sh.
15771         * tests/test-dprintf-gnu.c: New file, based on
15772         tests/test-vasnprintf-gnu.c.
15773         * modules/dprintf-gnu-tests: New file, based on
15774         modules/dprintf-posix-tests.
15776         dprintf-gnu: New module.
15777         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): New macro,
15778         extracted from gl_FUNC_DPRINTF_POSIX.
15779         (gl_FUNC_DPRINTF_POSIX): Require it. Invoke
15780         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15781         * m4/dprintf-gnu.m4: New file, based on m4/dprintf-posix.m4.
15782         * modules/dprintf-gnu: New file, based on modules/vasnprintf-gnu.
15783         * doc/posix-functions/dprintf.texi: Mention the new module.
15785 2023-03-24  Bruno Haible  <bruno@clisp.org>
15787         vdprintf-gnu: Add tests.
15788         * tests/test-vdprintf-gnu.sh: New file, based on
15789         tests/test-vdprintf-posix.sh.
15790         * tests/test-vdprintf-gnu.c: New file, based on
15791         tests/test-vdprintf-posix.c.
15792         * modules/vdprintf-gnu-tests: New file, based on
15793         modules/vdprintf-posix-tests.
15795         vdprintf-gnu: New module.
15796         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): New macro,
15797         extracted from gl_FUNC_VDPRINTF_POSIX.
15798         (gl_FUNC_VDPRINTF_POSIX): Require it. Invoke
15799         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15800         * m4/vdprintf-gnu.m4: New file, based on m4/vdprintf-posix.m4.
15801         * modules/vdprintf-gnu: New file, based on modules/vasnprintf-gnu.
15802         * doc/posix-functions/vdprintf.texi: Mention the new module.
15804 2023-03-24  Bruno Haible  <bruno@clisp.org>
15806         printf-gnu: Add tests.
15807         * tests/test-printf-gnu.sh: New file, based on
15808         tests/test-printf-posix.sh.
15809         * tests/test-printf-gnu.c: New file, based on tests/test-printf-posix.c.
15810         * modules/printf-gnu-tests: New file, based on
15811         modules/printf-posix-tests.
15813         printf-gnu: New module.
15814         * m4/printf-posix.m4: Renamed from m4/printf-posix-rpl.m4.
15815         (gl_FUNC_PRINTF_IS_POSIX): New macro.
15816         (gl_FUNC_PRINTF_POSIX): Require it. Don't require
15817         gl_FUNC_VFPRINTF_POSIX. Invoke gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS
15818         and gl_REPLACE_VASNPRINTF.
15819         * m4/printf-gnu.m4: New file, based on m4/fprintf-posix.m4.
15820         * modules/printf-posix (Files): Update.
15821         * modules/printf-gnu: New file, based on modules/vasnprintf-gnu.
15822         * doc/posix-functions/printf.texi: Mention the new module.
15824 2023-03-24  Bruno Haible  <bruno@clisp.org>
15826         vprintf-gnu: Add tests.
15827         * tests/test-vprintf-gnu.sh: New file, based on
15828         tests/test-vprintf-posix.sh.
15829         * tests/test-vprintf-gnu.c: New file, based on
15830         tests/test-vprintf-posix.c.
15831         * tests/test-printf-gnu.h: New file, based on
15832         tests/test-vasnprintf-gnu.c.
15833         * modules/vprintf-gnu-tests: New file, based on
15834         modules/vprintf-posix-tests.
15836         vprintf-gnu: New module.
15837         * m4/vprintf-posix.m4 (gl_FUNC_VPRINTF_IS_POSIX): New macro.
15838         (gl_FUNC_VPRINTF_POSIX): Require it. Don't require
15839         gl_FUNC_VFPRINTF_POSIX. Invoke gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS
15840         and gl_REPLACE_VASNPRINTF.
15841         * m4/vprintf-gnu.m4: New file, based on m4/vfprintf-posix.m4.
15842         * modules/vprintf-gnu: New file, based on modules/vasnprintf-gnu.
15843         * doc/posix-functions/vprintf.texi: Mention the new module.
15845 2023-03-24  Bruno Haible  <bruno@clisp.org>
15847         fprintf-gnu: Add tests.
15848         * tests/test-fprintf-gnu.sh: New file, based on
15849         tests/test-fprintf-posix.sh.
15850         * tests/test-fprintf-gnu.c: New file, based on
15851         tests/test-fprintf-posix.c.
15852         * modules/fprintf-gnu-tests: New file, based on
15853         modules/fprintf-posix-tests.
15855         fprintf-gnu: New module.
15856         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): New macro,
15857         extracted from gl_FUNC_FPRINTF_POSIX.
15858         (gl_FUNC_FPRINTF_POSIX): Require it. Invoke
15859         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15860         * m4/fprintf-gnu.m4: New file, based on m4/fprintf-posix.m4.
15861         * modules/fprintf-gnu: New file, based on modules/vasnprintf-gnu.
15862         * doc/posix-functions/fprintf.texi: Mention the new module.
15864 2023-03-24  Bruno Haible  <bruno@clisp.org>
15866         vfprintf-gnu: Add tests.
15867         * tests/test-vfprintf-gnu.sh: New file, based on
15868         tests/test-vfprintf-posix.sh.
15869         * tests/test-vfprintf-gnu.c: New file, based on
15870         tests/test-vfprintf-posix.c.
15871         * tests/test-fprintf-gnu.h: New file, based on
15872         tests/test-vasnprintf-gnu.c.
15873         * tests/test-printf-gnu.output: New file, based on
15874         tests/test-vasnprintf-gnu.c.
15875         * modules/vfprintf-gnu-tests: New file, based on
15876         modules/vfprintf-posix-tests.
15878         vfprintf-gnu: New module.
15879         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): New macro,
15880         extracted from gl_FUNC_VFPRINTF_POSIX.
15881         (gl_FUNC_VFPRINTF_POSIX): Require it. Invoke
15882         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15883         * m4/vfprintf-gnu.m4: New file, based on m4/vfprintf-posix.m4.
15884         * modules/vfprintf-gnu: New file, based on modules/vasnprintf-gnu.
15885         * doc/posix-functions/vfprintf.texi: Mention the new module.
15887 2023-03-24  Bruno Haible  <bruno@clisp.org>
15889         vasprintf-gnu: Add tests.
15890         * tests/test-vasprintf-gnu.c: New file, based on
15891         tests/test-vasprintf-posix.c and tests/test-vasnprintf-gnu.c.
15892         * modules/vasprintf-gnu-tests: New file, based on
15893         modules/vasprintf-posix-tests.
15895         vasprintf-gnu: New module.
15896         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): New macro,
15897         extracted from gl_FUNC_VASPRINTF_POSIX.
15898         (gl_FUNC_VASPRINTF_POSIX): Require it. Invoke
15899         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15900         * m4/vasprintf-gnu.m4: New file, based on m4/vasprintf-posix.m4.
15901         * modules/vasprintf-gnu: New file, based on modules/vasnprintf-gnu.
15902         * doc/glibc-functions/vasprintf.texi: Mention the new module.
15903         * doc/glibc-functions/asprintf.texi: Likewise.
15905 2023-03-24  Bruno Haible  <bruno@clisp.org>
15907         sprintf-gnu: Add tests.
15908         * tests/test-sprintf-gnu.c: New file, based on
15909         tests/test-sprintf-posix.c.
15910         * modules/sprintf-gnu-tests: New file, based on
15911         modules/sprintf-posix-tests.
15913         sprintf-gnu: New module.
15914         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): New macro,
15915         extracted from gl_FUNC_SPRINTF_POSIX.
15916         (gl_FUNC_SPRINTF_POSIX): Require it. Invoke
15917         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15918         * m4/sprintf-gnu.m4: New file, based on m4/sprintf-posix.m4.
15919         * modules/sprintf-gnu: New file, based on modules/vasnprintf-gnu.
15920         * doc/posix-functions/sprintf.texi: Mention the new module.
15922 2023-03-24  Bruno Haible  <bruno@clisp.org>
15924         vsprintf-gnu: Add tests.
15925         * tests/test-vsprintf-gnu.c: New file, based on
15926         tests/test-vsprintf-posix.c.
15927         * tests/test-sprintf-gnu.h: New file, based on
15928         tests/test-vasnprintf-gnu.c.
15929         * modules/vsprintf-gnu-tests: New file, based on
15930         modules/vsprintf-posix-tests.
15932         vsprintf-gnu: New module.
15933         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): New macro,
15934         extracted from gl_FUNC_VSPRINTF_POSIX.
15935         (gl_FUNC_VSPRINTF_POSIX): Require it. Invoke
15936         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15937         * m4/vsprintf-gnu.m4: New file, based on m4/vsprintf-posix.m4.
15938         * modules/vsprintf-gnu: New file, based on modules/vasnprintf-gnu.
15939         * doc/posix-functions/vsprintf.texi: Mention the new module.
15941 2023-03-24  Bruno Haible  <bruno@clisp.org>
15943         snprintf-gnu: Add tests.
15944         * tests/test-snprintf-gnu.c: New file, based on
15945         tests/test-snprintf-posix.c.
15946         * modules/snprintf-gnu-tests: New file, based on
15947         modules/snprintf-posix-tests.
15949         snprintf-gnu: New module.
15950         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): New macro,
15951         extracted from gl_FUNC_SNPRINTF_POSIX.
15952         (gl_FUNC_SNPRINTF_POSIX): Require it. Invoke
15953         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15954         * m4/snprintf-gnu.m4: New file, based on m4/snprintf-posix.m4.
15955         * modules/snprintf-gnu: New file, based on modules/vasnprintf-gnu.
15956         * doc/posix-functions/snprintf.texi: Mention the new module.
15958 2023-03-24  Bruno Haible  <bruno@clisp.org>
15960         vsnprintf-gnu: Add tests.
15961         * tests/test-vsnprintf-gnu.c: New file, based on
15962         tests/test-vsnprintf-posix.c.
15963         * tests/test-snprintf-gnu.h: New file, based on
15964         tests/test-vasnprintf-gnu.c.
15965         * modules/vsnprintf-gnu-tests: New file, based on
15966         modules/vsnprintf-posix-tests.
15968         vsnprintf-gnu: New module.
15969         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): New macro,
15970         extracted from gl_FUNC_VSNPRINTF_POSIX.
15971         (gl_FUNC_VSNPRINTF_POSIX): Require it. Invoke
15972         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
15973         * m4/vsnprintf-gnu.m4: New file, based on m4/vsnprintf-posix.m4.
15974         * modules/vsnprintf-gnu: New file, based on modules/vasnprintf-gnu.
15975         * doc/posix-functions/vsnprintf.texi: Mention the new module.
15977 2023-03-23  Bruno Haible  <bruno@clisp.org>
15979         vasnprintf-gnu: Add tests.
15980         * tests/test-vasnprintf-gnu.c: New file, based on
15981         tests/test-vasnprintf-posix.c.
15982         * modules/vasnprintf-gnu-tests: New file.
15984         vasnprintf-gnu: New module.
15985         Suggested by Eric Blake in
15986         <https://lists.gnu.org/archive/html/bug-gnulib/2023-03/msg00060.html>.
15987         * lib/printf-parse.c (PRINTF_PARSE): Recognize the 'B' conversion.
15988         * lib/printf-parse.h: Update comments.
15989         * lib/wprintf-parse.h: Likewise.
15990         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Treat the 'B' conversion like 'b'.
15991         (VASNPRINTF): Implement 'B' conversion if
15992         NEED_PRINTF_DIRECTIVE_UPPERCASE_B is set. Support the 'B' conversion if
15993         requested.
15994         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_B): When cross-compiling, guess yes
15995         on glibc >= 2.35.
15996         (gl_PRINTF_DIRECTIVE_UPPERCASE_B): New macro.
15997         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS): Renamed
15998         from gl_PREREQ_VASNPRINTF_WITH_EXTRAS.
15999         (gl_PREREQ_VASNPRINTF_DIRECTIVE_UPPERCASE_B,
16000         gl_PREREQ_VASNPRINTF_WITH_GNU_EXTRAS): New macros.
16001         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): New macro,
16002         extracted from gl_FUNC_VASNPRINTF_POSIX.
16003         (gl_FUNC_VASNPRINTF_POSIX): Require it. Invoke
16004         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
16005         * m4/vasnprintf-gnu.m4: New file.
16006         * modules/vasnprintf-gnu: New file.
16007         * modules/c-vasnprintf (configure.ac): Update.
16008         * modules/unistdio/u8-vasnprintf (configure.ac): Likewise.
16009         * modules/unistdio/u8-u8-vasnprintf (configure.ac): Likewise.
16010         * modules/unistdio/u16-vasnprintf (configure.ac): Likewise.
16011         * modules/unistdio/u16-u16-vasnprintf (configure.ac): Likewise.
16012         * modules/unistdio/u32-vasnprintf (configure.ac): Likewise.
16013         * modules/unistdio/u32-u32-vasnprintf (configure.ac): Likewise.
16014         * modules/unistdio/ulc-vasnprintf (configure.ac): Likewise.
16016 2023-03-23  Bruno Haible  <bruno@clisp.org>
16018         printf-posix tests: Fix compilation error (regression 2021-08-28).
16019         * modules/printf-posix-tests (Files): Add tests/qemu.h.
16021 2023-03-22  Jim Meyering  <meyering@fb.com>
16023         gnu-web-doc-update: don't use host alias, cvs.sv.gnu.org
16024         * build-aux/gnu-web-doc-update: Use hostname cvs.savannah.gnu.org,
16025         not cvs.sv.gnu.org. Using the shorter alias would elicit this:
16026           $ pkg=grep ; cvs -d $USER@cvs.sv.gnu.org:/webcvs/$pkg co $pkg
16027           Bad server host key: Invalid key length
16029 2023-03-22  Bruno Haible  <bruno@clisp.org>
16031         *printf-posix: Fix implementation of %b directive.
16032         * lib/vasnprintf.c (VASNPRINTF): In the %b directive implementation, fix
16033         the precision handling, and ignore the '0' flag when a width and a
16034         precision are both present.
16035         * tests/test-snprintf-posix.h (test_function): Add test cases for the %x
16036         directive and more test cases for the %b directive.
16037         * tests/test-sprintf-posix.h (test_function): Likewise.
16038         * tests/test-vasnprintf-posix.c (test_function): Likewise.
16039         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
16040         * tests/test-vasprintf-posix.c (test_function): Likewise.
16041         * modules/vasnwprintf-posix-tests (Files): Add m4/musl.m4.
16042         (configure.ac): Invoke gl_MUSL_LIBC.
16044 2023-03-22  Bruno Haible  <bruno@clisp.org>
16046         vasnwprintf: Fix a warning: implicit declaration of function ‘wcsnlen’.
16047         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Test also whether wcsnlen is
16048         declared.
16049         * lib/vasnprintf.c (local_wcsnlen): Together with HAVE_WCSNLEN, test
16050         also HAVE_DECL_WCSNLEN.
16052 2023-03-22  Bruno Haible  <bruno@clisp.org>
16054         vasnwprintf: Fix a "warning: unused function local_wcsnlen".
16055         * lib/vasnprintf.c: Adjust #if conditions.
16057 2023-03-22  Bruno Haible  <bruno@clisp.org>
16059         vasnwprintf: Fix test failures on FreeBSD, NetBSD, AIX, mingw.
16060         * m4/printf.m4 (gl_SWPRINTF_WORKS): New macro.
16061         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke it and define
16062         HAVE_WORKING_SWPRINTF accordingly.
16063         * lib/vasnprintf.c: Together with HAVE_SWPRINTF, test also
16064         HAVE_WORKING_SWPRINTF.
16065         (VASNPRINTF): If WIDE_CHAR_VERSION && !DCHAR_IS_TCHAR, don't pass a
16066         wchar_t[] to snprintf. Add a workaround against mingw's snwprintf
16067         function.
16068         * doc/posix-functions/swprintf.texi: Document the null wide character
16069         bug.
16071 2023-03-22  Bruno Haible  <bruno@clisp.org>
16073         vasnwprintf: Fix a "warning: unused function 'wmax_room_needed'".
16074         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Adjust #if condition.
16076 2023-03-22  Bruno Haible  <bruno@clisp.org>
16078         vasnwprintf: Simplify last change.
16079         * lib/vasnprintf.c (VASNPRINTF): Remove unused variable 'len'.
16081 2023-03-22  Bruno Haible  <bruno@clisp.org>
16083         vasnwprintf tests: Fix link errors on AIX.
16084         * modules/vasnwprintf (Link): New section.
16085         * modules/vasnwprintf-posix (Link): New section.
16086         * modules/vasnwprintf-tests (Makefile.am): Link test-vasnwprintf with
16087         $(MBRTOWC_LIB).
16088         * modules/vasnwprintf-posix-tests (Makefile.am): Link
16089         test-vasnwprintf-posix, test-vasnwprintf-posix2, test-vasnwprintf-posix3
16090         with $(MBRTOWC_LIB).
16092 2023-03-22  Bruno Haible  <bruno@clisp.org>
16094         gnu-web-doc-update: Make it work for the first upload of a manual.
16095         Reported by Reuben Thomas <rrt@sc3d.org> in
16096         <https://lists.gnu.org/archive/html/bug-gnulib/2023-03/msg00066.html>.
16097         * build-aux/gnu-web-doc-update: Put the 'manual' directory under version
16098         control if it is not yet.
16100 2023-03-21  Bruno Haible  <bruno@clisp.org>
16102         unistdio/u*-vasnprintf: Fix conversion of %Id directive result.
16103         * lib/vasnprintf.c (VASNPRINTF): Don't assume that snprintf's result is
16104         entirely ASCII if the directive contain the glibc 'I' flag.
16106 2023-03-21  Bruno Haible  <bruno@clisp.org>
16108         vasnwprintf: Fix for older platforms without swprintf.
16109         * lib/vasnprintf.c (VASNPRINTF): In the %lc handling, ignore the
16110         precision. Convert the snprintf result to a wchar_t[] not by mbsrtowcs,
16111         but by a loop that does not stop at NUL characters.
16112         * tests/test-vasnwprintf-posix.c (test_function): Add more tests for the
16113         %c and %lc directives.
16114         * modules/vasnwprintf (Depends-on): Add mbrtowc. Remove mbsrtowcs.
16116 2023-03-21  Bruno Haible  <bruno@clisp.org>
16118         *printf-posix: Work around bug with %lc of 0 on many platforms.
16119         * lib/vasnprintf.c (local_wctomb): Define also for
16120         NEED_PRINTF_DIRECTIVE_LC.
16121         (VASNPRINTF): Implement %lc handling ourselves if
16122         NEED_PRINTF_DIRECTIVE_LC.
16123         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LC): New macro.
16124         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_LC): New macro.
16125         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
16126         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Require
16127         gl_PRINTF_DIRECTIVE_LC and test its result. Invoke
16128         gl_PREREQ_VASNPRINTF_DIRECTIVE_LC.
16129         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
16130         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
16131         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
16132         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
16133         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
16134         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
16135         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
16136         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
16137         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
16138         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
16139         * tests/test-snprintf-posix.h (test_function): Add more tests for the
16140         %c and %lc directives.
16141         * tests/test-sprintf-posix.h (test_function): Likewise.
16142         * tests/test-vasnprintf-posix.c (test_function): Likewise.
16143         * tests/test-vasprintf-posix.c (test_function): Likewise.
16144         * doc/glibc-functions/asprintf.texi: Mention the %lc 0 bug.
16145         * doc/glibc-functions/obstack_printf.texi: Likewise.
16146         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
16147         * doc/glibc-functions/vasprintf.texi: Likewise.
16148         * doc/posix-functions/dprintf.texi: Likewise.
16149         * doc/posix-functions/fprintf.texi: Likewise.
16150         * doc/posix-functions/printf.texi: Likewise.
16151         * doc/posix-functions/snprintf.texi: Likewise.
16152         * doc/posix-functions/sprintf.texi: Likewise.
16153         * doc/posix-functions/vdprintf.texi: Likewise.
16154         * doc/posix-functions/vfprintf.texi: Likewise.
16155         * doc/posix-functions/vprintf.texi: Likewise.
16156         * doc/posix-functions/vsnprintf.texi: Likewise.
16157         * doc/posix-functions/vsprintf.texi: Likewise.
16159 2023-03-21  Ar Rakin  <rakinar2@onesoftnet.eu.org>  (tiny change)
16161         gnupload: correct SFTP connection URL
16162         Approved by Sergey Poznyakoff in
16163         <https://lists.gnu.org/archive/html/bug-gnulib/2023-03/msg00078.html>.
16164         * build-aux/gnupload: fix gnu.org.ua SFTP connection URL:
16165         puszcza.gnu.org.ua -> download.gnu.org.ua
16167 2023-03-20  Bruno Haible  <bruno@clisp.org>
16169         memrchr tests: Avoid GCC warning.
16170         * tests/test-memrchr.c: Don't use '#pragma GCC diagnostic' for GCC
16171         versions older than 4.7.
16173 2023-03-20  Bruno Haible  <bruno@clisp.org>
16175         unistdio: Simplify code.
16176         * lib/unistdio/u8-vasnprintf.c (DCHAR_T_IS_UINT8_T): Remove unused
16177         macro.
16178         * lib/unistdio/u8-u8-vasnprintf.c: Likewise.
16179         * lib/unistdio/u16-vasnprintf.c (DCHAR_T_IS_UINT16_T): Remove unused
16180         macro.
16181         * lib/unistdio/u16-u32-vasnprintf.c: Likewise.
16182         * lib/unistdio/u32-vasnprintf.c (DCHAR_T_IS_UINT32_T): Remove unused
16183         macro.
16184         * lib/unistdio/u32-u32-vasnprintf.c: Likewise.
16186 2023-03-20  Bruno Haible  <bruno@clisp.org>
16188         vasnwprintf: Port to older platforms without swprintf.
16189         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Test for swprintf.
16190         * lib/vasnprintf.c (TCHAR_T, DCHAR_IS_TCHAR, SNPRINTF): When
16191         WIDE_CHAR_VERSION and swprintf does not exist, use TCHAR_T = char,
16192         SNPRINTF = snprintf, and !DCHAR_IS_TCHAR.
16193         (VASNPRINTF): In this case, implement %ls and %lc directly. Adjust a
16194         couple of #if conditions. For the conversion from TCHAR_T[] to
16195         DCHAR_T[], use mbsrtowcs.
16196         * modules/vasnwprintf (Depends-on): Add mbsrtowcs.
16198 2023-03-20  Bruno Haible  <bruno@clisp.org>
16200         wmemset: Relicense under LGPLv2+.
16201         * modules/wmemset (License): Change to LGPLv2+.
16202         * lib/wmemset.c: Update license notice.
16203         * lib/wmemset-impl.h: Likewise.
16205 2023-03-20  Bruno Haible  <bruno@clisp.org>
16207         wmemcpy: Relicense under LGPLv2+.
16208         * modules/wmemcpy (License): Change to LGPLv2+.
16209         * lib/wmemcpy.c: Update license notice.
16210         * lib/wmemcpy-impl.h: Likewise.
16212 2023-03-19  Bruno Haible  <bruno@clisp.org>
16214         vasnwprintf: Fix test failures on musl libc.
16215         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke gl_MUSL_LIBC.
16216         * lib/vasnprintf.c (VASNPRINTF): On musl libc, when WIDE_CHAR_VERSION,
16217         - force pad_ourselves to be 1,
16218         - don't use %n.
16219         Fix zero-padding when the result starts with a prefix "0x" or "0b".
16220         * modules/vasnwprintf (Files): Add musl.m4.
16221         * doc/posix-functions/swprintf.texi: Mention two musl libc bugs.
16223 2023-03-19  Bruno Haible  <bruno@clisp.org>
16225         vasnwprintf: Fix module dependencies.
16226         * modules/vasnwprintf (Depends-on): Add wmemcpy, wmemset.
16227         * modules/vasnwprintf-tests (Depends-on): Add wmemcmp.
16228         * modules/vasnwprintf-posix-tests (Depends-on): Likewise.
16230 2023-03-19  Paul Eggert  <eggert@cs.ucla.edu>
16232         test-pselect, test-select: use different ports
16233         I have observed rare and hard-to-reproduce problems with the GNU
16234         grep release candidate with ‘make -j5 check’ on Fedora 37 x86-64.
16235         One possibility is that test-pselect and test-select interfere
16236         with each other somehow when run simultaneously, as they use the
16237         same port.  Work around this possibility by using different ports
16238         from each other, and from test-poll (which also uses 12345).
16239         Of course it’d be better if all these tests used system-assigned
16240         ports, but I assume that’d take more work.
16241         * tests/test-pselect.c, tests/test-select.c (TEST_PORT): New macro.
16242         * tests/test-select.h (TEST_PORT): Remove.
16244 2023-03-19  Bruno Haible  <bruno@clisp.org>
16246         Update MODULES.html.sh.
16247         * MODULES.html.sh: Move stack, wmempcpy, bison to different sections.
16248         Fix a HTML layout problem.
16250 2023-03-18  Paul Eggert  <eggert@cs.ucla.edu>
16252         dfa: pacify Oracle Solaris Studio 12.6
16253         Without this patch, the compiler complains “statement not reached”.
16254         * lib/dfa.c (lex): Refactor to omit unreachable statement.
16256         Update MODULES.html.sh
16257         * MODULES.html.sh: Add some recently-added modules.
16258         This is by no means a complete update.  I needed to point
16259         to something about ‘time’ so I added ‘time’, and then added
16260         more modules until I ran out of, errr, time.
16261         Assuming MODULES.html.sh is still useful,
16262         at some point a more-complete update should be done.
16264 2023-03-17  Bruno Haible  <bruno@clisp.org>
16266         *printf-posix: ISO C 23: Add %b directive for binary output of integers.
16267         * lib/printf-parse.c (PRINTF_PARSE): Recognize the 'b' directive.
16268         * lib/printf-parse.h: Update comment.
16269         * lib/wprintf-parse.h: Likewise.
16270         * lib/vasnprintf.c (MAX_ROOM_NEEDED, VASNPRINTF): Add support for the
16271         'b' directive.
16272         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_B): New macro.
16273         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_B): New macro.
16274         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
16275         * m4/vasnwprintf-posix.m4 (gl_FUNC_VASNWPRINTF_POSIX): Invoke
16276         gl_PREREQ_VASNPRINTF_DIRECTIVE_B.
16277         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Require
16278         gl_PRINTF_DIRECTIVE_B and test its result. Invoke
16279         gl_PREREQ_VASNPRINTF_DIRECTIVE_B.
16280         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
16281         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
16282         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
16283         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
16284         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
16285         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
16286         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
16287         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
16288         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
16289         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
16290         * tests/test-snprintf-posix.h (test_function): Add some tests of the %b
16291         directive.
16292         * tests/test-sprintf-posix.h (test_function): Likewise.
16293         * tests/test-vasnprintf-posix.c (test_function): Likewise.
16294         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
16295         * tests/test-vasprintf-posix.c (test_function): Likewise.
16296         * doc/glibc-functions/asprintf.texi: Mention the 'b' directive.
16297         * doc/glibc-functions/obstack_printf.texi: Likewise.
16298         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
16299         * doc/glibc-functions/vasprintf.texi: Likewise.
16300         * doc/posix-functions/dprintf.texi: Likewise.
16301         * doc/posix-functions/fprintf.texi: Likewise.
16302         * doc/posix-functions/fwprintf.texi: Likewise.
16303         * doc/posix-functions/printf.texi: Likewise.
16304         * doc/posix-functions/snprintf.texi: Likewise.
16305         * doc/posix-functions/sprintf.texi: Likewise.
16306         * doc/posix-functions/swprintf.texi: Likewise.
16307         * doc/posix-functions/vdprintf.texi: Likewise.
16308         * doc/posix-functions/vfprintf.texi: Likewise.
16309         * doc/posix-functions/vfwprintf.texi: Likewise.
16310         * doc/posix-functions/vprintf.texi: Likewise.
16311         * doc/posix-functions/vsnprintf.texi: Likewise.
16312         * doc/posix-functions/vsprintf.texi: Likewise.
16313         * doc/posix-functions/vswprintf.texi: Likewise.
16314         * doc/posix-functions/vwprintf.texi: Likewise.
16315         * doc/posix-functions/wprintf.texi: Likewise.
16317 2023-03-17  Bruno Haible  <bruno@clisp.org>
16319         vasnprintf, vasnwprintf: Simplify code.
16320         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Remove dead code: The directives
16321         'o', 'x', 'X' always take an unsigned integer argument.
16323 2023-03-17  Bruno Haible  <bruno@clisp.org>
16325         vasnwprintf: Fix test failure on OpenBSD.
16326         * lib/vasnprintf.c (VASNPRINTF): Don't use the %n directive on OpenBSD.
16328 2023-03-17  Bruno Haible  <bruno@clisp.org>
16330         time: Fix test failure on AIX 7.2.
16331         * m4/time.m4 (gl_FUNC_TIME): Guess that it does not work on AIX.
16332         * doc/posix-functions/time.texi: Mention the bug on AIX.
16334         time: Fix test failure on native Windows.
16335         * m4/time.m4 (gl_FUNC_TIME): Guess that it does not work on native
16336         Windows.
16337         * modules/time (Depends-on): Add gettimeofday.
16338         * doc/posix-functions/time.texi: Mention the bug on Windows.
16340 2023-03-17  Bruno Haible  <bruno@clisp.org>
16342         vasnprintf, vasnwprintf: Include all necessary workarounds in libintl.
16343         * lib/vasnprintf.c: Remove IN_LIBINTL special-casing.
16345 2023-03-17  Bruno Haible  <bruno@clisp.org>
16347         vasnwprintf-posix: Add tests.
16348         * tests/test-vasnwprintf-posix.c: New file, based on
16349         tests/test-vasnprintf-posix.c.
16350         * tests/test-vasnwprintf-posix2.sh: New file, based on
16351         tests/test-vasnprintf-posix2.sh.
16352         * tests/test-vasnwprintf-posix2.c: New file, based on
16353         tests/test-vasnprintf-posix2.c.
16354         * tests/test-vasnwprintf-posix3.c: New file, based on
16355         tests/test-vasnprintf-posix3.c.
16356         * modules/vasnwprintf-posix-tests: New file, based on
16357         modules/vasnprintf-posix-tests.
16359         vasnwprintf-posix: New module.
16360         * m4/vasnwprintf-posix.m4: New file.
16361         * modules/vasnwprintf-posix: New file, based on
16362         modules/vasnprintf-posix.
16364 2023-03-17  Bruno Haible  <bruno@clisp.org>
16366         vasnprintf-posix: Relicense under LGPLv2+.
16367         * modules/vasnprintf-posix (License): Change to LGPLv2+.
16369 2023-03-17  Bruno Haible  <bruno@clisp.org>
16371         vasnwprintf: Add tests.
16372         * tests/test-vasnwprintf.c: New file, based on tests/test-vasnprintf.c.
16373         * modules/vasnwprintf-tests: New file, based on
16374         modules/vasnprintf-tests.
16376         vasnwprintf: New module.
16377         * lib/vasnprintf.c: Enable more code for WIDE_CHAR_VERSION, because
16378         snwprintf()/_snwprintf() (Windows) and swprintf() (Unix) don't return
16379         the needed buffer size, like snprintf does.
16380         * lib/wprintf-parse.h: New file, based on lib/printf-parse.h and
16381         gettext/gettext-runtime/intl/wprintf-parse.h.
16382         * lib/wprintf-parse.c: New file, based on
16383         gettext/gettext-runtime/intl/printf.c.
16384         * lib/vasnwprintf.h: New file, based on lib/vasnprintf.h and
16385         gettext/gettext-runtime/intl/vasnwprintf.h.
16386         * lib/vasnwprintf.c: New file.
16387         * lib/asnwprintf.c: New file, based on lib/asnprintf.c.
16388         * m4/vasnprintf.m4 (gl_FUNC_VASNWPRINTF): New macro.
16389         (gl_PREREQ_VASNXPRINTF): New macro, extracted from gl_PREREQ_VASNPRINTF.
16390         (gl_PREREQ_VASNPRINTF): Invoke it. Don't test for wcsnlen and mbrtowc.
16391         (gl_PREREQ_VASNWPRINTF): New macro.
16392         * modules/vasnwprintf: New file, based on modules/vasnprintf.
16394 2023-03-16  Bruno Haible  <bruno@clisp.org>
16396         strtol, strtoll, strtoul, strtoull: Make ISO C 23 compliant.
16397         * lib/strtol.c (INTERNAL (strtol)): Treat 'b' and base 2 like 'x' and
16398         base 16. Based on glibc commit 64924422a99690d147a166b4de3103f3bf3eaf6c
16399         by Joseph Myers.
16400         * m4/strtol.m4 (gl_FUNC_STRTOL): Test also whether parsing binary
16401         integers works. Update cross-compilation guesses.
16402         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
16403         * m4/strtoul.m4 (gl_FUNC_STRTOUL): Likewise.
16404         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise.
16405         * tests/test-strtol.c (main): Add tests of parsing binary integers.
16406         * tests/test-strtoll.c (main): Likewise.
16407         * tests/test-strtoul.c (main): Likewise.
16408         * tests/test-strtoull.c (main): Likewise.
16409         * doc/posix-functions/strtol.texi: Mention the problem with parsing
16410         binary integers.
16411         * doc/posix-functions/strtoll.texi: Likewise.
16412         * doc/posix-functions/strtoul.texi: Likewise.
16413         * doc/posix-functions/strtoull.texi: Likewise.
16415 2023-03-16  Bruno Haible  <bruno@clisp.org>
16417         timegm: Document under ISO C and POSIX substitutes.
16418         * doc/posix-functions/timegm.texi: Renamed from doc/glibc-functions/timegm.texi.
16419         * doc/gnulib.texi (Function Substitutes): Include timegm.texi here...
16420         (Glibc time.h): ... not here.
16422 2023-03-16  Bruno Haible  <bruno@clisp.org>
16424         stddef: Fix a compilation error on AIX 7.2 with xlclang.
16425         * lib/stddef.in.h (__CLANG_MAX_ALIGN_T_DEFINED): Define whenever we
16426         define GNULIB_defined_max_align_t.
16428 2023-03-16  Bruno Haible  <bruno@clisp.org>
16430         stddef: Define 'unreachable', for ISO C 23 compliance.
16431         * lib/verify.h (_GL_HAS_BUILTIN_UNREACHABLE): Don't define if already
16432         defined.
16433         * lib/stddef.in.h (_GL_HAS_BUILTIN_UNREACHABLE, unreachable): New
16434         macros.
16435         (abort): Declare if needed for unreachable.
16436         * m4/stddef_h.m4 (gl_STDDEF_H): Test for unreachable.
16437         * tests/test-stddef.c (test_unreachable_optimization,
16438         test_unreachable_noreturn): New functions, based on tests/test-verify.c.
16439         * doc/posix-headers/stddef.texi: Mention unreachable.
16441 2023-03-10  Paul Eggert  <eggert@cs.ucla.edu>
16443         posixtm: work around Glibc time issue
16444         * modules/posixtm (Depends-on): Add time.
16446 2023-03-09  Jim Meyering  <meyering@fb.com>
16448         bootstrap: correct last change
16449         * top/bootstrap-funclib.sh (autogen) [AUTORECONFFLAGS]: Do always
16450         apply the --no-recursive option.
16451         * build-aux/bootstrap: Regenerate.
16453         bootstrap: remove code that accommodated RHEL5's old autoreconf
16454         * top/bootstrap-funclib.sh (autogen) [AUTORECONFFLAGS]: RHEL5 has not
16455         been supported since 2017. It included (and this code worked around)
16456         a version of autoreconf that was so old it did not accept the
16457         --no-recursive option. Drop that workaround.
16458         * build-aux/bootstrap: Regenerate.
16460 2023-03-08  Bruno Haible  <bruno@clisp.org>
16462         gettimeofday, timespec_get tests: Avoid test failure on glibc/Linux.
16463         * modules/gettimeofday-tests (Depends-on): Add 'time'.
16464         * modules/timespec_get-tests (Depends-on): Likewise.
16465         * tests/test-gettimeofday.c (test_consistency): Update comment.
16466         * tests/test-timespec_get.c (main): Likewise.
16468         time: Add tests.
16469         * tests/test-time.c: New file.
16470         * modules/time-tests: New file.
16472         time: New module.
16473         * lib/time.in.h (time): New declaration.
16474         * lib/time.c: New file.
16475         * m4/time_h.m4 (gl_TIME_H_REQUIRE_DEFAULTS): Initialize GNULIB_TIME.
16476         (gl_TIME_H_DEFAULTS): Initialize REPLACE_TIME.
16477         * m4/time.m4: New file.
16478         * modules/time-h (Makefile.am): Substitute GNULIB_TIME, REPLACE_TIME.
16479         * modules/time: New file.
16480         * tests/test-time-h-c++.cc: Check the signature of
16481         GNULIB_NAMESPACE::time.
16482         * doc/posix-functions/time.texi: Mention the glibc problem and the
16483         'time' module.
16485 2023-03-08  Bruno Haible  <bruno@clisp.org>
16487         time-h: Renamed from time.
16488         * modules/time-h: Renamed from modules/time.
16489         * tests/test-time-h.c: Renamed from tests/test-time.c.
16490         * modules/time-h-tests: Renamed from modules/time-tests. Update.
16491         * tests/test-time-h-c++.cc: Renamed from tests/test-time-c++.cc.
16492         * tests/test-time-h-c++2.cc: Renamed from tests/test-time-c++2.cc.
16493         * modules/time-h-c++-tests: Renamed from modules/time-c++-tests. Update.
16494         * modules/cond (Depends-on): Update.
16495         * modules/ctime (Depends-on): Likewise.
16496         * modules/localtime (Depends-on): Likewise.
16497         * modules/mktime (Depends-on): Likewise.
16498         * modules/nanosleep (Depends-on): Likewise.
16499         * modules/parse-datetime (Depends-on): Likewise.
16500         * modules/posixcheck (Depends-on): Likewise.
16501         * modules/pthread-h (Depends-on): Likewise.
16502         * modules/stat-time (Depends-on): Likewise.
16503         * modules/stat-time-tests (Depends-on): Likewise.
16504         * modules/strftime-fixes (Depends-on): Likewise.
16505         * modules/strptime (Depends-on): Likewise.
16506         * modules/sys_stat (Depends-on): Likewise.
16507         * modules/tempname (Depends-on): Likewise.
16508         * modules/threads-h (Depends-on): Likewise.
16509         * modules/time_r (Depends-on): Likewise.
16510         * modules/time_rz (Depends-on): Likewise.
16511         * modules/timegm (Depends-on): Likewise.
16512         * modules/timespec (Depends-on): Likewise.
16513         * modules/timespec_get (Depends-on): Likewise.
16514         * modules/timespec_getres (Depends-on): Likewise.
16515         * modules/tzset (Depends-on): Likewise.
16516         * modules/usleep-tests (Depends-on): Likewise.
16517         * modules/utime (Depends-on): Likewise.
16518         * modules/utimecmp (Depends-on): Likewise.
16519         * modules/utimens (Depends-on): Likewise.
16520         * modules/windows-cond (Depends-on): Likewise.
16521         * modules/windows-timedmutex (Depends-on): Likewise.
16522         * modules/windows-timedrecmutex (Depends-on): Likewise.
16523         * modules/windows-timedrwlock (Depends-on): Likewise.
16524         * modules/xnanosleep (Depends-on): Likewise.
16525         * doc/posix-headers/time.texi: Update.
16526         * NEWS: Mention the change.
16528 2023-03-08  Bruno Haible  <bruno@clisp.org>
16530         gettimeofday tests: Enhance test.
16531         * tests/test-gettimeofday.c: Include <stdlib.h> and macros.h.
16532         (test_clobber): New function, extracted from main.
16533         (test_consistency): New function, based on tests/test-timespec_get.c.
16534         (main): Invoke both functions.
16535         * modules/gettimeofday-tests (Files): Add macros.h.
16537 2023-03-05  Paul Eggert  <eggert@cs.ucla.edu>
16539         stdio: suppress macOS 13 sprintf warnings
16540         * lib/stdio.in.h (_POSIX_C_SOURCE, _GL_DEFINED__POSIX_C_SOURCE):
16541         Suppress deprecation warnings for sprintf and vsprintf
16542         that were introduced in macOS 13.  These are not useful
16543         for Gnulib itself, and are more likely than not to be
16544         merely an annoyance for Gnulib-using code.
16546 2023-03-05  Bruno Haible  <bruno@clisp.org>
16548         timespec_get tests: Add comment.
16549         * tests/test-timespec_get.c: Add a comment regarding a glibc bug.
16551 2023-03-02  Bruno Haible  <bruno@clisp.org>
16553         nl_langinfo tests: Avoid test failure on Solaris 11.
16554         * tests/test-nl_langinfo2.c (main): Skip French T_FMT_AMPM test on
16555         Solaris.
16557 2023-02-28  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
16559         terminfo, termcap: Fix more spellos in a comment.
16560         * lib/tparm.c: Fix misspellings and wording in the main comment.
16562 2023-02-28  Bruno Haible  <bruno@clisp.org>
16564         perl: Allow this module to be used with 'gnulib-tool --lgpl'.
16565         Reported by Reuben Thomas <rrt@sc3d.org> in
16566         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00191.html>.
16567         * modules/perl (License): Relax to 'GPLed build tool'.
16568         Approved by Jim Meyering in
16569         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00198.html>.
16571 2023-02-28  Bruno Haible  <bruno@clisp.org>
16573         dfa: Tweak the last patch.
16574         Suggested by Alexei Podtelezhnikov <apodtele@gmail.com>.
16575         * lib/dfa.c (FALLTHROUGH): Assume that Apple clang, in C mode, supports
16576         __attribute__ ((__fallthrough__)) starting with version 1200.
16577         References:
16578         https://en.wikipedia.org/wiki/Xcode#Xcode_11.0_-_14.x_(since_SwiftUI_framework)_2
16579         https://github.com/apple/llvm-project/blob/swift-5.3-RELEASE/clang/test/Sema/fallthrough-attr.c
16581 2023-02-27  ChuanGang Jiang  <jiangchuanganghw@outlook.com>
16583         fts: fail gracefully when out of memory
16584         * lib/fts.c (fts_read): Set errno==ENOMEM and return NULL
16585         when setup_dir() fails, rather than hitting an assertion later.
16587 2023-02-26  Jim Meyering  <meyering@fb.com>
16589         announce-gen: spell OpenBSD with a capital "O"
16590         * build-aux/announce-gen (print_checksums): Capitalize
16591         the "O" in OpenBSD, as suggested by Bruno Haible.
16593 2023-02-26  Bruno Haible  <bruno@clisp.org>
16595         dfa: Avoid warnings with some Apple clang versions.
16596         Reported by Werner Lemberg <wl@gnu.org> in
16597         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00159.html>.
16598         * lib/dfa.c (FALLTHROUGH): When __apple_build_version__ is defined,
16599         ignore __clang_major__.
16601 2023-02-25  Jim Meyering  <meyering@fb.com>
16603         announce-gen: add more info the auto-generated announce template
16604         * build-aux/announce-gen (readable_interval, readable_interval0):
16605         New functions.
16606         (digest_file_base64_wrap): New function to add padding to the
16607         base64-encoded SHA256 checksums.
16608         (print_checksums): Use that wrapper. Indent each line by two spaces.
16609         (main): Emit new sections, e.g., these lines from grep-3.8's release:
16610         - There have been 104 commits by 6 people in the 55 weeks since 3.7.
16611         - The following people contributed changes to this release: (and list)
16612         I tested with this, running from a sibling cloned grep directory:
16613           ../gnulib/build-aux/announce-gen --release-type=stable \
16614             --package-name=grep --previous-version=3.7 --current-version=3.8 \
16615             --gpg-key-id=0x7FD9FCCB000BEEEE --url-directory=https://testing
16616         Also, reference the cksum programs from coreutils-9.2 and from OpenBSD.
16618 2023-02-25  ChuanGang Jiang  <jiangchuanganghw@outlook.com>  (tiny change)
16620         terminfo, termcap: Fix typos in comments.
16621         * lib/tparm.c: Fix misspellings in comments.
16623 2023-02-23  Paul Eggert  <eggert@cs.ucla.edu>
16625         lseek: avoid SEEK_HOLE bugs in FreeBSD, macOS
16626         This attempts to fix <https://bugs.gnu.org/61386>, a bug in GNU cp
16627         caused by a serious data corruption bug in FreeBSD and macOS.
16628         * doc/posix-functions/lseek.texi: Mention the bug.
16629         * lib/unistd.in.h (SEEK_DATA, SEEK_HOLE): Undef in macOS < 13 and
16630         FreeBSD < 14.  FreeBSD fixed the bug sometime during FreeBSD 13
16631         <https://bugs.freebsd.org/256205>, so the "FreeBSD < 14" is
16632         conservative.  It’s unknown when Apple will fix macOS so use
16633         macOS "9999" as a placeholder.
16634         * m4/lseek.m4 (gl_FUNC_LSEEK): Replace lseek if on one of the
16635         above platforms.
16637 2023-02-18  Bruno Haible  <bruno@clisp.org>
16639         configmake: Add support for $build_os != $host_os.
16640         * m4/build-to-host.m4: New file.
16641         * m4/configmake.m4 (gl_CONFIGMAKE_PREP): Provide a configure-time
16642         definition for pkgdatadir, pkgincludedir, pkglibdir.
16643         (gl_CONFIGMAKE): New macro.
16644         * modules/configmake (Files): Add m4/build-to-host.m4.
16645         (configure.ac): Invoke gl_CONFIGMAKE instead of gl_CONFIGMAKE_PREP.
16646         (Makefile.am): For creating configmake.h, use the various *prefix_c_make
16647         and *dir_c_make variables.
16649 2023-02-18  Bruno Haible  <bruno@clisp.org>
16651         configmake: Prepare for using directory names with backslashes.
16652         * modules/configmake (Makefile.am): Use printf instead of echo.
16654 2023-02-18  Bruno Haible  <bruno@clisp.org>
16656         unilbrk tests: Fix compilation failures (regression 2023-02-11).
16657         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Outside of
16658         libunistring, don't test the backward compatibility function.
16659         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
16660         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
16661         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
16662         * tests/unilbrk/test-u8-width-linebreaks.c (main): Likewise.
16663         * tests/unilbrk/test-u16-width-linebreaks.c (main): Likewise.
16664         * tests/unilbrk/test-u32-width-linebreaks.c (main): Likewise.
16665         * tests/unilbrk/test-ulc-width-linebreaks.c (main): Likewise.
16667 2023-02-17  Bruno Haible  <bruno@clisp.org>
16669         Improve cross-compilation for midipix.
16670         Reported by Ørjan Malde <red@foxi.me> at
16671         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00131.html>.
16672         This patch handles the cases where midipix acts like Linux.
16673         * m4/chmod.m4 (gl_FUNC_CHMOD): Treat midipix like Linux with glibc or
16674         musl libc.
16675         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
16676         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
16677         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
16678         * m4/link.m4 (gl_FUNC_LINK): Likewise.
16679         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
16680         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
16681         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
16682         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
16683         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Likewise.
16684         * m4/readlink.m4 (gl_FUNC_READLINK): Likewise.
16685         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
16686         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
16687         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
16688         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
16689         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
16690         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
16691         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
16692         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
16693         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
16695         Improve cross-compilation for midipix.
16696         Reported by Ørjan Malde <red@foxi.me> at
16697         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00131.html>.
16698         Since midipix consists of musl libc based on an emulation of Linux system
16699         calls, for pure libc functionality it can be treated like musl libc.
16700         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Treat midipix like systems with
16701         musl libc.
16702         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Likewise.
16703         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
16704         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
16705         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
16706         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
16707         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
16708         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
16709         * m4/expm1f.m4 (gl_FUNC_EXPM1F): Likewise.
16710         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Likewise.
16711         * m4/fclose.m4 (gl_FUNC_FCLOSE_STDIN): Likewise.
16712         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Likewise.
16713         * m4/ffsll.m4 (gl_FUNC_FFSLL): Likewise.
16714         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
16715         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
16716         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
16717         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
16718         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
16719         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
16720         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): Likewise.
16721         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
16722         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
16723         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
16724         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
16725         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
16726         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
16727         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): Likewise.
16728         * m4/log.m4 (gl_FUNC_LOG): Likewise.
16729         * m4/log10.m4 (gl_FUNC_LOG10): Likewise.
16730         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
16731         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Likewise.
16732         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
16733         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Likewise.
16734         * m4/log1pl.m4 (gl_FUNC_LOG1PL, gl_FUNC_LOG1PL_WORKS): Likewise.
16735         * m4/log2.m4 (gl_FUNC_LOG2): Likewise.
16736         * m4/log2f.m4 (gl_FUNC_LOG2F): Likewise.
16737         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Likewise.
16738         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
16739         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
16740         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Likewise.
16741         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
16742         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
16743         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
16744         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
16745         * m4/musl.m4 (gl_MUSL_LIBC): Likewise.
16746         * m4/perror.m4 (gl_FUNC_PERROR): Likewise.
16747         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_SECURE,
16748         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE,
16749         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2,
16750         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): Likewise.
16751         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_INFINITE,
16752         gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_A,
16753         gl_PRINTF_DIRECTIVE_F, gl_PRINTF_FLAG_ZERO, gl_SNPRINTF_TRUNCATION_C99,
16754         gl_SNPRINTF_RETVAL_C99, gl_SNPRINTF_DIRECTIVE_N,
16755         gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
16756         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
16757         Likewise.
16758         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
16759         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
16760         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
16761         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
16762         * m4/remainderl.m4 (gl_FUNC_REMAINDERL, gl_FUNC_REMAINDERL_WORKS):
16763         Likewise.
16764         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
16765         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
16766         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
16767         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
16768         * m4/setenv.m4 (gl_FUNC_SETENV): Likewise.
16769         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Likewise.
16770         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
16771         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
16772         * m4/strerror.m4 (gl_FUNC_STRERROR, gl_FUNC_STRERROR_0): Likewise.
16773         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
16774         * m4/strtold.m4 (gl_FUNC_STRTOLD): Likewise.
16775         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
16776         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
16777         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
16778         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
16779         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
16781 2023-02-13  ChuanGang Jiang  <jiangchuanganghw@outlook.com>  (tiny change)
16783         hamt: Detect GCC version correctly.
16784         * lib/hamt.h:Use __GNUC_MINOR__, not  __GNUC_MINOR.
16786 2023-02-11  Bruno Haible  <bruno@clisp.org>
16788         terminfo, termcap: Avoid wrong configure result with clang ≥ 15.
16789         clang 15 reports an error for -Wint-conversion by default.
16790         Reported by Sam James <sam@gentoo.org> in
16791         <https://savannah.gnu.org/bugs/?63793>.
16792         * m4/terminfo.m4 (gl_TERMINFO_BODY): Avoid a -Wint-conversion warning
16793         when testing for tparam and tparm.
16794         * m4/termcap.m4 (gl_TERMCAP_BODY): Likewise.
16796 2023-02-11  Bruno Haible  <bruno@clisp.org>
16798         error-h: Make less fragile.
16799         * lib/error.in.h: Use #include_next if the system has an <error.h>. Use
16800         a split double-inclusion guard.
16801         * m4/error_h.m4 (gl_ERROR_H): Invoke gl_CHECK_NEXT_HEADERS. Set
16802         HAVE_ERROR_H.
16803         * modules/error-h (Makefile.am): Substitute GUARD_PREFIX, HAVE_ERROR_H,
16804         INCLUDE_NEXT, PRAGMA_SYSTEM_HEADER, NEXT_ERROR_H.
16806 2023-02-11  Bruno Haible  <bruno@clisp.org>
16808         unilbrk: Don't compile unused functions outside of libunistring.
16809         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Don't
16810         compile outside of libunistring.
16811         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
16812         Likewise.
16813         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
16814         Likewise.
16815         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
16816         Likewise.
16817         * lib/unilbrk/u8-width-linebreaks.c (u8_width_linebreaks): Likewise.
16818         * lib/unilbrk/u16-width-linebreaks.c (u16_width_linebreaks): Likewise.
16819         * lib/unilbrk/u32-width-linebreaks.c (u32_width_linebreaks): Likewise.
16820         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Likewise.
16822 2023-02-11  Bruno Haible  <bruno@clisp.org>
16824         sigsegv: Fix a compilation error on OpenBSD with clang ≥ 16.
16825         * lib/sigsegv.c (install_for): Add a cast when assigning to
16826         action.sa_sigaction.
16828 2023-02-10  Bruno Haible  <bruno@clisp.org>
16830         Fix code duplication in last commit.
16831         * m4/gnulib-common.m4 (gl_CHECK_FUNCS_DEFAULT_CASE,
16832         gl_CHECK_FUNCS_CASE_FOR_ANDROID, gl_CHECK_FUNCS_CASE_FOR_MACOS,
16833         gl_CHECK_FUNCS_SET_RESULTS): New macros, extracted from
16834         gl_CHECK_FUNCS_ANDROID, gl_CHECK_FUNCS_MACOS,
16835         gl_CHECK_FUNCS_ANDROID_MACOS.
16836         (gl_CHECK_FUNCS_ANDROID, gl_CHECK_FUNCS_MACOS,
16837         gl_CHECK_FUNCS_ANDROID_MACOS): Use them.
16839         mkfifoat: Fix crash on macOS 12.
16840         * m4/gnulib-common.m4 (gl_PREPARE_CHECK_FUNCS_MACOS,
16841         gl_CHECK_FUNCS_MACOS, gl_CHECK_FUNCS_ANDROID_MACOS): New macros.
16842         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Test for mknodat and mkfifoat using
16843         gl_CHECK_FUNCS_ANDROID_MACOS instead of gl_CHECK_FUNCS_ANDROID.
16845 2023-02-10  ChuanGang Jiang  <jiangchuanganghw@outlook.com>  (tiny change)
16847         Fix typos like "the the" and "a a" in comments.
16848         * lib/c32is-impl.h: s/the the/the/
16849         * lib/getopt-pfx-core.h: s/a a/a/
16850         * lib/term-style-control.h: s/the the/the/
16851         * lib/textstyle.in.h: Likewise.
16853 2023-02-10  Bruno Haible  <bruno@clisp.org>
16855         chown, lchown, fchownat tests: Avoid test failure on macOS 12.
16856         * tests/test-chown.h (test_chown): Skip some assertions if
16857         getgid() == (gid_t)-1.
16858         * tests/test-lchown.h (test_lchown): Likewise.
16860 2023-02-09  Paul Eggert  <eggert@cs.ucla.edu>
16862         nullptr: work around Apple clang 14 issue
16863         Problem reported by Bruno Haible in:
16864         https://lists.gnu.org/r/bug-gnulib/2023-02/msg00098.html
16865         * doc/gnulib.texi (nullptr): Document limitations better.
16866         * m4/nullptr.m4 (gl_NULLPTR): Check for incompatibility of macOS
16867         clang 14.0.0 (clang-1400.0.29.202), where <stddef.h> defines a
16868         non-working nullptr macro.
16870 2023-02-09  Bruno Haible  <bruno@clisp.org>
16872         math: Fix compilation error in C++ mode on macOS 12.5.
16873         * lib/math.in.h (isnan): On macOS, treat clang version 14 again like
16874         clang versions < 12.
16876 2023-02-09  Bruno Haible  <bruno@clisp.org>
16878         Fix compilation errors in C++ mode on macOS 12.5.
16879         * m4/gnulib-common.m4 (gl_COMMON_BODY): Don't define
16880         _GL_ATTRIBUTE_MAYBE_UNUSED to [[__maybe_unused__]] if the compiler is
16881         an Apple variant of clang.
16883 2023-02-09  Bruno Haible  <bruno@clisp.org>
16885         limits-h: Work around a clang 15 bug.
16886         * m4/limits-h.m4 (gl_LIMITS_H): Test also for BOOL_MAX.
16887         * lib/limits.in.h: Handle the case where BOOL_WIDTH is present and
16888         BOOL_MAX is missing.
16889         * doc/posix-headers/limits.texi: Mention the clang bug.
16891 2023-02-09  Bruno Haible  <bruno@clisp.org>
16893         Fix error in C++ mode on glibc systems (regression 2022-04-28).
16894         * lib/malloc.in.h (rpl_free): Add exception specification like
16895         stdlib.in.h does.
16896         * lib/string.in.h (rpl_free): Likewise.
16897         * lib/wchar.in.h (rpl_free): Likewise.
16899 2023-02-09  Bruno Haible  <bruno@clisp.org>
16901         getcwd: Fix compilation error in C23 mode.
16902         * lib/getcwd.c: Include <stdio.h>.
16904 2023-02-08  Bruno Haible  <bruno@clisp.org>
16906         x-to-1: Accept additional help2man arguments.
16907         Suggested by Reuben Thomas <rrt@sc3d.org> in
16908         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00078.html>.
16909         * build-aux/x-to-1.in: Allow additional options after the HELP2MAN
16910         argument, and pass them down to help2man.
16912 2023-02-08  Bruno Haible  <bruno@clisp.org>
16914         x-to-1: Document the configure-time prerequisites.
16915         Suggested by Reuben Thomas <rrt@sc3d.org> in
16916         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00078.html>.
16917         * build-aux/x-to-1.in: Add more comments.
16919 2023-02-08  Bruno Haible  <bruno@clisp.org>
16921         hard-locale: Add comment regarding per-thread locales.
16922         * lib/hard-locale.h (hard_locale): Add comment.
16924 2023-02-08  Bruno Haible  <bruno@clisp.org>
16926         nl_langinfo: Add comment regarding per-thread locales.
16927         * lib/nl_langinfo.c (ctype_codeset): Add comment.
16929         nl_langinfo tests: Add another test.
16930         * tests/test-nl_langinfo2.c: New file.
16931         * tests/test-nl_langinfo2.sh: New file.
16932         * modules/nl_langinfo-tests (Files): Add them. Add
16933         intl-thread-locale.m4.
16934         (Depends-on): Add c-strcasestr, stdbool.
16935         (configure.ac): Invoke gt_FUNC_USELOCALE.
16936         (Makefile.am): Arrange to compile test-nl_langinfo2 and test it through
16937         test-nl_langinfo2.sh.
16939         nl_langinfo tests: Prepare for adding more tests.
16940         * tests/test-nl_langinfo1.c: Renamed from tests/test-nl_langinfo.c.
16941         * tests/test-nl_langinfo1.sh: Renamed from tests/test-nl_langinfo.sh.
16942         Update.
16943         * modules/nl_langinfo-tests (Files, Makefile.am): Update.
16945 2023-02-08  Bruno Haible  <bruno@clisp.org>
16947         assert-h: Fix test failure on IRIX 6.5.
16948         * m4/assert_h.m4 (gl_ASSERT_H): Ensure that on IRIX, including
16949         <assert.h> after <config.h> actually defines the assert macro.
16951 2023-02-07  Paul Eggert  <eggert@cs.ucla.edu>
16953         nullptr: test for compilers at autoconf-time
16954         * m4/nullptr.m4 (gl_NULLPTR): Test for C and C++ compiler usage at
16955         autoconf-time.  This should work better than testing at
16956         configure-time.  Also, push and pop languages so we check the
16957         proper compiler.
16959         nullptr: test for C++ nullptr at configure-time
16960         * m4/nullptr.m4 (gl_NULLPTR): Test for C++ support for nullptr
16961         at configure-time, as we already do for C support.
16962         This should be more reliable than maintaining #ifdefs by hand.
16964         nullptr: rename from c-nullptr
16965         * NEWS, doc/gnulib.texi: Mention this.
16966         * m4/nullptr.m4: Rename from m4/c-nullptr.m4.
16967         (gl_NULLPTR): Rename from gl_C_NULLPTR.
16968         * modules/nullptr: Rename from modules/nullptr.
16969         * modules/nullptr-c++-tests: Rename from modules/c-nullptr-c++-tests.
16970         * modules/nullptr-tests: Rename from modules/c-nullptr-tests.
16971         All uses changed.
16973 2023-02-07  Bruno Haible  <bruno@clisp.org>
16975         Fix a copyright header - module license mismatch.
16976         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
16977         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00057.html>.
16978         * lib/gen-uni-tables.c (output_predicate): For uniwidth/width2.h, use an
16979         LGPLv2+ license.
16980         (output_nonspacing_property): Use an LGPLv2+ license.
16981         * lib/uniwidth/width0.h: Regenerated.
16982         * lib/uniwidth/width2.h: Likewise.
16984 2023-02-07  Bruno Haible  <bruno@clisp.org>
16986         check-copyright: Don't fail because of the 'glob' module.
16987         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
16988         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00057.html>.
16989         * check-copyright: Filter out the files from the 'glob' module.
16991 2023-02-07  Bruno Haible  <bruno@clisp.org>
16993         check-copyright: Make output prettier.
16994         * check-copyright: Resize the second column from width 14 to width 17.
16996 2023-02-06  Bruno Haible  <bruno@clisp.org>
16998         setlocale-null: Don't use a lock in Cygwin >= 3.4.6.
16999         Road paved by Corinna Vinschen <vinschen@redhat.com>.
17000         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Assume that
17001         setlocale (LC_ALL, NULL) is multithread-safe in Cygwin >= 3.4.6.
17002         * lib/setlocale_null.c: Update comments.
17003         * tests/test-setlocale_null-mt-all.c: Likewise.
17005 2023-02-05  Bruno Haible  <bruno@clisp.org>
17007         c-nullptr: Fix conflict with libstdc++ in GCC >= 11.
17008         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
17009         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00030.html>.
17010         * m4/c-nullptr.m4 (gl_C_NULLPTR): Don't define nullptr if it is already
17011         defined. In C++ mode, ignore the result of the configure test and don't
17012         define it when we know that the C++ compiler already supports it.
17014 2023-02-05  Bruno Haible  <bruno@clisp.org>
17016         c-nullptr: Add tests.
17017         * tests/test-nullptr.c: New file.
17018         * modules/c-nullptr-tests: New file.
17019         * tests/test-nullptr-c++.cc: New file.
17020         * modules/c-nullptr-c++-tests: New file.
17022 2023-02-05  Paul Eggert  <eggert@cs.ucla.edu>
17024         sh-quote: backport fix from diffutils
17025         * lib/sh-quote.c (init_sh_quoting_options):
17026         Use C89 through C17 style for parameterless static function.
17027         This avoided a warning when compiling diffutils.
17028         This patch is backported from a circa-2009 diffutils patch
17029         and lets us remove diffutils/gl/lib/sh-quote.c.diff; see:
17030         https://git.savannah.gnu.org/cgit/diffutils.git/commit/?id=8c3d25a63a2c5912170ef6e13f748f3904e6b5cf
17032         c-nullptr: new module
17033         * doc/gnulib.texi (nullptr): New section.
17034         * doc/posix-headers/stddef.texi: Document lack of nullptr_t.
17035         * m4/c-nullptr.m4, modules/c-nullptr: New files.
17037 2023-02-05  Bruno Haible  <bruno@clisp.org>
17039         Update build-aux/po/Makefile.in.in.
17040         Reported by Reuben Thomas <rrt@sc3d.org> in
17041         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00020.html>.
17042         * build-aux/po/Makefile.in.in: Sync from GNU gettext 0.21.1.
17043         Fixes:
17044         - In the .po -> .gmo rules, consider the newest changes to the POT file.
17045         - Emit a warning when creating a tarball without POT file.
17047 2023-02-05  Bruno Haible  <bruno@clisp.org>
17049         assert-h, verify: Fix compilation error in C++ mode with MSVC 14.
17050         * lib/verify.h (static_assert): Define _ALLOW_KEYWORD_MACROS.
17051         * tests/test-assert-h-c++.cc: Strengthen test.
17052         * tests/test-assert-h-c++2.cc: Likewise.
17054 2023-02-04  Paul Eggert  <eggert@cs.ucla.edu>
17056         fts: pacify GCC 13 -Wuse-after-free
17057         Ordinarily I fix this sort of thing by using well-defined rather
17058         than undefined behavior, but a straightforward patch along those
17059         lines would change the fts_.h API since fts_accpath would change
17060         from a pointer to an integer with a more-complex interpretation.
17061         Instead, attempt to pacify GCC 13 with code that relies on
17062         undefined but portable-in-practice behavior that GCC 13 does not
17063         complain about.  GCC problem reported by Peter Frazier in:
17064         https://lists.gnu.org/r/bug-gnulib/2023-02/msg00000.html
17065         * lib/fts.c: Include stdint.h.
17066         (fts_build): Do not access freed pointer directly; instead,
17067         save its bit-pattern into a uintptr_t, and use that to compare.
17068         (ADJUST): Likewise, but more trickily since this hack
17069         actually accesses freed pointers, but does so in a way that
17070         I hope GCC doesn’t notice.  Although using ‘*(uintptr_t *) &P’
17071         instead of ‘(uintptr_t) P’ would avoid accessing freed pointers,
17072         it would provoke a -Wstrict-aliasing diagnostic.
17073         * modules/fts (Depends-on): Add stdint.
17075 2023-02-04  Bruno Haible  <bruno@clisp.org>
17077         assert-h, verify: Fix conflict with standard C++ header files on macOS.
17078         * lib/verify.h (_Static_assert): Don't redefine with clang ≥ 3.8.0
17079         in C++ mode.
17080         * tests/test-assert-h-c++.cc: Also check against conflict with the
17081         standard C++ header files.
17082         * tests/test-assert-h-c++2.cc: Likewise.
17084 2023-02-04  Bruno Haible  <bruno@clisp.org>
17086         Activate all existing C++ tests.
17087         * modules/assert-h-tests (Depends-on): Add assert-h-c++-tests.
17088         * modules/stdarg-tests (Depends-on): Add stdarg-c++-tests.
17090 2023-02-04  Bruno Haible  <bruno@clisp.org>
17092         spawn: Fix compilation error on macOS (regression 2023-01-22).
17093         * lib/spawn.in.h: Tweak logic for defining the POSIX_SPAWN_* constants.
17095 2023-02-03  Bruno Haible  <bruno@clisp.org>
17097         relocatable-prog: Fix compiler warning.
17098         * lib/progreloc.c (full_read): Use a non-const pointer.
17100 2023-02-03  Bruno Haible  <bruno@clisp.org>
17102         doc: Update regarding AIX.
17103         * doc/glibc-headers/getopt.texi: Update.
17105 2023-02-03  Bruno Haible  <bruno@clisp.org>
17107         doc: Update regarding NetBSD.
17108         * doc/posix-functions/sigprocmask.texi: Mention a NetBSD 9.0 bug.
17109         * doc/posix-functions/pthread_sigmask.texi: Likewise.
17111 2023-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17113         isnan: update comment
17114         * lib/isnan.c: Update comment for C23.
17116 2023-01-30  Bruno Haible  <bruno@clisp.org>
17118         at-internal: Fix support for z/OS.
17119         * lib/openat-proc.c (openat_proc_name) [z/OS]: Proper error handling.
17120         Convert only the relevant part of the dir[] buffer.
17122         at-internal: Add support for z/OS.
17123         Reported and draft patch by Igor Todorovski <itodorov@ca.ibm.com>.
17124         * lib/openat-proc.c [z/OS]: Include <termios.h>.
17125         (openat_proc_name): For z/OS, use an approach similar to kLIBC, with
17126         3 lines of z/OS specific code by Igor Todorovski <itodorov@ca.ibm.com>.
17128 2023-01-30  Bruno Haible  <bruno@clisp.org>
17130         Update NEWS.
17131         * NEWS: Update for qcopy-acl change on 2023-01-13.
17133 2023-01-29  Bruno Haible  <bruno@clisp.org>
17135         maintainer-makefile: Determine gnulib's location on disk correctly.
17136         * top/maint.mk (gnulib_dir): Give priority to $(GNULIB_SRCDIR) over
17137         $(srcdir)/gnulib.
17139 2023-01-29  Bruno Haible  <bruno@clisp.org>
17141         Fix compilation errors with CC="clang -D_FORTIFY_SOURCE=2" on Android.
17142         Reported by Alexey Rochev <equeim@gmail.com> in
17143         <https://lists.gnu.org/archive/html/bug-gnu-libiconv/2023-01/msg00019.html>.
17144         * lib/cdefs.h (__bos, __bos0, __glibc_objsize0, __glibc_objsize,
17145         __glibc_safe_len_cond, __glibc_unsigned_or_positive,
17146         __glibc_safe_or_unknown_len, __glibc_unsafe_len, __glibc_fortify,
17147         __glibc_fortify_n): Don't define these macros in Gnulib.
17148         * lib/libc-config.h: Don't undefine these macros in Gnulib.
17150 2023-01-28  Bruno Haible  <bruno@clisp.org>
17152         Clarify _GL_ATTRIBUTE_NODISCARD code.
17153         Reported by Paul Eggert.
17154         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add comment regarding
17155         _GL_ATTRIBUTE_NODISCARD definition.
17157 2023-01-28  Bruno Haible  <bruno@clisp.org>
17159         unistdio/*printf: Fix negative width handling for %U, %lU, %llU.
17160         * lib/vasnprintf.c (VASNPRINTF): In the code for %U, %lU, %llU, test for
17161         the FLAG_LEFT bit in the flags variable.
17162         * tests/unistdio/test-u8-printf1.h (test_xfunction): Add tests for width
17163         given as argument for the directives %U, %lU, %llU, %s, %a, %f, %e, %g.
17164         * tests/unistdio/test-u16-printf1.h (test_xfunction): Likewise.
17165         * tests/unistdio/test-u32-printf1.h (test_xfunction): Likewise.
17166         * tests/unistdio/test-ulc-printf1.h (test_xfunction): Likewise.
17168 2023-01-28  Bruno Haible  <bruno@clisp.org>
17170         vasnprintf-posix: Fix possible bug with negative width handling for %lc.
17171         * lib/vasnprintf.c (VASNPRINTF): In the code for %lc in vasnprintf, test
17172         for the FLAG_LEFT bit in the flags variable.
17173         * tests/test-vasnprintf-posix.c (test_function): Add tests for width
17174         given as argument for the directives %c, %lc.
17175         * tests/test-vasprintf-posix.c (test_function): Likewise.
17176         * tests/test-snprintf-posix.h (test_function): Likewise.
17177         * tests/test-sprintf-posix.h (test_function): Likewise.
17178         * tests/test-snprintf-posix.c: Include <wchar.h>, for wint_t.
17179         * tests/test-sprintf-posix.c: Likewise.
17180         * tests/test-vsnprintf-posix.c: Likewise.
17181         * tests/test-vsprintf-posix.c: Likewise.
17183 2023-01-28  Bruno Haible  <bruno@clisp.org>
17185         vasnprintf-posix: Fix negative width handling for %ls directive.
17186         Reported by clang via Po Lu <luangruo@yahoo.com>.
17187         * lib/vasnprintf.c (VASNPRINTF): In the code for %ls in vasnprintf and
17188         for %s in vasnwprintf, test for the FLAG_LEFT bit in the flags variable.
17189         * tests/test-vasnprintf-posix.c (test_function): Add tests for width
17190         given as argument for the directives %s, %ls.
17191         * tests/test-vasprintf-posix.c (test_function): Likewise.
17192         * tests/test-snprintf-posix.h (test_function): Likewise.
17193         * tests/test-sprintf-posix.h (test_function): Likewise.
17195 2023-01-28  Bruno Haible  <bruno@clisp.org>
17197         vasnprintf-posix: Add more unit tests.
17198         * tests/test-vasnprintf-posix.c (test_function): Add tests for width
17199         given as argument for the directives %a, %f, %e, %g.
17200         * tests/test-vasprintf-posix.c (test_function): Likewise.
17201         * tests/test-snprintf-posix.h (test_function): Likewise.
17202         * tests/test-sprintf-posix.h (test_function): Likewise.
17204 2023-01-28  Bruno Haible  <bruno@clisp.org>
17206         Avoid clang warnings regarding [[__nodiscard__]].
17207         * m4/gnulib-common.m4 (gl_COMMON_BODY): For clang, in C++ mode, ignore
17208         the __has_c_attribute value and define _GL_ATTRIBUTE_NODISCARD to
17209         __attribute__ ((__warn_unused_result__)), not [[__nodiscard__]].
17211 2023-01-28  Bruno Haible  <bruno@clisp.org>
17213         Avoid clang warnings regarding [[__maybe_unused__]].
17214         * m4/gnulib-common.m4 (gl_COMMON_BODY): For clang versions ≥ 6, < 10,
17215         in C++ mode, ignore the __has_c_attribute value and define
17216         _GL_ATTRIBUTE_MAYBE_UNUSED to __attribute__ ((__unused__)), not
17217         [[__maybe_unused__]].
17219 2023-01-27  Bruno Haible  <bruno@clisp.org>
17221         alignasof: Ensure a correct _Alignof (regression 2023-01-15).
17222         * m4/stdalign.m4 (gl_ALIGNASOF): Apply the workaround for wrong _Alignof
17223         in GCC < 4.9 and clang < 8.0.0 also when the system has <stdalign.h>.
17225 2023-01-27  Bruno Haible  <bruno@clisp.org>
17227         stdalign: Ensure alignof is defined on FreeBSD (regression 2023-01-15).
17228         * lib/stdalign.in.h: Include the system's <stdalign.h> when it exists.
17229         * m4/stdalign.m4 (gl_ALIGNASOF): Invoke gl_CHECK_NEXT_HEADERS. Set
17230         HAVE_STDALIGN_H.
17231         * modules/stdalign (Makefile.am): Substitute GUARD_PREFIX,
17232         HAVE_STDALIGN_H, INCLUDE_NEXT, PRAGMA_SYSTEM_HEADER, PRAGMA_COLUMNS,
17233         NEXT_STDALIGN_H.
17235 2023-01-27  Bruno Haible  <bruno@clisp.org>
17237         stddef: Fix test-stddef compilation error on FreeBSD 12/x86.
17238         * m4/stddef_h.m4 (gl_STDDEF_H): When testing for good max_align_t, use
17239         an ISO C compliant definition of _Alignof.
17241 2023-01-25  Bruno Haible  <bruno@clisp.org>
17243         Keep config.h idempotent.
17244         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add double-inclusion guards to
17245         the definitions of the macros _GL_ATTRIBUTE_ALLOC_SIZE,
17246         _GL_ATTRIBUTE_ALWAYS_INLINE, _GL_ATTRIBUTE_ARTIFICIAL,
17247         _GL_ATTRIBUTE_COLD, _GL_ATTRIBUTE_CONST, _GL_ATTRIBUTE_DEALLOC,
17248         _GL_ATTRIBUTE_DEPRECATED, _GL_ATTRIBUTE_ERROR, _GL_ATTRIBUTE_WARNING,
17249         _GL_ATTRIBUTE_EXTERNALLY_VISIBLE, _GL_ATTRIBUTE_FALLTHROUGH,
17250         _GL_ATTRIBUTE_FORMAT, _GL_ATTRIBUTE_LEAF, _GL_ATTRIBUTE_MALLOC,
17251         _GL_ATTRIBUTE_MAY_ALIAS, _GL_ATTRIBUTE_MAYBE_UNUSED,
17252         _GL_ATTRIBUTE_NODISCARD, _GL_ATTRIBUTE_NOINLINE, _GL_ATTRIBUTE_NONNULL,
17253         _GL_ATTRIBUTE_NONSTRING, _GL_ATTRIBUTE_NOTHROW, _GL_ATTRIBUTE_PACKED,
17254         _GL_ATTRIBUTE_PURE, _GL_ATTRIBUTE_RETURNS_NONNULL,
17255         _GL_ATTRIBUTE_SENTINEL, _GL_ATTRIBUTE_UNUSED, _GL_UNUSED_LABEL.
17257 2023-01-25  Bruno Haible  <bruno@clisp.org>
17259         vasnprintf: Fix compilation error on Android NDK r26b.
17260         Reported by Po Lu <luangruo@yahoo.com>.
17261         * lib/vasnprintf.c: Include <wchar.h>.
17263 2023-01-25  Nick Bowler  <nbowler@draconx.ca>  (tiny change)
17265         threadlib: Fix support for Solaris 9 and older.
17266         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): Allow case patterns to survive
17267         m4 processing by using changequote.
17269 2023-01-24  Bruno Haible  <bruno@clisp.org>
17271         alignasof, stdalign: Fix a compilation error on FreeBSD 12.0.
17272         * m4/stdalign.m4 (gl_ALIGNASOF): In C mode, prefer __builtin_offsetof
17273         over offsetof when possible, since __builtin_offsetof works also when
17274         <stddef.h> has not been fully included yet.
17276 2023-01-22  Bruno Haible  <bruno@clisp.org>
17278         doc: Update list of target platforms.
17279         * doc/gnulib-intro.texi (Supported Platforms): Mark musl libc, Android,
17280         and MSVC as "occasionally tested". Update the version numbers of some
17281         OSes. Combine paragraphs regarding mingw and MSVC.
17282         (Formerly Supported Platforms): Mark AIX 5, 6 as "formerly supported".
17284 2023-01-22  Bruno Haible  <bruno@clisp.org>
17286         Resolve conflicts for functions introduced in Android API level 29.
17288         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY): Conditionally set
17289         REPLACE_REALLOCARRAY.
17290         * lib/stdlib.in.h (reallocarray): Disable _GL_CXXALIASWARN invocation on
17291         non-glibc systems.
17293         * lib/stdlib.in.h (getloadavg): Consider REPLACE_GETLOADAVG. Disable
17294         _GL_CXXALIASWARN invocation on non-glibc systems.
17295         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_GETLOADAVG.
17296         * modules/stdlib (Makefile.am): Substitute REPLACE_GETLOADAVG.
17297         * m4/getloadavg.m4 (gl_GETLOADAVG): Conditionally set
17298         REPLACE_GETLOADAVG.
17299         * modules/getloadavg (Depends-on, configure.ac): Consider
17300         REPLACE_GETLOADAVG.
17302         * lib/time.in.h (timespec_get): Consider REPLACE_TIMESPEC_GET. Disable
17303         _GL_CXXALIASWARN invocation on non-glibc systems.
17304         * m4/time_h.m4 (gl_TIME_H_DEFAULTS): Initialize REPLACE_TIMESPEC_GET.
17305         * modules/time (Makefile.am): Substitute REPLACE_TIMESPEC_GET.
17306         * m4/gettime.m4 (gl_CHECK_FUNC_TIMESPEC_GET): Set also
17307         gl_cv_onwards_func_timespec_get.
17308         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET): Conditionally set
17309         REPLACE_TIMESPEC_GET.
17310         * modules/timespec_get (Depends-on, configure.ac): Consider
17311         REPLACE_TIMESPEC_GET.
17313 2023-01-22  Bruno Haible  <bruno@clisp.org>
17315         Resolve conflicts for functions introduced in Android API level 28.
17317         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Conditionally set
17318         REPLACE_ALIGNED_ALLOC.
17319         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Conditionally set
17320         REPLACE_GETRANDOM.
17322         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Conditionally set
17323         REPLACE_GETLOGIN_R.
17324         * lib/unistd.in.h (getlogin_r): Disable _GL_CXXALIASWARN invocation on
17325         non-glibc systems.
17327         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): Conditionally set
17328         REPLACE_POSIX_SPAWN.
17329         * lib/spawn.in.h: Adapt logic for defining the POSIX_SPAWN_* constants.
17330         (posix_spawn, posix_spawnp, posix_spawnattr_init,
17331         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
17332         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
17333         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
17334         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
17335         posix_spawnattr_setpgroup, posix_spawn_file_actions_init,
17336         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addchdir,
17337         posix_spawn_file_actions_addfchdir): Disable _GL_CXXALIASWARN invocation
17338         on non-glibc systems.
17340         * m4/glob.m4 (gl_GLOB): Conditionally set REPLACE_GLOB.
17341         * lib/glob.in.h (glob): Disable _GL_CXXALIASWARN invocation on non-glibc
17342         systems.
17344         * lib/unistd.in.h (getentropy): Consider REPLACE_GETENTROPY. Disable
17345         _GL_CXXALIASWARN invocation on non-glibc systems.
17346         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_GETENTROPY.
17347         * modules/unistd (Makefile.am): Substitute REPLACE_GETENTROPY.
17348         * m4/getentropy.m4 (gl_FUNC_GETENTROPY): Conditionally set
17349         REPLACE_GETENTROPY.
17350         * modules/getentropy (Depends-on, configure.ac): Consider
17351         REPLACE_GETENTROPY.
17353 2023-01-22  Bruno Haible  <bruno@clisp.org>
17355         Resolve conflicts for functions introduced in Android API level 26.
17357         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Test for getdomainname
17358         using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS. Conditionally
17359         set REPLACE_GETSUBOPT.
17361         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Conditionally set
17362         REPLACE_NL_LANGINFO.
17363         * lib/langinfo.in.h (nl_langinfo): Disable _GL_CXXALIASWARN invocation
17364         on non-glibc systems.
17366         * lib/stdlib.in.h (getsubopt): Consider REPLACE_GETSUBOPT. Disable
17367         _GL_CXXALIASWARN invocation on non-glibc systems.
17368         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_GETSUBOPT.
17369         * modules/stdlib (Makefile.am): Substitute REPLACE_GETSUBOPT.
17370         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Conditionally set
17371         REPLACE_GETSUBOPT.
17372         * modules/getsubopt (Depends-on, configure.ac): Consider
17373         REPLACE_GETSUBOPT.
17375 2023-01-22  Bruno Haible  <bruno@clisp.org>
17377         Resolve conflicts for functions introduced in Android API level 24.
17378         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Conditionally set
17379         REPLACE_STRCHRNUL.
17381 2023-01-22  Bruno Haible  <bruno@clisp.org>
17383         Resolve conflicts for functions introduced in Android API level 23.
17385         * m4/login_tty.m4 (gl_FUNC_LOGIN_TTY): Conditionally set
17386         REPLACE_LOGIN_TTY.
17387         * lib/utmp.in.h (login_tty): Disable _GL_CXXALIASWARN invocation on
17388         non-glibc systems.
17390         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Conditionally set REPLACE_MKFIFOAT.
17391         * lib/sys_stat.in.h (mkfifoat): Disable _GL_CXXALIASWARN invocation on
17392         non-glibc systems.
17394         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Conditionally set
17395         REPLACE_STRERROR_R.
17396         * lib/string.in.h (strerror_r): Disable _GL_CXXALIASWARN invocation on
17397         non-glibc systems.
17399         * m4/error_h.m4 (gl_ERROR_H): Conditionally set REPLACE_ERROR.
17400         * lib/error.in.h (error): Disable _GL_CXXALIASWARN invocation on
17401         non-glibc systems.
17403         * lib/wchar.in.h (wmempcpy): Consider REPLACE_WMEMPCPY.
17404         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WMEMPCPY.
17405         * modules/wchar (Makefile.am): Substitute REPLACE_WMEMPCPY.
17406         * m4/wmempcpy.m4 (gl_FUNC_WMEMPCPY): Conditionally set
17407         REPLACE_WMEMPCPY.
17408         * modules/wmempcpy (configure.ac): Consider REPLACE_WMEMPCPY.
17410         * lib/unistd.in.h (sethostname): Consider REPLACE_SETHOSTNAME. Disable
17411         _GL_CXXALIASWARN invocation on non-glibc systems.
17412         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_SETHOSTNAME.
17413         * modules/unistd (Makefile.am): Substitute REPLACE_SETHOSTNAME.
17414         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): Conditionally set
17415         REPLACE_SETHOSTNAME.
17416         * modules/sethostname (Depends-on, configure.ac): Consider
17417         REPLACE_SETHOSTNAME.
17419         * lib/string.in.h (mempcpy): Consider REPLACE_MEMPCPY. Disable
17420         _GL_CXXALIASWARN invocation on non-glibc systems.
17421         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize REPLACE_MEMPCPY.
17422         * modules/string (Makefile.am): Substitute REPLACE_MEMPCPY.
17423         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Conditionally set REPLACE_MEMPCPY.
17424         * modules/mempcpy (configure.ac): Consider REPLACE_MEMPCPY.
17426         * lib/stdlib.in.h (mkostemp): Consider REPLACE_MKOSTEMP. Disable
17427         _GL_CXXALIASWARN invocation on non-glibc systems.
17428         (mkostemps): Consider REPLACE_MKOSTEMPS. Disable _GL_CXXALIASWARN
17429         invocation on non-glibc systems.
17430         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MKOSTEMP,
17431         REPLACE_MKOSTEMPS.
17432         * modules/stdlib (Makefile.am): Substitute REPLACE_MKOSTEMP,
17433         REPLACE_MKOSTEMPS.
17434         * m4/mkostemp.m4 (gl_FUNC_MKOSTEMP): Conditionally set REPLACE_MKOSTEMP.
17435         * modules/mkostemp (Depends-on, configure.ac): Consider
17436         REPLACE_MKOSTEMP.
17437         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Conditionally set
17438         REPLACE_MKOSTEMPS.
17439         * modules/mkostemps (Depends-on, configure.ac): Consider
17440         REPLACE_MKOSTEMPS.
17442 2023-01-22  Bruno Haible  <bruno@clisp.org>
17444         Resolve conflicts for functions introduced in Android API level 21.
17446         * m4/fts.m4 (gl_FUNC_FTS_CORE): Use rpl_* symbols also when the system
17447         will have fts_open in a future version.
17448         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Conditionally set REPLACE_ISWBLANK.
17449         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Conditionally set REPLACE_MBTOWC.
17450         * m4/vdprintf.m4 (gl_REPLACE_VDPRINTF): Conditionally set
17451         REPLACE_VDPRINTF.
17452         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): Conditionally set
17453         REPLACE_WCSNRTOMBS.
17455         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Conditionally set
17456         REPLACE_MBSNRTOWCS.
17457         * lib/wchar.in.h (mbsnrtowcs): Disable _GL_CXXALIASWARN invocation on
17458         non-glibc systems.
17460         * m4/execvpe.m4 (gl_FUNC_EXECVPE): Conditionally set REPLACE_EXECVPE.
17461         * m4/linkat.m4 (gl_FUNC_LINKAT): Conditionally set REPLACE_LINKAT.
17462         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Conditionally set
17463         REPLACE_READLINKAT.
17464         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Conditionally set
17465         REPLACE_SYMLINKAT.
17466         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Conditionally set REPLACE_TRUNCATE.
17467         * lib/unistd.in.h (execvpe, linkat, readlinkat, symlinkat, truncate):
17468         Disable _GL_CXXALIASWARN invocation on non-glibc systems.
17470         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Conditionally set REPLACE_MKNODAT.
17471         * lib/sys_stat.in.h (mknodat): Disable _GL_CXXALIASWARN invocation on
17472         non-glibc systems.
17474         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Conditionally set REPLACE_STPNCPY.
17475         * lib/string.in.h (stpncpy): Disable _GL_CXXALIASWARN invocation on
17476         non-glibc systems.
17478         * m4/random.m4 (gl_FUNC_RANDOM): Conditionally set REPLACE_INITSTATE,
17479         REPLACE_SETSTATE.
17480         * lib/stdlib.in.h (initstate, setstate): Disable _GL_CXXALIASWARN
17481         invocation on non-glibc systems.
17483         * m4/dprintf.m4 (gl_REPLACE_DPRINTF): Conditionally set REPLACE_DPRINTF.
17484         * lib/stdio.in.h (dprintf): Disable _GL_CXXALIASWARN invocation on
17485         non-glibc systems.
17487         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Conditionally set
17488         REPLACE_DUPLOCALE.
17489         * m4/localename.m4 (gl_LOCALENAME): Conditionally set REPLACE_NEWLOCALE,
17490         REPLACE_DUPLOCALE, REPLACE_FREELOCALE.
17491         * lib/locale.in.h (newlocale, duplocale, freelocale): Disable
17492         _GL_CXXALIASWARN invocation on non-glibc systems.
17494         * lib/unistd.in.h (dup3): Consider REPLACE_DUP3. Disable
17495         _GL_CXXALIASWARN invocation on non-glibc systems.
17496         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_DUP3.
17497         * modules/unistd (Makefile.am): Substitute REPLACE_DUP3.
17498         * m4/dup3.m4 (gl_FUNC_DUP3): Conditionally set REPLACE_DUP3.
17500         * lib/string.in.h (stpcpy): Consider REPLACE_STPCPY. Disable
17501         _GL_CXXALIASWARN invocation on non-glibc systems.
17502         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize REPLACE_STPCPY.
17503         * modules/string (Makefile.am): Substitute REPLACE_STPCPY.
17504         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Conditionally set REPLACE_STPCPY.
17505         * modules/stpcpy (configure.ac): Consider REPLACE_STPCPY.
17507         * lib/stdlib.in.h (_Exit): Consider REPLACE__EXIT. Disable
17508         _GL_CXXALIASWARN invocation on non-glibc systems.
17509         (getprogname): Consider REPLACE_GETPROGNAME. Disable _GL_CXXALIASWARN
17510         invocation on non-glibc systems.
17511         (posix_openpt): Consider REPLACE_POSIX_OPENPT. Disable _GL_CXXALIASWARN
17512         invocation on non-glibc systems.
17513         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE__EXIT,
17514         REPLACE_GETPROGNAME, REPLACE_POSIX_OPENPT.
17515         * modules/stdlib (Makefile.am): Substitute REPLACE__EXIT,
17516         REPLACE_GETPROGNAME, REPLACE_POSIX_OPENPT.
17517         * m4/_Exit.m4 (gl_FUNC__EXIT): Conditionally set REPLACE__EXIT.
17518         * modules/_Exit (configure.ac): Consider REPLACE__EXIT.
17519         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Conditionally set
17520         REPLACE_GETPROGNAME.
17521         * modules/getprogname (configure.ac): Consider REPLACE_GETPROGNAME.
17522         * m4/posix_openpt.m4 (gl_FUNC_POSIX_OPENPT): Conditionally set
17523         REPLACE_POSIX_OPENPT.
17524         * modules/posix_openpt (configure.ac): Consider REPLACE_POSIX_OPENPT.
17526         * lib/search.in.h (twalk): Consider REPLACE_TWALK.
17527         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize REPLACE_TWALK.
17528         * modules/search (Makefile.am): Substitute REPLACE_TWALK.
17529         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Conditionally set REPLACE_TWALK.
17530         * modules/tsearch (configure.ac): Consider REPLACE_TWALK.
17532 2023-01-22  Bruno Haible  <bruno@clisp.org>
17534         Resolve conflicts for functions introduced in Android API level 19.
17536         * lib/inttypes.in.h (imaxabs): Consider REPLACE_IMAXABS. Disable
17537         _GL_CXXALIASWARN invocation on non-glibc systems.
17538         (imaxdiv): Consider REPLACE_IMAXDIV. Disable _GL_CXXALIASWARN invocation
17539         on non-glibc systems.
17540         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Initialize HAVE_IMAXABS,
17541         HAVE_IMAXDIV, REPLACE_IMAXABS, REPLACE_IMAXDIV.
17542         * modules/inttypes-incomplete (Makefile.am): Substitute REPLACE_IMAXABS,
17543         REPLACE_IMAXDIV.
17544         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Conditionally set HAVE_IMAXABS,
17545         REPLACE_IMAXABS.
17546         * modules/imaxabs (configure.ac): Consider HAVE_IMAXABS, REPLACE_IMAXABS.
17547         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Conditionally set HAVE_IMAXDIV,
17548         REPLACE_IMAXDIV.
17549         * modules/imaxdiv (configure.ac): Consider HAVE_IMAXDIV, REPLACE_IMAXDIV.
17551         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Conditionally set REPLACE_FUTIMENS.
17552         * lib/sys_stat.in.h (futimens): Disable _GL_CXXALIASWARN invocation on
17553         non-glibc systems.
17555 2023-01-22  Bruno Haible  <bruno@clisp.org>
17557         Resolve conflicts for functions introduced in Android API level 18.
17559         * m4/log2.m4 (gl_FUNC_LOG2): Conditionally set REPLACE_LOG2.
17560         * m4/log2f.m4 (gl_FUNC_LOG2F): Conditionally set REPLACE_LOG2F.
17561         * m4/log2l.m4 (gl_FUNC_LOG2L): Conditionally set REPLACE_LOG2L.
17562         * lib/math.in.h (log2f): Disable _GL_CXXALIASWARN invocation on
17563         non-glibc systems.
17565         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Conditionally set REPLACE_GETDELIM.
17566         * m4/getline.m4 (gl_FUNC_GETLINE): Conditionally set REPLACE_GETLINE.
17567         * lib/stdio.in.h (getdelim, getline): Disable _GL_CXXALIASWARN
17568         invocation on non-glibc systems.
17570 2023-01-22  Bruno Haible  <bruno@clisp.org>
17572         Resolve conflicts for functions introduced in Android API level 16-17.
17573         * m4/posix_memalign.m4 (gl_FUNC_POSIX_MEMALIGN): Conditionally set
17574         REPLACE_POSIX_MEMALIGN.
17575         * lib/stdlib.in.h (posix_memalign): Disable _GL_CXXALIASWARN invocation
17576         on non-glibc systems.
17578 2023-01-22  Bruno Haible  <bruno@clisp.org>
17580         Resolve conflicts for functions introduced in Android API level 16.
17582         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Conditionally set REPLACE_TSEARCH.
17583         * lib/search.in.h (tsearch, tfind, tdelete, twalk): Disable
17584         _GL_CXXALIASWARN invocation on non-glibc systems.
17586         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Conditionally set
17587         REPLACE_FACCESSAT.
17588         * lib/unistd.in.h (faccessat): Disable _GL_CXXALIASWARN invocation on
17589         non-glibc systems.
17591 2023-01-22  Bruno Haible  <bruno@clisp.org>
17593         Resolve conflicts for functions introduced in Android API level 12.
17595         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Conditionally set
17596         REPLACE_UTIMENSAT.
17597         * lib/sys_stat.in.h (utimensat): Disable _GL_CXXALIASWARN invocation on
17598         non-glibc systems.
17600         * m4/timegm.m4 (gl_FUNC_TIMEGM): Conditionally set REPLACE_TIMEGM.
17601         * lib/time.in.h (timegm): Disable _GL_CXXALIASWARN invocation on
17602         non-glibc systems.
17604         * m4/pwrite.m4 (gl_FUNC_PWRITE): Conditionally set REPLACE_PWRITE.
17605         * lib/unistd.in.h (pwrite): Disable _GL_CXXALIASWARN invocation on
17606         non-glibc systems.
17608         * m4/pread.m4 (gl_FUNC_PREAD): Conditionally set REPLACE_PREAD.
17609         * lib/unistd.in.h (pread): Disable _GL_CXXALIASWARN invocation on
17610         non-glibc systems.
17612         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Conditionally set
17613         REPLACE_FTRUNCATE.
17614         * lib/unistd.in.h (ftruncate): Disable _GL_CXXALIASWARN invocation on
17615         non-glibc systems.
17617 2023-01-22  Bruno Haible  <bruno@clisp.org>
17619         Resolve conflicts for functions introduced in Android API level 9.
17620         * lib/unistd.in.h (fdatasync): Consider REPLACE_FDATASYNC. Disable
17621         _GL_CXXALIASWARN invocation on non-glibc systems.
17622         (pipe2): Consider REPLACE_PIPE2. Disable _GL_CXXALIASWARN invocation on
17623         non-glibc systems.
17624         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_FDATASYNC,
17625         REPLACE_PIPE2.
17626         * modules/unistd (Makefile.am): Substitute REPLACE_FDATASYNC,
17627         REPLACE_PIPE2.
17628         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Test for fdatasync using
17629         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS. Conditionally set
17630         REPLACE_FDATASYNC.
17631         * modules/fdatasync (Depends-on, configure.ac): Consider
17632         REPLACE_FDATASYNC.
17633         * m4/pipe2.m4 (gl_FUNC_PIPE2): Conditionally set REPLACE_PIPE2.
17635 2023-01-22  Bruno Haible  <bruno@clisp.org>
17637         Resolve conflicts for functions introduced in Android API level 8.
17638         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Conditionally set
17639         REPLACE_TTYNAME_R.
17640         * lib/unistd.in.h (ttyname_r): Disable _GL_CXXALIASWARN invocation on
17641         non-glibc systems.
17643 2023-01-22  Bruno Haible  <bruno@clisp.org>
17645         Prepare for resolving conflicts regarding future Android API levels.
17646         * m4/gnulib-common.m4 (gl_CHECK_FUNCS_ANDROID): Don't check for the
17647         function declaration on platforms other than Android. Set a variable
17648         gl_cv_onwards_func_<func>.
17650 2023-01-22  Paul Eggert  <eggert@cs.ucla.edu>
17652         sigsegv, vma-iter: port to Solaris 10
17653         On this platform, <sys/types.h> does not define off_t if neither
17654         _LP64 nor _FILE_OFFSET_BITS is defined, which can happen if we
17655         #undef _FILE_OFFSET_BITS.  This became a problem with the new way
17656         of doing stdbool, since config.h now includes <stdbool.h>, and
17657         Solaris 10 <stdbool.h> includes <sys/feature_tests.h> which
17658         arranges for _FILE_OFFSET_BITS to always be defined (if only to 32),
17659         which <sys/types.h> assumes.
17660         * lib/stackvma.c, lib/vma-iter.c (_FILE_OFFSET_BITS) [__sun && !_LP64]:
17661         Define to 32 instead of leaving undefined.
17663 2023-01-21  Bruno Haible  <bruno@clisp.org>
17665         login_tty: Ensure declaration in <utmp.h>.
17667         * tests/test-utmp-c++.cc: New file.
17668         * modules/utmp-c++-tests: New file.
17670         * tests/test-utmp.c: New file.
17671         * modules/utmp-tests: New file.
17673         * lib/login_tty.c: Include <utmp.h>.
17674         * m4/login_tty.m4: New file.
17675         (gl_FUNC_LOGIN_TTY): Moved here from m4/pty.m4. Set HAVE_LOGIN_TTY.
17676         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Moved to m4/login_tty.m4.
17677         * modules/login_tty (Files): Add m4/login_tty.m4.
17678         (Depends-on): Add utmp. Remove pty. Update condition.
17679         (configure.ac): Update condition. Invoke gl_UTMP_MODULE_INDICATOR
17680         instead of gl_PTY_MODULE_INDICATOR.
17681         (Include): List <utmp.h>.
17682         * doc/glibc-functions/login_tty.texi: Mark the include file diversity as
17683         fixed.
17684         * tests/test-login_tty.c: Include <utmp.h>. Don't declare login_tty
17685         here.
17687         * lib/utmp.in.h: New file.
17688         * m4/utmp_h.m4: New file.
17689         * modules/utmp: New file.
17690         * doc/glibc-headers/utmp.texi: New file.
17691         * doc/gnulib.texi (Glibc Header File Substitutes): Include it.
17693 2023-01-21  Bruno Haible  <bruno@clisp.org>
17695         login_tty: Fix detection of declaration (regression 2023-01-19).
17696         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Check for the three possible header
17697         files.
17699 2023-01-21  Bruno Haible  <bruno@clisp.org>
17701         alignasof tests: Rename test file.
17702         * tests/test-alignasof.c: Renamed from tests/test-stdalign.c.
17703         * modules/alignasof-tests (Files, Makefile.am): Update accordingly.
17705 2023-01-21  Bruno Haible  <bruno@clisp.org>
17707         alignasof tests: Fix GCC warning (regression 2023-01-15).
17708         * tests/test-stdalign.c (alignas): Undefine before redefine.
17710 2023-01-21  Bruno Haible  <bruno@clisp.org>
17712         getprogname: Move declaration from "getprogname.h" to <stdlib.h>.
17713         * lib/stdlib.in.h (getprogname): New declaration.
17714         * lib/getprogname.h: Add deprecation warning.
17715         (getprogname): Remove declaration.
17716         * lib/getprogname.c: Include <stdlib.h> instead of getprogname.h.
17717         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether getprogname is declared.
17718         (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPROGNAME.
17719         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_GETPROGNAME.
17720         * m4/getprogname.m4 (gl_PREREQ_GETPROGNAME): New macro, extracted from
17721         gl_FUNC_GETPROGNAME. Set HAVE_GETPROGNAME.
17722         (gl_FUNC_GETPROGNAME): Remove code that was moved to
17723         gl_PREREQ_GETPROGNAME.
17724         * modules/stdlib (Makefile.am): Substitute GNULIB_GETPROGNAME and
17725         HAVE_GETPROGNAME.
17726         * modules/getprogname (Depends-on): Add stdlib.
17727         (configure.ac): Define a module indicator. Invoke gl_PREREQ_GETPROGNAME.
17728         (Makefile.am): Don't compile getprogname.c if not needed.
17729         (Include): List <stdlib.h> instead of getprogname.h.
17730         * tests/test-getprogname.c: Include <stdlib.h> instead of getprogname.h.
17731         * NEWS: Mention the change.
17732         * lib/argmatch.c: Don't include getprogname.h.
17733         * lib/c-stack.c: Likewise.
17734         * lib/error.c: Likewise.
17735         * lib/git-merge-changelog.c: Likewise.
17737 2023-01-19  Paul Eggert  <eggert@cs.ucla.edu>
17739         snippet/_Noreturn: work around Clang _Noreturn bug
17740         This is a bigger-hammer workaround for the clang _Noreturn issue
17741         fix for dfa.c on 2023-01-01.  Unfortunately, it causes 270
17742         -Wreturn-type and -Wsometimes-uninitialized warnings when building
17743         bleeding-edge GNU Emacs from Git on Fedora 37 with plain
17744         ‘./configure && make’.  So the workaround is enabled only if you
17745         compile with -D_GL_WORK_AROUND_LLVM_BUG_59792.
17746         * lib/_Noreturn.h (_Noreturn):
17747         * m4/gnulib-common.m4 (gl_COMMON_BODY):
17748         #define _Noreturn to be empty if it is Clang 15 or earlier,
17749         and if _GL_WORK_AROUND_LLVM_BUG_59792 is defined.
17751 2023-01-19  Bruno Haible  <bruno@clisp.org>
17753         Fix warnings for functions introduced in Android API level 34.
17754         * modules/execute-tests (configure.ac): Test for close_range using
17755         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17757 2023-01-19  Bruno Haible  <bruno@clisp.org>
17759         Fix warnings for functions introduced in Android API level 30.
17760         * m4/threadlib.m4 (gl_STDTHREADLIB_BODY): Test for thrd_create using
17761         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17763 2023-01-19  Bruno Haible  <bruno@clisp.org>
17765         Fix warnings for functions introduced in Android API level 29.
17766         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for getloadavg using
17767         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNC.
17769 2023-01-19  Bruno Haible  <bruno@clisp.org>
17771         Fix warnings for functions introduced in Android API level 28.
17772         * m4/glob.m4 (gl_GLOB): Test for glob using gl_CHECK_FUNCS_ANDROID
17773         instead of AC_CHECK_FUNCS_ONCE.
17775 2023-01-19  Bruno Haible  <bruno@clisp.org>
17777         Fix warnings for functions introduced in Android API level 26.
17778         * m4/mountlist.m4 (gl_MOUNTLIST): Test for hasmntopt using
17779         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17780         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Test for nl_langinfo using
17781         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17782         * m4/strtod.m4 (gl_PREREQ_STRTOD): Test for nl_langinfo using
17783         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17784         * m4/strtold.m4 (gl_PREREQ_STRTOLD): Likewise.
17785         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Likewise.
17786         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R): Test for catgets using
17787         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17788         * m4/utimens.m4 (gl_UTIMENS): Test for lutimes using
17789         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17790         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Test for nl_langinfo_l using
17791         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17792         * modules/duplocale-tests (configure.ac): Likewise.
17793         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Update comment.
17795 2023-01-19  Bruno Haible  <bruno@clisp.org>
17797         Fix warnings for functions introduced in Android API level 24.
17798         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Test for strchrnul using
17799         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17801 2023-01-19  Bruno Haible  <bruno@clisp.org>
17803         Fix warnings for functions introduced in Android API level 23.
17804         * m4/fbufmode.m4 (gl_FUNC_FBUFMODE): Test for __flbf, __fbufsize using
17805         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17806         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT_LGPL): Test for mempcpy using
17807         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17808         * m4/fpurge.m4 (gl_FUNC_FPURGE): Test for __fpurge using
17809         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17810         * m4/freadable.m4 (gl_FUNC_FREADABLE): Test for __freadable using
17811         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17812         * m4/fwritable.m4 (gl_FUNC_FWRITABLE): Test for __fwritable using
17813         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17814         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): Test for __fsetlocking using
17815         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17816         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Test for mempcpy using
17817         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17818         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Test for mkfifoat using
17819         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17820         * m4/mkostemp.m4 (gl_FUNC_MKOSTEMP): Test for mkostemp using
17821         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17822         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Test for mkostemps using
17823         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17824         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Test for login_tty using
17825         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17826         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): Test for sethostname using
17827         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17828         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Test for strerror_r using
17829         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17830         * m4/wmempcpy.m4 (gl_FUNC_WMEMPCPY): Test for wmempcpy using
17831         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17833 2023-01-19  Bruno Haible  <bruno@clisp.org>
17835         Fix warnings for functions introduced in Android API level 21.
17836         * m4/_Exit.m4 (gl_FUNC__EXIT): Test for _Exit using
17837         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17838         * m4/c-strtod.m4 (gl_C_STRTOLD): Test for strtold_l using
17839         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17840         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Test for c32rtomb like
17841         gl_CHECK_FUNCS_ANDROID does.
17842         * m4/dprintf.m4 (gl_FUNC_DPRINTF): Test for dprintf using
17843         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17844         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Likewise.
17845         * m4/dup3.m4 (gl_FUNC_DUP3): Test for dup3 using
17846         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17847         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Test for duplocale using
17848         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17849         * m4/execvpe.m4 (gl_FUNC_EXECVPE): Test for execvpe using
17850         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17851         * m4/fts.m4 (gl_FUNC_FTS_CORE): Test for fts_open using
17852         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNC.
17853         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Test for getprogname using
17854         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17855         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): Test for uselocale using
17856         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17857         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Test for iswblank using
17858         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17859         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Test for
17860         tcdrain using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17861         * m4/linkat.m4 (gl_FUNC_LINKAT): Test for linkat using
17862         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17863         * m4/localename.m4 (gl_LOCALENAME): Test for newlocale, duplocale,
17864         freelocale using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17865         * m4/mbrtoc32.m4 (gl_CHECK_FUNC_MBRTOC32): Test for mbrtoc32 like
17866         gl_CHECK_FUNCS_ANDROID does.
17867         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Test for mbsnrtowcs using
17868         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17869         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Test for mbtowc using
17870         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17871         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Test for mknodat using
17872         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17873         * m4/mountlist.m4 (gl_MOUNTLIST): Test for setmntent, endmntent using
17874         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17875         * m4/posix_openpt.m4 (gl_FUNC_POSIX_OPENPT): Test for posix_openpt using
17876         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17877         * m4/pty.m4 (gl_FUNC_OPENPTY): Test for posix_openpt using
17878         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17879         * m4/random.m4 (gl_FUNC_RANDOM): Test for initstate, setstate using
17880         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17881         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Test for stpcpy using
17882         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17883         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Test for stpncpy using
17884         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17885         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Test for symlinkat using
17886         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17887         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Test for truncate using
17888         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17889         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Test for twalk using
17890         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17891         * m4/vdprintf.m4 (gl_FUNC_VDPRINTF): Test for vdprintf using
17892         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17893         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
17894         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): Test for wcsnrtombs using
17895         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17896         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Test for readlinkat using
17897         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17898         * m4/fchmodat.m4 (gl_PREREQ_FCHMODAT): Likewise.
17899         * modules/careadlinkat (configure.ac): Likewise.
17900         * modules/ftoastr (configure.ac): Test for strtof using
17901         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17902         * modules/duplocale-tests (configure.ac): Test for duplocale using
17903         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17904         * modules/hard-locale-tests (configure.ac): Likewise.
17905         * modules/locale-tests (configure.ac): Test for newlocale using
17906         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17907         * modules/localename-tests (configure.ac): Likewise.
17908         * modules/tsearch-tests (configure.ac): Test for initstate using
17909         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17910         * modules/unistr/u8-stpcpy (configure.ac): Test for stpcpy using
17911         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17913         * m4/tcgetattr.m4: New file, extracted from m4/getpass.m4.
17914         * m4/getpass.m4 (gl_PREREQ_GETPASS): Remove code that tests for
17915         tcgetattr. Invoke gl_HAVE_TCGETATTR instead.
17916         * modules/getpass (Files): Add tcgetattr.m4.
17917         * modules/getpass-gnu (Files): Add tcgetattr.m4.
17918         * modules/term-style-control (Files): Add tcgetattr.m4.
17919         (configure.ac): Remove code that tests for tcgetattr. Invoke
17920         gl_HAVE_TCGETATTR instead.
17922 2023-01-19  Bruno Haible  <bruno@clisp.org>
17924         Fix warnings for functions introduced in Android API level 19.
17925         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Test for futimens using
17926         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17927         * m4/utimens.m4 (gl_UTIMENS): Likewise.
17928         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Test for imaxabs using
17929         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17930         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Test for imaxdiv using
17931         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17933 2023-01-19  Bruno Haible  <bruno@clisp.org>
17935         Fix warnings for functions introduced in Android API level 18.
17936         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Test for getdelim using
17937         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17938         * m4/getline.m4 (gl_FUNC_GETLINE): Test for getline using
17939         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNC.
17940         * m4/log2.m4 (gl_FUNC_LOG2): Test for log2 using
17941         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17942         * m4/log2f.m4 (gl_FUNC_LOG2F): Test for log2f using
17943         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17944         * m4/log2l.m4 (gl_FUNC_LOG2L): Test for log2l using
17945         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17947 2023-01-19  Bruno Haible  <bruno@clisp.org>
17949         Fix warnings for functions introduced in Android API level 16 or 17.
17950         * m4/posix_memalign.m4 (gl_FUNC_POSIX_MEMALIGN): Test for posix_memalign
17951         using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17952         * m4/alignalloc.m4 (gl_ALIGNALLOC): Likewise.
17953         * m4/pagealign_alloc.m4 (gl_PREREQ_PAGEALIGN_ALLOC): Likewise.
17954         * modules/aligned-malloc (configure.ac): Likewise.
17956 2023-01-19  Bruno Haible  <bruno@clisp.org>
17958         Fix warnings for functions introduced in Android API level 16.
17959         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Test for faccessat using
17960         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17961         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE,
17962         gl_CANONICALIZE_LGPL_SEPARATE): Likewise.
17963         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
17964         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Test for tsearch using
17965         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17966         * m4/setenv.m4 (gl_PREREQ_SETENV): Likewise.
17968 2023-01-19  Bruno Haible  <bruno@clisp.org>
17970         Fix warnings for functions introduced in Android API level 12.
17971         Reported by Po Lu <luangruo@yahoo.com>.
17972         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Test for ftruncate using
17973         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17974         * m4/glob.m4 (gl_PREREQ_GLOB): Test for getpwnam_r using
17975         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17976         * m4/nproc.m4 (gl_PREREQ_NPROC): Test for sched_getaffinity using
17977         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17978         * m4/pread.m4 (gl_FUNC_PREAD): Test for pread using
17979         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17980         * m4/pwrite.m4 (gl_FUNC_PWRITE): Test for pwrite using
17981         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17982         * m4/thread.m4 (gl_THREAD): Test for pthread_atfork using
17983         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
17984         * m4/timegm.m4 (gl_FUNC_TIMEGM): Test for timegm using
17985         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17986         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Test for utimensat using
17987         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17988         * m4/utimens.m4 (gl_UTIMENS): Likewise.
17990 2023-01-19  Bruno Haible  <bruno@clisp.org>
17992         Fix warnings for functions introduced in Android API level 9.
17993         * m4/pipe2.m4 (gl_FUNC_PIPE2): Test for pipe2 using
17994         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17995         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Update comments.
17997 2023-01-19  Bruno Haible  <bruno@clisp.org>
17999         Fix warnings for functions introduced in Android API level 8.
18000         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test for ttyname_r using
18001         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
18003 2023-01-19  Bruno Haible  <bruno@clisp.org>
18005         fts: Document this module.
18006         * doc/glibc-headers/fts.texi: Mention the 'fts' module.
18007         * doc/glibc-functions/fts_children.texi: Likewise.
18008         * doc/glibc-functions/fts_close.texi: Likewise.
18009         * doc/glibc-functions/fts_open.texi: Likewise.
18010         * doc/glibc-functions/fts_read.texi: Likewise.
18011         * doc/glibc-functions/fts_set.texi: Likewise.
18013 2023-01-18  Bruno Haible  <bruno@clisp.org>
18015         getcwd: Speed up on Linux. Add support for Android.
18016         * lib/getcwd.c (__getcwd_generic): On Linux, use a specific readlink
18017         call to speed up the operation.
18019 2023-01-17  Paul Eggert  <eggert@cs.ucla.edu>
18021         qcopy-acl: port to Fedora 9
18022         It has libattr-2.4.41, which is too old for our code.
18023         Problem reported by Po Lu <https://bugs.gnu.org/60843>.
18024         * m4/xattr.m4 (gl_FUNC_XATTR): Check that we can use
18025         ATTR_ACTION_PERMISSIONS, too.  Refactor so that there’s a single
18026         test program that we compile and link, rather than doing the tests
18027         in dribs and drabs.
18029 2023-01-17  Bruno Haible  <bruno@clisp.org>
18031         execute tests: Avoid test failure with GNU make 4.4.
18032         Reported by Eric Blake in
18033         <https://lists.gnu.org/archive/html/bug-gnulib/2023-01/msg00157.html>.
18034         * tests/test-execute-main.c (main): Reset the SIGPIPE handler to
18035         default on all platforms.
18037 2023-01-17  Bruno Haible  <bruno@clisp.org>
18039         fflush: Tweak last commit.
18040         * lib/stdio-impl.h (fp_): Make the last change work also with newer
18041         Android NDKs and _FILE_OFFSET_BITS=64.
18043 2023-01-17  Ondrej Valousek  <ondrej.valousek.xm@renesas.com>
18045         qset-acl, acl: Improve comments.
18046         * lib/qset-acl.c (qset_acl): Improve comments.
18047         * lib/set-acl.c (set_acl): Likewise.
18049 2023-01-17  Bruno Haible  <bruno@clisp.org>
18051         fflush: Fix a buffer overrun on 32-bit Android.
18052         * lib/stdio-impl.h (fp_): On Android, change the type of _offset to
18053         'long'.
18054         * lib/fflush.c (update_fpos_cache): On Android, update a 'long', not an
18055         'fpos_t'.
18057 2023-01-17  Bruno Haible  <bruno@clisp.org>
18059         execute tests: Avoid test failure on Android.
18060         * tests/test-execute-main.c (main): Reset the SIGPIPE handler to
18061         default.
18063 2023-01-17  Bruno Haible  <bruno@clisp.org>
18065         hard-locale: Port to Android ≥ 5.0.
18066         * lib/hard-locale.c: Include <stdlib.h>.
18067         (hard_locale): On Android, consider also MB_CUR_MAX, even if the
18068         locale's name is "C".
18069         * tests/test-hard-locale.c (test_one, main): Assume that on Android,
18070         even the "C" locale is hard.
18072 2023-01-16  Bruno Haible  <bruno@clisp.org>
18074         stddef tests: Fix compilation error (regression 2023-01-15).
18075         * tests/test-stddef.c: Don't include <stdalign.h>.
18077 2023-01-16  Bruno Haible  <bruno@clisp.org>
18079         mbrtowc, mbrtoc32 tests: Avoid test failure on Android ≥ 5.0.
18080         * tests/test-mbrtowc.c (main): On Android 5.0 or newer, when testing
18081         the "C" locale, verify that the encoding is UTF-8.
18082         * tests/test-mbrtoc32.c (main): Likewise.
18083         * doc/posix-functions/setlocale.texi: Mention the Android problems.
18085         mbrtowc, mbrtoc32 tests: Refactor.
18086         * tests/test-mbrtowc.c (main): Straighten convoluted code.
18087         * tests/test-mbrtoc32.c (main): Likewise.
18089 2023-01-16  Paul Eggert  <eggert@cs.ucla.edu>
18091         sigpipe tests: Modernize use of 'head'.
18092         POSIX no longer requires support for ‘head -1’.
18093         * tests/test-sigpipe.sh: Use ‘head -n1’ rather than ‘head -1’.
18094         * tests/test-sigpipe.c (main): Likewise.
18095         * lib/git-merge-changelog.c (main): Update comment accordingly.
18097 2023-01-15  Paul Eggert  <eggert@cs.ucla.edu>
18099         alignasof: new module
18100         This splits off support for the C23 keywords alignas and alignof,
18101         from the now-deprecated stdalign module.  The latter now merely
18102         provides C11 support.
18103         * MODULES.html.sh, NEWS, doc/gnulib.texi:
18104         * doc/posix-headers/stdalign.texi: Document the change.
18105         * lib/stdalign.in.h: Remove most of the definitions (which are now
18106         supplied by the alignasof module), leaving only
18107         __alignas_is_defined and __alignof_is_defined.
18108         * modules/alignasof, modules/alignasof-tests: New files.
18109         * m4/stdalign.m4 (gl_ALIGNASOF): New macro, with
18110         most of the contents of the old gl_STDALIGN_H.
18111         Do not define __alignas_is_defined or __alignof_is_defined.
18112         (gl_STDALIGN_H): Rely on gl_ALIGNASOF for most of the work.
18113         * modules/alignalloc, modules/alignof, modules/argp:
18114         * modules/crypto/md4-buffer, modules/crypto/md5-buffer:
18115         * modules/crypto/sha1-buffer, modules/crypto/sha256-buffer:
18116         * modules/crypto/sha512-buffer, modules/crypto/sm3-buffer:
18117         * modules/fts, modules/rawmemchr, modules/relocatable-prog-wrapper:
18118         * modules/stddef-tests, modules/sys_socket:
18119         Depend on alignasof, not stdalign.
18120         * modules/stdalign: Deprecate.  Depend on alignasof.
18121         * modules/stdalign-tests: Move most contents to the new module
18122         alignasof-tests, and depend on that.
18124 2023-01-15  Bruno Haible  <bruno@clisp.org>
18126         fpending: Fix compilation error with NDK ≥ r14b and Android API < 23.
18127         Report and patch by Po Lu <luangruo@yahoo.com>.
18128         * lib/fpending.c (__fpending) [__ANDROID__]: Use the fp_ macro.
18130 2023-01-14  Paul Eggert  <eggert@cs.ucla.edu>
18132         alignof: port to strict C23
18133         Problem reported by Khem Raj in:
18134         https://lists.gnu.org/r/bug-gnulib/2023-01/msg00111.html
18135         * lib/alignof.h (alignof_slot) [!__cplusplus]: Use C23-style alignof.
18136         * modules/alignof (Depends-on): Add stdalign.
18138         test-framework-sh: work around AIX 7.2 diff bugs
18139         * tests/init.sh (compare_dev_null_): Run diff in the C locale.
18140         AIX 7.2 diff messes up in UTF-8 locales; for example,
18141         ‘printf '\360\220\200\200\n' | diff - /dev/null’ incorrectly
18142         outputs nothing and exits with status 0 when LC_ALL=en_US.UTF-8.
18144 2023-01-14  Bruno Haible  <bruno@clisp.org>
18146         error, verror tests: Fix link error when the package uses libintl.
18147         * modules/error-tests (Makefile.am): Link test-error with $(LIBINTL).
18148         * modules/verror-tests (Makefile.am): Link test-verror with $(LIBINTL).
18150 2023-01-13  Bruno Haible  <bruno@clisp.org>
18152         localename: Fix -Wtautological-pointer-compare warning in a better way.
18153         * lib/localename.c (duplocale, freelocale): Revert last patch.
18154         (_GL_ARG_NONNULL): Define to empty.
18156 2023-01-13  Paul Eggert  <eggert@cs.ucla.edu>
18158         verify: work around xlclang 16.1 compiler bug
18159         Problem reported by Bruno Haible in:
18160         https://lists.gnu.org/r/grep-devel/2023-01/msg00003.html
18161         * lib/verify.h (_GL_HAS_BUILTIN_TRAP, _GL_HAS_BUILTIN_UNREACHABLE):
18162         Define to 0 if compiler advertises itself as clang before version 5.
18163         xlclang 16.1 advertises itself as 4.0.1 and this patch works
18164         around what appears to be a compiler bug when compiling dfa.c in
18165         bleeding-edge grep.
18167         assert-h: suppress xlclang 16.1 false alarms
18168         * m4/assert_h.m4 (gl_ASSERT_H): Pacify older clangs too,
18169         with regard to single-argument static_assert.
18170         Problem found with xlclang 16.1 on AIX 7.2.
18172         assert-h: fix configure comment-out
18173         * m4/assert_h.m4 (gl_ASSERT_H): Also break apart "#undef
18174         static_assert" with /**/.  Problem discovered with xlclang 16.1,
18175         though it does not directly affect xlclang 16.1.
18177         Don’t use alloc_size with xlclang 16.1
18178         * m4/gnulib-common.m4 (_GL_HAS_ATTRIBUTE): Require Clang 5 instead
18179         of 3.5 for this, to pacify xlclang 16.1.0 on AIX 7.2, which
18180         advertises itself as clang 4.0.1, and which otherwise issues
18181         warnings like “./xalloc.h:141:3: warning: 1540-2990 The attribute
18182         "__attribute__((alloc_size(2, 3)))" is not supported.  The
18183         attribute is ignored.” when building bleeding-edge GNU grep.
18185         localename: -Wtautological-pointer-compare
18186         Problem found by xlclang 16.1 on AIX 7.2.
18187         * lib/localename.c (duplocale, freelocale):
18188         Omit unnecessary comparison of non-null args to NULL.
18190 2023-01-13  Bruno Haible  <bruno@clisp.org>
18192         login_tty tests: Be more verbose when the test fails.
18193         * tests/test-login_tty.c (main): When the test fails, write a message
18194         into a file.
18196 2023-01-13  Bruno Haible  <bruno@clisp.org>
18198         qcopy-acl: Make last patch more robust.
18199         * m4/acl.m4 (gl_FUNC_ACL): Define through AC_DEFUN_ONCE.
18200         * modules/qcopy-acl (configure.ac): Require gl_FUNC_ACL.
18202         qcopy-acl: Adjust link dependencies.
18203         * modules/qcopy-acl (Depends-on): Add condition.
18204         (configure.ac): Set QCOPY_ACL_LIB.
18205         (Link): Add $(QCOPY_ACL_LIB). Remove $(LIB_ACL).
18206         * modules/qacl (Link): Add $(LIB_ACL) and $(QCOPY_ACL_LIB).
18207         * modules/acl (Link): Add $(LIB_ACL) and $(QCOPY_ACL_LIB).
18208         * modules/copy-file (Link): Add $(QCOPY_ACL_LIB).
18209         * modules/supersede (Link): Add $(QCOPY_ACL_LIB).
18210         * modules/acl-tests (Makefile.am): Link test-copy-acl with
18211         $(QCOPY_ACL_LIB).
18212         * modules/copy-file-tests (Makefile.am): Link test-copy-file with
18213         $(QCOPY_ACL_LIB).
18214         * modules/supersede-tests (Makefile.am): Link test-supersede with
18215         $(QCOPY_ACL_LIB).
18217 2023-01-13  Bruno Haible  <bruno@clisp.org>
18219         qcopy-acl: Avoid autoconf warning.
18220         * m4/xattr.m4 (gl_FUNC_XATTR): Provide a description in AC_DEFINE.
18221         Also, protect against unsafe use of a configure option value.
18223 2023-01-12  Ondrej Valousek  <ondrej.valousek.xm@renesas.com>
18225         qcopy-acl: Optimize copying of ACLs by directly copying the attributes.
18226         * lib/qcopy-acl.c (is_attr_permissions): New functions.
18227         (qcopy_acl): If USE_XATTR, copy the ACL related attributes directly.
18228         * m4/xattr.m4: New file.
18229         * modules/qcopy-acl (Files): Add it.
18230         (configure.ac): Invoke gl_FUNC_XATTR.
18232 2023-01-12  Bruno Haible  <bruno@clisp.org>
18234         error: Work around an Android problem.
18235         * lib/error.in.h: Renamed from lib/error.h.
18236         (_GL_ATTRIBUTE_SPEC_PRINTF_ERROR): New macro.
18237         (error): Consider HAVE_ERROR and REPLACE_ERROR.
18238         (error_at_line): Consider HAVE_ERROR_AT_LINE and REPLACE_ERROR_AT_LINE.
18239         * m4/error_h.m4: New file, partially based on m4/error.m4.
18240         * m4/error.m4 (gl_ERROR): Remove the test for error_at_line.
18241         * modules/error-h: New file.
18242         * modules/error (Files): Remove lib/error.h.
18243         (Depends-on): Add error-h. Update conditions.
18244         (configure.ac): Require gl_ERROR_H. Update condition.
18245         * doc/glibc-headers/error.texi: Mention the 'error-h' module.
18246         * doc/glibc-functions/error.texi: Mention the Android problem.
18247         * config/srclist.txt: Add comment regarding error.h.
18249 2023-01-12  Bruno Haible  <bruno@clisp.org>
18251         error, verror tests: Add clarification.
18252         * tests/test-error.c (main): Clarify why we don't test error_at_line
18253         with a NULL filename.
18254         * tests/test-verror.c (main): Clarify why we don't test verror_at_line
18255         with a NULL filename.
18257 2023-01-12  Bruno Haible  <bruno@clisp.org>
18259         verror: Add tests.
18260         * tests/test-verror.sh: New file, based on tests/test-error.sh.
18261         * tests/test-verror.c: New file, based on tests/test-error.c.
18262         * modules/verror-tests: New file.
18264 2023-01-12  Bruno Haible  <bruno@clisp.org>
18266         error: Add tests.
18267         * tests/test-error.sh: New file.
18268         * tests/test-error.c: New file.
18269         * modules/error-tests: New file.
18271 2023-01-11  Bruno Haible  <bruno@clisp.org>
18273         xstrtol-error: Improve comments.
18274         * lib/xstrtol-error.h (xstrtol_fatal): Add parameter names to
18275         declaration.
18277 2023-01-11  Bruno Haible  <bruno@clisp.org>
18279         spawn-pipe tests: Fix test failure on Android.
18280         * tests/test-spawn-pipe-child.c (main): Skip the is_open (STDERR_FILENO)
18281         check on Android.
18283 2023-01-11  Bruno Haible  <bruno@clisp.org>
18285         perror: Fix "perror clobbers strerror's buffer" problem on Android.
18286         * m4/perror.m4 (gl_FUNC_PERROR): Set REPLACE_PERROR to 1 on Android.
18287         * doc/posix-functions/perror.texi: Mention the Android problem.
18289 2023-01-11  Bruno Haible  <bruno@clisp.org>
18291         posix_spawn_file_actions_addfchdir tests: Fix test failure on Android.
18292         * tests/test-posix_spawn-fchdir.c: Include xvasprintf.h.
18293         (test): On Android, use "/proc" instead of "/".
18294         (main): Determine the relative location of the 'pwd' program
18295         accordingly.
18296         * modules/posix_spawn_file_actions_addfchdir-tests (Depends-on): Add
18297         xvasprintf.
18299 2023-01-11  Bruno Haible  <bruno@clisp.org>
18301         rename, renameat, renameatu: Fix test failures on Android/Termux.
18302         * tests/test-rename.h (test_rename): On Android, treat an EACCES failure
18303         like EPERM.
18305 2023-01-11  Bruno Haible  <bruno@clisp.org>
18307         link, linkat tests: Fix test failures on Android/Termux.
18308         * tests/test-link.h (test_link): On Android, treat an EACCES failure
18309         like EPERM.
18310         * tests/test-linkat.c (main): When test_link is marked skipped, skip the
18311         rest of the test as well.
18313 2023-01-11  Bruno Haible  <bruno@clisp.org>
18315         link tests: Correct indentation.
18316         * tests/test-link.h (test_link): Correct indentation.
18318 2023-01-11  Bruno Haible  <bruno@clisp.org>
18320         Fix link errors on Android 4.3.
18321         * lib/asyncsafe-spin.c: Don't use the GCC >= 4.1 builtins on Android,
18322         when building with GCC.
18323         * lib/pthread-spin.c: Likewise.
18324         * lib/simple-atomic.c: Likewise.
18326 2023-01-10  Jim Meyering  <meyering@fb.com>
18328         update-copyright: also work with two or more updatable lines in a file
18329         * build-aux/update-copyright: Replace every occurrence of the copyright
18330         line, not just the first one.
18331         * tests/test-update-copyright.sh: Add a test case for this.
18333 2023-01-10  Bruno Haible  <bruno@clisp.org>
18335         immutable: Fix initialization failure on Android.
18336         * lib/immutable.c: Include "pathmax.h".
18337         (do_init_mmap_file): Use $TMPDIR rather than /tmp, if it is safe.
18338         * modules/immutable (Depends-on): Add pathmax.
18340 2023-01-10  Bruno Haible  <bruno@clisp.org>
18342         Fix some test failures on Android ≥ 11.
18343         * tests/test-fclose.c (main): On Android, avoid triggering the
18344         file-descriptor sanitizer (fdsan).
18345         * tests/test-fdopen.c (main): Likewise.
18346         * tests/test-fflush.c (main): Likewise.
18347         * tests/test-fgetc.c (main): Likewise.
18348         * tests/test-fputc.c (main): Likewise.
18349         * tests/test-fread.c (main): Likewise.
18350         * tests/test-fseeko4.c (main): Likewise.
18351         * tests/test-ftello4.c (main): Likewise.
18352         * tests/test-fwrite.c (main): Likewise.
18354 2023-01-10  Bruno Haible  <bruno@clisp.org>
18356         utimens: Fix warning on Android.
18357         * m4/utimens.m4 (gl_UTIMENS): Test for futimesat and futimes using
18358         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
18360 2023-01-10  Bruno Haible  <bruno@clisp.org>
18362         secure_getenv: Fix warning on Android.
18363         * m4/secure_getenv.m4 (gl_FUNC_SECURE_GETENV): Test for issetugid using
18364         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
18365         * lib/secure_getenv.c: Fix comment regarding issetugid.
18367 2023-01-10  Bruno Haible  <bruno@clisp.org>
18369         renameat, renameatu: Fix warning on Android.
18370         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Test for renameat2 using
18371         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
18373 2023-01-10  Bruno Haible  <bruno@clisp.org>
18375         memset_explicit tests: Fix signature check.
18376         * tests/test-memset_explicit.c: Fix return type in signature check.
18378 2023-01-10  Bruno Haible  <bruno@clisp.org>
18380         math: Fix compilation errors in C++ mode on Android.
18381         * lib/math.in.h: Declare nothing if this file gets included from
18382         /usr/include/c++/v1/math.h too early.
18384 2023-01-10  Bruno Haible  <bruno@clisp.org>
18386         sys_ioctl: Fix compilation error in C++ mode on Android.
18387         * lib/sys_ioctl.in.h (ioctl): Disable _GL_CXXALIASWARN invocation on
18388         non-glibc systems.
18390 2023-01-09  Bruno Haible  <bruno@clisp.org>
18392         threads-h: Improve portability.
18393         * lib/threads.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE when possible.
18394         * modules/threads-h (Makefile.am): Substitute
18395         INCLUDE_NEXT_AS_FIRST_DIRECTIVE and NEXT_AS_FIRST_DIRECTIVE_THREADS_H.
18397 2023-01-09  Bruno Haible  <bruno@clisp.org>
18399         threads-h: Fix compilation errors in C++ mode on Android.
18400         * lib/threads.in.h (_GL_ALREADY_INCLUDING_THREADS_H): New macro.
18402 2023-01-09  Bruno Haible  <bruno@clisp.org>
18404         aligned-malloc: Don't disturb the module aligned_alloc.
18405         * modules/aligned-malloc (configure.ac): Test for aligned_alloc in the
18406         same way as module aligned_alloc does.
18408 2023-01-09  Bruno Haible  <bruno@clisp.org>
18410         malloc-h: Improve portability.
18411         * lib/malloc.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE when possible.
18412         * modules/malloc-h (Makefile.am): Substitute
18413         INCLUDE_NEXT_AS_FIRST_DIRECTIVE and NEXT_AS_FIRST_DIRECTIVE_MALLOC_H.
18415 2023-01-09  Bruno Haible  <bruno@clisp.org>
18417         reallocarray: Fix compilation error in C++ mode on Android.
18418         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY): Use gl_CHECK_FUNCS_ANDROID
18419         instead of AC_CHECK_FUNCS.
18421 2023-01-09  Bruno Haible  <bruno@clisp.org>
18423         getsubopt: Fix compilation error in C++ mode on Android.
18424         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Use gl_CHECK_FUNCS_ANDROID
18425         instead of AC_CHECK_FUNCS_ONCE.
18427 2023-01-09  Bruno Haible  <bruno@clisp.org>
18429         malloc-h: Fix compilation errors in C++ mode on Android.
18430         * lib/malloc.in.h: Don't include <stdlib.h>, except on Solaris and on
18431         HP-UX. Include <stddef.h>. Make _GL_ATTRIBUTE_DEALLOC_FREE work (code
18432         snippet copied from string.in.h and wchar.in.h).
18433         * m4/malloc_h.m4 (gl_MALLOC_H_REQUIRE_DEFAULTS): Invoke
18434         gl_STDLIB_H_REQUIRE_DEFAULTS.
18435         * modules/malloc-h (Depends-on): Add stddef, stdlib.
18436         (Makefile.am): Substitute GNULIB_FREE_POSIX and REPLACE_FREE.
18438 2023-01-09  Bruno Haible  <bruno@clisp.org>
18440         gettime: Fix compilation error in C++ mode on Android.
18441         * m4/gettime.m4 (gl_CHECK_FUNC_TIMESPEC_GET): Also test whether
18442         timespec_get is declared.
18444 2023-01-09  Bruno Haible  <bruno@clisp.org>
18446         malloc-h: Fix compilation error in C++ mode on Android.
18447         * lib/malloc.in.h (_GL_ALREADY_INCLUDING_MALLOC_H): New macro.
18449 2023-01-07  Bruno Haible  <bruno@clisp.org>
18451         timer_time: Rename LIB_TIMER_TIME to TIMER_TIME_LIB.
18452         * m4/timer_time.m4: Rename LIB_TIMER_TIME to TIMER_TIME_LIB.
18453         All uses changed.
18454         * NEWS: Mention the change
18456 2023-01-07  Bruno Haible  <bruno@clisp.org>
18458         setlocale-null: Rename LIB_SETLOCALE_NULL to SETLOCALE_NULL_LIB.
18459         * m4/setlocale_null.m4: Rename LIB_SETLOCALE_NULL to SETLOCALE_NULL_LIB.
18460         All uses changed.
18461         * NEWS: Mention the change
18463 2023-01-07  Bruno Haible  <bruno@clisp.org>
18465         setlocale: Rename LIB_SETLOCALE to SETLOCALE_LIB.
18466         * m4/setlocale.m4: Rename LIB_SETLOCALE to SETLOCALE_LIB.
18467         All uses changed.
18468         * NEWS: Mention the change.
18470 2023-01-07  Bruno Haible  <bruno@clisp.org>
18472         select: Rename LIB_SELECT to SELECT_LIB.
18473         * m4/select.m4: Rename LIB_SELECT to SELECT_LIB.
18474         All uses changed.
18475         * NEWS: Mention the change.
18477 2023-01-07  Bruno Haible  <bruno@clisp.org>
18479         sched_yield: Rename LIB_SCHED_YIELD to SCHED_YIELD_LIB.
18480         * m4/threadlib.m4: Rename LIB_SCHED_YIELD to SCHED_YIELD_LIB.
18481         All uses changed.
18482         * NEWS: Mention the change.
18484 2023-01-07  Bruno Haible  <bruno@clisp.org>
18486         pthread_sigmask: Rename LIB_PTHREAD_SIGMASK to PTHREAD_SIGMASK_LIB.
18487         * m4/pthread_sigmask.m4: Rename LIB_PTHREAD_SIGMASK to
18488         PTHREAD_SIGMASK_LIB.
18489         All uses changed.
18490         * NEWS: Mention the change.
18492 2023-01-07  Bruno Haible  <bruno@clisp.org>
18494         posix_spawn: Rename LIB_POSIX_SPAWN to POSIX_SPAWN_LIB.
18495         * m4/spawn_h.m4: Rename LIB_POSIX_SPAWN to POSIX_SPAWN_LIB.
18496         All uses changed.
18497         * NEWS: Mention the change.
18499 2023-01-07  Bruno Haible  <bruno@clisp.org>
18501         poll: Rename LIB_POLL to POLL_LIB.
18502         * m4/poll.m4: Rename LIB_POLL to POLL_LIB.
18503         All uses changed.
18504         * NEWS: Mention the change.
18506 2023-01-07  Bruno Haible  <bruno@clisp.org>
18508         nanosleep: Rename LIB_NANOSLEEP to NANOSLEEP_LIB.
18509         * m4/nanosleep.m4: Rename LIB_NANOSLEEP to NANOSLEEP_LIB.
18510         All uses changed.
18511         * NEWS: Mention the change.
18513 2023-01-07  Bruno Haible  <bruno@clisp.org>
18515         mbrtowc: Rename LIB_MBRTOWC to MBRTOWC_LIB.
18516         * m4/mbrtowc.m4: Rename LIB_MBRTOWC to MBRTOWC_LIB.
18517         All uses changed.
18518         * NEWS: Mention the change.
18520 2023-01-07  Bruno Haible  <bruno@clisp.org>
18522         hard-locale: Rename LIB_HARD_LOCALE to HARD_LOCALE_LIB.
18523         * modules/hard-locale (configure.ac): Rename LIB_HARD_LOCALE to
18524         HARD_LOCALE_LIB.
18525         All uses changed.
18526         * NEWS: Mention the change.
18528 2023-01-07  Bruno Haible  <bruno@clisp.org>
18530         getrandom: Rename LIB_GETRANDOM to GETRANDOM_LIB.
18531         * m4/getrandom.m4: Rename LIB_GETRANDOM to GETRANDOM_LIB.
18532         All uses changed.
18533         * NEWS: Mention the change.
18535 2023-01-07  Bruno Haible  <bruno@clisp.org>
18537         getlogin, getlogin_r: Rename LIB_GETLOGIN to GETLOGIN_LIB.
18538         * m4/getlogin.m4: Rename LIB_GETLOGIN to GETLOGIN_LIB.
18539         All uses changed.
18540         * NEWS: Mention the change.
18542 2023-01-07  Bruno Haible  <bruno@clisp.org>
18544         gethrxtime: Rename LIB_GETHRXTIME to GETHRXTIME_LIB.
18545         * m4/gethrxtime.m4: Rename LIB_GETHRXTIME to GETHRXTIME_LIB.
18546         All uses changed.
18547         * NEWS: Mention the change.
18549 2023-01-07  Bruno Haible  <bruno@clisp.org>
18551         fdatasync: Rename LIB_FDATASYNC to FDATASYNC_LIB.
18552         * m4/fdatasync.m4: Rename LIB_FDATASYNC to FDATASYNC_LIB.
18553         All uses changed.
18554         * NEWS: Mention the change.
18556 2023-01-07  Bruno Haible  <bruno@clisp.org>
18558         euidaccess: Rename LIB_EACCESS to EUIDACCESS_LIBGEN.
18559         * m4/euidaccess.m4: Rename LIB_EACCESS to EUIDACCESS_LIBGEN.
18560         All uses changed.
18561         * NEWS: Mention the change.
18563 2023-01-07  Bruno Haible  <bruno@clisp.org>
18565         duplocale: Rename LIB_DUPLOCALE to DUPLOCALE_LIB.
18566         * m4/duplocale.m4: Rename LIB_DUPLOCALE to DUPLOCALE_LIB.
18567         All uses changed.
18568         * NEWS: Mention the change.
18570 2023-01-07  Bruno Haible  <bruno@clisp.org>
18572         clock_time: Rename LIB_CLOCK_GETTIME to CLOCK_TIME_LIB.
18573         * m4/clock_time.m4: Rename LIB_CLOCK_GETTIME to CLOCK_TIME_LIB.
18574         All uses changed.
18575         * NEWS: Mention the change.
18577 2023-01-06  Paul Eggert  <eggert@cs.ucla.edu>
18579         file-has-acl: don’t bother setting LIB_HAS_ACL
18580         * m4/acl.m4 (gl_FUNC_ACL, gl_FILE_HAS_ACL): Don’t set LIB_HAS_ACL.
18581         I think only Coreutils and Tar used it, and I’ve updated them.
18583         bootstrap: suppress stray message from --pull
18584         * build-aux/bootstrap: Regenerate.
18585         * top/bootstrap-funclib.sh (autopull): Suggest running autogen.sh
18586         only if it exists (i.e., the package is using autopull.sh/autogen.sh).
18587         Suggest the same name for autogen.sh that is used in the test.
18589 2023-01-05  Bruno Haible  <bruno@clisp.org>
18591         string: Fix compilation errors in C++ mode on Android.
18592         * lib/string.in.h (memrchr, strchrnul, strcasestr): Disable
18593         _GL_CXXALIASWARN invocation on non-glibc systems.
18595 2023-01-05  Bruno Haible  <bruno@clisp.org>
18597         getpass: Fix compilation error on Android.
18598         * m4/getpass.m4 (gl_FUNC_GETPASS): Define NO_INLINE_GETPASS.
18599         * doc/glibc-functions/getpass.texi: Mention the Android problem.
18601 2023-01-05  Bruno Haible  <bruno@clisp.org>
18603         Recognize functions added in future versions of Android.
18604         * m4/gnulib-common.m4 (gl_CHECK_FUNCS_ANDROID): New macro.
18605         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Use
18606         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
18607         * m4/freading.m4 (gl_FUNC_FREADING): Likewise.
18608         * m4/fseterr.m4 (gl_FUNC_FSETERR): Likewise.
18609         * m4/fwriting.m4 (gl_FUNC_FWRITING): Likewise.
18610         * m4/getentropy.m4 (gl_FUNC_GETENTROPY): Likewise.
18611         * m4/getlogin_r.m4 (gl_CHECK_FUNCS_ANDROID): Likewise.
18612         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
18613         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
18614         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): Likewise.
18615         * doc/glibc-functions/getentropy.texi: Mark function as existing in
18616         Android 9.0.
18617         * doc/glibc-functions/getrandom.texi: Likewise.
18618         * doc/posix-functions/pthread_attr_getinheritsched.texi: Likewise.
18619         * doc/posix-functions/pthread_attr_setinheritsched.texi: Likewise.
18621 2023-01-05  Bruno Haible  <bruno@clisp.org>
18623         copy-file, supersede: Fix link-time requirements.
18624         * modules/copy-file (Link): Add $(LIB_ACL).
18625         * modules/supersede (Link): Likewise.
18627 2023-01-05  Bruno Haible  <bruno@clisp.org>
18629         More systematic naming of LIB variables.
18630         * m4/acl.m4 (gl_FUNC_ACL, gl_FILE_HAS_ACL): Set FILE_HAS_ACL_LIB to the
18631         same value as LIB_HAS_ACL.
18632         * modules/file-has-acl (Link): Use FILE_HAS_ACL_LIB instead of
18633         LIB_HAS_ACL.
18634         * modules/file-has-acl-tests (Makefile.am): Likewise.
18636 2023-01-04  Bruno Haible  <bruno@clisp.org>
18638         doc: Update regarding Android.
18639         * doc/glibc-functions/getdtablesize.texi: Update Android information.
18640         * doc/glibc-functions/wait3.texi: Likewise.
18641         * doc/pastposix-functions/ftime.texi: Likewise.
18642         * doc/pastposix-functions/index.texi: Likewise.
18643         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Likewise.
18644         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Likewise.
18645         * doc/pastposix-functions/wcswcs.texi: Likewise.
18647 2023-01-03  Bruno Haible  <bruno@clisp.org>
18649         ffsl, ffsll: Fix compilation error on Android.
18650         * lib/string.in.h: On Android as well, include <strings.h>.
18651         * m4/ffsl.m4 (gl_FUNC_FFSL): Use a specific link test instead of
18652         AC_CHECK_FUNCS_ONCE.
18653         * m4/ffsll.m4 (gl_FUNC_FFSLL): Likewise.
18654         * doc/glibc-functions/ffsl.texi: Mention Android problems.
18655         * doc/glibc-functions/ffsll.texi: Likewise.
18657         ffs: Document Android problem.
18658         * doc/posix-functions/ffs.texi: Mention Android problem.
18659         * m4/ffs.m4: Update comment.
18661 2023-01-03  Bruno Haible  <bruno@clisp.org>
18663         stdio: Fix error in C++ mode on Android, due to putw.
18664         * lib/stdio.in.h (putw): Don't declare in the C++ namespace if putw is
18665         not declared.
18666         * m4/stdio_h.m4 (gl_STDIO_H): Test whether putw is declared.
18667         (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_PUTW.
18668         * modules/stdio (Makefile.am): Substitute HAVE_DECL_PUTW.
18669         * doc/glibc-functions/putw.texi: Update regarding Android.
18671 2023-01-03  Bruno Haible  <bruno@clisp.org>
18673         stdio: Fix error in C++ mode on Android, due to getw.
18674         * lib/stdio.in.h (getw): Don't declare in the C++ namespace if getw is
18675         not declared.
18676         * m4/stdio_h.m4 (gl_STDIO_H): Test whether getw is declared.
18677         (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_GETW.
18678         * modules/stdio (Makefile.am): Substitute HAVE_DECL_GETW.
18680 2023-01-02  Bruno Haible  <bruno@clisp.org>
18682         sigsegv: Fix compilation error on Android 4.3.
18683         * lib/sigsegv.in.h: For Android, don't include <ucontext.h> and don't
18684         reference ucontext_t.
18685         * lib/sigsegv.c (SIGSEGV_FAULT_): For Android, use a plain POSIX fault
18686         handler (cf. libsigsegv/src/fault-posix.h).
18688 2023-01-01  Paul Eggert  <eggert@cs.ucla.edu>
18690         dfa: work around Clang 15 bug
18691         Problem reported by Kenton Groombridge in:
18692         https://lists.gnu.org/archive/html/bug-gawk/2022-12/msg00010.html
18693         On x86-64, Clang 15 gets confused by a call (X ? dfaerror :
18694         dfawarn) (Y) and generates the wrong code, presumably because
18695         dfaerror is _Noreturn and dfawarn is not.
18696         * lib/dfa.c (parse_bracket_exp): Reword to have one call for
18697         dfaerror, the other for dfawarn.
18699 2023-01-01  Bruno Haible  <bruno@clisp.org>
18701         doc: Update regarding stable branches.
18702         * doc/gnulib-readme.texi (Stable Branches): Mention new branch
18703         stable-202301. Mention that stable-202201 is no longer updated.
18705 2022-12-31  Paul Eggert  <eggert@cs.ucla.edu>
18707         maint: use UTC when updating copyright date
18708         Problem reported by Simon Josefsson in:
18709         https://lists.gnu.org/r/bug-gnulib/2022-12/msg00125.html
18710         * Makefile (COPYRIGHT_TZ): New macro.
18711         (update-copyright): Use it.
18713 2022-12-28  Paul Eggert  <eggert@cs.ucla.edu>
18715         assert-h: port static_assert to strict C99
18716         * lib/verify.h (_GL_VERIFY): Port MSVC hack back to C99.
18717         Problem found when testing bleeding-edge gzip on IBM XL C for AIX,
18718         V12.1 (5765-J02, 5725-C72), which complained ‘"malloca.c", line
18719         42.56: 1506-041 (E) The invocation of macro _Static_assert
18720         contains fewer arguments than are required by the macro
18721         definition.’  This diagnostic is valid because C99 requires
18722         that if you #define _Static_assert(R, ...) you must call
18723         _Static_assert with at least two arguments.  I found a similar
18724         problem with Sun C 5.9 SunOS_sparc Patch 124867-12 2009/11/22.
18726 2022-12-27  Paul Eggert  <eggert@cs.ucla.edu>
18728         file-has-acl: fix recently-introduced NFSv4 bug
18729         * lib/file-has-acl.c (acl_nfs4_nontrivial): Fix off-by-one
18730         error when rounding WHOLEN up to next multiple of 4.
18731         Pacify GCC 12.2.1 -Wcast-align.
18733         Add --pull, --gen options to build-aux/bootstrap
18734         This supports a single bootstrap script with --pull and --gen
18735         options, as an alternative to separate autogen.sh and autopull.sh
18736         and bootstrap-funclib.sh auxiliary files.
18737         * top/bootstrap: With --version, also output library version.
18738         Support update of package that has only the bootstrap script,
18739         and not the other three files.
18741         Support packages with just 'bootstrap'
18742         * top/bootstrap: With --version, also output library version.
18743         Support update of package that has only the bootstrap script,
18744         and not the other three files.
18746         * top/bootstrap-funclib.sh (scriptlibversion): Rename
18747         from scriptversion.  All uses changed.  This way we
18748         can distinguish script from script library versions.
18749         (upgrade_bootstrap): If the package currently has only
18750         the bootstrap script, just update that.
18752         Bootstrap with functions, not scripts
18753         * top/bootstrap: Use autopull and autogen functions, not
18754         shell scripts.  This lets build-aux/bootstrap become a
18755         standalone script.  It does not change the behavior of
18756         top/bootstrap, except for minor rewording of disagnostics.
18758         Make autopull a shell function too
18759         This does not change behavior.  It is helpful for future changes.
18760         * top/autopull.sh: Call autopull to do the actual work.
18761         (usage, download_po_files, update_po_files):
18762         Move to top/bootstrap-funclib.sh.
18763         * top/bootstrap-funclib.sh (autopull_usage): Rename from ‘usage’.
18764         (autopull): New function, containing the top level of the
18765         old top/autopull.sh.
18767         Make autogen a shell function too
18768         This does not change behavior.  It is helpful for future changes.
18769         * top/autogen.sh: Call autogen to do the actual work.
18770         (usage, version_controlled_file, gitignore_entries, insert_if_absent):
18771         (insert_vc_ignore, symlink_to_dir): Move to top/bootstrap-funclib.sh.
18772         * top/bootstrap-funclib.sh (autogen_usage): Rename from ‘usage’.
18773         (autogen): New function, containing the top level of the
18774         old top/autogen.sh.
18776 2022-12-27  Bruno Haible  <bruno@clisp.org>
18778         Fix compilation errors in C++ mode on Solaris 11 OpenIndiana.
18779         * m4/gnulib-common.m4 (gl_COMMON_BODY): In _GL_ATTRIBUTE_DEALLOC_FREE,
18780         with GNU C++, cast the 'free' function.
18781         * lib/string.in.h (_GL_ATTRIBUTE_DEALLOC_FREE): With GNU C++, cast the
18782         'free' function.
18783         * lib/wchar.in.h (_GL_ATTRIBUTE_DEALLOC_FREE): Likewise.
18785 2022-12-27  Bruno Haible  <bruno@clisp.org>
18787         stdnoreturn: Mark as deprecated, not obsolete. (Regression 2022-12-24.)
18788         * modules/stdnoreturn (Status): Remove.
18789         (Notice): Say that it is deprecated, not obsolete.
18790         * doc/noreturn.texi: Fix a typo.
18792 2022-12-26  Paul Eggert  <eggert@cs.ucla.edu>
18794         stdbool-c99: fix typo
18795         Reported against Autoconf by Todd C. Miller in:
18796         https://lists.gnu.org/r/autoconf/2022-12/msg00001.html
18797         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Sync from Autoconf master.
18799 2022-12-26  Bruno Haible  <bruno@clisp.org>
18801         ctime: Mark as deprecated, not obsolete. (Regression 2022-12-21.)
18802         * modules/ctime (Status): Remove.
18803         (Notice): Say that it is deprecated, not obsolete.
18805 2022-12-25  Paul Eggert  <eggert@cs.ucla.edu>
18807         largefile: sync from Autoconf master
18808         * m4/largefile.m4 (gl_SET_LARGEFILE_SOURCE): Test whether
18809         AC_SYS_YEAR2038 is defined when this macro is defined, not when it
18810         is used, as we now define AC_SYS_YEAR2038 later.
18811         (_AC_SYS_LARGEFILE_MACRO_VALUE): Remove.
18812         (_AC_SYS_YEAR2038_TEST_CODE, _AC_SYS_YEAR2038_OPTIONS)
18813         (_AC_SYS_YEAR2038_PROBE, _AC_SYS_YEAR2038_ENABLE)
18814         (_AC_SYS_YEAR2038_OPT_IN, AC_SYS_YEAR2038)
18815         (_AC_SYS_LARGEFILE_TEST_CODE, _AC_SYS_LARGEFILE_OPTIONS)
18816         (_AC_SYS_LARGEFILE_PROBE, _AC_SYS_LARGEFILE_ENABLE): New macros.
18817         (AC_SYS_LARGEFILE): Use them.
18818         * m4/year2038.m4: Remove.  All mentions removed.
18819         * modules/largefile, modules/year2038 (configure.ac-early):
18820         Do not require gl_YEAR2038_EARLY.
18821         * modules/year2038 (Depends-on): Depend on largefile.
18822         (configure.ac): Require AC_SYS_YEAR2038, not gl_YEAR2038.
18824 2022-12-24  Paul Eggert  <eggert@cs.ucla.edu>
18826         extensions: enable some C23 Annex F functions
18827         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
18828         Also define __STDC_WANT_IEC_60559_EXT__, for C23 Annex F
18829         functions like totalorder.  This syncs from Autoconf master.
18831         stdnoreturn: deprecate
18832         C23 says <stdnoreturn.h> is obsolescent, so deprecate the
18833         stdnoreturn module.  I don't think it was being used anyway
18834         as it had too many problems.
18835         * modules/stdnoreturn: Mark as obsolete.
18837 2022-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18839         file-has-acl: improve recent NFSv4 support
18840         This fixes a link failure with emacsclient on GNU/Linux.  This
18841         program wants file_has_acl but none of the other ACL primitives,
18842         so it doesn’t link acl-internal.o; this way it doesn’t need to
18843         link with -lacl.  While I was at it I reviewed the recent changes,
18844         fixed some unlikely overflow bugs, and adjusted to GNU style.
18845         * doc/acl-nfsv4.txt: Remove.  Its contents are now in a
18846         comment in lib/file-has-acl.c.
18847         * lib/acl-internal.c, lib/acl-internal.h: Move recent changes
18848         relating to acl_nfs4_nontrivial to lib/file-has-acl.c, so that
18849         there is no trouble linking programs that need only file_has_acl.
18850         * lib/file-has-acl.c (acl_nfs4_nontrivial): Move here from
18851         lib/acl-internal.c, so that we needn't link -lacl in
18852         programs that want only file_has_acl, such as emacsclient.
18853         Do not assume a char buffer is aligned for uint32_t.
18854         Check more carefully for buffer read overrun.
18855         Allow up to 6 ACEs, since other code does; but check
18856         that they’re distinct.  Avoid integer overflow.
18857         Use memcmp rather than strncmp to compare memory blocks.
18858         (file_has_acl): Preserve initial errno instead of setting to 0.
18859         Allocate a bit more room for trivial ACL buffer.
18860         Use EINVAL for botchedk NFSv4 ACLs (which shouldn’t happen).
18862 2022-12-22  Paul Eggert  <eggert@cs.ucla.edu>
18864         posix_spawnp-tests: fix filename typo
18865         Problem reported for GNU m4 by Mitchell Dorrell in:
18866         https://lists.gnu.org/r/bug-m4/2022-12/msg00000.html
18867         * tests/test-posix_spawnp-script.c (DATA_FILENAME):
18868         Fix typo in file name that caused race with
18869         test-posix_spawn-script.c.
18871 2022-12-22  Ondrej Valousek  <ondrej.valousek.xm@renesas.com>
18873         file-has-acl: Basic support for checking NFSv4 ACLs in Linux.
18874         * lib/acl-internal.h (acl_nfs4_nontrivial): New declaration.
18875         * lib/acl-internal.c (acl_nfs4_nontrivial): New function.
18876         * lib/file-has-acl.c: Include <arpa/inet.h>.
18877         (XATTR_NAME_NFSV4_ACL, TRIVIAL_NFS4_ACL_MAX_LENGTH): New macros.
18878         (file_has_acl): Test for NFSv4 ACLs.
18879         * doc/acl-nfsv4.txt: New file.
18881 2022-12-21  Paul Eggert  <eggert@cs.ucla.edu>
18883         Port __has_c_attribute to strict C23
18884         * m4/gnulib-common.m4 (_GL_HAS_C_ATTRIBUTE): Remove, as C23 says
18885         behavior is undefined if __has_c_attribute appears anywhere other
18886         than at the top level of an #if or #ifdef.  All uses replaced by
18887         wordier invocations of __has_c_attribute.
18889         asctime, ctime: deprecate
18890         C23 deprecates asctime and ctime, so deprecate them in Gnulib too.
18891         * NEWS, doc/posix-functions/asctime.texi:
18892         * doc/posix-functions/ctime.texi: Mention this.
18893         * lib/time.in.h (ctime): Deprecate any ctime replacement.
18894         * modules/ctime: Now obsolete.
18896 2022-12-17  Paul Eggert  <eggert@cs.ucla.edu>
18898         memset_explicit: port to older MS-Windows
18899         * lib/memset_explicit.c (memset_explicit):
18900         Remove special case for C==0 and MS-Windows.  The code isn’t
18901         needed for correctness and it’s more trouble than it’s worth as it
18902         prevents this module from being used with GNU Emacs, which wants
18903         to port to MS-Windows versions so old that they lack
18904         SecureZeroMemory.
18906 2022-12-09  Bruno Haible  <bruno@clisp.org>
18908         Update users.txt.
18909         * users.txt: Add lbzip2.
18911 2022-12-09  Paul Eggert  <eggert@cs.ucla.edu>
18913         fts: make debug version compilable again
18914         This fixes things in what I hope is a better way than the
18915         fd-only approach proposed by Kamil Dudka here:
18916         https://lists.gnu.org/archive/html/bug-gnulib/2018-03/msg00079.html
18917         https://lists.gnu.org/archive/html/bug-gnulib/2018-03/msg00080.html
18918         * lib/fts.c (GNULIB_FTS_DEBUG): Rename from FTS_DEBUG,
18919         to avoid collision with coreutils symbol.
18920         Do not include <stdint.h> (not needed, since we include <stdint.h>)
18921         or "getcwdat.h" (no longer exists).
18922         (fd_ring_check, fd_ring_print): Add forward decls.
18923         (struct devino): New type.
18924         (PRINT_DEVINO): New macro.
18925         (getdevino): New static function.
18926         (fd_ring_print): Do nothing if not debugging.
18927         (fd_ring_print, fd_ring_check): Use getdevino instead of getcwdat.
18928         The output isn’t as good, but at least it compiles and runs.
18930 2022-12-07  Paul Eggert  <eggert@cs.ucla.edu>
18932         verify: update __STDC_VERSION__ as per C23
18933         This shouldn’t affect anything; it’s merely a refactoring.
18934         * lib/verify.h (_GL_HAVE__STATIC_ASSERT1): Require
18935         __STDC_VERSION__ to be at least 202311, instead of at least
18936         202000.  The latter number was put in in 2019 because we didn’t
18937         yet know C23’s __STDC_VERSION__ value.
18939 2022-12-06  Paul Eggert  <eggert@cs.ucla.edu>
18941         fts: fix race + mishandling of fstatat failure
18942         I hope this fixes a Luke Dashjr coreutils bug report about ext4
18943         ramdisks; see “9.1: du Aborted (corrupt filesystem)”
18944         <https://debbugs.gnu.org/59821>.
18945         * lib/fts.c (fts_build): Fix two bugs.  First, fts_stat was being
18946         called without checking its return value, causing a later abort.
18947         Second, there was a race between opening a directory and statting
18948         it, fixed by using fstat on the file descriptor rather than
18949         fstatat on the directory name.
18951         fts: omit goto break_without_closedir
18952         * lib/fts.c (fts_build): Refactor to omit goto.
18954         fts: clarify ISSET
18955         * lib/fts.c (ISSET): Refactor to clarify boolean usage.
18957 2022-12-05  Bruno Haible  <bruno@clisp.org>
18959         argp: Correct documentation.
18960         Reported by José E. Marchesi <jemarch@gnu.org>.
18961         * doc/glibc-functions/argp_*.texi: Mention the 'argp' module.
18963 2022-12-02  Pádraig Brady  <P@draigBrady.com>
18965         doc: poll: document poll of special files not supported on macOS
18966         * doc/posix-functions/poll.texi: Reinstate (updated) macOS info,
18967         removed in recent cleanup re removal of support for Mac OS X <= 10.4.
18968         * m4/poll.m4: Update macOS to latest tested version.
18970 2022-11-29  Pádraig Brady  <P@draigBrady.com>
18972         add new ronna and quetta SI prefixes
18973         As voted for in Nov 2022 by the BIPM:
18974         https://www.bipm.org/en/cgpm-2022/resolution-3
18976         * lib/human.c: Add Ronna (10^27), and Quetta (10^30) to the prefix list.
18977         * lib/xstrtol.c (__xstrtol): Likewise.
18979 2022-11-29  Bruno Haible  <bruno@clisp.org>
18981         Update users.txt.
18982         * users.txt: Add 4ti2, ale, amanda, binfmt-support, cgminer, collectd,
18983         complexity, dc3dd, dico, enchant-2, fuse-overlayfs, gsequencer, idutils,
18984         libu2f-host, licenseutils, mmv, pacemaker, trader, ttfautohint.
18986 2022-11-27  Paul Eggert  <eggert@cs.ucla.edu>
18988         explicit_bzero: implement via memset_explicit
18989         * lib/explicit_bzero.c (explicit_bzero):
18990         Simplify by just calling memset_explicit.
18991         * m4/explicit_bzero.m4 (gl_PREREQ_EXPLICIT_BZERO): Remove.
18992         All uses removed.
18993         * modules/explicit_bzero (Depends-on): Add memset_explicit.
18995         explicit_bzero: memset_explicit is standard
18996         * doc/glibc-functions/explicit_bzero.texi:
18997         Say that memset_explicit is preferred in new code.
18999         read-file: use memset_explicit
19000         * lib/read-file.c (fread_file, read_file):
19001         Use memset_explicit instead of explicit_bzero.
19002         * modules/read-file (Depends-on): Depend on memset_explicit
19003         instead of on explicit_bzero.
19005         memset_explicit: new module
19006         * doc/posix-functions/memset_explicit.texi, lib/memset_explicit.c:
19007         * m4/memset_explicit.m4, modules/memset_explicit:
19008         * modules/memset_explicit-tests, tests/test-memset_explicit.c:
19009         New files.
19010         * lib/string.in.h (memset_explict): New decl.
19011         * m4/string_h.m4 (gl_STRING_H, gl_STRING_H_REQUIRE_DEFAULTS)
19012         (gl_STRING_H_DEFAULTS):
19013         * modules/string (string.h):
19014         Support memset_explicit.
19016         explicit_bzero: add poison
19017         * m4/string_h.m4 (gl_STRING_H): Poison explicit_bzero.
19018         This was inadvertently omitted when explicit_bzero was added.
19020 2022-11-27  Arsen Arsenović  <arsen@aarsen.me>
19022         bootstrap: Fix --help output.
19023         * build-aux/bootstrap (usage): Regenerate.
19025 2022-11-27  Paul Eggert  <eggert@cs.ucla.edu>
19027         explicit_bzero: work with gcc -std=c99
19028         * lib/explicit_bzero.c (explicit_bzero) [__GNUC__ && !__clang__]:
19029         Use __asm__ instead of asm.
19031 2022-11-26  Paul Eggert  <eggert@cs.ucla.edu>
19033         Prefer "kill -INT" to killing with a number
19034         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
19035         * tests/test-login_tty.c (main):
19036         * tests/test-pthread_sigmask1.c (main):
19037         * tests/test-sigprocmask.c (main):
19038         Prefer "kill -INT" to "kill -N" where N is SIGINT’s value.
19039         Don’t assume pid_t fits in int.
19041 2022-11-25  Bruno Haible  <bruno@clisp.org>
19043         In 'trap' commands, prefer symbolic to numeric signal names.
19044         Reported by Mike Fulton <fultonm@ca.ibm.com> in
19045         <https://lists.gnu.org/archive/html/bug-gnulib/2022-11/msg00130.html>.
19046         * gnulib-tool: Use symbolic signal names.
19047         * posix-modules: Likewise.
19048         * MODULES.html.sh: Likewise.
19049         * build-aux/bootstrap (prepare_GNULIB_SRCDIR): Likewise.
19050         * build-aux/csharpcomp.sh.in: Likewise.
19051         * build-aux/gnu-web-doc-update: Likewise.
19052         * top/autogen.sh: Likewise.
19053         * top/bootstrap-funclib.sh: Likewise.
19054         * top/gitsub.sh: Likewise.
19055         * lib/t-idcache: Likewise.
19056         * tests/havelib/rpath-1: Likewise.
19057         * tests/havelib/rpath-2_a: Likewise.
19058         * tests/havelib/rpath-2_b: Likewise.
19059         * tests/havelib/rpath-3_a: Likewise.
19060         * tests/havelib/rpath-3_b: Likewise.
19061         * tests/init.sh: Likewise.
19062         * tests/test-binary-io.sh: Likewise.
19063         * tests/test-c-stack.sh: Likewise.
19064         * tests/test-c-stack2.sh: Likewise.
19065         * tests/test-dprintf-posix.sh: Likewise.
19066         * tests/test-fpending.sh: Likewise.
19067         * tests/test-fprintf-posix.sh: Likewise.
19068         * tests/test-lseek.sh: Likewise.
19069         * tests/test-printf-posix.sh: Likewise.
19070         * tests/test-select-in.sh: Likewise.
19071         * tests/test-select-out.sh: Likewise.
19072         * tests/test-sigpipe.sh: Likewise.
19073         * tests/test-tsearch.sh: Likewise.
19074         * tests/test-update-copyright.sh: Likewise.
19075         * tests/test-vdprintf-posix.sh: Likewise.
19076         * tests/test-vfprintf-posix.sh: Likewise.
19077         * tests/test-vprintf-posix.sh: Likewise.
19078         * tests/test-xprintf-posix.sh: Likewise.
19079         * tests/uniwidth/test-uc_width2.sh: Likewise.
19081 2022-11-20  Bruno Haible  <bruno@clisp.org>
19083         posix_spawn-internal: Avoid warning on macOS.
19084         Suggested by Minsoo Choo in
19085         <https://lists.gnu.org/archive/html/bug-gnulib/2022-11/msg00114.html>.
19086         * lib/spawni.c: Ignore -Wdeprecated-declarations warnings.
19088 2022-11-20  Bruno Haible  <bruno@clisp.org>
19090         posix_spawn tests: Fix compilation error (regression 2022-09-14).
19091         * modules/posix_spawn-tests (Makefile.am): Augment DEFS, to define
19092         EXEEXT.
19094 2022-11-14  Paul Eggert  <eggert@cs.ucla.edu>
19096         parse-datetime: improve doc formatting, timeliness
19097         * doc/parse-datetime.texi: Use @samp and @code in menus
19098         for consistenty with how the Coreutils manual will do
19099         this sort of thing.  Update examples to this year.
19101 2022-11-13  Simon Josefsson  <simon@josefsson.org>
19103         vc-list-files-tests: Avoid OpenPGP private key operations.
19104         * tests/test-vc-list-files-git.sh (GIT_CONFIG_GLOBAL): Set it to
19105         /dev/null.
19107 2022-11-03  Bruno Haible  <bruno@clisp.org>
19109         dynarray: Rename to glibc-internal/dynarray.
19110         * modules/glibc-internal/dynarray: Renamed from modules/dynarray.
19111         * modules/glibc-internal/dynarray-tests: Renamed from
19112         modules/dynarray-tests.
19113         * modules/regex (Depends-on): Update.
19114         * NEWS: Mention this change and the previous one.
19116 2022-11-03  Bruno Haible  <bruno@clisp.org>
19118         scratch_buffer: Rename to glibc-internal/scratch_buffer.
19119         * modules/glibc-internal/scratch_buffer: Renamed from
19120         modules/scratch_buffer.
19121         * modules/glibc-internal/scratch_buffer-tests: Renamed from
19122         modules/scratch_buffer-tests.
19123         * modules/canonicalize (Depends-on): Update.
19124         * modules/canonicalize-lgpl (Depends-on): Likewise.
19125         * modules/glob (Depends-on): Likewise.
19127 2022-11-02  Bruno Haible  <bruno@clisp.org>
19129         scratch_buffer: Document last change.
19130         * NEWS: Mention last change.
19132 2022-11-02  Paul Eggert  <eggert@cs.ucla.edu>
19134         scratch_buffer: adjust to glibc changes
19135         Problem reported by Karl Berry in:
19136         https://lists.gnu.org/r/bug-gnulib/2022-11/msg00004.html
19137         * build-aux/depcomp, doc/make-stds.texi, lib/malloc/scratch_buffer.h:
19138         Autoupdate.
19139         * build-aux/install-reloc (func_create_wrapper):
19140         Omit removed file scratch_buffer_dupfree.c.
19141         * config/srclist.txt: Remove lib/malloc/scratch_buffer_dupfree.c
19142         * lib/canonicalize-lgpl.c: Merge changes from glibc through its
19143         commit ef0700004bf0dccf493a5e8e21f71d9e7972ea9f dated 2022-07-05
19144         11:04:45 +0200.
19145         (__strdup) [!_LIBC]: New macro.
19146         (struct realpath_bufs): New type.
19147         (realpath_stk): Use it as the extra argument.  All uses changed.
19148         No longer any need for noinline or GCC_BOGUS_WRETURN_LOCAL_ADDR.
19149         * lib/canonicalize.c (struct realpath_bufs)
19150         (canonicalize_filename_mode_stk): Likewise.
19151         * lib/malloc/scratch_buffer_dupfree.c:
19152         Remove, since it was removed in glibc.
19153         * lib/scratch_buffer.h (scratch_buffer_dupfree) [0]:
19154         (__libc_scratch_buffer_dupfree): Remove decls.
19155         * modules/relocatable-prog-wrapper (Files):
19156         * modules/scratch_buffer (Files, lib_SOURCES):
19157         Remove lib/malloc/scratch_buffer_dupfree.c.
19159 2022-11-01  Bruno Haible  <bruno@clisp.org>
19161         relocatable-script: Relax license.
19162         * modules/relocatable-script (License): Change to GPLv2+.
19163         * build-aux/relocatable.sh.in: Change copyright header to GPLv2+.
19165 2022-10-31  Simon Josefsson  <simon@josefsson.org>
19167         maintainer-makefile: Fix Apple Xcode 'make syntax-check'.
19168         * top/maint.mk (sc_indent): Don't use non-GNU indent.
19170 2022-10-30  Paul Eggert  <eggert@cs.ucla.edu>
19172         thread: pacify gcc -Wbad-function-cast
19173         * lib/glthread/thread.h (gl_thread_self_pointer): With POSIX
19174         threads, cast the call to gl_thread_t before casting to void *.
19176         test-getlogin: pacify gcc -Wshadow
19177         * tests/test-getlogin.h (test_getlogin_result): Rename local.
19179 2022-10-25  Simon Josefsson  <simon@josefsson.org>
19181         gendocs: Output timestamp in English.
19182         * build-aux/gendocs.sh (SETLANG): Add LC_TIME= for "date".
19184 2022-10-23  Bruno Haible  <bruno@clisp.org>
19186         assert-h: Make static_assert work on Solaris 11.4.
19187         * m4/assert_h.m4 (gl_ASSERT_H): After including <assert.h>, on Solaris,
19188         redefine static_assert.
19190 2022-10-16  Bruno Haible  <bruno@clisp.org>
19192         getdelim: Work around buggy implementation on macOS 10.13.
19193         * doc/posix-functions/getdelim.texi: Mention the macOS bug.
19194         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Let the "checking for working
19195         getdelim function" test answer 'no' on macOS.
19197 2022-10-15  Bruno Haible  <bruno@clisp.org>
19199         Update to Unicode 15.0.0.
19201         * lib/gen-uni-tables.c (is_property_default_ignorable_code_point):
19202         Exclude 0x13439..0x1343F.
19203         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
19205         * All generated files under lib/uni* and tests/uni*: Regenerate.
19206         * tests/uniname/NameAliases.txt: Update.
19207         * tests/uniname/UnicodeData.txt: Update.
19208         * tests/uninorm/NormalizationTest.txt: Update.
19209         * tests/unigbrk/GraphemeBreakTest.txt: Update.
19210         * tests/uniwbrk/WordBreakTest.txt: Update.
19212         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
19213         0x0ECE, 0x10EFD..0x10EFF, 0x11241, 0x11F00..0x11F01, 0x11F36..0x11F3A,
19214         0x11F40, 0x11F42, 0x13439..0x13440, 0x13447..0x13455, 0x1E08F,
19215         0x1E4EC..0x1E4EF.
19217         * All the affected modules: Bump required libunistring version.
19219 2022-10-15  Bruno Haible  <bruno@clisp.org>
19221         gen-uni-tables: Temporarily revert last change.
19222         * lib/gen-uni-tables.c: Include <stdbool.h>, unless the C compiler
19223         advertises compliance to ISO C 23.
19225 2022-10-12  Paul Eggert  <eggert@cs.ucla.edu>
19227         doc: improve intprops doc
19228         * doc/intprops.texi: Tighten up wording, by saying that macros
19229         "yield 1 if X, 0 otherwise" rather than the weaker "yield 1 if X".
19230         Say "yield" rather than "return" since the macros are not
19231         functions.  Say "1" and "0" rather than "true" and "false" since
19232         the macros yield int.  Say that stdckdint.h is the standard
19233         alternative to the _WRAPV macros.  Mention another source of
19234         problems with the _OVERFLOW macros.
19236 2022-10-10  Paul Eggert  <eggert@cs.ucla.edu>
19238         tests: prefer stdckdint to intprops
19239         * modules/chown-tests, modules/fchownat-tests:
19240         * modules/fdutimensat-tests, modules/futimens-tests:
19241         * modules/lchown-tests, modules/stat-time-tests:
19242         * modules/utime-tests, modules/utimens-tests:
19243         * modules/utimensat-tests:
19244         (Depends on): Depend on stdckint, not intprops.
19245         * tests/nap.h: Include stdckdint.h, not intprops.h.
19246         All macro uses changed.
19248         stat-time: prefer stdckdint to intprops
19249         * lib/stat-time.h: Include stdckdint.h instead of intprops.h.
19250         (stat_time_normalize): Use ckd_add instead of INT_ADD_WRAPV.
19251         * modules/stat-time (Depends-on): Depend on stdckdint, not intprops.
19253         xalloc: remove stray includes + dependencies
19254         These used to be needed, but are not needed now.
19255         * lib/xalloc.h: Do not include stdlib.h.
19256         [GNULIB_XALLOC]: Do not include "intprops.h".
19257         * lib/xmalloc.c: Include stdint.h here instead, for SIZE_MAX.
19258         * modules/xalloc-die, modules/xvasprintf (Depends-on): Remove stdint.
19260 2022-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19262         assert-h: suppress Apple clang 13 false alarms
19263         * m4/assert_h.m4 (gl_ASSERT_H): Suppress bogus warnings from Apple
19264         clang 13 (clang-1300.0.29.30).  Problem privately reported by
19265         Mattias Engdegård for GNU Emacs.
19267 2022-09-26  Daiki Ueno  <ueno@gnu.org>
19269         largefile: fix detection of time_t size on mingw32
19270         * modules/largefile (configure.ac-early): Ensure gl_YEAR2038_EARLY
19271         is invoked before gl_YEAR2038_BODY.
19273 2022-09-25  Paul Eggert  <eggert@cs.ucla.edu>
19275         fts: fix errno handling if dirfd fails
19276         * lib/fts.c (fts_build): Use proper errno if dirfd failed.
19277         Although I don’t know of any platform where dirfd can fail here,
19278         we might as well get it right.
19280 2022-09-25  Bruno Haible  <bruno@clisp.org>
19282         stdbool: Mostly revert last patch.
19283         * m4/c-bool.m4 (gl_C_BOOL): If stdbool.h does not exist, just err out.
19284         * modules/stdbool (Files): Remove m4/stdbool.m4.
19286 2022-09-24  Bruno Haible  <bruno@clisp.org>
19288         stdbool: Don't #include a gnulib-generated stdbool.h from config.h.
19289         * m4/c-bool.m4 (gl_C_BOOL): Check for stdbool.h and for _Bool. If
19290         stdbool.h does not exist, don't #include <stdbool.h> but instead put the
19291         substitute code into config.h.
19292         * modules/stdbool (Files): Add m4/stdbool.m4.
19294 2022-09-24  Bruno Haible  <bruno@clisp.org>
19296         stdalign: Don't #include a gnulib-generated stdalign.h from config.h.
19297         * m4/stdalign.m4 (gl_STDALIGN_H): Check for stdalign.h. If it does not
19298         exist, don't #include <stdalign.h> but instead put the substitute code
19299         into config.h.
19301 2022-09-24  Bruno Haible  <bruno@clisp.org>
19303         stdalign: Fix compilation error with MSVC in C++ mode.
19304         * lib/stdalign.in.h: Treat MSVC in C++ mode like C++11 compliant
19305         compilers.
19306         * tests/test-stdalign-c++.cc: Include some other header files.
19308         stdalign: Avoid namespace pollution.
19309         * lib/stdalign.in.h (_GL_STDALIGN_NEEDS_STDDEF): New macro.
19310         Include <stddef.h> only when needed.
19312 2022-09-23  Simon Josefsson  <simon@josefsson.org>
19314         warnings, manywarnings: Doc fixes.
19315         * doc/manywarnings.texi (manywarnings): Improve usage instruction.
19316         Start list of comments on particular warning flags, based on
19317         comment from Paul Eggert <eggert@cs.ucla.edu>.
19318         * doc/warnings.texi (warnings): Mention that it is often used with manywarnings.
19320 2022-09-21  Paul Eggert  <eggert@cs.ucla.edu>
19322         assert-h: suppress clang false alarms
19323         Suppress scads of annoying warnings from clang version 14.0.5
19324         (Fedora 14.0.5-1.fc36) of the form "warning: '_Static_assert' with
19325         no message is a C2x extension [-Wc2x-extensions]",
19326         by refusing to use single-arg static_assert with older clang.
19327         * m4/assert_h.m4 (gl_ASSERT_H): Turn -Wc2x-extensions from a
19328         warning into an error when testing static_assert, so that the
19329         annoying diagnostic causes the test to fail, which causes assert.h
19330         to be replaced in a way that suppresses the diagnostic during
19331         the real build.
19333 2022-09-20  Bruno Haible  <bruno@clisp.org>
19335         Add another helper script for creating testdirs.
19336         * all-modules: New file, based on posix-modules.
19338 2022-09-20  Bruno Haible  <bruno@clisp.org>
19340         snippet/warn-on-use: Don't cause wrong AC_CHECK_DECL results with clang.
19341         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Use the clang command-line
19342         option that disables implicit built-in function declarations in clang.
19344 2022-09-19  Bruno Haible  <bruno@clisp.org>
19346         stdbool, stdbool-c99 tests: Fix compilation error with clang/MSVC.
19347         * tests/test-stdbool.c (WORKING_BOOL): Define to 0 on compilers that
19348         define _MSC_VER.
19350 2022-09-18  Paul Eggert  <eggert@cs.ucla.edu>
19352         stdbool: omit ‘#undef true’
19353         This is mostly just simplification.
19354         * m4/c-bool.m4 (gl_C_BOOL): Test all preprocessors when
19355         !HAVE_C_BOOL, not merely __SUNPRO_CC.  Use the slightly
19356         more-elegant ‘!true’ instead of ‘true == 1’; this shouldn’t matter
19357         in practice and if it does matter we want to know about it anyway.
19358         Remove an unnecessary ‘#undef true’ that is simply commented out
19359         by ‘configure’; again, if true is already #defined to be 0 the
19360         system is so messed up we want to know about it anyway.
19362 2022-09-18  Bruno Haible  <bruno@clisp.org>
19364         stdbool: Ensure that 'true' can be used in the preprocessor.
19365         * m4/c-bool.m4 (gl_C_BOOL): With Sun C++, redefine 'true' if it does not
19366         evaluate to 1 in the preprocessor.
19368         stdbool-c99: Ensure that 'true' can be used in the preprocessor.
19369         * lib/stdbool.in.h (true): Redefine if it does not evaluate to 1 in the
19370         preprocessor.
19372 2022-09-18  Bruno Haible  <bruno@clisp.org>
19374         uni{case,ctype,gbrk,str}/base: Fix installed .h file (regr. 2022-09-10).
19375         * lib/unicase.in.h: Do include <stdbool.h>.
19376         * lib/unictype.in.h: Likewise.
19377         * lib/unigbrk.in.h: Likewise.
19378         * lib/unistr.in.h: Likewise.
19380 2022-09-18  Bruno Haible  <bruno@clisp.org>
19382         signal: Fix a C++ compilation error due to sched_yield on OpenBSD 6.0.
19383         * lib/signal.in.h: On OpenBSD, include <sys/param.h>. Don't include
19384         <pthread.h> on OpenBSD ≥ 5.1.
19386 2022-09-17  Paul Eggert  <eggert@cs.ucla.edu>
19388         explicit_bzero-tests: robustify a bit
19389         This is mostly to suppress GCC warnings, though I suppose it
19390         might also improve the test.
19391         * tests/test-explicit_bzero.c: Do not ignore -Wmaybe-uninitialized,
19392         as this warning should no longer be generated given the other changes.
19393         (test_heap): ASSERT that malloc succeeds, to suppress any GCC
19394         warning about relying on malloc succeeding.  Declare addr to be
19395         volatile, so that GCC does not deduce that it is heapbuf in
19396         disguise and diagnose using it after freeing it.
19397         (do_secret_stuff): Declare more things to be volatile, to avoid
19398         optimizations that might disturb the stack and/or mess up the test
19399         in other ways.  Pass last_stackbuf address as a parameter rather
19400         than having last_stackbuf be static, to avoid GCC warning about
19401         assigning address of a local to a static; all callers changed.
19403 2022-09-17  Bruno Haible  <bruno@clisp.org>
19405         wchar: Fix compilation errors in C++ mode on Solaris 11.3.
19406         * lib/wchar.in.h (wcsnlen, wcpcpy, wcpncpy, wcscasecmp, wcsncasecmp,
19407         wcsdup): Force declaration in C++ mode on Solaris (which does not
19408         declare these functions in the global namespace).
19410 2022-09-17  Bruno Haible  <bruno@clisp.org>
19412         swab: Fix compilation error with Sun C++ on Solaris 11.3.
19413         * lib/unistd.in.h (swab): For the C++ declaration, under Solaris 11 but
19414         not under Solaris 10, test also __XOPEN_OR_POSIX.
19416 2022-09-17  Bruno Haible  <bruno@clisp.org>
19418         time C++ tests: Fix link error on CentOS 5.
19419         * modules/time-c++-tests (Makefile.am): Link test-time-c++ against
19420         $(LIB_CLOCK_GETTIME).
19422 2022-09-14  Bruno Haible  <bruno@clisp.org>
19424         time: Fix compilation errors with clang/MSVC.
19425         * m4/time_h.m4 (gl_TIME_H): Test whether asctime_r and ctime_r are
19426         declared.
19427         * lib/time.in.h (asctime_r, ctime_r): Skip _GL_WARN_ON_USE invocations
19428         when these functions are not declared.
19430 2022-09-14  Bruno Haible  <bruno@clisp.org>
19432         verify: Avoid syntax error due to static_assert with clang in C++ mode.
19433         * lib/verify.h (static_assert): Don't define in clang C++ 6 or newer.
19434         * m4/assert_h.m4 (gl_ASSERT_H): If we don't need to define static_assert
19435         with clang in C++ mode, don't include <assert.h>.
19437 2022-09-14  Paul Eggert  <eggert@cs.ucla.edu>
19439         assert-h: work around include confusion
19440         * m4/assert_h.m4 (gl_ASSERT_H): Arrange for <config.h> to not
19441         include <assert.h> if assert is already defined.  This works
19442         around bugs in packages that mistakenly include <config.h> after
19443         including <assert.h> (typically due to double-inclusion of
19444         <config.h>).  Found in coreutils, which I plan to fix.
19446         stdbool: depend on C99
19447         Record that stdbool depends on C99 these days.
19448         This matters only for ancient compilers that need special
19449         flags to support C99 features.
19450         * modules/stdbool (Depends-on): Add c99.
19452 2022-09-14  Bruno Haible  <bruno@clisp.org>
19454         verify: Avoid syntax error due to static_assert with MSVC 14 in C++.
19455         * lib/verify.h (static_assert): For MSVC in C++ mode, use a definition
19456         that supports both the two-arguments and the one-argument syntax.
19458 2022-09-14  Bruno Haible  <bruno@clisp.org>
19460         posix_spawn-* tests: Fix test failure on mingw when libtool is in use.
19461         * tests/test-posix_spawn-inherit0.c (CHILD_PROGRAM_FILENAME): Add the
19462         EXEEXT suffix.
19463         * tests/test-posix_spawn-inherit1.c (CHILD_PROGRAM_FILENAME): Likewise.
19464         * tests/test-posix_spawn-open1.c (CHILD_PROGRAM_FILENAME): Likewise.
19465         * tests/test-posix_spawn-open2.c (CHILD_PROGRAM_FILENAME): Likewise.
19467 2022-09-14  Bruno Haible  <bruno@clisp.org>
19469         verify: Avoid syntax error due to static_assert with MSVC 14.
19470         * lib/verify.h (_Static_assert): Pass only the first argument to
19471         _GL_VERIFY.
19473 2022-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19475         verify: treat GNU C++ 6 like recent C++
19476         * m4/assert_h.m4 (gl_ASSERT_H):
19477         If we check __cpp_static_assert < 201411, also check __GNUG__ < 6,
19478         for consistency with the previous change.
19480 2022-09-13  Bruno Haible  <bruno@clisp.org>
19482         verify: Avoid syntax error due to static_assert with GNU C++ 6.x.
19483         * lib/verify.h (static_assert): Don't define in GNU C++ 6 or newer.
19485 2022-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19487         stdalign: prefer to not include <stdalign.h>
19488         * lib/alignalloc.c, lib/argp-parse.c, lib/fts.c, lib/md4.c, lib/md5.c:
19489         * lib/rawmemchr.c, lib/sha1.c, lib/sha256.c, lib/sha512.c, lib/sm3.c:
19490         * lib/sys_socket.in.h:
19491         In C23, <stdalign.h> is a no-op, so don’t include it.
19493         stdalign: alignas and alignof are C23 keywords
19494         * m4/stdalign.m4 (gl_STDALIGN_H): Check also whether
19495         alignas and alignof are keywords and so don’t need stdalign.h,
19496         and define HAVE_C_ALIGNASOF if so.
19497         If not, arrange for config.h to #define alignas and alignof
19498         by including <stdalign.h>.
19499         * modules/stdalign: No need to include <stdalign.h>.
19500         * tests/test-stdalign.c: Do not include stdalign.h.
19502         assert-h: prefer to ‘verify’
19503         Where it’s easy, prefer ‘static_assert’ to ‘verify’,
19504         as this simplifies the source by removing the need to
19505         include verify.h.  Keep using ‘verify’ if verify.h
19506         is used for other reasons, or if code is shared with glibc.
19507         * lib/alignalloc.c, lib/argmatch.h, lib/c32is-impl.h:
19508         * lib/c32snrtombs.c, lib/c32srtombs.c, lib/exclude.c:
19509         * lib/filevercmp.c, lib/fma.c, lib/i-ring.h, lib/ino-map.c:
19510         * lib/localeinfo.c, lib/malloca.c, lib/mbrtoc32.c, lib/mbrtowc.c:
19511         * lib/mbsinit.c, lib/mbsnrtoc32s.c, lib/mbsrtoc32s.c:
19512         * lib/nanosleep.c, lib/parse-datetime.y, lib/pipe2.c:
19513         * lib/rawmemchr.c, lib/relocwrapper.c, lib/sleep.c:
19514         * lib/stat-w32.c, lib/strerror.c, lib/strtoimax.c:
19515         * lib/utimecmp.c, lib/vasnprintf.c, tests/test-alignof.c:
19516         * tests/test-intprops.c, tests/test-libgmp.c:
19517         * tests/test-limits-h.c, tests/test-locale.c:
19518         * tests/test-pthread.c, tests/test-round2.c:
19519         * tests/test-stdalign.c, tests/test-stddef.c, tests/test-stdio.c:
19520         * tests/test-stdlib.c, tests/test-string.c, tests/test-sys_stat.c:
19521         * tests/test-time.c, tests/test-uchar.c, tests/test-unistd.c:
19522         * tests/test-wchar.c:
19523         Prefer static_assert to verify, and stop including verify.h.
19524         * lib/stat.c: Don’t include verify.h (this include was unnecessary).
19525         * modules/alignalloc, modules/alignof-tests, modules/argmatch:
19526         * modules/c-vasnprintf, modules/c32isalnum, modules/c32isalpha:
19527         * modules/c32isblank, modules/c32iscntrl, modules/c32isdigit:
19528         * modules/c32isgraph, modules/c32islower, modules/c32isprint:
19529         * modules/c32ispunct, modules/c32isspace, modules/c32isupper:
19530         * modules/c32isxdigit, modules/c32snrtombs, modules/c32srtombs:
19531         * modules/exclude, modules/filevercmp, modules/fma, modules/fmaf:
19532         * modules/fmal, modules/fstat, modules/i-ring, modules/ino-map:
19533         * modules/intprops-tests, modules/libgmp-tests:
19534         * modules/limits-h-tests, modules/locale-tests, modules/malloca:
19535         * modules/mbrtoc32, modules/mbrtowc, modules/mbsinit:
19536         * modules/mbsnrtoc32s, modules/mbsrtoc32s, modules/nanosleep:
19537         * modules/parse-datetime, modules/pipe2, modules/pthread-h-tests:
19538         * modules/rawmemchr, modules/relocatable-prog-wrapper:
19539         * modules/round-tests, modules/roundf-tests, modules/sleep:
19540         * modules/stat, modules/stdalign-tests, modules/stdckdint-tests:
19541         * modules/stddef-tests, modules/stdio-tests, modules/stdlib-tests:
19542         * modules/strerror, modules/string-tests, modules/strtoimax:
19543         * modules/strtoumax, modules/sys_stat-tests, modules/time-tests:
19544         * modules/uchar-tests, modules/unistd-tests:
19545         * modules/unistdio/u16-u16-vasnprintf:
19546         * modules/unistdio/u16-vasnprintf:
19547         * modules/unistdio/u32-u32-vasnprintf:
19548         * modules/unistdio/u32-vasnprintf:
19549         * modules/unistdio/u8-u8-vasnprintf:
19550         * modules/unistdio/u8-vasnprintf, modules/unistdio/ulc-vasnprintf:
19551         * modules/utimecmp, modules/vasnprintf, modules/wchar-tests:
19552         Depend on assert-h, not verify.
19554         assert-h: static_assert is a keyword in C23
19555         * m4/assert_h.m4 (gl_ASSERT_H): Also test for static_assert
19556         keyword a la C23, and define HAVE_C_STATIC_ASSERT if so.
19557         If not, arrange for config.h to #define static_assert
19558         by including <assert.h>, and then do "#undef assert"
19559         so that the assert macro still needs an explicit include.
19560         This should be safe even on very old hosts, as assert.h
19561         has been re-includable for decades.
19562         * tests/tests-assert.c: New test.
19563         * modules/assert-h-tests (Files, Makefile.am): Add it.
19565 2022-09-13  Bruno Haible  <bruno@clisp.org>
19567         Prefer talking about alignas than _Alignas.
19568         * m4/gnulib-common.m4 (gl_COMMON_BODY): Don't mention _Alignas in a
19569         comment.
19570         * m4/stdalign.m4 (gl_STDALIGN_H): Likewise.
19572 2022-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19574         stdalign-tests: port to C23
19575         * tests/test-stdalign.c: Do not test __alignas_is_defined,
19576         _Alignof, or _Alignas as they are obsolescent.
19577         Do not use __alignas_is_defined in C23 or later (or C++11 or later),
19578         as it’s removed in C23.
19580 2022-09-12  Bruno Haible  <bruno@clisp.org>
19582         supersede: Avoid a failure when writing to /dev/null in Solaris zones.
19583         * lib/supersede.c (open_supersede): Treat EACCES (seen on Solaris 11.3)
19584         like EINVAL (seen on Illumos).
19586 2022-09-11  Paul Eggert  <eggert@cs.ucla.edu>
19588         maint: avoid unportable ERE \}
19589         * top/maint.mk (sc_copyright_check):
19590         Avoid unportable use of \} in ERE.
19592         verify: improve maint check
19593         * top/maint.mk (sc_prohibit_verify_without_use):
19594         Adjust re to match verify.h.
19596         verify: port better to C23
19597         * lib/verify.h (_GL_VERIFY, static_assert):
19598         If C23, use static_assert keyword; no macro.
19599         This should simplify diagnostics and debugging.
19601 2022-09-10  Bruno Haible  <bruno@clisp.org>
19603         pipe-filter-gi: Fix test failure on native Windows.
19604         * lib/pipe-filter-aux.h (write): Redefine on native Windows.
19606 2022-09-10  Bruno Haible  <bruno@clisp.org>
19608         stdbool C++ tests: Fix compilation error with MSVC14 (regr. from today).
19609         * tests/test-stdbool-c++.cc (s): Choose field names that are not type
19610         names.
19612         Reorganize C++ tests for stdbool and stdbool-c99.
19613         * tests/test-stdbool-c++.cc: Don't include <stdbool.h> if TEST_STDBOOL_H
19614         is not defined. Add a couple of simple tests, from test-stdbool.c.
19615         * tests/test-stdbool-c99-c++.cc: New file.
19616         * modules/stdbool-c99-c++-tests: New file, based on
19617         modules/stdbool-c++-tests.
19618         * modules/stdbool-c99-tests (Depends-on): Add stdbool-c99-c++-tests.
19619         Remove stdbool-c++-tests.
19620         * modules/stdbool-tests (Depends-on): Add stdbool-c++-tests.
19622 2022-09-10  Bruno Haible  <bruno@clisp.org>
19624         stdbool C++ tests: Fix for C++20.
19625         * tests/test-stdbool-c++2.cc: Don't include <cstdbool> in C++20 or
19626         newer.
19628 2022-09-10  Bruno Haible  <bruno@clisp.org>
19630         uchar: Work around error in C++ mode on AIX 7.2 with xlclang.
19631         * lib/uchar.in.h (char16_t, char32_t): On AIX with xlclang++, define
19632         these as macros.
19633         * doc/posix-headers/uchar.texi: Document the AIX + xlclang++ bug.
19635 2022-09-10  Paul Eggert  <eggert@cs.ucla.edu>
19637         Rely on new stdbool behavior
19638         Prefer the C23 style to the C99 style,
19639         since the stdbool module now supports C23.
19640         * lib/acl-internal.h, lib/acl.h, lib/argmatch.c, lib/argmatch.h:
19641         * lib/argp-help.c, lib/argv-iter.h, lib/asyncsafe-spin.c:
19642         * lib/backup-internal.h, lib/backupfile.c, lib/base32.h:
19643         * lib/base64.h, lib/basename-lgpl.c, lib/bitset/base.h:
19644         * lib/c-ctype.h, lib/c-strcasestr.c, lib/canonicalize-lgpl.c:
19645         * lib/canonicalize.c, lib/chdir-long.c, lib/chown.c:
19646         * lib/classpath.h, lib/clean-temp-private.h:
19647         * lib/clean-temp-simple.c, lib/clean-temp-simple.h:
19648         * lib/clean-temp.c, lib/clean-temp.h, lib/cloexec.h:
19649         * lib/close-stream.c, lib/closein.c, lib/closeout.c, lib/closeout.h:
19650         * lib/csharpcomp.h, lib/csharpexec.h, lib/cycle-check.c:
19651         * lib/cycle-check.h, lib/des.h, lib/dfa.h, lib/diffseq.h:
19652         * lib/dirname.h, lib/exclude.c, lib/exclude.h, lib/execute.c:
19653         * lib/execute.h, lib/execvpe.c, lib/fatal-signal.c, lib/fchdir.c:
19654         * lib/file-set.h, lib/filevercmp.c, lib/findprog-in.c:
19655         * lib/findprog.c, lib/findprog.h, lib/fma.c, lib/fnmatch.c:
19656         * lib/fopen.c, lib/freadable.h, lib/freading.h, lib/freopen-safer.c:
19657         * lib/fstrcmp.c, lib/fsusage.h, lib/fts.c, lib/fwritable.h:
19658         * lib/fwriteerror.c, lib/fwriting.h, lib/gen-uni-tables.c:
19659         * lib/getaddrinfo.c, lib/getcwd.c, lib/getloadavg.c:
19660         * lib/getndelim2.c, lib/getpass.c, lib/getrandom.c:
19661         * lib/git-merge-changelog.c, lib/gl_list.h, lib/gl_map.h:
19662         * lib/gl_omap.h, lib/gl_oset.h, lib/gl_set.h, lib/glob.c:
19663         * lib/glthread/cond.h, lib/hamt.h, lib/hard-locale.h:
19664         * lib/hash-triple.h, lib/hash.h, lib/human.h, lib/i-ring.h:
19665         * lib/isapipe.c, lib/javacomp.h, lib/javaexec.h, lib/javaversion.c:
19666         * lib/lchown.c, lib/localeinfo.h, lib/localename.c:
19667         * lib/long-options.h, lib/malloc/dynarray.h, lib/mbchar.h:
19668         * lib/mbfile.h, lib/mbiter.h, lib/mbmemcasecoll.h, lib/mbscasestr.c:
19669         * lib/mbsstr.c, lib/mbuiter.h, lib/mkdir-p.h, lib/modechange.h:
19670         * lib/mountlist.h, lib/nanosleep.c, lib/nonblocking.h:
19671         * lib/nstrftime.c, lib/openat.c, lib/openat.h, lib/os2-spawn.c:
19672         * lib/parse-datetime.h, lib/pipe-filter-aux.c, lib/pipe-filter-gi.c:
19673         * lib/pipe-filter-ii.c, lib/pipe-filter.h, lib/posixtm.h:
19674         * lib/priv-set.c, lib/progreloc.c, lib/propername.c:
19675         * lib/pthread-spin.c, lib/quotearg.c, lib/readtokens.c:
19676         * lib/readtokens0.h, lib/readutmp.c, lib/regex-quote.h:
19677         * lib/regex_internal.h, lib/relocwrapper.c, lib/rename.c:
19678         * lib/renameatu.c, lib/rpmatch.c, lib/same.c, lib/same.h:
19679         * lib/save-cwd.c, lib/savewd.c, lib/savewd.h, lib/spawn-pipe.h:
19680         * lib/spawni.c, lib/stack.h, lib/stat.c, lib/stdckdint.in.h:
19681         * lib/strcasestr.c, lib/strfmon_l.c, lib/striconveh.c:
19682         * lib/striconveha.h, lib/string-buffer.h, lib/strptime.c:
19683         * lib/strstr.c, lib/strtod.c, lib/supersede.h, lib/system-quote.c:
19684         * lib/tempname.c, lib/term-style-control.c:
19685         * lib/term-style-control.h, lib/textstyle.in.h, lib/time_rz.c:
19686         * lib/tmpdir.c, lib/tmpdir.h, lib/tmpfile.c, lib/unicase.in.h:
19687         * lib/unicase/caseprop.h, lib/unicase/invariant.h:
19688         * lib/unicase/u16-casemap.c, lib/unicase/u16-ct-totitle.c:
19689         * lib/unicase/u16-is-invariant.c, lib/unicase/u32-casemap.c:
19690         * lib/unicase/u32-ct-totitle.c, lib/unicase/u32-is-invariant.c:
19691         * lib/unicase/u8-casemap.c, lib/unicase/u8-ct-totitle.c:
19692         * lib/unicase/u8-is-invariant.c, lib/unictype.in.h:
19693         * lib/unigbrk.in.h, lib/unigbrk/u16-grapheme-breaks.c:
19694         * lib/unigbrk/u32-grapheme-breaks.c:
19695         * lib/unigbrk/u8-grapheme-breaks.c:
19696         * lib/unigbrk/uc-grapheme-breaks.c, lib/uniname/uniname.c:
19697         * lib/unistr.in.h, lib/unlinkdir.h, lib/userspec.h, lib/utime.c:
19698         * lib/utimecmp.c, lib/utimens.c, lib/wait-process.h:
19699         * lib/windows-cond.c, lib/windows-spawn.c, lib/windows-spawn.h:
19700         * lib/windows-timedrwlock.c, lib/write-any-file.h, lib/xbinary-io.c:
19701         * lib/xstrtod.h, lib/yesno.h:
19702         * tests/nap.h, tests/qemu.h, tests/test-areadlink-with-size.c:
19703         * tests/test-areadlink.c, tests/test-areadlinkat-with-size.c:
19704         * tests/test-areadlinkat.c, tests/test-base32.c:
19705         * tests/test-base64.c, tests/test-ceil2.c, tests/test-ceilf2.c:
19706         * tests/test-chown.c, tests/test-dirname.c, tests/test-dup-safer.c:
19707         * tests/test-dup3.c, tests/test-exclude.c:
19708         * tests/test-execute-child.c, tests/test-execute-main.c:
19709         * tests/test-execute-script.c, tests/test-explicit_bzero.c:
19710         * tests/test-fchownat.c, tests/test-fcntl-safer.c:
19711         * tests/test-fcntl.c, tests/test-fdutimensat.c:
19712         * tests/test-filenamecat.c, tests/test-floor2.c:
19713         * tests/test-floorf2.c, tests/test-fstatat.c, tests/test-fstrcmp.c:
19714         * tests/test-futimens.c, tests/test-getlogin.h, tests/test-getopt.h:
19715         * tests/test-hard-locale.c, tests/test-hash.c:
19716         * tests/test-idpriv-drop.c, tests/test-idpriv-droptemp.c:
19717         * tests/test-immutable.c, tests/test-intprops.c:
19718         * tests/test-lchown.c, tests/test-link.c, tests/test-linkat.c:
19719         * tests/test-lstat.c, tests/test-mbmemcasecmp.c:
19720         * tests/test-mbmemcasecoll.c, tests/test-mkdir.c:
19721         * tests/test-mkdirat.c, tests/test-mkfifo.c, tests/test-mkfifoat.c:
19722         * tests/test-mknod.c, tests/test-nonblocking-pipe-child.c:
19723         * tests/test-nonblocking-pipe-main.c:
19724         * tests/test-nonblocking-socket-child.c:
19725         * tests/test-nonblocking-socket-main.c, tests/test-open.c:
19726         * tests/test-openat.c, tests/test-pipe.c, tests/test-pipe2.c:
19727         * tests/test-poll.c, tests/test-posix_spawn-chdir.c:
19728         * tests/test-posix_spawn-dup2-stdin.c:
19729         * tests/test-posix_spawn-dup2-stdout.c:
19730         * tests/test-posix_spawn-fchdir.c, tests/test-posix_spawn-open1.c:
19731         * tests/test-posix_spawn-open2.c, tests/test-quotearg-simple.c:
19732         * tests/test-quotearg.c, tests/test-readlink.c:
19733         * tests/test-readlinkat.c, tests/test-readtokens.c:
19734         * tests/test-rename.c, tests/test-renameat.c:
19735         * tests/test-renameatu.c, tests/test-rmdir.c, tests/test-round2.c:
19736         * tests/test-select.h, tests/test-spawn-pipe-child.c:
19737         * tests/test-spawn-pipe-main.c, tests/test-spawn-pipe-script.c:
19738         * tests/test-stack.c, tests/test-stat.c, tests/test-supersede.c:
19739         * tests/test-symlink.c, tests/test-symlinkat.c:
19740         * tests/test-system-quote-main.c:
19741         * tests/test-term-style-control-hello.c:
19742         * tests/test-term-style-control-yes.c, tests/test-timespec.c:
19743         * tests/test-trunc2.c, tests/test-truncf2.c, tests/test-unlink.c:
19744         * tests/test-unlinkat.c, tests/test-userspec.c, tests/test-utime.c:
19745         * tests/test-utimens.c, tests/test-utimensat.c:
19746         * tests/unictype/test-categ_byname.c:
19747         * tests/unigbrk/test-uc-is-grapheme-break.c:
19748         Don’t include stdbool.h.
19749         * modules/acl, modules/xgetcwd:
19750         Don’t depend on stdbool, as these modules don’t use bool.
19751         * modules/argp, modules/bitset, modules/diffseq, modules/file-has-acl:
19752         * modules/gen-uni-tables, modules/getrandom:
19753         * modules/hash-triple-simple, modules/posix_spawn-internal:
19754         * modules/strcasestr, modules/supersede, modules/system-quote:
19755         * modules/uniconv/base, modules/uniname/uniname, modules/utime:
19756         * modules/windows-timedrwlock:
19757         Depend on stdbool, as these modules use bool.
19759         stdbool: upgrade from C99 to C23
19760         Change the stdbool module so that it now emulates C23.
19761         The module now assumes C99.  The old module (which assumes
19762         C89 and emulates C99) is still available  as stdbool-c99,
19763         but is deprecated.
19764         * tests/test-stdbool.c [TEST_C_BOOL]: Do not include stdbool.h.
19765         * m4/c-bool.m4, modules/c-bool, modules/c-bool-tests:
19766         * tests/test-c-bool.c: New files.
19768 2022-09-10  Bruno Haible  <bruno@clisp.org>
19770         string: Fix compilation error in C++ mode on AIX 7.2 with xlclang.
19771         * lib/string.in.h (mbslen): Enable the C++ alias warning only on glibc
19772         systems.
19774 2022-09-10  Bruno Haible  <bruno@clisp.org>
19776         math: Fix compilation error in C++ mode on AIX 7.2 with xlclang.
19777         * lib/math.in.h (cbrtl, copysignl, exp2l, expm1l, fmal, ilogbl, log1pl,
19778         log2l, logbl, remainderl, rintl, roundl, truncl): Enable the C++ alias
19779         warning only on glibc systems.
19781 2022-09-10  Bruno Haible  <bruno@clisp.org>
19783         doc: Mention the stable branches.
19784         * doc/gnulib-readme.texi (High Quality): Add subsection
19785         'Stable Branches'.
19786         (Writing reliable code): Extracted from 'High Quality'. Mention also
19787         -Wall and valgrind.
19789 2022-09-09  Bruno Haible  <bruno@clisp.org>
19791         posix_spawn-internal: Optimize DuplicateHandle calls on native Windows.
19792         * lib/windows-spawn.h (DELAYED_DUP2_OLDFD, DELAYED_DUP2_NEWFD): New
19793         macros.
19794         (struct IHANDLE): Add a linked_fd field.
19795         * lib/spawni.c (SPAWN_INTERNAL_OPTIMIZE_DUPLICATEHANDLE): New macro.
19796         (do_delayed_dup2, do_remaining_delayed_dup2): New functions.
19797         (close_inheritable_handles): Don't close handles in DELAYED_DUP2_NEWFD
19798         entries.
19799         (do_close): Add a third parameter. Optimize delayed dup2 calls.
19800         (do_open): Use do_close.
19801         (do_dup2): Likewise. Prepare for optimizing the DuplicateHandle call.
19802         (__spawni): Do the remaining delayed dup2 invocations after the loop
19803         over the actions.
19805         posix_spawn-internal: Refactor.
19806         * lib/windows-spawn.h (struct IHANDLE): New type.
19807         (struct inheritable_handles): Combine handles and flags into a single
19808         array.
19809         * lib/windows-spawn.c (init_inheritable_handles, compose_handles_block,
19810         spawnpvech): Update.
19811         * lib/spawni.c (grow_inheritable_handles, shrink_inheritable_handles,
19812         do_open, do_dup2, do_close): Update.
19814         posix_spawn-internal: Optimize DuplicateHandle calls on native Windows.
19815         * lib/spawni.c (open_handle): Return an inheritable HANDLE.
19816         (do_open): Don't call DuplicateHandle. Remove curr_process parameter.
19817         (__spawni): Update.
19819         posix_spawn-internal: Optimize DuplicateHandle calls on native Windows.
19820         * lib/windows-spawn.h (KEEP_OPEN_IN_PARENT): New macro.
19821         * lib/windows-spawn.c (init_inheritable_handles): When a handle is
19822         already inheritable, don't bother duplicating it; instead, just mark it
19823         as KEEP_OPEN_IN_PARENT.
19824         * lib/spawni.c (shrink_inheritable_handles, close_inheritable_handles,
19825         do_open, do_dup2, do_close): Don't close handles that are marked as
19826         KEEP_OPEN_IN_PARENT.
19828 2022-09-09  Bruno Haible  <bruno@clisp.org>
19830         posix_spawn-internal: Don't lose flags while duplicating an fd.
19831         * lib/spawni.c (do_dup2): Fix the flags of the new fd.
19833 2022-09-09  Bruno Haible  <bruno@clisp.org>
19835         spawn-pipe: Fix pipe-filter-* test hangs (regression 2020-12-24).
19836         * lib/windows-spawn.h (struct inheritable_handles): Widen the per-fd
19837         flags from 8 bits to 16 bits.
19838         (KEEP_OPEN_IN_CHILD): New macro.
19839         (init_inheritable_handles): Change description of what it does when
19840         duplicate == true.
19841         * lib/windows-spawn.c (init_inheritable_handles): If duplicate == true,
19842         add all fds to the array, regardless whether they are scheduled to be
19843         preserved in the child process.
19844         (compose_handles_block): Update.
19845         (spawnpvech): Update.
19846         * lib/spawni.c (grow_inheritable_handles): Update.
19847         (shrink_inheritable_handles): Also close the handles not marked with
19848         KEEP_OPEN_IN_CHILD.
19849         (do_open, do_dup2): Mark the new fd with KEEP_OPEN_IN_CHILD.
19851 2022-09-09  Bruno Haible  <bruno@clisp.org>
19853         spawn-pipe: Fix possible hangs in programs that spawn several children.
19854         * lib/spawn-pipe.c (create_pipe) [Unix]: Create the ifd[] and ofd[] file
19855         descriptors with the close-on-exec flag set.
19857 2022-09-09  Bruno Haible  <bruno@clisp.org>
19859         pipe-filter-gi tests: Fix long-standing failure on native Windows.
19860         * tests/test-pipe-filter-gi2-main.c: Include binary-io.h.
19861         (main): Avoid NL to CRLF conversion on standard output.
19862         * tests/test-pipe-filter-gi2-child.c: Include <unistd.h>, binary-io.h.
19863         (main): Avoid NL to CRLF conversion on standard output.
19865 2022-09-09  Bruno Haible  <bruno@clisp.org>
19867         posix_spawn_file_actions_addclose tests: Fix mistake from 2022-09-07.
19868         * modules/posix_spawn_file_actions_addclose-tests (Files): Add
19869         m4/musl.m4.
19871 2022-09-08  Paul Eggert  <eggert@cs.ucla.edu>
19873         stdbool-tests: match stdbool
19874         * tests/test-stdbool.c: Omit test for
19875         __bool_true_false_are_defined since AC_CHECK_HEADER_STDBOOL no
19876         longer checks for this obsolescent macro.
19878         mktime: back in sync with GNUlib
19879         * config/srclist.txt: glibc has synced mktime from Gnulib.
19881 2022-09-07  Bruno Haible  <bruno@clisp.org>
19883         posix_spawn_file_actions_addclose tests: Avoid test failure on musl.
19884         Reported by Valery Ushakov <uwe@stderr.spb.ru> in
19885         <https://lists.gnu.org/archive/html/bug-gnulib/2022-09/msg00041.html>.
19886         * modules/posix_spawn_file_actions_addclose-tests (configure.ac): Invoke
19887         gl_MUSL_LIBC.
19888         * tests/test-posix_spawn_file_actions_addclose.c (main): Skip one of the
19889         tests on musl libc.
19891 2022-09-06  Simon Josefsson  <simon@josefsson.org>
19893         gnumakefile: Improve tarball reproducibility.
19894         * top/GNUmakefile (TAR_OPTIONS): Add --sort=name.  Suggested by
19895         Tzvetelin Katchov <katchov@gnu.org>.
19896         * DEPENDENCIES: Mention tar 1.28 dependency.
19898 2022-09-05  Bruno Haible  <bruno@clisp.org>
19900         pthread-h: Fix compilation error on mingw with --enable-threads=windows.
19901         * lib/pthread.in.h: In C++ mode, if mingw's <pthread.h> has not been
19902         used, import many pthread_* symbols from the GNULIB_NAMESPACE into the
19903         global namespace.
19905 2022-09-04  Bruno Haible  <bruno@clisp.org>
19907         Fix various test link errors on MSVC.
19908         * modules/crypto/gc-arcfour-tests (Makefile.am): Link test-gc-arcfour
19909         with $(LIB_GETRANDOM).
19910         * modules/crypto/gc-arctwo-tests (Makefile.am): Link test-gc-arctwo with
19911         $(LIB_GETRANDOM).
19912         * modules/crypto/gc-des-tests (Makefile.am): Link test-gc-des with
19913         $(LIB_GETRANDOM).
19914         * modules/crypto/gc-hmac-md5-tests (Makefile.am): Link test-gc-hmac-md5
19915         with $(LIB_GETRANDOM).
19916         * modules/crypto/gc-hmac-sha1-tests (Makefile.am): Link
19917         test-gc-hmac-sha1 with $(LIB_GETRANDOM).
19918         * modules/crypto/gc-hmac-sha256-tests (Makefile.am): Link
19919         test-gc-hmac-sha256 with $(LIB_GETRANDOM).
19920         * modules/crypto/gc-hmac-sha512-tests (Makefile.am): Link
19921         test-gc-hmac-sha512 with $(LIB_GETRANDOM).
19922         * modules/crypto/gc-md2-tests (Makefile.am): Link test-gc-md2 with
19923         $(LIB_GETRANDOM).
19924         * modules/crypto/gc-md4-tests (Makefile.am): Link test-gc-md4 with
19925         $(LIB_GETRANDOM).
19926         * modules/crypto/gc-md5-tests (Makefile.am): Link test-gc-md5 with
19927         $(LIB_GETRANDOM).
19928         * modules/crypto/gc-pbkdf2-tests (Makefile.am): Link test-gc-pbkdf2 with
19929         $(LIB_GETRANDOM).
19930         * modules/crypto/gc-pbkdf2-sha1-tests (Makefile.am): Link
19931         test-gc-pbkdf2-sha1 with $(LIB_GETRANDOM).
19932         * modules/crypto/gc-rijndael-tests (Makefile.am): Link test-gc-rijndael
19933         with $(LIB_GETRANDOM).
19934         * modules/crypto/gc-sha1-tests (Makefile.am): Link test-gc-sha1 with
19935         $(LIB_GETRANDOM).
19936         * modules/crypto/gc-sha256-tests (Makefile.am): Link test-gc-sha256 with
19937         $(LIB_GETRANDOM).
19938         * modules/crypto/gc-sha512-tests (Makefile.am): Link test-gc-sha512 with
19939         $(LIB_GETRANDOM).
19940         * modules/crypto/gc-sm3-tests (Makefile.am): Link test-gc-sm3 with
19941         $(LIB_GETRANDOM).
19942         * modules/sys_stat-c++-tests (Makefile.am): Link test-sys_stat-c++ with
19943         $(LIB_GETRANDOM).
19944         * modules/unistd-c++-tests (Makefile.am): Link test-unistd-c++ with
19945         $(LIB_GETRANDOM).
19947 2022-09-04  Bruno Haible  <bruno@clisp.org>
19949         count-leading-zeros: Fix a link error on 32-bit MSVC and a test failure.
19950         * lib/count-leading-zeros.h: Correct syntax for #pragma intrinsic.
19951         (COUNT_LEADING_ZEROS): Fix the return value.
19952         (count_leading_zeros_ll): Use two _BitScanReverse invocations instead
19953         of a _BitScanReverse64 invocation.
19955 2022-09-04  Bruno Haible  <bruno@clisp.org>
19957         count-trailing-zeros: Fix a link error on 32-bit MSVC.
19958         * lib/count-trailing-zeros.h: Correct syntax for #pragma intrinsic.
19959         (count_trailing_zeros_ll): Use two _BitScanForward invocations instead
19960         of a _BitScanForward64 invocation.
19962 2022-09-04  Bruno Haible  <bruno@clisp.org>
19964         unictype/category-none tests: Fix a link error on MSVC.
19965         * tests/unictype/test-categ_none.c (main): Disable the test on MSVC.
19967 2022-09-04  Bruno Haible  <bruno@clisp.org>
19969         oset-c++: Fix compilation error with MSVC 14.
19970         * lib/gl_oset.hh: With MSVC, avoid 'friend'.
19972 2022-09-04  Bruno Haible  <bruno@clisp.org>
19974         glob tests: Fix link error on mingw.
19975         * modules/glob-tests (Makefile.am): Link test-glob with $(LIBINTL).
19977 2022-09-04  Bruno Haible  <bruno@clisp.org>
19979         timespec_get: Fix compilation error with MSVC 14.
19980         * m4/gettime.m4 (gl_CHECK_FUNC_TIMESPEC_GET): New macro.
19981         (gl_GETTIME): Use it instead of AC_CHECK_FUNCS_ONCE.
19982         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET): Likewise.
19984 2022-09-04  Bruno Haible  <bruno@clisp.org>
19986         stdbool: Fix compilation error in C++ mode with MSVC 14.
19987         * lib/stdbool.in.h (_Bool, bool, false, true): In C++ mode with MSVC 14,
19988         don't define these as macros.
19990 2022-09-04  Bruno Haible  <bruno@clisp.org>
19992         fts: Fix compilation error with MSVC 14.
19993         * lib/fts.c (S_IFBLK): Add fallback definition.
19995 2022-09-04  Bruno Haible  <bruno@clisp.org>
19997         lstat: Fix compilation error in C++ mode on mingw.
19998         * lib/sys_stat.h (lstat): Move declaration after the declaration of
19999         'stat'.
20001 2022-09-04  Bruno Haible  <bruno@clisp.org>
20003         pselect: Fix compilation error in C++ mode on mingw.
20004         * lib/sys_select.in.h (pselect): Enable the C++ alias warning only on
20005         glibc systems.
20007 2022-09-04  Bruno Haible  <bruno@clisp.org>
20009         nanosleep: Work around bug on newer 32-bit mingw.
20010         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Test for 32-bit mingw bug.
20011         * tests/test-nanosleep.c (main): Add another test.
20012         * doc/posix-functions/nanosleep.texi: Mention the mingw bug.
20014 2022-09-03  Bruno Haible  <bruno@clisp.org>
20016         fmal: Work around glibc 2.17 bug on x86_64.
20017         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Test against bug seen on glibc 2.17
20018         x86_64.
20019         * doc/posix-functions/fmal.texi: Update info.
20021 2022-09-03  Bruno Haible  <bruno@clisp.org>
20023         Fix a compilation error in C++ mode on Solaris 11.4.
20024         * lib/uchar.in.h (c32rtomb): Enable the C++ alias warning only on
20025         glibc ≥ 2.16 systems. Fix a GNULIB_POSIXCHECK mistake.
20026         (mbrtoc32): Enable the C++ alias warning only on glibc ≥ 2.16 systems.
20028 2022-09-03  Bruno Haible  <bruno@clisp.org>
20030         Fix compilation errors of C++ tests on Solaris 10 with Sun C++.
20031         * modules/string-c++-tests (Makefile.am): Link test-string-c++ with
20032         $(LIBUNISTRING).
20033         * modules/wchar-c++-tests (Makefile.am): Link test-wchar-c++ with
20034         $(LIBUNISTRING).
20036 2022-09-03  Bruno Haible  <bruno@clisp.org>
20038         Fix a compilation error in C++ mode on FreeBSD 13.1.
20039         * lib/signal.in.h: Don't include <pthread.h> on FreeBSD ≥ 8.0.
20040         * lib/sys_select.in.h: Don't include <sys/time.h> on FreeBSD.
20042 2022-09-03  Bruno Haible  <bruno@clisp.org>
20044         stdnoreturn: Document relation to C++.
20045         * doc/posix-headers/stdnoreturn.texi: Document FreeBSD problem.
20047 2022-09-03  Bruno Haible  <bruno@clisp.org>
20049         sysexits: Add C++ tests.
20050         * tests/test-sysexits-c++.cc: New file.
20051         * modules/sysexits-c++-tests: New file.
20052         * modules/sysexits-tests (Depends-on): Add sysexits-c++-tests.
20054 2022-09-03  Bruno Haible  <bruno@clisp.org>
20056         sys_utsname: Add C++ tests.
20057         * tests/test-sys_utsname-c++.cc: New file.
20058         * modules/sys_utsname-c++-tests: New file.
20059         * modules/sys_utsname-tests (Depends-on): Add sys_utsname-c++-tests.
20061 2022-09-03  Bruno Haible  <bruno@clisp.org>
20063         sys_uio: Add C++ tests.
20064         * tests/test-sys_uio-c++.cc: New file.
20065         * modules/sys_uio-c++-tests: New file.
20066         * modules/sys_uio-tests (Depends-on): Add sys_uio-c++-tests.
20068 2022-09-03  Bruno Haible  <bruno@clisp.org>
20070         sys_times: Add C++ tests.
20071         * tests/test-sys_times-c++.cc: New file.
20072         * modules/sys_times-c++-tests: New file.
20073         * modules/sys_times-tests (Depends-on): Add sys_times-c++-tests.
20075 2022-09-03  Bruno Haible  <bruno@clisp.org>
20077         sys_file: Add C++ tests.
20078         * tests/test-sys_file-c++.cc: New file.
20079         * modules/sys_file-c++-tests: New file.
20080         * modules/sys_file-tests (Depends-on): Add sys_file-c++-tests.
20082         sys_file: Document this module.
20083         * doc/glibc-headers/sys_file.texi: New file.
20084         * doc/gnulib.texi (Glibc Header File Substitutes): Include it.
20086 2022-09-03  Bruno Haible  <bruno@clisp.org>
20088         stdckdint: Add C++ tests.
20089         * tests/test-stdckdint-c++.cc: New file.
20090         * modules/stdckdint-c++-tests: New file.
20091         * modules/stdckdint-tests (Depends-on): Add stdckdint-c++-tests.
20093 2022-09-03  Bruno Haible  <bruno@clisp.org>
20095         stdalign: Add C++ tests.
20096         * tests/test-stdalign-c++.cc: New file.
20097         * modules/stdalign-c++-tests: New file.
20098         * modules/stdalign-tests (Depends-on): Add stdalign-c++-tests.
20100 2022-09-03  Bruno Haible  <bruno@clisp.org>
20102         sched: Add C++ tests.
20103         * tests/test-sched-c++.cc: New file.
20104         * modules/sched-c++-tests: New file.
20105         * modules/sched-tests (Depends-on): Add sched-c++-tests.
20107 2022-09-03  Bruno Haible  <bruno@clisp.org>
20109         netinet_in: Add C++ tests.
20110         * tests/test-netinet_in-c++.cc: New file.
20111         * modules/netinet_in-c++-tests: New file.
20112         * modules/netinet_in-tests (Depends-on): Add netinet_in-c++-tests.
20114 2022-09-03  Bruno Haible  <bruno@clisp.org>
20116         net_if: Add C++ tests.
20117         * tests/test-net_if-c++.cc: New file.
20118         * modules/net_if-c++-tests: New file.
20119         * modules/net_if-tests (Depends-on): Add net_if-c++-tests.
20120         * doc/posix-headers/net_if.texi: Fix documentation.
20122 2022-09-03  Bruno Haible  <bruno@clisp.org>
20124         termcap: Fix link error on AIX 7.
20125         * m4/termcap.m4 (gl_TERMCAP_BODY): Search also for libxcurses and for
20126         libcurses, like gl_TERMINFO_BODY does.
20127         * m4/terminfo.m4 (gl_TERMINFO_BODY): Update platform list in comment.
20129 2022-09-02  Bruno Haible  <bruno@clisp.org>
20131         getrandom: Fix compilation error in C++ mode on FreeBSD 12.
20132         * lib/sys_random.in.h (getrandom): Enable the C++ alias warning only on
20133         glibc ≥ 2.25 systems.
20135 2022-09-02  Bruno Haible  <bruno@clisp.org>
20137         math C++ tests: Fix compilation error with clang on FreeBSD 13.
20138         * lib/math.in.h (isnan): For clang >= 11 on FreeBSD, declare 'isnan',
20139         not 'rpl_isnan'.
20141 2022-09-02  Bruno Haible  <bruno@clisp.org>
20143         strerror_r-posix: Fix for Hurd.
20144         * lib/strerror_r.c (strerror_r): Interpret return value of
20145         __xpg_strerror_r correctly. Remove assumption about how strerror_r
20146         behaves.
20148 2022-09-02  Bruno Haible  <bruno@clisp.org>
20150         ptsname tests, ptsname_r tests: Fix test failures on Hurd.
20151         * tests/test-ptsname.c (main): On Hurd, test only the BSD ptys that
20152         actually exist on Hurd.
20153         * tests/test-ptsname_r.c (main): Likewise.
20155 2022-09-02  Bruno Haible  <bruno@clisp.org>
20157         strtol, strtoul: Fix compilation error in C++ mode on Solaris 11.
20158         * lib/stdlib.in.h (strtol, strtoul): Enable the C++ alias warning only
20159         on glibc systems.
20161 2022-09-02  Bruno Haible  <bruno@clisp.org>
20163         aligned_alloc: Fix compilation error in C++ mode on Solaris 11.
20164         * lib/stdlib.in.h (aligned_alloc): Enable the C++ alias warning only on
20165         glibc systems.
20167 2022-09-02  Bruno Haible  <bruno@clisp.org>
20169         getdomainname: Fix compilation error in C++ mode on Solaris 11.
20170         * lib/unistd.in.h (getdomainname): Enable the C++ alias warning only on
20171         glibc systems.
20173 2022-09-02  Bruno Haible  <bruno@clisp.org>
20175         terminfo: Don't disturb the termcap module.
20176         * m4/terminfo.m4 (gl_TERMINFO_BODY): Save and restore the variables
20177         determined by the gl_TERMCAP_BODY macro.
20179 2022-08-30  Paul Eggert  <eggert@cs.ucla.edu>
20181         fnmatch: fix stdckdint typo
20182         * lib/fnmatch_loop.c (NEW_PATTERN): Fix typo in previous patch.
20183         Problem and fix reported by Simon Josefsson in:
20184         https://lists.gnu.org/r/bug-gnulib/2022-08/msg00104.html
20186 2022-08-25  Paul Eggert  <eggert@cs.ucla.edu>
20188         tempname: simplify by omitting _LIBC code
20189         * lib/tempname.c [_LIBC]: Simplify.
20190         Suggested by Bruno Haible in:
20191         https://lists.gnu.org/r/bug-gnulib/2022-08/msg00077.html
20192         I plan to propose a corresponding patch to glibc.
20194 2022-08-22  Paul Eggert  <eggert@cs.ucla.edu>
20196         tempname: don't lose entropy in seed
20197         * lib/tempname.c (random_bits): Don't lose entropy in S
20198         in the rare case where where the template has more than 10 Xs.
20199         From a suggestion by Bruno Haible in:
20200         https://bugs.gnu.org/57129#149
20202         tempname: fix multithreading, ASLR leak etc.
20203         Fix problems with tempname and multithreading, entropy loss,
20204         and missing clock data (this last on non-GNU platforms).
20205         See analysis by Bruno Haible in:
20206         https://bugs.gnu.org/57129#149
20207         While looking into this, I noticed that tempname can leak
20208         info derived from ASLR into publicly-visible file names,
20209         which is a no-no.  Fix that too.
20210         * lib/tempname.c: Don't include stdalign.h.
20211         (HAS_CLOCK_ENTROPY): Remove.
20212         (mix_random_values): New function.
20213         (random_bits): Use it.  Args are now new value address and
20214         old value, and this function now returns a success indicator.
20215         Omit old USE_GETRANDOM argument: always try getrandom now, as
20216         there is no good reason not to now that GRND_NONBLOCK is used.
20217         Caller changed.  Use CLOCK_REALTIME for for ersatz entropy,
20218         as CLOCK_MONOTONIC doesn't work on some platforms.
20219         Also, mix in ersatz entropy from tv_sec and from clock ().
20220         (try_tempname_len): Do not mix in ASLR-based entropy, as
20221         the result is published to the world and ASLR should be private.
20222         Do not try to use a static var as that has issues if multithreaded.
20223         Instead, simply generate new random bits.
20224         Worry about bias only with high-quality random bits.
20226         * modules/tempname (Depends-on): Do not depend on stdalign.
20228         tempname: merge 64-bit time_t fix from glibc
20229         This merges glibc commit 52a5fe70a2c77935afe807fb6e904e512ddd894e
20230         "Use 64 bit time_t stat internally".
20231         * lib/tempname.c (struct_stat64) [_LIBC]: Use struct __stat64_t64.
20232         (__lstat64_time64) [!_LIBC]: Rename from __lstat64.
20233         All uses changed.
20234         (direxists): Use __stat64_time64 instead of __stat64.
20236 2022-08-16  Bruno Haible  <bruno@clisp.org>
20238         tempname: Add more tests.
20239         Based on scenario described by Eli Zaretskii in
20240         <https://lists.gnu.org/archive/html/bug-gnulib/2022-08/msg00043.html>.
20241         * tests/test-tempname.c (main): Add another test.
20242         * modules/tempname-tests (Status): Mark the test as unportable.
20244 2022-08-16  Paul Eggert  <eggert@cs.ucla.edu>
20246         tempname: generate better names for MinGW Emacs
20247         On MinGW, GNU Emacs disables clock_gettime, which reliably breaks
20248         some of gen_tempname’s optimistic callers.  Work around the
20249         problem by making the generated names less predictable.  We don’t
20250         need cryptographic randomness here, just enough unpredictability
20251         to keep Emacs happy most of the time.
20252         * lib/tempname.c (HAS_CLOCK_ENTROPY): New macro.
20253         (random_bits): Use it.
20254         (try_tempname_len): On systems lacking clock entropy, maintain
20255         state so that gen_filename generates less-predictable names on
20256         successive successful calls.
20258 2022-08-16  Simon Josefsson  <simon@josefsson.org>
20260         maintainer-makefile: Check for incorrect DISTCHECK_CONFIGURE_FLAGS
20261         usage.
20262         * top/maint.mk (sc_makefile_DISTCHECK_CONFIGURE_FLAGS): Add.
20264 2022-08-16  Bruno Haible  <bruno@clisp.org>
20266         tempname: Add tests.
20267         * tests/test-tempname.c: New file.
20268         * modules/tempname-tests: New file.
20270 2022-08-16  Simon Josefsson  <simon@josefsson.org>
20272         pmccabe2html: Doc fix.
20273         * build-aux/pmccabe2html: Don't use reserved _SOURCES namespace.
20274         Use AM_V_GEN.  Use LC_ALL=C.
20276 2022-08-15  Bruno Haible  <bruno@clisp.org>
20278         stdbool: Drop old BeOS support that gets in the way of ISO C 23 support.
20279         * lib/stdbool.in.h: Don't include <OS.h>.
20281 2022-08-15  Bruno Haible  <bruno@clisp.org>
20283         tempname: Fix a comment.
20284         * lib/tempname.c (try_tempname_len): Use of entropy makes the function
20285         more, not less, secure.
20287 2022-08-15  Paul Eggert  <eggert@cs.ucla.edu>
20289         tempname: remove incorrect comment
20290         * lib/tempname.c, lib/tempname.h: Remove incorrect comment,
20291         as the names are not necessarily hard to predict (Bug#57129).
20293 2022-08-14  Simon Josefsson  <simon@josefsson.org>
20295         bootstrap.conf: Use proper shell marker for Emacs.
20296         * build-aux/bootstrap.conf: Add it.
20298 2022-08-13  Paul Eggert  <eggert@cs.ucla.edu>
20300         stdbool: port to C23
20301         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Copy from bleeding-edge
20302         Autoconf.  Define only if Autoconf 2.71 and earlier.
20303         * tests/test-stdbool.c (bool, false, true)
20304         (__bool_true_false_are_defined): Do not require these to be
20305         defined.  C23 still requires __bool_true_false_are_defined but
20306         marks it as obsolescent, and it’s no longer worth testing.
20307         (WORKING_BOOL): New macro, which also tests __STDC_VERSION__.
20308         Use it in tests for working bool.
20309         Test for bool instead of for _Bool, which C23 says is obsolescent.
20311 2022-08-13  Bruno Haible  <bruno@clisp.org>
20313         gnulib-tool.py: Fix some code generation details.
20314         * pygnulib/GLEmiter.py: Don't produce Windows CR-LFs on Windows.
20315         (GLEmiter.po_Makevars): Emit a definition of top_builddir, not
20316         top_subdir.
20317         (GLEmiter.po_POTFILES_in): Fix result when sourcebase is 'tests' or
20318         something like that.
20319         (GLEmiter.initmacro_start): Add two more newlines (mistake from
20320         2021-04-11).
20322         gnulib-tool.py: Reduce code duplication.
20323         * pygnulib/constants.py (relinverse): New function.
20324         * pygnulib/GLEmiter.py (GLEmiter.po_Makevars,
20325         GLEmiter.tests_Makefile_am): Use it.
20326         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
20328 2022-08-12  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
20330         hamt: fix technically undefined behavior
20331         Bug reported by Bruno Haible in
20332         <https://lists.gnu.org/r/bug-gnulib/2022-04/msg00023.html>.
20333         * lib/hamt.c (entry_insert): Remove technically undefined
20334         behavior when shifting an integer of N bits by N or more bits.
20336 2022-08-10  Paul Eggert  <eggert@cs.ucla.edu>
20338         stdckdint: fix dependency
20339         * modules/stdckdint (Depends-on): Add stdbool.
20340         Reported by Bruno Haible.
20342         maint: parenthesize macro definiens
20343         * lib/intprops.h (INT_ADD_OK, INT_SUBTRACT_OK, INT_MULTIPLY_OK):
20344         * lib/pipe-filter-ii.c (GetLastError):
20345         * lib/thread-optim.h (gl_multithreaded): Parenthesize
20346         function-like macro definiens beginning with a unary operator;
20347         needed for weird invocations like ‘m (...)[p]’.
20349 2022-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20351         stdckdint: prefer to intprops when easy
20352         stdckdint.h is part of draft C23 and therefore is more likely
20353         to be familiar to programmers in the future, so prefer it to
20354         intprops.h in files that don’t need non-_WRAPV intprops.h macros.
20355         * lib/alignalloc.c, lib/backupfile.c, lib/fnmatch.c, lib/fnmatch_loop.c:
20356         * lib/group-member.c, lib/malloca.c, lib/posixtm.c, lib/reallocarray.c:
20357         * lib/xmalloc.c:
20358         For files that can use stdckdint.h just as easily as intprops.h,
20359         include the former instead of the latter, and use the former’s
20360         ckd_* macros instead of the latter’s *_WRAPV macros.
20361         * modules/alignalloc, modules/backup-rename, modules/backupfile:
20362         * modules/fnmatch, modules/group-member, modules/malloca:
20363         * modules/posixtm, modules/reallocarray:
20364         * modules/relocatable-prog-wrapper, modules/xalloc:
20365         Depend on stdckdint instead of intprops.
20367         stdckdint: new module
20368         This supports draft C23 <stdckdint.h>.
20369         * doc/posix-headers/stdckdint.texi:
20370         * lib/stdckdint.in.h, modules/stdckdint:
20371         * modules/stdckdint-tests, tests/test-stdckdint.c:
20372         New files.
20373         * MODULES.html.sh, doc/gnulib.texi: Update for new module.
20374         * lib/intprops-internal.h: Include <stdckdint.h> if C23 and
20375         its macros would help and our substitute has not already
20376         started to be included.
20377         (_GL_INT_ADD_WRAPV, _GL_INT_SUBTRACT_WRAPV)
20378         (_GL_INT_MULTIPLY_WRAPV): Use ckd_add, ckd_sub, ckd_mul
20379         if they are defined and would help.
20380         * lib/intprops-internal.h, lib/intprops.h: Improve comments.
20381         The C23 restrictions on stdckdint macros already mostly applied to
20382         intprops.h, so these are clarifications, not further restrictions.
20383         * tests/test-intprops.c: If TEST_STDCKDINT is defined,
20384         include <stdckdint.h> instead of "intprops.h", and test
20385         it instead.
20386         (VERIFY) [TEST_STDCKDINT]: Ignore the arg in this case.
20387         (main) [TEST_STDCKDINT]: Skip tests irrelevant to stdckdint.h.
20389         intprops: refactor intprops.h into two
20390         * lib/intprops.h: Include new file intprops-internal.h.
20391         (_GL_INT_CONVERT, _GL_INT_NEGATE_CONVERT, _GL_INT_MINIMUM)
20392         (_GL_INT_MAXIMUM, _GL_SIGNED_INT_MAXIMUM, LLONG_MAX, LLONG_MIN)
20393         (_GL_HAVE___TYPEOF__, _GL_SIGNED_TYPE_OR_EXPR)
20394         (_GL_HAS_BUILTIN_ADD_OVERFLOW, _GL_HAS_BUILTIN_MUL_OVERFLOW)
20395         (_GL_HAS_BUILTIN_OVERFLOW_P, _GL__GENERIC_BOGUS)
20396         (_GL_INT_OP_WRAPV, _GL_INT_OP_WRAPV_LONGISH, _GL_INT_OP_CALC)
20397         (_GL_INT_OP_WRAPV_VIA_UNSIGNED, _GL_INT_ADD_RANGE_OVERFLOW)
20398         (_GL_INT_SUBTRACT_RANGE_OVERFLOW)
20399         (_GL_INT_MULTIPLY_RANGE_OVERFLOW):
20400         Move to intprops-internal.h.
20401         (TYPE_SIGNED, EXPR_SIGNED, TYPE_WIDTH, INT_NEGATE_RANGE_OVERFLOW)
20402         (INT_NEGATE_OVERFLOW, INT_ADD_WRAPV, INT_SUBTRACT_WRAPV)
20403         (INT_MULTIPLY_WRAPV): Rename to _GL_ prefix, move to
20404         intprops-internal.h, and define here in terms of the _GL_ name.
20405         * lib/intprops-internal.h: New file, containing the above.
20406         * modules/intprops (Files): Add lib/intprops-internal.h.
20408         intprops: refactor _GL_HAS_BUILTIN_OVERFLOW_P
20409         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P)
20410         [_GL_HAS_BUILTIN_OVERFLOW_P]: Use __builtin_sub_overflow_p
20411         directly rather than indirectly via INT_SUBTRACT_OVERFLOW.
20412         This simplifies future changes, and doesn’t change the generated code.
20414         verify: port ‘assume’ to C23 non-GCC
20415         * lib/verify.h (assume): Use C23's unreachable if available
20416         and if GCC and/or MSC primitives are not available.
20418 2022-08-09  Bruno Haible  <bruno@clisp.org>
20420         gnulib-tool.py: Finish implementing option --conditional-dependencies.
20421         * gnulib-tool.py (main) Accept options --conditional-dependencies,
20422         --no-conditional-dependencies.
20423         * pygnulib/GLModuleSystem.py (GLModuleTable.addConditional): Use
20424         str(module), not module, as key. Fix logic bug.
20425         (GLModuleTable.getCondition): Simplify.
20426         (GLModuleTable.transitive_closure): Show a warning when there are
20427         duplicate dependencies. Fix logic bug.
20428         (GLModuleTable.transitive_closure_separately): Simplify.
20429         (GLModuleTable.add_dummy): Ignore tests modules. Cope with multiple
20430         lib_SOURCES augmentation lines. Cope with comments at the end of a
20431         lib_SOURCES augmentation line. Add the dummy module at the end of the
20432         modules list.
20433         * pygnulib/GLTestDir.py (GLTestDir.execute): Remove the code that forces
20434         the dummy module to the end of the list.
20435         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Add code to
20436         terminate the shell functions. Add code for the dependencies from the
20437         unconditional to the conditional modules. Don't emit AM_CONDITIONAL for
20438         unconditional modules.
20440         gnulib-tool.py: Don't do license replacements in the autoconf snippets.
20441         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Remove fileassistant
20442         argument. Don't invoke the 'aux' transformer here. Don't produce Windows
20443         CR-LFs on Windows.
20444         (GLEmiter.autoconfSnippets): Remove fileassistant argument.
20445         * pygnulib/GLImport.py (GLImport.gnulib_comp): Update all callers.
20446         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
20448         gnulib-tool.py: Fix some code generation details.
20449         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): When removing a
20450         lib_LDFLAGS line, remove also the newline. Fix regex that matches
20451         lib_SOMETHING. Add a newline after each '## begin gnulib module' line.
20452         Don't emit 'endif' lines without corresponding 'if'. When emitting a
20453         '+=' augmentation, make sure it does not get emitted a second time.
20454         Don't emit a blank line when there is no AM_CPPFLAGS augmentation.
20455         Update after getLink() changed. In the value of DEFAULT_TEXT_DOMAIN,
20456         backslash-escape the double-quotes. Don't produce Windows CR-LFs on
20457         Windows. Simplify.
20458         (GLEmiter.tests_Makefile_am): When removing a lib_LDFLAGS line, remove
20459         also the newline. Fix regex that matches lib_SOMETHING. Don't remove a
20460         blank line before EXTRA_DIST. Add a newline after each
20461         '## begin gnulib module' line. Set uses_subdirs also when there is a .c
20462         file in a subdir of tests/. When emitting a '+=' augmentation, make sure
20463         it does not get emitted a second time. Don't produce Windows CR-LFs on
20464         Windows. Simplify.
20465         * pygnulib/GLImport.py (GLImport.execute): Update after getLink()
20466         changed.
20468         gnulib-tool.py: Fixes for conditional dependencies.
20469         * pygnulib/GLModuleSystem.py (GLModule.shell_id_chars): New constant.
20470         (GLModule.getShellFunc): Don't use md5 just because of an '_' character.
20471         (GLModule.getShellVar): Likewise.
20472         (GLModule.getConditionalName): Include a newline in the md5 input.
20473         * pygnulib/constants.py (ALPHANUMERIC): Remove constant.
20475         gnulib-tool.py: Refactor.
20476         * pygnulib/GLModuleSystem.py (GLModule.getLicense): Separate the warning
20477         logic from the result logic.
20479 2022-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20481         largefile, year2038: simplify if > Autoconf 2.71
20482         * m4/largefile.m4 (gl_SET_LARGEFILE_SOURCE)
20483         (_AC_SYS_LARGEFILE_MACRO_VALUE):
20484         * m4/year2038.m4 (gl_YEAR2038_EARLY, gl_YEAR2038, gl_YEAR2038_BODY):
20485         Adjust to Autoconf versions after 2.71, which should contain the Gnulib
20486         patches in this area and so should not need to be overridden.
20488 2022-08-07  Bruno Haible  <bruno@clisp.org>
20490         gnulib-tool.py: Finish implementing option --extract-test-module.
20491         * gnulib-tool.py (main): Accept option --extract-tests-module.
20493         gnulib-tool.py: Fix handling of nonexistent module names in --extract-*.
20494         * gnulib-tool.py (main): To test whether a module exists, just call
20495         GLModuleSystem.find and test its return value.
20497         gnulib-tool.py: Fix --extract-dependencies result.
20498         * pygnulib/GLModuleSystem.py (GLModule.getDependencies): Return a
20499         snippet, not a list. Implement dependency of ${module}-tests on
20500         ${module}.
20501         (GLModule.getDependenciesWithoutConditions,
20502         GLModule.getDependenciesWithConditions): New methods.
20503         (GLModuleTable.transitive_closure): Call getDependenciesWithConditions.
20504         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Call
20505         getDependenciesWithoutConditions.
20506         * gnulib-tool.py (main) [--extract-dependencies]: Update.
20508         gnulib-tool.py: Rename a method.
20509         * pygnulib/GLModuleSystem.py (GLModule.getAutoconfEarlySnippet): Renamed
20510         from GLModule.getAutoconfSnippet_Early.
20511         * pygnulib/GLImport.py: Update.
20512         * pygnulib/GLTestDir.py: Likewise.
20514         gnulib-tool.py: Fix section extraction from module descriptions.
20515         The code with   self.content.split(section)[-1]
20516         was broken because it recognizes an indented section label.
20517         Similar code with   ('\n' + self.content).split('\n' + section)[-1]
20518         would still be broken because it recognizes an indented section label
20519         in the first line of the file.
20520         The code with   section_label_regex
20521         was broken because sometimes it returns the second-to-last section with
20522         the given label, not the last one.
20523         Also, whitespace after the colon was not ignored.
20524         * pygnulib/GLModuleSystem.py (GLModule.__init__): Dissect the module
20525         description's contents immediately, once only, in a reliable way.
20526         (GLModule.getDescription, GLModule.getComment): Simplify.
20527         (GLModule.getStatus): Simplify. Return a string.
20528         (GLModule.getStatuses): New function. Return a list.
20529         (GLModule.getNotice, GLModule.getApplicability, GLModule.getFiles,
20530         GLModule.getDependencies, GLModules.getAutoconfSnippet_Early,
20531         GLModules.getAutoconfSnippet, GLModule.getAutomakeSnippet_Conditional,
20532         GLModule.getInclude, GLModule.getLink, GLModule.getLicense_Raw):
20533         Simplify.
20534         (GLModule.getLicense): Remove whitespace after calling getLicense_Raw.
20535         (GLModule.getMaintainer): Simplify.
20536         (GLModuleTable.transitive_closure): Call getStatuses() instead of
20537         getStatus().
20538         * pygnulib/GLEmiter.py: Likewise.
20539         * gnulib-tool.py (main): For --extract-description, --extract-comment,
20540         --extract-status, --extract-notice, --extract-autoconf-snippet,
20541         --extract-automake-snippet, --extract-include-directive,
20542         --extract-link-directive, --extract-maintainer, don't add an extra
20543         newline after the snippet.
20545         gnulib-tool.py: Improve field naming.
20546         * pygnulib/GLModuleSystem.py (GLModule): Rename field 'module' to
20547         'path'. Fix a typo in a TypeError message.
20549         gnulib-tool.py: Simplify.
20550         * pygnulib/GLModuleSystem.py (GLModule): Convert Windows newlines right
20551         after reading the module description, not in every accessor.
20553         gnulib-tool.py: Reduce code duplication.
20554         * pygnulib/GLModuleSystem.py (GLModule): Declare two regexes are class
20555         variables.
20557         gnulib-tool.py: Implement option --find.
20558         * pygnulib/GLModuleSystem.py (GLModuleSystem.file_is_module): New
20559         method.
20560         (GLModuleSystem.list): Filter the listing in memory; don't use a 'sed'
20561         subprocess.
20562         * gnulib-tool.py (main): Handle mode 'find'.
20564         gnulib-tool: Fix option --find in combination with option --local-dir.
20565         * gnulib-tool (func_prefixed_modules_in_dir): New function.
20566         (find): Use it, and filter the directory names away after the 'grep'
20567         pass.
20569         gnulib-tool.py: Fix some regexes.
20570         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Use an equivalent
20571         regex as gnulib-tool.
20572         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
20574         gnulib-tool.py: Fix some regex uses.
20575         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Match
20576         the regex against all lines of the snippet, not only the first line.
20577         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Likewise.
20579         gnulib-tool.py: Make regex uses more straightforward.
20580         * pygnulib/constants.py: Don't use the "minimal matching" *? construct
20581         when it makes no difference (because we're matching a single line only
20582         and flag re.M is not specified).
20583         * pygnulib/GLModuleSystem.py: Likewise.
20585         gnulib-tool.py: Make regex uses more straightforward.
20586         * pygnulib/GLModuleSystem.py: Don't use flag re.S on regular expressions
20587         that are meant to match a single line only, and remove the use of the
20588         "minimal matching" *? construct whose only purpose was to neutralize the
20589         re.S flag.
20590         * pygnulib/GLEmiter.py: Likewise.
20591         * pygnulib/GLImport.py: Likewise.
20592         * pygnulib/GLTestDir.py: Likewise.
20594         gnulib-tool.py: Make regex uses more straightforward.
20595         * pygnulib/GLEmiter.py: Don't use flag re.S on regular expressions on
20596         regular expressions with no '.'.
20597         * pygnulib/GLImport.py: Likewise.
20599 2022-08-06  Bruno Haible  <bruno@clisp.org>
20601         gnulib-tool: In the VC files messages, omit the destination directory.
20602         This makes these messages consistent with the other "Copying ..." and
20603         "Creating ..." messages.
20604         * gnulib-tool (func_import): Omit $destdir/ from the "Updating"/
20605         "Creating" messages regarding .gitignore files.
20606         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Likewise.
20608         gnulib-tool.py: Fix output in --dry-run mode.
20609         * pygnulib/GLImport.py (GLImport._update_ignorelist_): In dry-run mode,
20610         say "Update", not "Updating".
20612         gnulib-tool.py: Finish implementing options --vc-files, --no-vc-files.
20613         * gnulib-tool.py (main): Accept options --vc-files, --no-vc-files.
20614         * pygnulib/GLImport.py (GLImport.__init__): Correct parsing of
20615         gl_VC_FILES directive.
20616         (GLImport.gnulib_cache): Don't treat the value False like None.
20617         (GLImport.execute): Skip the .gitignore file manipulations if vc_files
20618         is False.
20620         gnulib-tool.py: Finish implementing option --witness-c-macro.
20621         * gnulib-tool.py (main): Accept option --witness-c-macro.
20622         * pygnulib/GLConfig.py (GLConfig.__init__): Remove wrong type check of
20623         witness_c_macro argument.
20625 2022-08-05  Bruno Haible  <bruno@clisp.org>
20627         gnulib-tool.py: Don't initialize local variables too early.
20628         * gnulib-tool.py (main): Initialize each local variable in one place.
20629         I prefer to have pylint tell me about uninitialized variables than to
20630         get the value None at runtime.
20632         gnulib-tool.py: Finish implementing option --po-domain.
20633         * gnulib-tool.py (main): Accept option --po-domain.
20634         * pygnulib/GLEmiter.py (GLEmiter.po_POTFILES_in): Fix variable
20635         reference.
20636         * pygnulib/GLImport.py (GLImport.execute): Don't delete Makefile.in.in
20637         from the gnulib directory. Don't require a shell when invoking wget.
20638         After invoking wget, restore the current directory.
20640         gnulib-tool.py: Finish implementing option --macro-prefix.
20641         * gnulib-tool.py (main): Accept option --macro-prefix.
20643         gnulib-tool.py: Refactor --makefile-name option.
20644         * gnulib-tool.py (main): Handle option --makefile-name like all other
20645         string-valued options.
20647         gnulib-tool.py: Implement option --no-libtool.
20648         * gnulib-tool.py (main): Accept option --no-libtool.
20650         gnulib-tool.py: Remove redundant type checks.
20651         * pygnulib/GLConfig.py (GLConfig.__init__): Remove redundant type
20652         checks, left over from 2022-08-04.
20653         (GLConfig.getIncludeGuardPrefix): Improve comment.
20654         (GLConfig.resetMacroPrefix): Optimize.
20656         gnulib-tool.py: Refactor --makefile-name option.
20657         * gnulib-tool.py (main): Rename variable 'makefile' to 'makefile_name'.
20658         * pygnulib/GLConfig.py: Rename attribute 'makefile' to 'makefile_name'.
20659         * pygnulib/GLMakefileTable.py: Update.
20660         * pygnulib/GLEmiter.py: Likewise.
20661         * pygnulib/GLImport.py: Likewise.
20662         * pygnulib/GLFileSystem.py (GLFileAssistant): Remove unused assignment.
20664         gnulib-tool.py: Fix link_if_changed function.
20665         * pygnulib/constants.py (joinpath): Fix comment.
20666         (as_link_value_at_dest): New function, extracted from link_relative.
20667         (link_relative): Use it.
20668         (link_if_changed): Really don't replace the symbolic link if it does not
20669         need to change.
20671         gnulib-tool.py: Fix 'Unused import' warnings.
20672         * gnulib-tool.py: Remove unused imports.
20673         * pygnulib/*.py: Likewise.
20675         gnulib-tool.py: Fix 'Undefined variable' errors.
20676         * pygnulib/constants.py: Import codecs.
20677         * pygnulib/GLConfig.py (GLConfig.setLibName): Fix local variable
20678         reference.
20679         * pygnulib/GLFileSystem.py (GLFileSystem.lookup,
20680         GLFileAssistant.update): Fix local variable references.
20681         * pygnulib/GLEmiter.py (GLEmiter.po_POTFILES_in): Fix reference.
20682         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Define missing local
20683         variables.
20685         gnulib-tool.py: Make option --version work.
20686         * pygnulib/constants.py (__copyright__): Bump copyright year.
20687         * pygnulib/GLInfo.py (GLInfo.authors): Add a comma after the
20688         second-to-last author.
20689         (GLInfo.copyright): Show only the last modification year.
20690         (GLInfo.date): Check whether git and GNU date are available. Use
20691         'git log ChangeLog', not 'git log'. Run 'git log' in the gnulib
20692         directory, not in the current directory. Search for 'Date:' only at the
20693         beginning of a line. As a fallback, look at the first ChangeLog entry.
20694         (GLInfo.version): Check whether git is available. Run git-version-gen in
20695         the gnulib directory, not in the current directory. Replace '-dirty'
20696         with '-modified'. As a fallback, return the empty string.
20697         * gnulib-tool.py (main) [--version]: Add a space before the version.
20699         gnulib-tool.py: Simplify.
20700         * pygnulib/constants.py (compiler): Remove function.
20701         * gnulib-tool.py: Use re.compile directly instead.
20702         * pygnulib/*.py: Likewise.
20704 2022-08-04  Bruno Haible  <bruno@clisp.org>
20706         gnulib-tool.py: Fix typo.
20707         * pygnulib/GLImport.py (GLImport.execute): Actually handle file
20708         removals.
20710         gnulib-tool.py: Coding style: Revisit line breaks.
20711         * gnulib-tool.py: Avoid line breaks at arbitrary points inside
20712         expressions. Use line breaks to clarify [... for ...] iterations.
20713         * pygnulib/*.py: Likewise.
20715         gnulib-tool.py: Simplify boolean setters.
20716         * pygnulib/GLConfig.py (setLibtool): New method, replaces enableLibtool
20717         and disableLibtool.
20718         (setCondDeps): New method, replaces enableCondDeps and disableCondDeps.
20719         (setVCFiles): New method, replaces enableVCFiles and disableVCFiles.
20720         (setSymbolic): New method, replaces enableSymbolic and disableSymbolic.
20721         (setLSymbolic): New method, replaces enableLSymbolic and
20722         disableLSymbolic.
20723         (setLibtests): New method, replaces enableLibtests and disableLibtests.
20724         (setSingleConfigure): New method, replaces enableSingleConfigure and
20725         disableSingleConfigure.
20726         (setDryRun): New method, replaces enableDryRun and disableDryRun.
20727         (setErrors): New method, replaces enableErrors and disableErrors.
20728         (__init__): Update.
20729         * pygnulib/GLImport.py: Likewise.
20730         * pygnulib/GLTestDir.py: Likewise.
20732         gnulib-tool.py: Implement options --cache-modules, --no-cache-modules.
20733         * gnulib-tool.py (main): Accept options --cache-modules,
20734         --no-cache-modules.
20735         * pygnulib/GLConfig.py: Remove modcache property and constructor
20736         argument.
20737         * pygnulib/GLInfo.py (GLInfo.usage): Don't document these no-op options.
20739         gnulib-tool.py: Use mainstream/GNU coding style.
20740         * gnulib-tool.py: Break lines before the % operator, not after.
20741         * pygnulib/*.py: Likewise. Avoid line breaks when the resulting lines
20742         are not too long.
20744         gnulib-tool.py: Follow gnulib-tool changes, part 24.
20745         Follow gnulib-tool change
20746         2017-02-19  Bruno Haible  <bruno@clisp.org>
20747         gnulib-tool: Avoid conflict of havelib-tests with --single-configure.
20748         * pygnulib/GLTestDir.py (GLTestDir.__init__): Don't allocate the
20749         GLModuleTable here.
20750         (GLTestDir.execute): Do it here. Avoid havelib-tests when
20751         --with-tests --single-configure is specified.
20753         gnulib-tool.py: Respect the specified module list.
20754         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't remove specific
20755         modules (ftruncate, mountlist, etc.) from the specified module list.
20757         gnulib-tool.py: Implement option --avoid.
20758         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Compute the
20759         effective avoids list here.
20760         (GLModuleTable.transitive_closure, GLModuleTable.add_dummy): Consider
20761         the avoids list.
20762         * pygnulib/GLImport.py (GLImport.gnulib_cache): Use the avoids list from
20763         GLConfig directly.
20764         (GLImport.prepare): No need any more to set the avoids list in the
20765         GLModuleTable.
20767         gnulib-tool.py: Make --with/--without-*-tests handling a little safer.
20768         * pygnulib/GLConfig.py (__init__): Fix reset* invocations.
20769         setInclTestCategories, setExclTestCategories): Revert to old value if
20770         the new value is invalid.
20772 2022-08-03  Bruno Haible  <bruno@clisp.org>
20774         gnulib-tool.py: Implement option --single-configure.
20775         * gnulib-tool.py (main): Accept option --single-configure. Pass its
20776         value to the GLConfig constructor.
20777         * pygnulib/GLTestDir.py (GLTestDir.execute): Remove debugging output.
20779         gnulib-tool.py: Implement options --without-c++-tests etc.
20780         * gnulib-tool.py (main): Accept options --without-c++-tests,
20781         --without-longrunning-tests, --without-privileged-tests,
20782         --without-unportable-tests.
20783         Improve error message for --copy-file with invalid number of arguments.
20784         Check for invalid options given in --import, --add-import,
20785         --remove-import, --update modes.
20786         Pass both sets of test categories to the GLConfig constructor.
20787         * pygnulib/GLConfig.py (GLConfig.__init__): Accept incl_test_categories
20788         and excl_test_categories instead of testflags.
20789         (checkInclTestCategory): Renamed from checkTestFlag.
20790         (enableInclTestCategory): Renamed from enableTestFlag.
20791         (disableInclTestCategory): Renamed from disableTestFlag.
20792         (getInclTestCategories): Renamed from getTestFlags.
20793         (setInclTestCategories): Renamed from setTestFlags.
20794         (resetInclTestCategories): Renamed from resetTestFlags.
20795         (setInclTestCategory, checkExclTestCategory, enableExclTestCategory,
20796         disableExclTestCategory, getExclTestCategories, setExclTestCategories,
20797         resetExclTestCategories): New methods.
20798         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Accept two
20799         booleans as second and third constructor arguments.
20800         (transitive_closure): Correct the determination of whether to include
20801         each module, depending on the with-* and without-* options.
20802         (transitive_closure_separately): Update.
20803         * pygnulib/GLMakefileTable.py: Update.
20804         * pygnulib/GLImport.py (__init__, actioncmd, gnulib_cache, execute):
20805         Update.
20806         * pygnulib/GLTestDir.py (GLTestDir.__init__, GLTestDir.execute,
20807         GLMegaTestDir.__init__): Update.
20809         gnulib-tool.py: Implement option --without-tests.
20810         * gnulib-tool.py (main): Accept option --without-tests.
20812         gnulib-tool.py: Fix broken 'for' loop.
20813         * gnulib-tool.py (main): Canonicalize inctests before creating the
20814         GLConfig. Rewrite a broken 'for' loop.
20815         * pygnulib/GLConfig.py (GLConfig.setTestFlags): Remove unused statement.
20817         gnulib-tool.py: Follow gnulib-tool changes, part 23.
20818         Follow gnulib-tool changes
20819         2016-11-11  Bruno Haible  <bruno@clisp.org>
20820         gnulib-tool: Support for the dual "LGPLv3+ or GPLv2" license.
20821         2016-12-02  Nikos Mavrogiannopoulos <nmav@gnutls.org>
20822         gnulib-tool (func_import): Adhere to the license guideline ...
20823         2016-12-02  Daiki Ueno  <ueno@gnu.org>
20824         gnulib-tool (func_import): Relax the regex ...
20825         * gnulib-tool.py: For --lgpl, accept value 3orGPLv2.
20826         * pygnulib/GLInfo.py (GLInfo.usage): Update.
20827         * pygnulib/GLConfig.py (GLConfig.setLGPL): Update argument check.
20828         * pygnulib/GLImport.py (GLImport.__init__, GLImport.gnulib_cache):
20829         Update gl_LGPL handling.
20830         (GLImport.prepare): Update license compatibility checks and license
20831         header rewriting.
20832         * pygnulib/GLTestDir.py (GLTestDir.execute): Update license
20833         compatibility checks. Handle also the licenses GPLv3+, GPL, LGPLv3+.
20835         gnulib-tool.py: Fix unjustified "incompatible license" warnings.
20836         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't emit a warning when
20837         the dependency module has a license such as "public domain" or
20838         "unlimited".
20840         gnulib-tool.py: Follow gnulib-tool changes, part 22.
20841         Follow gnulib-tool change
20842         2016-10-15  Bruno Haible  <bruno@clisp.org>
20843         Avoid gnulib-tool warnings about the dependencies of 'parse-datetime'.
20844         * pygnulib/GLModuleSystem.py (GLModule.getLicense): Special-case the
20845         'parse-datetime' module.
20847         gnulib-tool.py: Follow gnulib-tool changes, part 21.
20848         Follow gnulib-tool change
20849         2016-10-16  Bruno Haible  <bruno@clisp.org>
20850         gnulib-tool: Make --create-testdir on all modules work again.
20851         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't include the
20852         non-recursive-gnulib-prefix-hack module.
20854         gnulib-tool.py: Follow gnulib-tool changes, part 20.
20855         Follow gnulib-tool changes
20856         2016-01-15  Paul Eggert  <eggert@cs.ucla.edu>
20857         gnulib-tool: don't assume ln -s works
20858         2016-01-24  Paul Eggert  <eggert@cs.ucla.edu>
20859         gnulib-tool: don't give up on ln -s so easily
20860         2017-06-08  Bruno Haible  <bruno@clisp.org>
20861         gnulib-tool: Fix bug in func_ln_s, from 2016-01-15.
20862         * pygnulib/constants.py (symlink_relative): New function.
20863         (link_relative): Use it instead of os.symlink.
20865         gnulib-tool.py: Avoid errors when writing to a VFAT file system, part 2.
20866         * pygnulib/constants.py (movefile): New function.
20867         * pygnulib/*.py: Use it instead of shutil.
20869         gnulib-tool.py: Avoid errors when writing to a VFAT file system.
20870         * pygnulib/constants.py (copyfile, copyfile2): New functions.
20871         * gnulib-tool.py: Use them instead of shutil.
20872         * pygnulib/*.py: Likewise.
20874         gnulib-tool.py: Fix typo.
20875         * pygnulib/GLImport.py (GLImport.__init__): Use the relative auxdir as
20876         second, not as first argument of joinpath.
20878 2022-07-31  Bruno Haible  <bruno@clisp.org>
20880         gnulib-tool.py: Fix typo.
20881         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Invoke os.mkdir as
20882         intended.
20884         gnulib-tool.py: Improve some error messages.
20885         * gnulib-tool.py (main): Write "*** Stop." instead of "*** Exit.".
20886         (__main__): Print an error message for GLError 5, 13, 14, 15, 16, 17, 18.
20887         * pygnulib/GLError.py (GLError.__repr__): Compute one error message,
20888         not 19.
20890         gnulib-tool.py: Write errors to stderr, not stdout.
20891         * pygnulib/constants.py: Write error messages to stderr, not stdout.
20893         gnulib-tool.py: Use mainstream coding style.
20894         * pygnulib/GLConfig.py: Use 'raise' to re-throw an exception.
20896         gnulib-tool.py: Implement options --symlink and --local-symlink.
20897         * gnulib-tool.py (main): Handle options --symlink and --local-symlink.
20898         * pygnulib/constants.py (link_if_changed): Ignore FileNotFoundError from
20899         os.remove call.
20901         gnulib-tool.py: Make --copy-file work.
20902         * gnulib-tool.py (main) [copy-file]: Fix reference to uninitialized
20903         variable. Fix error handling of os.makedirs. Pass the destdir to the
20904         GLFileAssistant.
20906         gnulib-tool.py: Allow module arguments to occur at any position.
20907         * gnulib-tool.py (main): Collect the non-option arguments in a single
20908         list, regardless of their position. Use parse_known_args instead of
20909         parse_args, and give an error message about unknown options ourselves.
20910         * gnulib-tool: Fix typo in error message.
20912         gnulib-tool.py: Make --test behaviour more similar to gnulib-tool.
20913         * gnulib-tool.py (main) [test]: Remove space from the testdir name.
20915         gnulib-tool: Clarify that --test allows zero module arguments.
20916         * gnulib-tool (func_usage): Mark the modules for --test as optional.
20917         * pygnulib/GLInfo.py (GLInfo.usage): Likewise.
20919         gnulib-tool.py: Make option processing more similar to gnulib-tool.
20920         * gnulib-tool.py (main): Allow --add-import and --remove-import with 0
20921         modules.
20923         gnulib-tool.py: Improve compliance with GNU standards.
20924         * gnulib-tool.py (main): Handle --help and --version before testing for
20925         conflicting modes.
20927         gnulib-tool.py: Emit error message when conflicting modes are specified.
20928         * gnulib-tool.py (main): Fix test of conflicting modes. (Some options
20929         produce a value of [], and as a condition, [] evaluates to False.)
20931         gnulib-tool.py: Remove most short options.
20932         * gnulib-tool.py (main): Reorder the list of options. Remove most short
20933         options, for consistency with gnulib-tool.
20935         gnulib-tool.py: Follow gnulib-tool changes, part 19.
20936         Follow gnulib-tool changes
20937         2015-12-09  Pavel Raiskup  <praiskup@redhat.com>
20938         gnulib-tool: allow multiple --local-dir usage
20939         2019-02-14  Bruno Haible  <bruno@clisp.org>
20940         gnulib-tool: Improve handling of multiple --local-dir options.
20941         * gnulib-tool (func_reconstruct_cached_dir): When the argument is
20942         absolute, return it unmodified.
20943         (func_compute_relative_local_gnulib_path): Renamed from
20944         func_count_relative_local_gnulib_path. Add comment.
20945         * gnulib-tool.py: Accept multiple --local-dir options and collect the
20946         values into localpath.
20947         * pygnulib/GLConfig.py: Take a localpath argument instead of a localdir
20948         argument.
20949         (getLocalDir, setLocalDir, resetLocalDir): Remove methods.
20950         (getLocalPath, setLocalPath, resetLocalPath): New methods.
20951         * pygnulib/GLFileSystem.py (CopyAction): New class.
20952         (GLFileSystem.lookup): Consider all dirs in localpath.
20953         (GLFileSystem.shouldLink): New method.
20954         (GLFileAssistant): Use shouldLink.
20955         * pygnulib/GLModuleSystem.py (GLModuleSystem.exists): Iterate over all
20956         dirs in localpath.
20957         (GLModuleSystem.list): Likewise.
20958         * pygnulib/GLEmiter.py: Update.
20959         * pygnulib/GLImport.py (GLImport.__init__): Put the argument of
20960         gl_LOCAL_DIR into localpath, not localdir.
20961         (GLImport.actioncmd): Consider all dirs in localpath.
20962         (GLImport.relative_to_destdir, GLImport.relative_to_currdir): New
20963         methods.
20964         (GLImport.gnulib_cache): Combine all dirs in localpath. Use
20965         self.relative_to_destdir.
20966         * pygnulib/GLTestDir.py (GLTestDir.execute): Use shouldLink.
20968         gnulib-tool.py: Improve the primitives for relative file names.
20969         * pygnulib/constants.py (relativize): Don't attempt to handle absolute
20970         file names. Fix bug with relativize('../foo/bar', '../foo/bla/zut').
20971         (relconcat): New function.
20973         gnulib-tool.py: Follow gnulib-tool changes, part 18.
20974         Follow gnulib-tool change
20975         2005-09-20  Bruno Haible  <bruno@clisp.org>
20976         gnulib-tool: Remove trailing slashes
20977         * pygnulib/constants.py (remove_trailing_slashes): New function.
20978         * pygnulib/GLConfig.py (GLConfig): Use it in the setters.
20980 2022-07-31  Bruno Haible  <bruno@clisp.org>
20982         avltree-omap, avltree-oset, avltreehash-list, rbtree-omap: Pacify GCC.
20983         * lib/gl_avltree_omap.c (gl_avltree_omap_check_invariants): Add extern
20984         decl.
20985         * lib/gl_avltree_oset.c (gl_avltree_oset_check_invariants): Likewise.
20986         * lib/gl_avltreehash_list.c (gl_avltreehash_list_check_invariants):
20987         Likewise.
20988         * lib/gl_rbtree_omap.c (gl_rbtree_omap_check_invariants): Likewise.
20990 2022-07-31  Paul Eggert  <eggert@cs.ucla.edu>
20992         rbtree-oset, rbtreehash-list: Pacify GCC
20993         * lib/gl_rbtree_oset.c (gl_rbtree_oset_check_invariants):
20994         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_check_invariants):
20995         Add extern decls, to pacify --enable-gcc-warnings with Bison.
20997 2022-07-31  Akim Demaille  <akim@lrde.epita.fr>
20999         gnulib-tool: add support for --automake-subdir-tests
21000         <https://lists.gnu.org/r/bug-gnulib/2022-01/msg00111.html>
21001         * gnulib-tool (main): Handle --automake-subdir-tests.
21002         (func_emit_shellvars_init, func_emit_lib_Makefile_am): Use
21003         $sourcebase when handling tests and --automake-subdir-tests is
21004         given.
21005         (func_append_actionarg): Support --automake-subdir-tests.
21006         (func_create_testdir): Add missing argument for func_emit_initmacro_end.
21008 2022-07-31  Bruno Haible  <bruno@clisp.org>
21010         gendocs.sh: Fix error when invoking 'perl' (regression 2022-07-23).
21011         * build-aux/gendocs.sh (PERL): Use double-quotes, not single-quotes.
21013 2022-07-30  Bruno Haible  <bruno@clisp.org>
21015         gnulib-tool.py: Clean up imports.
21016         * gnulib-tool.py: Remove unused constants.
21017         * pygnulib/*.py: Likewise.
21019         gnulib-tool.py: Assume Python 3.
21020         * gnulib-tool.py: Don't allow 'bytes' as an alternative to 'str'.
21021         * pygnulib/*.py: Likewise.
21023         gnulib-tool.py: Assume Python 3.
21024         * gnulib-tool.py: Don't set PYTHON3, string. Use str instead of string.
21025         * pygnulib/*.py: Likewise.
21027         gnulib-tool.py: Modernize coding style.
21028         * pygnulib/*.py: Remove parentheses around raise value expressions.
21030 2022-07-30  Bruno Haible  <bruno@clisp.org>
21032         doc: Update regarding bootstrap split.
21033         Reported by Paul Smith <psmith@gnu.org>.
21034         * doc/gnulib-tool.texi (gettextize and autopoint): Mention autogen.sh
21035         instead of bootstrap.
21036         (VCS Issues): Describe three alternative approaches.
21037         * doc/gnulib.texi (Developer tools): Mention also autopull.sh and
21038         autogen.sh.
21039         * top/bootstrap (usage): Fix copy&paste mistake.
21041 2022-07-29  Bruno Haible  <bruno@clisp.org>
21043         gnulib-tool.py: Follow gnulib-tool changes, part 17.
21044         Follow gnulib-tool change
21045         2015-10-06  Pavel Raiskup  <praiskup@redhat.com>
21046         gnulib-tool: fix tests of 'extensions' module
21047         * pygnulib/GLEmiter.py (GLEmiter.preEarlyMacros): New function.
21048         * pygnulib/GLImport.py (GLImport.gnulib_comp): Invoke it.
21049         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
21051         gnulib-tool.py: Follow gnulib-tool changes, part 16.
21052         Follow gnulib-tool change
21053         2015-09-25  Pavel Raiskup  <praiskup@redhat.com>
21054         gnulib-common.m4: fix gl_PROG_AR_RANLIB/AM_PROG_AR clash
21055         * pygnulib/GLImport.py (GLImport.gnulib_comp): Put the
21056         gl_USE_SYSTEM_EXTENSIONS right before gl_PROG_AR_RANLIB into
21057         gnulib-comp.m4 (if the 'extensions' module is used).
21059         gnulib-tool.py: Modernize coding style.
21060         * pygnulib/*.py: Remove parentheses around return value expressions.
21062         gnulib-tool.py: Modernize the file headers.
21063         * pygnulib/*.py: Remove '#!/usr/bin/python' (not needed) and
21064         'encoding: UTF-8' lines (default in Python 3). Add copyright notice.
21066         gnulib-tool.py: Use mainstream coding style.
21067         * gnulib-tool.py: Clarify the coding style. Fix some pycodestyle
21068         warnings.
21069         * pygnulib/constants.py: Likewise.
21070         * pygnulib/GLEmiter.py: Likewise.
21071         * pygnulib/GLImport.py: Likewise.
21072         * pygnulib/GLMakefileTable.py: Likewise.
21074 2022-07-29  Bruno Haible  <bruno@clisp.org>
21076         gnulib-tool.py: Fix error (regression 2021-04-11).
21077         * pygnulib/GLConfig.py (GLConfig.getModuleIndicatorPrefix): Fix code.
21079         gnulib-tool.py: Fix warning from Python 3.10.4.
21080         * pygnulib/GLModuleSystem.py (getConditionalName): Fix a string
21081         substitution expression.
21083         gnulib-tool.py: Fix error in Ubuntu 22.04.
21084         * gnulib-tool.py: Search for python3 in $PATH.
21086 2022-07-25  Bruno Haible  <bruno@clisp.org>
21088         bootstrap: Make the automatic sync more resilient.
21089         Reported by Paul Eggert in
21090         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00060.html>.
21091         * top/bootstrap (bootstrap_sync): Set to true when bootstrap-funclib.sh
21092         is not present.
21093         * top/gen-bootstrap.sed: Insert a couple of comment lines.
21094         * build-aux/bootstrap: Regenerated using "make build-aux/bootstrap".
21096 2022-07-24  Bruno Haible  <bruno@clisp.org>
21098         Fix comment.
21099         Reported by Paul Eggert in
21100         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00058.html>.
21101         * top/bootstrap-funclib.sh: Fix comment about canonical location.
21102         * top/autopull.sh: Likewise.
21103         * top/autogen.sh: Likewise.
21104         * top/bootstrap: Likewise.
21106         Split bootstrap into autopull.sh and autogen.sh.
21107         * top/bootstrap-funclib.sh: New file, based on build-aux/bootstrap.
21108         * top/autopull.sh: New file, based on build-aux/bootstrap.
21109         * top/autogen.sh: New file, based on build-aux/bootstrap.
21110         * top/bootstrap: New file, based on build-aux/bootstrap.
21111         * top/gen-bootstrap.sed: New file.
21112         * Makefile (build-aux/bootstrap): New rule.
21113         (regen): Depend on it.
21114         * build-aux/bootstrap: Regenerated using "make build-aux/bootstrap".
21116 2022-07-24  Bruno Haible  <bruno@clisp.org>
21118         bootstrap: Obey another environment variable GNULIB_REFDIR.
21119         * build-aux/bootstrap (usage): Document option --gnulib-refdir and
21120         environment variable GNULIB_REFDIR.
21121         Accept option --gnulib-refdir.
21122         When GNULIB_SRCDIR is specified, verify that it denotes a directory.
21123         Use $GNULIB_REFDIR, not $GNULIB_SRCDIR, as argument to git's --reference
21124         option.
21125         Improve an error message.
21126         * NEWS: Mention the change.
21128 2022-07-23  Bruno Haible  <bruno@clisp.org>
21130         Fix a couple of ShellCheck warnings.
21131         * MODULES.html.sh (sed_escape_slash): Remove unused variable.
21132         * build-aux/bootstrap: Avoid computed printf format strings.
21133         * build-aux/do-release-commit-and-tag: Likewise.
21134         * build-aux/gendocs.sh: Likewise.
21135         * build-aux/declared.sh: Fix "unrecognized option" message.
21136         * gnulib-tool (supplied_opts): Remove unused variable.
21137         (--single-con): Remove redundant option recognition.
21138         * tests/test-parse-duration.sh (nl): Remove unused variable.
21139         * tests/test-update-copyright.sh: Use double-quotes instead of
21140         single-quotes.
21142 2022-07-23  Bruno Haible  <bruno@clisp.org>
21144         Avoid DoS vulnerability through unsafe default assignment.
21145         See https://www.shellcheck.net/wiki/SC2223 .
21146         * MODULES.html.sh (func_tmpdir): Surround default assignment with
21147         double-quotes.
21148         * build-aux/bootstrap: Likewise.
21149         * build-aux/csharpcomp.sh.in (func_tmpdir): Likewise.
21150         * build-aux/gendocs.sh: Likewise.
21151         * build-aux/libtool-next-version (func_tmpdir): Likewise.
21152         * config/srclist-update: Likewise.
21153         * gnulib-tool (func_tmpdir): Likewise.
21154         * posix-modules (func_tmpdir): Likewise.
21155         * tests/test-atexit.sh: Likewise.
21156         * tests/test-btoc32-1.sh: Likewise.
21157         * tests/test-btoc32-2.sh: Likewise.
21158         * tests/test-btowc1.sh: Likewise.
21159         * tests/test-btowc2.sh: Likewise.
21160         * tests/test-c-dtoastr.sh: Likewise.
21161         * tests/test-c-ldtoastr.sh: Likewise.
21162         * tests/test-c-snprintf.sh: Likewise.
21163         * tests/test-c-strcase.sh: Likewise.
21164         * tests/test-c-vasprintf.sh: Likewise.
21165         * tests/test-c-vsnprintf.sh: Likewise.
21166         * tests/test-c-xvasprintf.sh: Likewise.
21167         * tests/test-c32isalnum.sh: Likewise.
21168         * tests/test-c32isalpha.sh: Likewise.
21169         * tests/test-c32isblank.sh: Likewise.
21170         * tests/test-c32iscntrl.sh: Likewise.
21171         * tests/test-c32isdigit.sh: Likewise.
21172         * tests/test-c32isgraph.sh: Likewise.
21173         * tests/test-c32islower.sh: Likewise.
21174         * tests/test-c32isprint.sh: Likewise.
21175         * tests/test-c32ispunct.sh: Likewise.
21176         * tests/test-c32isspace.sh: Likewise.
21177         * tests/test-c32isupper.sh: Likewise.
21178         * tests/test-c32isxdigit.sh: Likewise.
21179         * tests/test-c32rtomb.sh: Likewise.
21180         * tests/test-c32snrtombs-1.sh: Likewise.
21181         * tests/test-c32snrtombs-2.sh: Likewise.
21182         * tests/test-c32snrtombs-3.sh: Likewise.
21183         * tests/test-c32snrtombs-4.sh: Likewise.
21184         * tests/test-c32srtombs-1.sh: Likewise.
21185         * tests/test-c32srtombs-2.sh: Likewise.
21186         * tests/test-c32srtombs-3.sh: Likewise.
21187         * tests/test-c32srtombs-4.sh: Likewise.
21188         * tests/test-c32stombs-1.sh: Likewise.
21189         * tests/test-c32stombs-2.sh: Likewise.
21190         * tests/test-c32stombs-3.sh: Likewise.
21191         * tests/test-c32stombs-4.sh: Likewise.
21192         * tests/test-closein.sh: Likewise.
21193         * tests/test-copy-acl.sh (func_tmpdir): Likewise.
21194         * tests/test-copy-file.sh (func_tmpdir): Likewise.
21195         * tests/test-dprintf-posix.sh: Likewise.
21196         * tests/test-execl.sh: Likewise.
21197         * tests/test-execle.sh: Likewise.
21198         * tests/test-execlp.sh: Likewise.
21199         * tests/test-execv.sh: Likewise.
21200         * tests/test-execve.sh: Likewise.
21201         * tests/test-execvp.sh: Likewise.
21202         * tests/test-execvpe.sh: Likewise.
21203         * tests/test-file-has-acl.sh (func_tmpdir): Likewise.
21204         * tests/test-fprintf-posix.sh: Likewise.
21205         * tests/test-init.sh: Likewise.
21206         * tests/test-iswdigit.sh: Likewise.
21207         * tests/test-iswxdigit.sh: Likewise.
21208         * tests/test-mbmemcasecmp1.sh: Likewise.
21209         * tests/test-mbmemcasecmp2.sh: Likewise.
21210         * tests/test-mbmemcasecmp3.sh: Likewise.
21211         * tests/test-mbmemcasecoll1.sh: Likewise.
21212         * tests/test-mbmemcasecoll2.sh: Likewise.
21213         * tests/test-mbmemcasecoll3.sh: Likewise.
21214         * tests/test-mbrtoc32-1.sh: Likewise.
21215         * tests/test-mbrtoc32-2.sh: Likewise.
21216         * tests/test-mbrtoc32-3.sh: Likewise.
21217         * tests/test-mbrtoc32-4.sh: Likewise.
21218         * tests/test-mbrtowc1.sh: Likewise.
21219         * tests/test-mbrtowc2.sh: Likewise.
21220         * tests/test-mbrtowc3.sh: Likewise.
21221         * tests/test-mbrtowc4.sh: Likewise.
21222         * tests/test-mbscasecmp.sh: Likewise.
21223         * tests/test-mbscasestr2.sh: Likewise.
21224         * tests/test-mbscasestr3.sh: Likewise.
21225         * tests/test-mbscasestr4.sh: Likewise.
21226         * tests/test-mbschr.sh: Likewise.
21227         * tests/test-mbscspn.sh: Likewise.
21228         * tests/test-mbsinit.sh: Likewise.
21229         * tests/test-mbsncasecmp.sh: Likewise.
21230         * tests/test-mbsnrtoc32s-1.sh: Likewise.
21231         * tests/test-mbsnrtoc32s-2.sh: Likewise.
21232         * tests/test-mbsnrtoc32s-3.sh: Likewise.
21233         * tests/test-mbsnrtoc32s-4.sh: Likewise.
21234         * tests/test-mbsnrtowcs1.sh: Likewise.
21235         * tests/test-mbsnrtowcs2.sh: Likewise.
21236         * tests/test-mbsnrtowcs3.sh: Likewise.
21237         * tests/test-mbsnrtowcs4.sh: Likewise.
21238         * tests/test-mbspbrk.sh: Likewise.
21239         * tests/test-mbspcasecmp.sh: Likewise.
21240         * tests/test-mbsrchr.sh: Likewise.
21241         * tests/test-mbsrtoc32s-1.sh: Likewise.
21242         * tests/test-mbsrtoc32s-2.sh: Likewise.
21243         * tests/test-mbsrtoc32s-3.sh: Likewise.
21244         * tests/test-mbsrtoc32s-4.sh: Likewise.
21245         * tests/test-mbsrtowcs1.sh: Likewise.
21246         * tests/test-mbsrtowcs2.sh: Likewise.
21247         * tests/test-mbsrtowcs3.sh: Likewise.
21248         * tests/test-mbsrtowcs4.sh: Likewise.
21249         * tests/test-mbsspn.sh: Likewise.
21250         * tests/test-mbsstr2.sh: Likewise.
21251         * tests/test-mbsstr3.sh: Likewise.
21252         * tests/test-mbstoc32s-1.sh: Likewise.
21253         * tests/test-mbstoc32s-2.sh: Likewise.
21254         * tests/test-mbstoc32s-3.sh: Likewise.
21255         * tests/test-mbstoc32s-4.sh: Likewise.
21256         * tests/test-nl_langinfo.sh: Likewise.
21257         * tests/test-parse-duration.sh (func_tmpdir): Likewise.
21258         * tests/test-perror.sh: Likewise.
21259         * tests/test-printf-posix.sh: Likewise.
21260         * tests/test-set-mode-acl.sh (func_tmpdir): Likewise.
21261         * tests/test-setlocale1.sh: Likewise.
21262         * tests/test-strtod1.sh: Likewise.
21263         * tests/test-strtold1.sh: Likewise.
21264         * tests/test-unicodeio2.sh: Likewise.
21265         * tests/test-unicodeio3.sh: Likewise.
21266         * tests/test-vasnprintf-posix2.sh: Likewise.
21267         * tests/test-vc-list-files-cvs.sh: Likewise.
21268         * tests/test-vc-list-files-git.sh: Likewise.
21269         * tests/test-vdprintf-posix.sh: Likewise.
21270         * tests/test-vfprintf-posix.sh: Likewise.
21271         * tests/test-vprintf-posix.sh: Likewise.
21272         * tests/test-wcrtomb.sh: Likewise.
21273         * tests/test-wcsnrtombs1.sh: Likewise.
21274         * tests/test-wcsnrtombs2.sh: Likewise.
21275         * tests/test-wcsnrtombs3.sh: Likewise.
21276         * tests/test-wcsnrtombs4.sh: Likewise.
21277         * tests/test-wcsrtombs1.sh: Likewise.
21278         * tests/test-wcsrtombs2.sh: Likewise.
21279         * tests/test-wcsrtombs3.sh: Likewise.
21280         * tests/test-wcsrtombs4.sh: Likewise.
21281         * tests/test-xprintf-posix.sh: Likewise.
21282         * tests/test-xstrtoimax.sh: Likewise.
21283         * tests/test-xstrtol.sh: Likewise.
21284         * tests/test-xstrtoll.sh: Likewise.
21285         * tests/test-xstrtoumax.sh: Likewise.
21286         * tests/test-yesno.sh: Likewise.
21287         * tests/unicase/test-locale-language.sh: Likewise.
21288         * tests/unicase/test-ulc-casecmp1.sh: Likewise.
21289         * tests/unicase/test-ulc-casecmp2.sh: Likewise.
21290         * tests/unicase/test-ulc-casecoll1.sh: Likewise.
21291         * tests/unicase/test-ulc-casecoll2.sh: Likewise.
21292         * tests/unigbrk/test-ulc-grapheme-breaks.sh: Likewise.
21293         * tests/unistdio/test-u16-vasnprintf2.sh: Likewise.
21294         * tests/unistdio/test-u16-vasnprintf3.sh: Likewise.
21295         * tests/unistdio/test-u32-vasnprintf2.sh: Likewise.
21296         * tests/unistdio/test-u32-vasnprintf3.sh: Likewise.
21297         * tests/unistdio/test-u8-vasnprintf2.sh: Likewise.
21298         * tests/unistdio/test-u8-vasnprintf3.sh: Likewise.
21299         * tests/unistdio/test-ulc-vasnprintf2.sh: Likewise.
21300         * tests/unistdio/test-ulc-vasnprintf3.sh: Likewise.
21301         * tests/uniwbrk/test-ulc-wordbreaks.sh: Likewise.
21302         * tests/uniwidth/test-uc_width2.sh: Likewise.
21304 2022-07-18  Bruno Haible  <bruno@clisp.org>
21306         bootstrap: Comments.
21307         * build-aux/bootstrap: Comment about two unused variables.
21309 2022-07-17  Bruno Haible  <bruno@clisp.org>
21311         doc: Update README.
21312         * doc/README: Fix stale links (reported by Tzvetelin Katchov). Clarify
21313         the relation to build-aux/gnu-web-doc-update.
21315 2022-07-14  Bruno Haible  <bruno@clisp.org>
21317         doc: Fix typo.
21318         Reported by Eric Gallager <egall@gwmail.gwu.edu> in
21319         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00045.html>.
21320         * doc/posix-functions/mmap.texi: Add parenthesis.
21322 2022-07-12  Paul Eggert  <eggert@cs.ucla.edu>
21324         parse-datetime: improve doc for TZ="<-07>7" etc.
21325         * doc/parse-datetime.texi (Specifying time zone rules):
21326         Give examples of POSIX TZ strings that specify UTC offsets (Bug#56524).
21328 2022-07-10  Bruno Haible  <bruno@clisp.org>
21330         sigsegv: Optimize stackvma implementation for AIX 7.
21331         Reported by Neha Jain <nehajain29@in.ibm.com> in
21332         <https://lists.gnu.org/archive/html/bug-m4/2022-06/msg00005.html>
21333         via Eric Blake.
21334         * lib/stackvma.c: For AIX, add implementation that uses /proc/$pid/map,
21335         based on lib/vma-iter.c.
21336         (sigsegv_get_vma): Use it on AIX 7 or higher.
21338 2022-07-10  Bruno Haible  <bruno@clisp.org>
21340         vma-iter: Add support for AIX 7.
21341         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on AIX.
21342         * lib/vma-iter.c (vma_iterate): Add code for AIX, known to work on
21343         AIX 7.
21344         * lib/get-rusage-as.c: Update comments.
21345         * lib/get-rusage-data.c: Likewise.
21346         * tests/test-get-rusage-as.c (main): Take into account the special
21347         address space organization on AIX in 32-bit mode.
21349 2022-07-10  Bruno Haible  <bruno@clisp.org>
21351         iconv: Define a summary result.
21352         Reported by Simon Josefsson in
21353         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00020.html>.
21354         * m4/iconv.m4 (AM_ICONV): Define also am_cv_func_iconv_summary.
21356 2022-07-10  Bruno Haible  <bruno@clisp.org>
21358         iconv: Remove obsolete comment.
21359         * m4/iconv.m4 (AM_ICONV): Remove comment that is obsolete since
21360         2020-08-16.
21362 2022-07-10  Bruno Haible  <bruno@clisp.org>
21364         announce-gen: Fix internationalization in verification instructions.
21365         * build-aux/announce-gen: Set LC_ALL, not LANG, to "C", to force English
21366         output from gpg.
21368 2022-07-10  Bruno Haible  <bruno@clisp.org>
21370         lib-symbol-visibility: Improve documentation.
21371         * doc/lib-symbol-visibility.texi: Tweak BUILDING_SHARED snippet.
21373 2022-07-10  Bruno Haible  <bruno@clisp.org>
21375         doc: Mark Minix as no longer tested.
21376         Rationale: No commits since 2018 at https://git.minix3.org/.
21377         Reported by Paul Eggert and Jim Meyering in
21378         <https://lists.gnu.org/archive/html/grep-devel/2022-07/msg00027.html>.
21379         * doc/gnulib-intro.texi (Supported Platforms): Mark Minix as no longer
21380         tested.
21382 2022-07-09  Jim Meyering  <meyering@fb.com>
21384         announce-gen: better diagnose some usage errors
21385         * build-aux/announce-gen (main): Erroneous usage would elicit a
21386         misleading diagnostic. When --gnulib-version=V was specified:
21387         - without --bootstrap_tools, or
21388         - with --bootstrap_tools, but without listing "gnulib" as a tool
21389         we would give an inappropriate diagnostic. Now, each diagnostic
21390         is tailored to the precise erroneous condition.
21391         Reported by Bruno Haible in
21392         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00025.html
21394 2022-07-09  Simon Josefsson  <simon@josefsson.org>
21396         git-version-gen: Doc fix.
21397         Reported by Reuben Thomas <rrt@sc3d.org> in
21398         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00012.html>.
21399         * build-aux/git-version-gen (usage): Replace incorrect text with
21400         bug report instructions.
21402 2022-07-09  Simon Josefsson  <simon@josefsson.org>
21404         announce-gen: Improve GnuPG verification instructions.
21405         * build-aux/announce-gen: Add GPG fingerprint to output, and a
21406         pointer to GNU keyring.
21408 2022-07-08  Simon Josefsson  <simon@josefsson.org>
21410         lib-symbol-visibility: Improve documentation.
21411         * doc/lib-symbol-visibility.texi: Include BUILDING_SHARED snippet
21412         suggested by Bruno Haible.
21414 2022-07-04  Bruno Haible  <bruno@clisp.org>
21416         havelib: Fix 'configure --help' output.
21417         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Fix m4 quoting bug.
21419 2022-07-03  Bruno Haible  <bruno@clisp.org>
21421         lib-symbol-visibility: Improve documentation.
21422         Reported by Vivien Kraus <vivien@planete-kraus.eu> in
21423         <https://lists.gnu.org/archive/html/bug-gnulib/2022-06/msg00093.html>.
21424         * doc/lib-symbol-visibility.texi: List the platforms. Extend the
21425         LIBFOO_DLL_EXPORTED to work also with mingw and also with
21426         --disable-shared.
21428 2022-07-03  Bruno Haible  <bruno@clisp.org>
21430         supersede: Support the file name "/dev/null" on native Windows.
21431         * lib/supersede.c (open_supersede): On native Windows, map "/dev/null"
21432         to "NUL".
21434 2022-06-23  Jim Meyering  <meyering@fb.com>
21436         maint.mk: fix syntax-check for unnecessary hash.h header use
21437         * top/maint.mk (_hash_re): Correct the regexp. It had two problems:
21438         - lacked the "hash_" prefix, so would match non-uses
21439         - failed to detect uses of the hash_x?initialize functions
21440         The former led to an excess/unneeded use of hash.h in coreutils' cut.c.
21441         The latter would have led to a FP "not needed" report for copy.c.
21443 2022-06-22  Bruno Haible  <bruno@clisp.org>
21445         fchmodat: Fix test failure on native Windows.
21446         * modules/fchmodat (Depends-on): Add 'chmod'.
21448 2022-06-22  Bruno Haible  <bruno@clisp.org>
21450         chmod: Add tests.
21451         * tests/test-chmod.c: New file, based on tests/test-lchmod.c.
21452         * modules/chmod-tests: New file.
21454         chmod: New module.
21455         * lib/sys_stat.in.h (chmod): Declare when GNULIB_CHMOD is 1.
21456         * lib/chmod.c: New file, based on lib/lchmod.c.
21457         * m4/chmod.m4: New file, based on m4/fchmodat.m4.
21458         * m4/sys_stat_h.m4 (gl_SYS_STAT_H): Test whether chmod is declared.
21459         (gl_SYS_STAT_H_REQUIRE_DEFAULTS): Initialize GNULIB_CHMOD.
21460         (gl_SYS_STAT_H_DEFAULTS): Initialize REPLACE_CHMOD.
21461         * modules/sys_stat (Makefile.am): Substitute GNULIB_CHMOD,
21462         REPLACE_CHMOD.
21463         * modules/chmod: New file, based on modules/lchmod.
21464         * doc/posix-functions/chmod.texi: Mention the new module and the
21465         problems on IRIX and Windows.
21467 2022-06-21  Bruno Haible  <bruno@clisp.org>
21469         lchmod: Simplify.
21470         * lib/lchmod.c: Remove unnecessary include, obsolete since 2020-02-23.
21472 2022-06-20  Bruno Haible  <bruno@clisp.org>
21474         javacomp-script, javaexec-script: Add support for disabling Java.
21475         * m4/javacomp.m4 (gt_JAVACOMP_DISABLED): New macro.
21476         * m4/javaexec.m4 (gt_JAVAEXEC_DISABLED): New macro.
21478 2022-06-19  Paul Eggert  <eggert@cs.ucla.edu>
21480         lchmod: port back to AIX 7.2
21481         Problem reported by Bruno Haible in:
21482         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00075.html
21483         * lib/lchmod.c: Include string.h, for strlen.
21484         (lchmod): Do not depend on HAVE_READLINK since we now depend on
21485         the readlink module.  Check for AIX 7.2 bug.
21486         * m4/lchmod.m4 (gl_PREREQ_LCHMOD): Do not check for readlink
21487         since we now depend on the readlink module.
21488         * modules/lchmod (Depends-on): Depend on readlink.
21490         fchmodat: pacify gcc -Wunused-variable
21491         Problem reported by Bruno Haible in:
21492         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00075.html
21493         * lib/fchmodat.c (fchmodat): Remove unused local.
21495 2022-06-19  Bruno Haible  <bruno@clisp.org>
21497         getlogin, getlogin_r tests: Really avoid test failure.
21498         Reported by Letu Ren <fantasquex@gmail.com> in
21499         <https://lists.gnu.org/archive/html/bug-gnulib/2022-06/msg00037.html>.
21500         * tests/test-getlogin.h (test_getlogin_result): Parse the contents of
21501         /proc/self/loginuid as an unsigned integer.
21503 2022-06-12  Paul Eggert  <eggert@cs.ucla.edu>
21505         fchmodat: port better to MS-Windows etc.
21506         MS-Windows problem reported by Bruno Haible in:
21507         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00041.html
21508         Although I don’t use MS-Windows I see some related fstatat etc.
21509         problems and am trying to fix them with this further patch.
21510         * lib/fchmodat.c (fchmodat):
21511         * lib/lchmod.c (lchmod):
21512         * lib/lchown.c (lchown)
21513         [!HAVE_LCHOWN && HAVE_CHOWN && !CHOWN_MODIFIES_SYMLINK]:
21514         * lib/renameatu.c (renameatu)
21515         [HAVE_RENAME && RENAME_TRAILING_SLASH_SOURCE_BUG]:
21516         Use readlinkat/readlink instead of fstatat/lstat to test merely
21517         whether a string names a symlink, as this avoids problems
21518         with EOVERFLOW.  Also, I hope it works around the MS-Windows
21519         issues that Bruno noted.
21520         * m4/fchmodat.m4 (gl_PREREQ_FCHMODAT):
21521         Check for readlinkat, not lchmod.
21522         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Do not require AC_CANONICAL_HOST
21523         or check for lstat.
21524         (gl_PREREQ_LCHMOD): Check for readlink.
21525         * modules/lchown (Depends-on): Add readlink.  Do not depend on
21526         lstat merely because !HAVE_LCHOWN.
21527         * modules/renameatu (Depends-on): Add fstatat, readlinkat.
21529 2022-06-12  Bruno Haible  <bruno@clisp.org>
21531         doc: Update O_PATH platforms list.
21532         * doc/posix-headers/fcntl.texi: Update O_PATH platforms list.
21534 2022-06-11  Paul Eggert  <eggert@cs.ucla.edu>
21536         fcntl: document O_PATH
21537         * doc/posix-headers/fcntl.texi: Mention O_PATH.
21539         fchmodat: port to old Linux kernel + newer headers
21540         Problem reported by Lance Fredrickson in:
21541         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00038.html
21542         * lib/fchmodat.c (fchmodat):
21543         * lib/lchmod.c (lchmod): Do not rely on AT_EMPTY_PATH as to
21544         whether syscalls work on ""; instead, if a call fails with
21545         ENOENT assume that those syscalls do not work.
21546         Do not use fstatat to determine whether a file is a symlink,
21547         as this has problems with EOVERFLOW.  Use readlinkat instead,
21548         and if it fails with EINVAL then the file is not a symlink.
21549         Remove #if tests on __linux__ || __ANDROID__ || __CYGWIN__
21550         as this has been a maintenance hassle and it’s unlikely
21551         these days that a new platform would #define O_PATH without also
21552         either supporting /proc or keeping it absent.
21553         * modules/fchmodat (Depends-on): Remove fstatat.
21554         There should be no need for either fchmodat or lchmod to depend on
21555         readlinkat, since they use readlinkat only in contexts where it
21556         should work without Gnulib intervention.
21558 2022-06-06  Bruno Haible  <bruno@clisp.org>
21560         fopen-gnu: Make this module work again (regression 2022-01-03).
21561         Reported by Nelson H. F. Beebe <beebe@math.utah.edu> in
21562         <https://lists.gnu.org/archive/html/platform-testers/2022-04/msg00005.html>.
21563         * modules/fopen-gnu (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
21565 2022-06-06  Bruno Haible  <bruno@clisp.org>
21567         getlogin, getlogin_r tests: Avoid test failure in specific environments.
21568         Reported by Letu Ren <fantasquex@gmail.com> in
21569         <https://lists.gnu.org/archive/html/bug-gnulib/2022-06/msg00001.html>.
21570         * modules/getlogin-tests (Depends-on): Add stdbool.
21571         * modules/getlogin_r-tests (Depends-on): Likewise.
21572         * tests/test-getlogin.h: Include stdbool.h.
21573         (test_getlogin_result): On Linux, skip the test if /proc/self/loginuid
21574         contains "-1".
21576 2022-06-05  Bruno Haible  <bruno@clisp.org>
21578         doc: Add section to attract more people towards the GNU project.
21579         Inspired by a suggestion from José E. Marchesi <jemarch@gnu.org> on
21580         the gnu-prog-discuss mailing list.
21581         * doc/join-gnu.texi: New file.
21582         * doc/gnulib-readme.texi: Include it.
21584 2022-06-05  Bruno Haible  <bruno@clisp.org>
21586         doc: Fix warnings about regex chapter structure (regression 2022-05-15).
21587         * doc/regex.texi (GNU Operators): Fix menu.
21589 2022-06-04  Paul Eggert  <eggert@cs.ucla.edu>
21591         regex-quote: \} -> } in EREs
21592         * lib/regex-quote.c (ere_special): Don’t use \} in EREs,
21593         as POSIX says the interpretation is undefined.
21594         * tests/test-regex-quote.c (test_bre, test_ere):
21595         Add tests for }.
21597         dfa: do not warn about \] and \}
21598         * lib/dfa.c (lex): Do not warn about \] and \}, since they’re
21599         surely universally supported even though POSIX says their
21600         interpretation is undefined.
21602 2022-06-03  Paul Eggert  <eggert@cs.ucla.edu>
21604         regex-quote: \] -> ] in EREs and BREs
21605         * build-aux/bootstrap:
21606         * build-aux/bootstrap.conf (gettext_external):
21607         * check-AC_LIBOBJ:
21608         * lib/regex-quote.c (bre_special, ere_special):
21609         * gnulib-tool (func_modules_transitive_closure)
21610         (func_emit_autoconf_snippet, func_import, func_create_testdir):
21611         * tests/test-regex-quote.c (test_bre, test_ere):
21612         * top/maint.mk (longopt_re, gpg_key_ID):
21613         Don’t use \] in BREs and EREs, as POSIX says the interpretation is
21614         undefined.
21616         filevercmp: don’t treat entire filename as suffix
21617         Problem reported by Artém S. Tashkinóv in:
21618         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00012.html
21619         * lib/filevercmp.c (file_prefixlen): When stripping
21620         (\.[A-Za-z~][A-Za-z0-9~]*)*$ suffixes, do not strip
21621         the entire file name.
21622         * tests/test-filevercmp.c (examples): Adjust to match new behavior.
21624 2022-06-03  Bruno Haible  <bruno@clisp.org>
21626         setlocale: Update after Turkey changed its name.
21627         * lib/setlocale.c: Update comments.
21629 2022-05-25  Karl Berry  <karl@freefriends.org>
21631         doc: regex.texi deleted the node GNU Emacs Operators
21632         * doc/gnulib.texi (Regular expression): remove "GNU Emacs Operators"
21633         from the @menu, since the node no longer exists in regex.texi.
21635 2022-05-24  Paul Eggert  <eggert@cs.ucla.edu>
21637         dfa: new options DFA_STAR_WARN, DFA_PLUS_WARN
21638         This lets ‘grep -E '(*a|+b)'’ warn about the * and the +.
21639         * lib/dfa.h (DFA_STAR_WARN, DFA_PLUS_WARN): New flags.
21640         * lib/dfa.c (lex): Support them.
21642 2022-05-23  Paul Eggert  <eggert@cs.ucla.edu>
21644         dfa: '\n' is not governed by RE_LIMITED_OPS
21645         * lib/dfa.c (lex): Pay no attention to RE_LIMITED_OPS when
21646         deciding how to parse '\n', since regcomp.c doesn’t.
21648         dfa: new option DFA_STRAY_BACKSLASH_WARN
21649         This is for grep, which wants to warn about stray backslashes that
21650         lead to unspecified behavior.  For example, "grep -oi '\a'"
21651         surprisingly is not equivalent to "grep -oi 'a'", so the stray
21652         backslash should be warned about.
21653         * lib/dfa.c: Include wctype.h, for iswprint and iswspace.
21654         (lex): Add support for DFA_STRAY_BACKSLASH_WARN.
21655         * lib/dfa.h (DFA_STRAY_BACKSLASH_WARN): New constant.
21657         dfa: new option DFA_CONFUSING_BRACKETS_ERROR
21658         This is for grep, which wants [:alpha:] to be an error
21659         at the top level.
21660         * lib/dfa.c (struct regex_syntax): New member dfaopts,
21661         replacing anchor.  All uses changed.
21662         (parse_bracket_exp): Error, not warn, if DFA_CONFUSING_BRACKETS_ERROR.
21663         * lib/dfa.h (DFA_CONFUSING_BRACKETS_ERROR): New constant.
21665 2022-05-21  Paul Eggert  <eggert@cs.ucla.edu>
21667         strstr-simple: pacify GCC 12.1
21668         * lib/str-two-way.h (two_way_long_needle): Pacify GCC 12.1
21669         -Wsuggest-attribute=pure (x86-64, -O2).
21671 2022-05-20  Paul Eggert  <eggert@cs.ucla.edu>
21673         dfa: steer cleer of POSIX-reserved symbols
21674         * lib/dfa.c (str_eq): Rename from streq.  All uses changed.
21675         (c_isdigit): Rename from isasciidigit.  The function worked in
21676         EBCDIC so it wasn’t ASCII-specific anyway.  All uses changed.
21678 2022-05-17  Paul Eggert  <eggert@cs.ucla.edu>
21680         parse-datetime: support 'J' military time zone
21681         Requested by Brian Inglis in:
21682         https://savannah.gnu.org/support/?110644
21683         * lib/parse-datetime.y (parser_control): New member J_zones_seen.
21684         (item): New item 'J'.
21685         (military_table): Add 'J'.
21686         (parse_datetime_body): Set and use J_zones_seen.
21687         * tests/test-parse-datetime.c (main): Test "J".
21689 2022-05-15  Reuben Thomas  <rrt@sc3d.org>
21691         doc: Update regex documentation to match implementation.
21692         * doc/regex.texi: remove Emacs-specific documentation; match code.
21693         Remove mention of both Emacs and non-Emacs syntax tables, as these
21694         are no longer supported by the code.  Document the word character
21695         class (alnum + _).  Add documentation for \s and \S.  Replace
21696         mentions of #defining emacs with RE_NO_GNU_OPS (which takes effect
21697         in the opposite sense); merge the node “GNU Emacs Operators” into
21698         “GNU Operators”.  For \` and \', refer to the “whole string” rather
21699         than the (Emacs) “buffer”.
21701 2022-05-15  Bruno Haible  <bruno@clisp.org>
21703         string, wchar: Fix compilation error on MSVC (regression 2021-09-07).
21704         * lib/string.in.h (free): For MSVC, add the dllimport specification if
21705         the MSVC headers have it.
21706         * lib/wchar.in.h (free): Likewise.
21708 2022-05-14  Bruno Haible  <bruno@clisp.org>
21710         glob tests: Fix a warning (regression from 2022-03-23).
21711         * tests/test-glob.c: Include <fcntl.h>.
21712         * modules/glob-tests (Depends-on): Add fcntl-h.
21714 2022-05-14  Bruno Haible  <bruno@clisp.org>
21716         termcap: Fix link error when no suitable library is found.
21717         * m4/termcap.m4 (gl_TERMCAP_BODY): If no suitable library is found,
21718         set LIBTERMCAP and LTLIBTERMCAP to empty.
21720 2022-05-13  Paul Eggert  <eggert@cs.ucla.edu>
21722         dfa: fix bug with ‘.’ and UTF-8 Hangul Syllables
21723         This fixes a bug introduced in 2019-12-18T05:41:27Z!eggert@cs.ucla.edu,
21724         an earlier patch that fixed dfa.c to not match invalid UTF-8.
21725         Unfortunately that patch had a couple of typos when dfa.c is
21726         matching against the regular expression ‘.’ (dot).  One typo
21727         caused dfa.c to incorrectly reject the valid UTF-8 sequences
21728         (ED)(90-9F)(80-BF) corresponding to U+D400 through U+D7FF, which
21729         are some Hangul Syllables and Hangul Jamo Extended-B.  The other
21730         typo caused dfa.c to incorrectly reject the valid sequences
21731         (F4)(88-8F)(80-BF)(80-BF) which correspond to U+108000 through
21732         U+10FFFF (Supplemental Private Use Area plane B).
21733         * lib/dfa.c (utf8_classes): Fix typos.
21734         * tests/test-dfa-match.sh: Test the fix.
21736 2022-05-12  Paul Eggert  <eggert@cs.ucla.edu>
21738         manywarnings: update C warnings for GCC 12
21739         Adjust for C programs compiled by GCC 12.
21740         (A C++ expert still needs to look at manywarnings-c++.m4.)
21741         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 12.
21742         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wbidi-chars=any,ucn
21743         and -Wuse-after-free=3.  Although not enabled by -Wall or -Wextra
21744         they seem suitable for Gnulib-using C code.
21746 2022-05-11  Paul Eggert  <eggert@cs.ucla.edu>
21748         parse-datetime: remove Emacs cruft
21749         * lib/parse-datetime.y: Remove an ‘ifdef emacs’.  Emacs has never
21750         used this module.  The module is derived from code taken from
21751         Emacs, but that code was removed from Emacs in the 1990s.
21753 2022-05-11  Bruno Haible  <bruno@clisp.org>
21755         alloca: Remove old code for Emacs, unused since 2009.
21756         Reported by Reuben Thomas <rrt@sc3d.org> in
21757         <https://lists.gnu.org/archive/html/bug-gnulib/2022-05/msg00032.html>.
21758         * lib/alloca.c: Remove Emacs specific code.
21760 2022-05-05  Paul Eggert  <eggert@cs.ucla.edu>
21762         libc-config: update to match cdefs
21763         * lib/libc-config.h (__attribute_alloc_align__)
21764         (__attribute_maybe_unused, __fortified_attr_access)
21765         (__glibc_fortify, __glibc_fortify_n, __glibc_likely)
21766         (__glibc_safe_len_cond, __glibc_safe_or_unknown_len)
21767         (__glibc_unsafe_len, __glibc_unsigned_or_positive, __wur):
21768         Undef these too, since lib/cdefs.h now defines them
21769         unconditionally.
21771         cdefs: merge from glibc
21772         * lib/cdefs.h (__glibc_safe_or_unknown_len):
21773         Use glibc’s newer version.
21775 2022-05-02  Paul Eggert  <eggert@cs.ucla.edu>
21777         gettime-res: help the compiler
21778         * lib/gettime-res.c (gettime_res): Pacify GCC versions that
21779         incorrectly complain about earlier.tv_sec not being initialized.
21780         Let GCC know that gcd args are always positive.
21782         af_alg: port to Ubuntu 22.04
21783         Without this patch, maintainer builds of coreutils fail on Ubuntu
21784         22.04 with diagnostics like "./lib/gl_openssl.h:79:1: error:
21785         'MD5_Init' is deprecated: Since OpenSSL 3.0
21786         [-Werror=deprecated-declarations]".  From
21787         <https://wiki.openssl.org/index.php/OpenSSL_1.1.0_Changes>
21788         it appears that Gnulib needs to either define OPENSSL_API_COMPAT
21789         to a version less than 3.0, or use a compatibility layer, or
21790         assume OpenSSL 1.1.0 or later.  The simplest workaround is to
21791         define OPENSSL_API_COMPAT for 1.1.1, the oldest OpenSSL release
21792         still supported.  A better fix would be to rewrite the code to
21793         assume OpenSSL 1.1.1 or later, and stop using the older API.
21794         * lib/md5.h, lib/sha1.h, lib/sha256.h, lib/sha512.h, lib/sm3.h:
21795         Define OPENSSL_API_COMPAT to 0x10101000L to suppress
21796         the deprecation warnings on Ubuntu 22.04.
21798 2022-05-01  Paul Eggert  <eggert@cs.ucla.edu>
21800         vasnprintf: Simplify. Reduce binary code size.
21801         * lib/vasnprintf.c (VASNPRINTF): Coalesce cleanup code.
21803         vasnprintf: Simplify 'result' variable.
21804         * lib/vasnprintf.c (VASNPRINTF): Simplify initialization and test of
21805         'result' variable.
21807         vasnprintf: Simplify a free() call.
21808         * lib/vasnprintf.c (divide): Just call
21809         free (x) instead of doing ‘if (x != NULL) free (x);’.
21811 2022-04-30  Bruno Haible  <bruno@clisp.org>
21813         string: Avoid syntax error on glibc systems with GCC 11.
21814         Reported by Tom Tromey <tromey@adacore.com> in
21815         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00075.html>
21816         and by Satadru Pramanik <satadru@umich.edu> in
21817         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00076.html>.
21818         * lib/string.in.h (strndup): Don't rededeclare strndup if it is defined
21819         as a macro.
21821 2022-04-28  Simon Marchi  <simon.marchi@efficios.com>  (tiny change)
21823         stdlib: Fix error in C++ mode on glibc systems (regr. 2022-04-13).
21824         * lib/stdlib.in.h (free): Add exception specification like glibc does.
21826 2022-04-28  Paul Eggert  <eggert@cs.ucla.edu>
21828         glob: improve config and test cleanup
21829         Config problem reported by Benno Schulenberg in:
21830         https://lists.gnu.org/r/bug-gnulib/2022-04/msg00071.html
21831         * m4/glob.m4 (gl_GLOB): Clean up temporary file.
21832         Also, name it conf$$-file not conf-file, so it’s cleaned
21833         up on interrupt.
21834         * modules/glob-tests (MOSTLYCLEANFILES):
21835         Append test-glob.tglobfile, test-glob.tgloblink[123].
21837 2022-04-26  Paul Eggert  <eggert@cs.ucla.edu>
21839         glob: port to NetBSD 9.2
21840         Problem reported by Benno Schulenberg in:
21841         https://lists.gnu.org/r/bug-gnulib/2022-04/msg00052.html
21842         * doc/posix-functions/dirfd.texi: Document NetBSD 9.2 portability
21843         bugs.  Remove an old comment about errno that is no longer true
21844         of POSIX 2018.
21845         * lib/glob.c (glob_in_dir): Convert dirfd arg from void *
21846         to DIR * before passing it to dirfd.
21848 2022-04-21  Paul Eggert  <eggert@cs.ucla.edu>
21850         regex: match [...---...] like V7 grep
21851         Problem reported by Arnold Robbins in:
21852         https://bugs.gnu.org/20657
21853         https://lists.gnu.org/r/bug-gnulib/2022-04/msg00053.html
21854         * lib/regcomp.c (peek_token_bracket): Let [...---...] match '-'.
21855         This is an extension to POSIX, and matches V7 Unix grep.
21857 2022-04-20  Paul Eggert  <eggert@cs.ucla.edu>
21859         backupfile: fix bug when renaming simple backups
21860         * lib/backupfile.c (backupfile_internal): Fix bug when RENAME
21861         and when doing simple backups.  Problem reported by Steve Ward in:
21862         https://bugs.gnu.org/55029
21864         gettime-res: more-robust sampling
21865         * lib/gettime-res.c (gettime_res): If adjacent timestamps are
21866         identical search for a differing timestamp.  Also, stop collecting
21867         samples thereafter since they surely won’t help.
21869 2022-04-19  Paul Eggert  <eggert@cs.ucla.edu>
21871         Port _GL_HAS_C_ATTRIBUTE to pedantic gcc -std=c99
21872         * m4/gnulib-common.m4 (_GL_HAS_C_ATTRIBUTE):
21873         Disable -Wpedantic if using __has_c_attribute and this is not C2x.
21875         verify: port to pedantic gcc -std=c99
21876         * lib/verify.h (_GL_VERIFY): If we lack both _Static_assert and
21877         static_assert, suppress -Wnexted-externs.
21879         gettime-res: add tests
21880         * modules/gettime-res-tests, tests/test-gettime-res.c: New files.
21882 2022-04-16  Paul Eggert  <eggert@cs.ucla.edu>
21884         verify: port to Mac OS 10.7.5
21885         Mac OS 10.7.5 clang sets __clang_major__ to 4 even though it was
21886         derived from Clang 3.2.  Problem reported by Werner Lemberg in:
21887         https://lists.gnu.org/r/emacs-devel/2022-04/msg00779.html
21888         * lib/verify.h (_GL_HAVE__STATIC_ASSERT): Don’t define to 1
21889         when __clang_major__ == 4 && !__cplusplus
21890         && __STDC_VERSION__ < 201112L && !defined __STRICT_ANSI__.
21892 2022-04-15  Bruno Haible  <bruno@clisp.org>
21894         sigsegv: Fix compilation error on arceb CPUs.
21895         Reported by Fabrice Fontaine <fontaine.fabrice@gmail.com> in
21896         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00028.html>.
21897         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Treat the 'arc' variants
21898         like 'arc'.
21900 2022-04-13  Bruno Haible  <bruno@clisp.org>
21902         string, wchar: Fix error in C++ mode on glibc systems with clang.
21903         * lib/string.in.h (free): Add exception specification like glibc does.
21904         * lib/wchar.in.h (free): Likewise.
21906 2022-04-13  Bruno Haible  <bruno@clisp.org>
21908         string: Fix errors in C++ mode on glibc systems with clang.
21909         * lib/string.in.h (memchr, memrchr, rawmemchr, strchrnul, strpbrk,
21910         strstr, strcasestr): Use _GL_CXXALIASWARN1 also with clang, and add
21911         exception specification.
21913 2022-04-13  Bruno Haible  <bruno@clisp.org>
21915         math: Fix errors in C++ mode on glibc systems with clang.
21916         * lib/math.in.h (GNULIB_NAMESPACE_LACKS_ISFINITE,
21917         GNULIB_NAMESPACE_LACKS_ISINF, GNULIB_NAMESPACE_LACKS_ISNAN,
21918         GNULIB_NAMESPACE_LACKS_SIGNBIT): New macros.
21919         * tests/test-math-c++.cc (isfinite): Skip test if
21920         GNULIB_NAMESPACE_LACKS_ISFINITE is 1.
21921         (isinf): Skip test if GNULIB_NAMESPACE_LACKS_ISINF is 1.
21922         (isnan): Skip test if GNULIB_NAMESPACE_LACKS_ISNAN is 1.
21923         (signbit): Skip test if GNULIB_NAMESPACE_LACKS_SIGNBIT is 1.
21925 2022-04-08  Paul Eggert  <eggert@cs.ucla.edu>
21927         libgmp: pacify Clang too
21928         * lib/mini-gmp-gnulib.c [NDEBUG]: Also use -Wunused-variable if clang.
21929         Problem reported for Emacs by Mattias Engdegård.
21931 2022-04-04  Paul Eggert  <eggert@cs.ucla.edu>
21933         init.sh: don’t assume gzip
21934         * tests/init.sh (rand_bytes_): Don’t assume gzip is installed.
21935         I found this while testing gzip installation on a platform where I
21936         had removed the installed gzip.  gzip is executed only on
21937         platforms lacking mktemp and /dev/urandom so this code is rarely
21938         used; however, these platforms might also lack gzip since gzip
21939         is neither specified by POSIX or required by the GNU Coding Standards.
21941 2022-03-30  Paul Eggert  <eggert@cs.ucla.edu>
21943         glob: sync better with glibc
21944         * lib/glob.c (dirfd) [_LIBC]: Use #undef instead of #ifdef.
21945         Problem reported by DJ Delorie.
21947 2022-03-23  Paul Eggert  <eggert@cs.ucla.edu>
21949         glob: test for glibc bug 25659
21950         https://sourceware.org/bugzilla/show_bug.cgi?id=25659
21951         * m4/glob.m4 (gl_GLOB): Replace glob if it has bug 25659.
21952         * tests/test-glob.c (main): Test for glibc bug 25659.
21954         glob: fix symlink and // issues; improve speed
21955         * lib/glob.c: Include fcntl.h.
21956         (dirfd) [_LIBC]: New macro.
21957         (GLOB_STAT64, GLOB_LSTAT64): Remove.  Replace all uses with ...
21958         (GLOB_FSTATAT64): ... this new macro.
21959         (glob_in_dir): Treat DT_LNK like DT_UNKNOWN.
21960         Use directory-relative fstatat unless GLOB_ALTDIRFUNC, or dirfd fails.
21961         Avoid duplicate strlen (directory).
21962         Work even if directory is "/", without turning it into "//".
21963         Use a scratch buffer instead of by-hand alloca stuff.
21964         Use mempcpy and memcpy instead of stpcpy and strcpy.
21965         * modules/glob (Depends-on): Add dirfd, fstatat.  Remove stat.
21966         (License): Change from LGPLv2+ to GPL, since it depends on
21967         fstatat.
21969 2022-03-23  DJ Delorie  <dj@redhat.com>
21971         glob: resolve DT_UNKNOWN via is_dir
21973         The DT_* values returned by getdents (readdir) are only hints and
21974         not required.  In fact, some Linux filesystems return DT_UNKNOWN
21975         for most entries, regardless of actual type.  This causes make
21976         to mis-match patterns with a trailing slash (via GLOB_ONLYDIR)
21977         (see make's functions/wildcard test case).  Thus, this patch
21978         detects that case and uses is_dir() to make the type known enough
21979         for proper operation.
21981         Performance in non-DT_UNKNOWN cases is not affected.
21983         The lack of DT_* is a well known issue on older XFS installations
21984         (for example, RHEL 7 and 8, Fedora 28) but can be recreated by
21985         creating an XFS filesystem with flags that mimic older behavior:
21987         $ fallocate -l 10G /xfs.fs
21988         $ mkfs.xfs -n ftype=0 -m crc=0 -f /xfs.fs
21989         $ mkdir /xfs
21990         $ mount -o loop /xfs.fs /xfs
21992 2022-03-20  Jim Meyering  <meyering@fb.com>
21994         maint: bootstrap: split a too-long line
21995         * build-aux/bootstrap (git_modules_config): Split longer-than-80 line.
21997 2022-03-14  Simon Josefsson  <simon@josefsson.org>
21999         announce-gen: Modernize GnuPG key retrieval suggestions.  Based on
22000         patch by Darshit Shah in:
22001         https://lists.gnu.org/archive/html/bug-gnulib/2022-03/msg00022.html
22002         * build-aux/announce-gen (usage): Add --gpg-key-email and
22003         --gpg-keyring-url.
22004         (main): Support the new options.
22005         (main): Don't suggest 'gpg --keyserver' since the situation with
22006         public key servers is complicated and GnuPG version dependent.
22008         maintainer-makefile: Improve GnuPG announce-gen options.
22009         * top/maint.mk (gpg_key_emil): New variable.
22010         (gpg_keyring_url): New variable.
22011         (announcement): Pass them as --gpg-key-email and
22012         --gpg-keyring-url.
22014 2022-03-13  Ben Pfaff  <blp@cs.stanford.edu>
22016         Document Automake 1.14 requirement in NEWS, too, since it had been
22017         documented there before for the Automake 1.11 requirement.
22018         * NEWS: Mention the change.
22020 2022-03-13  Bruno Haible  <bruno@clisp.org>
22022         sigsegv: Add support for Linux/PowerPC (32-bit) with musl libc.
22023         Reported by Khem Raj <raj.khem@gmail.com> in
22024         <https://lists.gnu.org/archive/html/m4-patches/2022-03/msg00000.html>.
22025         * src/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): In the Linux/PowerPC
22026         32-bit case, handle musl libc differently.
22027         * modules/sigsegv (Files): Add m4/musl.m4.
22028         (configure.ac): Invoke gl_MUSL_LIBC.
22030 2022-03-11  Paul Eggert  <eggert@cs.ucla.edu>
22032         regex: fix double-free
22033         * lib/regex_internal.c (re_dfa_add_node): Don’t free storage
22034         twice if an allocation fails.
22036         regex: fix minor over-allocation
22037         * lib/regexec.c (push_fail_stack): Fix off-by-one error that
22038         over-allocated the stack.
22040         regex: fix free_fail_stack undefined behavior
22041         * lib/regexec.c (push_fail_stack): Don’t increment number of
22042         re_fail_stack_t entries until after successful allocation.  This
22043         prevents a crash if re_realloc or re_malloc fails here, and a
22044         later free_fail_stack examines regs or a later pop_fail_stack
22045         examines node.  Problem discovered by Coverity scan sent
22046         2022-03-11 11:03:52Z.
22048 2022-03-10  Paul Eggert  <eggert@cs.ucla.edu>
22050         fts: revert change to use AT_NO_AUTOMOUNT
22051         * NEWS: Don’t mention AT_NO_AUTOMOUNT.
22052         * lib/fts.c (fts_stat): Don’t use AT_NO_AUTOMOUNT, as
22053         it has no effect with fstatat.
22055 2022-03-09  Paul Eggert  <eggert@cs.ucla.edu>
22057         statat: now obsolete
22058         * lib/openat.h (statat, lstatat): Now deprecated.
22059         All uses removed, and replaced with fstatat.
22060         * modules/statat: Mark as obsolete, because it’s confusing:
22061         it’s not clear whether it should use AT_NO_AUTOMOUNT,
22062         which is implied by stat and by lstat, but not by fstatat.
22063         * tests/test-statat.c: Disable deprecated-declarations warnings.
22065         fts: be consistent about AT_NO_AUTOMOUNT
22066         * lib/fts.c (fts_stat): Use fstatat with AT_NO_AUTOMOUNT
22067         consistently, instead of sometimes using stat (which implies
22068         AT_NO_AUTOMOUNT) and sometimes using fstatat without AT_NO_AUTOMOUNT.
22069         Remove a goto while we’re at it.
22071 2022-03-07  Pádraig Brady  <P@draigBrady.com>
22073         fcntl-h: add AT_NO_AUTOMOUNT
22074         * lib/fcntl.in.h: Define AT_NO_AUTOMOUNT to 0 where not defined.
22075         This is available on Linux since 2.6.38.
22077 2022-03-01  Paul Eggert  <eggert@cs.ucla.edu>
22079         Create lib/Makefile.am after gnulib-comp.m4
22080         * gnulib-tool (func_import): Create library makefile after
22081         creating gnulib-comp.m4.  With --gnu-make, the latter depends on
22082         the former.  See <https://bugs.gnu.org/32452#109>.
22084 2022-02-26  Paul Eggert  <eggert@cs.ucla.edu>
22086         gettime-res: fix unlikely overflow bug
22087         * lib/gettime-res.c (gettime_res): Fix bug when hz * tv_sec overflows.
22088         With 64-bit ‘long’ and nanosecond resolution the bug can occur
22089         starting in the year 2262, with probability about 2e-9.
22090         With 32-bit ‘long’ the bug can occur now, with same probability.
22091         The probability goes up on hosts with worse timestamp resolution.
22093         Document clang -fsanitize=undefined glitch
22094         * doc/gnulib-intro.texi (Unsupported Platforms):
22095         Document incompatibility of ‘clang -fsanitize=undefined’
22096         with Gnulib, and how to work around it by also using
22097         ‘-fno-sanitize=pointer-overflow’.
22099 2022-02-25  Darshit Shah  <darnir@gnu.org>
22101         modules/unicase/special-casing: Fix compilation error
22102         * modules/unicase/special-casing: Don't prepend $(AM_V_at) to the
22103         second part of a compound command.  It causes make to try and
22104         execute the command "@sed" which doesn't exist.
22106 2022-02-25  Paul Eggert  <eggert@cs.ucla.edu>
22108         Port __has_attribute to Apple’s Clang renumbering
22109         Problem reported by Kirill A. Korinsky in:
22110         https://lists.gnu.org/r/bug-gnulib/2022-02/msg00034.html
22111         * config/srclist.txt: Comment out sys/cdefs.h for now.
22112         * lib/cdefs.h (__glibc_has_attribute):
22113         * m4/gnulib-common.m4 (gl_COMMON_BODY):
22114         Port to Apple’s renumbering of Clang versions.
22116         nanosleep: simplify by using pselect
22117         GNU Emacs avoids Gnulib’s ‘select’ module and uses only pselect,
22118         which it implements in a special way on MS-DOS.
22119         Unfortunately, though, nanosleep uses ‘select’;
22120         problem reported by Lars Ingebrigtsen (Bug#32452#74).
22121         As far as I can tell, Gnulib nanosleep's use of
22122         ‘select’ with signals is only for ancient platforms
22123         that Gnulib no longer cares about, so remove that use of ‘select’.
22124         I don’t know of any platforms that still need this fallback code,
22125         but just in case, fall back to pselect instead, while removing
22126         signal handling that it shouldn’t be needed nowadays.
22127         * lib/nanosleep.c: Do not include sig-handler.h, sys/time.h.
22128         (SIGCONT, suspended, sighandler, my_usleep): Remove.
22129         (nanosleep) [!HAVE_BUG_BIG_NANOSLEEP && !(_WIN32 && !__CYGWIN__)]:
22130         Just call pselect.
22131         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Do not check for sys/time.h
22132         or call gl_FUNC_SELECT.  Do not include sys/time.h or worry
22133         about LIBSOCKET.
22134         (gl_PREREQ_NANOSLEEP): Remove as it’s no longer needed.
22135         All uses removed.
22136         * modules/nanosleep (Depends-on): Add pselect.
22137         Remove select, sigaction, sys_time.
22139 2022-02-24  Paul Eggert  <eggert@cs.ucla.edu>
22141         userspec: warn about '.' separator
22142         Problem reported by Dan Jacobson (Bug#44770).
22143         * lib/userspec.c: Don’t include stdbool.h since it’s now in our API.
22144         (parse_user_spec_warn): New function, broken out of parse_user_spec
22145         and with a new PWARN arg.
22146         (parse_user_spec): Use it.
22147         * lib/userspec.h: Include stdbool.h and declare new function.
22148         * tests/test-userspec.c (struct test.in): Now a char array
22149         so that it can be modified.
22150         (T): Make the placeholder a valid test, as that simplifies
22151         the code.  Omit NULL placeholder at the end, likewise.
22152         (main): Set up T in the new way, and test that the "."  separator
22153         acts like the ":" separator except with a warning if it works.
22155         userspec: no need for static vars
22156         * lib/userspec.c (parse_with_separator): Simplify.
22158 2022-02-22  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
22160         doc: add two missing closing parentheses
22161         * doc/regex.texi (Syntax Bits): Add missing closing parenthesis.
22162         * doc/regex.texi (BSD Regular Expression Compiling): Likewise.
22164 2022-02-22  Simon Josefsson  <simon@josefsson.org>
22166         gnulib-tool: Bump automake dependency.
22167         * gnulib-tool (func_emit_lib_Makefile_am)
22168         (func_emit_tests_Makefile_am): Demand Automake ≥ 1.14, for
22169         %reldir%.
22171 2022-02-21  Paul Eggert  <eggert@cs.ucla.edu>
22173         close-stream: don't depend on fclose
22174         This reverts 2022-01-26T17:33:03Z!eggert@cs.ucla.edu.
22175         Depending on fclose broke Emacs, and since this dependency didn't
22176         help GNU m4 let's remove it for now.  Problem reported by
22177         Lars Ingebrigtsen <https://bugs.gnu.org/32452#47>.
22178         * modules/close-stream (Depends-on): Remove fclose.
22180 2022-02-20  Bruno Haible  <bruno@clisp.org>
22182         Document that Automake ≥ 1.14 is needed (regression 2021-12-15).
22183         Reported by Simon Josefsson and Mike Frysinger in
22184         <https://lists.gnu.org/archive/html/bug-gnulib/2022-02/msg00010.html>.
22185         * DEPENDENCIES (Automake): Require version 1.14 or newer.
22187 2022-02-19  Paul Eggert  <eggert@cs.ucla.edu>
22189         mktime: improve heuristic for ca-1986 Indiana DST
22190         Problem reported by Mark Krenz <https://bugs.gnu.org/48085>.
22191         * lib/mktime.c (__mktime_internal): Be more generous about
22192         accepting arguments with the wrong value of tm_isdst, by falling
22193         back to a one-hour DST difference if we find no nearby DST that is
22194         unusual.  This fixes a problem where "1986-04-28 00:00 EDT" was
22195         rejected when TZ="America/Indianapolis" because the nearest DST
22196         timestamp occurred in 1970, a temporal distance too great for the
22197         old heuristic.  This also also narrows the search a bit, which
22198         is a minor performance win.
22199         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS):
22200         Check for putenv failures and for Bug#48085.
22201         * tests/test-parse-datetime.c (main):
22202         Test for setenv failures and for Bug#48085.
22204 2022-02-12  Paul Eggert  <eggert@cs.ucla.edu>
22206         filevercmp: fix several unexpected results
22207         Problems reported by Michael Debertol in <https://bugs.gnu.org/49239>.
22208         While looking into this, I spotted some more areas where the
22209         code and documentation did not agree, or where the documentation
22210         was unclear.  The biggest change needed by coreutils is a new
22211         function filenvercmp that can compare byte strings containing NUL.
22212         * lib/filevercmp.c: Do not include sys/types.h, stdlib.h, string.h.
22213         Include idx.h, verify.h.
22214         (match_suffix): Remove, replacing all uses with calls to ...
22215         (file_prefixlen): ... this new function.  Simplify it by
22216         avoiding the need for a confusing READ_ALPHA state variable.
22217         Change its API to something more useful, with a *LEN arg.
22218         it with a new *LEN arg.
22219         (file_prefixlen, verrevcmp):
22220         Prefer idx_t to size_t where either will do.
22221         (order): Change args to S, POS, LEN instead of just S[POS].
22222         This lets us handle NUL bytes correctly.  Callers changed.
22223         Verify that ints are sufficiently wide for its API.
22224         (verrevcmp): Don't assume that S1[S1_LEN] is a non-digit,
22225         and likewise for S2[S2_LEN].  The byte might not be accessible
22226         if filenvercmp is being called.
22227         (filevercmp): Reimplement by calling filenvercmp.
22228         (filenvercmp): New function, rewritten without the assumption
22229         that the inputs are null-terminated.
22230         Remove "easy comparison to see if strings are identical", as the
22231         use of it later (a) was undocumented, and (b) caused sort -V to be
22232         unstable.  When both strings start with ".", do not skip past
22233         the "."s before looking for suffixes, as this disagreed
22234         with the documentation.
22235         * lib/filevercmp.h: Fix comments, which had many mistakes.
22236         (filenvercmp): New decl.
22237         * modules/filevercmp (Depends-on): Add idx, verify.  Remove string.
22238         * tests/test-filevercmp.c: Include string.h.
22239         (examples): Reorder examples ".0" and ".9" that matched the code
22240         but not the documentation.  The code has been fixed to match the
22241         documentation.  Add some examples involving \1 so that they
22242         can be tried with both \1 and \0.  Add some other examples
22243         taken from the bug report.
22244         (equals): New set of test cases.
22245         (sign, test_filevercmp): New functions.
22246         (main): Remove test case where the fixed filevercmp disagrees with
22247         strverscmp.  Use test_filevercmp instead of filevercmp, so that
22248         we also test filenvercmp.  Test the newly-introduced EQUALS cases.
22250 2022-02-09  Bruno Haible  <bruno@clisp.org>
22252         string: Fix "mismatched allocation function" warnings regarding strndup.
22253         * lib/string.in.h (strndup): Mark with _GL_ATTRIBUTE_MALLOC and
22254         _GL_ATTRIBUTE_DEALLOC_FREE. For GCC >= 11: Declare also when the
22255         platform already declares the function or when the module 'strndup' is
22256         not in use.
22258 2022-02-09  Bruno Haible  <bruno@clisp.org>
22260         unictype/category-byname: Fix test failure.
22261         * modules/unictype/category-byname (configure.ac): Bump required
22262         libunistring version.
22264 2022-02-06  Bruno Haible  <bruno@clisp.org>
22266         termcap, termcap-h: Deprecate.
22267         * modules/termcap (Status, Notice): Add deprecation.
22268         * modules/termcap-h (Status, Notice): Likewise.
22270 2022-02-05  Paul Eggert  <eggert@cs.ucla.edu>
22272         parse-datetime: allow calculations to yield -1
22273         Problem reported by Jeremy Cantrell <https://bugs.gnu.org/50115>.
22274         * lib/parse-datetime.y (parse_datetime_body): When calling mktime,
22275         use an unmodifed and negative tm_wday or tm_yday to detect an error,
22276         as a (time_t) -1 return value is valid on most hosts.
22277         * tests/test-parse-datetime.c (main): Add a test for the bug.
22279 2022-02-04  Paul Eggert  <eggert@cs.ucla.edu>
22281         userspec: help fix GNU ‘id’ incompatibility
22282         * lib/userspec.c (parse_with_separator):
22283         Don’t set *username to a numeric string that is not a user name,
22284         and similarly for *groupname.  Needed to fix Bug#53631.
22286 2022-01-30  Pádraig Brady  <P@draigBrady.com>
22288         argmatch: add variants that only match full argument
22289         * lib/argmatch.h (argmatch_exact, [X]ARGMATCH_EXACT): New interfaces
22290         that don't allow abbreviations.
22291         * lib/argmatch.c (argmatch_exact): Likewise.
22292         (__xargmatch_internal): Add a bool parameter to disable abbreviations.
22293         * tests/test-argmatch.c: Add tests.
22295 2022-01-30  Bruno Haible  <bruno@clisp.org>
22297         tests: Fix interpretation of setupterm's return code.
22298         * tests/test-terminfo.c (main): Test the value of err when setupterm
22299         fails, not when it succeeds.
22300         * tests/test-termcap.c (main): Likewise.
22302 2022-01-30  Bruno Haible  <bruno@clisp.org>
22304         terminfo: Add tests.
22305         * tests/test-terminfo.c: New file.
22306         * modules/terminfo-tests: New file.
22308         terminfo, terminfo-h: New modules.
22309         * lib/terminfo.h: New file, from GNU gettext.
22310         * m4/terminfo.m4: New file, from GNU gettext.
22311         * modules/terminfo: New file, from GNU gettext.
22312         * modules/terminfo-h: New file, from GNU gettext.
22314 2022-01-30  Bruno Haible  <bruno@clisp.org>
22316         termcap: Add tests.
22317         * tests/test-termcap.c: New file.
22318         * modules/termcap-tests: New file.
22320         termcap, termcap-h: New modules.
22321         * lib/termcap.h: New file, from GNU gettext.
22322         * lib/tparm.c: New file, from GNU gettext.
22323         * lib/tputs.c: New file, from GNU gettext.
22324         * m4/termcap.m4: New file, from GNU gettext.
22325         * m4/curses.m4: New file, from GNU gettext.
22326         * modules/termcap: New file, from GNU gettext.
22327         * modules/termcap-h: New file, from GNU gettext.
22329 2022-01-29  Bruno Haible  <bruno@clisp.org>
22331         doc: Clarify MSVC support.
22332         * doc/gnulib-intro.texi (Supported Platforms): Document that "debug"
22333         builds are unsupported.
22335 2022-01-28  Pádraig Brady  <P@draigBrady.com>
22337         maintainer-makefile: fix sc_error_message_uppercase false failure
22338         * top/maint.mk (sc_error_message_uppercase): Don't trigger for
22339         any of the PRI... defines.
22341 2022-01-27  Paul Eggert  <eggert@cs.ucla.edu>
22343         alignalloc: work around AddressSanitizer bug
22344         * doc/posix-functions/aligned_alloc.texi (aligned_alloc):
22345         Mention AddressSanitizer bug.
22346         * lib/alignalloc.h (ALIGNALLOC_VIA_ALIGNED_ALLOC):
22347         Define to 0 if AddressSanitizer is in use.
22348         * tests/test-alignalloc.c (test_alignalloc): New function,
22349         which tests for non-aligned sizes too.
22350         (main): Use it.  Don’t bother checking for alignments
22351         greater than 16 MiB, as this flummoxes AddressSanitizer
22352         and there seems little point to testing them.
22354         doc: use UTF-8 encoding
22355         * doc/gnulib.texi: Use ‘@documentencoding UTF-8’.
22356         Partly this is because there are a few UTF-8 characters
22357         in the .texi files and there seems little point nowadays
22358         to @U-ifiying them.  And partly it is so that the .info
22359         output uses nicer UTF-8 characters, e.g., it single-quotes
22360         ‘like this’ instead of 'like this'.
22362         maint: Update copyright notices
22363         * build-aux/announce-gen, build-aux/declared.sh:
22364         * build-aux/git-version-gen, build-aux/gitlog-to-changelog:
22365         * build-aux/gnu-web-doc-update, build-aux/gnupload:
22366         * build-aux/increment-serial, build-aux/libtool-next-version:
22367         * build-aux/useless-if-before-free:
22368         Update some copyright notices by hand, that were not
22369         updated automatically.
22371 2022-01-26  Paul Eggert  <eggert@cs.ucla.edu>
22373         calloc-gnu: fix misspelling in 2022-01-03 patch
22374         Problem reported by Thien-Thi Nguyen in:
22375         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00170.html
22376         * modules/calloc-gnu (Depends-on):
22377         * modules/calloc-posix (Depends-on):
22378         Fix misspelling of REPLACE_CALLOC_FOR_CALLOC_POSIX.
22380         close-stream: avoid crash on MSVC Debug mode
22381         Problem reported by Julien Marrec in:
22382         https://lists.gnu.org/r/bug-m4/2022-01/msg00000.html
22383         * modules/close-stream (Depends-on): Depend on fclose.
22385 2022-01-23  Paul Eggert  <eggert@cs.ucla.edu>
22387         xstrtoimax, xstrtoumax: depend on inttypes-incomplete
22388         This fixes a call to strtoimax without declaring it,
22389         and similarly for strtoumax.
22390         * lib/xstrtoimax.c, lib/xstrtoumax.c (XSTRTOL_INCLUDE_INTTYPES_H):
22391         Define, so that strtoimax and strtoumax are declared.
22392         * lib/xstrtol.c [XSTRTOL_INCLUDE_INTTYPES_H]: Include inttypes.h.
22393         * modules/xstrtoimax, modules/xstrtoumax (Depends-on):
22394         Add inttypes-incomplete.
22396         alignalloc, xalignalloc: new modules
22397         * lib/alignalloc.c, lib/alignalloc.h, lib/xalignalloc.c:
22398         * m4/alignalloc.m4, modules/alignalloc, modules/alignalloc-tests:
22399         * modules/xalignalloc, tests/test-alignalloc.c:
22400         New files.
22402 2022-01-17  Paul Eggert  <eggert@cs.ucla.edu>
22404         extern-inline: improve macOS port
22405         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
22406         Define HAVE___HEADER_INLINE at configure-time, so that config.h
22407         knows the workaround is not needed even though ctype.h has not yet
22408         been included.  This lets the compiler use extern inline functions
22409         on newer macOS platforms, instead of static inline.
22410         Problem reported by Reuben Thomas in:
22411         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00130.html
22413 2022-01-17  Bruno Haible  <bruno@clisp.org>
22415         xstrtol: Trim dependencies.
22416         * lib/xstrtol.h: Include <stdint.h>, not <inttypes.h>.
22417         * modules/xstrtol (Depends-on): Add stdint. Remove inttypes-incomplete.
22419 2022-01-17  Bruno Haible  <bruno@clisp.org>
22421         xstrtol: Fix compilation error (regression 2022-01-16).
22422         * modules/xstrtol (Depends-on): Add intprops.
22424 2022-01-17  Jim Meyering  <meyering@fb.com>
22426         xstrtol: remove unnecessary else after return
22427         * lib/xstrtol.c (bkm_scale): Drop "else" after return.
22429 2022-01-16  Paul Eggert  <eggert@cs.ucla.edu>
22431         xstrtol: simplify integer overflow checking
22432         * lib/xstrtol.c: Include intprops.h.
22433         (TYPE_SIGNED): Remove, as intprops.h defines that for us now.
22434         (bkm_scale): Use INT_MULTIPLY_WRAPV instead of checking for
22435         overflow by hand.
22437         xstrtoll-tests: use %lld for long long
22438         * tests/test-xstrtoll.c, tests/test-xstrtoull.c (__spec):
22439         Do not assume long long is 64 bits, or that exact-width
22440         64-bit types exist.  Although these assumptions are true
22441         on current Gnulib platforms they are not true in general.
22442         Also, GCC warns if PRId64 is "ld" but intmax_t is long long
22443         even when long and long long are both 64 bits.
22445 2022-01-15  Bruno Haible  <bruno@clisp.org>
22447         Don't pass unknown warning option to clang.
22448         Reported by Assaf Gordon via Paul Eggert in
22449         <https://lists.gnu.org/archive/html/coreutils/2022-01/msg00018.html>.
22450         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Don't use
22451         -Wno-unsuffixed-float-constants with clang.
22453 2022-01-15  Bruno Haible  <bruno@clisp.org>
22455         log tests: Avoid test failure with nvc 22.1.
22456         * tests/test-log.h (test_function): With nvc, expect up to 4 ulps error.
22458 2022-01-15  Bruno Haible  <bruno@clisp.org>
22460         havelib: Recognize ELF platform despite nvc 22.1.
22461         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Recognize Linux as an ELF
22462         platform, even with a compiler that does not define __ELF__.
22464 2022-01-15  Bruno Haible  <bruno@clisp.org>
22466         oset-c++: Avoid compilation error with nvc++ 22.1.
22467         * lib/gl_oset.hh: With EDG C++ compilers, avoid 'friend'.
22469 2022-01-14  Paul Eggert  <eggert@cs.ucla.edu>
22471         nstrftime: pacify nvc 22.1 unreachable statement
22472         * lib/nstrftime.c (__strftime_internal):
22473         Omit unreachable ‘break;’.
22475         tests: pacify nvc 22.1 unreachable statement
22476         * tests/test-sys_wait.h (test_sys_wait_macros):
22477         Widen scope of ‘#if 0’ so that there is not an unreachable ‘break;’.
22479         tests: pacify nvc 22.1 set-but-not-used
22480         * tests/test-fnmatch.c (main): Don’t set a var without using it.
22481         * tests/test-sched.c (f1): Now extern.
22483         intprops: work around nvc 22.1 bug
22484         Problem reported by Olivier Cessenat (Bug#53256).
22485         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW) [__EDG__]:
22486         Define to 0, since __builtin_add_overflow doesn’t work
22487         on NVIDIA HPC SDK 22.1.
22489         copy-file-range: work around Linux kernel bug
22490         This workaround is adapted from Coreutils.
22491         * lib/copy-file-range.c [__linux__ && HAVE_COPY_FILE_RANGE]:
22492         Include <sys/utsname.h>.
22493         (copy_file_range): Use a stub to replace the copy_file_range of
22494         Linux kernel versions 4.5 through 5.2.
22495         * lib/unistd.in.h (copy_file_range):
22496         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS):
22497         * modules/copy-file-range (configure.ac):
22498         * modules/unistd (unistd.h):
22499         Support replacement of copy_file_range.
22500         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE):
22501         Define HAVE_COPY_FILE_RANGE if the system has copy_file_range,
22502         and on Linux check whether the system’s is known to work.
22504 2022-01-14  Bruno Haible  <bruno@clisp.org>
22506         Avoid error "conditional LIBUNISTRING_COMPILE_... was never defined"
22507         when option --conditional-dependencies is used (regression 2022-01-09).
22508         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
22509         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00099.html>.
22510         * m4/libunistring-base.m4 (gl_LIBUNISTRING_MODULE): Use gl_CONDITIONAL
22511         instead of AM_CONDITIONAL.
22513 2022-01-13  Bruno Haible  <bruno@clisp.org>
22515         Avoid warning "_GL_ATTRIBUTE_DEALLOC_FREE redefined" (regr. 2022-01-04).
22516         Reported by Werner Lemberg <wl@gnu.org> in
22517         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00094.html>.
22518         * m4/gnulib-common.m4 (gl_COMMON_BODY): Avoid redefining
22519         _GL_ATTRIBUTE_DEALLOC_FREE.
22521 2022-01-10  Paul Eggert  <eggert@cs.ucla.edu>
22523         backupfile: fix bug when renaming not from wd
22524         * lib/backupfile.c (backupfile_internal): Fix bug when DIR_FD
22525         does not specify the working directory, and when RENAME.
22526         Without the bug fix, FILE is treated as relative to the working
22527         directory, not relative to DIR_FD, when renaming FILE.
22528         This bug was introduced when DIR_FD and RENAME were introduced,
22529         in 2018-10-24T02:10:21Z!eggert@cs.ucla.edu.
22530         While we’re at it, when SDIR is nonnegative improve performance a
22531         bit by passing an SDIR-relative old name to renameatu.
22533 2022-01-09  Bruno Haible  <bruno@clisp.org>
22535         host-cpu-c-abi: Add support for LoongArch64 CPU.
22536         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Define __loongarch64__. (GCC
22537         and clang predefine only __loongarch__, __loongarch64.)
22539 2022-01-09  Bruno Haible  <bruno@clisp.org>
22541         stdio: Fix "missing file" errors (regression from today).
22542         * modules/stdio (Files): Add stdio-read.c, stdio-write.c.
22543         * m4/stdio_h.m4 (gl_STDIO_H): Update comments.
22545 2022-01-09  Bruno Haible  <bruno@clisp.org>
22547         Use the GL_CFLAG_GNULIB_WARNINGS for most AC_LIBOBJ compilation units.
22548         * modules/_Exit (configure.ac): Define an Automake conditional. Remove
22549         the AC_LIBOBJ invocation.
22550         (Makefile.am): Augment lib_SOURCES, guarded by that Automake
22551         conditional.
22552         * modules/accept: Likewise.
22553         * modules/access: Likewise.
22554         * modules/acosf: Likewise.
22555         * modules/acosl: Likewise.
22556         * modules/aligned_alloc: Likewise.
22557         * modules/alphasort: Likewise.
22558         * modules/argz: Likewise.
22559         * modules/asinf: Likewise.
22560         * modules/asinl: Likewise.
22561         * modules/atan2f: Likewise.
22562         * modules/atanf: Likewise.
22563         * modules/atanl: Likewise.
22564         * modules/atexit: Likewise.
22565         * modules/atoll: Likewise.
22566         * modules/bind: Likewise.
22567         * modules/btowc: Likewise.
22568         * modules/c32rtomb: Likewise.
22569         * modules/canonicalize-lgpl: Likewise.
22570         * modules/cbrt: Likewise.
22571         * modules/cbrtf: Likewise.
22572         * modules/cbrtl: Likewise.
22573         * modules/ceil: Likewise.
22574         * modules/ceilf: Likewise.
22575         * modules/ceill: Likewise.
22576         * modules/chdir-long: Likewise.
22577         * modules/chown: Likewise.
22578         * modules/close: Likewise.
22579         * modules/closedir: Likewise.
22580         * modules/cnd: Likewise.
22581         * modules/connect: Likewise.
22582         * modules/copy-file-range: Likewise.
22583         * modules/copysign: Likewise.
22584         * modules/copysignf: Likewise.
22585         * modules/copysignl: Likewise.
22586         * modules/cosf: Likewise.
22587         * modules/coshf: Likewise.
22588         * modules/cosl: Likewise.
22589         * modules/creat: Likewise.
22590         * modules/crypto/gc: Likewise.
22591         * modules/ctime: Likewise.
22592         * modules/dirfd: Likewise.
22593         * modules/dup: Likewise.
22594         * modules/dup2: Likewise.
22595         * modules/duplocale: Likewise.
22596         * modules/error: Likewise.
22597         * modules/euidaccess: Likewise.
22598         * modules/execinfo: Likewise.
22599         * modules/execl: Likewise.
22600         * modules/execle: Likewise.
22601         * modules/execlp: Likewise.
22602         * modules/execv: Likewise.
22603         * modules/execve: Likewise.
22604         * modules/execvp: Likewise.
22605         * modules/execvpe: Likewise.
22606         * modules/exp2: Likewise.
22607         * modules/exp2f: Likewise.
22608         * modules/exp2l: Likewise.
22609         * modules/expf: Likewise.
22610         * modules/expl: Likewise.
22611         * modules/explicit_bzero: Likewise.
22612         * modules/expm1: Likewise.
22613         * modules/expm1f: Likewise.
22614         * modules/expm1l: Likewise.
22615         * modules/fabsf: Likewise.
22616         * modules/fabsl: Likewise.
22617         * modules/faccessat: Likewise.
22618         * modules/fchdir: Likewise.
22619         * modules/fchmodat: Likewise.
22620         * modules/fchownat: Likewise.
22621         * modules/fclose: Likewise.
22622         * modules/fcntl: Likewise.
22623         * modules/fdatasync: Likewise.
22624         * modules/fdopen: Likewise.
22625         * modules/fdopendir: Likewise.
22626         * modules/fflush: Likewise.
22627         * modules/ffs: Likewise.
22628         * modules/ffsl: Likewise.
22629         * modules/ffsll: Likewise.
22630         * modules/fileblocks: Likewise.
22631         * modules/float: Likewise.
22632         * modules/flock: Likewise.
22633         * modules/floor: Likewise.
22634         * modules/floorf: Likewise.
22635         * modules/floorl: Likewise.
22636         * modules/fma: Likewise.
22637         * modules/fmaf: Likewise.
22638         * modules/fmal: Likewise.
22639         * modules/fmod: Likewise.
22640         * modules/fmodf: Likewise.
22641         * modules/fmodl: Likewise.
22642         * modules/forkpty: Likewise.
22643         * modules/fpending: Likewise.
22644         * modules/fpurge: Likewise.
22645         * modules/freadable: Likewise.
22646         * modules/freadahead: Likewise.
22647         * modules/freadptr: Likewise.
22648         * modules/free-posix: Likewise.
22649         * modules/freopen: Likewise.
22650         * modules/frexpf: Likewise.
22651         * modules/fseek: Likewise.
22652         * modules/fseeko: Likewise.
22653         * modules/fseterr: Likewise.
22654         * modules/fstat: Likewise.
22655         * modules/fstatat: Likewise.
22656         * modules/fsusage: Likewise.
22657         * modules/fsync: Likewise.
22658         * modules/ftell: Likewise.
22659         * modules/ftello: Likewise.
22660         * modules/ftruncate: Likewise.
22661         * modules/fts: Likewise.
22662         * modules/futimens: Likewise.
22663         * modules/fwritable: Likewise.
22664         * modules/fwriting: Likewise.
22665         * modules/getaddrinfo: Likewise.
22666         * modules/getcwd: Likewise.
22667         * modules/getcwd-lgpl: Likewise.
22668         * modules/getdelim: Likewise.
22669         * modules/getdomainname: Likewise.
22670         * modules/getdtablesize: Likewise.
22671         * modules/getentropy: Likewise.
22672         * modules/getgroups: Likewise.
22673         * modules/gethostname: Likewise.
22674         * modules/getline: Likewise.
22675         * modules/getloadavg: Likewise.
22676         * modules/getlogin: Likewise.
22677         * modules/getlogin_r: Likewise.
22678         * modules/getopt-posix: Likewise.
22679         * modules/getpagesize: Likewise.
22680         * modules/getpeername: Likewise.
22681         * modules/getrandom: Likewise.
22682         * modules/getrusage: Likewise.
22683         * modules/getsockname: Likewise.
22684         * modules/getsockopt: Likewise.
22685         * modules/getsubopt: Likewise.
22686         * modules/gettimeofday: Likewise.
22687         * modules/getumask: Likewise.
22688         * modules/getusershell: Likewise.
22689         * modules/glob: Likewise.
22690         * modules/grantpt: Likewise.
22691         * modules/group-member: Likewise.
22692         * modules/hypot: Likewise.
22693         * modules/hypotf: Likewise.
22694         * modules/hypotl: Likewise.
22695         * modules/iconv_open: Likewise.
22696         * modules/ilogb: Likewise.
22697         * modules/ilogbf: Likewise.
22698         * modules/ilogbl: Likewise.
22699         * modules/imaxabs: Likewise.
22700         * modules/imaxdiv: Likewise.
22701         * modules/inet_ntop: Likewise.
22702         * modules/inet_pton: Likewise.
22703         * modules/ioctl: Likewise.
22704         * modules/isapipe: Likewise.
22705         * modules/isatty: Likewise.
22706         * modules/isblank: Likewise.
22707         * modules/isfinite: Likewise.
22708         * modules/isinf: Likewise.
22709         * modules/iswblank: Likewise.
22710         * modules/iswctype: Likewise.
22711         * modules/iswdigit: Likewise.
22712         * modules/iswxdigit: Likewise.
22713         * modules/lchmod: Likewise.
22714         * modules/lchown: Likewise.
22715         * modules/ldexpf: Likewise.
22716         * modules/ldexpl: Likewise.
22717         * modules/libgmp: Likewise.
22718         * modules/link: Likewise.
22719         * modules/linkat: Likewise.
22720         * modules/listen: Likewise.
22721         * modules/localeconv: Likewise.
22722         * modules/localtime: Likewise.
22723         * modules/log: Likewise.
22724         * modules/log10: Likewise.
22725         * modules/log10f: Likewise.
22726         * modules/log10l: Likewise.
22727         * modules/log1p: Likewise.
22728         * modules/log1pf: Likewise.
22729         * modules/log1pl: Likewise.
22730         * modules/log2: Likewise.
22731         * modules/log2f: Likewise.
22732         * modules/log2l: Likewise.
22733         * modules/logb: Likewise.
22734         * modules/logbf: Likewise.
22735         * modules/logbl: Likewise.
22736         * modules/logf: Likewise.
22737         * modules/login_tty: Likewise.
22738         * modules/logl: Likewise.
22739         * modules/lseek: Likewise.
22740         * modules/lstat: Likewise.
22741         * modules/mbrlen: Likewise.
22742         * modules/mbrtoc32: Likewise.
22743         * modules/mbrtowc: Likewise.
22744         * modules/mbsinit: Likewise.
22745         * modules/mbsnrtowcs: Likewise.
22746         * modules/mbsrtowcs: Likewise.
22747         * modules/mbtowc: Likewise.
22748         * modules/memalign: Likewise.
22749         * modules/memchr: Likewise.
22750         * modules/memcmp: Likewise.
22751         * modules/memcpy: Likewise.
22752         * modules/memmove: Likewise.
22753         * modules/mempcpy: Likewise.
22754         * modules/memrchr: Likewise.
22755         * modules/memset: Likewise.
22756         * modules/mkdir: Likewise.
22757         * modules/mkdirat: Likewise.
22758         * modules/mkdtemp: Likewise.
22759         * modules/mkfifo: Likewise.
22760         * modules/mkfifoat: Likewise.
22761         * modules/mknod: Likewise.
22762         * modules/mkostemp: Likewise.
22763         * modules/mkostemps: Likewise.
22764         * modules/mkstemp: Likewise.
22765         * modules/mkstemps: Likewise.
22766         * modules/modf: Likewise.
22767         * modules/modff: Likewise.
22768         * modules/modfl: Likewise.
22769         * modules/mountlist: Likewise.
22770         * modules/msvc-inval: Likewise.
22771         * modules/msvc-nothrow: Likewise.
22772         * modules/mtx: Likewise.
22773         * modules/nanosleep: Likewise.
22774         * modules/nl_langinfo: Likewise.
22775         * modules/obstack: Likewise.
22776         * modules/open: Likewise.
22777         * modules/openat: Likewise.
22778         * modules/opendir: Likewise.
22779         * modules/openpty: Likewise.
22780         * modules/pclose: Likewise.
22781         * modules/perror: Likewise.
22782         * modules/pipe-posix: Likewise.
22783         * modules/poll: Likewise.
22784         * modules/popen: Likewise.
22785         * modules/posix_memalign: Likewise.
22786         * modules/posix_openpt: Likewise.
22787         * modules/posix_spawn: Likewise.
22788         * modules/posix_spawn-internal: Likewise.
22789         * modules/posix_spawn_file_actions_addchdir: Likewise.
22790         * modules/posix_spawn_file_actions_addclose: Likewise.
22791         * modules/posix_spawn_file_actions_adddup2: Likewise.
22792         * modules/posix_spawn_file_actions_addfchdir: Likewise.
22793         * modules/posix_spawn_file_actions_addopen: Likewise.
22794         * modules/posix_spawn_file_actions_destroy: Likewise.
22795         * modules/posix_spawn_file_actions_init: Likewise.
22796         * modules/posix_spawnattr_destroy: Likewise.
22797         * modules/posix_spawnattr_getflags: Likewise.
22798         * modules/posix_spawnattr_getpgroup: Likewise.
22799         * modules/posix_spawnattr_getschedparam: Likewise.
22800         * modules/posix_spawnattr_getschedpolicy: Likewise.
22801         * modules/posix_spawnattr_getsigdefault: Likewise.
22802         * modules/posix_spawnattr_getsigmask: Likewise.
22803         * modules/posix_spawnattr_init: Likewise.
22804         * modules/posix_spawnattr_setflags: Likewise.
22805         * modules/posix_spawnattr_setpgroup: Likewise.
22806         * modules/posix_spawnattr_setschedparam: Likewise.
22807         * modules/posix_spawnattr_setschedpolicy: Likewise.
22808         * modules/posix_spawnattr_setsigdefault: Likewise.
22809         * modules/posix_spawnattr_setsigmask: Likewise.
22810         * modules/posix_spawnp: Likewise.
22811         * modules/powf: Likewise.
22812         * modules/pread: Likewise.
22813         * modules/pselect: Likewise.
22814         * modules/pthread-cond: Likewise.
22815         * modules/pthread-mutex: Likewise.
22816         * modules/pthread-once: Likewise.
22817         * modules/pthread-rwlock: Likewise.
22818         * modules/pthread-spin: Likewise.
22819         * modules/pthread-thread: Likewise.
22820         * modules/pthread-tss: Likewise.
22821         * modules/pthread_mutex_timedlock: Likewise.
22822         * modules/pthread_sigmask: Likewise.
22823         * modules/ptsname: Likewise.
22824         * modules/ptsname_r: Likewise.
22825         * modules/putenv: Likewise.
22826         * modules/pwrite: Likewise.
22827         * modules/qsort_r: Likewise.
22828         * modules/raise: Likewise.
22829         * modules/random: Likewise.
22830         * modules/random_r: Likewise.
22831         * modules/rawmemchr: Likewise.
22832         * modules/read: Likewise.
22833         * modules/readdir: Likewise.
22834         * modules/readline: Likewise.
22835         * modules/readlink: Likewise.
22836         * modules/readlinkat: Likewise.
22837         * modules/readutmp: Likewise.
22838         * modules/reallocarray: Likewise.
22839         * modules/recv: Likewise.
22840         * modules/recvfrom: Likewise.
22841         * modules/regex: Likewise.
22842         * modules/relocatable-prog: Likewise.
22843         * modules/remainder: Likewise.
22844         * modules/remainderf: Likewise.
22845         * modules/remainderl: Likewise.
22846         * modules/remove: Likewise.
22847         * modules/rename: Likewise.
22848         * modules/renameat: Likewise.
22849         * modules/rewinddir: Likewise.
22850         * modules/rint: Likewise.
22851         * modules/rintf: Likewise.
22852         * modules/rintl: Likewise.
22853         * modules/rmdir: Likewise.
22854         * modules/round: Likewise.
22855         * modules/roundf: Likewise.
22856         * modules/roundl: Likewise.
22857         * modules/rpmatch: Likewise.
22858         * modules/scandir: Likewise.
22859         * modules/sched_yield: Likewise.
22860         * modules/secure_getenv: Likewise.
22861         * modules/select: Likewise.
22862         * modules/selinux-h: Likewise.
22863         * modules/send: Likewise.
22864         * modules/sendto: Likewise.
22865         * modules/setenv: Likewise.
22866         * modules/sethostname: Likewise.
22867         * modules/setlocale: Likewise.
22868         * modules/setlocale-null: Likewise.
22869         * modules/setsockopt: Likewise.
22870         * modules/shutdown: Likewise.
22871         * modules/sig2str: Likewise.
22872         * modules/sigabbrev_np: Likewise.
22873         * modules/sigaction: Likewise.
22874         * modules/sigdescr_np: Likewise.
22875         * modules/signbit: Likewise.
22876         * modules/sigprocmask: Likewise.
22877         * modules/sinf: Likewise.
22878         * modules/sinhf: Likewise.
22879         * modules/sinl: Likewise.
22880         * modules/sleep: Likewise.
22881         * modules/socket: Likewise.
22882         * modules/spawn-pipe: Likewise.
22883         * modules/sqrtf: Likewise.
22884         * modules/sqrtl: Likewise.
22885         * modules/stat: Likewise.
22886         * modules/stdio: Likewise.
22887         * modules/stpcpy: Likewise.
22888         * modules/stpncpy: Likewise.
22889         * modules/strcase: Likewise.
22890         * modules/strchrnul: Likewise.
22891         * modules/strcspn: Likewise.
22892         * modules/strdup-posix: Likewise.
22893         * modules/strerror: Likewise.
22894         * modules/strerror-override: Likewise.
22895         * modules/strerrorname_np: Likewise.
22896         * modules/strfmon_l: Likewise.
22897         * modules/strftime-fixes: Likewise.
22898         * modules/strncat: Likewise.
22899         * modules/strndup: Likewise.
22900         * modules/strnlen: Likewise.
22901         * modules/strpbrk: Likewise.
22902         * modules/strptime: Likewise.
22903         * modules/strsep: Likewise.
22904         * modules/strsignal: Likewise.
22905         * modules/strtod: Likewise.
22906         * modules/strtoimax: Likewise.
22907         * modules/strtok_r: Likewise.
22908         * modules/strtol: Likewise.
22909         * modules/strtold: Likewise.
22910         * modules/strtoll: Likewise.
22911         * modules/strtoul: Likewise.
22912         * modules/strtoull: Likewise.
22913         * modules/strtoumax: Likewise.
22914         * modules/strverscmp: Likewise.
22915         * modules/symlink: Likewise.
22916         * modules/symlinkat: Likewise.
22917         * modules/tanf: Likewise.
22918         * modules/tanhf: Likewise.
22919         * modules/tanl: Likewise.
22920         * modules/tcgetsid: Likewise.
22921         * modules/thrd: Likewise.
22922         * modules/time_r: Likewise.
22923         * modules/time_rz: Likewise.
22924         * modules/timegm: Likewise.
22925         * modules/times: Likewise.
22926         * modules/timespec_get: Likewise.
22927         * modules/timespec_getres: Likewise.
22928         * modules/tmpfile: Likewise.
22929         * modules/towctrans: Likewise.
22930         * modules/trunc: Likewise.
22931         * modules/truncate: Likewise.
22932         * modules/truncf: Likewise.
22933         * modules/truncl: Likewise.
22934         * modules/tsearch: Likewise.
22935         * modules/tss: Likewise.
22936         * modules/ttyname_r: Likewise.
22937         * modules/tzset: Likewise.
22938         * modules/uname: Likewise.
22939         * modules/unlink: Likewise.
22940         * modules/unlinkat: Likewise.
22941         * modules/unlockpt: Likewise.
22942         * modules/unsetenv: Likewise.
22943         * modules/usleep: Likewise.
22944         * modules/utime: Likewise.
22945         * modules/utimensat: Likewise.
22946         * modules/waitpid: Likewise.
22947         * modules/wcpcpy: Likewise.
22948         * modules/wcpncpy: Likewise.
22949         * modules/wcrtomb: Likewise.
22950         * modules/wcscasecmp: Likewise.
22951         * modules/wcscat: Likewise.
22952         * modules/wcschr: Likewise.
22953         * modules/wcscmp: Likewise.
22954         * modules/wcscoll: Likewise.
22955         * modules/wcscpy: Likewise.
22956         * modules/wcscspn: Likewise.
22957         * modules/wcsdup: Likewise.
22958         * modules/wcsftime: Likewise.
22959         * modules/wcslen: Likewise.
22960         * modules/wcsncasecmp: Likewise.
22961         * modules/wcsncat: Likewise.
22962         * modules/wcsncmp: Likewise.
22963         * modules/wcsncpy: Likewise.
22964         * modules/wcsnlen: Likewise.
22965         * modules/wcsnrtombs: Likewise.
22966         * modules/wcspbrk: Likewise.
22967         * modules/wcsrchr: Likewise.
22968         * modules/wcsrtombs: Likewise.
22969         * modules/wcsspn: Likewise.
22970         * modules/wcsstr: Likewise.
22971         * modules/wcstok: Likewise.
22972         * modules/wcswidth: Likewise.
22973         * modules/wcsxfrm: Likewise.
22974         * modules/wctob: Likewise.
22975         * modules/wctomb: Likewise.
22976         * modules/wctrans: Likewise.
22977         * modules/wctype: Likewise.
22978         * modules/wcwidth: Likewise.
22979         * modules/windows-cond: Likewise.
22980         * modules/windows-mutex: Likewise.
22981         * modules/windows-once: Likewise.
22982         * modules/windows-recmutex: Likewise.
22983         * modules/windows-rwlock: Likewise.
22984         * modules/windows-spawn: Likewise.
22985         * modules/windows-spin: Likewise.
22986         * modules/windows-thread: Likewise.
22987         * modules/windows-timedmutex: Likewise.
22988         * modules/windows-timedrecmutex: Likewise.
22989         * modules/windows-timedrwlock: Likewise.
22990         * modules/windows-tls: Likewise.
22991         * modules/wmemchr: Likewise.
22992         * modules/wmemcmp: Likewise.
22993         * modules/wmemcpy: Likewise.
22994         * modules/wmemmove: Likewise.
22995         * modules/wmempcpy: Likewise.
22996         * modules/wmemset: Likewise.
22997         * modules/write: Likewise.
22999 2022-01-09  Bruno Haible  <bruno@clisp.org>
23001         obstack: Move AC_LIBOBJ invocation to the module description.
23002         * m4/obstack.m4 (gl_FUNC_OBSTACK): Renamed from AC_FUNC_OBSTACK. Don't
23003         invoke AC_LIBSOURCES nor AC_LIBOBJ.
23004         * modules/obstack (configure.ac): Update. Invoke AC_LIBOBJ here.
23006 2022-01-09  Bruno Haible  <bruno@clisp.org>
23008         stdio: Move AC_LIBOBJ invocations to the module description.
23009         * m4/stdio_h.m4 (gl_STDIO_H): Don't invoke AC_LIBOBJ.
23010         * modules/stdio (configure.ac): Invoke AC_LIBOBJ here.
23012 2022-01-09  Bruno Haible  <bruno@clisp.org>
23014         fchdir: Move AC_LIBOBJ invocation to the module description.
23015         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke AC_LIBOBJ and
23016         gl_PREREQ_FCHDIR.
23017         * modules/fchdir (configure.ac): Invoke AC_LIBOBJ and gl_PREREQ_FCHDIR.
23019 2022-01-09  Bruno Haible  <bruno@clisp.org>
23021         Remove influence of Automake conditionals on conditional dependencies.
23022         * m4/gnulib-common.m4 (gl_CONDITIONAL): New macro.
23023         (gl_CONDITIONAL_HEADER): Use it instead of AM_CONDITIONAL.
23024         * m4/libgmp.m4 (gl_LIBGMP): Likewise.
23025         * modules/posix_spawn_file_actions_addfchdir-tests (configure.ac):
23026         Likewise.
23027         * modules/uchar-c++-tests (configure.ac): Likewise.
23028         * gnulib-tool (func_modules_transitive_closure): Don't inhibit
23029         conditional dependencies processing on a module that uses an Automake
23030         conditional.
23032 2022-01-08  Bruno Haible  <bruno@clisp.org>
23034         gnulib-tool: Fix "Don't forget" messages (regression 2021-12-12).
23035         * gnulib-tool (func_import): Fix variable references in "Don't forget"
23036         messages.
23038 2022-01-08  Bruno Haible  <bruno@clisp.org>
23040         gnulib-tool: Remove all *.Po files upon distclean (regr. 2022-01-05).
23041         Reported by Mohammad Akhlaghi <mohammad@akhlaghi.org> in
23042         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00061.html>.
23043         * gnulib-tool (func_emit_initmacro_end): Collect the *.Po or *.Plo files
23044         to remove into an AC_SUBSTed variable gl_LIBOBJDEPS.
23045         (func_emit_lib_Makefile_am): Extend the distclean and maintainer-clean
23046         rules.
23048 2022-01-08  Bruno Haible  <bruno@clisp.org>
23050         Add another example.
23051         * examples/hello-c-gnulib-conddeps: New directory.
23053 2022-01-08  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
23055         c-stack: Adapt header file for use in C++ applications.
23056         * lib/c-stack.h: Add extern "C" block.
23058 2022-01-08  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
23060         version-etc: Adapt header file for use in C++ applications.
23061         * lib/version-etc.h: Add extern "C" block.
23063 2022-01-07  Bruno Haible  <bruno@clisp.org>
23065         sigsegv: Improve support for Linux/LoongArch64.
23066         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): Add special case for
23067         Linux/LoongArch.
23069 2022-01-05  Glenn Washburn  <development@efficientek.com>
23071         bootstrap: When a commit is specified, do a shallow fetch if possible.
23072         Rationale and explanation:
23073         <https://lists.gnu.org/archive/html/bug-gnulib/2021-10/msg00073.html>.
23074         * bootstrap: When a commit hash is specified, ask for this specific
23075         commit on fetch, and fallback to fetching the entire repository if
23076         fetching by commit hash fails.
23078 2022-01-05  Paul Eggert  <eggert@cs.ucla.edu>
23080         stack: pacify gcc -Wsign-compare
23081         * lib/stack.h (_GL_STACK_TYPE): Use idx_t for size too.
23082         Suggested by Bruno Haible in:
23083         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00035.html
23084         (_GL_STACK_PREFIX (size)): Return idx_t, not size_t.
23086 2022-01-05  Bruno Haible  <bruno@clisp.org>
23088         Fix last commit.
23089         Based on a patch by José E. Marchesi <jemarch@gnu.org>, reported in
23090         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00036.html>.
23091         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Don't enable
23092         -Wimplicit-fallthrough for GCC < 7.
23094 2022-01-05  Bruno Haible  <bruno@clisp.org>
23096         gnulib-tool: Avoid known warnings that reflect Gnulib's coding style.
23097         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): New macro.
23098         * gnulib-tool (func_emit_lib_Makefile_am): Add the
23099         GL_CFLAG_GNULIB_WARNINGS to the CFLAGS of all the compilation units of
23100         the library.
23101         (func_emit_tests_Makefile_am): Add the GL_CFLAG_GNULIB_WARNINGS to the
23102         CFLAGS.
23103         (func_import): Emit an invocation of gl_CC_GNULIB_WARNINGS.
23105 2022-01-04  Bernhard Voelker  <mail@bernhard-voelker.de>
23107         license: fix GPLv3 texts to use a comma instead of semicolon.
23108         See: https://www.gnu.org/licenses/gpl-3.0.html#howto
23109         Run:
23110           $ git grep -l 'Foundation; either version 3' \
23111               | xargs sed -i '/Foundation; either version 3/ s/n; e/n, e/'
23112         * All files using GPLv3: Adjust via the above command.
23114 2022-01-04  Bruno Haible  <bruno@clisp.org>
23116         string, wchar: Fix compilation error on MSVC (regression 2021-09-07).
23117         * lib/string.in.h (free): Don't redeclare as rpl_free. Instead, redefine
23118         _GL_ATTRIBUTE_DEALLOC_FREE to reference rpl_free directly.
23119         * lib/wchar.in.h (free): Likewise.
23121 2022-01-03  Bruno Haible  <bruno@clisp.org>
23123         getpass-gnu: Allow use as dependency from test modules.
23124         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): Set
23125         REPLACE_GETPASS_FOR_GETPASS_GNU instead of REPLACE_GETPASS.
23126         * m4/unistd_h.m4 (gl_UNISTD_H_REQUIRE_DEFAULTS): Initialize the
23127         getpass-gnu module indicator.
23128         (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_GETPASS_FOR_GETPASS_GNU.
23129         * modules/unistd (Makefile.am): Substitute GNULIB_GETPASS_GNU,
23130         REPLACE_GETPASS_FOR_GETPASS_GNU.
23131         * modules/getpass-gnu (configure.ac): Test
23132         REPLACE_GETPASS_FOR_GETPASS_GNU instead of REPLACE_GETPASS. Set a module
23133         indicator.
23134         * lib/unistd.in.h (getpass): Test REPLACE_GETPASS,
23135         REPLACE_GETPASS_FOR_GETPASS_GNU, and the respective module indicators
23136         instead of just REPLACE_GETPASS.
23138 2022-01-03  Bruno Haible  <bruno@clisp.org>
23140         fopen-gnu: Allow use as dependency from test modules.
23141         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): Set REPLACE_FOPEN_FOR_FOPEN_GNU
23142         instead of REPLACE_FOPEN.
23143         * m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize the fopen-gnu
23144         module indicator.
23145         (gl_STDIO_H_DEFAULTS): Initialize REPLACE_FOPEN_FOR_FOPEN_GNU.
23146         * modules/stdio (Makefile.am): Substitute GNULIB_FOPEN_GNU,
23147         REPLACE_FOPEN_FOR_FOPEN_GNU.
23148         * modules/fopen-gnu (Depends-on): Add more dependencies.
23149         (configure.ac): Test REPLACE_FOPEN_FOR_FOPEN_GNU instead of
23150         REPLACE_FOPEN.
23151         * lib/stdio.in.h (fopen): Test REPLACE_FOPEN,
23152         REPLACE_FOPEN_FOR_FOPEN_GNU, and the respective module indicators
23153         instead of just REPLACE_FOPEN.
23155 2022-01-03  Bruno Haible  <bruno@clisp.org>
23157         realloc-gnu: Allow use as dependency from test modules.
23158         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): Set
23159         REPLACE_REALLOC_FOR_REALLOC_GNU instead of REPLACE_REALLOC.
23160         (gl_FUNC_REALLOC_POSIX): Set REPLACE_REALLOC_FOR_REALLOC_POSIX instead
23161         of REPLACE_REALLOC.
23162         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
23163         realloc-gnu module indicator.
23164         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_REALLOC_FOR_REALLOC_GNU,
23165         REPLACE_REALLOC_FOR_REALLOC_POSIX, not REPLACE_REALLOC.
23166         * modules/stdlib (Makefile.am): Substitute GNULIB_REALLOC_GNU,
23167         REPLACE_REALLOC_FOR_REALLOC_GNU, REPLACE_REALLOC_FOR_REALLOC_POSIX, not
23168         REPLACE_REALLOC.
23169         * modules/realloc-posix (Depends-on, configure.ac): Test
23170         REPLACE_REALLOC_FOR_REALLOC_POSIX instead of REPLACE_REALLOC.
23171         * modules/realloc-gnu (Comment): Remove section.
23172         (Depends-on): Add free-posix, malloc-gnu, xalloc-oversized.
23173         (configure.ac): Test REPLACE_REALLOC_FOR_REALLOC_GNU instead of
23174         REPLACE_REALLOC. Set a module indicator.
23175         * lib/stdlib.in.h (realloc): Test REPLACE_REALLOC_FOR_REALLOC_POSIX,
23176         REPLACE_REALLOC_FOR_REALLOC_GNU, and the respective module indicators
23177         instead of just REPLACE_REALLOC.
23179 2022-01-03  Bruno Haible  <bruno@clisp.org>
23181         calloc-gnu: Allow use as dependency from test modules.
23182         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Set REPLACE_CALLOC_FOR_CALLOC_GNU
23183         instead of REPLACE_CALLOC.
23184         (gl_FUNC_CALLOC_POSIX): Set REPLACE_CALLOC_FOR_CALLOC_POSIX instead of
23185         REPLACE_CALLOC.
23186         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
23187         calloc-gnu module indicator.
23188         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_CALLOC_FOR_CALLOC_GNU,
23189         REPLACE_CALLOC_FOR_CALLOC_POSIX, not REPLACE_CALLOC.
23190         * modules/stdlib (Makefile.am): Substitute GNULIB_CALLOC_GNU,
23191         REPLACE_CALLOC_FOR_CALLOC_GNU, REPLACE_CALLOC_FOR_CALLOC_POSIX, not
23192         REPLACE_CALLOC.
23193         * modules/calloc-posix (Depends-on, configure.ac): Test
23194         REPLACE_CALLOC_FOR_CALLOC_POSIX instead of REPLACE_CALLOC.
23195         * modules/calloc-gnu (Depends-on): Add xalloc-oversized.
23196         (configure.ac): Test REPLACE_CALLOC_FOR_CALLOC_GNU instead of
23197         REPLACE_CALLOC. Set a module indicator.
23198         * lib/stdlib.in.h (calloc): Test REPLACE_CALLOC_FOR_CALLOC_POSIX,
23199         REPLACE_CALLOC_FOR_CALLOC_GNU, and the respective module indicators
23200         instead of just REPLACE_CALLOC.
23202 2022-01-03  Bruno Haible  <bruno@clisp.org>
23204         malloc-gnu: Allow use as dependency from test modules.
23205         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): Set REPLACE_MALLOC_FOR_MALLOC_GNU
23206         instead of REPLACE_MALLOC.
23207         (gl_FUNC_MALLOC_PTRDIFF, gl_FUNC_MALLOC_POSIX): Set
23208         REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
23209         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Test
23210         REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
23211         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
23212         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
23213         malloc-gnu module indicator.
23214         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MALLOC_FOR_MALLOC_GNU,
23215         REPLACE_MALLOC_FOR_MALLOC_POSIX, not REPLACE_MALLOC.
23216         * modules/stdlib (Makefile.am): Substitute GNULIB_MALLOC_GNU,
23217         REPLACE_MALLOC_FOR_MALLOC_GNU, REPLACE_MALLOC_FOR_MALLOC_POSIX, not
23218         REPLACE_MALLOC.
23219         * modules/malloc-posix (Depends-on, configure.ac): Test
23220         REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
23221         * modules/malloc-gnu (Comment): Remove section.
23222         (Depends-on): Add xalloc-oversized.
23223         (configure.ac): Test REPLACE_MALLOC_FOR_MALLOC_GNU instead of
23224         REPLACE_MALLOC. Set a module indicator.
23225         * lib/stdlib.in.h (malloc): Test REPLACE_MALLOC_FOR_MALLOC_POSIX,
23226         REPLACE_MALLOC_FOR_MALLOC_GNU, and the respective module indicators
23227         instead of just REPLACE_MALLOC.
23229 2022-01-02  Bruno Haible  <bruno@clisp.org>
23231         striconveh: Make the last change also work on Solaris 11.
23232         * lib/striconveh.c (mem_cd_iconveh_internal): Tweak last commit.
23234         striconveh: Make the last change also work on musl libc.
23235         * lib/striconveh.c (mem_cd_iconveh_internal): Make the U+FFFD conversion
23236         also work with non-GNU iconv() implementations.
23238 2022-01-01  Paul Eggert  <eggert@cs.ucla.edu>
23240         gen-header: port to BusyBox ‘sed’
23241         Problem reported by Tim Rühsen in:
23242         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00004.html
23243         * modules/gen-header (SED_HEADER_NOEDIT): Replace instead of prepend.
23244         (SED_HEADER_STDOUT, SED_HEADER_TO_AT_t): Adjust to that change.
23245         Do not use ‘w foo’ twice in the same script, as BusyBox ‘sed’
23246         mistakenly opens ‘foo’ for output twice, thus losing some output.
23248 2022-01-01  Bruno Haible  <bruno@clisp.org>
23250         striconveh: Support an error handler that produces a Unicode U+FFFD.
23251         Suggested by Marc Nieper-Wißkirchen in
23252         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00175.html>.
23253         * lib/iconveh.h (iconveh_replacement_character): New enum value.
23254         * lib/striconveh.c (mem_cd_iconveh_internal): When the handler is
23255         iconveh_replacement_character, try to produce U+FFFD when possible,
23256         instead of '?'.
23257         * tests/test-striconveh.c (main): Add GB18030 tests. Test also
23258         iconveh_replacement_character.
23260 2022-01-01  Bruno Haible  <bruno@clisp.org>
23262         maint: Update copyright notices.
23263         * build-aux/declared.sh (func_version): Bump year.
23265 2022-01-01  Bruno Haible  <bruno@clisp.org>
23267         maint: Update copyright notices in code generating programs.
23268         * lib/gen-uni-tables.c (output_predicate_test, output_predicate,
23269         output_category, output_combclass, output_bidi_category,
23270         output_decimal_digit_test, output_decimal_digit, output_digit_test,
23271         output_digit, output_numeric_test, output_numeric, output_mirror,
23272         output_joining_type_test, output_joining_type,
23273         output_joining_group_test, output_joining_group, output_scripts,
23274         output_scripts_byname, output_blocks, output_ident_category,
23275         output_nonspacing_property, output_lbrk_tables,
23276         output_lbrk_rules_as_tables, output_wbrk_tables, output_gbp_test,
23277         output_gbp_table, output_decomposition_tables,
23278         output_composition_tables, output_simple_mapping_test,
23279         output_simple_mapping, output_casing_rules): Extend copyright year of
23280         generated file to 2022.
23281         * lib/uniname/gen-uninames.lisp (main): Likewise. Produce license notice
23282         that is consistent with the gnulib/etc/license-notices/ files.
23283         * All files regenerated.
23285 2022-01-01  Paul Eggert  <eggert@cs.ucla.edu>
23287         maint: fix ‘make update-copyright’ on symlinks
23288         After running ‘make update-copyright’ I noticed that it
23289         incorrectly replaced a couple of symlinks with their contents.
23290         * Makefile (update-copyright): Do not update symlinks.
23291         * etc/license-notices/GPL, etc/license-notices/LGPL:
23292         Change these back to symlinks.
23294 2021-12-31  Bruno Haible  <bruno@clisp.org>
23296         unistdio: Prefer newer version to older, buggy one.
23297         * modules/unistdio/ulc-vasnprintf (configure.ac): Bump required
23298         libunistring version. This is needed because of the heap overrun fix
23299         (2018-09-23) and the need to avoid %n on more platforms (2020-10-04).
23300         * modules/unistdio/ulc-asnprintf (configure.ac): Likewise.
23301         * modules/unistdio/ulc-asprintf (configure.ac): Likewise.
23302         * modules/unistdio/ulc-fprintf (configure.ac): Likewise.
23303         * modules/unistdio/ulc-snprintf (configure.ac): Likewise.
23304         * modules/unistdio/ulc-sprintf (configure.ac): Likewise.
23305         * modules/unistdio/ulc-vasprintf (configure.ac): Likewise.
23306         * modules/unistdio/ulc-vfprintf (configure.ac): Likewise.
23307         * modules/unistdio/ulc-vsnprintf (configure.ac): Likewise.
23308         * modules/unistdio/ulc-vsprintf (configure.ac): Likewise.
23310 2021-12-31  Bruno Haible  <bruno@clisp.org>
23312         uniwidth: Optimize.
23313         * lib/gen-uni-tables.c (output_nonspacing_property): Add version
23314         parameter. Emit the usual boilerplate header for generated files.
23315         (is_width2): New function, based on lib/uniwidth/width.c.
23316         (output_width2_property): New function.
23317         (main): Create uniwidth/width0.h instead of uniwidth/width.c.part.
23318         Create uniwidth/width2.h.
23319         * lib/uniwidth/width.c: Include width0.h, width2.h, bitmap.h.
23320         (nonspacing_table_data, nonspacing_table_ind): Remove here.
23321         (uc_width): Replace the double-width character with an u_width2 bitmap
23322         lookup.
23323         * modules/uniwidth/width (Files): Add lib/uniwidth/width0.h,
23324         lib/uniwidth/width2.h, lib/unictype/bitmap.h.
23326 2021-12-31  Bruno Haible  <bruno@clisp.org>
23328         Update to Unicode 14.0.0.
23330         * lib/gen-uni-tables.c (UC_JOINING_GROUP_THIN_YEH,
23331         UC_JOINING_GROUP_VERTICAL_TAIL): New enum values.
23332         (fill_arabicshaping, joining_group_as_c_identifier): Recognize these
23333         joining groups.
23334         * lib/unictype.in.h (UC_JOINING_GROUP_THIN_YEH,
23335         UC_JOINING_GROUP_VERTICAL_TAIL): New enum values.
23336         * lib/unictype/joininggroup_name.h: Add the THIN_YEH, VERTICAL_TAIL
23337         joining groups.
23338         * lib/unictype/joininggroup_byname.gperf: Likewise.
23340         * lib/gen-uni-tables.c (LBP_ID1, LBP_ID2): New enum values.
23341         (LBP_ID): Assign artificial value.
23342         (get_lbp): Use the extended_pictographic property to assign LBP_ID1,
23343         LBP_ID2 instead of LBP_ID. Update such that unilbrk/lbrkprop.txt comes
23344         out as expected.
23345         (debug_output_lbp): Print either LBP_ID1 or LBP_ID2 as LBP_ID.
23346         (lbp_value_to_string): Handle LBP_ID1, LBP_ID2 instead of LBP_ID.
23347         (output_lbrk_rules_as_tables): Treat LBP_ID as macro that maps to two
23348         table rows/columns. In rule LB30b, use LBP_ID2 in addition to LBP_EB.
23349         Remove redundant part of rule LB27.
23350         * lib/unilbrk/lbrktables.h (LBP_ID1, LBP_ID2): New enum values.
23351         (LBP_ID): Remove enum value.
23352         (unilbrk_table): Update declaration.
23353         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks_loop):
23354         Use LBP_ID1 instead of LBP_ID.
23355         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks_loop):
23356         Likewise.
23357         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks_loop):
23358         Likewise.
23359         * tests/unilbrk/test-u8-possible-linebreaks.c (test_function): Add a
23360         test of potential future emoji.
23361         * tests/unilbrk/test-u16-possible-linebreaks.c (test_function):
23362         Likewise.
23363         * tests/unilbrk/test-u32-possible-linebreaks.c (test_function):
23364         Likewise.
23366         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
23367         Update.
23368         (uc_width): Assign width 2 to the characters 0x1AFF0..0x1AFF3,
23369         0x1AFF5..0x1AFFB, 0x1AFFD..0x1AFFE, 0x1B120..0x1B122, 0x1F6DD..0x1F6DF,
23370         0x1F7F0, 0x1FA7B..0x1FA7C, 0x1FAA9..0x1FAAC, 0x1FAB7..0x1FABA,
23371         0x1FAC3..0x1FAC5, 0x1FAD7..0x1FAD9, 0x1FAE0..0x1FAE7, 0x1FAF0..0x1FAF6.
23372         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
23373         0x0890..0x0891, 0x0898..0x089F, 0x08CA..0x0902, 0x0C3C, 0x180F,
23374         0x1AC1..0x1ACE, 0x1DFA, 0x10F82..0x10F85, 0x11070, 0x11073..0x11074,
23375         0x110C2, 0x1CF00..0x1CF2D, 0x1CF30..0x1CF46, 0x1E2AE. Expect ambiguous
23376         width for the character 0x1734. Expect width 2 for the characters
23377         0x1AFF0..0x1AFF3, 0x1AFF5..0x1AFFB, 0x1AFFD..0x1AFFE, 0x1B120..0x1B122,
23378         0x1F6DD..0x1F6DF, 0x1F7F0, 0x1FA7B..0x1FA7C, 0x1FAA9..0x1FAAC,
23379         0x1FAB7..0x1FABA, 0x1FAC3..0x1FAC5, 0x1FAD7..0x1FAD9, 0x1FAE0..0x1FAE7,
23380         0x1FAF0..0x1FAF6.
23382         * All generated files under lib/uni* and tests/uni*: Regenerate.
23383         * tests/uniname/NameAliases.txt: Update.
23384         * tests/uniname/UnicodeData.txt: Update.
23385         * tests/uninorm/NormalizationTest.txt: Update.
23386         * tests/unigbrk/GraphemeBreakTest.txt: Update.
23387         * tests/uniwbrk/WordBreakTest.txt: Update.
23389         * All the affected modules: Bump required libunistring version.
23391 2021-12-31  Bruno Haible  <bruno@clisp.org>
23393         Update to Unicode 13.0.0.
23395         * lib/gen-uni-tables.c (is_WBP_MIDLETTER): Add character 0x055F.
23396         (get_wbp): Assign value WBP_ALETTER to the characters 0x02E5..0x02EB,
23397         0x055A, 0x058A, 0xA708..0xA716.
23399         * lib/gen-uni-tables.c (LBP_CP1, LBP_CP2, LBP_OP1, LBP_OP2): New enum
23400         values.
23401         (LBP_OP, LBP_CP): Assign artificial values.
23402         (get_lbp): Use the unicode_width[] table to assign LBP_CP1, LBP_CP2
23403         instead of LBP_CP, and LBP_OP1, LBP_OP2 instead of LBP_OP. Update such
23404         that unilbrk/lbrkprop.txt comes out as expected.
23405         (debug_output_lbp): Print either LBP_CP1 or LBP_CP2 as LBP_CP. Print
23406         either LBP_OP1 or LBP_OP2 as LBP_OP.
23407         (lbp_value_to_string): Handle LBP_CP1, LBP_CP2, LBP_OP1, LBP_OP2 instead
23408         of LBP_CP, LBP_OP.
23409         (output_lbrk_rules_as_tables): Treat LBP_CP and LBP_OP as macros that
23410         map to two table rows/columns. In rule LB30, use only LBP_OP1 instead of
23411         LBP_OP, and only LBP_CP1 instead of LBP_CP. Simplify rule LB22.
23412         * lib/unilbrk/lbrktables.h (LBP_CP1, LBP_CP2, LBP_OP1, LBP_OP2): New
23413         enum values.
23414         (LBP_OP, LBP_CP): Remove enum values.
23415         (unilbrk_table): Update declaration.
23416         * tests/unilbrk/test-u8-possible-linebreaks.c (test_function): Add a
23417         test for East Asian opening parenthesis.
23418         * tests/unilbrk/test-u16-possible-linebreaks.c (test_function):
23419         Likewise.
23420         * tests/unilbrk/test-u32-possible-linebreaks.c (test_function):
23421         Likewise.
23423         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
23424         Update.
23425         (uc_width): Assign width 2 to the characters 0x16FF0..0x16FF1,
23426         0x18AF3..0x18CD5, 0x18D00..0x18D08, 0x1F6D6..0x1F6D7, 0x1F6FB..0x1F6FC,
23427         0x1F90C, 0x1FA74, 0x1FA83..0x1FA86, 0x1FA96..0x1FAA8, 0x1FAB0..0x1FAB6,
23428         0x1FAC0..0x1FAC2, 0x1FAD0..0x1FAD6.
23429         Assign width 1 to the characters 0x1F93B, 0x1F946.
23430         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
23431         0x0B55, 0x0D81, 0x1ABF..0x1AC0, 0xA82C, 0x10EAB..0x10EAC, 0x111CF,
23432         0x1193B..0x1193C, 0x1193E, 0x11943, 0x16FE4. Expect width 2 for the
23433         characters 0x16FF0..0x16FF1, 0x18AF3..0x18CD5, 0x18D00..0x18D08,
23434         0x1F6D6..0x1F6D7, 0x1F6FB..0x1F6FC, 0x1F90C, 0x1FA74, 0x1FA83..0x1FA86,
23435         0x1FA96..0x1FAA8, 0x1FAB0..0x1FAB6, 0x1FAC0..0x1FAC2, 0x1FAD0..0x1FAD6.
23436         Expect width 1 for the characters 0x1F93B, 0x1F946.
23438         * All generated files under lib/uni* and tests/uni*: Regenerate.
23439         * tests/uniname/NameAliases.txt: Update.
23440         * tests/uniname/UnicodeData.txt: Update.
23441         * tests/uninorm/NormalizationTest.txt: Update.
23442         * tests/unigbrk/GraphemeBreakTest.txt: Update.
23443         * tests/uniwbrk/WordBreakTest.txt: Update.
23445         * All the affected modules: Bump required libunistring version.
23447 2021-12-30  Bruno Haible  <bruno@clisp.org>
23449         uniwbrk: Correction of Unicode 10.0.0 support.
23450         * lib/gen-uni-tables.c (is_WBP_MIDLETTER): Remove character 0x02D7.
23451         The generated files are not affected.
23453 2021-12-30  Bruno Haible  <bruno@clisp.org>
23455         Update to Unicode 12.1.0.
23457         * lib/gen-uni-tables.c: Update comments.
23459         * All generated files under lib/uni* and tests/uni*: Regenerate.
23460         * tests/uniname/NameAliases.txt: Update.
23461         * tests/uniname/UnicodeData.txt: Update.
23462         * tests/uninorm/NormalizationTest.txt: Update.
23463         * tests/unigbrk/GraphemeBreakTest.txt: Update.
23464         * tests/uniwbrk/WordBreakTest.txt: Update.
23466         * All the affected modules: Bump required libunistring version.
23468 2021-12-30  Bruno Haible  <bruno@clisp.org>
23470         Update to Unicode 12.0.0.
23472         * lib/gen-uni-tables.c (is_property_default_ignorable_code_point):
23473         Exclude 0x13430..0x13438.
23474         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
23475         (get_wbp): Map 0xFF10..0xFF19 to WBP_NUMERIC.
23477         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
23478         Update.
23479         (uc_width): Assign width 2 to the characters 0x16FE2..0x16FE3,
23480         0x187F2..0x187F7, 0x1B150..0x1B152, 0x1B164..0x1B167, 0x1F6D5, 0x1F6FA,
23481         0x1F7E0..0x1F7EB, 0x1F90D..0x1F90F, 0x1FA70..0x1FA73, 0x1FA78..0x1FA7A,
23482         0x1FA80..0x1FA82, 0x1FA90..0x1FA95.
23483         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
23484         0x0EBA, 0xA9BD, 0x119D4..0x119D7, 0x119DA..0x119DB, 0x119E0,
23485         0x13430..0x13438, 0x16F4F, 0x1E130..0x1E136, 0x1E2EC..0x1E2EF. Expect
23486         width 2 for the characters 0x16FE2..0x16FE3, 0x187F2..0x187F7,
23487         0x1B150..0x1B152, 0x1B164..0x1B167, 0x1F6D5, 0x1F6FA, 0x1F7E0..0x1F7EB,
23488         0x1F90D..0x1F90F, 0x1FA70..0x1FA73, 0x1FA78..0x1FA7A, 0x1FA80..0x1FA82,
23489         0x1FA90..0x1FA95.
23491         * All generated files under lib/uni* and tests/uni*: Regenerate.
23492         * tests/uniname/NameAliases.txt: Update.
23493         * tests/uniname/UnicodeData.txt: Update.
23494         * tests/uninorm/NormalizationTest.txt: Update.
23495         * tests/unigbrk/GraphemeBreakTest.txt: Update.
23496         * tests/uniwbrk/WordBreakTest.txt: Update.
23498         * All the affected modules: Bump required libunistring version.
23500 2021-12-30  Paul Eggert  <eggert@cs.ucla.edu>
23502         crypto/sm3-buffer: fix C99 conformance bug
23503         * lib/sm3.c (sm3_process_block): Call varargs macro with enough
23504         arguments.  Problem found by IBM XL/C 12.1.0.0 for AIX.
23506 2021-12-30  Bruno Haible  <bruno@clisp.org>
23508         Update to Unicode 11.0.0.
23510         * lib/gen-uni-tables.c (is_property_default_ignorable_code_point):
23511         Simplify by use of PROP_PREPENDED_CONCATENATION_MARK.
23512         (UC_JOINING_GROUP_HANIFI_ROHINGYA_PA,
23513         UC_JOINING_GROUP_HANIFI_ROHINGYA_KINNA_YA): New enum values.
23514         (fill_arabicshaping, joining_group_as_c_identifier): Recognize these
23515         joining groups.
23516         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
23517         (WBP_EB, WBP_EM, WBP_GAZ, WBP_EBG): Remove enum values.
23518         (WBP_WSS): New enum value.
23519         (get_wbp): Update such that uniwbrk/wbrkprop.txt comes out as expected.
23520         (debug_output_wbp, fill_org_wbp, debug_output_org_wbp, output_wbp):
23521         Update for changed enum values.
23523         * lib/unictype.in.h (UC_JOINING_GROUP_HANIFI_ROHINGYA_*): New enum
23524         values.
23525         * lib/unictype/joininggroup_name.h: Add the HANIFI_ROHINGYA_* joining
23526         groups.
23527         * lib/unictype/joininggroup_byname.gperf: Likewise.
23529         * lib/unigbrk.in.h: Mark 4 enum values as obsolete.
23530         * lib/unigbrk/u-grapheme-breaks.h (FUNC): Handle emoji modifier sequence
23531         according to Unicode 11.0.0.
23532         * lib/unigbrk/u8-grapheme-breaks.c: Include <stdbool.h>, unictype.h.
23533         * lib/unigbrk/u16-grapheme-breaks.c: Likewise.
23534         * lib/unigbrk/u32-grapheme-breaks.c: Likewise.
23535         * lib/unigbrk/uc-grapheme-breaks.c: Likewise.
23536         * modules/unigbrk/u8-grapheme-breaks (Depends-on): Add
23537         unictype/property-extended-pictographic, stdbool.
23538         * modules/unigbrk/u16-grapheme-breaks (Depends-on): Likewise.
23539         * modules/unigbrk/u32-grapheme-breaks (Depends-on): Likewise.
23540         * modules/unigbrk/uc-grapheme-breaks (Depends-on): Likewise.
23541         * tests/unigbrk/test-u8-grapheme-breaks.c (main): Add test for emoji
23542         modifier / ZWJ sequence.
23543         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
23544         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
23545         * tests/unigbrk/test-uc-is-grapheme-break.c: Include <stdbool.h>,
23546         unictype.h.
23547         (main): Update workaround logic to match the one in
23548         lib/unigbrk/u-grapheme-breaks.h.
23549         * modules/unigbrk/uc-is-grapheme-break-tests (Depends-on): Add
23550         unictype/property-extended-pictographic, stdbool.
23552         * lib/uniwbrk.in.h: Mark 4 enum values as obsolete.
23553         (WBP_WSS): New enum value.
23554         * lib/uniwbrk/u-wordbreaks.h (FUNC): Handle emoji ZWJ sequences and
23555         horizontal whitespace according to Unicode 11.0.0.
23556         * lib/uniwbrk/u8-wordbreaks.c: Include unictype.h.
23557         * lib/uniwbrk/u16-wordbreaks.c: Likewise.
23558         * lib/uniwbrk/u32-wordbreaks.c: Likewise.
23559         * lib/uniwbrk/wbrktable.c (uniwbrk_prop_index, uniwbrk_table): Add a row
23560         and column for WBP_WSS.
23561         * lib/uniwbrk/wbrktable.h (uniwbrk_prop_index, uniwbrk_table): Update
23562         declarations.
23563         * modules/uniwbrk/u8-wordbreaks (Depends-on): Add
23564         unictype/property-extended-pictographic.
23565         * modules/uniwbrk/u16-wordbreaks (Depends-on): Likewise.
23566         * modules/uniwbrk/u32-wordbreaks (Depends-on): Likewise.
23567         * tests/uniwbrk/test-u8-wordbreaks.c (main): Update expected results.
23568         * tests/uniwbrk/test-u16-wordbreaks.c (main): Likewise.
23569         * tests/uniwbrk/test-u32-wordbreaks.c (main): Likewise.
23570         * tests/uniwbrk/test-uc-wordbreaks.c (wordbreakproperty_to_string):
23571         Update.
23573         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks_loop):
23574         Handle ZWJ according to Unicode 11.0.0.
23575         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks_loop):
23576         Likewise.
23577         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks_loop):
23578         Likewise.
23580         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
23581         Update.
23582         (uc_width): Assign width 2 to the characters 0x187ED..0x187F1, 0x1F6F9,
23583         0x1F9E7..0x1F9FF.
23584         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
23585         0x07FD, 0x08D3, 0x09FE, 0x0C04, 0xA8FF, 0x10D24..0x10D27,
23586         0x10F46..0x10F50, 0x110CD, 0x111C9, 0x1133B, 0x1145E, 0x1182F..0x11837,
23587         0x11839..0x1183A, 0x11D90..0x11D91, 0x11D95, 0x11D97, 0x11EF3..0x11EF4.
23588         Expect width 2 for the characters 0x187ED..0x187F1, 0x1F6F9,
23589         0x1F9E7..0x1F9FF.
23591         * All generated files under lib/uni* and tests/uni*: Regenerate.
23592         * tests/uniname/NameAliases.txt: Update.
23593         * tests/uniname/UnicodeData.txt: Update.
23594         * tests/uninorm/NormalizationTest.txt: Update.
23595         * tests/unigbrk/GraphemeBreakTest.txt: Update.
23596         * tests/uniwbrk/WordBreakTest.txt: Update.
23598         * All the affected modules: Bump required libunistring version.
23600 2021-12-30  Bruno Haible  <bruno@clisp.org>
23602         unictype: Add Emoji properties from Unicode 11.0.0.
23603         * lib/gen-uni-tables.c (PROP_EMOJI*, PROP_EXTENDED_PICTOGRAPHIC): New
23604         enum values.
23605         (fill_properties): Don't require a space between the property name and
23606         the comment. Handle the property names from emoji-data.txt.
23607         (is_property_emoji, is_property_emoji_presentation,
23608         is_property_emoji_modifier, is_property_emoji_modifier_base,
23609         is_property_emoji_component, is_property_extended_pictographic): New
23610         declarations.
23611         (output_properties): Emit the properties emoji, emoji_presentation,
23612         emoji_modifier, emoji_modifier_base, emoji_component,
23613         extended_pictographic.
23614         (get_lbp): Use the emoji_modifier property.
23615         (main): Expect one more argument, for the emoji-data.txt file.
23616         * lib/unictype.in.h (UC_PROPERTY_EMOJI, UC_PROPERTY_EMOJI_PRESENTATION,
23617         UC_PROPERTY_EMOJI_MODIFIER, UC_PROPERTY_EMOJI_MODIFIER_BASE,
23618         UC_PROPERTY_EMOJI_COMPONENT, UC_PROPERTY_EXTENDED_PICTOGRAPHIC,
23619         uc_is_property_emoji, uc_is_property_emoji_presentation,
23620         uc_is_property_emoji_modifier, uc_is_property_emoji_modifier_base,
23621         uc_is_property_emoji_component, uc_is_property_extended_pictographic):
23622         New declarations.
23623         * lib/unictype/pr_emoji.c: New file.
23624         * lib/unictype/pr_emoji_presentation.c: New file.
23625         * lib/unictype/pr_emoji_modifier.c: New file.
23626         * lib/unictype/pr_emoji_modifier_base.c: New file.
23627         * lib/unictype/pr_emoji_component.c: New file.
23628         * lib/unictype/pr_extended_pictographic.c: New file.
23629         * modules/unictype/property-emoji: New file.
23630         * modules/unictype/property-emoji-tests: New file.
23631         * modules/unictype/property-emoji-presentation: New file.
23632         * modules/unictype/property-emoji-presentation-tests: New file.
23633         * modules/unictype/property-emoji-modifier: New file.
23634         * modules/unictype/property-emoji-modifier-tests: New file.
23635         * modules/unictype/property-emoji-modifier-base: New file.
23636         * modules/unictype/property-emoji-modifier-base-tests: New file.
23637         * modules/unictype/property-emoji-component: New file.
23638         * modules/unictype/property-emoji-component-tests: New file.
23639         * modules/unictype/property-extended-pictographic: New file.
23640         * modules/unictype/property-extended-pictographic-tests: New file.
23641         * modules/unictype/property-all (Depends-on): Depend on the new modules.
23643 2021-12-29  Bruno Haible  <bruno@clisp.org>
23645         uniwidth: Give width 0 to conjoining Hangul Jamo jungseong, jongseong.
23646         Reported by Luis Javier Merino <ninjalj@gmail.com> in
23647         <https://lists.gnu.org/archive/html/bug-libunistring/2021-12/msg00006.html>.
23648         * lib/gen-uni-tables.c (is_nonspacing): Return true for the conjoining
23649         Hangul Jamo jungseong and jongseong characters.
23650         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
23651         Regenerated.
23652         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
23653         0x1160..0x11FF, 0xD7B0..0xD7C6, 0xD7CB..0xD7FB.
23655 2021-12-29  Bruno Haible  <bruno@clisp.org>
23657         uniwidth: Update to Unicode 10.0.0.
23658         * lib/uniwidth/width.c (uc_width): Assign width 2 to the characters
23659         0x231A..0x231B, 0x23E9..0x23EC, 0x23F0, 0x23F3, 0x25FD..0x25FE,
23660         0x2614..0x2615, 0x2648..0x2653, 0x267F, 0x2693, 0x26A1, 0x26AA..0x26AB,
23661         0x26BD..0x26BE, 0x26C4..0x26C5, 0x26CE, 0x26D4, 0x26EA, 0x26F2..0x26F3,
23662         0x26F5, 0x26FA, 0x26FD, 0x2705, 0x270A..0x270B, 0x2728, 0x274C, 0x274E,
23663         0x2753..0x2755, 0x2757, 0x2795..0x2797, 0x27B0, 0x27BF, 0x2B1B..0x2B1C,
23664         0x2B50, 0x2B55, 0xA960..0xA97C, 0x16FE0..0x16FE1, 0x17000..0x187EC,
23665         0x18800..0x18AF2, 0x1B000..0x1B11F, 0x1B170..0x1B2FB, 0x1F004, 0x1F0CF,
23666         0x1F18E, 0x1F191..0x1F19A, 0x1F200..0x1F320, 0x1F32D..0x1F335,
23667         0x1F337..0x1F37C, 0x1F37E..0x1F393, 0x1F3A0..0x1F3CA, 0x1F3CF..0x1F3D3,
23668         0x1F3E0..0x1F3F0, 0x1F3F4, 0x1F3F8..0x1F43E, 0x1F440, 0x1F442..0x1F4FC,
23669         0x1F4FF..0x1F53D, 0x1F54B..0x1F54E, 0x1F550..0x1F567, 0x1F57A,
23670         0x1F595..0x1F596, 0x1F5A4, 0x1F5FB..0x1F64F, 0x1F680..0x1F6C5, 0x1F6CC,
23671         0x1F6D0..0x1F6D2, 0x1F6EB..0x1F6EC, 0x1F6F4..0x1F6F8, 0x1F910..0x1F9E6.
23672         Assign ambiguous width to the characters 0x3248..0x324F.
23673         * tests/uniwidth/test-uc_width2.sh: Expect these changes.
23675 2021-12-29  Bruno Haible  <bruno@clisp.org>
23677         unilbrk: Improve support for strings that contain CR-LF sequences.
23678         * lib/gen-uni-tables.c (LBP_CR, LBP_LF): New enum values.
23679         (get_lbp): For '\r' and '\n', return LBP_CR and LBP_LF, respectively,
23680         instead of LBP_BK.
23681         (debug_output_lbp, fill_org_lbp, debug_output_org_lbp,
23682         lbp_value_to_string): Handle LBP_CR, LBP_LF.
23683         * lib/unilbrk/lbrkprop2.h: Regenerated.
23684         * lib/unilbrk/lbrktables.h (LBP_CR, LBP_LF): New enum values.
23685         * lib/unilbrk.in.h (UC_BREAK_CR_BEFORE_LF): New enum value.
23686         (u8_possible_linebreaks, u16_possible_linebreaks,
23687         u32_possible_linebreaks, ulc_possible_linebreaks, u8_width_linebreaks,
23688         u16_width_linebreaks, u32_width_linebreaks, ulc_width_linebreaks):
23689         Declare also a _v2 variant, and use a C macro to activate it by default.
23690         * lib/unilbrk/internal.h: New file.
23691         * lib/unilbrk/u8-possible-linebreaks.c: Include unilbrk/internal.h.
23692         (u8_possible_linebreaks_loop): Renamed from u8_possible_linebreaks. Add
23693         'cr' parameter.
23694         (u8_possible_linebreaks, u8_possible_linebreaks_v2): New functions.
23695         (main): Update.
23696         * lib/unilbrk/u16-possible-linebreaks.c: Include unilbrk/internal.h.
23697         (u16_possible_linebreaks_loop): Renamed from u16_possible_linebreaks.
23698         Add 'cr' parameter.
23699         (u16_possible_linebreaks, u16_possible_linebreaks_v2): New functions.
23700         * lib/unilbrk/u32-possible-linebreaks.c: Include unilbrk/internal.h.
23701         (u32_possible_linebreaks_loop): Renamed from u32_possible_linebreaks.
23702         Add 'cr' parameter.
23703         (u32_possible_linebreaks, u32_possible_linebreaks_v2): New functions.
23704         * lib/unilbrk/ulc-possible-linebreaks.c: Include unilbrk/internal.h,
23705         unilbrk/lbrktables.h.
23706         (ulc_possible_linebreaks_internal): Renamed from
23707         ulc_possible_linebreaks. Add 'cr' parameter.
23708         (ulc_possible_linebreaks, ulc_possible_linebreaks_v2): New functions.
23709         (main): Update.
23710         * lib/unilbrk/u8-width-linebreaks.c: Include unilbrk/internal.h,
23711         unilbrk/lbrktables.h.
23712         (u8_width_linebreaks_internal): Renamed from u8_width_linebreaks. Add
23713         'cr' parameter.
23714         (u8_width_linebreaks, u8_width_linebreaks_v2): New functions.
23715         (main): Update.
23716         * lib/unilbrk/u16-width-linebreaks.c: Include unilbrk/internal.h,
23717         unilbrk/lbrktables.h.
23718         (u16_width_linebreaks_internal): Renamed from u16_width_linebreaks. Add
23719         'cr' parameter.
23720         (u16_width_linebreaks, u16_width_linebreaks_v2): New functions.
23721         * lib/unilbrk/u32-width-linebreaks.c: Include unilbrk/internal.h,
23722         unilbrk/lbrktables.h.
23723         (u32_width_linebreaks_internal): Renamed from u32_width_linebreaks. Add
23724         'cr' parameter.
23725         (u32_width_linebreaks, u32_width_linebreaks_v2): New functions.
23726         * lib/unilbrk/ulc-width-linebreaks.c: Include unilbrk/internal.h,
23727         unilbrk/lbrktables.h.
23728         (ulc_width_linebreaks_internal): Renamed from ulc_width_linebreaks. Add
23729         'cr' parameter.
23730         (ulc_width_linebreaks, ulc_width_linebreaks_v2): New functions.
23731         (main): Update.
23732         * modules/unilbrk/u8-possible-linebreaks (Files): Add
23733         lib/unilbrk/internal.h.
23734         * modules/unilbrk/u16-possible-linebreaks (Files): Likewise.
23735         * modules/unilbrk/u32-possible-linebreaks (Files): Likewise.
23736         * modules/unilbrk/u8-width-linebreaks (Files): Likewise.
23737         * tests/unilbrk/test-u8-possible-linebreaks.c (test_function): New
23738         function, extracted from main. Add a test of CR-LF handling.
23739         (main): Invoke it twice.
23740         * tests/unilbrk/test-u16-possible-linebreaks.c (test_function): New
23741         function, extracted from main. Add a test of CR-LF handling.
23742         (main): Invoke it twice.
23743         * tests/unilbrk/test-u32-possible-linebreaks.c (test_function): New
23744         function, extracted from main. Add a test of CR-LF handling.
23745         (main): Invoke it twice.
23746         * tests/unilbrk/test-ulc-possible-linebreaks.c (test_function): New
23747         function, extracted from main.
23748         (main): Invoke it twice.
23749         * tests/unilbrk/test-u8-width-linebreaks.c (test_function): New
23750         function, extracted from main.
23751         (main): Invoke it twice.
23752         * tests/unilbrk/test-u16-width-linebreaks.c (test_function): New
23753         function, extracted from main.
23754         (main): Invoke it twice.
23755         * tests/unilbrk/test-u32-width-linebreaks.c (test_function): New
23756         function, extracted from main.
23757         (main): Invoke it twice.
23758         * tests/unilbrk/test-ulc-width-linebreaks.c (test_function): New
23759         function, extracted from main.
23760         (main): Invoke it twice.
23762 2021-12-29  Bruno Haible  <bruno@clisp.org>
23764         uniwbrk: Add unit tests of CR-LF sequences.
23765         * tests/uniwbrk/test-u8-wordbreaks.c (main): Add test of a string with
23766         CR-LF.
23767         * tests/uniwbrk/test-u16-wordbreaks.c (main): Likewise.
23768         * tests/uniwbrk/test-u32-wordbreaks.c (main): Likewise.
23770 2021-12-29  Bruno Haible  <bruno@clisp.org>
23772         unigbrk: Add unit tests of CR-LF sequences.
23773         * tests/unigbrk/test-u8-grapheme-breaks.c (main): Add test of a string
23774         with CR-LF.
23775         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
23776         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
23778 2021-12-29  Bruno Haible  <bruno@clisp.org>
23780         unilbrk: Update handling of Hebrew letter + hyphen for Unicode 10.0.0.
23781         * lib/unilbrk/lbrktables.h (LBP_HL_BA): New enum value.
23782         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Add
23783         code for handling break-after character after Hebrew letter.
23784         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
23785         Likewise.
23786         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
23787         Likewise.
23788         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
23789         regarding break-after character after Hebrew letter.
23790         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
23791         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
23793 2021-12-28  Paul Eggert  <eggert@cs.ucla.edu>
23795         nstrftime: improve handling of invalid formats
23796         * lib/nstrftime.c (__strftime_internal): Without this change,
23797         ‘date +'%0_-+^#1%A'’ would output ‘%A’; with it, it outputs
23798         something like ‘%0_-+^#1Tuesday’ which is easier to debug and to
23799         write wrappers for (such as the nstrftime/fprintftime usage in GNU
23800         ‘date’).
23802 2021-12-28  Bruno Haible  <bruno@clisp.org>
23804         unilbrk: Update handling of regional indicators for Unicode 10.0.0.
23805         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Add
23806         code for handling regional indicators.
23807         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
23808         Likewise.
23809         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
23810         Likewise.
23811         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
23812         regarding regional indicators.
23813         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
23814         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
23816 2021-12-28  Bruno Haible  <bruno@clisp.org>
23818         unilbrk: Update handling of zero-width joiner for Unicode 10.0.0.
23819         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Update
23820         code for zero-width joiner handling to match UAX #14 for Unicode 10.0.0.
23821         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
23822         Likewise.
23823         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
23824         Likewise.
23825         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
23826         regarding zero-width joiner.
23827         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
23828         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
23830 2021-12-28  Bruno Haible  <bruno@clisp.org>
23832         unilbrk: Update handling of combining marks for Unicode 10.0.0.
23833         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Update
23834         code for combining characters to match UAX #14 for Unicode 10.0.0.
23835         Remove legacy support for space + combining mark.
23836         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
23837         Likewise.
23838         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
23839         Likewise.
23840         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
23841         regarding combining characters.
23842         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
23843         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
23845 2021-12-28  Bruno Haible  <bruno@clisp.org>
23847         unilbrk: Restore deviation for (IS,AL) pair.
23848         * lib/gen-uni-tables.c (output_lbrk_rules_as_tables): Disable rule LB29.
23849         * lib/unilbrk/lbrktables.c: Regenerated.
23850         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add test case with
23851         HTML markup.
23852         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
23853         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
23854         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
23856 2021-12-28  Bruno Haible  <bruno@clisp.org>
23858         unilbrk: Change algorithm to be closer to Unicode Standard Annex #14.
23859         * lib/gen-uni-tables.c (lbp_value_to_string): New function, extracted
23860         from output_lbp.
23861         (output_lbp): Invoke it.
23862         (output_lbrk_rules_as_tables): New function.
23863         (main): Invoke it.
23864         * lib/unilbrk/lbrktables.c: Now automatically generated.
23865         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update expected
23866         result.
23867         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
23868         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
23869         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
23870         * tests/unilbrk/test-ulc-width-linebreaks.c (main): Likewise.
23872 2021-12-28  Bruno Haible  <bruno@clisp.org>
23874         uniwbrk: Add unit tests of regional indicators.
23875         * tests/uniwbrk/test-u8-wordbreaks.c (main): Add test of regional
23876         indicators.
23877         * tests/uniwbrk/test-u16-wordbreaks.c (main): Likewise.
23878         * tests/uniwbrk/test-u32-wordbreaks.c (main): Likewise.
23880 2021-12-28  Bruno Haible  <bruno@clisp.org>
23882         unigbrk: Simplify code for regional indicators.
23883         * lib/unigbrk/u-grapheme-breaks.h (FUNC): Make code for regional
23884         indicators more future-proof.
23885         * tests/unigbrk/test-u8-grapheme-breaks.c (main): Add test of regional
23886         indicators.
23887         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
23888         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
23890 2021-12-28  Paul Eggert  <eggert@cs.ucla.edu>
23892         clock_getres: document portability issues better
23893         * doc/posix-functions/clock_getres.texi:
23894         * doc/posix-functions/timespec_getres.texi:
23895         Document problems with timestamp resolution.
23897         timespec_getres: new module
23898         * lib/time.in.h (timespec_getres): New decl.
23899         * lib/timespec_getres.c, m4/timespec_getres.m4:
23900         * modules/timespec_getres, modules/timespec_getres-tests:
23901         * tests/test-timespec_getres.c:
23902         New files.
23903         * m4/time_h.m4 (gl_TIME_H_REQUIRE_DEFAULTS, gl_TIME_H_DEFAULTS):
23904         * modules/time (time.h):
23905         Support timespec_getres.
23907         gettime-res: new module
23908         * lib/gettime-res.c, modules/gettime-res: New files.
23909         * lib/timespec.h (gettime_res): New decl.
23910         * m4/clock_time.m4 (gl_CLOCK_TIME): Also check for clock_getres.
23911         * m4/gettime.m4 (gl_GETTIME_RES): New macro.
23913         gettime: port better to non-POSIX C2x
23914         C2x requires a function timespec_get; prefer that to
23915         gettimeofday, since it has better resolution.
23916         * lib/gettime.c (gettime): Prefer timespec_get to gettimeofday.
23917         * m4/gettime.m4 (gl_GETTIME): Check for timespec_get.
23918         Omit a check for gettimeofday; not needed because
23919         the gettime module depends on the gettimeofday module.
23921 2021-12-28  Bruno Haible  <bruno@clisp.org>
23923         gen-uni-tables: Produce license notices suitable for Gnulib.
23924         * lib/gen-uni-tables.c (output_library_license, output_tests_license):
23925         Produce license notices that are consistent with the
23926         gnulib/etc/license-notices/ files.
23927         * All generated files under lib/uni* and tests/uni*: Regenerate.
23929 2021-12-28  Bruno Haible  <bruno@clisp.org>
23931         unigbrk, uniwbrk: No-op tweaks.
23932         * lib/unigbrk/u-grapheme-breaks.h: Comment tweaks.
23933         * lib/uniwbrk/u-wordbreaks.h: Coding style and comment tweaks.
23934         * lib/uniwbrk/wbrktable.c: Comment tweaks.
23936 2021-12-28  Paul Eggert  <eggert@cs.ucla.edu>
23938         perl: let caller see whether perl was found
23939         Problem reported for coreutils by Serge Belyshev (Bug#52844).
23940         * m4/perl.m4 (gl_PERL): Use AC_CACHE_CHECK, so that
23941         an invoker of gl_PERL can later inspect gl_cv_prog_perl
23942         to see whether perl was found.
23944 2021-12-28  Bruno Haible  <bruno@clisp.org>
23946         Fix --automake-subdir breakage (regression 2021-12-24).
23947         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
23948         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00156.html>.
23949         * build-aux/prefix-gnulib-mk (prefix_assignment): Don't change
23950         SED_HEADER_* variables.
23952 2021-12-26  Bruno Haible  <bruno@clisp.org>
23954         Update to Unicode 10.0.0.
23956         * lib/gen-uni-tables.c (PROP_REGIONAL_INDICATOR): New enum value.
23957         (fill_properties): Recognize property "Regional_Indicator".
23958         (is_property_regional_indicator): New function.
23959         (output_properties): Also output the data for regional_indicator.
23960         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
23961         Use is_property_regional_indicator.
23962         (get_wbp): Update such that uniwbrk/wbrkprop.txt comes out as expected.
23963         Use is_property_regional_indicator.
23964         (UC_JOINING_GROUP_MALAYALAM_*): New enum values.
23965         (fill_arabicshaping, joining_group_as_c_identifier): Recognize these
23966         joining groups.
23968         * lib/uniname/gen-uninames.lisp (main): Ignore empty lines and comment
23969         lines in the aliases file. Needed because since 2015-06-20, we use the
23970         unmodified Unicode NameAliases.txt file. Remove reference to undefined
23971         variable. Correct indentation.
23973         * lib/unictype.in.h (UC_PROPERTY_REGIONAL_INDICATOR,
23974         uc_is_property_regional_indicator): New declarations.
23975         * lib/unictype/pr_regional_indicator.c: New file.
23976         * modules/unictype/property-regional-indicator: New file.
23977         * modules/unictype/property-regional-indicator-tests: New file.
23978         * modules/unictype/property-all (Depends-on): Add
23979         unictype/property-regional-indicator.
23981         * lib/unictype.in.h (UC_JOINING_GROUP_MALAYALAM_*): New enum values.
23982         * lib/unictype/joininggroup_name.h: Add the MALAYALAM_* joining groups.
23983         * lib/unictype/joininggroup_byname.gperf: Likewise.
23985         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
23986         Update.
23987         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
23988         0x0AFA..0x0AFF, 0x0D00, 0x0D3B..0x0D3C, 0x1DF6..0x1DF9,
23989         0x11A01..0x11A06, 0x11A09..0x11A0A, 0x11A33..0x11A38, 0x11A3B..0x11A3E,
23990         0x11A47, 0x11A51..0x11A56, 0x11A59..0x11A5B, 0x11A8A..0x11A96,
23991         0x11A98..0x11A99, 0x11D31..0x11D36, 0x11D3A, 0x11D3C..0x11D3D,
23992         0x11D3F..0x11D45, 0x11D47.
23994         * All generated files under lib/uni* and tests/uni*: Regenerate.
23995         * tests/uniname/NameAliases.txt: Update.
23996         * tests/uniname/UnicodeData.txt: Update.
23997         * tests/uninorm/NormalizationTest.txt: Update.
23998         * tests/unigbrk/GraphemeBreakTest.txt: Update.
23999         * tests/uniwbrk/WordBreakTest.txt: Update.
24001         * All the affected modules: Bump required libunistring version.
24003 2021-12-26  Bruno Haible  <bruno@clisp.org>
24005         pselect: Fix compilation error in C++ mode on AIX 7.
24006         * lib/sys_select.in.h (pselect): Use _GL_CXXALIAS_SYS_CAST instead of
24007         _GL_CXXALIAS_SYS.
24008         * doc/posix-functions/pselect.texi: Mention the AIX problem.
24010 2021-12-25  Bruno Haible  <bruno@clisp.org>
24012         gnulib-tool: Fix handling of module libtextstyle-optional.
24013         Reported by Paul Eggert in
24014         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00152.html>.
24015         * gnulib-tool (func_repeat_module_in_tests): New function.
24016         (func_emit_tests_Makefile_am, func_create_testdir): Use it for the file
24017         list and when creating tests/Makefile.am.
24019 2021-12-25  Bruno Haible  <bruno@clisp.org>
24021         gnulib-tool: Respect applicability 'all' without --single-configure.
24022         * gnulib-tool (func_verify_tests_module): Treat modules with
24023         applicability 'all' like 'tests' modules, not like 'main' modules.
24025 2021-12-24  Paul Eggert  <eggert@cs.ucla.edu>
24027         maint: avoid empty lines in recipes
24028         AIX 7.2 ‘make’ complains about recipe lines that are empty after
24029         macro expansion, and I suppose there’s a good chance some
24030         non-POSIX ‘make’ would prohibit them.  Rework macros so
24031         that we can avoid them.
24032         * gnulib-tool (func_emit_lib_Makefile_am)
24033         (func_emit_tests_Makefile_am): Support @!NMD@ too.
24034         * modules/gen-header (@gl_V_at): New macro.
24035         * modules/alloca-opt, modules/argz, modules/assert-h:
24036         * modules/byteswap, modules/configmake, modules/ctype:
24037         * modules/dirent, modules/errno, modules/execinfo, modules/fcntl-h:
24038         * modules/float, modules/fnmatch-h, modules/getopt-posix:
24039         * modules/glob-h, modules/iconv-h, modules/ieee754-h:
24040         * modules/inttypes-incomplete, modules/langinfo:
24041         * modules/libtextstyle-optional, modules/limits-h, modules/locale:
24042         * modules/malloc-h, modules/math, modules/monetary, modules/netdb:
24043         * modules/openmp-init, modules/poll-h, modules/posix-shell:
24044         * modules/pthread-h, modules/pty, modules/sched, modules/search:
24045         * modules/signal-h, modules/sigsegv, modules/snippet/link-warning:
24046         * modules/spawn, modules/stdalign, modules/stdarg, modules/stdbool:
24047         * modules/stddef, modules/stdint, modules/stdio, modules/stdlib:
24048         * modules/stdnoreturn, modules/string, modules/strings:
24049         * modules/sysexits, modules/termios, modules/threads-h:
24050         * modules/time, modules/uchar, modules/unicase/base:
24051         * modules/uniconv/base, modules/unictype/base, modules/unigbrk/base:
24052         * modules/unilbrk/base, modules/uniname/base, modules/uninorm/base:
24053         * modules/unistd, modules/unistdio/base, modules/unistr/base:
24054         * modules/unitypes, modules/uniwbrk/base, modules/uniwidth/base:
24055         * modules/utime-h, modules/wchar, modules/wctype-h:
24056         Use it.
24058         maint: tight-scope.mk need not be read-only
24059         * top/maint.mk (tight-scope.mk): Don’t bother to make
24060         tight-scope.mk read-only either.
24062         maint: break out '&& mv $@-t $@'
24063         * build-aux/git-version-gen, config/argz.mk, modules/configmake:
24064         * modules/posix_spawnp-tests, modules/snippet/link-warning:
24065         * top/maint.mk:
24066         Break out '&& mv $@-t $@' to a separate line in the Make recipe,
24067         as this makes things a bit easier to debug.
24069         gen-header: new module
24070         Simplify header generation by using Makefile variables
24071         defined by a new gen-header module.
24072         * modules/gen-header: New module.
24073         * modules/alloca-opt, modules/argz, modules/arpa_inet:
24074         * modules/assert-h, modules/byteswap:
24075         * modules/ctype, modules/dirent, modules/dynarray, modules/errno:
24076         * modules/execinfo, modules/fcntl-h, modules/float:
24077         * modules/fnmatch-h, modules/getopt-posix, modules/glob-h:
24078         * modules/iconv-h, modules/ieee754-h, modules/inttypes-incomplete:
24079         * modules/langinfo, modules/libtextstyle-optional, modules/limits-h:
24080         * modules/locale, modules/malloc-h, modules/math, modules/monetary:
24081         * modules/net_if, modules/netdb, modules/netinet_in:
24082         * modules/openmp-init, modules/poll-h:
24083         * modules/pthread-h, modules/pty, modules/sched:
24084         * modules/scratch_buffer, modules/search, modules/selinux-h:
24085         * modules/signal-h, modules/sigsegv:
24086         * modules/spawn, modules/stdalign, modules/stdarg, modules/stdbool:
24087         * modules/stddef, modules/stdint, modules/stdio, modules/stdlib:
24088         * modules/stdnoreturn, modules/string, modules/strings:
24089         * modules/sys_file, modules/sys_ioctl, modules/sys_random:
24090         * modules/sys_resource, modules/sys_select, modules/sys_socket:
24091         * modules/sys_stat, modules/sys_time, modules/sys_times:
24092         * modules/sys_types, modules/sys_uio, modules/sys_utsname:
24093         * modules/sys_wait, modules/sysexits, modules/termios:
24094         * modules/threads-h, modules/time, modules/uchar:
24095         * modules/unicase/base, modules/unicase/special-casing:
24096         * modules/uniconv/base, modules/unictype/base, modules/unigbrk/base:
24097         * modules/unilbrk/base, modules/uniname/base, modules/uninorm/base:
24098         * modules/unistd, modules/unistdio/base, modules/unistr/base:
24099         * modules/unitypes, modules/uniwbrk/base, modules/uniwidth/base:
24100         * modules/utime-h, modules/wchar, modules/wctype-h:
24101         Depend on gen-header, and use its macros to simplify
24102         header generation.
24104 2021-12-24  Bruno Haible  <bruno@clisp.org>
24106         passfd: Fix compilation error on IRIX.
24107         * lib/passfd.c (sendfd): On IRIX, ignore CMSG_FIRSTHDR.
24108         (recvfd): Likewise. Produce a fake error ENOTCONN.
24110 2021-12-24  Bruno Haible  <bruno@clisp.org>
24112         tests: Fix link errors on AIX.
24113         * modules/fnmatch-h-c++-tests (Makefile.am): Link test-fnmatch-h-c++
24114         with $(LIB_MBRTOWC).
24115         * modules/glob-h-c++-tests (Makefile.am): Link test-glob-h-c++ with
24116         $(LIB_MBRTOWC).
24117         * modules/stdlib-c++-tests (Makefile.am): Link test-stdlib-c++ with
24118         $(GETLOADAVG_LIBS).
24119         * modules/sys_stat-c++-tests (Makefile.am): Link test-sys_stat-c++ with
24120         $(LIB_MBRTOWC).
24121         * modules/uchar-c++-tests (Makefile.am): Link test-uchar-c++ with
24122         $(LIBUNISTRING).
24124 2021-12-24  Bruno Haible  <bruno@clisp.org>
24126         hamt tests: Fix compilation error with AIX xlc.
24127         * tests/test-hamt.c (test_iterator): Don't use compound initializer.
24129 2021-12-24  Bruno Haible  <bruno@clisp.org>
24131         strerrorname_np: Fix compilation error on IRIX.
24132         * lib/strerrorname_np.c (strerrorname_np): Handle conflict between
24133         EDIRCORRUPTED and EFSCORRUPTED.
24134         * tests/test-strerrorname_np.c (main): Likewise.
24136 2021-12-24  Bruno Haible  <bruno@clisp.org>
24138         hamt: Fix compilation error on NetBSD 7.
24139         * lib/hamt.h (GL_HAMT_THREAD_SAFE): Define to 0 if the compiler is a
24140         GCC version < 4.9.
24142 2021-12-24  Bruno Haible  <bruno@clisp.org>
24144         search: Fix compilation errors with SunPRO C++ on Solaris 10.
24145         * lib/search.in.h (_gl_lsearch_compar_fn): New type.
24146         (lfind, lsearch): Use it.
24148 2021-12-24  Bruno Haible  <bruno@clisp.org>
24150         qsort_r: Fix compilation error with SunPRO C++ on Solaris 10.
24151         * lib/stdlib.in.h (_gl_qsort_r_compar_fn): New type.
24152         (qsort_r): Use it.
24153         * tests/test-stdlib-c++.cc (qsort_r): Don't test with SunPRO C++.
24155 2021-12-24  Bruno Haible  <bruno@clisp.org>
24157         threads-h tests: Avoid clang warnings.
24158         * tests/test-threads.c (main): Add 'default' to switch statements.
24160 2021-12-24  Bruno Haible  <bruno@clisp.org>
24162         doc: Small updates.
24163         * doc/glibc-functions/ptsname_r.texi: Update info regarding Mac OS X.
24164         * doc/posix-functions/getlogin_r.texi: Update info regarding FreeBSD.
24166 2021-12-22  Paul Eggert  <eggert@cs.ucla.edu>
24168         libgmp: omit redundant 'mkdir -p .'
24169         * modules/libgmp: Mark $(MKDIR) with @NMD@; this was missed
24170         in a previous pass.
24172         maint: omit unnecessary ‘rm -f $@-t $@’
24173         * modules/alloca-opt, modules/argz, modules/arpa_inet:
24174         * modules/assert-h, modules/byteswap, modules/configmake:
24175         * modules/ctype, modules/dirent, modules/dynarray, modules/errno:
24176         * modules/execinfo, modules/fcntl-h, modules/float:
24177         * modules/fnmatch-h, modules/getopt-posix, modules/glob-h:
24178         * modules/iconv-h, modules/ieee754-h, modules/inttypes-incomplete:
24179         * modules/langinfo, modules/libtextstyle-optional:
24180         * modules/limits-h, modules/langinfo, modules/libgmp, modules/limits-h:
24181         * modules/locale, modules/malloc-h, modules/math, modules/monetary:
24182         * modules/net_if, modules/netdb, modules/netinet_in:
24183         * modules/openmp-init, modules/poll-h, modules/posix-shell:
24184         * modules/posix_spawnp-tests, modules/pthread-h, modules/pty:
24185         * modules/sched, modules/scratch_buffer, modules/search:
24186         * modules/selinux-h, modules/signal-h, modules/sigsegv:
24187         * modules/snippet/link-warning, modules/spawn, modules/stdalign:
24188         * modules/stdarg, modules/stdbool, modules/stddef, modules/stdint:
24189         * modules/stdio, modules/stdlib, modules/stdnoreturn:
24190         * modules/string, modules/strings, modules/sys_file:
24191         * modules/sys_ioctl, modules/sys_random, modules/sys_resource:
24192         * modules/sys_select, modules/sys_socket, modules/sys_stat:
24193         * modules/sys_time, modules/sys_times, modules/sys_types:
24194         * modules/sys_uio, modules/sys_utsname, modules/sys_wait:
24195         * modules/sysexits, modules/termios, modules/threads-h:
24196         * modules/time, modules/uchar, modules/unicase/base:
24197         * modules/unicase/special-casing, modules/uniconv/base:
24198         * modules/unictype/base, modules/unigbrk/base, modules/unilbrk/base:
24199         * modules/uniname/base, modules/uninorm/base, modules/unistd:
24200         * modules/unistdio/base, modules/unistr/base, modules/unitypes:
24201         * modules/uniwbrk/base, modules/uniwidth/base, modules/utime-h:
24202         * modules/wchar, modules/wctype-h:
24203         Don’t bother to do a ‘rm -f $@-t $@’ at the start of recipes that
24204         create .h and similar files.  This is a revenant of a style in
24205         which the files were created read-only.  Also, consistently use
24206         use plain ‘mv $@-t $@’ afterwards, instead of usually using
24207         ‘mv -f’ but sometimes plain ‘mv’.
24209 2021-12-21  Paul Eggert  <eggert@cs.ucla.edu>
24211         maint: fix __clang_major__ misspellings
24212         The intprops.h typo fix should fix a bug in Emacs on Debian testing
24213         with clang <https://bugs.gnu.org/52711>.
24214         * lib/asyncsafe-spin.c, lib/intprops.h, lib/pthread-spin.c:
24215         Fix some misspellings of ‘__clang_major__’.
24216         I left one misspelling alone, in lib/cdefs.h,
24217         and instead reported that bug upstream here:
24218         https://sourceware.org/pipermail/libc-alpha/2021-December/134512.html
24220 2021-12-21  Bruno Haible  <bruno@clisp.org>
24222         get_ppid_of, get_progname_of: Fix runtime error on Mac OS X < 10.5.
24223         Reported by Evan Miller <emmiller@gmail.com>
24224         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00081.html>.
24225         * lib/get_ppid_of.c (proc_pidinfo): Declare with WEAK_IMPORT_ATTRIBUTE.
24226         (get_ppid_of): Test whether the symbol declared weak evaluates to
24227         non-NULL before invoking it.
24228         * lib/get_progname_of (proc_pidinfo): Declare with
24229         WEAK_IMPORT_ATTRIBUTE.
24230         (get_progname_of): Test whether the symbol declared weak evaluates to
24231         non-NULL before invoking it.
24233 2021-12-21  Paul Eggert  <eggert@cs.ucla.edu>
24235         Move AM_V_GEN to recipe start
24236         This is especially needed when building Emacs, as it uses
24237         ‘AM_V_GEN=@$(info GEN $@)', which means the GEN line is output by
24238         GNU make just before the recipe runs, regardless of where AM_V_GEN
24239         appears in the recipe.  And it’s also good practice even if the
24240         default Automake ‘AM_V_GEN=@echo GEN $@;’ is used, as it’s better
24241         to output the GEN line consistently at the start of every recipe,
24242         even if this precedes a preparatory command that almost always
24243         works silently.
24244         * modules/arpa_inet, modules/dynarray, modules/net_if:
24245         * modules/netinet_in, modules/scratch_buffer, modules/selinux-h:
24246         * modules/sys_file, modules/sys_ioctl, modules/sys_random:
24247         * modules/sys_resource, modules/sys_select, modules/sys_socket:
24248         * modules/sys_stat, modules/sys_time, modules/sys_times:
24249         * modules/sys_types, modules/sys_uio, modules/sys_utsname:
24250         * modules/sys_wait, modules/unicase/special-casing, top/maint.mk:
24251         Use AM_V_GEN only at the start of each recipe.
24253 2021-12-21  Bruno Haible  <bruno@clisp.org>
24255         c-xvasprintf: Fix declarations (regression 2021-08-07).
24256         * lib/c-xvasprintf.h (c_xasprintf, c_xvasprintf): Remove
24257         _GL_ATTRIBUTE_RETURNS_NONNULL attribute.
24259 2021-12-21  Bruno Haible  <bruno@clisp.org>
24261         snippet/warn-on-use: Fix compilation error in C++ mode on OpenBSD 7.0.
24262         * lib/warn-on-use.h (_GL_WARN_ON_USE): In C++ mode, declare function
24263         with "C" linkage.
24265 2021-12-21  Bruno Haible  <bruno@clisp.org>
24267         Optimize redundant 'mkdir -p .' invocations.
24268         Reported by Paul Eggert.
24269         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
24270         Eliminate @NMD@ tokens.
24271         * modules/alloca-opt (Makefile.am): Prefix the "$(MKDIR_P) '%reldir%'"
24272         line with @NMD@.
24273         * modules/argz (Makefile.am): Likewise.
24274         * modules/assert-h (Makefile.am): Likewise.
24275         * modules/byteswap (Makefile.am): Likewise.
24276         * modules/configmake (Makefile.am): Likewise.
24277         * modules/ctype (Makefile.am): Likewise.
24278         * modules/dirent (Makefile.am): Likewise.
24279         * modules/errno (Makefile.am): Likewise.
24280         * modules/execinfo (Makefile.am): Likewise.
24281         * modules/fcntl-h (Makefile.am): Likewise.
24282         * modules/float (Makefile.am): Likewise.
24283         * modules/fnmatch-h (Makefile.am): Likewise.
24284         * modules/getopt-posix (Makefile.am): Likewise.
24285         * modules/glob-h (Makefile.am): Likewise.
24286         * modules/iconv-h (Makefile.am): Likewise.
24287         * modules/ieee754-h (Makefile.am): Likewise.
24288         * modules/inttypes-incomplete (Makefile.am): Likewise.
24289         * modules/langinfo (Makefile.am): Likewise.
24290         * modules/libtextstyle-optional (Makefile.am): Likewise.
24291         * modules/limits-h (Makefile.am): Likewise.
24292         * modules/locale (Makefile.am): Likewise.
24293         * modules/malloc-h (Makefile.am): Likewise.
24294         * modules/math (Makefile.am): Likewise.
24295         * modules/monetary (Makefile.am): Likewise.
24296         * modules/netdb (Makefile.am): Likewise.
24297         * modules/openmp-init (Makefile.am): Likewise.
24298         * modules/poll-h (Makefile.am): Likewise.
24299         * modules/posix-shell (Makefile.am): Likewise.
24300         * modules/pthread-h (Makefile.am): Likewise.
24301         * modules/pty (Makefile.am): Likewise.
24302         * modules/sched (Makefile.am): Likewise.
24303         * modules/search (Makefile.am): Likewise.
24304         * modules/signal-h (Makefile.am): Likewise.
24305         * modules/sigsegv (Makefile.am): Likewise.
24306         * modules/snippet/link-warning (Makefile.am): Likewise.
24307         * modules/spawn (Makefile.am): Likewise.
24308         * modules/stdalign (Makefile.am): Likewise.
24309         * modules/stdarg (Makefile.am): Likewise.
24310         * modules/stdbool (Makefile.am): Likewise.
24311         * modules/stddef (Makefile.am): Likewise.
24312         * modules/stdint (Makefile.am): Likewise.
24313         * modules/stdio (Makefile.am): Likewise.
24314         * modules/stdlib (Makefile.am): Likewise.
24315         * modules/stdnoreturn (Makefile.am): Likewise.
24316         * modules/string (Makefile.am): Likewise.
24317         * modules/strings (Makefile.am): Likewise.
24318         * modules/sysexits (Makefile.am): Likewise.
24319         * modules/termios (Makefile.am): Likewise.
24320         * modules/threads-h (Makefile.am): Likewise.
24321         * modules/time (Makefile.am): Likewise.
24322         * modules/uchar (Makefile.am): Likewise.
24323         * modules/unicase/base (Makefile.am): Likewise.
24324         * modules/uniconv/base (Makefile.am): Likewise.
24325         * modules/unictype/base (Makefile.am): Likewise.
24326         * modules/unigbrk/base (Makefile.am): Likewise.
24327         * modules/unilbrk/base (Makefile.am): Likewise.
24328         * modules/uniname/base (Makefile.am): Likewise.
24329         * modules/uninorm/base (Makefile.am): Likewise.
24330         * modules/unistd (Makefile.am): Likewise.
24331         * modules/unistdio/base (Makefile.am): Likewise.
24332         * modules/unistr/base (Makefile.am): Likewise.
24333         * modules/unitypes (Makefile.am): Likewise.
24334         * modules/uniwbrk/base (Makefile.am): Likewise.
24335         * modules/uniwidth/base (Makefile.am): Likewise.
24336         * modules/utime-h (Makefile.am): Likewise.
24337         * modules/wchar (Makefile.am): Likewise.
24338         * modules/wctype-h (Makefile.am): Likewise.
24340 2021-12-19  Bruno Haible  <bruno@clisp.org>
24342         non-recursive-gnulib-prefix-hack: Deprecate module.
24343         * modules/non-recursive-gnulib-prefix-hack (Status, Notice): New
24344         sections.
24346 2021-12-19  Bruno Haible  <bruno@clisp.org>
24348         gnulib-tool: Don't insist on ACLOCAL_AMFLAGS.
24349         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
24350         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00112.html>.
24351         * gnulib-tool (func_import): Mention an AC_CONFIG_MACRO_DIRS invocation
24352         as an alternative to augmenting ACLOCAL_AMFLAGS.
24353         (--import, --add-import, --remove-import, --update): To find the m4
24354         directories, look also for AC_CONFIG_MACRO_DIR and AC_CONFIG_MACRO_DIRS
24355         invocations in configure.ac.
24357 2021-12-18  Bruno Haible  <bruno@clisp.org>
24359         nstrftime: Update meta info.
24360         * config/srclist.txt: Fix typo from 2017-07-23.
24362 2021-12-18  Bruno Haible  <bruno@clisp.org>
24364         stdint: Fix handling of limits.h (regression 2021-12-16).
24365         * modules/stdint (configure.ac): Revert last change.
24366         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
24367         If --gnu-make is used, assume that AC_SUBSTed variables for conditionals
24368         are constructed by appending the suffix '_CONDITION'.
24370 2021-12-18  Paul Eggert  <eggert@cs.ucla.edu>
24372         nstrftime: simplify by using libc-config.h.
24373         * lib/nstrftime.c [!_LIBC]: Include libc-config.h
24374         instead of config.h.
24375         (iso_week_days): Simplify via libc-config.h’s __inline.
24376         (my_strftime): Simplify via libc-config.h’s libc_hidden_def.
24377         * modules/nstrftime (Depends-on): Add libc-config.
24379 2021-12-18  Bruno Haible  <bruno@clisp.org>
24381         libtextstyle-optional: Fix generation of textstyle.h (regr. 2021-12-15).
24382         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Invoke
24383         gl_CONDITIONAL_HEADER.
24385 2021-12-18  Bruno Haible  <bruno@clisp.org>
24387         Fix support for --gnu-make in tests (regression 2021-12-15).
24388         * gnulib-tool (func_emit_tests_Makefile_am): When producing output for
24389         GNU make, eliminate %reldir% tokens.
24391 2021-12-17  Bruno Haible  <bruno@clisp.org>
24393         getopt-posix: Fix build on AIX (regression 2021-12-15).
24394         * modules/getopt-posix (configure.ac): Arrange to generate
24395         getopt-cdefs.h.
24396         (Makefile.am): Separate the rules for getopt.h and getopt-cdefs.h.
24398 2021-12-16  Paul Eggert  <eggert@cs.ucla.edu>
24400         getopt-posix: omit unnessary building of getopt.h
24401         * modules/getopt-posix (getopt.h, getopt-cdefs.h):
24402         Build only if GL_GENERATE_GETOPT_H.
24404         stdint: omit duplicate gl_CONFIGURE_HEADER calls
24405         * modules/stdint (configure.ac): Omit
24406         ‘gl_CONDITIONAL_HEADER([limits.h])’, since stdint depends on
24407         limits-h and doing gl_CONDITIONAL_HEADER twice can result in
24408         ‘configure’ failing with “*** GL_GENERATE_LIMITS_H is not set
24409         correctly”.
24411 2021-12-15  Bruno Haible  <bruno@clisp.org>
24413         automake-subdir support: Support the libunistring modules.
24414         * m4/libunistring-base.m4 (gl_LIBUNISTRING_LIBHEADER): Use the value of
24415         the gl_source_base_prefix variable.
24417 2021-12-15  Bruno Haible  <bruno@clisp.org>
24419         automake-subdir support: Support arbitrary --source-base value.
24420         Reported by Marc Nieper-Wißkirchen in
24421         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00066.html>.
24422         * build-aux/prefix-gnulib-mk ($canon_prefix): New variable.
24423         (prefix): Initialize it.
24424         (prefix_assignment): Use it.
24426 2021-12-15  Bruno Haible  <bruno@clisp.org>
24428         automake-subdir support: Look for 'subdir-objects' also in configure.ac.
24429         * gnulib-tool: Look for the automake options also in the first argument
24430         of the AM_INIT_AUTOMAKE invocation in configure.ac.
24432 2021-12-15  Bruno Haible  <bruno@clisp.org>
24434         Add simple examples.
24435         * examples: New directory.
24437 2021-12-15  Bruno Haible  <bruno@clisp.org>
24439         Accommodate non-recursive Automake in a less hacky way.
24440         * gnulib-tool: New option --automake-subdir.
24441         (automake_subdir): New variable.
24442         (func_emit_initmacro_end): Add a second argument. Use it to prefix each
24443         object file name in *_LIBOBJS and *_LTLIBOBJS.
24444         (func_emit_shellvars_init): New function.
24445         (func_import): Add support for --automake-subdir. Invoke
24446         prefix-gnulib-mk. Update calls to func_emit_initmacro_end. Call
24447         func_emit_shellvars_init.
24448         (func_create_testdir): Update calls to func_emit_initmacro_end. Call
24449         func_emit_shellvars_init.
24450         * m4/gnulib-tool.m4 (gl_AUTOMAKE_SUBDIR): New macro.
24451         * m4/gnulib-common.m4 (gl_CONDITIONAL_HEADER): Use the value of the
24452         gl_source_base_prefix variable.
24453         * build-aux/prefix-gnulib-mk: New options --from-gnulib-tool, --prefix.
24454         (contents_of_file): Renamed from contents.
24455         (contents_of_stdin): New function.
24456         (process): Inline and remove function.
24457         * doc/gnulib-tool.texi (Non-recursive make): New section.
24459 2021-12-15  Bruno Haible  <bruno@clisp.org>
24461         Move .h file names out of the *.m4 files.
24462         This is useful because Autoconf macros defined in *.m4 files can be
24463         AC_REQUIREd. In the configure file, they are then expanded before
24464         gl_INIT, i.e. at a place where it is not known whether they are required
24465         for the lib/ or for the tests/ directory (or both).
24466         * m4/gnulib-common.m4 (gl_CONDITIONAL_HEADER): New macro.
24467         * m4/alloca.m4 (gl_FUNC_ALLOCA): Set GL_GENERATE_ALLOCA_H instead of
24468         ALLOCA_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24469         * modules/alloca-opt (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24470         * m4/argz.m4 (gl_FUNC_ARGZ): Set GL_GENERATE_ARGZ_H instead of ARGZ_H.
24471         Drop AC_SUBST and AM_CONDITIONAL invocations.
24472         * modules/argz (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24473         * m4/assert_h.m4 (gl_ASSERT_H): Set GL_GENERATE_ASSERT_H instead of
24474         ASSERT_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24475         * modules/assert-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24476         * m4/byteswap.m4 (gl_BYTESWAP): Set GL_GENERATE_BYTESWAP_H instead of
24477         BYTESWAP_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24478         * modules/byteswap (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24479         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Set GL_GENERATE_ERRNO_H instead of
24480         ERRNO_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24481         (gl_REPLACE_ERRNO_VALUE): Update.
24482         * m4/perror.m4 (gl_FUNC_PERROR): Update.
24483         * m4/strerror.m4 (gl_FUNC_STRERROR): Update.
24484         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R, gl_FUNC_STRERROR_R_WORKS):
24485         Update.
24486         * modules/errno (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24487         * m4/execinfo.m4 (gl_EXECINFO_H): Set GL_GENERATE_EXECINFO_H instead of
24488         EXECINFO_H. Drop AC_SUBST and AM_CONDITIONAL invocations. Drop AC_LIBOBJ
24489         invocation.
24490         * modules/execinfo (configure.ac): Invoke gl_CONDITIONAL_HEADER and
24491         AC_LIBOBJ.
24492         * m4/float_h.m4 (gl_FLOAT_H): Set GL_GENERATE_FLOAT_H instead of
24493         FLOAT_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24494         * modules/float (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24495         * m4/fnmatch_h.m4 (gl_FNMATCH_H, gl_REPLACE_FNMATCH_H): Set
24496         GL_GENERATE_FNMATCH_H instead of FNMATCH_H. Drop AC_SUBST and
24497         AM_CONDITIONAL invocations.
24498         * modules/fnmatch-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24499         * modules/fnmatch (configure.ac): Likewise.
24500         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX, gl_GETOPT_SUBSTITUTE_HEADER): Set
24501         GL_GENERATE_GETOPT_H instead of GETOPT_H. Set GL_GENERATE_GETOPT_CDEFS_H
24502         instead of GETOPT_CDEFS_H. Drop AC_SUBST invocations.
24503         * modules/getopt-posix (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24504         * m4/glob_h.m4 (gl_GLOB_H, gl_REPLACE_GLOB_H): Set GL_GENERATE_GLOB_H
24505         instead of GLOB_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24506         * modules/glob-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24507         * modules/glob (configure.ac): Likewise.
24508         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS, gl_REPLACE_ICONV_H): Set
24509         GL_GENERATE_ICONV_H instead of ICONV_H. Drop AC_SUBST and AM_CONDITIONAL
24510         invocations.
24511         (gl_ICONV_H): Update.
24512         * modules/iconv-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24513         * modules/iconv_open (configure.ac): Likewise.
24514         * m4/ieee754-h.m4 (gl_IEEE754_H): Set GL_GENERATE_IEEE754_H instead of
24515         IEEE754_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24516         * modules/ieee754-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24517         * m4/libgmp.m4 (gl_LIBGMP): Set GL_GENERATE_GMP_H instead of GMP_H. Drop
24518         AC_SUBST invocation.
24519         * modules/libgmp (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24520         (Makefile.am): Use GL_GENERATE_GMP_H.
24521         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Set
24522         GL_GENERATE_TEXTSTYLE_H instead of TEXTSTYLE_H. Drop AC_SUBST and
24523         AM_CONDITIONAL invocations.
24524         * modules/libtextstyle-optional (configure.ac): Invoke
24525         gl_CONDITIONAL_HEADER.
24526         * m4/limits-h.m4 (gl_LIMITS_H, gl_REPLACE_LIMITS_H): Set
24527         GL_GENERATE_LIMITS_H instead of LIMITS_H. Drop AC_SUBST and
24528         AM_CONDITIONAL invocations.
24529         * modules/limits-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24530         * m4/monetary_h.m4 (gl_MONETARY_H): Set GL_GENERATE_MONETARY_H instead
24531         of MONETARY_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24532         * modules/monetary (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24533         * m4/net_if_h.m4 (gl_HEADER_NET_IF): Set GL_GENERATE_NET_IF_H instead of
24534         NET_IF_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24535         * modules/net_if (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24536         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Set
24537         GL_GENERATE_NETINET_IN_H instead of NETINET_IN_H. Drop AC_SUBST and
24538         AM_CONDITIONAL invocations.
24539         * modules/netinet_in (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24540         * m4/selinux-context-h.m4 (gl_HEADERS_SELINUX_CONTEXT_H): Set
24541         GL_GENERATE_SELINUX_CONTEXT_H instead of SELINUX_CONTEXT_H. Drop
24542         AC_SUBST and AM_CONDITIONAL invocations.
24543         * m4/selinux-label-h.m4 (gl_HEADERS_SELINUX_LABEL_H): Set
24544         GL_GENERATE_SELINUX_LABEL_H instead of SELINUX_LABEL_H. Drop AC_SUBST
24545         and AM_CONDITIONAL invocations.
24546         * modules/selinux-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24547         * m4/stdalign.m4 (gl_STDALIGN_H): Set GL_GENERATE_STDALIGN_H instead of
24548         STDALIGN_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24549         * modules/stdalign (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24550         * m4/stdarg.m4 (gl_STDARG_H): Set GL_GENERATE_STDARG_H instead of
24551         STDARG_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24552         * modules/stdarg (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24553         * m4/stdbool.m4 (gl_STDBOOL_H): Renamed from AM_STDBOOL_H. Set
24554         GL_GENERATE_STDBOOL_H instead of STDBOOL_H. Drop AC_SUBST and
24555         AM_CONDITIONAL invocations.
24556         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Don't require AM_STDBOOL_H.
24557         * modules/stdbool (configure.ac): Invoke gl_STDBOOL_H instead of
24558         AM_STDBOOL_H. Invoke gl_CONDITIONAL_HEADER.
24559         * m4/stddef_h.m4 (gl_STDDEF_H): Set GL_GENERATE_STDDEF_H instead of
24560         STDDEF_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24561         * modules/stddef (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24562         * m4/stdint.m4 (gl_STDINT_H): Set GL_GENERATE_STDINT_H instead of
24563         STDINT_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24564         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): Update.
24565         * modules/stdint (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24566         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): Set GL_GENERATE_STDNORETURN_H
24567         instead of STDNORETURN_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24568         * modules/stdnoreturn (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24569         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H): Set GL_GENERATE_SYS_SOCKET_H
24570         instead of SYS_SOCKET_H.
24571         * m4/sysexits.m4 (gl_SYSEXITS): Set GL_GENERATE_SYSEXITS_H instead of
24572         SYSEXITS_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
24573         * modules/sysexits (configure.ac): Invoke gl_CONDITIONAL_HEADER.
24574         * modules/sigsegv (configure.ac): Set GL_GENERATE_SIGSEGV_H instead of
24575         SIGSEGV_H. Drop AC_SUBST and AM_CONDITIONAL invocations. Invoke
24576         gl_CONDITIONAL_HEADER.
24578 2021-12-15  Bruno Haible  <bruno@clisp.org>
24580         Fix creation of build directories with non-recursive-gnulib-prefix-hack.
24581         This is necessary for executing "make" in a VPATH build of a package
24582         that uses prefix-gnulib-mk and a module such as alloca-opt.
24583         * modules/alloca-opt (Makefile.am): Before generating the .h-t file,
24584         ensure that the directory in which we want to create it exists.
24585         (configure.ac): Invoke AC_PROG_MKDIR_P.
24586         * modules/argz: Likewise.
24587         * modules/arpa_inet: Likewise.
24588         * modules/assert-h: Likewise.
24589         * modules/byteswap: Likewise.
24590         * modules/configmake: Likewise.
24591         * modules/ctype: Likewise.
24592         * modules/dirent: Likewise.
24593         * modules/dynarray: Likewise.
24594         * modules/errno: Likewise.
24595         * modules/execinfo: Likewise.
24596         * modules/fcntl-h: Likewise.
24597         * modules/float: Likewise.
24598         * modules/fnmatch-h: Likewise.
24599         * modules/getopt-posix: Likewise.
24600         * modules/glob-h: Likewise.
24601         * modules/iconv-h: Likewise.
24602         * modules/ieee754-h: Likewise.
24603         * modules/inttypes-incomplete: Likewise.
24604         * modules/langinfo: Likewise.
24605         * modules/libgmp: Likewise.
24606         * modules/libtextstyle-optional: Likewise.
24607         * modules/limits-h: Likewise.
24608         * modules/locale: Likewise.
24609         * modules/malloc-h: Likewise.
24610         * modules/math: Likewise.
24611         * modules/monetary: Likewise.
24612         * modules/net_if: Likewise.
24613         * modules/netdb: Likewise.
24614         * modules/netinet_in: Likewise.
24615         * modules/openmp-init: Likewise.
24616         * modules/poll-h: Likewise.
24617         * modules/posix-shell: Likewise.
24618         * modules/pthread-h: Likewise.
24619         * modules/pty: Likewise.
24620         * modules/sched: Likewise.
24621         * modules/scratch_buffer: Likewise.
24622         * modules/search: Likewise.
24623         * modules/selinux-h: Likewise.
24624         * modules/signal-h: Likewise.
24625         * modules/sigsegv: Likewise.
24626         * modules/snippet/link-warning: Likewise.
24627         * modules/spawn: Likewise.
24628         * modules/stdalign: Likewise.
24629         * modules/stdarg: Likewise.
24630         * modules/stdbool: Likewise.
24631         * modules/stddef: Likewise.
24632         * modules/stdint: Likewise.
24633         * modules/stdio: Likewise.
24634         * modules/stdlib: Likewise.
24635         * modules/stdnoreturn: Likewise.
24636         * modules/string: Likewise.
24637         * modules/strings: Likewise.
24638         * modules/sys_file: Likewise.
24639         * modules/sys_ioctl: Likewise.
24640         * modules/sys_random: Likewise.
24641         * modules/sys_resource: Likewise.
24642         * modules/sys_select: Likewise.
24643         * modules/sys_socket: Likewise.
24644         * modules/sys_stat: Likewise.
24645         * modules/sys_time: Likewise.
24646         * modules/sys_times: Likewise.
24647         * modules/sys_types: Likewise.
24648         * modules/sys_uio: Likewise.
24649         * modules/sys_utsname: Likewise.
24650         * modules/sys_wait: Likewise.
24651         * modules/sysexits: Likewise.
24652         * modules/termios: Likewise.
24653         * modules/threads-h: Likewise.
24654         * modules/time: Likewise.
24655         * modules/uchar: Likewise.
24656         * modules/unicase/base: Likewise.
24657         * modules/unicase/special-casing: Likewise.
24658         * modules/uniconv/base: Likewise.
24659         * modules/unictype/base: Likewise.
24660         * modules/unigbrk/base: Likewise.
24661         * modules/unilbrk/base: Likewise.
24662         * modules/uniname/base: Likewise.
24663         * modules/uninorm/base: Likewise.
24664         * modules/unistd: Likewise.
24665         * modules/unistdio/base: Likewise.
24666         * modules/unistr/base: Likewise.
24667         * modules/unitypes: Likewise.
24668         * modules/uniwbrk/base: Likewise.
24669         * modules/uniwidth/base: Likewise.
24670         * modules/utime-h: Likewise.
24671         * modules/wchar: Likewise.
24672         * modules/wctype-h: Likewise.
24673         * gnulib-tool (func_emit_lib_Makefile_am): When producing output for
24674         GNU make, eliminate %reldir% tokens.
24676 2021-12-15  Bruno Haible  <bruno@clisp.org>
24678         non-recursive-gnulib-prefix-hack: Remove obsolete code.
24679         * build-aux/prefix-gnulib-mk (prefix): Remove handling of t-$@ pattern.
24681 2021-12-15  Bruno Haible  <bruno@clisp.org>
24683         Indentation fix.
24684         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Correct indentation.
24686 2021-12-14  Paul Eggert  <eggert@cs.ucla.edu>
24688         renameatu: port to macOS tmpfs
24689         Problem reported by Sudhip Nashi (Bug#52193).
24690         * lib/renameatu.c (renameat2ish) [HAVE_RENAMEAT]: New function.
24691         (renameatu): Use the new function, to avoid a bug when
24692         renameatx_np fails with errno == ENOTSUP.  Don’t try to support
24693         RENAME_EXCHANGE; the old code didn’t work and nobody using using
24694         RENAME_EXCHANGE anyway.
24696 2021-12-12  Bruno Haible  <bruno@clisp.org>
24698         gnulib-tool: Try to support non-recursive-gnulib-prefix-hack with tests.
24699         * gnulib-tool (func_import): Synthesize an AC_CONFIG_LIBOBJ_DIR
24700         invocation.
24701         * m4/non-recursive-gnulib-prefix-hack.m4
24702         (gl_NON_RECURSIVE_GNULIB_PREFIX_HACK): Don't invoke
24703         AC_CONFIG_LIBOBJ_DIR.
24705 2021-12-12  Paul Eggert  <eggert@cs.ucla.edu>
24707         bootstrap: refactor for GNU tar
24708         * build-aux/bootstrap (gitignore_entries, insert_if_absent)
24709         (insert_vc_ignore, symlink_to_dir): Define these shell functions
24710         before including bootstrap.conf.  This is for GNU tar, whose
24711         bootstrap.conf uses symlink_to_dir.
24713 2021-12-12  Bruno Haible  <bruno@clisp.org>
24715         gnulib-tool: Support different basenames for the lib/,tests/ Makefiles.
24716         * gnulib-tool: New option --tests-makefile-name.
24717         (tests_makefile_name): New variable.
24718         (func_import): Add support for --tests-makefile-name. Replace local
24719         variable makefile_am with two local variables source_makefile_am,
24720         tests_makefile_am.
24721         * m4/gnulib-tool.m4 (gl_TESTS_MAKEFILE_NAME): New macro.
24723 2021-12-11  Bruno Haible  <bruno@clisp.org>
24725         get_ppid_of, get_progname_of: Fix compilation error on Mac OS X < 10.5.
24726         Reported by Ryan Schmidt <gnulib@ryandesign.com> in
24727         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00011.html>.
24728         * lib/get_ppid_of.c: Include AvailabilityMacros.h
24729         (get_ppid_of): Use MAC_OS_X_VERSION_MAX_ALLOWED and
24730         MAC_OS_X_VERSION_MIN_REQUIRED.
24731         * lib/get_progname_of: Include AvailabilityMacros.h
24732         (get_progname_of): Use MAC_OS_X_VERSION_MAX_ALLOWED and
24733         MAC_OS_X_VERSION_MIN_REQUIRED.
24735 2021-12-10  Paul Eggert  <eggert@cs.ucla.edu>
24737         backupfile: assume C99 decls
24738         * lib/backupfile.c: Use C99-style decls after statements.
24740         backupfile: prefer signed integers
24741         * lib/backupfile.c: Include ialloc.h instead of idx.h.
24742         Prefer idx_t to size_t where either will do.
24743         Use imalloc and irealloc instead of malloc and realloc.
24745         * modules/backupfile, modules/backup-rename (Depends-on):
24746         Depend on ialloc not idx.
24748         backupfile: fix numbered backups for XXX/
24749         * lib/backupfile.c (check_extension): Return a bool indicating
24750         whether the original extension was OK.  Caller changed.
24751         (numbered_backup): Require that FILELEN does not count
24752         trailing slashes after a non-slash, and don’t require
24753         that *BUF be null-terminated.  Caller changed.
24754         This fixes a bug where the numbered backup file name for X/ was
24755         incorrectly computed because the slash messed up the code
24756         looking for X.~1~, X.~2~, etc., and this caused numbered_backup
24757         to loop forever.  Also, check that check_extension doesn’t
24758         truncate a file name leading to an infloop.
24760 2021-12-07  Paul Eggert  <eggert@cs.ucla.edu>
24762         regex: pacify Coverity clean_state_log_if_needed
24763         Problem reported by Robbie Harwood in:
24764         https://lists.gnu.org/r/bug-gnulib/2021-12/msg00005.html
24765         * lib/regexec.c (clean_state_log_if_needed):
24766         Add a DEBUG_ASSERT; this both pacifies Coverity and
24767         will help to debug in case some other change mistakenly
24768         causes the assertion to become false.
24770 2021-12-07  Bruno Haible  <bruno@clisp.org>
24772         gettext-h: Optimize also for clang.
24773         * lib/gettext.h (pgettext_aux, npgettext_aux, dcpgettext_expr,
24774         dcnpgettext_expr): Inline also on clang.
24776 2021-12-06  Bruno Haible  <bruno@clisp.org>
24778         intprops: Break sync with glibc.
24779         * config/srclist.txt: Comment out intprops.h.
24781 2021-12-06  Paul Eggert  <eggert@cs.ucla.edu>
24783         intprops: streamline and get ready for Clang 14
24784         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW):
24785         Rely on __has_builtin first, since GCC didn’t introduce it until
24786         GCC 9 so we don’t need to special-case GCC first.
24787         (_GL_HAS_BUILTIN_ADD_OVERFLOW, _GL_HAS_BUILTIN_OVERFLOW_P):
24788         Look at __EDG__ rather than __ICC, since icc defines __EDG__ too.
24789         (_GL_HAS_BUILTIN_MUL_OVERFLOW): Define to 1 in Clang 14 and later,
24790         as a bug fix is scheduled for Clang 14.
24791         (_GL_HAS_BUILTIN_OVERFLOW_P): Do not bother to special-case
24792         __clang__, since __has_builtin should do the right thing anyway.
24794 2021-12-06  Bruno Haible  <bruno@clisp.org>
24796         intprops: Treat EDG-based compilers like Intel compilers.
24797         Reported by Ilya Kurdyukov <ilyakurdyukov@altlinux.org> in
24798         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00028.html>.
24799         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P): Define to 0 on EDG-based
24800         compilers.
24802 2021-12-05  Bruno Haible  <bruno@clisp.org>
24804         sigsegv: Fix build on some more embedded CPUs.
24805         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Assume the stack grows
24806         negative, when the GCC 11 sources say so.
24808 2021-11-30  Paul Eggert  <eggert@cs.ucla.edu>
24810         sys_random: port better to uClibc < 1.0.35
24811         Problem reported by Fabrice Fontaine in:
24812         https://lists.gnu.org/r/bug-gnulib/2021-11/msg00043.html
24813         * lib/sys_random.in.h [HAVE_SYS_RANDOM_H && !__GLIBC__ && __UCLIBC__]:
24814         Include <stddef.h>, in case this file is included before
24815         __UCLIBC__ is defined.
24817 2021-11-27  Paul Eggert  <eggert@cs.ucla.edu>
24819         gettext-h: document GNULIB_NO_VLA
24820         * doc/gnulib-readme.texi (C99 features avoided):
24821         Document GNULIB_NO_VLA.
24823         gettext-h: use VLA test similar to regex
24824         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Assuming
24825         GNULIB_NO_VLA, define if (defined __STDC_VERSION__ && 199901L <=
24826         __STDC_VERSION__ \ + && !defined __STDC_NO_VLA___), not if
24827         ((__GNUC__ >= 3 || __GNUG__ >= 2) && !defined __STRICT_ANSI__).
24828         This is more consistent with what the regex module does.
24829         * modules/gettext-h (Depends-on): Depend on vararrays, since
24830         lib/gettext.h uses __STDC_NO_VLA__.
24832         regex: port to tcc
24833         Problem reported by Benno Schulenberg in:
24834         https://lists.gnu.org/r/bug-gnulib/2021-11/msg00038.html
24835         * modules/regex (Depends-on): Depend on vararrays, since
24836         lib/regex.h uses __STDC_NO_VLA__.
24837         * modules/vararrays: Change license from LGPL to LGPLv2+.
24839 2021-11-25  Bernhard Voelker  <mail@bernhard-voelker.de>
24841         test-framework-sh: remove unsafe entries from PATH
24842         Running tests with '.' in the PATH may yield unspecified results,
24843         and is deemed unsafe per se.  This includes empty entries as well
24844         which are treated like a '.' entry as per POSIX.
24845         * tests/init.sh (setup_): Add snippet to remove relative and non-
24846         accessible entries from the PATH environment variable.
24848 2021-11-24  Paul Eggert  <eggert@cs.ucla.edu>
24850         regex: merge from glibc
24851         The main change here, imported from Glibc, is for the regex
24852         code to stop using nested functions when _LIBC is defined.
24853         The intent is for the result to be copied back to Glibc
24854         so that the two implementations can resync.
24855         * lib/regcomp.c (re_set_fastmap, seek_collating_symbol_entry)
24856         (lookup_collation_sequence_value, build_range_exp)
24857         (build_collating_symbol):
24858         * lib/regexec.c (acquire_init_state_context):
24859         Declare with __always_inline instead of with
24860         ‘inline __attribute__ ((always_inline))’.
24861         * lib/regexec.c (init_word_char):
24862         Move uint64_t comment to regex_internal.h.
24863         (parse_byte): Change multibyte-detecting arg from re_charset_t *
24864         to re_dfa_t const *.  All callers changed.
24865         (build_range_exp, build_collating_symbol) [!_LIBC]:
24866         Change signature to match _LIBC well enough so that the caller can
24867         be simplified to assume _LIBC.
24868         (parse_bracket_exp): Pull its nested functions
24869         seek_collating_symbol_entry, lookup_collation_sequence_value,
24870         build_range_exp, build_collating_symbol out to the top level,
24871         adding args to pass the information instead of having them access
24872         nonlocal vars.  Use types in local vars that do not assume glibc.
24873         * lib/regex_internal.h: Explain uint64_t etc. here.
24875 2021-11-23  Paul Eggert  <eggert@cs.ucla.edu>
24877         regex: assume RE_ENABLE_I18N
24878         These days there is no longer any need to port to platforms
24879         lacking iswctype etc., since Gnulib now has substitutes.
24880         * config/srclist.txt: Comment out regex_internal.c and
24881         regex_internal.h for now, since they no longer match glibc.
24882         The intent is to merge them again soon.
24883         * lib/regex_internal.h (RE_ENABLE_I18N): Remove.
24884         All uses changed to assume that RE_ENABLE_I18N is 1.
24885         * modules/regex (Depends-on): Add iswctype.
24887 2021-11-15  Paul Eggert  <eggert@cs.ucla.edu>
24889         lseek: port around macOS SEEK_HOLE glitch
24890         Problem reported by Sudhip Nashi (Bug#51857#47).
24891         * lib/lseek.c (rpl_lseek): Work around macOS lseek+SEEK_HOLE
24892         returning -1 with ENXIO if there are no holes before EOF,
24893         contrary to the macOS documentation.
24895         lseek: port around macOS SEEK_DATA glitch
24896         Problem reported by Sudhip Nashi (Bug#51857).
24897         * doc/posix-functions/lseek.texi (lseek): Mention macOS SEEK_DATA
24898         issue.
24899         * lib/lseek.c (rpl_lseek): Work around macOS portability glitch.
24900         * m4/lseek.m4 (gl_FUNC_LSEEK): Replace lseek on Darwin.
24901         * modules/lseek (Depends-on): Depend on msvc-nothrow
24902         and fstat only if needed.
24904 2021-11-11  Fabrice Fontaine  <fontaine.fabrice@gmail.com>  (tiny change)
24906         sigsegv: fix builds on microblazeel, or1k
24907         * m4/stack-direction.m4 (SV_STACK_DIRECTION):
24908         Assume it grows negative on microblaze* and or1k.
24910 2021-11-09  Paul Eggert  <eggert@cs.ucla.edu>
24912         exclude: yield proper errno on failure
24913         * lib/exclude.c (add_exclude_file): Do not assume that fclose
24914         preserves errno on success.
24916 2021-11-07  Paul Eggert  <eggert@cs.ucla.edu>
24918         regex: break regcomp.c link with glibc
24919         Problem reported by Bruno Haible in:
24920         https://lists.gnu.org/r/bug-gnulib/2021-11/msg00005.html
24921         * config/srclist.txt: Comment out regcomp.c for now.
24922         * lib/regcomp.c: Revert previous change.
24924 2021-10-24  Bruno Haible  <bruno@clisp.org>
24926         string: Avoid syntax error re strdup in string.in.h (regr. 2021-09-07).
24927         Reported by Jan Engelhardt <jengelh@inai.de>
24928         and by Arash Esbati <arash@gnu.org> via Andy Moreton in
24929         <https://lists.gnu.org/archive/html/bug-gnulib/2021-10/msg00058.html>.
24930         * lib/string.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE,
24931         _GL_ATTRIBUTE_MALLOC): Add fallback declarations, like in
24932         lib/stdlib.in.h.
24933         * lib/wchar.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE,
24934         _GL_ATTRIBUTE_MALLOC): Likewise.
24936 2021-10-19  Paul Eggert  <eggert@cs.ucla.edu>
24938         xalloc: new function xinmalloc
24939         * lib/xmalloc.c (xinmalloc): New function, which is like
24940         xnmalloc but for idx_t instead of size_t.
24942 2021-10-18  Paul Eggert  <eggert@cs.ucla.edu>
24944         regex: fix buffer read overrrun
24945         * lib/regexec.c (re_search_internal):
24946         Fix buffer read overrun reported by Benno Schulenberg in:
24947         https://lists.gnu.org/r/bug-gnulib/2021-10/msg00035.html
24949 2021-10-15  Paul Eggert  <eggert@cs.ucla.edu>
24951         nproc: port better to macOS 10.14
24952         * lib/nproc.c (num_processors_ignoring_omp)
24953         [HAVE_SYSCTL && !defined __GLIBC__ && defined HW_NCPU]:
24954         Do not use a const mib, as macOS 10.14 rejects this.
24956 2021-10-13  Paul Eggert  <eggert@cs.ucla.edu>
24958         sigsegv: fix quoting problem
24959         Problem reported for FreeBSD ports by Alexey Dokuchaev in:
24960         https://bugs.gnu.org/51144
24961         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Quote brackets.
24963 2021-10-10  Paul Eggert  <eggert@cs.ucla.edu>
24965         nproc: port better to OpenBSD
24966         Problem reported by Omar Polo in:
24967         https://lists.gnu.org/r/emacs-devel/2021-10/msg00692.html
24968         * lib/nproc.c (num_processors_ignoring_omp): Prefer HW_NCPUONLINE
24969         to HW_NCPU, for OpenBSD.  Also, make mib const.
24971 2021-10-02  Paul Eggert  <eggert@cs.ucla.edu>
24973         timer-time: port better to OpenBSD 6.9
24974         * m4/timer_time.m4 (gl_TIMER_TIME): Also require timer_settime to
24975         be declared, as it exists in OpenBSD but always fails with ENOSYS.
24977         sys_select: port better to OpenBSD 6.9
24978         OpenBSD 6.9’s <sys/time.h> includes <sys/select.h> which then
24979         includes <signal.h>, which caused coreutils/lib/nproc.c compiles
24980         to fail with "/usr/include/signal.h:57: warning: 'struct
24981         sigaction' declared inside parameter list".  Fix this.
24982         * lib/sys_select.in.h [__OpenBSD__]: Simply delegate to the system
24983         header if being included from <sys/time.h>.
24985 2021-09-22  Bruno Haible  <bruno@clisp.org>
24987         doc: Fix outdated statement about Spanish collation.
24988         Reported by Dietmar Schindler in
24989         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00095.html>.
24990         * doc/regex.texi (Collating Elements vs. Characters): Choose another
24991         example of a digraph with special collation.
24993         doc: Don't assume that the output format is TeX-based or info.
24994         Reported by Dietmar Schindler in
24995         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00095.html>.
24996         * doc/regex.texi (Collating Elements vs. Characters): Assume a texinfo
24997         version that groks UTF-8 encoded ISO-8859-1 characters.
24999 2021-09-21  Paul Eggert  <eggert@cs.ucla.edu>
25001         regex: sync with glibc
25002         * config/srclist.txt: Uncomment-out posix/regex.c and related
25003         files, as the Gnulib versions have now been copied to glibc.
25004         * lib/intprops.h: Remove authorship comment, as per glibc guidelines.
25006 2021-09-20  Simon Josefsson  <simon@josefsson.org>
25008         maint: Avoid syntax-check failure for empty gnulib submodule.
25009         * top/maint.mk (gnulib_dir): Fall back to GNULIB_SRCDIR if
25010         submodule is not checked out.
25012 2021-09-19  Bruno Haible  <bruno@clisp.org>
25014         Relicense qemu.h under LGPLv2+.
25015         * tests/qemu.h: Change license header.
25017 2021-09-19  Bruno Haible  <bruno@clisp.org>
25019         ialloc: Update license headers after license change from 2021-08-29.
25020         * lib/ialloc.h: Update license header.
25021         * lib/ialloc.c: Likewise.
25023 2021-09-19  Bruno Haible  <bruno@clisp.org>
25025         Improve 'configure --help' output for crypto modules.
25026         * m4/af_alg.m4 (gl_AF_ALG): List the hash functions for which we use the
25027         Linux crypto. Also mention that we use it on files only.
25028         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Use manual line breaking, not the
25029         line-filling style of AS_HELP_STRING. Show that --with-openssl takes an
25030         optional argument. List the hash functions for which we use the OpenSSL
25031         library. Don't mention --with-linux-crypto if the af_alg module is not
25032         in use. Mention that --with-linux-crypto applies only to the Linux
25033         kernel. Mention that it gets used only when available. Mention that it
25034         takes precedence only for files. In the error or warning, mention the
25035         pre-built package name that people can install.
25037 2021-09-18  Bruno Haible  <bruno@clisp.org>
25039         string, wchar: Don't require undefined m4 macros (regr. today).
25040         Reported by Colin Watson <cjwatson@debian.org> in
25041         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00078.html>.
25042         * m4/string_h.m4 (gl_STRING_H_REQUIRE_DEFAULTS): Don't use m4_require
25043         directly. Instead, invoke gl_STDLIB_H_REQUIRE_DEFAULTS.
25044         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Likewise.
25046 2021-09-18  Bruno Haible  <bruno@clisp.org>
25048         sm3-buffer tests: New module.
25049         * tests/test-sm3-buffer.c: Renamed from tests/test-sm3.c.
25050         * modules/crypto/sm3-buffer-tests: Renamed from
25051         modules/crypto/sm3-tests. Test tests/test-sm3-buffer.c instead of
25052         tests/test-sm3.c.
25054         sm3-buffer: New module.
25055         * lib/sm3-stream.c: New file, extracted from lib/sm3.c.
25056         * lib/sm3.c: Don't include stdlib.h, unlocked-io.h.
25057         (BLOCKSIZE, sm3_stream): Moved to sm3-stream.c.
25058         * lib/sm3.h: Tweak.
25059         * modules/crypto/sm3-buffer: New file, based on modules/crypto/sm3.
25060         * modules/crypto/sm3: Rewritten.
25062 2021-09-18  Bruno Haible  <bruno@clisp.org>
25064         sha512-buffer tests: New module.
25065         * tests/test-sha512-stream.c: Renamed from tests/test-sha512.c.
25066         * modules/crypto/sha512-buffer-tests: New file, based on
25067         modules/crypto/sha512-tests.
25068         * modules/crypto/sha512-tests: Remove tests that are now in
25069         modules/crypto/sha512-buffer-tests. Test tests/test-sha512-stream.c
25070         instead of tests/test-sha512.c.
25072         sha512: Clarify module to source relation.
25073         * lib/sha512-stream.c: New file, extracted from lib/sha512.c.
25074         * lib/sha512.c: Don't include stdlib.h, unlocked-io.h.
25075         (BLOCKSIZE, shaxxx_stream, sha512_stream, sha384_stream): Moved to
25076         sha512-stream.c.
25077         * lib/sha512.h: Tweak.
25078         * modules/crypto/sha512 (Files): Add lib/sha512-stream.c.
25079         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
25080         (Makefile.am): Arrange to compile sha512-stream.c.
25081         (Link): Mention $(LIB_CRYPTO).
25083 2021-09-18  Bruno Haible  <bruno@clisp.org>
25085         sha256-buffer tests: New module.
25086         * tests/test-sha256-stream.c: Renamed from tests/test-sha256.c.
25087         * modules/crypto/sha256-buffer-tests: New file, based on
25088         modules/crypto/sha256-tests.
25089         * modules/crypto/sha256-tests: Remove tests that are now in
25090         modules/crypto/sha256-buffer-tests. Test tests/test-sha256-stream.c
25091         instead of tests/test-sha256.c.
25093         sha256: Clarify module to source relation.
25094         * lib/sha256-stream.c: New file, extracted from lib/sha256.c.
25095         * lib/sha256.c: Don't include stdlib.h, unlocked-io.h.
25096         (BLOCKSIZE, shaxxx_stream, sha256_stream, sha224_stream): Moved to
25097         sha256-stream.c.
25098         * lib/sha256.h: Tweak.
25099         * modules/crypto/sha256 (Files): Add lib/sha256-stream.c.
25100         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
25101         (Makefile.am): Arrange to compile sha256-stream.c.
25102         (Link): Mention $(LIB_CRYPTO).
25104 2021-09-18  Bruno Haible  <bruno@clisp.org>
25106         sha1-buffer tests: New module.
25107         * tests/test-sha1-buffer.c: New file, based on tests/test-sha1.c.
25108         * tests/test-sha1-stream.c: Renamed from tests/test-sha1.c.
25109         (main): Remove sha1-buffer tests.
25110         * modules/crypto/sha1-buffer-tests: New file, based on
25111         modules/crypto/sha1-tests.
25112         * modules/crypto/sha1-tests: Remove tests that are now in
25113         modules/crypto/sha1-buffer-tests. Test tests/test-sha1-stream.c instead
25114         of tests/test-sha1.c.
25116         sha1: Clarify module to source relation.
25117         * lib/sha1-stream.c: New file, extracted from lib/sha1.c.
25118         * lib/sha1.c: Don't include stdlib.h, unlocked-io.h.
25119         (BLOCKSIZE, sha1_stream): Moved to sha1-stream.c.
25120         * lib/sha1.h: Correct indentation.
25121         * modules/crypto/sha1 (Files): Add lib/sha1-stream.c.
25122         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
25123         (Makefile.am): Arrange to compile sha1-stream.c.
25124         (Link): Mention $(LIB_CRYPTO).
25126 2021-09-18  Bruno Haible  <bruno@clisp.org>
25128         md5-buffer tests: New module.
25129         * tests/test-md5-buffer.c: New file, based on tests/test-md5.c.
25130         * tests/test-md5-stream.c: Renamed from tests/test-md5.c.
25131         (main): Remove md5-buffer tests.
25132         * modules/crypto/md5-buffer-tests: New file, based on
25133         modules/crypto/md5-tests.
25134         * modules/crypto/md5-tests: Remove tests that are now in
25135         modules/crypto/md5-buffer-tests. Test tests/test-md5-stream.c instead
25136         of tests/test-md5.c.
25138         md5: Clarify module to source relation.
25139         * lib/md5-stream.c: New file, extracted from lib/md5.c.
25140         * lib/md5.c: Don't include stdlib.h, unlocked-io.h.
25141         (BLOCKSIZE, md5_stream): Moved to md5-stream.c.
25142         * lib/md5.h: Tweak.
25143         * modules/crypto/md5 (Files): Add lib/md5-stream.c.
25144         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
25145         (Makefile.am): Arrange to compile md5-stream.c.
25146         (Link): Mention $(LIB_CRYPTO).
25148 2021-09-18  Bruno Haible  <bruno@clisp.org>
25150         md4-buffer tests: New module.
25151         * tests/test-md4-buffer.c: Renamed from tests/test-md4.c.
25152         * modules/crypto/md4-buffer-tests: Renamed from
25153         modules/crypto/md4-tests. Test tests/test-md4-buffer.c instead of
25154         tests/test-md4.c.
25156         md4-buffer: New module.
25157         * lib/md4-stream.c: New file, extracted from lib/md4.c.
25158         * lib/md4.c: Don't include stdlib.h, unlocked-io.h.
25159         (BLOCKSIZE, md4_stream): Moved to md4-stream.c.
25160         * lib/md4.h: Reorder declarations.
25161         * modules/crypto/md4-buffer: New file, based on modules/crypto/md4.
25162         * modules/crypto/md4: Rewritten.
25164 2021-09-18  Bruno Haible  <bruno@clisp.org>
25166         md2-buffer tests: New module.
25167         * tests/test-md2-buffer.c: Renamed from tests/test-md2.c.
25168         * modules/crypto/md2-buffer-tests: Renamed from
25169         modules/crypto/md2-tests. Test tests/test-md2-buffer.c instead of
25170         tests/test-md2.c.
25172         md2-buffer: New module.
25173         * lib/md2-stream.c: New file, extracted from lib/md2.c.
25174         * lib/md2.c: Don't include stdlib.h, unlocked-io.h.
25175         (BLOCKSIZE, md2_stream): Moved to md2-stream.c.
25176         * lib/md2.h: Reorder declarations.
25177         * modules/crypto/md2-buffer: New file, based on modules/crypto/md2.
25178         * modules/crypto/md2: Rewritten.
25180 2021-09-18  Bruno Haible  <bruno@clisp.org>
25182         string, wchar: Don't cause link errors for rpl_free (regr. 2021-09-07).
25183         Reported by Simon Josefsson in
25184         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00042.html>.
25185         * lib/string.in.h (free, rpl_free): Consider GNULIB_FREE_POSIX variable.
25186         * lib/wchar.in.h (free, rpl_free): Likewise.
25187         * m4/string_h.m4 (gl_STRING_H_REQUIRE_DEFAULTS): Require module
25188         indicator variable initializations from the stdlib module.
25189         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Likewise.
25190         * modules/string (Makefile.am): Substitute GNULIB_FREE_POSIX in string.h.
25191         * modules/wchar (Makefile.am): Substitute GNULIB_FREE_POSIX in wchar.h.
25193 2021-09-17  Bruno Haible  <bruno@clisp.org>
25195         threadlib: Avoid crashes in thread-related functions on Cygwin 3.2.0.
25196         Reported by Brian Inglis via Akim Demaille in
25197         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00063.html>.
25198         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): Force a "guessing no" result on
25199         Cygwin.
25201 2021-09-13  Bruno Haible  <bruno@clisp.org>
25203         simple-atomic: Port to Oracle Studio 12.6.
25204         * lib/simple-atomic.c (asm) [0x590 <= __SUNPRO_C && __STDC__]:
25205         #define to __asm.
25207 2021-09-13  Paul Eggert  <eggert@cs.ucla.edu>
25209         asyncsafe-spin: port to Oracle Studio 12.6 sparc
25210         Problem reported by Dennis Clarke via Eric Blake in:
25211         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00056.html
25212         * lib/asyncsafe-spin.c (asm) [0x590 <= __SUNPRO_C && __STDC__]:
25213         #define to __asm.
25215 2021-09-12  Paul Eggert  <eggert@cs.ucla.edu>
25217         stdint-tests: long long preproc on recent Sun C
25218         * tests/test-stdint.c: Test long long preprocessor constants on
25219         Oracle Developer Studio 12.6, where they should work.
25221 2021-09-13  Bruno Haible  <bruno@clisp.org>
25223         extern-inline: Fix syntax error on macOS with GCC 11 (regr. 2021-08-22).
25224         Reported by Akim Demaille in
25225         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00052.html>.
25226         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE): Put _GL_UNUSED
25227         before, not after, 'static'.
25229 2021-09-11  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
25231         sigsegv: port to OpenBSD 6.8+ powerpc64
25232         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER):
25233         Special case for __OpenBSD__ && __powerpc64__, needed due to:
25234         https://github.com/openbsd/src/commit/5e649a8714ba05cf482011b7b7d1e5437b7c17db
25235         which is part of the oldest currently-supported OpenBSD (6.8),
25236         so we needn’t worry about older versions.
25238 2021-09-09  Pádraig Brady  <P@draigBrady.com>
25240         maintainer-makefile: add 'can' to sc_prohibit_doubled_word
25241         * top/maint.mk (sc_prohibit_doubled_word): Check for "can can".
25243 2021-09-08  Paul Eggert  <eggert@cs.ucla.edu>
25245         strerror_r-posix: port even better to Android
25246         * lib/strerror_r.c: Use STRERROR_R_CHAR_P to decide whether the
25247         system strerror_r returns char *, and HAVE_DECL_STRERROR_R to
25248         decide whether it either does that or returns an integer.  In the
25249         former case, use the system strerror_r even on platforms like
25250         Android API level 23 that don’t have __xpg_strerror_r; also
25251         check for strerror_r failure just in case.
25252         * m4/error.m4 (gl_PREREQ_ERROR):
25253         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R):
25254         Use system extensions on Android, to avoid mishandling strerror_r
25255         on API level 23 and later.
25256         * modules/error, modules/strerror_r-posix (configure.ac):
25257         Surround gl_PREREQ_ERROR with AS_IF instead of plain if, so that
25258         AC_REQUIREs are propagated out.
25260         strerror_r-posix: port better to Android
25261         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Move requirement of
25262         gl_USE_SYSTEM_EXTENSIONS from here ...
25263         (gl_FUNC_STRERROR_R_WORKS): ... to here, which is the macro that
25264         actually needs it.  This avoids a bug where 'configure' tests
25265         whether strerror_r has the POSIX API before enabling GNU
25266         extensions.  On Android, enabling GNU extensions switches from the
25267         POSIX to the GNU API.  Problem reported by Lucy Phipps in:
25268         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00026.html
25270         string, wchar: port rpl_free decl to Android
25271         * lib/string.in.h, lib/wchar.in.h:
25272         (free): When replacing it, declare the unreplaced version too.
25273         Problem reported by Lucy Phipps in:
25274         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00026.html
25276 2021-09-07  Paul Eggert  <eggert@cs.ucla.edu>
25278         string, wchar: avoid some namespace pollution
25279         * lib/string.in.h, lib/wchar.in.h:
25280         (free): Declare by hand instead of including stdlib.h.
25281         This avoids some namespace pollution.  It should also avoid some
25282         nested-include problems described by Lucy Phipps in:
25283         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00018.html
25284         * modules/string, modules/wchar:
25285         (Depends-on): Add stdlib, so that REPLACE_FREE has the right value.
25286         (Makefile.am): Replace @REPLACE_FREE@ when creating the include file.
25288 2021-09-04  Paul Eggert  <eggert@cs.ucla.edu>
25290         idx: break copying from glibc
25291         * config/srclist.txt: Comment out idx.h, and bring back recent change.
25293 2021-09-04  Sun Haiyong  <youbest@sina.com>  (tiny change)
25295         sigsegv: Improve cross-compilation support for LoongArch CPU.
25296         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Assume the stack grows
25297         down on LoongArch.
25299 2021-09-04  Simon Josefsson  <simon@josefsson.org>
25301         doc: Improve help related to bootstrap script.
25302         * doc/gnulib-tool.texi (VCS Issues): Make title more positive,
25303         s/Issues/Integration/.  Some more bootstrap-related hints,
25304         including changing suggested submodule path from .gnulib to gnulib
25305         as this seems to be more wide-spread.
25307 2021-09-04  Paul Eggert  <eggert@cs.ucla.edu>
25309         intprops: fix minor doc glitches
25310         * doc/intprops.texi (Integer Properties): Fix doc glitches.
25312 2021-09-04  Simon Josefsson  <simon@josefsson.org>
25314         doc: Add suggestions on FDL texinfo usage.
25315         * doc/licenses-texi.texi (License Texinfo sources): Add texinfo
25316         examples.
25318 2021-09-03  Simon Josefsson  <simon@josefsson.org>
25320         maintainer-makefile: Add indentation syntax-check rule.
25321         * top/maint.mk (indent): Use AM_V_GEN and indent_args.
25322         (sc_indent): New rule.
25323         (indent_args): New variable.
25324         (C_SOURCES): New variable, initialized to reasonable C files.
25325         (exclude_file_name_regexp--indent): New variable.
25327 2021-08-30  Paul Eggert  <eggert@cs.ucla.edu>
25329         idx: add commentary
25330         * lib/idx.h: Add comments about ssize_t and strlen, in
25331         response to comments from Simon Josefsson in:
25332         https://lists.gnu.org/r/bug-gnulib/2021-08/msg00196.html
25334 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
25336         attribute: keep up with gnulib-common.m4
25337         * lib/attribute.h (ATTRIBUTE_DEALLOC, ATTRIBUTE_DEALLOC_FREE):
25338         New macros, aliases for the _GL_-prefixed macros added
25339         to gnulib-common.m4 last month.
25341 2021-08-29  Bruno Haible  <bruno@clisp.org>
25343         supersede: Fix test failure under QEMU user-mode for Linux/mips.
25344         * tests/test-supersede-open.h (test_open_supersede): Copy statbuf.st_dev
25345         into a local variable of type dev_t.
25346         * tests/test-supersede-fopen.h (test_fopen_supersede): Likewise.
25348 2021-08-29  Bruno Haible  <bruno@clisp.org>
25350         spawn-pipe: Fix test failure when running under QEMU user-mode.
25351         * tests/test-spawn-pipe-child.c: Include <stdbool.h>, <string.h>,
25352         qemu.h.
25353         (main): Under QEMU user-mode, allow fd 2 or fd 3 to be open.
25354         * modules/spawn-pipe-tests (Files): Add qemu.h.
25355         (Depends-on): Add stdbool.
25357 2021-08-29  Bruno Haible  <bruno@clisp.org>
25359         execute: Fix test failure when running under QEMU user-mode.
25360         * tests/test-execute-child.c: Include <stdbool.h>, qemu.h.
25361         (main): Under QEMU user-mode, allow fd 3 to be open.
25362         * modules/execute-tests (Files): Add qemu.h.
25363         (Depends-on): Add stdbool.
25365 2021-08-29  Bruno Haible  <bruno@clisp.org>
25367         posix_spawn_file_actions_addfchdir: Avoid test failure under QEMU.
25368         * tests/test-posix_spawn-fchdir.c: Include qemu.h.
25369         (is_qemu): New variable.
25370         (test): Under QEMU user-mode, don't expect that "pwd" produces the
25371         result "/".
25372         (main): Initialize is_qemu. Under QEMU user-mode, skip the relative file
25373         name test.
25374         * modules/posix_spawn_file_actions_addfchdir-tests (Files): Add qemu.h.
25375         (Depends-on): Add stdbool.
25377 2021-08-29  Bruno Haible  <bruno@clisp.org>
25379         getcwd tests: Avoid test failure when running under QEMU user-mode.
25380         * modules/getcwd-tests (Files): Add qemu.h.
25381         (Depends-on): Add stdbool.
25382         * tests/test-getcwd.c: Include qemu.h.
25383         (test_long_name): Skip this test when running under QEMU user-mode.
25384         (main): Consider return code 77 from test_long_name.
25386 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
25388         base32, base64: treat negative sizes as overflows
25389         * lib/base64.c (base64_encode_alloc):
25390         * lib/base32.c (base32_encode_alloc):
25391         Treat negative sizes as overflows, for better compatibility
25392         with previous API.
25394 2021-08-29  Bruno Haible  <bruno@clisp.org>
25396         explicit_bzero test: Fix test failure due to GCC optimizations.
25397         * tests/test-explicit_bzero.c (do_secret_stuff): Use static variable
25398         'last_stackbuf'.
25399         (main): Use an 'if' to combine the two do_secret_stuff invocations.
25401 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
25403         dfa: port to non-gnulib
25404         Suggested by Arnold Robbins in:
25405         https://lists.gnu.org/r/bug-gnulib/2021-08/msg00181.html
25406         * lib/dfa.h (_GL_ATTRIBUTE_DEALLOC) [!_GL_ATTRIBUTE_MALLOC]:
25407         Add missing definition.
25409 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
25411         base32, base64: fix broken tests
25412         Problem reported by Bruno Haible in:
25413         https://lists.gnu.org/r/bug-gnulib/2021-08/msg00170.html
25414         * lib/base32.c, lib/base64.c: Do not include verify.h,
25415         and omit all uses of ‘assume’.
25416         * modules/base32, modules/base64 (Depends-on): Remove verify.
25417         * tests/test-base32.c, tests/test-base64.c:
25418         Don’t pass out-of-range values to allocator,
25419         as converting them to idx_t relies on implementation-defined
25420         behavior that could trap.
25422         ialloc: relicense
25423         * modules/ialloc (License): Change from LGPL to LGPLv2+.
25425 2021-08-28  Bruno Haible  <bruno@clisp.org>
25427         fma: Fix compilation error on Linux/sh4.
25428         * lib/fma.c (FUNC): Don't test for FE_DOWNWARD or FE_UPWARD when these
25429         rounding modes are not defined.
25431 2021-08-28  Bruno Haible  <bruno@clisp.org>
25433         Skip some tests when running under QEMU user-mode.
25434         * tests/qemu.h: New file.
25435         * tests/test-get-rusage-as.c: Include qemu.h.
25436         (main): Skip the test when running under QEMU.
25437         * tests/test-get-rusage-data.c: Include qemu.h.
25438         (main): Skip the test when running under QEMU.
25439         * tests/test-printf-posix2.c: Include qemu.h.
25440         (main): Return with code 77 when running under QEMU.
25441         * tests/test-fprintf-posix2.c: Include qemu.h.
25442         (main): Return with code 77 when running under QEMU.
25443         * tests/test-fprintf-posix3.c: Include qemu.h.
25444         (main): Return with code 79 when running under QEMU.
25445         * tests/test-fprintf-posix3.sh: Skip the test when the return code was
25446         79.
25447         * tests/test-dprintf-posix2.c: Include qemu.h.
25448         (main): Return with code 79 when running under QEMU. Use return code 80
25449         instead of 78.
25450         * tests/test-dprintf-posix2.sh: Skip the test when the return code was
25451         79. Update for changed return code.
25452         * modules/get-rusage-as-tests (Files): Add qemu.h.
25453         (Depends-on): Add stdbool.
25454         * modules/get-rusage-data-tests (Files): Add qemu.h.
25455         (Depends-on): Add stdbool.
25456         * modules/fprintf-posix-tests (Files): Add qemu.h.
25457         (Depends-on): Add stdbool.
25458         * modules/dprintf-posix-tests (Files): Add qemu.h.
25459         (Depends-on): Add stdbool.
25461 2021-08-28  Bruno Haible  <bruno@clisp.org>
25463         sigabbrev_np, sigdescr_np: Fix compilation error on Linux/alpha.
25464         * lib/sigabbrev_np.c (sigabbrev_np): When SIGINFO and SIGPWR have the
25465         same value, give precendence to SIGPWR.
25466         * lib/sigdescr_np.c (sigdescr_np): Likewise.
25467         * tests/test-sigabbrev_np.c (main): Likewise.
25468         * tests/test-sigdescr_np.c (main): Likewise.
25470 2021-08-28  Bruno Haible  <bruno@clisp.org>
25472         execle, execve, execvpe tests: Fix test failures under qemu user-mode.
25473         * test-execle-main.c: Include <string.h>.
25474         (get_environ_assignment, create_minimal_env): New functions.
25475         (main): Call create_minimal_env.
25476         * test-execve-main.c: Likewise.
25477         * test-execvpe-main.c: Likewise.
25479 2021-08-27  Paul Eggert  <eggert@cs.ucla.edu>
25481         base32, base64: prefer signed to unsigned integers
25482         * lib/base32.c, lib/base64.c: Include ialloc.h instad of stdlib.h.
25483         Include intprops.h, verify.h.
25484         * lib/base32.c (base32_encode, base32_encode_alloc, get_8, decode_8)
25485         (base32_decode_ctx, base32_decode_alloc_ctx):
25486         * lib/base32.h (struct base32_decode_context):
25487         * lib/base64.c (base64_encode_fast, base64_encode)
25488         (base64_encode_alloc, get_4, decode_4, base64_decode_ctx)
25489         (base64_decode_alloc_ctx):
25490         * lib/base64.h (struct base64_decode_context):
25491         * tests/test-base32.c (main):
25492         * tests/test-base64.c (main):
25493         Prefer signed to unsigned integers.
25494         * lib/base32.c (base32_encode_alloc):
25495         * lib/base64.c (base64_encode_alloc):
25496         Use simpler and more-direct check for overflow, removing a TODO.
25497         * lib/base32.h, lib/base64.h: Include idx.h instead of stddef.h.
25498         * modules/base32, modules/base64 (Depends-on): Add ialloc, verify.
25500 2021-08-26  Paul Eggert  <eggert@cs.ucla.edu>
25502         regex: use __attr_access and C99-style array arg
25503         This should help with some static checking.
25504         Derived from a suggestion by Martin Sebor in:
25505         https://sourceware.org/pipermail/libc-alpha/2021-August/130336.html
25506         * config/srclist.txt: Remove lib/regex.c for now.
25507         * lib/regex.c: Ignore -Wvla for the whole file.
25508         * lib/regex.h (_REGEX_NELTS, _Attr_access_): New macros.
25509         Ignore -Wvla when declaring regexec.
25510         (re_compile_pattern, re_search, re_search2, re_match, re_match_2)
25511         (regerror): Mark with _Attr_access_, as glibc does.
25512         * lib/regex.h (regexec):
25513         * lib/regexec.c (regexec, __compat_regexec):
25514         Use _REGEX_NELTS for each array parameter whose size is another arg
25515         but with an access pattern that cannot be captured with __attr_access.
25517 2021-08-25  Bruno Haible  <bruno@clisp.org>
25519         execute tests: Fix test failure when libtool is in use.
25520         * modules/execute-tests (Makefile.am): Link test-execute-child without
25521         using libtool.
25522         * modules/spawn-pipe-tests (Makefile.am): Link test-spawn-pipe-child
25523         without using libtool.
25524         * modules/system-quote-tests (Makefile.am): Link test-system-quote-child
25525         without using libtool.
25527 2021-08-24  Paul Eggert  <eggert@cs.ucla.edu>
25529         dfa: prefer idx_t to ptrdiff_t for nonnegative
25530         * lib/dfa.c (struct dfa, dfaexec_main, dfaexec_mb, dfaexec_sb)
25531         (dfaexec_noop, dfaexec):
25532         * lib/dfa.h (dfaparse, dfacomp, dfaexec):
25533         Prefer idx_t to ptrdiff_t for counts, which should be nonnegative.
25534         * lib/dfa.h: Include idx.h.
25536 2021-08-22  Bruno Haible  <bruno@clisp.org>
25538         snippet/unused-parameter: Mark unused module obsolete.
25539         * modules/snippet/unused-parameter (Status, Notice): Mark as obsolete.
25541 2021-08-22  Bruno Haible  <bruno@clisp.org>
25543         Make generated .in.h files as standalone as possible.
25544         Reported by Jan Engelhardt <jengelh@inai.de>.
25545         * lib/stdlib.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE,
25546         _GL_ATTRIBUTE_MALLOC): Add fallback definitions.
25547         * lib/dirent.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_MALLOC): Add
25548         fallback definitions.
25549         * lib/stdio.in.h (_GL_ATTRIBUTE_DEALLOC): Add fallback definition.
25550         * lib/math.in.h (_GL_ATTRIBUTE_CONST): Add fallback definition.
25551         * lib/pthread.in.h (_GL_ATTRIBUTE_PURE): Add fallback definition.
25552         * lib/threads.in.h (_GL_ATTRIBUTE_PURE): Likewise.
25553         * lib/uchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
25554         * lib/string.in.h (_GL_ATTRIBUTE_PURE): Move definition, for consistency
25555         with the other *.in.h files.
25556         * lib/se-context.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Add fallback
25557         definition.
25558         * lib/se-label.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Likewise.
25559         * lib/se-selinux.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Likewise.
25560         * lib/textstyle.in.h: Use _GL_ATTRIBUTE_MAYBE_UNUSED instead of
25561         _GL_UNUSED.
25562         (_GL_ATTRIBUTE_SPEC_PRINTF_STANDARD, _GL_ATTRIBUTE_MAYBE_UNUSED): Add
25563         fallback definitions.
25565 2021-08-22  Bruno Haible  <bruno@clisp.org>
25567         gnulib-common.m4: Clarify logic behind _GL_UNUSED_LABEL.
25568         Reported by Paul Eggert.
25569         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add comment and write the
25570         condition in a way that is close to the comment.
25572 2021-08-22  Paul Eggert  <eggert@cs.ucla.edu>
25574         c-stack: depend on inttypes, mempcpy
25575         * modules/c-stack (Depends-on): Add inttypes, mempcpy.
25576         mempcpy problem reported by Evan Miller in:
25577         https://debbugs.gnu.org/50098#31
25579 2021-08-22  Bruno Haible  <bruno@clisp.org>
25581         mountlist: Use recommended syntax for _GL_UNUSED_LABEL.
25582         * lib/mountlist.c (read_file_system_list): Add semicolon after
25583         _GL_UNUSED_LABEL.
25585 2021-08-22  Bruno Haible  <bruno@clisp.org>
25587         gnulib-common.m4: Make _GL_UNUSED_LABEL effective for clang.
25588         * m4/gnulib-common.m4 (gl_COMMON_BODY): Make _GL_UNUSED_LABEL use
25589         _GL_ATTRIBUTE_UNUSED also for clang.
25591 2021-08-22  Bruno Haible  <bruno@clisp.org>
25593         gnulib-common.m4: Use C2x [[maybe_unused]] when possible.
25594         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _GL_UNUSED as an alias of
25595         _GL_ATTRIBUTE_MAYBE_UNUSED, not of _GL_ATTRIBUTE_UNUSED.
25596         * lib/binary-io.h (__gl_setmode): Put _GL_UNUSED before, not after, the
25597         declaration.
25598         * lib/c-stack.c (null_action, segv_handler, overflow_handler,
25599         c_stack_action): Likewise.
25600         * lib/chown.c (chown): Likewise.
25601         * lib/clean-temp-simple.c (cleanup_action): Likewise.
25602         * lib/fts.c (dirent_inode_sort_may_be_useful, leaf_optimization,
25603         fts_set): Likewise.
25604         * lib/getgroups.c (getgroups): Likewise.
25605         * lib/getopt.c (_getopt_initialize): Likewise.
25606         * lib/getugroups.c (getugroups): Likewise.
25607         * lib/localename.c (gl_locale_name_thread_unsafe, gl_locale_name_thread,
25608         gl_locale_name_posix, gl_locale_name_environ): Likewise.
25609         * lib/mkdir.c (rpl_mkdir): Likewise.
25610         * lib/mkfifo.c (mkfifo): Likewise.
25611         * lib/mkfifoat.c (mkfifoat): Likewise.
25612         * lib/mknod.c (mknod): Likewise.
25613         * lib/mknodat.c (mknodat): Likewise.
25614         * lib/mountlist.c (me_remote): Likewise.
25615         * lib/openpty.c (openpty): Likewise.
25616         * lib/parse-datetime.y (yyerror): Likewise.
25617         * lib/passfd.c (sendfd, recvfd): Likewise.
25618         * lib/pthread-cond.c (pthread_condattr_destroy, pthread_cond_init,
25619         pthread_cond_wait, pthread_cond_timedwait, pthread_cond_signal,
25620         pthread_cond_broadcast, pthread_cond_destroy): Likewise.
25621         * lib/pthread-mutex.c (pthread_mutexattr_destroy, pthread_mutex_init,
25622         pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_timedlock,
25623         pthread_mutex_unlock, pthread_mutex_destroy): Likewise.
25624         * lib/pthread-rwlock.c (pthread_rwlockattr_destroy, pthread_rwlock_init,
25625         pthread_rwlock_timedrdlock, pthread_rwlock_timedwrlock): Likewise.
25626         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
25627         pthread_spin_trylock, pthread_spin_unlock, pthread_spin_destroy):
25628         Likewise.
25629         * lib/pthread-thread.c (pthread_attr_destroy): Likewise.
25630         * lib/readlink.c (readlink): Likewise.
25631         * lib/rename.c (rpl_rename): Likewise.
25632         * lib/set-permissions.c (set_permissions): Likewise.
25633         * lib/sockets.c (gl_sockets_startup): Likewise.
25634         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime,
25635         stat_time_normalize): Likewise.
25636         * lib/strptime.c (__strptime_internal): Likewise.
25637         * lib/strtod.c (LDEXP): Likewise.
25638         * lib/symlink.c (symlink): Likewise.
25639         * lib/symlinkat.c (symlinkat): Likewise.
25640         * lib/tempname.c (try_dir, try_nocreate): Likewise.
25641         * lib/textstyle.in.h (styled_ostream_begin_use_class,
25642         styled_ostream_end_use_class, styled_ostream_get_hyperlink_ref,
25643         styled_ostream_get_hyperlink_id, styled_ostream_set_hyperlink,
25644         styled_ostream_flush_to_current_style, fd_ostream_create,
25645         term_ostream_get_color, term_ostream_set_color,
25646         term_ostream_get_bgcolor, term_ostream_set_bgcolor,
25647         term_ostream_get_weight, term_ostream_set_weight,
25648         term_ostream_get_posture, term_ostream_set_posture,
25649         term_ostream_get_underline, term_ostream_set_underline,
25650         term_ostream_get_hyperlink_ref, term_ostream_get_hyperlink_id,
25651         term_ostream_set_hyperlink, term_ostream_create,
25652         term_styled_ostream_create, html_styled_ostream_create,
25653         handle_color_option, handle_style_option, style_file_prepare,
25654         styled_ostream_create, libtextstyle_set_failure_exit_code): Likewise.
25655         * lib/unicodeio.c (exit_failure_callback, fallback_failure_callback):
25656         Likewise.
25657         * lib/wait-process.c (cleanup_slaves_action): Likewise.
25658         * tests/signature.h (SIGNATURE_CHECK2): Likewise.
25659         * tests/test-areadlink.c (do_areadlink): Likewise.
25660         * tests/test-areadlinkat.c (do_areadlinkat): Likewise.
25661         * tests/test-ceilf-ieee.c (main): Likewise.
25662         * tests/test-ceilf1.c (main): Likewise.
25663         * tests/test-dirent.c (dir): Likewise.
25664         * tests/test-fchownat.c (main): Likewise.
25665         * tests/test-fdopendir.c (main): Likewise.
25666         * tests/test-filenamecat.c (main): Likewise.
25667         * tests/test-floor1.c (main): Likewise.
25668         * tests/test-floorf-ieee.c (main): Likewise.
25669         * tests/test-floorf1.c (main): Likewise.
25670         * tests/test-fseeko.c (main): Likewise.
25671         * tests/test-fstatat.c (main): Likewise.
25672         * tests/test-ftello.c (main): Likewise.
25673         * tests/test-getdomainname.c (main): Likewise.
25674         * tests/test-getgroups.c (main): Likewise.
25675         * tests/test-gethostname.c (main): Likewise.
25676         * tests/test-math-c++.cc (OVERLOADED_CHECK): Likewise.
25677         * tests/test-mkdirat.c (main): Likewise.
25678         * tests/test-openat.c (main): Likewise.
25679         * tests/test-parse-datetime.c (main): Likewise.
25680         * tests/test-quotearg-simple.c (main): Likewise.
25681         * tests/test-quotearg.c (main): Likewise.
25682         * tests/test-sethostname2.c (main): Likewise.
25683         * tests/test-unlinkat.c (main): Likewise.
25684         * tests/test-version-etc.c (main): Likewise.
25685         * tests/test-xalloc-die.c (main): Likewise.
25686         * tests/test-xfprintf-posix.c (main): Likewise.
25687         * tests/test-xprintf-posix.c (main): Likewise.
25688         * tests/test-xvasprintf.c (main): Likewise.
25690 2021-08-22  Bruno Haible  <bruno@clisp.org>
25692         gnulib-common.m4: Document the gnulib-internal _GL_ATTRIBUTE_* macros.
25693         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add comments to the
25694         _GL_ATTRIBUTE_* macros, based on lib/attribute.h.
25696 2021-08-22  Bernhard Voelker  <mail@bernhard-voelker.de>
25698         doc: fix order of stdlib functions
25699         * doc/gnulib.texi (node Glibc stdlib.h): Move mrand48_r after mkstemps.
25700         Reported by Benno Schulenberg.
25702 2021-08-21  Bruno Haible  <bruno@clisp.org>
25704         c-stack: Test for libsigsegv once, not twice.
25705         * m4/sigsegv.m4: New file, based on modules/sigsegv.
25706         * modules/sigsegv (Files): Add it.
25707         (configure.ac): Require gl_SIGSEGV. Test gl_sigsegv_uses_libsigsegv
25708         instead of with_libsigsegv and gl_cv_lib_sigsegv.
25709         * m4/c-stack.m4 (gl_C_STACK): Likewise.
25711 2021-08-21  Bruno Haible  <bruno@clisp.org>
25713         rawmemchr: Fix use in relocatable-prog-wrapper (regression 2021-08-20).
25714         * lib/rawmemchr.c: Restore test of HAVE_RAWMEMCHR.
25715         * modules/relocatable-prog-wrapper (Depends-on): Add stdalign.
25717 2021-08-20  Paul Eggert  <eggert@cs.ucla.edu>
25719         rawmemchr: modernize and simplify
25720         * lib/rawmemchr.c (HAVE_RAWMEMCHR): Assume it’s not defined;
25721         otherwise this file would not be compiled.  Include limits.h,
25722         stdalign.h, stdint.h, verify.h.
25723         (rawmemchr): Prefer uintptr_t to unsigned long and to size_t when
25724         it’s the better type.  Verify that longword lacks padding.  Use
25725         alignof rather than sizeof when checking alignment.  Simplify by
25726         assuming C99 decl-after-statement, and by using multiplication
25727         rather than repeated shifting and OR (modern compilers can
25728         optimize the multiplication if needed).  Avoid unnecessary casts.
25729         Don’t assume CHAR_WIDTH is 8.  Convert back and forth between void *
25730         to suppress bogus GCC warnings about alignment.  Omit a
25731         duplicate assignment to char_ptr.
25732         * modules/rawmemchr (Depends-on): Add stdalign, stdint, verify.
25734 2021-08-17  Paul Eggert  <eggert@cs.ucla.edu>
25736         c-stack: fix libsigsegv dependency (regression 2021-05-18)
25737         Problem reported for GNU grep by Evan Miller (Bug#50098).
25738         * m4/c-stack.m4 (gl_C_STACK): Call gl_LIBSIGSEGV before
25739         testing gl_cv_lib_sigsegv.
25741 2021-08-14  Bruno Haible  <bruno@clisp.org>
25743         doc: Update for glibc 2.34.
25744         * doc/posix-functions/timespec_getres.texi: New file.
25745         * doc/glibc-functions/_Fork.texi: New file.
25746         * doc/glibc-functions/closefrom.texi: New file.
25747         * doc/glibc-functions/dn_comp.texi: New file.
25748         * doc/glibc-functions/dn_skipname.texi: New file.
25749         * doc/glibc-functions/execveat.texi: New file.
25750         * doc/glibc-functions/posix_spawn_file_actions_addclosefrom_np.texi: New
25751         file.
25752         * doc/glibc-functions/res_dnok.texi: New file.
25753         * doc/glibc-functions/res_hnok.texi: New file.
25754         * doc/glibc-functions/res_mailok.texi: New file.
25755         * doc/glibc-functions/res_nmkquery.texi: New file.
25756         * doc/glibc-functions/res_nquery.texi: New file.
25757         * doc/glibc-functions/res_nquerydomain.texi: New file.
25758         * doc/glibc-functions/res_nsearch.texi: New file.
25759         * doc/glibc-functions/res_nsend.texi: New file.
25760         * doc/glibc-functions/res_ownok.texi: New file.
25761         * doc/glibc-functions/res_send.texi: New file.
25762         * doc/gnulib.texi: Include them.
25763         * doc/glibc-functions/inet_neta.texi: Remove file.
25764         * doc/glibc-functions/malloc_get_state.texi: Remove file.
25765         * doc/glibc-functions/malloc_set_state.texi: Remove file.
25766         * doc/glibc-functions/pthread_mutex_consistent_np.texi: Remove file.
25767         * doc/glibc-functions/pthread_mutexattr_getrobust_np.texi: Remove file.
25768         * doc/glibc-functions/pthread_mutexattr_setrobust_np.texi: Remove file.
25769         * doc/glibc-functions/pthread_yield.texi: Remove file.
25770         * doc/gnulib.texi: Don't include them.
25771         * doc/glibc-headers/resolv.texi: Update.
25772         * doc/pastposix-functions/h_errno.texi: Likewise.
25773         * doc/posix-functions/*.texi: Likewise.
25774         * doc/glibc-functions/*.texi: Likewise.
25776 2021-08-12  Paul Eggert  <eggert@cs.ucla.edu>
25778         memrchr-tests: port to GCC 12
25779         * tests/test-memrchr.c: Bug#101494 is fixed in GCC 12.
25781 2021-08-12  Akim Demaille  <akim@lrde.epita.fr>
25783         snippet/_Noreturn: Fix typo
25784         * lib/_Noreturn.h: Fix spelling of 4.
25786 2021-08-11  Paul Eggert  <eggert@cs.ucla.edu>
25788         dynarray: merge from glibc
25789         This also helps document glibc’s direction in using GCC’s
25790         memory-allocation checking.
25791         * lib/cdefs.h: Omit comments that glibc rejected.
25792         (__returns_nonnull, __attr_access_none, __attr_dealloc)
25793         (__attr_dealloc_free): New macros.
25794         * lib/libc-config.h: Undef the new macros that are defined
25795         unconditionally.
25796         * lib/malloc/dynarray_at_failure.c [_LIBC]: Do not include stdlib.h.
25797         (__libc_dynarray_at_failure) [_LIBC]: Call __libc_fatal,
25798         fixing a bad merge previously.
25800 2021-08-08  Bruno Haible  <bruno@clisp.org>
25802         canonicalize-lgpl: Fix conflict with z/OS <sys/stat.h>.
25803         Reported by Mike Fulton <mikefultonpersonal@gmail.com> in
25804         <https://lists.gnu.org/archive/html/m4-discuss/2021-08/msg00000.html>
25805         via Eric Blake.
25806         * lib/canonicalize-lgpl.c (__stat): Remove macro.
25807         (file_accessible): Use 'stat' instead.
25809 2021-08-08  Bruno Haible  <bruno@clisp.org>
25811         ptsname_r: Drop sync with glibc.
25812         * lib/ptsname_r.c: Drop _LIBC code.
25813         (__set_errno, __isatty, __stat, __ttyname_r, __ptsname_r): Remove
25814         macros.
25815         (ptsname_r): Rename local variable 'save_errno'.
25817 2021-08-08  Bruno Haible  <bruno@clisp.org>
25819         config: Update after glibc changed.
25820         * config/srclist.txt: Remove two files that glibc dropped on 2013-12-17.
25822 2021-08-08  Bruno Haible  <bruno@clisp.org>
25824         relocatable-lib-lgpl: Fix a memory leak related to a Windows DLL.
25825         Reported by Jonathan Boeing <jonathan@claws-mail.org> in
25826         <https://lists.gnu.org/archive/html/bug-gnulib/2021-08/msg00048.html>.
25827         * lib/relocatable.c (DllMain): Avoid memory leak in a special case
25828         of repeated attach/detach.
25830 2021-08-08  Bruno Haible  <bruno@clisp.org>
25832         fopen: Fix link error on native Windows.
25833         * modules/fopen (Depends-on): Add close.
25835 2021-08-08  Bruno Haible  <bruno@clisp.org>
25837         fopen: Fix compilation error on AIX (regression from 2020-05-28).
25838         * modules/fopen (Depends-on): Add fcntl-h.
25840 2021-08-08  Bruno Haible  <bruno@clisp.org>
25842         stdio: Improve GCC 11 allocation-deallocation checking.
25843         * lib/stdio.in.h (fdopen, fopen, tmpfile): For GCC >= 11: Declare nearly
25844         always.
25845         (popen): For GCC >= 11: Declare also when the platform already declares
25846         the function or when the module 'popen' is not in use.
25848 2021-08-08  Bruno Haible  <bruno@clisp.org>
25850         dirent: Improve GCC 11 allocation-deallocation checking.
25851         * lib/dirent.in.h (opendir): For GCC >= 11: Declare also when the
25852         platform already declares the function or when the module 'opendir' is
25853         not in use.
25854         (fdopendir): For GCC >= 11: Declare also when the platform already
25855         declares the function or when the module 'fdopendir' is not in use.
25857 2021-08-08  Bruno Haible  <bruno@clisp.org>
25859         stdlib, string, wchar: Improve GCC 11 allocation-deallocation checking.
25860         * lib/stdlib.in.h (aligned_alloc): For GCC >= 11: Declare also when the
25861         platform already declares the function or when the module
25862         'aligned_alloc' is not in use.
25863         (calloc): For GCC >= 11: Declare nearly always.
25864         (canonicalize_file_name): For GCC >= 11: Declare also when the platform
25865         already declares the function or when the module 'canonicalize-lgpl' is
25866         not in use.
25867         (malloc, realloc): For GCC >= 11: Declare nearly always.
25868         * lib/malloc.in.h: Remove redundant include.
25869         (memalign): For GCC >= 11: Declare also when the platform already
25870         declares the function or when the module 'memalign' is not in use.
25871         * lib/string.in.h: Include <stdlib.h> always.
25872         (strdup): For GCC >= 11: Declare also when the platform already declares
25873         the function or when the module 'strdup' or 'strdup-posix' is not in
25874         use.
25875         * lib/wchar.in.h: Include <stdlib.h> always.
25876         (wcsdup): For GCC >= 11: Declare also when the platform already declares
25877         the function or when the module 'wcsdup' is not in use.
25878         * modules/free-posix (Depends-on): Add string, wchar.
25880 2021-08-07  Bruno Haible  <bruno@clisp.org>
25882         gnulib-tool: Add support for Automake 1.16.4.
25883         Reported by <shoober420@gmail.com> in
25884         <https://lists.gnu.org/archive/html/bug-libunistring/2021-08/msg00000.html>.
25885         * build-aux/test-driver-1.16.3.diff: Renamed from
25886         build-aux/test-driver.diff.
25887         * build-aux/test-driver.diff: Update to match Automake 1.16.4.
25888         * gnulib-tool (func_create_testdir, func_create_megatestdir): Try both
25889         .diff files.
25891 2021-08-07  Bruno Haible  <bruno@clisp.org>
25893         gnulib-common.m4: Minor style fix.
25894         * m4/gnulib-common.m4 (gl_COMMON_BODY): Keep list of attributes sorted
25895         alphabetically.
25897 2021-08-07  Bruno Haible  <bruno@clisp.org>
25899         uninorm, unistr: Improve GCC 11 allocation-deallocation checking.
25900         * lib/uninorm.in.h (uninorm_filter_free): Move declaration up.
25901         (uninorm_filter_create): Declare that deallocation must happen through
25902         'uninorm_filter_free'.
25903         * lib/unistr.in.h: Include <stdlib.h>.
25904         (u8_strdup, u16_strdup, u32_strdup): Declare that deallocation must
25905         happen through 'free'.
25907 2021-08-07  Bruno Haible  <bruno@clisp.org>
25909         ialloc: Prepare for allocation-deallocation checking.
25910         * lib/ialloc.h (imalloc, irealloc, icalloc): Add comment that
25911         deallocation must happen through 'free'.
25913 2021-08-07  Bruno Haible  <bruno@clisp.org>
25915         aligned-malloc: Prepare for allocation-deallocation checking.
25916         * lib/aligned-malloc.h (aligned_free): Move declaration up.
25917         (aligned_malloc): Add comment that deallocation must happen through
25918         'aligned_free'.
25920 2021-08-07  Bruno Haible  <bruno@clisp.org>
25922         list, set, oset, map, omap: Prepare allocation-deallocation checking.
25923         * lib/gl_list.h (gl_list_create_empty, gl_list_nx_create_empty,
25924         gl_list_create, gl_list_nx_create): Add comment that deallocation must
25925         happen through 'gl_list_free'.
25926         * lib/gl_xlist.h (gl_list_create_empty, gl_list_create): Likewise.
25927         * lib/gl_sublist.h (gl_sublist_create, gl_sublist_nx_create): Likewise.
25928         * lib/gl_xsublist.h (gl_sublist_create): Likewise.
25929         * lib/gl_set.h (gl_set_create_empty, gl_set_nx_create_empty): Add
25930         comment that deallocation must happen through 'gl_set_free'.
25931         * lib/gl_xset.h (gl_set_create_empty): Likewise.
25932         * lib/gl_oset.h (gl_oset_create_empty, gl_oset_nx_create_empty): Add
25933         comment that deallocation must happen through 'gl_oset_free'.
25934         * lib/gl_xoset.h (gl_oset_create_empty): Likewise.
25935         * lib/gl_map.h (gl_map_create_empty, gl_map_nx_create_empty): Add
25936         comment that deallocation must happen through 'gl_map_free'.
25937         * lib/gl_xmap.h (gl_map_create_empty): Likewise.
25938         * lib/gl_omap.h (gl_omap_create_empty, gl_omap_nx_create_empty): Add
25939         comment that deallocation must happen through 'gl_omap_free'.
25940         * lib/gl_xomap.h (gl_omap_create_empty): Likewise.
25942 2021-08-07  Bruno Haible  <bruno@clisp.org>
25944         xgetdomainname: Improve GCC 11 allocation-deallocation checking.
25945         * lib/xgetdomainname.h: Include <stdlib.h>.
25946         (xgetdomainname): Declare that deallocation must happen through 'free'.
25948 2021-08-07  Bruno Haible  <bruno@clisp.org>
25950         xgetdomainname: Ensure .c file starts with '#include <config.h>'.
25951         * lib/xgetaname-impl.h: New file, based on lib/xgethostname.c.
25952         * lib/xgethostname.c: Move implementation to lib/xgetaname-impl.h.
25953         * lib/xgetdomainname.c: Include <config.h>. Include xgetaname-impl.h
25954         instead of xgethostname.c.
25955         * modules/xgethostname (Files): Add lib/xgetaname-impl.h.
25956         * modules/xgetdomainname (Files): Likewise.
25957         (Depends-on): Remove xgethostname. Add free-posix, xalloc.
25959 2021-08-07  Bruno Haible  <bruno@clisp.org>
25961         xstrndup: Improve GCC 11 allocation-deallocation checking.
25962         * lib/xstrndup.h: Include <stdlib.h> instead of <stddef.h>.
25963         (xstrndup): Declare that deallocation must happen through 'free'.
25965 2021-08-07  Bruno Haible  <bruno@clisp.org>
25967         xstriconveh: Improve GCC 11 allocation-deallocation checking.
25968         * lib/xstriconveh.h: Include <stdlib.h> instead of <stddef.h>.
25969         (xstr_cd_iconveh, xstr_iconveh): Declare that deallocation must happen
25970         through 'free'.
25972 2021-08-07  Bruno Haible  <bruno@clisp.org>
25974         xmemdup0: Improve GCC 11 allocation-deallocation checking.
25975         * lib/xmemdup0.h: Include <stdlib.h> instead of <stddef.h>.
25976         (xmemdup0): Declare that deallocation must happen through 'free'.
25978 2021-08-07  Bruno Haible  <bruno@clisp.org>
25980         windows-spawn: Improve GCC 11 allocation-deallocation checking.
25981         * lib/windows-spawn.h: Include <stdlib.h>.
25982         (compose_command, compose_envblock): Declare that deallocation must
25983         happen through 'free'.
25985 2021-08-07  Bruno Haible  <bruno@clisp.org>
25987         string-buffer: Improve GCC 11 allocation-deallocation checking.
25988         * lib/string-buffer.h: Include <stdlib.h> instead of <stddef.h>.
25989         (sb_dupfree): Declare that deallocation must happen through 'free'.
25991 2021-08-07  Bruno Haible  <bruno@clisp.org>
25993         striconveha: Improve GCC 11 allocation-deallocation checking.
25994         * lib/striconveha.h: Include <stdlib.h> instead of <stddef.h>.
25995         (str_iconveha): Declare that deallocation must happen through 'free'.
25997 2021-08-07  Bruno Haible  <bruno@clisp.org>
25999         striconveh: Improve GCC 11 allocation-deallocation checking.
26000         * lib/striconveh.h: Include <stdlib.h> instead of <stddef.h>.
26001         (str_cd_iconveh, str_iconveh): Declare that deallocation must happen
26002         through 'free'.
26004 2021-08-07  Bruno Haible  <bruno@clisp.org>
26006         striconv: Improve GCC 11 allocation-deallocation checking.
26007         * lib/striconv.h: Include <stdlib.h> instead of <stddef.h>.
26008         (str_cd_iconv, str_iconv): Declare that deallocation must happen through
26009         'free'.
26011 2021-08-07  Bruno Haible  <bruno@clisp.org>
26013         relocatable-lib-lgpl: Improve GCC 11 allocation-deallocation checking.
26014         * lib/relocatable.h: Include <stdlib.h>.
26015         (compute_curr_prefix): Declare that deallocation must happen through
26016         'free'.
26018 2021-08-07  Bruno Haible  <bruno@clisp.org>
26020         regex-quote: Improve GCC 11 allocation-deallocation checking.
26021         * lib/regex-quote.h: Include <stdlib.h> instead of <stddef.h>.
26022         (regex_quote): Declare that deallocation must happen through 'free'.
26024 2021-08-07  Bruno Haible  <bruno@clisp.org>
26026         readline: Improve GCC 11 allocation-deallocation checking.
26027         * lib/readline.h: Include <stdlib.h>.
26028         (readline): Declare that deallocation must happen through 'free'.
26030 2021-08-07  Bruno Haible  <bruno@clisp.org>
26032         read-file: Improve GCC 11 allocation-deallocation checking.
26033         * lib/read-file.h: Include <stdlib.h> instead of <stddef.h>.
26034         (fread_file, read_file): Declare that deallocation must happen through
26035         'free'.
26037 2021-08-07  Bruno Haible  <bruno@clisp.org>
26039         pipe-filter-gi: Improve GCC 11 allocation-deallocation checking.
26040         * lib/pipe-filter.h (pipe_filter_gi_close): Move declaration up.
26041         (pipe_filter_gi_create): Declare that deallocation must happen through
26042         'pipe_filter_gi_close'.
26044 2021-08-07  Bruno Haible  <bruno@clisp.org>
26046         javaversion: Improve GCC 11 allocation-deallocation checking.
26047         * lib/javaversion.h: Include <stdlib.h>.
26048         (javaexec_version): Declare that deallocation must happen through
26049         'free'.
26051 2021-08-07  Bruno Haible  <bruno@clisp.org>
26053         ino-map: Improve GCC 11 allocation-deallocation checking.
26054         * lib/ino-map.h (ino_map_free): Move declaration up.
26055         (ino_map_alloc): Declare that deallocation must happen through
26056         'ino_map_free'.
26058 2021-08-07  Bruno Haible  <bruno@clisp.org>
26060         hash: Improve GCC 11 allocation-deallocation checking.
26061         * lib/hash.h (hash_free): Move declaration up.
26062         (hash_initialize, hash_xinitialize): Declare that deallocation must
26063         happen through 'hash_free'.
26065 2021-08-07  Bruno Haible  <bruno@clisp.org>
26067         hamt: Improve GCC 11 allocation-deallocation checking.
26068         * lib/hamt.h (hamt_free): Move declaration up.
26069         (hamt_create, hamt_copy): Declare that deallocation must happen through
26070         'hamt_free'.
26072 2021-08-07  Bruno Haible  <bruno@clisp.org>
26074         get_progname_of: Improve GCC 11 allocation-deallocation checking.
26075         * lib/get_progname_of.h: Include <stdlib.h>.
26076         (get_progname_of): Declare that deallocation must happen through 'free'.
26078 2021-08-07  Bruno Haible  <bruno@clisp.org>
26080         fts: Improve GCC 11 allocation-deallocation checking.
26081         * lib/fts_.h (fts_open): Declare that deallocation must happen through
26082         'fts_close'.
26084 2021-08-07  Bruno Haible  <bruno@clisp.org>
26086         eealloc: Improve GCC 11 allocation-deallocation checking.
26087         * lib/eealloc.h (eemalloc): Declare that deallocation must happen
26088         through 'free'.
26090 2021-08-07  Bruno Haible  <bruno@clisp.org>
26092         di-set: Improve GCC 11 allocation-deallocation checking.
26093         * lib/di-set.h (di_set_free): Move declaration up.
26094         (di_set_alloc): Declare that deallocation must happen through
26095         'di_set_free'.
26097 2021-08-07  Bruno Haible  <bruno@clisp.org>
26099         [x]concat-filename: Improve GCC 11 allocation-deallocation checking.
26100         * lib/concat-filename.h: Include <stdlib.h>.
26101         (concatenated_filename, xconcatenated_filename): Declare that
26102         deallocation must happen through 'free'.
26104 2021-08-07  Bruno Haible  <bruno@clisp.org>
26106         clean-temp: Improve GCC 11 allocation-deallocation checking.
26107         * lib/clean-temp.h (cleanup_temp_dir): Move declaration up.
26108         (create_temp_dir): Declare that deallocation must happen through
26109         'cleanup_temp_dir'.
26111 2021-08-07  Bruno Haible  <bruno@clisp.org>
26113         canon-host: Improve GCC 11 allocation-deallocation checking.
26114         * lib/canon-host.h: Include <stdlib.h>.
26115         (canon_host, canon_host_r): Declare that deallocation must happen
26116         through 'free'.
26118 2021-08-07  Bruno Haible  <bruno@clisp.org>
26120         c-xvasprintf: Improve GCC 11 allocation-deallocation checking.
26121         * lib/c-xvasprintf.h: Include <stdlib.h>.
26122         (c_xasprintf, c_xvasprintf): Declare that deallocation must happen
26123         through 'free'.
26125 2021-08-07  Bruno Haible  <bruno@clisp.org>
26127         bitsetv: Improve GCC 11 allocation-deallocation checking.
26128         * lib/bitsetv.h (bitsetv_free): Move declaration up.
26129         (bitsetv_alloc, bitsetv_create): Declare that deallocation must happen
26130         through 'bitsetv_free'.
26132         bitset: Improve GCC 11 allocation-deallocation checking.
26133         * lib/bitset.h (bitset_free): Move declaration up.
26134         (bitset_alloc, bitset_create): Declare that deallocation must happen
26135         through 'bitset_free'.
26136         (bitset_obstack_free): Move declaration up.
26137         (bitset_obstack_alloc): Declare that deallocation must happen through
26138         'bitset_obstack_free'.
26140 2021-08-07  Bruno Haible  <bruno@clisp.org>
26142         argv-iter: Improve GCC 11 allocation-deallocation checking.
26143         * lib/argv-iter.h (argv_iter_free): Move declaration up.
26144         (argv_iter_init_argv, argv_iter_init_stream): Declare that deallocation
26145         must happen through 'argv_iter_free'.
26147 2021-08-07  Bruno Haible  <bruno@clisp.org>
26149         argp: Improve GCC 11 allocation-deallocation checking.
26150         * lib/argp-fmtstream.h (__argp_fmtstream_free, argp_fmtstream_free):
26151         Move declarations up.
26152         (__argp_make_fmtstream): Declare that deallocation must happen through
26153         '__argp_fmtstream_free'.
26154         (argp_make_fmtstream): Declare that deallocation must happen through
26155         'argp_fmtstream_free'.
26157 2021-08-07  Bruno Haible  <bruno@clisp.org>
26159         areadlink, areadlinkat: Improve GCC 11 allocation-deallocation checking.
26160         * lib/areadlink.h: Include <stdlib.h> instead of <stddef.h>.
26161         (areadlink, areadlink_with_size, areadlinkat, areadlinkat_with_size):
26162         Declare that deallocation must happen through 'free'.
26164 2021-08-07  Bruno Haible  <bruno@clisp.org>
26166         stdio: Improve GCC 11 allocation-deallocation checking.
26167         * lib/stdio.in.h (fdopen, fopen, tmpfile): Declare that deallocation
26168         must happen through 'fclose'.
26169         (popen): Declare that deallocation must happen through 'pclose'.
26170         * lib/stdio-safer.h (fopen_safer, tmpfile_safer): Declare that
26171         deallocation must happen through 'fclose'.
26172         (popen_safer): Declare that deallocation must happen through 'pclose'.
26173         (freopen_safer): Declare that arguments must be non-NULL.
26175 2021-08-07  Bruno Haible  <bruno@clisp.org>
26177         dirent: Improve GCC 11 allocation-deallocation checking.
26178         * lib/dirent.in.h (closedir): Move declaration up.
26179         (opendir, fdopendir): Declare that deallocation must happen through
26180         'closedir'.
26181         * lib/dirent-safer.h (opendir_safer): Likewise.
26182         * lib/opendirat.h (opendirat): Likewise.
26184 2021-08-07  Bruno Haible  <bruno@clisp.org>
26186         stdlib, string, wchar: Improve GCC 11 allocation-deallocation checking.
26187         * lib/stdlib.in.h (free): Move declaration up.
26188         (aligned_alloc, calloc, canonicalize_file_name, malloc, realloc):
26189         Declare that deallocation must happen through 'free' (which may actually
26190         be 'rpl_free').
26191         * lib/string.in.h: Include <stdlib.h>.
26192         (strdup): Declare deallocation.
26193         * lib/wchar.in.h: Include <stdlib.h>.
26194         (wcsdup): Declare deallocation.
26195         * lib/malloc.in.h: Include <stdlib.h>.
26196         (memalign): Declare deallocation.
26198 2021-08-07  Bruno Haible  <bruno@clisp.org>
26200         year2038: Fix recommendation regarding -m64 flag.
26201         * m4/year2038.m4 (gl_YEAR2038_BODY): Recommend to put option --m64 in
26202         CC, not in CPPFLAGS and LDFLAGS.
26204 2021-08-07  Bruno Haible  <bruno@clisp.org>
26206         quotearg: Tweak last commit.
26207         * lib/quotearg.h: Don't include <stddef.h>. Remove stray semicolon.
26209 2021-08-07  Bruno Haible  <bruno@clisp.org>
26211         malloca: Tweak last commit.
26212         * lib/malloca.h: Keep use and declaration of mmalloca close together.
26214 2021-08-07  Bruno Haible  <bruno@clisp.org>
26216         dirname-lgpl, sh-quote, system-quote, xstriconv: Clean up includes.
26217         * lib/dirname.h: Don't include <stddef.h>.
26218         * lib/sh-quote.h: Likewise.
26219         * lib/system-quote.h: Likewise.
26220         * lib/xstriconv.h: Likewise.
26222 2021-08-07  Bruno Haible  <bruno@clisp.org>
26224         dfa: Improve GCC 11 allocation-deallocation checking.
26225         * lib/dfa.h (dfamust): Declare that deallocation must happen through
26226         dfamustfree.
26228 2021-08-06  Paul Eggert  <eggert@cs.ucla.edu>
26230         glob: merge from glibc
26231         * lib/glob-libc.h, lib/glob.c: Merge changes from glibc 2.34.
26232         The result should be copyable directly into glibc.
26233         * modules/glob-h (glob-libc.gl.h): Also omit __THROWNL.
26235 2021-08-03  Simon Josefsson  <simon@josefsson.org>
26237         announce-gen: Print SHA1/B64(SHA256) instead of MD5/SHA1.
26238         * build-aux/announce-gen (%digest_classes): Removed.
26239         (usage): Doc fix.
26240         (print_checksums): Instead of MD5/SHA1, print SHA1 and
26241         B64(SHA256), inspired by OpenSSH announcements.
26243         maintainer-makefile: Print checksums by default.
26244         * top/maint.mk (announcement): Drop --no-print-checksums.
26246 2021-08-02  Paul Eggert  <eggert@cs.ucla.edu>
26248         manywarnings: enable some malloc warnings
26249         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Stop adding
26250         -Wno-analyzer-double-free, -Wno-analyzer-null-dereference, and
26251         -Wno-analyzer-use-after-free, as these false alarms don’t seem
26252         to be as much of an issue now that we’ve pacified a couple
26253         of individual modules and GCC has some bug fixes.
26255         dfa: omit unneeded malloc+free
26256         Problem indirectly found by Coverity.
26257         * lib/dfa.c (enlistnew): New function, with most of the body of
26258         the old ‘enlist’.  It assumes its arg NEW has been malloced and
26259         can be freed eventually.
26260         (enlist, addlists, dfamust): Use it.
26261         (dfamust): Omit an unnecessary malloc+free.
26263         year2038: port to unusual time_t platforms
26264         * m4/year2038.m4 (gl_YEAR2038_TEST_INCLUDES): Check that time_t
26265         can go to 2**32 - 1, not to 2**63 - 1, as the former is enough to
26266         be year 2038 safe.  Unsigned 32-bit time_t (AmigaOS) and signed
26267         40-bit time_t (Unisys ClearPath) have occurred in the wild, and
26268         even if Gnulib code is rarely or never ported to them there’s no
26269         need to exclude them merely because of year 2038 issues.
26270         (gl_YEAR2038_BODY): Adjust messages to match.  Use 2**32 - 1,
26271         not 2**32, as the test timestamp, to allow unsigned 32-bit time_t.
26273 2021-08-01  Paul Eggert  <eggert@cs.ucla.edu>
26275         xalloc: no attribute (malloc (free)) on inline
26276         The GCC manual says you can’t use __attribute__ ((__malloc__
26277         (free, 1))) on inline functions.  Problem discovered when
26278         compiling diffutils 3.8 on RHEL 8.4 using a GCC 11.2.0 that I
26279         built myself.  Perhaps the problem was not discovered earlier
26280         because the attribute works with ‘free’ (which is what I was
26281         seeing before on Fedora 34) but not with ‘rpl_free’ (seen on RHEL
26282         8.4).  Anyway, the GCC manual says it shouldn’t work at all, so
26283         don’t use it.
26284         * lib/xalloc.h (xnmalloc, xcharalloc): No longer inline.
26285         * lib/xmalloc.c (xcharalloc, xnmalloc): Move function bodies here.
26286         * m4/gnulib-common.m4 (_GL_ATTRIBUTE_DEALLOC)
26287         (_GL_ATTRIBUTE_DEALLOC_FREE): Document that these cannot be
26288         used on inline functions, as per the GCC 11.2.1 manual.
26290         sigsegv-tests: make more things static
26291         * tests/test-sigsegv-catch-segv1.c:
26292         * tests/test-sigsegv-catch-stackoverflow1.c:
26293         * tests/test-sigsegv-catch-stackoverflow2.c:
26294         Declare some functions and variables static, to pacify GCC when
26295         warning about external functions missing declarations.
26297         maint: improve -fanalyzer malloc checking
26298         * lib/backup-internal.h, lib/backupfile.h:
26299         * lib/canonicalize.h, lib/dfa.h, lib/dirname.h, lib/exclude.h:
26300         * lib/filenamecat.h, lib/malloca.h, lib/modechange.h:
26301         * lib/mountlist.h, lib/pagealign_alloc.h, lib/quotearg.h:
26302         * lib/readutmp.h, lib/savedir.h, lib/sh-quote.h, lib/system-quote.h:
26303         * lib/trim.h, lib/xgetcwd.h, lib/xgethostname.h, lib/xmalloca.h:
26304         * lib/xreadlink.h, lib/xstriconv.h, lib/xvasprintf.h:
26305         Add malloc-related attributes and include stdlib.h as needed.
26306         * lib/dfa.c: Include verify.h.
26307         (assume_nonnull): New macro.
26308         (dfamust): Use it to pacify GCC.
26309         * lib/malloca.c (mmalloca): Redo to pacify GCC, to cut down on the
26310         number of casts, and to avoid signed integer overflow on
26311         theoretical platforms.
26312         * lib/vasnprintf.c, tests/test-argmatch.c:
26313         Disable -Wanalyzer-null-argument here.
26314         * m4/manywarnings.m4: Update GCC bug report number in comment.
26316 2021-08-01  Jim Meyering  <meyering@fb.com>
26318         regex: pacify GCC 11.2.1's -fanalyzer
26319         * lib/regex_internal.c (re_node_set_merge):
26320         Add a debug assertion to pacify GCC 11.2.1's -fanalyzer.
26322 2021-08-01  Bruno Haible  <bruno@clisp.org>
26324         limits-h tests: Add tests for BOOL_MAX and BOOL_WIDTH.
26325         * tests/test-limits-h.c (bool_attrs): New variable.
26326         Check value of BOOL_MAX.
26328 2021-07-31  Paul Eggert  <eggert@cs.ucla.edu>
26330         regex: pacify GCC 11.2 -fanalyzer
26331         * lib/regex_internal.c (re_node_set_insert):
26332         Add a debug assertion to pacify GCC 11.2 -fanalyzer.
26334         maint: pacify GCC 11.2 -fanalyzer in crypto tests
26335         * tests/bench-digest.h (main): Report an error after memory
26336         exhaustion, instead of using a null pointer.
26338 2021-07-30  Paul Eggert  <eggert@cs.ucla.edu>
26340         xalloc: add malloc-related function attributes
26341         * lib/quotearg.h, lib/xalloc.h: Include stdlib.h, for
26342         the benefit of _GL_ATTRIBUTE_RETURNS_NONNULL.
26343         * lib/quotearg.h (clone_quoting_options):
26344         * lib/xalloc.h (xmalloc, ximalloc, xzalloc, xizalloc, xcalloc)
26345         (xicalloc, xrealloc, xirealloc, xireallocarray, x2realloc)
26346         (x2nrealloc, xmemdup, ximemdup, xstrdup, xnmalloc, xcharalloc):
26347         Add _GL_ATTRIBUTE_DALLOC_FREE and _GL_ATTRIBUTE_RETURNS_NONNULL
26348         attributes as appropriate.
26350         gnulib-common: update for gcc -Wmismatched-dealloc
26351         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define the macros
26352         _GL_ATTRIBUTE_DEALLOC and _GL_ATTRIBUTE_DEALLOC_FREE.  These can
26353         be useful with gcc -Wmismatched-dealloc.
26355         gnulib-common: update for C2x 2020-12-11 draft
26356         Use blessed-by-draft-standard way to test for [[__deprecated__]]
26357         etc.; this is supported by GCC 11 and the fallback code should
26358         work fine with GCC 10 and earlier.
26359         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define the macro
26360         _GL_HAS_C_ATTRIBUTE, and use it instead of __STDC_VERSION__ in
26361         deciding whether to use C2x attributes like [[__deprecated__]].
26363         manywarnings: document GCC 11 warnings
26364         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 11.
26365         None of them require Gnulib code changes, so this is just
26366         a documentation change.
26368         limits-h: add BOOL_MAX, BOOL_WIDTH
26369         * doc/posix-headers/limits.texi (limits.h): Document them.
26370         * lib/limits.in.h: Also define CHAR_WIDTH etc. if C2x.
26371         (BOOL_MAX, BOOL_WIDTH): New macros, from C2x.
26372         * m4/limits-h.m4 (gl_LIMITS_H): Also check BOOL_WIDTH.
26374 2021-07-28  Simon Josefsson  <simon@josefsson.org>
26376         maintainer-makefile: Respect cfg.mk setting announcement_Cc_,
26377         reverting most of the previous patch.
26378         * top/maint.mk (announcement_mail_Cc_stable): Rename back to
26379         announcement_Cc_stable.
26380         (announcement_Cc_alpha): Rename back to
26381         announcement_mail_Cc_alpha.
26382         (announcement_Cc_): Renamed from announcement_mail_Cc_.
26383         (announcement_mail_headers_stable)
26384         (announcement_mail_headers_alpha): Use announcement_Cc_ again.
26386 2021-07-28  Simon Josefsson  <simon@josefsson.org>
26388         maintainer-makefile: Fix announcement mail CC's.
26389         * top/maint.mk (announcement_Cc_stable): Rename to
26390         announcement_mail_Cc_stable.
26391         (announcement_Cc_alpha): Rename to announcement_mail_Cc_alpha.
26392         (announcement_mail_headers_stable)
26393         (announcement_mail_headers_alpha): Use announcement_mail_Cc_
26394         instead of announcement_Cc_.
26396 2021-07-25  Bruno Haible  <bruno@clisp.org>
26398         Assume GNU gettext >= 0.17.
26399         * modules/vasprintf (Notice): Remove.
26400         * modules/xvasprintf (Notice): Remove.
26401         * modules/xprintf (Notice): Remove.
26402         * modules/error (Notice): Remove.
26403         * modules/verror (Notice): Remove.
26404         * modules/argp (Notice): Remove.
26405         * modules/propername (Notice): Remove.
26406         * lib/propername.h: Remove outdated comment.
26408 2021-07-19  Simon Josefsson  <simon@josefsson.org>
26410         gendocs.sh: Fix local rendering of HTML manuals.
26411         * build-aux/gendocs.sh (htmlarg): Don't use relative URLs.
26413 2021-07-18  Paul Eggert  <eggert@cs.ucla.edu>
26415         explicit_bzero-tests: pacify GCC better
26416         Problem reported by Bruno Haible in:
26417         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00039.html
26418         * tests/test-explicit_bzero.c: Ignore -Wmaybe-uninitialized.
26419         (stackbuf): Remove this static pointer, reverting recent change.
26420         (do_secret_stuff, test_stack): Revert these related changes too.
26422 2021-07-17  Paul Eggert  <eggert@cs.ucla.edu>
26424         memrchr-tests: pacify GCC
26425         Pacify GCC 11.1.1 20210531 (Red Hat 11.1.1-3) x86-64.
26426         * tests/test-memrchr.c: Disable -Wmaybe-uninitialized.
26428         explicit_bzero-tests: pacify GCC
26429         Redo to pacify -Wmaybe-uninitialized with
26430         GCC 11.1.1 20210531 (Red Hat 11.1.1-3) x86-64.
26431         * tests/test-explicit_bzero.c (stackbuf): New static pointer.
26432         (do_secret_stuff): Use it.
26433         (test_stack): Set it to a local buffer.
26435         posixtm: pacify latest GCC
26436         Also, modernize while I’m at it.
26437         * lib/posixtm.c: Include c-ctype.h, idx.h, intprops.h, verify.h
26438         instead of stdlib.h.
26439         (ISDIGIT): Remove.  All uses replaced by c_isdigit.
26440         (year, posix_time_parse): Prefer idx_t to size_t.  Use assume
26441         instead of abort.
26442         (posixtime): Do not parse twice; once is enough.  That way, we
26443         needn’t worry about a bogus warning about strcpy overrunning a
26444         buffer from GCC 11.1.1 20210531 (Red Hat 11.1.1-3) x86-64
26445         when coreutils is configured with --enable-gcc-warnings.
26446         * modules/posixtm (Depends-on): Add c-ctype, intprops, verify.
26447         Remove stpcpy.
26449 2021-07-17  Bruno Haible  <bruno@clisp.org>
26451         Don't use '#pragma weak' for thread functions in Linux/glibc>=2.34.
26452         Suggested by Florian Weimer <fweimer@redhat.com> in
26453         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00211.html>.
26454         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): Set gl_pthread_in_glibc and set
26455         LIBPMULTITHREAD accordingly.
26456         (gl_STDTHREADLIB_BODY): Update comments.
26457         (gl_THREADLIB_BODY): Define USE_POSIX_THREADS_FROM_LIBC.
26458         * lib/glthread/thread.h (c11_threads_in_use): Define to 1 if all POSIX
26459         thread functions are in libc.
26460         * lib/glthread/lock.h (c11_threads_in_use): Likewise.
26461         * lib/glthread/cond.h (c11_threads_in_use): Likewise.
26462         * lib/glthread/tls.h (c11_threads_in_use): Likewise.
26464 2021-07-17  Bruno Haible  <bruno@clisp.org>
26466         Fix cross-compilation test results.
26467         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): When cross-compiling, include
26468         <string.h> before testing __GNU_LIBRARY__.
26469         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Likewise.
26470         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Likewise.
26472 2021-07-14  Paul Eggert  <eggert@cs.ucla.edu>
26474         regex: modernize to newer regex bugset
26475         Problem reported by Hiroo Hayashi in:
26476         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00024.html
26477         * m4/regex.m4 (gl_REGEX): Allow newer glibc behavior for ()0|\1,
26478         behavior where the regex compiles but does not match.
26479         Test for glibc bug 11053.
26480         * tests/test-regex.c (bug_regex11, main): Add casts needed
26481         for printf portability.
26482         (main): Allow newer glibc behavior for ()0|\1.
26484         regex: fix shell quoting problem in configuration
26485         * m4/regex.m4 (gl_REGEX): Fix quoting problems.
26486         These C programs are put into unquoted here-documents,
26487         so $ and \ need to be quoted.
26489 2021-07-08  Paul Eggert  <eggert@cs.ucla.edu>
26491         select: port better to MinGW
26492         Problem reported by Eli Zaretskii in:
26493         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00017.html
26494         * lib/select.c (rpl_select) [_WIN32 && !__CYGWIN__]:
26495         Pass a SOCKET, not a HANDLE, to FD_ISSET.
26497 2021-07-06  Paul Eggert  <eggert@cs.ucla.edu>
26499         year2038: Add --disable-year2038 option
26500         Also, document this stuff better.  Suggested by Bruno Haible in:
26501         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00011.html
26502         * doc/year2038.texi: Document --disable-year2038.
26503         * m4/year2038.m4 (gl_YEAR2038_BODY): Support ‘./configure
26504         --disable-year2038’ to disable 64-bit time_t when that is not the
26505         default.  Arg is now either empty or nonempty (not a shell
26506         command) and is evaluated at m4 expansion time instead of at
26507         runtime; all callers changed.
26509         doc: clarify which module fixes 32-bit time_t
26510         * doc/posix-headers/time.texi: Make it clear that the 32-bit
26511         time_t problem is addressed by the year2038 module, not
26512         by the time module.
26514 2021-07-01  Paul Eggert  <eggert@cs.ucla.edu>
26516         year2038: support glibc 2.34 _TIME_BITS=64
26517         In glibc 2.34 on Linux kernels where time_t is traditionally 32-bit,
26518         defining _FILE_OFFSET_BITS=64 and _TIME_BITS=64 makes time_t 64-bit.
26519         Apps must define both macros.  Gnulib applications that use either
26520         the largefile or the year2038 modules will want this behavior;
26521         largefile because it deals with the off_t and ino_t components of
26522         struct stat already, and so should also deal with time_t.
26523         * NEWS, doc/largefile.texi, doc/posix-headers/time.texi:
26524         Mention this.
26525         * m4/largefile.m4: Override two macros even in Autoconf 2.70 and later.
26526         (_AC_SYS_LARGEFILE_MACRO_VALUE): #undef $1 before #defining it, in
26527         case some other Gnulib macro has #defined it.
26528         (AC_SYS_LARGEFILE): Use AS_IF and AS_CASE to propagate AC_REQUIREs.
26529         Invoke gl_YEAR2038_BODY if we need to set _FILE_OFFSET_BITS=64.
26530         * m4/year2038.m4 (gl_YEAR2038_TEST_INCLUDES): New macro.
26531         (gl_YEAR2038_BODY): New macro, with gl_YEAR2038’s old body; this
26532         macro is designed to be used directly instead of being
26533         AC_REQUIREd.  It takes an argument specifying whether 64-bit is
26534         required.  Set _TIME_BITS=64 if this makes a difference in time_t
26535         width when setting _FILE_OFFSET_BITS=64.  Do not warn about
26536         32-bit time_t more than once.
26537         * modules/largefile (Files): Add year2038.m4.
26538         (Depends-on): Require gl_YEAR2038_EARLY.
26540         relocatable-prog-wrapper: add m4 files
26541         Add .m4 files needed for standalone relocatable-prog-wrapper, so
26542         that ‘./gnulib-tool --test relocatable-prog-wrapper’ does not fail
26543         with diagnostics like ‘configure.ac:63: error: possibly undefined
26544         macro: gl_FUNC_MALLOC_POSIX’.
26545         * modules/relocatable-prog-wrapper (Files): Add m4/free.m4,
26546         m4/malloc.m4, m4/mempcpy.m4, m4/rawmemchr.m4, m4/realloc.m4.
26548 2021-06-28  Bruno Haible  <bruno@clisp.org>
26550         strerror-override: Fix possible compilation error.
26551         Reported by Thomas Klausner <wiz@netbsd.org>.
26552         * lib/strerror-override.h (GNULIB_defined_strerror_override_macro): New
26553         macro.
26554         * lib/strerror-override.c (strerror_override): Don't define if
26555         GNULIB_defined_strerror_override_macro is set.
26557 2021-06-27  Bruno Haible  <bruno@clisp.org>
26559         environ: Fix wrong autoconf test result in C++ mode.
26560         * m4/environ.m4 (gt_CHECK_VAR_DECL): Use a typedef'ed type, not an
26561         anonymous type.
26563 2021-06-22  Egor Ignatov  <egori@altlinux.org>  (tiny change)
26565         regex: fix undefined behavior
26566         Problem reported by Paul Eggert in:
26567         https://lists.gnu.org/r/bug-gnulib/2021-06/msg00115.html
26568         * lib/regexec.c (proceed_next_node):
26569         Don’t insert already-inserted node.
26571 2021-06-21  Eric Blake  <eblake@redhat.com>
26573         sigsegv, sigsegv-tests: Assign my contributions to the FSF.
26574         * m4/sigaltstack.m4: Change copyright notice: Write "Copyright (C) FSF"
26575         instead of "Copyright (C) Eric Blake".
26576         * tests/altstack-util.h: Likewise.
26577         * tests/test-sigsegv-catch-stackoverflow1.c: Likewise.
26578         * tests/test-sigsegv-catch-stackoverflow2.c: Likewise.
26580 2021-06-20  Bruno Haible  <bruno@clisp.org>
26582         unistd: Avoid compilation error in C++ mode on Solaris, HP-UX, mingw.
26583         Reported by Eli Zaretskii <eliz@gnu.org> in
26584         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00135.html>.
26585         * lib/unistd.in.h (swab): Consider different declarations on Solaris,
26586         HP-UX, and old mingw.
26588 2021-06-20  Bruno Haible  <bruno@clisp.org>
26590         Sync with GNU gettext.
26591         * lib/printf-parse.c: Ignore IN_LIBINTL and IN_LIBASPRINTF.
26592         * lib/vasnprintf.c: Ignore IN_LIBINTL.
26594 2021-06-19  Bruno Haible  <bruno@clisp.org>
26596         Sync with GNU gettext.
26597         * lib/tsearch.c: Ignore IN_LIBINTL.
26598         * lib/localename-table.h: Likewise.
26599         * lib/localename.c: Ignore IN_LIBINTL in some places.
26601 2021-06-19  Bruno Haible  <bruno@clisp.org>
26603         unistd: Improve conflict resolution between gnulib and textstyle.h.
26604         * lib/unistd.in.h (GNULIB_overrides_isatty): New macro.
26606 2021-06-19  Bruno Haible  <bruno@clisp.org>
26608         stdio: Improve conflict resolution between gnulib and libintl.h.
26609         * lib/stdio.in.h (GNULIB_overrides_snprintf, GNULIB_overrides_sprintf,
26610         GNULIB_overrides_asprintf, GNULIB_overrides_vasprintf,
26611         GNULIB_overrides_vsnprintf, GNULIB_overrides_vsprintf): New macros.
26613 2021-06-19  Bruno Haible  <bruno@clisp.org>
26615         declared.sh: Allow parsing 'extern "C"' lines.
26616         * build-aux/declared.sh: Don't concatenate lines to an 'extern "C" {'
26617         line.
26619 2021-06-19  Bruno Haible  <bruno@clisp.org>
26621         unitypes: Fix trouble caused by installed older versions of unitypes.h.
26622         * modules/unitypes (configure.ac): Define _UC_RESTRICT through config.h.
26624 2021-06-19  Bruno Haible  <bruno@clisp.org>
26626         sigsegv, sigsegv-tests: Assign my contributions to the FSF.
26627         * lib/sigsegv.in.h: Change copyright notice: Write "Copyright (C) FSF"
26628         instead of "Copyright (C) Bruno Haible".
26629         * lib/sigsegv.c: Likewise.
26630         * lib/stackvma.h: Likewise.
26631         * lib/stackvma.c: Likewise.
26632         * m4/sigaltstack.m4: Likewise.
26633         * m4/stack-direction.m4: Likewise.
26634         * tests/altstack-util.h: Likewise.
26635         * tests/mmap-anon-util.h: Likewise.
26636         * tests/test-sigsegv-catch-segv1.c: Likewise.
26637         * tests/test-sigsegv-catch-segv2.c: Likewise.
26638         * tests/test-sigsegv-catch-stackoverflow1.c: Likewise.
26639         * tests/test-sigsegv-catch-stackoverflow2.c: Likewise.
26641 2021-06-18  Darren Kenny  <darren.kenny@oracle.com>  (tiny change)
26643         argp: Avoid possible NULL access in argp_help.
26644         Reported by Coverity. The invocation chain is:
26645         argp_help -> _help -> fill_in_uparams -> validate_uparams.
26646         * lib/argp-help.c (validate_uparams): Don't crash if state == NULL.
26648 2021-06-16  Bruno Haible  <bruno@clisp.org>
26650         tsearch: Relicense under LGPLv2+.
26651         * modules/tsearch (License): Change to LGPLv2+.
26652         * lib/tsearch.c: Update license notice.
26654 2021-06-15  Bruno Haible  <bruno@clisp.org>
26656         pipe-filter-ii tests: Fix long-standing failure on native Windows.
26657         * tests/test-pipe-filter-ii2-main.c: Include binary-io.h.
26658         (main): Avoid NL to CRLF conversion on standard output.
26659         * tests/test-pipe-filter-ii2-child.c: Include <unistd.h>, binary-io.h.
26660         (main): Avoid NL to CRLF conversion on standard output.
26662 2021-06-15  Bruno Haible  <bruno@clisp.org>
26664         xnanosleep: Improve module description.
26665         * modules/xnanosleep (Description): Improve.
26666         * lib/xnanosleep.h: Add comment. Make includable from C++.
26667         * lib/xnanosleep.c: Update comment.
26669 2021-06-15  Bruno Haible  <bruno@clisp.org>
26671         xfreopen: Improve module description.
26672         * modules/xfreopen (Description): Improve.
26673         * lib/xfreopen.h: Add comments. Make includable from C++.
26674         * lib/xfreopen.c: Update comment.
26676 2021-06-14  Paul Eggert  <eggert@cs.ucla.edu>
26678         idx: new printf/scanf length modifier macro
26679         * lib/idx.h (pIDX): New macro.
26681 2021-06-13  Bruno Haible  <bruno@clisp.org>
26683         Align 2011-11-26 patch to 2021-04-11 patch (regression from 2021-04-11).
26684         Reported by Paul Eggert.
26685         * m4/unistd_h.m4 (gl_UNISTD_H_REQUIRE_DEFAULTS): Also initialize
26686         GNULIB_UNISTD_H_GETOPT variable.
26687         * modules/getopt-posix (configure.ac): Set GNULIB_UNISTD_H_GETOPT
26688         variable.
26689         * modules/unistd (Makefile.am): Rely on ${gl_include_guard_prefix}
26690         processing done by gnulib-tool since 2021-04-11.
26691         * gnulib-tool: Revert last change.
26692         * pygnulib/GLEmiter.py: Likewise.
26694 2021-06-13  Paul Eggert  <eggert@cs.ucla.edu>
26696         * lib/stack.h (_GL_STACK_PREFIX): Omit stray semicolon.
26698         getopt-gnu: port back to Solaris 10
26699         * gnulib-tool (func_emit_lib_Makefile_am)
26700         (func_emit_tests_Makefile_am): Don’t substitute things like
26701         $(GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT),
26702         as this mishandles unistd and getopt-gnu, which breaks
26703         ‘make check’ on Solaris 10 with getopt-gnu.
26704         * pygnulib/GLEmiter.py (lib_Makefile_am, tests_Makefile_am):
26705         Likewise, albeit hackier since I did not test this and
26706         so went with a trivial hack instead.
26708 2021-06-13  Bruno Haible  <bruno@clisp.org>
26710         ialloc: Put appropriate license notice in source files.
26711         * lib/ialloc.h: Use LGPLv3+ notice.
26712         * lib/ialloc.c: Likewise.
26714 2021-06-11  Paul Eggert  <eggert@cs.ucla.edu>
26716         xalloc: new idx_t-based allocators
26717         This is for code that prefers to use idx_t for sizes.
26718         * lib/basename.c (base_name):
26719         * lib/dfa.c (mbs_to_wchar, state_index, dfaoptimize, dfaanalyze)
26720         (icatalloc, enlist, allocmust, dfamust):
26721         * lib/exclude.c (struct exclude_pattern, free_exclude_segment)
26722         (file_pattern_matches, add_exclude, add_exclude_fp):
26723         * lib/getusershell.c (line_size, readname):
26724         * lib/linebuffer.c (readlinebuffer_delim):
26725         * lib/linebuffer.h (struct linebuffer):
26726         * lib/readtokens.c (readtoken, readtokens):
26727         * lib/readutmp.c (read_utmp):
26728         * lib/savedir.c (streamsavedir):
26729         * lib/stack.h (_GL_STACK_TYPE, _GL_STACK_PREFIX):
26730         * lib/userspec.c (parse_with_separator):
26731         * lib/xgethostname.c (XGETANAME):
26732         Prefer idx_t to size_t for indexes, and use idx_t-related allocators.
26733         * lib/basename.c: Do not include xstrndup.h.
26734         (basename): Simplify by always using memcpy.
26735         * lib/xalloc.h (ximalloc, xizalloc, xicalloc, xirealloc)
26736         (xireallocarray, ximemdup, ximemdup0) [GNULIB_XALLOC]:
26737         New decls.
26738         (x2nrealloc): Now just a decl, as the body is moved into xmalloc.c.
26739         * lib/xmalloc.c: Include ialloc.h.
26740         Rename some local parameters to be consistent with the .h files.
26741         (nonnull): New static function.
26742         (xmalloc, xcalloc): Simplify by using nonnull.
26743         (ximalloc, xirealloc, xireallocarray, xizalloc, xicalloc)
26744         (ximemdup, ximemdup0): New functions.
26745         (x2nrealloc): Moved here from xalloc.h.
26746         * modules/xalloc (Depends-on): Add ialloc.
26747         * modules/dirname (Depends-on): Removbe xstrndup.
26748         * modules/linebuffer (Depends-on): Add idx.
26750         ialloc: new module
26751         * lib/ialloc.c, lib/ialloc.h, modules/ialloc: New files.
26753         exclude: improve wide-character hashing
26754         * lib/exclude.c (string_hasher_ci): Take the modulo at the end
26755         rather than each time a wide character is retrieved; this should
26756         be more efficient and should hash better.
26758 2021-06-11  Bruno Haible  <bruno@clisp.org>
26760         Make message in last commit more precise.
26761         Suggested by Eric Blake.
26762         * gnulib-tool (func_emit_tests_Makefile_am): Add more precision to
26763         'check-notice' message.
26765 2021-06-10  Bruno Haible  <bruno@clisp.org>
26767         Clarify where to report test failures from Gnulib tests.
26768         * gnulib-tool (func_emit_tests_Makefile_am): Emit a dependency of
26769         'check-am' on 'check-notice' that prints a notice.
26771 2021-06-10  Bruno Haible  <bruno@clisp.org>
26773         Clarify that compiler warnings in the Gnulib tests can be ignored.
26774         * gnulib-tool (func_emit_tests_Makefile_am): Emit overrides for CFLAGS
26775         and CXXFLAGS. Emit a dependency of 'all' on 'all-notice' that prints a
26776         notice.
26777         (func_emit_initmacro_start): Add a second argument. If it is true, emit
26778         code to require gl_CC_ALLOW_WARNINGS and gl_CXX_ALLOW_WARNINGS.
26779         (func_import, func_create_testdir): All callers updated.
26780         * m4/gnulib-common.m4 (gl_CC_ALLOW_WARNINGS, gl_CXX_ALLOW_WARNINGS): New
26781         macros.
26783 2021-06-09  Bruno Haible  <bruno@clisp.org>
26785         sigsegv tests: Hide a null pointer from the compiler's optimizations.
26786         Patch by Paul Eggert.
26787         * tests/test-sigsegv-catch-stackoverflow2.c
26788         (null_pointer_to_volatile_int): New variable.
26789         (main): Use it.
26791 2021-06-07  Bruno Haible  <bruno@clisp.org>
26793         get_ppid_of: Add support for DragonFly BSD.
26794         * lib/get_ppid_of.c: Treat DragonFly BSD like FreeBSD.
26796 2021-06-07  Bruno Haible  <bruno@clisp.org>
26798         sigsegv: Document context type for DragonFly BSD.
26799         * lib/sigsegv.in.h (stackoverflow_context_t): On DragonFly BSD, it is a
26800         pointer to 'struct sigcontext'.
26802 2021-06-07  Bruno Haible  <bruno@clisp.org>
26804         dynarray, scratch_buffer: Fix VPATH builds (regression from yesterday).
26805         * modules/dynarray (configure.ac): Invoke AC_PROG_MKDIR_P.
26806         (Makefile.am): Create malloc/ directory before creating
26807         malloc/dynarray.gl.h and malloc/dynarray-skeleton.gl.h.
26808         * modules/scratch_buffer (configure.ac): Invoke AC_PROG_MKDIR_P.
26809         (Makefile.am): Create malloc/ directory before creating
26810         malloc/scratch_buffer.gl.h.
26812 2021-06-07  Bruno Haible  <bruno@clisp.org>
26814         ptsname_r: Add support for DragonFly BSD 6.0.
26815         * lib/ptsname_r.c (__ptsname_r): Add implementation for DragonFly BSD.
26816         * tests/test-ptsname_r.c (main): Treat Dragonfly BSD like Solaris.
26818 2021-06-07  Bruno Haible  <bruno@clisp.org>
26820         Avoid some test failures on DragonFly BSD 6.0.
26821         * tests/test-c32isalnum.c (main): On Dragonfly BSD, disable tests that
26822         fail.
26823         * tests/test-c32isalpha.c (main): Likewise.
26824         * tests/test-c32islower.c (main): Likewise.
26825         * tests/test-c32isupper.c (main): Likewise.
26826         * tests/test-ptsname.c (main): Treat Dragonfly BSD like Solaris.
26828 2021-06-07  Kamil Dudka  <kdudka@redhat.com>
26830         mountlist: recognize fuse.portal as dummy file system
26831         * lib/mountlist.c [ME_DUMMY_0]: Add "fuse.portal" as
26832         a dummy file system (used in flatpak implementations).
26834 2021-06-07  Bruno Haible  <bruno@clisp.org>
26836         host-os: Add support for DragonFly BSD.
26837         * m4/host-os.m4 (gl_HOST_OS): On DragonFly BSD, set
26838         HOST_OPERATING_SYSTEM to "DragonFly BSD", not "Dragonfly".
26840 2021-06-07  Bruno Haible  <bruno@clisp.org>
26842         thread: Fix test link error on DragonFly BSD 6.0.
26843         * lib/glthread/thread.c (gl_thread_create): Moved to here...
26844         * lib/glthread/thread.h (gl_thread_create): ...from here.
26845         (_GLTHREAD_THREAD_INLINE): Remove macro.
26846         Remove _GL_INLINE_HEADER_BEGIN/END invocations.
26848 2021-06-06  Bruno Haible  <bruno@clisp.org>
26850         sigsegv: Avoid a gcc warning "declaration of 'sig' shadows a parameter".
26851         Reported by Dmitry V. Levin <ldv@altlinux.org> in
26852         <https://lists.gnu.org/archive/html/bug-gnulib/2021-06/msg00018.html>.
26853         * lib/sigsegv.c (sigsegv_handler): Use a different local variable name
26854         than 'sig'.
26856 2021-06-06  Bruno Haible  <bruno@clisp.org>
26858         scratch_buffer: Avoid conflict with prepr. macros owned by the system.
26859         * lib/scratch_buffer.h: Don't include <libc-config.h>. Define
26860         _GL_LIKELY, _GL_UNLIKELY. Include malloc/scratch_buffer.gl.h instead of
26861         malloc/scratch_buffer.h.
26862         * modules/scratch_buffer (Depends-on): Add builtin-expect.
26863         (Makefile.am): Arrange to create malloc/scratch_buffer.gl.h from
26864         malloc/scratch_buffer.h.
26866 2021-06-06  Bruno Haible  <bruno@clisp.org>
26868         dynarray: Avoid conflict with preprocessor macros owned by the system.
26869         * lib/dynarray.h: Don't include <libc-config.h>. Define _GL_LIKELY,
26870         _GL_UNLIKELY. Include malloc/dynarray.gl.h instead of malloc/dynarray.h.
26871         Include malloc/dynarray-skeleton.gl.h instead of
26872         malloc/dynarray-skeleton.c.
26873         * modules/dynarray (Depends-on): Add builtin-expect.
26874         (Makefile.am): Arrange to create malloc/dynarray.gl.h from
26875         malloc/dynarray.h and malloc/dynarray-skeleton.gl.h from
26876         malloc/dynarray-skeleton.c.
26878 2021-06-06  Bruno Haible  <bruno@clisp.org>
26880         glob-h: Avoid conflict with preprocessor macros owned by the system.
26881         This fixes a compilation error on DragonFly BSD 6.0.
26882         * lib/glob.in.h: Don't include <libc-config.h>. Don't define __USE_GNU.
26883         Include glob-libc.gl.h instead of glob-libc.h.
26884         * modules/glob-h (Makefile.am): Arrange to create glob-libc.gl.h from
26885         glob-libc.h.
26886         * lib/libc-config.h: Add comment.
26888 2021-06-06  Dmitry V. Levin  <ldv@altlinux.org>
26890         * tests/test-regex.c (tests): Add test cases for *+ and ** regressions
26891         fixed by the previous commit.
26893         * tests/test-regex.c (tests): Remove the comment saying that some tests
26894         are not used.  That comment was copied along with tests from glibc
26895         where some of these tests are commented out.
26897 2021-06-06  Egor Ignatov  <egori@altlinux.org>  (tiny change)
26899         * lib/regexec.c (set_regs): Pop if CUR_NODE has already been checked
26900         only when we have a fail stack.
26902 2021-06-05  Bruno Haible  <bruno@clisp.org>
26904         lib-symbol-visibility: Make configure check work for newer GCC.
26905         Reported by Ozkan Sezer <sezeroz@gmail.com> in
26906         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00117.html>.
26907         * m4/visibility.m4 (gl_VISIBILITY): Add a function definition for each
26908         declaration in the test program.
26910 2021-06-05  Bruno Haible  <bruno@clisp.org>
26912         vasnprintf: Don't leak memory when memory allocation fails.
26913         Found by Coverity. Reported by Mike Fabian <mfabian@redhat.com> in
26914         <https://lists.gnu.org/archive/html/bug-libunistring/2021-06/msg00000.html>.
26915         * lib/vasnprintf.c (VASNPRINTF): In places where a local variable points
26916         to heap-allocated storage, free that storage before doing
26917         'goto out_of_memory;'.
26919 2021-06-04  Bruno Haible  <bruno@clisp.org>
26921         gnulib-tool: Stop doing license notice replacements.
26922         * gnulib-tool: Don't document --more-symlinks and --more-hardlinks any
26923         more.
26924         (do_copyrights): Remove variable.
26925         (func_import): Don't perform license updates on imported files any more.
26926         * pygnulib/GLInfo.py: Don't document --more-symlinks any more.
26927         * doc/gnulib-intro.texi (Copyright): Document the new situation.
26928         * doc/gnulib.texi (Module description): Likewise.
26929         * NEWS: Mention the change.
26931 2021-06-04  Bruno Haible  <bruno@clisp.org>
26933         git-merge-changelog: Fix license.
26934         * modules/git-merge-changelog (License): Change back to GPL.
26935         * lib/git-merge-changelog.c: Use a GPLv3+ notice.
26937 2021-06-04  Bruno Haible  <bruno@clisp.org>
26939         Put GPLv3+ notices in source files where appropriate.
26940         * lib/*.{h,c}: Use GPLv3+ notice whenever the module description says
26941         so.
26942         * build-aux/pmccabe.css: Likewise.
26944 2021-06-04  Bruno Haible  <bruno@clisp.org>
26946         Put LGPLv3+ notices in source files where appropriate.
26947         * lib/*.{h,c}: Use LGPLv3+ notice whenever the module description says
26948         so.
26950 2021-06-04  Bruno Haible  <bruno@clisp.org>
26952         Put "LGPLv3+ or GPLv2+" notices in source files where appropriate.
26953         * lib/**.{h,c,gperf}: Use "LGPLv3+ or GPLv2+" notice whenever the module
26954         description says so.
26956 2021-06-04  Bruno Haible  <bruno@clisp.org>
26958         Generate correct license notices in libunistring files.
26959         * lib/gen-uni-tables.c (output_library_license, output_tests_license):
26960         New functions.
26961         (output_predicate, output_category, output_combclass,
26962         output_bidi_category, output_decimal_digit, output_digit,
26963         output_numeric, output_mirror, output_joining_type,
26964         output_joining_group, output_scripts, output_scripts_byname,
26965         output_blocks, output_ident_category, output_lbrk_tables,
26966         output_wbrk_tables, output_gbp_table, output_decomposition_tables,
26967         output_composition_tables, output_simple_mapping, output_casing_rules):
26968         Invoke output_library_license.
26969         (output_predicate_test, output_decimal_digit_test, output_digit_test,
26970         output_numeric_test, output_joining_type_test,
26971         output_joining_group_test, output_gbp_test, output_simple_mapping_test):
26972         Invoke output_tests_license.
26973         * lib/uni*/*.h, lib/uni*/*.gperf: Regenerated.
26974         * tests/uni*/*.h: Likewise.
26976 2021-06-04  Bruno Haible  <bruno@clisp.org>
26978         Generate correct license notices in libunistring files.
26979         * lib/uniname/gen-uninames.lisp (main): Emit a copyright and license
26980         notice.
26981         * lib/uniname/uninames.h: Regenerated.
26983 2021-06-04  Bruno Haible  <bruno@clisp.org>
26985         Put LGPLv2+ notices in source files where appropriate.
26986         * lib/**.{h,c,gperf}: Use LGPLv2+ notice whenever the module description
26987         says so.
26989 2021-06-04  Bruno Haible  <bruno@clisp.org>
26991         Put "unlimited" notices in source files where appropriate.
26992         * build-aux/prefix-gnulib-mk: Use "unlimited" notice, since the module
26993         description says so.
26995 2021-06-04  Bruno Haible  <bruno@clisp.org>
26997         Put public domain notices in source files where appropriate.
26998         * lib/{alloca.c,atexit.c,memmove.c}: Use public domain notice.
27000 2021-06-04  Bruno Haible  <bruno@clisp.org>
27002         Revamp check-copyright script.
27003         * check-copyright: Search only the first 50 lines of each file.
27004         Recognize 'LGPLv3+ or GPLv2+', 'unlimited', and 'public domain' license
27005         notices. For files that are part of several modules, consider the
27006         weakest among the licenses. Allocate more room for the first output
27007         column.
27009 2021-06-04  Bruno Haible  <bruno@clisp.org>
27011         gnupload, git-merge-changelog: Fix module description.
27012         * gnulib-tool (func_import, func_create_testdir): Treat
27013         'GPLv2+ build tool' like 'GPLed build tool'.
27014         * pygnulib/GLImport.py (prepare): Likewise.
27015         * modules/gnupload (License): Change to 'GPLv2+ build tool'.
27016         * modules/git-merge-changelog (License): Change to GPLv2+.
27018 2021-06-04  Bruno Haible  <bruno@clisp.org>
27020         New directory with license notices.
27021         * etc/license-notices/*: New files.
27023 2021-05-30  Paul Eggert  <eggert@cs.ucla.edu>
27025         reallocarray-tests: port to weird platforms
27026         * tests/test-reallocarray.c (main): Don’t assume that
27027         PTRDIFF_MAX / 2 + 1 <= SIZE_MAX.  POSIX allows platforms
27028         where this isn’t true, though I don’t know of any examples.
27030         dfa, etc.: prefer xreallocarray to older name
27031         * lib/dfa.c (addtok_mb, realloc_trans_if_necessary, enlist):
27032         * lib/readtokens.c (readtokens):
27033         * tests/uninorm/test-u32-normalize-big.c:
27034         (read_normalization_test_file):
27035         Prefer xreallocarray to the equivalent xnrealloc.
27036         The newer name follows the glibc lead of ‘reallocarray’.
27038 2021-05-30  Bruno Haible  <bruno@clisp.org>
27040         Write 'LGPLv3+ or GPLv2+' instead of 'LGPLv3+ or GPLv2'.
27041         * modules/* (License): Change.
27042         * gnulib-tool (func_import, func_create_testdir): Likewise.
27044 2021-05-29  Paul Eggert  <eggert@cs.ucla.edu>
27046         sigsegv: Port to Solaris 11
27047         Problem reported by Kiyoshi KANAZAWA in:
27048         https://lists.gnu.org/r/bug-m4/2021-05/msg00020.html
27049         * lib/stackvma.c (_FILE_OFFSET_BITS): #undef on Solaris and Android.
27051 2021-05-24  Bruno Haible  <bruno@clisp.org>
27053         c-stack: Document another restriction.
27054         Triggered by a discussion with Paul Eggert.
27055         * lib/c-stack.h: Mention that ACTION should not use nested functions.
27057 2021-05-22  Bruno Haible  <bruno@clisp.org>
27059         stdio: Fix compilation error on DragonFly BSD.
27060         * lib/stdio.in.h (fcloseall): Treat DragonFly BSD like FreeBSD.
27062 2021-05-22  Larkin Nickle  <me@larbob.org>  (tiny change)
27064         getprogname: port to Tru64
27065         * lib/getprogname.c: Treat __osf__ like __sgi, except
27066         with /proc/123 instead of /proc/pinfo/123.
27068 2021-05-21  Paul Eggert  <eggert@cs.ucla.edu>
27070         sigsegv: don’t assume SIGSTKSZ is a constant
27071         * m4/sigaltstack.m4 (SV_SIGALTSTACK): Don’t attempt to override
27072         SIGSTKSZ.  Instead, use an array that is plenty large, while
27073         checking that it’s large enough.  Also, be consistent about
27074         putting that array in static storage rather than on the stack.
27075         * tests/altstack-util.h (SIGSTKSZ): Don’t define.
27076         (MYSTACK_SIZE): New macro, used instead of SIGSTKSZ.
27077         (mystack_storage, mystack): Now static.
27078         (prepare_alternate_stack) [SIGSTKSZ]:
27079         Check that MYSTACK_SIZE is large enough.
27081 2021-05-20  Paul Eggert  <eggert@cs.ucla.edu>
27083         fstatat: doc improvement
27084         * doc/posix-functions/fstatat.texi (fstatat):
27085         Mention AT_EMPTY_PATH when talking about empty strings.
27087 2021-05-18  Bruno Haible  <bruno@clisp.org>
27089         c-stack: Support catching stack overflow on most platforms without libsigsegv.
27090         * lib/c-stack.c: Remove all Solaris-specific code. Include <sigsegv.h>
27091         always.
27092         * m4/c-stack.m4: Remove all Solaris-specific code.
27093         (gl_C_STACK): Test $with_libsigsegv from module 'sigsegv'.
27094         * modules/c-stack (Files): Remove m4/libsigsegv.m4.
27095         (Depends-on): Add sigsegv. Remove havelib, intprops, inttypes, mempcpy,
27096         sigaction, stdbool.
27098 2021-05-16  Bruno Haible  <bruno@clisp.org>
27100         sigsegv, c-stack: Avoid compilation error with glibc >= 2.34.
27101         * lib/sigsegv.in.h (SIGSTKSZ): On glibc systems, redefine to a suitable
27102         constant.
27103         * m4/sigaltstack.m4 (SV_SIGALTSTACK): Likewise.
27104         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Likewise.
27106 2021-05-16  Bruno Haible  <bruno@clisp.org>
27108         sigsegv: Add tests.
27109         * tests/test-sigsegv-catch-segv1.c: New file, from GNU libsigsegv with
27110         modifications.
27111         * tests/test-sigsegv-catch-segv2.c: Likewise.
27112         * tests/test-sigsegv-catch-stackoverflow1.c: Likewise.
27113         * tests/test-sigsegv-catch-stackoverflow2.c: Likewise.
27114         * tests/altstack-util.h: Likewise.
27115         * tests/mmap-anon-util.h: Likewise.
27116         * modules/sigsegv-tests: New file.
27118         sigsegv: New module.
27119         * lib/sigsegv.in.h: New file, from GNU libsigsegv with modifications.
27120         * lib/sigsegv.c: Likewise.
27121         * lib/stackvma.h: Likewise.
27122         * lib/stackvma.c: Likewise.
27123         * m4/sigaltstack.m4: Likewise.
27124         * m4/stack-direction.m4: Likewise.
27125         * modules/sigsegv: New file.
27127 2021-05-15  Pádraig Brady  <P@draigBrady.com>
27129         realloc-gnu: avoid glibc MALLOC_CHECK_ issue
27130         * tests/test-realloc-gnu.c (main): if MALLOC_CHECK_ env var
27131         is set then don't check ENOMEM is returned from realloc().
27132         See https://sourceware.org/bugzilla/show_bug.cgi?id=27870
27133         Note it doesn't suffice to unsetenv() this var within the program,
27134         as the hooks have already been set up at that stage.
27136 2021-05-14  Paul Eggert  <eggert@cs.ucla.edu>
27138         c-stack: work around Solaris 11 bugs
27139         Problem reported by Bruno Haible in:
27140         https://lists.gnu.org/r/bug-gnulib/2021-05/msg00062.html
27141         * lib/c-stack.c: Always include sigsegv.h if HAVE_LIBSIGSEGV.
27142         (USE_LIBSIGSEGV): Do not use libsigsegv if the kernel
27143         has the si_addr bug and libsigsegv is too old to work
27144         around it.
27145         (segv_handler) [!USE_LIBSIGSEGV]: Do not trust si_addr
27146         if BOGUS_SI_ADDR_UPON_STACK_OVERFLOW.
27147         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
27148         Define BOGUS_SI_ADDR_UPON_STACK_OVERFLOW on Solaris 2.11 SPARC.
27149         And do not define HAVE_XSI_STACK_OVERFLOW_HEURISTIC.
27151 2021-05-14  Bruno Haible  <bruno@clisp.org>
27153         fcntl tests: Avoid failure in MacPorts.
27154         Reported by Nicholas Gaya <nicholasgaya@gmail.com> in
27155         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00014.html>.
27156         * tests/test-fcntl.c (main): Close fd 10 before assuming that it is
27157         closed.
27158         * tests/test-execute-main.c: Update comment.
27160 2021-05-14  Bruno Haible  <bruno@clisp.org>
27162         linked-list-unportable-test: New module.
27163         * modules/linked-list-unportable-tests: New file, based on
27164         modules/linked-list-tests.
27165         * modules/linked-list-tests: Remove the unportable tests from here.
27166         Depend on linked-list-unportable-tests.
27168 2021-05-14  Simon Josefsson  <simon@josefsson.org>
27170         valgrind-tests: Doc fix and introduce AM_VALGRINDFLAGS.
27171         * doc/valgrind-tests.texi (Using valgrind automatically): Clarify
27172         when the parallel vs serial test harness is used, suggested by
27173         Bruno Haible <bruno@clisp.org>.
27174         * m4/valgrind-tests.m4: Add VALGRIND_PROGRAM and AM_VALGRINDFLAGS.
27176 2021-05-14  Bruno Haible  <bruno@clisp.org>
27178         malloc-gnu, realloc-gnu, calloc-gnu: Ensure errno gets set to ENOMEM.
27179         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Set gl_cv_func_malloc_posix to
27180         'no' also on Solaris.
27182 2021-05-14  Bruno Haible  <bruno@clisp.org>
27184         DEPENDENCIES: Mention the requirement for 'join'.
27185         Reported by Simon Josefsson <simon@josefsson.org> in
27186         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00047.html>.
27187         * DEPENDENCIES: Mention 'join' among the core POSIX utilities.
27189 2021-05-14  Bruno Haible  <bruno@clisp.org>
27191         *alloc-gnu tests: Use ASSERT macro.
27192         * tests/test-malloc-gnu.c: Include "macros.h".
27193         (main): Use ASSERT.
27194         * tests/test-calloc-gnu.c: Include "macros.h".
27195         (main): Use ASSERT.
27196         * tests/test-realloc-gnu.c: Include "macros.h".
27197         (main): Use ASSERT.
27198         * tests/test-reallocarray.c: Include "macros.h".
27199         (main): Use ASSERT.
27200         * modules/malloc-gnu-tests (Files): Add tests/macros.h.
27201         * modules/calloc-gnu-tests (Files): Likewise.
27202         * modules/realloc-gnu-tests (Files): Likewise.
27203         * modules/reallocarray-tests (Files): Likewise.
27205 2021-05-14  Simon Josefsson  <simon@josefsson.org>
27207         valgrind-tests: Fix 'sh: yes: unknown operand' error.
27208         * m4/valgrind-tests.m4: Protect variable usage.
27210 2021-05-14  Simon Josefsson  <simon@josefsson.org>
27212         valgrind-tests: Fix LOG_VALGRIND when valgrind is missing.
27213         * m4/valgrind-tests.m4: Clear all variables when missing.
27215 2021-05-14  Simon Josefsson  <simon@josefsson.org>
27217         valgrind-tests: Better option handling.
27218         * m4/valgrind-tests.m4: Support new variables VALGRINDFLAGS and
27219         DEFAULT_VALGRINDFLAGS.
27220         * doc/valgrind-tests.texi (Running self-tests under valgrind):
27221         Improve.
27223 2021-05-14  Markus Mützel  <markus.muetzel@gmx.de>  (tiny change)
27225         windows-spawn: Don't assume that UNICODE is not defined.
27226         * lib/windows-spawn.h (compose_handles_block): Use type STARTUPINFOA.
27228 2021-05-13  Bruno Haible  <bruno@clisp.org>
27230         getrandom: Produce a better error code.
27231         Reported by Paul Eggert in
27232         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00025.html>.
27233         * lib/getrandom.c (getrandom): When open() fails with an error that does
27234         not indicate the absence of the file, fail with that error code, not
27235         with ENOSYS.
27237 2021-05-13  Bruno Haible  <bruno@clisp.org>
27239         fstatat: Document a glibc 2.7 bug.
27240         * doc/posix-functions/fstatat.texi: Document an old glibc 2.7 bug.
27242 2021-05-13  Bruno Haible  <bruno@clisp.org>
27244         posix_spawn, posix_spawnp: Fix build error on Minix 3.3.
27245         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): If posix_spawn does not exist
27246         but is declared, set REPLACE_POSIX_SPAWN.
27247         * doc/posix-functions/posix_spawn.texi: Update platforms list.
27248         * doc/posix-functions/posix_spawnp.texi: Likewise.
27250 2021-05-13  Bruno Haible  <bruno@clisp.org>
27252         reallocarray tests: Avoid test failure on NetBSD.
27253         * tests/test-reallocarray.c (main): Accept EOVERFLOW error code.
27255 2021-05-12  Bruno Haible  <bruno@clisp.org>
27257         gnulib-tool: Fail properly if the 'join' program is not found.
27258         Reported by Simon Josefsson <simon@josefsson.org> in
27259         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00029.html>.
27260         * gnulib-tool: Bail out early of the 'join' program is not found.
27262 2021-05-09  Bruno Haible  <bruno@clisp.org>
27264         {realloc,calloc}-gnu: Fix autoconf macro (regression 2021-04-18).
27265         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Don't reset REPLACE_REALLOC
27266         to 0 if it is already 1 after gl_FUNC_REALLOC_GNU was executed.
27267         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Don't reset REPLACE_CALLOC
27268         to 0 if it is already 1 after gl_FUNC_CALLOC_GNU was executed.
27270         {malloc,realloc,calloc}-gnu: Fix autoconf macro (regression 2021-04-18).
27271         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): Don't assume that
27272         _AC_FUNC_MALLOC_IF expands to a single shell statement.
27273         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): Don't assume that
27274         _AC_FUNC_REALLOC_IF expands to a single shell statement.
27275         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Don't assume that
27276         _AC_FUNC_CALLOC_IF expands to a single shell statement.
27278 2021-05-09  Bruno Haible  <bruno@clisp.org>
27280         malloc-gnu, realloc-gnu, calloc-gnu: Ensure errno gets set on IRIX.
27281         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Require AC_CANONICAL_HOST. Set
27282         gl_cv_func_malloc_posix to 'no' also on IRIX.
27284         malloc-gnu, realloc-gnu, calloc-gnu tests: Verify errno is set.
27285         * tests/test-malloc-gnu.c: Include <errno.h>.
27286         (main): Verify that, when an allocation larger than PTRDIFF_MAX failed,
27287         errno is ENOMEM.
27288         * tests/test-realloc-gnu.c: Likewise.
27289         * tests/test-calloc-gnu.c: Likewise.
27291 2021-05-09  Bruno Haible  <bruno@clisp.org>
27293         getrandom: Fail with ENOSYS when the system has no randomness source.
27294         * lib/getrandom.c (getrandom): When open() fails, set errno to ENOSYS.
27296 2021-05-09  Bruno Haible  <bruno@clisp.org>
27298         free tests: Avoid test failure on glibc < 2.15.
27299         * tests/test-free.c (main): Skip the hairy test on glibc < 2.15.
27301 2021-05-08  Bruno Haible  <bruno@clisp.org>
27303         Fix build error when libintl is installed.
27304         * modules/posix_spawn_file_actions_addchdir-tests (Makefile.am): Link
27305         test-posix_spawn-chdir with libintl.
27306         * modules/posix_spawn_file_actions_addfchdir-tests (Makefile.am): Link
27307         test-posix_spawn-fchdir with libintl.
27309 2021-05-07  Bruno Haible  <bruno@clisp.org>
27311         Fix build when an older libunistring is installed (regr. 2020-02-23).
27312         * modules/unitypes (configure.ac): Arrange to generate the .h file if
27313         the installed one is from a version < 0.9.11.
27314         * modules/unicase/base (configure.ac): Likewise.
27315         * modules/uniconv/base (configure.ac): Likewise.
27316         * modules/unilbrk/base (configure.ac): Likewise.
27317         * modules/uninorm/base (configure.ac): Likewise.
27318         * modules/unistdio/base (configure.ac): Likewise.
27319         * modules/unistr/base (configure.ac): Likewise.
27320         * modules/uniwbrk/base (configure.ac): Likewise.
27321         * modules/uniwidth/base (configure.ac): Likewise.
27322         * modules/unictype/base (configure.ac): Arrange to generate the .h file
27323         if the installed one is from a version < 0.9.8.
27324         * modules/unigbrk/base (configure.ac): Likewise.
27326 2021-04-30  Bruno Haible  <bruno@clisp.org>
27328         immutable: Fix crash when immmalloc() fails.
27329         Found by GCC 11 '-fanalyzer'.
27330         * lib/immutable.c (immstrdup): Don't crash when immmalloc() fails.
27332 2021-04-30  Bruno Haible  <bruno@clisp.org>
27334         supersede: Fix crash when malloc() fails.
27335         Found by GCC 11 '-fanalyzer'.
27336         * lib/supersede.c (create_temp_file): Don't crash when malloc() fails.
27338 2021-04-27  Paul Eggert  <eggert@cs.ucla.edu>
27340         libc-config: fix include problem on older Debian
27341         https://lists.gnu.org/r/bug-gnulib/2021-04/msg00198.html
27342         * lib/cdefs.h: Use __GNULIB_CDEFS, not __GLIBC__,
27343         to determine whether to include the bits/* files.
27344         * lib/libc-config.h (__WORDSIZE): Remove.
27345         (__GNULIB_CDEFS): New macro.
27347 2021-04-26  Paul Eggert  <eggert@cs.ucla.edu>
27349         gnulib-tool: port better to current Autoconf
27350         * doc/gnulib-tool.texi (Initial import): Don’t mention
27351         AC_PROG_CC_STDC as it’s deprecated in current Autoconf.
27352         * gnulib-tool (func_done_dir): Suggest replacing
27353         AC_PROG_CC_STDC and AC_PROG_CC_C99, as per current Autoconf.
27355 2021-04-25  Paul Eggert  <eggert@cs.ucla.edu>
27357         reallocarray: a bit more tuning
27358         * lib/reallocarray.c: Include intprops.h.
27359         (reallocarray): Use INT_MULTIPLY_WRAPV instead of
27360         xalloc_oversized, as it now suffices and is likely a bit more
27361         efficient (five fewer machine insns on Ubuntu 20.10 x86-64).
27362         * modules/reallocarray (Depends-on): Depend on intprops, not
27363         xalloc-oversized.  Use conditional dependencies to avoid building
27364         realloc-gnu when not needed.
27366         reallocarray: don’t crash if item size is 0
27367         This problem affects only platforms where xalloc_oversized
27368         divides a number by the size arg.  Fix this by defining
27369         xalloc_oversized (n, s) to work even if s == 0.
27370         * lib/malloca.h, lib/xalloc-oversized.h: Document new behavior.
27371         * lib/xalloc-oversized.h (__xalloc_oversized): Do not crash if S==0.
27372         * tests/test-reallocarray.c (main): Test for the bug.
27374 2021-04-24  Paul Eggert  <eggert@cs.ucla.edu>
27376         xmalloca, etc.: avoid unlikely trap
27377         * lib/malloca.h (nmalloca):
27378         * lib/xmalloca.h (xnmalloca):
27379         Use size_t, not ptrdiff_t, to avoid implementation-defined
27380         behavior (which could include a trap) if N is 0 and S exceeds
27381         PTRDIFF_MAX.
27382         * lib/xalloc-oversized.h: Adjust comment to match.
27384         xmalloca, etc.: fix some xalloc-oversized issues
27385         * lib/malloca.h (nmalloca):
27386         * lib/xmalloca.h (xnmalloca): Convert S to ptrdiff_t to avoid
27387         arithmetic overflow if N and S are both narrower than ptrdiff_t.
27388         * lib/xalloc-oversized.h (xalloc_oversized):
27389         Don’t say that args must be ptrdiff_t or size_t or wider.
27390         The macro returns the correct answer even when that is not
27391         the case, and it’s the caller’s responsibility to avoid
27392         howlers like (xalloc_oversized (n, s) ? NULL : malloc (n * s))
27393         when N and S are both narrower than ptrdiff_t and size_t.
27394         Add a comment to that effect.
27395         * lib/xmalloca.h: Include xalloc-oversized.h, since this file uses
27396         xalloc_oversized.  Add comments about side effects and avoid
27397         unnecessary parens.
27398         * modules/xmalloca (Depends-on): Add xalloc-oversized.
27400         reallocarray: check for ptrdiff_t overflow
27401         * doc/glibc-functions/reallocarray.texi (reallocarray):
27402         Mention ptrdiff_t overflow.
27403         * lib/reallocarray.c (reallocarray): Reindent as per usual GNU.
27404         * lib/stdlib.in.h (reallocarray): Allow reallocarray to be replaced.
27405         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY):
27406         Check for ptrdiff_t overflow.
27407         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Set up REPLACE_REALLOCARRAY.
27408         * modules/reallocarray (Files): Add malloc.m4.
27409         (configure.ac): Also test REPLACE_REALLOCARRAY.
27410         * modules/reallocarray-tests (Depends-on): Add stdint.
27411         * modules/stdlib (stdlib.h): Substitute REPLACE_REALLOCARRAY.
27412         * tests/test-reallocarray.c: Include stdint.h.
27413         (main): Check for ptrdiff_t overflow.
27415         calloc-gnu-tests: add overflow tests
27416         * tests/test-calloc-gnu.c (identity): New function, replacing ‘eight’.
27417         (main): Do 2 * log2(SIZE_MAX) tests instead of just two tests.
27418         Don’t bother to free on failure.
27420 2021-04-22  Paul Eggert  <eggert@cs.ucla.edu>
27422         libc-config: port better to Fedora Rawhide
27423         Problem reported by Eric Blake in:
27424         https://lists.gnu.org/r/bug-gnulib/2021-04/msg00181.html
27425         * lib/cdefs.h: Make this closer to glibc, so that we can
27426         merge Gnulib into glibc here.
27427         (__attribute_maybe_unused__): Make identical to glibc’s
27428         definition, though with an additional comment.
27429         (__attribute_nonnull__): Add clarifying comment.
27430         Make inclusion of bits/wordsize.h, bits/long-double.h
27431         dependent on __GLIBC__, not on !__WORDSIZE.
27432         * lib/libc-config.h: Use __attribute_nonnull__,
27433         not __attribute_maybe_unused__, to detect whether
27434         to include sys/cdefs.h.
27436 2021-04-21  Paul Eggert  <eggert@cs.ucla.edu>
27438         realloc: port to AIX 7.1
27439         * lib/realloc.c (_GL_USE_STDLIB_ALLOC): Do not define.  This
27440         module relies on GNU malloc.  This fixes a test failure on AIX 7.1.
27442         malloc: simplify
27443         * lib/malloc.c: Omit unnecessary "#undef malloc".
27444         I recently introduced it by mistake.  This module defines
27445         _GL_USE_STDLIB_ALLOC and so malloc isn’t redefined to rpl_malloc.
27447         malloca: avoid ptrdiff_t overflow
27448         * lib/malloca.c: Include idx.h, intprops.h.
27449         (mmalloca): Check for ptrdiff_t overflow.  Since this module uses
27450         _GL_USE_STDLIB_ALLOC, it cannot assume GNU malloc semantics.
27451         * modules/malloca (Depends-on): Add idx, intprops.
27453         careadlinkat: avoid ptrdiff_t overflow
27454         * lib/careadlinkat.c: Include idx.h, minmax.h.
27455         (readlink_stk): Avoid ptrdiff_t overflow in object allocation.
27456         Since this module uses arbitrary allocators (including
27457         stdlib_allocator), it cannot assume GNU malloc semantics.
27458         * modules/careadlinkat (Depends-on): Add idx, minmax.
27460         execute-tests: pacify compiler
27461         * tests/test-execute-main.c (main): Use 0x7DEADBEE rather than
27462         0xDEADBEEF for nonces, to avoid provoking AIX XLC compiler warning
27463         that the latter is out of int range.
27465 2021-04-20  Paul Eggert  <eggert@cs.ucla.edu>
27467         malloc-gnu-tests, etc.: use volatile for clang
27468         In some more test locations, store the result of malloc etc. into
27469         a volatile pointer so that clang doesn’t optimize away the malloc
27470         and thus bypass the test.  This fixes a malloc-gnu test failure on
27471         macOS 11.2.3 with clang 12.0.0 on ARM.
27472         * tests/test-alloca-opt.c (do_allocation):
27473         * tests/test-malloc-gnu.c (main):
27474         * tests/test-malloca.c (do_allocation):
27475         * tests/test-realloc-gnu.c (main):
27476         * tests/test-reallocarray.c (main):
27477         * tests/test-aligned-malloc.c (main):
27478         * tests/test-aligned_alloc.c (main):
27479         Store malloc etc. results into a volatile pointer.
27481 2021-04-18  Paul Eggert  <eggert@cs.ucla.edu>
27483         malloc-gnu-tests: pacify -Walloc-size-larger-than
27484         * tests/test-malloc-gnu.c (main):
27485         * tests/test-realloc-gnu.c (main): Hide true intentions from GCC,
27486         to prevent diagnostics like “warning: argument 1 value
27487         ‘9223372036854775808’ exceeds maximum object size
27488         9223372036854775807 [-Walloc-size-larger-than=]”.
27490         safe-alloc: fix pointer implementation
27491         The old implementation assumed that all pointers use the same
27492         internal representation, but the C standard doesn’t guarantee
27493         this.  Use void * (pointer) not void ** (pointer-to-pointer) for
27494         the internal functions’ API.  The internal functions now return
27495         NULL if and only if they failed, and the macros translate that
27496         into -1 or 0 to satisfy the existing API.
27497         * doc/safe-alloc.texi (Safe Allocation Macros): Mention overflow.
27498         * lib/safe-alloc.c: Major rewrite.  Now this simply
27499         defines SAFE_ALLOC_INLINE and includes safe-alloc.h.
27500         * lib/safe-alloc.h: Include stddef.h, not stdlib.h.
27501         (SAFE_ALLOC_INLINE): New macro; use Gnulib inline function style.
27502         (safe_alloc_realloc_n): New API, which passes and returns
27503         the pointer, and which returns NULL if and only if failure occurs.
27504         (safe_alloc_check): New function.
27505         (ALLOC, ALLOC_N, ALLOC_N_UNINITIALIZED, REALLOC_N):
27506         Redo using the new API for internal functions, and using calloc
27507         which is good enough since it’s GNU-compatible now.
27508         (FREE): Expand to an expression rather than merely to something
27509         that needs a following ‘;’ to become a statement.
27510         * modules/safe-alloc (Depends-on): Add calloc-gnu.
27512         calloc-gnu: now LGPLv2+
27513         * modules/calloc-gnu (License): Change from GPL to LGPLv2+.
27514         The old value was evidently a longstanding typo, and calloc
27515         will be needed by LGPLv2+ modules that will want to rely
27516         on GNU behavior.
27518         safe-alloc: simplify via reallocarray
27519         * lib/safe-alloc.c: Do not include xalloc-oversized.h.
27520         (safe_alloc_alloc_n, safe_alloc_realloc_n):
27521         Use reallocarray to check for size or ptrdiff_t overflow.
27522         * modules/reallocarray (License): Switch from LGPL to LGPLv2+, as
27523         this is needed for safe-alloc and anyway is more appropriate for
27524         this library function common with BSD.
27525         * modules/safe-alloc (Depends-on): Depend on reallocarray
27526         rather than xalloc-oversized.
27528         xalloc-oversized: fix SIZE_MAX optimization bug
27529         * lib/xalloc-oversized.h (xalloc_count_t): Remove; no longer
27530         needed and was evidently error-prone anyway.
27531         (xalloc_oversized): Omit some over-optimization that caused
27532         SIZE_MAX to not be treated as too large (the Gnulib convention) on
27533         unusual platforms where PTRDIFF_MAX == SIZE_MAX.  This change
27534         should not affect typical platforms where PTRDIFF_MAX < SIZE_MAX.
27535         When optimizing, simply use ptrdiff_t instead of xalloc_count_t.
27537         xalloc: new function xreallocarray
27538         This is the same as xnrealloc, which perhaps should be deprecated.
27539         The name xreallocarray should be easier to remember now that
27540         reallocarray is a standard GNU function.
27541         * lib/xalloc.h [GNULIB_XALLOC]: Do not include xalloc-oversized.h.
27542         (xnmalloc, xnrealloc, x2nrealloc): Simplify by using xreallocarray.
27543         * lib/xmalloc.c (xreallocarray): New function.
27544         * modules/xalloc (Depends-on): Add reallocarray;
27545         remove xalloc-oversized.
27547         group-member: simplify via realloc-gnu
27548         * lib/group-member.c, modules/group-member:
27549         Simplify similarly to backupfile.
27551         backupfile: simplify via realloc-gnu
27552         * lib/backupfile.c: Do not include xalloc-oversized.h.
27553         (numbered_backup): Simplify now that realloc will do the right
27554         thing about ptrdiff_t overflow.
27555         * modules/backupfile (Depends-on): Add realloc-gnu;
27556         remove xalloc-oversized.
27558         safe-alloc: improve doc
27559         * doc/safe-alloc.texi: Clarify that reallocating an array appends
27560         uninitialized storage.  Say ‘sizeof *p’ rather than ‘sizeof(*p)’
27561         which would need a space before the paren to follow GNU style.
27563         malloc-gnu-tests, etc.: test ptrdiff_t overflow
27564         * modules/calloc-gnu-tests (Depends-on):
27565         * modules/malloc-gnu-tests (Depends-on):
27566         * modules/realloc-gnu-tests (Depends-on): Add stdint.
27567         * tests/test-calloc-gnu.c (main):
27568         * tests/test-malloc-gnu.c (main):,
27569         * tests/test-realloc-gnu.c (main): Test for ptrdiff_t overflow.
27571         malloc-gnu, etc.: prefer AS_CASE to woolly AS_IF
27572         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
27573         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
27574         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Use AS_CASE.
27576         malloc-gnu, etc.: sync better with Autoconf
27577         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
27578         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
27579         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF):
27580         Avoid some unnecessary differences from Autoconf’s versions.
27581         Separate our platforms into a different line so that it’s easier
27582         to diff.  Use AS_IF in case the args use AC_REQUIRE.
27583         However, don’t bother with omitting the first newline, as
27584         omitting the newline is not Gnulib style and the difference
27585         doesn’t seem to matter here.
27587 2021-04-18  Bruno Haible  <bruno@clisp.org>
27589         malloc-posix, realloc-posix, calloc-posix: Document affected platforms.
27590         * doc/posix-functions/malloc.texi: Re-add platforms list.
27591         * doc/posix-functions/realloc.texi: Likewise.
27592         * doc/posix-functions/calloc.texi: Likewise.
27594 2021-04-18  Bruno Haible  <bruno@clisp.org>
27596         More systematic file naming.
27597         * m4/ctype_h.m4: Renamed from m4/ctype.m4.
27598         * m4/threads_h.m4: Renamed from m4/threads.m4.
27599         * m4/uchar_h.m4: Renamed from m4/uchar.m4.
27601 2021-04-18  Bruno Haible  <bruno@clisp.org>
27603         Add comments after 2021-04-11 change.
27604         * m4/*_h.m4: Add comments regarding *_REQUIRE_DEFAULTS and
27605         *_MODULE_INDICATOR macros.
27607 2021-04-18  Bruno Haible  <bruno@clisp.org>
27609         doc: Update for FreeBSD 13.0/arm64.
27610         * doc/posix-headers/stdint.texi: Mention FreeBSD 13 bug.
27611         * m4/stdint.m4: Update comment.
27613 2021-04-17  Paul Eggert  <eggert@cs.ucla.edu>
27615         xalloc: adjust to malloc ptrdiff_t change
27616         * lib/xmalloc.c (HAVE_GNU_CALLOC, HAVE_GNU_MALLOC, HAVE_GNU_REALLOC):
27617         Remove.
27618         (xmalloc, xrealloc, xcalloc): Simplify by assuming GNU behavior.
27619         * modules/xalloc (Depends-on): Add calloc-gnu, malloc-gnu,
27620         realloc-gnu.
27622         malloc, etc.: check for ptrdiff_t overflow
27623         In glibc 2.30 and later, malloc, realloc and calloc reject
27624         attempts to create objects larger than PTRDIFF_MAX bytes.
27625         This patch changes malloc-gnu etc. to support this behavior
27626         on non-GNU hosts.  It also makes this change for malloc-posix etc.
27627         since it’s a safety measure that ought to be in POSIX (perhaps
27628         we can talk them into that...).
27630         In writing this patch I found a complicated set of code that had
27631         accumulated over the years, some written by yours truly.  I got
27632         rid of the code I couldn’t see the need for nowadays.  Among other
27633         things, the GNU realloc behavior is no longer incompatible with
27634         the C standard, because in C17 the latter was relaxed to allow the
27635         former.  If I went too far in cleaning up, the old stuff can be
27636         resurrected.
27638         This change is mostly for 32-bit platforms, since practical 64-bit
27639         platforms cannot create objects larger than PTRDIFF_MAX bytes anyway.
27640         * doc/posix-functions/calloc.texi:
27641         * doc/posix-functions/malloc.texi:
27642         * doc/posix-functions/realloc.texi:
27643         Mention ptrdiff_t issues, and go into more detail about what
27644         the gnu extension module does.
27645         * doc/posix-functions/realloc.texi: Fix now-obsolete commentary
27646         about C99 vs glibc, as C17 allows the glibc behavior and POSIX
27647         will follow suit when it gets around to it.
27648         * lib/calloc.c, lib/malloc.c, lib/realloc.c:
27649         Simplify by always supplying a GNU-compatible version,
27650         as that suffices for correctness and is good enough for performance.
27651         Include xalloc-oversized.h, and use xalloc_oversized to
27652         check for ptrdiff_t overflow.
27653         (NEED_CALLOC_GNU, NEED_MALLOC_GNU, NEED_REALLOC_GNU): Remove.
27654         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
27655         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
27656         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF):
27657         Don’t start with a newline.  Fix message to match behavior.
27658         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don’t test for size_t overflow,
27659         as the ptrdiff_t test is good enough.
27660         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU):
27661         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU):
27662         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU):
27663         Do not define HAVE_CALLOC_GNU, HAVE_MALLOC_GNU, HAVE_REALLOC_GNU.
27664         It’s not worth the aggravation of maintaining these, as they
27665         are confusing (they don’t really mean GNU-compatible anyway).
27666         Don’t bother testing for GNU behavior if we have already decided
27667         to replace the function, since the replacement is always GNUish.
27668         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX):
27669         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX):
27670         Defer to gl_FUNC_MALLOC_POSIX.
27671         * m4/malloc.m4 (gl_FUNC_MALLOC_PTRDIFF, gl_CHECK_MALLOC_PTRDIFF):
27672         New macros.
27673         (gl_FUNC_MALLOC_POSIX): Use them to check for ptrdiff_t overflow.
27674         * modules/calloc-gnu, modules/malloc-gnu, modules/realloc-gnu:
27675         Remove no-longer-needed module indicators.
27676         * modules/calloc-posix, modules/malloc-posix, modules/realloc-posix:
27677         Depend on xalloc-oversized.
27678         * modules/malloc-posix: Require gl_FUNC_MALLOC_POSIX instead of
27679         calling it directly, so that other code can require it.
27680         * modules/realloc-posix: Depend on free-posix and malloc-posix.
27682 2021-04-17  Bruno Haible  <bruno@clisp.org>
27684         stdio: Fix build error in some configurations (regression 2021-04-11).
27685         * m4/stdio_h.m4 (gl_STDIO_H): Move gl_STDIO_MODULE_INDICATOR and
27686         gl_MODULE_INDICATOR invocations from here...
27687         * modules/stdio (configure.ac): ... to here.
27689 2021-04-17  Bruno Haible  <bruno@clisp.org>
27691         doc: Update for FreeBSD 11.0, 12.0, 13.0.
27692         * doc/posix-headers/*.texi: Update.
27693         * doc/glibc-headers/*.texi: Update.
27694         * doc/posix-functions/*.texi: Likewise.
27695         * doc/pastposix-functions/*.texi: Likewise.
27696         * doc/glibc-functions/*.texi: Likewise.
27697         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Update cross-compilation guess.
27699 2021-04-16  Paul Eggert  <eggert@cs.ucla.edu>
27701         malloc, realloc: fix recently-introduced #undef typos
27702         * lib/malloc.c (malloc):
27703         * lib/realloc.c (malloc, realloc): #undef before using.
27705 2021-04-14  Bruno Haible  <bruno@clisp.org>
27707         hamt tests: Fix link error.
27708         * modules/hamt-tests (Makefile.am): Link test-hamt against @LIBINTL@.
27710 2021-04-14  Bruno Haible  <bruno@clisp.org>
27712         c-stack: Don't use an undefined C macro (regression from 2020-10-04).
27713         * lib/c-stack.c: Test GNU C version directly, without __GNUC_PREREQ.
27715 2021-04-12  Bruno Haible  <bruno@clisp.org>
27717         doc: Fix confusion between LIBADD and LDADD.
27718         Reported by Reuben Thomas <rrt@sc3d.org> in
27719         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00102.html>.
27720         * doc/gnulib-tool.texi (Multiple instances): For programs, use LDADD,
27721         not LIBADD.
27723 2021-04-11  Bruno Haible  <bruno@clisp.org>
27725         malloc, realloc, calloc: Support restricted library symbols on AIX.
27726         Suggested by Paul Eggert in
27727         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00119.html>.
27728         * lib/malloc.c: Drop the code that intends to collaborate with
27729         AC_FUNC_MALLOC.
27730         * lib/realloc.c: Drop the code that intends to collaborate with
27731         AC_FUNC_REALLOC.
27732         * lib/calloc.c: Drop the code that intends to collaborate with the
27733         nonexistent macro AC_FUNC_CALLOC.
27735 2021-04-11  Bruno Haible  <bruno@clisp.org>
27737         Support several gnulib-tool invocations under the same configure.ac.
27738         Reported by Reuben Thomas <rrt@sc3d.org> in
27739         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00104.html>.
27740         This is done by defining the Gnulib module indicator variables per
27741         gnulib-tool invocation. So that a generated .h file is no longer
27742         influenced by the set of modules used in other gnulib-tool invocations.
27743         * gnulib-tool (func_compute_include_guard_prefix): Set
27744         module_indicator_prefix.
27745         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use it to
27746         modify $(GNULIB_*) variable references in the Automake snippets.
27747         (func_emit_initmacro_start): Push macro definitions for GL_MACRO_PREFIX
27748         and GL_MODULE_INDICATOR_PREFIX.
27749         (func_emit_initmacro_end): Pop these macro definitions.
27750         * pygnulib/GLConfig.py (GLConfig.getIncludeGuardPrefix): New method.
27751         * pygnulib/GLEmiter.py (GLEmiter.initmacro_start): Push macro
27752         definitions for GL_MACRO_PREFIX and GL_MODULE_INDICATOR_PREFIX.
27753         (GLEmiter.initmacro_end): Pop these macro definitions.
27754         (GLEmiter.lib_Makefile_am, GLEmiter.tests_Makefile_am): Use the module
27755         indicator prefix to modify $(GNULIB_*) variable references in the
27756         Automake snippets.
27757         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_INIT_VARIABLE,
27758         gl_MODULE_INDICATOR_SET_VARIABLE): Use the value of
27759         GL_MODULE_INDICATOR_PREFIX.
27760         * m4/arpa_inet_h.m4: Use new idiom for header files that contain
27761         references to Gnulib module indicator variables:
27762         - Define the main macro through AC_DEFUN_ONCE.
27763         - Define a macro gl_*_H_REQUIRE_DEFAULTS that initializes the Gnulib
27764           module indicator variables (each prefixed with
27765           GL_MODULE_INDICATOR_PREFIX).
27766         - Invoke this macro in the gl_*_MODULE_INDICATOR macro.
27767         * m4/ctype.m4: Likewise.
27768         * m4/dirent_h.m4: Likewise.
27769         * m4/fcntl_h.m4: Likewise.
27770         * m4/fnmatch_h.m4: Likewise.
27771         * m4/glob_h.m4: Likewise.
27772         * m4/iconv_h.m4: Likewise.
27773         * m4/inttypes.m4: Likewise.
27774         * m4/langinfo_h.m4: Likewise.
27775         * m4/locale_h.m4: Likewise.
27776         * m4/malloc_h.m4: Likewise.
27777         * m4/math_h.m4: Likewise.
27778         * m4/monetary_h.m4: Likewise.
27779         * m4/netdb_h.m4: Likewise.
27780         * m4/poll_h.m4: Likewise.
27781         * m4/pthread_h.m4: Likewise.
27782         * m4/pty_h.m4: Likewise.
27783         * m4/sched_h.m4: Likewise.
27784         * m4/search_h.m4: Likewise.
27785         * m4/signal_h.m4: Likewise.
27786         * m4/spawn_h.m4: Likewise.
27787         * m4/stddef_h.m4: Likewise.
27788         * m4/stdio_h.m4: Likewise.
27789         * m4/stdlib_h.m4: Likewise.
27790         * m4/string_h.m4: Likewise.
27791         * m4/strings_h.m4: Likewise.
27792         * m4/sys_file_h.m4: Likewise.
27793         * m4/sys_ioctl_h.m4: Likewise.
27794         * m4/sys_random_h.m4: Likewise.
27795         * m4/sys_resource_h.m4: Likewise.
27796         * m4/sys_select_h.m4: Likewise.
27797         * m4/sys_socket_h.m4: Likewise.
27798         * m4/sys_stat_h.m4: Likewise.
27799         * m4/sys_time_h.m4: Likewise.
27800         * m4/sys_times_h.m4: Likewise.
27801         * m4/sys_types_h.m4: Likewise.
27802         * m4/sys_uio_h.m4: Likewise.
27803         * m4/sys_utsname_h.m4: Likewise.
27804         * m4/sys_wait_h.m4: Likewise.
27805         * m4/termios_h.m4: Likewise.
27806         * m4/threads.m4: Likewise.
27807         * m4/time_h.m4: Likewise.
27808         * m4/uchar.m4: Likewise.
27809         * m4/unistd_h.m4: Likewise.
27810         * m4/utime_h.m4: Likewise.
27811         * m4/wchar_h.m4: Likewise.
27812         * m4/wctype_h.m4: Likewise.
27813         * modules/arpa_inet (configure.ac): Invoke the macro
27814         gl_*_H_REQUIRE_DEFAULTS explicitly.
27815         * modules/ctype (configure.ac): Likewise.
27816         * modules/dirent (configure.ac): Likewise.
27817         * modules/fcntl-h (configure.ac): Likewise.
27818         * modules/fnmatch-h (configure.ac): Likewise.
27819         * modules/glob-h (configure.ac): Likewise.
27820         * modules/iconv-h (configure.ac): Likewise.
27821         * modules/inttypes-incomplete (configure.ac): Likewise.
27822         * modules/langinfo (configure.ac): Likewise.
27823         * modules/locale (configure.ac): Likewise.
27824         * modules/malloc-h (configure.ac): Likewise.
27825         * modules/math (configure.ac): Likewise.
27826         * modules/monetary (configure.ac): Likewise.
27827         * modules/netdb (configure.ac): Likewise.
27828         * modules/poll-h (configure.ac): Likewise.
27829         * modules/pthread-h (configure.ac): Likewise.
27830         * modules/pty (configure.ac): Likewise.
27831         * modules/sched (configure.ac): Likewise.
27832         * modules/search (configure.ac): Likewise.
27833         * modules/signal-h (configure.ac): Likewise.
27834         * modules/spawn (configure.ac): Likewise.
27835         * modules/stddef (configure.ac): Likewise.
27836         * modules/stdio (configure.ac): Likewise.
27837         * modules/stdlib (configure.ac): Likewise.
27838         * modules/string (configure.ac): Likewise.
27839         * modules/strings (configure.ac): Likewise.
27840         * modules/sys_file (configure.ac): Likewise.
27841         * modules/sys_ioctl (configure.ac): Likewise.
27842         * modules/sys_random (configure.ac): Likewise.
27843         * modules/sys_resource (configure.ac): Likewise.
27844         * modules/sys_select (configure.ac): Likewise.
27845         * modules/sys_socket (configure.ac): Likewise.
27846         * modules/sys_stat (configure.ac): Likewise.
27847         * modules/sys_time (configure.ac): Likewise.
27848         * modules/sys_times (configure.ac): Likewise.
27849         * modules/sys_types (configure.ac): Likewise.
27850         * modules/sys_uio (configure.ac): Likewise.
27851         * modules/sys_utsname (configure.ac): Likewise.
27852         * modules/sys_wait (configure.ac): Likewise.
27853         * modules/termios (configure.ac): Likewise.
27854         * modules/threads-h (configure.ac): Likewise.
27855         * modules/time (configure.ac): Likewise.
27856         * modules/uchar (configure.ac): Likewise.
27857         * modules/unistd (configure.ac): Likewise.
27858         * modules/utime-h (configure.ac): Likewise.
27859         * modules/wchar (configure.ac): Likewise.
27860         * modules/wctype-h (configure.ac): Likewise.
27861         * m4/af_alg.m4: Update after a macro name changed.
27862         * m4/ctime.m4: Likewise.
27863         * m4/explicit_bzero.m4: Likewise.
27864         * m4/ffs.m4: Likewise.
27865         * m4/ffsl.m4: Likewise.
27866         * m4/ffsll.m4: Likewise.
27867         * m4/flock.m4: Likewise.
27868         * m4/fstat.m4: Likewise.
27869         * m4/getaddrinfo.m4: Likewise.
27870         * m4/getdomainname.m4: Likewise.
27871         * m4/gettimeofday.m4: Likewise.
27872         * m4/hostent.m4: Likewise.
27873         * m4/ioctl.m4: Likewise.
27874         * m4/localtime.m4: Likewise.
27875         * m4/mbslen.m4: Likewise.
27876         * m4/memchr.m4: Likewise.
27877         * m4/memmem.m4: Likewise.
27878         * m4/mempcpy.m4: Likewise.
27879         * m4/memrchr.m4: Likewise.
27880         * m4/mktime.m4: Likewise.
27881         * m4/nanosleep.m4: Likewise.
27882         * m4/passfd.m4: Likewise.
27883         * m4/pselect.m4: Likewise.
27884         * m4/rawmemchr.m4: Likewise.
27885         * m4/select.m4: Likewise.
27886         * m4/servent.m4: Likewise.
27887         * m4/sigabbrev_np.m4: Likewise.
27888         * m4/sigdescr_np.m4: Likewise.
27889         * m4/sockpfaf.m4: Likewise.
27890         * m4/stat.m4: Likewise.
27891         * m4/stpcpy.m4: Likewise.
27892         * m4/stpncpy.m4: Likewise.
27893         * m4/strcase.m4: Likewise.
27894         * m4/strcasestr.m4: Likewise.
27895         * m4/strchrnul.m4: Likewise.
27896         * m4/strdup.m4: Likewise.
27897         * m4/strerror.m4: Likewise.
27898         * m4/strerror_r.m4: Likewise.
27899         * m4/strerrorname_np.m4: Likewise.
27900         * m4/strftime-fixes.m4: Likewise.
27901         * m4/strncat.m4: Likewise.
27902         * m4/strndup.m4: Likewise.
27903         * m4/strnlen.m4: Likewise.
27904         * m4/strpbrk.m4: Likewise.
27905         * m4/strptime.m4: Likewise.
27906         * m4/strsep.m4: Likewise.
27907         * m4/strsignal.m4: Likewise.
27908         * m4/strstr.m4: Likewise.
27909         * m4/strtok_r.m4: Likewise.
27910         * m4/strverscmp.m4: Likewise.
27911         * m4/time_r.m4: Likewise.
27912         * m4/time_rz.m4: Likewise.
27913         * m4/timegm.m4: Likewise.
27914         * m4/timespec_get.m4: Likewise.
27915         * m4/tzset.m4: Likewise.
27916         * modules/accept (configure.ac): Likewise.
27917         * modules/bind (configure.ac): Likewise.
27918         * modules/connect (configure.ac): Likewise.
27919         * modules/flock (configure.ac): Likewise.
27920         * modules/getpeername (configure.ac): Likewise.
27921         * modules/getsockname (configure.ac): Likewise.
27922         * modules/getsockopt (configure.ac): Likewise.
27923         * modules/listen (configure.ac): Likewise.
27924         * modules/recv (configure.ac): Likewise.
27925         * modules/recvfrom (configure.ac): Likewise.
27926         * modules/send (configure.ac): Likewise.
27927         * modules/sendto (configure.ac): Likewise.
27928         * modules/setsockopt (configure.ac): Likewise.
27929         * modules/shutdown (configure.ac): Likewise.
27930         * modules/socket (configure.ac): Likewise. Use the
27931         gl_*_H_REQUIRE_DEFAULTS macros.
27932         * modules/nonblocking (configure.ac): Use the gl_*_H_REQUIRE_DEFAULTS
27933         and gl_MODULE_INDICATOR_INIT_VARIABLE macros.
27934         * modules/sigpipe (configure.ac): Likewise.
27935         * modules/windows-stat-override (configure.ac): Likewise.
27936         * m4/nonblocking.m4: Update a comment.
27937         * m4/sigpipe.m4: Likewise.
27939 2021-04-11  Bruno Haible  <bruno@clisp.org>
27941         Rename GNULIB_OVERRIDES_CHAR16_T, GNULIB_OVERRIDES_CHAR32_T.
27942         * GNULIBHEADERS_OVERRIDE_CHAR16_T: Renamed from
27943         GNULIB_OVERRIDES_CHAR16_T.
27944         * GNULIBHEADERS_OVERRIDE_CHAR32_T: Renamed from
27945         GNULIB_OVERRIDES_CHAR32_T.
27947         Rename GNULIB_OVERRIDES_WINT_T.
27948         * GNULIBHEADERS_OVERRIDE_WINT_T: Renamed from GNULIB_OVERRIDES_WINT_T.
27950 2021-04-11  Bruno Haible  <bruno@clisp.org>
27952         increment-serial: New program.
27953         * build-aux/increment-serial: New file.
27955 2021-04-11  Bruno Haible  <bruno@clisp.org>
27957         useless-if-before-free: Implement --version option according to GCS.
27958         * build-aux/useless-if-before-free (copyright_year): New variable.
27959         (GetOptions): Print also a short copyright and license notice and
27960         author statement.
27962         libtool-next-version: Implement --version option according to GCS.
27963         * build-aux/libtool-next-version (scriptversion): New variable.
27964         (func_version): Deduce the copyright year from it. Terminate sentences
27965         with '.'.
27967         gnupload: Implement --version option according to GCS.
27968         * build-aux/gnupload (copyright_year, copyright): New variables.
27969         (--version): Print also a short copyright and license notice.
27971         git-version-gen: Implement --version option according to GCS.
27972         * build-aux/git-version-gen (version): State the license. Use wording
27973         from GCS.
27975         bootstrap: Implement --version option according to GCS.
27976         * build-aux/bootstrap (copyright_year, copyright): New variables.
27977         (--version): New option processing.
27979         announce-gen: Implement --version option according to GCS.
27980         * build-aux/announce-gen (copyright_year): New variable.
27981         (GetOptions): Print also a short copyright and license notice and
27982         author statement.
27984 2021-04-10  Bruno Haible  <bruno@clisp.org>
27986         Simplify GNULIB_* variable initializations.
27987         * modules/gnulib-common.m4 (gl_MODULE_INDICATOR_INIT_VARIABLE): New
27988         macro.
27989         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Use it.
27990         * m4/ctype.m4 (gl_CTYPE_H_DEFAULTS): Likewise.
27991         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Likewise.
27992         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Likewise.
27993         * m4/fnmatch_h.m4 (gl_FNMATCH_H_DEFAULTS): Likewise.
27994         * m4/glob_h.m4 (gl_GLOB_H_DEFAULTS): Likewise.
27995         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Likewise.
27996         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Likewise.
27997         * m4/langinfo_h.m4 (gl_LANGINFO_H_DEFAULTS): Likewise.
27998         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Likewise.
27999         * m4/malloc_h.m4 (gl_MALLOC_H_DEFAULTS): Likewise.
28000         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Likewise.
28001         * m4/monetary_h.m4 (gl_MONETARY_H_DEFAULTS): Likewise.
28002         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Likewise.
28003         * m4/poll_h.m4 (gl_POLL_H_DEFAULTS): Likewise.
28004         * m4/pthread_h.m4 (gl_PTHREAD_H_DEFAULTS): Likewise.
28005         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Likewise.
28006         * m4/sched_h.m4 (gl_SCHED_H_DEFAULTS): Likewise.
28007         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Likewise.
28008         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Likewise.
28009         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Likewise.
28010         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
28011         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
28012         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
28013         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_DEFAULTS): Likewise.
28014         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H_DEFAULTS): Likewise.
28015         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Likewise.
28016         * m4/sys_random_h.m4 (gl_SYS_RANDOM_H_DEFAULTS): Likewise.
28017         * m4/sys_resource_h.m4 (gl_SYS_RESOURCE_H_DEFAULTS): Likewise.
28018         * m4/sys_select_h.m4 (gl_SYS_SELECT_H_DEFAULTS): Likewise.
28019         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Likewise.
28020         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
28021         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): Likewise.
28022         * m4/sys_times_h.m4 (gl_SYS_TIMES_H_DEFAULTS): Likewise.
28023         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
28024         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H_DEFAULTS): Likewise.
28025         * m4/termios_h.m4 (gl_TERMIOS_H_DEFAULTS): Likewise.
28026         * m4/threads.m4 (gl_THREADS_H_DEFAULTS): Likewise.
28027         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Likewise.
28028         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Likewise.
28029         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
28030         * m4/utime_h.m4 (gl_UTIME_H_DEFAULTS): Likewise.
28031         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Likewise.
28032         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Likewise.
28034 2021-04-10  Paul Eggert  <eggert@cs.ucla.edu>
28036         realloc: fix undef typo
28037         * lib/realloc.c: #undef realloc if config.h defines it.
28038         This fixes a typo that I introduced in
28039         2011-04-08T18:39:01Z!eggert@cs.ucla.edu.
28040         Apparently nobody uses Gnulib realloc in that way?
28042 2021-04-07  Bruno Haible  <bruno@clisp.org>
28044         execute tests: Avoid test failure in certain environments.
28045         Reported by Dmitry V. Levin <ldv@altlinux.org> in
28046         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00082.html>.
28047         * tests/test-execute-main.c (main): Close file descriptors 3..19.
28048         * tests/test-execute-child.c (main): Remove NetBSD workaround.
28049         * modules/execute-tests (configure.ac): Test for close_range function.
28051 2021-04-07  Paul Eggert  <eggert@cs.ucla.edu>
28053         utimens: fix confusing arg type in internal func
28054         Although the old code was technically correct, this was accidental
28055         and it confused a GCC 11 prerelease.  Reported by Ondrej Dubaj in:
28056         https://lists.gnu.org/r/bug-tar/2021-04/msg00000.html
28057         * lib/utimens.c (update_timespec): Change arg type from ‘struct
28058         timespec *[2]’ (pointer to array of 2 pointers to timespecs) to
28059         ‘struct timespec **’ (pointer to pointer to the first timespec in
28060         an array of 2 timespecs).  Although the old code happened to be
28061         technically correct, it was misleading and confused Coverity.
28062         And though the type ‘struct timespec (**)[2]’ (pointer to pointer
28063         to array of 2 timespecs) would perhaps be more technically
28064         correct, it would be almost as confusing and would require changes
28065         elsewhere in this file; let’s quit while we’re ahead.
28067         xalloc: simplify integer overflow test
28068         * lib/xalloc.h (x2nrealloc): Simplify integer overflow detection.
28069         This is easier to maintain, and (unlike the old code) exact.
28071 2021-04-06  Paul Eggert  <eggert@cs.ucla.edu>
28073         group-member: minor tweak to omit a *
28074         * lib/group-member.c: Include intprops.h.
28075         (get_group_info): Use INT_MULTIPLY_WRAPV instead of
28076         xalloc_oversized (which does a multiplication) followed by the
28077         same multiplication.  The code was OK as-is; this is just
28078         conceptual simplification, possible now that we have xalloc_count_t.
28079         * modules/group-member: Depend on intprops.
28081         backupfile: less-aggressive buffer growth
28082         * lib/backupfile.c: Include intprops.h.
28083         (numbered_backup): Grow buffer by the usual 50%, not 100%.
28084         This is easier to do now that we have xalloc_count_t.
28085         * modules/backup-rename, modules/backupfile: Depend on intprops.
28087         xalloc-oversized: export xalloc_count_t
28088         * lib/xalloc-oversized.h (__xalloc_oversized, xalloc_oversized):
28089         * lib/xmalloca.h (nmalloca):
28090         Comment re restrictions on arg types.
28091         * lib/xalloc-oversized.h (xalloc_count_t): Rename from
28092         __xalloc_count_type; all uses changed.  This publicizes the type.
28094 2021-04-05  Paul Eggert  <eggert@cs.ucla.edu>
28096         xalloc: try to pacify gcc -Wsign-compare
28097         Problem reported by Marc Nieper-Wißkirchen in:
28098         https://lists.gnu.org/r/bug-gnulib/2021-04/msg00034.html
28099         * lib/xmalloc.c (xpalloc): For odd platforms where SIZE_MAX < IDX_MAX,
28100         use a tricky destination for INT_MULTIPLY_WRAPV instead of an
28101         explicit comparison to SIZE_MAX.  This should be more likely to
28102         pacify gcc -Wsign-compare.
28104 2021-04-05  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
28106         hamt: Fix coding errors.
28107         Reported by Bruno Haible in
28108         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00047.html>
28109         after a Coverity run.
28110         * lib/hamt.c (bucket_do_while, hamt_iterator): Add missing
28111         derefencing operator and silence a bogus warning on uninitialized
28112         variables.
28113         * tests/test-hamt.c (test_general): Replace two errorneous
28114         assignment operators with comparison operators.
28116 2021-04-05  Fabrice Fontaine  <fontaine.fabrice@gmail.com>
28118         pthread-cond: Fix compilation error.
28119         * lib/pthread-cond.c (pthread_cond_wait): Use tv.nsec instead of
28120         tv.usec.
28122 2021-04-04  Fabrice Fontaine  <fontaine.fabrice@gmail.com>
28124         pthread-cond: Fix wrong configure results when <pthread.h> is absent.
28125         * m4/pthread-cond.m4 (gl_PTHREAD_COND): When <pthread.h> does not exist,
28126         set HAVE_PTHREAD_COND_* to 0, not to 1.
28128 2021-04-04  Bruno Haible  <bruno@clisp.org>
28130         backupfile, backup-rename: Trim dependencies.
28131         * lib/backupfile.h: Add comment.
28132         * lib/backupfile.c: Include <dirent.h>, for readdir() declaration.
28133         * modules/backup-rename (Depends-on): Remove dirent-safer, fcntl. Add
28134         fcntl-h.
28135         * modules/backupfile (Depends-on): Likewise. Remove xalloc. Add
28136         xalloc-die.
28138 2021-04-04  Bruno Haible  <bruno@clisp.org>
28140         doc: Fix syntax error (regression from 2021-04-02).
28141         * doc/posix-functions/strtol.texi: Put @item inside @itemize block.
28143 2021-04-04  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
28145         hamt: Document the module in the Gnulib manual.
28146         Suggested by Bruno Haible in
28147         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00026.html>.
28148         * doc/containers.texi: Add a subsection to section 15.11 Container
28149         data types.
28150         * lib/hamt.h: Improve documentation on how Hamt_entry is supposed
28151         to be used.
28153 2021-04-03  Paul Eggert  <eggert@cs.ucla.edu>
28155         savedir: avoid unlikely undefined behavior
28156         * lib/savedir.c (streamsavedir): Prefer idx_to size_t where
28157         either will do.  Simplify reallocation of entries.
28158         Use xpalloc to reallocate name_space, to avoid some unlikely
28159         integer overflows.
28161         quotearg: avoid undefined and/or O(N**2)
28162         Avoid undefined and O(N**2) behavior in some very unlikely cases.
28163         * lib/quotearg.c (quotearg_n_options): Document that N must
28164         be less than MIN (INT_MAX, IDX_MAX), and add this to the
28165         abort test; this also avoids a conditional branch.
28166         Use xpalloc instead of xrealloc, to avoid O(N**2) behavior in
28167         very-unlikely cases.
28169         xgethostname: reorganize / simplify
28170         xgethostname and xgetdomainname were essentially copies long
28171         ago, but they’ve diverged.  Bring them back together again
28172         by implementing the (rarely used) latter in terms of the former.
28173         And avoid some unnecessary realloc calls while we’re at it.
28174         * lib/xgetdomainname.c: Rewrite from scratch so that it merely
28175         includes xgethostname.c with a few preliminaries.
28176         * lib/xgethostname.c: Generalize so that it can be included
28177         from xgetdomainname.c.
28178         (GETANAME, XGETANAME): New macros.
28179         (INITIAL_HOSTNAME_LENGTH): Remove.  No need for this parameter.
28180         Use 100 instead, as few hostnames are longer than that.
28181         (XGETANAME): Try getting the hostname into the stack first,
28182         as that avoids a malloc call in the usual case.
28183         Check for both POSIX-style truncation and SunOS 5.5 bug
28184         in a cleaner way, by simply checking string length.
28185         Don’t use x2realloc, which wastes time preserving buffer garbage;
28186         use xpalloc with NULL instead.  Don’t bother shrinking buffer
28187         in the very rare case where the hostname is longer than sizeof
28188         buf; it’s not worth the aggravation.
28189         * modules/xgetdomainname (Depends-on): Remove free-posix, xalloc.
28190         Add xgethostname.
28192 2021-04-03  Bruno Haible  <bruno@clisp.org>
28194         *-list tests: Add more tests.
28195         * tests/test-array_list.c (check_equals_by_forward_iteration,
28196         check_equals_by_backward_iteration): New functions.
28197         (main): Invoke them.
28198         * tests/test-carray_list.c: Likewise.
28199         * tests/test-linked_list.c: Likewise.
28200         * tests/test-linkedhash_list.c: Likewise.
28201         * tests/test-avltree_list.c: Likewise.
28202         * tests/test-avltreehash_list.c: Likewise.
28203         * tests/test-rbtree_list.c: Likewise.
28204         * tests/test-rbtreehash_list.c: Likewise.
28206         list: Add operations first_node, last_node.
28207         Reported by Marc Nieper-Wißkirchen in
28208         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00005.html>.
28209         * lib/gl_list.h (gl_list_first_node, gl_list_last_node): New functions.
28210         (struct gl_list_implementation): Add members first_node, last_node.
28211         * lib/gl_array_list.c (gl_array_first_node, gl_array_last_node): New
28212         functions.
28213         (gl_array_list_implementation): Add the new operations.
28214         * lib/gl_carray_list.c (gl_carray_first_node, gl_carray_last_node): New
28215         functions.
28216         (gl_carray_list_implementation): Add the new operations.
28217         * lib/gl_anylinked_list2.h (gl_linked_first_node, gl_linked_last_node):
28218         New functions.
28219         * lib/gl_linked_list.c (gl_linked_list_implementation): Add the new
28220         operations.
28221         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation):
28222         Likewise.
28223         * lib/gl_anytree_list2.h (gl_tree_first_node, gl_tree_last_node): New
28224         functions.
28225         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Add the new
28226         operations.
28227         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
28228         Likewise.
28229         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Likewise.
28230         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation):
28231         Likewise.
28232         * lib/gl_sublist.c (gl_sublist_first_node, gl_sublist_last_node): New
28233         functions.
28234         (gl_sublist_list_implementation): Add the new operations.
28235         * lib/gl_list.hh (class gl_List): Add member functions first_node,
28236         last_node.
28237         * doc/containers.texi: Update table.
28239 2021-04-03  Bruno Haible  <bruno@clisp.org>
28241         xalloc-die: Fix compilation error (regression from 2021-03-28).
28242         * lib/xalloc.h: Don't include idx.h and xalloc-oversized.h if the module
28243         'xalloc' is not in use.
28244         * modules/xalloc-die (Depends-on): Remove xalloc-oversized.
28246 2020-04-03  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
28248         hamt: New module.
28249         This module provides (persistent) hash array mapped tries.
28250         * MODULES.html.sh: Add hamt.
28251         * lib/hamt.c: New file.
28252         * lib/hamt.h: New file.
28253         * modules/hamt: New file.
28254         * modules/hamt-tests: New file.
28255         * tests/test-hamt.c: New file.
28257 2021-04-02  Bruno Haible  <bruno@clisp.org>
28259         strtoul, strtoll, strtoull: Fix compilation warning.
28260         * lib/strtol.c (strtol): Undefine before defining as a macro.
28262 2021-04-02  Bruno Haible  <bruno@clisp.org>
28264         strtoll: Work around a bug on native Windows and Minix.
28265         * lib/stdlib.in.h (strtoll): Override if REPLACE_STRTOLL is 1.
28266         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_STRTOLL.
28267         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Test whether strtoll works. Set
28268         REPLACE_STRTOLL.
28269         * modules/stdlib (Makefile.am): Substitute REPLACE_STRTOLL.
28270         * modules/strtoll (configure.ac): Test REPLACE_STRTOLL.
28271         * tests/test-strtoll.c (main): Add tests of hexadecimal integer syntax.
28272         * doc/posix-functions/strtoll.texi: Mention the bug.
28274 2021-04-02  Bruno Haible  <bruno@clisp.org>
28276         strtol: Work around a bug on native Windows and Minix.
28277         * lib/stdlib.in.h (strtol): New declaration.
28278         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtol is declared.
28279         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOL, HAVE_STRTOL,
28280         REPLACE_STRTOL.
28281         * m4/strtol.m4 (gl_FUNC_STRTOL): Require gl_STDLIB_H_DEFAULTS. Test
28282         whether strtol works. Set REPLACE_STRTOL.
28283         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOL, HAVE_STRTOL,
28284         REPLACE_STRTOL.
28285         * modules/strtol (Status, Notice): Remove.
28286         (Depends-on): Add stdlib.
28287         (configure.ac): Test HAVE_STRTOL and REPLACE_STRTOL. Invoke
28288         gl_STDLIB_MODULE_INDICATOR.
28289         * tests/test-strtol.c (main): Add tests of hexadecimal integer syntax.
28290         * doc/posix-functions/strtol.texi: Mention the bug.
28292 2021-04-02  Bruno Haible  <bruno@clisp.org>
28294         strtoull: Work around a bug on native Windows and Minix.
28295         * lib/stdlib.in.h (strtoull): Override if REPLACE_STRTOULL is 1.
28296         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_STRTOULL.
28297         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Test whether strtoull works. Set
28298         REPLACE_STRTOULL.
28299         * modules/stdlib (Makefile.am): Substitute REPLACE_STRTOULL.
28300         * modules/strtoull (configure.ac): Test REPLACE_STRTOULL.
28301         * tests/test-strtoull.c (main): Add tests of hexadecimal integer syntax.
28302         * doc/posix-functions/strtoull.texi: Mention the bug.
28304 2021-04-02  Bruno Haible  <bruno@clisp.org>
28306         strtoul: Work around a bug on native Windows and Minix.
28307         Reported by Eric Blake <eblake@redhat.com> in
28308         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00082.html>.
28309         * lib/stdlib.in.h (strtoul): New declaration.
28310         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtoul is declared.
28311         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOUL, HAVE_STRTOUL,
28312         REPLACE_STRTOUL.
28313         * m4/strtoul.m4 (gl_FUNC_STRTOUL): Require gl_STDLIB_H_DEFAULTS. Test
28314         whether strtoul works. Set REPLACE_STRTOUL.
28315         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOUL, HAVE_STRTOUL,
28316         REPLACE_STRTOUL.
28317         * modules/strtoul (Status, Notice): Remove.
28318         (Depends-on): Add stdlib.
28319         (configure.ac): Test HAVE_STRTOUL and REPLACE_STRTOUL. Invoke
28320         gl_STDLIB_MODULE_INDICATOR.
28321         * tests/test-strtoul.c (main): Add tests of hexadecimal integer syntax.
28322         * doc/posix-functions/strtoul.texi: Mention the bug.
28324 2021-04-02  Bruno Haible  <bruno@clisp.org>
28326         strtol, strtoul, strtoll, strtoull: Optimize.
28327         * lib/strtol.c (GROUP_PARAM_PROTO): New macro.
28328         (INTERNAL): Define differently if !USE_NUMBER_GROUPING.
28329         (INTERNAL (strtol)): Define without 'int group' parameter if
28330         !USE_NUMBER_GROUPING.
28331         (strtol): Don't define if !USE_NUMBER_GROUPING.
28333 2021-04-02  Bruno Haible  <bruno@clisp.org>
28335         strto*l: Don't pass invalid arguments to isspace, isalnum, toupper.
28336         * lib/strtol.c (ISSPACE, ISALPHA, TOUPPER): Cast argument to
28337         'unsigned char' before passing it to the functions isspace(), isalpha(),
28338         toupper().
28340 2021-04-02  Bruno Haible  <bruno@clisp.org>
28342         glob: Reject ~user syntax, when flag GLOB_TILDE_CHECK is given.
28343         Reported and patch suggested by Eli Zaretskii <eliz@gnu.org> in
28344         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00136.html>.
28345         * lib/glob.c (__glob) [WINDOWS32]: If flag GLOB_TILDE_CHECK is given, do
28346         error handling like when ~user is allowed by the user is unknown.
28348 2021-03-31  Paul Eggert  <eggert@cs.ucla.edu>
28350         xalloc: delay setting size until success
28351         * lib/xalloc.h (x2nrealloc): Don’t change *PN until after xrealloc
28352         succeeds, in case xalloc_die or one of its callees or longjmp
28353         targets uses *PN.  Similar code in xpalloc already does this.
28355 2021-03-28  Paul Eggert  <eggert@cs.ucla.edu>
28357         xalloc: new function xpalloc, from dfa
28358         Move xpalloc from dfa.c to xmalloc.c and change it from static to
28359         extern.  The function is useful in other contexts; I’m about to
28360         use it in coreutils.
28361         * lib/dfa.c: Include idx.h, instead of rolling our own idx_t and
28362         IDX_MAX.  Do not include intprops.h; no longer needed.
28363         (xpalloc): Move from here ...
28364         * lib/xmalloc.c (xpalloc): ... to here, and make it extern.
28365         Include intprops.h and minmax.h, needed by xpalloc.
28366         * lib/xalloc.h: Include idx.h, for idx_t.
28367         * modules/dfa (Depends-on): Add idx; remove intprops.
28368         * modules/xalloc (Depends-on): Add idx, intprops, minmax.
28370 2021-03-28  Bruno Haible  <bruno@clisp.org>
28372         linked-list tests: Add another test for SIGNAL_SAFE_LIST.
28373         * tests/test-asyncsafe-linked_list-strong.c: Renamed from
28374         tests/test-asyncsafe-linked_list.c.
28375         * tests/test-asyncsafe-linked_list-strong.sh: Renamed from
28376         tests/test-asyncsafe-linked_list.sh.
28377         * tests/test-asyncsafe-linked_list-weak.c: New file, based on
28378         tests/test-asyncsafe-linked_list.c.
28379         * tests/test-asyncsafe-linked_list-weak.sh: New file, based on
28380         tests/test-asyncsafe-linked_list.sh.
28381         * modules/linked-list-tests (Files): Add
28382         tests/test-asyncsafe-linked_list-weak.*,
28383         tests/test-asyncsafe-linked_list-strong.*.
28384         (Makefile.am): Arrange to test also
28385         tests/test-asyncsafe-linked_list-weak.sh. Mark
28386         test-asyncsafe-linked_list-weak.sh and
28387         test-asyncsafe-linked_list-strong.sh as expected failures.
28389 2021-03-27  Bruno Haible  <bruno@clisp.org>
28391         renameatu tests: Add unit test for bug found on macOS.
28392         * tests/test-renameatu.c (main): Add test for identical rename with
28393         RENAME_NOREPLACE.
28395 2021-03-26  Bruno Haible  <bruno@clisp.org>
28397         unistdio/*-vasnprintf: Fix errno value (regression from yesterday).
28398         * modules/unistdio/u8-vasnprintf (Depends-on): Add free-posix.
28399         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
28400         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
28401         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
28402         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
28403         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
28404         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
28406 2021-03-26  Bruno Haible  <bruno@clisp.org>
28408         vasnprintf: Fix memory leak (regression from yesterday).
28409         * lib/vasnprintf.c (VASNPRINTF): Restore omitted CLEANUP invocation.
28410         Some more simplifications of errno around free().
28412 2021-03-26  Akim Demaille  <akim@lrde.epita.fr>
28414         fprintf-posix: fix typo
28415         * modules/fprintf-posix (Depends-on): Fix typo.
28417 2021-03-25  Paul Eggert  <eggert@cs.ucla.edu>
28419         free-posix: use more often in other modules
28420         This lets us simplify cleanup code that calls ‘free’.
28421         * lib/amemxfrm.c (amemxfrm):
28422         * lib/areadlink-with-size.c (areadlink_with_size):
28423         * lib/areadlinkat-with-size.c (areadlinkat_with_size):
28424         * lib/astrxfrm.c (astrxfrm):
28425         * lib/dprintf.c (dprintf):
28426         * lib/execute.c (execute):
28427         * lib/execvpe.c (execvpe):
28428         * lib/fchdir.c (get_name):
28429         * lib/file-has-acl.c (file_has_acl):
28430         * lib/fprintf.c (fprintf):
28431         * lib/getcwd-lgpl.c (rpl_getcwd):
28432         * lib/getgroups.c (rpl_getgroups):
28433         * lib/link.c (link, rpl_link):
28434         * lib/linkat.c (link_immediate, link_follow, linkat_follow):
28435         * lib/localename.c (newlocale, duplocale):
28436         * lib/mgetgroups.c (mgetgroups):
28437         * lib/mountlist.c (read_file_system_list):
28438         * lib/pipe-filter-gi.c (pipe_filter_gi_close):
28439         * lib/putenv.c (_unsetenv, putenv):
28440         * lib/read-file.c (read_file):
28441         * lib/rename.c (rpl_rename):
28442         * lib/savedir.c (streamsavedir, savedir):
28443         * lib/spawni.c (do_open, __spawni):
28444         * lib/spawn-pipe.c (create_pipe):
28445         * lib/striconv.c (mem_cd_iconv, str_cd_iconv, str_iconv):
28446         * lib/striconveh.c (mem_cd_iconveh_internal, str_cd_iconveh)
28447         (mem_iconveh, str_iconveh):
28448         * lib/supersede.c (open_supersede, close_supersede):
28449         * lib/vasnprintf.c (VASNPRINTF):
28450         * lib/vdprintf.c (vdprintf):
28451         * lib/vfprintf.c (vfprintf):
28452         * lib/wcscoll-impl.h (wcscoll):
28453         * lib/wcsxfrm-impl.h (wcsxfrm):
28454         * lib/xgetdomainname.c (xgetdomainname):
28455         * lib/xgethostname.c (xgethostname):
28456         Simplify by assuming that ‘free’ preserves errno.
28457         * lib/localename.c: Do not include errno.h.
28458         * modules/amemxfrm, modules/areadlink-with-size:
28459         * modules/areadlinkat-with-size, modules/astrxfrm:
28460         * modules/c-vasnprintf, modules/dprintf, modules/execute:
28461         * modules/execvpe, modules/fchdir, modules/file-has-acl:
28462         * modules/fprintf-posix, modules/getcwd-lgpl, modules/getgroups:
28463         * modules/link, modules/linkat, modules/localename:
28464         * modules/mgetgroups, modules/mountlist, modules/pipe-filter-gi:
28465         * modules/posix_spawn-internal, modules/putenv, modules/read-file:
28466         * modules/rename, modules/savedir, modules/spawn-pipe:
28467         * modules/striconv, modules/striconveh, modules/supersede:
28468         * modules/vasnprintf, modules/vdprintf, modules/vfprintf-posix:
28469         * modules/wcscoll, modules/wcsxfrm, modules/xgetdomainname:
28470         * modules/xgethostname:
28471         Depend on free-posix.
28473 2021-03-24  Paul Eggert  <eggert@cs.ucla.edu>
28475         renameatu: work around macOS 11.2 renameatx_np bug
28476         * lib/renameatu.c (renameatu) [RENAME_EXCL]: Use lstatat test here too.
28478 2021-03-22  Bruno Haible  <bruno@clisp.org>
28480         clean-temp-simple: Fix a rare memory leak.
28481         * lib/clean-temp-simple.c (register_temporary_file): Fix cleanup code.
28483 2021-03-22  Bruno Haible  <bruno@clisp.org>
28485         clean-temp-simple: Relicense under LGPLv2+.
28486         * modules/clean-temp-simple (License): Change to LGPLv2+.
28488 2021-03-22  Bruno Haible  <bruno@clisp.org>
28490         clean-temp-simple: Remove dependency upon xalloc, xalloc-die, xlist.
28491         * lib/clean-temp-private.h (clean_temp_init): Change return type to
28492         'int'.
28493         * lib/clean-temp-simple.h (register_temporary_file): Change return type
28494         to 'int'.
28495         * lib/clean-temp-simple.c: Don't include xalloc.h, gl_xlist.h. Include
28496         gl_list.h instead.
28497         (init_failed): New variable.
28498         (do_clean_temp_init): Set it.
28499         (clean_temp_init): Return an error indicator.
28500         (register_temporary_file): Invoke gl_list_nx_create_empty instead of
28501         gl_list_create_empty. Invoke strdup instead of xstrdup. Invoke
28502         gl_list_nx_add_first instead of gl_list_add_first. Return an error
28503         indicator.
28504         * lib/clean-temp.c (create_temp_dir, gen_register_open_temp): Call
28505         xalloc_die() if clean_temp_init or register_temporary_file failed.
28506         * modules/clean-temp-simple (Depends-on): Remove xalloc, xalloc-die,
28507         xlist.
28509 2021-03-22  Bruno Haible  <bruno@clisp.org>
28511         clean-temp-simple: New module.
28512         * lib/clean-temp-simple.h: New file, based on lib/clean-temp.h.
28513         * lib/clean-temp-private.h: New file, based on lib/clean-temp.c.
28514         * lib/clean-temp-simple.c: New file, based on lib/clean-temp.c.
28515         * lib/clean-temp.h: Include clean-temp-simple.h.
28516         (register_temporary_file, unregister_temporary_file,
28517         cleanup_temporary_file): Remove declarations.
28518         * lib/clean-temp.c: Don't include <limits.h>, <stdint.h>. Include
28519         <signal.h>, <stdio.h>, clean-temp-simple.h, clean-temp-private.h.
28520         (file_cleanup_list_lock, file_cleanup_list): Moved to
28521         clean-temp-simple.c.
28522         (struct tempdir, dir_cleanup_list, struct closeable_fd, descriptors):
28523         Moved to clean-temp-private.h.
28524         (string_equals, SIZE_BITS, string_hash, fatal_signal_set,
28525         init_fatal_signal_set, asyncsafe_close): Moved to clean-temp-simple.c.
28526         (asyncsafe_fclose_variant): Use get_fatal_signal_set() here.
28527         (cleanup_action, do_init_clean_temp, clean_temp_once, init_clean_temp,
28528         register_temporary_file, unregister_temporary_file, do_unlink,
28529         cleanup_temporary_file): Moved to clean-temp-simple.c.
28530         (create_temp_dir, cleanup_temp_file, cleanup_temp_dir_contents,
28531         gen_register_open_temp, close_temp): Update for changed function names.
28532         (fclose_variant_temp): Don't call init_fatal_signal_set().
28533         * modules/clean-temp-simple: New file, based on modules/clean-temp.
28534         * modules/clean-temp (Depends-on): Add clean-temp-simple, list. Remove
28535         stdint.
28536         (configure.ac): Don't define SIGNAL_SAFE_LIST here.
28538 2021-03-22  Bruno Haible  <bruno@clisp.org>
28540         error: Relicense under LGPLv2+.
28541         Pino Toscano's approval is in
28542         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00109.html>.
28543         Paul Eggert's approval is in
28544         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00110.html>.
28545         * modules/error (License): Change to LGPLv2+.
28547 2021-03-22  Bruno Haible  <bruno@clisp.org>
28549         getprogname: Relicense under LGPLv2+.
28550         Pino Toscano's approval is in
28551         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00109.html>.
28552         Paul Eggert's approval is in
28553         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00110.html>.
28554         Jim Meyering's approval is in
28555         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00107.html>.
28556         Gisle Vanem's approval is in
28557         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00115.html>.
28558         Daniel Richard G's approval is in
28559         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00112.html>.
28560         John David Anglin's approval is in
28561         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00108.html>.
28562         Benji Wiebe's approval is in
28563         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00114.html>.
28564         * modules/getprogname (License): Change to LGPLv2+.
28566 2021-03-22  Bruno Haible  <bruno@clisp.org>
28568         fatal-signal: Relicense under LGPLv2+.
28569         Eric Blake's approval is in
28570         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00111.html>.
28571         * modules/fatal-signal (License): Change to LGPLv2+.
28573 2021-03-22  Bruno Haible  <bruno@clisp.org>
28575         doc: Mention an open glibc bug.
28576         * doc/posix-functions/mbrtowc.texi: Mention the possible out-of-range
28577         wchar_t values returned by this function on glibc.
28578         * doc/posix-functions/mbtowc.texi: Likewise.
28580 2021-03-22  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
28582         mbrtowc: Remove a redundant condition.
28583         * lib/mbrtowc-impl-utf8.h: There is no need to check for c == 0xf4
28584         when !(c < 0xf4), as ten lines earlier c <= 0xf4 was established.
28586 2021-03-22  Bruno Haible  <bruno@clisp.org>
28588         linkedhash-list: Relicense under LGPLv2+.
28589         Paul Eggert's approval is in
28590         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00102.html>.
28591         * modules/linkedhash-list (License): Change to LGPLv2+.
28593 2021-03-21  Bruno Haible  <bruno@clisp.org>
28595         fatal-signal: Remove dependency upon xalloc.
28596         * lib/fatal-signal.h (at_fatal_signal): Change return type to 'int'.
28597         * lib/fatal-signal.c: Don't include xalloc.h.
28598         (at_fatal_signal): Return an error indicator.
28599         * modules/fatal-signal (Depends-on): Remove xalloc.
28600         * NEWS: Mention the change.
28601         * lib/term-style-control.c: Include xalloc.h.
28602         (ensure_other_signal_handlers): Test return value of at_fatal_signal.
28603         * lib/clean-temp.c (do_init_clean_temp): Likewise.
28604         * lib/wait-process.c (register_slave_subprocess): Likewise.
28605         * modules/term-style-control (Depends-on): Add xalloc-die.
28606         * modules/clean-temp (Depends-on): Likewise.
28607         * modules/wait-process (Depends-on): Likewise.
28609 2021-03-21  Paul Eggert  <eggert@cs.ucla.edu>
28611         diacrit: remove
28612         * MODULES.html.sh (func_all_modules), NEWS: Remove diacrit.
28613         * lib/diacrit.c, lib/diacrit.h, modules/diacrit: Remove.
28615         tests: fix signed overflow issues
28616         * tests/test-dynarray.c (value_at): Avoid undefined behavior
28617         in signed integer multiplication.
28618         * tests/test-scratch-buffer.c (byte_at): Likewise, for the
28619         theoretically-possible case where size_t is narrower than int.
28621 2021-03-21  Bruno Haible  <bruno@clisp.org>
28623         doc: More updates.
28624         * doc/glibc-functions/sethostname.texi: Update regarding macOS.
28625         * doc/glibc-functions/sethostname.texi: List the affected platforms.
28627         doc: Update for macOS 11.1.
28628         * doc/posix-headers/*.texi: Update.
28629         * doc/glibc-headers/*.texi: Update.
28630         * doc/posix-functions/*.texi: Likewise.
28631         * doc/pastposix-functions/*.texi: Likewise.
28632         * doc/glibc-functions/*.texi: Likewise.
28633         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Update cross-compilation
28634         guess.
28636 2021-03-21  Bruno Haible  <bruno@clisp.org>
28638         ftell: Document bug in macOS >= 10.15.
28639         * doc/posix-functions/ftell.texi: Mention the macOS bug.
28641 2021-03-20  Bruno Haible  <bruno@clisp.org>
28643         ftello: Work around bug in macOS >= 10.15.
28644         Reported by Martin Storsjö <martin@martin.st> in
28645         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00002.html>.
28646         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): On macOS, don't define
28647         FUNC_UNGETC_BROKEN. Instead, set gl_ftello_broken_after_ungetc to yes.
28648         * m4/ftello.m4 (gl_FUNC_FTELLO): Invoke gl_FUNC_UNGETC_WORKS, and
28649         arrange to provide the workaround if ftello is broken after ungetc.
28650         * lib/ftello.c: Include <errno.h>, intprops.h.
28651         (ftello) [FTELLO_BROKEN_AFTER_UNGETC]: Implement from scratch.
28652         * modules/ftello (Files): Add m4/ungetc.m4.
28653         (Depends-on): Add intprops.
28654         * doc/posix-functions/ftello.texi: Mention the macOS bug.
28656 2021-03-20  Bruno Haible  <bruno@clisp.org>
28658         math C++ tests: Fix compilation error on macOS 11.2.
28659         * lib/math.in.h (isnan): For clang >= 12 on macOS, declare 'rpl_isnan',
28660         not 'isnan'.
28662 2021-03-18  Bruno Haible  <bruno@clisp.org>
28664         simple-atomic tests: Fix compilation error on Solaris 10.
28665         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
28666         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00085.html>.
28667         * tests/test-simple-atomic.c (yield): Define only after all #includes.
28669 2021-03-18  Bruno Haible  <bruno@clisp.org>
28671         simple-atomic: Fix compilation error on Solaris 10/x86_64 with cc.
28672         * lib/simple-atomic.c (atomic_compare_and_swap_ptr): Correct asm
28673         instruction.
28675 2021-03-18  Paul Eggert  <eggert@cs.ucla.edu>
28677         argmatch: fix testing typo
28678         Problem and fix reported by Gisle Vanem in:
28679         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00083.html
28680         * lib/argmatch.c (main) [TEST]: Fix address-of typo.
28682 2021-03-14  Paul Eggert  <eggert@cs.ucla.edu>
28684         intprops: improve commentary
28685         * lib/intprops.h: Improve comments about promotion etc.
28687 2021-03-14  Bruno Haible  <bruno@clisp.org>
28689         time_rz: Put reference documentation into the .h file.
28690         * lib/time.in.h (timezone_t, tzalloc, tzfree, localtime_rz, mktime_z):
28691         Add comments, based on modules/time_rz.
28692         * modules/time_rz (Comment): Remove section.
28694 2021-03-14  Bruno Haible  <bruno@clisp.org>
28696         parse-datetime tests: Avoid a test failure on NetBSD.
28697         Reported by Thomas Klausner <tk@giga.or.at> in
28698         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00069.html>.
28699         * tests/test-parse-datetime.c (main): Skip two tests on NetBSD.
28701 2021-03-10  Paul Eggert  <eggert@cs.ucla.edu>
28703         libc-config: port to DragonFlyBSD 5.9
28704         DragonFlyBSD defines __nonnull incompatibly with glibc,
28705         so avoid the use of __nonnull in Gnulib code.
28706         Problem reported by Gavin Smith in:
28707         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00066.html
28708         * lib/cdefs.h (__attribute_nonnull__): Rename from __nonnull.
28709         All uses in Gnulib changed.  There should be no need to change
28710         glibc code that is not shared with Gnulib.
28711         (__nonnull): New macro, defined in terms of __attribute_nonnull__,
28712         and which can be used in glibc code that is not shared with Gnulib.
28714 2021-03-07  Paul Eggert  <eggert@cs.ucla.edu>
28716         manywarnings: modernize documentation
28717         Problem reported by Reuben Thomas in:
28718         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00046.html
28719         * doc/manywarnings.texi (manywarnings): Update in
28720         the light of recent changes to the manywarnings module.
28722 2021-03-07  Bruno Haible  <bruno@clisp.org>
28724         sysexits: Fix for Haiku.
28725         * lib/sysexits.in.h: Don't assume that <sysexits.h>, when it exists,
28726         defines anything.
28727         * doc/glibc-headers/sysexits.texi: Mention the Haiku bug.
28729 2021-03-07  Bruno Haible  <bruno@clisp.org>
28731         Rename GNULIB_WCHAR_SINGLE to GNULIB_WCHAR_SINGLE_LOCALE.
28732         * lib/lc-charset-dispatch.c: Test GNULIB_WCHAR_SINGLE_LOCALE instead of
28733         GNULIB_WCHAR_SINGLE.
28734         * lib/wcwidth.c: Likewise.
28735         * tests/test-wcwidth.c: Likewise.
28736         * doc/multithread.texi: Document GNULIB_WCHAR_SINGLE_LOCALE instead of
28737         GNULIB_WCHAR_SINGLE.
28738         * NEWS: Document the change.
28740 2021-03-06  Bruno Haible  <bruno@clisp.org>
28742         mbrtowc: Allow locking optimization independently of 'unlocked-io'.
28743         * lib/mbtowc-lock.h: Test GNULIB_MBRTOWC_SINGLE_THREAD instead of
28744         USE_UNLOCKED_IO.
28745         * doc/multithread.texi: Document GNULIB_MBRTOWC_SINGLE_THREAD.
28747 2021-03-06  Bruno Haible  <bruno@clisp.org>
28749         regex: Allow locking optimization independently of 'unlocked-io'.
28750         * lib/regex_internal.h: Test GNULIB_REGEX_SINGLE_THREAD instead of
28751         USE_UNLOCKED_IO.
28752         * doc/multithread.texi: Document GNULIB_REGEX_SINGLE_THREAD.
28754 2021-03-06  Bruno Haible  <bruno@clisp.org>
28756         exclude: Allow stdio optimization independently of 'unlocked-io'.
28757         * lib/exclude.c: Test GNULIB_EXCLUDE_SINGLE_THREAD instead of
28758         USE_UNLOCKED_IO.
28759         * modules/exclude (Depends-on): Add unlocked-io-internal.
28760         * doc/multithread.texi: Document GNULIB_EXCLUDE_SINGLE_THREAD.
28762 2021-03-06  Bruno Haible  <bruno@clisp.org>
28764         readutmp: Optimize stdio accesses.
28765         * lib/readutmp.c: Include unlocked-io.h unconditionally.
28766         * modules/readutmp (Depends-on): Add unlocked-io-internal.
28768 2021-03-06  Bruno Haible  <bruno@clisp.org>
28770         mountlist: Optimize stdio accesses.
28771         * lib/mountlist.c: Include unlocked-io.h unconditionally.
28772         * modules/mountlist (Depends-on): Add unlocked-io-internal.
28774 2021-03-06  Bruno Haible  <bruno@clisp.org>
28776         getusershell: Optimize stdio accesses when possible.
28777         * lib/getusershell.c: Test GNULIB_GETUSERSHELL_SINGLE_THREAD instead of
28778         USE_UNLOCKED_IO.
28779         * modules/getusershell (Depends-on): Add unlocked-io-internal.
28780         * doc/multithread.texi: Document GNULIB_GETUSERSHELL_SINGLE_THREAD.
28782 2021-03-06  Bruno Haible  <bruno@clisp.org>
28784         unlocked-io-internal: New module.
28785         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Don't define
28786         USE_UNLOCKED_IO here.
28787         * modules/unlocked-io-internal: New file, based on modules/unlocked-io.
28788         * modules/unlocked-io (Description): Clarify.
28789         (Files, Depends-on): Just use the unlocked-io-internal module.
28790         (configure.ac): Define GNULIB_STDIO_SINGLE_THREAD and USE_UNLOCKED_IO
28791         here.
28792         * doc/multithread.texi: Clarify when the 'unlocked-io' module can be
28793         used.
28795 2021-03-06  Bruno Haible  <bruno@clisp.org>
28797         posixtm: Remove unused includes.
28798         * lib/posixtm.c: Don't include <stdio.h>, <sys/types.h>, unlocked-io.h.
28800 2021-03-06  Bruno Haible  <bruno@clisp.org>
28802         dynarray: Add tests.
28803         * tests/test-dynarray.c: New file.
28804         * modules/dynarray-tests: New file.
28806         dynarray: Make the module usable on its own.
28807         * lib/dynarray.h: Document the exported API. Comments taken from
28808         lib/malloc/dynarray-skeleton.c and lib/malloc/dynarray.h.
28809         Distinguish an internal include from an include for instantiation.
28810         In the latter case, include <libc-config.h> and
28811         <malloc/dynarray-skeleton.c>.
28812         * modules/dynarray (Depends-on): Add intprops.
28813         (Include): Reduce to just "dynarray.h".
28815 2021-03-06  Bruno Haible  <bruno@clisp.org>
28817         scratch_buffer: Add comment.
28818         * lib/scratch_buffer.h: Add comment.
28820 2021-03-06  Paul Eggert  <eggert@cs.ucla.edu>
28822         parse-datetime2: fix licensing
28823         Problem reported by Bruno Haible in:
28824         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00017.html
28825         * gnulib-tool (func_get_license): Treat parse-datetime2
28826         (actually, anything starting with "parse-datetime")
28827         like parse-datetime, as far as licenses go.
28829 2021-03-06  Bruno Haible  <bruno@clisp.org>
28831         free-posix: Update documentation.
28832         * doc/posix-functions/free.texi: Add platform details.
28834 2021-03-06  Bruno Haible  <bruno@clisp.org>
28836         doc: Update for glibc 2.33.
28837         * doc/glibc-functions/mallinfo2.texi: New file.
28838         * doc/gnulib.texi: Include it.
28839         (Glibc sys/vtimes.h): Remove section.
28840         * doc/glibc-functions/vtimes.texi: Remove file.
28841         * doc/pastposix-functions/h_errno.texi: Update.
28842         * doc/posix-functions/*.texi: Likewise.
28843         * doc/glibc-functions/*.texi: Likewise.
28845 2021-03-04  Bruno Haible  <bruno@clisp.org>
28847         stddef: Generalize tcc workaround to other compilers.
28848         Suggested by Paul Eggert in
28849         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00027.html>.
28850         * lib/stddef.in.h: Undefine the __need_* macros with all compilers.
28851         * doc/posix-headers/stddef.texi: Mention that the TinyCC bug also exists
28852         on macOS.
28854 2021-03-04  Paul Eggert  <eggert@cs.ucla.edu>
28856         stdalign: port to tcc + glibc
28857         * lib/stdalign.in.h (_Alignas): Do not define using __attribute__
28858         if __attribute__ is defined as a macro, as __attribute__ surely a
28859         no-op in that case and this is an area where __attribute__ cannot
28860         simply be ignored.
28861         * m4/stdalign.m4 (gl_STDALIGN_H): Include <stdint.h> so that
28862         it #defines __attribute__(x) to nothing on glibc-based systems
28863         when non-GNU-C-compatible compilers are used.
28864         This exposes a bug in Tiny C Compiler 0.9.27’s implementation
28865         of _Alignas on glibc platforms.
28867 2021-03-03  Bruno Haible  <bruno@clisp.org>
28869         asyncsafe-spin, simple-atomic: Add support for tcc/x86.
28870         * lib/asyncsafe-spin.c (memory_barrier): With tcc/x86, don't use the
28871         'mfence' instruction.
28872         * lib/simple-atomic.c (memory_barrier): Likewise.
28874         asyncsafe-spin, simple-atomic: Add support for tcc.
28875         * lib/asyncsafe-spin.c (memory_barrier, atomic_compare_and_swap): On
28876         i386 and x86_64, treat tcc like older GCC or clang.
28877         * lib/simple-atomic.c (memory_barrier, atomic_compare_and_swap,
28878         atomic_compare_and_swap_ptr): Likewise.
28880 2021-03-02  Bruno Haible  <bruno@clisp.org>
28882         stddef: Work around an interoperability problem of tcc with glibc.
28883         Reported by Luca Saiu <positron@gnu.org> in
28884         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00011.html>.
28885         * lib/stddef.in.h [__TINYC__]: In case of the special invocation
28886         convention, undefine the macros that TinyCC's <stddef.h> should undefine
28887         but doesn't.
28888         * doc/posix-headers/stddef.texi: Mention the TinyCC bug.
28890 2021-03-02  Paul Eggert  <eggert@cs.ucla.edu>
28892         mbrtowc: port to AIX 7.1 with xlc 12.1
28893         Fix a problem with locks when building GNU Tar (Savannah commit
28894         55f2a0772e08b9febac3ac0de5cb048d4c60d2f5) on AIX 7.1 with IBM XL
28895         C/C++ V12.1 using ‘./configure CC=xlc’.  The link fails due to
28896         missing definitions of pthread_mutex_lock and
28897         pthread_mutex_unlock.  GNU Tar uses unlocked-io and so
28898         should not need to worry about multithreading or locks.
28899         * lib/mbtowc-lock.h (mbtowc_with_lock) [USE_UNLOCKED_IO]:
28900         Don’t bother with locks, since this app is single-threaded.
28901         There may be similar linking problems with lib/nl_langinfo.c and
28902         lib/setlocale_null.c but my GNU Tar build didn’t run into them, so
28903         I left them alone for now.
28905 2021-03-01  Paul Eggert  <eggert@cs.ucla.edu>
28907         unlocked-io: do not redefine getc_unlocked etc.
28908         I ran into this problem on AIX 7.1 with GNU Tar, which
28909         enables visibility of getc_unlocked etc. after testing
28910         whether they’re declared, causing argp-namefrob.h and
28911         unlocked-io.h to redefine the macros.
28912         * lib/argp-namefrob.h, lib/unlocked-io.h:
28913         (clearerr_unlocked, feof_unlocked ferror_unlocked)
28914         (fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked)
28915         (fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked)
28916         (putc_unlocked, putchar_unlocked): Do not define if already defined.
28918         parse-datetime2: new module
28919         This splits the old parse-datetime into two parts; the
28920         first is parse-datetime2 which supports all the new bells
28921         and whistles, the second is parse-datetime, which reverts to
28922         its original intent.  This avoids some bogus diagnostics
28923         when build GNU Tar with gcc -flto -fanalyze and
28924         with --enable-gcc-warnings.  And it slims down the
28925         executable a bit.
28926         * NEWS: Mention this.
28927         * lib/parse-datetime.y (parser_control) [!GNULIB_PARSE_DATETIME2]:
28928         Omit parse_datetime_debug member.
28929         (debugging): New function.  Use it everywhere the old code
28930         would load parse_datetime_debug.
28931         (parse_datetime_body): New static function, with the body
28932         of the old parse_datetime2.  Set pc.parse_datetime_debug
28933         only if GNULIB_PARSE_DATETIME2.
28934         (parse_datetime2, parse_datetime): Use this new function.
28935         (parse_datetime2) [!GNULIB_PARSE_DATETIME2]: Remove.
28936         * modules/parse-datetime2: New file.
28938 2021-02-27  Bruno Haible  <bruno@clisp.org>
28940         string-buffer: Fixes.
28941         * modules/string-buffer (License): Change to LGPL.
28942         * tests/test-string-buffer.c (main): Add another sb_appendf call, that
28943         is more likely to fail.
28945 2021-02-25  Bernhard Voelker  <mail@bernhard-voelker.de>
28947         gitlog-to-changelog: output SHA in "empty commit message" warning
28948         * build-aux/gitlog-to-changelog: Add $sha to above warning diagnostic.
28950 2021-02-24  Paul Eggert  <eggert@cs.ucla.edu>
28952         glob: include libc-config.h in a more-standard way
28953         Inspired by Tom Tromey’s report for RHEL 6 in:
28954         https://lists.gnu.org/r/bug-gnulib/2021-02/msg00088.html
28955         * lib/glob.c [!_LIBC]: Include libc-config.h, not just config.h
28956         * lib/glob.in.h: Include libc-config.h only if needed.
28958 2021-02-21  Bruno Haible  <bruno@clisp.org>
28960         string-buffer: Add tests.
28961         * tests/test-string-buffer.c: New file.
28962         * modules/string-buffer-tests: New file.
28964         string-buffer: New module.
28965         * lib/string-buffer.h: New file.
28966         * lib/string-buffer.c: New file.
28967         * modules/string-buffer: New file.
28968         * doc/posix-functions/open_memstream.texi: Mention the new module.
28970 2021-02-21  Bruno Haible  <bruno@clisp.org>
28972         scratch_buffer: Document the exported API.
28973         * lib/scratch_buffer.h: Add comments, taken from
28974         lib/malloc/scratch_buffer.h.
28976 2021-02-21  Bruno Haible  <bruno@clisp.org>
28978         DEPENDENCIES: Update.
28979         * DEPENDENCIES: Require GCC >= 3.1. Tell where to find working GNU m4
28980         tarballs. Mention awk. Point to pre-built packages for gettext, bison,
28981         gperf, texinfo.
28983 2021-02-20  Bruno Haible  <bruno@clisp.org>
28985         parse-datetime: Fix comment.
28986         * modules/parse-datetime (Makefile.am): Fix comment.
28988 2021-02-16  Bruno Haible  <bruno@clisp.org>
28990         passfd: Fix test failure on FreeBSD >= 12 and NetBSD in 64-bit mode.
28991         * lib/passfd.c (recvfd): Use the CMSG_SPACE macro to compute the value
28992         for msg_controllen.
28994 2021-02-16  Paul Eggert  <eggert@cs.ucla.edu>
28996         Port better to macOS Mojave
28997         Problem reported by Tom Shields in:
28998         https://lists.gnu.org/r/bug-gnulib/2021-02/msg00064.html
28999         * config/srclist.txt: Comment out dynarray_finalize.c.
29000         * lib/dynarray.h (__libc_dynarray_at_failure): Don’t include
29001         libc-config.h here, as that’s the includer’s responsibility.
29002         * lib/malloc/dynarray_at_failure.c:
29003         * lib/malloc/dynarray_emplace_enlarge.c:
29004         * lib/malloc/dynarray_finalize.c:
29005         * lib/malloc/dynarray_resize.c:
29006         * lib/malloc/dynarray_resize_clear.c:
29007         If _LIBC is not defined, include libc-config.h.
29009 2021-02-15  Bruno Haible  <bruno@clisp.org>
29011         linked-list test: Add test for SIGNAL_SAFE_LIST. (It currently fails.)
29012         * tests/test-asyncsafe-linked_list.sh: New file.
29013         * tests/test-asyncsafe-linked_list.c: New file.
29014         * modules/linked-list-tests (Files): Add them.
29015         (Depends-on): Add thread, yield, nanosleep, sigaction, sigprocmask.
29016         (Makefile.am): Arrange to compile test-asyncsafe-linked_list.c and run
29017         test-asyncsafe-linked_list.sh.
29019 2021-02-14  Bruno Haible  <bruno@clisp.org>
29021         simple-atomic: Add tests.
29022         * tests/test-simple-atomic.c: New file.
29023         * modules/simple-atomic-tests: New file.
29025         simple-atomic: New module.
29026         * lib/simple-atomic.h: New file.
29027         * lib/simple-atomic.c: New file, based on lib/asyncsafe-spin.c.
29028         * modules/simple-atomic: New file.
29030 2021-02-14  Bruno Haible  <bruno@clisp.org>
29032         Fix distinction of 32-bit/64-bit mode with xlc 13.1.3 on AIX.
29033         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI, gl_HOST_CPU_C_ABI_32BIT):
29034         Test __LP64__ instead of _ARCH_PPC64.
29035         * m4/lib-ld.m4 (AC_LIB_PROG_LD): Likewise.
29036         * lib/stddef.in.h: Likewise.
29038 2021-02-13  Ozkan Sezer  <sezeroz@gmail.com>
29040         lib-symbol-visibility: Make it work with -Wmissing-prototypes.
29041         * m4/visibility.m4 (gl_VISIBILITY): Avoid error from simultaneous use of
29042         -Wmissing-prototypes and -Werror.
29044 2021-02-08  Bruno Haible  <bruno@clisp.org>
29046         stddef: Fix test-stddef compilation error on MidnightBSD/x86.
29047         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS, rpl_max_align_t, max_align_t):
29048         Don't ignore HAVE_MAX_ALIGN_T if the compiler is clang.
29050 2021-02-08  Bruno Haible  <bruno@clisp.org>
29052         Document non-standard prototypes on MidnightBSD.
29053         * doc/posix-functions/initstate.texi: Mention different prototype on
29054         MidnightBSD 2.0.
29055         * doc/posix-functions/srandom.texi: Likewise.
29056         * doc/posix-functions/getlogin_r.texi: Likewise.
29057         * doc/glibc-functions/sethostname.texi: Likewise.
29059 2021-02-08  Bruno Haible  <bruno@clisp.org>
29061         posixtm tests: Fix warnings seen on MidnightBSD/x86.
29062         * tests/test-posixtm.c (main): Convert two 'time_t' values to 'long' for
29063         printing.
29065 2021-02-07  Bruno Haible  <bruno@clisp.org>
29067         Add cross-compilation guesses for MidnightBSD.
29068         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): When cross-compiling, use the
29069         result from native compilation.
29070         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
29071         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Likewise.
29072         * m4/mprotect.m4 (gl_FUNC_MPROTECT_WORKS): Likewise.
29073         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_SECURE): Likewise.
29074         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_INFINITE,
29075         gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_F,
29076         gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
29077         gl_SNPRINTF_DIRECTIVE_N, gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
29078         * m4/strfmon_l.m4 (gl_FUNC_STRFMON_L): Likewise.
29079         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Use predetermined
29080         result on MidnightBSD.
29082 2021-02-07  Bruno Haible  <bruno@clisp.org>
29084         threadlib: Add support for MidnightBSD.
29085         * m4/threadlib.m4 (gl_WEAK_SYMBOLS, gl_THREADLIB_BODY): On MidnightBSD,
29086         use the same test as on FreeBSD.
29088 2021-02-07  Bruno Haible  <bruno@clisp.org>
29090         host-os: Add support for MidnightBSD.
29091         * m4/host-os.m4 (gl_HOST_OS): On MidnightBSD, set HOST_OPERATING_SYSTEM
29092         to "MidnightBSD", not "Midnightbsd".
29094 2021-02-07  Bruno Haible  <bruno@clisp.org>
29096         c-stack: Adjust for MidnightBSD.
29097         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): On MidnightBSD,
29098         set FAULT_YIELDS_SIGBUS.
29100 2021-02-07  Bruno Haible  <bruno@clisp.org>
29102         relocatable-prog: Add support for MidnightBSD.
29103         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Use the ELF $ORIGIN trick
29104         also on MidnightBSD >= 1.1.
29105         * build-aux/config.libpath: Treat MidnightBSD like FreeBSD.
29106         * build-aux/reloc-ldflags: Likewise.
29108 2021-02-07  Bruno Haible  <bruno@clisp.org>
29110         havelib: Add support for MidnightBSD.
29111         * build-aux/config.rpath: Treat MidnightBSD like FreeBSD >= 4.
29113 2021-02-07  Bruno Haible  <bruno@clisp.org>
29115         wcwidth: Document MidnightBSD bug.
29116         * doc/posix-functions/wcwidth.texi: Mention MidnightBSD as an affected
29117         platform.
29118         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Update comments.
29120 2021-02-07  Bruno Haible  <bruno@clisp.org>
29122         pthread_sigmask: Document MidnightBSD bug.
29123         * doc/posix-functions/pthread_sigmask.texi: Mention MidnightBSD as an
29124         affected platform.
29125         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Update
29126         cross-compilation guess accordingly.
29128 2021-02-07  Bruno Haible  <bruno@clisp.org>
29130         immutable: Avoid test failures on MidnightBSD.
29131         * tests/test-immutable.c (install_segv_handler): On FreeBSD, install the
29132         handler also for SIGBUS.
29134 2021-02-07  Bruno Haible  <bruno@clisp.org>
29136         c32is*: Avoid test failures on MidnightBSD.
29137         * tests/test-c32isalnum.c (main): On FreeBSD, disable tests that fail on
29138         MidnightBSD 1.1.
29139         * tests/test-c32isalpha.c (main): Likewise.
29140         * tests/test-c32isblank.c (main): Likewise.
29141         * tests/test-c32islower.c (main): Likewise.
29142         * tests/test-c32isupper.c (main): Likewise.
29144 2021-02-05  Paul Eggert  <eggert@cs.ucla.edu>
29146         regex: fix comment location
29147         * lib/regexec.c (update_regs): Move comment.
29149         regex-tests: add bug 11053 test
29150         * tests/test-regex.c (main): New test case for glibc bug 11053.
29152         regex: debug check for set member duplicates
29153         * lib/regex_internal.c (re_node_set_insert): Add a DEBUG_ASSERT
29154         that would have caught some recently-fixed performance bugs
29155         that caused sets to contain duplicate members.
29157         regex: fix longstanding backref match bug
29158         This fixes a longstanding glibc bug concerning backreferences
29159         <https://sourceware.org/11053> (2009-12-04).
29160         * lib/regexec.c (proceed_next_node, push_fail_stack)
29161         (pop_fail_stack): Push and pop the previous registers
29162         as well as the current ones.  All callers changed.
29163         (set_regs): Also pop if CUR_NODE has already been checked,
29164         so that it does not get added as a duplicate set entry.
29165         (update_regs): Fix comment location.
29166         * tests/test-regex.c (tests): New constant.
29167         (bug_regex11): New test function.
29168         (main): Bump alarm value.  Call new test function.
29170         regex: avoid duplicate in espilon closure
29171         * lib/regcomp.c (calc_eclosure_iter): Insert NODE into epsilon
29172         closure first rather than last.  Otherwise, the epsilon closure
29173         might contain a duplicate of NODE.
29175         regex-tests: fix typo
29176         * tests/test-regex.c (main): Fix typo that would have caused an
29177         old test case to report incorrect values on failure.
29179         regex: make it easier to merge into glibc
29180         * lib/regex_internal.h [_LIBC]: Do not include Gnulib’s dynarray.h.
29182         regex: minor refactoring
29183         * lib/regexec.c (proceed_next_node): Use more-local decls.
29185         regex: avoid undefined behavior
29186         * lib/regexec.c (pop_fail_stack): If the stack is empty, return -1
29187         instead of indulging in undefined behavior.  This simplifies
29188         callers, and avoids undefined behavior in some cases (see glibc
29189         bug 11053, though this change does not fix that overall bug).
29191         regex: improve comments
29192         * lib/regexec.c: Add and correct comments about return values.
29194 2021-01-31  Bruno Haible  <bruno@clisp.org>
29196         relocatable-prog-wrapper: Tweak today's patch.
29197         * build-aux/install-reloc (func_create_wrapper): Clean up free.o.
29199 2021-01-31  Bruno Haible  <bruno@clisp.org>
29201         fmaf: Document QEMU bug.
29202         * doc/posix-functions/fmaf.texi: Add note about QEMU bug.
29204 2021-01-31  Bruno Haible  <bruno@clisp.org>
29206         remainderl: Work around musl libc bug.
29207         * doc/posix-functions/remainderl.texi: Document musl libc bug.
29208         * m4/remainderl.m4 (gl_FUNC_REMAINDERL_WORKS): Add more tests. Update
29209         cross compilation guess.
29211 2021-01-31  Bruno Haible  <bruno@clisp.org>
29213         log2l: Work around musl libc bugs.
29214         * doc/posix-functions/log2l.texi: Document musl libc bugs.
29215         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Add more tests. Update cross
29216         compilation guess.
29218 2021-01-31  Bruno Haible  <bruno@clisp.org>
29220         log1pl: Work around musl libc bug.
29221         * doc/posix-functions/log1pl.texi: Document musl libc bug.
29222         * m4/log1pl.m4 (gl_FUNC_LOG1PL_WORKS): New macro.
29223         (gl_FUNC_LOG1PL): Invoke it.
29225 2021-01-31  Bruno Haible  <bruno@clisp.org>
29227         log10l: Document musl libc bug.
29228         * doc/posix-functions/log10l.texi: Document musl libc bug.
29229         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Update comment and cross
29230         compilation guess.
29232 2021-01-31  Bruno Haible  <bruno@clisp.org>
29234         logl: Document musl libc bug.
29235         * doc/posix-functions/logl.texi: Document musl libc bug.
29236         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Update comment and cross
29237         compilation guess.
29239 2021-01-31  Bruno Haible  <bruno@clisp.org>
29241         expm1l: Document musl libc bug.
29242         * doc/posix-functions/expm1l.texi: Document musl libc bug.
29243         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Update comment and cross
29244         compilation guess.
29246 2021-01-31  Bruno Haible  <bruno@clisp.org>
29248         expl: Document musl libc bug.
29249         * doc/posix-functions/expl.texi: Document musl libc bug.
29250         * m4/expl.m4 (gl_FUNC_EXPL): Update comment and cross
29251         compilation guess.
29253 2021-01-31  Bruno Haible  <bruno@clisp.org>
29255         relocatable-prog-wrapper: Update after recent changes.
29256         * lib/relocwrapper.c: Update comments.
29257         * modules/relocatable-prog-wrapper (Files): Add lib/scratch_buffer.h,
29258         lib/malloc/scratch_buffer*, lib/malloc.c, lib/realloc.c, lib/free.c,
29259         lib/mempcpy.c, lib/rawmemchr.c, m4/lstat.m4. Remove lib/lstat.c.
29260         (Depends-on): Add c99, eloop-threshold, fcntl-h, idx, intprops,
29261         libc-config, stddef, sys_stat. Remove alloca-opt.
29262         (configure.ac): Invoke gl_FUNC_MALLOC_POSIX, gl_FUNC_REALLOC_POSIX,
29263         gl_FUNC_FREE, gl_FUNC_MEMPCPY, gl_FUNC_RAWMEMCHR.
29264         * lib/canonicalize-lgpl.c (memmove): Undefine in the relocwrapper.
29265         * build-aux/install-reloc (func_create_wrapper): Compile also
29266         malloc/scratch_buffer_*.c, malloc.c, realloc.c, free.c, mempcpy.c,
29267         rawmemchr.c. Don't compile lstat.c.
29269         Make it possible to compile rawmemchr.c separately, unconditionally.
29270         * lib/rawmemchr.c: Don't define rawmemchr if not needed.
29272         Make it possible to compile mempcpy.c separately, unconditionally.
29273         * lib/mempcpy.c: Don't define mempcpy if not needed.
29275         Make it possible to compile free.c separately, unconditionally.
29276         * m4/free.m4 (gl_FUNC_FREE): Define HAVE_FREE_POSIX.
29277         * lib/free.c: Don't define rpl_free if not needed.
29279         Make it possible to compile realloc.c separately, unconditionally.
29280         * modules/realloc-posix (configure.ac): Invoke gl_MODULE_INDICATOR.
29281         * lib/realloc.c: Don't define rpl_realloc if not needed.
29283         Make it possible to compile malloc.c separately, unconditionally.
29284         * modules/malloc-posix (configure.ac): Invoke gl_MODULE_INDICATOR.
29285         * lib/malloc.c: Don't define rpl_malloc if not needed.
29287 2021-01-31  Bruno Haible  <bruno@clisp.org>
29289         canonicalize-lgpl: Simplify.
29290         * lib/canonicalize-lgpl.c (_GL_USE_STDLIB_ALLOC): Remove macro.
29292 2021-01-30  Bruno Haible  <bruno@clisp.org>
29294         canonicalize, canonicalize-lgpl: Straighten dependencies.
29295         * modules/canonicalize-lgpl (Depends-on): Remove free-posix,
29296         malloc-posix. Add unistd.
29297         * modules/canonicalize (Depends-on): Remove free-posix, xalloc.
29298         Add unistd.
29300 2021-01-30  Bruno Haible  <bruno@clisp.org>
29302         scratch_buffer: Fix dependencies.
29303         * modules/scratch_buffer (Depends-on): Add malloc-posix, realloc-posix,
29304         free-posix.
29306 2021-01-26  Bruno Haible  <bruno@clisp.org>
29308         doc: More precise wording.
29309         Reported by Reuben Thomas <rrt@sc3d.org> in
29310         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00300.html>.
29311         * doc/relocatable.texi (Enabling Relocatability): Talk about package
29312         management systems in general.
29314         doc: Remove obsolete text.
29315         Suggested by Reuben Thomas <rrt@sc3d.org> in
29316         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00299.html>.
29317         * doc/relocatable.texi (Enabling Relocatability): Stop mentioning an
29318         issue of libtool 1.5.x.
29320 2021-01-26  Simon Josefsson  <simon@josefsson.org>
29322         maintainer-makefile: Mimic bootstrap's gnulib-srcdir guessing.
29323         * top/maint.mk (gnulib_dir): If $(srcdir)/gnulib doesn't exist,
29324         fall back to $GNULIB_SRCDIR.
29326 2021-01-25  Bruno Haible  <bruno@clisp.org>
29328         posix_spawn_file_actions_* tests: Fix module dependencies.
29329         * modules/posix_spawn_file_actions_addclose-tests (Depends-on): Add
29330         posix_spawn_file_actions_destroy.
29331         * modules/posix_spawn_file_actions_addopen-tests (Depends-on): Likewise.
29332         * modules/posix_spawn_file_actions_adddup2-tests (Depends-on): Likewise.
29333         * modules/posix_spawn_file_actions_addchdir-tests (Depends-on):
29334         Likewise.
29335         * modules/posix_spawn_file_actions_addfchdir-tests (Depends-on):
29336         Likewise.
29338 2021-01-25  Bruno Haible  <bruno@clisp.org>
29340         posix_spawn_file_actions_addclose: Relax configure test.
29341         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE): Test a
29342         negative file descriptor, not an out-of-range file descriptor.
29343         * tests/test-posix_spawn_file_actions_addclose.c (main): Add comment.
29344         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Update.
29346 2021-01-25  Simon Josefsson  <simon@josefsson.org>
29348         getaddrinfo: Doc fix.
29349         * doc/posix-functions/getaddrinfo.texi (getaddrinfo): Gnulib does
29350         not support IDN.
29352 2021-01-24  Bruno Haible  <bruno@clisp.org>
29354         getcwd: Fix cross-compilation guess for musl libc.
29355         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Guess no also on
29356         musl libc.
29357         * doc/posix-functions/getcwd.texi: Update platform info.
29359 2021-01-24  Bruno Haible  <bruno@clisp.org>
29361         expm1l: Fix configure test result with GCC 10 on powerpc64le.
29362         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Change test to avoid GCC optimization.
29364 2021-01-23  Bruno Haible  <bruno@clisp.org>
29366         utime: Fix configure test (regression 2020-12-04).
29367         Reported by Ryan Schmidt <wget@ryandesign.com> via Tim Rühsen in
29368         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00282.html>.
29369         * m4/utime.m4 (gl_FUNC_UTIME): In the test program, include <utime.h>,
29370         not <time.h>.
29372 2021-01-23  Paul Eggert  <eggert@cs.ucla.edu>
29374         libc-config: port to Xcode 7
29375         Problem reported by Mattias Engdegård in:
29376         https://lists.gnu.org/r/emacs-devel/2021-01/msg01089.html
29377         * lib/cdefs.h (__nonnull): If already defined but glibc is not in
29378         use, override the definition with Gnulib’s _GL_ATTRIBUTE_NONNULL.
29379         This is needed for Xcode 7, which has a ‘#define __nonnull
29380         _Nonnull’ builtin for backwards-compatibility with an older Xcode
29381         syntax that GNUish code never uses.
29383 2021-01-23  Bastien Roucariès  <rouca@debian.org>
29385         explicit_bzero: Add fallback for other compilers.
29386         * lib/explicit_bzero.c (explicit_bzero): For other compilers, invoke
29387         memset through a volatile function pointer.
29389         explicit_bzero: Add support for clang.
29390         * lib/explicit_bzero.c (explicit_bzero): Add a compiler barrier for
29391         clang.
29393 2021-01-21  Paul Eggert  <eggert@cs.ucla.edu>
29395         Port FALLTHROUGH to clang 3.4 and earlier
29396         Problem reported by Akim Demaille in:
29397         https://lists.gnu.org/r/bug-gnulib/2021-01/msg00241.html
29398         * lib/cdefs.h (__glibc_has_attribute):
29399         * m4/gnulib-common.m4 (gl_COMMON_BODY):
29400         Do not trust __has_attribute in clang 3.4 and earlier, as
29401         <https://releases.llvm.org/3.5.0/tools/clang/docs/ReleaseNotes.html>
29402         says that __has_attribute is unreliable in these old versions.
29404 2021-01-20  Bruno Haible  <bruno@clisp.org>
29406         gc-random: Fix link error in tests.
29407         * modules/crypto/gc-random (Link): New section.
29408         * modules/crypto/gc-tests (Makefile.am): Link test-gc with
29409         $(LIB_GETRANDOM).
29411 2021-01-20  Simon Josefsson  <simon@josefsson.org>
29413         gc-random: Replace implementation with call to getrandom.
29414         * lib/gc-gnulib.c [GNULIB_GC_RANDOM]: Replace #include's with
29415         those needed for getrandom.
29416         (gc_init): Remove old randomness code.
29417         (gc_done): Likewise.
29418         (randomize): Rewrite using getrandom, inspired by getentropy.
29419         * m4/gc-random.m4: Remove file.
29420         * modules/crypto/gc-random: Drop gc-random.m4, gl_GC_RANDOM, and
29421         LIB_GC_RANDOM.  Add conditional dependency on getrandom.
29422         * modules/crypto/gc-tests (test_gc_LDADD): Drop LIB_GC_RANDOM.
29424 2021-01-20  Bruno Haible  <bruno@clisp.org>
29426         exec*e tests: Avoid test failures on Cygwin.
29427         * tests/test-execle-main.c (main): On Cygwin, add /bin to the new PATH.
29428         * tests/test-execve-main.c (main): Likewise.
29429         * tests/test-execvpe-main.c (main): Likewise.
29431 2021-01-20  Bruno Haible  <bruno@clisp.org>
29433         canonicalize-lgpl: Work around a Cygwin bug.
29434         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Test for lstat. Add a
29435         test case that involves a symbolic link to an existing file.
29436         * doc/posix-functions/realpath.texi: Mention the Cygwin bug.
29438 2021-01-20  Bruno Haible  <bruno@clisp.org>
29440         doc: Document ptsname_r bug on Cygwin.
29441         * doc/glibc-functions/ptsname_r.texi: Mention Cygwin bug.
29443 2021-01-20  Bruno Haible  <bruno@clisp.org>
29445         sethostname tests: Avoid test failure on Cygwin.
29446         * tests/test-sethostname2.c (main): Treat errno EACCESS like EPERM.
29448 2021-01-19  Paul Eggert  <eggert@cs.ucla.edu>
29450         fnmatch, regex, fts: FALLTHROUGH consistency
29451         Be more consistent about how FALLTHROUGH is defined.
29452         For Gnulib, use attribute.h.  For glibc, use __GNUC__ >= 7.
29453         Problem for glibc reported by Vaseeharan Vinayagamoorthy in:
29454         https://sourceware.org/pipermail/libc-alpha/2021-January/121778.html
29455         * lib/fnmatch.c (FALLTHROUGH) [_LIBC]:
29456         * lib/regex_internal.h (FALLTHROUGH) [_LIBC]:
29457         Don’t worry about Clang, as it’s not needed and provokes GCC.
29458         * lib/fts.c (FALLTHROUGH) [!_LIBC]:
29459         * lib/regex_internal.h (FALLTHROUGH) [!_LIBC]:
29460         Rely on attribute.h for FALLTHROUGH
29461         * modules/regex: Depend on attribute module.
29463 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
29465         spawn-pipe: Fix SIGSEGV on OS/2 kLIBC.
29466         * lib/spawn-pipe.c [OS/2 kLIBC]: Check directory correctly if it means
29467         a current directory.
29469 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
29471         dirent: Fix compilation error in C++ mode on OS/2 kLIBC.
29472         * lib/dirent.in.h (dirfd): Redefine dirfd macro as a rpl function
29473         always.
29475 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
29477         zerosize-ptr: Fix compilation on OS/2 kLIBC.
29478         * tests/zerosize-ptr.h [OS/2 kLIBC]: Don't use mmap().
29480 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
29482         stddef: Fix compilation for max_align_t on OS/2 kLIBC.
29483         * lib/stddef.in.h [OS/2 kLIBC]: Include <cstddef> in C++ mode.
29485 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
29487         yield: Implement for OS/2 kLIBC.
29488         * modules/yield (Depends-on): Add sched_yield.
29490         sched_yield: Implement for OS/2 kLIBC.
29491         * lib/sched_yield.c (sched_yield) [OS/2 kLIBC]: New implementation.
29493 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
29495         spawn: Use special invocation for <spawn.h> on OS/2 kLIBC.
29496         * lib/spawn.in.h: Use special invocation to include <spawn.h> properly
29497         on OS/2 kLIBC.
29499 2021-01-18  Bruno Haible  <bruno@clisp.org>
29501         noreturn tests: Avoid test failure on Solaris 10/x86 with cc.
29502         * tests/test-noreturn.c (main): Return 0.
29504 2021-01-18  Bruno Haible  <bruno@clisp.org>
29506         uninorm tests: Fix compilation error on Cygwin.
29507         * tests/uninorm/test-nfc.c (n): Don't define when using a preinstalled
29508         libunistring on Windows.
29509         * tests/uninorm/test-nfd.c (n): Likewise.
29510         * tests/uninorm/test-nfkc.c (n): Likewise.
29511         * tests/uninorm/test-nfkd.c (n): Likewise.
29513 2021-01-17  Bruno Haible  <bruno@clisp.org>
29515         immutable: Implement on native Windows.
29516         * lib/immutable.h (IMMUTABLE_EFFECTIVE): Set to 1 on native Windows.
29517         * lib/immutable.c: Include <windows.h>.
29518         (CreateFileMapping): New macro.
29519         (init_pagesize, init_mmap_file, alloc_pages, free_pages): Add
29520         implementation for native Windows.
29522 2021-01-17  Bruno Haible  <bruno@clisp.org>
29524         canonicalize-lgpl tests: Fix link error.
29525         * modules/canonicalize-lgpl-tests (Makefile.am): Link
29526         test-canonicalize-lgpl with $(LIBINTL).
29528 2021-01-17  Bruno Haible  <bruno@clisp.org>
29530         canonicalize-lgpl: Work around // handling in realpath() of musl 1.2.2.
29531         Reported by Natanael Copa <ncopa@alpinelinux.org> in
29532         <https://lists.gnu.org/archive/html/bug-gettext/2021-01/msg00021.html>.
29533         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Add a test whether // is
29534         the same as /, on Linux only.
29535         * lib/canonicalize-lgpl.c: Correct indentation of preprocessor
29536         directives.
29537         * doc/posix-functions/realpath.texi: Mention the musl 1.2.2 bug.
29539 2021-01-17  Bruno Haible  <bruno@clisp.org>
29541         canonicalize[-lgpl] tests: Add more tests.
29542         * tests/test-canonicalize.c (main): Add detailed tests for // handling.
29543         * tests/test-canonicalize-lgpl.c (main): Likewise.
29545 2021-01-17  Bruno Haible  <bruno@clisp.org>
29547         argp tests: Avoid test failures on Alpine Linux.
29548         * tests/test-argp-2.sh: Use the test framework (init.sh). Use the
29549         'compare' function instead of 'diff -c'.
29550         * tests/test-argp-version-etc-1.sh: Likewise.
29552 2021-01-17  Bruno Haible  <bruno@clisp.org>
29554         get-rusage-data tests: Avoid test failure on musl libc.
29555         * modules/get-rusage-data-tests (Files): Add m4/musl.m4.
29556         (configure.ac): Invoke gl_MUSL_LIBC.
29557         * tests/test-get-rusage-data.c (main): Treat musl libc like glibc.
29559 2021-01-17  Bruno Haible  <bruno@clisp.org>
29561         immutable, get-rusage-data: Fix autoconf warning.
29562         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Define through AC_DEFUN_ONCE.
29564 2021-01-16  Bruno Haible  <bruno@clisp.org>
29566         vma-iter: Port to 64-bit Haiku.
29567         * lib/vma-iter.c (vma_iterate): Adapt to changed signature of
29568         get_next_area_info.
29570 2021-01-15  Bruno Haible  <bruno@clisp.org>
29572         doc: Update doc about realpath.
29573         * doc/posix-functions/realpath.texi: Update info about macOS.
29575 2021-01-13  Paul Eggert  <eggert@cs.ucla.edu>
29577         verify: simplify static_assert configuration
29578         * lib/verify.h (_GL_HAVE__STATIC_ASSERT, _GL_HAVE__STATIC_ASSERT1):
29579         Do not define for C++.  This should be good enough nowadays,
29580         since recent-enough C++ compilers have static_assert.
29581         (_GL_HAVE_STATIC_ASSERT_CXX11, _GL_HAVE_STATIC_ASSERT_CXX17):
29582         Remove.  All uses replaced by simply checking __cpp_static_assert.
29584 2021-01-13  Simon Josefsson  <simon@josefsson.org>
29586         lib-msvc-compat: Update libtool usage recommendation.
29587         * doc/ld-output-def.texi (Visual Studio Compatibility): Install
29588         .def files into libdir, not bindir.  Have libfoo-*.def file depend
29589         on libfoo.la to fix parallell builds.
29591 2021-01-12  Bruno Haible  <bruno@clisp.org>
29593         verify: Use C++11 static_assert when available.
29594         Reported by Alexandre Duret-Lutz <adl@lrde.epita.fr> in
29595         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00177.html>.
29596         * lib/verify.h (_GL_HAVE_STATIC_ASSERT_CXX11): New macro.
29597         (_GL_HAVE_STATIC_ASSERT_CXX17): Renamed from _GL_HAVE_STATIC_ASSERT1.
29598         (_GL_VERIFY): Use static_assert when available with C++11 syntax.
29600 2021-01-11  Paul Eggert  <eggert@cs.ucla.edu>
29602         tempname: consume less entropy
29603         Derived from a glibc patch proposed by Adhemerval Zanella in:
29604         https://sourceware.org/pipermail/libc-alpha/2021-January/121302.html
29605         * lib/tempname.c: Include stdbool.h.
29606         (random_bits): New arg use_getrandom.
29607         (try_tempname_len): Skip getrandom on the first try,
29608         unless __GT_NOCREATE.
29609         * modules/tempname (Depends-on): Add stdbool.
29611 2021-01-10  Bruno Haible  <bruno@clisp.org>
29613         lchmod-tests: Fix link error.
29614         * modules/lchmod-tests (Makefile.am): Don't assume that LIBINTL is set.
29616 2021-01-10  Simon Josefsson  <simon@josefsson.org>
29618         Correct preceeding change.
29619         * top/gitsub.sh: Update link.
29621 2021-01-09  Bruno Haible  <bruno@clisp.org>
29623         immutable: Add tests.
29624         * tests/test-immutable.sh: New file.
29625         * tests/test-immutable.c: New file.
29626         * modules/immutable-tests: New file.
29628         immutable: New module.
29629         * lib/immutable.h: New file.
29630         * lib/immutable.c: New file.
29631         * m4/immutable.m4: New file.
29632         * m4/mprotect.m4: New file, based on libffcall/m4/codeexec.m4.
29633         * modules/immutable: New file.
29635 2021-01-10  Simon Josefsson  <simon@josefsson.org>
29637         Use https:// instead of git://.
29638         * build-aux/bootstrap (default_gnulib_url): Ditto.
29639         * config/srclistvars.sh: Ditto.
29640         * doc/gnulib-readme.texi (Git Checkout): Ditto.
29641         * doc/gnulib-tool.texi (VCS Issues): Ditto.
29642         * top/gitsub.sh: Update link.
29644 2021-01-09  Paul Eggert  <eggert@cs.ucla.edu>
29646         snippet/_Noreturn: port to pedantic clang
29647         Problem reported by Joe Nelson in:
29648         https://lists.gnu.org/r/bug-gnulib/2021-01/msg00152.html
29649         * doc/noreturn.texi: Improve.
29650         * lib/_Noreturn.h (_Noreturn):
29651         * m4/gnulib-common.m4 (gl_COMMON_BODY):
29652         Do not assume _Noreturn works as-is when __STRICT_ANSI__ is
29653         defined, unless __STDC_VERSION__ indicates C11 or later.
29654         * lib/_Noreturn.h (_Noreturn): Fall back on __attribute__
29655         ((__noreturn__)) if Clang; this merges the
29656         2020-08-10T23:53:13Zbruno@clisp.org patch to m4/gnulib-common.m4.
29658 2021-01-09  Darshit Shah  <darnir@gnu.org>
29660         Allow setting CVS username for gnu-web-doc-update.
29661         * build-aux/gnu-web-doc-update: Introduce new option --user to set the
29662         name of the user on Savannah, when it doesn't match $USER.
29664 2021-01-09  Bruno Haible  <bruno@clisp.org>
29666         exp* tests: Work around clang 6.0.1 optimization bugs on x86.
29667         * tests/test-exp-ieee.h (test_function): Mark some variable as
29668         'volatile'.
29669         * tests/test-exp2-ieee.h (test_function): Likewise.
29671 2021-01-09  Bruno Haible  <bruno@clisp.org>
29673         fchmodat: Work around trailing slash bug in fchmodat() on AIX 7.2.
29674         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): In the test whether fchmodat works,
29675         also test for the trailing slashes behaviour. Define
29676         HAVE_NEARLY_WORKING_FCHMODAT if this is the only missing feature.
29677         * lib/fchmodat.c (fchmodat): If HAVE_NEARLY_WORKING_FCHMODAT, handle
29678         trailing slashes here.
29679         * modules/fchmodat (Depends-on): Sort by condition, not alphabetically.
29680         * doc/posix-functions/fchmodat.texi: Document the AIX bug.
29682 2021-01-09  Bruno Haible  <bruno@clisp.org>
29684         fchmod-tests, fchmodat tests, lchmod tests: Add more tests.
29685         * tests/test-fchmod.c: Include <fcntl.h>.
29686         (BASE): New macro.
29687         (main): Add more tests.
29688         * tests/test-fchmodat.c (main): Add more tests.
29689         * tests/test-lchmod.c (main): Likewise.
29691 2021-01-09  Bruno Haible  <bruno@clisp.org>
29693         utimensat: Fix typo in last commit.
29694         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Fix typo in macro explanation.
29696 2021-01-09  Bruno Haible  <bruno@clisp.org>
29698         truncate: Document last workaround.
29699         * doc/posix-functions/truncate.texi: Document the AIX bug.
29701 2021-01-08  Paul Eggert  <eggert@cs.ucla.edu>
29703         dynarray: work even if ‘free’ is replaced
29704         Problem reported by Darshit Shah in:
29705         https://lists.gnu.org/r/bug-gnulib/2021-01/msg00140.html
29706         * lib/malloc/dynarray-skeleton.c (DYNARRAY_FREE): New macro.
29707         Use it everywhere instead of DYNARRAY_NAME (free).
29709         tempname: don’t block for minutes
29710         Derived from a patch proposed by Adhemerval Zanella in:
29711         https://sourceware.org/pipermail/libc-alpha/2021-January/121302.html
29712         * lib/tempname.c (random_bits): Use GRND_NONBLOCK.
29714         tempname: sync with proposed glibc patch
29715         This is from Adhemerval Zanella in:
29716         https://sourceware.org/pipermail/libc-alpha/2021-January/121301.html
29717         * lib/tempname.c (__lxstat64): Remove.
29718         (__lstat64, __stat64): New replacement macros.  All uses changed.
29720         regex: stop using alloca
29721         * lib/regex_internal.h: Do not include <alloca.h> or define
29722         __libc_use_alloca or alloca.  Patch written by Adhemerval Zanella:
29723         https://sourceware.org/pipermail/libc-alpha/2021-January/121374.html
29724         * modules/regex (Depends-on): Remove alloca-opt.
29726         regexec: remove alloca usage in build_trtable
29727         Prompted by this different change proposed by Adhemerval Zanella:
29728         https://sourceware.org/pipermail/libc-alpha/2021-January/121373.html
29729         * lib/regexec.c (build_trtable): Prevent inlining,
29730         so that it doesn’t bloat the caller’s stack.
29731         Use auto variables instead of alloca/malloc.
29732         After these changes, build_trtable’s total stack allocation is
29733         only 20 KiB on a 64-bit machine, and this is less than glibc’s 64
29734         KiB cutoff so there’s little point to using alloca to shrink it.
29735         Although Gnulib traditionally has used a 4 KiB cutoff, going to 20
29736         KiB here should not be a significant problem in practice;
29737         Gnulib-using packages concerned about overflow of tiny stacks can
29738         compile with something like gcc -fstack-clash-protection.
29740         scratch_buffer: add scratch_buffer_dupfree macro
29741         * lib/scratch_buffer.h (__libc_scratch_buffer_dupfree):
29742         New macro, needed to support recent changes in this module.
29744         regex: remove alloca usage on regex set_regs
29745         Derived from this patch by Adhemerval Zanella:
29746         https://sourceware.org/pipermail/libc-alpha/2021-January/121372.html
29747         * lib/regex_internal.h: Include dynarray.h, for Gnulib.
29748         * lib/regexec.c (DYNARRAY_STRUCT, DYNARRAY_ELEMENT)
29749         (DYNARRAY_PREFIX): New macros.
29750         Include malloc/dynarray-skeleton.c.
29751         (set_regs): Use dynarray rather than alloca.
29752         * modules/regex (Depends-on): Add dynarray.
29754         dynarray: new module
29755         * config/srclist.txt: Mention the new files.
29756         * lib/cdefs.h (__attribute_maybe_unused__): New macro,
29757         like Gnulib’s _GL_ATTRIBUTE_MAYBE_UNUSED but with glibc
29758         naming conventions.
29759         * lib/libc-config.h: Use it instead of __glibc_likely.
29760         * lib/dynarray.h, modules/dynarray: New files.
29761         * lib/malloc/dynarray-skeleton.c, lib/malloc/dynarray.h:
29762         * lib/malloc/dynarray_at_failure.c:
29763         * lib/malloc/dynarray_emplace_enlarge.c:
29764         * lib/malloc/dynarray_finalize.c, lib/malloc/dynarray_resize.c:
29765         * lib/malloc/dynarray_resize_clear.c, modules/dynarray:
29766         New files, from glibc with the following changes needed for
29767         portability to compilers that are not recent-enough GCC.
29768         * lib/malloc/dynarray_at_failure.c: Include stdlib.h, for abort.
29769         (__libc_dynarray_at_failure) [!_LIBC]: Simply abort.
29770         * lib/malloc/dynarray_emplace_enlarge.c:
29771         * lib/malloc/dynarray_resize.c:
29772         Include intprops.h, and use INT_MULTIPLY_WRAPV instead
29773         of __builtin_mul_overflow.
29774         * lib/malloc/dynarray.h (__libc_dynarray_at_failure):
29775         Use _Noreturn instead of __attribute__ ((noreturn)).
29776         * lib/malloc/dynarray_resize_clear.c: Do not include stdlib.h;
29777         it’s not needed.
29778         (__libc_dynarray_resize_clear): Do not do arithmetic on void *.
29779         * lib/malloc/dynarray-skeleton.c (struct DYNARRAY_STRUCT):
29780         Do not use anonymous unions, as they are not in C99. All uses changed.
29781         Use __nonnull (X) instead of __attribute__ ((nonnull X)),
29782         and __attribute_maybe_unused__ instead of __attribute__ ((unused)).
29784 2021-01-06  Simon Josefsson  <simon@josefsson.org>
29786         bootstrap: Fix parsing of package name.
29787         * build-aux/bootstrap (package): Attempt to use autoconf --trace
29788         to parse AC_INIT before falling back to sed expression.
29790 2021-01-07  Bruno Haible  <bruno@clisp.org>
29792         localename: Fix link error with duplocale on AIX 7.2 (regr. 2019-12-18).
29793         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize
29794         LOCALENAME_ENHANCE_LOCALE_FUNCS.
29795         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE):
29796         Set gt_working_uselocale.
29797         (gt_INTL_THREAD_LOCALE_NAME): Set gt_fake_locales, gt_good_uselocale,
29798         gt_localename_enhances_locale_funcs, LOCALENAME_ENHANCE_LOCALE_FUNCS.
29799         Define HAVE_GOOD_USELOCALE, LOCALENAME_ENHANCE_LOCALE_FUNCS.
29800         * m4/localename.m4 (gl_LOCALENAME): Test
29801         gt_localename_enhances_locale_funcs instead of gt_nameless_locales.
29802         * modules/locale (Makefile.am): Substitute
29803         LOCALENAME_ENHANCE_LOCALE_FUNCS.
29804         * lib/locale.in.h (newlocale, duplocale, freelocale): Don't override if
29805         module 'localename' is in use but LOCALENAME_ENHANCE_LOCALE_FUNCS is 0.
29806         * lib/localename.c (HAVE_GOOD_USELOCALE): Don't define here.
29807         (get_locale_t_name, newlocale, duplocale, freelocale): Define if
29808         LOCALENAME_ENHANCE_LOCALE_FUNCS.
29810 2021-01-06  Bruno Haible  <bruno@clisp.org>
29812         logb: Fix test failure on glibc/powerpc.
29813         * doc/posix-functions/logb.texi: Update platform info.
29814         * m4/logb.m4 (gl_FUNC_LOGB_WORKS): Test against bug with negative
29815         subnormal numbers.
29817 2021-01-06  Paul Eggert  <eggert@cs.ucla.edu>
29819         libc-config: simplify clang __has_* macros
29820         cdefs.h sometimes used names like __glibc_clang_has_attribute and
29821         sometimes __glibc_has_attribute.  There is no need in glibc or
29822         Gnulib to distinguish clang from other compilers here, so be
29823         consistent and use the simpler names.
29824         * lib/cdefs.h (__glibc_has_builtin, __glibc_has_extension):
29825         Rename from __glibc_clang_has_builtin, __glibc_clang_has_extension.
29826         All uses changed.
29827         (__glibc_clang_has_attribute): Remove. All uses replaced
29828         by __glibc_has_attribute.
29829         * lib/libc-config.h [!__glibc_likely]: Undef them here too.
29830         This fixes a problem where __glibc_has_attribute was not undeffed.
29832 2021-01-06  Bruno Haible  <bruno@clisp.org>
29834         flock: Update documentation.
29835         * doc/glibc-functions/flock.texi: Document what to expect on AIX and
29836         Solaris.
29838 2021-01-06  Bruno Haible  <bruno@clisp.org>
29840         ilogbl: Fix compilation error with xlclang on AIX 7.2.
29841         * lib/math.in.h (ilogbl): Undefine macro before declaration.
29843 2021-01-06  Bruno Haible  <bruno@clisp.org>
29845         ilogbl: Fix test failures on AIX 7.1 in 64-bit mode.
29846         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Test also some denormalized
29847         argument.
29848         * doc/posix-functions/ilogbl.texi: Mention the AIX bug.
29850 2021-01-06  Bruno Haible  <bruno@clisp.org>
29852         ilogb: Fix test failures on AIX 7.1 in 64-bit mode.
29853         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Test also some denormalized
29854         argument.
29855         * doc/posix-functions/ilogb.texi: Mention the AIX bug.
29857 2021-01-05  Bruno Haible  <bruno@clisp.org>
29859         fclose: Fix test failure on AIX 7.2.
29860         * m4/fclose.m4 (gl_FUNC_FCLOSE_STDIN): New macro.
29861         (gl_FUNC_FCLOSE): Invoke it. Set REPLACE_FCLOSE accordingly.
29862         * doc/posix-functions/fclose.texi: Update platform information.
29863         * doc/posix-functions/fflush.texi: Likewise.
29865 2021-01-05  Bruno Haible  <bruno@clisp.org>
29867         pipe-filter-gi: Fix test failure on AIX 7.2.
29868         * lib/pipe-filter-aux.h (SSIZE_MAX) [AIX]: Set to 4096.
29870 2021-01-05  Bruno Haible  <bruno@clisp.org>
29872         utimens, utimensat, fdutimensat: Avoid test failures on AIX 7.2.
29873         * lib/utimecmp.c (utimecmpat): On AIX, declare equality when the two
29874         times differ by less than 0.01 seconds.
29875         * tests/test-futimens.h (test_futimens): Pass UTIMECMP_TRUNCATE_SOURCE
29876         flag.
29878 2021-01-05  Bruno Haible  <bruno@clisp.org>
29880         utimensat: Work around trailing slash bug in utimensat() on AIX 7.2.
29881         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Require AC_CANONICAL_HOST. Add a
29882         test for trailing slash handling. Improve cross-compilation guesses.
29883         Conditionally define HAVE_NEARLY_WORKING_UTIMENSAT.
29884         * lib/utimensat.c (rpl_utimensat): Add alternative implementation when
29885         HAVE_NEARLY_WORKING_UTIMENSAT is defined.
29886         * lib/utimens.c: Use the overridden utimensat when
29887         HAVE_NEARLY_WORKING_UTIMENSAT is defined.
29888         * doc/posix-functions/utimensat.texi: Mention the AIX bug.
29890 2021-01-05  Bruno Haible  <bruno@clisp.org>
29892         ptsname_r, ptsname: Avoid test failures on AIX 7.2.
29893         * tests/test-ptsname_r.c (main): On AIX, set a 20-seconds timer.
29894         * tests/test-ptsname.c (main): Likewise. On AIX, open a pty through
29895         /dev/ptc and don't test the BSD ptys.
29897 2021-01-05  Paul Eggert  <eggert@cs.ucla.edu>
29899         libc-config: merge from glibc
29900         Use a better way of keeping glibc <sys/cdefs.h> and gnulib
29901         lib/cdefs.h mostly in sync, by using lib/cdefs.h only on platforms
29902         where <sys/cdefs.h> does not work well enough for Gnulib.
29903         * lib/cdefs.h: Go back to using _SYS_CDEFS_H rather than
29904         _GL_DEFS_H as an include guard.
29905         (__THROW, __THROWNL, __NTH, __NTHNL):
29906         Define to noexcept for C++11 and later.
29907         (__glibc_objsize, __glibc_objsize0): New, for _FORTIFY_SOURCE=3.
29908         (__warndecl): Remove.
29909         (__attribute_copy__): New macro, for GCC 9 support.
29910         (__LDBL_REDIR, __LDBL_REDIR_DECL, __LDBL_REDIR1)
29911         (__LDBL_REDIR1_DECL, __LDBL_REDIR1_NTH, __REDIRECT_NTH_LDBL)
29912         (__REDIRECT_LDBL, __LDBL_REDIR_NTH):
29913         Redirections for IEEE long double on powerpc64le.
29914         (__LDBL_REDIR2_DECL): New macro.
29915         (__attr_access): New macro, for GCC 10 bounds checking.
29916         (__attribute_returns_twice__): New macro, for setjmp etc.
29917         * lib/libc-config.h: Include <cdefs.h> only if __glibc_likely is
29918         undefined.  The following changes apply only if __glibc_likely
29919         is not defined.
29920         (__LDBL_REDIR2_DECL, __attr_access, __attribute_returns_twice__)
29921         (__glibc_clang_has_attribute, __glibc_clang_has_extension)
29922         (__glibc_objsize, __glibc_objsize0):
29923         Undef these new (or newer) <cdefs.h> macros.
29924         (__P, __PMT, __always_inline): Do not undef, since cdefs.h does that.
29925         (__glibc_likely): Do not undef, since this is inside
29926         ifndef __glibc_likely.
29927         (__warndecl): Do not undef; no longer defined.
29929 2021-01-05  Jim Meyering  <meyering@fb.com>
29931         maintainer-makefile: correct preceding change
29932         * top/maint.mk (syntax-check-rules): Use LC_ALL=C, not LANG=C.
29934 2021-01-05  Paul Eggert  <eggert@cs.ucla.edu>
29936         maint: note syncs to glibc
29937         * config/srclist.txt: filename.h, idx.h, scratch_buffer.h and
29938         scratch_buffer_dupfree.c are now identical to glibc.  Add
29939         commentary about some other syncs we’d like.
29940         * modules/filename, modules/idx (Maintainer): Add glibc.
29942 2021-01-05  Bruno Haible  <bruno@clisp.org>
29944         truncate: Work around trailing slash bug in truncate() on AIX 7.2.
29945         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Add a test whether truncate
29946         rejects trailing slashes. Set REPLACE_TRUNCATE and define
29947         TRUNCATE_TRAILING_SLASH_BUG if not.
29948         * lib/truncate.c (orig_truncate): New function.
29949         (truncate): Add alternative implementation when
29950         TRUNCATE_TRAILING_SLASH_BUG is defined.
29951         * modules/truncate (Depends-on): Add sys_stat, stat.
29953 2021-01-05  Bruno Haible  <bruno@clisp.org>
29955         mkfifoat: Fix cross-compilation guess (regression from 2021-01-04).
29956         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Fix copy-and-paste mistake.
29958 2021-01-05  Bruno Haible  <bruno@clisp.org>
29960         ffsll: Override completely broken implementation on AIX in 32-bit mode.
29961         * m4/ffsll.m4 (gl_FUNC_FFSLL): Test whether ffsll minimally works. If
29962         not, set REPLACE_FFSLL.
29963         * lib/string.in.h (ffsll): Consider REPLACE_FFSLL.
29964         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
29965         REPLACE_FFSLL.
29966         * modules/string (Makefile.am): Substitute REPLACE_FFSLL.
29967         * modules/ffsll (Depends-on, configure.ac): Consider REPLACE_FFSLL.
29968         * doc/glibc-functions/ffsll.texi: Mention the AIX 7.2 bug.
29970 2021-01-04  Bruno Haible  <bruno@clisp.org>
29972         symlinkat: Fix trailing slash handling.
29973         * lib/symlinkat.c (rpl_symlinkat): Don't follow symlinks during the
29974         trailing slash handling.
29975         * modules/symlinkat (Depends-on): Update conditions.
29977 2021-01-04  Bruno Haible  <bruno@clisp.org>
29979         mkfifoat: Update module description.
29980         * modules/mkfifoat (Depends-on): Update conditions after last commits.
29982 2021-01-04  Bruno Haible  <bruno@clisp.org>
29984         link: Improve trailing slash handling on native Windows.
29985         * lib/link.c (link): If stat() fails, provide a better errno.
29987 2021-01-04  Bruno Haible  <bruno@clisp.org>
29989         mkfifoat: Work around trailing slash bug in mknodat() on AIX 7.2.
29990         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Set also REPLACE_MKNODAT.
29991         * lib/sys_stat.in.h (mknodat): Consider REPLACE_MKNODAT.
29992         * lib/mknodat.c: Add an overriding implementation of mknodat().
29993         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize REPLACE_MKNODAT.
29994         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKNODAT.
29995         * modules/mkfifoat (Depends-on, configure.ac): Consider REPLACE_MKNODAT.
29996         * doc/posix-functions/mknodat.texi: Mention the AIX bug.
29998         mkfifoat: Work around trailing slash bug in mkfifoat() on AIX 7.2.
29999         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Add a test whether mkfifoat rejects
30000         trailing slashes. Set REPLACE_MKFIFOAT if not.
30001         * lib/sys_stat.in.h (mkfifoat): Consider REPLACE_MKFIFOAT.
30002         * lib/mkfifoat.c: Add an overriding implementation of mkfifoat().
30003         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
30004         REPLACE_MKFIFOAT.
30005         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKFIFOAT.
30006         * modules/mkfifoat (Depends-on): Add fstatat.
30007         (configure.ac): Consider REPLACE_MKFIFOAT.
30008         * doc/posix-functions/mkfifoat.texi: Mention the AIX bug.
30010 2021-01-04  Bruno Haible  <bruno@clisp.org>
30012         libc-config: Avoid overriding the headers from an installed newer glibc.
30013         Reported by Paul E Murphy <murphyp@linux.ibm.com> in
30014         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00106.html>.
30015         * lib/cdefs.h: Use a different include guard than glibc's <sys/cdefs.h>.
30016         * lib/libc-config.h: Update accordingly.
30018 2021-01-04  Simon Josefsson  <simon@josefsson.org>
30020         maintainer-makefile: Invoke syntax-checks regardless of locale.
30021         * top/maint.mk (syntax-check-rules): Invoke sed with LANG=C
30022         environment because [a-z] may not include 'w' in all locales.
30024 2021-01-04  Bruno Haible  <bruno@clisp.org>
30026         nstrftime, time_rz: Avoid using an obsolete Autoconf macro.
30027         Reported by Mike Gran <spk121@yahoo.com> in
30028         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00067.html>.
30029         * lib/time-internal.h: Test HAVE_STRUCT_TM_TM_ZONE, not HAVE_TM_ZONE.
30030         * lib/time_rz.c: Likewise.
30031         * lib/nstrftime.c: Set and test HAVE_STRUCT_TM_TM_ZONE, not
30032         HAVE_TM_ZONE.
30033         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Update comments.
30035 2021-01-04  Bruno Haible  <bruno@clisp.org>
30037         expm1f-ieee: Work around AIX 7.2 bug.
30038         * m4/expm1f.m4 (gl_FUNC_EXPM1F): Initialize gl_expm1f_required. If
30039         module 'expm1f-ieee' is in use, check whether expm1f works according to
30040         IEEE.
30041         * m4/expm1f-ieee.m4: New file.
30042         * modules/expm1f-ieee (Files): Add it.
30043         (Depends-on): Update conditions.
30044         (configure.ac): Invoke gl_FUNC_EXPM1F_IEEE.
30045         * doc/posix-functions/expm1f.texi: Mention the AIX bug.
30047 2021-01-04  Bruno Haible  <bruno@clisp.org>
30049         ffsl, ffsll: Work around AIX 7.2 problem.
30050         * lib/string.in.h: On AIX, include <strings.h> for the declarations of
30051         ffsl and ffsll.
30052         * doc/glibc-functions/ffsl.texi: Document the AIX 7.2 problem.
30053         * doc/glibc-functions/ffsll.texi: Likewise.
30055 2021-01-04  Bruno Haible  <bruno@clisp.org>
30057         ssfmalloc: Fix includes.
30058         * lib/ssfmalloc.h: Include <strings.h>, for ffs().
30059         * tests/test-ssfmalloc.c: Include <string.h>, for memset().
30061 2021-01-03  Bruno Haible  <bruno@clisp.org>
30063         quotearg tests: Avoid test failures on Solaris 11.3.
30064         * tests/test-quotearg.sh: Copy the fr/ directory using 'cp -R', not
30065         'cp -a'.
30067 2021-01-03  Bruno Haible  <bruno@clisp.org>
30069         tests: Fix link errors on Solaris, when libunistring-optional is in use.
30070         * modules/wcwidth (Link): New section.
30071         * modules/wcswidth (Link): New section.
30072         * modules/mbchar (Link): New section.
30073         * modules/mbfile (Link): Link against libunistring.
30074         * modules/mbiter (Link): Likewise.
30075         * modules/mbuiter (Link): Likewise.
30076         * modules/mbmemcasecmp (Link): Likewise.
30077         * modules/mbscasecmp (Link): Likewise.
30078         * modules/mbscasestr (Link): Likewise.
30079         * modules/mbschr (Link): Likewise.
30080         * modules/mbscspn (Link): Likewise.
30081         * modules/mbslen (Link): Likewise.
30082         * modules/mbsncasecmp (Link): Likewise.
30083         * modules/mbsnlen (Link): Likewise.
30084         * modules/mbspbrk (Link): Likewise.
30085         * modules/mbspcasecmp (Link): Likewise.
30086         * modules/mbsrchr (Link): Likewise.
30087         * modules/mbssep (Link): Likewise.
30088         * modules/mbsspn (Link): Likewise.
30089         * modules/mbsstr (Link): Likewise.
30090         * modules/mbstok_r (Link): Likewise.
30091         * modules/mbswidth (Link): Likewise.
30092         * modules/exclude (Link): Likewise.
30093         * modules/propername (Link): Likewise.
30094         * modules/regex-quote (Link): Likewise.
30095         * modules/trim (Link): Likewise.
30096         * modules/mbmemcasecmp-tests (Makefile.am): Link the test program
30097         against libunistring.
30098         * modules/mbscasecmp-tests (Makefile.am): Likewise.
30099         * modules/mbscasestr-tests (Makefile.am): Likewise.
30100         * modules/mbschr-tests (Makefile.am): Likewise.
30101         * modules/mbscspn-tests (Makefile.am): Likewise.
30102         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
30103         * modules/mbspbrk-tests (Makefile.am): Likewise.
30104         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
30105         * modules/mbsrchr-tests (Makefile.am): Likewise.
30106         * modules/mbsspn-tests (Makefile.am): Likewise.
30107         * modules/mbsstr-tests (Makefile.am): Likewise.
30108         * modules/exclude-tests (Makefile.am): Likewise.
30109         * modules/regex-quote-tests (Makefile.am): Likewise.
30111 2021-01-03  Bruno Haible  <bruno@clisp.org>
30113         c32ispunct tests: Avoid test failures on FreeBSD.
30114         * tests/test-c32ispunct.c (main): On FreeBSD, disable tests that fail on
30115         FreeBSD 12.1.1.
30117 2021-01-04  Simon Josefsson  <simon@josefsson.org>
30119         doc: Repeat warning that --with-tests cannot be used twice.
30120         * doc/gnulib-tool.texi (Multiple instances): Remind reader of
30121         --with-tests limitation.
30123 2021-01-03  Bruno Haible  <bruno@clisp.org>
30125         iconv, iconv_open: Improve documentation.
30126         Reported by Noah Misch <noah@leadboat.com> in
30127         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00172.html>.
30128         * doc/posix-functions/iconv_open.texi: Add new paragraph "Portability
30129         problems handled by Gnulib".
30130         * doc/posix-functions/iconv.texi: Likewise. Update info about AIX.
30131         * m4/iconv.m4 (AM_ICONV_LINK): Improve comments.
30133 2021-01-03  Bruno Haible  <bruno@clisp.org>
30135         iconv-h: Fix module description.
30136         * modules/iconv-h (Include): Check HAVE_ICONV_H.
30138 2021-01-03  Noah Misch  <noah@leadboat.com>
30140         iconv_open: Fix module description.
30141         * modules/iconv_open (Include): Check HAVE_ICONV, like modules/iconv.
30143 2021-01-03  Bruno Haible  <bruno@clisp.org>
30145         stddef: Override wrong max_align_t on AIX 7 with xlc in 64-bit mode.
30146         * m4/stddef_h.m4 (gl_STDDEF_H): Make check for good max_align_t
30147         stricter: Add tests for offsetof-based alignof.
30148         * lib/stddef.in.h (max_align_t): Override on AIX in 64-bit mode.
30149         * doc/posix-headers/stddef.texi: Document the AIX max_align_t bug.
30151 2021-01-03  Bruno Haible  <bruno@clisp.org>
30153         free-posix: Work around GCC mis-optimization bug.
30154         Code by Bernhard Voelker <mail@bernhard-voelker.de>.
30155         * lib/free.c (rpl_free): Add alternative complicated code for GCC.
30157 2021-01-02  Bruno Haible  <bruno@clisp.org>
30159         valgrind-tests: Disable valgrind if it would cause all tests to fail.
30160         Suggested by Simon Josefsson <simon@josefsson.org> in
30161         <https://lists.gnu.org/archive/html/help-gsasl/2021-01/msg00004.html>.
30162         * m4/valgrind-tests.m4 (gl_VALGRIND_TESTS): Test $VALGRIND on an
30163         executable produced by the current compiler. Set VALGRIND to empty if it
30164         does not work. Don't set VALGRIND to empty if it merely does not accept
30165         the --error-exitcode=1 --leak-check=full options.
30167 2021-01-02  Bruno Haible  <bruno@clisp.org>
30169         valgrind-tests: Really enable the valgrind options test.
30170         * m4/valgrind-tests.m4 (gl_VALGRIND_TESTS): Don't assume that the
30171         valgrind options --error-exitcode=1 --leak-check=full always work.
30173 2021-01-02  Bruno Haible  <bruno@clisp.org>
30175         utimensat: Fix test failures on macOS 10.13.
30176         * lib/utimensat.c: Include <string.h>, <sys/stat.h>.
30177         (rpl_utimensat): Check against invalid tv_nsec values. Before calling
30178         utimensat, recognize a filename ending in a slash that does not point
30179         to a directory.
30181 2021-01-02  Bruno Haible  <bruno@clisp.org>
30183         utimens: Fix test failure on macOS 10.13.
30184         * lib/utimens.c: Include <string.h>.
30186         utimens: Fix test failure on macOS 10.13.
30187         * lib/utimens.c (fdutimens): Before calling utimensat, recognize a
30188         filename ending in a slash that does not point to a directory.
30190 2021-01-02  Bruno Haible  <bruno@clisp.org>
30192         utimens: Avoid test failures on macOS 10.13.
30193         Reported by Martin Storsjö <martin@martin.st> in
30194         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
30195         * tests/test-utimens-common.h (check_ctime): Define to -1 on macOS.
30196         * tests/test-utimens.h (test_utimens): Don't expect a ctime change when
30197         only the atime is requested to change.
30198         * tests/test-futimens.h (test_futimens): Likewise.
30199         * tests/test-lutimens.h (test_lutimens): Likewise.
30201 2021-01-02  Bruno Haible  <bruno@clisp.org>
30203         renameatu: Fix test failures on macOS.
30204         Reported by Martin Storsjö <martin@martin.st> in
30205         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
30206         * lib/renameatu.c (renameatu): Don't call renameatx_np right away.
30207         Instead, treat it as a variant of renameat, with all possible bugs that
30208         renameat might have.
30210 2021-01-02  Bruno Haible  <bruno@clisp.org>
30212         getgroups test: Avoid warning with glibc >= 2.32 and gcc >= 10.
30213         Reported by Bernhard Voelker <mail@bernhard-voelker.de> in
30214         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00090.html>.
30215         * tests/test-getgroups.c: Silence gcc warnings of type
30216         -Wstringop-overflow.
30218 2021-01-02  Bruno Haible  <bruno@clisp.org>
30220         timespec_get: Add tests.
30221         * tests/test-timespec_get.c: New file.
30222         * modules/timespec_get-tests: New file.
30224         timespec_get: New module.
30225         * lib/time.in.h (timespec_get): New declaration.
30226         * lib/timespec_get.c: New file.
30227         * m4/timespec_get.m4: New file.
30228         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize
30229         GNULIB_TIMESPEC_GET, HAVE_TIMESPEC_GET.
30230         * modules/time (Makefile.am): Substitute GNULIB_TIMESPEC_GET,
30231         HAVE_TIMESPEC_GET.
30232         * modules/timespec_get: New file.
30233         * tests/test-time-c++.cc (timespec_get): Check signature.
30234         * doc/glibc-functions/timespec_get.texi: Mention the new module.
30236 2021-01-01  Bruno Haible  <bruno@clisp.org>
30238         time: Define TIME_UTC.
30239         * lib/time.in.h (TIME_UTC, GNULIB_defined_TIME_UTC): New macros.
30240         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Set TIME_H_DEFINES_TIME_UTC.
30241         * modules/time (Makefile.am): Substitute TIME_H_DEFINES_TIME_UTC.
30242         * tests/test-time.c: Check that TIME_UTC is defined and a positive
30243         integer.
30244         * doc/posix-headers/time.texi: Mention TIME_UTC.
30246 2021-01-01  Bruno Haible  <bruno@clisp.org>
30248         stddef: Try harder to get max_align_t defined on OpenBSD, part 2.
30249         * modules/stddef (Depends-on): Add extensions.
30251 2021-01-01  Paul Eggert  <eggert@cs.ucla.edu>
30253         canonicalize: remove NARROW_ADDRESSES optimization
30254         * lib/canonicalize-lgpl.c, lib/canonicalize.c (NARROW_ADDRESSES):
30255         Remove, and remove all uses, as the optimization is arguably not
30256         worth the extra complexity.  Suggested by Adhemerval Zanella in:
30257         https://sourceware.org/pipermail/libc-alpha/2020-December/121203.html
30259 2021-01-01  Bruno Haible  <bruno@clisp.org>
30261         stddef: Try harder to get max_align_t defined on OpenBSD.
30262         * m4/stddef_h.m4 (gl_STDDEF_H): Require gl_USE_SYSTEM_EXTENSIONS.
30264 2021-01-01  Bruno Haible  <bruno@clisp.org>
30266         aligned_alloc: Fix test failure on OpenBSD 6.8.
30267         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): On OpenBSD, define
30268         _ISOC11_SOURCE.
30269         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Require it. Update
30270         comment.
30272 2021-01-01  Bruno Haible  <bruno@clisp.org>
30274         posixtm tests: Disable part of the test on plaforms where it fails.
30275         * tests/test-posixtm.c (T): Disable two tests on macOS as well.
30277 2021-01-01  Bruno Haible  <bruno@clisp.org>
30279         c32isgraph/c32isprint/c32ispunct tests: Avoid test failures on OmniOS.
30280         * tests/test-c32isgraph.c (main): On Solaris, disable tests that fail on
30281         Solaris 11 OmniOS.
30282         * tests/test-c32isprint.c (main): Likewise.
30283         * tests/test-c32ispunct.c (main): Likewise.
30285 2021-01-01  Paul Eggert  <eggert@cs.ucla.edu>
30287         libc-config: port to Sun C 5.9
30288         * lib/libc-config.h (libc_hidden_proto): Omit ", ..." in macro
30289         definition.  It’s not needed for Gnulib and elicits a diagnostic
30290         from Sun C 5.9 Patch 124867-12 2009/11/22.
30292 2021-01-01  Bruno Haible  <bruno@clisp.org>
30294         quotearg tests: Avoid test failures on Solaris 11.
30295         * modules/quotearg-tests (Makefile.am): Set host_os in
30296         TESTS_ENVIRONMENT.
30297         * tests/test-quotearg.sh: On Solaris 11 systems, make a copy of the fr/
30298         directory that contains the .mo file.
30300 2021-01-01  Bruno Haible  <bruno@clisp.org>
30302         maint: Update copyright notices in --version output.
30303         List the most recent year in which changes were made, per
30304         <https://www.gnu.org/prep/standards/html_node/_002d_002dversion.html>.
30305         * build-aux/declared.sh (func_version): Say 2019.
30306         * build-aux/libtool-next-version (func_version): Likewise.
30307         * build-aux/run-test (func_version): Likewise.
30308         * check-module (COPYRIGHT_NOTICE): Say 2012.
30309         * lib/git-merge-changelog.c (main): Say 2020.
30311 2020-12-31  Paul Eggert  <eggert@cs.ucla.edu>
30313         filename: change filename.h comment to LGPLv2.1+
30314         * lib/filename.h: Change license notice to match what should be in
30315         glibc, and what modules/filename specifies.  This is to simplify
30316         syncing with glibc.
30318         doc: mention year-0 bugs in Solaris etc.
30319         * doc/posix-functions/gmtime.texi, doc/posix-functions/gmtime_r.texi:
30320         * doc/posix-functions/localtime.texi:
30321         * doc/posix-functions/localtime_r.texi:
30322         * doc/posix-functions/mktime.texi:
30323         Mention year-0 bugs in localtime etc.
30325 2020-12-31  Bruno Haible  <bruno@clisp.org>
30327         ptsname_r: Fix test failure on Solaris.
30328         * lib/ptsname_r.c (__ptsname_r) [__sun]: Don't test the major number of
30329         the device.
30331 2020-12-31  Bruno Haible  <bruno@clisp.org>
30333         posixtm tests: Disable part of the test on plaforms where it fails.
30334         * tests/test-posixtm.c (T): Disable two tests on Solaris.
30336 2020-12-31  Bruno Haible  <bruno@clisp.org>
30338         poll tests: Avoid test failure on AIX.
30339         * tests/test-poll.c (test_pipe): Disable the "expecting POLLHUP after
30340         shutdown" test on AIX.
30341         * doc/posix-functions/poll.texi: Mention the AIX bug.
30343 2020-12-31  Bruno Haible  <bruno@clisp.org>
30345         poll tests: Avoid test failure on BSD and Solaris systems.
30346         * tests/test-poll.c (test_accept_first, test_socket_pair): Disable the
30347         "expecting POLLHUP after shutdown" test on all platforms except Linux.
30349 2020-12-31  Paul Eggert  <eggert@cs.ucla.edu>
30351         fnmatch: merge from glibc + proposal
30352         This merges the change proposed by Adhemerval Zanella in:
30353         https://sourceware.org/pipermail/libc-alpha/2020-December/121212.html
30354         which fixes a Gnulib bug that led to a failed assert.
30355         * lib/fnmatch_loop.c (EXT): Use signed level, not unsigned, and
30356         check that it stays nonnegative.  Use __flexarr instead of
30357         FLEXIBLE_ARRAY_MEMBER, to port better to glibc.
30358         * tests/test-fnmatch.c (main): New test cases, taken from glibc.
30360         glob: merge proposed glibc changes
30361         This merges the change proposed by Adhemerval Zanella in:
30362         https://sourceware.org/pipermail/libc-alpha/2020-December/121211.html
30363         * lib/glob.c (__lstat64, __stat64) [_LIBC]: Remove.
30365 2020-12-31  Bruno Haible  <bruno@clisp.org>
30367         memalign: Work around Solaris bug.
30368         * lib/memalign.c: New file.
30369         * m4/memalign.m4: New file.
30370         * modules/memalign (Files): Add them.
30371         (Depends-on): Add malloc-h.
30372         (configure.ac): Invoke gl_FUNC_MEMALIGN. Conditionally compile
30373         memalign.c. Set module indicator.
30374         (Include): Include <malloc.h> unconditionally.
30375         * doc/glibc-functions/memalign.texi: Mention the Solaris issues.
30377         malloc-h: Add tests.
30378         * tests/test-malloc-h.c: New file.
30379         * modules/malloc-h-tests: New file.
30380         * tests/test-malloc-h-c++.cc: New file.
30381         * modules/malloc-h-c++-tests: New file.
30383         malloc-h: New module.
30384         * lib/malloc.in.h: New file.
30385         * m4/malloc_h.m4: New file.
30386         * modules/malloc-h: New file.
30387         * doc/glibc-headers/malloc.texi: New file.
30388         * doc/gnulib.texi (Glibc Header File Substitutes): Include it.
30390 2020-12-31  Bruno Haible  <bruno@clisp.org>
30392         unistd: Fix portability warnings.
30393         * lib/unistd.in.h (fchownat, unlinkat): Fix module name in warning.
30395 2020-12-31  Bruno Haible  <bruno@clisp.org>
30397         utime: Fix compilation error on macOS and Solaris 9 (regr. 2020-12-24).
30398         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
30399         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00295.html>.
30400         * lib/utime.c: Include <errno.h>.
30402 2020-12-30  Karl Berry  <karl@freefriends.org>
30404         config: srclistvars doc.
30405         * config/srclistvars.sh: doc a couple of unusual source repo urls.
30407 2020-12-30  Bruno Haible  <bruno@clisp.org>
30409         getlogin tests, getlogin_r tests: Avoid failure on Solaris OpenIndiana.
30410         * tests/test-getlogin.c (main): Don't fail if getlogin() returns NULL
30411         with no errno.
30412         * tests/test-getlogin_r.c (main): Don't fail if getlogin_r() returns
30413         EINVAL.
30415 2020-12-29  Jim Meyering  <meyering@fb.com>
30417         regex-tests: tweak to avoid a clang-10 warning
30418         * tests/test-regex.c: Compare with explicit zero, rather than
30419         as boolean to avoid this from clang-10:
30420         test-regex.c:315:9: error: converting the result of '<<' to a \
30421           boolean always evaluates to true \
30422           [-Werror,-Wtautological-constant-compare]
30423         if (! REG_STARTEND)
30425         hash: add casts-to-float to avoid clang-10 warnings
30426         * lib/hash.c (compute_bucket_size): Cast SIZE_MAX to float
30427         to avoid this warning from clang-10 (for use in grep):
30428           hash.c:501:11: error: implicit conversion from 'unsigned long' \
30429             to 'float' changes value from 18446744073709551615 to \
30430             18446744073709551616 [-Werror,-Wimplicit-int-float-conversion]
30431           if (SIZE_MAX <= new_candidate)
30432         (hash_insert_if_absent): Likewise.
30434 2020-12-29  Paul Eggert  <eggert@cs.ucla.edu>
30436         canonicalize: fix size overflow treatment
30437         This also has some minor cleanups.
30438         * lib/canonicalize-lgpl.c, lib/canonicalize.c: No need to include
30439         stddef.h, since the code no longer refers directly to ptrdiff_t.
30440         * lib/canonicalize-lgpl.c (realpath_stk):
30441         * lib/canonicalize.c (canonicalize_filename_mode_stk):
30442         Treat size overflow like other out-of-memory.
30443         * lib/canonicalize.c: No need to include stdlib.h, since
30444         the code no longer refers to stdlib.h functions (other
30445         than those that canonicalize.h must declare).
30446         * lib/canonicalize.c (canonicalize_filename_mode_stk):
30447         Do not bother terminating the string result on error.
30449 2020-12-29  Bruno Haible  <bruno@clisp.org>
30451         list-c++, [o]map-c++, [o]set-c++: Fix conflict with 'free-posix' module.
30452         * lib/gl_list.hh: Include <stdlib.h>.
30453         * lib/gl_map.hh: Likewise.
30454         * lib/gl_omap.hh: Likewise.
30455         * lib/gl_set.hh: Likewise.
30456         * lib/gl_oset.hh: Likewise.
30458 2020-12-29  Paul Eggert  <eggert@cs.ucla.edu>
30460         canonicalize: fix ptrdiff_t overflow bug
30461         Problem reported by Adhemerval Zanella in:
30462         https://sourceware.org/pipermail/libc-alpha/2020-December/121182.html
30463         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
30464         Include intprops.h.
30465         (NARROW_ADDRESSES): New constant.
30466         * lib/canonicalize-lgpl.c (realpath_stk):m
30467         * lib/canonicalize.c (canonicalize_filename_mode_stk):
30468         Work even if strlen (END) does not fit in idx_t, or if adding
30469         N to it overflows.
30470         * modules/canonicalize, modules/canonicalize-lgpl (Depends-on):
30471         Add intprops.
30473 2020-12-28  Bruno Haible  <bruno@clisp.org>
30475         havelib: Fix for Solaris 11 OpenIndiana and Solaris 11 OmniOS.
30476         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): In
30477         acl_is_expected_elfclass, use 'expr', not 'test'.
30479 2020-12-28  Bruno Haible  <bruno@clisp.org>
30481         ptsname_r: Fix a compiler warning on Solaris.
30482         * lib/ptsname_r.c (__ptsname_r): Reduce the scope of variable 'err'.
30484 2020-12-28  Bruno Haible  <bruno@clisp.org>
30486         gnulib-tool: Fix logic whether to add a dummy.c.
30487         * gnulib-tool (func_remove_if_blocks): New function.
30488         (func_modules_add_dummy): Use it to eliminate all conditional statements
30489         from the automake snippet.
30491 2020-12-28  Paul Eggert  <eggert@cs.ucla.edu>
30493         faccessat: revert recent EOVERFLOW change
30494         I misunderstood the glibc source code.  Deduced from
30495         Adhemerval Zanella’s proposed glibc patch in:
30496         https://sourceware.org/pipermail/libc-alpha/2020-December/121131.html
30497         * doc/posix-functions/faccessat.texi: It is not a problem.
30498         * lib/canonicalize-lgpl.c, lib/canonicalize.c, lib/faccessat.c:
30499         (FACCESSAT_NEVER_OVERFLOWS): Remove. All uses removed.
30500         * lib/faccessat.c: Revert to simpler version now that
30501         LSTAT_FOLLOWS_SLASHED_SYMLINK must be false.
30502         * m4/faccessat.m4 (gl_FUNC_FACCESSAT_EOVERFLOW):
30503         Remove.  All uses removed.
30504         * modules/canonicalize, modules/canonicalize-lgpl (Files):
30505         Remove m4/faccessat.m4.
30507         canonicalize-lgpl: accommodate picky cpp
30508         * lib/canonicalize-lgpl.c: Use "defined FUNC_REALPATH_WORKS" in
30509         case preprocessor is picky.  Reported by Adhemerval Zanella in:
30510         https://sourceware.org/pipermail/libc-alpha/2020-December/121130.html
30512         canonicalize: simplify via scratch_buffer_dupfree
30513         * config/srclist.txt: Adjust accordingly.
30514         * lib/canonicalize-lgpl.c (realpath_stk):
30515         * lib/canonicalize.c (canonicalize_filename_mode_stk):
30516         Simplify by using scratch_buffer_dupfree.
30517         * lib/malloc/scratch_buffer.h (scratch_buffer_dupfree): New function.
30518         * lib/malloc/scratch_buffer_dupfree.c: New file.
30519         * modules/scratch_buffer (Files, Depends-on):
30520         Add malloc/scratch_buffer_dupfree.c.
30522 2020-12-27  Paul Eggert  <eggert@cs.ucla.edu>
30524         regex: remove glibc21.m4
30525         It doesn’t seem to be needed any more; at least, I couldn’t
30526         reproduce the circa-2013 problem.  Perhaps the recent
30527         --conditional-dependencies fixes have removed the need for it.
30528         * m4/glibc21.m4: Remove.  All uses removed.
30530 2020-12-26  Bruno Haible  <bruno@clisp.org>
30532         gnulib-tool: Make --conditional-dependencies work with --with-tests.
30533         Reported by Paul Eggert in
30534         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00236.html>.
30535         * gnulib-tool (func_emit_tests_Makefile_am): Handle conditional
30536         dependencies like func_emit_lib_Makefile_am.
30538 2020-12-26  Bruno Haible  <bruno@clisp.org>
30540         execvpe: Make dependency to stdbool explicit.
30541         * lib/execvpe.c: Include <stdbool.h>.
30542         * modules/execvpe (Depends-on): Add stdbool.
30544         execlp: Add tests.
30545         * tests/test-execlp-main.c: New file.
30546         * tests/test-execlp.sh: New file.
30547         * modules/execlp-tests: New file.
30549         execlp: New module.
30550         * lib/execlp.c: New file.
30551         * m4/execlp.m4: New file.
30552         * modules/execlp: New file.
30553         * doc/posix-functions/execlp.texi: Mention more Windows problems and the
30554         new module.
30556         execle: Add tests.
30557         * tests/test-execle-main.c: New file.
30558         * tests/test-execle.sh: New file.
30559         * modules/execle-tests: New file.
30561         execle: New module.
30562         * lib/execle.c: New file.
30563         * m4/execle.m4: New file.
30564         * modules/execle: New file.
30565         * doc/posix-functions/execle.texi: Mention more Windows problems and the
30566         new module.
30568         execl: Add tests.
30569         * tests/test-execl-main.c: New file.
30570         * tests/test-execl.sh: New file.
30571         * modules/execl-tests: New file.
30573         execl: New module.
30574         * lib/execl.c: New file.
30575         * m4/execl.m4: New file.
30576         * modules/execl: New file.
30577         * doc/posix-functions/execl.texi: Mention more Windows problems and the
30578         new module.
30580         execv: Add tests.
30581         * tests/test-execv-main.c: New file.
30582         * tests/test-execv.sh: New file.
30583         * modules/execv-tests: New file.
30585         execv: New module.
30586         * lib/execv.c: New file.
30587         * m4/execv.m4: New file.
30588         * modules/execv: New file.
30589         * doc/posix-functions/execv.texi: Mention more Windows problems and the
30590         new module.
30592         execvp: Add tests.
30593         * tests/test-execvp-main.c: New file.
30594         * tests/test-execvp.sh: New file.
30595         * modules/execvp-tests: New file.
30597         execvp: New module.
30598         * lib/execvp.c: New file.
30599         * m4/execvp.m4: New file.
30600         * modules/execvp: New file.
30601         * doc/posix-functions/execvp.texi: Mention more Windows problems and the
30602         new module.
30604         execvpe: Add tests.
30605         * tests/test-execvpe-main.c: New file.
30606         * tests/test-execvpe.sh: New file.
30607         * modules/execvpe-tests: New file.
30609         execvpe: New module.
30610         * lib/execvpe.c: New file.
30611         * m4/execvpe.m4: New file.
30612         * modules/execvpe: New file.
30613         * doc/glibc-functions/execvpe.texi: Mention the Windows problems and the
30614         new module.
30616         execve: Add tests.
30617         * tests/test-exec-child.c: New file.
30618         * tests/test-execve-main.c: New file.
30619         * tests/test-execve.sh: New file.
30620         * modules/execve-tests: New file.
30622         execve: New module.
30623         * lib/execve.c: New file.
30624         * m4/execve.m4: New file.
30625         * modules/execve: New file.
30626         * doc/posix-functions/execve.texi: Mention more Windows problems and the
30627         new module.
30629         execve, execvpe, execvp, execv, execl, execle, execlp: Prepare modules.
30630         * lib/unistd.in.h (execl, execle, execlp, execv, execve, execvp,
30631         execvpe): Add declarations for the new modules.
30632         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether execl, execle, execlp,
30633         execv, execve, execvp, execvpe are declared.
30634         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_EXEC*, HAVE_EXECVPE,
30635         REPLACE_EXEC*.
30636         * modules/unistd (Makefile.am): Substitute GNULIB_EXEC*, HAVE_EXECVPE,
30637         REPLACE_EXEC*.
30638         * tests/test-unistd-c++.cc: Check the signature of execl, execle,
30639         execlp, execv, execve, execvp, execvpe.
30641 2020-12-26  Bruno Haible  <bruno@clisp.org>
30643         stack: Fix typo in comments.
30644         * lib/stack.h: Fix typo in comments.
30646 2020-12-26  Bruno Haible  <bruno@clisp.org>
30648         bitset: Fix conflict with 'free-posix' module.
30649         * lib/bitset/base.h: Include <stdlib.h>.
30651 2020-12-25  Paul Eggert  <eggert@cs.ucla.edu>
30653         idx: change idx.h comment to LGPLv2.1+
30654         * lib/idx.h: Change license notice to match what should be in glibc.
30655         gnulib-tool will change it as appropriate anyway, so this is just
30656         to simplify syncing with glibc.
30658 2020-12-25  Thien-Thi Nguyen  <ttn@gnu.org>
30660         MODULES.html.sh: Update after 2020-12-19 change.
30661         * MODULES.html.sh (func_all_modules): Do s/free/free-posix/.
30663 2020-12-25  Bruno Haible  <bruno@clisp.org>
30665         Make it possible to turn off the mkdir override on Windows.
30666         * lib/sys_stat.in.h (mkdir): Conditionalize through GNULIB_MKDIR and
30667         GNULIB_MDA_MKDIR. Also support GNULIB_POSIXCHECK.
30668         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_MKDIR,
30669         GNULIB_MDA_MKDIR.
30670         * modules/sys_stat (Makefile.am): Substitute GNULIB_MKDIR,
30671         GNULIB_MDA_MKDIR.
30672         * modules/mkdir (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
30673         * doc/posix-functions/mkdir.texi: Mention also the 'sys_stat' module.
30675         Make it possible to turn off each of the Windows oldnames workarounds.
30676         * lib/fcntl.in.h (creat, open):  Conditionalize each of the Windows
30677         oldnames workarounds through a GNULIB_MDA_<func> symbol.
30678         * lib/math.in.h (j0, j1, jn, y0, y1, yn): Likewise.
30679         * lib/search.in.h (lfind, lsearch): Likewise.
30680         * lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
30681         Likewise.
30682         * lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
30683         * lib/string.in.h (memccpy, strdup): Likewise.
30684         * lib/sys_stat.in.h (chmod, umask): Likewise.
30685         * lib/time.in.h (tzset): Likewise.
30686         * lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
30687         execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
30688         read, rmdir, swab, unlink, write): Likewise.
30689         * lib/utime.in.h (utime): Likewise.
30690         * lib/wchar.in.h (wcsdup): Likewise.
30691         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize these
30692         GNULIB_MDA_<func> symbols.
30693         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Likewise.
30694         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Likewise.
30695         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
30696         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
30697         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
30698         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
30699         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Likewise.
30700         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
30701         * m4/utime_h.m4 (gl_UTIME_H_DEFAULTS): Likewise.
30702         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Likewise.
30703         * modules/fcntl-h (Makefile.am): Substitute these GNULIB_MDA_<func>
30704         symbols.
30705         * modules/math (Makefile.am): Likewise.
30706         * modules/search (Makefile.am): Likewise.
30707         * modules/stdio (Makefile.am): Likewise.
30708         * modules/stdlib (Makefile.am): Likewise.
30709         * modules/string (Makefile.am): Likewise.
30710         * modules/sys_stat (Makefile.am): Likewise.
30711         * modules/time (Makefile.am): Likewise.
30712         * modules/unistd (Makefile.am): Likewise.
30713         * modules/utime-h (Makefile.am): Likewise.
30714         * modules/wchar (Makefile.am): Likewise.
30716 2020-12-24  Paul Eggert  <eggert@cs.ucla.edu>
30718         canonicalize, canonicalize-lgpl: remove lint
30719         Pacify GCC.  Some of these problems were reported by Bruno Haible in:
30720         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00217.html
30721         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
30722         Sort shared include directives, for consistency.
30723         (IF_LINT): New macro.
30724         (suffix_requires_dir_check): Mark with _GL_ATTRIBUTE_PURE.
30725         * lib/canonicalize-lgpl.c (GCC_LINT, _GL_ATTRIBUTE_PURE) [_LIBC]:
30726         New macros.
30727         (realpath_stk): Suppress bogus -Wmaybe-uninitialized warning.
30728         * lib/canonicalize.c (canonicalize_filename_mode_stk):
30729         Omit unused local.  Suppress bogus -Wmaybe-uninitialized warning.
30731 2020-12-24  Bruno Haible  <bruno@clisp.org>
30733         spawn-pipe: Use posix_spawn by default on native Windows.
30734         * lib/spawn-pipe.c (SPAWN_PIPE_IMPL_AVOID_POSIX_SPAWN): New macro.
30735         (create_pipe): Use it to decide among the two possible implementations.
30736         * modules/spawn-pipe (Depends-on): Add posix_spawnattr_setpgroup.
30738 2020-12-24  Bruno Haible  <bruno@clisp.org>
30740         unistd-safer: Implement pipe_safer on native Windows.
30741         * lib/pipe-safer.c (pipe_safer): Don't test HAVE_PIPE.
30742         * modules/unistd-safer (Depends-on): Add pipe-posix.
30744 2020-12-24  Bruno Haible  <bruno@clisp.org>
30746         execute: Use posix_spawn by default on native Windows.
30747         * lib/execute.c (EXECUTE_IMPL_AVOID_POSIX_SPAWN): New macro.
30748         (execute): Use it to decide among the two possible implementations.
30750 2020-12-24  Paul Eggert  <eggert@cs.ucla.edu>
30752         canonicalize-lgpl: merge proposed libc changes
30753         This merges the changes proposed for glibc in:
30754         https://sourceware.org/pipermail/libc-alpha/2020-December/121085.html
30755         https://sourceware.org/pipermail/libc-alpha/2020-December/121086.html
30756         * lib/canonicalize-lgpl.c: Include idx.h and filename.h
30757         unconditionally.
30758         (idx_t, IDX_MAX, FILE_SYSTEM_PREFIX_LEN, IS_ABSOLUTE_FILE_NAME)
30759         (ISSLASH) [_LIBC]: Remove.
30761 2020-12-24  Bruno Haible  <bruno@clisp.org>
30763         posix_spawn-internal: Implement for native Windows.
30764         * lib/spawni.c (grow_inheritable_handles, shrink_inheritable_handles,
30765         close_inheritable_handles, memiszero, sigisempty, open_handle, do_open,
30766         do_dup2, do_close): New functions.
30767         (__spawni): Implement on native Windows.
30768         * modules/posix_spawn-internal (Depends-on): Add filename,
30769         concat-filename, findprog-in, malloca, windows-spawn.
30770         * doc/posix-functions/posix_spawn.texi: Update.
30771         * doc/posix-functions/posix_spawnp.texi: Likewise.
30773 2020-12-24  Bruno Haible  <bruno@clisp.org>
30775         windows-spawn: Export another auxiliary function.
30776         * lib/windows-spawn.h (convert_CreateProcess_error): New declaration.
30777         * lib/windows-spawn.c (convert_CreateProcess_error): New function,
30778         extracted from spawnpvech.
30779         (spawnpvech): Use it.
30781 2020-12-24  Bruno Haible  <bruno@clisp.org>
30783         windows-spawn: Export some more auxiliary functions.
30784         * lib/windows-spawn.h: Include <stdbool.h>.
30785         (struct inheritable_handles): New type.
30786         (init_inheritable_handles, compose_handles_block,
30787         free_inheritable_handles): New declarations.
30788         * lib/windows-spawn.c (init_inheritable_handles, compose_handles_block):
30789         New functions, based on spawnvech.
30790         (free_inheritable_handles): New function.
30791         (spawnpvech): Use them.
30793 2020-12-24  Bruno Haible  <bruno@clisp.org>
30795         windows-spawn: Export another auxiliary function.
30796         * lib/windows-spawn.h (compose_envblock): New declaration.
30797         * lib/windows-spawn.c (compose_envblock): New function, extracted from
30798         spawnpvech.
30799         (spawnpvech): Use it.
30801 2020-12-24  Bruno Haible  <bruno@clisp.org>
30803         windows-spawn: Export an auxiliary function.
30804         * lib/windows-spawn.h (compose_command): New declaration.
30805         * lib/windows-spawn.c (compose_command): New function, extracted from
30806         spawnpvech.
30807         (spawnpvech): Use it.
30809 2020-12-24  Bruno Haible  <bruno@clisp.org>
30811         posix_spawn* tests: Add support for native Windows.
30812         * tests/test-posix_spawn-open1.c (DATA_FILENAME): Treat native Windows
30813         like Cygwin.
30814         * tests/test-posix_spawn-dup2-stdin.c (main): Don't assume the signals
30815         SIGHUP and SIGPIPE. On native Windows, don't call
30816         posix_spawnattr_setsigmask.
30817         * tests/test-posix_spawn-dup2-stdout.c (main): Likewise.
30818         * tests/test-posix_spawn-fchdir.c (main): Likewise.
30819         * tests/test-posix_spawn-chdir.c (test): Likewise. Accept the child
30820         output from Cygwin's 'pwd' program.
30821         * tests/test-posix_spawn-script.c (main): On native Windows, skip the
30822         executable-shell-script part of the test.
30823         * tests/test-posix_spawnp-script.c (main): Likewise.
30824         * modules/posix_spawn-tests (Depends-on): Add freopen, waitpid.
30825         (configure.ac): Don't define the POSIX_SPAWN_PORTED conditional.
30826         (Makefile.am): Don't test the POSIX_SPAWN_PORTED conditional.
30827         * modules/posix_spawnp-tests (Depends-on): Add  waitpid.
30828         (configure.ac): Don't define the POSIX_SPAWN_PORTED conditional.
30829         (Makefile.am): Don't test the POSIX_SPAWN_PORTED conditional.
30830         * modules/posix_spawn_file_actions_addchdir-tests (Makefile.am): Don't
30831         test the POSIX_SPAWN_PORTED conditional.
30832         * modules/posix_spawn_file_actions_addfchdir-tests (configure.ac):
30833         Define the POSIX_SPAWN_PORTED conditional here.
30835 2020-12-24  Bruno Haible  <bruno@clisp.org>
30837         sh-filename: Add support for native Windows.
30838         * m4/sh-filename.m4 (gl_SH_FILENAME): Treat native Windows like Cygwin.
30840 2020-12-24  Paul Eggert  <eggert@cs.ucla.edu>
30842         careadlinkat: improve warning line number
30843         This propagates an idea first used in canonicalize-lgpl.
30844         * lib/careadlinkat.c (GCC_BOGUS_WRETURN_LOCAL_ADDR):
30845         New macro.
30846         (careadlinkat): Use it.
30848         linkat: use eloop-threshold
30849         * lib/linkat.c: Include eloop-threshold.h.
30850         Do not include sys/param.h.
30851         (MAXSYMLINKS): Remove.
30852         (link_follow, linkat_follow): Use __eloop_threshold instead
30853         of MAXSYMLINKS.
30854         * m4/linkat.m4 (gl_FUNC_LINKAT): Omit sys/param.h check.
30855         * modules/linkat (Depends-on): Add eloop-threshold.  Sort.
30857         canonicalize-lgpl: use eloop-threshold
30858         * lib/canonicalize-lgpl.c [!_LIBC]: Include eloop-threshold.h.
30859         (MAXSYMLINKS, __eloop_threshold): Remove.
30860         * modules/canonicalize-lgpl (Depends-on): Add eloop-threshold.
30862         eloop-threshold: new module
30863         * config/srclist.txt: Add a comment about it.
30864         * lib/eloop-threshold.h, modules/eloop-threshold: New files.
30866         canonicalize: prefer faccessat to stat
30867         A proper faccessat doesn't have the EOVERFLOW problem, and can be
30868         more efficient as it needn't gather data from the filesystem to
30869         fill in struct stat.  So use stat only if faccessat is absent,
30870         or when checking for symlink loops in canonicalize.c.
30871         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
30872         Include fcntl.h, for AT_EACCESS.
30873         (FACCESSAT_NEVER_EOVERFLOWS): Default to false.
30874         (file_accessible): New function, based on faccessat but with
30875         a fallback to stat and with an EOVERFLOW workaround.
30876         (dir_check): Use it.
30877         (dir_suffix): New static constant.
30878         * lib/canonicalize-lgpl.c (FACCESSAT_NEVER_EOVERFLOWS) [_LIBC]:
30879         Use __ASSUME_FACCESSAT2 to set FACCESSAT_NEVER_EOVERFLOWS
30880         (__faccessat) [!_LIBC]: Define.
30881         (realpath_stk): Use dir_suffix now.
30882         * lib/canonicalize.c (canonicalize_filename_mode_stk):
30883         If logical, don't check each component's existence; just check
30884         at the end, as that's enough.
30885         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
30886         (gl_CANONICALIZE_LGPL_SEPARATE):
30887         Require gl_FUNC_FACCESSAT_EOVERFLOW,
30888         gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, and check for faccessat.
30889         (gl_CANONICALIZE_LGPL_SEPARATE): Do not check for readlink,
30890         as the code does not use HAVE_READLINK.
30891         * modules/canonicalize, modules/canonicalize-lgpl (Files):
30892         Add m4/faccessat.m4, m4/lstat.m4.
30893         (Depends-on): Add fcntl-lh.
30895         faccessat: work around F_OK EOVERFLOW bug
30896         * doc/posix-functions/faccessat.texi: Mention the problem.
30897         * lib/faccessat.c (FACCESSAT_NEVER_EOVERFLOWS): Default to 0.
30898         (rpl_faccessat): If !FACCESSAT_NEVER_EOVERFLOWS, check
30899         for F_OK and EOVERFLOW, which means we can return 0.
30900         * m4/faccessat.m4 (gl_FUNC_FACCESSAT_EOVERFLOW): New macro.
30901         (gl_FUNC_FACCESSAT): Use it.
30903         stat failing with EOVERFLOW implies existence
30904         * lib/euidaccess.c (euidaccess):
30905         * lib/file-has-acl.c (file_has_acl):
30906         * lib/link.c (link, rpl_link):
30907         * lib/mkdir.c (rpl_mkdir):
30908         * lib/mkfifo.c (rpl_mkfifo):
30909         * lib/mknod.c (rpl_mknod):
30910         * lib/ptsname_r.c (__ptsname_r):
30911         * lib/symlink.c (rpl_symlink):
30912         * lib/symlinkat.c (rpl_symlinkat):
30913         * lib/unlink.c (rpl_unlink):
30914         * lib/unlinkat.c (rpl_unlinkat):
30915         * lib/utime.c (utime):
30916         If stat fails with EOVERFLOW the file exists, so treat it that way
30917         in file-existence tests that do not need struct stat values.
30919         canonicalize-lgpl: remove freea macro
30920         * lib/canonicalize-lgpl.c (freea) [_LIBC]: Remove; not needed.
30922         canonicalize, canonicalize-lgpl: fix symlink bug
30923         Problem reported by Adhemerval Zanella in:
30924         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00155.html
30925         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
30926         (suffix_requires_dir_check, dir_check): New functions.
30927         (GCC_BOGUS_WRETURN_LOCAL_ADDR): New macro, to put the diagnostic
30928         closer to the related GCC diagnostics.
30929         * lib/canonicalize-lgpl.c (realpath_stk):
30930         * lib/canonicalize.c (canonicalize_file_mode_stk):
30931         Use them to fix a bug with .../symlink-to-regular-file/ etc.
30932         * lib/canonicalize-lgpl.c (__stat) [!_LIBC]: New macro.
30933         (realpath_stk): New function,
30934         with the contents of the old __realpath and a new scratch buffer arg.
30935         This is needed to pacify GCC 10.1, as canonicalize.c is already doing.
30936         (__realpath): Use it.
30937         * tests/test-canonicalize-lgpl.c, tests/test-canonicalize.c:
30938         Add test cases for the bugs.
30940 2020-12-24  Bruno Haible  <bruno@clisp.org>
30942         execute: Treat signalled processes like wait-process does.
30943         * lib/execute.c: Include <sys/types.h>, <sys/wait.h>.
30944         (execute): Recognize the case where the exit code indicates a signalled
30945         child process.
30946         * tests/test-execute-main.c (main): Update expected test result.
30947         * modules/execute (Depends-on): Add sys_wait.
30949 2020-12-24  Bruno Haible  <bruno@clisp.org>
30951         windows-spawn: Improve errno upon failure on native Windows.
30952         * lib/windows-spawn.c (spawnpvech): Map the CreateProcess errors
30953         ERROR_BAD_FORMAT and ERROR_BAD_EXE_FORMAT to ENOEXEC.
30954         * tests/executable-script.sh: New file.
30955         * tests/test-posix_spawn-script.c (main): Also try executing
30956         executable-script.sh.
30957         * tests/test-posix_spawnp-script.c (main): Likewise.
30958         * tests/test-execute-script.c (main): Likewise.
30959         * tests/test-spawn-pipe-script.c (main): Likewise.
30960         * modules/posix_spawn-tests (Files): Add tests/executable-script.sh.
30961         * modules/posix_spawnp-tests (Files): Likewise.
30962         * modules/execute-tests (Files): Likewise.
30963         * modules/spawn-pipe-tests (Files): Likewise.
30965 2020-12-24  Bruno Haible  <bruno@clisp.org>
30967         findprog-in: Improve errno upon failure on native Windows.
30968         * lib/findprog-in.c (find_in_given_path): If the file basename has no
30969         dot and the search with a suffix returned no result, do also a search
30970         without a suffix, and set errno = ENOEXEC if we find a file in this way.
30971         * tests/test-spawn-pipe-script.c (main): Update expected errno.
30973 2020-12-23  Bruno Haible  <bruno@clisp.org>
30975         posix_spawn, posix_spawnp: Fix execution of scripts.
30976         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_SECURE): New macro.
30977         (gl_POSIX_SPAWN_BODY): Invoke it. Set REPLACE_POSIX_SPAWN if posix_spawn
30978         or posix_spawnp allows unsecure execution of scripts.
30979         * doc/posix-functions/posix_spawn.texi: Document the script execution
30980         problem.
30981         * doc/posix-functions/posix_spawnp.texi: Likewise.
30983 2020-12-23  Bruno Haible  <bruno@clisp.org>
30985         Add unit tests regarding execution of scripts.
30986         * tests/executable-script: New file.
30987         * tests/executable-shell-script: New file.
30988         * tests/test-posix_spawn-script.c: New file.
30989         * tests/test-posix_spawnp-script.c: New file.
30990         * tests/test-execute-script.c: New file.
30991         * tests/test-spawn-pipe-script.c: New file.
30992         * modules/posix_spawn-tests (Files): Add
30993         tests/test-posix_spawn-script.c, tests/executable-script,
30994         tests/executable-shell-script.
30995         (Makefile.am): Compile and run test-posix_spawn-script.
30996         * modules/posix_spawnp-tests (Files): Add
30997         tests/test-posix_spawnp-script.c, tests/executable-script,
30998         tests/executable-shell-script.
30999         (Makefile.am): Compile and run test-posix_spawnp-script.
31000         * modules/execute-tests (Files): Add tests/test-execute-script.c,
31001         tests/executable-script, tests/executable-shell-script.
31002         (Makefile.am): Compile and run test-execute-script.
31003         * modules/spawn-pipe-tests (Files): Add tests/test-spawn-pipe-script.c,
31004         tests/executable-script, tests/executable-shell-script.
31005         (Makefile.am): Compile and run test-spawn-pipe-script.
31007 2020-12-23  Bruno Haible  <bruno@clisp.org>
31009         Don't execute scripts without '#!' marker through /bin/sh.
31010         This reflects the change done in glibc through
31011         <https://sourceware.org/bugzilla/show_bug.cgi?id=13134> and
31012         <https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=d96de9634a334af16c0ac711074c15ac1762b23c>.
31013         * lib/spawni.c (internal_function): Remove macro.
31014         (script_execute): Remove function.
31015         (__spawni): Don't invoke script_execute.
31016         * lib/execute.c (execute): Disable the ENOEXEC handling.
31017         * lib/spawn-pipe.c (create_pipe): Likewise.
31018         * NEWS: Mention the change.
31020 2020-12-23  Bruno Haible  <bruno@clisp.org>
31022         posix_spawn[p]: Fix compilation error on Windows (regr. 2020-12-14).
31023         Reported by Adrian Ebeling <devl@adrian-ebeling.de> in
31024         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00189.html>.
31025         * lib/spawni.c (__spawni): Update function parameters.
31027 2020-12-23  Bruno Haible  <bruno@clisp.org>
31029         posix_spawn tests: Add two more tests.
31030         * tests/test-posix_spawn-inherit0.c: New file, based on
31031         tests/test-posix_spawn-open2.c.
31032         * tests/test-posix_spawn-inherit1.c: New file, based on
31033         tests/test-posix_spawn-open2.c.
31034         * modules/posix_spawn-tests (Files): Add them.
31035         (Depends-on): Add fflush.
31036         (Makefile.am): Compile and run test-posix_spawn-inherit0 and
31037         test-posix_spawn-inherit1.
31039 2020-12-23  Bruno Haible  <bruno@clisp.org>
31041         posix_spawn tests: Add another test.
31042         * tests/test-posix_spawn-open2.c: New file, based on
31043         tests/test-posix_spawn-open1.c.
31044         * modules/posix_spawn-tests (Files): Add it.
31045         (Makefile.am): Compile and run test-posix_spawn-open1.
31047 2020-12-20  Bruno Haible  <bruno@clisp.org>
31049         Remove support for broken <wchar.h> in AIX 3.
31050         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify test programs.
31052 2020-12-20  Bruno Haible  <bruno@clisp.org>
31054         Remove support for broken <wchar.h> in BSD/OS and OSF/1.
31055         * lib/wchar.in.h: Don't include <stdio.h>, <time.h>.
31056         * lib/mbchar.h: Likewise.
31057         * lib/mbiter.h: Likewise.
31058         * lib/mbuiter.h: Likewise.
31059         * m4/stdint.m4 (gl_STDINT_INCLUDES): Likewise.
31060         * lib/mbfile.h: Don't include <time.h>.
31061         * lib/mbswidth.h: Update comment.
31062         * lib/stdint.in.h: Don't include <stddef.h>, <stdio.h>, <time.h> before
31063         <wchar.h>.
31064         * lib/wctype.in.h: Likewise.
31065         * m4/btowc.m4 (gl_FUNC_BTOWC): Simplify test programs.
31066         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Likewise.
31067         * m4/iswdigit.m4 (gl_FUNC_ISWDIGIT): Likewise.
31068         * m4/iswxdigit.m4 (gl_FUNC_ISWXDIGIT): Likewise.
31069         * m4/mbrlen.m4 (gl_FUNC_MBRLEN, gl_MBRLEN_INCOMPLETE_STATE,
31070         gl_MBRLEN_RETVAL, gl_MBRLEN_NUL_RETVAL): Likewise.
31071         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Likewise.
31072         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC, gl_MBRTOWC_INCOMPLETE_STATE,
31073         gl_MBRTOWC_SANITYCHECK, gl_MBRTOWC_NULL_ARG1, gl_MBRTOWC_NULL_ARG2,
31074         gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL, gl_MBRTOWC_STORES_INCOMPLETE,
31075         AC_FUNC_MBRTOWC): Likewise.
31076         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Likewise.
31077         * m4/mbsnrtowcs.m4 (gl_MBSNRTOWCS_WORKS_IN_TRADITIONAL_LOCALE):
31078         Likewise.
31079         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS, gl_MBSRTOWCS_WORKS): Likewise.
31080         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
31081         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
31082         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Likewise.
31083         * m4/wchar_h.m4 (gl_WCHAR_H, gl_WCHAR_H_INLINE_OK): Likewise.
31084         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
31085         * m4/wcsdup.m4 (gl_FUNC_WCSDUP): Likewise.
31086         * m4/wcsnrtombs.m4 (gl_WCSNRTOMBS_WORKS_IN_TRADITIONAL_LOCALE):
31087         Likewise.
31088         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS, gl_WCSRTOMBS_TERMINATION,
31089         gl_WCSRTOMBS_NULL): Likewise.
31090         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Likewise.
31091         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
31092         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
31093         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
31094         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
31095         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Likewise.
31096         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Likewise.
31097         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Likewise.
31098         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Likewise.
31099         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Likewise.
31101 2020-12-20  Bruno Haible  <bruno@clisp.org>
31103         isnanf: Fix autoconf test.
31104         * m4/isnanf.m4 (gl_ISNANF_WORKS): Fix one of the NaN tests.
31106 2020-12-20  Bruno Haible  <bruno@clisp.org>
31108         Remove some of the support for obsolete IRIX 4 and 5.
31109         * m4/mountlist.m4 (AC_FUNC_GETMNTENT): Don't test for getmntent in
31110         libsun.
31111         * tests/init.sh (setup_): Don't talk about IRIX 5.
31113 2020-12-20  Bruno Haible  <bruno@clisp.org>
31115         filemode: Remove Cray support.
31116         * lib/filemode.c (IS_MIGRATED_FILE): Remove macro.
31117         (filemodestring): Don't produce an 'M' type.
31118         * m4/filemode.m4 (gl_FILEMODE): Don't invoke AC_STRUCT_ST_DM_MODE.
31119         * m4/st_dm_mode.m4: Remove file.
31120         * modules/filemode (Files): Remove it.
31122 2020-12-20  Paul Eggert  <eggert@cs.ucla.edu>
31124         free-posix: assume glibc 2.33 fixes this.
31125         * m4/free.m4 (gl_FUNC_FREE): Assume glibc 2.33+ is fixed.
31126         Use compile-time test rather than guessing for cross-builds.
31128 2020-12-20  Bruno Haible  <bruno@clisp.org>
31130         backupfile: Fix compilation error on native Windows (regr. 2018-10-23).
31131         Reported by Adrian Ebeling <adrianebeling@gmx.de> in
31132         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00156.html>.
31133         * lib/backupfile.c (fpathconf): Define fallback, like for pathconf.
31135 2020-12-20  Bruno Haible  <bruno@clisp.org>
31137         float: Fix compilation error when gnulib's float.h exists twice.
31138         Reported by Santiago Vila <sanvila@unex.es>.
31139         * lib/float.in.h (GNULIB_defined_long_double_union): New macro.
31141 2020-12-19  Bruno Haible  <bruno@clisp.org>
31143         free-posix: Assume future POSIX compliance only on OpenBSD and Solaris.
31144         * m4/free.m4 (gl_FUNC_FREE): Guess yes only on OpenBSD and Solaris.
31145         Don't trust _POSIX_VERSION for this test.
31147 2020-12-19  Paul Eggert  <eggert@cs.ucla.edu>
31149         free-posix: port to GNU/Linux
31150         * m4/free.m4 (gl_FUNC_FREE): Don’t assume GNU hosts are free of
31151         the bug, as it occurs on Ubuntu 20.10 x86-64 and, I assume, on
31152         other GNU/Linux hosts.
31154 2020-12-19  Bruno Haible  <bruno@clisp.org>
31156         free-posix: Add tests.
31157         * tests/test-free.c: New file.
31158         * tests/macros.h (ASSERT_NO_STDIO,
31159         WRITE_MACROEXPANDED_INTEGER_TO_STDERR, WRITE_INTEGER_TO_STDERR,
31160         WRITE_TO_STDERR): New macros.
31161         * modules/free-posix-tests: New file.
31163 2020-12-18  Bruno Haible  <bruno@clisp.org>
31165         free-posix: Add C++ declaration test.
31166         * tests/test-stdlib-c++.cc (free): New declaration.
31168 2020-12-18  Bruno Haible  <bruno@clisp.org>
31170         free-posix: New module, renamed from 'free'.
31171         * modules/free-posix: Renamed from modules/free.
31172         (configure.ac): Update gl_STDLIB_MODULE_INDICATOR invocation.
31173         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_FREE_POSIX,
31174         not GNULIB_FREE.
31175         * modules/stdlib (Makefile.am): Substitute GNULIB_FREE_POSIX, not
31176         GNULIB_FREE.
31177         * lib/stdlib.in.h (free): Test GNULIB_FREE_POSIX, not GNULIB_FREE.
31178         * doc/posix-functions/free.texi: Mention the module 'free-posix' and
31179         what it does.
31180         * NEWS: Mention that module 'free' no longer exists.
31181         * modules/canonicalize (Depends-on): Add free-posix. Remove free.
31182         * modules/canonicalize-lgpl (Depends-on): Likewise.
31184 2020-12-18  Bruno Haible  <bruno@clisp.org>
31186         free: Remove support for obsolete platforms.
31187         * m4/free.m4 (gl_FUNC_FREE): Assume free(NULL) works. Don't define
31188         CANNOT_FREE_NULL.
31189         * lib/free.c (rpl_free): Don't test CANNOT_FREE_NULL.
31190         * modules/free (Description): Update.
31191         * doc/posix-functions/free.texi: Don't mention SunOS 4 any more.
31193 2020-12-18  Paul Eggert  <eggert@cs.ucla.edu>
31195         intprops: port to ICC 2021.1 Beta 20201112
31196         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P):
31197         Port to ICC 2021.1, which has a non-working __builtin_mul_overflow_p.
31198         Add a clause for other compilers that claim to support
31199         __builtin_mul_overflow_p, since we might as well find out about
31200         slackers other than Clang and ICC.
31201         (INT_MULTIPLY_WRAPV): ICC 2021 has GCC bug 91450, so treat it
31202         like older GCCs even when it claims to be a newer one.
31204 2020-12-18  Bruno Haible  <bruno@clisp.org>
31206         intprops: Avoid potentially buggy __builtin_add_overflow in GCC 5, 6.
31207         Reported by Stefan Liebler <stli@linux.ibm.com> in
31208         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00152.html>.
31209         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW): Don't define for
31210         GCC 5.x and 6.x.
31211         * lib/glob.c (size_add_wrapv): Don't use __builtin_add_overflow for
31212         GCC 5.x and 6.x.
31214 2020-12-17  Bruno Haible  <bruno@clisp.org>
31216         free: Fix warning.
31217         Reported by Pádraig Brady <P@draigBrady.com> in
31218         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00148.html>.
31219         * lib/stdlib.in.h (free): New declaration.
31220         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether 'free' is declared.
31221         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_FREE, REPLACE_FREE.
31222         * modules/stdlib (Makefile.am): Substitute GNULIB_FREE, REPLACE_FREE.
31223         * m4/free.m4 (gl_FUNC_FREE): Set REPLACE_FREE, instead of defining
31224         'free' as a macro here.
31225         * modules/free (Depends-on): Add stdlib.
31226         (configure.ac): Test REPLACE_FREE. Invoke gl_STDLIB_MODULE_INDICATOR.
31228 2020-12-17  Paul Eggert  <eggert@cs.ucla.edu>
31230         canonicalize-lgpl: fix AIX test failures
31231         This merges the recent canonicalize.c fix into canonicalize-lgpl.c.
31232         Problem reported by Bruno Haible in:
31233         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00138.html
31234         * lib/canonicalize-lgpl.c: Include sys/stat.h.
31235         (__realpath): When testing a file name ending in '/', use stat
31236         rather than readlink, so that it does the right thing on AIX.
31237         * modules/canonicalize-lgpl (Depends-on): Add stat, sys_stat.
31239         canonicalize: omit second readlink when not needed
31240         * lib/canonicalize.c (canonicalize_filename_mode_stk):
31241         Omit second readlink when (can_exist != CAN_MISSING
31242         && startlen != 0 && !logical).  Simplify.
31244         canonicalize: remove arbitrary 8192-byte limit
31245         Remove canonicalize.c’s arbitrary 8192-byte limit on platforms
31246         like GNU Hurd that do not define the PATH_MAX macro, and similarly
31247         for canonicalize-lgpl.c’s arbitrary 1024-byte limit.  Do this by
31248         using scratch buffers.  Lessen the number of differences between
31249         the two source files, to simplify this and future maintenance.
31250         * lib/canonicalize-lgpl.c (__realpath):
31251         * lib/canonicalize.c (canonicalize_filename_mode_stk):
31252         Use scratch buffers instead of malloc and malloca.  This avoids
31253         the need for alloca, and avoids the need for malloc in most cases.
31254         * lib/canonicalize-lgpl.c, lib/canonicalize.c: Make these files
31255         easier to compare, e.g., by sorting include files and by switching
31256         to the GNU convention of calling file names "file names", not
31257         "path names".  Include stdbool.h, scratch_buffer.h.
31258         * lib/canonicalize-lgpl.c (IDX_MAX) [_LIBC]: New macro.
31259         (malloca) [_LIBC]: Remove.
31260         [!_LIBC]: Do not include malloca.h.
31261         (get_path_max): New function, so that pathconf is called only in
31262         the rare and dubious case when when RESOLVED is not null and
31263         PATH_MAX is not defined.  Invoke pathconf on "/" not the input
31264         file name, as we care about the longest file name starting from
31265         "/" (not from the input file name), and POSIX does not specify
31266         what pathconf does on a non-directory file anyway.  If PATH_MAX is
31267         not defined, do not worry about overriding a path_max of 0, and do
31268         not let path_max exceed IDX_MAX.
31269         (__realpath): Remove an assumption that file name components
31270         cannot exceed 1024 bytes when PATH_MAX is not defined (wrong for
31271         the Hurd, presumably).
31272         When allocating the result, allocate it to just the right size;
31273         this costs nothing when the result is smaller than 1023 bytes,
31274         and for larger results it's probably worth the CPU to call realloc,
31275         as canonicalize.c already does.
31276         * lib/canonicalize.c: Include attribute.h.
31277         Do not include pathmax.h or xgetcwd.h.
31278         (PATH_MAX): Do not define, so file names longer than 8192 bytes
31279         work on platforms with no fixed limit.
31280         (canonicalize_filename_mode_stk): New function, with
31281         the content of the old canonicalize_filename_mode.
31282         Use getcwd instead of xgetcwd, and readlink instead of areadlink,
31283         since the scratch buffers now do memory management for us.
31284         Use rawmemchr instead of adding strlen.
31285         Use mempcpy instead of mempcpy + size.
31286         Assume free preserves errno.
31287         (canonicalize_filename_mode): Use it.
31288         * modules/canonicalize (Depends-on): Remove areadlink, pathmax,
31289         xgetcwd.  Add attribute, free, getcwd, mempcpy, rawmemchr,
31290         scratch_buffer, stdbool, xalloc-die.
31291         * modules/canonicalize-lgpl (Depends-on): Remove alloca-opt,
31292         malloca, realloc-posix.  Add scratch_buffer, stdbool.
31294         canonicalize-lgpl: simplify merge to glibc
31295         This patch lessens the differences between git glibc
31296         stdlib/canonicalize.c and lib/canonicalize-lgpl.c.
31297         The (perhaps wishful) goal is to make them identical.
31298         * lib/canonicalize-lgpl.c [!_LIBC]:
31299         Include <libc-config.h>, not config.h.
31300         Omit an unnecessary (!HAVE_CANONICALIZE_FILE_NAME ||
31301         !FUNC_REALPATH_WORKS || defined _LIBC) #if.
31302         Do not include alloca.h, since we use malloca now.
31303         [_LIBC]: Include <eloop-threshold.h>, and define dummy macros
31304         FILE_SYSTEM_PREFIX_LEN, IS_ABSOLUTE_FILE_NAME, ISSLASH, malloca,
31305         freea so that the mainline code can be kept #ifdef free.
31306         [!_LIBC]: Remove dummy macros for SHLIB_COMPAT, versioned_symbol,
31307         compat_symbol, weak_alias, __set_errno since libc-config.h does that.
31308         Add redirecting macros __mempcpy, __pathconf, __rawmemchr,
31309         __eloop_threshold.  All uses of their definiens changed.
31310         (SIZE_MAX): Remove; no longer needed.
31311         (alloc_failed): Remove, and remove all instances.
31312         No need for alloc_failed now that free preserves errno.
31313         (__realpath): Default path_max to 1024 instead of 8192, as that’s
31314         the glibc tradition and is safer when the 2nd argument is null.
31315         Use __rawmemchr instead of strchr.
31316         Use __mempcpy where appropriate.
31317         Simplify test for overflow so that it does not need SIZE_MAX.
31318         Do not preserve errno around free or freea calls; no longer needed.
31319         Mark __realpath with libc_hidden_def.
31320         * modules/canonicalize-lgpl (Depends-on): Add free, libc-config,
31321         malloc-posix, mempcpy, realloc-posix, rawmemchr.
31322         * modules/free: Now LGPLv2+, for canonicalize-lgpl.
31324         free: preserve errno
31325         * lib/free.c (rpl_free): Preserve errno.  Check for null only if
31326         CANNOT_FREE_NULL is defined, as an optimization for POSIX 2008
31327         platforms that do not preserve errno.
31328         * m4/free.m4 (gl_FUNC_FREE): Check whether free preserves errno.
31329         Also, define CANNOT_FREE_NULL if free cannot free NULL.
31330         * modules/free (configure.ac): Also replace 'free' if
31331         it does not preserve errno.
31333         idx: simplify IDX_MAX, remove IDX_WIDTH
31334         * lib/idx.h (IDX_MAX): Simplify by removing obsolete reference
31335         to UNSIGNED_IDX_T.
31336         (IDX_WIDTH): Remove, since it’s not used and its value
31337         arguably should be PTRDIFF_WIDTH anyway.
31339 2020-12-16  Bruno Haible  <bruno@clisp.org>
31341         posix_spawn_file_actions_addfchdir-tests: Rename test.
31342         * tests/test-posix_spawn-fchdir.c: Renamed from
31343         tests/test-posix_spawn5.c.
31344         * modules/posix_spawn_file_actions_addfchdir-tests (Files, Makefile.am):
31345         Update.
31347         posix_spawn_file_actions_addchdir-tests: Rename test.
31348         * tests/test-posix_spawn-chdir.c: Renamed from
31349         tests/test-posix_spawn4.c.
31350         * modules/posix_spawn_file_actions_addchdir-tests (Files, Makefile.am):
31351         Update.
31353         posix_spawn-tests: Rename test.
31354         * tests/test-posix_spawn-open1.c: Renamed from
31355         tests/test-posix_spawn3.c.
31356         * modules/posix_spawn-tests (Files, Makefile.am): Update.
31358         posix_spawnp-tests: Rename test.
31359         * tests/test-posix_spawn-dup2-stdin.c: Renamed from
31360         tests/test-posix_spawn2.c.
31361         * tests/test-posix_spawn-dup2-stdin.in.sh: Renamed from
31362         tests/test-posix_spawn2.in.sh.
31363         * modules/posix_spawnp-tests (Files, Makefile.am): Update.
31365         posix_spawnp-tests: Rename test.
31366         * tests/test-posix_spawn-dup2-stdout.c: Renamed from
31367         tests/test-posix_spawn1.c.
31368         * tests/test-posix_spawn-dup2-stdout.in.sh: Renamed from
31369         tests/test-posix_spawn1.in.sh.
31370         * modules/posix_spawnp-tests (Files, Makefile.am): Update.
31372 2020-12-14  Bruno Haible  <bruno@clisp.org>
31374         findprog-in: Allow overriding the current directory.
31375         * lib/findprog.h (find_in_given_path): Add directory argument.
31376         * lib/findprog-in.c (find_in_given_path): Likewise.
31377         * lib/execute.c (execute): Update caller.
31378         * lib/spawn-pipe.c (create_pipe): Likewise.
31379         * lib/windows-spawn.c (spawnpvech): Likewise.
31380         * NEWS: Mention the change.
31382 2020-12-14  Bruno Haible  <bruno@clisp.org>
31384         posix_spawn-internal: Make better use of 'const'.
31385         * lib/spawn_int.h (__spawni): Does not need write access to the elements
31386         of argv and envp.
31387         * lib/spawni.c (__spawni, script_execute): Likewise.
31388         * lib/spawn.c (posix_spawn): Update caller.
31389         * lib/spawnp.c (posix_spawnp): Likewise.
31391 2020-12-14  Bruno Haible  <bruno@clisp.org>
31393         spawn: Make it compile on native Windows.
31394         * modules/spawn (Depends-on): Add signal-h.
31396 2020-12-14  Bruno Haible  <bruno@clisp.org>
31398         windows-spawn: Avoid shadowing a variable.
31399         * lib/windows-spawn.c (spawnpvech): Rename local variable 'flags'.
31401 2020-12-13  Paul Eggert  <eggert@cs.ucla.edu>
31403         string: port memchr macro to AIX 7.2 XLC
31404         Its <string.h> defines a memchr macro to help inlining.
31405         * lib/string.in.h (memchr): #undef before #defining.
31407         canonicalize: fix AIX test failures
31408         Problem reported by Bruno Haible in:
31409         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00109.html
31410         * lib/canonicalize.c (canonicalize_filename_mode):
31411         When testing a file name ending in '/', use stat rather than
31412         readlink, so that it does the right thing on AIX.
31413         * modules/canonicalize (Depends-on): Add readlink, to pull in the
31414         recent changes in the Gnulib readlink module.
31416         Assume readlink/readlinkat ERANGE fix
31417         * lib/areadlink-with-size.c (areadlink_with_size):
31418         * lib/areadlinkat-with-size.c (areadlinkat_with_size):
31419         * lib/careadlinkat.c (readlink_stk):
31420         Do not worry about readlink or readlinkat failing with errno == ERANGE,
31421         since the Gnulib readlink and readlinkat modules now fix that.
31423         getcwd: port to AIX
31424         * lib/getcwd.c [!_LIBC]: Undef stat64 before #defining it,
31425         in case our sys/stat.h #defined a function macro with the same name.
31427         readlink, readlinkat: add ERANGE portability
31428         Fix some portability issues with Gnulib's readlink and readlinkat,
31429         notably mostly working around the ERANGE problem in AIX and HP-UX.
31430         * doc/posix-functions/readlink.texi:
31431         * doc/posix-functions/readlinkat.texi:
31432         ERANGE problem is mostly fixed now.  Mention AIX problem with
31433         trailing / and EINVAL.  Lessen differences between these two files.
31434         * lib/readlink.c (rpl_readlink):
31435         * lib/readlinkat.c (rpl_readlinkat):
31436         If stat ("FILE/", ...) reports EOVERFLOW, treat FILE/ as an
31437         existing directory.  Mostly work around READLINK_TRUNCATE BUG.
31438         Lessen spurious differences between the readlink and readlinkat code.
31439         * lib/readlinkat.c (rpl_readlinkat):
31440         Fix bug where stat was used where fstatat was intended.
31441         * m4/readlink.m4 (gl_FUNC_READLINK):
31442         Rename gl_cv_func_readlink_works to gl_cv_func_readlink_trailing_slash
31443         to identify readlink problems more precisely.  All uses changed.
31444         Guess no on AIX or HP-UX for this variable.
31445         Add check for whether readlink truncates results,
31446         and define new macro READLINK_TRUCATE_BUG accordingly.
31447         * m4/readlinkat.m4 (gl_FUNC_READLINKAT):
31448         Also check gl_cv_func_readlink_trailing_slash when deciding
31449         whether to replace readlinkat.
31450         * modules/readlinkat (Depends-on): Most dependencies are also
31451         needed if replacing readlinkat.  fstatat is different, as it
31452         is needed only if replacing an existing readlinkat.
31454 2020-12-13  Bruno Haible  <bruno@clisp.org>
31456         spawn-pipe: Fix hanging processes on Windows (regression 2020-11-30).
31457         * lib/spawn-pipe.c (create_pipe): After spawning the subprocess, close
31458         the stdin_handle and/or stdout_handle.
31460 2020-12-12  Bruno Haible  <bruno@clisp.org>
31462         Fix gnulib-tool error when some modules occur in tests/.
31463         * doc/gnulib.texi (Specification): Update statistics.
31464         (Autoconf macros): Don't suggest to use AC_LIBOBJ in a .m4 file.
31465         (Using AC_LIBOBJ): New section.
31466         * check-AC_LIBOBJ: New file.
31467         * modules/fnmatch-gnu (Files): Add lib/fnmatch.c.
31468         * modules/fopen-gnu (Files): Add lib/fopen.c.
31469         * modules/memmem (Files): Add lib/memmem.c.
31470         * modules/renameat (Files): Add lib/at-func2.c.
31471         * modules/strcasestr (Files): Add lib/strcasestr.c.
31472         * modules/strstr (Files): Add lib/strstr.c.
31474 2020-12-11  Bruno Haible  <bruno@clisp.org>
31476         sh-quote, execute, spawn-pipe, etc.: Make better use of 'const'.
31477         * lib/sh-quote.h (shell_quote_argv): Does not need write access to the
31478         elements of argv.
31479         * lib/sh-quote.c (shell_quote_argv): Likewise.
31480         * lib/windows-spawn.h (prepare_spawn): Add 'const' the argument type and
31481         the return type.
31482         * lib/windows-spawn.c (prepare_spawn): Likewise.
31483         * lib/os2-spawn.h (prepare_spawn): Likewise.
31484         * lib/os2-spawn.c (prepare_spawn): Likewise.
31485         * lib/execute.h (execute): Does not need write access to the elements of
31486         prog_argv.
31487         * lib/execute.c (execute): Likewise.
31488         * lib/spawn-pipe.h (create_pipe_out, create_pipe_in, create_pipe_bidi):
31489         Likewise.
31490         * lib/spawn-pipe.c (create_pipe, create_pipe_bidi, create_pipe_in,
31491         create_pipe_out): Likewise.
31492         * lib/pipe-filter.h (pipe_filter_ii_execute, pipe_filter_gi_create):
31493         Likewise.
31494         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Likewise.
31495         * lib/pipe-filter-gi.c (pipe_filter_gi_create): Likewise.
31496         * lib/javaexec.h (execute_fn): Does not need write access to the
31497         elements of prog_argv.
31498         * lib/javaexec.c (execute_java_class): Update variable types and remove
31499         casts to 'char *'.
31500         * lib/csharpexec.h (execute_fn): Does not need write access to the
31501         elements of prog_argv.
31502         * lib/csharpexec.c (execute_csharp_using_mono,
31503         execute_csharp_using_sscli): Update variable types and remove casts to
31504         'char *'.
31505         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
31506         compile_using_javac, compile_using_jikes, is_envjavac_gcj,
31507         is_envjavac_gcj43, is_gcj_present, is_gcj_43, is_javac_present,
31508         is_jikes_present): Update variable types and remove casts to 'char *'.
31509         * lib/javaversion.c (execute_and_read_line): Does not need write access
31510         to the elements of prog_argv.
31511         * lib/csharpcomp.c (compile_csharp_using_mono,
31512         compile_csharp_using_sscli): Update variable types and remove casts to
31513         'char *'.
31514         * tests/test-sh-quote.c (main): Update variable types and remove casts
31515         to 'char *'.
31516         * tests/test-execute-main.c (main): Update variable types and remove
31517         casts to 'char *'.
31518         * tests/test-spawn-pipe-main.c (test_pipe): Update variable types and
31519         remove casts to 'char *'.
31520         * NEWS: Mention the changes.
31522 2020-12-11  Bruno Haible  <bruno@clisp.org>
31524         execute-tests: Fix compilation error with MSVC.
31525         * tests/test-execute-child.c (is_device): With _fstat, use
31526         'struct _stat', not 'struct stat'.
31528 2020-12-11  Paul Eggert  <eggert@cs.ucla.edu>
31530         vararrays: just use 2.70
31531         * m4/vararrays.m4 (AC_C_VARARRAYS): Do not override Autoconf 2.70
31532         and later, since Autoconf 2.70 matches Gnulib now.
31534         sys_types: just use 2.70
31535         * m4/sys_types_h.m4 (AC_HEADER_MAJOR):
31536         Reindent to match Autoconf sources.
31537         Use Autoconf 2.70 as a prerequisite, not 2.69c.
31539         stdint: port to Autoconf 2.70
31540         * m4/stdint.m4 (gl_STDINT_H): Check for inttypes.h and sys/types.h
31541         instead of assuming that AC_INCLUDES_DEFAULT does it.
31542         The old code relied on AC_INCLUDES_DEFAULT being called
31543         and setting ac_cv_header_inttypes_h and ac_cv_header_sys_types_h,
31544         but this does not occur in Autoconf 2.70.
31546         pid_t.m4: just use 2.70
31547         * m4/pid_t.m4 (AC_TYPE_PID_T):
31548         Use Autoconf 2.70 as a prerequisite, not 2.69c.
31550         largefile: just use 2.70
31551         * m4/largefile.m4 (_AC_SYS_LARGEFILE_TEST_INCLUDES):
31552         Use Autoconf 2.70 as a prerequisite, not 2.69c.
31554         AC_C_RESTRICT: update from Autoconf
31555         * m4/gnulib-common.m4 (gl_PROG_CC_C99): Use Autoconf 2.70
31556         as a prerequisite, not 2.69c, since 2.70 is now out.
31557         (AC_C_RESTRICT): Define only for 2.70 or earlier.
31558         Try __restrict__ before __restrict.
31560         extensions: update from Autoconf
31561         * m4/extensions.m4 (AC_CHECK_INCLUDES_DEFAULT):
31562         Provide a default implementation for Autoconf 2.69 or earlier.
31563         (AC_USE_SYSTEM_EXTENSIONS): Copy from Autoconf git.  Define only
31564         if Autoconf 2.70 or earlier, since 2.70.1 or later should be OK.
31566         alloca: update from Autoconf
31567         * m4/alloca.m4 (gl_PREREQ_ALLOCA):
31568         Trivial update to match Autoconf 2.70.
31570 2020-12-11  Bruno Haible  <bruno@clisp.org>
31572         memchr: Work around memory overrun bug on AIX 7.2.
31573         * m4/memchr.m4 (gl_FUNC_MEMCHR): Test against AIX 7.2 bug.
31574         * doc/posix-functions/memchr.texi: Mention the AIX bug.
31576 2020-12-11  Bruno Haible  <bruno@clisp.org>
31578         execute-tests: Fix compilation error on AIX in 32-bit mode.
31579         * tests/test-execute-child.c: In order to get the original definition of
31580         fstat, don't use '#undef fstat' and '#undef stat'. Instead, arrange to
31581         include the system's <sys/stat.h> and use it before including other
31582         header files.
31584 2020-12-10  Bruno Haible  <bruno@clisp.org>
31586         windows-spawn: Relicense under LGPLv2+.
31587         * modules/windows-spawn (License): Change to LGPLv2+.
31589 2020-12-10  Bruno Haible  <bruno@clisp.org>
31591         execute, spawn-pipe: Fix memory leak on native Windows.
31592         * lib/windows-spawn.h (prepare_spawn): Add a second parameter.
31593         * lib/windows-spawn.c: Don't include xalloc.h.
31594         (quoted_arg_length, quoted_arg_string): New functions, extracted from
31595         prepare_spawn.
31596         (prepare_spawn): Use malloc instead of XNMALLOC. Allocate memory for all
31597         elements of *new_argv together.
31598         * modules/windows-spawn (Depends-on): Remove xalloc. Add malloc-posix.
31599         * lib/os2-spawn.h (prepare_spawn): Add a second parameter.
31600         * lib/os2-spawn.c: Don't include xalloc.h.
31601         (prepare_spawn): Use malloc instead of XNMALLOC. Allocate memory for all
31602         elements of *new_argv together.
31603         * lib/execute.c: Include xalloc.h.
31604         (execute): Check return value of prepare_spawn. Free the memory
31605         allocated by prepare_spawn.
31606         * modules/execute (Depends-on): Add xalloc-die.
31607         * lib/spawn-pipe.c: Include xalloc.h.
31608         (create_pipe): Check return value of prepare_spawn. Free the memory
31609         allocated by prepare_spawn.
31610         * modules/spawn-pipe (Depends-on): Add xalloc-die.
31612 2020-12-10  Bruno Haible  <bruno@clisp.org>
31614         findprog-in: Relicense under LGPLv2+.
31615         Paul Smith's approval is in
31616         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00072.html>.
31617         * modules/findprog-in (License): Change to LGPLv2+.
31619 2020-12-10  Bruno Haible  <bruno@clisp.org>
31621         findprog-in: Don't exit upon out-of-memory.
31622         * lib/findprog.h (find_in_given_path): Document ENOMEM as possible error
31623         code.
31624         * lib/findprog-in.c: Don't include xalloc.h.
31625         (find_in_given_path): Call concatenated_filename, not
31626         xconcatenated_filename. Call strdup, not xstrdup. Upon out-of-memory,
31627         return NULL with errno set.
31628         * modules/findprog-in (Depends-on): Remove xconcat-filename, xalloc. Add
31629         concat-filename, strdup-posix, malloc-posix.
31631 2020-12-09  Bruno Haible  <bruno@clisp.org>
31633         fmaf: Work around a bug on FreeBSD 12.2/arm.
31634         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Add one more test.
31635         * doc/posix-functions/fmaf.texi: Mention the FreeBSD bug.
31637 2020-12-09  Bruno Haible  <bruno@clisp.org>
31639         threadlib: Fix test-fstrcmp failure on FreeBSD 11.
31640         * m4/threadlib.m4 (gl_THREADLIB_BODY): When weak symbols are not present
31641         on FreeBSD, define PTHREAD_IN_USE_DETECTION_HARD.
31642         * lib/glthread/threadlib.c: Include <errno.h>.
31643         (glthread_in_use): For FreeBSD, provide an alternative implementation
31644         that uses pthread_key_create.
31646 2020-12-09  Bruno Haible  <bruno@clisp.org>
31648         math C++ tests: Fix compilation error in with clang >= 7 on FreeBSD.
31649         * lib/math.in.h (isnan): For clang >= 7 on FreeBSD, declare 'rpl_isnan',
31650         not 'isnan'.
31652 2020-12-08  Bruno Haible  <bruno@clisp.org>
31654         std-gnu11: Make compatible with Autoconf 2.70.
31655         * m4/std-gnu11.m4: Disable the entire file if Autoconf >= 2.70 is in
31656         use.
31658 2020-12-08  Bruno Haible  <bruno@clisp.org>
31660         argp: Avoid undefined behaviour when invoking qsort().
31661         This fixes a test-argp-2.sh test failure on macOS and FreeBSD.
31662         Reported by Jeffrey Walton <noloader@gmail.com> in
31663         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00085.html>.
31664         * lib/argp-help.c (group_cmp): Remove third argument.
31665         (hol_sibling_cluster_cmp, hol_cousin_cluster_cmp): New functions, based
31666         upon hol_cluster_cmp.
31667         (hol_cluster_cmp): Use hol_cousin_cluster_cmp.
31668         (hol_entry_cmp): Rewritten to implement a total order.
31670 2020-12-08  Bruno Haible  <bruno@clisp.org>
31672         argp: Improve comments.
31673         * lib/argp-help.c: Add sectioning comments. Write NULL to designate a
31674         null pointer.
31675         (struct hol_entry): Fix comment regarding sort order of group.
31676         (hol_entry_short_iterate, hol_entry_long_iterate): Add comment.
31677         (until_short, canon_doc_option, hol_entry_qcmp): Improve comment.
31678         (hol_cluster_is_child, argp_hol): Move functions.
31679         (HOL_ENTRY_PTRCMP): Remove unused macro.
31681 2020-12-08  Bruno Haible  <bruno@clisp.org>
31683         argp: Don't pass invalid arguments to isspace() and isalnum().
31684         * lib/argp-help.c (canon_doc_option): Cast character to 'unsigned int'
31685         before passing it to isspace() or isalnum().
31687 2020-12-08  Bruno Haible  <bruno@clisp.org>
31689         argp: Don't rely on undefined behaviour of _tolower().
31690         Patch by Eric Blake
31691         <https://lists.gnu.org/archive/html/bug-gnulib/2009-09/msg00287.html>.
31692         * lib/argp-help.c (hol_entry_cmp): Don't use _tolower on values that are
31693         not upper-case.  Pass correct range to tolower.
31695 2020-12-07  Bruno Haible  <bruno@clisp.org>
31697         unicodeio: Fix wrong result on FreeBSD.
31698         * lib/unicodeio.c (unicode_to_mb): Handle question mark fallback
31699         characters on all platforms.
31701 2020-12-07  Bruno Haible  <bruno@clisp.org>
31703         get-rusage-data tests: Avoid test failure on FreeBSD/x86_64.
31704         * tests/test-get-rusage-data.c (main): Don't expect a strict increase on
31705         FreeBSD systems.
31707 2020-12-07  Bruno Haible  <bruno@clisp.org>
31709         get-rusage-data: Fix link error on FreeBSD 12.2/arm64.
31710         * modules/get-rusage-data (configure.ac): Test whether sbrk exists.
31711         * lib/get-rusage-data.c (get_rusage_data_via_setrlimit): Define
31712         trivially of sbrk is not available.
31713         * doc/glibc-functions/sbrk.texi: Mention that the function does not
31714         exist in FreeBSD 12.2/arm64.
31715         * doc/glibc-functions/brk.texi: Likewise.
31717 2020-12-07  Bruno Haible  <bruno@clisp.org>
31719         Correct interaction between gl_ANSI_CXX and AC_PROG_CXX.
31720         Suggested by Zack Weinberg in
31721         <https://savannah.gnu.org/support/?110294>.
31722         * m4/ansi-c++.m4 (gl_ANSI_CXX): Mark AC_PROG_CXX as provided.
31723         * modules/uchar-c++-tests: Revert the workaround from 2020-08-18.
31725 2020-12-07  Bruno Haible  <bruno@clisp.org>
31727         Tweak the Windows oldnames workaround.
31728         Reported by Daniel R. Hurtmans <Daniel.Hurtmans@ulb.ac.be> in
31729         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00073.html>.
31730         * lib/unistd.in.h: On native Windows, include <io.h> and <direct.h>
31731         always.
31732         (getcwd): Use _GL_CXXALIAS_MDA_CAST.
31733         * lib/stdlib.in.h (putenv): Likewise.
31735 2020-12-06  Paul Eggert  <eggert@cs.ucla.edu>
31737         doc: fix flat address space discussion
31738         * doc/gnulib-readme.texi (Other portability assumptions):
31739         Move the all-bits-zero assumption outside the flat address space
31740         section, since the two issues are independent.
31742         doc: document -static-libubsan more
31743         * doc/gnulib-readme.texi (High Quality): Document pros and cons of
31744         -static-libubsan a bit more.  Mostly cons.
31746 2020-12-06  Bruno Haible  <bruno@clisp.org>
31748         doc: Add more details regarding the undefined behaviour sanitizer.
31749         * doc/gnulib-readme.texi (High Quality): Describe
31750         -fsanitize-undefined-trap-on-error better.
31752 2020-12-06  Bruno Haible  <bruno@clisp.org>
31754         Do the Windows oldnames workaround through the C++ GNULIB_NAMESPACE.
31755         Reported by Daniel R. Hurtmans <Daniel.Hurtmans@ulb.ac.be> in
31756         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00029.html>.
31757         * lib/c++defs.h (_GL_CXXALIAS_MDA_CAST): New macro.
31758         * lib/fcntl.in.h (creat, open):  In C++ mode, when GNULIB_NAMESPACE is
31759         defined: 1. Define a symbol in this namespace. 2. Don't redirect using
31760         a preprocessor #define.
31761         * lib/math.in.h (j0, j1, jn, y0, y1, yn): Likewise.
31762         * lib/search.in.h (lfind, lsearch): Likewise.
31763         * lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
31764         Likewise.
31765         * lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
31766         * lib/string.in.h (memccpy, strdup): Likewise.
31767         * lib/sys_stat.in.h (chmod, umask): Likewise.
31768         * lib/time.in.h (tzset): Likewise.
31769         * lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
31770         execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
31771         read, rmdir, swab, unlink, write): Likewise.
31772         * lib/utime.in.h (utime): Likewise.
31773         * lib/wchar.in.h (wcsdup): Likewise.
31774         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_FCLOSEALL.
31775         (gl_STDIO_H): Set HAVE_DECL_FCLOSEALL.
31776         * modules/stdio (Makefile.am): Substitute HAVE_DECL_FCLOSEALL.
31777         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_ECVT,
31778         HAVE_DECL_FCVT, HAVE_DECL_GCVT.
31779         (gl_STDLIB_H): Set HAVE_DECL_ECVT, HAVE_DECL_FCVT, HAVE_DECL_GCVT.
31780         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_ECVT,
31781         HAVE_DECL_FCVT, HAVE_DECL_GCVT.
31782         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_EXECVPE.
31783         (gl_UNISTD_H): Set HAVE_DECL_EXECVPE.
31784         * modules/unistd (Makefile.am): Substitute HAVE_DECL_EXECVPE.
31785         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize HAVE_DECL_WCSDUP.
31786         (gl_WCHAR_H): Set HAVE_DECL_WCSDUP.
31787         * modules/wchar (Makefile.am): Substitute HAVE_DECL_WCSDUP.
31789 2020-12-06  Bruno Haible  <bruno@clisp.org>
31791         doc: Mention some missing function declarations.
31792         * doc/glibc-functions/execvpe.texi: Mention the missing declaration on
31793         AIX.
31794         * doc/glibc-functions/fcloseall.texi: Mention the missing declaration on
31795         FreeBSD.
31796         * doc/pastposix-functions/ecvt.texi: Mention the missing declaration on
31797         Cygwin.
31798         * doc/pastposix-functions/fcvt.texi: Likewise.
31799         * doc/pastposix-functions/gcvt.texi: Likewise.
31801 2020-12-06  Bruno Haible  <bruno@clisp.org>
31803         doc: Tweak example.
31804         * doc/intprops.texi (Checking Integer Overflow): Use 'printf', not
31805         'print'.
31807 2020-12-06  Bruno Haible  <bruno@clisp.org>
31809         filenamecat-tests: Use idx_t for nonnegative ptrdiff_t variables.
31810         * tests/test-filenamecat.c: Include idx.h.
31811         (main): Mark prefixlen as nonnegative.
31812         * modules/filenamecat-tests (Depends-on): Add idx.
31814 2020-12-06  Bruno Haible  <bruno@clisp.org>
31816         time_rz: Use idx_t for nonnegative ptrdiff_t variables.
31817         * lib/time_rz.c: Include idx.h.
31818         (save_abbr): Mark zone_size as nonnegative.
31819         * modules/time_rz (Depends-on): Add idx.
31821 2020-12-06  Bruno Haible  <bruno@clisp.org>
31823         parse-datetime: Use idx_t for nonnegative ptrdiff_t variables.
31824         * lib/parse-datetime.y: Include idx.h.
31825         (textint): Mark digits as nonnegative.
31826         (parser_control): Mark dates_seen, days_seen, local_zones_seen,
31827         dsts_seen, times_seen, zones_seen as nonnegative.
31828         (lookup_word): Mark wordlen as nonnegative.
31829         (yylex): Mark count as nonnegative.
31830         (parse_datetime2): Mark tzsize as nonnegative.
31831         * modules/parse-datetime (Depends-on): Add idx.
31833 2020-12-06  Bruno Haible  <bruno@clisp.org>
31835         fnmatch: Use idx_t for nonnegative ptrdiff_t variables.
31836         * lib/fnmatch.c: Include idx.h. In glibc, define idx_t directly.
31837         * lib/fnmatch_loop.c (EXT): Mark slen, new_used, plensize as
31838         nonnegative.
31839         * modules/fnmatch (Depends-on): Add idx.
31841 2020-12-06  Bruno Haible  <bruno@clisp.org>
31843         c-stack: Use idx_t for nonnegative ptrdiff_t variables.
31844         * lib/c-stack.c: Include idx.h.
31845         (die): Mark buflen as nonnegative.
31846         * modules/c-stack (Depends-on): Add idx.
31848 2020-12-06  Bruno Haible  <bruno@clisp.org>
31850         backupfile: Use idx_t for nonnegative ptrdiff_t variables.
31851         * lib/backupfile.c: Include idx.h.
31852         (numbered_backup): Mark base_offset as nonnegative.
31853         (backupfile_internal): Likewise.
31854         * modules/backup-rename (Depends-on): Add idx.
31855         * modules/backupfile (Depends-on): Likewise.
31857 2020-12-05  Paul Eggert  <eggert@cs.ucla.edu>
31859         doc: fix curved quotes issue
31860         * doc/gnulib.texi: Set txicodequoteundirected and
31861         txicodequotebacktick so that ` and ' in examples do not generate
31862         curved single quotes that do the wrong thing when cut and pasted.
31864         doc: mention static and dynamic checking
31865         * doc/gnulib-readme.texi (High Quality): Add a bit of advice
31866         for static and dynamic checking.
31868         intprops: Add INT_ADD_OK etc.
31869         * doc/intprops.texi (Checking Integer Overflow): New section.
31870         * lib/intprops.h: From a suggestion by Bruno Haible in:
31871         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00051.html
31872         (SAFE_INT_ADD, SAFE_INT_SUBTRACT, SAFE_INT_MULTIPLY): New macros.
31874         doc: move exotic platfroms to Target Platforms
31875         * doc/gnulib-intro.texi (Supported Platforms)
31876         (Formerly Supported Platforms, Unsupported Platforms):
31877         New subsections, split off from Target Platforms.
31878         (Unsupported Platforms): Move the exotic-platform stuff here ...
31879         * doc/gnulib-readme.texi (Exotic platforms): ... from this removed
31880         section.
31882         doc: mention intptr_t etc. and IBM i
31883         * doc/gnulib-readme.texi (Other portability assumptions):
31884         Mention intptr_t and uintptr_t, and that arithmetic on them
31885         works in the usual way.
31886         (Exotic platforms): New section, containing material from
31887         the old 'Integer Portability' section.  Also mention IBM i.
31888         * doc/intprops.texi (Wraparound Arithmetic):
31889         Say that the macros work on unsigned integers too.
31890         (Integer Portability): Remove.
31892 2020-12-04  Bruno Haible  <bruno@clisp.org>
31894         utime: Fix a test failure on macOS 10.13.
31895         Reported by Martin Storsjö <martin@martin.st> in
31896         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
31897         * m4/utime.m4 (gl_FUNC_UTIME): Test whether utime handles trailing
31898         slashes on files.
31899         * lib/utime.c (utime): Add alternative implementation for Unix
31900         platforms.
31901         * modules/utime (Depends-on): Add stat.
31902         * doc/posix-functions/utime.texi: Mention the macOS 10.13 bug.
31903         * doc/posix-functions/lstat.texi: Mention that macOS 10.13 also has the
31904         trailing-slash bug.
31905         * doc/posix-functions/open.texi: Likewise.
31906         * doc/posix-functions/stat.texi: Likewise.
31907         * doc/posix-functions/symlink.texi: Likewise.
31909 2020-12-04  Paul Eggert  <eggert@cs.ucla.edu>
31911         intprops: update doc and mention Unisys
31912         * doc/gnulib-readme.texi (Other portability assumptions):
31913         Also mention ptrdiff_t when talking about widths and overflow.
31914         * doc/intprops.texi (Integer Properties): Summarize new section.
31915         (Arithmetic Type Properties): Document that EXPR_SIGNED no longer
31916         evaluates its argument.
31917         (Integer Bounds): Fix typo.
31918         (Wraparound Arithmetic): Remove obsolete comment about efficiency.
31919         Document that the _WRAPV macros now support pointers to unsigned
31920         integers.
31921         (Integer Range Overflow): Update SEI CERT citation.
31922         (Integer Portability): New subsection, which mentions
31923         the oddball Unisys platforms as non-Gnulib targets.
31925 2020-12-03  Bruno Haible  <bruno@clisp.org>
31927         idx: Clarify that idx_t always behaves like a signed type.
31928         Suggested by Paul Eggert in
31929         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00034.html>.
31930         * lib/idx.h: Clarify that idx_t always behaves like a signed type.
31931         Don't test UNSIGNED_IDX_T.
31933 2020-12-03  Bruno Haible  <bruno@clisp.org>
31935         idx: New module.
31936         * lib/idx.h: New file.
31937         * modules/idx: New file.
31938         * lib/canonicalize-lgpl.c: Include idx.h. Use idx_t instead of
31939         ptrdiff_t.
31940         * lib/canonicalize.c: Likewise.
31941         * modules/canonicalize-lgpl (Depends-on): Add idx.
31942         * modules/canonicalize (Depends-on): Likewise.
31944 2020-12-03  Bruno Haible  <bruno@clisp.org>
31946         fprintf-posix-tests: Avoid a test failure on macOS 10.13.
31947         Reported by Martin Storsjö <martin@martin.st> in
31948         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
31949         * tests/test-fprintf-posix3.c: Skip the test on macOS.
31950         (main): Return a different exit code at each point. Allow 100 KB extra
31951         memory consumption.
31952         * tests/test-fprintf-posix3.sh: Update. Remove the "get_rusage_as()
31953         doesn't work" diagnostic.
31955 2020-12-02  Paul Eggert  <eggert@cs.ucla.edu>
31957         canonicalize: refactor can_mode flag
31958         * lib/canonicalize.c (MULTIPLE_BITS_SET): Remove, replacing with ...
31959         (multiple_bits_set): ... this new static function.  Uses changed.
31960         (canonicalize_filename_mode): Refactor for clarity to avoid
31961         modifying the CAN_MODE argument.
31963         canonicalize: prefer signed integer types
31964         * lib/canonicalize.c: Include stddef.h, for ptrdiff_t.
31965         (seen_triple, canonicalize_filename_mode): Prefer signed to
31966         unsigned types where either will do, as they avoid some glitches
31967         in comparisons and can trap on overflow when debugging.
31969         canonicalize: fix most of another EOVERFLOW issue
31970         * lib/canonicalize.c (canonicalize_filename_mode):
31971         Do not call stat if fewer than 20 symlinks have been traversed.
31972         This avoids EOVERFLOW failure in the common case where there
31973         are not that many symlinks, while continuing to catch loops
31974         (or fail due to EOVERFLOW) in the unusual case when there
31975         are many symlinks to traverse.
31977         canonicalize: do not assume symlinks have st_ino
31978         * lib/canonicalize.c (canonicalize_filename_mode):
31979         When checking for loops, use st_dev and st_ino from the parent
31980         directory not from the symlink, as pre-2017 POSIX says these
31981         members are not reliable for symlinks.  Couple this with START
31982         (the remaining file name to be resolved), not NAME (the whole file
31983         name with START as its suffix).
31984         * modules/canonicalize (Depends-on): Depend on stat, not lstat.
31986         canonicalize: fix EOVERFLOW bug
31987         * lib/canonicalize.c (canonicalize_filename_mode):
31988         When testing whether a directory entry is a symbolic link, or a
31989         directory or other, do not use lstat or stat or
31990         areadlink_with_size.  Just use areadlink, as this suffices and it
31991         avoids the EOVERFLOW problem that lstat and stat have.
31992         * modules/canonicalize (Depends-on): Depend on areadlink instead
31993         of areadlink-with-size and stat.
31995         canonicalize-lgpl: fix EOVERFLOW bug
31996         * lib/canonicalize-lgpl.c: Do not include <sys/stat.h>.
31997         (__realpath): Do not use lstat.  Just use readlink, as this
31998         suffices and it avoids the EOVERFLOW problem that lstat has.
31999         * modules/canonicalize-lgpl (Depends-on): Remove lstat, sys_stat.
32001 2020-12-02  Bruno Haible  <bruno@clisp.org>
32003         strsignal-tests: Fix test failure on macOS 10.13.
32004         Reported by Martin Storsjö <martin@martin.st> in
32005         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
32006         * tests/test-strsignal.c (ASSERT_DESCRIPTION): Allow the actual result
32007         to be longer than the expected result.
32009 2020-12-02  Bruno Haible  <bruno@clisp.org>
32011         Fix compilation errors in test-math-c++.cc on FreeBSD 12.2/arm64.
32012         * lib/math.in.h (_GL_INCLUDING_MATH_H): New macro, to work around
32013         recursive self-include problem on FreeBSD 12.2 in C++ mode.
32015 2020-12-02  Bruno Haible  <bruno@clisp.org>
32017         spawn-pipe: Allow caller to specify directory for the subprocess.
32018         * lib/spawn-pipe.h (create_pipe_out, create_pipe_in, create_pipe_bidi):
32019         Add directory argument.
32020         * lib/spawn-pipe.c: Include canonicalize.h, filename.h, findprog.h.
32021         (create_pipe): Add directory argument. If specified, resolve the program
32022         file name and make it absolute, first. Pass the directory to spawnpvech
32023         and posix_spawn_file_actions_addchdir.
32024         (create_pipe_bidi, create_pipe_in, create_pipe_out): Add directory
32025         argument.
32026         * modules/spawn-pipe (Depends-on): Add canonicalize, filename,
32027         findprog-in, posix_spawn, posix_spawn_file_actions_addchdir.
32028         * tests/test-spawn-pipe-main.c (test_pipe): Update.
32029         * NEWS: Mention the change.
32030         * lib/csharpcomp.c (compile_csharp_using_mono,
32031         compile_csharp_using_sscli): Update.
32032         * lib/javacomp.c (is_envjavac_gcj, is_envjavac_gcj43, is_gcj_present,
32033         is_gcj_43): Update.
32034         * lib/javaversion.c (execute_and_read_line): Update.
32035         * lib/pipe-filter-gi.c (pipe_filter_gi_create): Update.
32036         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Update.
32038 2020-12-02  Bruno Haible  <bruno@clisp.org>
32040         execute: Allow caller to specify directory for the subprocess.
32041         * lib/execute.h (execute): Add directory argument.
32042         * lib/execute.c: Include canonicalize.h, filename.h, findprog.h.
32043         (execute): Add directory argument. If specified, resolve the program
32044         file name and make it absolute, first. Pass the directory to spawnpvech
32045         and posix_spawn_file_actions_addchdir.
32046         * modules/execute (Depends-on): Add canonicalize, filename, findprog-in,
32047         posix_spawn, posix_spawn_file_actions_addchdir.
32048         * tests/test-execute-main.c: Add test for passing a directory.
32049         * tests/test-execute-child.c: Likewise.
32050         * tests/test-execute.sh: Update.
32051         * modules/execute-tests (Depends-on): Add mkdir.
32052         * NEWS: Mention the change.
32053         * lib/csharpcomp.c (compile_csharp_using_sscli): Update.
32054         * lib/csharpexec.c (execute_csharp_using_mono,
32055         execute_csharp_using_sscli): Update.
32056         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
32057         compile_using_javac, compile_using_jikes, is_javac_present,
32058         is_jikes_present): Update.
32059         * lib/javaexec.c (execute_java_class): Update.
32061 2020-12-01  Bruno Haible  <bruno@clisp.org>
32063         vma-iter: Add support for macOS11/arm64.
32064         Patch suggested by Hill Ma <maahiuzeon@gmail.com> in
32065         <https://gitlab.com/gnu-clisp/clisp/-/issues/27>
32066         and by Martin Storsjö <martin@martin.st> in
32067         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
32068         * lib/vma-iter.c (vma_iterate): On arm64, use 64-bit type definitions.
32070 2020-12-01  Bruno Haible  <bruno@clisp.org>
32072         spawn-pipe: Fix handling of OS/2 kLIBC.
32073         Reported by KO Myung-Hun <komh78@gmail.com> in
32074         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00005.html>.
32075         * modules/spawn-pipe (configure.ac): Use the common idiom for
32076         recognizing the OS/2 operating system.
32078 2020-11-30  Bruno Haible  <bruno@clisp.org>
32080         execute: Fix uninitialized use of errno.
32081         * lib/execute.c (execute): Preserve errno across several system calls.
32083 2020-11-30  Bruno Haible  <bruno@clisp.org>
32085         access tests: Fix test failure on native Windows.
32086         * tests/test-access.c (main): Change permissions of f2 file before
32087         attempting to remove it.
32089 2020-11-30  Paul Eggert  <eggert@cs.ucla.edu>
32091         faccessat: link with $(LIB_EACCESS)
32092         * modules/faccessat (Link:): Add $(LIB_EACCESS), since this
32093         module depends on euidaccess.
32095 2020-11-30  Bruno Haible  <bruno@clisp.org>
32097         execute, spawn-pipe: Make multithread-safe on native Windows.
32098         * lib/windows-spawn.h: Include <stdint.h>, <windows.h>.
32099         (dup_safer_noinherit, undup_safer_noinherit): Remove declarations.
32100         (spawnpvech): New declaration.
32101         * lib/windows-spawn.c: Include <stdio.h>, <process.h>, findprog.h.
32102         Don't include <unistd.h>, cloexec.h, error.h, gettext.h.
32103         (_): Remove macro.
32104         (dup_noinherit, fd_safer_noinherit, dup_safer_noinherit,
32105         undup_safer_noinherit): Remove functions.
32106         (spawnpvech): New function.
32107         * modules/windows-spawn (Depends-on): Add findprog-in, stdint. Remove
32108         cloexec, dup2, error, gettext-h.
32109         * lib/execute.c: Include msvc-nothrow.h.
32110         (execute) [WIN32]: Use _get_osfhandle, spawnpvech instead of _spawnvpe.
32111         * lib/spawn-pipe.c: Include msvc-nothrow.h.
32112         (create_pipe) [WIN32]: Use _get_osfhandle, DuplicateHandle, spawnpvech
32113         instead of _spawnvpe.
32114         * modules/execute (Depends-on): Add msvc-nothrow.
32115         * modules/spawn-pipe (Depends-on): Likewise.
32117 2020-11-30  Bruno Haible  <bruno@clisp.org>
32119         execute, spawn-pipe: Improve documentation.
32120         * lib/execute.h: Describe progname, prog_path, prog_argv.
32121         * lib/spawn-pipe.h: Likewise.
32123 2020-11-30  Bruno Haible  <bruno@clisp.org>
32125         execute tests: Add more tests.
32126         * tests/test-execute-main.c: Add tests for reading, writing, isatty on
32127         inherited file descriptors >= 3.
32128         * tests/test-execute-child.c: Likewise.
32129         * tests/test-execute.sh: Update.
32131 2020-11-30  Bruno Haible  <bruno@clisp.org>
32133         havelib: Fix for non-ELF platforms (regression 2019-11-17).
32134         Reported by comex <comexk@gmail.com> in
32135         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00188.html>.
32136         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On non-ELF platforms,
32137         don't expect an ELF header.
32139 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
32141         bitset: use integer_length in table implementation
32142         * lib/bitset/table.c (tbitset_list_reverse): Use
32143         BITSET_FOR_EACH_BIT_REVERSE.
32145 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
32147         bitset: use integer_length in list implementation
32148         * lib/bitset/list.c (lbitset_list_reverse): Use
32149         BITSET_FOR_EACH_BIT_REVERSE.
32151 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
32153         bitset: use integer_length in vector implementation
32154         * lib/bitset/array.c (vbitset_list_reverse): Use
32155         BITSET_FOR_EACH_BIT_REVERSE.
32157 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
32159         bitset: use integer_length in array implementation
32160         * modules/bitset (Depends-on): Add integer_length_l.
32161         * lib/bitset/base.h (bitset_fls_, BITSET_FOR_EACH_BIT_REVERSE): New.
32162         * lib/bitset/array.c (abitset_list_reverse): Use it.
32164 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
32166         bitset: style: use consistent names
32167         * bitset/list.c (lbitset_list_reverse): Rename 'bcount' as 'bitcnt',
32168         and 'boffset' as 'bitoff', for consistency with the other
32169         implementations.
32170         * bitset/table.c (tbitset_list_reverse): Likewise.
32172 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
32174         bitset: style: sort header
32175         * lib/bitset/base.h (bitset_ffs): Rename as...
32176         (bitset_ffs_): this.
32177         (bitset_ffs_, BITSET_FOR_EACH_BIT): Move to better places.
32179 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
32181         bitset: tests: check BITSET_FOR_EACH_REVERSE
32182         * tests/test-bitset.c (compare, check_zero, check_one_bit, check_ones):
32183         Check BITSET_FOR_EACH_REVERSE.
32185 2020-11-29  Bruno Haible  <bruno@clisp.org>
32187         spawn-pipe tests: Fix test failure with MSVC.
32188         * tests/test-spawn-pipe-child.c: Include <stdint.h>.
32189         (gl_msvc_invalid_parameter_handler): New function.
32190         (main): Set a global invalid-parameter handler.
32191         * modules/spawn-pipe-tests (Depends-on): Add msvc-inval, stdint.
32193 2020-11-29  Bruno Haible  <bruno@clisp.org>
32195         execute: Add tests.
32196         * tests/test-execute.sh: New file.
32197         * tests/test-execute-main.c: New file.
32198         * tests/test-execute-child.c: New file.
32199         * modules/execute-tests: New file.
32201 2020-11-29  Bruno Haible  <bruno@clisp.org>
32203         fcntl: Work around NetBSD bug with F_DUPFD_CLOEXEC.
32204         * m4/fcntl.m4 (gl_FUNC_FCNTL): Test whether F_DUPFD_CLOEXEC actually
32205         works.
32206         * lib/fcntl.c (rpl_fcntl_DUPFD_CLOEXEC): On NetBSD, use the same
32207         fallback implementation as on Haiku.
32208         * tests/test-fcntl.c (main): Add a test whether F_DUPFD_CLOEXEC is
32209         effective.
32210         * doc/posix-functions/fcntl.texi: Mention the NetBSD bug.
32212 2020-11-29  Bruno Haible  <bruno@clisp.org>
32214         spawn-pipe: Fix build on OS/2 kLIBC (regression 2020-11-28).
32215         * lib/os2-spawn.h: New file, based on lib/windows-spawn.h.
32216         * lib/os2-spawn.c: New file, based on lib/windows-spawn.c.
32217         * lib/spawn-pipe.c: On OS/2 kLIBC, include "os2-spawn.h".
32218         * lib/windows-spawn.c: Remove modifications for kLIBC.
32219         * modules/spawn-pipe (Files): Add the new files.
32220         (configure.ac): Arrange to compile os2-spawn.c on OS/2.
32222 2020-11-28  Bruno Haible  <bruno@clisp.org>
32224         asyncsafe-spin: Fix compilation error with GCC on 32-bit SPARC.
32225         Reported by Paul Eggert in
32226         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00066.html>.
32227         * m4/sparcv8+.m4: New file.
32228         * modules/sparcv8+: New file.
32229         * modules/asyncsafe-spin (Depends-on): Add sparcv8+.
32231 2020-11-28  Bruno Haible  <bruno@clisp.org>
32233         asyncsafe-spin: Fix build error with GCC on 32-bit SPARC.
32234         * lib/asyncsafe-spin.c: Don't use GCC >= 4.1 primitives on SPARC.
32236 2020-11-28  Bruno Haible  <bruno@clisp.org>
32238         windows-spawn: New module.
32239         * lib/windows-spawn.h: Renamed from lib/w32spawn.h. Remove
32240         implementations.
32241         * lib/windows-spawn.c: Renamed from lib/w32spawn.h.
32242         * modules/windows-spawn: New file.
32243         * lib/execute.c: Include "windows-spawn.h" instead of "w32spawn.h".
32244         * lib/spawn-pipe.c: Likewise.
32245         * modules/execute (Files): Remove lib/w32spawn.h.
32246         (Depends-on): Add windows-spawn. Remove cloexec, msvc-nothrow, strpbrk,
32247         xalloc.
32248         (Makefile.am): Remove w32spawn.h from lib_SOURCES.
32249         * modules/spawn-pipe (Files): Remove lib/w32spawn.h.
32250         (Depends-on): Add windows-spawn. Remove cloexec, msvc-nothrow, strpbrk,
32251         xalloc.
32252         (Makefile.am): Remove w32spawn.h from lib_SOURCES.
32254 2020-11-27  Bruno Haible  <bruno@clisp.org>
32256         ssfmalloc tests: Port to macOS 11.
32257         * tests/test-ssfmalloc.c (PAGESIZE_MAX): Set to 16384, not 8192.
32259 2020-11-26  Bruno Haible  <bruno@clisp.org>
32261         Fix dependencies of modules that use '_exit' on native Windows.
32262         Reported by Jim Meyering in
32263         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00159.html>.
32264         * modules/_Exit (Depends-on): Add unistd.
32265         * modules/closein (Depends-on): Likewise.
32266         * modules/closeout (Depends-on): Likewise.
32267         * modules/forkpty (Depends-on): Likewise.
32268         * modules/posix_spawn-internal (Depends-on): Likewise.
32269         * modules/savewd (Depends-on): Likewise.
32270         * modules/stat-time-tests (Depends-on): Likewise.
32272 2020-11-26  Bruno Haible  <bruno@clisp.org>
32274         raise-tests: Fix compilation error on MSVC (regression 2020-11-25).
32275         * modules/raise-tests (Depends-on): Add unistd.
32276         * doc/posix-functions/_exit.texi: Mention the 'unistd' module.
32278 2020-11-25  Jim Meyering  <meyering@fb.com>
32280         setlocale-tests: do not trigger gcc's -Wanalyzer-possible-null-argument
32281         * tests/test-setlocale1.c (main): Assert that each strcmp argument is
32282         non-NULL, since we don't bother handing strdup failure.
32284         raise-tests: avoid GCC 11's new exit-from-signal-handler warning
32285         gcc's -Wanalyzer-unsafe-call-within-signal-handler exposed this.
32286         * tests/test-raise.c: Include unistd.h.
32287         (handler): Use _exit, not exit.
32289 2020-11-23  Bruno Haible  <bruno@clisp.org>
32291         Use the correct printf format attribute for mingw.
32292         Reported by Reuben Thomas <rrt@sc3d.org> in
32293         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00133.html>.
32295         * modules/vfprintf-posix (configure.ac): Define GNULIB_VFPRINTF_POSIX.
32296         * modules/vprintf-posix (configure.ac): Define GNULIB_VPRINTF_POSIX.
32298         * lib/stdio.in.h (_GL_ATTRIBUTE_SPEC_PRINTF_STANDARD,
32299         _GL_ATTRIBUTE_SPEC_PRINTF_SYSTEM): New macros.
32300         (_GL_ATTRIBUTE_FORMAT_PRINTF_STANDARD): Renamed from
32301         _GL_ATTRIBUTE_FORMAT_PRINTF. Use _GL_ATTRIBUTE_SPEC_PRINTF_STANDARD.
32302         (_GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM): Use
32303         _GL_ATTRIBUTE_SPEC_PRINTF_SYSTEM.
32305         * modules/vasnprintf (Depends-on): Add stdio.
32306         * lib/vasnprintf.h: Include <stdio.h>.
32307         (asnprintf, vasnprintf): Use the standard printf format attribute.
32309         * modules/xvasprintf (Depends-on): Add stdio.
32310         * lib/xvasprintf.h: Include <stdio.h>.
32311         (xasprintf, xvasprintf): Use the standard printf format attribute.
32313         * modules/xprintf (Depends-on): List stdio first.
32314         * lib/xprintf.h (xprintf, xvprintf): Use a printf format attribute that
32315         depends on GNULIB_VPRINTF_POSIX.
32316         (xfprintf, xvfprintf): Use a printf format attribute that depends on
32317         GNULIB_VFPRINTF_POSIX.
32319         * modules/c-vasnprintf (Depends-on): Add stdio.
32320         * lib/c-vasnprintf.h: Include <stdio.h>.
32321         (c_vasnprintf): Use the standard printf format attribute.
32323         * modules/c-vasprintf (Depends-on): Add stdio.
32324         * lib/c-vasprintf.h: Include <stdio.h>.
32325         (c_asprintf, c_vasprintf): Use the standard printf format attribute.
32327         * modules/c-vsnprintf (Depends-on): Add stdio.
32328         * lib/c-vsnprintf.h: Include <stdio.h>.
32329         (c_vsnprintf): Use the standard printf format attribute.
32331         * modules/c-snprintf (Depends-on): Add stdio.
32332         * lib/c-snprintf.h: Include <stdio.h>.
32333         (c_snprintf): Use the standard printf format attribute.
32335         * modules/c-xvasprintf (Depends-on): Add stdio.
32336         * lib/c-xvasprintf.h: Include <stdio.h>.
32337         (c_xasprintf, c_xvasprintf): Use the standard printf format attribute.
32339         * modules/error (Depends-on): Depend on stdio always.
32340         * lib/error.h: Include <stdio.h>.
32341         (_GL_ATTRIBUTE_SPEC_PRINTF): Remove macro.
32342         (error, error_at_line): Use a printf format attribute that depends on
32343         GNULIB_VFPRINTF_POSIX.
32344         * lib/error.c (_GL_ATTRIBUTE_FORMAT_PRINTF_STANDARD): Renamed from
32345         _GL_ATTRIBUTE_FORMAT_PRINTF.
32347         * modules/verror (Depends-on): Add stdio.
32348         * lib/verror.h: Include <stdio.h>. Don't include "error.h".
32349         (verror, verror_at_line): Use the standard printf format attribute.
32350         * lib/verror.c: Include "error.h".
32352         * modules/argp (Depends-on): Add stdio.
32353         * lib/argp.h (argp_error, __argp_error, argp_failure, __argp_failure):
32354         Use a printf format attribute that depends on GNULIB_VFPRINTF_POSIX.
32356         * modules/libtextstyle-optional (Depends-on): Add stdio.
32357         * lib/textstyle.in.h (ostream_printf, ostream_vprintf): Use the standard
32358         printf format attribute.
32360         * tests/test-nonblocking-misc.h (dbgfprintf): Use the standard printf
32361         format attribute.
32363 2020-11-23  Pádraig Brady  <P@draigBrady.com>
32365         selinux-at, selinux-h: use const correct declarations
32366         * lib/se-selinux.in.h: Use const for "set" functions,
32367         to match current selinux, and support cleaner user code.
32368         * lib/selinux-at.c: Likewise.
32369         * lib/selinux-at.h: Likewise.
32371 2020-11-22  Paul Eggert  <eggert@cs.ucla.edu>
32373         canonicalize-lgpl: fix memory leak
32374         * lib/canonicalize-lgpl.c (__realpath): Fix unlikely memory leak,
32375         which could have occurred if BUF was so large that malloc was
32376         called.  Do this by allocating EXTRA_BUF and BUF at the same time;
32377         this eliminates the need to free BUF separately.
32379 2020-11-22  Bruno Haible  <bruno@clisp.org>
32381         Fix missing module dependencies to 'xalloc' (regression 2020-10-19).
32382         * modules/xvasprintf (Depends-on): Add xalloc.
32383         * modules/pipe-filter-gi (Depends-on): Likewise.
32384         * modules/execute (Depends-on): Likewise, for w32spawn.h.
32385         * modules/spawn-pipe (Depends-on): Likewise.
32387 2020-11-22  Jose E. Marchesi  <jemarch@gnu.org>
32389         bootstrap: add option hooks
32390         * build-aux/bootstrap (bootstrap_print_option_usage_hook): Define.
32391         (bootstrap_option_hook): Likewise.
32392         (usage): Call bootstrap_print_option_usage_hook.
32394 2020-11-22  Bruno Haible  <bruno@clisp.org>
32396         argp: Don't break getprogname on non-glibc systems.
32397         * m4/argp.m4 (gl_ARGP): Don't expect <argp.h> to exist when testing for
32398         program_invocation_name and program_invocation_short_name.
32400 2020-11-22  Bruno Haible  <bruno@clisp.org>
32402         doc: Document <link.h>.
32403         * doc/glibc-headers/link.texi: New file.
32404         * doc/gnulib.texi: Include it.
32406 2020-11-22  Bruno Haible  <bruno@clisp.org>
32408         doc: Add references to the LSB.
32409         * doc/glibc-functions/*.texi: Add references to LSB 5.0.
32410         * doc/posix-functions/*.texi: Likewise.
32412 2020-11-22  Bruno Haible  <bruno@clisp.org>
32414         doc: Fix a makeinfo warning (regression 2020-11-03).
32415         * doc/posix-functions/aligned_alloc.texi: Add missing @item.
32417 2020-11-21  Paul Eggert  <eggert@cs.ucla.edu>
32419         parse-datetime: fix printf format typo
32420         * lib/parse-datetime.y (parse_datetime2): Fix format typo in
32421         previous patch to this file.  Problem reported by Chris Elvidge in
32422         <https://bugs.gnu.org/44763#32>.
32424         setlocale-null-tests: work around GCC bug 44511
32425         * tests/test-setlocale_null-mt-all.c:
32426         * tests/test-setlocale_null-mt-one.c:
32427         Ignore -Wreturn-type, to work around GCC bug 44511.
32429         nl_langinfo-tests: work around GCC bug 44511
32430         * tests/test-nl_langinfo-mt.c: Ignore -Wreturn-type, to work
32431         around a GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=44511>.
32432         Problem reported for GNU grep by Andreas Schwab
32433         <https://bugs.gnu.org/44535>.
32435         selinux-h: add stubs for selabel_open etc.
32436         Coreutils with --enable-gcc-warnings does not build on Ubuntu 20.10
32437         because matchpathcon is deprecated in favor of selabel_open etc.,
32438         so this patch adds stubs for these functions.
32439         * lib/se-label.c, lib/se-label.in.h, m4/selinux-label-h.m4: New files.
32440         * lib/se-selinux.in.h (struct selinux_opt): Add incomplete decl,
32441         as it is needed for selabel_open and selinux/selinux.h declares
32442         this type here.
32443         * modules/selinux-h (Files): Add the new files.
32444         (configure.ac): Add gl_HEADERS_SELINUX_LABEL_H.
32445         (lib_SOURCES): Add se-label.in.h, se-label.c.
32446         (BUILT_SOURCES): Add $(SELINUX_LABEL_H).
32447         (selinux/label.h): New rule, mimicking selinux/context.h.
32448         (MOSTLYCLEANFILES): Add selinux/label.h, selinux/label.h-t.
32449         (Include): Add selinux/label.h.
32451 2020-11-21  Bruno Haible  <bruno@clisp.org>
32453         Update after 'test-driver' in Automake changed.
32454         * build-aux/test-driver.diff: Rebase.
32456 2020-11-21  Daiki Ueno  <ueno@gnu.org>
32458         read-file: remove dead assignment
32459         * lib/read-file.c (fread_file): Remove dead assignment when
32460         RF_SENSITIVE is set, flagged by clang-analyzer.
32462 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
32464         bitset: tests: exercise the stats too
32466         * tests/test-bitset.c: Display the stats at the end of the test.
32467         * lib/bitset/stats.c (bitset_log_histogram_print): When diplaying the
32468         last bin, display "256-..." rather that "256-511", since the last bin
32469         does count item greater than or equal to 256.
32471 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
32473         bitset: tests: try harder to break it
32474         * tests/test-bitset.c (compare): Be ready to use bitsets larger than
32475         BITSET_LIST_SIZE.
32476         (main): Likewise.
32477         While at it, also exercise super small bitsets.
32479 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
32481         bitset: use ffs where possible in the vector implementation
32482         * lib/bitset/vector.c (vbitset_list): Use BITSET_FOR_EACH_BIT.
32484 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
32486         bitset: use ffs where possible in the table implementation
32487         * lib/bitset/table.c (tbitset_list): Use BITSET_FOR_EACH_BIT.
32489 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
32491         bitset: check empty and full bitsets
32492         * tests/test-bitset.c (check_zero, check_ones): New.
32493         (check_attributes): Use them.
32495 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
32497         bitset: be sure to always return a value
32498         * lib/bitset/array.c (abitset_small_list): Always update *next and
32499         return a value.
32501 2020-11-19  Siddhesh Poyarekar  <siddhesh@gotplt.org>
32503         vcs-to-changelog: Expect spaces in file names
32504         Reported by Thierry Bothorel <thierry.bothorel@zaclys.net> in
32505         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00040.html>,
32506         * build-aux/vcstocl/vcs_git.py (exec_git_cmd): Do not transform
32507         tabs to spaces.
32508         (list_changes): Use tabs to identify file names.
32510 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
32512         bitset: strengthen tests
32513         * tests/test-bitset.c (compare): Also check count.
32514         Deal only with random values, move the one-bit tests to...
32515         (check_one_bit): this new function.
32516         (check_attributes): Call it.
32518 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
32520         bitset: fix iteration over table bitsets
32521         * lib/bitset/table.c (tbitset_list): Update bitno when windex is.
32523 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
32525         bitset: rename internal details for consistency
32526         * lib/bitset/table.c: Rename all the EBITSET_ symbols as TBITSET_.
32528 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
32530         bitset: test: run deterministic tests on several bitset sizes
32531         * tests/test-bitset.c (check_attributes): Run it with small and large
32532         sizes.
32534 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
32536         bitset: use ffs where possible in the list implementation
32537         * lib/bitset/list.c (lbitset_list): Use BITSET_FOR_EACH_BIT.
32539 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
32541         bitset: use ffs where possible in array implementation
32542         * lib/bitset/array.c (abitset_small_list): Use BITSET_FOR_EACH_BIT.
32544 2020-11-17  Bruno Haible  <bruno@clisp.org>
32546         posixcheck: Don't enable GNULIB_POSIXCHECK in C++ mode.
32547         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
32548         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00062.html>.
32549         * m4/posixcheck.m4 (gl_POSIXCHECK): Don't define GNULIB_POSIXCHECK in
32550         C++ mode.
32552 2020-11-17  Bruno Haible  <bruno@clisp.org>
32554         Fix error when GNULIB_POSIXCHECK is enabled (regression 2019-06-04).
32555         * lib/unistd.in.h (copy_file_range): Don't assume that copy_file_range
32556         is always declared.
32557         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether copy_file_range is
32558         declared.
32560 2020-11-17  Bruno Haible  <bruno@clisp.org>
32562         Fix link errors on AIX.
32563         * modules/clean-temp (Link): Link with $(LIBTHREAD).
32564         * modules/getumask (Link): Link with $(LIBTHREAD).
32565         * modules/getumask-tests (Makefile.am): Link test-getumask with
32566         $(LIBTHREAD).
32567         * modules/supersede (Link): Link with $(LIBTHREAD).
32568         * modules/supersede-tests (Makefile.am): Link test-supersede with
32569         $(LIBTHREAD).
32570         * modules/fatal-signal (Link): New section.
32571         * modules/execute (Link): New section.
32572         * modules/csharpexec (Link): Link with $(LIBTHREAD).
32573         * modules/javaexec (Link): Link with $(LIBTHREAD).
32574         * modules/spawn-pipe (Link): New section.
32575         * modules/spawn-pipe-tests (Makefile.am): Link test-spawn-pipe-main with
32576         $(LIBTHREAD).
32577         * modules/csharpcomp (Link): Link with $(LIBTHREAD).
32578         * modules/javacomp (Link): Link with $(LIBTHREAD).
32579         * modules/javaversion (Link): Link with $(LIBTHREAD).
32580         * modules/pipe-filter-gi (Link): New section.
32581         * modules/pipe-filter-gi-tests (Makefile.am): Link test-pipe-filter-gi1,
32582         test-pipe-filter-gi2-main with $(LIBTHREAD).
32583         * modules/pipe-filter-ii (Link): New section.
32584         * modules/pipe-filter-ii-tests (Makefile.am): Link test-pipe-filter-ii1,
32585         test-pipe-filter-ii2-main with $(LIBTHREAD).
32586         * modules/term-style-control (Link): New section.
32587         * modules/term-style-control-tests (Makefile.am): Link
32588         test-term-style-control-hello, test-term-style-control-yes with
32589         $(LIBTHREAD).
32590         * modules/wait-process (Link): New section.
32591         * modules/nonblocking-pipe-tests (Makefile.am): Link
32592         test-nonblocking-pipe-main with $(LIBTHREAD).
32593         * modules/nonblocking-socket-tests (Makefile.am): Link
32594         test-nonblocking-socket-main with $(LIBTHREAD).
32596 2020-11-16  Bruno Haible  <bruno@clisp.org>
32598         Fix link errors on platforms with libunistring.
32599         * modules/c32isalnum (Link): New section.
32600         * modules/c32isalnum-tests (Makefile.am): Link test-c32isalnum with
32601         $(LIBUNISTRING).
32602         * modules/c32isalpha (Link): New section.
32603         * modules/c32isalpha-tests (Makefile.am): Link test-c32isalpha with
32604         $(LIBUNISTRING).
32605         * modules/c32isblank (Link): New section.
32606         * modules/c32isblank-tests (Makefile.am): Link test-c32isblank with
32607         $(LIBUNISTRING).
32608         * modules/c32iscntrl (Link): New section.
32609         * modules/c32iscntrl-tests (Makefile.am): Link test-c32iscntrl with
32610         $(LIBUNISTRING).
32611         * modules/c32isdigit (Link): New section.
32612         * modules/c32isdigit-tests (Makefile.am): Link test-c32isdigit with
32613         $(LIBUNISTRING).
32614         * modules/c32isgraph (Link): New section.
32615         * modules/c32isgraph-tests (Makefile.am): Link test-c32isgraph with
32616         $(LIBUNISTRING).
32617         * modules/c32islower (Link): New section.
32618         * modules/c32islower-tests (Makefile.am): Link test-c32islower with
32619         $(LIBUNISTRING).
32620         * modules/c32isprint (Link): New section.
32621         * modules/c32isprint-tests (Makefile.am): Link test-c32isprint with
32622         $(LIBUNISTRING).
32623         * modules/c32ispunct (Link): New section.
32624         * modules/c32ispunct-tests (Makefile.am): Link test-c32ispunct with
32625         $(LIBUNISTRING).
32626         * modules/c32isspace (Link): New section.
32627         * modules/c32isspace-tests (Makefile.am): Link test-c32isspace with
32628         $(LIBUNISTRING).
32629         * modules/c32isupper (Link): New section.
32630         * modules/c32isupper-tests (Makefile.am): Link test-c32isupper with
32631         $(LIBUNISTRING).
32632         * modules/c32isxdigit (Link): New section.
32633         * modules/c32isxdigit-tests (Makefile.am): Link test-c32isxdigit with
32634         $(LIBUNISTRING).
32635         * modules/unicodeio (Link): Mention $(LIBUNISTRING).
32636         * modules/unicodeio-tests (Makefile.am): Link test-unicodeio with
32637         $(LIBUNISTRING).
32639 2020-11-16  Bruno Haible  <bruno@clisp.org>
32641         Fix link errors on platforms with libintl (e.g. Solaris and AIX).
32642         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
32643         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00062.html>.
32644         * modules/getumask-tests (Makefile.am): Link test-getumask with
32645         $(LIBINTL).
32646         * modules/stack-tests (Makefile.am): Link test-stack with $(LIBINTL).
32647         * modules/supersede-tests (Makefile.am): Link test-supersede with
32648         $(LIBINTL).
32649         * modules/unicodeio-tests (Makefile.am): Link test-unicodeio with
32650         $(LIBINTL).
32652 2020-11-16  Bruno Haible  <bruno@clisp.org>
32654         getumask: Document link dependencies.
32655         * modules/getumask (Link): New section.
32657 2020-11-16  Bruno Haible  <bruno@clisp.org>
32659         Update link dependencies in modules after 2020-09-09 change.
32660         * modules/tempname (Link): Add $(LIB_CLOCK_GETTIME).
32661         * modules/mkdtemp (Link): Likewise.
32662         * modules/mkostemp (Link): Likewise.
32663         * modules/mkostemps (Link): Likewise.
32664         * modules/mkstemp (Link): Likewise.
32665         * modules/mkstemps (Link): Likewise.
32666         * modules/supersede (Link): Likewise.
32667         * modules/tmpfile (Link): Likewise.
32668         * modules/tmpfile-safer (Link): Likewise.
32670 2020-11-15  Paul Eggert  <eggert@cs.ucla.edu>
32672         getumask-tests: port to Solaris 10 etc.
32673         Problem reported by Tom Christensen in:
32674         https://lists.gnu.org/r/bug-gnulib/2020-11/msg00062.html
32675         * modules/getumask-tests (test_getumask_LDADD):
32676         Add $(LIB_CLOCK_GETTIME).
32678 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
32680         bitset: use ffsl to accelerate iterations over set bits
32681         Suggested by Bruno Haible.
32682         * modules/bitset: Depend upon ffsl.
32683         * lib/bitset/base.h (bitset_ffs, BITSET_FOR_EACH_BIT): New.
32684         * lib/bitset/array.c (abitset_list): Use BITSET_FOR_EACH_BIT.
32686 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
32688         bitset: more tests
32689         * tests/test-bitset.c (compare): Make it clear that the random values
32690         should not be modified.
32691         Check bitset_first, bitset_last and BITSET_FOR_EACH.
32693 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
32695         bitset: fix the copy from lbitset to other types
32696         * lib/bitset/list.c (lbitset_copy): Rename as...
32697         (lbitset_copy_): this.
32698         (lbitset_copy): New.
32699         Dispatch to heterogeneous/homogeneous copy.
32701 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
32703         bitset: making debug traces more useful
32704         * lib/bitset.c (bitset_print): Print the bitset type in verbose mode.
32706         bitset: comment changes
32707         * lib/bitset.c: Move some documenting comments to...
32708         * lib/bitset.h: here.
32709         * lib/bitset/array.c: Fix some comments.
32711 2020-11-14  Paul Eggert  <eggert@cs.ucla.edu>
32713         careadlinkat: warn better about GCC bug 93644
32714         * lib/careadlinkat.c (readlink_stk): When --enable-gcc-warnings is
32715         not in effect, use "#warning" to let builders know more clearly
32716         about GCC bug 93644, because the bug triggers even if no -W option
32717         is given to GCC.
32719 2020-11-13  Jim Meyering  <meyering@fb.com>
32721         hard-locale-tests: avoid a -Wstrict-prototypes warning
32722         * tests/locale.c (main): Placate gcc's -Wstrict-prototypes by
32723         changing "main ()" to "main (void)". This was the only case that
32724         triggered a warning when building grep with --enable-gcc-warnings.
32726 2020-11-11  Paul Eggert  <eggert@cs.ucla.edu>
32728         time_rz: simplify CVE-2017-7476 fix
32729         * lib/time_rz.c: Do not include limits.h; I think it was included
32730         under the mistaken impression that limits.h defines SIZE_MAX.
32731         (SIZE_MAX): Remove.
32732         (save_abbr): Put string length into a ptrdiff_t variable,
32733         so that the size comparison works naturally.  This
32734         fixes CVE-2017-7476 in a cleaner way.
32736         parse-datetime: streamline overflow checking
32737         When parse-datetime.y’s overflow code was written, INT_ADD_WRAPV
32738         did not work for unsigned destinations, and since time_t might
32739         be unsigned that meant it did not work for time_t destinations.
32740         This limitation of INT_ADD_WRAPV has been fixed, so we can
32741         now streamline parse-datetime.y a bit.
32742         * lib/parse-datetime.y: Do not include limits.h, as LONG_MAX
32743         has not been used for a while.
32744         (yylex, parse_datetime2): Assume C99 declarations after statements.
32745         (yyles): Use INT_SUBTRACT_WRAPV instead of an explicit comparison
32746         to TYPE_MINIMUM.
32747         (parse_datetime2): No need for time_overflow now that
32748         INT_ADD_WRAPV works for unsigned results.
32750         parse-datetime-tests: port to Alpine Linux 3.12.1
32751         * tests/test-parse-datetime.c: Include errno.h for errno,
32752         and unistd.h for _SC_TZNAME_MAX and sysconf.
32753         (main): In the outlandishly-long time zone abbreviation test,
32754         do not exceed TZNAME_MAX as this has undefined behavior,
32755         and on Alpine Linux 3.12.1 it makes the test fail.
32757 2020-11-09  Pádraig Brady  <P@draigBrady.com>
32759         mgetgroups: avoid warning with clang
32760         * lib/mgetgroups.c: Xcode-12.1 identifies as GCC 4.2.1,
32761         so disable -Wpointer-sign for all clang versions.
32763 2020-11-07  Bruno Haible  <bruno@clisp.org>
32765         gnulib-tool: Fix link error with 'version-etc' (regression 2020-05-29).
32766         Reported by Simon Josefsson in
32767         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00032.html>.
32768         * gnulib-tool (func_emit_tests_Makefile_am): Add libtests.a to
32769         LDADD a third time, after the second occurrence of ../lib/libgnu.a.
32770         * pygnulib/GLEmiter.py (tests_Makefile_am): Likewise.
32772 2020-11-04  Paul Eggert  <eggert@cs.ucla.edu>
32774         tests: pacify Sun C 5.9
32775         Without these changes, Sun C 5.9 (2009/11/22) issues complaints like
32776         “"test-nl_langinfo-mt.c", line 75: warning: statement not reached”.
32777         * tests/test-nl_langinfo-mt.c (thread1_func, thread2_func)
32778         (thread3_func, thread4_func, thread5_func, thread6_func, threadN_func):
32779         * tests/test-setlocale_null-mt-all.c (thread1_func, thread2_func):
32780         * tests/test-setlocale_null-mt-one.c (thread1_func, thread2_func):
32781         Remove unreachable ‘return NULL;’s.
32783         tests: port better to XLC 12.01
32784         * tests/test-argmatch.c (CHECK): Do not use -1 as a subscript,
32785         even in code that is not executed, as IBM XLC 12.01 complains "The
32786         subscript -1 is less than zero."
32787         * tests/test-stdint.c (verify_width): Pass an (unused) 3rd
32788         argument to _GL_VERIFY, as ISO C requires.  Otherwise, IBM XLC
32789         12.01 complains "The invocation of macro _GL_VERIFY contains fewer
32790         arguments than are required by the macro definition."
32792 2020-11-03  Bruno Haible  <bruno@clisp.org>
32794         aligned-malloc: Use fixes from the new modules.
32795         * modules/aligned-malloc (Depends-on): Add posix_memalign,
32796         aligned_alloc, memalign.
32797         (configure.ac): Use AC_CHECK_FUNCS_ONCE.
32799 2020-11-03  Bruno Haible  <bruno@clisp.org>
32801         aligned_alloc: Add tests.
32802         * tests/test-aligned_alloc.c: New file.
32803         * modules/aligned_alloc-tests: New file.
32805         aligned_alloc: New module.
32806         * lib/stdlib.in.h (aligned_alloc): New declaration.
32807         * lib/aligned_alloc.c: New file.
32808         * m4/aligned_alloc.m4: New file.
32809         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether aligned_alloc is declared.
32810         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_ALIGNED_ALLOC,
32811         HAVE_ALIGNED_ALLOC, REPLACE_ALIGNED_ALLOC.
32812         * modules/stdlib (Makefile.am): Substitute GNULIB_ALIGNED_ALLOC,
32813         HAVE_ALIGNED_ALLOC, REPLACE_ALIGNED_ALLOC.
32814         * modules/aligned_alloc: New file.
32815         * tests/test-stdlib-c++.cc (aligned_alloc): Check signature.
32816         * doc/posix-functions/aligned_alloc.texi: Mention the new module and the
32817         AIX bug.
32819 2020-11-03  Bruno Haible  <bruno@clisp.org>
32821         posix_memalign: Add tests.
32822         * tests/test-posix_memalign.c: New file.
32823         * modules/posix_memalign-tests: New file.
32825         posix_memalign: New module.
32826         * lib/stdlib.in.h (posix_memalign): New declaration.
32827         * lib/posix_memalign.c: New file.
32828         * m4/posix_memalign.m4: New file.
32829         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether posix_memalign is declared.
32830         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_POSIX_MEMALIGN,
32831         HAVE_POSIX_MEMALIGN, REPLACE_POSIX_MEMALIGN.
32832         * modules/stdlib (Makefile.am): Substitute GNULIB_POSIX_MEMALIGN,
32833         HAVE_POSIX_MEMALIGN, REPLACE_POSIX_MEMALIGN.
32834         * modules/posix_memalign: New file.
32835         * tests/test-stdlib-c++.cc (posix_memalign): Check signature.
32836         * doc/posix-functions/posix_memalign.texi: Mention the new module and
32837         the OpenBSD bug.
32839 2020-11-03  Bruno Haible  <bruno@clisp.org>
32841         memalign: Add tests.
32842         * tests/test-memalign.c: New file.
32843         * modules/memalign-tests: New file.
32845         memalign: New module.
32846         * modules/memalign: New file.
32847         * doc/glibc-functions/memalign.texi: Mention the new module.
32849 2020-11-03  Bruno Haible  <bruno@clisp.org>
32851         verify tests: Fix crash with GCC (regression 2020-11-02).
32852         * tests/test-verify.c (main): Fix initializer of s.
32854 2020-11-03  Pádraig Brady  <P@draigBrady.com>
32856         mountlist: recognize more file system types as remote
32858         * lib/mountlist.c (ME_REMOTE): Sync previously unconsidered
32859         "remote" file systems from stat.c in coreutils.
32861 2020-11-02  Bernhard Voelker  <mail@bernhard-voelker.de>
32863         verify tests: Fix -Wuninitialized warning (regression 2020-10-30).
32864         * tests/test-verify.c (main): Initialize state variable.
32865         Reported by Bruno Haible for GCC 5.4.0.
32867 2020-11-02  Paul Eggert  <eggert@cs.ucla.edu>
32869         dfa.h: support inclusion from C++
32870         * lib/dfa.h: Allow multiple inclusion, and inclusion from
32871         C++ code.  The latter was suggested by Arnold Robbins.
32873 2020-11-01  Bruno Haible  <bruno@clisp.org>
32875         ssfmalloc tests: Portability to Linux/PowerPC and Linux/SPARC.
32876         * tests/test-ssfmalloc.c: Include <limits.h>.
32877         (PAGESIZE_MAX): Set to 65536 on Linux/PowerPC.
32879 2020-11-01  Bruno Haible  <bruno@clisp.org>
32881         verify tests: Fix compilation error with MSVC (regression 2020-10-30).
32882         * tests/test-verify.c (test_assume_noreturn): Fix declaration.
32884 2020-11-01  Jim Meyering  <meyering@fb.com>
32886         dfa-tests: test for today's invalid-merge fix
32887         * tests/test-dfa-invalid-merge.sh: New file.
32888         * modules/dfa-tests (Files): Add it.
32889         (TESTS): Add it.
32891 2020-11-01  Norihiro Tanaka  <noritnk@kcn.ne.jp>
32893         dfa: retain sequences of similar nodes in optimization
32894         DFA was merging similar nodes when it should not.  For example,
32895         it would convert a+a+a to a+a.  Now, a sequence of similar nodes
32896         is not merged.  Problem reported by Gonzalo Padrino in
32897         https://bugs.gnu.org/44351
32898         * lib/dfa.c (merge_nfa_state): Skip the follow for repetition in
32899         optimization.
32901 2020-11-01  Jim Meyering  <meyering@fb.com>
32903         test-dfa-match-aux.c: accept EREs, not BREs
32904         * tests/test-dfa-match-aux.c (main): Specify RE_SYNTAX_EGREP, not
32905         RE_SYNTAX_GREP, so tests can use ERE syntax rather than BRE.
32907 2020-10-30  Bernhard Voelker  <mail@bernhard-voelker.de>
32909         verify tests: avoid -Wmissing-declarations warnings
32910         * tests/test-verify.c (test_assume_expressions): Add declaration.
32911         (test_assume_optimization): Likewise.
32912         (test_assume_noreturn): Likewise.
32913         (main): Move down after all other definitions.  While at it, also
32914         call test_assume_expressions and test_assume_optimization as a
32915         runtime check.
32917 2020-10-26  Paul Eggert  <eggert@cs.ucla.edu>
32919         sys_stat: update comments for S_IRWXUGO, S_IXUGO
32920         * lib/sys_stat.in.h (S_IXUGO, S_IRWXUGO): Update comments.
32921         Perhaps these macros should be removed, as they’re not in either
32922         POSIX or GNU.  They could be moved to stat-macros.h, which would
32923         be cleaner in some sense.
32925 2020-10-25  Bruno Haible  <bruno@clisp.org>
32927         ssfmalloc tests: Small tweaks.
32928         * tests/test-ssfmalloc.c: Add comments.
32929         (alloc_pages): Don't require PROT_EXEC bits.
32930         (block_sizes): Add more small sizes, for better coverage of
32931         ssfmalloc-bitmap.h.
32933         ssfmalloc tests: Portability to Minix.
32934         * modules/ssfmalloc-tests (Files): Add m4/mmap-anon.m4.
32935         (configure.ac): Invoke gl_FUNC_MMAP_ANON.
32936         * m4/mmap-anon.m4: Update comment.
32938         ssfmalloc: Portability to AIX.
32939         * modules/ssfmalloc (Include): Add ssfmalloc.h.
32940         (Link): New section.
32941         * modules/ssfmalloc-tests (Makefile.am): Link test-ssfmalloc with
32942         $(LIBTHREAD).
32944         ssfmalloc: Portability to Cygwin.
32945         * lib/ssfmalloc.h: Add parameter PAGESIZE_MAX.
32946         (pg_offset_t): Define depending on PAGESIZE_MAX.
32947         * tests/test-ssfmalloc.c: Undefine PAGESIZE.
32948         (PAGESIZE_MAX): New macro.
32950         ssfmalloc: Fix buffer overrun in bitmap search.
32951         * lib/ssfmalloc-bitmap.h (find_first_packet_set): Don't access the
32952         word *words_end.
32954 2020-10-24  Paul Eggert  <eggert@cs.ucla.edu>
32956         doc: mention ‘restrict’ and C++
32957         * doc/gnulib-readme.texi (C99 features assumed): Document
32958         that ‘restrict’ should be avoided in C++ code.
32960 2020-10-20  Bernhard Voelker  <mail@bernhard-voelker.de>
32962         selinux-at, selinux-h: port to SELinux 3.1
32963         The new release finally deprecated the typedef 'security_context_t',
32964         see <https://github.com/SELinuxProject/selinux/commit/7a124ca275>.
32965         Use the simpler 'char *' instead.
32966         * lib/getfilecon.c (getfilecon): Adjust type of context parameter.
32967         (lgetfilecon): Likewise.
32968         (fgetfilecon): Likewise.
32969         (map_to_failure): Likewise.
32970         (rpl_getfilecon): Likewise.
32971         (rpl_lgetfilecon): Likewise.
32972         (rpl_fgetfilecon): Likewise.
32973         * lib/se-selinux.in.h (security_context_t): Remove typedef.
32974         (getcon): Adjust type of context parameter.
32975         (freecon): Likewise.
32976         (getfscreatecon): Likewise.
32977         (setfscreatecon): Likewise.
32978         (matchpathcon): Likewise.
32979         (getfilecon): Likewise.
32980         (lgetfilecon): Likewise.
32981         (fgetfilecon): Likewise.
32982         (setfilecon): Likewise.
32983         (lsetfilecon): Likewise.
32984         (fsetfilecon): Likewise.
32985         (security_check_context): Likewise.
32986         (security_check_context_raw): Likewise.
32987         (setexeccon): Likewise.
32988         (security_compute_create): Likewise.
32989         * lib/selinux-at.c (getfileconat): Likewise.
32990         (lgetfileconat): Likewise.
32991         (setfileconat): Likewise.
32992         (lsetfileconat): Likewise.
32993         * lib/selinux-at.h: Likewise.
32995 2020-10-19  Bruno Haible  <bruno@clisp.org>
32997         xalloc-die: Fix link error with Solaris cc (regression 2020-07-27).
32998         * lib/xalloc.h (xalloc_die): Don't declare if GNULIB_XALLOC_DIE is 0.
32999         (xmalloc, xzalloc, xcalloc, xrealloc, x2realloc, xmemdup, xstrdup,
33000         XMALLOC, XNMALLOC, XZALLOC, XCALLOC, xnmalloc, xnrealloc, x2nrealloc,
33001         xcharalloc): Don't declare/define if GNULIB_XALLOC is 0.
33002         * modules/xalloc (configure.ac): Define GNULIB_XALLOC.
33003         * modules/xalloc-die (configure.ac): Define GNULIB_XALLOC_DIE.
33005 2020-10-18  Bruno Haible  <bruno@clisp.org>
33007         ssfmalloc: Add tests.
33008         * tests/test-ssfmalloc.c: New file.
33009         * modules/ssfmalloc-tests: New file.
33011         ssfmalloc: New module.
33012         * lib/ssfmalloc.h: New file.
33013         * lib/ssfmalloc-bitmap.h: New file.
33014         * modules/ssfmalloc: New file.
33016 2020-10-18  Bruno Haible  <bruno@clisp.org>
33018         wchar: Fix configure test result on some versions of AIX.
33019         Reported by Clément Chigot <clement.chigot@atos.net> in
33020         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00115.html>.
33021         * m4/wchar_h.m4 (gl_WCHAR_H_INLINE_OK): Execute the test only on glibc
33022         systems.
33024 2020-10-18  Bruno Haible  <bruno@clisp.org>
33026         time: Fix warning about asctime when asctime is not used.
33027         * lib/time.in.h (asctime_r, ctime, ctime_r): Fix _GL_WARN_ON_USE
33028         invocation.
33030 2020-10-18  Bruno Haible  <bruno@clisp.org>
33032         *-list, *-oset, *-omap: Avoid a GCC warning (regression 2020-10-10).
33033         * lib/gl_anylinked_list2.h (gl_linked_iterator_free): Remove
33034         '_GL_ATTRIBUTE_CONST'.
33035         * lib/gl_anytree_list2.h (gl_tree_iterator_free): Likewise.
33036         * lib/gl_anytree_omap.h (gl_tree_iterator_free): Likewise.
33037         * lib/gl_anytree_oset.h (gl_tree_iterator_free): Likewise.
33038         * lib/gl_array_list.c (gl_array_iterator_free): Likewise.
33039         * lib/gl_array_omap.c (gl_array_iterator_free): Likewise.
33040         * lib/gl_array_oset.c (gl_array_iterator_free): Likewise.
33041         * lib/gl_carray_list.c (gl_carray_iterator_free): Likewise.
33043 2020-10-18  Bruno Haible  <bruno@clisp.org>
33045         obstack: Fix a clang warning.
33046         * lib/obstack.c (print_and_abort): Mark as __attribute_noreturn__.
33048 2020-10-16  Bruno Haible  <bruno@clisp.org>
33050         hash: Rename hash_delete to hash_remove.
33051         * lib/hash.h (hash_remove): Renamed from hash_delete.
33052         (hash_delete): New declaration.
33053         * lib/hash.c (hash_remove): Renamed from hash_delete.
33054         (hash_delete): New function.
33055         * tests/test-hash.c (main): Update.
33056         * lib/fts-cycle.c (leave_dir): Likewise.
33057         * NEWS: Mention the change.
33059 2020-10-16  Bruno Haible  <bruno@clisp.org>
33061         hash, xhash: Make usable from C++.
33062         * lib/hash.h: Add extern "C".
33064 2020-10-16  Bruno Haible  <bruno@clisp.org>
33066         hash, xhash: Move comments to the .h file.
33067         * lib/hash.c: Move comments meant for the user from here...
33068         * lib/xhash.c: ... and here...
33069         * lib/hash.h: ... to here.
33071 2020-10-13  Philipp Klaus Krause  <pkk@spth.de>  (tiny change)
33073         Don't declare an intention to modify the return value of strerror.
33074         * tests/test-perror2.c (main): Assign the return value of strerror to a
33075         'const char *' variable.
33077 2020-10-11  Bruno Haible  <bruno@clisp.org>
33079         *printf: Avoid "expanded before it was required" warning.
33080         * m4/printf.m4 (gl_SNPRINTF_TRUNCATION_C99): Define through
33081         AC_DEFUN_ONCE.
33083 2020-10-11  Benji Wiebe  <benjiwiebe14@gmail.com>
33085         getprogname: Add support for OpenServer 6 and UnixWare 7.
33086         * lib/getprogname.c: Include <fcntl.h>, <stdlib.h>, <string.h>.
33087         (getprogname): On OpenServer6 and UnixWare, read /proc/<pid>/cmdline.
33089 2020-10-11  Bruno Haible  <bruno@clisp.org>
33091         tests: Avoid a name clash on UnixWare.
33092         Reported by Tim Rice <tim@multitalents.net> in
33093         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00025.html>.
33094         * tests/nap.h (nap): Define as gl_nap on OpenServer and UnixWare.
33096 2020-10-11  Bruno Haible  <bruno@clisp.org>
33098         stdioext: Update comments regarding UnixWare.
33099         Reported by Tim Rice <tim@multitalents.net> in
33100         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00005.html>.
33101         * lib/fbufmode.c: Update comments.
33102         * lib/fflush.c: Likewise.
33103         * lib/fpending.c: Likewise.
33104         * lib/fpurge.c: Likewise.
33105         * lib/freadable.h: Likewise.
33106         * lib/freadable.c: Likewise.
33107         * lib/freadahead.c: Likewise.
33108         * lib/freading.h: Likewise.
33109         * lib/freading.c: Likewise.
33110         * lib/freadptr.c: Likewise.
33111         * lib/freadseek.c: Likewise.
33112         * lib/fseeko.c: Likewise.
33113         * lib/fseterr.c: Likewise.
33114         * lib/fwritable.h: Likewise.
33115         * lib/fwritable.c: Likewise.
33116         * lib/fwriting.h: Likewise.
33117         * lib/fwriting.c: Likewise.
33119 2020-10-11  Bruno Haible  <bruno@clisp.org>
33121         stdioext: Treat OpenServer 6 and UnixWare 7 like OpenServer 5.
33122         Reported by Tim Rice <tim@multitalents.net> in
33123         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00005.html>.
33124         Uses the info from
33125         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00028.html>.
33126         * lib/stdio-impl.h: Test also __SCO_VERSION__ and __sysv5__.
33128 2020-10-11  Bruno Haible  <bruno@clisp.org>
33130         stdioext: Avoid compilation errors on UnixWare 7.
33131         Reported by Tim Rice <tim@multitalents.net> in
33132         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00127.html>.
33133         * lib/fbufmode.c: Don't include <stdio_ext.h> if it does not exist.
33134         * lib/fpurge.c: Likewise.
33135         * lib/freadable.h: Likewise.
33136         * lib/freading.h: Likewise.
33137         * lib/fwritable.h: Likewise.
33138         * lib/fwriting.h: Likewise.
33139         * m4/fbufmode.m4 (gl_FUNC_FBUFMODE): Test whether <stdio_ext.h> exists.
33140         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
33141         * m4/freadable.m4 (gl_FUNC_FREADABLE): Likewise.
33142         * m4/freading.m4 (gl_FUNC_FREADING): Likewise.
33143         * m4/fwritable.m4 (gl_FUNC_FWRITABLE): Likewise.
33144         * m4/fwriting.m4 (gl_FUNC_FWRITING): Likewise.
33146 2020-10-11  Bruno Haible  <bruno@clisp.org>
33148         stdioext: Update comments regarding Cygwin.
33149         * lib/fpending.c: Update comments.
33150         * lib/fpurge.c: Likewise.
33151         * lib/freadable.h: Likewise.
33152         * lib/freadable.c: Likewise.
33153         * lib/freading.h: Likewise.
33154         * lib/freading.c: Likewise.
33155         * lib/fwritable.h: Likewise.
33156         * lib/fwritable.c: Likewise.
33157         * lib/fwriting.h: Likewise.
33158         * lib/fwriting.c: Likewise.
33160 2020-10-11  KO Myung-Hun  <komh78@gmail.com>
33162         Fix "warning: implicit declaration of function 'pthread_sigmask'".
33163         * lib/signal.in.h [__KLIBC__]: Include <pthread.h>.
33164         * lib/sys_select.in.h [__KLIBC__]: Do not include <signal.h>.
33166 2020-10-10  Bruno Haible  <bruno@clisp.org>
33168         *-list, *-oset, *-omap: Avoid possible compiler warnings.
33169         Reported by Marc Nieper-Wißkirchen in
33170         <https://lists.gnu.org/r/bug-gnulib/2020-10/msg00025.html>.
33171         * lib/gl_anylinked_list2.h (gl_linked_iterator,
33172         gl_linked_iterator_from_to): Mark as 'pure'.
33173         (gl_linked_iterator_free): Mark as 'const'.
33174         * lib/gl_anytree_list2.h (gl_tree_size, gl_tree_node_value,
33175         gl_tree_search_from_to, gl_tree_indexof_from_to, gl_tree_iterator,
33176         gl_tree_iterator_from_to, gl_tree_sortedlist_search,
33177         gl_tree_sortedlist_search_from_to, gl_tree_sortedlist_indexof,
33178         gl_tree_sortedlist_indexof_from_to): Mark as 'pure'.
33179         (gl_tree_iterator_free): Mark as 'const'.
33180         * lib/gl_anytree_omap.h (gl_tree_size, gl_tree_iterator): Mark as
33181         'pure'.
33182         (gl_tree_iterator_free): Mark as 'const'.
33183         * lib/gl_anytree_oset.h (gl_tree_size, gl_tree_next_node,
33184         gl_tree_prev_node, gl_tree_iterator): Mark as 'pure'.
33185         (gl_tree_iterator_free): Mark as 'const'.
33186         * lib/gl_anytreehash_list1.h (node_position, compare_by_position,
33187         compare_position_threshold): Mark as 'pure'.
33188         * lib/gl_array_list.c (gl_array_size, gl_array_indexof_from_to,
33189         gl_array_search_from_to, gl_array_iterator, gl_array_iterator_from_to,
33190         gl_array_sortedlist_indexof_from_to, gl_array_sortedlist_indexof,
33191         gl_array_sortedlist_search_from_to, gl_array_sortedlist_search): Mark as
33192         'pure'.
33193         (gl_array_iterator_free): Mark as 'const'.
33194         * lib/gl_array_omap.c (gl_array_size, gl_array_indexof, gl_array_search,
33195         gl_array_search_atleast, gl_array_iterator): Mark as 'pure'.
33196         (gl_array_iterator_free): Mark as 'const'.
33197         * lib/gl_array_oset.c (gl_array_size, gl_array_indexof, gl_array_search,
33198         gl_array_indexof_atleast, gl_array_search_atleast, gl_array_iterator,
33199         gl_array_iterator_atleast): Mark as 'pure'.
33200         (gl_array_iterator_free): Mark as 'const'.
33201         * lib/gl_carray_list.c (gl_carray_size, gl_carray_node_value,
33202         gl_carray_next_node, gl_carray_previous_node, gl_carray_get_at,
33203         gl_carray_indexof_from_to, gl_carray_search_from_to, gl_carray_iterator,
33204         gl_carray_iterator_from_to, gl_carray_sortedlist_indexof_from_to,
33205         gl_carray_sortedlist_indexof, gl_carray_sortedlist_search_from_to,
33206         gl_carray_sortedlist_search): Mark as 'pure'.
33207         (gl_carray_iterator_free): Mark as 'const'.
33209 2020-10-10  Bruno Haible  <bruno@clisp.org>
33211         rbtree-list: Avoid possible compiler warnings.
33212         This mirrors the change of avltree-list on 2014-09-16.
33213         * lib/gl_rbtree_list.c (gl_rbtree_list_check_invariants): Add extern
33214         declaration. Add cast to void for ignored value of check_invariants.
33216 2020-10-10  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
33218         stack: New module.
33219         * MODULES.html.sh: Add entry for the stack module.
33220         * modules/stack: New file.
33221         * modules/stack-tests: New file.
33222         * lib/stack.h: New file.
33223         * tests/test-stack.c: New file.
33225 2020-10-10  Paul Eggert  <eggert@cs.ucla.edu>
33227         attribute: improve const, pure doc
33228         Problem reported by Marc Nieper-Wißkirchen in:
33229         https://lists.gnu.org/r/bug-gnulib/2020-10/msg00035.html
33230         * lib/attribute.h (ATTRIBUTE_CONST, ATTRIBUTE_PURE): Improv doc.  See:
33231         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=51971#c1
33233 2020-10-05  Paul Eggert  <eggert@cs.ucla.edu>
33235         thread: pacify GCC on Solaris 10
33236         Problem reported by Kiyoshi KANAZAWA for grep (Bug#43666#29).
33237         * lib/glthread/thread.h (gl_thread_self): Use ‘(pthread_t) 0’
33238         instead of ‘(pthread_t) NULL’, to pacify GCC on Solaris 10
33239         where pthread_t is unsigned int.
33241 2020-10-04  Paul Eggert  <eggert@cs.ucla.edu>
33243         c-stack: avoid AS_IF
33244         Problem reported by Bruno Haible in:
33245         https://lists.gnu.org/r/bug-gnulib/2020-10/msg00018.html
33246         * m4/c-stack.m4 (gl_PREREQ_C_STACK): No need for AS_IF.
33248         c-stack: pacify GCC 9.3.1 when using libsigsegv
33249         * lib/c-stack.c [USE_LIBSIGSEGV]: Disable --suggest-attribute=pure.
33251 2020-10-04  Bruno Haible  <bruno@clisp.org>
33253         localename: Fix a couple of "unused parameter" warnings.
33254         Reported by Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de> in
33255         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00014.html>.
33256         * lib/localename.c (gl_locale_name_thread_unsafe, gl_locale_name_thread,
33257         gl_locale_name_posix, gl_locale_name_environ): Add _GL_UNUSED in
33258         parameter list.
33260 2020-10-04  Bruno Haible  <bruno@clisp.org>
33262         vasnprintf: Don't use %n on modern, ISO C 99 compliant platforms.
33263         Suggested by Jeremie Courreges-Anglas <jca@wxcvbn.org> in
33264         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00010.html>.
33265         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Define
33266         HAVE_SNPRINTF_TRUNCATION_C99.
33267         * lib/vasnprintf.c (VASNPRINTF): Don't use %n if
33268         HAVE_SNPRINTF_RETVAL_C99 && HAVE_SNPRINTF_TRUNCATION_C99.
33270 2020-10-03  Paul Eggert  <eggert@cs.ucla.edu>
33272         c-stack: streamline Solaris configuration
33273         * lib/c-stack.c: Omit mention of HAVE_SIGALTSTACK, since
33274         the code is used only if a test for sigaltstack worked
33275         in some other way.
33276         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Do not require gl_LIBSIGSEGV;
33277         instead, execute gl_LIBSIGSEGV only if needed (because the XSI
33278         heuristic does not work).
33279         * modules/c-stack (Files): Add m4/libsigsegv.m4, since
33280         we no longer require the libsigsegv module.
33281         (Depends-on): Depend on havelib, not libsigsegv.
33283         c-stack: stop using SIGSTKSZ
33284         It’s been proposed to stop making SIGSTKSZ an integer constant:
33285         https://sourceware.org/pipermail/libc-alpha/2020-September/118028.html
33286         Also, using SIGSTKSZ in #if did not conform to current POSIX.
33287         Also, avoiding SIGSTKSZ makes the code simpler and easier to grok.
33288         * lib/c-stack.c (SIGSTKSZ): Remove.
33289         (alternate_signal_stack): Now a 64 KiB array, for simplicity.
33290         All uses changed.
33292         c-stack: fix libsigsegv typo
33293         Problem reported by Bruno Haible in:
33294         https://lists.gnu.org/r/bug-gnulib/2020-09/msg00175.html
33295         * lib/c-stack.c (USE_LIBSIGSEGV): Fix typo that caused libsigsegv
33296         to be used only on Solaris (exactly where it is not needed!).
33298 2020-10-03  Thien-Thi Nguyen  <ttn@gnuvola.org>
33300         MODULES.html.sh: Fix typo.
33301         * MODULES.html.sh (Numeric conversion functions <stdlib.h>): Fix typo.
33303 2020-09-28  Paul Eggert  <eggert@cs.ucla.edu>
33305         version-etc: pacify Oracle Studio 12.6
33306         Without this patch, it complains: "version-etc.h", line 64:
33307         warning: token-less macro argument (E_TOKENLESS_MACRO)" when in
33308         pedantic mode.
33309         * lib/version-etc.h (version_etc): Port to C89 macro rules.
33311 2020-09-27  Bruno Haible  <bruno@clisp.org>
33313         Avoid "warning: The macro `AC_DECL_SYS_SIGLIST' is obsolete".
33314         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
33315         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00154.html>.
33316         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Check for sys_siglist
33317         ourselves; don't use AC_DECL_SYS_SIGLIST.
33319 2020-09-27  Bruno Haible  <bruno@clisp.org>
33321         Avoid "warning: The macro `_AC_COMPUTE_INT' is obsolete".
33322         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
33323         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00154.html>.
33324         * m4/gethostname.m4 (gl_PREREQ_HOST_NAME_MAX): Use AC_COMPUTE_INT
33325         instead of _AC_COMPUTE_INT.
33327 2020-09-27  Bruno Haible  <bruno@clisp.org>
33329         Avoid "warning: The macro `AC_HEADER_STDC' is obsolete".
33330         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
33331         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00154.html>.
33332         Based on a patch by Paul Eggert.
33333         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Don't require AC_HEADER_STDC. Don't
33334         test STDC_HEADERS. Assume <stdlib.h> exists.
33335         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
33337 2020-09-27  Bruno Haible  <bruno@clisp.org>
33339         Enable testing of prereleases of Autoconf 2.70.
33340         Suggested by Paul Eggert in
33341         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00160.html>.
33342         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA): Test for Autoconf >= 2.69c, not
33343         >= 2.70.
33344         * m4/largefile.m4 (AC_SYS_LARGEFILE): Likewise.
33345         * m4/pid_t.m4 (AC_TYPE_PID_T): Likewise.
33346         * m4/sys_types_h.m4 (AC_HEADER_MAJOR): Likewise.
33348 2020-09-27  Bruno Haible  <bruno@clisp.org>
33350         Avoid "warning: The macro `AC_PROG_CC_STDC' is obsolete".
33351         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
33352         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00151.html>.
33353         * m4/gnulib-common.m4 (gl_PROG_CC_C99): Use AC_PROG_CC_C99 or
33354         AC_PROG_CC, depending on the Autoconf version.
33356 2020-09-27  Gavin Smith  <gavinsmith0123@gmail.com>
33358         Avoid "warning: The macro `AC_HELP_STRING' is obsolete".
33359         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Use AS_HELP_STRING instead
33360         of AC_HELP_STRING.
33361         * m4/libgcrypt.m4 (AM_PATH_LIBGCRYPT): Likewise.
33363 2020-09-27  Bruno Haible  <bruno@clisp.org>
33365         Avoid "warning: $as_echo_n is obsolete" from autoconf 2.69c.
33366         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
33367         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00151.html>.
33368         * m4/gnulib-common.m4 (gl_CACHE_VAL_SILENT): Use gl_SILENT.
33370 2020-09-27  Bruno Haible  <bruno@clisp.org>
33372         extensions: Simplify last commit.
33373         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't require
33374         AC_GNU_SOURCE ever.
33376 2020-09-26  Paul Eggert  <eggert@cs.ucla.edu>
33378         extensions: require AC_GNU_SOURCE only for <=2.63
33379         Problem reported by Gavin Smith in:
33380         https://lists.gnu.org/r/autoconf/2020-09/msg00012.html
33381         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS):
33382         Require AC_GNU_SOURCE only for Autoconf 2.63 and earlier, since it
33383         shouldn’t be needed after that, and Autoconf 2.70 complains about
33384         it being obsolete.
33386 2020-09-26  Bruno Haible  <bruno@clisp.org>
33388         regex-tests: Make test more robust.
33389         * tests/test-regex.c (main): Make sure to revert the locale to "C" after
33390         the test in "tr_TR.UTF-8" locale. Exit if we can't revert it.
33392 2020-09-25  Paul Eggert  <eggert@cs.ucla.edu>
33394         regex-tests: fix possible Turkish false-alarm
33395         * modules/regex-tests (Depends-on): Add wctype-h.
33396         * tests/test-regex.c: Include wctype.h.
33397         (main): Check that ‘i’ uppercases to ‘İ’ in Turkish,
33398         as the Turkish regex test assumes this.
33400         regex-tests: fix test and add debug output
33401         Perhaps this will fix the recent grep test failure reported at:
33402         https://buildfarm.opencsw.org/buildbot/builders/ggrep-solaris10-sparc/builds/199
33403         At least, the debug output should help narrow down the failure.
33404         * tests/test-regex.c: Include stdarg.h, stdio.h.
33405         (exit_status): New var.
33406         (report_error): New function.
33407         (main): Use it to report failures to stdout instead of merely
33408         exiting with some nonzero status.  The status info alone isn’t
33409         enough to do remote debugging.  In the new tr_TR.UTF-8 test, clear
33410         regex before calling re_compile_pattern, fixing a portability bug.
33412         regex: no longer match glibc
33413         * config/srclist.txt: Comment out regex_internal.c for now.
33415 2020-09-23  Paul Eggert  <eggert@cs.ucla.edu>
33417         regex: fix ignore-case Turkish bug
33418         * lib/regex_internal.c (build_wcs_upper_buffer):
33419         Do not assume that converting single-byte character to upper
33420         yields a single-byte character.  This is not true for Turkish,
33421         where towupper (L'i') yields L'İ', which is not single-byte.
33422         * tests/test-regex.c (main): Test for this bug.
33424         regex: port to weird isascii platforms
33425         * lib/regex_internal.h (isascii) [!_LIBC]: Supply glibc version.
33427 2020-09-20  Norihiro Tanaka  <noritnk@kcn.ne.jp>
33429         dfa: make dfasupported a global function
33430         * lib/dfa.c (dfasupported): Rename, and make it global.
33431         Update caller.
33432         * lib/dfa.h (dfasupported): Add prototype.
33434 2020-09-20  Bruno Haible  <bruno@clisp.org>
33436         canonicalize: Add support for UNC file names on native Windows.
33437         Reported and initial patch by Vaclav Slavik <vaclav@slavik.io> in
33438         <https://savannah.gnu.org/bugs/?59079>.
33439         * lib/canonicalize.c (canonicalize_filename_mode): For UNC file names,
33440         extend the prefix to include the server.
33442 2020-09-20  Bruno Haible  <bruno@clisp.org>
33444         supersede: Fix test failures on native Windows.
33445         * lib/supersede.c (open_supersede): Handle non-regular files on native
33446         Windows like on Solaris.
33447         * tests/test-supersede-open.h (test_open_supersede): Use O_BINARY flag.
33449 2020-09-20  Paul Eggert  <eggert@cs.ucla.edu>
33451         test-stdalign: test Oracle Studio better
33452         * doc/posix-headers/stdalign.texi (stdalign.h):
33453         * tests/test-stdalign.c (main):
33454         Sun Studio Bug #2125432 seems to be fixed.
33456         c-stack: output diagnostic in single 'write'
33457         * lib/c-stack.c (die): In the typical case, use just one 'write'
33458         syscall to output the diagnostic, as this lessens interleaving.
33459         (die, c_stack_action): Assume C99.
33460         * modules/c-stack (Depends-on): Add c99, mempcpy.
33462         c-stack: improve checking if !libsigsegv
33463         If SIGINFO_WORKS, do not treat a null pointer dereference as if it
33464         were a stack overflow.  Use uintptr_t and INT_ADD_WRAPV to avoid
33465         unlikely pointer overflow.  Also, fix some obsolete code and typos.
33466         I found these problems while looking into this bug report:
33467         https://lists.gnu.org/r/grep-devel/2020-09/msg00053.html
33468         * lib/c-stack.c: Include c-stack.h first, to test interface.
33469         Include inttypes.h for UINTPTR_MAX, stdbool.h, stddef.h for
33470         max_align_t, intprops.h for INT_ADD_WRAPV.
33471         (USE_LIBSIGSEGV): New macro; use it to simplify later code.
33472         (SIGSTKSZ): Simplify setup.  Work around libsigsegv bug only
33473         for libsigsegv 2.8 and earlier since the bug should be fixed
33474         after that.
33475         (alternate_signal_stack): Use max_align_t instead of doing it by hand.
33476         (segv_handler, overflow_handler, segv_handler) [DEBUG]:
33477         Assume sprintf returns byte count; this assumption is safe now.
33478         (page_size): New static volatile variable, since sysconf isn’t
33479         documented to be async-signal-safe on Solaris.  This variable is
33480         present and used if (!USE_LIBSIGSEGV && HAVE_SIGALTSTACK &&
33481         HAVE_DECL_SIGALTSTACK && HAVE_STACK_OVERFLOW_HANDLING &&
33482         SIGINFO_WORKS).
33483         (segv_handler): Use it if present.  Never report null pointer
33484         dereference as a stack overflow.  Check for (unlikely) unsigned
33485         and/or pointer overflow.
33486         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
33487         Rename cache variables to gl_cv_sys_stack_overflow_works
33488         and gl_cv_sys_xsi_stack_overflow_heuristic.
33489         All uses changed.
33490         (gl_PREREQ_C_STACK): Do not require AC_FUNC_ALLOCA, since
33491         c-stack no longer uses STACK_DIRECTION.
33492         Do not check for unistd.h, since we depend on unistd.
33493         Fix shell typo ‘$"ac_cv_sys_xsi_stack_overflow_heuristic"’.
33494         * modules/c-stack (Depends-on): Sort.  Add intprops, inttypes,
33495         stdbool, stddef.
33497 2020-09-20  Bruno Haible  <bruno@clisp.org>
33499         Revert now-unnecessary override of config.guess on Alpine Linux 3.10.
33500         * m4/musl.m4: Revert 2020-09-19 patch.
33501         * m4/setlocale_null.m4: Likewise.
33502         * modules/setlocale-null: Likewise.
33504 2020-09-19  Ben Pfaff  <blp@cs.stanford.edu>
33505             Bruno Haible  <bruno@clisp.org>
33507         relocatable-prog: Fix for multiple relocatable library directories.
33508         * build-aux/reloc-ldflags: Fix handling of multiple relocatable library
33509         directories.  Each one needs its own -Wl,-rpath,$dir option, instead of
33510         being attached to a single one.
33512 2020-09-19  Jim Meyering  <meyering@fb.com>
33514         test-verify.c: avoid -Wshadow warnings
33515         * tests/test-verify.c (gx): Rename global from "x". Adjust use.
33516         (enum): Capitalize member names. Adjust uses.
33518 2020-09-19  Bruno Haible  <bruno@clisp.org>
33520         havelib: Avoid linking with libc.a on GNU systems.
33521         Reported by Bruce Dubbs <bruce.dubbs@gmail.com> in
33522         <https://lists.gnu.org/archive/html/grep-devel/2020-09/msg00052.html>.
33523         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): When processing the
33524         dependency_libs value of a .la file, ignore '-lc' options on GNU
33525         systems.
33527 2020-09-19  Bruno Haible  <bruno@clisp.org>
33529         Fix recognition of musl libc on Alpine Linux 3.10.
33530         Reported by Jeffrey Walton <noloader@gmail.com> in
33531         <https://lists.gnu.org/archive/html/grep-devel/2020-09/msg00020.html>.
33532         * m4/musl.m4 (gl_MUSL_CANONICAL_HOST): New macro.
33533         (gl_MUSL_LIBC): Require it.
33534         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Likewise.
33535         * modules/setlocale-null (Files): Add m4/musl.m4.
33537 2020-09-19  Bruno Haible  <bruno@clisp.org>
33539         nl_langinfo: Make multithread-safe on Solaris 10 and Solaris 11.3.
33540         Reported for Solaris 10 by Dagobert Michelsen via Paul Eggert in
33541         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00023.html>
33542         and for Solaris 11.3 by Jeffrey Walton <noloader@gmail.com> in
33543         <https://lists.gnu.org/archive/html/bug-grep/2020-06/msg00013.html>.
33544         * lib/nl_langinfo-lock.c: New file, based on lib/setlocale_null-lock.c.
33545         * lib/nl_langinfo.c: Include <stdlib.h> and <windows.h> or <pthread.h>
33546         or <threads.h>.
33547         (ITEMS, MAX_RESULT_LEN): New macros.
33548         (nl_langinfo_unlocked): New function.
33549         (gl_get_nl_langinfo_lock): New declaration.
33550         (nl_langinfo_with_lock): New function, based on lib/setlocale_null.c.
33551         (rpl_nl_langinfo): Use nl_langinfo_with_lock instead of nl_langinfo.
33552         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Require gl_PTHREADLIB. Define
33553         HAVE_THREADS_H. Set NL_LANGINFO_MTSAFE. If setting it to 0, also set
33554         REPLACE_NL_LANGINFO.
33555         (gl_PREREQ_NL_LANGINFO_LOCK): New macro.
33556         * modules/nl_langinfo (Files): Add lib/nl_langinfo-lock.c,
33557         lib/windows-initguard.h, m4/threadlib.m4, m4/visibility.m4.
33558         (configure.ac): Compile nl_langinfo-lock.c when NL_LANGINFO_MTSAFE is 0.
33559         * doc/posix-functions/nl_langinfo.texi: Mention the Solaris bug.
33561 2020-09-18  Bruno Haible  <bruno@clisp.org>
33563         fsusage, getaddrinfo: Produce more regular configure output.
33564         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Remove AC_MSG_CHECKING without
33565         corresponding AC_MSG_RESULT.
33566         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
33568 2020-09-18  Bruno Haible  <bruno@clisp.org>
33570         Add back gl_SILENT.
33571         * m4/gnulib-common.m4 (GL_TMP_FD, gl_SILENT): New macros.
33573 2020-09-18  Paul Eggert  <eggert@cs.ucla.edu>
33575         c-stack-tests: fix -fsanitize=undefined false alarm
33576         * tests/test-c-stack2.sh: Skip the test-harness self-test
33577         if ‘gcc -fsanitize=undefined’ is in use.
33579 2020-09-17  Paul Eggert  <eggert@cs.ucla.edu>
33581         signalblocking: simplify and remove gl_SILENT
33582         gl_SILENT was problematic because if a trap was sprung, stderr
33583         generated during the trap was lost.  Avoid the problem by
33584         removing the need for gl_SILENT.
33585         * m4/gnulib-common.m4 (GL_TMP_FD, gl_SILENT): Remove.
33586         * m4/signalblocking.m4 (gl_SIGNALBLOCKING):
33587         Simplify, avoiding the need for gl_SILENT while preserving the
33588         ability of the user to override the value of the cache variable,
33589         now ac_cv_func_sigprocmask.
33591 2020-09-17  Bruno Haible  <bruno@clisp.org>
33593         sigprocmask: Fix configuration failure on Solaris 10 (regr. 2020-07-25).
33594         * m4/gnulib-common.m4 (GL_TMP_FD): New macro.
33595         (gl_SILENT): Use 'exec', not a compound statement, to redirect
33596         AS_MESSAGE_FD.
33598 2020-09-17  Paul Eggert  <eggert@cs.ucla.edu>
33600         intprops, xalloc: avoid __builtin_mul_overflow_p with Clang
33601         Problem reported by Nelson H. F. Beebe for clang 9.0.1 in:
33602         https://lists.gnu.org/r/grep-devel/2020-09/msg00028.html
33603         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P) [__clang__]:
33604         Define to 0.
33605         * lib/xalloc-oversized.h (xalloc_oversized) [__clang__]:
33606         Do not use __builtin_mul_overflow_p.
33608         libc-config: port __THROW to Ubuntu 4
33609         * lib/cdefs.h (__THROW): Do not use __attribute__ ((__nothrow__))
33610         for GCC 3.3.  Problem reported by Jeffrey Walton in:
33611         https://lists.gnu.org/r/bug-gnulib/2019-07/msg00058.html
33612         The GCC 3.3.4 documentation says the attribute should work, but
33613         apparently it does not work on Ubuntu 4’s GCC 3.3.  There seems
33614         little point or desire to research this circa-2004 platform further,
33615         so just avoid the attribute there.
33617 2020-09-17  Jim Meyering  <meyering@fb.com>
33619         test-dfa-match.sh: port timeout work-around to newer Busybox
33620         * tests/test-dfa-match.sh: Update timeout -t portability test to
33621         accommodate Busybox 1.30.0 and newer.
33623 2020-09-16  Paul Eggert  <eggert@cs.ucla.edu>
33625         fnmatch: adjust to match glibc fix
33626         This fixes handling of collating symbols in fnmatch (glibc bug 26620).
33627         This does not affect Gnulib; it merely keeps Gnulib and glibc
33628         closer together, to help with any eventual merge, by incorporating
33629         a recent glibc patch.  The patch and the following commentary is
33630         by Andreas Schwab.
33631         * lib/fnmatch_loop.c (FCT) [WIDE_CHAR_VERSION]: The variable idx
33632         contains the index into the extra array, whereas wextra points
33633         into the extra array at this index, containing the length of the
33634         following collating sequence in the wide character representation.
33636 2020-09-16  Bruno Haible  <bruno@clisp.org>
33638         stat, fstat: Fix compilation error with old mingw headers.
33639         Reported by Eli Zaretskii <eliz@gnu.org> in
33640         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00027.html>.
33641         * lib/stat-w32.c (VOLUME_NAME_NONE): Define if the Windows headers don't
33642         define it.
33644 2020-09-16  Bruno Haible  <bruno@clisp.org>
33646         stat, fstat: Fix when compiling for versions older than Windows Vista.
33647         Reported by Eli Zaretskii <eliz@gnu.org> in
33648         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00027.html>.
33649         * lib/stat-w32.c: Include <sdkddkver.h>. Test the value of _WIN32_WINNT
33650         that was originally set before we redefined it.
33651         * m4/stat.m4 (gl_PREREQ_STAT_W32): New macro.
33652         (gl_PREREQ_STAT): Require it.
33653         * m4/fstat.m4 (gl_PREREQ_FSTAT): Likewise.
33655 2020-09-15  Paul Eggert  <eggert@cs.ucla.edu>
33657         dfa: remove dfa-heap-overrun workaround
33658         * lib/dfa.c (reorder_tokens): Go back to a single pass that
33659         both sets map[*] and does other things.  This reverts
33660         2020-09-14T01:20:01Z!eggert@cs.ucla.edu, which is no longer
33661         neeeded now that 2020-09-14T13:21:05Z!noritnk@kcn.ne.jp
33662         fixed the underlying problem.
33664 2020-09-13  Paul Eggert  <eggert@cs.ucla.edu>
33666         dfa: avoid use of uninitialized constraint
33667         * lib/dfa.c (merge_nfa_state): Do not initialize the constraint
33668         to zero here.
33669         (dfaoptimize): Do it here instead, via xcalloc.  This prevents the
33670         use of an uninitialized constraint by later code when ! (flags[i]
33671         & OPT_QUEUED) means merge_nfa_state was not called to initialize
33672         the constraint.  Problem found by running 'valgrind src/grep -E
33673         '(^| )*(a|b)*(c|d)*( |$)' < /dev/null' on Ubuntu 18.04.5 x86-64.
33675         dfa: assume C99 in reorder_tokens
33676         * lib/dfa.c (reorder_tokens): Assume C99 and simplify.
33678         dfa: fix dfa-heap-overrun failure
33679         * lib/dfa.c (reorder_tokens): When setting
33680         map[d->follows[i].elems[j].index], instead of incorrectly assuming
33681         that (i < d->follows[i].elems[j].index), use two loops, one to set
33682         the map array and the other to use it.  The incorrect assumption
33683         caused some elements to be missed, and this in turn caused grep's
33684         dfa-heap-overrun test to fail on Solaris 10 sparc when compiled
33685         with GCC.  I found this bug while investigating
33686         https://buildfarm.opencsw.org/buildbot/builders/ggrep-solaris10-sparc/builds/183
33687         and I think the bug also occurs on GNU/Linux but with more-subtle
33688         symptoms.  The bug predates the recent dfa.c changes; perhaps the
33689         recent changes make the bug more likely.
33691 2020-09-13  Bruno Haible  <bruno@clisp.org>
33693         parse-datetime: Make the build rule work with parallel 'make'.
33694         Reported by Daiki Ueno <ueno@gnu.org> in
33695         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00036.html>.
33696         * modules/parse-datetime (Makefile.am): Use a phony target and the
33697         general idiom for rules that produce multiple files.
33699 2020-09-13  Ben Pfaff  <blp@cs.stanford.edu>
33701         getpass: Check for nonnull prompt argument while avoiding warnings.
33702         * lib/getpass.c (_GL_ARG_NONNULL): Define to empty.
33703         (getpass) [!_WIN32]: Print prompt only if nonnull.
33705 2020-09-12  Paul Eggert  <eggert@cs.ucla.edu>
33707         dfa: epsilon-closure tweaks (Bug#40634)
33708         Rename BACKWORD to BACKWARD consistently.
33709         * lib/dfa.c (struct dfa): Reorder members to reduce fragmentation.
33710         (addtok_mb): Redo slightly to make it act more like a state machine.
33711         Check depth only when it increases.
33712         (epsclosure): Let the switch test the tokens.
33713         (dfaanalyze): Cache tindex.  Simplify position loops.
33714         Prefer xcalloc to xnmalloc + explicit zeroing.  Free BACKWARD
33715         only if it is not null, since we're testing that anyway.
33716         (dfaanalyze, build_state): Use merge2 instead of doing it by hand.
33718 2020-09-12  Norihiro Tanaka  <noritnk@kcn.ne.jp>
33720         dfa: use backward set in removal of epsilon closure
33721         When removing in epsilon closure, the code searched all nodes
33722         sequentially, and this was slow for some cases.  Build a backward
33723         set before search, and only check previous position with the set.
33724         Problem reported in <https://bugs.gnu.org/40634>.
33725         * lib/dfa.c (struct dfa): New member 'epsilon'.
33726         (addtok_mb): Check whether a pattern has epsilon node or not.
33727         (epsclosure): New arg BACKWORD; caller changed.  When removing
33728         epsilon node and reconnecting, check only previous positions.
33729         Treat BEG as if it were character.
33730         (dfaanalyze): Build backward set.
33732 2020-09-10  Paul Eggert  <eggert@cs.ucla.edu>
33734         canonicalize: fix pointer indexing bugs
33735         Problem reported by Florian Weimer in:
33736         https://lists.gnu.org/r/bug-gnulib/2020-09/msg00025.html
33737         * lib/canonicalize-lgpl.c (__realpath):
33738         * lib/canonicalize.c (canonicalize_filename_mode):
33739         Do not generate a pointer past the end of the array.
33740         * lib/canonicalize.c (canonicalize_filename_mode):
33741         Do not use a pointer after passing it to realloc.
33743 2020-09-09  Paul Eggert  <eggert@cs.ucla.edu>
33745         tempname: help merge with glibc
33746         Inspired by draft patches by Adhemerval Zanella in:
33747         https://sourceware.org/pipermail/libc-alpha/2020-September/117501.html
33748         https://sourceware.org/pipermail/libc-alpha/2020-September/117502.html
33749         * lib/tempname.c: Include stdalign.h, time.h.
33750         If _LIBC, do not include random-bits.h.
33751         (__getrandom, __clock_gettime64, __timespec64) [!_LIBC]: New macros.
33752         (RANDOM_BITS): Remove, replacing with ...
33753         (random_bits): ... this new static function.  All uses changed.
33754         Add entropy each time if getrandom is not supported.
33755         (RANDOM_VALUE, BASE_62_DIGITS, BASE_62_POWER):
33756         Assume 64-bit support a la C99.
33757         (try_tempname_len): Take advantage of ASLR when initializing
33758         random value.
33759         * modules/tempname (Depends-on): Add clock-time, stdalign, time.
33761         getcwd: merge recent glibc changes
33762         * lib/getcwd.c (GETCWD_RETURN_TYPE) [!_LIBC]: New macro.
33763         (__getcwd, getcwd) [_LIBC && !GETCWD_RETURN_TYPE]: Add aliases.
33765 2020-09-06  Bruno Haible  <bruno@clisp.org>
33767         attribute: Clarify which file to include.
33768         * modules/attribute (Include): Add "attribute.h".
33770 2020-09-06  Bruno Haible  <bruno@clisp.org>
33772         pipe-filter-ii, pipe-filter-gi: Fix warnings on native Windows.
33773         * lib/pipe-filter-ii.c: Include <process.h>.
33774         * lib/pipe-filter-gi.c: Likewise.
33776 2020-09-05  Paul Eggert  <eggert@cs.ucla.edu>
33778         verify: avoid __builtin_assume
33779         Our latest attempt to use Clang’s __builtin_assume caused a crash
33780         in GNU Emacs that we spent quite some time tracking down as being
33781         caused by the switch to __builtin_assume.  It’s not known whether
33782         the crash is due is a Clang bug or a portability bug in GNU Emacs.
33783         For now, play it safe and avoid __builtin_assume.
33784         * lib/verify.h (_GL_HAS_BUILTIN_ASSUME): Remove.
33785         (assume): Simplify by not trying to use Clang’s __builtin_assume.
33787 2020-09-05  Bruno Haible  <bruno@clisp.org>
33789         Fix several "warning: no previous prototype for function".
33790         * modules/unicase/locale-language (Makefile.am): Add a 'static' keyword
33791         in front of the declaration of the lookup function in
33792         unicase/locale-languages.h.
33793         * modules/unictype/bidiclass-byname (Makefile.am): Likewise in
33794         unictype/bidi_byname.h.
33795         * modules/unictype/category-byname (Makefile.am): Likewise in
33796         unictype/categ_byname.h.
33797         * modules/unictype/combining-class-byname (Makefile.am): Likewise in
33798         unictype/combiningclass_byname.h.
33799         * modules/unictype/joininggroup-byname (Makefile.am): Likewise in
33800         unictype/joininggroup_byname.h.
33801         * modules/unictype/joiningtype-byname (Makefile.am): Likewise in
33802         unictype/joiningtype_byname.h.
33803         * modules/unictype/property-byname (Makefile.am): Likewise in
33804         unictype/pr_byname.h.
33805         * modules/unictype/scripts (Makefile.am): Likewise in
33806         unictype/scripts_byname.h.
33807         * modules/uninorm/composition (Makefile.am): Likewise in
33808         uninorm/composition-table.h.
33810 2020-09-05  Bruno Haible  <bruno@clisp.org>
33812         select: Fix "warning: no previous prototype for function".
33813         * lib/select.c: Include <sys/select.h>.
33815 2020-09-05  Bruno Haible  <bruno@clisp.org>
33817         Use module 'c99' when needed for variadic macros with '...' syntax.
33818         * modules/crypto/sm3 (Depends-on): Add c99.
33820 2020-09-05  Bruno Haible  <bruno@clisp.org>
33822         Use module 'c99' when needed for subobject initializer syntax.
33823         * modules/tempname (Depends-on): Add c99.
33824         * modules/nstrftime-tests (Depends-on): Likewise.
33826 2020-09-05  Bruno Haible  <bruno@clisp.org>
33828         Use module 'c99' when needed for declaration-after-statement syntax.
33829         * modules/backup-rename (Depends-on): Add c99.
33830         * modules/backupfile (Depends-on): Likewise.
33831         * modules/bitset-tests (Depends-on): Likewise.
33832         * modules/bitsetv (Depends-on): Likewise.
33833         * modules/c-strtod (Depends-on): Likewise.
33834         * modules/c-strtold (Depends-on): Likewise.
33835         * modules/clean-temp (Depends-on): Likewise.
33836         * modules/copy-file (Depends-on): Likewise.
33837         * modules/crypto/hmac-md5-tests (Depends-on): Likewise.
33838         * modules/crypto/hmac-sha1-tests (Depends-on): Likewise.
33839         * modules/crypto/hmac-sha256-tests (Depends-on): Likewise.
33840         * modules/crypto/hmac-sha512-tests (Depends-on): Likewise.
33841         * modules/crypto/md5-buffer (Depends-on): Likewise.
33842         * modules/crypto/md5-tests (Depends-on): Likewise.
33843         * modules/crypto/sha1-buffer (Depends-on): Likewise.
33844         * modules/crypto/sha1-tests (Depends-on): Likewise.
33845         * modules/crypto/sha256-buffer (Depends-on): Likewise.
33846         * modules/crypto/sha256-tests (Depends-on): Likewise.
33847         * modules/crypto/sha512-buffer (Depends-on): Likewise.
33848         * modules/crypto/sha512-tests (Depends-on): Likewise.
33849         * modules/diffseq (Depends-on): Likewise.
33850         * modules/fatal-signal (Depends-on): Likewise.
33851         * modules/fchmodat (Depends-on): Likewise.
33852         * modules/fstrcmp (Depends-on): Likewise.
33853         * modules/fsusage (Depends-on): Likewise.
33854         * modules/fts (Depends-on): Likewise.
33855         * modules/fts-tests (Depends-on): Likewise.
33856         * modules/getumask (Depends-on): Likewise.
33857         * modules/git-merge-changelog (Depends-on): Likewise.
33858         * modules/hash-map (Depends-on): Likewise.
33859         * modules/hash-set (Depends-on): Likewise.
33860         * modules/lchmod (Depends-on): Likewise.
33861         * modules/libgmp-tests (Depends-on): Likewise.
33862         * modules/libtextstyle-optional-tests (Depends-on): Likewise.
33863         * modules/linkedhash-map (Depends-on): Likewise.
33864         * modules/linkedhash-set (Depends-on): Likewise.
33865         * modules/long-options (Depends-on): Likewise.
33866         * modules/mbrtoc32 (Depends-on): Likewise.
33867         * modules/memchr2-tests (Depends-on): Likewise.
33868         * modules/memmem-tests (Depends-on): Likewise.
33869         * modules/memrchr-tests (Depends-on): Likewise.
33870         * modules/mktime-internal (Depends-on): Likewise.
33871         * modules/nstrftime (Depends-on): Likewise.
33872         * modules/opendirat (Depends-on): Likewise.
33873         * modules/parse-datetime (Depends-on): Likewise.
33874         * modules/quotearg-simple-tests (Depends-on): Likewise.
33875         * modules/same (Depends-on): Likewise.
33876         * modules/supersede (Depends-on): Likewise.
33877         * modules/supersede-tests (Depends-on): Likewise.
33878         * modules/time_rz (Depends-on): Likewise.
33879         * modules/unistr/u16-chr-tests (Depends-on): Likewise.
33880         * modules/unistr/u32-chr-tests (Depends-on): Likewise.
33881         * modules/unistr/u8-chr-tests (Depends-on): Likewise.
33882         * modules/xalloc (Depends-on): Likewise.
33883         * modules/xnanosleep (Depends-on): Likewise.
33885 2020-09-05  Bruno Haible  <bruno@clisp.org>
33887         Fix "warning: array initialized from parenthesized string constant".
33888         * tests/test-memmem.c (main): Remove parentheses around string constant.
33889         * tests/test-c-strcasestr.c (main): Likewise.
33890         * tests/test-strcasestr.c (main): Likewise.
33892 2020-09-05  Bruno Haible  <bruno@clisp.org>
33894         argmatch tests: Fix ISO C compliance warning.
33895         * tests/test-argmatch.c: Omit semicolon after ARGMATCH_DEFINE_GROUP
33896         invocation.
33898 2020-09-05  Bruno Haible  <bruno@clisp.org>
33900         uniname/uniname: Fix -Wshadow warning.
33901         * lib/uniname/uniname.c (unicode_name_word): Don't declare i upfront.
33902         * modules/uniname/uniname (Depends-on): Add c99.
33904 2020-09-05  Bruno Haible  <bruno@clisp.org>
33906         uniname/uniname: Fix -Wshorten-64-to-32 warnings.
33907         * lib/uniname/uniname.c (unicode_name_word_lookup): Change type of last
33908         argument to size_t.
33909         (unicode_name_character): Change type of len, n1, n2, n3, words_length,
33910         n to size_t.
33912 2020-09-05  Bruno Haible  <bruno@clisp.org>
33914         unistr/u{8,16,32}-uctomb: Avoid possible trouble with huge strings.
33915         * lib/unistr.in.h (u8_uctomb_aux, u8_uctomb, u16_uctomb_aux, u16_uctomb,
33916         u32_uctomb): Change type of last argument to ptrdiff_t.
33917         * lib/unistr/u8-uctomb.c (u8_uctomb): Likewise.
33918         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Likewise.
33919         * lib/unistr/u16-uctomb.c (u16_uctomb): Likewise.
33920         * lib/unistr/u16-uctomb-aux.c (u16_uctomb_aux): Likewise.
33921         * lib/unistr/u32-uctomb.c (u32_uctomb): Likewise.
33923 2020-09-01  Paul Eggert  <eggert@cs.ucla.edu>
33925         manywarnings: remove -Wchkp and -Wabi from C++ too
33926         Suggested by Reuben Thomas in:
33927         https://lists.gnu.org/r/bug-gnulib/2020-09/msg00001.html
33928         At some point somebody should merge the many other manywarnings-c.m4
33929         changes into manywarnings-c++.m4 too, e.g.,
33930         2020-07-02T00:00:51Z!eggert@cs.ucla.edu.
33931         * m4/manywarnings-c++.m4 (gl_MANYWARN_ALL_GCC_CXX_IMPL):
33932         Remove -Wchkp, -Wabi.
33934 2020-08-30  Bruno Haible  <bruno@clisp.org>
33936         strerrorname_np: Add tests.
33937         * tests/test-strerrorname_np.c: New file.
33938         * modules/strerrorname_np-tests: New file.
33940         strerrorname_np: New module.
33941         * lib/string.in.h (strerrorname_np): New declaration.
33942         * lib/strerrorname_np.c: New file.
33943         * m4/strerrorname_np.m4: New file.
33944         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Test whether strerrorname_np
33945         is declared.
33946         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_STRERRORNAME_NP,
33947         HAVE_STRERRORNAME_NP, REPLACE_STRERRORNAME_NP.
33948         * modules/string (Makefile.am): Substitute GNULIB_STRERRORNAME_NP,
33949         HAVE_STRERRORNAME_NP, REPLACE_STRERRORNAME_NP.
33950         * modules/strerrorname_np: New file.
33951         * tests/test-string-c++.cc: Verify the signature of strerrorname_np.
33952         * doc/glibc-functions/strerrorname_np.texi: Mention the new module and
33953         the glibc 2.32 bug.
33955 2020-08-27  Paul Eggert  <eggert@cs.ucla.edu>
33957         perror, strerror_r: remove unportable tests
33958         Problem reported by Florian Weimer in:
33959         https://lists.gnu.org/r/bug-gnulib/2020-08/msg00220.html
33960         * tests/test-perror2.c (main):
33961         * tests/test-strerror_r.c (main): Omit unportable tests.
33963 2020-08-26  Bruno Haible  <bruno@clisp.org>
33965         stdint, wchar, wctype-h: Change configure message.
33966         * m4/wint_t.m4 (gt_TYPE_WINT_T): Say "checking whether wint_t is large
33967         enough..." instead of "checking whether wint_t is too small...".
33969 2020-08-26  Bruno Haible  <bruno@clisp.org>
33971         time_rz: Change configure message.
33972         * m4/time_rz.m4 (gl_TIME_RZ): Say "checking whether localtime works even
33973         near extrema..." instead of "checking whether localtime loops forever
33974         near extrema...".
33976 2020-08-26  Bruno Haible  <bruno@clisp.org>
33978         stdint: Change configure message.
33979         * m4/stdint.m4 (gl_STDINT_H): Say "checking whether stdint.h works
33980         without ISO C predefines..." instead of "checking whether stdint.h
33981         predates C++11...".
33983 2020-08-26  Bruno Haible  <bruno@clisp.org>
33985         socketlib: Change configure message.
33986         * m4/socketlib.m4 (gl_SOCKETLIB): Say "checking for WSAStartup..."
33987         instead of "checking if we need to call WSAStartup in winsock2.h and
33988         -lws2_32...".
33990 2020-08-26  Bruno Haible  <bruno@clisp.org>
33992         include_next: Change configure message.
33993         * m4/include_next.m4 (gl_INCLUDE_NEXT): Say "checking whether source
33994         code line length is unlimited..." instead of "checking whether system
33995         header files limit the line length...".
33997 2020-08-26  Bruno Haible  <bruno@clisp.org>
33999         getcwd: Change configure message.
34000         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Say "checking
34001         whether getcwd succeeds when 4k < cwd_length < 16k..." instead of
34002         "checking whether getcwd aborts when 4k < cwd_length < 16k...".
34004 2020-08-26  Bruno Haible  <bruno@clisp.org>
34006         chdir-long: Change configure message.
34007         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Say "checking whether this
34008         system supports file names of any length..." instead of "checking
34009         whether this system has an arbitrary file name length limit...".
34010         Set gl_cv_have_unlimited_file_name_length instead of
34011         gl_cv_have_arbitrary_file_name_length_limit.
34012         * modules/chdir-long (Depends-on, configure.ac): Update accordingly.
34014 2020-08-26  Bruno Haible  <bruno@clisp.org>
34016         ceill: Change configure message.
34017         * m4/ceill.m4 (gl_FUNC_CEILL): Say "checking whether ceill() works..."
34018         instead of "checking whether ceill() breaks with small values...".
34020 2020-08-26  Bruno Haible  <bruno@clisp.org>
34022         iconv: Change configure message.
34023         * m4/iconv.m4 (AM_ICONV): Say "checking whether iconv is compatible
34024         with its POSIX signature..." instead of "checking for iconv
34025         declaration...". Remove K&R C support.
34027 2020-08-26  Paul Eggert  <eggert@cs.ucla.edu>
34029         getcwd: help the merge back into glibc
34030         This patch was inspired by Adhemerval Zanella’s proposed glibc patches:
34031         https://sourceware.org/pipermail/libc-alpha/2020-August/117294.html
34032         The idea is to make it easier for Gnulib lib/getcwd.c to match
34033         glibc io/getcwd-generic.c.
34034         * lib/getcwd.c [_LIBC]: Do not include pathmax.h.
34035         Include not-cancel.h.
34036         (HAVE_OPENAT, D_INO_IN_DIRENT, HAVE_MSVC_INVALID_PARAMETER_HANDLER)
34037         (HAVE_MINIMALLY_WORKING_GETCWD): Define for the _LIBC case.
34038         (__getcwd, __lstat, __readdir) [!_LIBC]: Remove these macros.
34039         (__close_nocancel_nostatus, __getcwd_generic, stat64, __fstat64)
34040         (__fstatat64, __lstat64, __readdir64, __fdopendir, __openat)
34041         (__rewinddir, __openat64, dirent64) [_LIBC]: New macros.
34042         (__getcwd_generic): Rename from __getcwd.
34043         Use the abovementioned macros for consistency with glibc.
34044         (weak_alias): Remove.
34046 2020-08-25  Bruno Haible  <bruno@clisp.org>
34048         verify: Avoid warnings when assume(0) is used.
34049         Reported by Mattias Engdegård <mattiase@acm.org> via Paul Eggert in
34050         <https://lists.gnu.org/archive/html/emacs-devel/2020-08/msg00838.html>.
34051         * lib/verify.h (assume): Use __builtin_unreachable if the argument is
34052         the constant 0.
34053         * tests/test-verify.c (f): New function.
34054         (state): New type.
34055         (test_assume_expressions, test_assume_optimization,
34056         test_assume_noreturn): New functions.
34058 2020-08-25  Bruno Haible  <bruno@clisp.org>
34060         fstrcmp: Clarification regarding NOTE_ORDERED.
34061         * lib/fstrcmp.c (NOTE_ORDERED): Define to false.
34063 2020-08-24  Paul Eggert  <eggert@cs.ucla.edu>
34065         diffseq: new option NOTE_ORDERED
34066         Problem reported by Phil Sainty <https://bugs.gnu.org/42931>.
34067         * NEWS: Mention this.
34068         * lib/diffseq.h (NOTE_ORDERED): New macro.
34069         (IF_LINT2): Remove; no longer needed.
34070         (compareseq): If (!NOTE_ORDERED), recurse on the smaller
34071         subproblem and iterate to do the larger.
34073 2020-08-23  Paul Eggert  <eggert@cs.ucla.edu>
34075         sys_types: let Autoconf 2.70 do pid_t
34076         * m4/pid_t.m4 (AC_TYPE_PID_T): Redefine this Autoconf macro
34077         only for Autoconf versions 2.69 and earlier, since 2.70
34078         will be fixed.
34080 2020-08-23  Bruno Haible  <bruno@clisp.org>
34082         tests: Don't assume that pid_t fits in an 'int'.
34083         * tests/test-nonblocking-pipe-main.c (main): Use type 'pid_t' instead
34084         of 'int'.
34085         * tests/test-nonblocking-socket-main.c (main): Likewise.
34087         sys_types: Fix definition of pid_t on 64-bit MSVC.
34088         * m4/pid_t.m4: New file.
34089         * modules/sys_types (Files): Add it.
34090         * modules/dirent (Files): Likewise.
34091         * modules/fcntl-h (Files): Likewise.
34092         * modules/sched (Files): Likewise.
34093         * modules/signal-h (Files): Likewise.
34094         * modules/spawn (Files): Likewise.
34095         * modules/sys_stat (Files): Likewise.
34096         * modules/sys_wait (Files): Likewise.
34097         * modules/termios (Files): Likewise.
34098         * modules/unistd (Files): Likewise.
34100 2020-08-23  Bruno Haible  <bruno@clisp.org>
34102         inttypes: Fix {PRI,SCN}*PTR on 32-bit native Windows (regr. 2020-07-21).
34103         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): Fix syntax error in test
34104         program.
34106 2020-08-23  Paul Eggert  <eggert@cs.ucla.edu>
34108         intprops: be consistent about +X vs X+0
34109         * lib/intprops.h (_GL_SIGNED_INT_MAXIMUM): Simplify.
34111         intprops: fix INT_MULTIPLY_WRAPV bit-field bug
34112         The bug occurs when using INT_MULTIPLY_WRAPV (a, b, c) where B
34113         is a bit-field, on older GCC or non-GCC compilers where we do
34114         things ourselves instead of using __builtin_mul_overflow.
34115         Without this fix, INT_MULTIPLY_WRAPV would not compile, due
34116         to applying sizeof to a bit-field.
34117         * lib/intprops.h (_GL_INT_MULTIPLY_RANGE_OVERFLOW):
34118         Promote B before giving it to TYPE_WIDTH, in case B is a bit-field.
34120 2020-08-23  Bruno Haible  <bruno@clisp.org>
34122         supersede: Avoid a failure when writing to /dev/null in Solaris zones.
34123         Reported by Jörg Sonnenberger <joerg@netbsd.org>
34124         via Thomas Klausner <tk@giga.or.at> in
34125         <https://pkgsrc.se/files.php?messageId=20200812233110.30230FB28@cvs.NetBSD.org>.
34126         * lib/supersede.c (open_supersede): When opening an existing non-regular
34127         file on Solaris, use O_CREAT although it should not be necessary.
34129 2020-08-23  Bruno Haible  <bruno@clisp.org>
34131         verify: Make assume work on bit field expressions (regr. 2020-08-22).
34132         Reported by Benno Schulenberg <bensberg@telfort.nl> in
34133         <https://lists.gnu.org/archive/html/bug-gnulib/2020-08/msg00202.html>.
34134         * lib/verify.h (assume): Use '_Bool' or 'bool' as type of the temporary
34135         variable.
34137 2020-08-23  Bruno Haible  <bruno@clisp.org>
34139         libc-config: Improve comments.
34140         * lib/cdefs.h (__warndecl, __warnattr, __errordecl): Explain why we
34141         cannot use clang's __diagnose_if__ here.
34143 2020-08-22  Bruno Haible  <bruno@clisp.org>
34145         verify: Do use __builtin_assume on clang.
34146         * lib/verify.h (assume): Use clang’s __builtin_assume, with a temporary
34147         variable in a statement expression.
34149 2020-08-22  Bruno Haible  <bruno@clisp.org>
34151         sig2str: Add more signals.
34152         * lib/sig2str.c (numname_table): Add SIGCPUFAIL, SIGTHR, SIGBREAK.
34154 2020-08-22  Bruno Haible  <bruno@clisp.org>
34156         doc: Update for OpenBSD 6.0, 6.7.
34157         * doc/*/*.texi: Update.
34158         * m4/printf.m4: Update comments and cross-compilation guesses.
34159         * m4/ceill.m4: Update comments.
34160         * m4/getcwd-abort-bug.m4: Likewise.
34161         * m4/ilogb.m4: Likewise.
34162         * m4/ilogbf.m4: Likewise.
34163         * m4/langinfo_h.m4: Likewise.
34164         * m4/modf.m4: Likewise.
34165         * m4/modff.m4: Likewise.
34167 2020-08-22  Bruno Haible  <bruno@clisp.org>
34169         doc: Mention sig2str module.
34170         * doc/glibc-functions/sigabbrev_np.texi: Mention the sig2str module.
34172 2020-08-21  Bruno Haible  <bruno@clisp.org>
34174         sigdescr_np: Add tests.
34175         * tests/test-sigdescr_np.c: New file.
34176         * modules/sigdescr_np-tests: New file.
34178         sigdescr_np: New module.
34179         * lib/string.in.h (sigdescr_np): New declaration.
34180         * lib/sigdescr_np.c: New file.
34181         * m4/sigdescr_np.m4: New file.
34182         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Test whether sigdescr_np is
34183         declared.
34184         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_SIGDESCR_NP,
34185         HAVE_SIGDESCR_NP.
34186         * modules/string (Makefile.am): Substitute GNULIB_SIGDESCR_NP,
34187         HAVE_SIGDESCR_NP.
34188         * modules/sigdescr_np: New file.
34189         * tests/test-string-c++.cc: Verify the signature of sigdescr_np.
34190         * doc/glibc-functions/sigdescr_np.texi: Mention the new module.
34192 2020-08-20  Bruno Haible  <bruno@clisp.org>
34194         sigabbrev_np: Add tests.
34195         * tests/test-sigabbrev_np.c: New file.
34196         * modules/sigabbrev_np-tests: New file.
34198         sigabbrev_np: New module.
34199         * lib/string.in.h (sigabbrev_np): New declaration.
34200         * lib/sigabbrev_np.c: New file.
34201         * m4/sigabbrev_np.m4: New file.
34202         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Test whether sigabbrev_np is
34203         declared.
34204         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_SIGABBREV_NP,
34205         HAVE_SIGABBREV_NP.
34206         * modules/string (Makefile.am): Substitute GNULIB_SIGABBREV_NP,
34207         HAVE_SIGABBREV_NP.
34208         * modules/sigabbrev_np: New file.
34209         * tests/test-string-c++.cc: Verify the signature of sigabbrev_np.
34210         * doc/glibc-functions/sigabbrev_np.texi: Mention the new module.
34212 2020-08-20  Bruno Haible  <bruno@clisp.org>
34214         stdalign tests: Skip test with AIX xlclang.
34215         * tests/test-stdalign.c (main): Skip alignas tests with AIX xlclang.
34217 2020-08-20  Bruno Haible  <bruno@clisp.org>
34219         stdalign: Fix test failures on 32-bit platforms with clang versions < 8.
34220         * lib/stdalign.in.h (_Alignof): For clang versions < 8, use the same
34221         workaround as for GCC versions < 4.9.
34223 2020-08-20  Siddhesh Poyarekar  <siddhesh@gotplt.org>
34225         Sync up ProjectQuirks comments and documentation
34226         Transform the ProjectQuirks comments into a docstring so that it can
34227         be accessed from python as ProjectQuirks.__doc__ and harmonize
34228         descriptions with the documentation.
34229         * build-aux/vcstocl/projectquirks.py (ProjectQuirks):
34230         Transform comments into a docstring.
34231         * doc/vcs-to-changelog.texi: Sync up description with comments.
34233         Split ProjectQuirks out into its own file
34234         ProjectQuirks is used by external quirks files and importing it from
34235         vcs-to-changelog.py is broken since it was renamed to use hyphens.  It
34236         is cleaner to put it in its own file anyway.
34237         * build-aux/vcstocl/projectquirks.py: A new file...
34238         * build-aux/vcs-to-changelog.py (ProjectQuirks): ...to which
34239         we move ProjectQuirks and import the file.
34241 2020-08-19  Bruno Haible  <bruno@clisp.org>
34243         uchar: Fix compilation errors in C++ mode on macOS.
34244         * m4/uchar.m4 (gl_UCHAR_H): Require gl_ANSI_CXX if present. Include some
34245         system header file before attempting to use 'char16_t' and 'char32_t'.
34247 2020-08-19  Bruno Haible  <bruno@clisp.org>
34249         ansi-c++-opt: Work around an autoconf macro reordering problem.
34250         * modules/ansi-c++-opt: Require gl_ANSI_CXX already in the early
34251         section.
34253 2020-08-19  Bruno Haible  <bruno@clisp.org>
34255         math C++ tests: Fix compilation error in with GCC 10.
34256         * lib/math.in.h (cbrt, ceil, copysign, exp2, expm1, floor, fma, fmod,
34257         hypot, ilogb, log, log10, log1p, log2, logb, modf, remainder, rint,
34258         round, trunc): Use _GL_CXXALIASWARN1 instead of _GL_CXXALIASWARN.
34260 2020-08-19  Bruno Haible  <bruno@clisp.org>
34262         uchar: Fix compilation errors in C++ mode on OpenBSD.
34263         * lib/uchar.in.h (char16_t, char32_t): Don't define in C++ mode if
34264         CXX_HAS_UCHAR_TYPES is 1.
34265         * m4/uchar.m4 (gl_UCHAR_H): Determine whether the C++ compiler
34266         predefines char16_t and char32_t. Substitute CXX_HAS_UCHAR_TYPES.
34267         * modules/uchar (Makefile.am): Substitute CXX_HAS_UCHAR_TYPES.
34269 2020-08-19  Bruno Haible  <bruno@clisp.org>
34271         Fix compilation errors in C++ mode on OpenBSD.
34272         * lib/math.in.h (isfinite, isinf, isnan, signbit): In C++ mode on
34273         OpenBSD with clang, use the approach without C preprocessor macro.
34275 2020-08-18  Bruno Haible  <bruno@clisp.org>
34277         uchar C++ tests: Fix side effect on math modules (regr. 2020-08-17).
34278         * modules/uchar-c++-tests (configure.ac): Don't use AC_LANG_PUSH and
34279         AC_LANG_POP.
34281 2020-08-17  Paul Eggert  <eggert@cs.ucla.edu>
34283         verify: avoid __built_assume on Clang
34284         * lib/verify.h (assume): Do not use Clang’s __builtin_assume, as
34285         Clang 9 incorrectly diagnoses arguments as having side effects
34286         even when they do not.  I guess Clang 9 considers any function
34287         call as if it had a side effect here.
34289         libc-config: avoid Clang’s __diagnose_if__
34290         * lib/cdefs.h (__warndecl, __warnattr, __errordecl):
34291         For now, do not use __diagnose_if__ here, as this fails
34292         on Fedora 31 with Clang 9.0.1, with diagnostic
34293         "/usr/include/bits/stdio2.h:263:9: error: fgets called with bigger
34294         size than length of destination buffer
34295         [-Werror,-Wuser-defined-warnings]".  I guess Clang 9 warns even
34296         for functions that are not called?
34298         careadlinkat: speedup for GCC 10 with GCC_LINT
34299         Inspired by a suggestion by Bruno Haible in:
34300         https://lists.gnu.org/r/bug-gnulib/2020-08/msg00155.html
34301         * lib/careadlinkat.c (STACK_BUF_SIZE): New constant.
34302         (readlink_stk): New function, with most of the old careadlinkat
34303         contents and with a new STACK_BUF arg.  Inline it in GCC 10
34304         if GCC_LINT.
34305         (careadlinkat): Use the new function for everything but the
34306         stack buffer.
34308         * build-aux/gcc-warning.spec: Update comments.
34310 2020-08-17  Bruno Haible  <bruno@clisp.org>
34312         Assume autoconf >= 2.64.
34313         * m4/std-gnu11.m4 (AC_PROG_CC, AC_PROG_CXX): Use _AC_DO_LIMIT always.
34315 2020-08-17  Bruno Haible  <bruno@clisp.org>
34317         Revert autoupdate's revert.
34318         * config/srclist.txt: Mark regcomp.c as needing sync with glibc.
34320 2020-08-17  Bruno Haible  <bruno@clisp.org>
34322         uchar C++ tests: Fix build error on FreeBSD 12.
34323         * modules/uchar-c++-tests (configure.ac): Test whether <cuchar> exists.
34324         (Makefile.am): Don't include test-uchar-c++2.cc in the compilation if
34325         <cuchar> does not exist.
34327 2020-08-16  Paul Eggert  <eggert@cs.ucla.edu>
34329         time_rz: remove unused functions
34330         * lib/time_rz.c (isdst_differ, equal_tm): Remove; no longer used.
34332         time_rz: fix issues with mktime_z failures
34333         * lib/time_rz.c (mktime_z): Do not update *TM if revert_tz fails.
34334         Use a cheaper tm_yday test for failed mktime.
34336 2020-08-16  Bruno Haible  <bruno@clisp.org>
34338         intprops test: Strengthen on clang.
34339         * tests/test-intprops.c (VERIFY): Use verify_stmt.
34341 2020-08-16  Bruno Haible  <bruno@clisp.org>
34343         nstrftime: Guide inlining also on clang.
34344         * lib/nstrftime.c (iso_week_days): Inline also on clang.
34346 2020-08-16  Bruno Haible  <bruno@clisp.org>
34348         intprops: Avoid bogus "warning: division by zero is undefined" on clang.
34349         * lib/intprops.h (_GL__GENERIC_BOGUS): Define to 1 on clang.
34351 2020-08-16  Bruno Haible  <bruno@clisp.org>
34353         log2l: Disable MSVC workaround on clang.
34354         * lib/log2l.c (log2l): On clang, use the expression 0.0L/0.0L.
34356 2020-08-16  Bruno Haible  <bruno@clisp.org>
34358         argp: Emit a warning also with clang.
34359         * lib/argp-help.c (__argp_short_program_name): Use #warning also on
34360         clang.
34362 2020-08-16  Bruno Haible  <bruno@clisp.org>
34364         libc-config: Enable __REDIRECT macro also on clang.
34365         * lib/cdefs.h (__REDIRECT, __REDIRECT_NTH, __REDIRECT_NTHNL, __ASMNAME,
34366         __ASMNAME2): Define on clang like on GCC.
34368 2020-08-16  Bruno Haible  <bruno@clisp.org>
34370         regex: Use initializer shorthand syntax also with clang.
34371         * lib/regcomp.c (utf8_sb_map): Use the initializer shorthand syntax also
34372         with clang.
34374 2020-08-16  Bruno Haible  <bruno@clisp.org>
34376         regex: Use space optimization also with clang.
34377         * lib/regex_internal.h (re_token_t): Use a single byte for the type also
34378         with clang.
34380 2020-08-16  Bruno Haible  <bruno@clisp.org>
34382         Use _Static_assert and static_assert primitives when present on clang.
34383         * lib/cdefs.h (_Static_assert): Don't define as a macro on clang.
34384         * lib/verify.h (_GL_HAVE__STATIC_ASSERT, _GL_HAVE__STATIC_ASSERT1,
34385         _GL_HAVE_STATIC_ASSERT1): Define as appropriate on clang.
34387 2020-08-16  Bruno Haible  <bruno@clisp.org>
34389         Use 'throw ()' for optimization in C++ mode also on clang.
34390         * lib/cdefs.h (__THROW): Define to 'throw ()' also on clang.
34391         * lib/getopt-cdefs.in.h (__THROW): Likewise.
34392         * lib/md5.h (__THROW): Likewise.
34394 2020-08-16  Bruno Haible  <bruno@clisp.org>
34396         absolute-header: Add support for clang.
34397         * modules/absolute-header (Makefile.am): Include '__clang__' in the
34398         HAVE_INCLUDE_NEXT expression.
34400 2020-08-16  Bruno Haible  <bruno@clisp.org>
34402         Fix "warning: implicitly declaring library function 'strcasecmp'".
34403         * lib/argp-help.c: Include <strings.h>.
34405 2020-08-16  Bruno Haible  <bruno@clisp.org>
34407         stdio: Don't break attribute 'scanf' on clang.
34408         * lib/stdio.in.h (scanf): Treat clang like GCC.
34410 2020-08-16  Bruno Haible  <bruno@clisp.org>
34412         Use __restrict also on clang.
34413         * lib/argp.h (__restrict): Don't define as a macro on clang >= 3.
34414         * lib/glob.in.h (_Restrict_): Use __restrict on clang >= 3.
34415         * lib/unitypes.in.h (_UC_RESTRICT): Likewise.
34417 2020-08-16  Bruno Haible  <bruno@clisp.org>
34419         pthread-spin: Use GCC built-ins also on clang.
34420         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
34421         pthread_spin_trylock, pthread_spin_unlock): Use the newer GCC built-ins
34422         also on clang.
34424 2020-08-16  Bruno Haible  <bruno@clisp.org>
34426         asyncsafe-spin tests: Update.
34427         * tests/test-asyncsafe-spin2.c: Update to match the change in
34428         lib/asyncsafe-spin.c from 2020-08-11.
34430 2020-08-16  Bruno Haible  <bruno@clisp.org>
34432         setenv: Use tree code also with clang.
34433         * lib/setenv.c (USE_TSEARCH): Treat clang like GCC.
34435 2020-08-16  Bruno Haible  <bruno@clisp.org>
34437         math: Optimize signbit also on clang.
34438         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Optimize also
34439         on clang.
34441 2020-08-16  Bruno Haible  <bruno@clisp.org>
34443         avltreehash-list, rbtreehash-list: Optimize also on clang.
34444         * lib/gl_anytreehash_list1.h (add_nodes_to_buckets): Use
34445         __builtin_expect also on clang.
34447 2020-08-16  Bruno Haible  <bruno@clisp.org>
34449         Fix "warning: 'WSASocketA' is deprecated: Use WSASocketW() instead".
34450         * lib/socket.c: Use WSASocketW, not WSASocketA.
34452         Fix "warning: format specifies type 'unsigned long'".
34453         * tests/test-nonblocking-writer.h (main_writer_loop): Cast dbgfprintf
34454         argument to match the format directive.
34456         Fix "warning: no case matching constant switch condition '0'".
34457         * tests/test-fcntl.c (check_flags): Add a 'default' case.
34459         Fix "warning: integer overflow in expression".
34460         * tests/test-strtol.c (main): Use an 'unsigned long' expression to
34461         remove a 'long' overflow.
34463         Fix "warning: "getpagesize" redefined".
34464         * tests/test-getcwd.c (getpagesize): Don't redefine if defined as a
34465         macro.
34467         Fix "warning: implicitly declaring library function 'strncasecmp'".
34468         * lib/strptime.c: Include <strings.h>.
34470         Fix "warning: 'snprintf' macro redefined".
34471         * lib/strerror_r.c (snprintf): Undefine before redefining.
34473         Fix "warning: address of array 'locale' will always evaluate to 'true'".
34474         * lib/nl_langinfo.c (ctype_codeset): Remove redundant NULL test.
34476         Fix "warning: '__stat64' macro redefined".
34477         * lib/glob.c (__stat64): Undefine also on MSVC/clang.
34479         Fix "warning: 'format' attribute argument not supported: rpl_printf".
34480         * lib/stdio.in.h (printf): Treat clang like GCC.
34482         Fix "warning: attribute declaration must precede definition" with clang.
34483         * lib/math.in.h (acosl, asinl, atanl, ceill, cosl, expl, fabsf, fabsl,
34484         floorl, fmodl, frexpf, frexpl, hypotf, hypotl, ldexpf, ldexpl, logl,
34485         log10l, modfl, sinl, sqrtl, tanl): Disable _GL_CXXALIASWARN invocation
34486         on non-glibc systems.
34487         * lib/netdb.in.h (gai_strerror): Likewise.
34488         * lib/stdio.in.h (snprintf, vfscanf, vscanf, vsnprintf): Likewise.
34489         * lib/sys_stat.in.h (fstat): Likewise.
34490         * lib/utime.in.h (utime): Likewise.
34492         Fix undesired warnings.
34493         * lib/sys_select.in.h: Disable all _GL_WARN_ON_USE invocations with
34494         clang.
34496 2020-08-16  Bruno Haible  <bruno@clisp.org>
34498         C++ tests: Fix link errors on MSVC (regression from 2020-05-31).
34499         * modules/stdio-c++-tests (Makefile.am): Link test-stdio-c++ with
34500         $(LIB_GETRANDOM), needed for the rpl_tmpfile symbol.
34501         * modules/stdlib-c++-tests (Makefile.am): Link test-stdlib-c++ with
34502         $(LIB_GETRANDOM), needed for the mkdtemp and mkstemp symbols.
34504 2020-08-16  Bruno Haible  <bruno@clisp.org>
34506         Don't use Autoconf quadrigraphs.
34507         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA): Use '#' instead of the corresponding
34508         Autoconf quadrigraph.
34509         * m4/free.m4 (gl_FUNC_FREE): Likewise.
34510         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Likewise.
34511         * m4/largefile.m4 (_AC_SYS_LARGEFILE_TEST_INCLUDES,
34512         _AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
34513         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
34514         * m4/math_h.m4 (gl_MATH_H): Likewise.
34515         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Likewise.
34517 2020-08-16  Bruno Haible  <bruno@clisp.org>
34519         Fix quoting of AC_LANG_PROGRAM arguments.
34520         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Quote the AC_LANG_PROGRAM
34521         arguments through [[...]].
34522         * m4/fpending.m4 (gl_FUNC_FPENDING): Likewise.
34523         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
34524         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Likewise.
34525         * m4/ld-output-def.m4 (gl_LD_OUTPUT_DEF): Likewise.
34526         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT): Likewise.
34527         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
34528         * m4/mountlist.m4 (gl_MOUNTLIST): Likewise.
34529         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
34530         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
34531         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Likewise.
34532         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Likewise.
34533         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Likewise.
34534         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
34536 2020-08-16  Bruno Haible  <bruno@clisp.org>
34538         Assume autoconf >= 2.64.
34539         * gnulib-tool (DEFAULT_AUTOCONF_MINVERSION): Set to 2.64.
34540         * DEPENDENCIES: Require Autoconf 2.64 or newer.
34541         * NEWS: Mention the changed requirement.
34542         * m4/00gnulib.m4 (_m4_divert_diversion, AC_DEFUN_ONCE): Remove macros.
34543         * m4/gnulib-common.m4 (AS_VAR_IF, AS_VAR_COPY): Remove macros.
34544         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Quote pushdef'ed
34545         variables.
34546         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Likewise.
34547         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Likewise.
34548         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Likewise.
34549         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C), gl_UNKNOWN_WARNINGS_ARE_ERRORS(C++),
34550         gl_UNKNOWN_WARNINGS_ARE_ERRORS(Objective C)): Define through AC_DEFUN.
34551         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C), gl_MANYWARN_ALL_GCC(C++)):
34552         Likewise.
34553         * m4/iconv.m4 (AM_ICONV): Define through AC_DEFUN_ONCE directly.
34554         * m4/libunistring.m4 (gl_LIBUNISTRING): Likewise.
34555         * m4/configmake.m4: Update comment.
34557 2020-08-16  Bruno Haible  <bruno@clisp.org>
34559         sys_ioctl: Simplify.
34560         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Remove confusing use of
34561         AC_INCLUDES_DEFAULT.
34563 2020-08-16  Bruno Haible  <bruno@clisp.org>
34565         Fix quoting of AC_LANG_SOURCE arguments.
34566         * m4/printf.m4 (gl_PRINTF_ENOMEM): Fix an m4 quoting bug in the
34567         GL_NOCRASH expansion.
34568         * m4/locale-ar.m4 (gt_LOCALE_AR): Simplify m4 quoting.
34569         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
34570         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
34571         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
34572         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
34574 2020-08-15  Paul Eggert  <eggert@cs.ucla.edu>
34576         nstrftime: be more predictable about errno
34577         This aligns nstrftime better with draft POSIX 202x strftime.
34578         * lib/nstrftime.c: Include errno.h.
34579         (width_add, __strftime_internal): Set errno on failure,
34580         and preserve it on success.  Check for mktime_z failure.
34581         * modules/nstrftime (Depends-on): Add errno.
34582         * modules/nstrftime-tests (Depends-on): Add atoll, intprops.
34583         * tests/test-nstrftime.c: Include intprops.h, limits.h.
34584         (errno_test): New test function.
34585         (main): Call it.
34587 2020-08-15  Bruno Haible  <bruno@clisp.org>
34589         canonicalize: Fix a problem of the autoconf test on MSVC/clang.
34590         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Remove undesired file
34591         from dependency analysis first.
34593 2020-08-15  Bruno Haible  <bruno@clisp.org>
34595         Determine asm output option and filename suffix for MSVC/clang.
34596         * m4/asm-underscore.m4 (gl_C_ASM): Distinguish clang from cl and
34597         clang-cl.
34599 2020-08-15  Bruno Haible  <bruno@clisp.org>
34601         doc: Update for MSVC/clang.
34602         * doc/*-functions/*printf.texi: Mention that MSVC/clang has two bugs
34603         that MSVC 14 does not have.
34605 2020-08-15  Bruno Haible  <bruno@clisp.org>
34607         Revert autoupdate's revert.
34608         * config/srclist.txt: Mark mktime.c as needing sync with glibc.
34610 2020-08-15  Bruno Haible  <bruno@clisp.org>
34612         frexpl: Fix configuration test result on MSVC.
34613         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Avoid a division by a constant
34614         zero.
34616 2020-08-15  Bruno Haible  <bruno@clisp.org>
34618         Support compiling without -loldnames on native Windows.
34619         * m4/gnulib-common.m4 (GL_MDA_DEFINES, _GL_MDA_DEFINES): New macros.
34620         * m4/chown.m4 (AC_FUNC_CHOWN): In the test programs, use GL_MDA_DEFINES.
34621         (gl_FUNC_CHOWN, gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Likewise.
34622         * m4/dup.m4 (gl_FUNC_DUP): Likewise.
34623         * m4/dup2.m4 (gl_FUNC_DUP2): Likewise.
34624         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
34625         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): Likewise.
34626         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Likewise.
34627         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Likewise.
34628         * m4/fcntl.m4 (gl_FUNC_FCNTL): Likewise.
34629         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Likewise.
34630         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Likewise.
34631         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Likewise.
34632         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): Likewise.
34633         * m4/freopen.m4 (gl_FUNC_FREOPEN): Likewise.
34634         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Likewise.
34635         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
34636         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
34637         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL, gl_FUNC_GETCWD_SIGNATURE):
34638         Likewise.
34639         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Likewise.
34640         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
34641         * m4/lseek.m4 (gl_FUNC_LSEEK): Likewise.
34642         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
34643         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
34644         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Likewise.
34645         * m4/open-slash.m4 (gl_OPEN_TRAILING_SLASH_BUG): Likewise.
34646         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
34647         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Likewise.
34648         * m4/pread.m4 (gl_FUNC_PREAD): Likewise.
34649         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
34650         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Likewise.
34651         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Likewise.
34652         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
34653         * m4/pwrite.m4 (gl_FUNC_PWRITE): Likewise.
34654         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
34655         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
34656         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
34657         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
34658         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
34659         * m4/strncat.m4 (gl_FUNC_STRNCAT): Likewise.
34660         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Likewise.
34661         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
34662         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
34663         * m4/utimens.m4 (gl_UTIMENS): Likewise.
34664         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
34665         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
34666         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL): On native Windows, don't
34667         test for getcwd.
34668         * m4/utime.m4 (gl_FUNC_UTIME): On native Windows, don't test for utime.
34669         * m4/wcsdup.m4 (gl_FUNC_WCSDUP): To test for wcsdup, use a test program
34670         with GL_MDA_DEFINES.
34671         * lib/c++defs.h (_GL_CXXALIAS_MDA): New macro.
34672         * lib/fcntl.in.h (creat, open):  On native Windows, use the underscore-
34673         prefixed symbol.
34674         * lib/search.in.h (lfind, lsearch): Likewise.
34675         * lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
34676         Likewise.
34677         * lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
34678         * lib/string.in.h (memccpy, strdup): Likewise.
34679         * lib/sys_stat.in.h (chmod, umask): Likewise.
34680         * lib/time.in.h (tzset): Likewise.
34681         * lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
34682         execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
34683         read, rmdir, swab, unlink, write): Likewise.
34684         * lib/utime.in.h (utime): Likewise.
34685         * lib/wchar.in.h (wcsdup): Likewise.
34686         * lib/math.in.h (j0, j1, jn, y0, y1, yn):  Likewise.
34687         (isfinite, isinf, isnan, signbit): On native Windows, don't define as an
34688         rpl_-prefixed macro.
34689         * lib/canonicalize-lgpl.c (__getcwd): On native Windows, use _getcwd.
34690         * lib/close.c (close_nothrow): On native Windows, use _close.
34691         * lib/creat.c (orig_creat): On native Windows, use _creat.
34692         * lib/dup.c (dup_nothrow): On native Windows, use _dup.
34693         * lib/dup2.c (dup2_nothrow): Use _dup2.
34694         * lib/fdopen.c (fdopen_nothrow): On native Windows, use _fdopen.
34695         * lib/getcwd-lgpl.c: On native Windows, use _getcwd.
34696         * lib/getcwd.c (getcwd_nothrow): Use _getcwd also on mingw.
34697         * lib/open.c (orig_open): On native Windows, use _open.
34698         * lib/read.c (read_nothrow): Use _read.
34699         * lib/rmdir.c: On native Windows, use _rmdir.
34700         * lib/unlink.c: On native Windows, use _unlink.
34701         * lib/write.c (write_nothrow): Use _write.
34702         * lib/sys_select.in.h (close): With clang, don't attach a warning on an
34703         undefined symbol.
34704         * lib/sys_socket.in.h (close): Likewise.
34705         * lib/sys_time.in.h (close): Likewise.
34706         * tests/test-spawn-pipe-child.c: On native Windows, use _fdopen.
34708 2020-08-15  Bruno Haible  <bruno@clisp.org>
34710         Fix "unknown pragma ignored" warnings with clang on native Windows.
34711         * lib/cbrt.c: Don't use '#pragma fenv_access (off)' with clang.
34712         * lib/cbrtf.c: Likewise.
34713         * lib/ceil.c: Likewise.
34714         * lib/floor.c: Likewise.
34715         * lib/fma.c: Likewise.
34716         * lib/fmod.c: Likewise.
34717         * lib/rint.c: Likewise.
34718         * lib/round.c: Likewise.
34719         * lib/trunc.c: Likewise.
34720         * tests/test-ceil2.c: Likewise.
34721         * tests/test-ceilf2.c: Likewise.
34722         * tests/test-floor2.c: Likewise.
34723         * tests/test-floorf2.c: Likewise.
34724         * tests/test-trunc2.c: Likewise.
34725         * tests/test-truncf2.c: Likewise.
34726         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
34727         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
34729 2020-08-15  Bruno Haible  <bruno@clisp.org>
34731         Fix compilation errors in C++ mode with clang on native Windows.
34732         * lib/pthread.in.h (pthread_*): Disable _GL_CXXALIASWARN invocation on
34733         non-glibc systems.
34734         * lib/sched.in.h (sched_yield): Likewise.
34736 2020-08-14  Bruno Haible  <bruno@clisp.org>
34738         stdnoreturn: Work around problem with MSVC/clang.
34739         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): On native Windows, include some
34740         system header after <stdnoreturn.h>.
34741         * doc/posix-headers/stdnoreturn.texi: Mention the issue.
34743 2020-08-14  Bruno Haible  <bruno@clisp.org>
34745         utime-h: Generate an utime.h file always.
34746         * modules/utime-h (Makefile.am): Generate utime.h always.
34747         * m4/utime_h.m4 (gl_UTIME_H): Don't set UTIME_H. Don't define
34748         GL_GENERATE_UTIME_H.
34750 2020-08-14  Bruno Haible  <bruno@clisp.org>
34752         mktime, mktime-internal: Remove obsolete code.
34753         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Don't #undef putenv.
34755 2020-08-14  Bruno Haible  <bruno@clisp.org>
34757         getcwd: Remove obsolete code.
34758         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Don't #undef mkdir.
34759         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
34761 2020-08-14  Bruno Haible  <bruno@clisp.org>
34763         tzset: Assume the function exists.
34764         * lib/time.in.h (tzset): Assume HAVE_TZSET is 1.
34765         * lib/tzset.c: Define rpl_tzset, not tzset. Assume HAVE_TZSET is 1.
34766         * modules/tzset (configure.ac): Don't test HAVE_TZSET.
34767         * m4/tzset.m4 (gl_FUNC_TZSET): Don't test for tzset. Don't set
34768         HAVE_TZSET.
34769         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Don't initialize HAVE_TZSET.
34770         * modules/time (Makefile.am): Don't substitute HAVE_TZSET.
34772         nstrftime: Assume tzset exists.
34773         * lib/nstrftime.c (HAVE_TZSET): Remove macro.
34774         (__strftime_internal): Test my_strftime, not HAVE_TZSET.
34775         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Don't test for tzset.
34777         mktime, mktime-internal: Assume tzset exists.
34778         * lib/mktime.c (my_tzset): Assume HAVE_TZSET is 1.
34779         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Don't test for tzset.
34781 2020-08-14  Bruno Haible  <bruno@clisp.org>
34783         strdup: Assume the function exists.
34784         * m4/strdup.m4 (gl_FUNC_STRDUP, gl_FUNC_STRDUP_POSIX): Don't test
34785         whether strdup exists.
34786         * modules/strdup (Files): Remove lib/strdup.c.
34787         (configure.ac): Don't compile strdup.c.
34788         * modules/strdup-posix (Depends-on, configure.ac): Don't test
34789         ac_cv_func_strdup.
34790         * doc/posix-functions/strdup.texi: Update.
34791         * lib/unistr/u8-strdup.c: Assume HAVE_STRDUP is 1.
34792         * modules/unistr/u8-strdup (Files): Remove lib/unistr/u-strdup.h.
34793         (Depends-on): Remove unistr/u8-strlen.
34795 2020-08-13  Bruno Haible  <bruno@clisp.org>
34797         sys_random: Work around an uClibc bug.
34798         Reported by akater <nuclearspace@gmail.com>
34799         via Stefan Kangas <stefan@marxist.se>
34800         in <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=42236>.
34801         * lib/sys_random.in.h: On uClibc, include <stddef.h> first.
34802         * m4/sys_random_h.m4 (gl_HEADER_SYS_RANDOM): Update comment.
34803         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
34804         * doc/glibc-headers/sys_random.texi: Mention the uClibc bug.
34806 2020-08-12  Bruno Haible  <bruno@clisp.org>
34808         Avoid implicit conversion from 'unsigned int' to 'int' in initializers.
34809         Reported by Florian Weimer in
34810         <https://lists.gnu.org/archive/html/bug-gnulib/2020-08/msg00086.html>.
34811         * lib/gen-uni-tables.c (output_predicate): Change the element type of
34812         the level3 array to 'unsigned int'.
34813         * lib/unictype/bitmap.h (bitmap_lookup): Access an 'unsigned int'.
34814         * lib/unictype/categ_*.h: Regenerated.
34815         * lib/unictype/ctype_*.h: Regenerated.
34816         * lib/unictype/pr_*.h: Regenerated.
34817         * lib/unictype/sy_*.h: Regenerated.
34818         * lib/unicase/cased.h: Regenerated.
34819         * lib/unicase/ignorable.h: Regenerated.
34821 2020-08-12  Paul Eggert  <eggert@cs.ucla.edu>
34823         stdint: port intptr_t to more-recent MinGW
34824         Problem reported by Eli Zaretskii in <https://bugs.gnu.org/36597#106>.
34825         * lib/stdint.in.h (intptr_t, uintptr_t): Do not define on MinGW,
34826         even if _INTPTR_T_DEFINED and _UINTPTR_T_DEFINED are not defined.
34827         Apparently those two macros were removed in mingwrt-3.22
34828         dated 2016-07-14.
34830 2020-08-12  Bruno Haible  <bruno@clisp.org>
34832         thread-optim: Export function-like macros only.
34833         Suggested by Paul Eggert.
34834         * lib/thread-optim.h (gl_multithreaded): New macro.
34835         (IF_MT_DECL, IF_MT): Remove macros.
34836         * doc/multithread.texi (Multithreading Optimizations): Add a small
34837         example.
34838         * lib/fatal-signal.c: Update all uses.
34839         * lib/clean-temp.c: Likewise.
34840         * lib/localename.c: Likewise.
34841         * modules/localename (Depends-on): Add stdbool.
34843 2020-08-12  Bruno Haible  <bruno@clisp.org>
34845         Revert autoupdate's revert.
34846         * config/srclist.txt: Mark regex.h as needing sync with glibc.
34848 2020-08-11  Bruno Haible  <bruno@clisp.org>
34850         thread-optim: Fix a compiler warning.
34851         * lib/thread-optim.h (IF_MT_DECL): Define differently.
34853 2020-08-11  Bruno Haible  <bruno@clisp.org>
34855         Use __restrict also on clang.
34856         * lib/cdefs.h (__restrict): Don't define as a macro on clang.
34857         (__restrict_arr): On clang, define like on GCC.
34858         * lib/regex.h (_Restrict_): Use '__restrict' also on clang.
34859         (_Restrict_arr_): Use _Restrict_ also on clang.
34860         * lib/spawn.in.h (_Restrict_): Use '__restrict' also on clang.
34861         (_Restrict_arr_): Use _Restrict_ also on clang.
34863 2020-08-11  Bruno Haible  <bruno@clisp.org>
34865         Use flexible array syntax also on clang.
34866         * lib/cdefs.h (__flexarr, __glibc_c99_flexarr_available): For clang,
34867         define like for GCC 3.
34869 2020-08-11  Bruno Haible  <bruno@clisp.org>
34871         fcntl: On native Windows, use _setmode, not setmode.
34872         * lib/fcntl.c (dupfd): Use _setmode, not setmode.
34873         * lib/binary-io.h: Update comment.
34874         * tests/test-cloexec.c: Call set_binary_mode, not setmode.
34875         * tests/test-dup2.c: Likewise.
34876         * tests/test-dup-safer.c: Likewise.
34877         * tests/test-fcntl.c: Likewise.
34879 2020-08-11  Bruno Haible  <bruno@clisp.org>
34881         execute, spawn-pipe: Use _spawnvpe, not spawnvpe.
34882         * lib/execute.c (execute): Use _spawnvpe, not spawnvpe.
34883         * lib/spawn-pipe.c (create_pipe): Likewise.
34884         * tests/test-nonblocking-pipe-main.c (main): Likewise.
34885         * tests/test-nonblocking-socket-main.c (main): Likewise.
34886         * lib/wait-process.c: Update comment.
34887         * doc/posix-functions/fork.texi: Update.
34889 2020-08-11  Bruno Haible  <bruno@clisp.org>
34891         asyncsafe-spin: Use GCC built-ins also on clang.
34892         * lib/asyncsafe-spin.c (asyncsafe_spin_init, do_lock, do_unlock): Use
34893         the newer GCC built-ins also on clang.
34895 2020-08-11  Bruno Haible  <bruno@clisp.org>
34897         Use expression statements also on clang.
34898         * lib/cdefs.h (__extension__): Don't define to empty on clang.
34899         * lib/obstack.h (__extension__): Likewise.
34900         (obstack_object_size, obstack_room, obstack_make_room, obstack_empty_p,
34901         obstack_grow, obstack_grow0, obstack_1grow, obstack_ptr_grow,
34902         obstack_int_grow, obstack_ptr_grow_fast, obstack_int_grow_fast,
34903         obstack_blank, obstack_alloc, obstack_copy, obstack_copy0,
34904         obstack_finish, obstack_free): Enable as optimized macros also on clang.
34905         * lib/fpucw.h (fpucw_t etc.): Enable the definitions also on clang.
34907 2020-08-10  Bruno Haible  <bruno@clisp.org>
34909         Use many __attribute__s with clang.
34910         * m4/gnulib-common.m4 (_Noreturn): Use __attribute__ __noreturn__ also
34911         on clang.
34912         * lib/cdefs.h (__glibc_clang_has_attribute, __glibc_clang_has_builtin):
34913         New macros.
34914         (__THROW, __THROWNL, __NTH, __NTHNL): Use __attribute__ __nothrow__ also
34915         on clang.
34916         (__warndecl, __warnattr, __errordecl): Use __attribute__ __diagnose_if__
34917         also on older clang versions.
34918         (__attribute__): Don't define to empty on clang.
34919         (__attribute_malloc__): Use __attribute__ __malloc__ also on clang.
34920         (__attribute_pure__): Use __attribute__ __pure__ also on clang.
34921         (__attribute_const__): Use __attribute__ __const__ also on clang.
34922         (__attribute_used__): Use __attribute__ __used__ also on clang.
34923         (__attribute_noinline__): Use __attribute__ __noinline__ also on clang.
34924         (__attribute_deprecated__): Use __attribute__ __deprecated__ also on
34925         clang.
34926         (__attribute_format_arg__): Use __attribute__ __format_arg__ also on
34927         clang.
34928         (__attribute_format_strfmon__): Use __attribute__ __format__ __strfmon__
34929         also on clang.
34930         (__nonnull): Use __attribute__ __nonnull__ also on clang.
34931         (__attribute_warn_unused_result__): Use __attribute__
34932         __warn_unused_result__ also on clang.
34933         (__always_inline): Use __attribute__ __always_inline__ also on clang.
34934         (__attribute_artificial__): Use __attribute__ __artificial__ also on
34935         clang >= 7.
34936         (__glibc_unlikely, __glibc_likely): Use __builtin_expect also on older
34937         clang versions.
34938         (_Noreturn): Don't redefine on clang >= 3.5.
34939         * lib/arg-nonnull.h (_GL_ARG_NONNULL): Use __attribute__ __nonnull__
34940         also on clang.
34941         * lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Use __attribute__ __pure__ also
34942         on clang.
34943         * lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Likewise.
34944         * lib/string.in.h (_GL_ATTRIBUTE_PURE): Likewise.
34945         * lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
34946         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT): Use __attribute__ __format__
34947         also on clang.
34948         * lib/monetary.in.h (_GL_ATTRIBUTE_FORMAT): Likewise.
34949         * lib/textstyle.in.h (ostream_printf, ostream_vprintf): Likewise.
34950         * lib/unitypes.in.h (_UC_ATTRIBUTE_CONST): Use __attribute__ __const__
34951         also on clang.
34952         (_UC_ATTRIBUTE_PURE): Use __attribute__ __pure__ also on clang.
34953         * lib/noreturn.h (_GL_NORETURN_FUNC, _GL_NORETURN_FUNCPTR): Use
34954         __attribute__ __noreturn__ also on clang.
34955         * lib/obstack.h (__attribute_noreturn__): Likewise.
34956         * lib/file-set.h (record_file): Use __attribute__ __nonnull__ also on
34957         clang.
34958         * lib/argp-help.c (hol_entry_long_iterate): Use __attribute__
34959         always_inline also on clang.
34960         * tests/test-printf-posix.c (func1, func2, func3, func4): Test also on
34961         clang.
34963 2020-08-10  Bruno Haible  <bruno@clisp.org>
34965         c-ldtoastr tests: Fix test failure.
34966         * tests/test-c-ldtoastr.c (main): Support platforms where 'long double'
34967         is longer than 'double'.
34969 2020-08-10  Bruno Haible  <bruno@clisp.org>
34971         Revert autoupdate's revert.
34972         * config/srclist.txt: Mark intprops.h as needing sync with glibc.
34974 2020-08-09  Bruno Haible  <bruno@clisp.org>
34976         string: Fix build error in C++ mode with clang (regression from today).
34977         * lib/warn-on-use.h (_GL_WARN_ON_USE_CXX): Expect two rettype
34978         parameters, one for GCC, one for clang.
34979         * lib/c++defs.h (_GL_CXXALIASWARN1_2): Update.
34980         * lib/string.in.h (strchr, strpbrk, strrchr): For clang, pass 'char *'
34981         as return type.
34983 2020-08-09  Bruno Haible  <bruno@clisp.org>
34985         ftruncate: Use _chsize, not chsize.
34986         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): Test for _chsize, not chsize.
34987         * lib/ftruncate.c: Test HAVE__CHSIZE.
34988         (chsize_nothrow): Use _chsize, not chsize.
34990 2020-08-09  Bruno Haible  <bruno@clisp.org>
34992         Silence warnings from clang 10 with -Wimplicit-fallthrough.
34993         * lib/dfa.c (FALLTHROUGH): Use __attribute__ __fallthrough__ also on
34994         clang >= 10.
34995         * lib/fnmatch.c (FALLTHROUGH): Likewise.
34996         * lib/fts.c (FALLTHROUGH): Likewise.
34997         * tests/macros.h (FALLTHROUGH): Likewise.
34998         * lib/regex_internal.h (FALLTHROUGH): Likewise.
34999         * config/srclist.txt: Mark it as needing sync with glibc.
35001 2020-08-09  Bruno Haible  <bruno@clisp.org>
35003         stdbool tests: Enable the stricter tests also on clang.
35004         * tests/test-stdbool.c (ADDRESS_CHECK_OKAY): Define also on clang.
35005         (e): Enable the address-to-bool conversion test also on clang.
35007 2020-08-09  Bruno Haible  <bruno@clisp.org>
35009         count-one-bits: Use __builtin_popcount{,l,ll} on clang.
35010         * lib/count-one-bits.h (COUNT_ONE_BITS): Use the GCC built-in.
35012 2020-08-09  Bruno Haible  <bruno@clisp.org>
35014         Use attribute __aligned__ with clang.
35015         * lib/stdalign.in.h (_Alignas): Treat clang like GCC.
35016         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS): Likewise.
35018 2020-08-09  Bruno Haible  <bruno@clisp.org>
35020         Use __alignof__ with clang.
35021         * m4/stddef_h.m4 (gl_STDDEF_H): Test the alignment of max_align_t also
35022         on clang.
35023         * lib/alignof.h (alignof_type): Use __alignof__ also on clang.
35024         * lib/stdalign.in.h (_Alignof): Don't activate the GCC workaround on
35025         clang.
35026         * lib/malloca.h (sa_alignof): Use __alignof__ also on clang.
35027         * lib/bitset/list.c (lbitset_elt_alloc): Use __alignof__ also on clang.
35028         * lib/bitset/table.c (tbitset_elt_alloc): Likewise.
35029         * tests/test-stddef.c: Very the behaviour of __alignof__ also on clang.
35031 2020-08-09  Bruno Haible  <bruno@clisp.org>
35033         ignore-value: Simplify on clang.
35034         * lib/ignore-value.h (ignore_value): With clang, no need to use the GCC
35035         workaround.
35037 2020-08-09  Bruno Haible  <bruno@clisp.org>
35039         Use __typeof__ with clang.
35040         * m4/stdint.m4 (gl_STDINT_H): Check for SIZE_MAX also on
35041         "clang -std=gnu99".
35042         * lib/intprops.h (_GL_HAVE___TYPEOF__): Define to 1 also on clang.
35043         * tests/test-stdint.c (verify_same_types): Enable the check also on
35044         clang.
35046 2020-08-09  Bruno Haible  <bruno@clisp.org>
35048         Add ability to emit user-defined warnings and errors with clang.
35049         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _GL_ATTRIBUTE_ERROR,
35050         _GL_ATTRIBUTE_WARNING using an attribute for clang.
35051         * lib/warn-on-use.h (_GL_WARN_ON_USE, _GL_WARN_ON_USE_ATTRIBUTE,
35052         _GL_WARN_ON_USE_CXX): Define using an attribute for clang.
35053         * lib/cdefs.h (__warndecl, __warnattr, __errordecl): Define using an
35054         attribute for clang.
35056 2020-08-09  Bruno Haible  <bruno@clisp.org>
35058         intprops: Fix typo in comment.
35059         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P): Fix typo in comment.
35061 2020-08-09  Bruno Haible  <bruno@clisp.org>
35063         Use __builtin_signbit* with clang.
35064         * lib/math.in.h (signbit): Use __builtin_signbit{,f,l} also on clang.
35065         * m4/signbit.m4 (gl_SIGNBIT): Use __builtin_signbit{,f,l} also on clang.
35066         Set REPLACE_SIGNBIT_USING_BUILTINS, not REPLACE_SIGNBIT_USING_GCC.
35067         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize
35068         REPLACE_SIGNBIT_USING_BUILTINS, not REPLACE_SIGNBIT_USING_GCC.
35069         * modules/math (Makefile.am): Substitute REPLACE_SIGNBIT_USING_BUILTINS,
35070         not REPLACE_SIGNBIT_USING_GCC.
35072 2020-08-09  Bruno Haible  <bruno@clisp.org>
35074         Use __builtin_isnan with clang.
35075         * lib/isnanf-nolibm.h (isnanf): Use the GCC built-in __builtin_isnan,
35076         not __builtin_isnanf. Also on clang.
35077         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_ISNANF_WORKS): Use the GCC
35078         built-in __builtin_isnan, not __builtin_isnanf. Also on clang.
35079         * lib/isnand-nolibm.h (isnand): With clang, use the GCC built-in.
35080         * m4/isnand.m4 (gl_HAVE_ISNAND_IN_LIBM): With clang, use the GCC
35081         built-in.
35082         * lib/isnanl-nolibm.h (isnanf): Use the GCC built-in __builtin_isnan,
35083         not __builtin_isnanl. Also on clang.
35084         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_FUNC_ISNANL_WORKS): Use the
35085         GCC built-in __builtin_isnan, not __builtin_isnanl. Also on clang.
35086         * lib/math.in.h (__has_builtin): Remove macro.
35087         (isnanf, gl_isnan_f): Use the GCC built-in __builtin_isnan, not
35088         __builtin_isnanf. Also on clang.
35089         (isnand, gl_isnan_d): With clang, use the GCC built-in.
35090         (isnanl, gl_isnan_l): Use the GCC built-in __builtin_isnan, not
35091         __builtin_isnanl. Also on clang.
35092         (isnan): Use the GCC built-in __builtin_isnan in all three cases. Also
35093         on clang.
35095 2020-08-09  Bruno Haible  <bruno@clisp.org>
35097         thread-optim: Fix logic error.
35098         Reported by Paul Eggert.
35099         * lib/thread-optim.h (IF_MT): Fix logic error.
35101 2020-08-08  Bruno Haible  <bruno@clisp.org>
35103         localename: Use module 'thread-optim'.
35104         * lib/localename.c: Include thread-optim.h.
35105         (struniq): Use IF_MT macro.
35106         * modules/localename (Depends-on): Add thread-optim.
35108         clean-temp: Use module 'thread-optim'.
35109         * lib/clean-temp.c: Include thread-optim.h.
35110         (register_temporary_file, unregister_temporary_file, create_temp_dir,
35111         register_temp_file, unregister_temp_file, register_temp_subdir,
35112         unregister_temp_subdir, cleanup_temp_dir_contents, register_fd,
35113         close_temp, fclose_variant_temp): Use IF_MT macro.
35114         * modules/clean-temp (Depends-on): Add thread-optim.
35116         fatal-signal: Use module 'thread-optim'.
35117         * lib/fatal-signal.c: Include thread-optim.h.
35118         (at_fatal_signal, block_fatal_signals, unblock_fatal_signals): Use IF_MT
35119         macro.
35120         * modules/fatal-signal (Depends-on): Add thread-optim.
35122 2020-08-08  Bruno Haible  <bruno@clisp.org>
35124         New module 'thread-optim'.
35125         * lib/thread-optim.h: New file.
35126         * modules/thread-optim: New file.
35127         * doc/multithread.texi (Multithreading Optimizations): New section.
35129 2020-08-07  Paul Eggert  <eggert@cs.ucla.edu>
35131         doc: more updates for glibc 2.32
35132         * doc/glibc-functions/lchmod.texi, doc/posix-functions/faccessat.texi:
35133         * doc/posix-functions/fchmodat.texi: Update.
35135 2020-08-07  Bruno Haible  <bruno@clisp.org>
35137         doc: Update for glibc 2.32.
35138         * doc/glibc-functions/__libc_single_threaded.texi: New file.
35139         * doc/glibc-functions/pthread_attr_getsigmask_np.texi: New file.
35140         * doc/glibc-functions/pthread_attr_setsigmask_np.texi: New file.
35141         * doc/glibc-functions/sigabbrev_np.texi: New file.
35142         * doc/glibc-functions/sigdescr_np.texi: New file.
35143         * doc/glibc-functions/strerrordesc_np.texi: New file.
35144         * doc/glibc-functions/strerrorname_np.texi: New file.
35145         * doc/gnulib.texi: Include them.
35146         (Glibc sys/single_threaded.h): New section.
35147         * doc/pastposix-functions/h_errno.texi: Update.
35148         * doc/posix-functions/*.texi: Likewise.
35149         * doc/glibc-functions/*.texi: Likewise.
35151 2020-08-07  Bruno Haible  <bruno@clisp.org>
35153         alloca: No need to compile alloca.c with clang.
35154         * lib/alloca.c: Skip all code with clang.
35156         Use __builtin_alloca with clang.
35157         * lib/alloca.in.h (alloca): Define as __builtin_alloca on clang.
35159 2020-08-06  Bruno Haible  <bruno@clisp.org>
35161         Use __builtin_assume with clang.
35162         * lib/verify.h (_GL_HAS_BUILTIN_ASSUME): New macro.
35163         (assume): Use __builtin_assume when available.
35165 2020-08-06  Paul Eggert  <eggert@cs.ucla.edu>
35167         libgmp: add <gmp/gmp.h> support
35168         * m4/libgmp.m4 (gl_LIBGMP):
35169         * modules/libgmp (configure.ac, Makefile.am):
35170         Support platforms requiring ‘#include <gmp/gmp.h>’ instead of
35171         ‘#include <gmp.h>’.
35173 2020-08-06  Bruno Haible  <bruno@clisp.org>
35175         Consider that clang defines __OPTIMIZE__ like GCC does.
35176         * lib/streq.h: Define the inline functions also on clang.
35177         * lib/c-strcaseeq.h: Likewise.
35178         * lib/c++defs.h (_GL_CXXALIASWARN_2, _GL_CXXALIASWARN1_2): Don't enable
35179         the GCC workaround to clang.
35181 2020-08-06  Bruno Haible  <bruno@clisp.org>
35183         safe-alloc: Remove unused code.
35184         * lib/safe-alloc.h (__GNUC_PREREQ): Remove macro.
35186 2020-08-06  Bruno Haible  <bruno@clisp.org>
35188         Use __builtin_expect with clang everywhere.
35189         * lib/cdefs.h (__glibc_unlikely, __glibc_likely): Use the GCC built-in
35190         also on clang.
35192 2020-08-05  Bruno Haible  <bruno@clisp.org>
35194         Use __builtin_ctz{,l,ll} and __builtin_ffs{,l,ll} with clang everywhere.
35195         * lib/count-trailing-zeros.h (COUNT_TRAILING_ZEROS): Use the GCC
35196         built-in also on clang.
35197         * lib/ffs.c: With clang, use the GCC built-in, not <intrin.h>.
35198         * lib/ffsl.h: Likewise. Assume GCC_BUILTIN is defined.
35200 2020-08-05  Bruno Haible  <bruno@clisp.org>
35202         Use __builtin_clz{,l,ll} with clang, also on Windows.
35203         * lib/integer_length.c: With clang, use the GCC built-in, not
35204         <intrin.h>.
35205         * lib/integer_length_l.c: Likewise.
35206         * lib/count-leading-zeros.h (COUNT_LEADING_ZEROS): Use the GCC built-in
35207         also on clang.
35208         * lib/vasnprintf.c (divide): Likewise.
35210 2020-08-04  Paul Eggert  <eggert@cs.ucla.edu>
35212         Update srclist.txt as per recent glibc changes
35213         * config/srclist.txt: Uncomment lines to reflect recent merges
35214         from Gnulib to glibc.
35216 2020-08-03  Bruno Haible  <bruno@clisp.org>
35218         Prefer documented autoconf macro 'm4_if' over 'ifelse'.
35219         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Use m4_if instead of ifelse.
35221 2020-08-03  Bruno Haible  <bruno@clisp.org>
35223         integer_length_ll: Optimize for MSVC in 64-bit mode.
35224         * lib/integer_length_l.c (MSVC_BUILTIN): Define for MSVC in 64-bit mode.
35225         (FUNC): On MSVC, use MSVC_BUILTIN if defined.
35227 2020-08-03  Bruno Haible  <bruno@clisp.org>
35229         integer_length_ll: Optimize for MSVC in 32-bit mode.
35230         * lib/integer_length_l.c: Include <intrin.h>.
35231         (integer_length): Define as inline function, like in
35232         lib/integer_length.c.
35234 2020-08-03  Bruno Haible  <bruno@clisp.org>
35236         integer_length: Optimize for MSVC.
35237         * lib/integer_length.c: Include <intrin.h>.
35238         (integer_length): With MSVC, use the _BitScanReverse built-in.
35240 2020-08-03  Bruno Haible  <bruno@clisp.org>
35242         ffsll: Optimize for MSVC in 64-bit mode.
35243         * lib/ffsl.h (FUNC): On MSVC, use MSVC_BUILTIN if defined.
35244         * lib/ffsll.c (MSVC_BUILTIN): Define for MSVC in 64-bit mode.
35245         * lib/ffsl.c (MSVC_BUILTIN): Define for MSVC.
35247 2020-08-03  Bruno Haible  <bruno@clisp.org>
35249         ffsll: Optimize for MSVC in 32-bit mode.
35250         * lib/ffsl.h: Include <intrin.h>.
35251         (ffs): Define as inline function, like in lib/ffs.c.
35253 2020-08-03  Bruno Haible  <bruno@clisp.org>
35255         ffs: Optimize for MSVC.
35256         * lib/ffs.c: Include <intrin.h>.
35257         (ffs): With MSVC, use the _BitScanForward built-in.
35259 2020-08-03  Bruno Haible  <bruno@clisp.org>
35261         sigprocmask: Try to avoid breakage for people who use an Autoconf cache.
35262         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Change the name of the cache
35263         variable.
35265 2020-08-03  Harald van Dijk  <harald@gigawatt.nl>  (tiny change)
35267         fopen: Avoid undesired interactions with glibc headers.
35268         * lib/fopen.c (_GL_ALREADY_INCLUDING_STDIO_H): Define this instead of
35269         __need_FILE, as the latter does not work with glibc.
35271 2020-08-02  Paul Eggert  <eggert@cs.ucla.edu>
35273         fcntl: document some F_SETLK errno variations
35274         * doc/posix-functions/fcntl.texi (fcntl): Document
35275         OpenIndiana, GNU/Linux, FreeBSD on NFS files.
35277 2020-08-02  Bruno Haible  <bruno@clisp.org>
35279         oset: Add an 'iterator_atleast' operation.
35280         * lib/gl_array_oset.c (gl_array_indexof_atleast): New function,
35281         extracted from gl_array_search_atleast.
35282         (gl_array_search_atleast): Use it.
35283         (gl_array_iterator_atleast): New function.
35284         (gl_array_oset_implementation): Use it.
35285         * lib/gl_anytree_oset.h (gl_tree_iterator_atleast): New function.
35286         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Use it.
35287         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Likewise.
35288         * lib/gl_oset.h (struct gl_oset_implementation): Add 'iterator_atleast'
35289         member.
35290         (gl_oset_iterator_atleast): New function.
35291         * lib/gl_oset.hh (gl_OSet): Add 'begin_atleast' member.
35292         (gl_OSet::iterator): Add another auxiliary constructor.
35293         * tests/test-array_oset.c (is_at_least, gl_sortedlist_indexof_atleast):
35294         New functions.
35295         (main): Test also gl_oset_iterator_atleast.
35296         * tests/test-avltree_oset.c (is_at_least): New function.
35297         (main): Test also gl_oset_iterator_atleast.
35298         * tests/test-rbtree_oset.c (is_at_least): New function.
35299         (main): Test also gl_oset_iterator_atleast.
35300         * tests/test-oset-c++.cc (is_at_most): New function.
35301         (main): Test also gl_OSet::begin_atleast.
35303 2020-08-02  Bruno Haible  <bruno@clisp.org>
35305         oset-c++, omap-c++: Remove restriction for search_atleast method.
35306         * lib/gl_oset.hh (gl_OSet::search_atleast): Allow the threshold to be of
35307         a different type than the element.
35308         * lib/gl_omap.hh (gl_OMap::search_atleast): Allow the threshold to be of
35309         a different type than the key.
35311 2020-08-01  Paul Eggert  <eggert@cs.ucla.edu>
35313         gnumakefile: say ‘$(MAKE)’ not ‘make’
35314         * top/GNUmakefile (abort-due-to-no-makefile):
35315         Prefer ‘$(MAKE)’ to ‘make’ in a diagnostic.
35316         This change is backported from Autoconf.
35318 2020-08-01  Bruno Haible  <bruno@clisp.org>
35320         Prefer documented autoconf macro 'm4_if' over 'ifelse'.
35321         * m4/autobuild.m4 (AB_INIT): Use m4_if instead of ifelse.
35322         * m4/csharpexec.m4 (gt_CSHARPEXEC): Likewise.
35323         * m4/javacomp.m4 (gt_JAVACOMP): Likewise.
35324         * m4/javaexec.m4 (gt_JAVAEXEC): Likewise.
35325         * m4/libtextstyle.m4 (gl_LIBTEXTSTYLE): Likewise.
35327 2020-08-01  Bruno Haible  <bruno@clisp.org>
35329         libtextstyle-optional: Update tests.
35330         * modules/libtextstyle-optional-tests (configure.ac): Invoke
35331         gl_LIBTEXTSTYLE_OPTIONAL.
35333 2020-08-01  Bruno Haible  <bruno@clisp.org>
35335         parse-datetime: Fix wrong #line statements.
35336         * modules/parse-datetime (Makefile.am): Correct #line statements also in
35337         parse-datetime-gen.h.
35339 2020-08-01  Bruno Haible  <bruno@clisp.org>
35341         libtextstyle[-optional]: Allow requesting a minimum version.
35342         * m4/libtextstyle.m4 (gl_LIBTEXTSTYLE): Allow an optional argument.
35343         (gl_LIBTEXTSTYLE_NEWEST_VERSION, gl_LIBTEXTSTYLE_INITIALIZE,
35344         gl_LIBTEXTSTYLE_SEARCH): New macros.
35345         * modules/libtextstyle (configure.ac): Don't invoke gl_LIBTEXTSTYLE.
35346         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Allow an
35347         optional argument. Invoke, not require, gl_LIBTEXTSTYLE.
35348         * modules/libtextstyle-optional (configure.ac): Don't invoke
35349         gl_LIBTEXTSTYLE_OPTIONAL.
35350         * NEWS: Mention the changes.
35352 2020-07-31  Bruno Haible  <bruno@clisp.org>
35354         _GL_CMP: Improve documentation.
35355         Reported by Paul Eggert in
35356         <https://lists.gnu.org/archive/html/bug-gnulib/2020-07/msg00188.html>.
35357         * m4/gnulib-common.m4 (gl_COMMON_BODY): Clarify what arguments can be
35358         passed.
35360 2020-07-30  Paul Eggert  <eggert@cs.ucla.edu>
35362         largefile: sync with Autoconf master
35363         * m4/largefile.m4 (_AC_SYS_LARGEFILE_TEST_INCLUDES):
35364         Avoid undefined behavior on platforms where off_t is 32 bits.
35365         See: https://bugs.debian.org/742780
35367         alloca: sync with Autoconf master
35368         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA):
35369         Do not define if Autoconf 2.70 or later, since Autoconf master
35370         now matches us.
35372 2020-07-30  Bruno Haible  <bruno@clisp.org>
35374         unicodeio: Add comment.
35375         * lib/unicodeio.c (unicode_to_mb): Clarify why the code distinguishes
35376         different iconv behaviours.
35378 2020-07-30  Paul Eggert  <eggert@cs.ucla.edu>
35380         Work around some Oracle Studio attribute bugs
35381         These were discovered when building bleeding-edge Emacs with
35382         Oracle Studio.
35383         * m4/gnulib-common.m4 (_GL_ATTRIBUTE_COLD, _GL_ATTRIBUTE_MAY_ALIAS):
35384         Port to Oracle Studio 12.6, which mishandles __attribute__
35385         ((__cold__)) and __attribute__ ((__may_alias__)) even though
35386         __has_attribute says they work.
35388 2020-07-29  Bruno Haible  <bruno@clisp.org>
35390         unicodeio: Fix wrong result on musl libc.
35391         Reported by A. Wilcox <awilfox@adelielinux.org> in
35392         <https://www.openwall.com/lists/musl/2020/07/29/2>.
35393         * lib/unicodeio.c (unicode_to_mb): Handle asterisk fallback characters
35394         on musl libc.
35395         * m4/unicodeio.m4 (gl_UNICODEIO): Invoke gl_MUSL_LIBC.
35396         * modules/unicodeio (Files): Add m4/musl.m4.
35398 2020-07-29  Paul Eggert  <eggert@cs.ucla.edu>
35400         fsusage, regex, stat-size: remove Cray support
35401         As near as I can make out this is actually support for UNICOS/mp,
35402         last released 2005, and Cray hasn’t supported that for years.
35403         * config/srclist.txt: Comment out regex.h for now.
35404         * lib/fsusage.c (get_fs_usage):
35405         * lib/regex.h (re_comp, re_exec):
35406         * lib/stat-size.h (ST_NBLOCKSIZE):
35407         Don’t worry about _CRAY.
35409 2020-07-29  Bruno Haible  <bruno@clisp.org>
35411         parse-datetime: Fix compilation error with bison 3.7.
35412         * modules/parse-datetime (Makefile.am): Create a generated header file
35413         parse-datetime-gen.h in the source directory. Correct #include and
35414         #line statements during preprocessing.
35416 2020-07-28  Bruno Haible  <bruno@clisp.org>
35418         fopen-gnu: Create files correctly (regression from 2020-05-24).
35419         * lib/fopen.c (rpl_open): Pass a third argument to open().
35421 2020-07-27  Paul Eggert  <eggert@cs.ucla.edu>
35423         xalloc-die: don’t depend on xalloc
35424         This removes a circular dependency, as xalloc depends on xalloc-die.
35425         * modules/xalloc-die (Files): Add lib/xalloc.h.
35426         (Depends-on): Remove xalloc.
35427         Add extern-inline, stdint, xalloc-oversized (this is for xalloc.h).
35429         dfa-tests: port to MSVC
35430         Problem reported by Gisle Vanem in:
35431         https://lists.gnu.org/r/bug-gnulib/2020-07/msg00159.html
35432         Also, remove an unnecessary dependency on getprogname.
35433         * modules/dfa-tests (Depends-on): Remove getprogname.
35434         * tests/test-dfa-match-aux.c: Do not include getprogname.h.
35435         (exit_status): New static var.
35436         (dfawarn): Set it instead of exiting.
35437         Do not declare as _Noreturn, to pacify MSVC.
35438         (main): Return exit_status.
35440 2020-07-26  Paul Eggert  <eggert@cs.ucla.edu>
35442         argz: pacify MSVC
35443         * lib/argz.in.h: Avoid "*/*" to pacify MSVC.
35444         Problem reported by Gisle Vanem.
35446         libgmp: remove dependency on havelib
35447         * m4/libgmp.m4 (gl_LIBGMP): If gl_HAVE_MODULE_HAVELIB is not defined,
35448         use the more-traditional AC_SEARCH_LIBS approach.
35449         This should work better with GNU Emacs configuration,
35450         which uses pkg-config instead of a havelib-style approach.
35451         * modules/havelib (gl_HAVE_MODULE_HAVELIB): New witness macro.
35452         * modules/libgmp (Depends-on): Remove havelib.
35454         libgmp: remove HAVE_GMP, LIB_GMP
35455         * m4/libgmp.m4 (gl_LIBGMP): Do not define HAVE_GMP and LIB_GMP, as
35456         they’re redundant.  I’ll adjust GNU Coreutils accordingly.
35458 2020-07-26  Bruno Haible  <bruno@clisp.org>
35460         inttypes: Remove support for AIX 4.
35461         * lib/inttypes.in.h: Assume that PRI_MACROS_BROKEN is 0.
35462         * m4/inttypes-pri.m4: Remove file.
35463         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): Don't require gt_INTTYPES_PRI.
35464         (gl_INTTYPES_H_DEFAULTS): Don't initialize PRI_MACROS_BROKEN.
35465         * modules/inttypes-incomplete (Makefile.am): Don't substitute
35466         PRI_MACROS_BROKEN.
35467         * modules/inttypes (Files): Remove m4/inttypes-pri.m4.
35469 2020-07-26  Bruno Haible  <bruno@clisp.org>
35471         gettimeofday: Remove workaround for Mac OS X 10.0.
35472         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Remove macro.
35473         (gl_FUNC_GETTIMEOFDAY): Don't invoke it.
35474         * lib/gettimeofday.c: Don't include localtime-buffer.h.
35475         (gettimeofday): Don't test GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35476         * lib/localtime.c: Don't test GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35477         * modules/gettimeofday (Depends-on): Remove localtime-buffer.
35478         * modules/localtime-buffer: Remove file.
35479         * lib/localtime-buffer.h: Remove file.
35480         * lib/localtime-buffer.c: Remove file.
35481         * m4/localtime-buffer.m4: Remove file.
35482         * MODULES.html.sh (Date and time <time.h>): Remove localtime-buffer.
35484 2020-07-26  Bruno Haible  <bruno@clisp.org>
35486         tzset: Remove workaround for Solaris 2.6.
35487         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Remove macro.
35488         (gl_FUNC_TZSET): Don't invoke it. Don't define TZSET_CLOBBERS_LOCALTIME.
35489         Don't require gl_LOCALTIME_BUFFER_DEFAULTS.
35490         * lib/localtime-buffer.h: Don't test TZSET_CLOBBERS_LOCALTIME.
35491         * lib/localtime-buffer.c: Likewise.
35492         * lib/localtime.c: Likewise.
35493         * lib/tzset.c: Don't include localtime-buffer.h.
35494         (tzset): Don't test TZSET_CLOBBERS_LOCALTIME.
35495         * lib/nstrftime.c (__strftime_internal): Assume HAVE_RUN_TZSET_TEST
35496         is 1.
35497         * modules/tzset (Depends-on): Remove localtime-buffer.
35499 2020-07-26  Bruno Haible  <bruno@clisp.org>
35501         expl: Simplify autoconf test.
35502         * m4/expl.m4 (gl_FUNC_EXPL): Merge the "checking whether expl() breaks
35503         with small values..." test into the "checking whether expl works..."
35504         test.
35506 2020-07-26  Bruno Haible  <bruno@clisp.org>
35508         alloca: Remove Cray-2 and Cray Y-MP support.
35509         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA): Don't define CRAY_STACKSEG_END.
35510         Enable also on Autoconf >= 2.69.
35511         * lib/alloca.c (ADDRESS_FUNCTION, struct stack_control_header,
35512         struct stack_segment_linkage, struct stk_stat, struct stk_trailer,
35513         i00afunc): Remove.
35515 2020-07-25  Bruno Haible  <bruno@clisp.org>
35517         multiarch: Prepare for x86_64+arm64 universal binaries in macOS 11.
35518         * m4/multiarch.m4 (gl_MULTIARCH): Recognize also the ARM architectures.
35520 2020-07-25  Bruno Haible  <bruno@clisp.org>
35522         sigprocmask: Small autoconf macro improvement.
35523         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Make it possible for the
35524         user to override the value of gl_cv_func_sigprocmask.
35525         * m4/gnulib-common.m4 (gl_SILENT): New macro.
35527 2020-07-25  Bruno Haible  <bruno@clisp.org>
35529         Small autoconf macro improvements.
35530         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Make it possible for the user to
35531         override the value of gl_cv_func_working_mktime.
35532         * m4/multiarch.m4 (gl_MULTIARCH): Show a line "checking whether the
35533         compiler produces multi-arch binaries..." in the configure output.
35534         * m4/size_max.m4 (gl_SIZE_MAX): When not found, say "no".
35535         * m4/parse-datetime.m4 (gl_C_COMPOUND_LITERALS): Improve indentation.
35537 2020-07-25  Bruno Haible  <bruno@clisp.org>
35539         doc: Update for NetBSD 7.1, 8.0, 9.0.
35540         * doc/*/*.texi: Update.
35541         * m4/exp2l.m4: Update comments.
35542         * m4/expl.m4: Likewise.
35543         * m4/ilogb.m4: Likewise.
35544         * m4/ilogbf.m4: Likewise.
35545         * m4/log10l.m4: Likewise.
35546         * m4/logl.m4: Likewise.
35547         * m4/printf.m4: Likewise.
35548         * m4/rintl.m4: Likewise.
35549         * m4/wcwidth.m4: Likewise.
35551 2020-07-24  Bruno Haible  <bruno@clisp.org>
35553         doc: Update for Mac OS X 10.13.
35554         * doc/*/*.texi: Update.
35555         * m4/expm1l.m4: Update comments.
35556         * m4/getgroups.m4: Likewise.
35557         * m4/getlogin_r.m4: Likewise.
35558         * m4/linkat.m4: Likewise.
35559         * m4/printf.m4: Likewise.
35561 2020-07-24  Bruno Haible  <bruno@clisp.org>
35563         doc: Update for Cygwin 2.9.0.
35564         * doc/*/*.texi: Update.
35566 2020-07-24  Paul Eggert  <eggert@cs.ucla.edu>
35568         parse-datetime: modernize doc
35569         * doc/parse-datetime.texi: Use more-current examples.
35570         Don’t lead with 32-bit time_t, as it’s on its way out.
35571         Capitalize “Epoch” to be consistent with POSIX.
35573         timespec: remove dependence on ‘verify’
35574         * lib/timespec.h: Do not include verify.h; no longer needed.
35575         * modules/timespec (Depends-on): Remove ‘verify’.
35577         Optimize a few more three-valued comparisons
35578         * lib/timespec.h (timespec_cmp, timespec_sign):
35579         * lib/utimecmp.c (utimecmpat):
35580         Avoid conditional branches by using _GL_CMP.
35582         Fix _GL_CMP parenthesization typo
35583         * m4/gnulib-common.m4 (_GL_CMP): Properly parenthesize.
35585 2020-07-24  Bruno Haible  <bruno@clisp.org>
35587         dfa: Revert breaking gawk.
35588         Reported by Arnold Robbins <arnold@skeeve.com>.
35589         * lib/dfa.c (compare): Don't reference the _GL_CMP macro.
35591 2020-07-23  Bruno Haible  <bruno@clisp.org>
35593         Optimize three-valued comparison between integers.
35594         (a > b ? 1 : a < b ? -1 : 0) is the same as (a > b) - (a < b).
35595         * m4/gnulib-common.m4 (gl_COMMON): Define _GL_CMP.
35596         * lib/c-strcasecmp.c (c_strcasecmp): Use _GL_CMP.
35597         * lib/c-strncasecmp.c (c_strncasecmp): Likewise.
35598         * lib/dfa.c (compare): Likewise.
35599         * lib/fts.c (fts_compare_ino): Likewise.
35600         * lib/mbmemcasecmp.c (mbmemcasecmp): Likewise.
35601         * lib/mbscasecmp.c (mbscasecmp): Likewise.
35602         * lib/mbsncasecmp.c (mbsncasecmp): Likewise.
35603         * lib/memcasecmp.c (memcasecmp): Likewise.
35604         * lib/memcmp2.c (memcmp2): Likewise.
35605         * lib/savedir.c (direntry_cmp_inode): Likewise.
35606         * lib/strcasecmp.c (strcasecmp): Likewise.
35607         * lib/strncasecmp.c (strncasecmp): Likewise.
35608         * lib/unistr/u-cmp2.h (FUNC): Likewise.
35610 2020-07-23  Bruno Haible  <bruno@clisp.org>
35612         lchmod: Use /proc on Cygwin.
35613         * lib/lchmod.c (lchmod): Use /proc on Cygwin.
35615 2020-07-23  Ken Brown  <kbrown@cornell.edu>
35617         fchmodat: Use /proc on Cygwin
35618         * lib/fchmodat.c (fchmodat): Use /proc on Cygwin.
35620 2020-07-21  Bruno Haible  <bruno@clisp.org>
35622         aligned-malloc: Optionally use aligned_alloc.
35623         * lib/aligned-malloc.h: Verify the alignment.
35624         (aligned_malloc): Use aligned_alloc as an alternative.
35625         * modules/aligned-malloc (configure.ac): Test for aligned_alloc.
35626         * doc/posix-functions/aligned_alloc.texi: Mention the modules
35627         'aligned-malloc' and 'pagealign_alloc'.
35629 2020-07-21  Bruno Haible  <bruno@clisp.org>
35631         aligned-malloc: Add tests.
35632         * tests/test-aligned-malloc.c: New file.
35633         * modules/aligned-malloc-tests: New file.
35635         aligned-malloc: New module.
35636         * lib/aligned-malloc.h: New file.
35637         * m4/malloc-align.m4: New file.
35638         * modules/aligned-malloc: New file.
35639         * doc/posix-functions/posix_memalign.texi: Mention the new module.
35640         * doc/glibc-functions/memalign.texi: Likewise.
35642 2020-07-21  Bruno Haible  <bruno@clisp.org>
35644         inttypes: Fix PRI*PTR and SCN*PTR on 64-bit native Windows.
35645         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): On 64-bit native Windows, make
35646         sure PRIPTR_PREFIX is defined to "ll", not "l".
35648 2020-07-21  Bruno Haible  <bruno@clisp.org>
35650         printf-posix: Make an autoconf test more future-proof.
35651         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): Include <inttypes.h> before
35652         using uintptr_t.
35654 2020-07-20  Bruno Haible  <bruno@clisp.org>
35656         list, oset, omap: Relicense some of the container modules under LGPLv2+.
35657         * modules/list (License): Change to LGPLv2+.
35658         * modules/array-list (License): Likewise.
35659         * modules/carray-list (License): Likewise.
35660         * modules/linked-list (License): Likewise.
35661         * modules/avltree-list (License): Likewise.
35662         * modules/rbtree-list (License): Likewise.
35663         * modules/oset (License): Likewise.
35664         * modules/array-oset (License): Likewise.
35665         * modules/avltree-oset (License): Likewise.
35666         * modules/rbtree-oset (License): Likewise.
35667         * modules/omap (License): Likewise.
35668         * modules/array-omap (License): Likewise.
35669         * modules/avltree-omap (License): Likewise.
35670         * modules/rbtree-omap (License): Likewise.
35672 2020-07-20  Bruno Haible  <bruno@clisp.org>
35674         oset: Add an 'update' operation.
35675         * lib/gl_array_oset.c (gl_array_update): New function.
35676         (gl_array_oset_implementation): Use it.
35677         * lib/gl_avltree_omap.c (NODE_PAYLOAD_DISPOSE): Add parameters.
35678         * lib/gl_rbtree_omap.c (NODE_PAYLOAD_DISPOSE): Add parameters.
35679         * lib/gl_avltree_ordered.h (gl_tree_add_node_before): New function,
35680         extracted from gl_tree_nx_add_before.
35681         (gl_tree_nx_add_before): Invoke it.
35682         (gl_tree_add_node_after): New function, extracted from
35683         gl_tree_nx_add_after.
35684         (gl_tree_nx_add_after): Invoke it.
35685         (gl_tree_remove_node_no_free): New function, extracted from
35686         gl_tree_remove_node.
35687         (gl_tree_remove_node): Invoke it.
35688         * lib/gl_rbtree_ordered.h (gl_tree_add_node_before): New function,
35689         extracted from gl_tree_nx_add_before.
35690         (gl_tree_nx_add_before): Invoke it.
35691         (gl_tree_add_node_after): New function, extracted from
35692         gl_tree_nx_add_after.
35693         (gl_tree_nx_add_after): Invoke it.
35694         (gl_tree_remove_node_no_free): New function, extracted from
35695         gl_tree_remove_node.
35696         (gl_tree_remove_node): Invoke it.
35697         * lib/gl_anytree_oset.h (gl_tree_next_node): New function, extracted
35698         from gl_tree_iterator_next.
35699         (gl_tree_iterator_next): Invoke it.
35700         (gl_tree_prev_node, gl_tree_update): New functions.
35701         * lib/gl_avltree_oset.c (NODE_PAYLOAD_DISPOSE): Add parameters.
35702         (gl_avltree_oset_implementation): Use gl_tree_update.
35703         * lib/gl_rbtree_oset.c (NODE_PAYLOAD_DISPOSE): Add parameters.
35704         (gl_rbtree_oset_implementation): Use gl_tree_update.
35705         * lib/gl_oset.h (struct gl_oset_implementation): Add 'update' member.
35706         (gl_oset_update): New function.
35707         * lib/gl_oset.hh (gl_OSet): Add 'update' member.
35708         * modules/avltree-oset (configure.ac): Require AC_C_INLINE.
35709         * modules/rbtree-oset (configure.ac): Likewise.
35710         * tests/test-oset-update.h: New file.
35711         * tests/test-array_oset.c: Include test-oset-update.h.
35712         (main): Invoke test_update.
35713         * tests/test-avltree_oset.c: Likewise.
35714         * tests/test-rbtree_oset.c: Likewise.
35715         * modules/array-oset-tests (Files): Add tests/test-oset-update.h.
35716         * modules/avltree-oset-tests (Files): Likewise.
35717         * modules/rbtree-oset-tests (Files): Likewise.
35718         * tests/test-oset-c++.cc (action): New function.
35719         (main): Test the 'update' member function.
35721 2020-07-15  Paul Eggert  <eggert@cs.ucla.edu>
35723         md5, sha1, sha256, sha512: pacify Autoconf 2.70
35724         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Use m4_if rather than a
35725         shell if, so that the argument to AC_CHECK_HEADERS is
35726         a simple string that does not require shell evaluation.
35727         This fixes a warning generated by Autoconf 2.69b.
35729 2020-07-12  Bruno Haible  <bruno@clisp.org>
35731         libgmp: Avoid warning when --without-libgmp is used.
35732         * lib/mini-gmp-gnulib.c: Ignore -Wsuggest-attribute=malloc only for
35733         GCC >= 8, not for GCC >= 4.6.
35735 2020-07-12  Bruno Haible  <bruno@clisp.org>
35737         libgmp: Link to the correct shared library.
35738         * m4/libgmp.m4 (gl_LIBGMP): Invoke AC_LIB_HAVE_LINKFLAGS.
35739         * modules/libgmp (Depends-on): Add havelib.
35740         (Link): Mention $(LIBGMP) and $(LTLIBGMP).
35741         * modules/libgmp-tests (Makefile.am): Link test-libgmp with $(LIBGMP).
35743 2020-07-12  Bruno Haible  <bruno@clisp.org>
35745         libgmp tests: Add some safety checks.
35746         * modules/libgmp-tests (Depends-on): Add verify.
35747         * tests/test-libgmp.c: Verify GMP_NUMB_BITS value.
35748         (main): Verify that gmp.h and libgmp versions match.
35750 2020-07-10  Bruno Haible  <bruno@clisp.org>
35752         unicodeio: Fix wrong result on NetBSD.
35753         * lib/unicodeio.c (unicode_to_mb): Handle question mark fallback
35754         characters also on NetBSD.
35756 2020-07-09  Bruno Haible  <bruno@clisp.org>
35758         unicodeio: Fix wrong result on Solaris 11.
35759         Reported by Kiyoshi Kanazawa <yoi_no_myoujou@yahoo.co.jp>
35760         via Akim Demaille <akim.demaille@gmail.com> in
35761         <https://lists.gnu.org/archive/html/bug-gnulib/2020-07/msg00036.html>.
35762         * lib/unicodeio.c (unicode_to_mb): Handle question mark fallback
35763         characters on Solaris.
35764         * tests/test-unicodeio.c (main): In the "C" locale, expect either the
35765         UTF-8 output or the specified fallback.
35767 2020-07-08  Bruno Haible  <bruno@clisp.org>
35769         unicodeio: Add tests.
35770         * tests/test-unicodeio.c: New file.
35771         * tests/test-unicodeio1.sh: New file.
35772         * tests/test-unicodeio2.sh: New file.
35773         * tests/test-unicodeio3.sh: New file.
35774         * modules/unicodeio-tests: New file.
35776 2020-07-08  Bruno Haible  <bruno@clisp.org>
35778         unicodeio: Document link requirements.
35779         * modules/unicodeio (Link): New section.
35781 2020-07-07  Bruno Haible  <bruno@clisp.org>
35783         doc: Remove support for some very old platforms.
35784         * doc/posix-functions/memcmp.texi: Don't mention "older platforms".
35785         * doc/posix-functions/memcpy.texi: Likewise.
35786         * doc/posix-functions/memmove.texi: Likewise.
35787         * doc/posix-functions/memset.texi: Likewise.
35788         * doc/posix-functions/getcwd.texi: Likewise.
35790         memchr: Remove support for some very old platforms.
35791         * m4/memchr-obsolete.m4: Remove file.
35792         * modules/memchr-obsolete: Remove file.
35793         * m4/memchr.m4 (gl_FUNC_MEMCHR): Assume module 'memchr-obsolete' is
35794         absent. Don't define HAVE_MEMCHR.
35795         * lib/string.in.h (memchr): Assume HAVE_MEMCHR is 1.
35796         * modules/memchr (Depends-on): Remove memchr-obsolete.
35797         (configure.ac): Assume HAVE_MEMCHR is 1.
35798         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
35799         HAVE_MEMCHR.
35800         * modules/string (Makefile.am): Don't substitute HAVE_MEMCHR.
35801         * doc/posix-functions/memchr.texi: Don't mention module
35802         'memchr-obsolete'.
35803         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Assume HAVE_MEMCHR is 1.
35804         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Assume HAVE_MEMCHR is 1.
35805         * modules/strnlen (Depends-on): Remove memchr-obsolete.
35807         dup2: Remove support for some very old platforms.
35808         * m4/dup2-obsolete.m4: Remove file.
35809         * modules/dup2-obsolete: Remove file.
35810         * m4/dup2.m4 (gl_FUNC_DUP2): Assume module 'dup2-obsolete' is absent.
35811         Don't define HAVE_DUP2.
35812         * lib/unistd.in.h (dup2): Assume HAVE_DUP2 is 1.
35813         * lib/dup2.c: Likewise.
35814         * modules/dup2 (Depends-on, configure.ac): Likewise.
35815         (Depends-on): Remove dup2-obsolete.
35816         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Don't initialize HAVE_DUP2.
35817         * modules/unistd (Makefile.am): Don't substitute HAVE_DUP2.
35818         * doc/posix-functions/dup2.texi: Don't mention module 'dup2-obsolete'.
35820 2020-07-07  Bruno Haible  <bruno@clisp.org>
35822         canonicalize: Trim module dependencies.
35823         * lib/hash-triple.h: Group declarations.
35824         * lib/hash-triple-simple.c: New file, extracted from lib/hash-triple.c.
35825         * lib/hash-triple.c: Don't include <stdlib.h>, <string.h>, hash-pjw.h.
35826         (STREQ): Remove macro.
35827         (triple_hash, triple_compare_ino_str, triple_free): Remove functions.
35828         * modules/hash-triple-simple: New file, based on modules/hash-triple.
35829         * modules/hash-triple (Files): Remove lib/hash-triple.h.
35830         (Depends-on): Add hash-triple-simple. Remove hash-pjw.
35831         * modules/canonicalize (Depends-on): Remove hash-triple. Add
35832         hash-triple-simple.
35833         * modules/file-set (Depends-on): Likewise.
35835 2020-07-07  Bruno Haible  <bruno@clisp.org>
35837         Clarify dependencies to double-slash-root.
35838         * modules/canonicalize (Files): Remove m4/double-slash-root.m4.
35839         (Depends-on): Add double-slash-root.
35840         * modules/canonicalize-lgpl (Depends-on): Add double-slash-root.
35841         * modules/dirname-lgpl (Depends-on): Add double-slash-root.
35843 2020-07-06  Paul Eggert  <eggert@cs.ucla.edu>
35845         libgmp: new module
35846         The idea is to let programs simply include <gmp.h>, and
35847         so long as they live within the mini-gmp subset they need
35848         not worry about whether the GMP libraries are installed.
35849         * MODULES.html.sh: Mention it.
35850         * config/srclist.txt: Mention files copied from GMP source.
35851         * config/srclistvars.sh (GMP): New var.
35852         * lib/mini-gmp-gnulib.c, m4/libgmp.m4, modules/libgmp:
35853         * modules/libgmp-tests, tests/test-libgmp.c: New files.
35854         * lib/mini-gmp.c, lib/mini-gmp.h: New files, copied from GMP.
35856 2020-07-05  Bruno Haible  <bruno@clisp.org>
35858         mkancesdirs: Trim module dependencies.
35859         * lib/mkancesdirs.c: Include filename.h instead of dirname.h.
35860         * modules/mkancesdirs (Depends-on): Remove dirname-lgpl. Add filename.
35862 2020-07-05  Bruno Haible  <bruno@clisp.org>
35864         getprogname: Trim module dependencies.
35865         * lib/getprogname.c: Include basename-lgpl.h instead of dirname.h.
35866         * modules/getprogname (Depends-on): Remove dirname-lgpl. Add
35867         basename-lgpl.
35869 2020-07-05  Bruno Haible  <bruno@clisp.org>
35871         filenamecat-lgpl: Trim module dependencies.
35872         * lib/filenamecat-lgpl.c: Include basename-lgpl.h, filename.h instead of
35873         dirname.h.
35874         * modules/filenamecat-lgpl (Depends-on): Remove dirname-lgpl. Add
35875         basename-lgpl, filename.
35877 2020-07-05  Bruno Haible  <bruno@clisp.org>
35879         backupfile, backup-rename: Trim module dependencies.
35880         * lib/backupfile.c: Include basename-lgpl.h instead of dirname.h.
35881         * modules/backupfile (Depends-on): Remove dirname-lgpl. Add
35882         basename-lgpl.
35883         * modules/backup-rename (Depends-on): Likewise.
35885 2020-07-05  Bruno Haible  <bruno@clisp.org>
35887         argp: Trim module dependencies.
35888         * lib/argp-namefrob.h: Include basename-lgpl.h instead of dirname.h.
35889         * modules/argp (Depends-on): Remove dirname-lgpl. Add basename-lgpl.
35891 2020-07-05  Bruno Haible  <bruno@clisp.org>
35893         basename-lgpl: New module.
35894         * lib/basename-lgpl.h: New file, based on lib/dirname.h and
35895         lib/basename-lgpl.c.
35896         * lib/basename-lgpl.c: Include basename-lgpl.h, not dirname.h. Include
35897         <stdbool.h>, filename.h.
35898         (last_component): Rename a local variable.
35899         * lib/dirname.h: Include basename-lgpl.h.
35900         (DOUBLE_SLASH_IS_DISTINCT_ROOT): Remove macro.
35901         (last_component, base_len): Remove declarations.
35902         * modules/basename-lgpl: New file.
35903         * modules/dirname-lgpl (Files): Remove lib/basename-lgpl.c.
35904         (Depends-on): Add basename-lgpl. Remove double-slash-root.
35905         (Makefile.am): Don't compile basename-lgpl.c.
35906         * doc/posix-functions/basename.texi: Mention the module 'basename-lgpl',
35907         not 'dirname'.
35909 2020-07-05  Bruno Haible  <bruno@clisp.org>
35911         dirname, dirname-lgpl: Simplify.
35912         * m4/dirname.m4: Remove file.
35913         * modules/dirname (configure.ac): Don't invoke gl_DIRNAME.
35914         * modules/dirname-lgpl (Files): Remove m4/dirname.m4.
35915         (configure.ac): Don't invoke gl_DIRNAME_LGPL.
35917 2020-07-05  Bernhard Voelker  <mail@bernhard-voelker.de>
35919         tests: avoid shadowing warning
35920         * tests/test-memchr.c (main): Give page_boundary variable a tight scope.
35922 2020-07-05  Bruno Haible  <bruno@clisp.org>
35924         supersede: Add tests.
35925         * tests/test-supersede.c: New file.
35926         * tests/test-supersede-open.h: New file.
35927         * tests/test-supersede-fopen.h: New file.
35928         * modules/supersede-tests: New file.
35930         supersede: New module.
35931         * lib/supersede.h: New file.
35932         * lib/supersede.c: New file.
35933         * m4/supersede.m4: New file.
35934         * modules/supersede: New file.
35936 2020-07-05  Bruno Haible  <bruno@clisp.org>
35938         Add some copyright headers.
35939         * lib/dev-ino.h: Add copyright header.
35940         * lib/di-set.h: Likewise.
35941         * lib/fchown-stub.c: Likewise.
35942         * lib/file-set.h: Likewise.
35943         * lib/hash-triple.h: Likewise.
35944         * lib/idcache.h: Likewise.
35945         * lib/ino-map.h: Likewise.
35946         * lib/mkancesdirs.h: Likewise.
35947         * lib/scratch_buffer.h: Likewise.
35948         * lib/se-context.in.h: Likewise.
35949         * lib/stdopen.h: Likewise.
35950         * lib/userspec.h: Likewise.
35952 2020-07-04  Bruno Haible  <bruno@clisp.org>
35954         getrandom: Relicense under LGPLv2+.
35955         Paul Eggert's approval is in
35956         <https://lists.gnu.org/archive/html/bug-gnulib/2020-07/msg00023.html>.
35957         * modules/getrandom (License): Change to LGPLv2+.
35959 2020-07-04  Bruno Haible  <bruno@clisp.org>
35961         getumask: Add tests.
35962         * tests/test-getumask.c: New file.
35963         * modules/getumask-tests: New file.
35965         getumask: New module.
35966         * lib/sys_stat.in.h (getumask): New declaration.
35967         * lib/getumask.c: New file.
35968         * m4/getumask.m4: New file.
35969         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Test whether getumask is
35970         declared.
35971         (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_GETUMASK, HAVE_GETUMASK.
35972         * modules/sys_stat (Makefile.am): Substitute GNULIB_GETUMASK,
35973         HAVE_GETUMASK.
35974         * modules/getumask: New file.
35975         * tests/test-sys_stat-c++.cc (getumask): Check signature.
35976         * doc/glibc-functions/getumask.texi: New file.
35977         * doc/gnulib.texi (Glibc sys/stat.h): Include it.
35979 2020-07-04  Bruno Haible  <bruno@clisp.org>
35981         clean-temp: Add support for temporary files with given mode.
35982         * lib/clean-temp.h (gen_register_open_temp): Add mode argument.
35983         * lib/clean-temp.c (struct try_create_file_params): New type.
35984         (try_create_file): New function.
35985         (gen_register_open_temp): Add mode argument. Use try_tempname instead of
35986         gen_tempname.
35988 2020-07-04  Bruno Haible  <bruno@clisp.org>
35990         clean-temp: Document limitations.
35991         * lib/clean-temp.h: Document limitations.
35993 2020-07-04  Bruno Haible  <bruno@clisp.org>
35995         clean-temp: Add support for temporary files with unpredictable names.
35996         * lib/clean-temp.h (gen_register_open_temp): New declaration.
35997         * lib/clean-temp.c: Include tempname.h.
35998         (gen_register_open_temp): New function.
35999         * modules/tempname (configure.ac): Define a module indicator.
36001 2020-07-04  Bruno Haible  <bruno@clisp.org>
36003         clean-temp: Add support for temporary files anywhere in the file system.
36004         * lib/clean-temp.h (register_temporary_file, unregister_temporary_file,
36005         cleanup_temporary_file): New declarations.
36006         * lib/clean-temp.c (file_cleanup_list_lock, file_cleanup_list): New
36007         variables.
36008         (dir_cleanup_list_lock): Renamed from cleanup_list_lock.
36009         (dir_cleanup_list): Renamed from cleanup_list.
36010         (cleanup_action): Process the file_cleanup_list as well.
36011         (do_init_clean_temp): New function.
36012         (clean_temp_once): New variable.
36013         (init_clean_temp): New function.
36014         (create_temp_dir): Invoke it.
36015         (register_temporary_file, unregister_temporary_file,
36016         cleanup_temporary_file): New functions.
36017         (do_unlink, do_rmdir): Remove 'dir' argument. Add 'cleanup_verbose'
36018         argument.
36020 2020-07-04  Bruno Haible  <bruno@clisp.org>
36022         clean-temp: Improve comments.
36023         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
36024         fwriteerror_temp, close_stream_temp): Clarify intended use.
36025         * lib/clean-temp.c: Likewise.
36027 2020-07-04  Bruno Haible  <bruno@clisp.org>
36029         clean-temp: Make multithread-safe, part 2.
36030         * lib/fatal-signal.h: Include <signal.h>.
36031         (get_fatal_signal_set): New declaration.
36032         * lib/fatal-signal.c (get_fatal_signal_set): New function.
36033         * lib/clean-temp.c: Include asyncsafe-spin.h, gl_linked_list.h.
36034         (struct closeable_fd): New type.
36035         (fatal_signal_set): New variable.
36036         (init_fatal_signal_set): New function.
36037         (asyncsafe_close, asyncsafe_fclose_variant): New functions.
36038         (cleanup_action): Invoke asyncsafe_close instead of close.
36039         (create_temp_dir): Invoke init_fatal_signal_set.
36040         (register_fd): Use a plain linked list. Add a 'struct closeable_fd *'
36041         element.
36042         (unregister_fd): Remove function.
36043         (close_temp): Cleanup descriptors list on the fly. Invoke
36044         init_fatal_signal_set. Invoke asyncsafe_close instead of close.
36045         (fclose_variant_temp): New function.
36046         (fclose_temp, fwriteerror_temp, close_stream_temp): Use it.
36047         * modules/clean-temp (Depends-on): Add asyncsafe-spin, linked-list.
36049 2020-07-04  Bruno Haible  <bruno@clisp.org>
36051         clean-temp: Make multithread-safe, part 1.
36052         * lib/clean-temp.c: Include glthread/lock.h.
36053         (cleanup_list_lock): New variable.
36054         (register_temp_file, unregister_temp_file, register_temp_subdir,
36055         unregister_temp_subdir, cleanup_temp_dir_contents): Use it.
36056         (create_temp_dir): Likewise. Don't free the old array.
36057         (descriptors_lock): New variable.
36058         (register_fd, unregister_fd): Use it.
36059         * modules/clean-temp (Depends-on): Add lock.
36061 2020-07-04  Bruno Haible  <bruno@clisp.org>
36063         fatal-signal: Make multithread-safe.
36064         * lib/fatal-signal.c (init_fatal_signals): Add comment.
36065         (do_init_fatal_signal_set): New function, extracted from
36066         init_fatal_signal_set.
36067         (fatal_signal_set_once): New variable.
36068         (init_fatal_signal_set): Use gl_once.
36070 2020-07-03  Bruno Haible  <bruno@clisp.org>
36072         getrandom: Fix compilation error on native Windows (regr. 2020-06-28).
36073         * lib/getrandom.c: Don't include <ntdef.h>. Instead, define NTSTATUS.
36074         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Include <windows.h> before
36075         <bcrypt.h>.
36077 2020-07-03  Bruno Haible  <bruno@clisp.org>
36079         dfa tests: Follow common file naming conventions.
36080         * tests/test-dfa-match-aux.c: Renamed from tests/dfa-match-aux.c.
36081         * tests/test-dfa-match.sh: Renamed from tests/dfa-match.sh. Update.
36082         * tests/test-dfa-invalid-char-class.sh: Renamed from
36083         tests/dfa-invalid-char-class.sh. Update.
36084         * modules/dfa-tests (Files, Makefile.am): Update.
36086 2020-07-03  Bruno Haible  <bruno@clisp.org>
36088         asyncsafe-spin: Use GCC extended asm syntax for SunStudio 12 compiler.
36089         * lib/asyncsafe-spin.c (memory_barrier, atomic_compare_and_swap): Use
36090         the GCC extended asm syntax also for the Sun Studio 12 compilers.
36092 2020-07-03  Bruno Haible  <bruno@clisp.org>
36094         asyncsafe-spin: Reduce code duplication.
36095         * lib/asyncsafe-spin.c (do_lock, do_unlock): New functions.
36096         (asyncsafe_spin_lock, asyncsafe_spin_unlock): Use them.
36097         * modules/asyncsafe-spin (configure.ac): Require AC_C_INLINE.
36099 2020-07-03  Bruno Haible  <bruno@clisp.org>
36101         lchmod: Simplify after 2020-02-22 change.
36102         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Don't require AC_C_INLINE.
36104 2020-07-03  Bruno Haible  <bruno@clisp.org>
36106         gen-uni-tables: Make sure the compiler does not barf on 'inline'.
36107         * modules/gen-uni-tables (configure.ac): Require AC_C_INLINE.
36109 2020-07-03  Bruno Haible  <bruno@clisp.org>
36111         dfa: Make sure the compiler does not barf on 'inline'.
36112         * modules/dfa (configure.ac): Require AC_C_INLINE.
36114 2020-07-03  Bruno Haible  <bruno@clisp.org>
36116         bitset: Make sure the compiler does not barf on 'inline'.
36117         * modules/bitset (configure.ac): New section.
36119 2020-07-01  Paul Eggert  <eggert@cs.ucla.edu>
36121         manywarnings: improve port to GCC 10.1
36122         * build-aux/gcc-warning.spec: Also list warnings that are default
36123         or are enabled by already-given flags.  This lets us speed up
36124         checking for attributes, and makes the generated compilation
36125         commands shorter.  Add -Wanalyzer-too-complex (too much noise).
36126         * m4/manywarnings.m4 (gl_MANYWARN_COMPLEMENT)
36127         (gl_MANYWARN_ALL_GCC): Use gl_AS_VAR_APPEND to append
36128         to shell variables that may have long values.
36129         (gl_MANYWARN_ALL_GCC): Omit flags that are default or are
36130         consequences of other flags, to speed up checking and
36131         shorten commands.
36133         tests: pacify gcc -fanalyzer on zerosize_ptr
36134         * tests/test-memcasecmp.c (main):
36135         * tests/test-memchr.c (main):
36136         * tests/test-memchr2.c (main):
36137         * tests/test-memcmp.c (main):
36138         * tests/test-memmem.c (main):
36139         * tests/test-memrchr.c (main):
36140         * tests/unistr/test-chr.h (main):
36141         * tests/unistr/test-cmp.h (test_cmp):
36142         Check whether zerosize_ptr returns NULL before using it.
36143         This pacifies GCC 10.1’s new fanalyzer option, and matches
36144         other uses of zerosize_ptr.
36146 2020-07-01  Bruno Haible  <bruno@clisp.org>
36148         asyncsafe-spin: Add tests.
36149         * tests/test-asyncsafe-spin1.c: New file.
36150         * tests/test-asyncsafe-spin2.c: New file, based on tests/test-lock.c and
36151         tests/test-pthread-spin.c.
36152         * modules/asyncsafe-spin-tests: New file.
36154 2020-07-01  Bruno Haible  <bruno@clisp.org>
36156         asyncsafe-spin: New module.
36157         * lib/asyncsafe-spin.h: New file.
36158         * lib/asyncsafe-spin.c: New file, based on lib/pthread-spin.c.
36159         * modules/asyncsafe-spin: New file.
36161 2020-07-01  Bruno Haible  <bruno@clisp.org>
36163         windows-spin: Fix race condition on multiprocessor systems.
36164         * lib/windows-spin.c (glwthread_spin_init): Add a memory barrier.
36166 2020-07-01  Bruno Haible  <bruno@clisp.org>
36168         pthread-spin: Add optimized fallback for GCC versions >= 4.1, < 4.7.
36169         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
36170         pthread_spin_trylock, pthread_spin_unlock): For GCC >= 4.1, < 4.7, use
36171         an implementation based on other GCC built-ins.
36173 2020-07-01  Bruno Haible  <bruno@clisp.org>
36175         pthread-spin: Optimize fallback for GCC versions >= 4.7.
36176         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
36177         pthread_spin_trylock, pthread_spin_unlock): Use a lock word instead of a
36178         lock byte.
36180 2020-07-01  Bruno Haible  <bruno@clisp.org>
36182         pthread-spin: Add error checking.
36183         * lib/pthread-spin.c: Include <stdbool.h>.
36184         (pthread_spin_init, pthread_spin_lock, pthread_spin_trylock,
36185         pthread_spin_unlock) [GCC>=4.7]: Prefer an implementation that verifies
36186         the unlocks.
36187         * modules/pthread-spin (Depends-on): Add stdbool.
36189 2020-07-01  Bruno Haible  <bruno@clisp.org>
36191         pthread-spin: Add tests.
36192         * tests/test-pthread-spin.c: New file, based on tests/test-lock.c.
36193         * modules/pthread-spin-tests: New file.
36195 2020-07-01  Bruno Haible  <bruno@clisp.org>
36197         tests: Reduce code duplication.
36198         * tests/atomic-int-posix.h: New file, extracted from
36199         tests/test-pthread-mutex.c.
36200         * tests/test-pthread-mutex.c: Include it. Remove the corresponding code.
36201         * tests/test-pthread-rwlock.c: Likewise.
36202         * modules/pthread-mutex-tests (Files): Add tests/atomic-int-posix.h.
36203         * modules/pthread-rwlock-tests (Files): Likewise.
36205 2020-07-01  Bruno Haible  <bruno@clisp.org>
36207         tests: Refactor.
36208         * tests/atomic-int-isoc.h: New file, extracted from tests/test-mtx.c.
36209         * tests/test-mtx.c: Include it. Remove the corresponding code.
36210         * modules/mtx-tests (Files): Add tests/atomic-int-isoc.h.
36212 2020-07-01  Bruno Haible  <bruno@clisp.org>
36214         tests: Refactor.
36215         * tests/atomic-int-gnulib.h: New file, extracted from tests/test-lock.c.
36216         * tests/test-lock.c: Include it. Remove the corresponding code.
36217         * modules/lock-tests (Files): Add tests/atomic-int-gnulib.h.
36219 2020-06-29  Bruno Haible  <bruno@clisp.org>
36221         sys_socket: Don't define socklen_t if it is already defined on mingw.
36222         Reported by Keith Marshall <keith.d.marshall@ntlworld.com> in
36223         <https://savannah.gnu.org/bugs/?57725>,
36224         by Rahul Das <bokul_4u@yahoo.com> in
36225         <https://lists.gnu.org/archive/html/bug-gnulib/2020-04/msg00081.html>,
36226         and by Eli Zaretskii <eliz@gnu.org> in
36227         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00068.html>.
36228         * lib/sys_socket.in.h (socklen_t): Remove definition.
36230 2020-06-29  Bruno Haible  <bruno@clisp.org>
36232         alloca-opt: Fix warning on mingw.
36233         Reported and solution by Eli Zaretskii <eliz@gnu.org> in
36234         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00069.html>.
36235         * lib/alloca.in.h: On mingw, include <alloca.h> and then test again
36236         whether alloca is defined.
36238 2020-06-28  Paul Eggert  <eggert@cs.ucla.edu>
36240         getrandom: do not depend on ‘open’ on mingw
36241         Similarly for at-internal, getloadavg.  These modules do not call
36242         the ‘open’ function when they are compiled on mingw.  On mingw,
36243         this avoids having to compile open.c when building Emacs, which
36244         does its own thing with ‘open’.
36245         * modules/at-internal, modules/getloadavg, modules/getrandom:
36246         (Depends-on): Don’t depend on ‘open’ on mingw.
36247         (Depends-on): Require AC_CANONICAL_HOST, for host_os.
36248         * modules/getloadavg (Depends-on):
36249         Depend on intprops, open, stdbool, stdlib only if compiling
36250         getloadavg.c.
36252 2020-06-28  Bruno Haible  <bruno@clisp.org>
36254         doc: Add a note about sigprocmask vs. pthread_sigmask.
36255         * doc/posix-functions/sigprocmask.texi: Add note.
36257 2020-06-28  Bruno Haible  <bruno@clisp.org>
36259         getrandom: Fix compilation errors on older versions of mingw.
36260         Reported by Eli Zaretskii <eliz@gnu.org> in
36261         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00059.html>.
36262         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Test whether <bcrypt.h> exists.
36263         * lib/getrandom.c: If <bcrypt.h> is not available, include <ntdef.h> and
36264         define/declare BCRYPT_ALG_HANDLE, BCRYPT_USE_SYSTEM_PREFERRED_RNG,
36265         BCryptGenRandom ourselves.
36267 2020-06-28  Bruno Haible  <bruno@clisp.org>
36269         clean-temp: Fix wrong errno in error message.
36270         * lib/clean-temp.c (create_temp_dir): Save errno around
36271         unblock_fatal_signals call.
36273 2020-06-27  Bruno Haible  <bruno@clisp.org>
36275         fatal-signal: Make multithread-safe.
36276         * lib/fatal-signal.c (at_fatal_signal): Don't free the old actions array.
36278 2020-06-27  Bruno Haible  <bruno@clisp.org>
36280         clean-temp: Don't force deletion of temporary files on native Windows.
36281         * lib/clean-temp.h (open_temp, fopen_temp): Add delete_on_close
36282         argument.
36283         * lib/clean-temp.c (open_temp, fopen_temp): Likewise.
36284         * NEWS: Mention the change.
36285         * lib/javacomp.c (write_temp_file): Update.
36287 2020-06-27  Bruno Haible  <bruno@clisp.org>
36289         fatal-signal: Make multithread-safe.
36290         * lib/fatal-signal.c: Include glthread/lock.h.
36291         (at_fatal_signal_lock): New variable.
36292         (at_fatal_signal): Use it.
36293         (fatal_signals_block_lock, fatal_signals_block_counter): New variables.
36294         (block_fatal_signals, unblock_fatal_signals): Use them.
36295         * modules/fatal-signal (Depends-on): Add lock.
36297 2020-06-27  Paul Eggert  <eggert@cs.ucla.edu>
36299         getloadavg: don’t depend on fopen-gnu
36300         This is for Emacs, which does not need fopen-gnu for anything else,
36301         and which would need it only on a NetBSD platform where getloadavg
36302         does not work (does that even happen?).
36303         * lib/getloadavg.c (getloadavg) [__NetBSD__]: Use open, not fopen.
36304         * modules/getloadavg (Depends-on): Remove fopen-gnu.
36306         * tests/test-getloadavg.c (main): Fix typo.
36308 2020-06-27  Bruno Haible  <bruno@clisp.org>
36310         tempname et al.: Fix link errors on MSVC (regression from 2020-05-31).
36311         * modules/tempname (Link): New section.
36312         * modules/mkdtemp (Link): Likewise.
36313         * modules/clean-temp (Link): Likewise.
36314         * modules/mkstemp (Link): Likewise.
36315         * modules/stdlib-safer (Link): Likewise.
36316         * modules/mkstemps (Link): Likewise.
36317         * modules/mkostemp (Link): Likewise.
36318         * modules/mkostemps (Link): Likewise.
36319         * modules/tmpfile (Link): Likewise.
36320         * modules/tmpfile-safer (Link): Likewise.
36321         * modules/javacomp (Link): Add $(LIB_GETRANDOM).
36322         * modules/argv-iter-tests (Makefile.am): Link test-argv-iter with
36323         $(LIB_GETRANDOM).
36324         * NEWS: Mention the changes.
36326 2020-06-27  Bruno Haible  <bruno@clisp.org>
36328         fopen-gnu: Simplify code.
36329         * lib/fopen.c: Include <stdbool.h>.
36330         (rpl_fopen): Use a single variable open_flags instead of
36331         open_flags_standard and open_flags_gnu. Make open_flags_gnu a bool.
36332         * modules/fopen (Depends-on): Add stdbool.
36334 2020-06-26  Bruno Haible  <bruno@clisp.org>
36336         canonicalize: Improve documentation.
36337         * lib/canonicalize.h (canonicalize_filename_mode): Document the failure
36338         return convention.
36340 2020-06-26  Bruno Haible  <bruno@clisp.org>
36342         xgetcwd: Improve documentation.
36343         * lib/xgetcwd.c (xgetcwd): Document the failure return convention.
36345 2020-06-26  Bruno Haible  <bruno@clisp.org>
36347         getcwd: Improve documentation.
36348         * lib/getcwd.c (__getcwd): Document the failure return convention.
36350 2020-06-26  Bruno Haible  <bruno@clisp.org>
36352         fchdir: Improve documentation.
36353         * lib/fchdir.c (get_name, _gl_register_fd): Document the failure return
36354         convention.
36356 2020-06-26  Bruno Haible  <bruno@clisp.org>
36358         filenamecat-lgpl: Set errno upon failure.
36359         * lib/filenamecat-lgpl.c (mfile_name_concat): Document the failure
36360         return convention.
36361         * modules/filenamecat-lgpl (Depends-on): Add malloc-posix.
36363 2020-06-26  Bruno Haible  <bruno@clisp.org>
36365         areadlink-with-size: Set errno upon failure.
36366         * lib/areadlink-with-size.c (areadlink_with_size): Set errno when malloc
36367         fails.
36368         * lib/areadlinkat-with-size.c (areadlinkat_with_size): Add comment.
36370 2020-06-26  Bruno Haible  <bruno@clisp.org>
36372         copy-file: Shrink dependencies.
36373         * modules/copy-file (Depends-on): Remove acl. Add acl-permissions,
36374         qcopy-acl.
36376 2020-06-26  Bruno Haible  <bruno@clisp.org>
36378         doc: Mention declaration fixes implemented by some modules.
36379         * doc/posix-functions/chdir.texi: Mention the module 'chdir'.
36380         * doc/posix-functions/close.texi: Mention that Gnulib makes the function
36381         declaration appear in <unistd.h>.
36382         * doc/posix-functions/dup.texi: Likewise.
36383         * doc/posix-functions/dup2.texi: Likewise.
36384         * doc/posix-functions/gethostname.texi: Likewise.
36385         * doc/posix-functions/isatty.texi: Likewise.
36386         * doc/posix-functions/lseek.texi: Likewise.
36387         * doc/posix-functions/unlink.texi: Likewise.
36388         * doc/posix-functions/read.texi: Mention the module 'read'.
36389         * doc/posix-functions/write.texi: Mention the effects of the module
36390         'write'.
36392 2020-06-25  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
36394         c-dtoastr, c-ldtoastr: new modules
36395         These modules provide the same functionality as the modules
36396         dtoastr and ldtoastr except for the formatting taking place in the
36397         C locale.
36398         * MODULES.html.sh: Add c-dtoastr and c-ldtoastr.
36399         * lib/c-dtoastr.c, lib/c-ldtoastr.c: New files.
36400         * lib/ftoastr.c: Prefix exported functions when the macro C_LOCALE is
36401         defined.  Use c_snprintf and c_strtod/c_strtold instead of
36402         snprintf and strtod/strtold whhen the macro C_LOCALE is defined.
36403         * lib/ftoastr.h: Add prototypes for c_dtoastr and c_ldtoastr.
36404         * modules/c-dtoastr, modules/c-dtoastr-tests, modules/c-ldtoastr,
36405         modules/c-ldtoastr-tests: New files.
36406         * tests/test-c-dtoastr.c, tests/test-c-dtoastr.sh,
36407         tests-c-ldtoastr.c tests-c-ldtoastr.sh: New files.
36409 2020-06-21  Bruno Haible  <bruno@clisp.org>
36411         tzset: Fix compilation warnings on mingw (regression from 2017-05-01).
36412         * lib/tzset.c: Include <stdlib.h>, <string.h>.
36414 2020-06-16  Bruno Haible  <bruno@clisp.org>
36416         thread: Avoid possible compiler warnings in uses of gl_thread_exit.
36417         * lib/glthread/thread.h (gl_thread_exit): Add a cast to void.
36419 2020-06-16  Bruno Haible  <bruno@clisp.org>
36421         thread, thrd: Avoid a compiler warning.
36422         * lib/windows-thread.h (glwthread_thread_exit): Mark as non-returning.
36424 2020-06-16  Biswapriyo Nath  <nathbappai@gmail.com>  (tiny change)
36426         windows-thread: Avoid a compiler warning.
36427         * lib/windows-thread.h (glwthread_thread_exit): Change return type to
36428         void.
36429         * lib/windows-thread.c (glwthread_thread_exit): Likewise.
36431 2020-06-15  Bruno Haible  <bruno@clisp.org>
36433         unictype/joininggroup-name: Fix warning on 64-bit mingw.
36434         Reported by Biswapriyo Nath <nathbappai@gmail.com> in
36435         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00036.html>.
36436         * lib/unictype/joininggroup_name.c (ELEM): Cast struct offset to size_t
36437         first.
36439 2020-06-06  Bruno Haible  <bruno@clisp.org>
36441         calloc-gnu tests: Avoid a test failure with clang.
36442         * tests/test-calloc-gnu.c (main): Mark the pointer variable as
36443         'volatile', to defeat compiler optimizations.
36445 2020-06-01  Paul Eggert  <eggert@cs.ucla.edu>
36447         getloadavg: fix double-increment bug
36448         * lib/getloadavg.c (getloadavg): Fix double-increment typo on
36449         Linux without glibc, Android, Cygwin.  This fixes a bug I
36450         introduced in 2011-02-08T20:23:29Z!eggert@cs.ucla.edu.
36451         Problem and fix reported by Semen Verchenko in:
36452         https://lists.gnu.org/r/bug-gnulib/2020-06/msg00007.html
36454         tempname: use getrandom, not getentropy
36455         This removes a dependency, as getentropy depends on getrandom.
36456         * lib/tempname.c: Include sys/random.h instead of unistd.h.
36457         (RANDOM_BITS) [!_LIBC]: Use getrandom, not getentropy.
36458         * modules/tempname (Depends-on): Depend on getrandom, not getentropy.
36460 2020-06-01  Bruno Haible  <bruno@clisp.org>
36462         doc: New chapter 'Multithreading'.
36463         * doc/multithread.texi: New file.
36464         * doc/gnulib.texi: Include it.
36466 2020-06-01  Bruno Haible  <bruno@clisp.org>
36468         doc: Move 'Running self-tests under valgrind' section.
36469         * doc/gnulib.texi (Build Infrastructure Modules): Include
36470         valgrind-tests.texi here...
36471         (Miscellaneous Notes): ... not here.
36473 2020-06-01  Bruno Haible  <bruno@clisp.org>
36475         doc: Move 'Visual Studio Compatibility' section.
36476         * doc/gnulib.texi (Native Windows Support): Include ld-output-def.texi
36477         here...
36478         (Build Infrastructure Modules): ... not here.
36480 2020-06-01  Paul Eggert  <eggert@cs.ucla.edu>
36482         doc: improve randomness discussion
36483         Inspired by comments from Jeffrey Walton in:
36484         https://lists.gnu.org/r/bug-gnulib/2020-06/msg00002.html
36485         * doc/glibc-functions/getentropy.texi (getentropy):
36486         * doc/glibc-functions/getrandom.texi (getrandom):
36487         Improve discussion of problems with "random" data,
36488         and cite Ristenpart & Yilek.  Also, mention GRND_INSECURE.
36490 2020-06-01  Bruno Haible  <bruno@clisp.org>
36492         doc: Fix Texinfo syntax error.
36493         * doc/glibc-functions/getrandom.texi: Add missing '@item'.
36495 2020-06-01  Asher Gordon  <AsDaGo@posteo.net>
36497         doc: Change '.' to '@.' where appropriate.
36498         * doc/c-ctype.texi: Change '.' to '@.' where appropriate.
36499         * doc/glibc-functions/fstatfs.texi: Likewise.
36500         * doc/glibc-functions/fts_children.texi: Likewise.
36501         * doc/glibc-functions/fts_read.texi: Likewise.
36502         * doc/glibc-functions/getdirentries.texi: Likewise.
36503         * doc/glibc-functions/mkostemp.texi: Likewise.
36504         * doc/glibc-functions/mkostemps.texi: Likewise.
36505         * doc/glibc-functions/mkstemps.texi: Likewise.
36506         * doc/glibc-functions/preadv.texi: Likewise.
36507         * doc/glibc-functions/pwritev.texi: Likewise.
36508         * doc/glibc-functions/sendfile.texi: Likewise.
36509         * doc/glibc-functions/statfs.texi: Likewise.
36510         * doc/gnulib-intro.texi: Likewise.
36511         * doc/gnulib-tool.texi: Likewise.
36512         * doc/intprops.texi: Likewise.
36513         * doc/lib-symbol-visibility.texi: Likewise.
36514         * doc/licenses-texi.texi: Likewise.
36515         * doc/pastposix-functions/bcmp.texi: Likewise.
36516         * doc/pastposix-functions/bcopy.texi: Likewise.
36517         * doc/pastposix-functions/bzero.texi: Likewise.
36518         * doc/pastposix-functions/ecvt.texi: Likewise.
36519         * doc/pastposix-functions/fcvt.texi: Likewise.
36520         * doc/pastposix-functions/ftime.texi: Likewise.
36521         * doc/pastposix-functions/gcvt.texi: Likewise.
36522         * doc/pastposix-functions/getwd.texi: Likewise.
36523         * doc/pastposix-functions/index.texi: Likewise.
36524         * doc/pastposix-functions/mktemp.texi: Likewise.
36525         * doc/pastposix-functions/rindex.texi: Likewise.
36526         * doc/pastposix-functions/wcswcs.texi: Likewise.
36527         * doc/posix-functions/aio_cancel.texi: Likewise.
36528         * doc/posix-functions/aio_error.texi: Likewise.
36529         * doc/posix-functions/aio_fsync.texi: Likewise.
36530         * doc/posix-functions/aio_read.texi: Likewise.
36531         * doc/posix-functions/aio_return.texi: Likewise.
36532         * doc/posix-functions/aio_suspend.texi: Likewise.
36533         * doc/posix-functions/aio_write.texi: Likewise.
36534         * doc/posix-functions/creat.texi: Likewise.
36535         * doc/posix-functions/ctime.texi: Likewise.
36536         * doc/posix-functions/daylight.texi: Likewise.
36537         * doc/posix-functions/fgetpos.texi: Likewise.
36538         * doc/posix-functions/fopen.texi: Likewise.
36539         * doc/posix-functions/freopen.texi: Likewise.
36540         * doc/posix-functions/fseeko.texi: Likewise.
36541         * doc/posix-functions/fsetpos.texi: Likewise.
36542         * doc/posix-functions/fstatat.texi: Likewise.
36543         * doc/posix-functions/fstatvfs.texi: Likewise.
36544         * doc/posix-functions/ftello.texi: Likewise.
36545         * doc/posix-functions/ftruncate.texi: Likewise.
36546         * doc/posix-functions/getrlimit.texi: Likewise.
36547         * doc/posix-functions/lio_listio.texi: Likewise.
36548         * doc/posix-functions/localtime.texi: Likewise.
36549         * doc/posix-functions/lseek.texi: Likewise.
36550         * doc/posix-functions/mkstemp.texi: Likewise.
36551         * doc/posix-functions/mktime.texi: Likewise.
36552         * doc/posix-functions/open.texi: Likewise.
36553         * doc/posix-functions/openat.texi: Likewise.
36554         * doc/posix-functions/opendir.texi: Likewise.
36555         * doc/posix-functions/pread.texi: Likewise.
36556         * doc/posix-functions/pwrite.texi: Likewise.
36557         * doc/posix-functions/readdir.texi: Likewise.
36558         * doc/posix-functions/readdir_r.texi: Likewise.
36559         * doc/posix-functions/scandir.texi: Likewise.
36560         * doc/posix-functions/seekdir.texi: Likewise.
36561         * doc/posix-functions/setrlimit.texi: Likewise.
36562         * doc/posix-functions/statvfs.texi: Likewise.
36563         * doc/posix-functions/strftime.texi: Likewise.
36564         * doc/posix-functions/telldir.texi: Likewise.
36565         * doc/posix-functions/timezone.texi: Likewise.
36566         * doc/posix-functions/tmpfile.texi: Likewise.
36567         * doc/posix-functions/truncate.texi: Likewise.
36568         * doc/posix-functions/tzname.texi: Likewise.
36569         * doc/posix-functions/wcsftime.texi: Likewise.
36570         * doc/windows-sockets.texi: Likewise.
36572 2020-05-31  Paul Eggert  <eggert@cs.ucla.edu>
36574         getrandom-tests: do not assume GRND_RANDOM yields short read
36575         * tests/test-getrandom.c (main): Omit assertion that
36576         getrandom (b, sizeof b, GRND_RANDOM | GRND_NONBLOCK) < sizeof b
36577         when b’s size is 100000.  This assertion fails with Linux kernel
36578         5.6.13, as that kernel ignores the GRND_RANDOM flag.
36579         The separate blocking pool is going away in the Linux kernel, and
36580         they’ve added a flag GRND_INSECURE instead; see:
36581         https://lore.kernel.org/linux-api/705c5a091b63cc5da70c99304bb97e0109be0a26.1577088521.git.luto@kernel.org/
36582         The assertion was iffy anyway; what’s to prevent a kernel from
36583         lazily filling a large buffer with random bytes?
36585         read-file-test: pacify --enable-gcc-warnings
36586         * tests/test-read-file.c (test_read_file): Now static.
36588         tempname: merge from glibc and coreutils
36589         Also, merge in Gnulib’s more-recent methods of making it easier
36590         to share between Gnulib and glibc, and fix a few randomness
36591         glitches.
36592         * lib/tempname.c: Include libc-config.h, not config.h, if !_LIBC.
36593         (__set_errno): Remove; libc-config.h does that for us.
36594         Do not include <sys/time.h>.
36595         (__secure_getenv) [_LIBC]: New macro.
36596         (__try_tempname, __getpid, __gettimeofday) [!_LIBC]: Remove macros.
36597         (RANDOM_BITS): Rewrite.
36598         (RANDOM_VALUE_MAX, BASE_62_DIGITS, BASE_62_POWER): New macros.
36599         (random_value): New typedef.
36600         (try_file, try_dir, try_nocreate): Move up.
36601         (gen_tempname_len, try_tempname_len): New functions.
36602         (gen_tempname_len): Use a constant array rather than a switch.
36603         (try_tempname_len): Don’t assume string length fits in int.
36604         Generalize use of RANDOM_BITS.  If _LIBC, don’t assume RANDOM_BITS
36605         has enough entropy (it’s a bit short).
36606         (__gen_tempname): Rewrite in terms of gen_tempname_len.
36607         (__try_tempname): Rewrite in terms of try_tempname_len.
36608         * lib/tempname.h (gen_tempname_len, try_tempname_len): New decls.
36609         * modules/tempname (Depends-on): Remove gettimeofday, sys_time.
36610         Add getentropy, libc-config.
36612 2020-05-31  Bruno Haible  <bruno@clisp.org>
36614         getrandom, getentropy: Mention the crypto/gc-random module.
36615         Suggested by Simon Josefsson in
36616         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00400.html>.
36617         * doc/glibc-functions/getrandom.texi: Mention the quality issues and the
36618         crypto/gc-random module.
36619         * doc/glibc-functions/getentropy.texi: Likewise.
36621 2020-05-31  Bruno Haible  <bruno@clisp.org>
36623         getentropy: Enhance tests.
36624         * tests/test-getentropy.c (main): Add one more test.
36625         * tests/test-unistd-c++.cc: Check the signature of getentropy.
36627 2020-05-31  Bruno Haible  <bruno@clisp.org>
36629         getentropy: Work around a macOS and Solaris problem.
36630         * lib/unistd.in.h: Include <sys/random.h>, when needed for the
36631         'getentropy' module.
36632         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
36633         UNISTD_H_HAVE_SYS_RANDOM_H.
36634         * m4/sys_random_h.m4 (gl_HEADER_SYS_RANDOM): Set
36635         UNISTD_H_HAVE_SYS_RANDOM_H.
36636         * modules/unistd (Makefile.am): Substitute UNISTD_H_HAVE_SYS_RANDOM_H.
36637         * doc/glibc-functions/getentropy.texi: Document the macOS and Solaris
36638         problem. List more platforms.
36640 2020-05-31  Paul Eggert  <eggert@cs.ucla.edu>
36642         fnmatch: merge from glibc
36643         Also, merge in Gnulib’s more-recent methods of making it easier
36644         to share between Gnulib and glibc.
36645         * lib/fnmatch.c: Reorder includes to match glibc better.
36646         Include libc-config.h instead of config.h.
36647         Include alloca.h only if _LIBC || HAVE_ALLOCA.
36648         Do not include "../locale/elem-hash.h" if _LIBC.
36649         Define macros for btowc, etc. if _LIBC.  All uses simplified.
36650         Define FALLTHROUGH if _LIBC, instead of including attribute.h.
36651         Include intprops.h, since glibc has it now.
36652         (SIZE_MAX): Remove; use (size_t) -1 instead.
36653         Omit the "Comment out all this code" ifdef, since Gnulib
36654         has never really needed it.
36655         (STREQ): Remove; no longer used.
36656         (__libc_use_alloca, alloca, alloca_account): Define as
36657         needed if !_LIBC.
36658         (ISWCTYPE): Remove; all uses replaced by iswctype.
36659         (HANDLE_MULTIBYTE): Remove.  All uses removed by assuming true.
36660         (internal_function): Remove.  All uses removed.
36661         (STRUCT): New macro.
36662         (WIDE_CHAR_VERSION): Define to 0 instead of leaving undefined.
36663         (WMEMCMP): New macro.
36664         (FINDIDX): Define if _LIBC, and include <locale/weight.h>
36665         and <locale/weightwc.h>.
36666         (fnmatch): Prefer __glibc_likely and __glibc_unlikely to
36667         __builtin_expect.  Check for integer overflow more
36668         systematically.  Account for alloca storage better when
36669         recursive.  Use strnlen instead of strlen for efficiency.
36670         * lib/fnmatch_loop.c: Include stdint.h if _LIBC, for int32_t etc.
36671         (struct STRUCT): New type.
36672         (FCT, EXT): New ENDS and ALLOCA_USED args.
36673         All callers changed.
36674         (FCT): Prefer __glibc_unlikely to __builtin_expect.
36675         Simplify by assuming WIDE_CHAR_SUPPORT.
36676         Copy _LIBC code from glibc without worrying Gnulib compatibility.
36677         Cast cold to UCHAR to avoid signedness warning.
36678         (END): Check for invalid pattern.
36679         (EXT): Improve alloca/malloc checking (taken from glibc),
36680         and improve it some more by using intprops.h and checking
36681         for integer overflow and using bool for booleans.
36682         * lib/libc-config.h (compat_symbol): New macro.
36683         (versioned_symbol): Make it ‘extern int dummy’ so that it’s
36684         acceptable to non-GCC when a trailing semicolon is added.
36685         * modules/fnmatch (Depends-on): Add alloca-opt, intprops,
36686         libc-config, strnlen.  Remove alloca.
36688 2020-05-31  Bruno Haible  <bruno@clisp.org>
36690         getrandom: Doc and test tweaks.
36691         * lib/getrandom.c (getrandom): Mention that it never returns 0, and that
36692         it sets errno when failing.
36693         * tests/test-getrandom.c (main): Disable the high-quality check on those
36694         platforms on which it fails.
36695         * doc/glibc-functions/getrandom.texi: Add Minix, AIX, HP-UX, IRIX,
36696         Cygwin to the list of platforms that don't have the function. Add a note
36697         about the quality of the result.
36698         * doc/glibc-headers/sys_random.texi: Don't mention the 'getrandom'
36699         declaration; this is fixed by module 'getrandom'.
36701 2020-05-31  Bruno Haible  <bruno@clisp.org>
36703         getrandom: Add support for native Windows.
36704         * lib/getrandom.c: Include <errno.h>, <windows.h>, <bcrypt.h>,
36705         <wincrypt.h>.
36706         (CRYPT_VERIFY_CONTEXT): New macro.
36707         (LoadLibrary, CryptAcquireContext): Redirect to the variant with suffix
36708         'A'.
36709         (GetProcAddress): New macro.
36710         (BCryptGenRandomFuncType): New type.
36711         (BCryptGenRandomFunc, initialized): New variables.
36712         (initialize): New function.
36713         (getrandom): On native Windows, use <bcrypt.h> API when available, and
36714         <wincrypt.h> API as fallback.
36715         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Set LIB_GETRANDOM.
36716         * modules/getrandom (Link): New section.
36717         * modules/getentropy (Link): Likewise.
36718         * modules/getrandom-tests (Makefile.am): Link test-getrandom against
36719         $(LIB_GETRANDOM).
36720         * modules/getentropy-tests (Makefile.am): Link test-getentropy against
36721         $(LIB_GETRANDOM).
36722         * modules/sys_random-c++-tests (Makefile.am): Link test-sys_random-c++
36723         against $(LIB_GETRANDOM).
36724         * doc/glibc-functions/getrandom.texi: Mention the native Windows
36725         support.
36727 2020-05-31  Bruno Haible  <bruno@clisp.org>
36729         getrandom: Simplify the determination of the random number devices.
36730         Suggested by Paul Eggert in
36731         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00383.html>.
36732         * lib/getrandom.c (NAME_OF_RANDOM_DEVICE, NAME_OF_NONCE_DEVICE): New
36733         macros.
36734         * modules/getrandom (Depends-on): Remove crypto/gc-random.
36736 2020-05-31  Bruno Haible  <bruno@clisp.org>
36738         crypto/gc-random: Fix list of crypto devices for Solaris.
36739         * m4/gc-random.m4 (gl_GC_RANDOM): Don't special-case Solaris.
36741 2020-05-31  Akim Demaille  <akim@lrde.epita.fr>
36743         list: fix GCC warnings
36744         * lib/gl_anytree_list2.h (gl_tree_iterator_free)
36745         (gl_tree_next_node, gl_tree_node_nx_set_value)
36746         (gl_tree_previous_node, gl_tree_next_node):
36747         Mark unused arguments.
36748         * lib/gl_anytree_oset.h (gl_tree_iterator_free): Likewise.
36749         * lib/gl_anylinked_list2.h (gl_linked_node_value)
36750         (gl_linked_node_nx_set_value, gl_linked_iterator_free): Likewise.
36752         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Avoid using
36753         the same variable name in nested scopes.
36755 2020-05-31  Bruno Haible  <bruno@clisp.org>
36757         list-c++, set-c++, oset-c++, map-c++, omap-c++: Don't fool the compiler.
36758         Reported by Akim Demaille in
36759         <https://lists.gnu.org/archive/html/bug-bison/2020-05/msg00102.html>.
36760         * lib/gl_list.hh (gl_List::iterator::next): Avoid a reinterpret_cast.
36761         * lib/gl_set.hh (gl_Set::iterator::next): Likewise.
36762         * lib/gl_oset.hh (gl_OSet::iterator::next): Likewise.
36763         * lib/gl_map.hh (gl_Map::iterator::next): Likewise.
36764         * lib/gl_omap.hh (gl_OMap::iterator::next): Likewise.
36766 2020-05-30  Bruno Haible  <bruno@clisp.org>
36768         wmemchr: Relicense under LGPLv2+.
36769         * modules/wmemchr (License): Set to LGPLv2+.
36771 2020-05-30  Bruno Haible  <bruno@clisp.org>
36773         wmempcpy: New module.
36774         Reported by Paul Eggert in
36775         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00387.html>.
36776         * lib/wchar.in.h (wmempcpy): New declaration.
36777         * lib/wmempcpy.c: New file.
36778         * m4/wmempcpy.m4: New file.
36779         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmempcpy is declared.
36780         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMPCPY, HAVE_WMEMPCPY.
36781         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMPCPY,
36782         HAVE_WMEMPCPY.
36783         * modules/wmempcpy: New file.
36784         * tests/test-wchar-c++.cc: Check the signature of wmempcpy.
36785         * doc/glibc-functions/wmempcpy.texi: Mention the new module.
36786         * modules/mempcpy (Description): Fix typo.
36788 2020-05-30  Bruno Haible  <bruno@clisp.org>
36790         crypto/gc-random: Fix list of crypto devices for NetBSD, OpenBSD.
36791         * m4/gc-random.m4 (gl_GC_RANDOM): Don't special-case NetBSD and OpenBSD.
36793 2020-05-30  Bruno Haible  <bruno@clisp.org>
36795         sys_random: Work around macOS bug.
36796         * m4/sys_random_h.m4 (gl_HEADER_SYS_RANDOM): Include <sys/types.h> and
36797         <stdlib.h> before <sys/random.h>.
36798         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
36799         * lib/sys_random.in.h: On macOS, include <sys/types.h> and <stdlib.h>
36800         first.
36801         * doc/glibc-headers/sys_random.texi: Mention the macOS problem.
36803 2020-05-30  Bruno Haible  <bruno@clisp.org>
36805         getrandom: Override incompatible system function on Solaris 11.
36806         * lib/sys_random.in.h (getrandom): Override if REPLACE_GETRANDOM is 1.
36807         * lib/getrandom.c (getrandom): When the system has getrandom, just
36808         invoke it.
36809         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Set REPLACE_GETRANDOM if the
36810         system's getrandom function's prototype is not the expected one.
36811         * m4/sys_random_h.m4 (gl_SYS_RANDOM_H_DEFAULTS): Initialize
36812         REPLACE_GETRANDOM.
36813         * modules/sys_random (Makefile.am): Substitute REPLACE_GETRANDOM.
36814         * modules/getrandom (modules/getrandom): Consider REPLACE_GETRANDOM.
36815         * tests/test-getrandom.c (main): Allow error EINVAL as an alternative to
36816         EAGAIN.
36817         * doc/glibc-functions/getrandom.texi: Mention the new module and the
36818         Solaris problem.
36820 2020-05-30  Bruno Haible  <bruno@clisp.org>
36822         sys_random: Add C++ tests.
36823         * tests/test-sys_random-c++.cc: New file.
36824         * modules/sys_random-c++-tests: New file.
36825         * modules/sys_random-tests (Depends-on): Depend on it.
36827         sys_random: Add tests.
36828         * tests/test-sys_random.c: New file.
36829         * modules/sys_random-tests: New file.
36831         sys_random: New module.
36832         * lib/sys_random.in.h: Use the common idioms for overridable header
36833         files.
36834         * m4/sys_random_h.m4: New file.
36835         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Require gl_SYS_RANDOM_H_DEFAULTS.
36836         * modules/sys_random: New file.
36837         * modules/getrandom (Files): Remove lib/sys_random.in.h.
36838         (Depends-on): Add sys_random.
36839         (configure.ac): Use gl_SYS_RANDOM_MODULE_INDICATOR, not
36840         gl_UNISTD_MODULE_INDICATOR.
36841         (Makefile.am): Don't generate sys/random.h here.
36842         * doc/glibc-headers/sys_random.texi: New file.
36843         * doc/gnulib.texi: Include it.
36845 2020-05-30  Bruno Haible  <bruno@clisp.org>
36847         unistd: Remove conflicting declaration of getrandom().
36848         * lib/unistd.in.h (getrandom): Remove declaration.
36849         * m4/unistd_h.m4 (gl_UNISTD_H): Don't test whether getrandom is
36850         declared.
36851         (gl_UNISTD_H_DEFAULTS): Don't initialize GNULIB_GETRANDOM,
36852         HAVE_GETRANDOM.
36853         * modules/unistd (Makefile.am): Don't substitute GNULIB_GETRANDOM,
36854         HAVE_GETRANDOM.
36856 2020-05-30  Bruno Haible  <bruno@clisp.org>
36858         getrandom: Add tests.
36859         * tests/test-getrandom.c: New file.
36860         * modules/getrandom-tests: New file.
36862 2020-05-30  Bruno Haible  <bruno@clisp.org>
36864         crypto/gc-random: Fix link error on MSVC.
36865         * m4/gc-random.m4 (gl_GC_RANDOM): Set LIB_GC_RANDOM.
36866         * modules/crypto/gc-random (Link): New section.
36867         * modules/crypto/gc-tests (Makefile.am): Link test-gc against
36868         $(LIB_GC_RANDOM).
36870 2020-05-30  Bruno Haible  <bruno@clisp.org>
36872         Don't assume that UNICODE is not defined.
36873         Many Windows API functions are defined differently (redirecting to a
36874         function with suffix 'W') if the application defines the macro UNICODE
36875         than by default (redirecting to a function with suffix 'A').
36876         * lib/clean-temp.c (OSVERSIONINFO, GetVersionEx): Redirect to the
36877         variant with suffix 'A'.
36878         * lib/dirent-private.h (WIN32_FIND_DATA): Likewise.
36879         * lib/gc-gnulib.c (CryptAcquireContext): Likewise.
36880         * lib/getaddrinfo.c (GetModuleHandle): Likewise.
36881         * lib/getlogin.c (GetUserName): Likewise.
36882         * lib/getlogin_r.c (GetUserName): Likewise.
36883         * lib/gettimeofday.c (LoadLibrary): Likewise.
36884         * lib/isatty.c (LoadLibrary, QueryFullProcessImageName): Likewise.
36885         * lib/link.c (GetModuleHandle, CreateHardLink): Likewise.
36886         * lib/localename.c (GetLocaleInfo, EnumSystemLocales): Likewise.
36887         * lib/mountlist.c (GetDriveType): Likewise.
36888         * lib/nonblocking.c (GetNamedPipeHandleState): Likewise.
36889         * lib/opendir.c (WIN32_FIND_DATA, GetFullPathName, FindFirstFile):
36890         Likewise.
36891         * lib/physmem.c (GetModuleHandle): Likewise.
36892         * lib/poll.c (GetModuleHandle, PeekConsoleInput, CreateEvent,
36893         PeekMessage, DispatchMessage): Likewise.
36894         * lib/progreloc.c (GetModuleFileName): Likewise.
36895         * lib/putenv.c (SetEnvironmentVariable): Likewise.
36896         * lib/read.c (GetNamedPipeHandleState): Likewise.
36897         * lib/readdir.c (FindNextFile): Likewise.
36898         * lib/relocatable.c (GetModuleFileName): Likewise.
36899         * lib/rename.c (MoveFileEx): Likewise.
36900         * lib/rewinddir.c (FindFirstFile): Likewise.
36901         * lib/select.c (GetModuleHandle, PeekConsoleInput, CreateEvent,
36902         PeekMessage, DispatchMessage): Likewise.
36903         * lib/sethostname.c (GetComputerNameEx, SetComputerNameEx): Likewise.
36904         * lib/socket.c (WSASocket): Likewise.
36905         * lib/stat-w32.c (LoadLibrary, GetFinalPathNameByHandle): Likewise.
36906         * lib/stat.c (WIN32_FIND_DATA, CreateFile, FindFirstFile): Likewise.
36907         * lib/stdio-read.c (GetNamedPipeHandleState): Likewise.
36908         * lib/stdio-write.c (GetNamedPipeHandleState): Likewise.
36909         * lib/tmpdir.c (GetTempPath): Likewise.
36910         * lib/tmpfile.c (OSVERSIONINFO, GetVersionEx, GetTempPath): Likewise.
36911         * lib/uname.c (OSVERSIONINFO, GetVersionEx): Likewise.
36912         * lib/utime.c (CreateFile, GetFileAttributes): Likewise.
36913         * lib/windows-cond.c (CreateEvent): Likewise.
36914         * lib/windows-rwlock.c (CreateEvent): Likewise.
36915         * lib/windows-timedmutex.c (CreateEvent): Likewise.
36916         * lib/windows-timedrecmutex.c (CreateEvent): Likewise.
36917         * lib/windows-timedrwlock.c (CreateEvent): Likewise.
36918         * lib/write.c (GetNamedPipeHandleState): Likewise.
36920 2020-05-30  Bruno Haible  <bruno@clisp.org>
36922         physmem: Fix compilation errors on MSVC.
36923         * lib/physmem.c (PFN_MS_EX): Use BOOL, not WINBOOL.
36924         * modules/physmem (Depends-on): Add unistd.
36926 2020-05-29  Bruno Haible  <bruno@clisp.org>
36928         gnulib-tool: Fix link errors with a particular set of modules on mingw.
36929         * gnulib-tool (func_emit_tests_Makefile_am): Add ../lib/libgnu.a to
36930         LDADD a second time, after the second occurrence of libtests.a.
36931         * pygnulib/GLEmiter.py (tests_Makefile_am): Likewise.
36933 2020-05-29  Bruno Haible  <bruno@clisp.org>
36935         fnmatch: Rely on more gnulib modules.
36936         * modules/fnmatch (Depends-on): Add btowc, isblank, iswctype, wmemchr,
36937         wmempcpy, mempcpy.
36938         * lib/fnmatch.c: Assume that HAVE_WCTYPE_H, HAVE_BTOWC, HAVE_ISWCTYPE,
36939         HAVE_WMEMCHR, HAVE_WMEMPCPY, HAVE_ISBLANK, HAVE_DECL_ISBLANK,
36940         HAVE_MEMPCPY are all 1.
36941         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): Don't test for btowc, isblank,
36942         iswctype, mempcpy, wmemchr, wmemcpy, wmempcpy, <wctype.h>.
36944 2020-05-29  Bruno Haible  <bruno@clisp.org>
36946         Avoid dynamic lookup of Windows API functions when possible.
36947         * lib/getaddrinfo.c (GetProcAddress, getaddrinfo_func,
36948         freeaddrinfo_func, getnameinfo_func, getaddrinfo_ptr, freeaddrinfo_ptr,
36949         getnameinfo_ptr): Don't define in a build for Windows XP or higher.
36950         (use_win32_p): Define differently.
36951         * lib/link.c (GetProcAddress, CreateHardLinkFuncType,
36952         CreateHardLinkFunc, initialized, initialize): Don't define in a build
36953         for Windows XP or higher.
36955 2020-05-29  Daiki Ueno  <ueno@gnu.org>
36957         read-file: disable buffering if RF_SENSITIVE is set
36958         * lib/read-file.c (read_file): Call setvbuf if RF_SENSITIVE.
36959         Suggested by Glenn Strauss.
36960         (fread_file): Suggest calling setvbuf before calling this
36961         function.  Suggested by Bruno Haible.
36963 2020-05-29  Bruno Haible  <bruno@clisp.org>
36965         wmemchr, wmemcmp, wmemcpy, wmemmove, wmemset: Fix autoconf test.
36966         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Link, not only compile, the test
36967         program.
36968         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Likewise.
36969         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Likewise.
36970         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Likewise.
36971         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Likewise.
36973 2020-05-29  Bruno Haible  <bruno@clisp.org>
36975         Fix compilation error on native Windows (regression from 2020-05-28).
36976         Reported by Daiki Ueno.
36977         * lib/gettimeofday.c (GetSystemTimePreciseAsFileTimeFunc): Define as
36978         macro when not using dynamic loading.
36979         * lib/isatty.c (GetNamedPipeClientProcessIdFunc,
36980         QueryFullProcessImageNameFunc): Likewise.
36981         * lib/stat-w32.c (GetFileInformationByHandleExFunc,
36982         GetFinalPathNameByHandleFunc): Likewise.
36984 2020-05-29  Daiki Ueno  <ueno@gnu.org>
36986         fopen-gnu-tests: fix "\x" escape usage
36987         * tests/test-fopen-gnu.c (DATA): Use safer escape sequence.
36989 2020-05-28  Bruno Haible  <bruno@clisp.org>
36991         Avoid dynamic loading of Windows API functions when possible.
36992         Reported by Steve Lhomme <robux4@ycbcr.xyz> in
36993         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00182.html>.
36994         * lib/gettimeofday.c (GetProcAddress,
36995         GetSystemTimePreciseAsFileTimeFuncType,
36996         GetSystemTimePreciseAsFileTimeFunc, initialized, initialize): Don't
36997         define in a build for Windows 8 or higher.
36998         * lib/isatty.c (GetProcAddress, GetNamedPipeClientProcessIdFuncType,
36999         GetNamedPipeClientProcessIdFunc, QueryFullProcessImageNameFuncType,
37000         QueryFullProcessImageNameFunc, initialized, initialize): Don't define
37001         in a build for Windows Vista or higher.
37002         * lib/stat-w32.c (GetProcAddress, GetFileInformationByHandleExFuncType,
37003         GetFileInformationByHandleExFunc, GetFinalPathNameByHandleFuncType,
37004         GetFinalPathNameByHandleFunc, initialized, initialize): Likewise.
37006 2020-05-28  Paul Eggert  <eggert@cs.ucla.edu>
37008         explicit_bzero-tests: improve -Wmissing-declarations pacification
37009         * tests/test-explicit_bzero.c: Now noinline.
37010         Suggested by Bruno Haible in:
37011         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00300.html
37013 2020-05-28  Bruno Haible  <bruno@clisp.org>
37015         Fix build errors due to read-file changes (regression from 2020-05-27).
37016         * lib/git-merge-changelog.c (read_changelog_file): Update read_file
37017         invocation.
37018         * tests/test-sameacls.c (main): Likewise.
37019         * tests/test-pipe-filter-gi1.c (main): Call read_file instead of
37020         read_binary_file.
37021         * tests/test-pipe-filter-ii1.c (main): Likewise.
37023 2020-05-28  Bruno Haible  <bruno@clisp.org>
37025         fts: Make more robust in multithreaded applications.
37026         * lib/fts.c (fts_open): Pass an O_CLOEXEC flag to open().
37027         * modules/fts (Depends-on): Add 'open'.
37029 2020-05-28  Bruno Haible  <bruno@clisp.org>
37031         relocatable-prog: Make more robust in multithreaded applications.
37032         * lib/progreloc.c (O_CLOEXEC): Define fallback to 0 when use from module
37033         relocatable-prog-wrapper.
37034         (find_executable): Pass an O_CLOEXEC flag to open().
37035         * modules/relocatable-prog (Depends-on): Add 'open'.
37037 2020-05-28  Bruno Haible  <bruno@clisp.org>
37039         getloadavg: Make more robust in multithreaded applications.
37040         * lib/getloadavg.c (getloadavg): Pass an O_CLOEXEC flag to open().
37041         Simplify use of O_CLOEXEC.
37042         * modules/getloadavg (Depends-on): Add 'open'.
37044 2020-05-28  Bruno Haible  <bruno@clisp.org>
37046         vma-iter: Make more robust in multithreaded applications.
37047         * lib/vma-iter.c (rof_open, vma_iterate): Pass an O_CLOEXEC flag to
37048         open().
37049         * modules/vma-iter (Depends-on): Add 'open'.
37051 2020-05-28  Bruno Haible  <bruno@clisp.org>
37053         truncate: Make more robust in multithreaded applications.
37054         * lib/truncate.c (truncate): Pass an O_CLOEXEC flag to open().
37056 2020-05-28  Bruno Haible  <bruno@clisp.org>
37058         pagealign_alloc: Make more robust in multithreaded applications.
37059         * lib/pagealign_alloc.c (pagealign_alloc): Pass an O_CLOEXEC flag to
37060         open().
37061         * modules/pagealign_alloc (Depends-on): Add 'open'.
37063 2020-05-28  Bruno Haible  <bruno@clisp.org>
37065         openat: Make more robust in multithreaded applications.
37066         * lib/openat.c (openat_needs_fchdir): Pass an O_CLOEXEC flag to open().
37068 2020-05-28  Bruno Haible  <bruno@clisp.org>
37070         at-internal: Make more robust in multithreaded applications.
37071         * lib/openat-proc.c (openat_proc_name): Pass an O_CLOEXEC flag to
37072         open().
37074 2020-05-28  Bruno Haible  <bruno@clisp.org>
37076         mountlist: Make more robust in multithreaded applications.
37077         * lib/mountlist.c (read_file_system_list): Pass an O_CLOEXEC flag to
37078         open().
37079         * modules/mountlist (Depends-on): Add 'open'.
37081 2020-05-28  Bruno Haible  <bruno@clisp.org>
37083         login_tty: Make more robust in multithreaded applications.
37084         * lib/login_tty.c (login_tty): Pass an O_CLOEXEC flag to open().
37085         * modules/login_tty (Depends-on): Add 'open'.
37087 2020-05-28  Bruno Haible  <bruno@clisp.org>
37089         javacomp: Make more robust in multithreaded applications.
37090         * lib/javacomp.c (get_classfile_version): Pass an O_CLOEXEC flag to
37091         open().
37092         * modules/javacomp (Depends-on): Add 'open'.
37094 2020-05-28  Bruno Haible  <bruno@clisp.org>
37096         getprogname: Make more robust in multithreaded applications.
37097         * lib/getprogname.c (getprogname): Pass an O_CLOEXEC flag to open().
37098         * modules/getprogname (Depends-on): Add 'open'.
37100 2020-05-28  Bruno Haible  <bruno@clisp.org>
37102         get_progname_of: Make more robust in multithreaded applications.
37103         * lib/get_progname_of.c (get_progname_of): Pass an O_CLOEXEC flag to
37104         open().
37105         * modules/get_progname_of (Depends-on): Add 'open'.
37107 2020-05-28  Bruno Haible  <bruno@clisp.org>
37109         get_ppid_of: Make more robust in multithreaded applications.
37110         * lib/get_ppid_of.c (get_ppid_of): Pass an O_CLOEXEC flag to open().
37111         * modules/get_ppid_of (Depends-on): Add 'open'.
37113 2020-05-28  Bruno Haible  <bruno@clisp.org>
37115         get-rusage-as: Make more robust in multithreaded applications.
37116         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit): Pass an O_CLOEXEC
37117         flag to open().
37118         * modules/get-rusage-as (Depends-on): Add 'open'.
37120 2020-05-28  Bruno Haible  <bruno@clisp.org>
37122         crypto/gc: Make more robust in multithreaded applications.
37123         * lib/gc-gnulib.c (randomize): Pass an O_CLOEXEC flag to open().
37124         * modules/crypto/gc (Depends-on): Add 'open'.
37126 2020-05-28  Bruno Haible  <bruno@clisp.org>
37128         copy-file: Make more robust in multithreaded applications.
37129         * lib/copy-file.c (qcopy_file_preserving): Pass an O_CLOEXEC flag to
37130         open().
37132 2020-05-28  Bruno Haible  <bruno@clisp.org>
37134         chown: Make more robust in multithreaded applications.
37135         * lib/chown.c (rpl_chown): Pass an O_CLOEXEC flag to open().
37137 2020-05-28  Bruno Haible  <bruno@clisp.org>
37139         doc: Fix statement about O_CLOEXEC (wrong since 2017-08-14).
37140         * doc/posix-headers/fcntl.texi: Gnulib no longer defines O_CLOEXEC to 0.
37142 2020-05-28  Daiki Ueno  <ueno@gnu.org>
37144         fopen-gnu: make 'b' flag can be used with 'e' on Windows
37145         * lib/fopen.c (rpl_fopen): Pass O_BINARY to open, if a 'b' flag is
37146         specified on Windows.
37147         * tests/test-fopen-gnu.c (DATA): New define.
37148         (main): Add test for reading binary files with an 'e' flag.
37150 2020-05-27  Bruno Haible  <bruno@clisp.org>
37152         Don't assume that UNICODE is not defined.
37153         Some Windows types, such as TCHAR, LPTSTR, LPCTSTR, are defined
37154         differently if the application defines the macro UNICODE.
37155         Reported by Steve Lhomme <robux4@ycbcr.xyz> in
37156         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00184.html>.
37157         * lib/link.c (CreateHardLinkFuncType): Use LPCSTR, not LPCTSTR.
37158         * lib/localename.c (enum_locales_fn): Use LPSTR, not LPTSTR.
37159         * lib/stat-w32.c (GetFinalPathNameByHandleFuncType): Likewise.
37161 2020-05-27  Bruno Haible  <bruno@clisp.org>
37163         Improve pattern for defining _WIN32_WINNT.
37164         Newer versions of the Windows API may not only add, but also remove API
37165         functions. Therefore, when the user is e.g. building for Windows 10, we
37166         should not set _WIN32_WINNT to e.g. Windows 8, as this may enable the
37167         use of APIs that were present in Windows 8 but removed in Windows 10.
37168         Suggested by Steve Lhomme <robux4@ycbcr.xyz> in
37169         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00318.html>.
37170         * lib/ftruncate.c (_WIN32_WINNT): Don't set to a smaller value.
37171         * lib/sethostname.c (_WIN32_WINNT): Likewise.
37172         * lib/stat-w32.c (_WIN32_WINNT): Likewise.
37174 2020-05-27  Bruno Haible  <bruno@clisp.org>
37176         javacomp: Make more robust in multithreaded applications.
37177         * lib/javacomp.c (write_temp_file): Pass an 'e' flag to fopen_temp.
37178         * modules/javacomp (Depends-on): Add fopen-gnu.
37180 2020-05-27  Bruno Haible  <bruno@clisp.org>
37182         mountlist: Make more robust in multithreaded applications.
37183         * lib/mountlist.c (setmntent, read_file_system_list): Pass an 'e' flag
37184         to fopen.
37185         * modules/mountlist (Depends-on): Add fopen-gnu.
37187 2020-05-27  Bruno Haible  <bruno@clisp.org>
37189         sethostname: Make more robust in multithreaded applications.
37190         * lib/sethostname.c (sethostname): Pass an 'e' flag to fopen.
37191         * modules/sethostname (Depends-on): Add fopen-gnu.
37193 2020-05-27  Bruno Haible  <bruno@clisp.org>
37195         readutmp: Make more robust in multithreaded applications.
37196         * lib/readutmp.c (read_utmp): Pass an 'e' flag to fopen.
37197         * modules/readutmp (Depends-on): Add fopen-gnu.
37199 2020-05-27  Bruno Haible  <bruno@clisp.org>
37201         getpass: Make more robust in multithreaded applications.
37202         * lib/getpass.c (getpass): Pass an 'e' flag to fopen.
37203         * modules/getpass (Depends-on): Add fopen-gnu.
37205 2020-05-27  Bruno Haible  <bruno@clisp.org>
37207         getloadavg: Make more robust in multithreaded applications.
37208         * lib/getloadavg.c (getloadavg): Pass an 'e' flag to fopen.
37209         * modules/getloadavg (Depends-on): Add fopen-gnu.
37211 2020-05-27  Bruno Haible  <bruno@clisp.org>
37213         exclude: Make more robust in multithreaded applications.
37214         * lib/exclude.c (add_exclude_file): Pass an 'e' flag to fopen.
37215         * modules/exclude (Depends-on): Add fopen-gnu.
37217 2020-05-27  Bruno Haible  <bruno@clisp.org>
37219         bitset: Make more robust in multithreaded applications.
37220         * lib/bitset/stats.c (bitset_stats_read, bitset_stats_write): Pass an
37221         'e' flag to fopen.
37222         * modules/bitset (Depends-on): Add fopen-gnu.
37224 2020-05-27  Daiki Ueno  <ueno@gnu.org>
37226         read-file: add RF_SENSITIVE flag
37227         * lib/read-file.h (RF_SENSITIVE): New define.
37228         * lib/read-file.c (fread_file, read_file): Take into account of
37229         RF_SENSITIVE flag.
37230         * modules/read-file (Depends-on): Add explicit_bzero.
37231         This adds an alternative behavior of those functions to explicitly
37232         clear the internal memory block when it becomes unused.  This is
37233         useful for reading sensitive information from a file.
37235 2020-05-27  Daiki Ueno  <ueno@gnu.org>
37237         read-file: add flags to modify reading behavior
37238         * lib/read-file.h (RF_BINARY): New define.
37239         (fread_file, read_file): Take FLAGS argument.
37240         (read_binary_file): Remove.
37241         * lib/read-file.c (internal_read_file): Merge into ...
37242         (read_file): ... here.
37243         * modules/read-file-tests (Files): Add "tests/macros.h".
37244         * tests/test-read-file.c (main): Refactor using ASSERT macro.
37245         * NEWS: Mention this change.
37247 2020-05-26  Bernhard Voelker  <mail@bernhard-voelker.de>
37249         doc/gnulib-intro.texi: add missing "to" in sentence
37250         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
37251         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00316.html>.
37252         * doc/gnulib-intro.texi (Collaborative Development): Add "to".
37254 2020-05-26  Bruno Haible  <bruno@clisp.org>
37256         count-one-bits: Fix MSVC specific code.
37257         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
37258         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00309.html>.
37259         * lib/count-one-bits.h (COUNT_ONE_BITS_GENERIC): Don't define if we're
37260         using GCC.
37261         [_MSC_VER]: Use correct syntax for #pragma intrinsic.
37262         (__popcnt64): In 32-bit mode, define as an inline function.
37263         (COUNT_ONE_BITS): Rename first argument to GCC_BUILTIN.
37265 2020-05-26  Bruno Haible  <bruno@clisp.org>
37267         argz: Avoid name clashes through argz.h.
37268         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
37269         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00308.html>.
37270         * lib/argz.h: Don't use __ prefixed identifiers.
37271         (const): Remove definition.
37272         (argz_next): Remove inline definitions.
37274 2020-05-26  Daiki Ueno  <ueno@gnu.org>
37276         read-file: make use of fopen-gnu
37277         * lib/read-file.c (read_file): Pass an 'e' flag to fopen.
37278         (read_binary_file): Likewise.
37279         * modules/read-file (Depends-on): Add fopen-gnu.
37281 2020-05-25  Paul Eggert  <eggert@cs.ucla.edu>
37283         getentropy, getrandom: new modules
37284         * MODULES.html.sh (func_all_modules):
37285         * lib/unistd.in.h (getentropy, getrandom):
37286         * m4/unistd_h.m4 (gl_UNISTD_H, gl_UNISTD_H_DEFAULTS):
37287         * modules/unistd (unistd.h):
37288         Add support for getentropy, getrandom.
37289         * doc/glibc-functions/getentropy.texi (getentropy):
37290         * doc/glibc-functions/getrandom.texi (getrandom):
37291         These are now fixed on some platforms.
37292         * lib/getentropy.c, lib/getrandom.c, lib/sys_random.in.h:
37293         * m4/getentropy.m4, m4/getrandom.m4:
37294         * modules/getentropy, modules/getentropy-tests:
37295         * modules/getrandom, modules/getrandom-tests:
37296         * tests/test-getentropy.c, tests/test-getrandom.c:
37297         New files.
37299 2020-05-25  Bruno Haible  <bruno@clisp.org>
37301         Add missing C99 dependencies.
37302         Reported by Paul Smith <psmith@gnu.org> in
37303         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00290.html>.
37304         * modules/assert (Depends-on): Add c99.
37305         * modules/filenamecat-lgpl (Depends-on): Likewise.
37306         * modules/libc-config (Depends-on): Likewise.
37307         * modules/mktime (Depends-on): Likewise.
37308         * modules/random_r (Depends-on): Likewise.
37309         * modules/regex (Depends-on): Likewise.
37310         * modules/scratch_buffer (Depends-on): Likewise.
37311         * modules/timespec-add (Depends-on): Likewise.
37312         * modules/timespec-sub (Depends-on): Likewise.
37313         * modules/verify (Depends-on): Likewise.
37315 2020-05-24  Paul Eggert  <eggert@cs.ucla.edu>
37317         explicit_bzero-tests: pacify -Wmissing-declarations
37318         * tests/test-explicit_bzero.c (do_secret_stuff, test_stack):
37319         Now static.
37321 2020-05-24  Bruno Haible  <bruno@clisp.org>
37323         fopen-gnu: Add tests.
37324         * tests/test-fopen-gnu.c: New file.
37325         * modules/fopen-gnu-tests: New file.
37327         fopen-gnu: New module.
37328         Suggested by Tim Rühsen <tim.ruehsen@gmx.de> in
37329         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00119.html>.
37330         * lib/fopen.c (rpl_fopen): When the fopen-gnu module is enabled and the
37331         mode contains an 'x' or 'e' flag, use open() followed by fdopen().
37332         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): New macro.
37333         * modules/fopen-gnu: New file.
37334         * doc/posix-functions/fopen.texi: Document the 'fopen-gnu' module.
37336 2020-05-24  Bruno Haible  <bruno@clisp.org>
37338         open, openat: Really support O_CLOEXEC.
37339         * lib/open.c (open): When have_cloexec is still undecided, do pass a
37340         O_CLOEXEC flag to orig_open.
37341         * lib/openat.c (rpl_openat): When have_cloexec is still undecided, do
37342         pass a O_CLOEXEC flag to orig_openat.
37343         * tests/test-open.h (test_open): Verify that O_CLOEXEC is honoured.
37344         * modules/open-tests (Depends-on): Add fcntl.
37345         * modules/openat-tests (Depends-on): Likewise.
37346         * modules/fcntl-safer-tests (Depends-on): Likewise.
37348 2020-05-24  Bruno Haible  <bruno@clisp.org>
37350         fopen: Fix the trailing slash workaround.
37351         * lib/fopen.c (rpl_fopen): Parse the mode string. Recognize "r+" as a
37352         write access. Pass the right flags to open().
37353         * tests/test-fopen.h (test_fopen): Add a few more tests on directories.
37355 2020-05-23  Paul Eggert  <eggert@cs.ucla.edu>
37357         assure: new macro ‘affirm’
37358         * lib/assure.h: Include verify.h.
37359         (affirm): New macro, after a suggestion by Marc Nieper-Wißkirchen in:
37360         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00263.html
37361         and commentary by Bruno Haible in:
37362         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00278.html
37363         * modules/assure (Depends-on:): Add verify.
37365 2020-05-23  Bruno Haible  <bruno@clisp.org>
37367         calloc-gnu: Make test work in non-flat address spaces.
37368         Uses code by Paul Eggert.
37369         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Allow a calloc() implementation
37370         to return more than SIZE_MAX bytes, but only without wrap-around bugs.
37372 2020-05-23  Bruno Haible  <bruno@clisp.org>
37374         calloc-gnu: Avoid wrong configure results with GCC's AddressSanitizer.
37375         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Split the AC_RUN_IFELSE into two
37376         AC_RUN_IFELSE invocations.
37378 2020-05-23  Bruno Haible  <bruno@clisp.org>
37380         isnanf, isnanl, isnan: Don't use nonexistent builtins with clang.
37381         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_HAVE_ISNANF_IN_LIBM,
37382         gl_ISNANF_WORKS): Don't use __builtin_isnanf on clang versions that
37383         don't have it.
37384         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM,
37385         gl_FUNC_ISNANL_WORKS): Don't use __builtin_isnanl on clang versions that
37386         don't have it.
37387         * lib/isnanf-nolibm.h (__has_builtin): New macro.
37388         (isnanf): Don't use __builtin_isnanf on clang versions that don't have
37389         it.
37390         * lib/isnanl-nolibm.h (__has_builtin): New macro.
37391         (isnanl): Don't use __builtin_isnanl on clang versions that don't have
37392         it.
37393         * lib/math.in.h (__has_builtin): New macro.
37394         (isnanf): Don't use __builtin_isnanf on clang versions that don't have
37395         it.
37396         (isnanl): Don't use __builtin_isnanl on clang versions that don't have
37397         it.
37398         (isnan): Don't use the builtins on clang versions that don't have
37399         __builtin_isnanf and __builtin_isnanl.
37401 2020-05-23  Bruno Haible  <bruno@clisp.org>
37403         calloc-gnu: Avoid wrong configure results with clang.
37404         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Mark the pointer variable as
37405         'volatile', to defeat compiler optimizations.
37407 2020-05-23  Bruno Haible  <bruno@clisp.org>
37409         isnanl, isnanl-nolibm: Make a test work better with "gcc -O2" on x86_64.
37410         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Pass the
37411         'long double' values by reference, with values taken from a statically
37412         allocated array.
37414 2020-05-23  Bruno Haible  <bruno@clisp.org>
37416         findprog-in: Ignore directories.
37417         Reported by Frederick Eaton via Dmitry Goncharov in
37418         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00003.html>.
37419         * lib/findprog-in.c (find_in_given_path): When the file found is a
37420         directory, set errno to EACCES and, during a PATH search, continue
37421         searching.
37422         * modules/findprog-in (Depends-on): Add sys_stat, stat.
37424 2020-05-23  Paul Eggert  <eggert@cs.ucla.edu>
37426         verify: document ‘assume’ better
37427         * lib/verify.h (assume): Say it’s for static analysis, not dynamic.
37429 2020-05-22  Asher Gordon  <AsDaGo@posteo.net>
37431         gendocs: Clarify licenses for templates.
37432         * doc/gendocs_template: Add a GNU All-Permissive license notice
37433         and bump Parent-Version.
37434         * doc/gendocs_template_min: Add a GNU All-Permissive license
37435         notice and copy the explanatory comment about the license notice
37436         at the bottom from gendocs_template.
37438 2020-05-21  Bruno Haible  <bruno@clisp.org>
37440         group-member: Relicense under LGPLv2+.
37441         Jim Meyering's approval is in
37442         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00218.html>.
37443         Paul Eggert's approval is in
37444         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00225.html>.
37445         Eric Blake's approval is in
37446         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00217.html>.
37447         * modules/group-member (License): Change to LGPLv2+.
37449 2020-05-21  Bruno Haible  <bruno@clisp.org>
37451         memmem: Avoid wrong configure results with "clang -fsanitize=undefined".
37452         Reported by Tim Rühsen in
37453         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
37454         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Use NULL + 1, not NULL.
37456 2020-05-21  Bruno Haible  <bruno@clisp.org>
37458         regex: Avoid wrong configure results with "clang -fsanitize=leak".
37459         Reported by Tim Rühsen in
37460         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
37461         * m4/regex.m4 (gl_REGEX): Free compiled regexes and allocated registers
37462         before returning with status 0.
37464 2020-05-21  Bruno Haible  <bruno@clisp.org>
37466         glob: Avoid wrong configure results with "clang -fsanitize=leak".
37467         Reported by Tim Rühsen in
37468         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
37469         * m4/glob.m4 (gl_GLOB): Free allocated memory before returning.
37471 2020-05-21  Bruno Haible  <bruno@clisp.org>
37473         fchownat: Support clang -fsanitize=implicit-integer-sign-change better.
37474         Reported by Tim Rühsen in
37475         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
37476         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG,
37477         gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Cast -1 to uid_t or git_t,
37478         respectively.
37480 2020-05-18  Tim Rühsen  <tim.ruehsenqgmx.de>
37482         getdelim: Avoid wrong configure results with gcc -fsanitize=address.
37483         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Fix memleak.
37485 2020-05-19  Paul Eggert  <eggert@cs.ucla.edu>
37487         ftoastr: fix ifndef typo
37488         * lib/ftoastr.h (_GL_FTOASTR_H): Define.
37490 2020-05-19  Bruno Haible  <bruno@clisp.org>
37492         havelib: Tweak documentation.
37493         * doc/havelib.texi (Searching for Libraries): Fix typo.
37495 2020-05-18  Siddhesh Poyarekar  <siddhesh@gotplt.org>
37497         vcs-to-changelog: Rename vcs_to_changelog.py to use hyphens.
37498         This was needed earlier because modules had to import the main script,
37499         but that is no longer true.  Rename the script so that it is
37500         consistent with all other scripts in gnulib and uses hyphens.
37501         * build-aux/vcs_to_changelog.py: Rename to...
37502         * build-aux/vcs-to-changelog.py: ... this.
37503         * doc/vcs-to-changelog.texi (VCS To ChangeLog): Update reference.
37504         * modules/vcs-to-changelog: Likewise.
37506 2020-05-17  Bruno Haible  <bruno@clisp.org>
37508         Clarify intended usage of the license file modules.
37509         Reported by Asher Gordon <AsDaGo@posteo.net> in
37510         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00126.html>.
37511         * doc/licenses-texi.texi (License Texinfo sources): Mention the
37512         GNU AGPL. Explain the intended usage of the modules.
37513         * modules/fdl (Notice): Discourage use as a module.
37514         * modules/fdl-1.3 (Notice): Likewise.
37516 2020-05-17  Akim Demaille  <akim@lrde.epita.fr>
37518         hash: add hash_xinsert
37519         * lib/hash.h, lib/xhash.c (hash_xinsert): New.
37521 2020-05-16  Bruno Haible  <bruno@clisp.org>
37523         findprog-lgpl: Fix link error (existing since 2008-09-02).
37524         * modules/findprog-lgpl (Makefile.am): Arrange to compile
37525         findprog-lgpl.c, not findprog.c.
37526         * lib/findprog.c (find_in_path): Add LGPLed replacement code for
37527         XNMALLOC.
37529 2020-05-15  Paul Eggert  <eggert@cs.ucla.edu>
37531         c-stack: pacify -Wunused-result when DEBUG
37532         Problem reported by Marc Nieper-Wißkirchen in:
37533         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00132.html
37534         * lib/c-stack.c (segv_handler, overflow_handler, segv_handler) [DEBUG]:
37535         Explicitly ignore write failures.
37537 2020-05-13  Jim Meyering  <meyering@fb.com>
37539         announce-gen: improve a comment
37540         * build-aux/announce-gen: Improve comment.
37542 2020-05-12  Paul Eggert  <eggert@cs.ucla.edu>
37544         xalloc: pacify -Wanalyzer-possible-null-argument
37545         Problem reported for GCC 10.1.0 by Bruno Haible in:
37546         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00118.html
37547         * lib/xmalloc.c (HAVE_GNU_MALLOC, HAVE_GNU_REALLOC): New constants.
37548         (xmalloc): Suppress unnecessary check if HAVE_GNU_MALLOC.
37549         (xrealloc): Suppress unnecssary check if HAVE_GNU_REALLOC.
37551 2020-05-11  Paul Eggert  <eggert@cs.ucla.edu>
37553         careadlinkat: fix GCC 10 workaround
37554         * lib/careadlinkat.c (careadlinkat) [GCC_LINT]:
37555         Massage the code so that it’s closer to what it was before
37556         the GCC 10.1.0 workaround was introduced.  This fixes
37557         a loop when !buffer and the bug workaround is in effect.
37558         Remove unnecessary casts.  Defend in a different way
37559         against (buffer && !buffer_size), by adding at least 1
37560         to buf_size each time through the loop.
37562 2020-05-10  Bruno Haible  <bruno@clisp.org>
37564         doc: Mark HP-UX as unsupported.
37565         * doc/gnulib-intro.texi (Target Platforms): List HP-UX as unsupported.
37567 2020-05-10  Paul Eggert  <eggert@cs.ucla.edu>
37569         careadlinkat: limit GCC workaround
37570         * lib/careadlinkat.c (careadlinkat): Limit workaround to GCC
37571         10.1.0 and later, since the workaround is pretty bad and the GCC
37572         bug should get fixed.
37574 2020-05-10  Bruno Haible  <bruno@clisp.org>
37576         havelib: Enhance documentation.
37577         * doc/havelib.texi (Searching for Libraries): Mention the bad
37578         consequences of using LIBxxx instead of LTLIBxxx and vice versa.
37580 2020-05-10  Bruno Haible  <bruno@clisp.org>
37582         attribute: Clarify list of attributes.
37583         * lib/attribute.h: Reorder the list of attributes, and group them by
37584         purpose.
37586 2020-05-10  Bruno Haible  <bruno@clisp.org>
37588         string: Fix compilation error in C++ mode.
37589         * lib/warn-on-use.h (_GL_WARN_ON_USE_CXX): In C mode, use plain
37590         _GL_WARN_ON_USE.
37591         * lib/string.in.h (strchr, strpbrk, strrchr): Use _GL_WARN_ON_USE_CXX
37592         instead of _GL_WARN_ON_USE.
37594 2020-05-10  Akim Demaille  <akim@lrde.epita.fr>
37596         announce-gen: add support for dist-lzip
37597         * build-aux/announce-gen (@archive_suffixes): Add tar.lz.
37599 2020-05-09  Paul Eggert  <eggert@cs.ucla.edu>
37601         manywarnings: port to GCC 10.1
37602         * build-aux/gcc-warning.spec:
37603         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C)):
37604         Add GCC 10.1.0 warnings.
37606         careadlinkat: pacify -Wreturn-local-addr
37607         * lib/careadlinkat.c (careadlinkat) [GCC_LINT]:
37608         Pacify gcc 10’s -Wreturn-local-addr option.
37609         Simplify some of the later code.
37611 2020-05-09  Paul Eggert  <eggert@cs.ucla.edu>
37613         attribute: remove ATTRIBUTE_DEPRECATED
37614         * lib/attribute.h: Improve recently-added comments, mostly
37615         by shortening them (use active voice, etc.).
37616         (ATTRIBUTE_DEPRECATED): Remove, as it duplicates DEPRECATED.
37617         Problem reported by Bruno Haible in:
37618         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00089.html
37620 2020-05-09  Bruno Haible  <bruno@clisp.org>
37622         attribute: Add comments.
37623         * lib/attribute.h: Document each macro.
37625 2020-05-09  Akim Demaille  <akim@lrde.epita.fr>
37627         bitset: use the attribute module
37628         * modules/bitset: Depend on 'attribute'.
37629         * lib/bitset/base.h (ATTRIBUTE_UNUSED): Remove.
37630         * lib/bitset.c, lib/bitset/array.c, lib/bitset/list.c,
37631         * lib/bitset/stats.c, lib/bitset/table.c, lib/bitset/vector.c:
37632         Use MAYBE_UNUSED instead of ATTRIBUTE_UNUSED.
37634 2020-05-09  Bruno Haible  <bruno@clisp.org>
37636         c-stack: Fix warning when DEBUG is enabled.
37637         Patch suggested by Marc Nieper-Wißkirchen <marc.nieper+gnu@gmail.com> in
37638         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00081.html>.
37639         * lib/c-stack.c: Include <stdio.h>.
37641 2020-05-09  Bruno Haible  <bruno@clisp.org>
37643         Remove redundant definitions of _GL_ATTRIBUTE_FORMAT.
37644         * lib/argp.h (_GL_ATTRIBUTE_FORMAT): Remove macro.
37645         * lib/argp-fmtstream.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37646         * lib/c-snprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37647         * lib/c-vasnprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37648         * lib/c-vasprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37649         * lib/c-vsnprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37650         * lib/c-xvasprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37651         * lib/error.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37652         * lib/parse-datetime.y (_GL_ATTRIBUTE_FORMAT): Likewise.
37653         * lib/vasnprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37654         * lib/xprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37655         * lib/xvasprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37657 2020-05-09  Bruno Haible  <bruno@clisp.org>
37659         Remove redundant definitions of _GL_ATTRIBUTE_ALLOC_SIZE.
37660         Reported by Akim Demaille in
37661         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00077.html>.
37662         * lib/eealloc.h (_GL_ATTRIBUTE_ALLOC_SIZE): Remove macro.
37663         * lib/pagealign_alloc.h (_GL_ATTRIBUTE_ALLOC_SIZE): Likewise.
37664         * lib/xalloc.h (_GL_ATTRIBUTE_ALLOC_SIZE): Likewise.
37666 2020-05-09  Bruno Haible  <bruno@clisp.org>
37668         stdio, monetary: Don't redefine _GL_ATTRIBUTE_FORMAT.
37669         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT): Don't override the definition
37670         that usually comes from m4/gnulib-common.m4.
37671         * lib/monetary.in.h (_GL_ATTRIBUTE_FORMAT): Likewise.
37673 2020-05-09  Bruno Haible  <bruno@clisp.org>
37675         dirent, stdlib, wchar, string: Don't redefine _GL_ATTRIBUTE_PURE.
37676         * lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Don't override the definition
37677         that usually comes from m4/gnulib-common.m4.
37678         * lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Likewise.
37679         * lib/string.in.h (_GL_ATTRIBUTE_PURE): Likewise.
37680         * lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
37682 2020-05-09  Bruno Haible  <bruno@clisp.org>
37684         uchar: Work around incorrect char16_t, char32_t types on Haiku 2020.
37685         * lib/uchar.in.h (char16_t): Define as macro if
37686         GNULIB_OVERRIDES_CHAR16_T.
37687         (char32_t): Define as macro if GNULIB_OVERRIDES_CHAR32_T.
37688         * m4/uchar.m4 (gl_TYPE_CHAR16_T, gl_TYPE_CHAR32_T): New macros.
37689         (gl_UCHAR_H): Invoke them.
37690         (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_OVERRIDES_CHAR16_T,
37691         GNULIB_OVERRIDES_CHAR32_T.
37692         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32, gl_MBRTOC32_SANITYCHECK): Require
37693         gl_TYPE_CHAR32_T and test GNULIB_OVERRIDES_CHAR32_T.
37694         * modules/uchar (Makefile.am): Substitute GNULIB_OVERRIDES_CHAR16_T,
37695         GNULIB_OVERRIDES_CHAR32_T.
37697 2020-05-09  Bruno Haible  <bruno@clisp.org>
37699         Macro tweaks.
37700         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Correct config.h comment.
37701         * m4/wint_t.m4 (gt_TYPE_WINT_T): Correct indentation.
37703 2020-05-08  Bruno Haible  <bruno@clisp.org>
37705         c32rtomb: Avoid compilation failure on Haiku.
37706         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Test for c32rtomb without excluding
37707         inline definitions.
37708         * doc/posix-functions/c32rtomb.texi: Mention the Haiku problem.
37710 2020-05-08  Bruno Haible  <bruno@clisp.org>
37712         mbrtoc32: Avoid compilation failure on Haiku.
37713         * m4/mbrtoc32.m4 (gl_CHECK_FUNC_MBRTOC32): New macro.
37714         (gl_FUNC_MBRTOC32, gl_MBRTOC32_SANITYCHECK): Use it instead of
37715         AC_CHECK_FUNCS_ONCE.
37716         * doc/posix-functions/mbrtoc32.texi: Mention the Haiku problem.
37718 2020-05-08  Bruno Haible  <bruno@clisp.org>
37720         limits-h: Define LONG_BIT correctly on Haiku/x86_64.
37721         * lib/limits.in.h: Define and test _GL_ALREADY_INCLUDING_LIMITS_H.
37723 2020-05-08  Bruno Haible  <bruno@clisp.org>
37725         list: Update documentation.
37726         Reported by Marc Nieper-Wißkirchen <marc.nieper+gnu@gmail.com> in
37727         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00062.html>.
37728         * doc/containers.texi (Container data types): Document the new list
37729         operations and their complexity.
37731 2020-05-08  Bruno Haible  <bruno@clisp.org>
37733         ignore-value tests: Use module 'attribute'.
37734         * m4/gnulib-common.m4 (gl_COMMON_BODY): Fix a typo.
37735         * tests/test-ignore-value.c: Include attribute.h.
37736         (_GL_ATTRIBUTE_RETURN_CHECK): Remove macro. Use NODISCARD instead.
37737         * modules/ignore-value-tests (Depends-on): Add attribute.
37739 2020-05-08  Bruno Haible  <bruno@clisp.org>
37741         uniname/uniname: Use module 'attribute'.
37742         * lib/uniname/gen-uninames.lisp: Emit a reference to ATTRIBUTE_PACKED.
37743         * lib/uniname/uninames.h: Regenerated.
37744         * lib/uniname/uniname.c: Include attribute.h.
37745         * modules/uniname/uniname (Depends-on): Add attribute.
37747 2020-05-08  Bruno Haible  <bruno@clisp.org>
37749         c32rtomb: Use module 'attribute'.
37750         * lib/c32rtomb.c: Include attribute.h.
37751         (FALLTHROUGH): Remove macro.
37752         * modules/c32rtomb (Depends-on): Add attribute.
37754 2020-05-08  Bruno Haible  <bruno@clisp.org>
37756         xsize: Use module 'attribute'.
37757         * lib/xsize.h: Include attribute.h. Use ATTRIBUTE_PURE.
37758         * modules/xsize (Depends-on): Add attribute.
37760 2020-05-06  Paul Eggert  <eggert@cs.ucla.edu>
37762         * m4/gnulib-common.m4 (gl_COMMON_BODY): Minor style fixes.
37764         * lib/attribute.h: Minor style fixes.
37766         Fix version-etc glitch on OpenIndiana
37767         Problem reported by Mats Erik Andersson in:
37768         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00067.html
37769         * lib/version-etc.h (_GL_ATTRIBUTE_SENTINEL): Remove defn
37770         that now clashes with gnulib-common.h.  All uses changed.
37772 2020-05-03  Paul Eggert  <eggert@cs.ucla.edu>
37774         attribute: new module
37775         This simplifies use of GCC and C2x attributes like ‘deprecated’.
37776         * MODULES.html.sh: Add attribute.
37777         * doc/attribute.texi, lib/attribute.h, modules/attribute: New files.
37778         * doc/gnulib.texi (Particular Modules): Add Attributes.
37779         * lib/backupfile.c, lib/fnmatch.c, lib/freopen-safer.c:
37780         * lib/mbrtoc32.c, lib/mbrtowc.c, lib/nstrftime.c, lib/quotearg.c:
37781         * lib/savewd.c, lib/unistr/u8-uctomb-aux.c, lib/unistr/u8-uctomb.c:
37782         * lib/vasnprintf.c:
37783         Include attribute.h, and let it define FALLTHROUGH.
37784         * lib/bitset/base.h, lib/c-stack.c (__attribute__): Remove macro.
37785         * lib/bitset/base.h (ATTRIBUTE_UNUSED): Define in terms of
37786         _GL_ATTRIBUTE_MAYBE_UNUSED, for forwards compatibility to C2x.
37787         * lib/dfa.c (FALLTHROUGH): Define consistently with gl_COMMON_BODY.
37788         This is a copy since Gawk doesn’t use Gnulib.
37789         * lib/di-set.h (_GL_ATTRIBUTE_NONNULL): Remove definition that
37790         is incompatible with gl_COMMON_BODY’s.  All uses changed.
37791         * lib/fts.c: Include attribte.h, for FALLTHROUGH.
37792         Keep the existing FALLTHROUGH definition since Glibc might use it,
37793         and it does no harm to Gnulib’s FALLTHROUGH.
37794         * lib/fts_.h, lib/inttostr.h:
37795         (__GNUC_PREREQ): Remove; no longer needed.
37796         (__attribute_warn_unused_result__): Remove.  All uses
37797         replaced by _GL_ATTRIBUTE_NODISCARD.
37798         * lib/gl_list.h, lib/gl_map.h, lib/gl_omap.h, lib/gl_oset.h:
37799         * lib/gl_set.h: Prefer _GL_ATTRIBUTE_NODISCARD to an ifdeffed
37800         __attribute__ ((__warn_unused_result__)), for forward
37801         compatibility to C2x.
37802         * lib/hash.h (_GL_ATTRIBUTE_WUR): Remove.  All uses replaced by
37803         _GL_ATTRIBUTE_NODISCARD.
37804         (_GL_ATTRIBUTE_DEPRECATED): Remove, since gl_COMMON_BODY defines it.
37805         * lib/ino-map.h (_GL_ATTRIBUTE_NONNULL): Remove.  All uses
37806         replaced by gl_COMMON_BODY’s implementation, which has a
37807         slightly different signature.
37808         * lib/safe-alloc.h (_GL_ATTRIBUTE_RETURN_CHECK):
37809         Remove.  All uses replaced by _GL_ATTRIBUTE_NODISCARD.
37810         * lib/unused-parameter.h (_GL_UNUSED_PARAMETER):
37811         Define in terms of _GL_ATTRIBUTE_MAYBE_UNUSED.
37812         No doubt all uses should be replaced, at some point.
37813         * m4/gnulib-common.m4 (_GL_GNUC_PREREQ): New macro.
37814         (_Noreturn): Use it.
37815         (_GL_HAS_ATTRIBUTE, _GL_ATTRIBUTE_ALLOC_SIZE)
37816         (_GL_ATTRIBUTE_ALWAYS_INLINE, _GL_ATTRIBUTE_ARTIFICIAL)
37817         (_GL_ATTRIBUTE_COLD)
37818         (_GL_ATTRIBUTE_DEPRECATED, _GL_ATTRIBUTE_ERROR)
37819         (_GL_ATTRIBUTE_WARNING, _GL_ATTRIBUTE_EXTERNALLY_VISIBLE)
37820         (_GL_ATTRIBUTE_FALLTHROUGH, _GL_ATTRIBUTE_FORMAT)
37821         (_GL_ATTRIBUTE_LEAF, _GL_ATTRIBUTE_MAY_ALIAS)
37822         (_GL_ATTRIBUTE_MAYBE_UNUSED)
37823         (_GL_ATTRIBUTE_NODISCARD, _GL_ATTRIBUTE_NOINLINE)
37824         (_GL_ATTRIBUTE_NONNULL, _GL_ATTRIBUTE_NONSTRING)
37825         (_GL_ATTRIBUTE_NOTHROW, _GL_ATTRIBUTE_PACKED, _GL_ATTRIBUTE_PURE)
37826         (_GL_ATTRIBUTE_RETURNS_NONNULL)
37827         (_GL_ATTRIBUTE_SENTINEL): New macros.
37828         * modules/backup-rename, modules/backupfile, modules/c-vasnprintf:
37829         * modules/fnmatch, modules/freopen-safer, modules/fts:
37830         * modules/mbrtoc32, modules/mbrtowc, modules/nstrftime:
37831         * modules/quotearg, modules/savewd:
37832         * modules/unistdio/u16-u16-vasnprintf:
37833         * modules/unistdio/u16-vasnprintf:
37834         * modules/unistdio/u32-u32-vasnprintf:
37835         * modules/unistdio/u32-vasnprintf:
37836         * modules/unistdio/u8-u8-vasnprintf:
37837         * modules/unistdio/u8-vasnprintf:
37838         * modules/unistdio/ulc-vasnprintf:
37839         * modules/unistr/u8-uctomb, modules/vasnprintf:
37840         (Depends-on:): Add attribute module.
37842 2020-05-03  Bruno Haible  <bruno@clisp.org>
37844         bison: Fix today's commit.
37845         * m4/bison.m4 (gl_PROG_BISON): Set ac_verc_fail to 'yes', not 'true'.
37847 2020-05-03  Bruno Haible  <bruno@clisp.org>
37849         list-c++: Add get_first, get_last, set_first, set_last operations.
37850         * lib/gl_list.hh (class gl_List): Add methods get_first, get_last,
37851         set_first, set_last.
37852         * lib/gl_list.h: Tweak comments.
37854 2020-05-03  Akim Demaille  <akim@lrde.epita.fr>
37856         bison: rely on bison's %require to check a version requirement
37857         See https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00021.html.
37858         * m4/bison.m4 (gl_PROG_BISON): Let bison itself decide if it it recent
37859         enough of not.
37860         So far it is the only know Yacc tool that supports '%require'.
37861         Other yaccs will actually even choke on seeing the -o option after the
37862         input file name.
37863         * m4/parse-datetime.m4: Simplify gl_PROG_BISON invocation.
37865 2020-05-02  Bruno Haible  <bruno@clisp.org>
37867         list: Add get_first, get_last, set_first, set_last operations.
37868         * lib/gl_list.h (gl_list_get_first, gl_list_get_last,
37869         gl_list_nx_set_first, gl_list_nx_set_last): New functions.
37870         * lib/gl_xlist.h (gl_list_set_first, gl_list_set_last): New functions.
37872 2020-05-02  Bruno Haible  <bruno@clisp.org>
37874         list: Remove redundant code for remove_first and remove_last operations.
37875         * lib/gl_list.h (struct gl_list_implementation): Remove fields
37876         remove_first, remove_last.
37877         (gl_list_remove_first, gl_list_remove_last): Implement in a generic way.
37878         * lib/gl_array_list.c: Revert last change.
37879         * lib/gl_carray_list.c: Likewise.
37880         * lib/gl_anylinked_list2.h: Likewise.
37881         * lib/gl_linked_list.c: Likewise.
37882         * lib/gl_linkedhash_list.c: Likewise.
37883         * lib/gl_anytree_list2.h: Likewise.
37884         * lib/gl_avltree_list.c: Likewise.
37885         * lib/gl_avltreehash_list.c: Likewise.
37886         * lib/gl_rbtree_list.c: Likewise.
37887         * lib/gl_rbtreehash_list.c: Likewise.
37888         * lib/gl_sublist.c: Likewise.
37890 2020-05-02  Bruno Haible  <bruno@clisp.org>
37892         bison-i18n: Add support for cross-compilation.
37893         Reported by Hongxu Jia <hongxu.jia@windriver.com> in
37894         <https://lists.gnu.org/archive/html/bison-patches/2016-02/msg00000.html>
37895         via Akim Demaille <akim@lrde.epita.fr>.
37896         * m4/bison-i18n.m4 (BISON_I18N): Accept a configure option
37897         --with-bison-prefix=PREFIX and use it to determine BISON_LOCALEDIR.
37898         Don't use bison's --print-localedir option when cross-compiling.
37899         Also, fix an error message and a comment.
37901 2020-05-01  Bruno Haible  <bruno@clisp.org>
37903         list: Add remove_first and remove_last operations.
37904         Suggested by Marc Nieper-Wißkirchen <marc.nieper+gnu@gmail.com> in
37905         <https://lists.gnu.org/archive/html/bug-gnulib/2020-04/msg00092.html>.
37906         * lib/gl_list.h (struct gl_list_implementation): Add fields
37907         remove_first, remove_last.
37908         (gl_list_remove_first, gl_list_remove_last): New functions.
37909         * lib/gl_array_list.c (gl_array_remove_first, gl_array_remove_last): New
37910         functions, based on gl_array_remove_at.
37911         (gl_array_list_implementation): Implement the new operations.
37912         * lib/gl_carray_list.c (gl_carray_remove_first, gl_carray_remove_last):
37913         New functions, based on gl_carray_remove_at.
37914         (gl_carray_list_implementation): Implement the new operations.
37915         * lib/gl_anylinked_list2.h (gl_linked_remove_first,
37916         gl_linked_remove_last): New functions, based on gl_linked_remove_at.
37917         * lib/gl_linked_list.c (gl_linked_list_implementation): Implement the
37918         new operations.
37919         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation):
37920         Likewise.
37921         * lib/gl_anytree_list2.h (gl_tree_remove_first, gl_tree_remove_last):
37922         New functions, based on gl_tree_remove_at.
37923         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Implement the
37924         new operations.
37925         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
37926         Likewise.
37927         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Likewise.
37928         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation):
37929         Likewise.
37930         * lib/gl_sublist.c (gl_sublist_remove_first, gl_sublist_remove_last):
37931         New functions, based on gl_sublist_remove_at.
37932         (gl_sublist_list_implementation): Implement the new operations.
37933         * lib/gl_list.hh (class gl_List): Add methods remove_first,
37934         remove_last.
37935         * tests/test-array_list.c (main): Test also gl_list_remove_first and
37936         gl_list_remove_last.
37937         * tests/test-avltree_list.c (main): Likewise.
37938         * tests/test-avltreehash_list.c (main): Likewise.
37939         * tests/test-carray_list.c (main): Likewise.
37940         * tests/test-linked_list.c (main): Likewise.
37941         * tests/test-linkedhash_list.c (main): Likewise.
37942         * tests/test-rbtree_list.c (main): Likewise.
37943         * tests/test-rbtreehash_list.c (main): Likewise.
37945 2020-05-01  Bruno Haible  <bruno@clisp.org>
37947         parse-datetime: Fix a build failure with an older bison version.
37948         * modules/parse-datetime (Makefile.am): Don't do the post-processing of
37949         parse-datetime.tab.c if a suitable version of bison was not found.
37951 2020-05-01  Bruno Haible  <bruno@clisp.org>
37953         bison: New module.
37954         * m4/bison.m4 (gl_PROG_BISON): New macro, extracted from
37955         m4/parse-datetime.m4.
37956         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Invoke gl_PROG_BISON.
37957         * modules/bison: New file.
37958         * modules/parse-datetime (Files): Remove m4/bison.m4.
37959         (Depends-on): Add bison.
37961 2020-05-01  Jose E. Marchesi  <jemarch@gnu.org>
37963         Update users.txt.
37964         * users.txt: Add poke.
37966 2020-04-28  Bruno Haible  <bruno@clisp.org>
37968         posix_spawn_file_actions_addfchdir tests: Enhance test.
37969         * tests/test-posix_spawn5.c: Include findprog.h.
37970         (test): New function, extracted from main.
37971         (main): Invoke it. Also, invoke it with a program name such as
37972         "bin/pwd".
37973         * modules/posix_spawn_file_actions_addfchdir-tests (Depends-on): Add
37974         findprog.
37976 2020-04-28  Bruno Haible  <bruno@clisp.org>
37978         posix_spawn_file_actions_addchdir tests: Enhance test.
37979         * tests/test-posix_spawn4.c: Include findprog.h.
37980         (test): New function, extracted from main.
37981         (main): Invoke it. Also, invoke it with a program name such as
37982         "bin/pwd".
37983         * modules/posix_spawn_file_actions_addchdir-tests (Depends-on): Add
37984         findprog.
37986 2020-04-28  Bruno Haible  <bruno@clisp.org>
37988         posix_spawn_file_actions_destroy: Fix a crash (bug from 2019-06-10).
37989         * lib/spawn_faction_destroy.c (posix_spawn_file_actions_destroy): Don't
37990         access elements of the wrong union member.
37992 2020-04-27  Bruno Haible  <bruno@clisp.org>
37994         getdate: Remove deprecated module.
37995         * modules/getdate: Remove file.
37996         * doc/getdate.texi: Remove file.
37997         * lib/getdate.h: Remove file.
37998         * NEWS: Mention the removal.
38000 2020-04-27  Bruno Haible  <bruno@clisp.org>
38002         realloc: Remove deprecated module.
38003         * modules/realloc: Remove file.
38004         * NEWS: Mention the removal.
38006 2020-04-27  Bruno Haible  <bruno@clisp.org>
38008         calloc: Remove deprecated module.
38009         * modules/calloc: Remove file.
38010         * NEWS: Mention the removal.
38012 2020-04-27  Bruno Haible  <bruno@clisp.org>
38014         malloc: Remove deprecated module.
38015         * modules/malloc: Remove file.
38016         * NEWS: Mention the removal.
38018 2020-04-27  Bruno Haible  <bruno@clisp.org>
38020         fnmatch-posix: Remove deprecated module.
38021         * modules/fnmatch-posix: Remove file.
38022         * MODULES.html.sh (Enhancements for POSIX:2008 functions): Update.
38023         * NEWS: Mention the removal.
38025 2020-04-27  Bruno Haible  <bruno@clisp.org>
38027         pipe: Remove deprecated module.
38028         * modules/pipe: Remove file.
38029         * lib/pipe.h: Remove file.
38030         * NEWS: Mention the removal.
38032 2020-04-27  Bruno Haible  <bruno@clisp.org>
38034         getopt: Remove deprecated module.
38035         * modules/getopt: Remove file.
38036         * NEWS: Mention the removal.
38038 2020-04-27  Bruno Haible  <bruno@clisp.org>
38040         remove-dest-slash: Remove deprecated module.
38041         * modules/rename-dest-slash: Remove file.
38042         * MODULES.html.sh (Compatibility checks for POSIX:2008 functions):
38043         Update.
38044         * NEWS: Mention the removal.
38046 2020-04-27  Bruno Haible  <bruno@clisp.org>
38048         unictype/bidicategory-*: Remove deprecated modules.
38049         * modules/unictype/bidicategory-all: Remove file.
38050         * modules/unictype/bidicategory-byname: Remove file.
38051         * modules/unictype/bidicategory-name: Remove file.
38052         * modules/unictype/bidicategory-of: Remove file.
38053         * modules/unictype/bidicategory-test: Remove file.
38054         * MODULES.html.sh (Unicode string functions): Update.
38055         * NEWS: Mention the removals.
38057 2020-04-25  Paul Eggert  <eggert@cs.ucla.edu>
38059         Tune fts for FTS_LOGICAL+FTS_NOSTAT
38060         From a suggestion by Askar Safin in:
38061         https://lists.gnu.org/r/bug-gnulib/2020-04/msg00074.html
38062         * lib/fts.c (fts_build): If file types are known, optimize
38063         FTS_LOGICAL+FTS_NOSTAT for non-symlinks and non-directories the
38064         same way that we already optimize FTS_PHYSICAL+FTS_NOSTAT for
38065         non-directories.
38067 2020-04-19  Bruno Haible  <bruno@clisp.org>
38069         vasnprintf: Add support for printing wide characters using escapes.
38070         * lib/vasnprintf.c (ENABLE_WCHAR_FALLBACK): Document optional macro.
38071         (wctomb_fallback): New function.
38072         (local_wctomb): New function.
38073         (local_wcrtomb): New function or macro.
38074         (MAX_ROOM_NEEDED): Adjust estimate for %lc.
38075         (VASNPRINTF): Simplify %ls code by use of local_wcrtomb. Add code for
38076         %lc.
38078 2020-04-15  Paul Eggert  <eggert@cs.ucla.edu>
38080         fts: remove NOSTAT_LEAF_OPTIMIZATION
38081         It caused ‘find’ and ‘du’ to dump core, and it was useful
38082         only for obsolescent Linux filesystems anyway.  Problem reported in:
38083         https://lists.gnu.org/r/bug-gnulib/2020-04/msg00068.html
38084         Quite possibly there is still a serious underlying fts bug with
38085         tight-loop-check and mutating file systems, but if so this patch
38086         should cause the bug to be triggered less often.
38087         * lib/fts.c (enum leaf_optimization): Remove
38088         NOSTAT_LEAF_OPTIMIZATION, as it’s problematic.
38089         (S_MAGIC_REISERFS, S_MAGIC_XFS): Remove; no longer needed.
38090         (leaf_optimization): Remove special cases for ReiserFS and XFS.
38091         (fts_read): Remove NOSTAT_LEAF_OPTIMIZATION code.
38092         * lib/fts_.h (struct _ftsent.fts_n_dirs_remaining):
38093         Remove.  All uses removed.
38095 2020-04-13  Bastien Roucariès  <rouca@debian.org>
38097         explicit_bzero: Improve code style.
38098         * lib/explicit_bzero.c (explicit_bzero): Use '\0' instead of 0.
38100 2020-04-13  Bastien Roucariès  <rouca@debian.org>
38102         explicit_bzero: On native Windows, use SecureZeroMemory().
38103         * lib/explicit_bzero.c: Include <windows.h>.
38104         (explicit_bzero): On native Windows, use SecureZeroMemory.
38106 2020-04-13  Bastien Roucariès  <rouca@debian.org>
38108         explicit_bzero: Use memset_s() when available.
38109         * lib/explicit_bzero.c (__STDC_WANT_LIB_EXT1__): Define.
38110         (explicit_bzero): Use memset_s when available.
38111         * m4/explicit_bzero.m4 (gl_PREREQ_EXPLICIT_BZERO): Test for memset_s.
38113 2020-04-13  Bastien Roucariès  <rouca@debian.org>
38115         explicit_bzero tests: Fix test failure on OpenBSD 6.5.
38116         * tests/test-explicit_bzero.c (test_heap): Handle implementations of
38117         free() that overwrite the memory with canaries.
38119 2020-04-13  Akim Demaille  <akim@lrde.epita.fr>
38121         bootstrap: recommend git submodule update --init
38122         Reported by Bruno Haible.
38123         <https://lists.gnu.org/r/bug-gnulib/2020-03/msg00101.html>
38124         * build-aux/bootstrap: recommand "git submodule update --init"
38125         rather than "git submodule init".
38127 2020-04-12  Bruno Haible  <bruno@clisp.org>
38129         explicit_bzero: Add tests.
38130         * tests/test-explicit_bzero.c: New file.
38131         * modules/explicit_bzero-tests: New file.
38133 2020-04-11  Bruno Haible  <bruno@clisp.org>
38135         explicit_bzero: Relicense under LGPLv2+.
38136         Approved by Paul Eggert.
38137         * modules/explicit_bzero (License): Change to LGPLv2+.
38139 2020-04-10  Bruno Haible  <bruno@clisp.org>
38141         findprog, relocatable-prog: Ignore directories during PATH search.
38142         Reported by Frederick Eaton via Dmitry Goncharov in
38143         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00003.html>.
38145         * lib/findprog.c (find_in_path): When the file found in a PATH element
38146         is a directory, continue searching.
38147         * modules/findprog (Depends-on): Add sys_stat, stat.
38148         * modules/findprog-lgpl (Depends-on): Likewise.
38150         * lib/progreloc.c (maybe_executable): When the file found in a PATH
38151         element is a directory, continue searching.
38152         * lib/relocwrapper.c: Update comments.
38153         * modules/relocatable-prog-wrapper (Files): Add m4/largefile.m4.
38154         (configure.ac-early): New section.
38156 2020-04-10  Bruno Haible  <bruno@clisp.org>
38158         MODULES.html.sh: Support for reproducible builds from git-less tarballs.
38159         Reported by Bernhard M. Wiedemann <bwiedemann@suse.de> in
38160         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00061.html>.
38161         * MODULES.html.sh: In a git-less tarball, use the date of the first
38162         ChangeLog entry.
38164 2020-04-04  Bruno Haible  <bruno@clisp.org>
38166         Fix comments: The gettext library is under LGPL 2.1, not LGPL 2.0.
38167         * m4/gettext.m4: Fix comments regarding the gettext library.
38168         * m4/intl-thread-locale.m4: Likewise.
38169         * m4/intlmacosx.m4: Likewise.
38170         * m4/lcmessage.m4: Likewise.
38171         * m4/nls.m4: Likewise.
38172         * m4/po.m4: Likewise.
38173         * m4/progtest.m4: Likewise.
38175 2020-04-04  Jim Meyering  <meyering@fb.com>
38177         maint: remove a stray inter-word space in a 6x-repeated comment
38178         Induce the changes by running this:
38179           re='by  perl'; git grep -l "$re"|xargs perl -pi -e "s/$re/by perl/"
38180         * build-aux/announce-gen: Change "by  perl" to "by perl".
38181         * build-aux/gitlog-to-changelog: Likewise.
38182         * build-aux/prefix-gnulib-mk: Likewise.
38183         * build-aux/update-copyright: Likewise.
38184         * build-aux/useless-if-before-free: Likewise.
38185         * tests/test-update-copyright.sh: Likewise.
38187 2020-03-28  Bruno Haible  <bruno@clisp.org>
38189         Use module 'filename' instead of module 'dosname'.
38191         * lib/at-func.c: Include filename.h instead of dosname.h.
38192         * lib/unlinkat.c: Likewise.
38193         * modules/areadlinkat (Depends-on): Add filename. Remove dosname.
38194         * modules/areadlinkat-with-size (Depends-on): Likewise.
38195         * modules/faccessat (Depends-on): Likewise.
38196         * modules/fchmodat (Depends-on): Likewise.
38197         * modules/fchownat (Depends-on): Likewise.
38198         * modules/fstatat (Depends-on): Likewise.
38199         * modules/mkdirat (Depends-on): Likewise.
38200         * modules/mkfifoat (Depends-on): Likewise.
38201         * modules/readlinkat (Depends-on): Likewise.
38202         * modules/selinux-at (Depends-on): Likewise.
38203         * modules/symlinkat (Depends-on): Likewise.
38204         * modules/unlinkat (Depends-on): Likewise.
38205         * modules/utimensat (Depends-on): Likewise.
38207         * lib/at-func2.c: Include filename.h instead of dosname.h.
38208         * modules/linkat (Depends-on): Add filename. Remove dosname.
38209         * modules/renameatu (Depends-on): Likewise.
38211         * lib/canonicalize.c: Include filename.h instead of dosname.h.
38212         * lib/canonicalize-lgpl.c: Likewise.
38213         * modules/canonicalize (Depends-on): Add filename.
38214         * modules/canonicalize-lgpl (Depends-on): Likewise.
38216         * lib/dirname.h: Include filename.h instead of dosname.h.
38217         * modules/dirname-lgpl (Depends-on): Add filename. Remove dosname.
38219         * lib/fchdir.c: Include filename.h instead of dosname.h.
38220         * modules/fchdir (Depends-on): Add filename. Remove dosname.
38222         * lib/openat.c: Include filename.h instead of dosname.h.
38223         * modules/openat (Depends-on): Add filename. Remove dosname.
38225         * lib/rmdir.c: Include filename.h instead of dosname.h.
38226         * modules/rmdir (Depends-on): Add filename. Remove dosname.
38228         * lib/savewd.c: Include filename.h instead of dosname.h.
38229         * modules/savewd (Depends-on): Add filename. Remove dosname.
38231         * lib/unlink.c: Include filename.h instead of dosname.h.
38232         * modules/unlink (Depends-on): Add filename. Remove dosname.
38234         * modules/relocatable-prog-wrapper (Depends-on): Add filename.
38235         * lib/relocwrapper.c: Update comments.
38237         * modules/lstat (Depends-on): Remove dosname.
38239 2020-03-28  Bruno Haible  <bruno@clisp.org>
38241         dosname: Redirect to 'filename'.
38242         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
38243         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00042.html>.
38244         * lib/dosname.h: Remove all definitions. Just include filename.h.
38245         * modules/dosname (Status, Notice): Mark as deprecated.
38246         (Depends-on): Add 'filename'.
38248 2020-03-28  Bruno Haible  <bruno@clisp.org>
38250         dosname: Change IS_RELATIVE_FILE_NAME.
38251         * lib/dosname.h (IS_RELATIVE_FILE_NAME): On native Windows, OS/2, DOS,
38252         change the definition so that IS_RELATIVE_FILE_NAME("c:") is false.
38253         * NEWS: Mention the change.
38255 2020-03-28  Bruno Haible  <bruno@clisp.org>
38257         filename: Copy some definitions from module 'dosname'.
38258         * lib/filename.h: Include <string.h>, for IS_FILE_NAME_WITH_DIR.
38259         (HAS_DEVICE): Document macro.
38260         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New macro.
38261         (IS_ABSOLUTE_FILE_NAME): Consider
38262         FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE.
38263         (IS_RELATIVE_FILE_NAME, IS_FILE_NAME_WITH_DIR): New macros.
38264         (IS_ABSOLUTE_PATH, IS_PATH_WITH_DIR): Define as deprecated aliases.
38265         * lib/relocatable.c (IS_FILE_NAME_WITH_DIR): Renamed from
38266         IS_PATH_WITH_DIR.
38267         (DllMain): Update.
38268         * lib/progreloc.c (IS_FILE_NAME_WITH_DIR): Renamed from
38269         IS_PATH_WITH_DIR.
38270         (find_executable): Update.
38271         * NEWS: Document the deprecations.
38273 2020-03-25  Paul Eggert  <eggert@cs.ucla.edu>
38275         getopt-posix: port __GETOPT_PREFIX to macOS
38276         * lib/getopt-pfx-core.h (_GETOPT) [__APPLE__ && __GETOPT_PREFIX]:
38277         Define to work around a problem with asm on macOS (Bug#40205).
38279 2020-03-22  Bruno Haible  <bruno@clisp.org>
38281         MODULES.html.sh: Add support for reproducible builds.
38282         Reported by Bernhard M. Wiedemann <bwiedemann@suse.de> in
38283         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00024.html>.
38284         * MODULES.html.sh: Print the date of the last gnulib commit, not the
38285         current date.
38287 2020-03-22  Bruno Haible  <bruno@clisp.org>
38289         Several modules: Depend on stat.
38290         * modules/acl-permissions (Depends-on): Add stat.
38291         * modules/canonicalize (Depends-on): Likewise.
38292         * modules/file-has-acl (Depends-on): Likewise.
38293         * modules/fstat (Depends-on): Likewise.
38294         * modules/fstatat (Depends-on): Likewise.
38295         * modules/glob (Depends-on): Likewise.
38296         * modules/javacomp (Depends-on): Likewise.
38297         * modules/linkat (Depends-on): Likewise.
38298         * modules/mkdir (Depends-on): Likewise.
38299         * modules/pt_chown (Depends-on): Likewise.
38300         * modules/ptsname_r (Depends-on): Likewise.
38301         * modules/readlinkat (Depends-on): Likewise.
38302         * modules/rename (Depends-on): Likewise.
38303         * modules/renameatu (Depends-on): Likewise.
38304         * modules/tmpdir (Depends-on): Likewise.
38305         * modules/utimens (Depends-on): Likewise.
38306         * modules/relocatable-prog-wrapper (Depends-on): Add largefile.
38307         * modules/same (Depends-on): Remove stat.
38309 2020-03-22  Bruno Haible  <bruno@clisp.org>
38311         acl-permissions: Improve autoconf macro.
38312         * m4/acl.m4 (gl_FUNC_ACL): Test the value of gl_need_lib_has_acl
38313         more reliably.
38315 2020-03-22  Bruno Haible  <bruno@clisp.org>
38317         file-has-acl: Fix module description.
38318         * modules/file-has-acl (Files): Add lib/acl-internal.h, m4/acl.m4.
38319         (Depends-on): Depend on acl-permissions unconditionally.
38321 2020-03-21  Bruno Haible  <bruno@clisp.org>
38323         unlink: Ensure errno also on native Windows.
38324         * modules/unlink (Depends-on): Add malloc-posix.
38326 2020-03-21  Paul Eggert  <eggert@cs.ucla.edu>
38328         unlink: fix malloc errno typo
38329         Problem reported by Tim Rühsen in:
38330         https://lists.gnu.org/r/bug-gnulib/2020-03/msg00044.html
38331         * lib/unlink.c (rpl_unlink): Don’t mask malloc errno.
38333 2020-03-16  Bruno Haible  <bruno@clisp.org>
38335         *printf-posix: Fix m4 error (regression from 2020-03-08).
38336         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): Enable interpretation of
38337         brackets in AC_COMPILE_IFELSE invocation.
38339 2020-03-08  Bruno Haible  <bruno@clisp.org>
38341         crypto/af_alg, renameatu, same, term-style-control: Depend on fstat.
38342         * modules/crypto/af_alg (Depends-on): Add fstat.
38343         * modules/renameatu (Depends-on): Likewise.
38344         * modules/same (Depends-on): Likewise.
38345         * modules/term-style-control (Depends-on): Likewise.
38347 2020-03-08  Bruno Haible  <bruno@clisp.org>
38349         *printf-posix: Document why it's overridden on some glibc systems.
38350         Reported by Adrian Bunk <bunk@stusta.de> in
38351         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00011.html>.
38352         * doc/posix-functions/*printf.texi: Document the problem with the %n
38353         directive on some glibc systems.
38354         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N, gl_SNPRINTF_DIRECTIVE_N): Adjust
38355         the cross-compilation guesses accordingly.
38357 2020-03-07  Paul Eggert  <eggert@cs.ucla.edu>
38359         open, openat: port to (O_RDWR | O_RDONLY) != 0
38360         Potential portability problem reported by Dan Gohman in:
38361         https://lists.gnu.org/r/bug-gnulib/2020-03/msg00000.html
38362         * lib/open.c (open):
38363         * lib/openat.c (rpl_openat):
38364         Don’t assume O_RDONLY is disjoint from O_RDWR.
38366 2020-03-07  Bruno Haible  <bruno@clisp.org>
38368         openat: Fix theoretically possible issue on GNU/Hurd.
38369         Reported by Dan Gohman <sunfish@mozilla.com> in
38370         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00000.html>.
38371         * lib/openat.c (rpl_openat): When testing whether flags contains O_RDWR,
38372         ignore the bits that are also set in O_RDONLY.
38374 2020-02-24  Bruno Haible  <bruno@clisp.org>
38376         getloadavg: Don't use /usr/local when cross-compiling on AIX.
38377         Reported by Jens Rehsack <sno@netbsd.org> in
38378         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00136.html>.
38379         * m4/getloadavg.m4 (gl_GETLOADAVG): Don't look in /usr/local/lib when
38380         cross-compiling.
38382 2020-02-24  Bruno Haible  <bruno@clisp.org>
38384         fcntl: Add witness of gnulib override.
38385         Reported by Jens Rehsack <sno@netbsd.org> in
38386         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00137.html>.
38387         * lib/fcntl.in.h (GNULIB_defined_rpl_fcntl, GNULIB_defined_fcntl): New
38388         macros.
38390 2020-02-23  Assaf Gordon  <assafgordon@gmail.com>
38392         Update users.txt.
38393         * users.txt: Add datamash, time.
38395 2020-02-23  Bruno Haible  <bruno@clisp.org>
38397         uni*/base: Use 'restrict'.
38398         * lib/unitypes.in.h (_UC_RESTRICT): New macro, based on '_Restrict_'
38399         from lib/regex.h.
38400         * lib/unistr.in.h (u8_cpy, u16_cpy, u32_cpy, u8_strcpy, u16_strcpy,
38401         u32_strcpy, u8_stpcpy, u16_stpcpy, u32_stpcpy, u8_strncpy, u16_strncpy,
38402         u32_strncpy, u8_stpncpy, u16_stpncpy, u32_stpncpy, u8_strcat,
38403         u16_strcat, u32_strcat, u8_strncat, u16_strncat, u32_strncat, u8_strtok,
38404         u16_strtok, u32_strtok): Use '_UC_RESTRICT'.
38405         * lib/uninorm.in.h (u8_normalize, u16_normalize, u32_normalize): Use
38406         '_UC_RESTRICT'.
38407         * lib/uniconv.in.h (u8_conv_to_encoding, u16_conv_to_encoding,
38408         u32_conv_to_encoding): Use '_UC_RESTRICT'.
38409         * lib/unicase.in.h (u8_toupper, u16_toupper, u32_toupper, u8_tolower,
38410         u16_tolower, u32_tolower, u8_totitle, u16_totitle, u32_totitle,
38411         u8_ct_toupper, u16_ct_toupper, u32_ct_toupper, u8_ct_tolower,
38412         u16_ct_tolower, u32_ct_tolower, u8_ct_totitle, u16_ct_totitle,
38413         u32_ct_totitle, u8_casefold, u16_casefold, u32_casefold, u8_ct_casefold,
38414         u16_ct_casefold, u32_ct_casefold, u8_casexfrm, u16_casexfrm,
38415         u32_casexfrm, ulc_casexfrm): Use '_UC_RESTRICT'.
38416         * lib/unilbrk.in.h (u8_possible_linebreaks, u16_possible_linebreaks,
38417         u32_possible_linebreaks, ulc_possible_linebreaks, u8_width_linebreaks,
38418         u16_width_linebreaks, u32_width_linebreaks, ulc_width_linebreaks): Use
38419         '_UC_RESTRICT'.
38420         * lib/uniwbrk.in.h (ulc_wordbreaks): Use '_UC_RESTRICT'.
38421         * lib/unistdio.in.h (ulc_sprintf, ulc_snprintf, ulc_asnprintf,
38422         ulc_vsprintf, ulc_vsnprintf, ulc_vasnprintf, u8_u8_sprintf,
38423         u8_u8_snprintf, u8_u8_asnprintf, u8_u8_vsprintf, u8_u8_vsnprintf,
38424         u8_u8_vasnprintf, u16_u16_sprintf, u16_u16_snprintf, u16_u16_asnprintf,
38425         u16_u16_vsprintf, u16_u16_vsnprintf, u16_u16_vasnprintf,
38426         u32_u32_sprintf, u32_u32_snprintf, u32_u32_asnprintf, u32_u32_vsprintf,
38427         u32_u32_vsnprintf, u32_u32_vasnprintf): Use '_UC_RESTRICT'.
38429 2020-02-23  Bruno Haible  <bruno@clisp.org>
38431         glob, spawn: Use improved '_Restrict_' definition.
38432         * lib/glob.in.h (_Restrict_): Use same definition as in lib/regex.h.
38433         * lib/spawn.in.h (_Restrict_, _Restrict_arr_): Likewise.
38435 2020-02-23  Bruno Haible  <bruno@clisp.org>
38437         crypto/gc: Use 'restrict'.
38438         * lib/gc.h (gc_pbkdf2_hmac, gc_pbkdf2_sha1): Use 'restrict'.
38439         * m4/gc.m4 (gl_GC): Require AC_C_RESTRICT.
38441         crypto/hmac-*: Use 'restrict'.
38442         * lib/hmac.h (hmac_md5, hmac_sha1, hmac_sha256, hmac_sha512): Use
38443         'restrict'.
38444         * modules/crypto/hmac-md5 (configure.ac): Require AC_C_RESTRICT.
38445         * modules/crypto/hmac-sha1 (configure.ac): Likewise.
38446         * modules/crypto/hmac-sha256 (configure.ac): Likewise.
38447         * modules/crypto/hmac-sha512 (configure.ac): Likewise.
38449         crypto/sm3: Use 'restrict'.
38450         * lib/sm3.h (sm3_finish_ctx, sm3_read_ctx, sm3_buffer): Use 'restrict'.
38451         * m4/sm3.m4 (gl_SM3): Require AC_C_RESTRICT.
38453         crypto/*-buffer: Use 'restrict'.
38454         * lib/gl_openssl.h (GL_CRYPTO_FN (_finish_ctx), GL_CRYPTO_FN (_buffer),
38455         GL_CRYPTO_FN (_read_ctx)): Use 'restrict'.
38457         crypto/sha512-buffer: Use 'restrict'.
38458         * lib/sha512.h (sha512_finish_ctx, sha384_finish_ctx, sha512_read_ctx,
38459         sha384_read_ctx, sha512_buffer, sha384_buffer): Use 'restrict'.
38460         * modules/crypto/sha512-buffer (configure.ac): Require AC_C_RESTRICT.
38462         crypto/sha256-buffer: Use 'restrict'.
38463         * lib/sha256.h (sha256_finish_ctx, sha224_finish_ctx, sha256_read_ctx,
38464         sha224_read_ctx, sha256_buffer, sha224_buffer): Use 'restrict'.
38465         * modules/crypto/sha256-buffer (configure.ac): Require AC_C_RESTRICT.
38467         crypto/sha1-buffer: Use 'restrict'.
38468         * lib/sha1.h (sha1_finish_ctx, sha1_read_ctx, sha1_buffer): Use
38469         'restrict'.
38470         * modules/crypto/sha1-buffer (configure.ac): Require AC_C_RESTRICT.
38472         crypto/md5-buffer: Use 'restrict'.
38473         * lib/md5.h (__md5_finish_ctx, __md5_read_ctx, __md5_buffer): Use
38474         'restrict'.
38475         * modules/crypto/md5-buffer (configure.ac): Require AC_C_RESTRICT.
38477         crypto/md4: Use 'restrict'.
38478         * lib/md4.h (md4_finish_ctx, md4_read_ctx, md4_buffer): Use 'restrict'.
38479         * modules/crypto/md4 (configure.ac): Require AC_C_RESTRICT.
38481         crypto/md2: Use 'restrict'.
38482         * lib/md2.h (md2_finish_ctx, md2_read_ctx, md2_buffer): Use 'restrict'.
38483         * modules/crypto/md2 (configure.ac): Require AC_C_RESTRICT.
38485         crypto/rijndael: Use 'restrict'.
38486         * lib/rijndael-api-fst.h (rijndaelBlockEncrypt, rijndaelPadEncrypt,
38487         rijndaelBlockDecrypt, rijndaelPadDecrypt): Use 'restrict'.
38488         * modules/crypto/rijndael (configure.ac): Require AC_C_RESTRICT.
38490         crypto/arctwo: Use 'restrict'.
38491         * lib/arctwo.h (arctwo_encrypt, arctwo_decrypt): Use 'restrict'.
38492         * modules/crypto/arctwo (configure.ac): Require AC_C_RESTRICT.
38494         crypto/arcfour: Use 'restrict'.
38495         * lib/arcfour.h (arcfour_stream): Use 'restrict'.
38496         * modules/crypto/arcfour (configure.ac): Require AC_C_RESTRICT.
38498         careadlinkat: Use 'restrict'.
38499         * lib/careadlinkat.h (careadlinkat): Use 'restrict'.
38500         * modules/careadlinkat (configure.ac): Require AC_C_RESTRICT.
38501         * modules/relocatable-prog-wrapper (configure.ac): Likewise.
38503         regex-quote: Use 'restrict'.
38504         * lib/regex-quote.h (regex_quote_copy): Use 'restrict'.
38505         * modules/regex-quote (configure.ac): Require AC_C_RESTRICT.
38507         system-quote: Use 'restrict'.
38508         * lib/system-quote.h (system_quote_copy): Use 'restrict'.
38509         * modules/system-quote (configure.ac): Require AC_C_RESTRICT.
38511         sh-quote: Use 'restrict'.
38512         * lib/sh-quote.h (shell_quote_copy): Use 'restrict'.
38513         * modules/sh-quote (configure.ac): Require AC_C_RESTRICT.
38515         quotearg: Use 'restrict'.
38516         * lib/quotearg.h (quotearg_buffer): Use 'restrict'.
38517         * m4/quotearg.m4 (gl_QUOTEARG): Require AC_C_RESTRICT.
38519         parse-datetime: Use 'restrict'.
38520         * lib/parse-datetime.h (parse_datetime, parse_datetime2): Use
38521         'restrict'.
38522         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Require AC_C_RESTRICT.
38524         nstrftime: Use 'restrict'.
38525         * lib/strftime.h (nstrftime): Use 'restrict'.
38526         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Require AC_C_RESTRICT.
38528         mbstok_r: Use 'restrict'.
38529         * lib/string.in.h (mbstok_r): Use 'restrict'.
38531         xmemcoll: Use 'restrict'.
38532         * lib/xmemcoll.h (xmemcoll): Use 'restrict'.
38533         * modules/xmemcoll (configure.ac): Require AC_C_RESTRICT.
38535         memcoll: Use 'restrict'.
38536         * lib/memcoll.h (memcoll): Use 'restrict'.
38537         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_C_RESTRICT.
38539         vasnprintf: Use 'restrict'.
38540         * lib/vasnprintf.h (asnprintf, vasnprintf): Use 'restrict'.
38541         * modules/vasnprintf (configure.ac): Require AC_C_RESTRICT.
38543         c-vasnprintf: Use 'restrict'.
38544         * lib/c-vasnprintf.h (c_vasnprintf): Use 'restrict'.
38545         * modules/c-vasnprintf (configure.ac): Require AC_C_RESTRICT.
38547         c-vsnprintf: Use 'restrict'.
38548         * lib/c-vsnprintf.h (c_vsnprintf): Use 'restrict'.
38549         * modules/c-vsnprintf (configure.ac): Require AC_C_RESTRICT.
38551         c-snprintf: Use 'restrict'.
38552         * lib/c-snprintf.h (c_snprintf): Use 'restrict'.
38553         * modules/c-snprintf (configure.ac): Require AC_C_RESTRICT.
38555         astrxfrm: Use 'restrict'.
38556         * lib/astrxfrm.h (astrxfrm): Use 'restrict'.
38557         * modules/astrxfrm (configure.ac): Require AC_C_RESTRICT.
38559         amemxfrm: Use 'restrict'.
38560         * lib/amemxfrm.h (amemxfrm): Use 'restrict'.
38561         * modules/amemxfrm (configure.ac): Require AC_C_RESTRICT.
38563 2020-02-22  Paul Eggert  <eggert@cs.ucla.edu>
38565         fchmodat, lchmod: simplify
38566         It appears that we may have overengineered lchmod and fchmodat,
38567         in that the code was prepared for some hypothetical platforms but
38568         was so complicated that it was hard to understand.  I attempted to
38569         improve the situation by simplifying the code when this
38570         simplification should not hurt on real platforms; we can re-add
38571         complexity later to port to platforms I didn’t know about.
38572         * lib/fchmodat.c (fchmodat):
38573         * lib/lchmod.c (lchmod):
38574         Put the ‘defined __linux__ || defined __ANDROID__’ #ifdef only
38575         around the /proc code that needs it.
38576         * lib/fchmodat.c (fchmodat): Coalese calls to orig_fchmodat.
38577         * lib/lchmod.c (__need_system_sys_stat_h): Omit; no longer needed.
38578         Do not include <config.h> twice.
38579         (orig_lchmod) [HAVE_LCHMOD]: Remove, since we need not wrap
38580         lchmod on any known hosts.
38581         (lchmod): Do not defer to fchmodat, so that the lchmod module
38582         need not depend on the fchmodat module (which is a circular
38583         dependency).  Do not use openat, since ‘open’ suffices.
38584         Coalesce calls to lchmod/chmod.
38585         * lib/lchmod.c, lib/sys_stat.in.h (lchmod):
38586         * m4/sys_stat_h.m4 (REPLACE_FSTAT):
38587         * modules/lchmod (Depends-on, configure.ac):
38588         * modules/sys_stat (Depends-on):
38589         Do not worry about replacing lchmod, since that shouldn’t happen.
38590         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Do not check for fchmodat.
38591         Do not worry about whether lchmod works on non-symlinks,
38592         since every known lchmod works on non-symlinks.
38593         * modules/lchmod (Depends-on):
38594         Remove circular dependency on fchmodat.
38596 2020-02-22  Bruno Haible  <bruno@clisp.org>
38598         lchmod: Fix link error on Solaris 10 (regression from 2020-02-16).
38599         * lib/lchmod.c (lchmod): Use the code with lstat and chmod also when
38600         NEED_LCHMOD_NONSYMLINK_FIX is not defined.
38602 2020-02-22  Bruno Haible  <bruno@clisp.org>
38604         Use 'restrict' in all POSIX function declarations.
38605         * lib/iconv.in.h (iconv): Use 'restrict'.
38606         * lib/inttypes.in.h (strtoimax, strtoumax): Likewise.
38607         * lib/monetary.in.h (strfmon_l): Likewise.
38608         * lib/pthread.in.h (pthread_create, pthread_mutex_init,
38609         pthread_mutexattr_gettype, pthread_mutexattr_getrobust,
38610         pthread_mutex_timedlock, pthread_rwlock_init,
38611         pthread_rwlock_timedrdlock, pthread_rwlock_timedwrlock,
38612         pthread_cond_init, pthread_cond_wait, pthread_cond_timedwait): Likewise.
38613         * lib/search.in.h (tdelete): Likewise.
38614         * lib/signal.in.h (pthread_sigmask, sigprocmask): Likewise.
38615         * lib/stdio.in.h (dprintf, fgets, fopen, fprintf, fputs, fread, freopen,
38616         fscanf, fwrite, getdelim, getline, printf, scanf, snprintf, sprintf,
38617         vdprintf, vfprintf, vfscanf, vprintf, vscanf, vsnprintf, vsprintf):
38618         Likewise.
38619         * lib/stdlib.in.h (mbtowc, realpath, strtod, strtold, strtoll,
38620         strtoull): Likewise.
38621         * lib/string.in.h (strncat): Likewise.
38622         * lib/sys_socket.in.h (accept, getpeername, getsockname, getsockopt,
38623         recvfrom): Likewise.
38624         * lib/sys_stat.in.h (fstatat, lstat, stat): Likewise.
38625         * lib/time.in.h (strftime): Likewise.
38626         * lib/unistd.in.h (readlink, readlinkat): Likewise.
38627         * lib/wchar.in.h (mbrtowc, mbrlen, mbsrtowcs, mbsnrtowcs, wcrtomb,
38628         wcsrtombs, wcsnrtombs, wmemcpy, wcscpy, wcpcpy, wcsncpy, wcpncpy,
38629         wcscat, wcsncat, wcsxfrm, wcsstr, wcstok, wcsftime): Likewise.
38630         * m4/iconv_h.m4 (gl_ICONV_H): Require AC_C_RESTRICT.
38631         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): Likewise.
38632         * m4/monetary_h.m4 (gl_MONETARY_H): Likewise.
38633         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
38634         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
38635         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
38636         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
38637         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
38638         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
38639         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
38640         * m4/wchar_h.m4 (gl_WCHAR_H): Likewise.
38641         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Make consistent with the
38642         other *_h.m4 files.
38643         * m4/time_h.m4 (gl_HEADER_TIME_H): Likewise.
38645 2020-02-22  Bruno Haible  <bruno@clisp.org>
38647         Update NEWS.
38648         * NEWS: Mention the last change.
38650 2020-02-22  Paul Eggert  <eggert@cs.ucla.edu>
38652         chmodat, chownat: new modules
38653         These are split from fchmodat, fchownat.  GNU Emacs needs the
38654         POSIX-specified fchmodat, but not the gnulib-specified chmodat and
38655         lchmodat.  Split the latter two into a new module chmodat.
38656         Similarly for fchownat.  This the same basic idea for why statat
38657         was split from fstatat on 2013-01-23.
38658         * lib/chmodat.c, lib/openat.h (CHMODAT_INLINE):
38659         Rename from FCHMODAT_INLINE.  All uses changed.
38660         * lib/chownat.c, lib/openat.h (CHOWNAT_INLINE):
38661         Rename from FCHOWNAT_INLINE.  All uses changed.
38662         * lib/openat.h:
38663         (chownat, lchownat): Define if GNULIB_CHOWNAT, not GNULIB_FCHOWNAT.
38664         (chmodat, lchmodat): Define if GNULIB_CHMODAT, not GNULIB_FCHMODAT.
38665         * modules/chmodat, modules/chownat, tests/test-chownat.c: New files.
38666         * modules/fchmodat (Files:): Remove lib/fchmodat.c.
38667         (configure.ac): Remove fchmodat module indicator.
38668         (Makefile.am): Omit chmodat.c.
38669         (Maintainer): Add self.
38670         * modules/fchownat: Similarly, but for chown.
38671         * tests/test-fchownat.c (BASE): Don't define if already defined.
38672         (do_chown, do_lchown) [!TEST_CHOWNAT]: Test fchownat instead.
38674 2020-02-22  Bruno Haible  <bruno@clisp.org>
38676         users.txt: Add groff.
38677         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is>.
38678         * users.txt: Add groff.
38680 2020-02-22  Bruno Haible  <bruno@clisp.org>
38682         gnulib-tool: Ensure copied files are writable.
38683         Reported by Benno Fünfstück <benno.fuenfstueck@gmail.com> in
38684         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00101.html>.
38685         * gnulib-tool (func_ensure_writable): New function.
38686         (func_ln_s, func_hardlink, func_lookup_file, func_import,
38687         func_create_testdir, copy-file): Invoke it after copying a file.
38689 2020-02-22  Bruno Haible  <bruno@clisp.org>
38691         users.txt: Update.
38692         * users.txt: Update URLs to projects that have moved or switched to git.
38693         Use canonical host names. Prefer gitweb over cgit. Prefer the tree view
38694         over the summary view. Add gawk.
38696 2020-02-21  Paul Eggert  <eggert@cs.ucla.edu>
38698         largefile: remove _DARWIN_USE_64_BIT_INODE
38699         It’s not needed in currently-supported macOS versions, and was
38700         problematic anyway in MacOS X 10.5 which was the only version that
38701         could use it.  Problem reported by Peter Eisentraut in:
38702         https://lists.gnu.org/r/bug-autoconf/2020-02/msg00004.html
38703         * m4/largefile.m4 (AC_SYS_LARGEFILE):
38704         Don’t define _DARWIN_USE_64_BIT_INODE.
38705         This syncs with Autoconf master.
38707         Add ‘extern "C"’ to count-one-bits.h etc.
38708         This ports these .h files to C++.
38709         Problem reported by Simon Marchi in:
38710         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00110.html
38711         * lib/count-leading-zeros.h, lib/count-one-bits.h:
38712         * lib/count-trailing-zeros.h: Add ‘extern "C"’.
38714 2020-02-19  Bruno Haible  <bruno@clisp.org>
38716         uninorm/decompose-internal: Avoid "no previous prototype" warning.
38717         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
38718         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00105.html>.
38719         * lib/array-mergesort.h: Accept an optional macro definition
38720         STATIC_FROMTO.
38721         * lib/uninorm/decompose-internal.c (STATIC_FROMTO): New macro.
38723 2020-02-16  Bruno Haible  <bruno@clisp.org>
38725         fchmodat: Make more future-proof.
38726         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): Define
38727         NEED_FCHMODAT_NONSYMLINK_FIX.
38728         (gl_PREREQ_FCHMODAT): New macro.
38729         * lib/fchmodat.c (fchmodat): Test NEED_FCHMODAT_NONSYMLINK_FIX. Access
38730         /proc only on Linux. Return EOPNOTSUPP only on Linux and on platforms
38731         without lchmod function.
38732         * modules/fchmodat (configure.ac): Invoke gl_PREREQ_FCHMODAT.
38734 2020-02-16  Bruno Haible  <bruno@clisp.org>
38736         lchmod: Make more future-proof.
38737         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Define NEED_LCHMOD_NONSYMLINK_FIX.
38738         (gl_PREREQ_LCHMOD): New macro.
38739         * lib/lchmod.c (orig_lchmod): New function.
38740         (lchmod): Test NEED_LCHMOD_NONSYMLINK_FIX. Access /proc only on Linux.
38741         Return EOPNOTSUPP only on Linux and on platforms without lchmod
38742         function.
38743         * modules/lchmod (configure.ac): Invoke gl_PREREQ_LCHMOD.
38745         lchmod: Fix buggy override on macOS, HP-UX (regression from 2020-02-08).
38746         * modules/lchmod (Makefile.am): Don't add lchmod.c to lib_SOURCES.
38748 2020-02-16  Paul Eggert  <eggert@cs.ucla.edu>
38750         xnanosleep: prefer pause, and get remaining time
38751         Problem reported by Vladimir Panteleev in:
38752         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00052.html
38753         * lib/xnanosleep.c: Include intprops.h, unistd.h.
38754         (xnanosleep) [HAVE_PAUSE]: Prefer pause when sleeping infinitely.
38755         (xnanosleep): Obtain remaining time when nanosleep is interrupted.
38756         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Check for 'pause'.
38757         * modules/xnanosleep (Depends-on): Add intprops, unistd.
38759 2020-02-16  Bruno Haible  <bruno@clisp.org>
38761         lchmod: Improve cross-compilation guess.
38762         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Require AC_CANONICAL_HOST. When
38763         cross-compiling, guess depending on the platform.
38765 2020-02-16  Bruno Haible  <bruno@clisp.org>
38767         fstrcmp: Add API to clean up resources.
38768         Reported by Akim Demaille <akim@lrde.epita.fr> in
38769         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00080.html>.
38770         * lib/fstrcmp.h (fstrcmp_free_resources): New declaration.
38771         * lib/fstrcmp.c (fstrcmp_free_resources): New function.
38773 2020-02-14  Bruno Haible  <bruno@clisp.org>
38775         wctype-h: Fix compilation errors in C++ (regression from 2020-01-25).
38776         Reported by Christian Biesinger in
38777         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00064.html>.
38778         * lib/wctype.in.h (iswdigit, iswxdigit): Don't declare if the
38779         corresponding module is not enabled.
38780         * tests/test-wctype-h-c++.cc (iswdigit, iswxdigit): Don't check the
38781         prototype if the corresponding module is not enabled.
38783 2020-02-13  Paul Eggert  <eggert@cs.ucla.edu>
38785         fchmodat, lchmod: port to buggy Linux filesystems
38786         Problem reported by Florian Weimer in:
38787         https://www.sourceware.org/ml/libc-alpha/2020-02/msg00534.html
38788         * lib/fchmodat.c (fchmodat):
38789         * lib/lchmod.c (lchmod):
38790         Don’t assume that chmod on the O_PATH-opened fd will do
38791         the right thing on a symbolic link.
38792         * lib/fchmodat.c (fchmodat):
38793         Don’t attempt to special-case
38794         any flag value other than AT_SYMLINK_NOFOLLOW.
38796 2020-02-11  Paul Eggert  <eggert@cs.ucla.edu>
38798         lchmod: pacify Coverity CID 1491216
38799         * lib/lchmod.c (lchmod): Redo #if nesting so that Coverity does
38800         not complain about unreachable code at the ‘struct stat st;’
38801         declaration.
38803 2020-02-10  Bruno Haible  <bruno@clisp.org>
38805         copysignf: Fix link error on HP-UX with cc.
38806         * m4/copysignf.m4 (gl_FUNC_COPYSIGNF): Require AC_CANONICAL_HOST. On
38807         HP-UX, set COPYSIGNF_LIBM to -lm.
38809 2020-02-10  Bruno Haible  <bruno@clisp.org>
38811         pthread-mutex-tests, pthread-rwlock-tests: Fix link errors on HP-UX.
38812         * modules/pthread-mutex-tests (Makefile.am): Link test-pthread-mutex
38813         with $(LIB_SEMAPHORE).
38814         * modules/pthread-rwlock-tests (Makefile.am): Link test-pthread-rwlock
38815         with $(LIB_SEMAPHORE).
38817 2020-02-10  Bruno Haible  <bruno@clisp.org>
38819         ptsname_r-tests: Avoid unused function warning.
38820         * tests/test-ptsname_r.c: Don't include null-ptr.h if we don't need it.
38822 2020-02-08  Bruno Haible  <bruno@clisp.org>
38824         lchmod: Add tests.
38825         * tests/test-lchmod.c: New file.
38826         * modules/lchmod-tests: New file.
38828 2020-02-08  Bruno Haible  <bruno@clisp.org>
38830         lchmod: Ensure declaration on HP-UX.
38831         * lib/sys_stat.in.h (lchown): Declare also on HP-UX.
38832         * doc/glibc-functions/lchmod.texi: Mention the HP-UX problem.
38834 2020-02-08  Bruno Haible  <bruno@clisp.org>
38836         fchmodat: Strengthen tests.
38837         * tests/test-fchmodat.c (BASE): New macro.
38838         (main): Use it, to avoid conflicts with other unit tests. Verify that
38839         fchmodat changed the file permission bits.
38841 2020-02-08  Bruno Haible  <bruno@clisp.org>
38843         fchmodat: Fix endless recursion on Cygwin (regression from 2020-02-07).
38844         * lib/fchmodat.c (orig_fchmodat): Move definition to immediately after
38845         '#undef __need_system_sys_stat_h'.
38847 2020-02-08  Bruno Haible  <bruno@clisp.org>
38849         fchmodat: Improve cross-compilation guesses.
38850         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): Require AC_CANONICAL_HOST. When
38851         cross-compiling, guess depending on the platform.
38852         * doc/posix-functions/fchmodat.texi: Clarify.
38854 2020-02-08  Bruno Haible  <bruno@clisp.org>
38856         Fix compilation errors in a testdir created with --with-c++-tests.
38857         * lib/c++defs.h (_GL_CXXALIASWARN1_2): Do not use __typeof__ (func),
38858         since it does not work any more with g++ >= 4.4.
38860 2020-02-08  Bruno Haible  <bruno@clisp.org>
38862         doc: Update for glibc 2.31.
38863         * doc/glibc-functions/pthread_clockjoin_np.texi: New file.
38864         * doc/gnulib.texi: Include it.
38865         * doc/pastposix-functions/h_errno.texi: Update.
38866         * doc/posix-functions/*.texi: Likewise.
38868 2020-02-08  Kenneth D'souza  <kdsouza@redhat.com>
38870         mountlist: consider smb3 file systems as remote
38871         * lib/mountlist.c (ME_REMOTE): Recognize file systems of type
38872         "smb3" as remote.
38874 2020-02-07  Paul Eggert  <eggert@cs.ucla.edu>
38876         fchmodat: AT_SYMLINK_NOFOLLOW fix for non-symlinks
38877         Fix lchmod, and fchmodat with AT_SYMLINK_NOFOLLOW, so that
38878         they act like chmod on non-symlinks.
38879         * NEWS:
38880         * doc/glibc-functions/lchmod.texi (lchmod):
38881         * doc/posix-functions/fchmodat.texi (fchmodat):
38882         Mention this.
38883         * lib/fchmodat.c: Define __need_system_sys_stat_h before including
38884         config.h, and undef it after including sys/stat.h the first time.
38885         Include fcntl.h, stdio.h, unistd.h, intprops.h, and include
38886         sys/stat.h a second time after defining orig_fchmodat.
38887         (orig_fchmodat) [HAVE_FCHMODAT]: New function.
38888         (fchmodat) [HAVE_FCHMODAT]: Work around the AT_SYMLINK_NOFOLLOW bug.
38889         * lib/lchmod.c: New file.
38890         * lib/sys_stat.in.h (fchmodat, lchmod):
38891         Support replacing these functions.
38892         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): If fchmodat exists,
38893         test that AT_SYMLINK_NOFOLLOW works on non-symlinks.
38894         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Check for lstat.
38895         Test that lchmod works on non-symlinks.
38896         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS):
38897         Default REPLACE_FCHMODAT and REPLACE_LCHMOD to 0.
38898         * modules/fchmodat (Depends-on): Add fstatat, intprops, lchmod, unistd.
38899         (Depends-on, configure.ac): Check REPLACE_FCHMODAT too.
38900         * modules/lchmod (Files): Add lib/lchmod.c.
38901         (Depends-on): Add errno, fcntl-h, fchmodat, intprops, lstat, unistd.
38902         (configure.ac): Compile lchmod.c if needed.
38903         (lib_SOURCES): Add lchmod.c.
38904         * modules/sys_stat (sys/stat.h): Substitute REPLACE_FCHMODAT
38905         and REPLACE_LCHMOD.
38906         * tests/test-fchmodat.c: Include fcntl.h, sys/stat.h.
38907         (main): Test fchmodat with AT_SYMLINK_NOFOLLOW on non-symlinks.
38909 2020-02-05  Marc Dionne  <marc.dionne@auristor.com>  (tiny change)
38911         mountlist: Consider AFS filesystems as remote
38912         df --local relies on the ME_REMOTE macro to determine if a given
38913         mount entry should be considered "local".  There is special logic
38914         for nfs and smb/cifs mounts, but /afs as mounted by OpenAFS, the
38915         kernel's kafs module or AuriStorFS is treated as a local mount.
38916         * lib/mountlist.c (ME_REMOTE): Treat mounts of type 'afs'
38917         (OpenAFS, kernel kafs) and 'auristorfs' (AuriStorFS) as remote.
38919 2020-02-04  Paul Eggert  <eggert@cs.ucla.edu>
38921         Port _Noreturn to older Clang
38922         Problem reported by Jeffery Walton in:
38923         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00013.html
38924         * lib/_Noreturn.h (_Noreturn):
38925         * m4/gnulib-common.m4 (gl_COMMON_BODY):
38926         Assume _Noreturn works in Clang 3.5 and later.
38927         It is documented to work in Clang 3.5:
38928         http://releases.llvm.org/3.5.0/tools/clang/docs/AttributeReference.html
38929         and is not documented in Clang 3.4:
38930         https://releases.llvm.org/3.4/tools/clang/docs/LanguageExtensions.html
38931         Apple sets __clang_version__ to a different value, so use
38932         __apple_build_version__ there.  See:
38933         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00017.html
38935 2020-02-04  Pádraig Brady  <P@draigBrady.com>
38937         test-canonicalize: avoid unused function warning
38938         * tests/test-canonicalize.c: Protect the inclusion of null-ptr.h
38939         with the same guard as that used to protect usage of the null_ptr
38940         function, so that one doesn't get a -Wunused warning.
38941         * tests/test-canonicalize-lgpl.c: Likewise.
38943 2020-02-03  Paul Eggert  <eggert@cs.ucla.edu>
38945         libc-config: port to Apple’s Clang variant
38946         * lib/libc-config.h (__glibc_clang_prereq):
38947         Port to Apple’s Clang variant, which uses a different
38948         numbering scheme for __clang_major__.
38950 2020-02-02  Bruno Haible  <bruno@clisp.org>
38952         Document the new modules list-c++, set-c++, oset-c++, map-c++, omap-c++.
38953         * doc/containers.texi: Document these new modules.
38955 2020-02-02  Bruno Haible  <bruno@clisp.org>
38957         omap-c++: Add tests.
38958         * tests/test-omap-c++.cc: New file.
38959         * modules/omap-c++-tests: New file.
38961         omap-c++: New module.
38962         * lib/gl_omap.hh: New file, based on lib/gl_omap.h.
38963         * modules/omap-c++: New file.
38965 2020-02-02  Bruno Haible  <bruno@clisp.org>
38967         map-c++: Add tests.
38968         * tests/test-map-c++.cc: New file.
38969         * modules/map-c++-tests: New file.
38971         map-c++: New module.
38972         * lib/gl_map.hh: New file, based on lib/gl_map.h.
38973         * modules/map-c++: New file.
38975 2020-02-02  Bruno Haible  <bruno@clisp.org>
38977         oset-c++: Add tests.
38978         * tests/test-oset-c++.cc: New file.
38979         * modules/oset-c++-tests: New file.
38981         oset-c++: New module.
38982         * lib/gl_oset.hh: New file, based on lib/gl_oset.h.
38983         * modules/oset-c++: New file.
38985 2020-02-02  Bruno Haible  <bruno@clisp.org>
38987         set-c++: Add tests.
38988         * tests/test-set-c++.cc: New file.
38989         * modules/set-c++-tests: New file.
38991         set-c++: New module.
38992         * lib/gl_set.hh: New file, based on lib/gl_set.h.
38993         * modules/set-c++: New file.
38995 2020-02-02  Bruno Haible  <bruno@clisp.org>
38997         list-c++: Add tests.
38998         * tests/test-list-c++.cc: New file.
38999         * modules/list-c++-tests: New file.
39001         list-c++: New module.
39002         * lib/gl_list.hh: New file, based on lib/gl_list.h.
39003         * modules/list-c++: New file.
39005 2020-02-02  Bruno Haible  <bruno@clisp.org>
39007         xalloc: Fix compilation error in C++ mode on FreeBSD 12.
39008         * lib/xalloc.h (xalloc_die): Comment out 'extern' keyword before
39009         '_Noreturn'.
39010         * lib/sigpipe-die.h (sigpipe_die): Likewise.
39012 2020-02-02  Pádraig Brady  <P@draigBrady.com>
39014         read-file: reduce max size from SIZE_MAX to PTRDIFF_MAX
39015         On x86_64 with glibc-2.30, gcc 9.2 is giving:
39016           error: argument 2 value '18446744073709551615'
39017           exceeds maximum object size 9223372036854775807
39018           [-Werror=alloc-size-larger-than=]
39019         The details of this restriction are discussed at:
39020         https://stackoverflow.com/q/42574890/4421
39021         * lib/read-file.c: s/SIZE_MAX/PTRDIFF_MAX/
39023 2020-02-02  Pádraig Brady  <P@draigBrady.com>
39025         sysctl.h: avoid including on glibc
39026         * lib/nproc.c: Avoid including deprecated and unneeded header on GLIBC.
39027         * lib/physmem.c: Likewise.
39029 2020-02-02  Bruno Haible  <bruno@clisp.org>
39031         list, set, oset, map, omap: Avoid imperative voice in documentation.
39032         * lib/gl_list.h: Use descriptive sentences instead of imperative voice
39033         in the specification of functions.
39034         * lib/gl_set.h: Likewise.
39035         * lib/gl_oset.h: Likewise.
39036         * lib/gl_map.h: Likewise.
39037         * lib/gl_omap.h: Likewise.
39038         * lib/gl_*.h: Likewise.
39040 2020-02-01  Bruno Haible  <bruno@clisp.org>
39042         ansi-c++-opt: Set CXXFLAGS to "-g -O2" by default.
39043         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): Determine CXXFLAGS like AC_PROG_CXX
39044         does.
39046 2020-01-29  Bruno Haible  <bruno@clisp.org>
39048         array-map, hash-map, linkedhash-map: Fix module description.
39049         * modules/array-map (Description): Fix description.
39050         * modules/hash-map (Description): Likewise.
39051         * modules/linkedhash-map (Description): Likewise.
39053 2020-01-29  Paul Eggert  <eggert@cs.ucla.edu>
39055         dfa: do not depend on isblank
39056         This removes a difference between Gawk dfa.c and Gnulib dfa.c.
39057         * lib/dfa.c (isblank): Define if neither system nor Gnulib does.
39058         * modules/dfa (Depends-on): Remove isblank.
39059         * modules/isblank: Add a module indicator, for lib/dfa.c.
39061         dfa: do not assume 64-bit int
39062         Problem reported for VAX/VMS C (!) by Arnold Robbins in:
39063         https://lists.gnu.org/r/bug-gnulib/2020-01/msg00173.html
39064         * lib/dfa.c (CHARCLASS_PAIR): Bring back this macro.
39065         (CHARCLASS_WORD_BITS, charclass_word) [!UINT_LEAST64_MAX]:
39066         Fall back to 32-bit words.
39067         (CHARCLASS_INIT): Go back to having 8 32-bit args instead
39068         of 4 64-bit args.  All uses changed.
39070 2020-01-27  Paul Eggert  <eggert@cs.ucla.edu>
39072         regex: remove limits-h dependency
39073         * modules/regex (Depends-on): Remove limits-h, since the
39074         code no longer depends on ULONG_WIDTH already being defined.
39076         regex: port to non-GCC pre-IEC-60559
39077         Problem reported by Arnold Robbins in:
39078         https://lists.gnu.org/r/bug-gnulib/2020-01/msg00154.html
39079         * lib/regex_internal.h (ULONG_WIDTH): Make this usable in #if.
39081 2020-01-25  Bruno Haible  <bruno@clisp.org>
39083         c32isxdigit: Add tests.
39084         * tests/test-c32isxdigit.c: New file, based on tests/test-iswxdigit.c.
39085         * tests/test-c32isxdigit.sh: New file.
39086         * modules/c32isxdigit-tests: New file.
39088         c32isxdigit: New module.
39089         * lib/c32isxdigit.c: New file.
39090         * modules/c32isxdigit: New file.
39091         * doc/posix-functions/iswxdigit.texi: Mention the new module.
39093 2020-01-25  Bruno Haible  <bruno@clisp.org>
39095         c32isupper: Add tests.
39096         * tests/test-c32isupper.c: New file.
39097         * tests/test-c32isupper.sh: New file.
39098         * modules/c32isupper-tests: New file.
39100         c32isupper: New module.
39101         * lib/c32isupper.c: New file.
39102         * modules/c32isupper: New file.
39103         * doc/posix-functions/iswupper.texi: Mention the new module.
39105 2020-01-25  Bruno Haible  <bruno@clisp.org>
39107         c32isspace: Add tests.
39108         * tests/test-c32isspace.c: New file.
39109         * tests/test-c32isspace.sh: New file.
39110         * modules/c32isspace-tests: New file.
39112         c32isspace: New module.
39113         * lib/c32isspace.c: New file.
39114         * modules/c32isspace: New file.
39115         * doc/posix-functions/iswspace.texi: Mention the new module.
39117 2020-01-25  Bruno Haible  <bruno@clisp.org>
39119         c32ispunct: Add tests.
39120         * tests/test-c32ispunct.c: New file.
39121         * tests/test-c32ispunct.sh: New file.
39122         * modules/c32ispunct-tests: New file.
39124         c32ispunct: New module.
39125         * lib/c32ispunct.c: New file.
39126         * modules/c32ispunct: New file.
39127         * doc/posix-functions/iswpunct.texi: Mention the new module.
39129 2020-01-25  Bruno Haible  <bruno@clisp.org>
39131         c32isprint: Add tests.
39132         * tests/test-c32isprint.c: New file.
39133         * tests/test-c32isprint.sh: New file.
39134         * modules/c32isprint-tests: New file.
39136         c32isprint: New module.
39137         * lib/c32isprint.c: New file.
39138         * modules/c32isprint: New file.
39139         * doc/posix-functions/iswprint.texi: Mention the new module.
39141 2020-01-25  Bruno Haible  <bruno@clisp.org>
39143         c32islower: Add tests.
39144         * tests/test-c32islower.c: New file.
39145         * tests/test-c32islower.sh: New file.
39146         * modules/c32islower-tests: New file.
39148         c32islower: New module.
39149         * lib/c32islower.c: New file.
39150         * modules/c32islower: New file.
39151         * doc/posix-functions/iswlower.texi: Mention the new module.
39153 2020-01-25  Bruno Haible  <bruno@clisp.org>
39155         c32isgraph: Add tests.
39156         * tests/test-c32isgraph.c: New file.
39157         * tests/test-c32isgraph.sh: New file.
39158         * modules/c32isgraph-tests: New file.
39160         c32isgraph: New module.
39161         * lib/c32isgraph.c: New file.
39162         * modules/c32isgraph: New file.
39163         * doc/posix-functions/iswgraph.texi: Mention the new module.
39165 2020-01-25  Bruno Haible  <bruno@clisp.org>
39167         c32isdigit: Add tests.
39168         * tests/test-c32isdigit.c: New file, based on tests/test-iswdigit.c.
39169         * tests/test-c32isdigit.sh: New file.
39170         * modules/c32isdigit-tests: New file.
39172         c32isdigit: New module.
39173         * lib/c32isdigit.c: New file.
39174         * modules/c32isdigit: New file.
39175         * doc/posix-functions/iswdigit.texi: Mention the new module.
39177 2020-01-25  Bruno Haible  <bruno@clisp.org>
39179         c32iscntrl: Add tests.
39180         * tests/test-c32iscntrl.c: New file.
39181         * tests/test-c32iscntrl.sh: New file.
39182         * modules/c32iscntrl-tests: New file.
39184         c32iscntrl: New module.
39185         * lib/c32iscntrl.c: New file.
39186         * modules/c32iscntrl: New file.
39187         * doc/posix-functions/iswcntrl.texi: Mention the new module.
39189 2020-01-25  Bruno Haible  <bruno@clisp.org>
39191         c32isblank: Add tests.
39192         * tests/test-c32isblank.c: New file.
39193         * tests/test-c32isblank.sh: New file.
39194         * modules/c32isblank-tests: New file.
39196         c32isblank: New module.
39197         * lib/c32isblank.c: New file.
39198         * modules/c32isblank: New file.
39199         * doc/posix-functions/iswblank.texi: Mention the new module.
39201 2020-01-25  Bruno Haible  <bruno@clisp.org>
39203         c32isalpha: Add tests.
39204         * tests/test-c32isalpha.c: New file.
39205         * tests/test-c32isalpha.sh: New file.
39206         * modules/c32isalpha-tests: New file.
39208         c32isalpha: New module.
39209         * lib/c32isalpha.c: New file.
39210         * modules/c32isalpha: New file.
39211         * doc/posix-functions/iswalpha.texi: Mention the new module.
39213 2020-01-25  Bruno Haible  <bruno@clisp.org>
39215         c32isalnum: Add tests.
39216         * tests/test-c32isalnum.c: New file.
39217         * tests/test-c32isalnum.sh: New file.
39218         * modules/c32isalnum-tests: New file.
39220         c32isalnum: New module.
39221         * lib/c32isalnum.c: New file.
39222         * lib/c32is-impl.h: New file.
39223         * modules/c32isalnum: New file.
39224         * doc/posix-functions/iswalnum.texi: Mention the new module.
39226 2020-01-25  Bruno Haible  <bruno@clisp.org>
39228         uchar: Preparations for modules c32isalnum, ..., c32isxdigit.
39229         * lib/uchar.in.h (c32isalnum, c32isalpha, c32isblank, c32iscntrl,
39230         c32isdigit, c32isgraph, c32islower, c32isprint, c32ispunct, c32isspace,
39231         c32isupper, c32isxdigit): New declarations.
39232         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32ISALNUM,
39233         GNULIB_C32ISALPHA, GNULIB_C32ISBLANK, GNULIB_C32ISCNTRL,
39234         GNULIB_C32ISDIGIT, GNULIB_C32ISGRAPH, GNULIB_C32ISLOWER,
39235         GNULIB_C32ISPRINT, GNULIB_C32ISPUNCT, GNULIB_C32ISSPACE,
39236         GNULIB_C32ISUPPER, GNULIB_C32ISXDIGIT.
39237         * modules/uchar (Makefile.am): Substitute GNULIB_C32ISALNUM,
39238         GNULIB_C32ISALPHA, GNULIB_C32ISBLANK, GNULIB_C32ISCNTRL,
39239         GNULIB_C32ISDIGIT, GNULIB_C32ISGRAPH, GNULIB_C32ISLOWER,
39240         GNULIB_C32ISPRINT, GNULIB_C32ISPUNCT, GNULIB_C32ISSPACE,
39241         GNULIB_C32ISUPPER, GNULIB_C32ISXDIGIT.
39242         * tests/test-uchar-c++.cc: Test the signature of c32isalnum, c32isalpha,
39243         c32isblank, c32iscntrl, c32isdigit, c32isgraph, c32islower, c32isprint,
39244         c32ispunct, c32isspace, c32isupper, c32isxdigit.
39246 2020-01-25  Bruno Haible  <bruno@clisp.org>
39248         mbchar, wctype: Use the corrected iswxdigit function.
39249         * modules/mbchar (Depends-on): Add iswxdigit.
39250         * modules/wctype (Depends-on): Likewise.
39252         iswxdigit: Add tests.
39253         * tests/test-iswxdigit.c: New file.
39254         * tests/test-iswxdigit.sh: New file.
39255         * modules/iswxdigit-tests: New file.
39257         iswxdigit: New module.
39258         * m4/iswxdigit.m4: New file.
39259         * lib/wctype.in.h (iswxdigit): Potentially override.
39260         (iswxdigit, rpl_iswxdigit): Test REPLACE_ISWXDIGIT, not
39261         REPLACE_ISWCNTRL. Rely on ISO C compliant definition.
39262         * lib/iswxdigit.c: New file.
39263         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_ISWXDIGIT,
39264         REPLACE_ISWXDIGIT.
39265         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWXDIGIT,
39266         REPLACE_ISWXDIGIT.
39267         * modules/iswxdigit: New file.
39268         * doc/posix-functions/iswxdigit.texi: Mention the portability problem.
39270 2020-01-25  Bruno Haible  <bruno@clisp.org>
39272         lseek: Fix the override to not undo the effects of AC_SYS_LARGEFILE.
39273         Reported by John Donoghue <john.david.donoghue@gmail.com> in
39274         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00146.html>.
39275         * lib/lseek.c (rpl_lseek): When AC_SYS_LARGEFILE has enabled a 64-bit
39276         off_t on mingw, invoke _lseeki64 instead of lseek.
39278 2020-01-25  Bruno Haible  <bruno@clisp.org>
39280         iswdigit tests: Avoid test failure on Cygwin.
39281         * tests/test-iswdigit.c (for_character): If mbrtowc cannot convert the
39282         byte sequence, return 0.
39284         iswdigit: Fix test failure on native Windows.
39285         * lib/wctype.in.h (rpl_iswdigit): Rely on ISO C compliant definition.
39287         mbchar, wctype: Use the corrected iswdigit function.
39288         * modules/mbchar (Depends-on): Add iswdigit.
39289         * modules/wctype (Depends-on): Likewise.
39291         iswdigit: Add tests.
39292         * tests/test-iswdigit.c: New file.
39293         * tests/test-iswdigit.sh: New file.
39294         * modules/iswdigit-tests: New file.
39296         iswdigit: New module.
39297         * m4/iswdigit.m4: New file.
39298         * lib/wctype.in.h (iswdigit): Potentially override.
39299         (iswdigit, rpl_iswdigit): Test REPLACE_ISWDIGIT, not REPLACE_ISWCNTRL.
39300         * lib/iswdigit.c: New file.
39301         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_ISWDIGIT,
39302         REPLACE_ISWDIGIT.
39303         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWDIGIT,
39304         REPLACE_ISWDIGIT.
39305         * modules/iswdigit: New file.
39306         * doc/posix-functions/iswdigit.texi: Mention the portability problem.
39308 2020-01-25  Bruno Haible  <bruno@clisp.org>
39310         hard-locale tests: Make it easy to reuse the musl test.
39311         * m4/musl.m4: New file, extracted from modules/hard-locale-tests.
39312         * modules/hard-locale-tests (Files): Add it.
39313         (configure.ac): Invoke gl_MUSL_LIBC.
39315 2020-01-24  Paul Eggert  <eggert@cs.ucla.edu>
39317         regex: port to Gawk on nonstandard platforms
39318         * lib/regex_internal.h (ULONG_WIDTH): Define if not already defined.
39319         This is useful for Gawk, which does not use the Gnulib stdlib-h
39320         module.  Problem reported by Arnold Robbins in:
39321         https://lists.gnu.org/r/bug-gnulib/2020-01/msg00138.html
39323 2020-01-21  Paul Eggert  <eggert@cs.ucla.edu>
39325         regex: fix bug with >=16 subexpressions
39326         * lib/regex_internal.h (struct re_backref_cache_entry):
39327         Use bitset_word_t as the type of eps_reachable_subexps_map,
39328         instead of unsigned short int.  This fixes a bug I introduced
39329         to glibc in 2005-09-28T17:33:18Z!drepper@redhat.com (glibc commit
39330         2c05d33f90861d074dc12808dafbde30f487b1a0, BZ #1302).
39331         Remove unused member 'unused'.
39333         regex: simplify definition of BITSET_WORD_BITS
39334         * config/srclist.txt: Remove regex.c, regex_internal.h temporarily.
39335         * lib/regex.c (__STDC_WANT_IEC_60559_BFP_EXT__): Define.
39336         * lib/regex_internal.h (BITSET_WORD_BITS):
39337         * modules/regex (Depends-on): Add limits-h.
39338         Simplify now that we can use ULONG_WIDTH.
39340 2020-01-20  Bruno Haible  <bruno@clisp.org>
39342         mbrtoc32: Add note about FreeBSD 12.
39343         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Guess no also on FreeBSD.
39344         * doc/posix-functions/mbrtoc32.texi: Mention that FreeBSD 12 is also
39345         affected.
39347 2020-01-20  Bruno Haible  <bruno@clisp.org>
39349         unistr/u8-uctomb: Fix warning.
39350         Reported by Andreas Schwab <schwab@suse.de> in
39351         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00127.html>.
39352         * lib/unistr/u8-uctomb.c (FALLTHROUGH): New macro.
39353         (u8_uctomb): Add FALLTHROUGH markers.
39355 2020-01-20  Bruno Haible  <bruno@clisp.org>
39357         lock: Fix test-once1 failure on FreeBSD 11 (regression from 2020-01-19).
39358         * lib/glthread/lock.c (glthread_once_multithreaded): New function.
39359         * lib/glthread/lock.h (glthread_once_multithreaded): New declaration.
39360         (glthread_once): Use it.
39362 2020-01-19  Bruno Haible  <bruno@clisp.org>
39364         threadlib: Disable use of weak symbols on FreeBSD 11.
39365         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
39366         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00061.html>.
39367         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): Require AC_CANONICAL_HOST. Test
39368         against a bug in FreeBSD 11.
39370 2020-01-19  Bruno Haible  <bruno@clisp.org>
39372         iconv_open: Improve z/OS support.
39373         * lib/iconv_open-zos.gperf: Choose better aliases. Add mapping for
39374         ISO-8859-3, KOI8-R, KOI8-U, CP775, CP857, CP865, CP1129, CP1131, CP1257.
39375         Remove mapping for EUC-TW.
39377 2020-01-18  Bruno Haible  <bruno@clisp.org>
39379         Rename ~~gnulib.m4 to zzgnulib.m4.
39380         Suggested by Paul Eggert.
39381         * m4/zzgnulib.m4: Renamed from m4/~~gnulib.m4.
39382         * gnulib-tool (func_get_filelist): Update.
39383         * pygnulib/GLModuleSystem.py (getFiles): Likewise.
39385 2020-01-18  Bruno Haible  <bruno@clisp.org>
39387         doc: Update license notices.
39388         * doc/*.texi: Reference the GFDL 1.3 through a URL, rather than by
39389         reference to a section or to a "file as part of this distribution".
39391 2020-01-18  Bruno Haible  <bruno@clisp.org>
39393         Avoid error "m4_require: circular dependency of AC_LANG_COMPILER(C)".
39394         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se> in
39395         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00109.html>.
39396         * m4/00gnulib.m4 (gl_COMPILER_CLANG): Use _AC_COMPILE_IFELSE, not
39397         AC_EGREP_CPP.
39399 2020-01-18  Bruno Haible  <bruno@clisp.org>
39401         Ensure Automake does not drop ~~gnulib.m4.
39402         * m4/~~gnulib.m4 (gl_ZZGNULIB): New macro.
39403         * m4/gnulib-common.m4 (gl_COMMON): Require it.
39405 2020-01-18  Bruno Haible  <bruno@clisp.org>
39407         Fix major regression from 2020-01-10.
39408         Reported by Paul Eggert in
39409         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00079.html>.
39410         * m4/00gnulib.m4 (gl_COMPILER_CLANG, gl_COMPILER_PREPARE_CHECK_DECL):
39411         Don't AC_REQUIRE anything.
39412         (gl_COMPILER_PREPARE_CHECK_DECL): Define through AC_DEFUN, not
39413         AC_DEFUN_ONCE. Use _AC_COMPILE_IFELSE, not AC_COMPILE_IFELSE.
39414         (_AC_CHECK_DECL_BODY): If ac_compile_for_check_decl has not been set,
39415         use ac_compile instead.
39416         (AC_CHECK_DECL): Remove override.
39417         * m4/~~gnulib.m4: New file.
39418         * gnulib-tool (func_get_filelist): Add also ~~gnulib.m4.
39419         * pygnulib/GLModuleSystem.py (getFiles): Likewise.
39421 2020-01-17  Bruno Haible  <bruno@clisp.org>
39422             Paul Eggert  <eggert@cs.ucla.edu>
39424         glob: Fix use-after-free bug.
39425         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
39426         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00102.html>.
39427         * lib/glob.c (__glob): Delay freeing dirname until after the use of
39428         end_name.
39430 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
39432         vcs-to-changelog: Fix parsing of fndecl without args.
39433         * build-aux/vcstocl/frontend_c.py (FNDECL_RE): Fix regular expression
39434         for empty arguments.
39436 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
39438         vcs-to-changelog: Add documentation.
39439         * doc/vcs-to-changelog.texi: New file.
39440         * doc/gnulib.texi (Build Infrastructure Modules): Add vcs-to-changelog
39441         section.
39443 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
39445         vcs-to-changelog: Allow loading of custom quirks file.
39446         * build-aux/vcs_to_changelog.py: New commandline option -q.
39448 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
39450         vcs-to-changelog: Fix formatting of ChangeLog output.
39451         * build-aux/vcstocl/vcs_git.py (list_changes): Add newline in print
39452         output.
39454 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
39456         vcs-to-changelog: Drop python3 shebang from frontend_c.py.
39457         Reported in
39458         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00050.html>.
39459         * build-aux/vcstocl/frontend_c.py: Remove shebang.
39461 2020-01-15  Simon Josefsson  <simon@josefsson.org>
39463         crypto/gc-pbkdf2: New module.
39464         * MODULES.html.sh (func_all_modules): Add gc-pbkdf2.
39465         * NEWS: Deprecated gc-pbkdf2-sha1 in favor of gc-pbkdf2.
39466         * lib/gc-pbkdf2.c: New file.
39467         * lib/gc-pbkdf2-sha1.c: Use new interface.
39468         * lib/gc.h (GC_MAX_DIGEST_SIZE, gc_pbkdf2_hmac): Add.
39469         * modules/crypto/gc-pbkdf2: New file.
39470         * modules/crypto/gc-pbkdf2-tests: New file.
39471         * tests/test-gc-pbkdf2.c: New file.
39473 2020-01-12  Bruno Haible  <bruno@clisp.org>
39475         c32stombs: Add tests.
39476         * tests/test-c32stombs.c: New file, based on tests/test-c32srtombs.c.
39477         * tests/test-c32stombs-1.sh: New file, based on
39478         tests/test-c32srtombs-1.sh.
39479         * tests/test-c32stombs-2.sh: New file, based on
39480         tests/test-c32srtombs-2.sh.
39481         * tests/test-c32stombs-3.sh: New file, based on
39482         tests/test-c32srtombs-3.sh.
39483         * tests/test-c32stombs-4.sh: New file, based on
39484         tests/test-c32srtombs-4.sh.
39485         * modules/c32stombs-tests: New file, based on modules/c32srtombs-tests.
39487         c32stombs: New module.
39488         * lib/uchar.in.h (c32stombs): New declaration.
39489         * lib/c32stombs.c: New file.
39490         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32STOMBS.
39491         * modules/uchar (Makefile.am): Substitute GNULIB_C32STOMBS.
39492         * modules/c32stombs: New file.
39493         * tests/test-uchar-c++.cc: Test the signature of c32stombs.
39494         * doc/posix-functions/wcstombs.texi: Mention the new module.
39496 2020-01-11  Jim Meyering  <meyering@fb.com>
39498         perl: require the "warnings" module
39499         * m4/perl.m4: Also "use warnings", so we reject the perl found
39500         on at least one IRIX 6.5 system. Reported by Bruno Haible in
39501         https://lists.gnu.org/r/sed-devel/2020-01/msg00004.html
39503 2020-01-10  Bruno Haible  <bruno@clisp.org>
39505         Fix major regression from 2020-01-04.
39506         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se> in
39507         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00072.html>.
39508         * m4/00gnulib.m4 (gl_COMPILER_PREPARE_CHECK_DECL): Define through
39509         AC_DEFUN_ONCE.
39510         (AC_CHECK_DECL): Invoke, not require, it.
39512 2020-01-10  Bruno Haible  <bruno@clisp.org>
39514         c32snrtombs: Add tests.
39515         * tests/test-c32snrtombs.c: New file, based on tests/test-wcsnrtombs.c.
39516         * tests/test-c32snrtombs-1.sh: New file, based on
39517         tests/test-wcsnrtombs1.sh.
39518         * tests/test-c32snrtombs-2.sh: New file, based on
39519         tests/test-wcsnrtombs2.sh.
39520         * tests/test-c32snrtombs-3.sh: New file, based on
39521         tests/test-wcsnrtombs3.sh.
39522         * tests/test-c32snrtombs-4.sh: New file, based on
39523         tests/test-wcsnrtombs4.sh.
39524         * modules/c32snrtombs-tests: New file, based on
39525         modules/wcsnrtombs-tests.
39527         c32snrtombs: New module.
39528         * lib/uchar.in.h (c32snrtombs): New declaration.
39529         * lib/wcsnrtombs-impl.h: Parameterize: Use macros FUNC, SCHAR_T,
39530         INTERNAL_STATE, WCRTOMB.
39531         * lib/wcsnrtombs.c (FUNC, SCHAR_T, INTERNAL_STATE, WCRTOMB): New macros.
39532         * lib/c32snrtombs.c: New file.
39533         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32SNRTOMBS.
39534         * modules/uchar (Makefile.am): Substitute GNULIB_C32SNRTOMBS.
39535         * modules/c32snrtombs: New file.
39536         * tests/test-uchar-c++.cc: Test the signature of c32snrtombs.
39537         * doc/posix-functions/wcsnrtombs.texi: Mention the new module.
39539 2020-01-09  Bruno Haible  <bruno@clisp.org>
39541         c32srtombs: Add tests.
39542         * tests/test-c32srtombs.c: New file, based on tests/test-wcsrtombs.c.
39543         * tests/test-c32srtombs-1.sh: New file, based on
39544         tests/test-wcsrtombs1.sh.
39545         * tests/test-c32srtombs-2.sh: New file, based on
39546         tests/test-wcsrtombs2.sh.
39547         * tests/test-c32srtombs-3.sh: New file, based on
39548         tests/test-wcsrtombs3.sh.
39549         * tests/test-c32srtombs-4.sh: New file, based on
39550         tests/test-wcsrtombs4.sh.
39551         * modules/c32srtombs-tests: New file, based on modules/wcsrtombs-tests.
39553         c32srtombs: New module.
39554         * lib/uchar.in.h (c32srtombs): New declaration.
39555         * lib/wcsrtombs-impl.h: Parameterize: Use macros FUNC, SCHAR_T,
39556         INTERNAL_STATE, WCRTOMB.
39557         * lib/wcsrtombs.c (FUNC, SCHAR_T, INTERNAL_STATE, WCRTOMB): New macros.
39558         * lib/c32srtombs.c: New file.
39559         * lib/c32srtombs-state.c: New file, based on lib/wcsrtombs-state.c.
39560         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32SRTOMBS.
39561         * modules/uchar (Makefile.am): Substitute GNULIB_C32SRTOMBS.
39562         * modules/c32srtombs: New file.
39563         * tests/test-uchar-c++.cc: Test the signature of c32srtombs.
39564         * doc/posix-functions/wcsrtombs.texi: Mention the new module.
39566 2020-01-08  Bruno Haible  <bruno@clisp.org>
39568         c32tob: Make consistent with mbrtoc32.
39569         * lib/c32tob.c: Include <stdio.h>, <string.h>, <wchar.h>.
39570         (c32tob): If the char32_t encoding and the wchar_t encoding may differ,
39571         use c32rtomb, not wctob.
39572         * modules/c32tob (Files): Add m4/mbrtoc32.m4.
39573         (Depends-on): Add c32rtomb.
39574         (configure.ac): Require gl_MBRTOC32_SANITYCHECK.
39576 2020-01-08  Bruno Haible  <bruno@clisp.org>
39578         c32rtomb: Add tests.
39579         * tests/test-c32rtomb.c: New file, based on tests/test-wcrtomb.c.
39580         * tests/test-c32rtomb.sh: New file, based on tests/test-wcrtomb.sh.
39581         * tests/test-c32rtomb-w32.c: New file, based on
39582         tests/test-wcrtomb-w32.c.
39583         * tests/test-c32rtomb-w32-1.sh: New file, based on
39584         tests/test-wcrtomb-w32-1.sh.
39585         * tests/test-c32rtomb-w32-2.sh: New file, based on
39586         tests/test-wcrtomb-w32-2.sh.
39587         * tests/test-c32rtomb-w32-3.sh: New file, based on
39588         tests/test-wcrtomb-w32-3.sh.
39589         * tests/test-c32rtomb-w32-4.sh: New file, based on
39590         tests/test-wcrtomb-w32-4.sh.
39591         * tests/test-c32rtomb-w32-5.sh: New file, based on
39592         tests/test-wcrtomb-w32-5.sh.
39593         * tests/test-c32rtomb-w32-6.sh: New file, based on
39594         tests/test-wcrtomb-w32-6.sh.
39595         * tests/test-c32rtomb-w32-7.sh: New file, based on
39596         tests/test-wcrtomb-w32-7.sh.
39597         * modules/c32rtomb-tests: New file.
39599         c32rtomb: New module.
39600         * lib/uchar.in.h (c32rtomb): New declaration.
39601         * lib/c32rtomb.c: New file, based on lib/unistr/u8-uctomb-aux.c.
39602         * m4/c32rtomb.m4: New file.
39603         * m4/uchar.m4 (gl_UCHAR_H): Test whether c32rtomb is declared.
39604         (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32RTOMB, HAVE_C32RTOMB,
39605         REPLACE_C32RTOMB.
39606         * modules/uchar (Makefile.am): Substitute GNULIB_C32RTOMB,
39607         HAVE_C32RTOMB, REPLACE_C32RTOMB.
39608         * modules/c32rtomb: New file.
39609         * tests/test-uchar-c++.cc: Test the signature of c32rtomb.
39610         * doc/posix-functions/c32rtomb.texi: Document the new module.
39611         * doc/posix-functions/wcrtomb.texi: Mention the new module.
39613 2020-01-08  Bruno Haible  <bruno@clisp.org>
39615         mbrtoc32: Use the system's mbrtoc32 if it exists and basically works.
39616         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): New macro.
39617         (gl_FUNC_MBRTOC32): Require it. Set REPLACE_MBRTOC32 if mbrtoc32 exists
39618         but is not working.
39619         * lib/mbrtoc32.c: Include hard-locale.h, <locale.h>.
39620         (mbrtoc32): If the char32_t encoding and the wchar_t encoding may
39621         differ, use the system's mbrtoc32, adding workarounds.
39622         * modules/mbrtoc32 (Depends-on): Add hard-locale.
39623         * doc/posix-functions/mbrtoc32.texi: Mention the Solaris and native
39624         Windows problem.
39625         * lib/btoc32.c: Include <stdio.h>, <string.h>.
39626         (btoc32): If the char32_t encoding and the wchar_t encoding may differ,
39627         use mbrtoc32, not btowc.
39628         * modules/btoc32 (Depends-on): Add mbrtoc32.
39629         * lib/mbsrtoc32s.c (mbsrtoc32s): If the char32_t encoding and the
39630         wchar_t encoding may differ, use mbrtoc32, not mbsrtowcs.
39631         * modules/mbsrtoc32s (Depends-on): Update conditions.
39632         (configure.ac): Compile mbsrtoc32s-state.c unconditionally.
39633         * lib/mbsnrtoc32s.c (mbsnrtoc32s): If the char32_t encoding and the
39634         wchar_t encoding may differ, use mbrtoc32, not mbsnrtowcs.
39635         * modules/mbsnrtoc32s (Depends-on): Update conditions.
39636         (configure.ac): Compile mbsrtoc32s-state.c unconditionally.
39638 2020-01-07  Bruno Haible  <bruno@clisp.org>
39640         wcrtomb: Make multithread-safe, except possibly on IRIX.
39641         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Don't set REPLACE_WCRTOMB to 1 when
39642         REPLACE_MBSTATE_T is set. Define WCRTOMB_C_LOCALE_BUG and
39643         WCRTOMB_RETVAL_BUG.
39644         * lib/wcrtomb.c (wcrtomb): Use original wcrtomb whenever available. Use
39645         wctomb only on IRIX.
39647 2020-01-05  Jim Meyering  <meyering@fb.com>
39649         tests: skip thread-using tests when threading is disabled
39650         sed's configure.ac specifies gl_DISABLE_THREADS, and that caused three
39651         thread-using gnulib tests to fail. Add an #if-guarded exit (77) to each
39652         of those, so they are skipped in this case.
39653         * tests/test-nl_langinfo-mt.c (main): Exit 77 when threading is disabled.
39654         * tests/test-setlocale_null-mt-all.c (main): Likewise.
39655         * tests/test-setlocale_null-mt-one.c (main): Likewise.
39657 2020-01-05  Bruno Haible  <bruno@clisp.org>
39659         tests: Avoid GCC over-optimization caused by _GL_ARG_NONNULL attributes.
39660         Reported by Jim Meyering in
39661         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00040.html>.
39662         * lib/stdlib.in.h (GNULIB_defined_canonicalize_file_name): New macro.
39663         (GNULIB_defined_ptsname_r): New macro.
39664         * tests/test-canonicalize.c (_GL_ARG_NONNULL): Define to empty.
39665         (main): Disable the NULL argument test if canonicalize_file_name does
39666         not come from gnulib.
39667         * tests/test-canonicalize-lgpl.c (_GL_ARG_NONNULL): Define to empty.
39668         (main): Disable the NULL argument test if canonicalize_file_name does
39669         not come from gnulib.
39670         * tests/test-ptsname_r.c (_GL_ARG_NONNULL): Define to empty.
39671         (test_errors): Disable the NULL argument test if ptsname_r does not come
39672         from gnulib.
39674 2020-01-04  Jim Meyering  <meyering@fb.com>
39676         update-copyright: reenable its always-skipped test
39677         * tests/test-update-copyright.sh: Restore the "-pi" options removed
39678         on 2019-06-15. Without those, an internal preliminary test would
39679         fail, causing this test always to be skipped.
39680         Verify that the test is now run and passes via this:
39681           ./gnulib-tool --test --dir /tmp/x --with-tests update-copyright
39683 2020-01-05  Bruno Haible  <bruno@clisp.org>
39685         mbstoc32s: Add tests.
39686         * tests/test-mbstoc32s.c: New file, based on tests/test-mbsrtoc32s.c.
39687         * tests/test-mbstoc32s-1.sh: New file, based on
39688         tests/test-mbsrtoc32s-1.sh.
39689         * tests/test-mbstoc32s-2.sh: New file, based on
39690         tests/test-mbsrtoc32s-2.sh.
39691         * tests/test-mbstoc32s-3.sh: New file, based on
39692         tests/test-mbsrtoc32s-3.sh.
39693         * tests/test-mbstoc32s-4.sh: New file, based on
39694         tests/test-mbsrtoc32s-4.sh.
39695         * modules/mbstoc32s-tests: New file, based on modules/mbsrtoc32s-tests.
39697         mbstoc32s: New module.
39698         * lib/uchar.in.h (mbstoc32s): New declaration.
39699         * lib/mbstoc32s.c: New file.
39700         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBSTOC32S.
39701         * modules/uchar (Makefile.am): Substitute GNULIB_MBSTOC32S.
39702         * modules/mbstoc32s: New file.
39703         * tests/test-uchar-c++.cc: Test the signature of mbstoc32s.
39704         * doc/posix-functions/mbstowcs.texi: Mention the new module.
39706 2020-01-05  Bruno Haible  <bruno@clisp.org>
39708         Tweak recently added tests.
39709         * tests/test-mbrtoc32.c: Make signature consistent with uchar.in.h.
39710         * tests/test-mbsrtoc32s.c: Likewise.
39711         * tests/test-mbsnrtoc32s.c: Likewise.
39713 2020-01-04  Bruno Haible  <bruno@clisp.org>
39715         mbsnrtoc32s: Add tests.
39716         * tests/test-mbsnrtoc32s.c: New file, based on tests/test-mbsnrtowcs.c.
39717         * tests/test-mbsnrtoc32s-1.sh: New file, based on
39718         tests/test-mbsnrtowcs1.sh.
39719         * tests/test-mbsnrtoc32s-2.sh: New file, based on
39720         tests/test-mbsnrtowcs2.sh.
39721         * tests/test-mbsnrtoc32s-3.sh: New file, based on
39722         tests/test-mbsnrtowcs3.sh.
39723         * tests/test-mbsnrtoc32s-4.sh: New file, based on
39724         tests/test-mbsnrtowcs4.sh.
39725         * modules/mbsnrtoc32s-tests: New file, based on
39726         modules/mbsnrtowcs-tests.
39728         mbsnrtoc32s: New module.
39729         * lib/uchar.in.h (mbsnrtoc32s): New declaration.
39730         * lib/mbsnrtowcs-impl.h: Parameterize: Use macros FUNC, DCHAR_T,
39731         INTERNAL_STATE, MBRTOWC.
39732         * lib/mbsnrtowcs.c (FUNC, DCHAR_T, INTERNAL_STATE, MBRTOWC): New macros.
39733         * lib/mbsnrtoc32s.c: New file.
39734         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBSNRTOC32S.
39735         * modules/uchar (Makefile.am): Substitute GNULIB_MBSNRTOC32S.
39736         * modules/mbsnrtoc32s: New file.
39737         * tests/test-uchar-c++.cc: Test the signature of mbsnrtoc32s.
39738         * doc/posix-functions/mbsnrtowcs.texi: Mention the new module.
39740 2020-01-04  Bruno Haible  <bruno@clisp.org>
39742         mbsrtoc32s tests: Enhance test.
39743         * tests/test-mbsrtoc32s.c (main): Include a non-BMP character in the
39744         test strings for UTF-8 and GB18030.
39746 2020-01-04  Bruno Haible  <bruno@clisp.org>
39748         mbsrtoc32s: Fix bug.
39749         * modules/mbsrtoc32s (configure.ac): Require gl_UCHAR_H, to make sure
39750         that SMALL_WCHAR_T is defined.
39752 2020-01-04  Bruno Haible  <bruno@clisp.org>
39754         mbsrtoc32s: Add tests.
39755         * tests/test-mbsrtoc32s.c: New file, based on tests/test-mbsrtowcs.c.
39756         * tests/test-mbsrtoc32s-1.sh: New file, based on
39757         tests/test-mbsrtowcs1.sh.
39758         * tests/test-mbsrtoc32s-2.sh: New file, based on
39759         tests/test-mbsrtowcs2.sh.
39760         * tests/test-mbsrtoc32s-3.sh: New file, based on
39761         tests/test-mbsrtowcs3.sh.
39762         * tests/test-mbsrtoc32s-4.sh: New file, based on
39763         tests/test-mbsrtowcs4.sh.
39764         * modules/mbsrtoc32s-tests: New file, based on modules/mbsrtowcs-tests.
39766         mbsrtoc32s: New module.
39767         * lib/uchar.in.h (mbsrtoc32s): New declaration.
39768         * lib/mbsrtowcs-impl.h: Parameterize: Use macros FUNC, DCHAR_T,
39769         INTERNAL_STATE, MBRTOWC.
39770         * lib/mbsrtowcs.c (FUNC, DCHAR_T, INTERNAL_STATE, MBRTOWC): New macros.
39771         * lib/mbsrtoc32s.c: New file.
39772         * lib/mbsrtoc32s-state.c: New file, based on lib/mbsrtowcs-state.c.
39773         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBSRTOC32S.
39774         * modules/uchar (Makefile.am): Substitute GNULIB_MBSRTOC32S.
39775         * modules/mbsrtoc32s: New file.
39776         * tests/test-uchar-c++.cc: Test the signature of mbsrtoc32s.
39777         * doc/posix-functions/mbsrtowcs.texi: Mention the new module.
39779 2020-01-04  Bruno Haible  <bruno@clisp.org>
39781         mbrtowc, mbrtoc32: Tighten dependendies.
39782         * modules/mbrtowc (Depends-on): Disable hard-locale, mbsinit if
39783         REPLACE_MBSTATE_T is 1.
39784         (configure.ac): Don't compile lc-charset-dispatch.c and mbtowc-lock.c if
39785         REPLACE_MBSTATE_T is 0.
39786         * modules/mbrtoc32 (Depends-on): Remove hard-locale, mbsinit. Disable
39787         mbrtowc dependency if REPLACE_MBSTATE_T is 1.
39788         (configure.ac): Don't compile lc-charset-dispatch.c and mbtowc-lock.c if
39789         REPLACE_MBSTATE_T is 0.
39791 2020-01-04  Bruno Haible  <bruno@clisp.org>
39793         uchar: Decide about _GL_LARGE_CHAR32_T at configure time.
39794         * m4/uchar.m4 (gl_UCHAR_H): Set SMALL_WCHAR_T.
39795         * modules/uchar (Files): Add stdint.m4.
39796         (Makefile.am): Substitute SMALL_WCHAR_T.
39797         * lib/uchar.in.h (_GL_LARGE_CHAR32_T): Rely on SMALL_WCHAR_T.
39799 2020-01-04  Bruno Haible  <bruno@clisp.org>
39801         Fix AC_CHECK_DECL so that it deactivates clang's built-in declarations.
39802         Reported by Martin Storsjö <martin@martin.st> in
39803         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00016.html>.
39804         * m4/00gnulib.m4 (gl_COMPILER_CLANG, gl_COMPILER_PREPARE_CHECK_DECL):
39805         New macros.
39806         (_AC_CHECK_DECL_BODY, AC_CHECK_DECL): Augment.
39808 2020-01-04  Bruno Haible  <bruno@clisp.org>
39810         btoc32: Add tests.
39811         * tests/test-btoc32.c: New file, based on tests/test-btowc.c.
39812         * tests/test-btoc32-1.sh: New file, based on tests/test-btowc1.sh.
39813         * tests/test-btoc32-2.sh: New file, based on tests/test-btowc2.sh.
39814         * modules/btoc32-tests: New file, based on modules/btowc-tests.
39816         btoc32: New module.
39817         * lib/uchar.in.h (btoc32): New declaration.
39818         * lib/btoc32.c: New file.
39819         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_BTOC32.
39820         * modules/uchar (Makefile.am): Substitute GNULIB_BTOC32.
39821         * modules/btoc32: New file.
39822         * tests/test-uchar-c++.cc: Test the signature of btoc32.
39823         * doc/posix-functions/btowc.texi: Mention the new module.
39825 2020-01-03  Bruno Haible  <bruno@clisp.org>
39827         uchar tests: Avoid compilation error with HP cc.
39828         * tests/test-uchar.c: Disable a test when HP cc is in use.
39830 2020-01-03  Bruno Haible  <bruno@clisp.org>
39832         mbrtoc32: Add tests.
39833         * tests/test-mbrtoc32.c: New file, based on tests/test-mbrtowc.c.
39834         * tests/test-mbrtoc32-1.sh: New file, based on tests/test-mbrtowc1.sh.
39835         * tests/test-mbrtoc32-2.sh: New file, based on tests/test-mbrtowc2.sh.
39836         * tests/test-mbrtoc32-3.sh: New file, based on tests/test-mbrtowc3.sh.
39837         * tests/test-mbrtoc32-4.sh: New file, based on tests/test-mbrtowc4.sh.
39838         * tests/test-mbrtoc32-5.sh: New file, based on tests/test-mbrtowc5.sh.
39839         * tests/test-mbrtoc32-w32.c: New file, based on tests/test-mbrtowc-w32.c.
39840         * tests/test-mbrtoc32-w32-1.sh: New file, based on
39841         tests/test-mbrtowc-w32-1.sh.
39842         * tests/test-mbrtoc32-w32-2.sh: New file, based on
39843         tests/test-mbrtowc-w32-2.sh.
39844         * tests/test-mbrtoc32-w32-3.sh: New file, based on
39845         tests/test-mbrtowc-w32-3.sh.
39846         * tests/test-mbrtoc32-w32-4.sh: New file, based on
39847         tests/test-mbrtowc-w32-4.sh.
39848         * tests/test-mbrtoc32-w32-5.sh: New file, based on
39849         tests/test-mbrtowc-w32-5.sh.
39850         * tests/test-mbrtoc32-w32-6.sh: New file, based on
39851         tests/test-mbrtowc-w32-6.sh.
39852         * tests/test-mbrtoc32-w32-7.sh: New file, based on
39853         tests/test-mbrtowc-w32-7.sh.
39854         * modules/mbrtoc32-tests: New file, based on modules/mbrtowc-tests.
39856         mbrtoc32: New module.
39857         * lib/uchar.in.h (mbrtoc32): New declaration.
39858         * lib/mbrtoc32.c: New file, based on lib/mbrtowc.c.
39859         * m4/mbrtoc32.m4: New file, based on m4/mbrtowc.m4.
39860         * m4/uchar.m4 (gl_UCHAR_H): Test whether mbrtoc32 is declared.
39861         (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBRTOC32, HAVE_MBRTOC32,
39862         REPLACE_MBRTOC32.
39863         * modules/uchar (Makefile.am): Substitute GNULIB_MBRTOC32,
39864         HAVE_MBRTOC32, REPLACE_MBRTOC32.
39865         * modules/mbrtoc32: New file, based on modules/mbrtowc.
39866         * tests/test-uchar-c++.cc (mbrtoc32): Verify the signature.
39867         * modules/uchar-c++-tests (Makefile.am): Link test-uchar-c++ with
39868         $(LIB_MBRTOWC).
39869         * doc/posix-functions/mbrtoc32.texi: Document the new module.
39870         * doc/posix-functions/mbrtowc.texi: Mention the new module.
39872 2020-01-03  Bruno Haible  <bruno@clisp.org>
39874         mbrtowc: Refactor to share code with mbrtoc32.
39875         * lib/mbrtowc-impl.h: New file, extracted from lib/mbrtowc.c.
39876         * lib/mbrtowc-impl-utf8.h: Likewise.
39877         * lib/mbrtowc.c (mbrtowc): Define macro FITS_IN_CHAR_TYPE. Include
39878         mbrtowc-impl.h.
39879         * modules/mbrtowc (Files): Add the new files.
39881 2020-01-03  Jim Meyering  <meyering@fb.com>
39883         doc: fix time.texi wording
39884         * doc/posix-headers/time.texi (time.h): Typo.
39886 2020-01-03  Bruno Haible  <bruno@clisp.org>
39888         mbrtowc: Refactor locale charset dispatching.
39889         * lib/lc-charset-dispatch.h: New file, extracted from lib/mbrtowc.c.
39890         * lib/lc-charset-dispatch.c: New file, extracted from lib/mbrtowc.c.
39891         * lib/mbrtowc.c: Include lc-charset-dispatch.h. Don't include
39892         localcharset.h, streq.h.
39893         (enc_t): Remove type.
39894         (locale_enc): Remove function.
39895         (cached_locale_enc): Remove variable.
39896         (locale_enc_cached): Remove function.
39897         (mbrtowc): Invoke locale_encoding_classification.
39898         * m4/mbrtowc.m4 (gl_PREREQ_MBRTOWC): Update comment.
39899         * modules/mbrtowc (Files): Add lc-charset-dispatch.h,
39900         lc-charset-dispatch.c.
39901         (configure.ac): Arrange to compile lc-charset-dispatch.c.
39903 2020-01-03  Paul Eggert  <eggert@cs.ucla.edu>
39905         doc: mention 32-bit time_t issue
39906         * doc/posix-headers/sys_stat.texi (sys/stat.h):
39907         * doc/posix-headers/time.texi (time.h): Mention 2038.
39909 2020-01-03  Bruno Haible  <bruno@clisp.org>
39911         mbrtowc: Ensure the mbtowc_lock is unique.
39912         * lib/mbtowc-lock.c: New file, based on lib/setlocale-lock.c.
39913         * lib/mbtowc-lock.h: New file, extracted from lib/mbrtowc.c and
39914         lib/setlocale_null.c.
39915         * lib/mbrtowc.c: Include headers needed for mbtowc-lock.h. Don't include
39916         glthread/lock.h. Include mbtowc-lock.h.
39917         (mbtowc_lock): Remove declaration.
39918         (mbrtowc): Use mbtowc_with_lock.
39919         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Require gl_PTHREADLIB. Check for
39920         threads.h. Set LIB_MBRTOWC.
39921         (gl_PREREQ_MBTOWC_LOCK): New macro.
39922         * modules/mbrtowc (Files): Add lib/mbtowc-lock.h, lib/mbtowc-lock.c,
39923         lib/windows-initguard.h, m4/threadlib.m4, m4/visibility.m4.
39924         (Depends-on): Remove lock.
39925         (configure.ac): Arrange to compile mbtowc-lock.c.
39926         (Link): Mention $(LIB_MBRTOWC) instead of $(LIBTHREAD).
39927         * modules/acl (Link): Likewise.
39928         * modules/argmatch (Link): Likewise.
39929         * modules/backup-rename (Link): Likewise.
39930         * modules/backupfile (Link): Likewise.
39931         * modules/closein (Link): Likewise.
39932         * modules/closeout (Link): Likewise.
39933         * modules/copy-file (Link): Likewise.
39934         * modules/csharpcomp (Link): Likewise.
39935         * modules/csharpexec (Link): Likewise.
39936         * modules/dfa (Link): Likewise.
39937         * modules/exclude (Link): Likewise.
39938         * modules/fnmatch (Link): Likewise.
39939         * modules/fnmatch-gnu (Link): Likewise.
39940         * modules/fnmatch-posix (Link): Likewise.
39941         * modules/glob (Link): Likewise.
39942         * modules/human (Link): Likewise.
39943         * modules/javacomp (Link): Likewise.
39944         * modules/javaexec (Link): Likewise.
39945         * modules/javaversion (Link): Likewise.
39946         * modules/mbfile (Link): Likewise.
39947         * modules/mbiter (Link): Likewise.
39948         * modules/mbmemcasecmp (Link): Likewise.
39949         * modules/mbmemcasecoll (Link): Likewise.
39950         * modules/mbrlen (Link): Likewise.
39951         * modules/mbscasecmp (Link): Likewise.
39952         * modules/mbscasestr (Link): Likewise.
39953         * modules/mbschr (Link): Likewise.
39954         * modules/mbscspn (Link): Likewise.
39955         * modules/mbsinit (Link): Likewise.
39956         * modules/mbslen (Link): Likewise.
39957         * modules/mbsncasecmp (Link): Likewise.
39958         * modules/mbsnlen (Link): Likewise.
39959         * modules/mbsnrtowcs (Link): Likewise.
39960         * modules/mbspbrk (Link): Likewise.
39961         * modules/mbspcasecmp (Link): Likewise.
39962         * modules/mbsrchr (Link): Likewise.
39963         * modules/mbsrtowcs (Link): Likewise.
39964         * modules/mbssep (Link): Likewise.
39965         * modules/mbsspn (Link): Likewise.
39966         * modules/mbsstr (Link): Likewise.
39967         * modules/mbstok_r (Link): Likewise.
39968         * modules/mbswidth (Link): Likewise.
39969         * modules/mbuiter (Link): Likewise.
39970         * modules/mkdir-p (Link): Likewise.
39971         * modules/propername (Link): Likewise.
39972         * modules/quote (Link): Likewise.
39973         * modules/quotearg (Link): Likewise.
39974         * modules/quotearg-simple (Link): Likewise.
39975         * modules/regex-quote (Link): Likewise.
39976         * modules/rpmatch (Link): Likewise.
39977         * modules/sh-quote (Link): Likewise.
39978         * modules/system-quote (Link): Likewise.
39979         * modules/trim (Link): Likewise.
39980         * modules/unistdio/ulc-asnprintf (Link): Likewise.
39981         * modules/unistdio/ulc-fprintf (Link): Likewise.
39982         * modules/unistdio/ulc-vasnprintf (Link): Likewise.
39983         * modules/unistdio/ulc-vasprintf (Link): Likewise.
39984         * modules/unistdio/ulc-vfprintf (Link): Likewise.
39985         * modules/unistdio/ulc-vsnprintf (Link): Likewise.
39986         * modules/unistdio/ulc-vsprintf (Link): Likewise.
39987         * modules/xfreopen (Link): Likewise.
39988         * modules/xmemcoll (Link): Likewise.
39989         * modules/yesno (Link): Likewise.
39990         * modules/regex (Link): Add $(LIB_MBRTOWC).
39991         * modules/acl-tests (Makefile.am): Link the programs with $(LIB_MBRTOWC)
39992         instead of $(LIBTHREAD).
39993         * modules/argmatch-tests (Makefile.am): Likewise.
39994         * modules/closein-tests (Makefile.am): Likewise.
39995         * modules/copy-file-tests (Makefile.am): Likewise.
39996         * modules/dfa-tests (Makefile.am): Likewise.
39997         * modules/fnmatch-tests (Makefile.am): Likewise.
39998         * modules/glob-tests (Makefile.am): Likewise.
39999         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
40000         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
40001         * modules/mbrtowc-tests (Makefile.am): Likewise.
40002         * modules/mbscasecmp-tests (Makefile.am): Likewise.
40003         * modules/mbscasestr-tests (Makefile.am): Likewise.
40004         * modules/mbschr-tests (Makefile.am): Likewise.
40005         * modules/mbscspn-tests (Makefile.am): Likewise.
40006         * modules/mbsinit-tests (Makefile.am): Likewise.
40007         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
40008         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
40009         * modules/mbspbrk-tests (Makefile.am): Likewise.
40010         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
40011         * modules/mbsrchr-tests (Makefile.am): Likewise.
40012         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
40013         * modules/mbsspn-tests (Makefile.am): Likewise.
40014         * modules/mbsstr-tests (Makefile.am): Likewise.
40015         * modules/quotearg-simple-tests (Makefile.am): Likewise.
40016         * modules/quotearg-tests (Makefile.am): Likewise.
40017         * modules/readtokens-tests (Makefile.am): Likewise.
40018         * modules/sh-quote-tests (Makefile.am): Likewise.
40019         * modules/system-quote-tests (Makefile.am): Likewise.
40020         * modules/unistdio/ulc-asnprintf-tests (Makefile.am): Likewise.
40021         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
40022         * modules/unistdio/ulc-vasprintf-tests (Makefile.am): Likewise.
40023         * modules/unistdio/ulc-vsnprintf-tests (Makefile.am): Likewise.
40024         * modules/unistdio/ulc-vsprintf-tests (Makefile.am): Likewise.
40025         * modules/yesno-tests (Makefile.am): Likewise.
40026         * modules/exclude-tests (Makefile.am): Link the programs with
40027         $(LIB_MBRTOWC).
40028         * modules/regex-tests (Makefile.am): Likewise.
40029         * modules/regex-quote-tests (Makefile.am): Likewise.
40031 2020-01-03  Bruno Haible  <bruno@clisp.org>
40033         getopt-posix: Fix compilation failure in testdirs.
40034         * lib/unistd.in.h: Include <getopt-cdefs.h> and <getopt-pfx-core.h> only
40035         when the gnulib module 'getopt-posix' is enabled.
40036         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETOPT_POSIX.
40037         * modules/getopt-posix (configure.ac): Set GNULIB_GETOPT_POSIX as a
40038         module indicator.
40039         * modules/unistd (Makefile.am): Substitute GNULIB_GETOPT_POSIX.
40041 2020-01-03  Bruno Haible  <bruno@clisp.org>
40043         doc: Mention the 64-bit inode number problem.
40044         * m4/largefile.m4 (AC_SYS_LARGEFILE): Mention that this macro fixes the
40045         64-bit inode number problem.
40046         * doc/posix-functions/stat.texi: Mention that this module fixes the
40047         64-bit inode number problem.
40048         * doc/posix-functions/lstat.texi: Likewise.
40049         * doc/posix-functions/fstat.texi: Likewise.
40050         * doc/posix-functions/readdir.texi: Add more details.
40051         * doc/posix-functions/readdir_r.texi: Likewise.
40053 2020-01-02  Bruno Haible  <bruno@clisp.org>
40055         wcrtomb: Add more tests.
40056         * tests/test-wcrtomb-w32.c: Include localcharset.h.
40057         (test_one_locale): For the GB18030 and UTF-8 tests, verify that
40058         locale_charset() returns the expected value; otherwise, skip the test.
40059         * tests/test-wcrtomb-w32-6.sh: Remove old comment.
40060         * tests/test-wcrtomb-w32-7.sh: Likewise.
40061         * modules/wcrtomb-tests (Files): Add these files.
40062         (Depends-on): Add localcharset.
40063         (TESTS): Add test-wcrtomb-w32-6.sh, test-wcrtomb-w32-7.sh.
40065 2020-01-02  Bruno Haible  <bruno@clisp.org>
40067         mbrtowc: Add more tests.
40068         * tests/test-mbrtowc-w32.c: Include localcharset.h.
40069         (test_one_locale): For the GB18030 and UTF-8 tests, verify that
40070         locale_charset() returns the expected value; otherwise, skip the test.
40071         * tests/test-mbrtowc-w32-6.sh: Remove old comment.
40072         * tests/test-mbrtowc-w32-7.sh: Likewise.
40073         * modules/mbrtowc-tests (Files): Add these files.
40074         (Depends-on): Add localcharset.
40075         (TESTS): Add test-mbrtowc-w32-6.sh, test-mbrtowc-w32-7.sh.
40077 2020-01-02  Bruno Haible  <bruno@clisp.org>
40079         mbrtowc: Fix test failures on MSVC (regression by previous commit).
40080         * m4/mbrtowc.m4 (gl_MBRTOWC_STORES_INCOMPLETE): New macro.
40081         (gl_FUNC_MBRTOWC): Invoke it. Define MBRTOWC_STORES_INCOMPLETE_BUG.
40082         * lib/mbrtowc.c (rpl_mbrtowc): Add workaround for
40083         MBRTOWC_STORES_INCOMPLETE_BUG.
40084         * doc/posix-functions/mbrtowc.texi: Mention the MSVC bug.
40086 2020-01-02  Paul Eggert  <eggert@cs.ucla.edu>
40088         doc: mention glibc bug 24269
40089         * doc/regex.texi (Back-reference Operator): Add glibc bug 24269.
40090         Reformat slightly so that it looks nicer in the Grep manual.
40092 2020-01-02  Bruno Haible  <bruno@clisp.org>
40094         mbrtowc: Don't replace mbstate_t on MSVC.
40095         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN): Require AC_CANONICAL_HOST. Ignore
40096         a missing mbsinit function on native Windows.
40097         * lib/wchar.in.h (GNULIB_defined_mbstate_t): Likewise.
40098         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Strengthen the test, to detect an
40099         MSVC bug.
40100         * doc/posix-functions/wcrtomb.texi: Mention the MSVC bug.
40102 2020-01-02  Bruno Haible  <bruno@clisp.org>
40104         setlocale-null: Avoid crashing the MSVC linker.
40105         * lib/setlocale-lock.c: Don't define IMP(gl_get_setlocale_null_lock) on
40106         MSVC.
40108 2020-01-02  Bruno Haible  <bruno@clisp.org>
40110         wchar: Make the HP-UX workaround work on HP-UX 11.31.
40111         * modules/wchar (Depends-on): Add inttypes-incomplete.
40112         * lib/inttypes.in.h: Define _GL_FINISHED_INCLUDING_SYSTEM_INTTYPES_H.
40113         * lib/wchar.in.h: Test _GL_FINISHED_INCLUDING_SYSTEM_INTTYPES_H instead
40114         of strtoimax.
40116 2020-01-02  Bruno Haible  <bruno@clisp.org>
40118         mbrtowc: Fix compilation error on IRIX (regression from 2019-12-26).
40119         * lib/mbrtowc.c: Include <stdint.h>.
40120         * modules/mbrtowc (Depends-on): Add stdint.
40122 2020-01-01  Pádraig Brady  <P@draigBrady.com>
40124         md5, sha1, sha256, sha512: support --with-openssl=auto-gpl-compat
40125         * m4/gl-openssl.m4: Add a new "auto-gpl-compat" mode,
40126         which will auto enable use of openssl, only for >= version 3,
40127         which is newly licensed under the Apache Software License.
40129 2020-01-01  Bruno Haible  <bruno@clisp.org>
40131         mbrtowc: Include function name in macro names.
40132         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Define
40133         MBRTOWC_IN_C_LOCALE_MAYBE_EILSEQ, not C_LOCALE_MAYBE_EILSEQ.
40134         (gl_MBRTOWC_C_LOCALE): Change cache variable name to
40135         gl_cv_func_mbrtowc_C_locale_sans_EILSEQ.
40136         * lib/mbrtowc.c: Test MBRTOWC_IN_C_LOCALE_MAYBE_EILSEQ, not
40137         C_LOCALE_MAYBE_EILSEQ.
40139 2020-01-01  Bruno Haible  <bruno@clisp.org>
40141         c32tob: New module.
40142         * lib/uchar.in.h (_GL_LARGE_CHAR32_T): New macro.
40143         (c32tob): New declaration.
40144         * lib/c32tob.c: New file.
40145         * m4/uchar.m4 (gl_UCHAR_MODULE_INDICATOR, gl_UCHAR_H_DEFAULTS): New
40146         macros.
40147         (gl_UCHAR_H): Require gl_UCHAR_H_DEFAULTS.
40148         * modules/uchar (Depends-on): Add snippet/c++defs.
40149         (Makefile.am): Include c++defs.h and substitute GNULIB_C32TOB in
40150         uchar.h.
40151         * modules/c32tob: New file.
40152         * tests/test-uchar.c: Verify that _GL_LARGE_CHAR32_T is correctly
40153         defined.
40154         * tests/test-uchar-c++.cc: Include signature.h. Test the signature of
40155         c32tob.
40156         * modules/uchar-c++-tests (Files): Add tests/signature.h.
40157         * doc/posix-functions/wctob.texi: Mention the new module.
40159 2020-01-01  Bruno Haible  <bruno@clisp.org>
40161         locale C++ tests: Fix link error on AIX (regression from 2019-12-18).
40162         * modules/locale-c++-tests (Makefile.am): Link test-locale-c++ with
40163         $(LIB_SETLOCALE).
40165 2020-01-01  Bruno Haible  <bruno@clisp.org>
40167         hard-locale tests: Fix a conflict with the C++ tests.
40168         * modules/hard-locale-tests (Makefile.am): Build a program named
40169         'current-locale', not 'locale'.
40171 2020-01-01  Bruno Haible  <bruno@clisp.org>
40173         doc: Update documentation about wchar_t.
40174         * doc/*/*wc*.texi: Clarify that 64-bit AIX does not have a too small
40175         wchar_t type.
40177 2020-01-01  Bruno Haible  <bruno@clisp.org>
40179         mbrtowc tests: Fix typos.
40180         * tests/test-mbrtowc.c (main): Fix typo.
40181         * tests/test-mbrtowc-w32.c (test_one_locale): Likewise.
40183 2019-12-31  Paul Eggert  <eggert@cs.ucla.edu>
40185         maint: update copyright notices
40186         Before doing the following changes done by hand, I also ran ‘make
40187         update-copyright’ and ‘config/srclist-update <config/srclist.txt’
40188         to do most of the copyright years automatically.  A few upstream
40189         sources are still in 2019 but these should eventually be changed
40190         automatically too.
40191         * build-aux/declared.sh (func_version):
40192         * build-aux/libtool-next-version (func_version):
40193         * build-aux/run-test (func_version):
40194         Update these notices by hand.  Put just the last year
40195         in output of programs, as per GNU coding standards.
40197 2019-12-31  Bruno Haible  <bruno@clisp.org>
40199         uchar: Add C++ tests.
40200         * tests/test-uchar-c++.cc: New file.
40201         * tests/test-uchar-c++2.cc: New file.
40202         * modules/uchar-c++-tests: New file.
40204         uchar: Add tests.
40205         * tests/test-uchar.c: New file.
40206         * modules/uchar-tests: New file.
40208         uchar: New module.
40209         * lib/uchar.in.h: New file.
40210         * m4/uchar.m4: New file.
40211         * modules/uchar: New file.
40212         * doc/posix-headers/uchar.texi: Mention the new module.
40214 2019-12-30  Jim Meyering  <meyering@fb.com>
40216         localeinfo: ->simple would be wrong for LC_ALL=C
40217         That would lead to using unnecessary and expensive code paths in dfa.c.
40218         * lib/localeinfo.c (using_simple_locale): Fix recently-introduced logic
40219         error that would have made grep many times slower in the C locale.
40220         With this change, and a file created like this:
40221           yes 00 | head -10000000 > in
40222         Running grep as follows becomes more than 40 times faster:
40223           LC_ALL=C grep -Fw 0 in
40225 2019-12-30  Paul Eggert  <eggert@cs.ucla.edu>
40227         doc: document trouble with back-references
40228         * doc/regex.texi (Back-reference Operator): Mention bugs etc.
40230 2019-12-29  Paul Eggert  <eggert@cs.ucla.edu>
40232         doc: use “back-reference” for \1 etc.
40233         * doc/regex.texi: Consistently spell “back-reference” with
40234         a hyphen, since that’s how POSIX does it.
40236 2019-12-26  Jim Meyering  <meyering@fb.com>
40238         test-framework-sh: tighten an internal grep regexp
40239         * tests/init.sh (gl_shell_test_script_): Tighten the grep regexp
40240         that helps test for a working printf.
40242 2019-12-26  Bruno Haible  <bruno@clisp.org>
40244         test-framework-sh: Avoid /bin/sh on AIX 7.2 due to its printf built-in.
40245         Reported by Paul Eggert in
40246         <https://lists.gnu.org/archive/html/grep-devel/2019-12/msg00020.html>.
40247         Simplification by Jim Meyering.
40248         * tests/init.sh (gl_shell_test_script_): Add a test of printf of an
40249         octal escape sequence in a UTF-8 locale.
40251 2019-12-26  Paul Eggert  <eggert@cs.ucla.edu>
40253         mbrtowc: port better to narrow-wchar_t platforms
40254         * lib/mbrtowc.c (mbrtowc): On platforms like AIX 7.2, where
40255         wchar_t is too narrow to represent all the Unicode characters,
40256         consider a byte sequence for an out-of-wchar_t-range character to
40257         be an encoding error.  This fixes grep’s surrogate-pair test
40258         failure on AIX 7.2.
40260 2019-12-24  Bruno Haible  <bruno@clisp.org>
40262         localcharset: Avoid referencing rpl_setlocale on native Windows.
40263         * lib/localcharset.c (setlocale): Undefine.
40265 2019-12-24  Bruno Haible  <bruno@clisp.org>
40267         lock tests: Fix link error on HP-UX/hppa (regression from 2019-12-21).
40268         * m4/semaphore.m4: New file.
40269         * modules/lock-tests (Files): Add it.
40270         (configure.ac): Require gl_SEMAPHORE.
40271         (Makefile.am): Link test-lock with $(LIB_SEMAPHORE).
40273 2019-12-24  Paul Eggert  <eggert@cs.ucla.edu>
40275         strptime: fix typo in previous patch
40276         Problem and fix reported by Bruno Haible in:
40277         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00202.html
40278         * lib/strptime.c (day_of_the_week): Fix paren bug.
40280 2019-12-24  Bruno Haible  <bruno@clisp.org>
40282         setlocale-null: Make it easy to rely on the lock in another library.
40283         * lib/setlocale-lock.c: Do not define anything if OMIT_SETLOCALE_LOCK is
40284         defined.
40286 2019-12-23  Paul Eggert  <eggert@cs.ucla.edu>
40288         gethrxtime, mktime, nstrftime, strptime: tweak division performance
40289         Performanced analyzed by Bruno Haible in:
40290         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00200.html
40291         * config/srclist.txt: Do not sync mktime.c for now.
40292         * lib/mktime.c (shr, ydhms_diff):
40293         * lib/nstrftime.c (SHR, tm_diff, __strftime_internal):
40294         * lib/strptime.c (day_of_the_week):
40295         * lib/xtime.h (xtime_sec):
40296         Redo with neither ‘%’ nor conditional branches.
40298 2019-12-23  Bruno Haible  <bruno@clisp.org>
40300         setlocale-null: Export the lock function also on non-Windows platforms.
40301         * lib/setlocale-lock.c (DLL_EXPORTED): New macro.
40302         (gl_get_setlocale_null_lock): Declare as DLL_EXPORTED.
40303         * m4/setlocale_null.m4 (gl_PREREQ_SETLOCALE_LOCK): New macro.
40304         * modules/setlocale-null (configure.ac): Invoke it.
40305         (Files): Add m4/visibility.m4.
40307 2019-12-22  Paul Eggert  <eggert@cs.ucla.edu>
40309         gethrxtime: fix rounding bug with negative args
40310         Problem reported by Bruno Haible in:
40311         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00192.html
40312         * lib/xtime.h (xtime_sec): Simplify calculation and correct bug
40313         with negative rounding.  Common platforms can compute / and % with
40314         a single instruction, so the simplified code should be shorter and
40315         faster on these platforms anyway.
40317 2019-12-22  Bruno Haible  <bruno@clisp.org>
40319         gethrxtime: remove incorrect overflow detection
40320         * lib/xtime.h (xtime_make): Remove attempt to prevent internal
40321         integer overflow, as it didn’t suffice.  This reverts the xtime.h
40322         part of 2018-10-12T04:46:09Z!akim.demaille@gmail.com, which I
40323         cannot now see the need for anyway (even in cases where it works),
40324         as the patch is helpful only when the signs of S and NS disagree,
40325         and all callers pass nonnegative values for S and NS.
40327 2019-12-22  Bruno Haible  <bruno@clisp.org>
40329         setlocale-null: Add standalone include file.
40330         * lib/setlocale_null.h: New file, extracted from lib/locale.in.h.
40331         * lib/locale.in.h: Include setlocale_null.h.
40332         (SETLOCALE_NULL_MAX, SETLOCALE_NULL_ALL_MAX, setlocale_null_r,
40333         setlocale_null): Remove declarations.
40334         * lib/setlocale_null.c: Include setlocale_null.h.
40335         * lib/localename.c: Likewise.
40336         * modules/setlocale-null (Files): Add lib/setlocale_null.h.
40337         (Depends-on): Add snippet/arg-nonnull.
40338         (Include): Allow either "setlocale_null.h" or <locale.h>.
40340 2019-12-22  Bruno Haible  <bruno@clisp.org>
40342         strfmon_l: Fix test failures on FreeBSD and Cygwin.
40343         * m4/strfmon_l.m4 (gl_FUNC_STRFMON_L): Require gt_LOCALE_FR_UTF8. Add an
40344         AC_RUN_IFELSE test.
40345         * modules/strfmon_l (Files): Add locale-fr.m4, codeset.m4.
40346         * doc/posix-functions/strfmon_l.texi: Mention the FreeBSD and Cygwin
40347         problem.
40349 2019-12-22  Bruno Haible  <bruno@clisp.org>
40351         Prefer lib_SOURCES to unconditional AC_LIBOBJ.
40352         * modules/at-internal: Prefer a lib_SOURCES augmentation to an
40353         unconditional AC_LIBOBJ.
40354         * modules/selinux-at: Likewise.
40355         * modules/xmemdup0: Likewise.
40356         * modules/xstrtoll: Likewise.
40358 2019-12-22  Bruno Haible  <bruno@clisp.org>
40360         longlong: Mark module obsolete.
40361         * modules/longlong (Status, Notice): New sections.
40363         stdint: Assume that the compiler supports 'long long'.
40364         * lib/stdint.in.h (int64_t, uint64_t, intmax_t, uintmax_t, INT64_C,
40365         UINT64_C, INTMAX_C, UINTMAX_C): Assume HAVE_LONG_LONG_INT and
40366         HAVE_UNSIGNED_LONG_LONG_INT to be 1.
40367         * m4/stdint.m4 (gl_STDINT_H): Don't require AC_TYPE_LONG_LONG_INT,
40368         AC_TYPE_UNSIGNED_LONG_LONG_INT.
40369         * modules/stdint (Files): Remove longlong.m4.
40370         (Makefile.am): Don't substitute HAVE_LONG_LONG_INT,
40371         HAVE_UNSIGNED_LONG_LONG_INT.
40373         inttypes-incomplete: Assume that the compiler supports 'long long'.
40374         * lib/inttypes.in.h (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX,
40375         _SCNu64_PREFIX): Assume HAVE_LONG_LONG_INT and
40376         HAVE_UNSIGNED_LONG_LONG_INT to be 1.
40377         * m4/inttypes.m4 (gl_INTTYPES_CHECK_LONG_LONG_INT_CONDITION): Assume
40378         HAVE_LONG_LONG_INT to be 1.
40379         * modules/inttypes-incomplete (Makefile.am): Don't substitute
40380         HAVE_LONG_LONG_INT, HAVE_UNSIGNED_LONG_LONG_INT.
40382         malloca: Assume that the compiler supports 'long long'.
40383         * lib/malloca.h: Assume HAVE_LONG_LONG_INT to be 1.
40384         * m4/malloca.m4 (gl_MALLOCA): Don't require AC_TYPE_LONG_LONG_INT.
40385         * modules/malloca (Files): Remove longlong.m4.
40386         * modules/relocatable-prog-wrapper (Files): Likewise.
40388         atoll: Assume that the compiler supports 'long long'.
40389         * m4/atoll.m4 (gl_FUNC_ATOLL): Don't require AC_TYPE_LONG_LONG_INT.
40390         * modules/atoll (Files): Remove longlong.m4.
40392         strtoll: Assume that the compiler supports 'long long'.
40393         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Don't require AC_TYPE_LONG_LONG_INT.
40394         * modules/strtoll (Files): Remove longlong.m4.
40396         strtoull: Assume that the compiler supports 'long long'.
40397         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Don't require
40398         AC_TYPE_UNSIGNED_LONG_LONG_INT.
40399         * modules/strtoull (Files): Remove longlong.m4.
40401         strtoimax, strtoumax: Assume that the compiler supports 'long long'.
40402         * lib/strtoimax.c: Assume HAVE_LONG_LONG_INT and
40403         HAVE_UNSIGNED_LONG_LONG_INT to be 1.
40404         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Don't require
40405         AC_TYPE_LONG_LONG_INT.
40406         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't require
40407         AC_TYPE_UNSIGNED_LONG_LONG_INT.
40408         * modules/strtoimax (Files): Remove longlong.m4.
40409         * modules/strtoumax (Files): Likewise.
40411         xstrtoll: Assume that the compiler supports 'long long'.
40412         * lib/xstrtol.h (xstrtoll, xstrtoull): Declare unconditionally.
40413         * modules/xstrtoll (configure.ac): Don't invoke AC_TYPE_LONG_LONG_INT.
40415         vasnprintf: Assume that the compiler supports 'long long'.
40416         * lib/printf-args.h: Assume HAVE_LONG_LONG_INT to be 1.
40417         * lib/printf-args.c (PRINTF_FETCHARGS): Likewise.
40418         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
40419         * lib/vasnprintf.c (MAX_ROOM_NEEDED, VASNPRINTF): Likewise.
40420         * m4/intmax_t.m4 (gl_AC_TYPE_INTMAX_T, gt_AC_TYPE_INTMAX_T): Don't
40421         require AC_TYPE_LONG_LONG_INT.
40422         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
40423         gl_PREREQ_VASNPRINTF): Likewise.
40424         * modules/vasnprintf (Files): Remove longlong.m4.
40425         * modules/c-vasnprintf (Files): Likewise.
40426         * modules/unistdio/u8-vasnprintf (Files): Likewise.
40427         * modules/unistdio/u8-u8-vasnprintf (Files): Likewise.
40428         * modules/unistdio/u16-vasnprintf (Files): Likewise.
40429         * modules/unistdio/u16-u16-vasnprintf (Files): Likewise.
40430         * modules/unistdio/u32-vasnprintf (Files): Likewise.
40431         * modules/unistdio/u32-u32-vasnprintf (Files): Likewise.
40432         * modules/unistdio/ulc-vasnprintf (Files): Likewise.
40434         gethrxtime: Assume that the compiler supports 'long long'.
40435         * lib/xtime.h (xtime_t): Define to 'long long int' always.
40436         (XTIME_PRECISION): Define to 1000000000 always.
40437         (xtime_make, xtime_sec): Optimize accordingly.
40438         * m4/gethrxtime.m4 (gl_XTIME): Don't require AC_TYPE_LONG_LONG_INT.
40439         * modules/gethrxtime (Files): Remove longlong.m4.
40441         integer_length*: Assume that the compiler supports 'long long'.
40442         * lib/integer_length.h (integer_length_ll): Declare unconditionally.
40443         * modules/integer_length (Files): Remove longlong.m4.
40444         (configure.ac): Don't require AC_TYPE_UNSIGNED_LONG_LONG_INT.
40445         * modules/integer_length_l (Files): Remove longlong.m4.
40446         (configure.ac): Don't require AC_TYPE_UNSIGNED_LONG_LONG_INT.
40447         * modules/integer_length_ll (Files): Remove longlong.m4.
40448         (configure.ac): Don't require AC_TYPE_UNSIGNED_LONG_LONG_INT.
40450         count-one-bits: Assume that the compiler supports 'long long'.
40451         * lib/count-one-bits.h (count_one_bits_ll): Define unconditionally.
40452         * m4/count-one-bits.m4: Remove file.
40453         * modules/count-one-bits (Files): Remove it.
40454         (configure.ac): Don't invoke gl_COUNT_ONE_BITS.
40455         * tests/test-count-one-bits.c (main): Test count_one_bits_ll
40456         unconditionally.
40458         count-trailing-zeros: Assume that the compiler supports 'long long'.
40459         * lib/count-trailing-zeros.h (count_trailing_zeros_ll): Define
40460         unconditionally.
40461         * m4/count-trailing-zeros.m4: Remove file.
40462         * modules/count-trailing-zeros (Files): Remove it.
40463         (configure.ac): Don't invoke gl_COUNT_TRAILING_ZEROS.
40464         * tests/test-count-trailing-zeros.c (main): Test count_trailing_zeros_ll
40465         unconditionally.
40467         count-leading-zeros: Assume that the compiler supports 'long long'.
40468         * lib/count-leading-zeros.h (count_leading_zeros_ll): Define
40469         unconditionally.
40470         * m4/count-leading-zeros.m4: Remove file.
40471         * modules/count-leading-zeros (Files): Remove it.
40472         (configure.ac): Don't invoke gl_COUNT_LEADING_ZEROS.
40473         * tests/test-count-leading-zeros.c (main): Test count_leading_zeros_ll
40474         unconditionally.
40476 2019-12-22  Bruno Haible  <bruno@clisp.org>
40478         localcharset: Update support for OpenBSD.
40479         * lib/localcharset.c (alias_table): Map "US-ASCII" to "ASCII".
40481 2019-12-21  Bruno Haible  <bruno@clisp.org>
40483         pthread_sigmask: Avoid test failure on NetBSD 8.0.
40484         * tests/test-pthread_sigmask2.c (main): Skip the error handling test on
40485         NetBSD.
40486         * doc/posix-functions/pthread_sigmask.texi: Mention the NetBSD problem.
40488 2019-12-21  Bruno Haible  <bruno@clisp.org>
40490         threadlib: Improve code structure.
40491         * m4/threadlib.m4: Reorder macros. Add comments.
40493 2019-12-21  Bruno Haible  <bruno@clisp.org>
40495         threadlib: Fix LIBMULTITHREAD on FreeBSD with --enable-threads=isoc.
40496         * m4/threadlib.m4 (gl_STDTHREADLIB_BODY): New macro (some code moved
40497         here from m4/threads.m4).
40498         (gl_THREADLIB_BODY): Don't test whether mtx_lock and cnd_timedwait exist
40499         in libc. Instead, rely on gl_STDTHREADLIB_BODY.
40500         (gl_STDTHREADLIB): New macro.
40501         * m4/threads.m4 (gl_THREADS_H): Require gl_STDTHREADLIB instead of
40502         gl_THREADLIB_BODY and gl_YIELD. Don't set LIBSTDTHREAD here.
40504 2019-12-21  Bruno Haible  <bruno@clisp.org>
40506         sched_yield: Don't depend on threadlib and yield.
40507         * m4/threadlib.m4 (gl_PTHREADLIB): Document that it sets
40508         LIB_SCHED_YIELD.
40509         (gl_PTHREADLIB_BODY): Set LIB_SCHED_YIELD (code moved here from
40510         m4/yield.m4).
40511         * m4/sched_yield.m4 (gl_FUNC_SCHED_YIELD): Require gl_PTHREADLIB, not
40512         gl_THREADLIB and gl_YIELD.
40513         * m4/yield.m4 (gl_YIELD): Require gl_PTHREADLIB. Determine YIELD_LIB
40514         based on $(LIB_SCHED_YIELD).
40515         * m4/threads.m4 (gl_THREADS_H): Don't require gl_YIELD. Use
40516         $(LIB_SCHED_YIELD), not $(YIELD_LIB).
40517         * modules/sched_yield (Files): Remove yield.m4. Add threadlib.m4.
40518         (Depends-on): Remove threadlib.
40519         (Link): Mention $(LIB_SCHED_YIELD), not $(YIELD_LIB).
40520         * modules/threads-h (Files): Remove m4/yield.m4.
40521         * modules/pthread-cond-tests (Makefile.am): Link the programs against
40522         $(LIB_SCHED_YIELD), not $(YIELD_LIB).
40523         * modules/pthread-mutex-tests (Makefile.am): Likewise.
40524         * modules/pthread-once-tests (Makefile.am): Likewise.
40525         * modules/pthread-rwlock-tests (Makefile.am): Likewise.
40526         * modules/pthread-tss-tests (Makefile.am): Likewise.
40528 2019-12-21  Bruno Haible  <bruno@clisp.org>
40530         threads-h: Don't depend on threadlib.
40531         * modules/threads-h (configure.ac-early): Invoke gl_ANYTHREADLIB_EARLY,
40532         not gl_THREADLIB_EARLY.
40534 2019-12-21  Bruno Haible  <bruno@clisp.org>
40536         nl_langinfo tests: Fix link error (regression from 2019-12-18).
40537         * modules/nl_langinfo-tests (Makefile.am): Link also test-nl_langinfo
40538         with $(LIB_SETLOCALE).
40540 2019-12-21  Bruno Haible  <bruno@clisp.org>
40542         threadlib: Remove unused dependency (left over from 2019-07-06).
40543         * modules/threadlib (Depends-on): Remove havelib.
40545 2019-12-21  Bruno Haible  <bruno@clisp.org>
40547         New convention for multithread-safety tests.
40548         * tests/test-setlocale_null-mt-one.c: Renamed from
40549         tests/test-setlocale_null-one.c.
40550         * tests/test-setlocale_null-mt-all.c: Renamed from
40551         tests/test-setlocale_null-all.c.
40552         * modules/setlocale-null-tests (Files, Makefile.am): Update.
40554 2019-12-21  Bruno Haible  <bruno@clisp.org>
40556         quotearg tests: Fix conflict with hard-locale tests.
40557         * tests/testlocale: Renamed from tests/locale.
40558         * modules/quotearg-tests (Files): Update.
40559         * tests/test-quotearg.sh (LOCALEDIR): Likewise.
40561 2019-12-21  Bruno Haible  <bruno@clisp.org>
40563         pthread-thread, lock: On z/OS, use PTHREAD_RWLOCK_INITIALIZER_NP.
40564         Reported by Daniel Richard G. in
40565         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00001.html>
40566         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00167.html>
40567         * lib/pthread.in.h (PTHREAD_RWLOCK_INITIALIZER): Define to
40568         PTHREAD_RWLOCK_INITIALIZER_NP when possible.
40569         * lib/glthread/lock.h: Allow PTHREAD_RWLOCK_INITIALIZER_NP as an
40570         alternative to PTHREAD_RWLOCK_INITIALIZER.
40571         * lib/glthread/lock.c: Likewise.
40573 2019-12-21  Bruno Haible  <bruno@clisp.org>
40575         memcmp tests: Work around the clang bug.
40576         * tests/test-memcmp.c (main): Use a volatile function pointer to disable
40577         the clang optimization.
40579 2019-12-20  Bruno Haible  <bruno@clisp.org>
40581         localcharset: Add support for z/OS encoding names.
40582         * lib/localcharset.h: Mention which encodings are used as locale
40583         encodings on z/OS.
40585 2019-12-20  Bruno Haible  <bruno@clisp.org>
40587         iconv_open: Add support for z/OS encoding names.
40588         Reported by Daniel Richard G. in
40589         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00172.html>.
40590         * lib/iconv_open-zos.gperf: New file.
40591         * modules/iconv_open (Files): Add iconv_open-zos.gperf.
40592         (Makefile.am): Add rules for generating iconv_open-zos.h from it.
40593         * lib/iconv_open.c (ICONV_FLAVOR_ZOS): New macro.
40594         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): On z/OS, use ICONV_FLAVOR_ZOS.
40595         * doc/posix-functions/iconv_open.texi: Mention z/OS.
40597 2019-12-20  Bruno Haible  <bruno@clisp.org>
40599         doc: Document the problem of the per-thread locale functions on z/OS.
40600         * doc/posix-functions/uselocale.texi: Document the z/OS problem.
40601         * doc/posix-functions/newlocale.texi: Likewise.
40602         * doc/posix-functions/duplocale.texi: Likewise.
40603         * doc/posix-functions/freelocale.texi: Likewise.
40605 2019-12-20  Bruno Haible  <bruno@clisp.org>
40607         localename, gettext: Fix host_os value for z/OS.
40608         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): Fix host_os value in
40609         cross-configuration code.
40611 2019-12-19  Jim Meyering  <meyering@fb.com>
40613         nstrftime: avoid a shadowing warning
40614         * lib/nstrftime.c (libc_hidden_def): Rename inner "i" to "j",
40615         to avoid shadowing an "i" declared hundreds of lines above.
40617 2019-12-19  Paul Eggert  <eggert@cs.ucla.edu>
40619         dfa: struct dfamust now uses flexible array
40620         * lib/dfa.c: Include flexmember.h.
40621         (dfamust, dfamustfree): Adjust to struct dfamust change.
40622         This saves a call to malloc+free.
40623         * lib/dfa.h (struct dfamust): Make the final member a
40624         flexible array member.
40625         * modules/dfa (Depends-on): Add flexmember.
40627         dfa: fast->small for array elements
40628         * lib/dfa.c (charclass_word): Use uint_least64_t not uint_fast64_t,
40629         since this type is used in arrays.  This change is more for
40630         documentation than for any practical effect, since the two types
40631         are the same on all known platforms.
40633 2019-12-19  Bruno Haible  <bruno@clisp.org>
40635         iconv tests: Test canonicalized, not system-dependent, encoding names.
40636         * tests/test-iconv.c (main): Revert part of the 2016-08-17 patch.
40637         * modules/iconv-tests (Depends-on): Add iconv_open.
40639 2019-12-18  Bruno Haible  <bruno@clisp.org>
40641         localename: Fix test failure on AIX 7.2.
40642         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): Enable nameless
40643         locales on AIX.
40644         * lib/localename.c (gl_locale_name_thread_unsafe): Handle nameless
40645         locales on AIX.
40647 2019-12-18  Paul Eggert  <eggert@cs.ucla.edu>
40649         Improve port of AC_C_RESTRICT to Oracle C++
40650         Problem reported by Christian Biesinger in:
40651         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00159.html
40652         * m4/gnulib-common.m4 (AC_C_RESTRICT): Port better to
40653         Oracle Developer Studio C++ 12.5 or later.
40655 2019-12-18  Bruno Haible  <bruno@clisp.org>
40657         wchar: Fix test failures on AIX and MSVC (regression from 2019-12-07).
40658         * lib/wchar.in.h (GNULIB_defined_mbstate_t): Do define on AIX and MSVC.
40660 2019-12-18  Bruno Haible  <bruno@clisp.org>
40662         localename: Ensure multithread-safety in future changes.
40663         * lib/localename.c (setlocale): Reference the system's setlocale().
40664         (get_locale_t_name): Invoke setlocale_null instead of setlocale.
40665         (gl_locale_name_posix): Likewise.
40666         * modules/localename (Depends-on): Add setlocale-null.
40668 2019-12-18  Bruno Haible  <bruno@clisp.org>
40670         setlocale-null: Make API more useful.
40671         * lib/locale.in.h (setlocale_null_r): Renamed from setlocale_null. All
40672         callers changed.
40673         (setlocale_null): New declaration.
40674         * lib/setlocale_null.c (setlocale_null_androidfix): New function,
40675         extracted from setlocale_null_unlocked.
40676         (setlocale_null_unlocked): Invoke it.
40677         (setlocale_null_r): Renamed from setlocale_null.
40678         (setlocale_null): New function, extracted from setlocale_mtsafe in
40679         setlocale.c.
40680         * lib/setlocale.c: Don't include <errno.h>.
40681         (setlocale_mtsafe): Invoke setlocale_null.
40682         * lib/setlocale-lock.c: Update comments.
40683         * doc/posix-functions/setlocale.texi: Mention both functions.
40685 2019-12-18  Bruno Haible  <bruno@clisp.org>
40687         localename: Optimize code for native Windows.
40688         * lib/localename.c (gl_locale_name_posix): Remove handling of LC_ALL
40689         category (not allowed here).
40691 2019-12-18  Bruno Haible  <bruno@clisp.org>
40693         setlocale: Make calls with NULL argument multithread-safe.
40694         * lib/setlocale.c: Include <errno.h>.
40695         (setlocale_mtsafe): New function.
40696         (setlocale_unixlike): Invoke setlocale_mtsafe instead of setlocale.
40697         (setlocale_improved): Renamed from rpl_setlocale.
40698         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Require gl_FUNC_SETLOCALE_NULL.
40699         Set and define NEED_SETLOCALE_IMPROVED and NEED_SETLOCALE_MTSAFE. Set
40700         LIB_SETLOCALE.
40701         * modules/setlocale (Depends-on): Add setlocale-null. Update conditions.
40702         (Link): New section.
40703         * tests/locale.c: Undefine setlocale.
40704         * tests/test-setlocale_null-one.c: Likewise.
40705         * tests/test-setlocale_null-all.c: Likewise.
40706         * modules/setlocale-tests (Makefile.am): Link the test programs with
40707         $(LIB_SETLOCALE).
40708         * modules/astrxfrm-tests (Makefile.am): Likewise.
40709         * modules/btowc-tests (Makefile.am): Likewise.
40710         * modules/c-ctype-tests (Makefile.am): Likewise.
40711         * modules/c-snprintf-tests (Makefile.am): Likewise.
40712         * modules/c-strcase-tests (Makefile.am): Likewise.
40713         * modules/c-vasprintf-tests (Makefile.am): Likewise.
40714         * modules/c-vsnprintf-tests (Makefile.am): Likewise.
40715         * modules/c-xvasprintf-tests (Makefile.am): Likewise.
40716         * modules/dfa-tests (Makefile.am): Likewise.
40717         * modules/duplocale-tests (Makefile.am): Likewise.
40718         * modules/hard-locale-tests (Makefile.am): Likewise.
40719         * modules/localcharset-tests (Makefile.am): Likewise.
40720         * modules/localename-tests (Makefile.am): Likewise.
40721         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
40722         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
40723         * modules/mbrtowc-tests (Makefile.am): Likewise.
40724         * modules/mbscasecmp-tests (Makefile.am): Likewise.
40725         * modules/mbscasestr-tests (Makefile.am): Likewise.
40726         * modules/mbschr-tests (Makefile.am): Likewise.
40727         * modules/mbscspn-tests (Makefile.am): Likewise.
40728         * modules/mbsinit-tests (Makefile.am): Likewise.
40729         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
40730         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
40731         * modules/mbspbrk-tests (Makefile.am): Likewise.
40732         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
40733         * modules/mbsrchr-tests (Makefile.am): Likewise.
40734         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
40735         * modules/mbsspn-tests (Makefile.am): Likewise.
40736         * modules/mbsstr-tests (Makefile.am): Likewise.
40737         * modules/nl_langinfo-tests (Makefile.am): Likewise.
40738         * modules/quotearg-tests (Makefile.am): Likewise.
40739         * modules/regex-tests (Makefile.am): Likewise.
40740         * modules/strfmon_l-tests (Makefile.am): Likewise.
40741         * modules/strtod-tests (Makefile.am): Likewise.
40742         * modules/strtold-tests (Makefile.am): Likewise.
40743         * modules/unicase/locale-language-tests (Makefile.am): Likewise.
40744         * modules/unicase/ulc-casecmp-tests (Makefile.am): Likewise.
40745         * modules/unicase/ulc-casecoll-tests (Makefile.am): Likewise.
40746         * modules/unigbrk/ulc-grapheme-breaks-tests (Makefile.am): Likewise.
40747         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
40748         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
40749         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
40750         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
40751         * modules/uniwbrk/ulc-wordbreaks-tests (Makefile.am): Likewise.
40752         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
40753         * modules/wcrtomb-tests (Makefile.am): Likewise.
40754         * modules/wcsnrtombs-tests (Makefile.am): Likewise.
40755         * modules/wcsrtombs-tests (Makefile.am): Likewise.
40756         * modules/wcwidth-tests (Makefile.am): Likewise.
40757         * doc/posix-functions/setlocale.texi: Mention that the multithread-
40758         safety fix is also available in module 'setlocale'.
40760 2019-12-18  Bruno Haible  <bruno@clisp.org>
40762         hard-locale: Make multithread-safe.
40763         * lib/hard-locale.h (hard_locale): Move documentation to here.
40764         * lib/hard-locale.c: Don't include <stdlib.h>.
40765         (GLIBC_VERSION): Remove macro.
40766         (hard_locale): Assume that all systems name the "C" and "POSIX" locales
40767         "C" or "POSIX". Invoke setlocale_null instead of setlocale.
40768         * modules/hard-locale (Depends-on): Remove strdup. Add setlocale-null.
40769         (configure.ac): Require gl_FUNC_SETLOCALE_NULL. Set LIB_HARD_LOCALE.
40770         (Link): New section.
40771         * modules/hard-locale-tests (Makefile.am): Link test-hard-locale against
40772         $(LIB_HARD_LOCALE).
40774 2019-12-18  Bruno Haible  <bruno@clisp.org>
40776         hard-locale: Avoid test failure on Haiku.
40777         * tests/test-hard-locale.c (test_one): Treat Haiku like recent OpenBSD.
40779 2019-12-18  Bruno Haible  <bruno@clisp.org>
40781         setlocale-null: Handle NULL result from setlocale.
40782         * lib/locale.in.h (setlocale_null): Document EINVAL return value.
40783         * lib/setlocale_null.c (setlocale_null_unlocked): Handle NULL result
40784         from setlocale or _wsetlocale.
40786 2019-12-18  Bruno Haible  <bruno@clisp.org>
40788         hard-locale: Add test.
40789         * tests/test-hard-locale.c: New file.
40790         * tests/locale.c: New file.
40791         * modules/hard-locale-tests: New file.
40793 2019-12-17  Paul Eggert  <eggert@cs.ucla.edu>
40795         dfa: do not match invalid UTF-8
40796         * lib/dfa.c (struct dfa): Grow utf8_anychar_classes member array
40797         from 5 to 9 tokens; this is needed due to the changes to
40798         add_utf8_anychar.
40799         (charclass_index): 2nd arg is now pointer-to-const.
40800         (add_utf8_anychar): Match only valid UTF-8 byte sequences
40801         instead of allowing overlong encodings or surrogate halves.
40803         dfa: simplify charclass by assuming C99
40804         * lib/dfa.c (CHARCLASS_WORD_BITS): Now always 64.
40805         (charclass_word): Now always uint_fast64_t.
40806         (CHARCLASS_PAIR): Remove.
40807         (CHARCLASS_INIT): Take 4 arguments instead of 8.  All uses changed.
40809         fts: tune via calloc
40810         * lib/fts.c (fts_open): Prefer calloc to malloc + memset.
40812         dfa: tune via xzalloc
40813         * lib/dfa.c (dfaoptimize): Prefer xzalloc to xmalloc + memset.
40815 2019-12-17  Bruno Haible  <bruno@clisp.org>
40817         localcharset: Fix multithread-safety bug on Windows and OS/2.
40818         * lib/localcharset.h (locale_charset): Clarify when the result becomes
40819         invalid.
40820         * lib/localcharset.c (locale_charset): Use a stack-allocated buffer to
40821         assemble the result.
40823 2019-12-17  Bruno Haible  <bruno@clisp.org>
40825         localcharset: Optimize code for native Windows.
40826         * lib/localcharset.c (locale_charset): Don't bother calling
40827         setlocale (LC_ALL, NULL) since we're not interested in its result.
40829 2019-12-17  Bruno Haible  <bruno@clisp.org>
40831         nl_langinfo: Fix multithread-safety bug on OpenBSD 3.8.
40832         * lib/nl_langinfo.c (ctype_codeset): Invoke setlocale_null instead of
40833         setlocale.
40834         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Require
40835         gl_FUNC_SETLOCALE_NULL. Set LIB_NL_LANGINFO.
40836         * modules/nl_langinfo (Depends-on): Add setlocale-null.
40838 2019-12-17  Bruno Haible  <bruno@clisp.org>
40840         nl_langinfo: Fix multithread-safety bug on mingw and MSVC.
40841         * lib/nl_langinfo.c (ctype_codeset, rpl_nl_langinfo): Use a
40842         stack-allocated buffer to assemble each result and different static
40843         buffers to return it.
40844         * tests/test-nl_langinfo-mt.c: New file.
40845         * modules/nl_langinfo-tests (Files): Add it.
40846         (Depends-on): Add thread, nanosleep.
40847         (Makefile.am): Build test-nl_langinfo-mt test.
40849 2019-12-17  Bruno Haible  <bruno@clisp.org>
40851         langinfo: Document more details.
40852         * doc/posix-headers/langinfo.texi: List platform details.
40853         * doc/posix-functions/nl_langinfo.texi: Likewise.
40855 2019-12-17  Bruno Haible  <bruno@clisp.org>
40857         mbsinit: Fix compilation error in mingw-w64 7.0 with _UCRT defined.
40858         Reported by Tom Kacvinsky <tom.kacvinsky@vector.com>
40859         and Martin Storsjö <martin@martin.st>
40860         in <https://savannah.gnu.org/bugs/?57406>.
40861         * lib/mbsinit.c: Accommodate an MSVC-like mbstate_t definition with
40862         mingw.
40864 2019-12-17  Bruno Haible  <bruno@clisp.org>
40866         glob: Avoid warning on mingw.
40867         Reported by Christian Biesinger <cbiesinger@google.com> in
40868         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00122.html>.
40869         * lib/glob.c (__stat64): Undefine first.
40871 2019-12-17  Paul Eggert  <eggert@cs.ucla.edu>
40873         xalloc: tune xzalloc for fresh allocations
40874         * lib/xmalloc.c (xzalloc): Use xcalloc rather than xmalloc+memset,
40875         because when the memory is freshly allocated from the OS via sbrk
40876         or mmap, calloc can avoid doing the memset.
40878         dfa: new function dfacopysyntax
40879         * lib/dfa.c (struct dfa): Move syntax member later so
40880         that dfacopysyntax can easily clear earlier members.
40881         (dfacopysyntax): New function, used by Gawk.
40883 2019-12-16  Paul Eggert  <eggert@cs.ucla.edu>
40885         dfa: port _GL_ATTRIBUTE_MALLOC to Gawk
40886         Gawk does not use Gnulib, and does not define _GL_ATTRIBUTE_MALLOC.
40887         * lib/dfa.h (_GL_ATTRIBUTE_MALLOC): Define to empty
40888         if not already defined.
40890         dfa: remove one dependency on MB_CUR_MAX
40891         * lib/dfa.c (dfamust): No need to refer to MB_CUR_MAX here.
40893         dfa: remove struct lexer_state.cur_mb_len
40894         * lib/dfa.c (struct lexer_state): Remove cur_mb_len member,
40895         as it’s not needed and the code is simpler without it.
40896         All uses removed.
40898 2019-12-16  Bruno Haible  <bruno@clisp.org>
40900         setlocale-null: Remove need for -lpthread on musl libc, *BSD, Haiku.
40901         Reported by Arnold Robbins <arnold@skeeve.com>.
40902         * lib/setlocale_null.c (c11_threads_in_use, pthread_in_use): New macros,
40903         copied from lib/glthread/lock.h.
40904         (pthread_mutex_lock, pthread_mutex_unlock): Mark as weak.
40905         (setlocale_null_with_lock): If pthread_in_use() is false, use
40906         setlocale_null_unlocked directly.
40907         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): New macro, extracted from
40908         gl_THREADLIB_BODY. Define HAVE_WEAK_SYMBOLS.
40909         (gl_THREADLIB_BODY): Invoke gl_WEAK_SYMBOLS.
40910         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Invoke gl_WEAK_SYMBOLS.
40911         Set LIB_SETLOCALE_NULL to empty if weak symbols are supported.
40912         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Add comment.
40914 2019-12-16  Paul Eggert  <eggert@cs.ucla.edu>
40916         dfa: make dfasyntax thread-safe
40917         Problem reported by Bruno Haible in:
40918         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00099.html
40919         * lib/dfa.c: Do not include locale.h.
40920         (struct dfa): Remove simple_locale member.
40921         All uses replaced by localeinfo.simple.
40922         (using_simple_locale): Remove; now present (with some
40923         changes) in localeinfo.c.
40924         (dfasyntax): No need to initialize removed member.
40926         localeinfo: record whether locale is simple
40927         * lib/localeinfo.c (using_simple_locale): New function,
40928         copied here from lib/dfa.c but with a change: it uses
40929         strcoll for its heuristic, instead of using setlocale.
40930         This lets it be thread-safe.
40931         * lib/localeinfo.h (struct localeinfo): New member ‘simple’.
40933 2019-12-15  Bruno Haible  <bruno@clisp.org>
40935         duplocale: Fix multithread-safety bug on AIX.
40936         * lib/duplocale.c: Don't include <stdlib.h>.
40937         (rpl_duplocale): Invoke setlocale_null instead of setlocale.
40938         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Require gl_FUNC_SETLOCALE_NULL.
40939         Set LIB_DUPLOCALE.
40940         * modules/duplocale (Depends-on): Add setlocale-null.
40941         (Link): New section.
40942         * modules/duplocale-tests (Makefile.am): Link test-duplocale with
40943         $(LIB_DUPLOCALE).
40945 2019-12-15  Bruno Haible  <bruno@clisp.org>
40947         setlocale-null: Add tests.
40948         * tests/test-setlocale_null.c: New file.
40949         * tests/test-setlocale_null-one.c: New file.
40950         * tests/test-setlocale_null-all.c: New file.
40951         * modules/setlocale-null-tests: New file.
40953         setlocale-null: New module.
40954         * lib/locale.in.h (SETLOCALE_NULL_MAX, SETLOCALE_NULL_ALL_MAX,
40955         setlocale_null): New declarations.
40956         * lib/setlocale_null.c: New file.
40957         * lib/setlocale-lock.c: New file.
40958         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): Define C macro HAVE_PTHREAD_API.
40959         * m4/setlocale_null.m4: New file.
40960         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize
40961         GNULIB_SETLOCALE_NULL.
40962         * modules/locale (Makefile.am): Substitute GNULIB_SETLOCALE_NULL.
40963         * modules/setlocale-null: New file.
40964         * doc/posix-functions/setlocale.texi: Mention the new module.
40966 2019-12-15  Bruno Haible  <bruno@clisp.org>
40968         lock tests: Skip test when no multithreading is enabled.
40969         * tests/test-rwlock1.c: Skip the test when no multithreading is enabled.
40971 2019-12-14  Bruno Haible  <bruno@clisp.org>
40973         locale, duplocale, localename: Fix last patch.
40974         Reported by Daniel Richard G. in
40975         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00093.html>.
40976         * lib/locale.in.h (HAVE_WORKING_NEWLOCALE, HAVE_WORKING_DUPLOCALE):
40977         Don't define if locale_t does not exist.
40979 2019-12-13  Bruno Haible  <bruno@clisp.org>
40981         locale, duplocale, localename: Fix errors if locale_t does not exist.
40982         Reported by Daniel Richard G. in
40983         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00078.html>.
40984         * lib/locale.in.h (HAVE_WORKING_NEWLOCALE, HAVE_WORKING_DUPLOCALE): New
40985         macros.
40986         * tests/test-locale.c: Test HAVE_WORKING_NEWLOCALE instead of
40987         HAVE_NEWLOCALE.
40988         * tests/test-localename.c: Likewise.
40989         * tests/test-duplocale.c: Test HAVE_WORKING_DUPLOCALE instead of
40990         HAVE_DUPLOCALE.
40991         * tests/test-locale-c++.cc: Likewise.
40993 2019-12-13  Bruno Haible  <bruno@clisp.org>
40995         wcstok: Fix test failure on HP-UX.
40996         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Set REPLACE_WCSTOK to 1 on HP-UX.
40997         * doc/posix-functions/wcstok.texi: Mention the HP-UX bug.
40999 2019-12-12  Bruno Haible  <bruno@clisp.org>
41001         strtod, strtold tests: Avoid test failure on AIX 7.2.
41002         * tests/test-strtod1.c (main): Allow implementations in which ',' and
41003         '.' both are radix characters.
41004         * tests/test-strtold1.c (main): Likewise.
41006 2019-12-12  Paul Eggert  <eggert@cs.ucla.edu>
41008         dfa: prefer ptrdiff_t for API, too
41009         Also, use ‘idx_t’ for ptrdiff_t values that must be nonnegative,
41010         but do this only for internal use for now.
41011         * NEWS: Mention the API change.
41012         * lib/dfa.c (idx_t, IDX_MAX): New type and max value, for internal
41013         use for now.  Use them instead of ptrdiff_t and PTRDIFF_MAX for
41014         values known to be nonnegative.
41015         (dfaparse, dfaexec_mb, dfaexec_sb, dfaexec_noop, dfaexec):
41016         Prefer idx_t or ptrdiff_t to size_t for API.
41017         * lib/dfa.h (dfaparse, dfacomp, dfaexec):
41018         Prefer ptrdiff_t to size_t for API.
41020         stdalign: port to xlclang 16.01
41021         Problem reportd by Bruno Haible in:
41022         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00064.html
41023         * lib/stdalign.in.h (_Alignas): Do not use __attribute__
41024         ((__aligned__ (...))) with xlclang, as a top-level
41025         ‘char __attribute__ ((__aligned__ (8))) c;’ does not work with
41026         xlclang version 16.01.0000.0001; the alignment directive is ignored.
41028 2019-12-12  Bruno Haible  <bruno@clisp.org>
41030         duplocale: Fix test failure on AIX 7.2 with xlclang.
41031         * lib/duplocale.c: Include <stdlib.h>.
41032         (rpl_duplocale): Use a heap-allocated copy of the first setlocale return
41033         value.
41035 2019-12-12  Bruno Haible  <bruno@clisp.org>
41037         stddef: Document the AIX xlc issue.
41038         * doc/posix-headers/stddef.texi: Document the NULL issue with AIX xlc.
41040 2019-12-12  Bruno Haible  <bruno@clisp.org>
41042         duplocale: Don't attempt to override if locale_t does not exist.
41043         Reported by Daniel Richard G. in
41044         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00039.html>.
41045         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): If locale_t does not exist, set
41046         HAVE_DUPLOCALE to 0.
41048 2019-12-12  Bruno Haible  <bruno@clisp.org>
41050         wcwidth: Avoid test failure on AIX 7.2.
41051         * tests/test-wcwidth.c (main): Don't fail if wcwidth(0x200B) is
41052         negative.
41053         * doc/posix-functions/wcwidth.texi: Mention the AIX issue.
41055 2019-12-12  Bruno Haible  <bruno@clisp.org>
41057         ilogbl: Work around Cygwin bug.
41058         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Test whether ilogbl(0.0L) is
41059         correct.
41060         * doc/posix-functions/ilogbl.texi: Mention the Cygwin bug.
41062 2019-12-12  Bruno Haible  <bruno@clisp.org>
41064         strtold: Work around Cygwin bug.
41065         * m4/strtold.m4 (gl_FUNC_STRTOLD): Add test for the underflow problem.
41066         If it is present, define STRTOLD_HAS_UNDERFLOW_BUG.
41067         * lib/strtod.c (HAVE_UNDERLYING_STRTOD): Set to 0 if
41068         STRTOLD_HAS_UNDERFLOW_BUG is defined.
41069         * doc/posix-functions/strtold.texi: Mention the Cygwin bug.
41071 2019-12-12  Bruno Haible  <bruno@clisp.org>
41073         strtold: Fix autoconf test.
41074         * m4/strtold.m4 (gl_FUNC_STRTOLD): Test strtold, not strtod.
41076 2019-12-11  Bruno Haible  <bruno@clisp.org>
41078         fsync tests: Skip test that is known to fail.
41079         * doc/posix-functions/fsync.texi: Update list of platforms.
41080         * tests/test-fsync.c (main): Skip test with read-only file descriptors
41081         that is known to fail on AIX and Cygwin.
41083 2019-12-11  Bruno Haible  <bruno@clisp.org>
41085         getaddrinfo: Fix calling convention in 32-bit mode on native Windows.
41086         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Test whether getaddrinfo has a
41087         non-POSIX signature. If so, set REPLACE_GETADDRINFO. Define
41088         HAVE_GETADDRINFO as a C macro.
41089         * lib/netdb.in.h (getaddrinfo, freeaddrinfo): If REPLACE_GETADDRINFO,
41090         declare as replacement functions.
41091         * lib/getaddrinfo.c (getaddrinfo, freeaddrinfo): If HAVE_GETADDRINFO,
41092         define as no-op overrides.
41093         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Initialize REPLACE_GETADDRINFO.
41094         * modules/netdb (Makefile.am): Substitute REPLACE_GETADDRINFO.
41095         * modules/getaddrinfo (Depends-on, configure.ac): Test
41096         REPLACE_GETADDRINFO.
41097         * doc/posix-functions/getaddrinfo.texi: Mention calling convention
41098         problem.
41099         * doc/posix-functions/freeaddrinfo.texi: Mention header file and calling
41100         convention problems.
41102 2019-12-11  Paul Eggert  <eggert@cs.ucla.edu>
41104         dfa: prefer signed integers for internals
41105         Signed integers can be checked more easily for integer overflow.
41106         * lib/dfa.c (position, struct lexer_state, struct parser_state)
41107         (struct dfa, mbs_to_wchar, fetch_wc, parse_bracket_exp)
41108         (struct lexptr, lex, addtok_mb, add_utf8_anychar, atom)
41109         (nsubtoks, copytoks, closure, alloc_position_set, delete)
41110         (replace, state_index, epsclosure, charclass_context)
41111         (state_separate_contexts, merge_nfa_state, dfaoptimize)
41112         (dfaanalyze, build_state, dfaexec_main, dfa_supported)
41113         (maybe_disable_superset_dfa, dfassbuild, dfafree, enlist)
41114         (comsubs, inboth, allocmust):
41115         Prefer a signed to an unsigned integer when calculating indexes,
41116         unless the integer is part of the external API (a bigger deal,
41117         and to be done later).
41119         dfa: fix index overflow
41120         * lib/dfa.c (compare): Avoid integer overflow when analyzing
41121         very large regular expressions.
41123         dfa: update commentary for previous change
41124         * NEWS: Mention the change.
41125         * lib/dfa.c, lib/dfa.h (dfaparse, dfamust, dfacomp): Update comments.
41127 2019-12-11  Norihiro Tanaka  <noritnk@kcn.ne.jp>
41129         dfa: separate parse and compile phase
41130         ‘dfamust’ must be called after parsing and before tokens are
41131         reordered, but both are executed in the compilation phase.
41132         Token reordering was introduced in Gnulib commit
41133         2018-10-22T15:01:08Z!noritnk@kcn.ne.jp
41134         (5c7a0371823876cca7a1347fa09ca26bbbff0c98).
41135         * lib/dfa.c (dfaparse): Change it to global function.
41136         (dfacomp): If first argument is NULL, skip parse.
41137         * lib/dfa.h: (dfaparse): Add a prototype.
41139 2019-12-11  Bruno Haible  <bruno@clisp.org>
41141         unistd tests: Fix link error on MSVC.
41142         * modules/unistd-c++-tests (Makefile.am): Link test-unistd-c++ against
41143         $(LIB_GETLOGIN).
41145 2019-12-11  Bruno Haible  <bruno@clisp.org>
41147         doc: Document that ISO C or POSIX substitutes are supported in C++ mode.
41148         * doc/gnulib-intro.texi (Various Kinds of Modules): Document that ISO C
41149         and POSIX substitutes are supported in C++ mode.
41150         * NEWS: Likewise.
41152 2019-12-11  Bruno Haible  <bruno@clisp.org>
41154         stddef: Fix compilation error in C++ mode on MSVC.
41155         * lib/stddef.in.h (max_align_t): With MSVC in C++ mode, don't define it;
41156         instead, include <cstddef>.
41158 2019-12-11  Bruno Haible  <bruno@clisp.org>
41160         unistd: Fix compilation error in C++ mode on MSVC.
41161         * lib/unistd.in.h: Don't do include[_next] <unistd.h> if the platform
41162         does not have <unistd.h>.
41164 2019-12-11  Bruno Haible  <bruno@clisp.org>
41166         locale: Fix compilation error in C++ mode on MSVC.
41167         * m4/locale_h.m4 (gl_LOCALE_H): Don't set REPLACE_STRUCT_LCONV on MSVC.
41168         * lib/locale.in.h (int_p_cs_precedes, int_p_sign_posn,
41169         int_p_sep_by_space, int_n_cs_precedes, int_n_sign_posn,
41170         int_n_sep_by_space): Define as macros on MSVC.
41172 2019-12-11  Bruno Haible  <bruno@clisp.org>
41174         wchar: Fix compilation error in C++ mode on MSVC.
41175         * lib/wchar.in.h (mbstate_t): Don't override on MSVC.
41177 2019-12-11  Bruno Haible  <bruno@clisp.org>
41179         pthread-thread: Fix compilation error in C++ mode on MSVC.
41180         * lib/pthread.in.h (pthread_exit): Don't use _Noreturn in the
41181         _GL_CXXALIAS_RPL invocation.
41183 2019-12-08  Bruno Haible  <bruno@clisp.org>
41185         Fix compilation errors in C++ mode on Haiku.
41186         * lib/stdio.in.h (vdprintf): Disable _GL_CXXALIASWARN invocation on
41187         non-glibc systems.
41188         * lib/spawn.in.h (posix_spawnattr_getschedpolicy,
41189         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
41190         posix_spawnattr_setschedparam): Likewise.
41191         * lib/stdlib.in.h (random, initstate_r, setstate_r): Use
41192         _GL_CXXALIAS_SYS_CAST instead of _GL_CXXALIAS_SYS.
41193         * lib/unistd.in.h (usleep): Likewise.
41195 2019-12-08  Bruno Haible  <bruno@clisp.org>
41197         Fix compilation errors in 32-bit C++ mode on HP-UX 11/ia64.
41198         * m4/largefile.m4 (gl_SET_LARGEFILE_SOURCE): New macro.
41199         * modules/fseeko (configure.ac-early): Require it instead of
41200         AC_FUNC_FSEEKO.
41201         * modules/ftello (configure.ac-early): Likewise.
41202         * modules/fflush (configure.ac-early): Likewise.
41204 2019-12-08  Bruno Haible  <bruno@clisp.org>
41206         Fix compilation error in C++ mode on HP-UX 11.
41207         * lib/unistd.in.h (getpagesize): Declare on HP-UX.
41208         * doc/glibc-functions/getpagesize.texi: Mention the HP-UX problem.
41210 2019-12-08  Bruno Haible  <bruno@clisp.org>
41212         Fix compilation errors on HP-UX 11/ia64.
41213         * lib/math.in.h (copysignf, fmaf, fma): Undefine before
41214         _GL_FUNCDECL_SYS.
41216 2019-12-08  Bruno Haible  <bruno@clisp.org>
41218         Fix compilation error in C++ mode on OpenBSD.
41219         * lib/signal.in.h (signal): Declare on OpenBSD.
41221 2019-12-08  Bruno Haible  <bruno@clisp.org>
41223         math tests: Don't fail if isfinite, isinf, isnan, signbit is a macro.
41224         * tests/test-math-c++.cc (isfinite, isinf, isnan, signbit): Use #warning
41225         instead of #error.
41227 2019-12-08  Bruno Haible  <bruno@clisp.org>
41229         Fix compilation errors in C++ mode on FreeBSD.
41230         * lib/pthread.in.h (pthread_exit): Remove _Noreturn from prototype.
41231         * tests/test-pthread-c++.cc (GNULIB_NAMESPACE::pthread_exit): Likewise.
41232         * lib/threads.in.h (thrd_exit): Likewise.
41233         * tests/test-threads-c++.cc (GNULIB_NAMESPACE::thrd_exit): Likewise.
41235 2019-12-08  Bruno Haible  <bruno@clisp.org>
41237         Fix compilation errors in C++ mode on macOS and FreeBSD.
41238         * lib/math.in.h (isfinite, isinf, isnan, signbit): In C++ mode on macOS
41239         or FreeBSD with clang, use the approach without C preprocessor macro.
41241 2019-12-07  Bruno Haible  <bruno@clisp.org>
41243         Fix compilation errors in C++ mode on AIX with xlclang++.
41244         Reported by Christian Biesinger <cbiesinger@google.com> in
41245         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00009.html>.
41246         * lib/wchar.in.h (mbstate_t): Don't override on AIX.
41248 2019-12-07  Bruno Haible  <bruno@clisp.org>
41250         Document compilation error in C++ mode on NetBSD 8.0.
41251         * doc/posix-headers/monetary.texi: Mention the NetBSD bug.
41253 2019-12-07  Bruno Haible  <bruno@clisp.org>
41255         Fix compilation errors in C++ mode on Solaris 10.
41256         * m4/stdbool.m4 (AM_STDBOOL_H): Require AC_CANONICAL_HOST. Set STDBOOL_H
41257         to non-empty on Solaris with a non-GCC compiler.
41258         * doc/posix-headers/stdbool.texi: Mention the Solaris issue.
41260 2019-12-07  Bruno Haible  <bruno@clisp.org>
41262         Reword NEWS entry.
41263         * NEWS: Reword the latest NEWS entry.
41265 2019-12-05  Pino Toscano  <ptoscano@redhat.com>
41267         Move xstrtol_fatal to a new xstrtol-error module.
41268         * lib/xstrtol.h: Stop including <getopt.h>.
41269         (xstrtol_fatal): Move ...
41270         * lib/xstrtol-error.h: ... here.  New file.
41271         * lib/xstrtol-error.c: Include xstrtol-error.h instead of xstrtol.h.
41272         * tests/test-xstrtol.c: Likewise.
41273         * modules/xstrtol (Files): Remove lib/xstrtol-error.c.
41274         (Depends-on): Remove exitfail, error, getopt-gnu, and gettext-h.
41275         (Makefile.am): Remove xstrtol-error.c from lib_SOURCES.
41276         * modules/xstrtol-error: New file.
41277         * modules/xstrtol-tests (Depends-on): Add xstrtol-error.
41278         * MODULES.html.sh: Add xstrtol-error.
41279         * NEWS: Document the change.
41281 2019-12-06  Paul Eggert  <eggert@cs.ucla.edu>
41283         nstrftime: better width support for %N, %z
41284         * lib/nstrftime.c (width_add, width_add1, width_cpy):
41285         New macros, which generalize ‘add’, ‘add1’, ‘cpy’ by adding
41286         a new WIDTH parameter.
41287         (add, add1, cpy): Use these macros.
41288         (width_add): Do not treat digits == 0 as a special case,
41289         do not pad if padding is ‘-’, and do not use a negative width.
41290         (__strftime_internal): Redo formatting of nanoseconds and numeric
41291         timezones to avoid buffer misuse in unusual cases, and so that
41292         widths make more sense.  Add support for widths greater than 9 to
41293         the %N format; they are zero filled on the right.
41294         * tests/test-nstrftime.c (posixtm_test): Add a %12N test.
41296 2019-12-05  Bruno Haible  <bruno@clisp.org>
41298         Fix compilation errors in C++ mode on Solaris 10 and Solaris 11.
41299         * m4/isfinite.m4 (gl_ISFINITE): Require AC_CANONICAL_HOST. On Solaris,
41300         set REPLACE_ISFINITE to 1.
41301         * m4/isinf.m4 (gl_ISINF): Require AC_CANONICAL_HOST. On Solaris, set
41302         REPLACE_ISINF to 1.
41303         * m4/signbit.m4 (gl_SIGNBIT): On Solaris, set REPLACE_SIGNBIT to 1.
41304         * lib/pthread.in.h (pthread_create, pthread_once, pthread_key_create):
41305         Use _GL_CXXALIAS_SYS_CAST instead of _GL_CXXALIAS_SYS.
41306         * lib/threads.in.h (call_once): Likewise.
41307         * lib/iconv.in.h (iconv): Likewise.
41309 2019-12-05  Bruno Haible  <bruno@clisp.org>
41311         wchar: Add more C++ tests.
41312         Reported by Christian Biesinger <cbiesinger@google.com> in
41313         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00009.html>.
41314         * tests/test-wchar-c++3.cc: New file.
41315         * modules/wchar-c++-tests (Files): Add it.
41316         (Makefile.am): Compile it.
41318 2019-12-05  Bruno Haible  <bruno@clisp.org>
41320         Add more C++ tests.
41322         assert-h: Add C++ tests.
41323         * tests/test-assert-h-c++.cc: New file.
41324         * tests/test-assert-h-c++2.cc: New file.
41325         * modules/assert-h-c++-tests: New file.
41326         * modules/assert-h-tests: New file.
41328         ctype: Add C++ tests.
41329         * tests/test-ctype-c++.cc: New file.
41330         * tests/test-ctype-c++2.cc: New file.
41331         * modules/ctype-c++-tests: New file.
41332         * modules/ctype-tests (Depends-on): Add ctype-c++-tests.
41334         errno: Add C++ tests.
41335         * tests/test-errno-c++.cc: New file.
41336         * tests/test-errno-c++2.cc: New file.
41337         * modules/errno-c++-tests: New file.
41338         * modules/errno-tests (Depends-on): Add errno-c++-tests.
41340         float: Add C++ tests.
41341         * tests/test-float-c++.cc: New file.
41342         * tests/test-float-c++2.cc: New file.
41343         * modules/float-c++-tests: New file.
41344         * modules/float-tests (Depends-on): Add float-c++-tests.
41346         inttypes: Add more C++ tests.
41347         * tests/test-inttypes-c++2.cc: New file.
41348         * modules/inttypes-c++-tests (Files): Add it.
41349         (Makefile.am): Compile it.
41351         limits-h: Add C++ tests.
41352         * tests/test-limits-h-c++.cc: New file.
41353         * tests/test-limits-h-c++2.cc: New file.
41354         * modules/limits-h-c++-tests: New file.
41355         * modules/limits-h-tests (Depends-on): Add limits-h-c++-tests.
41357         stdarg: Add C++ tests.
41358         * tests/test-stdarg-c++.cc: New file.
41359         * tests/test-stdarg-c++2.cc: New file.
41360         * modules/stdarg-c++-tests: New file.
41361         * modules/stdarg-tests: New file.
41363         stdbool: Add C++ tests.
41364         * tests/test-stdbool-c++.cc: New file.
41365         * tests/test-stdbool-c++2.cc: New file.
41366         * modules/stdbool-c++-tests: New file.
41367         * modules/stdbool-tests (Depends-on): Add stdbool-c++-tests.
41369         stddef: Add C++ tests.
41370         * tests/test-stddef-c++.cc: New file.
41371         * tests/test-stddef-c++2.cc: New file.
41372         * modules/stddef-c++-tests: New file.
41373         * modules/stddef-tests (Depends-on): Add stddef-c++-tests.
41375         stdint: Add C++ tests.
41376         * tests/test-stdint-c++.cc: New file.
41377         * tests/test-stdint-c++2.cc: New file.
41378         * modules/stdint-c++-tests: New file.
41379         * modules/stdint-tests (Depends-on): Add stdint-c++-tests.
41381         wchar: Add more C++ tests.
41382         * tests/test-wchar-c++2.cc: New file.
41383         * modules/wchar-c++-tests (Files): Add it.
41384         (Makefile.am): Compile it.
41386         wctype-h: Add more C++ tests.
41387         * tests/test-wctype-h-c++2.cc: New file.
41388         * modules/wctype-h-c++-tests (Files): Add it.
41389         (Makefile.am): Compile it.
41391 2019-12-04  Bruno Haible  <bruno@clisp.org>
41393         Fix compilation errors in C++ mode with xlclang++ on AIX.
41394         * lib/math.in.h (expm1l, fmal, remainderl, roundl): Don't redeclare in
41395         C++ mode on AIX.
41396         (isfinite, signbit): In C++ mode on AIX with clang, use the approach
41397         without C preprocessor macro.
41398         * lib/pthread.in.h (pthread_exit): Use _GL_CXXALIAS_SYS_CAST instead of
41399         _GL_CXXALIAS_SYS.
41400         * lib/threads.in.h (thrd_exit): Likewise.
41402 2019-12-04  Bruno Haible  <bruno@clisp.org>
41404         Fix compilation error in C++ mode on Solaris 11 OpenIndiana.
41405         * lib/wchar.in.h (wcsnrtombs): Force declaration in C++ mode on Solaris.
41406         * doc/posix-functions/wcsnrtombs.texi: Mention the issue.
41408 2019-12-04  Bruno Haible  <bruno@clisp.org>
41410         Disable more _GL_CXXALIASWARN on all platforms other than glibc systems.
41411         * lib/wchar.in.h (wcsnrtombs, wcwidth, wcswidth): Disable
41412         _GL_CXXALIASWARN invocation on non-glibc systems.
41413         * lib/wctype.in.h (iswalnum, iswalpha, iswcntrl, iswdigit, iswgraph,
41414         iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit, wctype,
41415         iswctype, towlower, towupper): Likewise.
41417 2019-12-03  Bruno Haible  <bruno@clisp.org>
41419         Avoid hassles caused by [[noreturn]] in C++.
41420         Reported by Christian Biesinger <cbiesinger@google.com> in
41421         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00010.html>.
41422         * m4/gnulib-common.m4 (gl_COMMON_BODY): Disable the use of [[noreturn]].
41423         * lib/_Noreturn.h: Likewise.
41425 2019-12-02  Bruno Haible  <bruno@clisp.org>
41427         Fix mistakes in --enable-threads=isoc fixes from 2019-12-01.
41428         * m4/pthread-mutex.m4 (gl_PTHREAD_MUTEX): Use LIBPMULTITHREAD, not
41429         LIBMULTITHREAD.
41430         * m4/pthread-rwlock.m4 (gl_PTHREAD_RWLOCK): Likewise.
41431         * m4/pthread-thread.m4 (gl_PTHREAD_THREAD): Likewise.
41432         * m4/timer_time.m4 (gl_TIMER_TIME): Likewise. Require gl_PTHREADLIB, not
41433         gl_THREADLIB.
41434         * modules/timer-time (Depends-on): Add pthread-h. Remove threadlib.
41436 2019-12-02  Bruno Haible  <bruno@clisp.org>
41438         Fix some more link errors with --enable-threads=isoc.
41439         * modules/pthread-mutex (Depends-on): Test $gl_threads_api differently.
41440         * modules/pthread-rwlock (Depends-on): Likewise.
41442 2019-12-02  Bruno Haible  <bruno@clisp.org>
41444         Fix link errors with --enable-threads=posix on AIX.
41445         * modules/string-c++-tests (Makefile.am): Link the test-string-c++
41446         program with $(LIBTHREAD).
41447         * modules/wchar-c++-tests (Makefile.am): Link the test-wchar-c++
41448         program with $(LIBTHREAD).
41450 2019-12-02  Bruno Haible  <bruno@clisp.org>
41452         Fix link errors with --enable-threads=posix on AIX.
41453         * modules/mbrtowc (Link): New section.
41454         * modules/acl (Link): Likewise.
41455         * modules/argmatch (Link): Likewise.
41456         * modules/backup-rename (Link): Likewise.
41457         * modules/backupfile (Link): Likewise.
41458         * modules/closein (Link): Likewise.
41459         * modules/closeout (Link): Likewise.
41460         * modules/copy-file (Link): Likewise.
41461         * modules/csharpcomp (Link): Likewise.
41462         * modules/csharpexec (Link): Likewise.
41463         * modules/dfa (Link): Likewise.
41464         * modules/exclude (Link): Likewise.
41465         * modules/fnmatch (Link): Likewise.
41466         * modules/fnmatch-gnu (Link): Likewise.
41467         * modules/fnmatch-posix (Link): Likewise.
41468         * modules/glob (Link): Likewise.
41469         * modules/human (Link): Likewise.
41470         * modules/javacomp (Link): Likewise.
41471         * modules/javaexec (Link): Likewise.
41472         * modules/javaversion (Link): Likewise.
41473         * modules/mbfile (Link): Likewise.
41474         * modules/mbiter (Link): Likewise.
41475         * modules/mbmemcasecmp (Link): Likewise.
41476         * modules/mbmemcasecoll (Link): Likewise.
41477         * modules/mbrlen (Link): Likewise.
41478         * modules/mbscasecmp (Link): Likewise.
41479         * modules/mbscasestr (Link): Likewise.
41480         * modules/mbschr (Link): Likewise.
41481         * modules/mbscspn (Link): Likewise.
41482         * modules/mbsinit (Link): Likewise.
41483         * modules/mbslen (Link): Likewise.
41484         * modules/mbsncasecmp (Link): Likewise.
41485         * modules/mbsnlen (Link): Likewise.
41486         * modules/mbsnrtowcs (Link): Likewise.
41487         * modules/mbspbrk (Link): Likewise.
41488         * modules/mbspcasecmp (Link): Likewise.
41489         * modules/mbsrchr (Link): Likewise.
41490         * modules/mbsrtowcs (Link): Likewise.
41491         * modules/mbssep (Link): Likewise.
41492         * modules/mbsspn (Link): Likewise.
41493         * modules/mbsstr (Link): Likewise.
41494         * modules/mbstok_r (Link): Likewise.
41495         * modules/mbswidth (Link): Likewise.
41496         * modules/mbuiter (Link): Likewise.
41497         * modules/mkdir-p (Link): Likewise.
41498         * modules/propername (Link): Likewise.
41499         * modules/quote (Link): Likewise.
41500         * modules/quotearg (Link): Likewise.
41501         * modules/quotearg-simple (Link): Likewise.
41502         * modules/regex-quote (Link): Likewise.
41503         * modules/rpmatch (Link): Likewise.
41504         * modules/sh-quote (Link): Likewise.
41505         * modules/system-quote (Link): Likewise.
41506         * modules/trim (Link): Likewise.
41507         * modules/unistdio/ulc-asnprintf (Link): Likewise.
41508         * modules/unistdio/ulc-fprintf (Link): Likewise.
41509         * modules/unistdio/ulc-vasnprintf (Link): Likewise.
41510         * modules/unistdio/ulc-vasprintf (Link): Likewise.
41511         * modules/unistdio/ulc-vfprintf (Link): Likewise.
41512         * modules/unistdio/ulc-vsnprintf (Link): Likewise.
41513         * modules/unistdio/ulc-vsprintf (Link): Likewise.
41514         * modules/xfreopen (Link): Likewise.
41515         * modules/xmemcoll (Link): Likewise.
41516         * modules/yesno (Link): Likewise.
41517         * modules/acl-tests (Makefile.am): Link the programs with $(LIBTHREAD).
41518         * modules/argmatch-tests (Makefile.am): Likewise.
41519         * modules/closein-tests (Makefile.am): Likewise.
41520         * modules/copy-file-tests (Makefile.am): Likewise.
41521         * modules/dfa-tests (Makefile.am): Likewise.
41522         * modules/fnmatch-tests (Makefile.am): Likewise.
41523         * modules/glob-tests (Makefile.am): Likewise.
41524         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
41525         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
41526         * modules/mbrtowc-tests (Makefile.am): Likewise.
41527         * modules/mbscasecmp-tests (Makefile.am): Likewise.
41528         * modules/mbscasestr-tests (Makefile.am): Likewise.
41529         * modules/mbschr-tests (Makefile.am): Likewise.
41530         * modules/mbscspn-tests (Makefile.am): Likewise.
41531         * modules/mbsinit-tests (Makefile.am): Likewise.
41532         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
41533         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
41534         * modules/mbspbrk-tests (Makefile.am): Likewise.
41535         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
41536         * modules/mbsrchr-tests (Makefile.am): Likewise.
41537         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
41538         * modules/mbsspn-tests (Makefile.am): Likewise.
41539         * modules/mbsstr-tests (Makefile.am): Likewise.
41540         * modules/quotearg-tests (Makefile.am): Likewise.
41541         * modules/quotearg-simple-tests (Makefile.am): Likewise.
41542         * modules/readtokens-tests (Makefile.am): Likewise.
41543         * modules/regex-quote-tests (Makefile.am): Likewise.
41544         * modules/sh-quote-tests (Makefile.am): Likewise.
41545         * modules/system-quote-tests (Makefile.am): Likewise.
41546         * modules/unistdio/ulc-asnprintf-tests (Makefile.am): Likewise.
41547         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
41548         * modules/unistdio/ulc-vasprintf-tests (Makefile.am): Likewise.
41549         * modules/unistdio/ulc-vsnprintf-tests (Makefile.am): Likewise.
41550         * modules/unistdio/ulc-vsprintf-tests (Makefile.am): Likewise.
41551         * modules/yesno-tests (Makefile.am): Likewise.
41553 2019-12-02  Bruno Haible  <bruno@clisp.org>
41555         Simplify link sections.
41556         * modules/threadlib (Link): Stop mentioning LTLIBTHREAD.
41557         * modules/lock (Link): Likewise.
41558         * modules/cond (Link): Likewise.
41559         * modules/tls (Link): Likewise.
41560         * modules/yield (Link): Likewise.
41561         * modules/regex (Link): Likewise.
41562         * modules/localename (Link): Likewise.
41563         * modules/unicase/locale-language (Link): Likewise.
41564         * modules/thread (Link): Stop mentioning LTLIBMULTITHREAD.
41566 2019-12-02  Bruno Haible  <bruno@clisp.org>
41568         thread tests: Avoid link error with --enable-threads=isoc+posix on AIX.
41569         * tests/test-thread_self.c (main): Disable test on AIX.
41571 2019-12-01  Bruno Haible  <bruno@clisp.org>
41573         pthread-h: Fix link errors with --enable-threads=isoc on AIX.
41574         * m4/threadlib.m4 (gl_ANYTHREADLIB_EARLY): New macro, extracted from
41575         gl_THREADLIB_EARLY_BODY.
41576         (gl_THREADLIB_EARLY_BODY): Invoke it.
41577         (gl_PTHREADLIB_BODY): New macro, extracted from gl_THREADLIB_BODY.
41578         (gl_THREADLIB_BODY): Invoke it.
41579         (gl_PTHREADLIB): New macro.
41580         * m4/pthread_h.m4 (gl_PTHREAD_H): Require gl_PTHREADLIB. Require
41581         gl_THREADLIB and test $gl_threads_api only if module 'threadlib' is
41582         present. Define LIB_PTHREAD using LIBPMULTITHREAD, not LIBMULTITHREAD.
41583         * modules/pthread-h (Files): Add threadlib.m4.
41584         (Depends-on): Remove threadlib.
41585         (configure.ac-early): Invoke gl_ANYTHREADLIB_EARLY. Don't set _REENTRANT
41586         and _THREAD_SAFE here.
41587         (Link): Use LIBPTHREAD, not LIBTHREAD.
41588         * modules/pthread-thread (Link): Use LIBPMULTITHREAD, not
41589         LIBMULTITHREAD.
41590         * modules/pthread-once (Link): Likewise.
41591         * modules/pthread-mutex (Link): Likewise.
41592         * modules/pthread-rwlock (Link): Likewise.
41593         * modules/pthread-cond (Link): Likewise.
41594         * modules/pthread-tss (Link): Likewise.
41595         * modules/pthread-spin (Link): Likewise.
41596         * modules/pthread (Link): Likewise.
41597         * modules/pthread-h-c++-tests (test_pthread_c___LDADD): Likewise.
41598         * modules/pthread-thread-tests (test_pthread_thread_LDADD): Likewise.
41599         * modules/pthread-once-tests (test_pthread_once1_LDADD,
41600         test_pthread_once2_LDADD): Likewise.
41601         * modules/pthread-mutex-tests (test_pthread_mutex_LDADD): Likewise.
41602         * modules/pthread-rwlock-tests (test_pthread_rwlock_LDADD): Likewise.
41603         * modules/pthread-cond-tests (test_pthread_cond_LDADD): Likewise.
41604         * modules/pthread-tss-tests (test_pthread_tss_LDADD): Likewise.
41606 2019-12-01  Bruno Haible  <bruno@clisp.org>
41608         cond: State linking requirements.
41609         * modules/cond (Link): New section.
41611 2019-12-01  Bruno Haible  <bruno@clisp.org>
41613         threadlib: Remove unnecessary file (left over from 2019-07-06).
41614         * modules/threadlib (Files): Remove config.rpath.
41616 2019-11-29  Tim Rühsen  <tim.ruehsen@gmx.de>
41618         gnulib-tool.py: Fix libgnu_la_LDFLAGS section in generated Makefile.am.
41619         Reported by Dagobert Michelsen <dam@opencsw.org> in
41620         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00086.html>.
41621         * pygnulib/GLModuleSystem.py (getLink): Don't join the parts. Return a
41622         list of strings instead of one string.
41623         * pygnulib/GLEmiter.py (lib_Makefile_am): Adapt accordingly.
41624         * pygnulib/GLImport.py (execute): Likewise.
41626 2019-11-27  Bruno Haible  <bruno@clisp.org>
41628         openpty, forkpty: Fix build error on Solaris 11.4.
41629         * m4/pty_h.m4 (gl_PTY_H): Test for termios.h. Look for the declarations
41630         also in <termios.h>.
41631         * m4/pty.m4 (gl_FUNC_FORKPTY, gl_FUNC_OPENPTY): Look for the declaration
41632         of the function also in <termios.h>.
41633         * doc/glibc-functions/openpty.texi: Mention the Solaris 11.4 problems.
41634         * doc/glibc-functions/forkpty.texi: Likewise.
41636 2019-11-27  Bruno Haible  <bruno@clisp.org>
41638         New options --enable-threads=isoc and --enable-threads=isoc+posix.
41639         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Accept the options
41640         --enable-threads=isoc and --enable-threads=isoc+posix.
41641         (gl_THREADLIB_BODY): Test whether the ISO C threads API is available.
41642         When both the ISO C and the POSIX threads API are available, choose
41643         USE_ISOC_AND_POSIX_THREADS instead of USE_POSIX_THREADS if
41644         --enable-threads=isoc+posix was specified. When only the ISO C threads
41645         API is available and --enable-threads=iso was specified, choose
41646         USE_ISOC_THREADS.
41647         * lib/glthread/lock.h: Add new code for USE_ISOC_THREADS ||
41648         USE_ISOC_AND_POSIX_THREADS.
41649         * lib/glthread/lock.c: Likewise.
41650         * lib/glthread/cond.h: Likewise.
41651         * lib/glthread/cond.c: Likewise.
41652         * lib/glthread/tls.h: Likewise.
41653         * lib/glthread/tls.c: Likewise.
41654         * lib/glthread/yield.h: Likewise.
41655         * lib/glthread/thread.h: Add new code for USE_ISOC_THREADS. Treat
41656         USE_ISOC_AND_POSIX_THREADS like USE_POSIX_THREADS.
41657         * lib/glthread/thread.c: Likewise.
41658         * lib/glthread/threadlib.c: Likewise.
41659         * tests/test-lock.c: Save and restore the values of USE_ISOC_THREADS and
41660         USE_ISOC_AND_POSIX_THREADS.
41661         * tests/test-cond.c: Consider USE_ISOC_THREADS and
41662         USE_ISOC_AND_POSIX_THREADS.
41663         * tests/test-tls.c: Likewise.
41664         * tests/test-thread_create.c (main): Likewise.
41665         * tests/test-pthread-cond.c: Likewise.
41666         * tests/test-pthread-mutex.c: Likewise.
41667         * tests/test-pthread-once2.c: Likewise.
41668         * tests/test-pthread-rwlock.c: Likewise.
41669         * tests/test-pthread-tss.c: Likewise.
41670         * tests/test-pthread_sigmask2.c: Treat USE_ISOC_AND_POSIX_THREADS like
41671         USE_POSIX_THREADS.
41673 2019-11-24  Bruno Haible  <bruno@clisp.org>
41675         mbrtowc: Modernize autoconf test.
41676         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Require
41677         gt_LOCALE_FR_UTF8. If a traditional Japanese locale is not available,
41678         try a UTF-8 locale.
41679         * doc/posix-functions/mbrtowc.texi: Update info about AIX.
41681 2019-11-24  Bruno Haible  <bruno@clisp.org>
41683         Fix errors in C++ mode on mingw.
41684         * lib/arpa_inet.in.h (inet_ntop, inet_pton): Use _GL_CXXALIAS_SYS_CAST
41685         instead of _GL_CXXALIAS_SYS.
41686         * lib/signal.in.h (pthread_sigmask): Likewise.
41687         * lib/spawn.in.h (posix_spawn_file_actions_addopen,
41688         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
41689         Likewise.
41690         * lib/wchar.in.h (btowc): Likewise.
41692 2019-11-24  Bruno Haible  <bruno@clisp.org>
41694         sys_time: Fix errors in C++ mode on mingw.
41695         * lib/sys_time.in.h (timeval): Restore the redirection
41696         '#define timeval rpl_timeval', for when the symbol timeval is being used
41697         outside the 'gnulib' namespace.
41698         * lib/sys_select.in.h (select): In C++, write 'timeval', not
41699         'struct timeval'.
41701 2019-11-24  Bruno Haible  <bruno@clisp.org>
41703         iswctype: Fix errors in C++ mode on mingw.
41704         * lib/wctype.in.h (rpl_iswctype): Override if GNULIB_OVERRIDES_WINT_T
41705         is 1.
41706         * lib/iswctype.c (iswctype): Add another implementation, for the
41707         GNULIB_defined_wint_t case.
41708         * modules/iswctype (configure.ac): Compile iswctype.c also if
41709         GNULIB_OVERRIDES_WINT_T is 1.
41711 2019-11-24  Bruno Haible  <bruno@clisp.org>
41713         windows-timedmutex: Fix errors in C++ mode on mingw.
41714         * lib/windows-timedmutex.h: Add closing brace.
41716 2019-11-24  Bruno Haible  <bruno@clisp.org>
41718         Fix errors in C++ mode on Cygwin.
41719         * lib/sys_wait.in.h (waitpid): Use _GL_CXXALIAS_SYS_CAST instead of
41720         _GL_CXXALIAS_SYS.
41722 2019-11-24  Bruno Haible  <bruno@clisp.org>
41724         time_r: Fix for mingw (regression from 2019-11-16).
41725         * m4/time_r.m4 (gl_TIME_R): Revert to using AC_CHECK_FUNCS_ONCE. Use the
41726         AC_LINK_IFELSE test only if the function does not appear to exist.
41728 2019-11-24  Bruno Haible  <bruno@clisp.org>
41730         wcstok: Add tests.
41731         * tests/test-wcstok.c: New file.
41732         * modules/wcstok-tests: New file.
41734 2019-11-24  Bruno Haible  <bruno@clisp.org>
41736         wcstok: Work around wrong signature on native Windows.
41737         * lib/wchar.in.h (wcstok): Override when REPLACE_WCSTOK is 1.
41738         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Check for signature of wcstok. Set
41739         REPLACE_WCSTOK.
41740         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSTOK.
41741         * modules/wchar (Makefile.am): Substitute REPLACE_WCSTOK.
41742         * modules/wcstok (Depends-on, configure.ac): Consider REPLACE_WCSTOK.
41743         * doc/posix-functions/wcstok.texi: Mention the problem.
41745 2019-11-22  Paul Eggert  <eggert@cs.ucla.edu>
41747         intprops: INT_MULTIPLY_WRAPV speedup for GCC 8.4+
41748         * lib/intprops.h (INT_MULTIPLY_WRAPV): If GCC 8.x where 4 <= x,
41749         remove workaround for GCC bug 91450 as the bug should be fixed
41750         there too.
41752 2019-11-21  Bruno Haible  <bruno@clisp.org>
41754         Disable many _GL_CXXALIASWARN on all platforms other than glibc systems.
41755         Reported by Christian Biesinger <cbiesinger@google.com> in
41756         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00066.html>.
41757         * lib/fnmatch.in.h (fnmatch): Disable _GL_CXXALIASWARN invocation on
41758         non-glibc systems.
41759         * lib/locale.in.h (localeconv, setlocale): Likewise.
41760         * lib/math.in.h (cbrt, ceil, copysign, exp2, expm1, floor, fma, fmod,
41761         frexp, hypot, ilogb, log, log10, log1p, log2, logb, modf, remainder,
41762         rint, round, trunc): Likewise.
41763         * lib/monetary.in.h (strfmon_l): Likewise.
41764         * lib/pthread.in.h (pthread_mutexattr_getrobust,
41765         pthread_mutexattr_setrobust, pthread_mutex_lock, pthread_spin_init,
41766         pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock,
41767         pthread_spin_destroy): Likewise.
41768         * lib/signal.in.h (raise, signal): Likewise.
41769         * lib/stdio.in.h (fclose, fflush, fgetc, fgets, fopen, fprintf, fputc,
41770         fputs, fread, freopen, fscanf, fseek, ftell, fwrite, getc, getchar,
41771         perror, printf, putc, putchar, puts, remove, rename, scanf, sprintf,
41772         tmpfile, vfprintf, vprintf, vsprintf): Likewise.
41773         * lib/stdlib.in.h (calloc, malloc, mbtowc, realloc, strtod, wctomb):
41774         Likewise.
41775         * lib/string.in.h (memchr, strncat, strpbrk, strstr, strerror):
41776         Likewise.
41777         * lib/time.in.h (mktime, localtime, ctime, strftime): Likewise.
41778         * lib/wchar.in.h (btowc, wctob, mbsinit, mbrtowc, mbrlen, mbsrtowcs,
41779         wcrtomb, wcsrtombs, wmemchr, wmemcmp, wmemcpy, wmemmove, wmemset,
41780         wcslen, wcscpy, wcsncpy, wcscat, wcsncat, wcscmp, wcsncmp, wcscoll,
41781         wcsxfrm, wcschr, wcsrchr, wcscspn, wcsspn, wcspbrk, wcsstr, wcstok,
41782         wcsftime): Likewise.
41783         * lib/wctype.in.h (iswblank, wctrans, towctrans): Likewise.
41785 2019-11-21  Bruno Haible  <bruno@clisp.org>
41787         Fix various errors in _GL_CXXALIAS_SYS invocations.
41788         * lib/locale.in.h (freelocale): Use _GL_CXXALIAS_SYS_CAST instead of
41789         _GL_CXXALIAS_SYS.
41790         * lib/pthread.in.h (pthread_mutexattr_gettype,
41791         pthread_mutexattr_getrobust): Likewise.
41792         * lib/stdlib.in.h (srandom, initstate, setstate): Likewise.
41793         * lib/sys_socket.in.h (recv, send): Likewise.
41794         * lib/unistd.in.h (getdtablesize): Likewise.
41795         * lib/sys_select.in.h (select): In C++, write 'timeval' instead of
41796         'struct timeval'.
41798 2019-11-21  Bruno Haible  <bruno@clisp.org>
41800         math tests: Update after 2019-08-28 change.
41801         * tests/test-math-c++.cc (isfinite, isinf, isnan, signbit): Expect a
41802         return type of 'bool', not 'int'.
41804 2019-11-21  Bruno Haible  <bruno@clisp.org>
41806         pthread-spin: Fix errors in C++ mode.
41807         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Mark the pthread_spin_*
41808         functions as nonexistent when <pthread.h> exists but does not define
41809         the pthread_spinlock_t type.
41811 2019-11-21  Bruno Haible  <bruno@clisp.org>
41813         pthread-mutex: Fix errors in C++ mode.
41814         * m4/pthread-mutex.m4 (gl_PTHREAD_MUTEX): Test whether
41815         pthread_mutexattr_getrobust exists. If not, define
41816         PTHREAD_MUTEXATTR_ROBUST_UNIMPLEMENTED.
41817         * lib/pthread-mutex.c (pthread_mutexattr_getrobust,
41818         pthread_mutexattr_setrobust): Define also if <pthread.h> exists but
41819         PTHREAD_MUTEXATTR_ROBUST_UNIMPLEMENTED.
41820         * modules/pthread-mutex (configure.ac): Compile pthread-mutex.c also
41821         when <pthread.h> exists but pthread_mutexattr_getrobust needs a gnulib
41822         definition.
41824 2019-11-19  Bruno Haible  <bruno@clisp.org>
41826         threads-h tests: Fix typo.
41827         * tests/test-threads-c++.cc: Fix references to undefined type 'mtx'.
41829 2019-11-19  Bruno Haible  <bruno@clisp.org>
41831         pthread-thread: Fix prototype of pthread_attr_getdetachstate.
41832         * lib/pthread.in.h (pthread_attr_getdetachstate): Change first parameter
41833         to 'const pthread_attr_t *'.
41834         * lib/pthread-thread.c (pthread_attr_getdetachstate): Likewise.
41835         * tests/test-pthread-c++.cc (pthread_attr_getdetachstate): Likewise.
41837 2019-11-19  Paul Eggert  <eggert@cs.ucla.edu>
41839         intprops: speed up INT_MULTIPLY_WRAPV in GCC 9.3
41840         * lib/intprops.h (INT_MULTIPLY_WRAPV): If GCC 9.3 or later, do not
41841         work around GCC bug 91450 as the bug should be fixed there.
41843 2019-11-18  Paul Eggert  <eggert@cs.ucla.edu>
41845         glob: get closer to glibc glob.c
41846         Omit differences from glibc when the differences don’t matter.
41847         * lib/glob.c [_LIBC]: Include shlib-compat.h.
41848         (__glob) [!_LIBC]: New macro.  All uses of glob changed to __glob.
41849         (glob_lstat): New function.
41850         (glob_in_dir): Use it.
41851         (GLOB_ATTRIBUTE): Define to empty if not already defined.
41852         Use changed.
41854 2019-11-18  Bruno Haible  <bruno@clisp.org>
41856         stdint: Define [u]intptr_t correctly on 64-bit native Windows.
41857         * lib/stdint.in.h (gl_intptr_t, gl_uintptr_t, INTPTR_MIN, INTPTR_MAX,
41858         UINTPTR_MAX): Consider _WIN64.
41859         * tests/test-stdint.c: Verify that [u]intptr_t is large enough to hold
41860         a pointer.
41862 2019-11-18  Bruno Haible  <bruno@clisp.org>
41864         stdint: Fix value of WINT_MAX when we override wint_t.
41865         * lib/stdint.in.h (WINT_MIN, WINT_MAX): Don't override a second time
41866         when GNULIB_OVERRIDES_WINT_T is 1.
41868 2019-11-18  Bruno Haible  <bruno@clisp.org>
41870         vcs-to-changelog: New module.
41871         * modules/vcs-to-changelog: New file.
41872         * MODULES.html.sh (func_all_modules): Add it.
41874 2019-11-01  Siddhesh Poyarekar  <siddhesh@gotplt.org>
41876         vcs-to-changelog: New script to generate ChangeLog-like output.
41877         Discussion:
41878         <https://lists.gnu.org/archive/html/bug-gnulib/2019-10/msg00062.html>
41879         * build-aux/vcs_to_changelog.py: New file.
41880         * build-aux/vcstocl/frontend_c.py: New file.
41881         * build-aux/vcstocl/misc_util.py: New file.
41882         * build-aux/vcstocl/vcs_git.py: New file.
41884 2019-11-18  Bruno Haible  <bruno@clisp.org>
41886         stdint: Avoid triggering a "conflicting types" error on mingw 5.22.
41887         Reported by Keith Marshall <keith@users.osdn.me> in
41888         <https://lists.gnu.org/archive/html/bug-gnulib/2019-10/msg00044.html>
41889         and <https://osdn.net/projects/mingw/ticket/39677>.
41890         * lib/stdint.in.h (intptr_t, uintptr_t): Don't define if the types have
41891         already been defined by mingw's <crtdefs.h>.
41893 2019-11-18  Bruno Haible  <bruno@clisp.org>
41895         gnulib-tool: Fix build error on macOS with --conditional-dependencies.
41896         * gnulib-tool (func_modules_add_dummy): Ignore modules that are
41897         conditionally enabled.
41899 2019-11-18  Bruno Haible  <bruno@clisp.org>
41901         gc: Mirror libgcrypt.m4 from libgcrypt.
41902         * config/srclistvars.sh (LIBGCRYPT): New variable.
41903         * config/srclist.txt: Use it to fetch m4/libgcrypt.m4.
41905 2019-11-17  Bruno Haible  <bruno@clisp.org>
41907         locale, localename: Improve z/OS support.
41908         Reported by Daniel Richard G. in
41909         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00001.html>.
41910         * m4/locale_h.m4 (gl_LOCALE_T): New macro, partially extracted from
41911         gl_LOCALE_H.
41912         (gl_LOCALE_H): Require it.
41913         * m4/localename.m4 (gl_LOCALENAME): Likewise. If locale_t is not
41914         defined, don't even check for newlocale, duplocale, freelocale.
41915         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): Make the test fail when
41916         locale_t is not defined.
41918 2019-11-17  Bruno Haible  <bruno@clisp.org>
41920         havelib: Make libdirstems processing more flexible.
41921         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Set 3 libdirstem
41922         variables: Consider 'lib' always, also on Solaris. Look for lib32 in
41923         addition to lib64. Don't invoke /usr/bin/gcc (reverting the second
41924         patch from 2017-02-19).
41925         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Consider up to 3 additional
41926         libdirs, even when the first one exists as a directory.
41928 2019-11-17  Bruno Haible  <bruno@clisp.org>
41930         havelib: Match the bitness when searching for libraries.
41931         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Define a function
41932         acl_is_expected_elfclass.
41933         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): When testing whether a library
41934         file exists, in ELF, also test whether it has the ELF class that
41935         corresponds to the host's bitness.
41937 2019-11-17  Bruno Haible  <bruno@clisp.org>
41939         host-cpu-c-abi: Add support for unknown CPUs.
41940         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): Set
41941         gl_cv_host_cpu_c_abi_32bit to 'unknown' if we don't know whether it's
41942         32-bit or 64-bit.
41944 2019-11-17  Bruno Haible  <bruno@clisp.org>
41946         havelib: Remove redundant code.
41947         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Remove Solaris specific
41948         test for 64-bit host. Use gl_HOST_CPU_C_ABI_32BIT result instead.
41950 2019-11-17  Bruno Haible  <bruno@clisp.org>
41952         havelib: Fix a bug in dependency processing.
41953         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): During dependency processing
41954         of .la files, don't overwrite the value of additional_libdir for the
41955         next rounds.
41957 2019-11-16  Bruno Haible  <bruno@clisp.org>
41959         wctype-h: When overriding wint_t, override also the related functions.
41960         Reported by Christian Biesinger <cbiesinger@google.com> in
41961         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00027.html>.
41962         * m4/wctype_h.m4 (gl_WCTYPE_H): When GNULIB_OVERRIDES_WINT_T is 1, set
41963         REPLACE_ISWCNTRL to 1.
41964         * lib/wctype.in.h (rpl_iswalnum, rpl_iswalpha, rpl_iswblank,
41965         rpl_iswcntrl, rpl_iswdigit, rpl_iswgraph, rpl_iswlower, rpl_iswprint,
41966         rpl_iswpunct, rpl_iswspace, rpl_iswupper, rpl_iswxdigit, rpl_towlower,
41967         rpl_towupper): New definitions when GNULIB_OVERRIDES_WINT_T is 1.
41968         * doc/posix-headers/wchar.texi: Mention that wint_t is also overridden
41969         on mingw.
41970         * doc/posix-headers/wctype.texi: Likewise.
41972 2019-11-16  Bruno Haible  <bruno@clisp.org>
41974         time_r: Fix for mingw.
41975         Reported by Christian Biesinger <cbiesinger@google.com> in
41976         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00014.html>.
41977         * lib/time.in.h: On mingw, include <unistd.h>.
41978         * m4/time_r.m4 (gl_TIME_R): On mingw, include <unistd.h> before
41979         <time.h>. Test for localtime_r in a way that works when it is defined
41980         as an inline function.
41982 2019-11-13  Bruno Haible  <bruno@clisp.org>
41984         havelib: Revert last change.
41985         * build-aux/config.rpath: Revert last change. We can add msys2 support
41986         when it has been added to libtool.m4 upstream.
41988 2019-11-09  Paul Eggert  <eggert@cs.ucla.edu>
41990         config: add msys support
41991         Requested by Arnold Robbins in:
41992         https://lists.gnu.org/r/bug-gnulib/2019-11/msg00008.html
41993         He also requested a change to config.guess, which I’ll forward
41994         upstream.
41995         * build-aux/ar-lib (func_file_conv):
41996         * build-aux/compile (func_file_conv):
41997         * build-aux/config.rpath (wl, with_gnu_ld)
41998         (hardcode_libdir_flag_spec, libext, shrext, library_names_spec):
41999         Treat msys like cygwin.
42001 2019-11-06  Paul Eggert  <eggert@cs.ucla.edu>
42003         regex: now back in sync with glibc
42004         * config/srclist.txt: regcomp.c, regex_internal.c, regex_internal.h,
42005         regexec.c got merged into glibc and are now copies again.
42007 2019-10-27  Bruno Haible  <bruno@clisp.org>
42009         host-cpu-c-abi: Recognize i386 and a couple of other CPUs as 32-bit.
42010         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Include i386 in the case
42011         statement.
42012         (gl_HOST_CPU_C_ABI_32BIT): Likewise. Also recognize a couple of other
42013         32-bit CPUs.
42015 2019-10-24  Paul Eggert  <eggert@cs.ucla.edu>
42017         timespec-add, timespec-sub: simplify
42018         * lib/timespec-add.c (timespec_add):
42019         * lib/timespec-sub.c (timespec_sub):
42020         Simplify, now that INT_ADD_WRAPV and INT_SUBTRACT_WRAPV
42021         work on unsigned integers.
42023 2019-10-23  Paul Eggert  <eggert@cs.ucla.edu>
42025         nstrftime: speed up integer overflow checking
42026         * lib/nstrftime.c: Include intprops.h.
42027         (INT_STRLEN_BOUND): Remove, as we can use intprops.h’s defn.
42028         (__strftime_internal): Use INT_MULTIPLY_WRAPV and INT_ADD_WRAPV
42029         instead of doing it by hand.
42030         * modules/nstrftime (Depends-on): Add intprops.
42032         Port better to GCC under macOS
42033         Work around macOS header that has ‘#define __has_builtin(x) 0’
42034         when compiled by GCC.  Apple really, really doesn’t want you to
42035         use GCC, apparently.  Rroblem reported by Akim Demaille in:
42036         https://lists.gnu.org/r/bug-bison/2019-10/msg00071.html
42037         The fix is to not trust __has_builtin when being compiled by
42038         recent-enough GCC.
42039         * lib/intprops.h (__has_builtin)
42040         (_GL_HAS___builtin_add_overflow, _GL_TEMPDEF___has_builtin):
42041         * lib/verify.h (__has_builtin, _GL_HAS___builtin_unreachable)
42042         (_GL_HAS___builtin_trap, _GL_TEMPDEF___has_builtin):
42043         Remove.  All uses removed.
42044         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW): Use __has_builtin
42045         directly, if defined and if not newer GCC.
42046         * lib/verify.h (_GL_HAS_BUILTIN_TRAP, _GL_HAS_BUILTIN_UNREACHABLE):
42047         New macro, that use __has_builtin directly, if defined and if
42048         not newer GCC.
42049         (assume): Use them.
42051 2019-10-22  Akim Demaille  <akim@lrde.epita.fr>
42053         maintainer-makefile: update rule for argmatch.
42054         * top/maint.mk (sc_prohibit_argmatch_without_use): Add ARGMATCH_DEFINE_GROUP.
42056 2019-10-21  Akim Demaille  <akim@lrde.epita.fr>
42058         bitset: let freeing functions accept NULL.
42059         * lib/bitset.c (bitset_free, bitset_obstack_free): Do nothing if
42060         given NULL.
42061         * lib/bitset.h: Document that.
42062         * doc/bitset.texi: Fix the example, and demonstrate bitset_free.
42064 2019-10-15  Paul Eggert  <eggert@cs.ucla.edu>
42066         inttypes: use more-robust test for int range
42067         This fixes Bison 3.4.2 when built with Oracle Solaris Studio 12.3.
42068         Problem reported by Dagobert Michelsen in:
42069         https://lists.gnu.org/r/bug-gnulib/2019-10/msg00042.html
42070         * lib/inttypes.in.h: Rely only on limits.h when checking
42071         int range.
42073 2019-10-15  Bruno Haible  <bruno@clisp.org>
42075         libtextstyle-optional: Sync with current not-yet-released libtextstyle.
42076         * libtextstyle-optional (styled_ostream_get_hyperlink_ref,
42077         styled_ostream_get_hyperlink_id, styled_ostream_set_hyperlink,
42078         term_ostream_get_hyperlink_ref, term_ostream_get_hyperlink_id,
42079         term_ostream_set_hyperlink): New functions.
42080         (term_styled_ostream_get_hyperlink_ref,
42081         term_styled_ostream_get_hyperlink_id,
42082         term_styled_ostream_set_hyperlink): New function aliases.
42084 2019-10-14  Paul Eggert  <eggert@cs.ucla.edu>
42086         update-copyright: use en dashes in .texi ranges
42087         * build-aux/update-copyright: Match year ranges like "1998--2019",
42088         which are used in the Autoconf manual.  Also, update ranges in
42089         .tex, .texi, and .texinfo files to use en dashes instead of
42090         hyphens.
42092 2019-10-13  Paul Eggert  <eggert@cs.ucla.edu>
42094         * config/srclist.txt: Remove posix/regex_internal.c for now.
42096 2019-10-13  Bruno Haible  <bruno@clisp.org>
42098         git-version-gen: Allow 'snapshot' as .tarball-version contents.
42099         * build-aux/git-version-gen: Don't map non-numeric .tarball-version
42100         contents to the empty string.
42102 2019-10-12  Bruno Haible  <bruno@clisp.org>
42104         intprops tests: Fix compilation errors on HP-UX/ia64 with cc.
42105         * tests/test-intprops.c (main): Disable two more tests when using
42106         HP-UX cc.
42108 2019-10-11  Paul Eggert  <eggert@cs.ucla.edu>
42110         Simplify and regularize regex use of ‘assert’
42111         Also, tell GCC about the asserts even when compiling without
42112         debugging, to give it further optimization opportunities.
42113         * lib/regex_internal.h (DEBUG_ASSERT): New macro.
42114         * lib/regcomp.c (link_nfa_nodes, calc_eclosure)
42115         (parse_expression, parse_bracket_exp):
42116         * lib/regex_internal.c (build_wcs_buffer)
42117         (build_wcs_upper_buffer, re_string_reconstruct)
42118         (re_string_context_at):
42119         * lib/regexec.c (re_search_stub, re_copy_regs)
42120         (re_search_internal, prune_impossible_nodes, check_matching)
42121         (check_halt_state_context, set_regs, sift_states_backward)
42122         (build_sifted_states, transit_state_mb, transit_state_bkref)
42123         (check_arrival_add_next_nodes, check_arrival_expand_ecl)
42124         (match_ctx_add_subtop):
42125         Use it instead of plain ‘assert’.
42127 2019-10-09  Paul Eggert  <eggert@cs.ucla.edu>
42129         regex: omit debug assignment when not debugging
42130         * lib/regexec.c (re_search_internal) [!DEBUG]:
42131         Remove unnecessary assignment.
42133         regex: tell compiler there’s at most 256 arcs out
42134         Partly this is to help the reader (and maybe help GCC);
42135         partly this is to pacify Coverity.
42136         * lib/regex_internal.h: Include verify.h.
42137         * lib/regexec.c (group_nodes_into_DFAstates):
42138         Tell the compiler that ndests cannot exceed SBC_MAX.
42139         * modules/regex (Depends-on): Add ‘verify’.
42141         regex: simplify by assuming C99
42142         * config/srclist.txt: Comment out regex_internal.h and regexec.c
42143         temporarily.
42144         * lib/regex_internal.h (lock_define, re_match_context_t):
42145         Simplify by assuming C99 macros and const.
42146         * lib/regexec.c (re_search_internal): Simplify by assuming C99
42147         initializers.  Remove unnecessary assignment, as mctx is now
42148         safely initialized earlier.
42150         regex: avoid copying of uninitialized storage
42151         * config/srclist.txt: Comment out regcomp.c temporarily.
42152         * lib/regcomp.c (build_charclass_op, create_tree) [! (GCC_LINT||lint)]:
42153         Initialize even when not checking for lint, as the behavior is
42154         arguably undefined otherwise and Coverity warns about it.
42156 2019-10-06  Bruno Haible  <bruno@clisp.org>
42158         access tests: Fix test failure when run as root.
42159         * tests/test-access.c: Include root-uid.h.
42160         (geteuid): Define fallback.
42161         (main): Don't expect that writing to a read-only file would fail when
42162         running as root. Also, remove the created files at the end.
42163         * modules/access-tests (Depends-on): Add root-uid.
42164         (configure.ac): Test whether geteuid exists.
42166 2019-10-06  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
42168         users.txt: add GNU nano
42169         Nano has been making use of gnulib since March 2017, version 2.8.0.
42171 2019-10-05  Paul Eggert  <eggert@cs.ucla.edu>
42173         bootstrap: simplify debugging of wget failures
42174         Problem reported by Tim Rühsen in:
42175         https://lists.gnu.org/r/bug-gnulib/2019-10/msg00000.html
42176         * build-aux/bootstrap (po_download_command_format):
42177         Invoke wget with -nv instead of -q, to make debugging easier.
42179 2019-09-29  Bruno Haible  <bruno@clisp.org>
42181         avltree-list: Fix compilation warning (introduced on 2014-09-16).
42182         * lib/gl_avltree_list.c (gl_avltree_list_check_invariants): Remove
42183         'const' attribute.
42185 2019-09-29  Bruno Haible  <bruno@clisp.org>
42187         fbufmode: Fix compilation error on glibc >= 2.28 systems.
42188         * lib/stdio-impl.h (_IO_UNBUFFERED): Define fallback on glibc >= 2.28.
42190 2019-09-28  Bruno Haible  <bruno@clisp.org>
42192         Update comments that refer to POSIX.
42193         * lib/creat.c, lib/fopen.c, lib/open.c, lib/openat.c: Cite the relevant
42194         sentence about trailing slashes.
42195         * lib/fflush.c: Clarify the reasoning.
42196         * tests/test-fflush2.c: Cite the relevant sentence.
42198 2019-09-28  Bruno Haible  <bruno@clisp.org>
42200         access: Document limitations on Windows.
42201         Suggested by Zaretskii <eliz@gnu.org>.
42202         * doc/posix-functions/access.texi: Mention two limitations on Windows.
42204 2019-09-28  Bruno Haible  <bruno@clisp.org>
42206         findprog-in: Fix comment.
42207         Reported by Eli Zaretskii <eliz@gnu.org>.
42208         * lib/findprog.h (find_in_given_path): Extend description of EACCES
42209         condition.
42210         * lib/stat.c (rpl_stat): Fix typo in comment.
42211         * lib/utime.c (_gl_utimens_windows): Likewise.
42213 2019-09-23  Paul Eggert  <eggert@cs.ucla.edu>
42215         Update URLs and associated text
42216         (Thanks to Bruno Haible for proofreading this patch.)
42217         Prefer https: to http: in URLs where either will do, for the usual
42218         security reasons.  I also updated broken and/or moved URLs
42219         discovered during the process. In a few places I had to resort to
42220         archive.org, since I didn't find the originals elsewhere.
42222 2019-09-15  Paul Smith  <psmith@gnu.org>
42223             Bruno Haible  <bruno@clisp.org>
42225         findprog-in: Set errno when the search fails.
42226         * lib/findprog-in.c: Include <errno.h>.
42227         (find_in_given_path): Set errno before returning NULL.
42228         * lib/findprog.h (find_in_given_path): Update comment accordingly.
42229         Define the term "slash".
42231 2019-09-15  Bruno Haible  <bruno@clisp.org>
42233         findprog, findprog-lgpl, findprog-in: Fix crash on MSVC.
42234         * modules/findprog (Depends-on): Add access.
42235         * modules/findprog-lgpl (Depends-on): Likewise.
42236         * modules/findprog-in (Depends-on): Likewise.
42238 2019-09-15  Bruno Haible  <bruno@clisp.org>
42240         access: Add tests.
42241         * tests/test-access.c: New file.
42242         * modules/access-tests: New file.
42244         access: New module.
42245         * lib/unistd.in.h (access): New declaration.
42246         * lib/access.c: New file.
42247         * m4/access.m4: New file.
42248         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether access is declared.
42249         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ACCESS, REPLACE_ACCESS.
42250         * modules/unistd (Makefile.am): Substitute GNULIB_ACCESS,
42251         REPLACE_ACCESS.
42252         * modules/access: New file.
42253         * tests/test-unistd-c++.cc (access): Check signature.
42254         * doc/posix-functions/access.texi: Mention the new module.
42256 2019-09-15  Bruno Haible  <bruno@clisp.org>
42258         fcntl-h: Fix compilation error of creat.c on MSVC.
42259         * lib/fcntl.in.h: Include <io.h> also when __need_system_fcntl_h is
42260         defined.
42262 2019-09-15  Bruno Haible  <bruno@clisp.org>
42264         creat: Add tests.
42265         * tests/test-creat.c: New file, based on tests/test-open.h.
42266         * modules/creat-tests: New file.
42268         creat: New module.
42269         * lib/fcntl.in.h (creat): New declaration.
42270         * lib/creat.c: New file, based on lib/open.c.
42271         * m4/creat.m4: New file.
42272         * m4/open-slash.m4: New file, extracted from m4/open.m4.
42273         * m4/open.m4 (gl_FUNC_OPEN): Move trailing-slash test to open-slash.m4.
42274         Invoke gl_OPEN_TRAILING_SLASH_BUG.
42275         * modules/open (Files): Add m4/open-slash.m4.
42276         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize GNULIB_CREAT,
42277         REPLACE_CREAT.
42278         * modules/fcntl-h (Makefile.am): Substitute GNULIB_CREAT, REPLACE_CREAT.
42279         * modules/creat: New file.
42280         * tests/test-fcntl-h-c++.cc (creat): Check signature.
42281         * doc/posix-functions/creat.texi: Mention the new module.
42283 2019-09-15  Bruno Haible  <bruno@clisp.org>
42285         open tests: Enhance test.
42286         * tests/test-open.h (test_open): Test the creation of an executable
42287         regular file. Also improve initial cleanup.
42289 2019-09-15  Bruno Haible  <bruno@clisp.org>
42291         intprops tests: Avoid build failure with HP-UX cc.
42292         * tests/test-intprops.c: Disable a check that makes HP cc choke with
42293         "error 4018: Macro param too large after substitution - use -H option.".
42295 2019-09-14  Bruno Haible  <bruno@clisp.org>
42297         Make autoconf tests work with -Werror=implicit-function-declaration.
42298         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Include <wctype.h>, for
42299         towupper() declaration.
42300         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Include <stdlib.h>, for ptsname()
42301         declaration.
42303 2019-09-14  Bruno Haible  <bruno@clisp.org>
42305         findprog-in: Better mimic the system on native Windows.
42306         Reported by Paul Smith <psmith@gnu.org>.
42307         * lib/findprog-in.c (find_in_given_path): On native Windows, don't try
42308         non-empty suffixes when the file name already contains a '.'.
42310 2019-09-10  Bruno Haible  <bruno@clisp.org>
42312         wctob: Fix autoconf test.
42313         Based on patch by Florian Weimer <fweimer@redhat.com>.
42314         * m4/wctob.m4 (gl_FUNC_WCTOB): Include <stdlib.h> before using mbtowc.
42316 2019-09-09  Akim Demaille  <akim@lrde.epita.fr>
42318         xhash: provide hash_xinitialize.
42319         Suggested by Egor Pugin <egor.pugin@gmail.com>
42320         https://lists.gnu.org/archive/html/bison-patches/2019-09/msg00026.html
42321         * modules/xhash, lib/xhash.c: New.
42322         * lib/hash.h (hash_xinitialize): New.
42324 2019-09-09  Bruno Haible  <bruno@clisp.org>
42326         findprog-in: Make exec optimization optional.
42327         * lib/findprog.h: Add double-inclusion guard. Include <stdbool.h>.
42328         (find_in_given_path): Add optimize_for_exec parameter.
42329         * lib/findprog-in.c (find_in_given_path): Likewise.
42331 2019-09-08  Bruno Haible  <bruno@clisp.org>
42333         Add option to assume the best, not the worst, when cross-compiling.
42334         Suggested by Jonas Termansen <sortie@maxsi.org>.
42335         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add --enable-cross-guesses=...
42336         option. Set gl_cross_guess_normal and gl_cross_guess_inverted.
42337         * m4/argz.m4 (gl_FUNC_ARGZ): Obey --enable-cross-guesses for
42338         lt_cv_sys_argz_works.
42339         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Obey --enable-cross-guesses for
42340         ac_cv_func_calloc_0_nonnull.
42341         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Obey
42342         --enable-cross-guesses for gl_cv_func_realpath_works.
42343         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Obey --enable-cross-guesses for
42344         gl_cv_func_cbrtl_ieee.
42345         * m4/ceil.m4 (gl_FUNC_CEIL): Obey --enable-cross-guesses for
42346         gl_cv_func_ceil_ieee.
42347         * m4/ceilf.m4 (gl_FUNC_CEILF): Obey --enable-cross-guesses for
42348         gl_cv_func_ceilf_ieee.
42349         * m4/ceill.m4 (gl_FUNC_CEILL): Obey --enable-cross-guesses for
42350         gl_cv_func_ceill_ieee.
42351         * m4/chown.m4 (AC_FUNC_CHOWN): Obey --enable-cross-guesses for
42352         ac_cv_func_chown_works.
42353         (gl_FUNC_CHOWN): Obey --enable-cross-guesses for
42354         gl_cv_func_chown_slash_works, gl_cv_func_chown_ctime_works.
42355         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Obey
42356         --enable-cross-guesses for gl_cv_struct_dirent_d_ino.
42357         * m4/exp2l.m4 (gl_FUNC_EXP2L): Obey --enable-cross-guesses for
42358         gl_cv_func_exp2l_works, gl_cv_func_exp2l_ieee.
42359         * m4/expl.m4 (gl_FUNC_EXPL): Obey --enable-cross-guesses for
42360         gl_cv_func_expl_works.
42361         * m4/expm1.m4 (gl_FUNC_EXPM1): Obey --enable-cross-guesses for
42362         gl_cv_func_expm1_ieee.
42363         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Obey --enable-cross-guesses for
42364         gl_cv_func_expm1l_works.
42365         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Obey --enable-cross-guesses for
42366         gl_cv_func_open_directory_works.
42367         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Obey
42368         --enable-cross-guesses for gl_cv_func_fchownat_nofollow_works.
42369         (gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Obey --enable-cross-guesses for
42370         gl_cv_func_fchownat_empty_filename_works.
42371         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Obey --enable-cross-guesses for
42372         gl_cv_func_fdopendir_works.
42373         * m4/floor.m4 (gl_FUNC_FLOOR): Obey --enable-cross-guesses for
42374         gl_cv_func_floor_ieee.
42375         * m4/floorf.m4 (gl_FUNC_FLOORF): Obey --enable-cross-guesses for
42376         gl_cv_func_floorf_ieee.
42377         * m4/fma.m4 (gl_FUNC_FMA_WORKS): Obey --enable-cross-guesses for
42378         gl_cv_func_fma_works.
42379         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Obey --enable-cross-guesses for
42380         gl_cv_func_fmaf_works.
42381         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Obey --enable-cross-guesses for
42382         gl_cv_func_fmal_works.
42383         * m4/fmod.m4 (gl_FUNC_FMOD): Obey --enable-cross-guesses for
42384         gl_cv_func_fmod_ieee.
42385         * m4/fmodf.m4 (gl_FUNC_FMODF): Obey --enable-cross-guesses for
42386         gl_cv_func_fmodf_ieee.
42387         * m4/fmodl.m4 (gl_FUNC_FMODL): Obey --enable-cross-guesses for
42388         gl_cv_func_fmodl_ieee.
42389         * m4/fpurge.m4 (gl_FUNC_FPURGE): Obey --enable-cross-guesses for
42390         gl_cv_func_fpurge_works.
42391         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Obey
42392         --enable-cross-guesses for gl_cv_func_getcwd_path_max.
42393         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Obey --enable-cross-guesses for
42394         gl_cv_func_getcwd_null.
42395         (gl_FUNC_GETCWD): Update for getcwd-path-max.m4 change.
42396         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Obey --enable-cross-guesses for
42397         gl_cv_func_working_getdelim.
42398         * m4/getgroups.m4 (AC_FUNC_GETGROUPS): Obey --enable-cross-guesses for
42399         ac_cv_func_getgroups_works. Keep this macro also in Autoconf >= 2.70.
42400         (gl_FUNC_GETGROUPS): Obey --enable-cross-guesses for
42401         gl_cv_func_getgroups_works.
42402         * m4/getline.m4 (gl_FUNC_GETLINE): Obey --enable-cross-guesses for
42403         am_cv_func_working_getline.
42404         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Obey --enable-cross-guesses
42405         for gl_cv_func_getopt_gnu.
42406         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Obey
42407         --enable-cross-guesses for gl_cv_func_gettimeofday_clobber.
42408         * m4/hypot.m4 (gl_FUNC_HYPOT): Obey --enable-cross-guesses for
42409         gl_cv_func_hypot_ieee.
42410         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Obey --enable-cross-guesses for
42411         gl_cv_func_hypotf_ieee.
42412         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Obey --enable-cross-guesses for
42413         gl_cv_func_hypotl_ieee.
42414         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): Obey
42415         --enable-cross-guesses for gl_cv_func_iconv_supports_utf.
42416         * m4/link.m4 (gl_FUNC_LINK): Obey --enable-cross-guesses for
42417         gl_cv_func_link_works.
42418         * m4/linkat.m4 (gl_FUNC_LINKAT): Obey --enable-cross-guesses for
42419         gl_cv_func_linkat_slash.
42420         * m4/log.m4 (gl_FUNC_LOG): Obey --enable-cross-guesses for
42421         gl_cv_func_log_ieee.
42422         * m4/logf.m4 (gl_FUNC_LOGF): Obey --enable-cross-guesses for
42423         gl_cv_func_logf_ieee.
42424         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Obey --enable-cross-guesses for
42425         gl_cv_func_logl_works.
42426         * m4/log10.m4 (gl_FUNC_LOG10): Obey --enable-cross-guesses for
42427         gl_cv_func_log10_ieee.
42428         * m4/log10f.m4 (gl_FUNC_LOG10F): Obey --enable-cross-guesses for
42429         gl_cv_func_log10f_ieee.
42430         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Obey --enable-cross-guesses for
42431         gl_cv_func_log10l_works.
42432         * m4/log1p.m4 (gl_FUNC_LOG1P): Obey --enable-cross-guesses for
42433         gl_cv_func_log1p_ieee.
42434         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Obey --enable-cross-guesses for
42435         gl_cv_func_log1pf_ieee.
42436         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Obey --enable-cross-guesses for
42437         gl_cv_func_log1pl_ieee.
42438         * m4/log2.m4 (gl_FUNC_LOG2): Obey --enable-cross-guesses for
42439         gl_cv_func_log2_ieee.
42440         * m4/log2f.m4 (gl_FUNC_LOG2F): Obey --enable-cross-guesses for
42441         gl_cv_func_log2f_ieee.
42442         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Obey
42443         --enable-cross-guesses for
42444         gl_cv_func_lstat_dereferences_slashed_symlink.
42445         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Obey --enable-cross-guesses for
42446         ac_cv_func_malloc_0_nonnull. Keep this macro also in Autoconf >= 2.70.
42447         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): Obey --enable-cross-guesses for
42448         gl_cv_C_locale_sans_EILSEQ.
42449         * m4/memchr.m4 (gl_FUNC_MEMCHR): Obey --enable-cross-guesses for
42450         gl_cv_func_memchr_works.
42451         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Obey --enable-cross-guesses for
42452         gl_cv_func_memmem_works_always.
42453         (gl_FUNC_MEMMEM): Obey --enable-cross-guesses for
42454         gl_cv_func_memmem_works_fast.
42455         * m4/mkdir.m4 (gl_FUNC_MKDIR): Obey --enable-cross-guesses for
42456         gl_cv_func_mkdir_trailing_slash_works,
42457         gl_cv_func_mkdir_trailing_dot_works.
42458         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Obey --enable-cross-guesses for
42459         gl_cv_func_mkfifo_works.
42460         * m4/mknod.m4 (gl_FUNC_MKNOD): Obey --enable-cross-guesses for
42461         gl_cv_func_mknod_works.
42462         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Obey --enable-cross-guesses for
42463         gl_cv_func_working_mkstemp.
42464         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Obey --enable-cross-guesses for
42465         gl_cv_func_working_mktime.
42466         * m4/modf.m4 (gl_FUNC_MODF): Obey --enable-cross-guesses for
42467         gl_cv_func_modf_ieee.
42468         * m4/modff.m4 (gl_FUNC_MODFF): Obey --enable-cross-guesses for
42469         gl_cv_func_modff_ieee.
42470         * m4/modfl.m4 (gl_FUNC_MODFL): Obey --enable-cross-guesses for
42471         gl_cv_func_modfl_ieee.
42472         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Obey --enable-cross-guesses for
42473         gl_cv_func_nanosleep.
42474         * m4/perror.m4 (gl_FUNC_PERROR): Obey --enable-cross-guesses for
42475         gl_cv_func_perror_works.
42476         * m4/printf.m4 (gl_PRINTF_SIZES_C99): Obey --enable-cross-guesses for
42477         gl_cv_func_printf_sizes_c99.
42478         (gl_PRINTF_INFINITE): Obey --enable-cross-guesses for
42479         gl_cv_func_printf_infinite.
42480         (gl_PRINTF_INFINITE_LONG_DOUBLE): Obey --enable-cross-guesses for
42481         gl_cv_func_printf_infinite_long_double.
42482         (gl_PRINTF_DIRECTIVE_A): Obey --enable-cross-guesses for
42483         gl_cv_func_printf_directive_a.
42484         (gl_PRINTF_DIRECTIVE_F): Obey --enable-cross-guesses for
42485         gl_cv_func_printf_directive_f.
42486         (gl_PRINTF_FLAG_ZERO): Obey --enable-cross-guesses for
42487         gl_cv_func_printf_flag_zero.
42488         (gl_PRINTF_ENOMEM): Obey --enable-cross-guesses for
42489         gl_cv_func_printf_enomem.
42490         (gl_SNPRINTF_TRUNCATION_C99): Obey --enable-cross-guesses for
42491         gl_cv_func_snprintf_truncation_c99.
42492         (gl_SNPRINTF_RETVAL_C99): Obey --enable-cross-guesses for
42493         gl_cv_func_snprintf_retval_c99.
42494         (gl_SNPRINTF_DIRECTIVE_N): Obey --enable-cross-guesses for
42495         gl_cv_func_snprintf_directive_n.
42496         (gl_VSNPRINTF_ZEROSIZE_C99): Obey --enable-cross-guesses for
42497         gl_cv_func_vsnprintf_zerosize_c99.
42498         * m4/pselect.m4 (gl_FUNC_PSELECT): Obey --enable-cross-guesses for
42499         gl_cv_func_pselect_detects_ebadf.
42500         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
42501         Obey --enable-cross-guesses for
42502         gl_cv_pthread_rwlock_rdlock_prefer_writer.
42503         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Obey --enable-cross-guesses for
42504         gl_cv_func_ptsname_sets_errno.
42505         * m4/putenv.m4 (gl_FUNC_PUTENV): Obey --enable-cross-guesses for
42506         gl_cv_func_svid_putenv.
42507         * m4/readlink.m4 (gl_FUNC_READLINK): Obey --enable-cross-guesses for
42508         gl_cv_func_readlink_works.
42509         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Obey --enable-cross-guesses for
42510         ac_cv_func_realloc_0_nonnull. Keep this macro also in Autoconf >= 2.70.
42511         * m4/regex.m4 (gl_REGEX): Obey --enable-cross-guesses for
42512         gl_cv_func_re_compile_pattern_working.
42513         * m4/remainder.m4 (gl_FUNC_REMAINDER): Obey --enable-cross-guesses for
42514         gl_cv_func_remainder_ieee.
42515         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Obey --enable-cross-guesses for
42516         gl_cv_func_remainderf_ieee.
42517         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Obey --enable-cross-guesses for
42518         gl_cv_func_remainderl_ieee.
42519         * m4/rintl.m4 (gl_FUNC_RINTL): Obey --enable-cross-guesses for
42520         gl_cv_func_rintl_works.
42521         * m4/rmdir.m4 (gl_FUNC_RMDIR): Obey --enable-cross-guesses for
42522         gl_cv_func_rmdir_works.
42523         * m4/round.m4 (gl_FUNC_ROUND): Obey --enable-cross-guesses for
42524         gl_cv_func_round_ieee.
42525         * m4/roundf.m4 (gl_FUNC_ROUNDF): Obey --enable-cross-guesses for
42526         gl_cv_func_roundf_ieee.
42527         * m4/roundl.m4 (gl_FUNC_ROUNDL): Obey --enable-cross-guesses for
42528         gl_cv_func_roundl_ieee.
42529         * m4/select.m4 (gl_FUNC_SELECT): Obey --enable-cross-guesses for
42530         gl_cv_func_select_detects_ebadf.
42531         * m4/setenv.m4 (gl_FUNC_SETENV): Obey --enable-cross-guesses for
42532         gl_cv_func_setenv_works.
42533         (gl_FUNC_UNSETENV): Obey --enable-cross-guesses for
42534         gl_cv_func_unsetenv_works.
42535         * m4/signbit.m4 (gl_SIGNBIT): Obey --enable-cross-guesses for
42536         gl_cv_func_signbit, gl_cv_func_signbit_gcc.
42537         * m4/sleep.m4 (gl_FUNC_SLEEP): Obey --enable-cross-guesses for
42538         gl_cv_func_sleep_works.
42539         * m4/stat.m4 (gl_FUNC_STAT): Obey --enable-cross-guesses for
42540         gl_cv_func_stat_file_slash.
42541         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Obey --enable-cross-guesses for
42542         gl_cv_func_stpncpy.
42543         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Obey
42544         --enable-cross-guesses for gl_cv_func_strcasestr_works_always.
42545         (gl_FUNC_STRCASESTR): Obey --enable-cross-guesses for
42546         gl_cv_func_strcasestr_linear.
42547         * m4/strerror.m4 (gl_FUNC_STRERROR): Obey --enable-cross-guesses for
42548         gl_cv_func_working_strerror.
42549         (gl_FUNC_STRERROR_0): Obey --enable-cross-guesses for
42550         gl_cv_func_strerror_0_works.
42551         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Obey
42552         --enable-cross-guesses for gl_cv_func_strerror_r_works.
42553         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Obey --enable-cross-guesses for
42554         gl_cv_func_strstr_works_always.
42555         (gl_FUNC_STRSTR): Obey --enable-cross-guesses for
42556         gl_cv_func_strstr_linear.
42557         * m4/strtod.m4 (gl_FUNC_STRTOD): Obey --enable-cross-guesses for
42558         gl_cv_func_strtod_works.
42559         * m4/strtold.m4 (gl_FUNC_STRTOLD): Obey --enable-cross-guesses for
42560         gl_cv_func_strtold_works.
42561         * m4/symlink.m4 (gl_FUNC_SYMLINK): Obey --enable-cross-guesses for
42562         gl_cv_func_symlink_works.
42563         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Obey --enable-cross-guesses for
42564         gl_cv_func_symlinkat_works.
42565         * m4/trunc.m4 (gl_FUNC_TRUNC): Obey --enable-cross-guesses for
42566         gl_cv_func_trunc_ieee.
42567         * m4/truncf.m4 (gl_FUNC_TRUNCF): Obey --enable-cross-guesses for
42568         gl_cv_func_truncf_ieee.
42569         * m4/truncl.m4 (gl_FUNC_TRUNCL): Obey --enable-cross-guesses for
42570         gl_cv_func_truncl_ieee.
42571         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Obey --enable-cross-guesses for
42572         gl_cv_func_tzset_clobber.
42573         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Obey --enable-cross-guesses for
42574         gl_cv_func_ungetc_works.
42575         * m4/unlink.m4 (gl_FUNC_UNLINK): Obey --enable-cross-guesses for
42576         gl_cv_func_unlink_honors_slashes, gl_cv_func_unlink_parent_fails.
42577         * m4/usleep.m4 (gl_FUNC_USLEEP): Obey --enable-cross-guesses for
42578         gl_cv_func_usleep_works.
42579         * m4/utimens.m4 (gl_UTIMENS): Obey --enable-cross-guesses for
42580         gl_cv_func_futimesat_works.
42581         * m4/utimes.m4 (gl_FUNC_UTIMES): Obey --enable-cross-guesses for
42582         gl_cv_func_working_utimes.
42583         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Obey --enable-cross-guesses for
42584         gl_cv_func_wcwidth_works.
42585         * m4/glob.m4 (gl_GLOB): When cross-compiling, don't create symlinks for
42586         testing. Obey --enable-cross-guesses for gl_cv_glob_lists_symlinks.
42587         * m4/rename.m4 (gl_FUNC_RENAME): When cross-compiling, don't create
42588         links for testing. Obey --enable-cross-guesses for
42589         gl_cv_func_rename_slash_dst_works, gl_cv_func_rename_slash_src_works,
42590         gl_cv_func_rename_link_works, gl_cv_func_rename_dest_works.
42592 2019-09-08  Bruno Haible  <bruno@clisp.org>
42594         Clarify that cross-compilation guesses are guesses.
42595         * m4/threads.m4 (gl_THREADS_H): Say "guessing yes" or "guessing no" when
42596         cross-compiling.
42598 2019-09-08  Bruno Haible  <bruno@clisp.org>
42600         chown: Fix configure output (regression from 2019-03-23).
42601         * m4/chown.m4 (gl_FUNC_CHOWN): Fix reference to
42602         gl_cv_func_chown_follows_symlink variable.
42604 2019-09-08  Bruno Haible  <bruno@clisp.org>
42606         findprog-in: New module.
42607         Suggested by Paul Smith <psmith@gnu.org>.
42608         * lib/findprog.h (find_in_given_path): New declaration.
42609         * lib/findprog-in.c: New file, based on lib/findprog.c.
42610         * m4/findprog-in.m4: New file, based on m4/findprog.m4.
42611         * modules/findprog-in: New file.
42613 2019-09-08  Bruno Haible  <bruno@clisp.org>
42615         findprog: Remove unused dependency.
42616         * modules/findprog (Depends-on): Remove strdup.
42618 2019-09-08  Bruno Haible  <bruno@clisp.org>
42620         findprog: Remove test that is obsolete since 2006-04-24.
42621         * m4/findprog.m4 (gl_FINDPROG): Don't test for unistd.h.
42623 2019-09-06  Akim Demaille  <akim@lrde.epita.fr>
42625         bitset: style changes
42626         * lib/bitset/vector.c (vbitset_resize): Factor computation.
42627         * lib/bitset.c, lib/bitset/stats.c, lib/bitsetv.c: Prefer
42628         xzalloc to xcalloc.
42629         Suggested by Paul Eggert.
42631 2019-09-06  Akim Demaille  <akim@lrde.epita.fr>
42633         bitset: check memory allocation
42634         Reported by 江 祖铭 (Zu-Ming Jiang).
42635         With help from Paul Eggert.
42636         https://lists.gnu.org/archive/html/bug-bison/2019-08/msg00016.html
42637         * lib/bitset/table.c (tbitset_resize): When growing, use xrealloc
42638         instead of realloc.
42639         When shrinking, accept failures.
42640         * lib/bitset/vector.c (vbitset_resize): Likewise.
42642 2019-09-07  Paul Eggert  <eggert@cs.ucla.edu>
42644         scratch_buffer: sync from glibc
42645         * config/srclist.txt: Add the scratch_buffer source
42646         code from glibc, since these should be in sync.
42647         Autoupdate.
42649 2019-09-07  Bruno Haible  <bruno@clisp.org>
42651         doc: Update for glibc 2.30.
42652         * doc/glibc-functions/gettid.texi: New file.
42653         * doc/glibc-functions/pthread_cond_clockwait.texi: New file.
42654         * doc/glibc-functions/pthread_mutex_clocklock.texi: New file.
42655         * doc/glibc-functions/pthread_rwlock_clockrdlock.texi: New file.
42656         * doc/glibc-functions/pthread_rwlock_clockwrlock.texi: New file.
42657         * doc/glibc-functions/sem_clockwait.texi: New file.
42658         * doc/glibc-functions/tgkill.texi: New file.
42659         * doc/glibc-functions/twalk_r.texi: New file.
42660         * doc/gnulib.texi: Include them.
42661         (Glibc semaphore.h): New section.
42662         * doc/pastposix-functions/h_errno.texi: Update.
42663         * doc/posix-functions/*.texi: Likewise.
42665 2019-09-06  Bruno Haible  <bruno@clisp.org>
42667         symlink tests: Avoid test failure on Linux with Lustre file system.
42668         Reported by Thomas C Oppe <Thomas.C.Oppe@erdc.dren.mil>
42669         at <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=37312>.
42670         * tests/test-symlink.h (test_symlink): Accept errno value ENOENT.
42672 2019-09-01  Bruno Haible  <bruno@clisp.org>
42674         gitsub.sh: Add support for shallow-cloning of subdirectories.
42675         * top/gitsub.sh (func_usage): Document allowed git options with
42676         'git pull'.
42677         (func_pull): Accept GIT_OPTIONS argument.
42678         (pull): Parse git options before complaining about too many arguments.
42679         Pass the git options to func_pull.
42681 2019-08-29  Bruno Haible  <bruno@clisp.org>
42683         lock: Fix cross-compilation guesses.
42684         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
42685         Require AC_CANONICAL_HOST. When cross-compiling, guess no on most
42686         platforms.
42688 2019-08-28  Bruno Haible  <bruno@clisp.org>
42690         isfinite, isinf, isnan, signbit: Fix error in C++ mode on mingw.
42691         Reported by Martin Storsjö <martin@martin.st> in
42692         <https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00075.html>.
42693         * lib/math.in.h (_GL_MATH_CXX_REAL_FLOATING_DECL_2): Add more arguments.
42694         (isfinite, isinf, isnan, signbit): On platforms that use C++ include
42695         files from GCC 6 or newer, use an override through '#define', because
42696         the inline definitions in the platform's <cmath> cannot be overridden
42697         in another way.
42699 2019-08-27  Paul Eggert  <eggert@cs.ucla.edu>
42701         Revert macOS INT_MULTIPLY_WRAPV patch
42702         Problem reported by Bruno Haible in:
42703         https://lists.gnu.org/r/bug-gnulib/2019-08/msg00076.html
42704         * lib/intprops.h (_GL_HAS___builtin_mul_overflow): Remove.
42705         (_GL_HAS_BUILTIN_MUL_OVERFLOW):
42706         Go back to working around the Clang bug on macOS.
42708 2019-08-27  Bruno Haible  <bruno@clisp.org>
42710         libtool-next-version: Fix error output.
42711         * build-aux/libtool-next-version (func_fatal_error): Fix the program
42712         name.
42714 2019-08-27  Paul Eggert  <eggert@cs.ucla.edu>
42716         Speed up INT_MULTIPLY_WRAPV on macOS
42717         Assume that __builtin_mul_overflow works OK with Clang on macOS.
42718         Mattias Engdegård says it’s safe to assume the relevant library
42719         is always available there.
42720         * lib/intprops.h (_GL_HAS___builtin_mul_overflow):
42721         New temporary internal macro.
42722         (_GL_HAS_BUILTIN_MUL_OVERFLOW):
42723         No need to work around the Clang bug on macOS.
42725 2019-08-25  Paul Eggert  <eggert@cs.ucla.edu>
42727         intprops.h, verify.h: port better to clang
42728         Improve code generated by INT_ADD_WRAPV and INT_SUBTRACT_WRAPV
42729         with Clang.  Problem reported privately by Mattias Engdegård.
42730         Also, insulate intprops.h and verify.h better against each other’s
42731         definitions of __has_builtin on non-Clang hosts.
42732         * lib/intprops.h (__has_builtin): Define a temporary substitute
42733         if __has_builtin is not already defined.
42734         (_GL_HAS___builtin_add_overflow, _GL_TEMPDEF___has_builtin):
42735         New temporary internal macros.
42736         (_GL_HAS_BUILTIN_ADD_OVERFLOW, _GL_HAS_BUILTIN_MUL_OVERFLOW):
42737         Now two separate macros, replacing the old
42738         _GL_HAS_BUILTIN_OVERFLOW, since we no longer assume that
42739         __builtin_mul_overflow is like the rest.  All uses changed.
42740         (INT_ADD_WRAPV, INT_SUBTRACT_WRAPV, INT_MULTIPLY_WRAPV):
42741         Adjust to above changes.
42742         (_GL_INT_OP_WRAPV): Remove ‘builtin’ arg, since it’s no
42743         longer relevant.  All uses changed.
42744         * lib/verify.h (__has_builtin): Treat like intprops.h,
42745         so that the two .h files do not collide with each other.
42746         (_GL_HAS___builtin_unreachable, _GL_HAS___builtin_trap)
42747         (_GL_TEMPDEF___has_builtin): New temporary internal macros.
42749 2019-08-24  Paul Eggert  <eggert@cs.ucla.edu>
42751         intprops: say why not Clang __builtin_add_overflow
42752         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW):
42753         Mention Clang in comment, responding to a query from
42754         Mattias Engdegård.
42756 2019-08-24  Bruno Haible  <bruno@clisp.org>
42758         doc: Document most of the files outside of modules.
42759         * doc/gnulib.texi (Build Infrastructure Files,
42760         Release Management Files): New chapters.
42762 2019-08-24  Bruno Haible  <bruno@clisp.org>
42764         bootstrap: Keep in sync with the 'gettext' module.
42765         Reported by Assaf Gordon in
42766         <https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00045.html>.
42767         * build-aux/po/Makefile.in.in: Update to gettext 0.20.
42768         * build-aux/po/remove-potcdate.sin: Likewise.
42770 2019-08-24  Bruno Haible  <bruno@clisp.org>
42772         crypto/gc-sha512: Add tests.
42773         * tests/test-gc-sha512.c: New file, based on tests/test-gc-sha1.c.
42774         * modules/crypto/gc-sha512-tests: New file.
42776         crypto/gc-sha256: Add tests.
42777         * tests/test-gc-sha256.c: New file, based on tests/test-gc-sha1.c.
42778         * modules/crypto/gc-sha256-tests: New file.
42780         crypto/gc-sha256, crypto/gc-sha512: New modules.
42781         * lib/gc.h (gc_sha256, gc_sha512): New declarations.
42782         * lib/gc-gnulib.c: Include sha256.h, sha512.h.
42783         (MAX_DIGEST_SIZE): Set to 64.
42784         (_gc_hash_ctx, gc_hash_open, gc_hash_digest_length, gc_hash_write,
42785         gc_hash_read, gc_hash_buffer): Add support for sha256 and sha512.
42786         (gc_sha256, gc_sha512): New functions.
42787         * lib/gc-libgcrypt.c (gc_sha256, gc_sha512): New functions.
42788         * modules/crypto/gc-sha256: New file, based on modules/crypto/gc-sha1.
42789         * modules/crypto/gc-sha512: New file, based on modules/crypto/gc-sha1.
42791 2019-08-24  Bruno Haible  <bruno@clisp.org>
42793         crypto/gc-sha1 tests: Improve output when the test fails.
42794         * tests/test-gc-sha1.c (main): In case of mismatch, print the entire
42795         output.
42797 2019-08-24  Bruno Haible  <bruno@clisp.org>
42799         crypto/gc-sm3: Fix compilation error with --with-libgcrypt.
42800         * m4/gc-sm3.m4 (gl_GC_SM3): Test whether libgcrypt supports SM3. Define
42801         LIBGCRYPT_HAS_MD_SM3.
42802         * lib/gc-libgcrypt.c: Include sm3.h.
42803         (_gc_hash_ctx, gc_hash_open, gc_hash_hmac_setkey, gc_hash_write,
42804         gc_hash_read, gc_hash_close, gc_hash_buffer, gc_sm3): Use the gnulib
42805         implementation if libgcrypt does not support SM3.
42807 2019-08-24  Bruno Haible  <bruno@clisp.org>
42809         crypto/gc-md2: Optimize and clarify code.
42810         * lib/gc-gnulib.c (gc_hash_open): Comment out md2_init_ctx invocation.
42811         * lib/gc-libgcrypt.c (gc_hash_open): Clarify why md2_init_ctx invocation
42812         is not needed.
42814 2019-08-24  Bruno Haible  <bruno@clisp.org>
42816         crypto/gc-md2: Add comment.
42817         * lib/gc-libgcrypt.c: Add comment.
42819 2019-08-24  Bruno Haible  <bruno@clisp.org>
42821         crypto/gc-{md[24],rijndael} tests: Fix link error with --with-libgcrypt.
42822         * modules/crypto/gc-md2-tests (test_gc_md2_LDADD): New variable.
42823         * modules/crypto/gc-md4-tests (test_gc_md4_LDADD): New variable.
42824         * modules/crypto/gc-rijndael-tests (test_gc_rijndael_LDADD): New
42825         variable.
42827 2019-08-24  Bruno Haible  <bruno@clisp.org>
42829         crypto/gc: Fix link error with --with-libgcrypt.
42830         * m4/gc.m4 (gl_GC): Set LIB_CRYPTO to the value found by the
42831         AC_LIB_HAVE_LINKFLAGS invocation.
42833 2019-08-24  Bruno Haible  <bruno@clisp.org>
42835         crypto/gc: Access the module indicators correctly.
42836         * lib/gc-gnulib.c: Use '#if GNULIB_GC_*', not '#ifdef GNULIB_GC_*'.
42837         * lib/gc-libgcrypt.c: Likewise.
42839 2019-08-24  Bruno Haible  <bruno@clisp.org>
42841         crypto/gc: Fix configuration with --with-libgcrypt.
42842         * m4/libgcrypt.m4: New file, copied from libgcrypt/src/libgcrypt.m4.
42843         * modules/crypto/gc (Files): Add it.
42844         * m4/gc.m4 (gl_GC): Assume AM_PATH_LIBGCRYPT is defined.
42846 2019-08-24  Bruno Haible  <bruno@clisp.org>
42848         Remove unused file.
42849         * m4/stat-macros.m4: Remove file.
42851 2019-08-21  Paul Eggert  <eggert@cs.ucla.edu>
42853         New strip-trailing-space option for srclist-update
42854         * config/srclist-update (fixfile): Support new option.
42855         * config/srclist.txt (texinfo.tex, maintain.texi, standards.texi):
42856         Use it.
42858 2019-08-20  Eric Blake  <eblake@redhat.com>
42860         accept4: Support SOCK_NONBLOCK, if defined
42861         * lib/accept4.c (accept4): If SOCK_NONBLOCK is defined, honor it.
42863         accept4: Fix compilation when native accept4() exists.
42864         Reported by Richard W.M. Jones <rjones@redhat.com> in
42865         https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00029.html
42866         * lib/accept4.c (accept4): Match witness symbol to m4 file update.
42868 2019-08-18  Bruno Haible  <bruno@clisp.org>
42870         Defeat -flto GCC optimization in math autoconf tests.
42871         Reported by Tomasz Kłoczko <kloczko.tomasz@gmail.com>
42872         at <https://savannah.gnu.org/bugs/?56109>.
42873         * m4/mathfunc.m4 (gl_MATHFUNC): Mark function pointer as 'volatile'.
42874         * m4/acosl.m4 (gl_FUNC_ACOSL): Likewise.
42875         * m4/asinl.m4 (gl_FUNC_ASINL): Likewise.
42876         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
42877         * m4/cosl.m4 (gl_FUNC_COSL): Likewise.
42878         * m4/exp2.m4 (gl_FUNC_EXP2): Likewise.
42879         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
42880         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
42881         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Likewise.
42882         * m4/sinl.m4 (gl_FUNC_SINL): Likewise.
42883         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Likewise.
42884         * m4/tanl.m4 (gl_FUNC_TANL): Likewise.
42886 2019-08-17  Bruno Haible  <bruno@clisp.org>
42888         windows-spin: Implement declared functions.
42889         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
42890         <https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00024.html>.
42891         * lib/windows-spin.c (glwthread_spin_trylock): Fix typo in function
42892         name.
42894 2019-08-17  Paul Eggert  <eggert@cs.ucla.edu>
42896         intprops: port to Oracle Developer Studio 12.6
42897         * lib/intprops.h (_GL_INT_OP_WRAPV): Fix recently-introduced
42898         typos that were in a section not compiled by GCC.
42900 2019-08-14  Paul Eggert  <eggert@cs.ucla.edu>
42902         intprops: support uchar, ushort _WRAPV dests
42903         * lib/intprops.h (_GL_INT_OP_WRAPV_SMALLISH): New macro, defined
42904         when __builtin_add_overflow etc. and _Generic are not used.
42905         (_GL_INT_OP_WRAPV): Use it to support destinations that
42906         are unsigned char or unsigned short, even in compilers
42907         that lack __typeof__ and are not C11-compatible.
42909         intprops: pacify picky GCC
42910         * lib/intprops.h (_GL_BUILTIN_MUL_OVERFLOW):
42911         Pacify GCC’s complaints about ignoring __builtin_mul_overflow’s
42912         possibly-incorrect result.
42913         (_GL_INT_MULTIPLY_RANGE_OVERFLOW): Pacify GCC’s complaints
42914         about (A) used as a boolean, when A is an expression like 3 * 4.
42916         intprops: support unsigned *_WRAPV results
42917         Add support for unsigned, unsigned long, and unsigned long long
42918         results to INT_ADD_WRAPV, INT_SUBTRACT_WRAPV, and
42919         INT_MULTIPLY_WRAPV.  Also, work around GCC bug 91450, and fix a
42920         bug with unsigned inputs reported by Eli Zaretskii in:
42921         https://lists.gnu.org/r/bug-gnulib/2019-08/msg00012.html
42922         * config/srclist.txt: Break the glibc connection for intprops.h
42923         temporarily, while more testing is done in Gnulib-using apps.
42924         * lib/intprops.h (INT_ADD_WRAPV, INT_SUBTRACT_WRAPV)
42925         (INT_MULTIPLY_WRAPV, _GL_INT_OP_WRAPV, _GL_INT_OP_WRAPV_LONGISH):
42926         Support unsigned results no narrower than unsigned int.  Report
42927         overflow correctly if some arguments are unsigned.
42928         (_GL_BUILTIN_MUL_OVERFLOW): New macro, to work around GCC bug 91450.
42929         (_GL_INT_OP_CALC): Simplify now that the OVERFLOW argument does
42930         the right thing with narrow args.
42931         (_GL_INT_OP_CALC1): Remove.  All callers removed.
42932         (_GL_INT_ADD_RANGE_OVERFLOW, _GL_INT_SUBTRACT_RANGE_OVERFLOW)
42933         (_GL_INT_MULTIPLY_RANGE_OVERFLOW): New macros.
42934         * tests/test-intprops.c: Check for bugs and test new behavior.
42936 2019-08-14  Bruno Haible  <bruno@clisp.org>
42938         get_progname_of: New module.
42939         * lib/get_progname_of.h: New file.
42940         * lib/get_progname_of.c: New file, based on lib/getprogname.c.
42941         * lib/getprogname.c (getprogname): Tweak coding style.
42942         * lib/vma-iter.c (vma_iterate_bsd): Update comment.
42943         * modules/get_progname_of: New file.
42945 2019-08-14  Bruno Haible  <bruno@clisp.org>
42947         get_ppid_of: New module.
42948         * lib/get_ppid_of.h: New file.
42949         * lib/get_ppid_of.c: New file.
42950         * modules/get_ppid_of: New file.
42952 2019-08-13  Bruno Haible  <bruno@clisp.org>
42954         libtextstyle-optional tests: Support the NO_COLOR environment variable.
42955         * tests/test-libtextstyle.c (main): Do not emit styling when the
42956         environment variable NO_COLOR is set.
42958 2019-08-12  Paul Eggert  <eggert@cs.ucla.edu>
42960         verify: improve diagnostic quality in recent GCC
42961         If ‘verify’ fails in a deeply-nested macro, GCC does not output a
42962         useful line number containing the top-level caller of the macro.
42963         So, bring back the older way of issuing a diagnostic containing
42964         the top-level call’s arg, so that it is easier to diagnose
42965         ‘verify’ failures with recent GCC.
42966         * lib/verify.h (_GL_VERIFY_TRUE, _GL_VERIFY_TYPE):
42967         Bring back DIAGNOSTIC arg.  All callers changed.
42968         (verify): Just use _GL_VERIFY.
42970 2019-08-11  Bruno Haible  <bruno@clisp.org>
42972         localcharset: Add more aliases for OS/2.
42973         Based on patch by KO Myung-Hun <komh78@gmail.com> in
42974         <https://lists.gnu.org/archive/html/bug-gnu-libiconv/2019-08/msg00004.html>.
42975         * lib/localcharset.c (alias_table) [OS2]: Add more aliases.
42977 2019-08-10  Eric Blake  <eblake@redhat.com>
42979         configmake: Update advice on usage.
42980         * modules/configmake (Include): No longer necessary to include
42981         last, since configmake.h itself worries about collision avoidance.
42983 2019-08-10  Assaf Gordon <assafgordon@gmail.com>
42985         parse-datetime: fix 'T' military timezone handling
42986         * lib/parse-datetime.y (zone):
42987         follow-up to the previous commit: the 'T' case is handled outside the
42988         conversion table (used as either military timezone UTC-7 or ISO8601
42989         separator). Change it from "HOUR(7)" to "-HOUR(7)" to match other
42990         timezone letters.
42992 2019-08-09  Paul Eggert  <eggert@cs.ucla.edu>
42994         parse-datetime: fix military timezone letters
42995         Problem and trivial fix reported by Neil Hoggarth in:
42996         https://lists.gnu.org/r/bug-gnulib/2019-08/msg00005.html
42997         * lib/parse-datetime.y (military_table):
42998         Do it the right way, not the RFC 822 way.
43000 2019-08-08  Eric Blake  <eblake@redhat.com>
43002         configmake: Avoid namespace pollution issue on mingw.
43003         * modules/configmake (Makefile.am): If the project uses
43004         <winsock2.h>, include that header before defining DATADIR.
43006 2019-07-28  Bruno Haible  <bruno@clisp.org>
43008         mbrtowc tests: Fix regression on mingw (regression from 2018-02-24).
43009         * tests/test-mbrtowc.c (main): Fix expected value of wc.
43011 2019-07-24  Bruno Haible  <bruno@clisp.org>
43013         pthread-h: Fix definitions of types and macros on mingw.
43014         * lib/pthread.in.h (pthread_t, pthread_attr_t, PTHREAD_CREATE_JOINABLE,
43015         PTHREAD_CREATE_DETACHED): Define also when module 'pthread-thread' is
43016         not in use.
43017         (pthread_once_t, PTHREAD_ONCE_INIT): Define also when module
43018         'pthread-once' is not in use.
43019         (pthread_mutex_t, pthread_mutexattr_t, PTHREAD_MUTEX_INITIALIZER,
43020         PTHREAD_MUTEX_DEFAULT, PTHREAD_MUTEX_NORMAL, PTHREAD_MUTEX_ERRORCHECK,
43021         PTHREAD_MUTEX_RECURSIVE): Define also when module 'pthread-mutex' is not
43022         in use.
43023         (pthread_rwlock_t, pthread_rwlockattr_t, PTHREAD_RWLOCK_INITIALIZER):
43024         Define also when module 'pthread-rwlock' is not in use.
43025         (pthread_cond_t, pthread_condattr_t, PTHREAD_COND_INITIALIZER): Define
43026         also when module 'pthread-cond' is not in use.
43027         (pthread_key_t, PTHREAD_DESTRUCTOR_ITERATIONS): Define also when module
43028         'pthread-tss' is not in use.
43029         (pthread_spinlock_t): Define also when module 'pthread-spin' is not in
43030         use.
43032 2019-07-24  Simon Josefsson  <simon@josefsson.org>
43034         crypto/gc: Cope with libgcrypt without SM3.
43035         * lib/gc-libgcrypt.c (gc_hash_open): Guard SM3 usage.
43037 2019-07-23  Paul Eggert  <eggert@cs.ucla.edu>
43039         backupfile: fix resource leak on memory failure
43040         Problem found by Coverity (CID 1484214).
43041         * lib/backupfile.c (backupfile_internal): Don’t leak dirp.
43043 2019-07-22  Bruno Haible  <bruno@clisp.org>
43045         Avoid missing-declarations warning in various tests.
43046         * tests/test-argp.c (fail, test1, test2, test_file, test3, test4, test5,
43047         test6, test_optional, test7, test8, test9, test10, test11, test12,
43048         test13, test14, test15, test_fun): Declare static.
43049         * tests/test-cnd.c (test_cnd_wait): Likewise.
43050         * tests/test-cond.c (test_cond): Likewise.
43052 2019-07-22  Bernhard Voelker  <mail@bernhard-voelker.de>
43054         pthread tests: Avoid missing-declarations warning.
43055         * tests/test-pthread-cond.c (test_pthread_cond_wait): Declare static.
43057 2019-07-19  Bruno Haible  <bruno@clisp.org>
43059         parse-datetime: Avoid warnings from bison versions >= 3.3.
43060         Reported by Bernhard Voelker <mail@bernhard-voelker.de>.
43061         * modules/parse-datetime (Makefile.am): Don't pass option '-y' to bison.
43063 2019-07-19  Bruno Haible  <bruno@clisp.org>
43065         parse-datetime: Require Bison 2.4 or newer.
43066         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Set PARSE_DATETIME_BISON.
43067         Code taken from gettext's intl.m4.
43068         * modules/parse-datetime (Makefile.am): Use PARSE_DATETIME_BISON instead
43069         of YACC.
43071 2019-07-19  Bruno Haible  <bruno@clisp.org>
43073         areadlink-with-size, xgethostname, xgetdomainname: Fix GCC warning.
43074         * lib/areadlink-with-size.c: Include <string.h>.
43075         * lib/areadlinkat-with-size.c: Likewise.
43076         * lib/xgethostname.c: Likewise.
43077         * lib/xgetdomainname.c: Likewise.
43079 2019-07-19  Bernhard Voelker  <mail@bernhard-voelker.de>
43081         parse-datetime: avoid "%pure-parser" deprecation warning from Bison 3.4
43082         * lib/parse-datetime.y: Use "%define api.pure" rather than obsolescent
43083         "%pure-parser".  The former is available since Bison 2.3b (2008),
43084         while the latter is marked as obsolete since version 3.4 (May 2019).
43086 2019-07-16  Bruno Haible  <bruno@clisp.org>
43088         update-copyright: Make it work again (regression from 2019-06-15).
43089         Reported by Brian C. Lane <bcl@redhat.com>.
43090         * build-aux/update-copyright: Add back the -0777, -p, -i options.
43092 2019-07-14  Bruno Haible  <bruno@clisp.org>
43094         doc: Update info about <pthread.h>.
43095         * doc/posix-headers/pthread.texi: Mention the module 'pthread-h' instead
43096         of 'pthread'.
43098 2019-07-14  Bruno Haible  <bruno@clisp.org>
43100         pthread_sigmask tests: Use new multithread modules.
43101         * tests/test-pthread_sigmask2.c: Include <pthread.h> instead of
43102         glthread/thread.h.
43103         (main_thread, killer_thread): Change type to pthread_t.
43104         (main): Update accordingly.
43105         * modules/pthread_sigmask-tests (Depends-on): Add pthread-thread. Remove
43106         thread.
43108 2019-07-14  Bruno Haible  <bruno@clisp.org>
43110         pthread-tss: Add tests.
43111         * tests/test-pthread-tss.c: New file, based on tests/test-tls.c and
43112         tests/test-tss.c.
43113         * modules/pthread-tss-tests: New file.
43115 2019-07-14  Bruno Haible  <bruno@clisp.org>
43117         pthread-cond: Add tests.
43118         * tests/test-pthread-cond.c: New file, based on tests/test-cond.c and
43119         tests/test-cnd.c.
43120         * modules/pthread-cond-tests: New file.
43122 2019-07-14  Bruno Haible  <bruno@clisp.org>
43124         pthread-rwlock: Add tests.
43125         * tests/test-pthread-rwlock.c: New file, based on tests/test-lock.c.
43126         * modules/pthread-rwlock-tests: New file.
43128 2019-07-14  Bruno Haible  <bruno@clisp.org>
43130         pthread-mutex: Add tests.
43131         * tests/test-pthread-mutex.c: New file, based on tests/test-lock.c and
43132         tests/test-mtx.c.
43133         * modules/pthread-mutex-tests: New file.
43135 2019-07-14  Bruno Haible  <bruno@clisp.org>
43137         pthread-once: Add tests.
43138         * tests/test-pthread-once1.c: New file, based on tests/test-once.c and
43139         tests/test-call_once.c.
43140         * tests/test-pthread-once2.c: New file, based on tests/test-lock.c and
43141         tests/test-mtx.c.
43142         * modules/pthread-once-tests: New file.
43144 2019-07-14  Bruno Haible  <bruno@clisp.org>
43146         pthread-thread: Add tests.
43147         * tests/test-pthread-thread.c: New file, based on
43148         tests/test-thread_create.c and tests/test-thrd_create.c.
43149         * modules/pthread-thread-tests: New file.
43151 2019-07-14  Bruno Haible  <bruno@clisp.org>
43153         pthread: Turn into a convenience module.
43154         * lib/pthread.in.h: Remove declarations for extern inline functions.
43155         * lib/pthread.c: Remove file.
43156         * modules/pthread (Files): Remove it.
43157         (Depends-on): Add pthread-thread, pthread-once, pthread-mutex,
43158         pthread-rwlock, pthread-cond, pthread-tss, pthread-spin.
43159         (configure.ac): Don't compile lib/pthread.c. Don't set GNULIB_PTHREAD.
43160         * m4/pthread_h.m4 (gl_PTHREAD_H_DEFAULTS): Don't initialize
43161         GNULIB_PTHREAD.
43162         * modules/pthread-h (Makefile.am): Don't substitute GNULIB_PTHREAD.
43164 2019-07-14  Bruno Haible  <bruno@clisp.org>
43166         pthread-spin: New module.
43167         * lib/pthread.in.h (pthread_spin_init, pthread_spin_destroy,
43168         pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock): Remove
43169         inline definitions.
43170         * lib/pthread-spin.c: New file.
43171         * m4/pthread-spin.m4: New file.
43172         * modules/pthread-spin: New file.
43173         * doc/posix-functions/pthread_spin_init.texi: Mention the new module.
43174         * doc/posix-functions/pthread_spin_lock.texi: Likewise.
43175         * doc/posix-functions/pthread_spin_trylock.texi: Likewise.
43176         * doc/posix-functions/pthread_spin_unlock.texi: Likewise.
43177         * doc/posix-functions/pthread_spin_destroy.texi: Likewise.
43179 2019-07-14  Bruno Haible  <bruno@clisp.org>
43181         pthread-tss: New module.
43182         * lib/pthread-tss.c: New file.
43183         * m4/pthread-tss.m4: New file.
43184         * modules/pthread-tss: New file.
43185         * doc/posix-functions/pthread_key_create.texi: Mention the new module.
43186         * doc/posix-functions/pthread_setspecific.texi: Likewise.
43187         * doc/posix-functions/pthread_getspecific.texi: Likewise.
43188         * doc/posix-functions/pthread_key_delete.texi: Likewise.
43190 2019-07-14  Bruno Haible  <bruno@clisp.org>
43192         pthread-cond: New module.
43193         * lib/pthread.in.h (pthread_cond_destroy, pthread_cond_init,
43194         pthread_cond_signal, pthread_cond_wait): Remove inline definitions.
43195         * lib/pthread-cond.c: New file.
43196         * m4/pthread-cond.m4: New file.
43197         * modules/pthread-cond: New file.
43198         * doc/posix-functions/pthread_cond_init.texi: Mention the new module.
43199         * doc/posix-functions/pthread_condattr_init.texi: Likewise.
43200         * doc/posix-functions/pthread_condattr_destroy.texi: Likewise.
43201         * doc/posix-functions/pthread_cond_wait.texi: Likewise.
43202         * doc/posix-functions/pthread_cond_timedwait.texi: Likewise.
43203         * doc/posix-functions/pthread_cond_signal.texi: Likewise.
43204         * doc/posix-functions/pthread_cond_broadcast.texi: Likewise.
43205         * doc/posix-functions/pthread_cond_destroy.texi: Likewise.
43207 2019-07-14  Bruno Haible  <bruno@clisp.org>
43209         pthread-rwlock: New module.
43210         * lib/pthread-rwlock.c: New file, based on lib/glthread/lock.c.
43211         * m4/pthread-rwlock.m4: New file.
43212         * modules/pthread-rwlock: New file.
43213         * doc/posix-functions/pthread_rwlock_init.texi: Mention the new module
43214         and the Android problem.
43215         * doc/posix-functions/pthread_rwlockattr_init.texi: Likewise.
43216         * doc/posix-functions/pthread_rwlockattr_destroy.texi: Likewise.
43217         * doc/posix-functions/pthread_rwlock_rdlock.texi: Likewise.
43218         * doc/posix-functions/pthread_rwlock_wrlock.texi: Likewise.
43219         * doc/posix-functions/pthread_rwlock_tryrdlock.texi: Likewise.
43220         * doc/posix-functions/pthread_rwlock_trywrlock.texi: Likewise.
43221         * doc/posix-functions/pthread_rwlock_timedrdlock.texi: Likewise.
43222         * doc/posix-functions/pthread_rwlock_timedwrlock.texi: Likewise.
43223         * doc/posix-functions/pthread_rwlock_unlock.texi: Likewise.
43224         * doc/posix-functions/pthread_rwlock_destroy.texi: Likewise.
43226 2019-07-14  Bruno Haible  <bruno@clisp.org>
43228         pthread-mutex: New module.
43229         * lib/pthread.in.h (pthread_mutexattr_destroy, pthread_mutexattr_init,
43230         pthread_mutexattr_settype, pthread_mutex_destroy, pthread_mutex_init,
43231         pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_timedlock,
43232         pthread_mutex_unlock): Remove inline definitions.
43233         * lib/pthread-mutex.c: New file.
43234         * m4/pthread-mutex.m4: New file.
43235         * modules/pthread-mutex: New file.
43236         * doc/posix-functions/pthread_mutex_init.texi: Mention the new module.
43237         * doc/posix-functions/pthread_mutexattr_init.texi: Likewise.
43238         * doc/posix-functions/pthread_mutexattr_gettype.texi: Likewise.
43239         * doc/posix-functions/pthread_mutexattr_settype.texi: Likewise.
43240         * doc/posix-functions/pthread_mutexattr_getrobust.texi: Likewise.
43241         * doc/posix-functions/pthread_mutexattr_setrobust.texi: Likewise.
43242         * doc/posix-functions/pthread_mutexattr_destroy.texi: Likewise.
43243         * doc/posix-functions/pthread_mutex_lock.texi: Likewise.
43244         * doc/posix-functions/pthread_mutex_trylock.texi: Likewise.
43245         * doc/posix-functions/pthread_mutex_timedlock.texi: Likewise.
43246         * doc/posix-functions/pthread_mutex_unlock.texi: Likewise.
43247         * doc/posix-functions/pthread_mutex_destroy.texi: Likewise.
43249 2019-07-14  Bruno Haible  <bruno@clisp.org>
43251         pthread-once: New module.
43252         * lib/pthread-once.c: New file.
43253         * m4/pthread-once.m4: New file.
43254         * modules/pthread-once: New file.
43255         * doc/posix-functions/pthread_once.texi: Mention the new module.
43257 2019-07-14  Bruno Haible  <bruno@clisp.org>
43259         pthread-thread: New module.
43260         * lib/pthread.in.h (pthread_create, pthread_exit, pthread_join): Remove
43261         inline definitions.
43262         * lib/pthread-thread.c: New file.
43263         * m4/pthread-thread.m4: New file.
43264         * modules/pthread-thread: New file.
43265         * doc/posix-functions/pthread_create.texi: Mention the new module.
43266         * doc/posix-functions/pthread_attr_init.texi: Likewise.
43267         * doc/posix-functions/pthread_attr_getdetachstate.texi: Likewise.
43268         * doc/posix-functions/pthread_attr_setdetachstate.texi: Likewise.
43269         * doc/posix-functions/pthread_attr_destroy.texi: Likewise.
43270         * doc/posix-functions/pthread_self.texi: Likewise.
43271         * doc/posix-functions/pthread_equal.texi: Likewise.
43272         * doc/posix-functions/pthread_detach.texi: Likewise.
43273         * doc/posix-functions/pthread_join.texi: Likewise.
43274         * doc/posix-functions/pthread_exit.texi: Likewise.
43276 2019-07-14  Bruno Haible  <bruno@clisp.org>
43278         pthread-h: Prepare for adding new modules.
43279         * lib/pthread.in.h: Define the types and macros for each of the
43280         facilities separately.
43281         * m4/pthread_h.m4 (gl_PTHREAD_H): Set HAVE_PTHREAD_CREATE_DETACHED,
43282         HAVE_PTHREAD_MUTEX_RECURSIVE, HAVE_PTHREAD_MUTEX_ROBUST,
43283         HAVE_PTHREAD_PROCESS_SHARED.
43284         (gl_PTHREAD_H_DEFAULTS): Initialize HAVE_PTHREAD_CREATE_DETACHED,
43285         HAVE_PTHREAD_MUTEX_RECURSIVE, HAVE_PTHREAD_MUTEX_ROBUST,
43286         HAVE_PTHREAD_PROCESS_SHARED.
43287         * modules/pthread-h (Makefile.am): Substitute
43288         HAVE_PTHREAD_CREATE_DETACHED, HAVE_PTHREAD_MUTEX_RECURSIVE,
43289         HAVE_PTHREAD_MUTEX_ROBUST, HAVE_PTHREAD_PROCESS_SHARED.
43291 2019-07-14  Bruno Haible  <bruno@clisp.org>
43293         pthread-h: Add declarations of essential pthread functions.
43294         * lib/pthread.in.h: Include snippets.
43295         (pthread_create, pthread_attr_init, pthread_attr_getdetachstate,
43296         pthread_attr_setdetachstate, pthread_attr_destroy, pthread_self,
43297         pthread_equal, pthread_detach, pthread_join, pthread_exit, pthread_once,
43298         pthread_mutex_init, pthread_mutexattr_init, pthread_mutexattr_gettype,
43299         pthread_mutexattr_settype, pthread_mutexattr_getrobust,
43300         pthread_mutexattr_setrobust, pthread_mutexattr_destroy,
43301         pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_unlock,
43302         pthread_mutex_destroy, pthread_rwlock_init, pthread_rwlockattr_init,
43303         pthread_rwlockattr_destroy, pthread_rwlock_rdlock,
43304         pthread_rwlock_wrlock, pthread_rwlock_tryrdlock,
43305         pthread_rwlock_trywrlock, pthread_rwlock_timedrdlock,
43306         pthread_rwlock_timedwrlock, pthread_rwlock_unlock,
43307         pthread_rwlock_destroy, pthread_cond_init, pthread_condattr_init,
43308         pthread_condattr_destroy, pthread_cond_wait, pthread_cond_timedwait,
43309         pthread_cond_signal, pthread_cond_broadcast, pthread_cond_destroy,
43310         pthread_key_create, pthread_setspecific, pthread_getspecific,
43311         pthread_key_delete, pthread_spin_init, pthread_spin_lock,
43312         pthread_spin_trylock, pthread_spin_unlock, pthread_spin_destroy): New
43313         declarations.
43314         (pthread_mutex_timedlock): Move declaration.
43315         * m4/pthread_h.m4 (gl_PTHREAD_H): Check whether the new functions are
43316         declared.
43317         (gl_PTHREAD_H_DEFAULTS): Initialize GNULIB_PTHREAD_THREAD,
43318         GNULIB_PTHREAD_ONCE, GNULIB_PTHREAD_MUTEX, GNULIB_PTHREAD_RWLOCK,
43319         GNULIB_PTHREAD_COND, GNULIB_PTHREAD_TSS, GNULIB_PTHREAD_SPIN and the
43320         HAVE_* and REPLACE_* variables for the new functions.
43321         * modules/pthread-h (Depends-on): Add snippet/c++defs,
43322         snippet/_Noreturn, snippet/arg-nonnull, snippet/warn-on-use.
43323         (Makefile.am): Substitute GNULIB_PTHREAD_THREAD, GNULIB_PTHREAD_ONCE,
43324         GNULIB_PTHREAD_MUTEX, GNULIB_PTHREAD_RWLOCK, GNULIB_PTHREAD_COND,
43325         GNULIB_PTHREAD_TSS, GNULIB_PTHREAD_SPIN and the HAVE_* and REPLACE_*
43326         variables for the new functions. Split the sed script, to avoid the
43327         limit of 99 commands of HP-UX sed.
43328         * tests/test-pthread-c++.cc: Check the signature of the new functions.
43330 2019-07-14  Bruno Haible  <bruno@clisp.org>
43332         pthread-h: Respect --enable-threads={posix|windows} option on mingw.
43333         * m4/pthread_h.m4 (gl_PTHREAD_H): Require gl_THREADLIB. Set
43334         HAVE_PTHREAD_H if gl_threads_api is 'windows'.
43335         (LIB_PTHREAD): Rely on $LIBMULTITHREAD from threadlib.m4.
43336         * modules/pthread (Link): Change to $(LIBMULTITHREAD).
43337         * modules/pthread-h (Depends-on): Add threadlib.
43338         (Link): Change to $(LIBTHREAD).
43339         * modules/pthread-h-c++-tests (test_pthread_c___LDADD): Use
43340         $(LIBMULTITHREAD) instead of $(LIB_PTHREAD).
43342 2019-07-14  Bruno Haible  <bruno@clisp.org>
43344         pthread-h: Add C++ tests.
43345         * tests/test-pthread-c++.cc: New file.
43346         * modules/pthread-h-c++-tests: New file.
43348 2019-07-14  Bruno Haible  <bruno@clisp.org>
43350         pthread-h: Add tests.
43351         * tests/test-pthread.c: New file.
43352         * modules/pthread-h-tests: New file.
43354 2019-07-14  Bruno Haible  <bruno@clisp.org>
43356         pthread-h: New module.
43357         * lib/pthread.in.h: Define replacement functions only if GNULIB_PTHREAD
43358         is 1.
43359         * m4/pthread_h.m4: Renamed from m4/pthread.m4.
43360         (gl_PTHREAD_H): Renamed from gl_PTHREAD_CHECK. Don't test whether
43361         <pthread.h> pollutes the namespace; instead, prepare for generating a
43362         pthread.h always. Substitute HAVE_PTHREAD_H here.
43363         (gl_PTHREAD_H_DEFAULTS): Renamed from gl_PTHREAD_DEFAULTS. Initialize
43364         GNULIB_PTHREAD. Don't initialize HAVE_PTHREAD_H here.
43365         * modules/pthread-h: New file, based on modules/pthread.
43366         * modules/pthread: Rely on 'pthread-h'.
43367         * m4/pthread_mutex_timedlock.m4 (gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK):
43368         Update.
43369         * modules/pthread_mutex_timedlock (Depends-on): Add pthread-h. Remove
43370         pthread.
43372 2019-07-14  Bruno Haible  <bruno@clisp.org>
43374         sched_yield: New module.
43375         * lib/sched.in.h: Add _GL_FUNCDECL_RPL, _GL_WARN_ON_USE placeholders.
43376         (sched_yield): New declaration.
43377         * lib/sched_yield.c: New file.
43378         * m4/sched_yield.m4: New file.
43379         * m4/sched_h.m4 (gl_SCHED_H): Require gl_SCHED_H_DEFAULTS. Arrange to
43380         provide a replacement sched.h always. Test whether sched_yield is
43381         declared.
43382         (gl_SCHED_MODULE_INDICATOR, gl_SCHED_H_DEFAULTS): New macros.
43383         * modules/sched (Depends-on): Add snippet/c++defs, snippet/warn-on-use.
43384         (Makefile.am): Provide a replacement sched.h always. Substitute
43385         GNULIB_SCHED_YIELD, HAVE_SCHED_YIELD, REPLACE_SCHED_YIELD,
43386         _GL_FUNCDECL_RPL, _GL_WARN_ON_USE.
43387         * modules/sched_yield: New file.
43388         * doc/posix-functions/sched_yield.texi: Mention the new module.
43390 2019-07-14  Bruno Haible  <bruno@clisp.org>
43392         windows-spin: New module.
43393         * lib/windows-spin.h: New file.
43394         * lib/windows-spin.c: New file.
43395         * modules/windows-spin: New file.
43397 2019-07-14  Bruno Haible  <bruno@clisp.org>
43399         windows-timedrwlock: New module.
43400         * lib/windows-timedrwlock.h: New file, based on windows-rwlock.h.
43401         * lib/windows-timedrwlock.c: New file, based on windows-rwlock.c and
43402         windows-cond.c.
43403         * lib/windows-cond.h (struct glwthread_waitqueue_link): Protect against
43404         redefinition conflict with windows-timedrwlock.h.
43405         * modules/windows-timedrwlock: New file.
43407 2019-07-14  Bruno Haible  <bruno@clisp.org>
43409         windows-rwlock: New module.
43410         * lib/windows-rwlock.h: New file, extracted from lib/glthread/lock.h.
43411         * lib/windows-rwlock.c: New file, extracted from lib/glthread/lock.c.
43412         * lib/glthread/lock.h: Include windows-rwlock.h. Don't include
43413         windows-initguard.h.
43414         (gl_rwlock_t): Define using glwthread_rwlock_t.
43415         (gl_rwlock_initializer): Define using GLWTHREAD_RWLOCK_INIT.
43416         (glthread_rwlock_init): Define using glwthread_rwlock_init.
43417         (glthread_rwlock_rdlock): Define using glwthread_rwlock_rdlock.
43418         (glthread_rwlock_wrlock): Define using glwthread_rwlock_wrlock.
43419         (glthread_rwlock_unlock): Define using glwthread_rwlock_unlock.
43420         (glthread_rwlock_destroy): Define using glwthread_rwlock_destroy.
43421         (glthread_rwlock_init_func, glthread_rwlock_rdlock_func,
43422         glthread_rwlock_wrlock_func, glthread_rwlock_unlock_func,
43423         glthread_rwlock_destroy_func): Remove declarations.
43424         * lib/glthread/lock.c (gl_waitqueue_t): Remove type.
43425         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_notify_first,
43426         gl_waitqueue_notify_all, glthread_rwlock_init_func,
43427         glthread_rwlock_rdlock_func, glthread_rwlock_wrlock_func,
43428         glthread_rwlock_unlock_func, glthread_rwlock_destroy_func): Remove
43429         functions.
43430         * modules/windows-rwlock: New file.
43431         * modules/lock (Depends-on): Add windows-rwlock.
43433 2019-07-14  Bruno Haible  <bruno@clisp.org>
43435         windows-thread: Add support for creating a thread in detached state.
43436         * lib/windows-thread.h (GLWTHREAD_ATTR_DETACHED): New macro.
43437         (glwthread_thread_create): Add attr argument.
43438         * lib/windows-thread.c (glwthread_thread_create): Likewise.
43439         * lib/glthread/thread.h (glthread_create): Update.
43440         * lib/thrd.c (thrd_create): Update.
43442 2019-07-14  Bruno Haible  <bruno@clisp.org>
43444         windows-*: Rename glwthread_spinlock_t to glwthread_initguard_t.
43445         * lib/windows-initguard.h: Renamed from lib/windows-spinlock.h.
43446         (glwthread_initguard_t): Renamed from glwthread_spinlock_t.
43447         (GLWTHREAD_INITGUARD_INIT): Renamed from GLWTHREAD_SPINLOCK_INIT.
43448         * lib/windows-mutex.h: Update.
43449         * lib/windows-recmutex.h: Likewise.
43450         * lib/windows-timedmutex.h: Likewise.
43451         * lib/windows-timedrecmutex.h: Likewise.
43452         * lib/windows-cond.h: Likewise.
43453         * lib/glthread/lock.h: Likewise.
43454         * modules/windows-mutex (Files): Add lib/windows-initguard.h. Remove
43455         lib/windows-spinlock.h.
43456         * modules/windows-recmutex (Files): Likewise.
43457         * modules/windows-timedmutex (Files): Likewise.
43458         * modules/windows-timedrecmutex (Files): Likewise.
43459         * modules/windows-cond (Files): Likewise.
43460         * modules/threads-h (Files): Likewise.
43462 2019-07-14  Bruno Haible  <bruno@clisp.org>
43464         doc: Fix info about pthread API in HP-UX.
43465         * doc/posix-functions/pthread_*.texi: Fix info about HP-UX 11.
43467 2019-07-14  Bruno Haible  <bruno@clisp.org>
43469         threads-h: Fix generation of threads.h.
43470         * modules/threads-h (Makefile.am): Insert the required header file
43471         snippets.
43473 2019-07-09  Bruno Haible  <bruno@clisp.org>
43475         striconveh test: Fix a compilation failure when iconv is not available.
43476         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
43477         * tests/test-striconveh.c (main): Move iconv_close invocations inside
43478         HAVE_ICONV.
43480 2019-07-07  Akim Demaille  <akim@lrde.epita.fr>
43482         argmatch: adjust columns for help2man.
43483         * lib/argmatch.h (argmatch_##Name##_doc_col): If some argument
43484         requires column 20 or more, return 20.
43486 2019-07-06  Paul Eggert  <eggert@cs.ucla.edu>
43488         areadlink-with-size: avoid realloc when size==0
43489         * lib/areadlink-with-size.c (areadlink_with_size):
43490         * lib/areadlinkat-with-size.c (areadlinkat_with_size):
43491         Reallocate at the end to the actual size, to avoid memory waste,
43492         as suggested by Bruno Haible.  But when the guessed size is zero -
43493         useful when the size is unknown - do the initial small readlink
43494         into the stack, to avoid that realloc in the usual case.
43496 2019-07-06  Pádraig Brady  <P@draigBrady.com>
43498         areadlink-with-size: guess a buffer size with 0 size
43499         The size is usually taken from st_size, which can be zero,
43500         resulting in inefficient operation.
43501         Instead let zero select an initial memory allocation
43502         of 128 bytes, which most symlinks fit within.
43503         * lib/areadlink-with-size.c (areadlink_with_size):
43504         Start with a 128 byte buffer, for SIZE == 0.
43505         * lib/areadlinkat-with-size.c (areadlinkat_with_size): Likewise.
43507 2019-07-06  Konstantin Kharlamov  <Hi-Angel@yandex.ru>
43509         Replace manually crafted hex regexes with [:xdigit:]
43510         * build-aux/gitlog-to-changelog (parse_amend_file)
43511         (git_dir_option):
43512         Replace various combinations of [0-9a-fA-F] with [[:xdigit:]].
43513         This patch is backported from Emacs (Bug#36167).
43515 2019-07-06  Bruno Haible  <bruno@clisp.org>
43517         error: Fix documentation.
43518         * doc/glibc-functions/error_at_line.texi: Document what the 'error'
43519         module provides.
43520         * doc/glibc-functions/error_message_count.texi: Likewise.
43521         * doc/glibc-functions/error_one_per_line.texi: Likewise.
43522         * doc/glibc-functions/error_print_progname.texi: Likewise.
43524 2019-07-06  Bruno Haible  <bruno@clisp.org>
43526         doc: Remove documentation of glibc <= 2.1.x as a supported platform.
43527         * doc/gnulib-intro.texi (Target Platforms): Mention that glibc 2.1.x
43528         and older is unsupported.
43529         * doc/**/*.texi: Update.
43531 2019-07-06  Bruno Haible  <bruno@clisp.org>
43533         doc: Remove documentation of Linux libc5 as a supported platform.
43534         * doc/posix-functions/iswalnum.texi: Don't mention workarounds specific
43535         to Linux libc5.
43536         * doc/posix-functions/iswalpha.texi: Likewise.
43537         * doc/posix-functions/iswblank.texi: Likewise.
43538         * doc/posix-functions/iswcntrl.texi: Likewise.
43539         * doc/posix-functions/iswdigit.texi: Likewise.
43540         * doc/posix-functions/iswgraph.texi: Likewise.
43541         * doc/posix-functions/iswlower.texi: Likewise.
43542         * doc/posix-functions/iswprint.texi: Likewise.
43543         * doc/posix-functions/iswpunct.texi: Likewise.
43544         * doc/posix-functions/iswspace.texi: Likewise.
43545         * doc/posix-functions/iswupper.texi: Likewise.
43546         * doc/posix-functions/iswxdigit.texi: Likewise.
43547         * doc/posix-functions/snprintf.texi: Likewise.
43548         * doc/posix-functions/vsnprintf.texi: Likewise.
43550 2019-07-06  Bruno Haible  <bruno@clisp.org>
43552         doc: Remove documentation of Tandem/NSK as a supported platform.
43553         * doc/posix-headers/stdlib.texi: Don't mention workarounds specific to
43554         Tandem/NSK.
43555         * doc/**/*.texi: Update.
43557 2019-07-06  Bruno Haible  <bruno@clisp.org>
43559         doc: Remove documentation of Mac OS X <= 10.4 as a supported platform.
43560         * doc/gnulib-intro.texi (Target Platforms): Mention that Mac OS X 10.4
43561         and older is unsupported.
43562         * doc/posix-functions/acosl.texi: Don't mention workarounds specific to
43563         Mac OS X 10.4 and older.
43564         * doc/posix-functions/asinl.texi: Likewise.
43565         * doc/posix-functions/atanl.texi: Likewise.
43566         * doc/posix-functions/cosl.texi: Likewise.
43567         * doc/posix-functions/expl.texi: Likewise.
43568         * doc/posix-functions/frexpl.texi: Likewise.
43569         * doc/posix-functions/gettimeofday.texi: Likewise.
43570         * doc/posix-functions/logl.texi: Likewise.
43571         * doc/posix-functions/mkstemp.texi: Likewise.
43572         * doc/posix-functions/sinl.texi: Likewise.
43573         * doc/posix-functions/sqrtl.texi: Likewise.
43574         * doc/posix-functions/tanl.texi: Likewise.
43575         * doc/posix-functions/wcswidth.texi: Likewise.
43576         * doc/**/*.texi: Update.
43578 2019-07-06  Bruno Haible  <bruno@clisp.org>
43580         doc: Remove documentation of AIX 4 as a supported platform.
43581         * doc/gnulib-intro.texi (Target Platforms): Mention that AIX 4 is
43582         unsupported.
43583         * doc/posix-functions/nanosleep.texi: Don't mention AIX 4 specific
43584         workarounds.
43585         * doc/posix-functions/strnlen.texi: Likewise.
43586         * doc/posix-headers/inttypes.texi: Likewise.
43587         * doc/**/*.texi: Update.
43589 2019-07-06  Bruno Haible  <bruno@clisp.org>
43591         doc: Remove documentation of HP-UX 10 as a supported platform.
43592         * doc/gnulib-intro.texi (Target Platforms): Mention that HP-UX 10 is
43593         unsupported.
43594         * doc/*-functions/*printf.texi: Don't mention HP-UX 10 specific
43595         workarounds.
43596         * doc/posix-functions/gmtime_r.texi: Likewise.
43597         * doc/posix-functions/localtime_r.texi: Likewise.
43598         * doc/posix-functions/mkstemp.texi: Likewise.
43599         * doc/**/*.texi: Update.
43601 2019-07-06  Bruno Haible  <bruno@clisp.org>
43603         doc: Remove documentation of Interix 3.5 as a supported platform.
43604         * doc/gnulib-intro.texi (Target Platforms): Mention that Interix is
43605         unsupported.
43606         * doc/posix-functions/select.texi: Don't mention Interix specific
43607         workarounds.
43608         * doc/posix-headers/signal.texi: Likewise.
43609         * doc/**/*.texi: Update.
43611 2019-07-06  Bruno Haible  <bruno@clisp.org>
43613         doc: Remove documentation of IRIX 6.4 and older as supported platforms.
43614         * doc/gnulib-intro.texi (Target Platforms): Mention that IRIX <= 6.4 is
43615         unsupported.
43616         * doc/pastposix-functions/usleep.texi: Don't mention IRIX specific
43617         workarounds.
43618         * doc/posix-functions/nl_langinfo.texi: Likewise.
43619         * doc/posix-functions/remainder.texi: Likewise.
43620         * doc/posix-functions/towlower.texi: Likewise.
43621         * doc/posix-functions/towupper.texi: Likewise.
43622         * doc/posix-functions/vsnprintf.texi: Likewise.
43623         * doc/posix-functions/wcscat.texi: Likewise.
43624         * doc/posix-functions/wcschr.texi: Likewise.
43625         * doc/posix-functions/wcscmp.texi: Likewise.
43626         * doc/posix-functions/wcscpy.texi: Likewise.
43627         * doc/posix-functions/wcscspn.texi: Likewise.
43628         * doc/posix-functions/wcslen.texi: Likewise.
43629         * doc/posix-functions/wcsncat.texi: Likewise.
43630         * doc/posix-functions/wcsncmp.texi: Likewise.
43631         * doc/posix-functions/wcsncpy.texi: Likewise.
43632         * doc/posix-functions/wcspbrk.texi: Likewise.
43633         * doc/posix-functions/wcsrchr.texi: Likewise.
43634         * doc/posix-functions/wcsspn.texi: Likewise.
43635         * doc/posix-headers/langinfo.texi: Likewise.
43636         * doc/posix-headers/signal.texi: Likewise.
43637         * doc/posix-headers/wchar.texi: Likewise.
43638         * doc/posix-headers/wctype.texi: Likewise.
43639         * doc/**/*.texi: Update.
43641 2019-07-05  Bruno Haible  <bruno@clisp.org>
43643         doc: Remove documentation of OSF/1 as supported platform.
43644         * doc/gnulib-intro.texi (Target Platforms): Mention that OSF/1 is
43645         unsupported.
43646         * doc/glibc-functions/getdomainname.texi: Don't mention OSF/1 specific
43647         workarounds.
43648         * doc/glibc-functions/pthread_setname_np.texi: Likewise.
43649         * doc/glibc-functions/ptsname_r.texi: Likewise.
43650         * doc/posix-functions/ceil.texi: Likewise.
43651         * doc/posix-functions/ceilf.texi: Likewise.
43652         * doc/posix-functions/ceill.texi: Likewise.
43653         * doc/posix-functions/fchdir.texi: Likewise.
43654         * doc/posix-functions/floor.texi: Likewise.
43655         * doc/posix-functions/floorf.texi: Likewise.
43656         * doc/posix-functions/fmod.texi: Likewise.
43657         * doc/posix-functions/fmodf.texi: Likewise.
43658         * doc/posix-functions/fmodl.texi: Likewise.
43659         * doc/posix-functions/log.texi: Likewise.
43660         * doc/posix-functions/logf.texi: Likewise.
43661         * doc/posix-functions/logl.texi: Likewise.
43662         * doc/posix-functions/log10.texi: Likewise.
43663         * doc/posix-functions/log10f.texi: Likewise.
43664         * doc/posix-functions/log10l.texi: Likewise.
43665         * doc/posix-functions/log2.texi: Likewise.
43666         * doc/posix-functions/log2f.texi: Likewise.
43667         * doc/posix-functions/log2l.texi: Likewise.
43668         * doc/posix-functions/mbrtowc.texi: Likewise.
43669         * doc/posix-functions/recv.texi: Likewise.
43670         * doc/posix-functions/recvfrom.texi: Likewise.
43671         * doc/posix-functions/remainder.texi: Likewise.
43672         * doc/posix-functions/remainderf.texi: Likewise.
43673         * doc/posix-functions/remainderl.texi: Likewise.
43674         * doc/posix-functions/round.texi: Likewise.
43675         * doc/posix-functions/roundf.texi: Likewise.
43676         * doc/posix-functions/roundl.texi: Likewise.
43677         * doc/posix-functions/send.texi: Likewise.
43678         * doc/posix-functions/sendto.texi: Likewise.
43679         * doc/posix-functions/setenv.texi: Likewise.
43680         * doc/posix-functions/snprintf.texi: Likewise.
43681         * doc/posix-functions/tcgetsid.texi: Likewise.
43682         * doc/posix-functions/trunc.texi: Likewise.
43683         * doc/posix-functions/truncf.texi: Likewise.
43684         * doc/posix-functions/truncl.texi: Likewise.
43685         * doc/posix-functions/ttyname_r.texi: Likewise.
43686         * doc/posix-functions/unsetenv.texi: Likewise.
43687         * doc/posix-functions/wcsrtombs.texi: Likewise.
43688         * doc/posix-headers/sys_select.texi: Likewise.
43689         * doc/posix-headers/wchar.texi: Likewise.
43690         * doc/posix-headers/wctype.texi: Likewise.
43691         * doc/**/*.texi: Update.
43693 2019-07-05  Bruno Haible  <bruno@clisp.org>
43695         doc: Remove documentation of BSDI and BSD/OS as supported platforms.
43696         * doc/**/*.texi: Update.
43698 2019-07-05  Bruno Haible  <bruno@clisp.org>
43700         doc: Remove documentation of Solaris 8 and older as supported platforms.
43701         * doc/gnulib-intro.texi (Target Platforms): Mention that Solaris <= 8 is
43702         unsupported.
43703         * doc/posix-functions/mbrtowc.texi: Don't mention Solaris specific
43704         workarounds.
43705         * doc/posix-functions/memcmp.texi: Likewise.
43706         * doc/posix-functions/rename.texi: Likewise.
43707         * doc/posix-functions/tzset.texi: Likewise.
43708         * doc/posix-headers/wctype.texi: Likewise.
43709         * doc/**/*.texi: Update.
43711 2019-07-05  Bruno Haible  <bruno@clisp.org>
43713         doc: Remove documentation of Interix 3.5 as a supported platform.
43714         * doc/**/*.texi: Update.
43716 2019-07-05  Bruno Haible  <bruno@clisp.org>
43718         doc: Remove documentation of BeOS as a supported platform.
43719         * doc/gnulib-intro.texi (Target Platforms): Mention that BeOS is
43720         unsupported.
43721         * doc/*-functions/*printf.texi: Don't mention BeOS specific workarounds.
43722         * doc/posix-functions/getdelim.texi: Likewise.
43723         * doc/**/*.texi: Update.
43725 2019-07-05  Bruno Haible  <bruno@clisp.org>
43727         thread, lock, cond, tls: Remove support for Pth threads.
43728         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Don't document
43729         --enable-threads=pth any more.
43730         (gl_THREADLIB_BODY): Don't set USE_PTH_THREADS any more.
43731         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Update comment.
43732         * m4/threads.m4 (gl_THREADS_H): Remove test for conflict between Pth
43733         threads and ISO C11 threads.
43734         * lib/glthread/thread.h: Remove code for USE_PTH_THREADS.
43735         * lib/glthread/lock.h: Likewise.
43736         * lib/glthread/lock.c: Likewise.
43737         * lib/glthread/cond.h: Likewise.
43738         * lib/glthread/cond.c: Likewise.
43739         * lib/glthread/tls.h: Likewise.
43740         * lib/glthread/tls.c: Likewise.
43741         * lib/glthread/yield.h: Likewise.
43742         * lib/regex_internal.h: Likewise.
43743         * tests/test-thread_create.c: Likewise.
43744         * tests/test-lock.c: Likewise.
43745         * tests/test-cond.c: Likewise.
43746         * tests/test-tls.c: Likewise.
43747         * tests/test-rwlock1.c: Don't include glthread/yield.h.
43748         (main): Sleep without calling gl_thread_yield.
43750 2019-07-05  Bruno Haible  <bruno@clisp.org>
43752         thread, lock, cond, tls: Remove support for old Solaris threads.
43753         Solaris >= 2.5.1 has POSIX threads.
43754         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Don't document
43755         --enable-threads=solaris any more.
43756         (gl_THREADLIB_BODY): Don't set USE_SOLARIS_THREADS any more.
43757         * lib/glthread/thread.c: Update comment.
43758         * lib/glthread/thread.h: Remove code for USE_SOLARIS_THREADS.
43759         * lib/glthread/lock.h: Likewise.
43760         * lib/glthread/lock.c: Likewise.
43761         * lib/glthread/cond.h: Likewise.
43762         * lib/glthread/cond.c: Likewise.
43763         * lib/glthread/tls.h: Likewise.
43764         * lib/glthread/tls.c: Likewise.
43765         * lib/glthread/yield.h: Likewise.
43766         * lib/regex_internal.h: Likewise.
43767         * tests/test-thread_create.c: Likewise.
43768         * tests/test-lock.c: Likewise.
43769         * tests/test-cond.c: Likewise.
43770         * tests/test-tls.c: Likewise.
43772 2019-07-05  Bruno Haible  <bruno@clisp.org>
43774         getcwd-lgpl, getcwd: Don't call realloc when it is pointless.
43775         * lib/getcwd-lgpl.c (rpl_getcwd): Don't call realloc if the result's
43776         needed size is equal to the allocated size.
43777         * lib/getcwd.c (__getcwd): Likewise.
43779 2019-07-05  Bruno Haible  <bruno@clisp.org>
43781         xgetdomainname: Don't return an excessive memory allocation.
43782         * lib/xgetdomainname.c (xgetdomainname): Shrink the domainname buffer
43783         before returning it.
43785 2019-07-05  Bruno Haible  <bruno@clisp.org>
43787         xgethostname: Don't return an excessive memory allocation.
43788         * lib/xgethostname.c (xgethostname): Shrink the hostname buffer before
43789         returning it.
43791 2019-07-05  Bruno Haible  <bruno@clisp.org>
43793         areadlinkat-with-size: Don't return an excessive memory allocation.
43794         * lib/areadlinkat-with-size.c (areadlinkat_with_size): Shrink the buffer
43795         before returning it.
43797 2019-07-05  Bruno Haible  <bruno@clisp.org>
43799         areadlink-with-size: Don't return an excessive memory allocation.
43800         Reported by Andreas Dilger <adilger@whamcloud.com>.
43801         * lib/areadlink-with-size.c (areadlink_with_size): Shrink the buffer
43802         before returning it.
43804 2019-07-03  Bruno Haible  <bruno@clisp.org>
43806         renameatu: Fix test failure on MSVC.
43807         * lib/at-func2.c (at_func2): Fail with ENOENT if file1 or file2 is the
43808         empty string.
43810 2019-07-03  Bruno Haible  <bruno@clisp.org>
43812         mbrtowc: Fix invalid use of mbtowc() on MSVC.
43813         * lib/mbrtowc.c: Include glthread/lock.h.
43814         (mbtowc_lock): New variable.
43815         (mbrtowc): Treat UTF-8 encoding without locking. For the other
43816         encodings, explicitly reset the internal state of mbtowc, and protect
43817         this through a lock.
43818         * modules/mbrtowc (Depends-on): Add lock.
43820 2019-07-03  Akim Demaille  <akim@lrde.epita.fr>
43822         argmatch: don't define _ in the header.
43823         Reported by Jim Meyering.
43824         * lib/argmatch.h (N_, _): Don't define.
43825         Use gettext instead.
43826         * lib/argmatch.h (_): Define.
43827         * tests/test-argmatch.c (N_): Define.
43829 2019-07-02  Paul Eggert  <eggert@cs.ucla.edu>
43831         verify: document ‘assume’ better
43832         * lib/verify.h: Reword doc (Bug#36370).
43834 2019-07-02  Bruno Haible  <bruno@clisp.org>
43836         localcharset, nl_langinfo: Fix return value for UTF-8 locales on MSVC.
43837         * lib/localcharset.c (locale_charset): Return "UTF-8" instead of
43838         "CPutf8".
43839         * lib/nl_langinfo.c (ctype_codeset): Likewise.
43841 2019-07-02  Bruno Haible  <bruno@clisp.org>
43843         getcwd: Fix crash when invoked with size = 0 on MSVC.
43844         * lib/getcwd.c: Include msvc-inval.h.
43845         (getcwd_nothrow): New function/macro.
43846         (getcwd_system): New macro.
43847         (__getcwd): Use it instead of getcwd.
43848         * modules/getcwd (Depends-on): Add msvc-inval.
43849         * doc/posix-functions/getcwd.texi: Mention the MSVC issue.
43851 2019-07-02  Bruno Haible  <bruno@clisp.org>
43853         nonblocking-pipe tests: Fix test failure on MSVC.
43854         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE): Set to 10000 on
43855         native Windows.
43857 2019-07-02  Bruno Haible  <bruno@clisp.org>
43859         usleep: Implement with millisecond resolution on native Windows.
43860         * lib/usleep.c (usleep): On native Windows, implement using Sleep().
43861         * doc/pastposix-functions/usleep.texi: Update accordingly.
43863 2019-07-02  Bruno Haible  <bruno@clisp.org>
43865         lstat tests: Fix test failure on MSVC.
43866         * tests/test-lstat.h (test_lstat_func): Don't test SAME_INODE values on
43867         native Windows, unless _GL_WINDOWS_STAT_INODES is defined.
43869 2019-07-02  Bruno Haible  <bruno@clisp.org>
43871         stat tests: Fix test failure on MSVC.
43872         * tests/test-stat.h (test_stat_func): Don't test SAME_INODE values on
43873         native Windows, unless _GL_WINDOWS_STAT_INODES is defined.
43875 2019-07-02  Bruno Haible  <bruno@clisp.org>
43877         getaddrinfo tests: Fix test failure on MSVC.
43878         * tests/test-getaddrinfo.c: Include sockets.h.
43879         (main): Invoke gl_sockets_startup.
43880         * modules/getaddrinfo-tests (Depends-on): Add sockets.
43882 2019-07-01  Hannes Müller  <h.c.f.mueller@gmx.de>
43884         poll: Fix type of timeout pointer passed to select() on mingw x86_64.
43885         * lib/poll.c: Call Windows native select() with Windows native timeval.
43887 2019-06-30  Bruno Haible  <bruno@clisp.org>
43889         argmatch: Fix compilation errors.
43890         * lib/argmatch.h: Include <limits.h>, for INT_MAX.
43891         * tests/test-argmatch.c (main): Update after last-minute function names
43892         change.
43894 2019-06-30  Bruno Haible  <bruno@clisp.org>
43896         Include <stdlib.h> when needed.
43897         * lib/cnd.c: Include <stdlib.h>, needed for abort().
43898         * lib/fcntl.c: Likewise.
43899         * lib/mbscasestr.c: Likewise.
43900         * lib/mbssep.c: Likewise.
43901         * lib/mbsstr.c: Likewise.
43902         * lib/openat.c: Include <stdlib.h>, needed for free().
43903         * lib/windows-tls.c: Include <stdlib.h>, needed for malloc(), free(),
43904         abort().
43906 2019-06-30  Bruno Haible  <bruno@clisp.org>
43908         Include <stdlib.h> when needed.
43909         * lib/areadlinkat.c: Include <stdlib.h>, needed for free() in at-func.c.
43910         * lib/faccessat.c: Likewise.
43911         * lib/fchmodat.c: Likewise.
43912         * lib/fchownat.c: Likewise.
43913         * lib/fstatat.c: Likewise.
43914         * lib/mkfifoat.c: Likewise.
43915         * lib/mknodat.c: Likewise.
43916         * lib/readlinkat.c: Likewise.
43917         * lib/symlinkat.c: Likewise.
43918         * lib/utimensat.c: Likewise.
43919         * lib/mkdirat.c: Likewise. Include also the specification header.
43921 2019-06-30  Bruno Haible  <bruno@clisp.org>
43923         inet_ntop, inet_pton: Avoid conflict with native Windows functions.
43924         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WS2TCPIP): New macro, extracted
43925         from gl_PREREQ_SYS_H_SOCKET.
43926         (gl_PREREQ_SYS_H_SOCKET): Invoke it.
43927         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Invoke
43928         gl_PREREQ_SYS_H_WS2TCPIP.
43929         * modules/arpa_inet (Files): Add m4/sys_socket_h.m4, m4/socklen.m4.
43930         (Makefile.am): Substitute HAVE_WS2TCPIP_H.
43931         * lib/arpa_inet.in.h: Include <ws2tcpip.h>.
43933 2019-06-30  Bruno Haible  <bruno@clisp.org>
43935         inet_ntop, inet_pton: Forward-compatibility with newer Windows versions.
43936         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): On native Windows, set
43937         REPLACE_INET_NTOP to 1 always.
43938         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): On native Windows, set
43939         REPLACE_INET_PTON to 1 always.
43941 2019-06-30  Bruno Haible  <bruno@clisp.org>
43943         inet_pton: Fix link error on mingw with _WIN32_WINNT >= 0x0600.
43944         * modules/inet_pton (Depends-on, configure.ac): Test REPLACE_INET_PTON,
43945         not REPLACE_INET_NTOP.
43947 2019-06-30  Bruno Haible  <bruno@clisp.org>
43949         poll: Add comment.
43950         * lib/poll.c: Add comment about WSAPoll.
43952 2019-06-30  Bruno Haible  <bruno@clisp.org>
43954         poll-h: Fix compilation error on mingw with _WIN32_WINNT >= 0x0600.
43955         Reported by Hannes Müller <h.c.f.mueller@gmx.de>.
43956         * lib/poll.in.h: Include <winsock2.h>.
43957         (POLL*, pollfd): Override on native Windows.
43958         * m4/poll_h.m4 (gl_POLL_H): Invoke gl_PREREQ_SYS_H_WINSOCK2.
43959         * modules/poll-h (Files): Add m4/sys_socket_h.m4.
43960         (Makefile.am): Substitute HAVE_WINSOCK2_H.
43962 2019-06-28  Bruno Haible  <bruno@clisp.org>
43964         accept4: Fix compilation error on OpenIndiana.
43965         Reported by Michal Nowak <mnowak@startmail.com>
43966         via Mark H Weaver <mhw@netris.org>.
43967         * m4/accept.m4 (gl_FUNC_ACCEPT4): Test whether accept4 is declared, not
43968         whether it exists as a function.
43970 2019-06-26  Paul Eggert  <eggert@cs.ucla.edu>
43972         strverscmp: sync from glibc
43973         * lib/strverscmp.c: Sync from glibc, except use UTF-8 encoding in
43974         comments, include libc-config.h, define __strverscmp to be
43975         strverscmp, and don’t assume types line uint8_t and int8_t that
43976         that C99 doesn’t guarantee.
43977         [!_LIBC]: Include libc-config.h; define __strverscmp.
43978         Include stdint.h.
43979         (__strverscmp): Assume C99.  Use uint_least8_t
43980         and int_least8_t instead of unsigned char and signed char.
43981         * modules/strverscmp (Depends-on): Add libc-config, stdint.
43983 2019-06-25  Bruno Haible  <bruno@clisp.org>
43985         tss tests: Add tests for destructors and races.
43986         * tests/test-tss.c (worker_thread): Fix typo in debug message.
43987         (test_tss_dtorcheck1, test_tss_dtorcheck2, test_tss_racecheck): New
43988         functions.
43989         (main): Invoke them.
43990         * modules/tls-tests (Depends-on): Add mtx.
43992 2019-06-25  Bruno Haible  <bruno@clisp.org>
43994         tls tests: Add tests for destructors and races.
43995         * tests/test-tls.c: Include glthread/lock.h.
43996         (test_tls_dtorcheck1, test_tls_dtorcheck2, test_tls_racecheck): New
43997         functions.
43998         (main): Invoke them.
43999         * modules/tls-tests (Depends-on): Add lock.
44001 2019-06-25  Bruno Haible  <bruno@clisp.org>
44003         windows-tls: Implement TLS key destructors for native Windows.
44004         * lib/windows-tls.h (glwthread_tls_process_destructors): New
44005         declaration.
44006         (GLWTHREAD_DESTRUCTOR_ITERATIONS): New macro.
44007         * lib/windows-tls.c: Include <limits.h>, windows-once.h.
44008         (dtor_table_init_once, dtor_table_lock: New variables.
44009         (struct dtor): New type.
44010         (dtor_table, dtors_count, dtors_used, dtors_allocated,
44011         dtor_processing_threads): New variables.
44012         (dtor_table_initialize, dtor_table_ensure_initialized,
44013         dtor_table_shrink_used, glwthread_tls_process_destructors): New
44014         functions.
44015         (glwthread_tls_key_create, glwthread_tls_key_delete): Rewritten to
44016         handle non-NULL destructors.
44017         * modules/windows-tls (Depends-on): Add windows-once.
44018         * lib/glthread/tls.h (glthread_tls_key_init, glthread_tls_key_destroy):
44019         Use the functions declared in windows-tls.h.
44020         * lib/threads.in.h (TSS_DTOR_ITERATIONS): Define using
44021         GLWTHREAD_DESTRUCTOR_ITERATIONS.
44022         * lib/windows-thread.c: Include windows-tls.h.
44023         (wrapper_func, glwthread_thread_exit): Invoke
44024         glwthread_tls_process_destructors.
44025         * modules/windows-thread (Depends-on): Add windows-tls.
44027 2019-06-25  Bruno Haible  <bruno@clisp.org>
44029         threadlib: Avoid autoconf warning "was expanded before it was required".
44030         * modules/threadlib (configure.ac): Require gl_THREADLIB.
44032 2019-06-25  Akim Demaille  <akim@lrde.epita.fr>
44034         argmatch: remove duplicate const qualifier
44035         * lib/argmatch.h (ARGMATCH_DEFINE_GROUP): Here.
44037 2019-06-24  Paul Eggert  <eggert@cs.ucla.edu>
44039         unistd: stddef.h and sys/types.h namespace cleanup
44040         * lib/unistd.in.h [__GLIBC__]:
44041         Do not include stddef.h or sys/types.h.
44042         [!__GLIBC__]: Always include sys/types.h, since unistd.h is
44043         supposed to declare off_t and ssize_t.  Problem found when looking
44044         at why @GNULIB_PWRITE@ was different from the newly-added
44045         @GNULIB_COPY_FILE_RANGE@ with respect to ssize_t.
44047 2019-06-22  Akim Demaille  <akim@lrde.epita.fr>
44049         maintainer-makefile: restore portability to non-GNU awks
44050         Reported by Tim Rühsen.
44051         * top/maint.mk (AWK): New variable.  Use it.
44052         (sc_prohibit_gnu_make_extensions): Skip if $(AWK) is not gawk.
44054 2019-06-23  Paul Eggert  <eggert@cs.ucla.edu>
44056         Document setvbuf _IOLBF problem
44057         * doc/posix-functions/setvbuf.texi (setvbuf):
44058         Document MS-Windows portability problem with _IOLBF.
44060         Document lseek SEEK_DATA/SEEK_HOLE
44061         * doc/posix-functions/lseek.texi (lseek):
44062         Document some systems that do not support SEEK_DATA and SEEK_HOLE.
44064 2019-06-22  Akim Demaille  <akim@lrde.epita.fr>
44066         argmatch: put all the docs member last.
44067         Reported by Bruno Haible.
44068         * lib/argmatch.h (argmatch_##Name##_group_type): Put the args
44069         member before the docs done.
44070         * doc/argmatch.texi, tests/test-argmatch.c: Adjust.
44072 2019-06-21  Akim Demaille  <akim@lrde.epita.fr>
44074         argmatch: add support to generate the usage message.
44075         * lib/argmatch.c: Move some #includes and gettext support to...
44076         * lib/argmatch.h: here.
44077         (ARGMATCH_DEFINE_GROUP): New macro.
44078         * tests/test-argmatch.c (argmatch_backup_docs, argmatch_backup_args)
44079         (argmatch_backup_group): New.
44080         (CHECK): New.
44081         (main): Check argmatch_backup_value, argmatch_backup_xvalue,
44082         argmatch_backup_argument and argmatch_backup_usage.
44083         * modules/argmatch: We depend on c99.
44084         * doc/argmatch.texi (Recognizing Option Arguments): New.
44085         * doc/gnulib.texi: Use it.
44087 2019-06-21  Bruno Haible  <bruno@clisp.org>
44089         thrd: Add comment.
44090         * lib/thrd.c (pthread_main_func): Add comment.
44092 2019-06-21  Bruno Haible  <bruno@clisp.org>
44094         threads-h: Define 'thread_local' if and only if it actually works.
44095         * m4/threads.m4 (gl_THREAD_LOCAL_DEFINITION): New macro.
44096         (gl_THREADS_H): Define _Thread_local to __thread also for ARM C, IBM C,
44097         Oracle Solaris Studio C. Compile a simple program, to see whether
44098         _Thread_local basically works. Set HAVE_THREAD_LOCAL and LIBTHREADLOCAL.
44099         (gl_THREADS_H_DEFAULTS): Initialize HAVE_THREAD_LOCAL.
44100         * lib/threads.in.h (thread_local): Undefine if it does not work.
44101         * modules/threads-h (Makefile.am): Substitute HAVE_THREAD_LOCAL.
44102         (Link): Mention LIBTHREADLOCAL.
44103         * tests/test-threads.c: Don't check that thread_local is defined.
44104         * tests/test-thread_local.c: New file.
44105         * modules/threads-h-tests (Files): Add it and macros.h.
44106         (Depends-on): Add thrd and stdint.
44107         (configure.ac): Test whether 'alarm' is declared.
44108         (Makefile.am): Arrange to build and link test-thread_local.
44109         * doc/posix-headers/threads.texi: Mention the platforms that don't
44110         support 'thread_local'.
44112 2019-06-20  Bruno Haible  <bruno@clisp.org>
44114         threads-h: Simplify link dependencies.
44115         * m4/threads.m4 (gl_THREADS_H): Bail out if Pth threading is requested.
44116         Don't set LTLIBSTDTHREAD.
44117         * modules/thrd (Link): Simplify accordingly.
44118         * modules/mtx (Link): Likewise.
44119         * modules/cnd (Link): Likewise.
44120         * modules/tss (Link): Likewise.
44121         * modules/threads (Link): Likewise.
44123 2019-06-20  Bruno Haible  <bruno@clisp.org>
44125         threads-h: Fix link error on FreeBSD 11.
44126         * m4/threads.m4 (gl_THREADS_H): When linking with -lstdthreads, link
44127         also with -lpthread.
44129 2019-06-20  Bruno Haible  <bruno@clisp.org>
44131         threadlib: Fix typo (regression from today).
44132         * m4/threadlib.m4 (gl_THREADLIB_BODY): Fix typo in comment marker.
44134 2019-06-20  Bruno Haible  <bruno@clisp.org>
44136         windows-thread, windows-tls: Fix compilation error on 32-bit mingw.
44137         * lib/windows-thread.c: Include <errno.h>.
44138         * lib/windows-tls.c: Likewise.
44140 2019-06-20  Bruno Haible  <bruno@clisp.org>
44142         tss tests: Small improvement.
44143         * tests/test-tss.c (test_tss): Pass a different id to each thread.
44145 2019-06-20  Bruno Haible  <bruno@clisp.org>
44147         threads: New module.
44148         * modules/threads: New file.
44150 2019-06-20  Bruno Haible  <bruno@clisp.org>
44152         tss: Add tests.
44153         * tests/test-tss.c: New file, based on tests/test-tls.c.
44154         * modules/tss-tests: New file.
44156 2019-06-20  Bruno Haible  <bruno@clisp.org>
44158         cnd: Add tests.
44159         * tests/test-cnd.c: New file, based on tests/test-cond.c.
44160         * modules/cnd-tests: New file.
44162 2019-06-20  Bruno Haible  <bruno@clisp.org>
44164         mtx: Add tests.
44165         * tests/test-mtx.c: New file, based on tests/test-lock.c.
44166         * tests/test-call_once.c: New file, based on tests/test-once.c.
44167         * modules/mtx-tests: New file.
44169 2019-06-20  Bruno Haible  <bruno@clisp.org>
44171         thrd: Add tests.
44172         * tests/test-thrd_create.c: New file, based on
44173         tests/test-thread_create.c.
44174         * tests/test-thrd_current.c: New file, based on
44175         tests/test-thread_self.c.
44176         * modules/thrd-tests: New file.
44178 2019-06-20  Bruno Haible  <bruno@clisp.org>
44180         tss: New module.
44181         * lib/tss.c: New file.
44182         * modules/tss: New file.
44183         * doc/posix-functions/tss_create.texi: Mention the new module.
44184         * doc/posix-functions/tss_set.texi: Likewise.
44185         * doc/posix-functions/tss_get.texi: Likewise.
44186         * doc/posix-functions/tss_delete.texi: Likewise.
44188 2019-06-20  Bruno Haible  <bruno@clisp.org>
44190         cnd: New module.
44191         * lib/cnd.c: New file.
44192         * modules/cnd: New file.
44193         * doc/posix-functions/cnd_init.texi: Mention the new module.
44194         * doc/posix-functions/cnd_wait.texi: Likewise.
44195         * doc/posix-functions/cnd_timedwait.texi: Likewise.
44196         * doc/posix-functions/cnd_signal.texi: Likewise.
44197         * doc/posix-functions/cnd_broadcast.texi: Likewise.
44198         * doc/posix-functions/cnd_destroy.texi: Likewise.
44200 2019-06-20  Bruno Haible  <bruno@clisp.org>
44202         mtx: New module.
44203         * lib/mtx.c: New file.
44204         * modules/mtx: New file.
44205         * doc/posix-functions/call_once.texi: Mention the new module.
44206         * doc/posix-functions/mtx_init.texi: Likewise.
44207         * doc/posix-functions/mtx_lock.texi: Likewise.
44208         * doc/posix-functions/mtx_trylock.texi: Likewise.
44209         * doc/posix-functions/mtx_timedlock.texi: Likewise.
44210         * doc/posix-functions/mtx_unlock.texi: Likewise.
44211         * doc/posix-functions/mtx_destroy.texi: Likewise.
44213 2019-06-20  Bruno Haible  <bruno@clisp.org>
44215         thrd: New module.
44216         * lib/thrd.c: New file.
44217         * m4/thrd.m4: New file.
44218         * modules/thrd: New file.
44219         * doc/posix-functions/thrd_current.texi: Mention the new module.
44220         * doc/posix-functions/thrd_detach.texi: Likewise.
44221         * doc/posix-functions/thrd_equal.texi: Likewise.
44222         * doc/posix-functions/thrd_exit.texi: Likewise.
44223         * doc/posix-functions/thrd_sleep.texi: Likewise.
44224         * doc/posix-functions/thrd_yield.texi: Likewise.
44225         * doc/posix-functions/thrd_create.texi: Mention the new module and the
44226         AIX bug.
44227         * doc/posix-functions/thrd_join.texi: Mention the new module and the
44228         AIX and Solaris bugs.
44230 2019-06-20  Bruno Haible  <bruno@clisp.org>
44232         threads-h: Add tests.
44233         * tests/test-threads.c: New file.
44234         * modules/threads-h-tests: New file.
44235         * tests/test-threads-c++.cc: New file.
44236         * modules/threads-h-c++-tests: New file.
44238 2019-06-20  Bruno Haible  <bruno@clisp.org>
44240         threads-h: New module.
44241         * lib/threads.in.h: New file.
44242         * m4/threads.m4: New file.
44243         * m4/yield.m4 (gl_YIELD): Update comment.
44244         * modules/threads-h: New file.
44245         * modules/yields (configure.ac): Use AC_REQUIRE.
44246         * doc/posix-headers/threads.texi: Mention the new module and the AIX
44247         bugs.
44249 2019-06-20  Bruno Haible  <bruno@clisp.org>
44251         windows-thread: New module.
44252         * lib/windows-thread.h: New file, based on lib/glthread/thread.h.
44253         * lib/windows-thread.c: New file, based on lib/glthread/thread.c.
44254         * lib/glthread/thread.h: Include windows-thread.h.
44255         (gl_thread_t): Define using glwthread_thread_t.
44256         (glthread_create): Define using glwthread_thread_create.
44257         (glthread_join): Define using glwthread_thread_join.
44258         (gl_thread_self): Define using glwthread_thread_self.
44259         (gl_thread_exit): Define using glwthread_thread_exit.
44260         (glthread_create_func, glthread_join_func, gl_thread_self_func,
44261         gl_thread_exit_func): Remove declarations.
44262         * lib/glthread/thread.c (self_key): Remove variable.
44263         (do_init_self_key, init_self_key): Remove functions.
44264         (struct gl_thread_struct): Remove type.
44265         (get_current_thread_handle, gl_thread_self_func, wrapper_func,
44266         glthread_create_func, glthread_join_func, gl_thread_exit_func): Remove
44267         functions.
44268         * modules/windows-thread: New file.
44269         * modules/thread (Depends-on): Add windows-thread.
44271 2019-06-20  Bruno Haible  <bruno@clisp.org>
44273         windows-tls: New module.
44274         * lib/windows-tls.h: New file, based on lib/glthread/tls.h.
44275         * lib/windows-tls.c: New file, based on lib/glthread/tls.h.
44276         * lib/glthread/tls.h: Include windows-tls.h.
44277         (gl_tls_key_t): Define using glwthread_tls_key_t.
44278         * modules/windows-tls: New file.
44279         * modules/tls (Depends-on): Add windows-tls.
44281 2019-06-20  Bruno Haible  <bruno@clisp.org>
44283         windows-cond: New module.
44284         * lib/windows-cond.h: New file, based on lib/glthread/cond.h.
44285         * lib/windows-cond.c: New file, based on lib/glthread/cond.c.
44286         * lib/glthread/cond.h: Include windows-cond.h.
44287         (struct gl_waitqueue_link, gl_linked_waitqueue_t): Remove types.
44288         (gl_cond_t): Define using glwthread_cond_t.
44289         (gl_cond_initializer): Define using GLWTHREAD_COND_INIT.
44290         (glthread_cond_init): Define using glwthread_cond_init.
44291         (glthread_cond_wait): Define using glwthread_cond_wait.
44292         (glthread_cond_timedwait): Define using glwthread_cond_timedwait.
44293         (glthread_cond_signal): Define using glwthread_cond_signal.
44294         (glthread_cond_broadcast): Define using glwthread_cond_broadcast.
44295         (glthread_cond_destroy): Define using glwthread_cond_destroy.
44296         (glthread_cond_init_func, glthread_cond_wait_func,
44297         glthread_cond_timedwait_func, glthread_cond_signal_func,
44298         glthread_cond_broadcast_func, glthread_cond_destroy_func): Remove
44299         declarations.
44300         * lib/glthread/cond.c (gl_waitqueue_t, gl_waitqueue_element): Remove
44301         types.
44302         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_remove,
44303         gl_waitqueue_notify_first, gl_waitqueue_notify_all,
44304         glthread_cond_init_func, glthread_cond_wait_func,
44305         glthread_cond_timedwait_func, glthread_cond_signal_func,
44306         glthread_cond_broadcast_func, glthread_cond_destroy_func): Remove
44307         functions.
44308         * modules/windows-cond: New file.
44309         * modules/cond (Depends-on): Add windows-cond. Remove gettimeofday.
44311 2019-06-20  Bruno Haible  <bruno@clisp.org>
44313         windows-timedrecmutex: New module.
44314         * lib/windows-timedrecmutex.h: New file, based on windows-recmutex.h.
44315         * lib/windows-timedrecmutex.c: New file, based on windows-recmutex.c.
44316         * modules/windows-timedrecmutex: New file.
44318 2019-06-20  Bruno Haible  <bruno@clisp.org>
44320         windows-timedmutex: New module.
44321         * lib/windows-timedmutex.h: New file, based on windows-mutex.h.
44322         * lib/windows-timedmutex.c: New file, based on windows-mutex.c.
44323         * modules/windows-timedmutex: New file.
44325 2019-06-20  Bruno Haible  <bruno@clisp.org>
44327         windows-recmutex: New module.
44328         * lib/windows-recmutex.h: New file, extracted from lib/glthread/lock.h.
44329         * lib/windows-recmutex.c: New file, extracted from lib/glthread/lock.c.
44330         * lib/glthread/lock.h: Include windows-recmutex.h.
44331         (gl_recursive_lock_t): Define using glwthread_recmutex_t.
44332         (gl_recursive_lock_initializer): Define using GLWTHREAD_RECMUTEX_INIT.
44333         (glthread_recursive_lock_init): Define using glwthread_recmutex_init.
44334         (glthread_recursive_lock_lock): Define using glwthread_recmutex_lock.
44335         (glthread_recursive_lock_unlock): Define using
44336         glwthread_recmutex_unlock.
44337         (glthread_recursive_lock_destroy): Define using
44338         glwthread_recmutex_destroy.
44339         (glthread_recursive_lock_init_func, glthread_recursive_lock_lock_func,
44340         glthread_recursive_lock_unlock_func,
44341         glthread_recursive_lock_destroy_func): Remove declarations.
44342         * lib/glthread/lock.c (glthread_recursive_lock_init_func,
44343         glthread_recursive_lock_lock_func, glthread_recursive_lock_unlock_func,
44344         glthread_recursive_lock_destroy_func): Remove functions.
44345         * modules/windows-recmutex: New file.
44346         * modules/lock (Depends-on): Add windows-recmutex.
44348 2019-06-20  Bruno Haible  <bruno@clisp.org>
44350         windows-mutex: New module.
44351         * lib/windows-mutex.h: New file, extracted from lib/glthread/lock.h.
44352         * lib/windows-mutex.c: New file, extracted from lib/glthread/lock.c.
44353         * lib/windows-spinlock.h: New file, extracted from lib/glthread/lock.h.
44354         * lib/glthread/lock.h: Include windows-spinlock.h, windows-mutex.h.
44355         (gl_spinlock_t): Remove type.
44356         (gl_lock_t): Define using glwthread_mutex_t.
44357         (gl_lock_initializer): Define using GLWTHREAD_MUTEX_INIT.
44358         (glthread_lock_init): Define using glwthread_mutex_init.
44359         (glthread_lock_lock): Define using glwthread_mutex_lock.
44360         (glthread_lock_unlock): Define using glwthread_mutex_unlock.
44361         (glthread_lock_destroy): Define using glwthread_mutex_destroy.
44362         (glthread_lock_init_func, glthread_lock_lock_func,
44363         glthread_lock_unlock_func, glthread_lock_destroy_func): Remove
44364         declarations.
44365         Use glwthread_spinlock_t instead of gl_spinlock_t.
44366         (gl_rwlock_initializer, gl_recursive_lock_initializer): Define using
44367         GLWTHREAD_SPINLOCK_INIT.
44368         * lib/glthread/lock.c (glthread_lock_init_func, glthread_lock_lock_func,
44369         glthread_lock_unlock_func, glthread_lock_destroy_func): Remove
44370         functions.
44371         * lib/glthread/cond.h: Use glwthread_spinlock_t instead of
44372         gl_spinlock_t.
44373         * modules/windows-mutex: New file.
44374         * modules/lock (Depends-on): Add windows-mutex.
44376 2019-06-20  Bruno Haible  <bruno@clisp.org>
44378         windows-once: New module.
44379         * lib/windows-once.h: New file, extracted from lib/glthread/lock.h.
44380         * lib/windows-once.c: New file, extracted from lib/glthread/lock.c.
44381         * lib/glthread/lock.h: Include windows-once.h.
44382         (gl_once_t): Define using glwthread_once_t.
44383         (gl_once_define): Define using GLWTHREAD_ONCE_INIT.
44384         (glthread_once): Define using glwthread_once.
44385         (glthread_once_func): Remove declaration.
44386         * lib/glthread/lock.c (glthread_once_func): Remove function.
44387         * modules/windows-once: New file.
44388         * modules/lock (Depends-on): Add windows-once.
44390 2019-06-20  Bruno Haible  <bruno@clisp.org>
44392         lock, cond: Avoid possible counter wraparound on Windows.
44393         * lib/glthread/lock.c (glthread_lock_lock_func): Leave the 'started'
44394         field of the guard unchanged if it was already positive.
44395         (glthread_rwlock_rdlock_func): Likewise.
44396         (glthread_rwlock_wrlock_func): Likewise.
44397         (glthread_recursive_lock_lock_func): Likewise.
44398         * lib/glthread/cond.c (glthread_cond_wait_func): Likewise.
44399         (glthread_cond_timedwait_func): Likewise.
44401 2019-06-20  Bruno Haible  <bruno@clisp.org>
44403         cond: Make glthread_cond_timedwait more reliable on Windows.
44404         * lib/glthread/cond.c (glthread_cond_timedwait_func): Initialize the
44405         condition variable before looking at the current time.
44407 2019-06-20  Bruno Haible  <bruno@clisp.org>
44409         pthread_mutex_timedlock: New module.
44410         * lib/pthread.in.h (pthread_mutex_timedlock): New dummy function and
44411         new declaration.
44412         * lib/pthread_mutex_timedlock.c: New file.
44413         * m4/pthread_mutex_timedlock.m4: New file.
44414         * m4/pthread.m4 (gl_PTHREAD_CHECK): Don't call AC_LIBOBJ here. Test
44415         whether pthread_mutex_timedlock is declared.
44416         (gl_PTHREAD_MODULE_INDICATOR): New macro.
44417         (gl_PTHREAD_DEFAULTS): Initialize GNULIB_PTHREAD_MUTEX_TIMEDLOCK,
44418         HAVE_PTHREAD_MUTEX_TIMEDLOCK.
44419         * modules/pthread (configure.ac): Call AC_LIBOBJ here.
44420         (Makefile.am): Substitute GNULIB_PTHREAD_MUTEX_TIMEDLOCK,
44421         HAVE_PTHREAD_MUTEX_TIMEDLOCK.
44422         * modules/pthread_mutex_timedlock: New file.
44423         * doc/posix-functions/pthread_mutex_timedlock.texi: Mention the new
44424         module.
44426 2019-06-20  Bruno Haible  <bruno@clisp.org>
44428         thread, lock, cond, tls: Recognize C11 multithreaded applications.
44429         * m4/threadlib.m4 (gl_THREADLIB_BODY): Test for <threads.h>.
44430         * lib/glthread/thread.h (c11_threads_in_use): New macro.
44431         (pthread_in_use, pth_in_use, thread_in_use): Use it.
44432         * lib/glthread/lock.h (c11_threads_in_use): New macro.
44433         (pthread_in_use, pth_in_use, thread_in_use): Use it.
44434         * lib/glthread/cond.h (c11_threads_in_use): New macro.
44435         (pthread_in_use, pth_in_use, thread_in_use): Use it.
44436         * lib/glthread/tls.h (c11_threads_in_use): New macro.
44437         (pthread_in_use, pth_in_use, thread_in_use): Use it.
44439 2019-06-20  Bruno Haible  <bruno@clisp.org>
44441         tls tests: Small improvements.
44442         * tests/test-tls.c: Include <stdint.h>.
44443         (worker_thread): Avoid gcc warning on 64-bit mingw.
44444         (test_tls): Pass a different id to each thread.
44445         * modules/tls-tests (Depends-on): Add stdint.
44447 2019-06-20  Bruno Haible  <bruno@clisp.org>
44449         cond tests: Simplify.
44450         * tests/test-cond.c (test_timedcond): Remove redundant assignment.
44452 2019-06-20  Bruno Haible  <bruno@clisp.org>
44454         lock tests: Avoid reference to undefined variable if !ENABLE_LOCKING.
44455         * tests/test-lock.c (test_once): Don't reference fire_signal if
44456         !ENABLE_LOCKING.
44458 2019-06-19  Bruno Haible  <bruno@clisp.org>
44460         nanosleep: Relicense under LGPLv2+.
44461         Approved by Jim Meyering, Paul Eggert, Eric Blake, Pádraig Brady.
44462         * modules/nanosleep (License): Change to LGPLv2+.
44464 2019-06-19  Bruno Haible  <bruno@clisp.org>
44466         Reorder pieces of header in perl scripts.
44467         The desired order is
44468         - Prologue part 1 (2 lines with #!)
44469         - Program short description
44470         - Copyright and license notice
44471         - Written-by notice
44472         - Program short description (optional)
44473         - Program long description (optional)
44474         - Prologue part 2
44475         - Time stamp
44476         - Code
44477         Reported by Paul Eggert.
44478         * build-aux/announce-gen: Reorder header.
44479         * build-aux/gitlog-to-changelog: Likewise.
44480         * build-aux/useless-if-before-free: Likewise.
44481         * build-aux/prefix-gnulib-mk: Add copyright notice and short
44482         description.
44483         * build-aux/update-copyright: Likewise. Add short description. Bump
44484         time-stamp-line-limit to 200.
44486 2019-06-18  Paul Eggert  <eggert@cs.ucla.edu>
44488         verify-tests: work around xlc bug
44489         Problem reported by Bruno Haible in:
44490         https://lists.gnu.org/r/bug-gnulib/2019-06/msg00049.html
44491         * tests/test-verify.c (item): Move the arithmetic inside the
44492         verify_expr, to avoid tickling a bug in IBM AIX xlc V12.1.
44494 2019-06-16  Bruno Haible  <bruno@clisp.org>
44496         Restore Emacs time-stamp hook applicability.
44497         Reported by Darshit Shah <darnir@gnu.org>.
44498         * build-aux/useless-if-before-free: Bump time-stamp-line-limit to 50.
44499         * build-aux/announce-gen: Likewise.
44500         * build-aux/gitlog-to-changelog: Likewise.
44501         * build-aux/prefix-gnulib-mk: Likewise.
44502         * build-aux/update-copyright: Likewise.
44504 2019-06-15  Bruno Haible  <bruno@clisp.org>
44506         Fix scripts to have valid executable format on Alpine Linux.
44507         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
44508         Idea by Paul Eggert.
44509         * build-aux/useless-if-before-free: Use a prologue that starts with
44510         '#!/bin/sh'.
44511         * build-aux/announce-gen: Likewise.
44512         * build-aux/gitlog-to-changelog: Likewise.
44513         * build-aux/prefix-gnulib-mk: Likewise.
44514         * build-aux/update-copyright: Likewise.
44515         * tests/test-update-copyright.sh: Update test program accordingly.
44517 2019-06-10  Bruno Haible  <bruno@clisp.org>
44519         nproc: Ensure nproc(NPROC_ALL) ≥ nproc(NPROC_CURRENT) with glibc ≥ 2.26.
44520         Reported by Nikita Ermakov <arei@altlinux.org> in
44521         <https://lists.gnu.org/archive/html/bug-gnulib/2019-06/msg00003.html>.
44522         * lib/nproc.c (num_processors_ignoring_omp): Treat a return value of
44523         sysconf (_SC_NPROCESSORS_CONF) == 2 like a return value == 1.
44525 2019-06-10  Bruno Haible  <bruno@clisp.org>
44527         posix_spawn_file_actions_addchdir: Fix possible use-after-free bug.
44528         * lib/spawn_int.h (struct __spawn_action): Remove 'const' from path.
44529         * lib/spawn_faction_addchdir.c (posix_spawn_file_actions_addchdir): Make
44530         a copy of the path argument.
44531         * lib/spawn_faction_destroy.c (posix_spawn_file_actions_destroy): Free
44532         it.
44534 2019-06-10  Bruno Haible  <bruno@clisp.org>
44536         posix_spawn_file_actions_addopen: Fix possible use-after-free bug.
44537         Reported at <https://sourceware.org/bugzilla/show_bug.cgi?id=17048>.
44538         * lib/spawn_int.h (struct __spawn_action): Remove 'const' from path.
44539         * lib/spawn_faction_addopen.c (posix_spawn_file_actions_addopen): Make
44540         a copy of the path argument.
44541         * lib/spawn_faction_destroy.c (posix_spawn_file_actions_destroy): Free
44542         it.
44544 2019-06-10  Bruno Haible  <bruno@clisp.org>
44546         posix_spawn_file_actions_addfchdir: Add tests.
44547         * tests/test-posix_spawn_file_actions_addfchdir.c: New file.
44548         * tests/test-posix_spawn5.c: New file.
44549         * modules/posix_spawn_file_actions_addfchdir-tests: New file.
44551 2019-06-10  Bruno Haible  <bruno@clisp.org>
44553         posix_spawn_file_actions_addfchdir: New module.
44554         * lib/spawn.in.h (posix_spawn_file_actions_addfchdir): New declaration.
44555         * lib/spawn_int.h (struct __spawn_action): Add tag 'spawn_do_fchdir' and
44556         union member 'fchdir_action'.
44557         * lib/spawn_faction_addfchdir.c: New file.
44558         * lib/spawni.c (__spawni): Implement the spawn_do_fchdir action.
44559         * m4/posix_spawn_faction_addfchdir.m4: New file.
44560         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test whether module
44561         'posix_spawn_file_actions_addfchdir' is present and whether
44562         posix_spawn_file_actions_addfchdir_np exists. Set REPLACE_POSIX_SPAWN.
44563         * m4/spawn_h.m4 (gl_SPAWN_H): Test whether
44564         posix_spawn_file_actions_addfchdir is declared.
44565         (gl_SPAWN_H_DEFAULTS): Initialize
44566         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
44567         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
44568         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR.
44569         * modules/spawn (Makefile.am): Substitute
44570         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
44571         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
44572         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR.
44573         * modules/posix_spawn_file_actions_addfchdir: New file.
44574         * tests/test-spawn-c++.cc (posix_spawn_file_actions_addfchdir): Check
44575         signature.
44576         * doc/posix-functions/posix_spawn.texi: Mention the new module.
44577         * doc/posix-functions/posix_spawnp.texi: Likewise.
44578         * doc/glibc-functions/posix_spawn_file_actions_addfchdir_np.texi:
44579         Likewise.
44581 2019-06-10  Bruno Haible  <bruno@clisp.org>
44583         doc: Document existence of posix_spawn_file_actions_addchdir module.
44584         * doc/glibc-functions/posix_spawn_file_actions_addchdir_np.texi: Mention
44585         the posix_spawn_file_actions_addchdir module.
44587 2019-06-10  Bruno Haible  <bruno@clisp.org>
44589         posix_spawn-internal: Fix module description.
44590         * modules/posix_spawn (configure.ac): Move request to compile spawni.c
44591         from here...
44592         * modules/posix_spawnp (configure.ac): ... and here...
44593         * modules/posix_spawn-internal (configure.ac): ... to here.
44595 2019-06-10  Bruno Haible  <bruno@clisp.org>
44597         doc: Update and improve documentation of glibc functions.
44598         This is a series of commits that
44599         - updates the documentation to the state of glibc 2.29,
44600         - adds references to Linux man pages and glibc documentation,
44601         - marks Linux specific functions as such.
44602         These are the commits:
44603         doc: Update after removal of crypt functions from glibc 2.28.
44604         doc: Remove mention of function vm86 (does not exist on x86_64).
44605         doc: Remove mention of functions that are gone from glibc.
44606         doc: Mention that glibc no longer provides h_errno.
44607         doc: Mention the availability of specific functions in glibc versions.
44608         doc: Mention eaccess.
44609         doc: Add references to Linux man pages.
44610         doc: Add references to glibc documentation.
44611         doc: Mention inotify_* functions.
44612         doc: Mention ppoll.
44613         doc: Mention sched_getcpu.
44614         doc: Mention sync_file_range.
44615         doc: Mention epoll_pwait.
44616         doc: Mention eventfd, eventfd_read, eventfd_write.
44617         doc: Mention signalfd.
44618         doc: Mention timerfd_create, timerfd_gettime, timerfd_settime.
44619         doc: Mention epoll_create1.
44620         doc: Mention getauxval.
44621         doc: Mention pthread_getattr_default_np, pthread_setattr_default_np.
44622         doc: Mention nextdown, nextup.
44623         doc: Mention more ISO TS 18661-1 <math.h> functions.
44624         doc: Mention ISO TS 18661-1 <fenv.h> functions.
44625         doc: Mention getrandom, getentropy.
44626         doc: Mention strfromf, strfromd, strfroml.
44627         doc: Mention preadv2, pwritev2.
44628         doc: Mention copy_file_range.
44629         doc: Mention memfd_create.
44630         doc: Mention mlock2.
44631         doc: Mention pkey_alloc, pkey_set, pkey_get, pkey_free, pkey_mprotect.
44632         doc: Mention more ISO TS 18661-1 <math.h> functions.
44633         doc: Mention renameat2.
44634         doc: Mention statx.
44635         doc: Mention the ISO C11 multithreading header and functions.
44636         doc: Mention getcpu.
44637         doc: Mention posix_spawn_file_actions_add[f]chdir_np.
44638         doc: Some glibc functions also exist on IRIX 6.5 in 32-bit mode.
44639         doc: Some glibc functions also exist on FreeBSD, AIX, HP-UX, Solaris 11.
44640         doc: Some glibc functions also exist on FreeBSD, Solaris 11.
44641         doc: Some glibc functions also exist on Solaris 11.
44642         doc: Some glibc functions also exist on Solaris 11.4.
44643         doc: Some glibc functions also exist on FreeBSD.
44644         doc: Some glibc functions also exist on BeOS.
44645         doc: Some glibc functions also exist on Haiku.
44646         doc: Mark functions which exist only on Linux.
44647         doc: Mark functions which exist only on Linux and illumos.
44649 2019-06-06  Paul Eggert  <eggert@cs.ucla.edu>
44651         copy-file: fix typo
44652         * lib/copy-file.c (qcopy_file_preserving): Remove unused label.
44654         copy-file-range: simplify into a stub
44655         Based on a comment by Florian Weimer in:
44656         https://lists.gnu.org/r/bug-gnulib/2019-06/msg00007.html
44657         It turns out that Emacs (which will use this module) won’t need an
44658         emulation and I suspect other programs won’t either, because these
44659         programs will need to fall back on read+write anyway.  Perhaps I
44660         am wrong and other programs will be able to use an emulation; if
44661         so, this patch can be reverted.
44662         * lib/copy-file-range.c (COPY_FILE_RANGE): Replace with a stub.
44663         Just call it copy_file_range.
44664         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE):
44665         Check via AC_LINK_IFELSE.
44666         * modules/copy-file-range (Depends-on): Remove modules no longer used.
44668 2019-06-04  Paul Eggert  <eggert@cs.ucla.edu>
44670         copy-file: prefer copy_file_range
44671         * lib/copy-file.c: Do not include xalloc.h.
44672         (qcopy_file_preserving): Allocate a buffer only if
44673         copy_file_range does not suffice.  If the allocation fails
44674         don't give up; just use a small stack-based buffer.
44675         Prefer copy_file_range if it works.
44676         * modules/copy-file (Depends-on): Add copy-file-range.
44677         Remove xalloc.
44679         copy-file-range: new module
44680         * MODULES.html.sh: Add copy-file-range.
44681         * lib/copy-file-range.c, m4/copy-file-range.m4:
44682         * modules/copy-file-range: New files.
44683         * lib/unistd.in.h (copy_file_range): Declare.
44684         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS):
44685         Set up GNULIB_COPY_FILE_RANGE and HAVE_COPY_FILE_RANGE.
44686         * modules/unistd (unistd.h): Substitute them.
44688 2019-05-28  Bruno Haible  <bruno@clisp.org>
44690         binary-io: Attempted use of O_BINARY on consoles no longer fails.
44691         Reported by KO Myung-Hun <komh78@gmail.com> in
44692         <https://lists.gnu.org/archive/html/bug-gnulib/2019-05/msg00124.html>.
44693         * lib/binary-io.h (__gl_setmode_check): Remove function.
44694         (set_binary_mode): Declare as notinline on DJGPP and EMX.
44695         * lib/binary-io.c (__gl_setmode_check): Remove function.
44696         (set_binary_mode): Define here on DJGPP and EMX. Inline
44697         __gl_setmode_check. In case of a tty, don't return an error code.
44699 2019-05-28  James Youngman  <jay@gnu.org>
44701         dirent-safer: Make opendir_safer usable from C++.
44702         * lib/dirent-safer.h: use extern "C".
44704 2019-05-28  James Youngman  <jay@gnu.org>
44706         canonicalize: Make canonicalize_filename_mode usable from C++.
44707         * lib/canonicalize.h: use extern "C".
44709 2019-05-26  Akim Demaille  <akim@lrde.epita.fr>
44711         prefix-gnulib-mk: Fix CPPFLAGS migration.
44712         * build-aux/prefix-gnulib-mk (prefix_assignment): Don't forget the
44713         _a part of the library name.
44715 2019-05-24  Paul Eggert  <eggert@cs.ucla.edu>
44717         flexmember: update comments again
44718         * lib/flexmember.h, m4/flexmember.m4: Improve comments further.
44720         flexmember: update comment
44721         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER): Improve comment.
44723 2019-05-20  Bruno Haible  <bruno@clisp.org>
44725         setlocale: Improve fallback on macOS.
44726         * lib/setlocale.c (search): Optimize away a redundant strcmp()
44727         invocation.
44728         (locales_with_principal_territory): New array.
44729         (langcmp, get_main_locale_with_same_language): New functions.
44730         (locales_with_principal_language): New array.
44731         (terrcmp, get_main_locale_with_same_territory): New functions.
44732         (rpl_setlocale): When setlocale_single failed, try again with a locale
44733         that is more likely to exist. Don't warn if the environment variable
44734         SETLOCALE_VERBOSE is not set.
44736 2019-05-19  Bruno Haible  <bruno@clisp.org>
44738         localename: Fix default on macOS.
44739         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Don't test for CFLocaleCopyCurrent.
44740         * lib/localename.c: Remove includes for HAVE_CFLOCALECOPYCURRENT.
44741         (gl_locale_name_environ, gl_locale_name_default): Remove code for
44742         HAVE_CFLOCALECOPYCURRENT.
44743         * lib/localename.h (gl_locale_name_default): Update.
44745 2019-05-19  Karl Berry  <karl@freefriends.org>
44747         * config/srclistvars.sh (TEXINFOTEX): make ftp.gnu.org be the
44748         source for texinfo.tex, replacing TEXINFOSRC, per Texinfo maintainer.
44749         * config/srclist.txt (texinfo.tex): use it. (Also doc changes.)
44751 2019-05-18  Akim Demaille  <akim@lrde.epita.fr>
44753         maintainer-makefile: catch uses of $< in non-implicit rules
44754         * top/maint.mk (sc_prohibit_magic_number_exit): New.
44756 2019-05-18  Bruno Haible  <bruno@clisp.org>
44758         threadlib: Provide an easy way to avoid mingw's winpthreads library.
44759         * m4/threadlib.m4 (gl_AVOID_WINPTHREAD): New macro.
44760         (gl_THREADLIB_EARLY_BODY): Recognize when it was invoked, and set
44761         gl_use_threads accordingly.
44763 2019-05-18  Bruno Haible  <bruno@clisp.org>
44765         pthread_sigmask: Fix compilation error with --enable-threads=windows.
44766         Reported by Tim Rühsen in
44767         <https://lists.gnu.org/archive/html/bug-gnulib/2018-01/msg00018.html>
44768         and Michele Locati in
44769         <https://lists.gnu.org/archive/html/bug-gettext/2019-04/msg00057.html>.
44770         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Revert change from
44771         2015-06-01. Test whether pthread_sigmask is a macro, regardless of
44772         $LIBMULTITHREAD. Consider it regardless whether module 'threadlib' is
44773         in use and regardless which threads API is chosen.
44775 2019-05-14  Paul Eggert  <eggert@cs.ucla.edu>
44777         close-stream, closein, closeout: simplify
44778         I noticed this opportunity for simplification while drafting a
44779         new, related module that I haven’t had time to finish yet.
44780         * m4/close-stream.m4, m4/closein.m4, m4/closeout.m4: Remove.
44781         * modules/close-stream (Files): Remove m4/close-stream.m4.
44782         (configure.ac): Omit gl_CLOSE_STREAM.
44783         * modules/closein (Files): Remove m4/closein.m4
44784         (configure.ac): Omit gl_CLOSEIN.
44785         * modules/closeout (Files): Remove m4/closeout.m4.
44786         (configure.ac): Omit gl_CLOSEOUT.
44788 2019-05-12  Bruno Haible  <bruno@clisp.org>
44790         libtool-next-version: New program.
44791         * build-aux/libtool-next-version: New file.
44793 2019-05-11  John Darrington  <john@darrington.wattle.id.au>
44794             Bruno Haible  <bruno@clisp.org>
44796         version-etc: Ease translation.
44797         * lib/version-etc.c (version_etc_arn, emit_bug_reporting_address): Move
44798         URLs and formatting newlines out of translatable string.
44800 2019-05-11  Bruno Haible  <bruno@clisp.org>
44802         gnupload: Explain how to create symlinks.
44803         * build-aux/gnupload (usage): Add an example that creates symlinks.
44805 2019-05-11  Paul Eggert  <eggert@cs.ucla.edu>
44807         fpucw: port to gcc -pedantic
44808         * lib/fpucw.h (GET_FPUCW, SET_FPUCW):
44809         Use __extension__ if using ({ ... }).
44811         crypto/af_alg: port to strict C compilers
44812         * lib/af_alg.c: Include af_alg.h regardless, so that the
44813         compilation unit is nonempty.
44815 2019-05-10  Bruno Haible  <bruno@clisp.org>
44817         base64: Avoid false positive warning from Coverity.
44818         Reported by Kamil Dudka <kdudka@redhat.com>.
44819         Idea by Paul Eggert.
44820         * lib/base64.c (base64_encode_fast, base64_encode): Add a no-op
44821         '& 0x3f' to the array index expressions. This convinces Coverity that
44822         there is no out-of-bounds array reference, regardless of the input.
44824 2019-05-09  Bruno Haible  <bruno@clisp.org>
44826         gettext: Update to gettext 0.20.
44827         * modules/gettext (Files): Remove m4/codeset.m4, m4/fcntl-o.m4,
44828         m4/glibc2.m4, m4/glibc21.m4, m4/intdiv0.m4, m4/intl.m4, m4/intldir.m4,
44829         m4/intmax.m4, m4/inttypes_h.m4, m4/inttypes-pri.m4, m4/lcmessage.m4,
44830         m4/lock.m4, m4/longlong.m4, m4/printf-posix.m4, m4/size_max.m4,
44831         m4/stdint_h.m4, m4/threadlib.m4, m4/uintmax_t.m4, m4/visibility.m4,
44832         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4. Add m4/host-cpu-c-abi.m4.
44833         (configure.ac): Request infrastructure compatible with gettext 0.20.
44834         * m4/glibc2.m4: Remove file.
44835         * m4/intdiv0.m4: Remove file.
44836         * m4/intl.m4: Remove file.
44837         * m4/intldir.m4: Remove file.
44838         * m4/intmax.m4: Remove file.
44839         * m4/printf-posix.m4: Remove file.
44840         * m4/uintmax_t.m4: Remove file.
44841         * m4/gettext.m4: Update from gettext 0.20.
44842         * m4/po.m4: Likewise.
44844 2019-05-09  Paul Eggert  <eggert@cs.ucla.edu>
44846         verify: remove verify_true
44847         * NEWS: Mention this.
44848         * lib/verify.h (verify_true): Remove.
44849         * tests/test-verify.c (item): Test verify_expr, not verify_true.
44851         Support C2x and C++17 static_assert
44852         C2x and C++17 finally added support for a simple, single-argument
44853         ‘static_assert’ that implements what the Gnulib ‘verify’ macro was
44854         doing back in 2005.  Implement static_assert on older platforms.
44855         The only remaining advantage of ‘verify’ is a shorter name.
44856         * doc/posix-headers/assert.texi (assert.h):
44857         * doc/verify.texi (Compile-time Assertions):
44858         Modernize for C2x and C++17.
44859         * lib/verify.h (_GL_HAVE__STATIC_ASSERT1, _GL_HAVE_STATIC_ASSERT1):
44860         New macros.
44861         (_GL_HAVE__STATIC_ASSERT): Remove.
44862         (_GL_HAVE__STATIC_ASSERT): Rely more heavily on __STDC_VERSION__.
44863         (_GL_VERIFY_TRUE, _GL_VERIFY_TYPE): Remove 2nd arg, the diagnostic
44864         string.  All callers changed.
44865         (_GL_VERIFY): Require 3 or more args, of which only the first 2
44866         are used.  All callers changed.
44867         (_Static_assert): Allow either 1 or 2 args, and define if
44868         !_GL_HAVE__STATIC_ASSERT1 instead of defining if
44869         !_GL_HAVE__STATIC_ASSERT.
44870         (static_assert): Define if !_GL_HAVE_STATIC_ASSERT1 instead
44871         of defining if !_GL_HAVE_STATIC_ASSERT.
44872         (verify_expr, verify): Don’t bother trying to copy the expression
44873         into the diagnostic, since 1-argument static_assert doesn’t.
44874         (verify): Prefer 1-argument _Static_assert if it works.
44875         * m4/assert_h.m4 (gl_ASSERT_H): Check for 1-argument static_assert.
44877 2019-05-08  Paul Eggert  <eggert@cs.ucla.edu>
44879         Fix _GL_HAVE__STATIC_ASSERT typo
44880         * lib/verify.h (_Static_assert): For the FreeBSD workaround,
44881         use _GL_HAVE__STATIC_ASSERT, not _GL_HAVE_STATIC_ASSERT.
44883 2019-05-05  Bruno Haible  <bruno@clisp.org>
44885         wcwidth: Ensure width 1, not 2, for ambiguous characters.
44886         Reported by Kiyoshi KANAZAWA <yoi_no_myoujou@yahoo.co.jp>
44887         via Akim Demaille <akim.demaille@gmail.com>.
44888         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check the width of U+2202. Use an
44889         en_US.UTF-8 locale, since that is more likely to be present than an
44890         fr_FR.UTF-8 locale.
44891         * tests/test-wcwidth.c (main): Check the width of U+2202.
44892         * doc/posix-functions/wcwidth.texi: Mention the issue.
44894 2019-05-03  Paul Eggert  <eggert@cs.ucla.edu>
44896         Port manywarnings to GCC 9
44897         * build-aux/gcc-warning.spec: Sort.  Add -Wattribute-alias,
44898         -Wc11-c2x-compat, -Wcast-result (for the D programming language),
44899         -Wclass-conversion, -Wdeprecated-copy, -Wdeprecated-copy-dtor,
44900         -Winit-list-lifetime, -Wpessimizing-move, -Wprio-ctor-dtor,
44901         -Wredundant-move.  Adjust to minor wording changes in GCC 9’s
44902         --help=warnings output.
44903         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wabsolute-value,
44904         -Waddress-of-packed-member, -Wattribute-warning, -Wcannot-profile,
44905         -Wmissing-profile.  Change -Wattribute-alias to -Wattribute-alias=2.
44907 2019-04-30  Paul Eggert  <eggert@cs.ucla.edu>
44909         Sync lib/mktime-internal.h from glibc
44910         * config/srclist.txt: Add entry for lib/mktime-internal.h.
44911         * lib/mktime-internal.h: Autoupdate.
44913 2019-04-28  Bruno Haible  <bruno@clisp.org>
44915         tls tests: Prevent that the test takes too long.
44916         * tests/test-tls.c: Include <signal.h>, <unistd.h>.
44917         (main): Let the test fail if it takes more than 10 minutes.
44918         * modules/tls-tests (configure.ac): Test whether 'alarm' is declared.
44920 2019-04-27  Bruno Haible  <bruno@clisp.org>
44922         lock tests: Prevent that the test takes too long.
44923         * tests/test-lock.c: Include <signal.h>, <unistd.h>.
44924         (main): Let the test fail if it takes more than 10 minutes.
44925         * modules/lock-tests (configure.ac): Test whether 'alarm' is declared.
44927 2019-04-27  Bruno Haible  <bruno@clisp.org>
44929         localename: Fix crash on mingw (regression from 2018-11-23).
44930         * lib/localename.c (gl_locale_name_posix): Don't attempt to convert a
44931         locale name that is null.
44933 2019-04-27  Bruno Haible  <bruno@clisp.org>
44935         Fix gcc warnings on 64-bit mode mingw.
44936         * lib/clean-temp.c: Include <stdint.h> instead of defining uintptr_t.
44937         * lib/gl_array_list.c: Likewise.
44938         * lib/gl_array_map.c: Likewise.
44939         * lib/gl_array_set.c: Likewise.
44940         * lib/gl_carray_list.c: Likewise.
44941         * lib/gl_sublist.c: Likewise.
44942         * lib/gl_avltreehash_list.c (uintptr_t): Remove definition.
44943         * lib/gl_rbtreehash_list.c (uintptr_t): Likewise.
44944         * lib/gl_hash_map.c (uintptr_t): Likewise.
44945         * lib/gl_hash_set.c (uintptr_t): Likewise.
44946         * lib/gl_linkedhash_list.c (uintptr_t): Likewise.
44947         * lib/gl_linkedhash_map.c (uintptr_t): Likewise.
44948         * lib/gl_linkedhash_set.c (uintptr_t): Likewise.
44949         * lib/iconv.c (uintptr_t): Likewise.
44950         * lib/iconv_close.c (uintptr_t): Likewise.
44951         * tests/test-lock.c: Include <stdint.h>.
44952         (once_contender_thread, test_once): Cast through 'intptr_t' instead of
44953         'long'.
44954         * modules/clean-temp (Depends-on): Add stdint.
44955         * modules/array-list (Depends-on): Likewise.
44956         * modules/array-map (Depends-on): Likewise.
44957         * modules/array-set (Depends-on): Likewise.
44958         * modules/carray-list (Depends-on): Likewise.
44959         * modules/sublist (Depends-on): Likewise.
44960         * modules/lock-tests (Depends-on): Likewise.
44962 2019-04-27  Bruno Haible  <bruno@clisp.org>
44964         error: Tweak indentation.
44965         * lib/error.c: Correct indentation.
44967 2019-04-27  Bruno Haible  <bruno@clisp.org>
44969         term-style-control: Fix gcc warning on mingw.
44970         * lib/term-style-control.c (ensure_other_signal_handlers): Reduce scope
44971         of i.
44973 2019-04-26  Bruno Haible  <bruno@clisp.org>
44975         pipe-filter-gi, pipe-filter-ii: Fix gcc warning.
44976         * lib/pipe-filter-aux.h (read): Undefine before redefinition.
44978 2019-04-26  Bruno Haible  <bruno@clisp.org>
44980         relocatable-prog: Fix gcc warning on mingw.
44981         * lib/progreloc.c (maybe_executable): Don't define on native Windows and
44982         on EMX.
44984 2019-04-02  Bruno Haible  <bruno@clisp.org>
44986         gitsub.sh: New file.
44987         * top/gitsub.sh: New file.
44989 2019-04-18  Akim Demaille  <akim@lrde.epita.fr>
44991         argmatch: use void* for raw memory pointers
44992         * lib/argmatch.h, lib/argmatch.c (argmatch, argmatch_valid)
44993         (__xargmatch_internal, argmatch_to_argument): Use void* for pointers
44994         to "values", keep char* for strings.
44996 2019-04-21  Akim Demaille  <akim@lrde.epita.fr>
44998         prefix-gnulib-mk: fix the support for gnulib-po
44999         * build-aux/prefix-gnulib-mk (prefix_assignment): Remove useless $res.
45000         Don't touch HAVE_* variables.
45001         Map AM_CPPFLAGS and AM_CPPFLAGS to the library's corresponding variables.
45003 2019-04-18  Bernhard Voelker  <mail@bernhard-voelker.de>
45005         di-set: allow free with 'ino_map' being NULL.
45006         * lib/di-set.c (di_set_free): Avoid ino_map_free() when dis->ino_map
45007         is NULL.  Bug introduced in commit 3703dbbe88dd.
45008         * tests/test-di-set.c: Add di_set_free() right after di_set_alloc()
45009         as a test.
45011 2019-04-14  Paul Eggert  <eggert@cs.ucla.edu>
45013         * lib/str-two-way.h: Fix comment typo.
45015 2019-04-13  Bruno Haible  <bruno@clisp.org>
45017         x-to-1: Restore ability to use original calling convention.
45018         * build-aux/x-to-1.in: Add comments. Accept the original form of
45019         HELP2MAN argument as well as the form expected since 2012-12-12.
45021 2019-04-13  Bruno Haible  <bruno@clisp.org>
45023         x-to-1: Avoid failure due to missing perl modules.
45024         * build-aux/x-to-1.in: Test whether all the perl modules that help2man
45025         needs are installed.
45027 2019-04-13  Bruno Haible  <bruno@clisp.org>
45029         openmp-init: New module.
45030         * modules/openmp-init: New file.
45031         * modules/openmp: (Files, Depends-on, configure.ac, Makefile.am): Revert
45032         the changes from 2019-04-09.
45034 2019-04-12  Bruno Haible  <bruno@clisp.org>
45036         signbit: Fix compilation error when gnulib's math.h exists twice.
45037         * lib/math.in.h (GNULIB_defined_signbit): New macro.
45039 2019-04-12  Bruno Haible  <bruno@clisp.org>
45041         openmp: Fix compilation error on platforms without OpenMP.
45042         * lib/omp-init.c: Include <omp.h> only if _OPENMP.
45044 2019-04-09  Bernhard Voelker  <mail@bernhard-voelker.de>
45046         mountlist: make parsing /proc/self/mountinfo more robust
45047         Cater for the following issues with mountinfo parsing (the first
45048         one was reported by Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
45049         in <https://bugs.gnu.org/35137>).
45050         1. The fields source, target, mntroot and fstype may contain characters
45051         like '\r'; sscanf(3) fails to read such values with the %s format
45052         specifier because it would stop at such characters.
45053         Example: "mount -t tmpfs tmpfs /foo^Mbar".
45054         The only true separator in that file is the ' ' character.
45055         2. The source field may be an empty string, which happens e.g. with
45056         "mount -t tmpfs '' /target".
45057         3. The fstype field may contain mangled characters as well which need
45058         unescaping.
45059         * lib/mountlist.c (terminate_at_blank): Add utility function.
45060         (read_file_system_list): In the block trying to read the mountinfo file,
45061         avoid using sscanf(3) with %s format; instead, parse the above fields
45062         separated by spaces one by one.
45063         This also handles the case when the source field is an empty string.
45064         Unescape the fstype field.
45066 2019-04-09  Bruno Haible  <bruno@clisp.org>
45068         openmp: Add workaround for 32-bit programs on AIX.
45069         * lib/omp.in.h: New file.
45070         * lib/omp-init.c: New file, based on lib/nproc.c.
45071         * m4/omp_h.m4: New file.
45072         * modules/openmp (Files): Add them.
45073         (Depends-on): Add include_next, c-ctype, setenv.
45074         (configure.ac): Invoke gl_OMP_H.
45075         (Makefile.am): Add rules to create omp.h and compile omp-init.c.
45076         (Include): Mention <omp.h>.
45078 2019-04-09  Bruno Haible  <bruno@clisp.org>
45080         nproc: Fix return value for privileged processes.
45081         * lib/nproc.c (num_processors_ignoring_omp): Test getuid(), not
45082         getpid().
45084 2019-04-07  Bruno Haible  <bruno@clisp.org>
45086         Add copyright notices in several files.
45087         Reported by <ineiev@gnu.org> in <https://savannah.gnu.org/bugs/?54809>.
45088         * lib/_Noreturn.h: Add LGPLv2+ copyright notice.
45089         * lib/libunistring.valgrind: Likewise.
45090         * lib/iconv_open-*.gperf: Add GPLv2+ copyright notice.
45091         * lib/uniname/gen-uninames.lisp: Add GPLv3+ copyright notice.
45092         * lib/memchr.valgrind: Likewise.
45093         * lib/memchr2.valgrind: Likewise.
45094         * lib/rawmemchr.valgrind: Likewise.
45095         * lib/relocatable.valgrind: Likewise.
45096         * lib/strchrnul.valgrind: Likewise.
45098 2019-03-25  Bruno Haible  <bruno@clisp.org>
45100         term-style-control tests: Fix link error.
45101         Reported by Tom G. Christensen in
45102         <https://lists.gnu.org/archive/html/bug-gnulib/2019-03/msg00108.html>.
45103         * modules/term-style-control-tests (Makefile.am): Link
45104         test-term-style-control-hello and test-term-style-control-yes against
45105         LIBINTL.
45107 2019-03-24  Bruno Haible  <bruno@clisp.org>
45109         term-style-control: Add tests.
45110         * tests/test-term-style-control-hello.c: New file.
45111         * tests/test-term-style-control-yes.c: New file.
45112         * modules/term-style-control-tests: New file.
45114         term-style-control: New module.
45115         * lib/term-style-control.h: New file, based on libtextstyle's
45116         term-ostream.oo.h and term-ostream.oo.c.
45117         * lib/term-style-control.c: New file, based on libtextstyle's
45118         term-ostream.oo.c.
45119         * modules/term-style-control: New file.
45121 2019-03-22  Akim Demaille  <akim@lrde.epita.fr>
45123         _Noreturn: beware of C's _Noreturn in C++ pre C++11.
45124         * lib/_Noreturn.h, m4/gnulib-common.m4: Using C's _Noreturn in
45125         C++98 appears to be supported by Clang, but not by GCC nor ICC.
45127 2019-03-23  Bruno Haible  <bruno@clisp.org>
45129         Support cross-compilation to musl libc.
45130         Reported by Necktwi Ozfguah <necktwi@ferryfair.com>.
45131         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Add cross-compilation guesses for
45132         musl libc.
45133         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Likewise.
45134         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Likewise.
45135         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
45136         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
45137         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
45138         * m4/chown.m4 (gl_FUNC_CHOWN): Likewise.
45139         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
45140         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
45141         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
45142         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
45143         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Likewise.
45144         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Likewise.
45145         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
45146         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
45147         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
45148         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
45149         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
45150         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
45151         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
45152         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
45153         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
45154         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
45155         * m4/getgroups.m4 (AC_FUNC_GETGROUPS, gl_FUNC_GETGROUPS): Likewise.
45156         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
45157         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Likewise.
45158         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
45159         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
45160         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
45161         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): Likewise.
45162         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Likewise.
45163         * m4/log.m4 (gl_FUNC_LOG): Likewise.
45164         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
45165         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
45166         * m4/log10.m4 (gl_FUNC_LOG10): Likewise.
45167         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
45168         * m4/log10l.m4 (gl_FUNC_LOG10L): Likewise.
45169         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
45170         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Likewise.
45171         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Likewise.
45172         * m4/log2.m4 (gl_FUNC_LOG2): Likewise.
45173         * m4/log2f.m4 (gl_FUNC_LOG2F): Likewise.
45174         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Likewise.
45175         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
45176         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
45177         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
45178         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
45179         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
45180         * m4/perror.m4 (gl_FUNC_PERROR): Likewise.
45181         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_INFINITE,
45182         gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_A,
45183         gl_PRINTF_DIRECTIVE_F, gl_PRINTF_FLAG_ZERO, gl_SNPRINTF_TRUNCATION_C99,
45184         gl_SNPRINTF_RETVAL_C99, gl_SNPRINTF_DIRECTIVE_N,
45185         gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
45186         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Likewise.
45187         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
45188         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
45189         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
45190         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
45191         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
45192         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
45193         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
45194         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
45195         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
45196         * m4/setenv.m4 (gl_FUNC_SETENV): Likewise.
45197         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
45198         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
45199         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
45200         * m4/strerror.m4 (gl_FUNC_STRERROR, gl_FUNC_STRERROR_0): Likewise.
45201         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
45202         * m4/strtold.m4 (gl_FUNC_STRTOLD): Likewise.
45203         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
45204         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
45205         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
45206         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
45207         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
45208         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
45209         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
45210         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
45212 2019-03-23  Bruno Haible  <bruno@clisp.org>
45214         posix_spawn_file_actions_*: Document musl libc bugs.
45215         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
45216         the bug.
45217         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Likewise.
45218         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Likewise.
45219         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE): When
45220         cross-compiling to a musl system, guess no.
45221         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2): Likewise.
45222         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): Likewise.
45224 2019-03-23  Bruno Haible  <bruno@clisp.org>
45226         futimens: Document musl libc bug.
45227         * doc/posix-functions/futimens.texi: Mention the bug.
45228         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Require AC_CANONICAL_HOST. When
45229         cross-compiling, guess no on glibc and musl systems.
45231 2019-03-23  Bruno Haible  <bruno@clisp.org>
45233         Clarify that cross-compilation guesses are guesses.
45234         * m4/chown.m4 (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): When cross-compiling, add
45235         prefix 'guessing ' to gl_cv_func_chown_follows_symlink.
45236         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): When cross-compiling, add
45237         prefix 'guessing ' to gl_cv_func_fchownat_nofollow_works.
45238         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): When
45239         cross-compiling, add prefix 'guessing ' to gl_cv_func_getcwd_abort_bug.
45240         * m4/glob.m4 (gl_GLOB): When cross-compiling, add prefix 'guessing ' to
45241         gl_cv_glob_lists_symlinks.
45242         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): When cross-compiling, add prefix
45243         'guessing ' to ac_cv_func_malloc_0_nonnull.
45244         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): When cross-compiling, add prefix
45245         'guessing ' to ac_cv_func_realloc_0_nonnull.
45246         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, add prefix
45247         'guessing ' to gl_cv_func_poll.
45248         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): When cross-
45249         compiling, add prefix 'guessing ' to gl_cv_func_iconv_supports_utf.
45250         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Update accordingly.
45252 2019-03-23  Bruno Haible  <bruno@clisp.org>
45254         strtold: Fix typo.
45255         * m4/strtold.m4 (gl_FUNC_STRTOLD): Fix typo in variable name.
45257 2019-03-23  Bruno Haible  <bruno@clisp.org>
45259         noreturn: In C++ mode with clang, use _Noreturn as fallback.
45260         Reported by Akim Demaille.
45261         * lib/noreturn.h (_GL_NORETURN_FUNC): In C++ mode with clang, when
45262         [[noreturn]] would not work, use _Noreturn instead.
45264 2019-03-22  Akim Demaille  <akim@lrde.epita.fr>
45266         libtextstyle-optional: Fix compiler warnings.
45267         * lib/textstyle.in.h (html_styled_ostream_create): Flag arguments
45268         as unused.
45270 2019-03-19  Akim Demaille  <akim@lrde.epita.fr>
45272         bitset: fix memory leaks
45273         Reported by Bruno Haible.
45274         https://lists.gnu.org/archive/html/bug-gnulib/2019-03/msg00027.html
45275         * lib/bitset/vector.c (vbitset_free): New.
45276         (vbitset_vtable): Use it.
45278 2019-03-19  Akim Demaille  <akim@lrde.epita.fr>
45280         bitset: minor changes
45281         * lib/bitset/base.h (bitset_alloc_type): Remove, unused.
45282         * lib/bitset/table.c: Formatting changes.
45283         Remove useless braces.
45284         Prefer using else in cascades of if/else-if with returns.
45285         * lib/bitset/vector.c: Reduce scopes.
45287 2019-03-19  Akim Demaille  <akim@lrde.epita.fr>
45289         bitset: expose bitset_resize
45290         * lib/bitset.h (bitset_resize): Bounce on the polymorphic implementation.
45291         * tests/test-bitset.c (check_attributes): Check bitset_resize.
45292         (main): Use a variable bitset as reference, since fixed does not support resize.
45294 2019-03-19  Bruno Haible  <bruno@clisp.org>
45296         doc: Document the 'stdnoreturn' and 'noreturn' modules.
45297         Reported by Akim Demaille.
45298         * doc/noreturn.texi: New file.
45299         * doc/gnulib.texi: Include it.
45301 2019-03-19  Bruno Haible  <bruno@clisp.org>
45303         doc: Document how to use 'static inline'.
45304         * doc/static-inline.texi: New file.
45305         * doc/gnulib.texi: Include it.
45307 2019-03-19  Bruno Haible  <bruno@clisp.org>
45309         libtextstyle-optional: Add tests.
45310         * tests/test-libtextstyle.c: New file, based on libtextstyle's
45311         adhoc-tests/hello.c.
45312         * tests/test-libtextstyle-default.css: New file, copied from
45313         libtextstyle's adhoc-tests/hello-default.css.
45314         * modules/libtextstyle-optional-tests: New file.
45316         libtextstyle-optional: New module.
45317         * lib/textstyle.in.h: New file, based on libtextstyle's textstyle.h.
45318         * m4/libtextstyle-optional.m4: New file, based on m4/libtextstyle.m4.
45319         * modules/libtextstyle-optional: New file.
45321 2019-03-19  Bruno Haible  <bruno@clisp.org>
45323         c-stack: Make signal handlers more reliable.
45324         * lib/c-stack.c (progname): New variable.
45325         (die): Use it.
45326         (c_stack_action): Initialize it.
45327         (segv_handler): Save and restore errno.
45329 2019-03-19  Bruno Haible  <bruno@clisp.org>
45331         Help making signal handlers more reliable.
45332         * m4/gnulib-common.m4 (gl_COMMON_BODY): Emit definition of
45333         _GL_ASYNC_SAFE into config.h.
45334         * lib/nanosleep.c (sighandler): Mark as _GL_ASYNC_SAFE.
45335         * lib/fatal-signal.h (at_fatal_signal): Add _GL_ASYNC_SAFE marker to
45336         argument.
45337         * lib/fatal-signal.c (action_t, uninstall_handlers,
45338         fatal_signal_handler): Mark as _GL_ASYNC_SAFE.
45339         * lib/clean-temp.c (cleanup_action): Mark as _GL_ASYNC_SAFE.
45340         * lib/wait-process.c (cleanup_slaves, cleanup_slaves_action): Mark as
45341         _GL_ASYNC_SAFE.
45342         * lib/c-stack.h (c_stack_action): Add _GL_ASYNC_SAFE marker to argument.
45343         * lib/c-stack.c: Add _GL_ASYNC_SAFE markers.
45345 2019-03-18  Bruno Haible  <bruno@clisp.org>
45347         _Noreturn: clang and MSVC do support [[noreturn]] in C++11 mode.
45348         * lib/_Noreturn.h: Use [[noreturn]] if __GNUC__ and __GNUC_MINOR__
45349         indicate clang, or if _MSC_VER indicates MSVC++ 14.0 or newer.
45351 2019-03-17  Akim Demaille  <akim@lrde.epita.fr>
45353         _Noreturn: GCC 4.7 does not support [[noreturn]] in C++11 mode
45354         * lib/_Noreturn.h, m4/gnulib-common.m4: Don't use [[noreturn]] before
45355         GCC 4.8.
45357 2019-03-17  Paul Eggert  <eggert@cs.ucla.edu>
45359         fts: minor simplification
45360         * lib/fts.c (fts_safe_changedir): Remove redundant assignment.
45362 2019-03-17  Akim Demaille  <akim@lrde.epita.fr>
45364         bitset, timevar: Depend on c99.
45365         Reported by Bruno Haible.
45366         * modules/bitset, modules/timevar (Depends-on): Add c99.
45368 2019-03-16  Akim Demaille  <akim@lrde.epita.fr>
45370         bitset: a bit (...) more tests
45371         * tests/test-bitset.c (check_attributes): Check zero and ones.
45373 2019-03-16  Akim Demaille  <akim@lrde.epita.fr>
45375         bitset: fix overflows.
45376         Reported by Bruno Haible.
45377         https://lists.gnu.org/archive/html/bug-gnulib/2019-03/msg00017.html
45378         * lib/bitset/table.c (tbitset_test): last_bit is the position of
45379         the bit in the array of bitset_word, so be sure to take its modulo
45380         number-of-bits-in-bitset-word (i.e., EBITSET_ELT_WORDS).
45381         * lib/bitset/list.c (lbitset_unused_clear): Likewise.
45383 2019-03-14  Akim Demaille  <akim@lrde.epita.fr>
45385         bitset: style changes.
45386         * lib/bitset/table.c: Use NULL, not 0, for pointers.
45387         Formatting changes.
45388         (tbitset_list): Reduce scopes.
45390 2019-03-16  Bruno Haible  <bruno@clisp.org>
45392         fatal-signal: Pass the signal number to the action.
45393         * lib/fatal-signal.h (at_fatal_signal): Change the signature.
45394         * lib/fatal-signal.c (action_t): Take the signal number as parameter.
45395         (fatal_signal_handler): Pass the signal number to the action.
45396         * lib/clean-temp.c (cleanup_action): Renamed from cleanup. Take the
45397         signal number as parameter.
45398         (create_temp_dir): Update.
45399         * lib/wait-process.c (cleanup_slaves_action): New function.
45400         (register_slave_subprocess): Update at_fatal_signal invocation.
45401         * NEWS: Mention the change.
45403 2019-03-16  Bruno Haible  <bruno@clisp.org>
45405         fatal-signal: Add function that lists the fatal signals.
45406         * lib/fatal-signal.h (get_fatal_signals): New declaration.
45407         * lib/fatal-signal.c (get_fatal_signals): New function.
45409 2019-03-14  Bruno Haible  <bruno@clisp.org>
45411         isatty: Make it return true in Cygwin consoles on native Windows.
45412         * lib/isatty.c: Include <string.h>.
45413         (GetProcAddress): New macro.
45414         (GetNamedPipeClientProcessIdFuncType): New type.
45415         (GetNamedPipeClientProcessIdFunc): New variable.
45416         (QueryFullProcessImageNameFuncType): New type.
45417         (QueryFullProcessImageNameFunc): New variable.
45418         (initialized): New variable.
45419         (initialize): New function.
45420         (IsCygwinConsoleHandle): New function.
45421         (isatty): Invoke it.
45422         * doc/posix-functions/isatty.texi: Mention the issue.
45424 2019-03-14  Bruno Haible  <bruno@clisp.org>
45426         all: Update URLs to msdn.microsoft.com.
45427         * lib/stat-w32.c et al.: Update URLs after most of msdn.microsoft.com
45428         was moved to docs.microsoft.com.
45430 2019-03-13  Bruno Haible  <bruno@clisp.org>
45432         gnulib-tool: Clarify the coding style.
45433         Suggested by Pavel Raiskup <praiskup@redhat.com>.
45434         * gnulib-tool: Add comment about coding style.
45436 2019-03-11  Paul Eggert  <eggert@cs.ucla.edu>
45438         strtod: fix clash with strtold
45439         Problem reported for RHEL 5 by Jesse Caldwell (Bug#34817).
45440         * lib/strtod.c (compute_minus_zero, minus_zero):
45441         Simplify by remving the macro / external variable,
45442         and having just a function.  User changed.  This avoids
45443         the need for an external variable that might clash.
45445 2019-03-10  Bruno Haible  <bruno@clisp.org>
45447         alloca-opt: Fix conflict mingw's new <alloca.h> file.
45448         Reported by Eli Zaretskii <eliz@gnu.org>.
45449         * lib/alloca.in.h: On mingw systems that have <alloca.h>, include that.
45450         * m4/alloca.m4 (gl_FUNC_ALLOCA): Set HAVE_ALLOCA_H.
45451         * modules/alloca-opt (Makefile.am): Substitute HAVE_ALLOCA_H.
45453 2019-03-10  Bruno Haible  <bruno@clisp.org>
45455         tests: Avoid havoc with "gcc -fcheck-pointer-bounds".
45456         * tests/test-fprintf-posix2.c: Skip the test when -fcheck-pointer-bounds
45457         is in use.
45458         * tests/test-printf-posix2.c: Likewise.
45460 2019-03-10  Bruno Haible  <bruno@clisp.org>
45462         uninorm tests: Free allocated memory.
45463         * tests/uninorm/test-u32-normalize-big.h
45464         (struct normalization_test_file): Remove 'const' from allocated member.
45465         (free_normalization_test_file): New declaration.
45466         * tests/uninorm/test-u32-normalize-big.c (test_other): Free allocated
45467         memory.
45468         (free_normalization_test_file): New function.
45469         * tests/uninorm/test-u32-nfc-big.c (main): Free allocated
45470         'struct normalization_test_file' contents.
45471         * tests/uninorm/test-u32-nfd-big.c (main): Likewise.
45472         * tests/uninorm/test-u32-nfkc-big.c (main): Likewise.
45473         * tests/uninorm/test-u32-nfkd-big.c (main): Likewise.
45475 2019-03-10  Bruno Haible  <bruno@clisp.org>
45477         di-set: Fix memory leak.
45478         * lib/di-set.c (di_set_free): Free the ino_map through ino_map_free(),
45479         not free().
45481 2019-03-10  Bruno Haible  <bruno@clisp.org>
45483         tests: Free allocated memory.
45484         Reported by <deltatau@protonmail.com> via Assaf Gordon.
45485         * tests/test-astrxfrm.c (main): Free allocated memory.
45486         * tests/test-bitset.c (compare, check_attributes): Free allocated
45487         bitsets.
45488         * tests/test-filenamecat.c (main): Free allocated memory.
45489         * tests/test-freadahead.c (main): Free allocated memory and close stdin.
45490         * tests/test-freadptr.c (main): Likewise.
45491         * tests/test-freadptr2.c (main): Free allocated memory.
45492         * tests/test-freadseek.c (main): Likewise.
45493         * tests/test-gc-arcfour.c (main): Close allocated context.
45494         * tests/test-gc-arctwo.c (main): Likewise.
45495         * tests/test-gc-des.c (main): Close all allocated contexts.
45496         * tests/test-pipe-filter-gi1.c (main): Free allocated memory.
45497         * tests/test-pipe-filter-ii1.c (main): Likewise.
45498         * tests/test-posix_spawn_file_actions_addchdir.c (main): Destroy the
45499         allocated file actions.
45500         * tests/test-posix_spawn_file_actions_addclose.c (main): Likewise.
45501         * tests/test-posix_spawn_file_actions_adddup2.c (main): Likewise.
45502         * tests/test-posix_spawn_file_actions_addopen.c (main): Likewise.
45503         * tests/test-sameacls.c (main): Free allocated memory and ACLs.
45504         * tests/test-strfmon_l.c (main): Free allocated locales.
45505         * tests/test-striconveh.c (main): Free allocated iconv_t objects.
45506         * tests/uniconv/test-u8-conv-to-enc.c (main): Free allocated memory.
45507         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
45508         * tests/uniconv/test-u32-conv-to-enc.c (main): Likewise.
45509         * tests/unistr/test-chr.h (main): Free input32.
45510         * tests/unistr/test-strchr.h (test_strchr): Likewise.
45512 2019-03-10  Bruno Haible  <bruno@clisp.org>
45514         tests: Prepare for using valgrind.
45515         * tests/*.sh: Invoke all test programs through ${CHECKER}.
45516         * tests/*/*.sh: Likewise.
45517         * tests/test-freadptr.c (main): Update accordingly.
45518         * tests/test-freadseek.c (main): Likewise.
45520 2019-03-09  Bruno Haible  <bruno@clisp.org>
45522         get-rusage-as, pthread_sigmask tests: Fix -fsanitize=thread findings.
45523         * lib/get-rusage-as.c (get_rusage_as): When compiled by
45524         "gcc -fsanitize=thread", don't try get_rusage_as_via_setrlimit.
45525         * tests/test-pthread_sigmask2.c (main): Clean up the killer_thread
45526         before exiting.
45528 2019-03-09  Jim Meyering  <meyering@fb.com>
45530         test-userspec.c: don't print NULL
45531         * tests/test-userspec.c (main): A test release of gcc,
45532         9.0.1 20190310, warned that this test would attempt to
45533         print a NULL pointer via a %s printf format.  Fix that
45534         and remove the unnecessary preceding "!diag" conjunct.
45535         Also add a comment.
45537 2019-03-03  Bruno Haible  <bruno@clisp.org>
45539         getloadavg: Write NULL for the null pointer.
45540         Reported by Michal Privoznik <mprivozn@redhat.com>.
45541         * lib/getloadavg.c (getloadavg): Write NULL instead of 0.
45543 2019-02-28  Michal Privoznik  <mprivozn@redhat.com>
45545         alloca, tsearch-tests: Write NULL for the null pointer.
45546         * lib/alloca.c (i00afunc): Write NULL instead of 0.
45547         * tests/test-tsearch.c (mangle_tree): Likewise.
45549 2019-03-09  Bruno Haible  <bruno@clisp.org>
45551         strfmon_l: Fix -fsanitize=address finding.
45552         * lib/strfmon_l.c: Include <errno.h>, <stdbool.h>, <stdlib.h>,
45553         <string.h>.
45554         (MAX_ARGS): Renamed from MAX_ARG_WORDS.
45555         (directive_t, directives_t): New types.
45556         (fmon_parse): New function.
45557         (rpl_strfmon_l): Don't call va_arg more often than needed for the
45558         format string. Consume 'long double' arguments in places where the
45559         format string indicates so.
45560         * modules/strfmon_l (Depends-on): Add 'stdbool'.
45562 2019-03-09  Bruno Haible  <bruno@clisp.org>
45564         crypto/des: Fix undefined behaviour.
45565         * lib/des.c (READ_64BIT_DATA): Cast bytes to 'unsigned int', to avoid
45566         shift operations on 'int'.
45568 2019-03-09  Bruno Haible  <bruno@clisp.org>
45570         Fix undefined behaviour.
45571         * lib/bitrotate.h (rotl16, rotr16, rotl8, rotr8): Cast x to
45572         'unsigned int', to avoid shift operations on 'int'.
45573         * lib/xmemdup0.c (xmemdup0): Don't invoke memcpy with a zero size.
45574         * tests/test-count-leading-zeros.c (main): Use a random number that has
45575         as many bits as TYPE, not only 2*15 or 2*31 bits.
45576         * tests/test-count-trailing-zeros.c (main): Likewise.
45577         * tests/test-count-one-bits.c (main): Likewise.
45578         * tests/test-memmem.c: Don't include "null-ptr.h".
45579         (main): Use zerosize_ptr() instead of null_ptr().
45580         * modules/memmem-tests (Files): Remove tests/null-ptr.h.
45582 2019-03-08  Bruno Haible  <bruno@clisp.org>
45584         unilbrk/u*-possible-linebreaks: Fix undefined behaviour.
45585         Reported by Jeffrey Walton <noloader@gmail.com>.
45586         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Don't
45587         invoke memset with a zero size.
45588         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
45589         Likewise.
45590         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
45591         Adjust accordingly.
45593 2019-03-08  Bruno Haible  <bruno@clisp.org>
45595         unistr/*, uniconv/*: Fix undefined behaviour.
45596         Reported by Jeffrey Walton <noloader@gmail.com>.
45597         * lib/unistr/u-cpy.h (FUNC): Don't invoke memcpy with a zero size.
45598         * lib/unistr/u-cpy-alloc.h (FUNC): Likewise.
45599         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Likewise.
45600         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
45602 2019-03-08  Bruno Haible  <bruno@clisp.org>
45604         unistr/u8-cmp: Fix undefined behaviour.
45605         Reported by Jeffrey Walton <noloader@gmail.com>.
45606         * lib/unistr/u8-cmp.c (u8_cmp): Don't invoke memcmp if n is zero.
45608 2019-03-08  Bruno Haible  <bruno@clisp.org>
45610         unictype/numeric: Fix undefined behaviour.
45611         Reported by Jeffrey Walton <noloader@gmail.com>.
45612         * lib/unictype/numeric.c (uc_numeric_value): Avoid undefined behaviour
45613         on shift overflow, caught by "gcc -fsanitize=undefined".
45614         * lib/unictype/bidi_of.c (uc_bidi_class): Add cast, for clarity.
45615         * lib/unictype/categ_of.c (lookup_withtable): Likewise.
45616         * lib/unictype/joininggroup_of.c (uc_joining_group): Likewise.
45618 2019-03-05  Paul Eggert  <eggert@cs.ucla.edu>
45620         git-version-gen: fix --version copyright year
45621         * build-aux/git-version-gen, build-aux/move-if-change (version):
45622         --version output copyright year is now taken from script year,
45623         so that it no longer needs to be updated by hand.
45625 2019-03-04  Bruno Haible  <bruno@clisp.org>
45627         relocatable-prog: Use wrapper-free installation on Mac OS X, take 2.
45628         This approach supports relocatable installation of shared libraries
45629         which depend on other shared libraries from the same package.
45630         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Determine use_macos_tools.
45631         If use_macos_tools is true, use reloc-ldflags and set LIBTOOL to be a
45632         wrapper around the original LIBTOOL.
45633         * build-aux/reloc-ldflags: Add support for Mac OS X, which uses the
45634         token '@loader_path' instead of '$ORIGIN'.
45635         * build-aux/libtool-reloc: New file.
45636         * modules/relocatable-prog (Files): Add it.
45637         * doc/relocatable-maint.texi (Supporting Relocation): Update to match
45638         the recent changes. Document the need to set the *_LDFLAGS of libraries.
45639         RELOCATABLE_LIBRARY_PATH and RELOCATABLE_CONFIG_H_DIR should be set in
45640         Makefile.am, not in configure.ac.
45642 2019-03-04  Bruno Haible  <bruno@clisp.org>
45644         relocatable-prog: Revert "Use wrapper-free installation on Mac OS X."
45645         * build-aux/install-reloc: Revert change.
45646         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Likewise.
45648 2019-02-24  Paul Eggert  <eggert@cs.ucla.edu>
45650         nstrftime: support the ‘+’ flag
45651         * lib/nstrftime.c (add, __strftime_internal):
45652         Add support for the ‘+’ flag introduced in POSIX.1-2017.
45653         (__strftime_internal): New arg ‘width’.  All uses changed.
45654         (DO_YEARISH, DO_MAYBE_SIGNED_NUMBER): New macros.
45656 2019-02-24  Bruno Haible  <bruno@clisp.org>
45658         relocatable-prog: Improve verbose output.
45659         * build-aux/install-reloc (func_verbose): Escape characters that would
45660         be interpreted by the shell.
45662 2019-02-24  Bruno Haible  <bruno@clisp.org>
45664         stat, lstat: Fix conflict with relocatable-prog-wrapper module.
45665         * lib/stat.c: On platforms other than OSF/1, include <sys/stat.h>, not
45666         "sys/stat.h".
45667         * lib/lstat.c: Likewise.
45668         * lib/fstat.c: Likewise.
45669         * lib/fstatat.c: Likewise.
45671 2019-02-23  Bernhard Voelker  <mail@bernhard-voelker.de>
45673         long-options: add parse_gnu_standard_options_only
45674         Discussed in https://bugs.gnu.org/33468 .
45676         * lib/long-options.c (parse_long_options): Use EXIT_SUCCESS instead of 0
45677         (parse_gnu_standard_options_only): Add function to process
45678         the GNU default options --help and --version and fail for
45679         any other unknown long or short option. See
45680         https://gnu.org/prep/standards/html_node/Command_002dLine-Interfaces.html
45681         * lib/long-options.h (parse_gnu_standard_options_only): Declare it.
45682         * modules/long-options (depends-on): Add stdbool, exitfail.
45683         * top/maint.mk (sc_prohibit_long_options_without_use): Update
45684         syntax-check rule, add new function name.
45686 2019-02-23  Bruno Haible  <bruno@clisp.org>
45688         relocatable-prog: Update documentation.
45689         * doc/relocatable-maint.texi (Supporting Relocation): Update to match
45690         the recent changes.
45692 2019-02-23  Paul Eggert  <eggert@cs.ucla.edu>
45694         nstrftime: tweak arg order
45695         * lib/nstrftime.c (__strftime_internal): Interchange arg order.
45696         All callers changed.  Suggested by TAMUKI Shoichi in:
45697         https://lists.gnu.org/r/bug-gnulib/2019-02/msg00052.html
45699 2019-02-23  Bruno Haible  <bruno@clisp.org>
45701         relocatable-prog: Use wrapper-free installation also on Mac OS X.
45702         Reported by Paul Smith <psmith@gnu.org>.
45703         * build-aux/install-reloc: Accept a 'mode' argument as first argument.
45704         (func_relativize): New function, from gnulib-tool.
45705         Handle mode 'macosx' through invocations of 'otool' and
45706         'install_name_tool'.
45707         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Determine use_macos_tools.
45708         If use_macos_tools is true, set INSTALL_PROGRAM_ENV to an
45709         'install-reloc' invocation with mode 'macosx'.
45711 2019-02-23  Bruno Haible  <bruno@clisp.org>
45713         relocatable-prog: Use $ORIGIN trick also on GNU/Hurd.
45714         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Use $ORIGIN trick also on
45715         Hurd with glibc >= 2.27.
45717 2019-02-21  Paul Eggert  <eggert@cs.ucla.edu>
45719         nstrftime: merge glibc strftime changes
45720         This incorporates:
45721         2019-02-11 Fix a few whitespace arrangement inconsistencies
45722         2019-01-24 strftime: Pass flags from "%EY" to "%Ey" [BZ #24096]
45723         2019-01-24 Set the default width of "%Ey" to 2 [BZ #23758]
45724         2019-01-11 strftime: use the "L_" macro with character literals
45725         * lib/nstrftime.c (__strftime_internal): New arg yr_spec.  All
45726         callers changed.  Default width of %Ey is now 2.  This is needed
45727         for proper handling of Japanese dates starting on 2019-05-01.
45729 2019-02-19  Bruno Haible  <bruno@clisp.org>
45731         relocatable-prog: Use $ORIGIN trick on more platforms.
45732         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Use $ORIGIN trick also on
45733         FreeBSD >= 7.3, DragonFly >= 3.0, NetBSD >= 8.0, OpenBSD >= 5.4,
45734         Solaris >= 10, Haiku. But don't use it on Android.
45735         * build-aux/reloc-ldflags: Allow the use of the $ORIGIN trick also on
45736         Hurd, FreeBSD, DragonFly, NetBSD, OpenBSD, Solaris, Haiku.
45738 2019-02-19  Bruno Haible  <bruno@clisp.org>
45740         progreloc: Speed up executable lookup on various platforms.
45741         * lib/progreloc.c: Include <errno.h>.
45742         (safe_read, full_read): New functions.
45743         (find_executable): On GNU/kFreeBSD, FreeBSD, DragonFly, NetBSD, Solaris,
45744         prefer the information from the /proc file system to a PATH search.
45746 2019-02-19  Bruno Haible  <bruno@clisp.org>
45748         progreloc: Simplify code for Android.
45749         * lib/progreloc.c (executable_fd): Don't define on Android.
45750         (maybe_executable, find_executable): Don't use executable_fd on Android.
45752 2019-02-15  Bruno Haible  <bruno@clisp.org>
45754         gnulib-tool: Support --import with just a few tests, not --with-tests.
45755         * gnulib-tool (func_import): New variable 'gentests'. Use it instead of
45756         'inctests' when generating files; use 'inctests' only for computing the
45757         transitive closure.
45759 2019-02-14  Bruno Haible  <bruno@clisp.org>
45761         gnulib-tool: Improve handling of multiple --local-dir options.
45762         * doc/gnulib.texi (Extending Gnulib): Explain how multiple --local-dir
45763         options work.
45764         * gnulib-tool (func_path_prepend): Remove function.
45765         (func_path_foreach): Make IFS handling more robust.
45766         (local_gnulib_path): Collect --local-dir values using func_path_append,
45767         not func_path_prepend.
45768         (func_determine_path_separator): Make IFS handling more robust.
45769         (func_lookup_file_cb): New function.
45770         (func_lookup_file): Rewritten to use func_lookup_file_cb instead of
45771         func_lookup_local_file. Apply the patches in the reverse order of their
45772         origin in $local_gnulib_path.
45773         (func_count_relative_local_gnulib_path): Make IFS handling more robust.
45774         * NEWS: Mention that the first --local-dir option is the one with
45775         highest priority.
45777 2019-02-10  Bruno Haible  <bruno@clisp.org>
45779         libtextstyle: New module.
45780         * m4/libtextstyle.m4: New file.
45781         * modules/libtextstyle: New file.
45783 2019-02-05  Bruno Haible  <bruno@clisp.org>
45785         declared.sh: Fix bug with variables of pointer type.
45786         * build-aux/declared.sh (sed_extract_extern_declared): Allow the space
45787         before the symbol to be omitted if the preceding character is a '*'.
45789 2019-02-04  Bruno Haible  <bruno@clisp.org>
45791         Add script for running tests under valgrind.
45792         * build-aux/run-test: New file, from GNU libunistring.
45793         * doc/valgrind-tests.texi: Rewritten to mention alternative approaches
45794         as well.
45796 2019-02-04  Bruno Haible  <bruno@clisp.org>
45798         declared.sh: Fix --version output.
45799         * build-aux/declared.sh (func_version): Update package name.
45801 2019-02-03  Bruno Haible  <bruno@clisp.org>
45803         Add script for determining the set of symbols to export from a library.
45804         * build-aux/declared.sh: New file, from GNU libunistring.
45805         * doc/lib-symbol-visibility.texi (Exported Symbols of Shared Libraries):
45806         Mention it.
45808 2019-02-02  Paul Eggert  <eggert@cs.ucla.edu>
45810         vla: add commentary about VLA_ELEMS
45811         * lib/vla.h (VLA_ELEMS): Add commentary,
45812         some inspired by Bruno Haible’s proposal in:
45813         https://lists.gnu.org/r/bug-gnulib/2019-01/msg00109.html
45815         dtoastr,ftoastr,ldtoastr: port to c-strtod changes
45816         Decouple these modules from c-strtod.  Nowadays it’s reasonable to
45817         assume the C99 signatures for strtod and strtold.  Programs that
45818         require stricter adherence to C99 should also use the strtod and
45819         strtold modules as needed, and we no longer need the
45820         HAVE_C99_STRTOLD macro.
45821         * NEWS: Mention this.
45822         * lib/ftoastr.c (STRTOF) [LENGTH == 3]: Assume strtold.
45823         * m4/c-strtod.m4 (gl_C_STRTOLD): Do not define HAVE_C99_STRTOLD.
45824         * modules/dtoastr, modules/ftoastr, modules/ldtoastr:
45825         (Files): Remove m4/c-strtod.m4.
45826         (configure.ac): Do not require gl_C99_STRTOLD, which no longer
45827         exists.
45829 2019-02-02  Bruno Haible  <bruno@clisp.org>
45831         fma: Improve code style.
45832         * lib/fma.c: Include <limits.h>, for CHAR_BIT.
45834 2019-02-02  Colin Watson  <cjwatson@debian.org>
45836         *-map tests: Fix compilation error.
45837         * tests/test-array_map.c: Include <limits.h>, for CHAR_BIT.
45838         * tests/test-hash_map.c: Likewise.
45839         * tests/test-linkedhash_map.c: Likewise.
45841 2019-01-31  Bruno Haible  <bruno@clisp.org>
45843         c-strtod, c-strtold: Use the bug fixes for strtod, strtold.
45844         * lib/stdlib.in.h (GNULIB_defined_strtod_function,
45845         GNULIB_defined_strtold_function): New macros.
45846         * lib/c-strtod.c (HAVE_GOOD_STRTOD_L): New macro.
45847         (STRTOD): Ignore HAVE_C99_STRTOLD.
45848         (c_locale): Don't define it on platforms where strtod_l/strtold_l is
45849         deemed buggy. But do use it on platforms where uselocale exists and is
45850         usable.
45851         (C_STRTOD): Don't use STRTOD_L on platforms where strtod_l/strtold_l is
45852         deemed buggy. On platforms where uselocale exists and is usable, use
45853         uselocale and strtod/strtold.
45854         * m4/c-strtod.m4 (gl_C99_STRTOLD): Remove macro.
45855         (gl_C_STRTOD): Require gt_FUNC_USELOCALE.
45856         (gl_C_STRTOLD): Likewise. Define HAVE_C99_STRTOLD unconditionally.
45857         * modules/c-strtod (Files): Add m4/intl-thread-locale.m4.
45858         (Depends-on): Add strtod.
45859         * modules/c-strtold (Files): Add m4/intl-thread-locale.m4.
45860         (Depends-on): Add strtold.
45862 2019-01-31  Bruno Haible  <bruno@clisp.org>
45864         strtod, strtold: Use the locale's decimal point.
45865         * lib/strtod.c: Include <locale.h>, <stdio.h>, <langinfo.h>.
45866         (decimal_point_char): New function, copied from lib/vasnprintf.c.
45867         (parse_number): Add a radixchar argument. Use it instead of '.'.
45868         (STRTOD): Invoke decimal_point_char and pass the result to parse_number.
45869         * m4/strtod.m4 (gl_PREREQ_STRTOD): Test whether nl_langinfo exists.
45870         * m4/strtold.m4 (gl_PREREQ_STRTOLD): Likewise.
45871         * tests/test-strtod1.c: New file.
45872         * tests/test-strtod1.sh: New file.
45873         * modules/strtod-tests (Files): Add test-strtod1.{sh,c}. Add
45874         locale-fr.m4 and its dependencies.
45875         (configure.ac): Invoke gt_LOCALE_FR, gt_LOCALE_FR_UTF8.
45876         (Makefile.am): Arrange to compile test-strtod1.c and run
45877         test-strtod1.sh.
45878         * tests/test-strtold1.c: New file.
45879         * tests/test-strtold1.sh: New file.
45880         * modules/strtold-tests (Files): Add test-strtold1.{sh,c}. Add
45881         locale-fr.m4 and its dependencies.
45882         (configure.ac): Invoke gt_LOCALE_FR, gt_LOCALE_FR_UTF8.
45883         (Makefile.am): Arrange to compile test-strtold1.c and run
45884         test-strtold1.sh.
45886 2019-01-31  Bruno Haible  <bruno@clisp.org>
45888         strtod, strtold tests: Simplify tests.
45889         * tests/test-strtod.c (main): Assume no rounding errors for 0.5.
45890         * tests/test-strtold.c (main): Likewise.
45892 2019-01-31  Bruno Haible  <bruno@clisp.org>
45894         strtod, strtold: Avoid unnecessary rounding errors.
45895         * lib/strtod.c (parse_number): Drop trailing zeroes before doing the
45896         decimal to DOUBLE conversion.
45898 2019-01-31  Bruno Haible  <bruno@clisp.org>
45900         strtod, strtold: Work around HP-UX 11.31/ia64 bug.
45901         * lib/strtod.c (STRTOD): When there is an extra character after the
45902         exponent marker 'p', reparse the number.
45903         * doc/posix-functions/strtod.texi: Document the HP-UX 11.31 bug.
45904         * doc/posix-functions/strtold.texi: Likewise.
45906 2019-01-29  Bruno Haible  <bruno@clisp.org>
45908         strtold: Add tests.
45909         * tests/test-strtold.c: New file, based on tests/test-strtod.c.
45910         * modules/strtold-tests: New file.
45912 2019-01-29  Bruno Haible  <bruno@clisp.org>
45914         strtold: New module.
45915         * lib/stdlib.in.h (strtold): New declaration.
45916         * lib/strtold.c: New file.
45917         * lib/strtod.c: Consider USE_LONG_DOUBLE.
45918         (STRTOD, LDEXP, HAVE_UNDERLYING_STRTOD, DOUBLE, MIN, MAX, L_,
45919         USE_LDEXP): New macros.
45920         (LDEXP, scale_radix_exp, parse_number, STRTOD): Adapt for
45921         USE_LONG_DOUBLE.
45922         (underlying_strtod): Remove function. Replace with some macros.
45923         Re-add the code for a missing underlying function that was removed on
45924         2013-02-19.
45925         * m4/strtold.m4: New file.
45926         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtold is declared.
45927         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOLD, HAVE_STRTOLD,
45928         REPLACE_STRTOLD.
45929         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOLD, HAVE_STRTOLD,
45930         REPLACE_STRTOLD.
45931         * modules/strtold: New file.
45932         * doc/posix-functions/strtold.texi: Document the new module.
45934 2019-01-29  Bruno Haible  <bruno@clisp.org>
45936         strtod: Fix compilation error on IRIX 6.5.
45937         * modules/strtod (Depends-on): Add 'math'.
45939 2019-01-28  Bruno Haible  <bruno@clisp.org>
45941         Fix build error when building a shared libunistring on Android.
45942         * tests/uninorm/test-nfc.c (n): Don't define on Android.
45943         (main): Add 'volatile', to defeat a GCC optimization that would
45944         eliminate the reference.
45945         * tests/uninorm/test-nfd.c (n): Don't define on Android.
45946         (main): Add 'volatile', to defeat a GCC optimization that would
45947         eliminate the reference.
45948         * tests/uninorm/test-nfkc.c (n): Don't define on Android.
45949         (main): Add 'volatile', to defeat a GCC optimization that would
45950         eliminate the reference.
45951         * tests/uninorm/test-nfkd.c (n): Don't define on Android.
45952         (main): Add 'volatile', to defeat a GCC optimization that would
45953         eliminate the reference.
45955 2019-01-27  Bruno Haible  <bruno@clisp.org>
45957         Avoid build errors due to wrong references between modules.
45958         * lib/uninorm/canonical-decomposition.c: Include
45959         "uninorm/decomposition-table.h", not "decomposition-table.h".
45960         * lib/uninorm/decomposition.c: Likewise.
45961         * lib/uninorm/u8-normalize.c: Include "uninorm/decompose-internal.h",
45962         not "decompose-internal.h".
45963         * lib/uninorm/u16-normalize.c: Likewise.
45964         * lib/uninorm/u32-normalize.c: Likewise.
45965         * lib/uninorm/uninorm-filter.c: Likewise.
45966         * lib/uninorm/nfkc.c: Likewise.
45967         * lib/uninorm/nfkd.c: Likewise.
45968         * lib/unicase/u8-casemap.c: Include "unicase/caseprop.h", not
45969         "caseprop.h".
45970         * lib/unicase/u8-ct-totitle.c: Likewise.
45971         * lib/unicase/u8-prefix-context.c: Likewise.
45972         * lib/unicase/u8-suffix-context.c: Likewise.
45973         * lib/unicase/u16-casemap.c: Likewise.
45974         * lib/unicase/u16-ct-totitle.c: Likewise.
45975         * lib/unicase/u16-prefix-context.c: Likewise.
45976         * lib/unicase/u16-suffix-context.c: Likewise.
45977         * lib/unicase/u32-casemap.c: Likewise.
45978         * lib/unicase/u32-ct-totitle.c: Likewise.
45979         * lib/unicase/u32-prefix-context.c: Likewise.
45980         * lib/unicase/u32-suffix-context.c: Likewise.
45981         * lib/unicase/u8-tolower.c: Include "unicase/unicasemap.h", not
45982         "unicasemap.h".
45983         * lib/unicase/u8-toupper.c: Likewise.
45984         * lib/unicase/u8-ct-tolower.c: Likewise.
45985         * lib/unicase/u8-ct-toupper.c: Likewise.
45986         * lib/unicase/u16-tolower.c: Likewise.
45987         * lib/unicase/u16-toupper.c: Likewise.
45988         * lib/unicase/u16-ct-tolower.c: Likewise.
45989         * lib/unicase/u16-ct-toupper.c: Likewise.
45990         * lib/unicase/u32-tolower.c: Likewise.
45991         * lib/unicase/u32-toupper.c: Likewise.
45992         * lib/unicase/u32-ct-tolower.c: Likewise.
45993         * lib/unicase/u32-ct-toupper.c: Likewise.
45994         * lib/unicase/u8-ct-casefold.c: Include "unicase/unicasemap.h", not
45995         "unicasemap.h", and "unicase/casefold.h", not "casefold.h".
45996         * lib/unicase/u16-ct-casefold.c: Likewise.
45997         * lib/unicase/u32-ct-casefold.c: Likewise.
45999 2019-01-27  Bruno Haible  <bruno@clisp.org>
46001         gperf: Fix error when this module is required by some test module.
46002         * modules/gperf (Applicability): Set to 'all'.
46004 2019-01-27  Bruno Haible  <bruno@clisp.org>
46006         tmpfile: Add support for Android.
46007         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Add a runtime test whether tmpfile()
46008         works.
46009         * lib/tmpfile.c (tmpfile): Add an alternative implementation for
46010         Android.
46011         * modules/tmpfile (Depends-on): Add 'stdbool'.
46012         * doc/posix-functions/tmpfile.texi: Mention the Android bug.
46013         * modules/argv-iter-tests (Depends-on): Add 'tmpfile'.
46015 2019-01-27  Akim Demaille  <akim@lrde.epita.fr>
46017         bitsetv: allow free on NULL.
46018         * lib/bitsetv.c (bitsetv_free): Do nothing when the bitsetv is NULL.
46020 2019-01-27  Bruno Haible  <bruno@clisp.org>
46022         test-framework-sh: Improve maintainability.
46023         * tests/init.sh: Clarify what belongs together. Reorder definitions.
46025 2019-01-27  Bruno Haible  <bruno@clisp.org>
46027         tests: Don't assume that /tmp exists.
46028         * tests/test-set-mode-acl-1.sh: Skip the test if /tmp does not exist.
46029         * tests/test-copy-acl-1.sh: Likewise.
46030         * tests/test-file-has-acl-1.sh: Likewise.
46031         * tests/test-copy-file-1.sh: Likewise.
46033 2019-01-27  Bruno Haible  <bruno@clisp.org>
46035         tests: Accommodate a shell that is not in /bin/sh.
46036         * tests/init.sh (setup_): Set srcdir and builddir.
46037         (BOURNE_SHELL): New variable.
46038         * modules/acl-tests (Depends-on): Add 'test-framework-sh'.
46039         * modules/file-has-acl-tests (Depends-on): Likewise.
46040         * modules/copy-file-tests (Depends-on): Likewise.
46041         * tests/test-set-mode-acl-1.sh: Use the test framework. Invoke shell
46042         scripts through $BOURNE_SHELL.
46043         * tests/test-set-mode-acl-2.sh: Likewise.
46044         * tests/test-copy-acl-1.sh: Likewise.
46045         * tests/test-copy-acl-2.sh: Likewise.
46046         * tests/test-file-has-acl-1.sh: Likewise.
46047         * tests/test-file-has-acl-2.sh: Likewise.
46048         * tests/test-copy-file-1.sh: Likewise.
46049         * tests/test-copy-file-2.sh: Likewise.
46050         * tests/test-set-mode-acl.sh (builddir): Consider value set by the
46051         invoker.
46052         * tests/test-copy-acl.sh (builddir): Likewise.
46053         * tests/test-file-has-acl.sh (builddir): Likewise.
46054         * tests/test-copy-file.sh (builddir): Likewise.
46055         * tests/test-vc-list-files-cvs.sh: Don't create shims for executables in
46056         build-aux/. Instead, invoke shell scripts through $BOURNE_SHELL.
46057         * tests/test-vc-list-files-git.sh: Likewise.
46059 2019-01-27  Bruno Haible  <bruno@clisp.org>
46061         tests: Fix some "unused variable" warnings.
46062         * tests/test-fts.c (fts_dealloc): Remove unused variable.
46063         * tests/unigbrk/test-uc-grapheme-breaks.c (main): Likewise.
46064         * tests/test-striconveh.c (main): Move some variable into the
46065         '#if HAVE_ICONV'.
46066         * tests/test-striconveha.c (main): Likewise.
46067         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
46068         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
46069         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
46070         * tests/uniconv/test-u8-conv-to-enc.c (main): Likewise.
46071         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
46072         * tests/uniconv/test-u32-conv-to-enc.c (main): Likewise.
46073         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
46074         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
46075         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
46076         * tests/uniconv/test-u8-strconv-to-enc.c (main): Likewise.
46077         * tests/uniconv/test-u16-strconv-to-enc.c (main): Likewise.
46078         * tests/uniconv/test-u32-strconv-to-enc.c (main): Likewise.
46079         * tests/test-tsearch.c (main): Move some variable into the
46080         '#if HAVE_INITSTATE'.
46082 2019-01-27  Bruno Haible  <bruno@clisp.org>
46084         unigbrk/uc-grapheme-breaks: Fix build failure.
46085         * lib/unigbrk/uc-grapheme-breaks.c: Don't include unistr.h.
46086         * modules/unigbrk/uc-grapheme-breaks (Makefile.am): Fix typo.
46088 2019-01-27  Bruno Haible  <bruno@clisp.org>
46090         mountlist: Merge two .m4 files.
46091         * m4/mountlist.m4 (gl_MOUNTLIST): Inline gl_LIST_MOUNTED_FILE_SYSTEMS.
46092         (AC_FUNC_GETMNTENT): Move to here, from m4/ls-mntd-fs.m4.
46093         * m4/ls-mntd-fs.m4: Remove file.
46094         * modules/mountlist (Files): Remove m4/ls-mntd-fs.m4.
46096 2019-01-27  Bruno Haible  <bruno@clisp.org>
46098         tests: Enable Linux specific tests on Android.
46099         * tests/test-flock.c (main): Treat Android like Linux.
46100         * tests/test-openat-safer.c (main): Likewise.
46102 2019-01-27  Bruno Haible  <bruno@clisp.org>
46104         relocatable-prog: Use Linux code on Android.
46105         * lib/progreloc.c: Treat Android like Linux.
46107 2019-01-26  Bruno Haible  <bruno@clisp.org>
46109         getloadavg: Add support for Android.
46110         * lib/getloadavg.c: Treat Android like Linux.
46112 2019-01-26  Bruno Haible  <bruno@clisp.org>
46114         vma-iter: Add support for Android.
46115         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define on Android as well.
46116         * lib/vma-iter.c: Treat Android like Linux.
46117         * lib/get-rusage-data.c (get_rusage_data): Likewise.
46119 2019-01-26  Bruno Haible  <bruno@clisp.org>
46121         fts: Optimize on Android.
46122         * lib/fts.c: Treat Android like Linux.
46124 2019-01-26  Bruno Haible  <bruno@clisp.org>
46126         fts: Add support for Android.
46127         * m4/fts.m4 (gl_FUNC_FTS_CORE): Avoid conflicts between the symbols
46128         defined by this module and the ones in libc.
46129         * tests/test-fts.c (main): Treat mkdir error EMLINK like EMFILE.
46131 2019-01-26  Bruno Haible  <bruno@clisp.org>
46133         mountlist: Use Linux code on Android.
46134         * lib/mountlist.c (setmntent, endmntent): Define fallbacks.
46135         (unescape_tab, read_file_system_list): Enable Linux code on Android
46136         as well.
46137         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Test for setmntent
46138         and endmntent.
46139         * modules/mountlist (Depends-on): Add 'getline'.
46141 2019-01-26  Bruno Haible  <bruno@clisp.org>
46143         localename tests: Fix test failure on Android.
46144         * modules/localename-tests (Depends-on): Add 'setlocale'.
46146 2019-01-26  Bruno Haible  <bruno@clisp.org>
46148         mountlist: Port better to Android.
46149         * lib/mountlist.c (MOUNTED): Redefine on Android.
46150         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Redefine MOUNTED on
46151         Android.
46153 2019-01-26  Bruno Haible  <bruno@clisp.org>
46155         striconveh: Fix use of uninitialized iconv_t.
46156         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
46157         <https://lists.gnu.org/archive/html/bug-libunistring/2019-01/msg00000.html>.
46158         * lib/striconveh.c (iconveh_open): Correct the iconv_close argument.
46160 2019-01-26  Bruno Haible  <bruno@clisp.org>
46162         nonblocking-socket-tests: Fix test failure on Android 4.3.
46163         * tests/test-nonblocking-socket.h (SOCKET_HAS_LARGE_BUFFER): Define to 1
46164         also on Android.
46166 2019-01-26  Bruno Haible  <bruno@clisp.org>
46168         sh-filename: Add support for Android 4.3.
46169         * m4/sh-filename.m4 (gl_SH_FILENAME): Set to "sh" on Android.
46171 2019-01-26  Bruno Haible  <bruno@clisp.org>
46173         ptsname_r: Work around bug on Android 4.3.
46174         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Define
46175         HAVE_ESSENTIALLY_WORKING_PTSNAME_R. Test whether the return value is
46176         correct.
46177         * lib/ptsname_r.c (__ptsname_r): If HAVE_ESSENTIALLY_WORKING_PTSNAME_R
46178         is defined, just fix the return value.
46179         * doc/glibc-functions/ptsname_r.texi: Mention the Android bug. Reword:
46180         The behaviour of musl libc is nothing to be "fixed", since it is
46181         compliant with the next POSIX standard.
46183 2019-01-26  Bruno Haible  <bruno@clisp.org>
46185         ttyname_r: Work around bug on Android 4.3.
46186         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test whether ttyname_r is a stub.
46187         * lib/ttyname_r.c (ttyname_r): Implement for Android.
46188         * doc/posix-functions/ttyname_r.texi: Mention the Android bug.
46189         * doc/posix-functions/ttyname.texi: Likewise.
46191 2019-01-25  Bruno Haible  <bruno@clisp.org>
46193         getprogname: Port to Android 4.3.
46194         * lib/getprogname.c (getprogname): On Android, take only the last
46195         component of __progname.
46197 2019-01-25  Bruno Haible  <bruno@clisp.org>
46199         wcrtomb: Work around bug on Android 4.3.
46200         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Test also whether wcrtomb works in
46201         the C locale.
46202         * lib/wcrtomb.c (wcrtomb): Provide alternate implementation for Android,
46203         which does not have the 'wctomb' function.
46204         * doc/posix-functions/wcrtomb.texi: Mention the Android bug.
46205         * tests/test-wcrtomb.c (main): Accept argument '5'.
46206         * tests/test-wcrtomb.sh: Add tests in the POSIX locale.
46208 2019-01-25  Bruno Haible  <bruno@clisp.org>
46210         setlocale: Work around bug on Android 4.3.
46211         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Test whether setlocale supports
46212         the "C" locale.
46213         * lib/setlocale.c (setlocale_unixlike): New wrapper for Android.
46214         * doc/posix-functions/setlocale.texi: Mention the Android bug.
46216 2019-01-24  Bruno Haible  <bruno@clisp.org>
46218         memchr: Work around bug on Android <= 5.0.
46219         * m4/memchr.m4 (gl_FUNC_MEMCHR): Add test against the Android bug.
46220         * doc/posix-functions/memchr.texi: Mention the Android bug.
46222 2019-01-24  Bruno Haible  <bruno@clisp.org>
46224         random: Fix compilation error on Android 4.3.
46225         * lib/stdlib.in.h (random, srandom): Test also REPLACE_RANDOM.
46226         (initstate): Test REPLACE_INITSTATE and HAVE_INITSTATE, not HAVE_RANDOM.
46227         (setstate): Test REPLACE_SETSTATE and HAVE_SETSTATE, not HAVE_RANDOM.
46228         * m4/random.m4 (gl_FUNC_RANDOM): Set HAVE_INITSTATE, HAVE_SETSTATE,
46229         REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
46230         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_INITSTATE,
46231         HAVE_SETSTATE, REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
46232         * modules/stdlib (Makefile.am): Substitute HAVE_INITSTATE, HAVE_SETSTATE,
46233         REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
46234         * modules/random (Depends-on, configure.ac): Test also REPLACE_RANDOM,
46235         REPLACE_INITSTATE, REPLACE_SETSTATE.
46236         * doc/posix-functions/random.texi: Correct the description of the
46237         situation on Android.
46238         * doc/posix-functions/srandom.texi: Likewise.
46239         * doc/posix-functions/rand.texi: Likewise.
46240         * doc/posix-functions/srand.texi: Likewise.
46242 2019-01-24  Bruno Haible  <bruno@clisp.org>
46244         mbtowc: Fix compilation error on Android 4.3.
46245         * lib/stdlib.in.h (mbtowc): Test also HAVE_MBTOWC.
46246         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Test whether mbtowc exists. Set
46247         HAVE_MBTOWC.
46248         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether mbtowc is declared.
46249         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_MBTOWC.
46250         * modules/stdlib (Makefile.am): Substitute HAVE_MBTOWC.
46251         * modules/mbtowc (Depends-on, configure.ac): Test also HAVE_MBTOWC.
46252         * doc/posix-functions/mbtowc.texi: Mention the change.
46254 2019-01-24  Bruno Haible  <bruno@clisp.org>
46256         fdatasync: Fix compilation error on Android 4.3.
46257         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): On platforms other than Solaris,
46258         test whether fdatasync() exists.
46260 2019-01-24  Bruno Haible  <bruno@clisp.org>
46262         unlinkat: Fix compilation error on Android 4.3.
46263         * lib/unistd.in.h: Include <fcntl.h> when module 'unlinkat' is in use
46264         also on Android.
46265         * doc/posix-functions/unlinkat.texi: Mention the issue.
46267 2019-01-24  Bruno Haible  <bruno@clisp.org>
46269         renameat: Fix compilation error on Android 4.3.
46270         * lib/stdio.in.h: Include <sys/stat.h> when module 'renameat' is in use.
46271         * doc/posix-functions/renameat.texi: Mention the issue.
46273 2019-01-24  Bruno Haible  <bruno@clisp.org>
46275         fchownat: Fix compilation error on Android 4.3.
46276         * lib/unistd.in.h: Include <sys/stat.h> when module 'fchownat' is in
46277         use.
46278         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG,
46279         gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Include also <sys/stat.h>.
46280         * doc/posix-functions/fchownat.texi: Mention the issue.
46282 2019-01-23  Bruno Haible  <bruno@clisp.org>
46284         gnulib-tool: Support running testdirs on Android.
46285         * build-aux/test-driver.diff: New file.
46286         * gnulib-tool (func_create_testdir, func_create_megatestdir): Patch
46287         build-aux/test-driver after running automake.
46289 2019-01-23  Akim Demaille  <akim@lrde.epita.fr>
46291         relocatable-prog: avoid warnings from Automake
46292         * modules/relocatable-prog: Don't declare PHONY dependencies in
46293         Automake conditionals.
46295 2019-01-23  Akim Demaille  <akim@lrde.epita.fr>
46297         array-list: Pacify warnings about unused arguments (-Wunused-parameter).
46298         * lib/gl_array_list.c (gl_array_iterator_free): "Use" the argument.
46300 2019-01-23  Bruno Haible  <bruno@clisp.org>
46302         threadlib: Revert commit from 2018-06-25. We now have a better fix.
46303         * m4/threadlib.m4 (gl_THREADLIB_BODY): Don't attempt to defeat a
46304         preceding -Wl,--as-needed option. Don't check whether the linker
46305         supports --as-needed/--no-as-needed and --push-state/--pop-state.
46307 2019-01-23  Bruno Haible  <bruno@clisp.org>
46309         thread: Force linking with -lpthread, even when --as-needed is in use.
46310         Reported by Richard W.M. Jones <rjones@redhat.com> in
46311         <https://lists.gnu.org/archive/html/bug-gnulib/2019-01/msg00123.html>.
46312         * lib/glthread/thread.h (pthread_create): Don't declare weak.
46314 2019-01-23  Akim Demaille  <akim.demaille@gmail.com>
46315             Bruno Haible  <bruno@clisp.org>
46317         relocatable: avoid compiler warnings (-Wshadow)
46318         * lib/relocatable.c (compute_curr_prefix): Rename local variables
46319         to avoid name collisions with global variables.
46321 2019-01-22  Bruno Haible  <bruno@clisp.org>
46323         vasnprintf: Don't use %n on Android.
46324         Reported and fix suggested by Hugo Beauzée-Luyssen <hugo@beauzee.fr> in
46325         <https://lists.gnu.org/archive/html/bug-gnulib/2018-12/msg00123.html>.
46326         * lib/vasnprintf.c (VASNPRINTF): Don’t use %n on Android.
46328 2019-01-22  Bruno Haible  <bruno@clisp.org>
46330         *printf: Support cross-compilation to Android.
46331         * m4/printf.m4: Add cross-compilation guesses for Android.
46333 2019-01-21  Bruno Haible  <bruno@clisp.org>
46335         diacrit: Mark deprecated.
46336         * modules/diacrit (Status, Notice): Mark as deprecated.
46337         * NEWS: Mention it.
46339 2019-01-20  Bruno Haible  <bruno@clisp.org>
46341         rintl: Override broken implementation on NetBSD.
46342         * lib/math.in.h (rintl): Test also REPLACE_RINTL.
46343         * m4/rintl.m4 (gl_FUNC_RINTL): Add test for negative arguments. Set
46344         REPLACE_RINTL.
46345         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_RINTL.
46346         * modules/math (Makefile.in): Substitute REPLACE_RINTL.
46347         * modules/rintl (Depends-on, configure.ac): Test REPLACE_RINTL.
46348         * doc/posix-functions/rintl.texi: Mention the NetBSD bug.
46350 2019-01-20  Bruno Haible  <bruno@clisp.org>
46352         log10l: Work around inaccurate implementation on NetBSD.
46353         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Add test for a certain accuracy.
46354         * lib/log10l.c: Comment out too simplistic override.
46355         * doc/posix-functions/log10l.texi: Mention the NetBSD bug.
46357 2019-01-20  Bruno Haible  <bruno@clisp.org>
46359         logl: Work around inaccurate implementation on NetBSD.
46360         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Add test for a certain accuracy.
46361         * lib/logl.c: Comment out unused code.
46362         * doc/posix-functions/logl.texi: Mention the NetBSD bug.
46364 2019-01-20  Bruno Haible  <bruno@clisp.org>
46366         expm1l: Work around inaccurate implementation on NetBSD.
46367         * lib/math.in.h (expm1l): Test also REPLACE_EXPM1L.
46368         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Add test for a certain accuracy. Set
46369         REPLACE_EXPM1L.
46370         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPM1L.
46371         * modules/math (Makefile.in): Substitute REPLACE_EXPM1L.
46372         * modules/expm1l (Depends-on, configure.ac): Test REPLACE_EXPM1L.
46373         * doc/posix-functions/expm1l.texi: Mention the NetBSD bug.
46375 2019-01-20  Bruno Haible  <bruno@clisp.org>
46377         expl: Work around inaccurate implementation on NetBSD.
46378         * lib/math.in.h (expl): Test also REPLACE_EXPL.
46379         * m4/expl.m4 (gl_FUNC_EXPL): Add test for a certain accuracy. Set
46380         REPLACE_EXPL.
46381         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPL.
46382         * modules/math (Makefile.in): Substitute REPLACE_EXPL.
46383         * modules/expl (Depends-on, configure.ac): Test REPLACE_EXPL.
46384         * doc/posix-functions/expl.texi: Mention the NetBSD bug.
46386 2019-01-20  Bruno Haible  <bruno@clisp.org>
46388         exp2l: Work around inaccurate implementation on NetBSD.
46389         * m4/exp2l.m4 (gl_FUNC_EXP2L): Add test for a certain accuracy.
46390         * doc/posix-functions/exp2l.texi: Mention the NetBSD bug.
46392 2019-01-20  Bruno Haible  <bruno@clisp.org>
46394         floor, floorl: Avoid autoconf warnings.
46395         * modules/floor (configure.ac): Use AC_REQUIRE.
46396         * modules/floorl (configure.ac): Likewise.
46398 2019-01-20  Bruno Haible  <bruno@clisp.org>
46400         Defeat current GCC optimizations in math autoconf tests.
46401         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Mark function pointer as 'volatile'.
46402         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
46403         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
46404         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
46405         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
46406         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
46407         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
46408         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
46409         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
46410         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
46411         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
46412         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
46413         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
46414         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
46415         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Likewise.
46416         * m4/ilogbf.m4 (gl_FUNC_ILOGBF_WORKS): Likewise.
46417         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Likewise.
46418         * m4/log.m4 (gl_FUNC_LOG): Likewise.
46419         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
46420         * m4/log10.m4 (gl_FUNC_LOG10): Likewise.
46421         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
46422         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
46423         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Likewise.
46424         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Likewise.
46425         * m4/log2.m4 (gl_FUNC_LOG2): Likewise.
46426         * m4/log2f.m4 (gl_FUNC_LOG2F): Likewise.
46427         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
46428         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
46429         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
46430         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
46431         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
46432         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
46433         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
46434         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
46435         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
46436         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
46437         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
46438         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
46440 2019-01-19  Pádraig Brady  <P@draigBrady.com>
46442         gettext: support disabling use of VLAs
46443         * lib/gettext.h: Disable use of VLAs if GNULIB_NO_VLA is defined
46445 2019-01-17  KO Myung-Hun  <komh78@gmail.com>
46447         sys_stat: Fix 'implicit declaration of function' warning on OS/2 kLIBC.
46448         * lib/sys_stat.in.h [kLIBC]: Include <unistd.h>.
46450 2019-01-17  KO Myung-Hun  <komh78@gmail.com>
46452         fcntl: Fix syntax error (regression from 2018-10-05).
46453         * lib/fcntl.c (klibc_fcntl): Remove mis-placed ';'.
46455 2019-01-13  Akim Demaille  <akim@lrde.epita.fr>
46457         relocatable: improve documentation.
46458         * doc/relocatable-maint.texi (Supporting Relocation): For
46459         substitutions performed by config.status, we need more variables
46460         (for instance datarootdir defaults to '${prefix}/share' so we need
46461         prefix).
46463 2019-01-13  Akim Demaille  <akim@lrde.epita.fr>
46465         backup: update dependencies
46466         * modules/backup-rename (Depends-on): It now depends on opendirat
46467         instead of opendir.  It also uses stdint, and xalloc-oversized.
46468         But no longer dirfd.
46469         * modules/backupfile (Depends-on): Add xalloc-oversized.
46471 2019-01-13  Bruno Haible  <bruno@clisp.org>
46473         getcwd: Fix test failure when building on a Linux 9p file system.
46474         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): On Linux, treat error
46475         EINVAL from mkdir like ENAMETOOLONG.
46476         * tests/test-getcwd.c (test_long_name): Likewise.
46478 2019-01-12  Tim Rühsen  <tim.ruehsen@gmx.de>
46480         Fix typos found by codespell.
46481         * lib/*.[hc]: Fix typos in comments.
46482         * pygnulib/*.py: Fix typos in error messages and comments.
46484 2019-01-12  Bruno Haible  <bruno@clisp.org>
46486         doc: Fix documentation about container data types.
46487         Reported by Werner Lemberg <wl@gnu.org>.
46488         * doc/containers.texi (Container data types): Fix typo.
46490 2019-01-10  Bruno Haible  <bruno@clisp.org>
46492         verify: Enable _GL_HAVE_STATIC_ASSERT for recent G++ versions.
46493         Reported by Reuben Thomas <rrt@sc3d.org>.
46494         * lib/verify.h (_GL_HAVE_STATIC_ASSERT): Define for g++ versions >= 6.
46496 2019-01-06  Bruno Haible  <bruno@clisp.org>
46498         maintainer-makefile: Make the configure.ac section optional.
46499         * top/maint.mk (GREP, SED): Define if not defined.
46501 2019-01-06  Bruno Haible  <bruno@clisp.org>
46503         localename: Assume setlocale function.
46504         * lib/localename.c (gl_locale_name_posix): Assume setlocale exists.
46505         * m4/localename.m4 (gl_LOCALENAME): Don't test whether setlocale exists.
46507 2019-01-06  Bruno Haible  <bruno@clisp.org>
46509         doc: Add documentation about container data types.
46510         * doc/containers.texi: New file.
46511         * doc/gnulib.texi (Particular Modules): Include it.
46513 2019-01-06  Bruno Haible  <bruno@clisp.org>
46515         doc: Update documentation about 'progname' module.
46516         * doc/progname.texi: Rename from doc/error.texi. Change node name and
46517         title. Rewrite.
46518         * doc/gnulib.texi (Particular Modules): Update.
46520 2019-01-06  Bruno Haible  <bruno@clisp.org>
46522         doc: Document the xstdopen and *-safer modules.
46523         * doc/xstdopen.texi: New file.
46524         * doc/gnulib.texi (Particular Modules): Include it.
46526 2019-01-06  Bruno Haible  <bruno@clisp.org>
46528         xstdopen: Add tests.
46529         * tests/test-xstdopen.c: New file.
46530         * tests/test-xstdopen.sh: New file.
46531         * modules/xstdopen-tests: New file.
46533         xstdopen: New module.
46534         * lib/xstdopen.h: New file.
46535         * lib/xstdopen.c: New file.
46536         * modules/xstdopen: New file.
46538 2019-01-06  Bruno Haible  <bruno@clisp.org>
46540         stdopen: Fix compilation error with IRIX cc.
46541         * lib/stdopen.c (stdopen): Do not use C99-style decl in loop.
46543 2019-01-05  Paul Eggert  <eggert@cs.ucla.edu>
46545         xfreopen need not include stdio--.h
46546         * lib/xfreopen.c: Do not include stdio--.h.
46548         xfreopen need not depend on freopen-safer
46549         * modules/xfreopen (Depends-on):
46550         Depend on freopen, not freopen-safer.
46552         stdopen: modernize and simplify
46553         * lib/stdopen.c: Update copyright date
46554         Do not include sys/types.h; no longer needed these days.
46555         (stdopen): Use C99-style decl in loop.  Return int errno
46556         value, rather than just a bool.  Do not worry about fd mismatches,
46557         since the caller cares only if 0, 1, 2 are occupied.
46558         * lib/stdopen.h: No need to include <stdbool.h>.
46559         * m4/stdopen.m4: Remove.
46560         * modules/stdopen: New file.
46562         stdopen: copy from last use in coreutils
46563         * lib/stdopen.c, lib/stdopen.h, m4/stdopen.m4:
46564         New files, taken from their last commit in coreutils
46565         2007-07-23T12:35:58Z!jim@meyering.net
46566         71aa3ea88084d17bcb4fc1031ad7b66f8647115e.
46568 2019-01-05  Bruno Haible  <bruno@clisp.org>
46570         argp: Don't pass an invalid argument to dgettext().
46571         Reported by He X <xw897002528@gmail.com>.
46572         * lib/argp-help.c (print_header, argp_doc): Don't pass a NULL doc to
46573         dgettext().
46575 2019-01-05  Bruno Haible  <bruno@clisp.org>
46577         argp: Don't pass an invalid argument to dgettext().
46578         Reported by He X <xw897002528@gmail.com>.
46579         * lib/argp.h (struct argp): Clarify that the args_doc field may be NULL.
46580         * lib/argp-help.c (argp_args_usage): Don't pass a NULL args_doc to
46581         dgettext().
46583 2018-12-22  Paul Eggert  <eggert@cs.ucla.edu>
46585         stdioext: port to newer 32-bit Android
46586         Problem reported by Tom Yan in:
46587         https://lists.gnu.org/archive/html/bug-gnulib/2018-07/msg00014.html
46588         * lib/stdio-impl.h (_gl_FILE_flags_t) [__ANDROID__]: New macro.
46589         (fp_) [__ANDROID__]: Use it.
46591 2019-01-04  Bruno Haible  <bruno@clisp.org>
46593         lock: Fix link error with --enable-threads=pth.
46594         * lib/glthread/lock.h (pth_cond_init, pth_cond_await, pth_cond_notify):
46595         Mark as weak.
46597 2019-01-04  Bruno Haible  <bruno@clisp.org>
46599         Fix link errors in unit tests.
46600         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
46601         * modules/bitset-tests (Makefile.am): Link test-bitset against libintl.
46602         * modules/array-map-tests (Makefile.am): Link test-array_map against
46603         libintl.
46604         * modules/array-set-tests (Makefile.am): Link test-array_set against
46605         libintl.
46606         * modules/hash-map-tests (Makefile.am): Link test-hash_map against
46607         libintl.
46608         * modules/hash-set-tests (Makefile.am): Link test-hash_set against
46609         libintl.
46610         * modules/linkedhash-map-tests (Makefile.am): Link test-linkedhash_map
46611         against libintl.
46612         * modules/linkedhash-set-tests (Makefile.am): Link test-linkedhash_set
46613         against libintl.
46615 2019-01-04  Bruno Haible  <bruno@clisp.org>
46617         Fix incorrect 'Link' sections.
46618         * modules/regex (Link): Mention the link requirement of module 'lock'.
46619         * modules/regex-tests (Makefile.am): Don't use LIB_PTHREAD.
46621 2019-01-04  Bruno Haible  <bruno@clisp.org>
46623         Fix some 'Link' sections.
46624         * modules/c-stack (Link): Add link directive from the 'gettext-h'
46625         dependency.
46626         * modules/getaddrinfo (Link): Likewise.
46628 2019-01-04  Bruno Haible  <bruno@clisp.org>
46630         Remove redundant 'Link' sections.
46631         * modules/canon-host (Link): Remove section.
46632         * modules/timevar (Link): Likewise.
46634 2019-01-04  Bruno Haible  <bruno@clisp.org>
46636         Remove incorrect 'Link' sections.
46637         * modules/acl (Link): Remove section. Use combined 'Link' sections from
46638         the dependencies instead.
46639         * modules/crypto/md5 (Link): Likewise.
46640         * modules/crypto/sha1 (Link): Likewise.
46641         * modules/crypto/sha256 (Link): Likewise.
46642         * modules/crypto/sha512 (Link): Likewise.
46643         * modules/faccessat (Link): Likewise.
46644         * modules/fdutimensat (Link): Likewise.
46645         * modules/iconv_open-utf (Link): Likewise.
46646         * modules/propername (Link): Likewise.
46647         * modules/qacl (Link): Likewise.
46648         * modules/unicodeio (Link): Likewise.
46649         * modules/utimecmp (Link): Likewise.
46650         * modules/utimensat (Link): Likewise.
46651         * modules/xstriconv (Link): Likewise.
46652         * modules/xstriconveh (Link): Likewise.
46654 2019-01-04  Bruno Haible  <bruno@clisp.org>
46656         gnulib-tool: New option --extract-recursive-link-directive.
46657         * gnulib-tool (func_usage): Document the new options
46658         --extract-recursive-dependencies, --extract-recursive-link-directive.
46659         (func_verify_module): Document output variables.
46660         (func_get_dependencies_recursively): New function.
46661         (func_get_link_directive_recursively): New function.
46662         Use them to implement the new options
46663         --extract-recursive-dependencies, --extract-recursive-link-directive.
46664         * doc/gnulib-tool.texi (Link-time requirements): New section.
46666 2019-01-04  Bruno Haible  <bruno@clisp.org>
46668         Clarify meaning of 'Link' section in module description.
46669         * doc/gnulib.texi (Module description): Clarify the meaning of the
46670         'Link' section versus the one of the dependencies.
46671         * NEWS: Mention the change.
46673 2019-01-04  Bruno Haible  <bruno@clisp.org>
46675         pselect: Fix module description.
46676         * modules/pselect (Link): Put one link option per line.
46678 2019-01-04  Bruno Haible  <bruno@clisp.org>
46680         cosl: Fix module description.
46681         * modules/cosl (Link): Fix typo.
46682         * modules/mathl (configure.ac): Likewise.
46684 2019-01-04  Bruno Haible  <bruno@clisp.org>
46686         c-xvasprintf: Fix module dependencies.
46687         * modules/c-xvasprintf (Depends-on): Add 'xalloc-die'.
46689 2019-01-04  Akim Demaille  <akim@lrde.epita.fr>
46691         bootstrap: die when some submodules are not initialized
46692         * build-aux/bootstrap: Make sure all submodules are initialized.
46694 2019-01-04  Bruno Haible  <bruno@clisp.org>
46696         bitsetv: Fix module dependencies.
46697         * lib/bitsetv.c: Include xalloc.h.
46698         * modules/bitsetv (Depends-on): Add 'xalloc'.
46700 2019-01-04  Bruno Haible  <bruno@clisp.org>
46702         xmemdup0: Remove redundant code.
46703         * lib/xmemdup0.h (xalloc_die): Remove declaration.
46705 2019-01-04  Bruno Haible  <bruno@clisp.org>
46707         backupfile: Fix module dependencies.
46708         * modules/backupfile (Depends-on): Add 'xalloc'.
46710 2019-01-03  Paul Eggert  <eggert@cs.ucla.edu>
46712         bitset, crypto/gc: fix conflicts with Solaris 11
46713         * lib/bitset.h (_GL_BITSET_H): Rename from _BITSET_H, to
46714         avoid clash with Solaris 11 <sys/bitset.h>.
46715         * lib/gc.h (_GL_GC_H): Rename from GC_H, to avoid clash
46716         with Solaris 11 <xorg/gc.h>.
46718 2019-01-04  Bruno Haible  <bruno@clisp.org>
46720         safe-read, safe-write: Fix conflict with Illumos-Joyent <sys/limits.h>.
46721         Reported by Andy Fiddaman <andy@omniosce.org>.
46722         * lib/sys-limits.h: Add a '_GL' prefix to the guard symbol.
46724 2019-01-03  Eric Blake  <eblake@redhat.com>
46726         maintainer-makefile: fix typo in previous patch
46727         * top/maint.mk (_sc_search_regexp): Fix my accidental corruption
46728         of Roman's work.
46730 2019-01-02  Roman Bolshakov <r.bolshakov@yadro.com>  (tiny change)
46732         maintainer-makefile: prefer $(GREP) over grep
46733         * modules/maintainer-makefile (configure.ac): Ensure $(GREP) is
46734         defined.
46735         * top/maint.mk: Use it everywhere.
46737         maintainer-makefile: split long argument lines
46738         * top/maint.mk: Use xargs to split $(VC_LIST_EXCEPT) usage where
46739         it would be too long for exec limits on BSD.
46741 2018-12-27  Paul Eggert  <eggert@cs.ucla.edu>
46743         mkfifo: bring back HAVE_MKFIFO macro
46744         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): #define HAVE_MKFIFO as needed.
46745         Problem reported by Andrew Janke in:
46746         https://lists.gnu.org/r/bug-gnulib/2018-12/msg00147.html
46748 2018-12-21  Bruno Haible  <bruno@clisp.org>
46750         Assume Autoconf >= 2.63.
46751         * modules/stdarg (configure.ac-early): Remove comment about Autoconf
46752         versions < 2.60.
46754 2018-12-21  Bruno Haible  <bruno@clisp.org>
46756         memcmp: Mention the clang bug.
46757         * tests/test-memcmp.c: Add comment about a known test failure.
46758         * doc/posix-functions/memcmp.texi: Mention the clang bug.
46760 2018-12-20  Jim Meyering  <meyering@fb.com>
46762         revert v0.1-2213-gae4b73e28 and part of v0.1-2281-g95cd86dd7
46763         v0.1-2213-gae4b73e28 caused a regression in grep-3.2 (no match):
46764           echo '123-x'|LC_ALL=C grep -E '.\bx'
46765         The goal is to revert the first, but reverting it requires to restore
46766         the function deleted in the second. I ran this to restore the deleted
46767         function:
46768           git show v0.1-2281-g95cd86dd7 lib/dfa.c \
46769             | perl -0777 -pe 's/^@@[^\n]*dfaan.*//ms' \
46770             | patch -R -p1
46771         * lib/dfa.c (charclass_context): Restore deleted function.
46772         Reverting the primary commit removes this change:
46773         dfa: Simplify a building state
46774         * lib/dfa.c (build_state): Simplify a building state.
46776 2018-12-20  Paul Eggert  <eggert@cs.ucla.edu>
46778         version-etc: allow zero authors
46779         * lib/version-etc.c (version_etc_arn): If no authors are given,
46780         omit authorship info instead of dumping core.
46782 2018-12-19  Bruno Haible  <bruno@clisp.org>
46784         lchown tests: Be more permissive regarding errno values.
46785         Reported by Ivan Zakharyaschev <imz@altlinux.org>.
46786         * tests/test-lchown.h (test_lchown): Recognize EOPNOTSUPP as an
46787         alternative to ENOSYS.
46788         * modules/lchown-tests (Depends-on): Add 'errno'.
46789         * modules/fchownat-tests (Depends-on): Likewise.
46791 2018-12-18  Bruno Haible  <bruno@clisp.org>
46793         duplocale: Avoid test failure on AIX 7.
46794         * modules/duplocale-tests (Files): Add m4/intl-thread-locale.m4.
46795         (configure.ac): Invoke gt_FUNC_USELOCALE.
46796         * tests/test-duplocale.c: Test HAVE_WORKING_USELOCALE instead of
46797         HAVE_USELOCALE. Assume that nl_langinfo_l only works when uselocale
46798         works.
46800 2018-12-18  Bruno Haible  <bruno@clisp.org>
46802         localename: Fix test failure on AIX 7.
46803         Reported by Assaf Gordon in
46804         <https://lists.gnu.org/archive/html/sed-devel/2018-12/msg00019.html>.
46805         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): New macro.
46806         (gt_INTL_THREAD_LOCALE_NAME): Invoke it. Test gt_cv_func_uselocale_works
46807         instead of ac_cv_func_uselocale.
46808         * lib/localename.c: Test HAVE_WORKING_USELOCALE instead of
46809         HAVE_USELOCALE.
46810         * lib/localename-table.h: Likewise.
46811         * lib/localename-table.c: Likewise.
46812         * tests/test-localename.c: Likewise.
46813         * doc/posix-functions/uselocale.texi: Mention the AIX problem.
46815 2018-12-18  Bruno Haible  <bruno@clisp.org>
46817         localename: Update comments regarding Cygwin.
46818         * lib/localename.c: Update comment.
46819         * doc/posix-functions/uselocale.texi: Update platforms list.
46820         * doc/posix-functions/newlocale.texi: Likewise.
46821         * doc/posix-functions/duplocale.texi: Likewise.
46822         * doc/posix-functions/freelocale.texi: Likewise.
46824 2018-12-16  Bruno Haible  <bruno@clisp.org>
46826         c-stack: Fix for Linux/sparc.
46827         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Set
46828         ac_cv_sys_xsi_stack_overflow_heuristic to 'no' on Linux/sparc.
46830 2018-12-16  Bruno Haible  <bruno@clisp.org>
46832         localename: Avoid test failure on some glibc systems.
46833         * tests/test-localename.c (test_locale_name, test_locale_name_posix):
46834         Unset environment variables that might disturb the first setlocale call,
46835         and verify that this setlocale call succeeds.
46837 2018-12-16  Assaf Gordon  <assafgordon@gmail.com>
46839         random: Fix build error on native Windows (regression from 2018-06-21).
46840         * lib/random.c (__srandom, __initstate, __setstate, __random,
46841         __srandom_r, __initstate_r, __setstate_r, __random_r) [!_LIBC]: Redirect
46842         to the symbols without '__' prefix.
46844 2018-12-16  Bruno Haible  <bruno@clisp.org>
46846         obstack, libc-config: Support HP-UX cc in C99 mode.
46847         * lib/obstack.h (__FLEXIBLE_ARRAY_MEMBER): Treat HP-UX cc as a pre-C99
46848         compiler, even when in C99 mode.
46849         * lib/cdefs.h (__flexarr): Likewise.
46850         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Update comment.
46852 2018-12-16  Bruno Haible  <bruno@clisp.org>
46854         localename: Fix test failure on OpenBSD >= 6.2.
46855         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): Test for fake
46856         locale system. Define HAVE_FAKE_LOCALES in this case.
46857         * lib/localename.c (HAVE_GOOD_USELOCALE): New macro. Use it instead of
46858         HAVE_USELOCALE.
46859         * tests/test-localename.c (HAVE_GOOD_USELOCALE): New macro. Use it
46860         instead of HAVE_NEWLOCALE && HAVE_USELOCALE.
46861         * doc/posix-functions/uselocale.texi: Mention OpenBSD problem. Update
46862         platforms list.
46863         * doc/posix-functions/newlocale.texi: Likewise.
46864         * doc/posix-functions/duplocale.texi: Update platforms list.
46865         * doc/posix-functions/freelocale.texi: Likewise.
46867 2018-12-16  Bruno Haible  <bruno@clisp.org>
46869         duplocale tests: Re-enable the test on platforms without <monetary.h>.
46870         * tests/test-duplocale.c: Use more fine-grained #ifs to re-enable most
46871         of the test, on platforms without <monetary.h>.
46873 2018-12-16  Bruno Haible  <bruno@clisp.org>
46875         localename: Update comments.
46876         * lib/localename.c (HAVE_USELOCALE): Update list of platforms.
46878 2018-12-15  Jim Meyering  <meyering@fb.com>
46880         regex: fix indentation
46881         * m4/regex.m4 (gl_REGEX): Indent with spaces, not TABs.
46883 2018-12-15  Bruno Haible  <bruno@clisp.org>
46885         openat-safer tests: Avoid test failure on NetBSD 8.
46886         * tests/test-openat-safer.c (main): Execute a Linux specific test only
46887         on Linux.
46889 2018-12-15  Jim Meyering  <meyering@fb.com>
46891         regex: work around a bug in glibc-2.27 and prior
46892         * m4/regex.m4 (gl_REGEX): Reject any system regexp that gets a failed
46893         assertion for /0|()0|\1|0/.
46894         * tests/test-regex.c (main): Add the same test here.
46896 2018-12-15  Bruno Haible  <bruno@clisp.org>
46898         localename: Fix use of uninitialized shell variable.
46899         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): Initialize
46900         gt_cv_locale_solaris114 always before use. Remove assignment without
46901         effect.
46903 2018-12-15  Bruno Haible  <bruno@clisp.org>
46905         dfa tests: Avoid test failure on Alpine Linux.
46906         * tests/dfa-match.sh (timeout_10): Accommodate the BusyBox 'timeout'
46907         command found on Alpine Linux.
46909 2018-12-15  Jim Meyering  <meyering@fb.com>
46911         dfa: avoid new warnings from gcc
46912         These would prevent building with -Werror and a Dec snapshot of gcc.
46913         * lib/dfa.c (dfaanalyze): Avoid shadowing warnings for "pos".
46914         Rename each inner instance to "p".
46915         (charclass_context): Remove unused static function.
46917 2018-12-14  Paul Eggert  <eggert@cs.ucla.edu>
46919         mkdir-p: improve diagnostic for FUSE mounts
46920         Problem reported by Niklas Hambüchen in:
46921         https://lists.gnu.org/r/bug-gnulib/2018-12/msg00074.html
46922         * lib/mkdir-p.c (make_dir_parents): In diagnostic, prefer stat
46923         errno to mkdir errno if the stat errno is likely more interesting.
46925 2018-12-14  Bruno Haible  <bruno@clisp.org>
46927         hash-map: Add tests.
46928         * tests/test-hash_map.c: New file.
46929         * modules/hash-map-tests: New file.
46931         linkedhash-map: Add tests.
46932         * tests/test-linkedhash_map.c: New file.
46933         * modules/linkedhash-map-tests: New file.
46935         array-map: Add tests.
46936         * tests/test-array_map.c: New file.
46937         * modules/array-map-tests: New file.
46939         xmap: New module.
46940         * lib/gl_xmap.h: New file.
46941         * lib/gl_xmap.c: New file.
46942         * modules/xmap: New file.
46944         hash-map: New module.
46945         * lib/gl_hash_map.h: New file.
46946         * lib/gl_hash_map.c: New file.
46947         * modules/hash-map: New file.
46949         linkedhash-map: New module.
46950         * lib/gl_linkedhash_map.h: New file.
46951         * lib/gl_linkedhash_map.c: New file.
46952         * lib/gl_anyhash1.h: Update comments.
46953         * lib/gl_anyhash2.h: Likewise.
46954         * modules/linkedhash-map: New file.
46956         array-map: New module.
46957         * lib/gl_array_map.h: New file.
46958         * lib/gl_array_map.c: New file.
46959         * modules/array-map: New file.
46961         map: New module.
46962         * lib/gl_map.h: New file.
46963         * lib/gl_map.c: New file.
46964         * lib/gl_omap.h (gl_mapkey_dispose_fn, gl_mapvalue_dispose_fn): Avoid
46965         conflict with gl_map.h.
46966         * modules/map: New file.
46968 2018-12-13  Bruno Haible  <bruno@clisp.org>
46970         select tests: Avoid test failure on Cygwin.
46971         * tests/test-select.h (test_bad_fd): Use an fd < FD_SETSIZE.
46973 2018-12-13  Bruno Haible  <bruno@clisp.org>
46975         localtime-buffer: Avoid endless recursion in localtime and gmtime.
46976         * lib/localtime-buffer.c: Undefine localtime and gmtime before use.
46978 2018-12-13  Bruno Haible  <bruno@clisp.org>
46980         localeconv tests: Avoid test failure on Cygwin.
46981         * tests/test-localeconv.c (main): On Cygwin, skip the 'grouping' and
46982         'mon_grouping' tests.
46984 2018-12-11  Bruno Haible  <bruno@clisp.org>
46986         omap: Don't dispose the old value when the function returns it.
46987         * lib/gl_array_omap.c (gl_array_remove_at): Don't invoke the vdispose_fn
46988         here.
46989         * lib/gl_avltree_omap.c (NODE_PAYLOAD_DISPOSE): Likewise.
46990         * lib/gl_rbtree_omap.c (NODE_PAYLOAD_DISPOSE): Likewise.
46991         * lib/gl_omap.h (gl_omap_nx_put, gl_omap_remove): Invoke the vdispose_fn
46992         here.
46994         array-omap, avltree-omap, rbtree-omap: Tweak style.
46995         * lib/gl_anytree_omap.h (gl_tree_nx_getput): Return 1 or 0, not true or
46996         false.
46997         * lib/gl_array_omap.c (gl_array_nx_getput): Likewise.
46999         rbtree-omap: Add tests.
47000         * tests/test-rbtree_omap.c: New file.
47001         * modules/rbtree-omap-tests: New file.
47003         avltree-omap: Add tests.
47004         * tests/test-avltree_omap.c: New file.
47005         * modules/avltree-omap-tests: New file.
47007         array-omap: Add tests.
47008         * tests/test-array_omap.c: New file.
47009         * modules/array-omap-tests: New file.
47011         xomap: New module.
47012         * lib/gl_xomap.h: New file.
47013         * lib/gl_xomap.c: New file.
47014         * modules/xomap: New file.
47016         rbtree-omap: New module.
47017         * lib/gl_rbtree_omap.h: New file.
47018         * lib/gl_rbtree_omap.c: New file.
47019         * lib/gl_rbtree_ordered.h: Code moved to here from lib/gl_rbtree_oset.c.
47020         Parameterize.
47021         * lib/gl_rbtree_oset.c: Include gl_rbtree_ordered.h.
47022         * modules/rbtree-omap: New file.
47023         * modules/rbtree-oset (Files): Add lib/gl_rbtree_ordered.h.
47024         (Makefile.am): Add gl_rbtree_ordered.h to lib_SOURCES.
47026         avltree-omap: New module.
47027         * lib/gl_avltree_omap.h: New file.
47028         * lib/gl_avltree_omap.c: New file.
47029         * lib/gl_avltree_ordered.h: Code moved to here from
47030         lib/gl_avltree_oset.c. Parameterize.
47031         * lib/gl_avltree_oset.c: Include gl_avltree_ordered.h.
47032         * lib/gl_anytree_omap.h: New file.
47033         * modules/avltree-omap: New file.
47034         * modules/avltree-oset (Files): Add lib/gl_avltree_ordered.h.
47035         (Makefile.am): Add gl_avltree_ordered.h to lib_SOURCES.
47037         array-omap: New module.
47038         * lib/gl_array_omap.h: New file.
47039         * lib/gl_array_omap.c: New file.
47040         * modules/array-omap: New file.
47042         omap: New module.
47043         * lib/gl_omap.h: New file.
47044         * lib/gl_omap.c: New file.
47045         * modules/omap: New file.
47047 2018-12-11  Bruno Haible  <bruno@clisp.org>
47049         hash-set, linkedhash-set: Reduce code duplication.
47050         * lib/gl_anyhash1.h: Rename from lib/gl_anyhash_list1.h and
47051         lib/gl_anyhash_set1.h.
47052         * lib/gl_anyhash2.h: Rename from lib/gl_anyhash_list2.h and
47053         lib/gl_anyhash_set2.h. Parameterize.
47054         (hash_resize_after_add): New function, from lib/gl_anyhash_set2.h.
47055         * lib/gl_anytreehash_list1.h (hash_resize_after_add): Remove function.
47056         * lib/gl_avltreehash_list.c: Include gl_anyhash1.h instead of
47057         gl_anyhash_list1.h. Include gl_anyhash2.h instead of gl_anyhash_list2.h.
47058         * lib/gl_rbtreehash_list.c: Likewise.
47059         * lib/gl_linkedhash_list.c: Likewise.
47060         (hash_resize_after_add): Remove function.
47061         * lib/gl_linkedhash_set.c: Include gl_anyhash1.h instead of
47062         gl_anyhash_set1.h. Include gl_anyhash2.h instead of gl_anyhash_set2.h.
47063         * gl_hash_set.c: Likewise.
47064         * modules/avltreehash-list (Files, Makefile.am): Update file list.
47065         * modules/rbtreehash-list (Files, Makefile.am): Likewise.
47066         * modules/linkedhash-list (Files, Makefile.am): Likewise.
47067         * modules/linkedhash-set (Files, Makefile.am): Likewise.
47068         * modules/hash-set (Files, Makefile.am): Likewise.
47070 2018-12-11  Bruno Haible  <bruno@clisp.org>
47072         array-set: Optimize.
47073         * lib/gl_array_set.c (gl_array_search, gl_array_remove): Test equals_fn
47074         outside the loop, not inside the loop.
47076 2018-12-11  Bruno Haible  <bruno@clisp.org>
47078         times: Fix tests.
47079         * tests/test-times.c (doublecmp): Implement a total order.
47081 2018-12-11  Bruno Haible  <bruno@clisp.org>
47083         array-set, linkedhash-set, hash-set: Fix tests.
47084         * tests/test-array_set.c (cmp_objects_in_array): New function.
47085         (check_equals): Use it.
47086         * tests/test-hash_set.c: Likewise.
47087         * tests/test-linkedhash_set.c: Likewise.
47089 2018-12-08  Bruno Haible  <bruno@clisp.org>
47091         Fix comments.
47092         * lib/gl_list.h (gl_list_free): Clarify what it does.
47093         * lib/gl_oset.h (gl_oset_free): Likewise.
47094         * lib/gl_set.h (gl_set_free): Likewise.
47095         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Fix typo in comment.
47096         * lib/gl_array_oset.c (gl_array_search_atleast): Likewise.
47097         * lib/gl_anyavltree_list1.h (MAXHEIGHT): Likewise.
47098         * lib/gl_avltree_oset.c (MAXHEIGHT): Likewise.
47100 2018-12-03  Bruno Haible  <bruno@clisp.org>
47102         hash-set: Add tests.
47103         * tests/test-hash_set.c: New file.
47104         * modules/hash-set-tests: New file.
47106         linkedhash-set: Add tests.
47107         * tests/test-linkedhash_set.c: New file.
47108         * modules/linkedhash-set-tests: New file.
47110         array-set: Add tests.
47111         * tests/test-array_set.c: New file.
47112         * modules/array-set-tests: New file.
47114         xset: New module.
47115         * lib/gl_xset.h: New file.
47116         * lib/gl_xset.c: New file.
47117         * modules/xset: New file.
47119         hash-set: New module.
47120         * lib/gl_hash_set.h: New file.
47121         * lib/gl_hash_set.c: New file.
47122         * modules/hash-set: New file.
47124         linkedhash-set: New module.
47125         * lib/gl_linkedhash_set.h: New file.
47126         * lib/gl_linkedhash_set.c: New file.
47127         * lib/gl_anyhash_set1.h: New file, based on lib/gl_anyhash_list1.h.
47128         * lib/gl_anyhash_set2.h: New file, based on lib/gl_anyhash_list2.h.
47129         * lib/gl_anyhash_primes.h: New file, extracted from
47130         lib/gl_anyhash_list2.h.
47131         * lib/gl_anyhash_list2.h: Include it.
47132         (primes, next_prime): Remove definitions.
47133         * modules/linkedhash-set: New file.
47134         * modules/avltreehash-list (Files): Add lib/gl_anyhash_primes.h.
47135         (Makefile.am): Add gl_anyhash_primes.h to lib_SOURCES.
47136         * modules/linkedhash-list (Files): Add lib/gl_anyhash_primes.h.
47137         (Makefile.am): Add gl_anyhash_primes.h to lib_SOURCES.
47138         * modules/rbtreehash-list (Files): Add lib/gl_anyhash_primes.h.
47139         (Makefile.am): Add gl_anyhash_primes.h to lib_SOURCES.
47141         array-set: New module.
47142         * lib/gl_array_set.h: New file.
47143         * lib/gl_array_set.c: New file.
47144         * modules/array-set: New file.
47146         set: New module.
47147         * lib/gl_set.h: New file.
47148         * lib/gl_set.c: New file.
47149         * lib/gl_oset.h (gl_setelement_dispose_fn): Avoid conflict with
47150         gl_set.h.
47151         * modules/set: New file.
47153 2018-12-07  Akim Demaille  <akim@lrde.epita.fr>
47155         bison: don't force the Yacc mode
47156         Passing -y forces Bison into POSIX YACC mode.  This includes reporting
47157         errors when Bison features are used in the grammar file.  Some of
47158         these features (such as %expect) were flagged non-yacc recently.  Most
47159         of the time, -y is actually used to please Automake's ylwrap which
47160         expects the output to be y.tab.c.
47161         * m4/bison.m4 (gl_BISON): Use `-o y.tab.c` rather than `-y`.
47163 2018-12-01  Bruno Haible  <bruno@clisp.org>
47165         gnupload: Document short options.
47166         * build-aux/gnupload (usage): Document the short options.
47168 2018-11-28  Ben Elliston  <bje@gnu.org>
47170         gnupload: Support option -h as alias of --help.
47171         * build-aux/gnupload: Support -h.
47173 2018-11-30  Paul Eggert  <eggert@cs.ucla.edu>
47175         memrchr: port better to clang
47176         * lib/memrchr.c (__memrchr): Cast to void * instead of to
47177         longword *, to pacify clang -Wcast-align (Bug#33544).
47179 2018-11-29  Eric Blake  <eblake@redhat.com>
47181         docs: mention printf %m considerations
47182         * doc/glibc-functions/asprintf.texi (asprintf): Document that %m
47183         is not portable, and is easy enough to work around.
47184         * doc/glibc-functions/obstack_printf.texi (obstack_printf): Likewise.
47185         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf): Likewise.
47186         * doc/glibc-functions/vasprintf.texi (vasprintf): Likewise.
47187         * doc/posix-functions/dprintf.texi (dprintf): Likewise.
47188         * doc/posix-functions/fprintf.texi (fprintf): Likewise.
47189         * doc/posix-functions/fwprintf.texi (fwprintf): Likewise.
47190         * doc/posix-functions/printf.texi (printf): Likewise.
47191         * doc/posix-functions/snprintf.texi (snprintf): Likewise.
47192         * doc/posix-functions/sprintf.texi (sprintf): Likewise.
47193         * doc/posix-functions/swprintf.texi (swprintf): Likewise.
47194         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
47195         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
47196         * doc/posix-functions/vfwprintf.texi (vfwprintf): Likewise.
47197         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
47198         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
47199         * doc/posix-functions/vsprintf.texi (vsprintf): Likewise.
47200         * doc/posix-functions/vswprintf.texi (vswprintf): Likewise.
47201         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
47202         * doc/posix-functions/wprintf.texi (wprintf): Likewise.
47204 2018-11-29  Akim Demaille  <akim@lrde.epita.fr>
47206         bitset: rename ebitset/expandable.* as tbitset/table.*
47207         See
47208         https://lists.gnu.org/archive/html/bug-gnulib/2018-11/msg00096.html.
47209         * lib/bitset/expandable.h, lib/bitset/expandable.c: Rename as...
47210         * lib/bitset/table.h, lib/bitset/table.c: these.
47211         Rename all the ebitset* symbols as tbitset*.
47212         Adjust dependencies.
47214 2018-11-28  Akim Demaille  <akim@lrde.epita.fr>
47216         bitset: check the operations
47217         * tests/test-bitset.c (bitset_random): New.
47218         Use it.
47219         * lib/bitset/expandable.c (ebitset_not): Fix typo.
47221 2018-11-28  Akim Demaille  <akim@lrde.epita.fr>
47223         bitset: properly use false/true instead of 0/1 for Booleans
47224         * lib/bitset/expandable.c, lib/bitset/vector.c: Use false/true, not
47225         0/1, as Booleans.
47227 2018-11-28  Akim Demaille  <akim@lrde.epita.fr>
47229         bitset: rename BITSET_VARRAY as BITSET_VECTOR
47230         For consistency with the name of the file.
47231         * doc/bitset.texi, lib/bitset.c, lib/bitset/base.h,
47232         * lib/bitset/stats.c, lib/bitset/vector.c
47233         (BITSET_VARRAY): Rename as...
47234         (BITSET_VECTOR): this.
47236 2018-11-28  Paul Eggert  <eggert@cs.ucla.edu>
47238         strerror_r-posix: memmove, not memcpy
47239         * lib/strerror_r.c (safe_copy): Use memmove, not memcpy,
47240         since the source and destination might overlap in the call
47241         ‘safe_copy (buf, buflen, strerror_r (errnum, buf, buflen))’.
47242         Simplify.
47244 2018-11-25  Akim Demaille  <akim@lrde.epita.fr>
47246         bitsetv: new module
47247         * lib/bitsetv.c, lib/bitsetv.h, modules/bitsetv: New.
47249 2018-11-25  Akim Demaille  <akim@lrde.epita.fr>
47251         bitset: add tests and doc
47252         First stabs at providing a documentation and test for the bitset
47253         module.
47254         * doc/bitset.texi, modules/test-bitset, tests/bitset-tests.c: New.
47256 2018-11-25  Akim Demaille  <akim@lrde.epita.fr>
47258         bitset: new module
47259         * lib/bitset.c, lib/bitset.h, lib/bitset/array.c,
47260         * lib/bitset/array.h, lib/bitset/base.h, lib/bitset/expandable.c,
47261         * lib/bitset/expandable.h, lib/bitset/list.c, lib/bitset/list.h,
47262         * lib/bitset/stats.c, lib/bitset/stats.h, lib/bitset/vector.c,
47263         * lib/bitset/vector.h, modules/bitset:
47264         New.
47266 2018-11-23  Bruno Haible  <bruno@clisp.org>
47268         localename: Fix gettext test failures on mingw.
47269         * lib/localename.c (gl_locale_name_posix): Convert the result of
47270         gl_locale_name_environ to XPG syntax.
47272 2018-11-23  Karl Berry  <karl@freefriends.org>
47274         * config/srclistvars.txt,
47275         * config/srclist.txt: remove all gettext references;
47276         the gettext maintainers will sync as needed.
47278 2018-11-21  Paul Eggert  <eggert@cs.ucla.edu>
47280         mktime: add libc-config dependency
47281         I missed this when we synced from glibc.
47282         * modules/mktime (Depends-on): Add libc-config.
47284 2018-11-13  Paul Eggert  <eggert@cs.ucla.edu>
47286         longlong: fix comment typo
47287         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Fix typo.
47289 2018-11-11  Bruno Haible  <bruno@clisp.org>
47291         havelib: Remove the need to include asm-underscore.m4.
47292         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): New macro.
47293         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Use it instead of
47294         gl_HOST_CPU_C_ABI.
47295         * modules/havelib (Files): Add host-cpu-c-abi.m4.
47296         (Depends-on): Remove host-cpu-c-abi.
47298 2018-11-03  Paul Eggert  <eggert@cs.ucla.edu>
47300         parse-datetime: simplify test for mktime failure
47301         * lib/parse-datetime.y (mktime_ok): Simplify.
47302         Remove args TZ and T; no longer needed.  Callers changed.
47304         posixtm: simplify test for mktime failure
47305         * lib/posixtm.c (posixtime): Simplify.
47307         nstrftime: simplify test for mktime failure
47308         * lib/nstrftime.c (__strftime_internal): Simplify.
47310 2018-11-02  Paul Eggert  <eggert@cs.ucla.edu>
47312         gnulib-common.m4: port _Noreturn to C++
47313         Problem reported by Akim Demaille in:
47314         https://lists.gnu.org/r/bug-bison/2018-10/msg00067.html
47315         * m4/gnulib-common.m4 (gl_COMMON_BODY): If C++, use [[noreturn]].
47316         Merge adjustments from _Noreturn.h and from glibc into the non-C++
47317         version.
47318         * lib/_Noreturn.h: Match gnulib-common.
47320 2018-10-30  Bruno Haible  <bruno@clisp.org>
47322         gnu-make: Fix for NetBSD 8 'make'.
47323         Reported by Reuben Thomas in
47324         <https://lists.gnu.org/archive/html/bug-gnulib/2018-10/msg00135.html>.
47325         * m4/gnu-make.m4 (gl_GNU_MAKE): Use a heuristic based on the --version
47326         output, ignoring exit codes.
47328 2018-10-28  Bernhard Voelker  <mail@bernhard-voelker.de>
47330         maintainer-makefile: fix syntax-check rule for "same.h"
47331         * top/maint.mk (sc_prohibit_same_without_use): Adjust regex to check
47332         for 'same_nameat', too.
47334 2018-10-25  Paul Eggert  <eggert@cs.ucla.edu>
47336         havelib: fix nested ‘configure’ chatter
47337         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Don’t nest
47338         AC_CACHE_CHECK calls, which resulted in confusing output like
47339         “checking for the common suffixes of directories in the library
47340         search path... checking for 64-bit host... no lib,lib”.
47342         backupfile: tweak for better code
47343         * lib/backupfile.c: Sort include directives, and remove
47344         unnecessary <limits.h> include.
47345         (FALLTHROUGH): New macro, copied from other modules.
47346         (backupfile_internal): Use it to avoid code duplication.
47347         This lets GCC 8.2.1 generate better code by inlining the
47348         call to check_extension.
47350 2018-10-23  Paul Eggert  <eggert@cs.ucla.edu>
47352         backupfile: new dir_fd args
47353         New module opendirat with code taken from fts.
47354         Use this module to let backupfile use a directory file descriptor.
47355         * NEWS: Document the incompatible change.
47356         * lib/backup-find.c (find_backup_file_name):
47357         * lib/backup-rename.c (backup_file_rename):
47358         New arg DIR_FD.
47359         * lib/backupfile.c: Include stdint.h, for SIZE_MAX.
47360         (SIZE_MAX): Remove.
47361         Include opendirat.h rather than dirent--.h.
47362         (check_extension): New args DIR_FD and BASE_MAX.  All callers changed.
47363         (numbered_backup): New args DIR_FD and PNEW_FD.  All callers changed.
47364         (backupfile_internal): New arg DIR_FD.  All callers changed.
47365         * lib/fts.c: Include opendirat.h.
47366         (opendirat): Move to opendirat.c.
47367         * lib/opendirat.c, lib/opendirat.h, modules/opendirat: New files.
47368         * modules/backupfile (Depends-on): Remove dirfd, opendir.
47369         Add opendirat.
47370         * modules/fts (Depends-on): Remove fdopendir, openat-safer.
47371         Add opendirat.
47373 2018-10-23  Bruno Haible  <bruno@clisp.org>
47375         localename: Simplify support for per-thread locales on Solaris 11.4.
47376         * m4/intl-thread-locale.m4: Renamed from m4/intlsolaris.m4.
47377         (gt_INTL_THREAD_LOCALE_NAME): Renamed from gt_INTL_SOLARIS. Define
47378         HAVE_SOLARIS114_LOCALES instead of HAVE_NAMELESS_LOCALES.
47379         * lib/localename.c: Handle HAVE_SOLARIS114_LOCALES through Solaris
47380         specific code.
47381         * lib/localename-table.h: Update comments.
47382         * lib/localename-table.c: Update comments.
47383         * m4/localename.m4 (gl_LOCALENAME): Require gt_INTL_THREAD_LOCALE_NAME.
47384         Test for 'uselocale'. Don't invoke gt_INTL_SOLARIS.
47385         * m4/intl.m4 (AM_INTL_SUBDIR): Require gt_INTL_THREAD_LOCALE_NAME. Test
47386         for 'uselocale'. Set HAVE_NAMELESS_LOCALES.
47387         (gt_INTL_SUBDIR_CORE): Don't invoke gt_INTL_SOLARIS. Don't set
47388         HAVE_NAMELESS_LOCALES here.
47389         * modules/localename (Files): Add m4/intl-thread-locale.m4. Remove
47390         m4/intlsolaris.m4.
47391         * modules/gettext (Files): Likewise.
47393 2018-10-22  Bruno Haible  <bruno@clisp.org>
47395         std-gnu11: Support Autoconf versions < 2.64.
47396         * m4/std-gnu11.m4 (AC_PROG_CC, AC_PROG_CXX): Use _AC_DO as fallback
47397         when _AC_DO_LIMIT does not exist.
47399 2018-10-22  Bruno Haible  <bruno@clisp.org>
47401         Assume Autoconf >= 2.63.
47402         * DEPENDENCIES: Mention the requirement.
47404         * gnulib-tool (DEFAULT_AUTOCONF_MINVERSION): Bump to 2.63.
47405         (func_get_filelist): Don't list m4/onceonly.m4 any more.
47406         * pygnulib/GLModuleSystem.py (getFiles): Likewise.
47407         * m4/onceonly.m4: Remove file.
47409         * m4/openmp.m4: Remove file.
47410         * modules/openmp (Files): Remove m4/openmp.m4.
47412         * m4/configmake.m4 (gl_CONFIGMAKE_PREP): Don't set datarootdir, docdir,
47413         htmldir, dvidir, pdfdir, psdir, localedir.
47414         * m4/po.m4 (AM_PO_SUBDIRS): Don't set localedir.
47416         * m4/gnulib-common.m4 (m4_foreach_w): Remove fallback for
47417         Autoconf < 2.60.
47418         (AC_PROG_MKDIR_P): Remove definition for Autoconf < 2.62.
47419         (AC_PROG_SED): Remove fallback for Autoconf < 2.60.
47421         * m4/errno_h.m4 (AC_COMPUTE_INT): Remove fallback for Autoconf < 2.61.
47422         * m4/size_max.m4 (AC_COMPUTE_INT): Likewise.
47423         * m4/stdint.m4 (AC_COMPUTE_INT): Likewise.
47425         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Assume AC_USE_SYSTEM_EXTENSIONS
47426         exists.
47427         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Likewise,
47429         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Remove workaround for
47430         Autoconf < 2.61.
47432         * m4/lib-prefix.m4 (AC_LIB_ARG_WITH): Remove macro.
47433         (AC_LIB_PREFIX): Use AC_ARG_WITH, assuming semantics of
47434         Autoconf >= 2.52.
47436         * m4/longlong.m4: Require Autoconf >= 2.62. Update comments.
47437         * m4/ls-mntd-fs.m4: Require Autoconf >= 2.60. Update comments.
47438         * m4/gettext.m4 (AM_GNU_GETTEXT): Update comment.
47440 2018-10-22  Bruno Haible  <bruno@clisp.org>
47442         Assume Automake >= 1.11.
47443         * m4/configmake.m4: Update comments.
47444         * m4/lib-link.m4 (AC_LIB_RPATH): Assume AC_REQUIRE_AUX_FILE exists.
47445         * m4/po.m4 (AM_PO_SUBDIRS, AM_POSTPROCESS_PO_MAKEFILE): Eliminate uses
47446         of 'eval'.
47447         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am,
47448         func_create_testdir, func_create_megatestdir): Emit a Makefile.am that
47449         requires Automake >= 1.11.
47451 2018-10-22  Bruno Haible  <bruno@clisp.org>
47453         localename: Fix typo in comment.
47454         * tests/test-locale-c++.cc (newlocale): Fix typo in comment.
47456 2018-10-22  Bruno Haible  <bruno@clisp.org>
47458         Fix failure of 'gnulib-tool --create-testdir' with all modules.
47459         * gnulib-tool (func_create_testdir): Exclude 'timevar' module.
47461 2018-10-21  Bruno Haible  <bruno@clisp.org>
47463         locale: Ease integration with GNU libintl.
47464         * lib/locale.in.h (GNULIB_defined_newlocale, GNULIB_defined_duplocale,
47465         GNULIB_defined_freelocale): New macros.
47467 2018-10-21  Bruno Haible  <bruno@clisp.org>
47469         localename: Fine-tune support for per-thread locales on Solaris 11.4.
47470         * lib/localename-table.h: New file, extracted from lib/localename.c.
47471         * lib/localename-table.c: Likewise.
47472         * lib/localename.c: Include localename-table.h.
47473         (get_locale_t_name, newlocale, duplocale, freelocale): Invoke
47474         locale_hash_function instead of pointer_hash.
47475         * modules/localename (Files): Add lib/localename-table.h,
47476         lib/localename-table.c.
47477         (lib_SOURCES): Add localename-table.c.
47478         * m4/intlsolaris.m4 (gt_INTL_SOLARIS): Require AC_CANONICAL_HOST. Test
47479         for Solaris 11.4 locale system only on Solaris. Test for it
47480         independently whether getlocalename_l exists.
47481         * m4/intl.m4 (gt_INTL_SUBDIR_CORE): Don't test for 'uselocale' and
47482         'getlocalename_l'. Instead, invoke gt_INTL_SOLARIS. Set
47483         HAVE_NAMELESS_LOCALES.
47484         * modules/gettext (Files): Add m4/intlsolaris.m4.
47486 2018-10-21  Bruno Haible  <bruno@clisp.org>
47488         Small update from gettext.
47489         * m4/intl.m4: Update from gettext:
47490         - 2018-01-02: Fix 'ar' invocation when cross-compiling and in 64-bit
47491         mode on AIX.
47492         - 2018-01-02: Don't use -lc explicitly when linking with libtool.
47493         - 2017-05-19: (AM_INTL_SUBDIR): Require AC_C_FLEXIBLE_ARRAY_MEMBER.
47495 2018-10-16  Bruno Haible  <bruno@clisp.org>
47497         mountlist: Remove support for Cray with UNICOS 9.
47498         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't define
47499         MOUNTED_LISTMNTENT.
47500         * lib/mountlist.c: Remove MOUNTED_LISTMNTENT case.
47502 2018-10-16  Bruno Haible  <bruno@clisp.org>
47504         fsusage, mountlist, getloadavg, getgroups: Remove support for Ultrix.
47505         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't define
47506         STAT_STATFS2_FS_DATA.
47507         * lib/fsusage.c: Remove STAT_STATFS2_FS_DATA case.
47508         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't define
47509         MOUNTED_GETMNT.
47510         * lib/mountlist.c: Remove MOUNTED_GETMNT case.
47511         * lib/getloadavg.c (decstation): Remove definition and case.
47512         * m4/getgroups.m4 (AC_FUNC_GETGROUPS): Mention NeXTstep, not Ultrix.
47513         * lib/getgroups.c: Likewise.
47514         * doc/posix-functions/getgroups.texi: Likewise.
47515         * lib/time.in.h: Update comments.
47517 2018-10-16  Bruno Haible  <bruno@clisp.org>
47519         getloadavg: Remove support for ConvexOS.
47520         * lib/getloadavg.c: Remove convex case.
47522 2018-10-16  Bruno Haible  <bruno@clisp.org>
47524         getloadavg: Remove support for Sony NEWS.
47525         * lib/getloadavg.c: Remove sony_news case.
47527 2018-10-16  Bruno Haible  <bruno@clisp.org>
47529         fsusage, mountlist, getloadavg: Remove support for Dynix/ptx.
47530         * lib/fsusage.c: Remove _SEQUENT_ case.
47531         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Update comments.
47532         * lib/mountlist.c: Don't test for MNTTABNAME.
47533         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Don't test for libseq.
47534         (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't test for MNTTABNAME.
47535         * lib/getloadavg.c: Remove _SEQUENT_ and sequent cases.
47536         * lib/stat-size.h: Don't mention the Sequent bug.
47537         * doc/posix-functions/utime.texi: Don't mention the Dynix bug.
47539 2018-10-16  Bruno Haible  <bruno@clisp.org>
47541         fsusage: Remove support for AIX 3.
47542         * lib/fsusage.c: Remove code for AIX 3.
47543         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Update comments.
47545 2018-10-16  Bruno Haible  <bruno@clisp.org>
47547         fsusage, stat-size, getloadavg: Remove support for AIX PS/2.
47548         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for dustat.h.
47549         * lib/fsusage.c: Remove code for AIX PS/2.
47550         * lib/stat-size.h (ST_NBLOCKSIZE): Likewise.
47551         * lib/getloadavg.c: Likewise.
47553 2018-10-16  Bruno Haible  <bruno@clisp.org>
47555         getloadavg: Remove support for HP-UX on m68k.
47556         * lib/getloadavg.c: Remove hp9000s300 case.
47558 2018-10-16  Bruno Haible  <bruno@clisp.org>
47560         fsusage, mountlist: Remove support for DolphinOS (an SVR3 variant).
47561         * lib/fsusage.c: Remove DOLPHIN case.
47562         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Update comments.
47563         * lib/mountlist.c: Remove MOUNTED_GETMNTTBL case.
47565 2018-10-16  Bruno Haible  <bruno@clisp.org>
47567         getloadavg: Remove support for Alliant FX/2800.
47568         * lib/getloadavg.c: Remove alliant case.
47570 2018-10-16  Bruno Haible  <bruno@clisp.org>
47572         getloadavg: Remove support for tek4300.
47573         * lib/getloadavg.c: Remove tek4300 case.
47575 2018-10-16  Bruno Haible  <bruno@clisp.org>
47577         getloadavg: Remove support for Ardent.
47578         * lib/getloadavg.c: Remove ardent case.
47580 2018-10-16  Bruno Haible  <bruno@clisp.org>
47582         mountlist: Remove support for SVR2.
47583         Reported by Andrew Borodin <aborodin@vmail.ru> in
47584         <https://lists.gnu.org/archive/html/bug-gnulib/2018-10/msg00101.html>.
47585         * lib/mountlist.c: Remove MOUNTED_FREAD case.
47586         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't define
47587         MOUNTED_FREAD.
47589 2018-10-15  Paul Eggert  <eggert@cs.ucla.edu>
47591         libc-config: merge from glibc
47592         * lib/cdefs.h (__glibc_has_attribute): New macro.
47594         regex: depend on libc-config
47595         * modules/regex (Depends-on): Add libc-config.
47596         This is needed after the recent autoupdate from glibc.
47598 2018-10-14  Bruno Haible  <bruno@clisp.org>
47600         localename: Add support for per-thread locales on Solaris 11.4.
47601         * lib/locale.in.h (newlocale, freelocale): New declarations.
47602         (duplocale): Declare also when the 'localename' module requests it.
47603         * lib/localename.c (struniq_hash_node): Renamed from hash_node.
47604         (STRUNIQ_HASH_TABLE_SIZE): Renamed from HASH_TABLE_SIZE.
47605         (struniq): Update.
47606         (struct locale_categories_names, struct locale_hash_node): New types.
47607         (LOCALE_HASH_TABLE_SIZE): New constant.
47608         (locale_hash_table, locale_lock): New variables.
47609         (pointer_hash, get_locale_t_name): New functions.
47610         (newlocale, duplocale, freelocale): New overridden functions.
47611         (gl_locale_name_thread_unsafe): Use get_locale_t_name.
47612         * m4/intlsolaris.m4: New file.
47613         * m4/localename.m4 (gl_LOCALENAME): Require gl_LOCALE_H_DEFAULTS. Invoke
47614         gt_INTL_SOLARIS. Set HAVE_NEWLOCALE, HAVE_DUPLOCALE, HAVE_FREELOCALE,
47615         REPLACE_NEWLOCALE, REPLACE_DUPLOCALE, REPLACE_FREELOCALE.
47616         * m4/locale_h.m4 (gl_LOCALE_H): Test whether newlocale, freelocale are
47617         declared.
47618         (gl_LOCALE_H_DEFAULTS): Initialize GNULIB_LOCALENAME, HAVE_NEWLOCALE,
47619         HAVE_FREELOCALE, REPLACE_NEWLOCALE, REPLACE_FREELOCALE.
47620         * modules/locale (Makefile.am): Substitute GNULIB_LOCALENAME,
47621         HAVE_NEWLOCALE, HAVE_FREELOCALE, REPLACE_NEWLOCALE, REPLACE_FREELOCALE.
47622         * modules/localename (Files): Add intlsolaris.m4.
47623         (Depends-on): Add 'locale'.
47624         (configure.ac): Invoke gl_LOCALE_MODULE_INDICATOR.
47625         * tests/test-locale-c++.cc (newlocale, freelocale): Prepare for checking
47626         the signatures.
47628 2018-10-14  Akim Demaille  <akim@lrde.epita.fr>
47630         timevar: use gethrxtime to get wall clock time
47631         clock_gettime is not portable.  gethrxtime takes the best available
47632         option to get the wall clock time, including clock_gettime (monotonic
47633         clock), and gettime (non monotonic).
47634         Also, using xtime_t instead of float preserves the precision.
47635         Suggested by Bruno Haible.
47636         * lib/xtime.h (xtime_make): Handle overflows of nanoseconds.
47637         * modules/timevar (Depends-on): We need gethrxtime.
47638         We no longer use times().
47639         (Link): Update.
47640         * lib/timevar.h (timevar_time_def): Use xtime_t.
47641         * lib/timevar.c (set_to_current_time): Use gethrxtime.
47642         (timevar_print): Instead of checking whether the timings themselves
47643         are large enough for the timevar to be printed, check the percentages.
47645 2018-10-14  Bruno Haible  <bruno@clisp.org>
47647         wcsnrtombs: Work around Solaris 11.4 bug.
47648         * m4/wcsnrtombs.m4 (gl_WCSNRTOMBS_WORKS_IN_TRADITIONAL_LOCALE): New
47649         macro.
47650         (gl_FUNC_WCSNRTOMBS): Invoke it.
47651         * doc/posix-functions/wcsnrtombs.texi: Mention the Solaris bug.
47653 2018-10-14  Bruno Haible  <bruno@clisp.org>
47655         mbsnrtowcs: Work around Solaris 11.4 bug.
47656         * m4/mbsnrtowcs.m4 (gl_MBSNRTOWCS_WORKS_IN_TRADITIONAL_LOCALE): New
47657         macro.
47658         (gl_FUNC_MBSNRTOWCS): Invoke it.
47659         * doc/posix-functions/mbsnrtowcs.texi: Mention the Solaris bug.
47661 2018-10-14  Bruno Haible  <bruno@clisp.org>
47663         doc: Update for Solaris 11.4.
47664         * doc/**/*.texi: For bugs that exist in both Solaris 11.3 and 11.4,
47665         mention Solaris 11.4.
47666         * m4/printf.m4: Update comments about Solaris.
47667         * m4/log.m4: Likewise.
47668         * m4/log10.m4: Likewise.
47669         * m4/logb.m4: Likewise.
47670         * m4/logbf.m4: Likewise.
47671         * m4/logbl.m4: Likewise.
47672         * m4/rename.m4: Likewise.
47673         * m4/wcrtomb.m4: Likewise.
47674         * m4/hostent.m4: Likewise.
47675         * m4/servent.m4: Likewise.
47677 2018-10-14  Bruno Haible  <bruno@clisp.org>
47679         floor, ceil, trunc, truncf, truncl: Defeat GCC optimizations.
47680         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Use 'floor' also through a function
47681         pointer.
47682         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Use 'ceil' also through a function
47683         pointer.
47684         * m4/trunc.m4 (gl_FUNC_TRUNC): Use 'trunc' also through a function
47685         pointer.
47686         * m4/truncf.m4 (gl_FUNC_TRUNCF): Use 'truncf' also through a function
47687         pointer.
47688         * m4/truncl.m4 (gl_FUNC_TRUNCL): Use 'truncl' also through a function
47689         pointer.
47691 2018-10-13  Akim Demaille  <akim@lrde.epita.fr>
47693         bootstrap: fix wget command for po files.
47694         * build-aux/bootstrap (po_download_command_format): Fix comment,
47695         and adjust callers.
47697 2018-10-13  Akim Demaille  <akim@lrde.epita.fr>
47699         timevar: improve the output format
47700         Suggested by Bruno Haible.
47701         See https://lists.gnu.org/archive/html/bug-gnulib/2018-10/msg00040.html.
47702         * lib/timevar.c (timevar_print): Use %7.3f for usr/sys and %11.6f for
47703         wall, since its resolution is much higher.
47705 2018-10-13  Akim Demaille  <akim@lrde.epita.fr>
47707         timevar: expect that getrusage is available.
47708         Don't keep both times and getrusage as backend: both are guaranteed by
47709         gnulib, a single one suffices.  Using getrusage is open to possibly
47710         tracking other types of resources in the future.
47711         * modules/timevar (Depends-on): Add getrusage.
47712         (configure.ac): Remove gl_TIMEVAR.
47713         (Files): Remove m4/timevar.m4.
47714         * m4/timevar.m4: Remove, rely on gnulib for getrusage.
47715         * lib/timevar.h (timevar_enabled): Clarify documentation.
47716         * lib/timevar.c: Remove all the code about times.
47717         Remove all the CPP guards about getrusage: expect it to be present
47718         (courtesy of gnulib).
47720 2018-10-12  Bruno Haible  <bruno@clisp.org>
47722         mountlist: Improve support for Solaris in 64-bit mode.
47723         Reported by David Wood <David.Wood@deshaw.com> in
47724         <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=6816>.
47725         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): On Solaris 8 or
47726         newer, define MOUNTED_GETEXTMNTENT instead of MOUNTED_GETMNTENT2.
47727         * lib/mountlist.c: Add code for MOUNTED_GETEXTMNTENT case.
47729 2018-10-12  Bruno Haible  <bruno@clisp.org>
47731         mountlist: Add support for Minix.
47732         Reported by Assaf Gordon in
47733         <https://lists.gnu.org/archive/html/bug-gnulib/2014-09/msg00074.html>.
47734         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use
47735         AC_CHECK_FUNCS to check for 'getmntinfo'.
47736         * lib/mountlist.c: Update comments.
47738 2018-10-12  Bruno Haible  <bruno@clisp.org>
47740         Make better use of Autoconf.
47741         * m4/environ.m4: Use AC_CACHE_CHECK where possible.
47742         * m4/manywarnings.m4: Likewise.
47743         * m4/manywarnings-c++.m4: Likewise.
47744         * m4/socklen.m4: Likewise.
47745         * m4/sockpfaf.m4: Likewise.
47746         * m4/stdarg.m4: Likewise.
47747         * m4/visibility.m4: Likewise.
47748         * m4/fsusage.m4: Use AC_CACHE_CHECK where possible. Modernize
47749         indentation.
47750         * m4/ls-mntd-fs.m4: Likewise.
47752 2018-10-11  Bruno Haible  <bruno@clisp.org>
47754         mountlist: Modernize platform lists.
47755         * m4/ls-mntd-fs.m4: Clarify which MOUNTED_* symbol applies to which
47756         platforms, deemphasizing the obsolete ones.
47757         * lib/mountlist.c: Likewise.
47759 2018-10-11  Bruno Haible  <bruno@clisp.org>
47761         getprogname: Add support for 32-bit programs on HP-UX.
47762         * lib/getprogname.c (getprogname) [HP-UX]: If pstat_getproc fails,
47763         try the similar functions 32-bit programs on 64-bit HP-UX.
47765 2018-10-11  Bruno Haible  <bruno@clisp.org>
47767         getprogname: Work around program name truncation when possible.
47768         * lib/getprogname.c (getprogname) [HP-UX]: When pst_ucomm is truncated,
47769         possibly use pst_cmd instead.
47771 2018-10-08  Paul Eggert  <eggert@cs.ucla.edu>
47773         fts: cleanup after FTS_NOATIME removal
47774         * lib/fts_.h (FTS_VERBATIM, FTS_OPTIONMASK, FTS_NAMEONLY)
47775         (FTS_STOP): Shrink to minimal values.  We don’t need to
47776         worry about binary compatibility in Gnulib, and the old way
47777         of doing things had a hole in the user options that caused
47778         FTS_OPTIONMASK to not work as desired.
47780 2018-10-08  Bernhard Voelker  <mail@bernhard-voelker.de>
47782         fts: remove FTS_NOATIME
47783         This reverts commit da4d6974013c822af1498941e32db774b2031765.
47784         We cannot guarantee that O_NOATIME works: e.g. openat fails
47785         with EPERM if the effective user ID of the caller does not match
47786         the owner of the file and the caller is not privileged.
47787         Downstream findutils has never picked up FTS_NOATIME.  Discussed at
47788         <https://lists.gnu.org/r/bug-gnulib/2018-09/msg00122.html>.
47789         * lib/fts_.h (FTS_NOATIME): Remove bit flag.
47790         (FTS_OPTIONMASK): Adjust.
47791         * lib/fts.c (diropen, fts_open, fts_build): Likewise.
47792         (fd_ring_check): Likewise.
47794 2018-10-08  Bruno Haible  <bruno@clisp.org>
47796         csharpcomp*, csharpexec*: Remove support for pnet.
47797         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Don't test for cscc. Don't set
47798         HAVE_CSCC.
47799         * build-aux/csharpcomp.sh.in (options_cscc): Remove variable.
47800         Don't test HAVE_CSCC.
47801         * lib/csharpcomp.c (compile_csharp_using_pnet): Remove function.
47802         (compile_csharp_class): Don't invoke it.
47803         * m4/csharpexec.m4 (gt_CSHARPEXEC): Don't test for ilrun. Don't set
47804         HAVE_ILRUN.
47805         * build-aux/csharpexec.sh.in (options_ilrun): Remove variable.
47806         Don't test HAVE_ILRUN.
47807         * lib/csharpexec.c (execute_csharp_using_pnet): Remove function.
47808         (execute_csharp_program): Don't invoke it.
47809         * m4/csharp.m4 (gt_CSHARP_CHOICE): Don't recognize --enable-csharp=pnet
47810         any more.
47812 2018-10-07  Andreas Henriksson  <andreas@fatal.se>  (tiny change)
47814         renameatu: prefer renameat2 to syscall
47815         * lib/renameatu.c (renameatu) [HAVE_RENAMEAT2]:
47816         Use renameat2 instead of syscall (Bug#32796).
47817         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Check for renameat2.
47819 2018-10-07  Benno Schulenberg  <bensberg@telfort.nl>
47821         bootstrap, gnulib-tool: use https instead of insecure rsync
47822         * build-aux/bootstrap (download_po_files, po_download_command_format):
47823         Don't try using rsync; always use wget over https to fetch PO files.
47824         * gnulib-tool (func_import): Likewise.
47825         * pygnulib/GLImport.py (GLImport.execute): Likewise.
47827 2018-10-07  Benno Schulenberg  <bensberg@telfort.nl>
47829         bootstrap, gnulib-tool: correct the translations wget command
47830         * build-aux/bootstrap (po_download_command_format2): Restrict
47831         recursion to a single level.
47832         * gnulib-tool (func_import): Likewise.
47833         * pygnulib/GLImport.py (GLImport.execute): Likewise.
47835 2018-10-07  Akim Demaille  <akim@lrde.epita.fr>
47837         doc: the gnulib snapshots are not maintained
47838         * doc/gnulib-intro.texi (Steady Development): Don't mention them.
47840 2018-10-07  Akim Demaille  <akim@lrde.epita.fr>
47842         timevar: add to lib_SOURCES
47843         * modules/timevar (lib_SOURCES): Add timevar.c and timevar.def.
47845 2018-10-07  Bruno Haible  <bruno@clisp.org>
47847         dirent: Update documentation.
47848         * doc/posix-headers/dirent.texi: The MSVC issue is fixed by Gnulib.
47850 2018-10-05  Bruno Haible  <bruno@clisp.org>
47852         strpbrk: Make it possible to namespace the defined symbol.
47853         * lib/strpbrk.c (strpbrk): Don't undefine outside of glibc.
47855 2018-10-05  Bruno Haible  <bruno@clisp.org>
47857         strcspn: Make it possible to namespace the defined symbol.
47858         * lib/strcspn.c (strcspn): Don't undefine outside of glibc.
47860 2018-10-05  Bruno Haible  <bruno@clisp.org>
47862         raise: Make it possible to namespace the defined symbol.
47863         * lib/raise.c (raise): Undefine only after the replacement function has
47864         been defined.
47865         (raise): Renamed from rpl_raise.
47866         (raise_nothrow): Move to the end of the compilation unit.
47868 2018-10-05  Bruno Haible  <bruno@clisp.org>
47870         memcmp: Make it possible to namespace the defined symbol.
47871         * lib/memcmp.c (memcmp): Don't undefine outside of glibc.
47873 2018-10-05  Bruno Haible  <bruno@clisp.org>
47875         explicit_bzero: Make it possible to namespace the defined symbol.
47876         * lib/explicit_bzero.c (explicit_bzero): Don't undefine outside of
47877         glibc.
47879 2018-10-05  Bruno Haible  <bruno@clisp.org>
47881         mkdir-p: Depend on 'mkdir'.
47882         * modules/mkdir-p (Depends-on): Add 'mkdir'.
47884 2018-10-05  Bruno Haible  <bruno@clisp.org>
47886         tempname: Depend on 'mkdir'.
47887         Reported by Maarten Bosmans <mkbosmans@gmail.com>
47888         at <https://savannah.gnu.org/bugs/?33379>.
47889         * modules/tempname (Depends-on): Add 'mkdir'.
47891 2018-10-05  Akim Demaille  <akim@lrde.epita.fr>
47893         timevar: rely on gnulib modules for time portability.
47894         * modules/timevar (Depends-on): Add sys_time, sys_times, and times.
47895         * m4/timevar.m4: Don't check for clock_t and struct tms,
47896         guaranteed by gnulib.
47897         * lib/timevar.h: Use extern "C" protection.
47898         Include <stdio.h> for FILE.
47899         * lib/timevar.c: Include sys/time.h, sys/times.h unconditionally,
47900         they are guaranteed by gnulib.
47901         Remove uses of clock as (now useless) fallback.
47903 2018-10-04  Bruno Haible  <bruno@clisp.org>
47905         sh-filename: New module.
47906         * m4/sh-filename.m4: New file.
47907         * modules/sh-filename: New file.
47908         * lib/spawni.c (_PATH_BSHELL): Use BOURNE_SHELL instead of hardcoding
47909         "/bin/sh".
47910         * tests/test-posix_spawn1.c (main): Likewise.
47911         * tests/test-posix_spawn2.c (main): Likewise.
47912         * lib/javacomp.c (compile_using_envjavac, is_envjavac_gcj,
47913         is_envjavac_gcj43): Likewise.
47914         * lib/javaexec.c (execute_java_class): Likewise.
47915         * modules/posix_spawn-internal (Depends-on): Add sh-filename.
47916         * modules/posix_spawnp-tests (Depends-on): Likewise.
47917         * modules/javacomp (Depends-on): Likewise.
47918         * modules/javaexec (Depends-on): Likewise.
47920 2018-10-04  Bruno Haible  <bruno@clisp.org>
47922         spawn-pipe tests: Avoid test failure on native Windows.
47923         * tests/test-spawn-pipe-child.c (main): On native Windows, don't expect
47924         that fd 2 is closed.
47926 2018-10-04  Bruno Haible  <bruno@clisp.org>
47928         fcntl: Make it possible to namespace the defined symbol.
47929         * lib/fcntl.c (fcntl): Undefine only after the replacement function has
47930         been defined.
47931         (fcntl): Renamed from rpl_fcntl.
47932         (rpl_fcntl_DUPFD, rpl_fcntl_DUPFD_CLOEXEC): New functions, extracted
47933         from fcntl.
47934         (klibc_fcntl): Move to the end of the compilation unit.
47936 2018-10-02  Bruno Haible  <bruno@clisp.org>
47938         vasnprintf tests: Avoid test failure on HP-UX/hppa and IRIX.
47939         * tests/test-vasnprintf.c (test_function): Change the test added on
47940         2018-09-23 to check only the 18 most significant digits.
47942         vasnprintf tests: Avoid test failure on Cygwin.
47943         * tests/test-vasnprintf.c (test_function): Change the test added on
47944         2018-09-23 to check only the 42 most significant digits.
47946 2018-10-01  Bruno Haible  <bruno@clisp.org>
47948         mkostemp, mkostemps: Update documentation.
47949         * doc/glibc-functions/mkostemp.texi: Mention the Mac OS X issue.
47950         * doc/glibc-functions/mkostemps.texi: Likewise.
47952 2018-10-01  Tom Tromey  <tom@tromey.com>
47954         mkostemp, mkostemps: Fix compilation error in C++ mode on Mac OS X.
47955         * lib/stdlib.in.h: Include <unistd.h> for mkostemp and mkostemps
47956         on OS X.
47958 2018-09-30  Pádraig Brady  <P@draigBrady.com>
47960         hmac-*: refactor to remove repetitive code
47961         * lib/hmac.c: A new parameterized single implementation.
47962         * lib/hmac-md5.c: Define parameters and include implementation.
47963         * lib/hmac-sha1.c: Likewise.
47964         * lib/hmac-sha256.c: Likewise.
47965         * lib/hmac-sha512.c: Likewise.
47966         * modules/crypto/hmac-md5: Reference the new implementation file.
47967         * modules/crypto/hmac-sha1: Likewise.
47968         * modules/crypto/hmac-sha256: Likewise.
47969         * modules/crypto/hmac-sha512: Likewise.
47970         * tests/test-hmac-md5.c: Refactor common code to a single function.
47971         * tests/test-hmac-sha1.c: Likewise.
47972         * tests/test-hmac-sha256.c: Likewise.
47973         * tests/test-hmac-sha512.c: Likewise.
47975 2018-09-30  Zhang Qing  <zhangqingl@126.com>
47977         hmac-sha512: fix hash for keys > blocksize (128 bytes)
47978         * lib/hmac-sha512.c (hmac_sha512): Set the computed/shortened
47979         key length to that output by sha512, not the blocksize.
47980         Otherwise uninitialized data from the stack
47981         is used when computing the hash.
47982         * tests/test-hmac-sha512.c: Add a shortened key test case.
47983         Reported at https://github.com/coreutils/gnulib/pull/5
47985 2018-09-30  Bruno Haible  <bruno@clisp.org>
47987         vasnprintf: Avoid warnings from GCC's -Wsign-compare.
47988         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
47989         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00105.html>.
47990         * lib/vasnprintf.c (VASNPRINTF): Cast 'count' from 'int' to
47991         'unsigned int' before comparison with an unsigned value.
47993 2018-09-30  Bruno Haible  <bruno@clisp.org>
47995         grantpt: Remove unnecessary dependency.
47996         * modules/grantpt (Depends-on): Remove 'builtin-expect'.
47998 2018-09-30  Bruno Haible  <bruno@clisp.org>
48000         timevar: Small tweaks.
48001         * lib/timevar.h: Fix comments. Add parameter names to function
48002         declarations.
48003         * lib/timevar.c: Include timevar.h immediately after config.h.
48004         * lib/timevar.def: Fix comments.
48005         * modules/timevar (Maintainer): List Akim Demaille.
48007 2018-09-30  Bruno Haible  <bruno@clisp.org>
48009         timevar: Include documentation in gnulib manual.
48010         * doc/timevar.texi: Change node and section name to 'Profiling of
48011         program phases'.
48012         In the code snippets, tweak the #includes and use GNU coding style.
48013         * doc/gnulib.texi: Include timevar.texi.
48015 2018-09-27  Akim Demaille  <akim@lrde.epita.fr>
48017         timevar: import from Bison.
48018         * m4/timevar.m4, modules/timevar, lib/timevar.h, lib/timevar.c:
48019         New files.
48020         * lib/timevar.def: New file.
48021         * doc/timevar.texi: New file.
48023 2018-09-26  Bruno Haible  <bruno@clisp.org>
48025         javacomp-script, javacomp: Add preliminary support for Java 12..17.
48026         * m4/javacomp.m4 (gt_JAVACOMP): Treat Java versions 12..17 like 11.
48027         * lib/javacomp.c (default_target_version): Likewise.
48029 2018-09-26  Bruno Haible  <bruno@clisp.org>
48031         javacomp-script, javacomp: Add support for Java 11.
48032         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 11 and
48033         target-version 11.
48034         * lib/javaversion.h: Update comments.
48035         * lib/javacomp.c (default_target_version, SOURCE_VERSION_BOUND,
48036         source_version_index, get_goodcode_snippet, get_failcode_snippet,
48037         TARGET_VERSION_BOUND, target_version_index,
48038         corresponding_classfile_version): Accept source_version 11 and
48039         target_version 11.
48040         * lib/javacomp.h: Update comments accordingly.
48042 2018-09-23  Bruno Haible  <bruno@clisp.org>
48044         vasnprintf: Fix heap memory overrun bug.
48045         Reported by Ben Pfaff <blp@cs.stanford.edu> in
48046         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00107.html>.
48047         * lib/vasnprintf.c (convert_to_decimal): Allocate one more byte of
48048         memory.
48049         * tests/test-vasnprintf.c (test_function): Add another test.
48051 2018-09-19  Paul Eggert  <eggert@cs.ucla.edu>
48053         maint: mktime.c now shared with glibc
48054         * config/srclist.txt: intprops.h, timegm.c and mktime.c
48055         are now the same in Gnulib and glibc.
48057         mktime: fix _LIBC typo
48058         * lib/mktime.c (mktime): Fix typo (misspelled "_LIBC").
48060 2018-09-19  Norihiro Tanaka  <noritnk@kcn.ne.jp>
48062         dfa: optimization for state merge
48063         * lib/dfa.c (merge2): New function.
48064         (merge_nfa_state): Use it.
48066 2018-09-18  Jim Meyering  <meyering@fb.com>
48068         dfa: trivial comment fix: s/is/if/
48069         * lib/dfa.c (maybe_disable_superset_dfa): Fix comment typo.
48071 2018-09-18  Paul Eggert  <eggert@cs.ucla.edu>
48073         dfa: use more-informative function name
48074         * lib/dfa.c (maybe_disable_superset_dfa):
48075         Rename from dfautf8noss.  Use change.
48077         dfa: tweak allocation performance
48078         * lib/dfa.c (merge_nfa_state, dfaoptimize):
48079         Prefer ptrdiff_t for indexes some more.
48080         Use char for flags, as it’s wide enough.
48081         Allocate queue and flags together, with one malloc call.
48082         No need to use xnmalloc since the multiplication and
48083         addition cannot overflow (it’s already been checked by
48084         earlier allocation).  Prefer memset to open-coding.
48086         dfa: prune states as we go
48087         * lib/dfa.c (prune): Remove.
48088         dfa: reorder enum for efficiency
48089         (merge_nfa_state): Prune as we go instead of at the end.
48090         Prefer ptrdiff_t for indexes, as this helps the compiler a bit.
48092         * lib/dfa.c (END): Now -1 again.  Reorder other elements
48093         of the enumeration to make it easier for GCC to generate
48094         efficient code by using fewer comparisons to check for
48095         ranges of values.
48096         (atom): Take advantage of the reordering.
48098 2018-09-18  Norihiro Tanaka  <noritnk@kcn.ne.jp>
48100         dfa: optimize alternation in NFA
48101         Even when similar states exist in alternation, the DFA treats them
48102         as separate items, which may complicate the transition in NFA and
48103         cause slowdown.  This change assembles the states into one.  For
48104         example, ab|ac is changed into a(b|c).  This change speeds-up
48105         matching for many branched patterns.  For example, grep speeds up
48106         more than 30× in:
48108           seq 10000 | sed 's/$/ abcdefghijklmnopqrstuvwxyz/; s/$/./' >in
48109           time -p env LC_ALL=C grep -vf in in
48111         * lib/dfa.c (prune): New function.
48112         (merge_nfa_state): New function.  It merges similar NFA states.
48113         (dfaoptimize): New function.  It seeks merged and removed nodes.
48114         (dfaanalyze): Call new function.
48115         (dfautf8noss): Change name from dfaoptimize because of addition of new
48116         function.
48117         (dfacomp): Update caller.
48119         dfa: simplify initial state
48120         Simplifying the initial state enables easier optimization of the NFA.
48121         * lib/dfa.c (enum token): Add new element BEG.
48122         (prtok): Adjust due to adding element BEG.
48123         (dfaparse): Put BEG at a head of tokens.
48124         (state_index): Adjust due to adding element BEG.
48125         (dfaanalyze): Concatenate BEG to other tokens, and simplify to
48126         build initial state.
48127         (dfamust): Adjust due to adding element BEG.  DFAMUST ignores it.
48129 2018-09-18  Bruno Haible  <bruno@clisp.org>
48131         file-has-acl: Fix test failure on Cygwin 2.9.
48132         * m4/acl.m4 (gl_FUNC_ACL): Update comments regarding Cygwin.
48133         * lib/acl-internal.h: Likewise.
48134         (HAVE_ACL_EXTENDED_FILE): Undefine on Cygwin.
48135         * lib/acl-internal.c: Update comments regarding Cygwin.
48136         * lib/acl_entries.c: Likewise.
48137         * lib/file-has-acl.c: Likewise.
48138         (file_has_acl): For Cygwin, use a different way to determine whether
48139         the "default" ACL of a directory is nontrivial.
48140         * lib/get-permissions.c: Update comments regarding Cygwin.
48141         * lib/set-permissions.c: Likewise.
48143 2018-09-18  Bruno Haible  <bruno@clisp.org>
48145         stat-time tests: Fix test failure on Cygwin.
48146         * tests/nap.h (nap_get_stat): Treat Cygwin like native Windows.
48148 2018-09-18  Paul Eggert  <eggert@cs.ucla.edu>
48150         doc: OS X 10.11 lacked ns time functions
48151         According to <https://github.com/zeromq/libzmq/issues/2175>,
48152         nanosecond-resolution timestamp functions were introduced
48153         in macOS 10.12, so document the last version (OS X 10.11)
48154         where they were absent.
48156         gettime: nanotime never existed
48157         Problem reported by Bruno Haible in:
48158         https://lists.gnu.org/r/bug-gnulib/2018-09/msg00082.html
48159         * lib/gettime.c (gettime) [HAVE_NANOTIME]: Remove unused code.
48160         * m4/gettime.m4 (gl_GETTIME): Don’t check for nanotime.
48162 2018-09-18  Bruno Haible  <bruno@clisp.org>
48164         doc: Update statement about target platforms.
48165         Reported by Simon Sobisch.
48166         * doc/gnulib-intro.texi (Target Platforms): Update. Mention
48167         restrictions on MSVC versions.
48169 2018-09-18  Bruno Haible  <bruno@clisp.org>
48171         posix_spawn tests: Fix link error on 64-bit Cygwin.
48172         * tests/test-posix_spawn1.c (environ): Remove declaration.
48173         * tests/test-posix_spawn2.c (environ): Likewise.
48174         * tests/test-posix_spawn3.c (environ): Likewise.
48175         * tests/test-posix_spawn4.c (environ): Likewise.
48176         * modules/posix_spawn-tests (Depends-on): Add 'environ'.
48177         * modules/posix_spawnp-tests (Depends-on): Likewise.
48179 2018-09-16  Paul Eggert  <eggert@cs.ucla.edu>
48181         timespec: new function current_timespec
48182         * lib/gettime.c (gettime): Prefer clock_gettime to nanotime,
48183         and don’t worry about it failing on a CLOCK_REALTIME arg.
48184         POSIX requires it to succeed and I don’t know of any
48185         counterexamples where the fallbacks would work.
48186         (current_timespec): New function, taken from Emacs.  It is more
48187         convenient than gettime, and can help register allocation.
48188         * lib/timespec.h: Include arg-nonnull.h.
48189         (current_timespec): New declaration.
48190         (gettime, settime): Declare args to be nonnull.
48191         * modules/timespec (Depends-on): Add snippet/arg-nonnull.
48193 2018-09-16  Bruno Haible  <bruno@clisp.org>
48195         setlocale: Improve locale handling on macOS 10.12 or newer.
48196         * lib/setlocale.c: Include header files for CoreFoundation. Declare
48197         gl_locale_name_canonicalize.
48198         (libintl_setlocale): Try harder to set a locale for categories LC_CTYPE
48199         and LC_MESSAGES.
48200         * m4/setlocale.m4 (gl_PREREQ_SETLOCALE): Add comment.
48202 2018-09-16  Bruno Haible  <bruno@clisp.org>
48204         Update list of locale names with scripts on macOS.
48205         * lib/localename.c (gl_locale_name_canonicalize): Update tables to
48206         match Mac OS X 10.13 and recent glibc.
48208 2018-09-16  Bruno Haible  <bruno@clisp.org>
48210         gettext: Use newer macOS APIs when possible.
48211         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Check for
48212         CFLocaleCopyPreferredLanguages.
48214 2018-09-16  Bruno Haible  <bruno@clisp.org>
48216         localename: Revisit macOS specific code.
48217         * lib/localename.c (gl_locale_name_default): Reduce code duplication.
48218         Fix comments about Mac OS X versions.
48220 2018-09-15  Bruno Haible  <bruno@clisp.org>
48222         setlocale: Improve support for locales not supported by libc.
48223         Reported by Dapeng Gao <peter@dpgao.cc> at
48224         <https://savannah.gnu.org/bugs/?54479>.
48225         * gettext-runtime/intl/setlocale.c: Include <stdio.h>.
48226         (libintl_setlocale): Use a more error-tolerant strategy when the locale
48227         to be set is not supported by libc: Emit warnings instead of failing.
48229 2018-09-15  Bruno Haible  <bruno@clisp.org>
48231         strstr, strcasestr: Add workaround against glibc-2.28 bug.
48232         Reported by Michael Brunnbauer via Siddhesh Poyarekar and Eric Blake.
48233         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Set
48234         gl_cv_func_strstr_works_always to 'no' on glibc 2.28.
48235         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Set
48236         gl_cv_func_strcasestr_works_always to 'no' on glibc 2.28.
48237         * doc/posix-functions/strstr.texi: Document the glibc 2.28 bug.
48238         * doc/glibc-functions/strcasestr.texi: Likewise.
48240 2018-09-14  Bruno Haible  <bruno@clisp.org>
48242         doc: Fix bottom of top-level page.
48243         Reported by Akim Demaille <akim.demaille@gmail.com> in
48244         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00072.html>.
48245         * doc/pastposix-functions/index.texi: Rename node to '_index' in HTML
48246         mode.
48247         * doc/gnulib.texi (Legacy Function Substitutes): Update menu
48248         accordingly.
48250 2018-09-12  Bruno Haible  <bruno@clisp.org>
48252         Add test case from a recent glibc bug.
48253         * tests/test-strstr.c (main): Add test of long needle.
48254         * tests/test-strcasestr.c (main): Likewise.
48255         * tests/test-c-strstr.c (main): Likewise.
48256         * tests/test-c-strcasestr.c (main): Likewise.
48257         * tests/test-memmem.c (main): Likewise.
48259 2018-09-12  Bruno Haible  <bruno@clisp.org>
48261         Apply Eric Blake's improvements from 2011-02-25 to more tests.
48262         * tests/test-c-strstr.c (main): Add the same tests here as well.
48264 2018-09-12  Bruno Haible  <bruno@clisp.org>
48266         Apply Jim Meyering's fix from 2015-01-11 to more tests.
48267         * tests/test-memmem.c (main): Free haystack.
48268         * tests/test-strcasestr.c (main): Likewise.
48269         * tests/test-c-strcasestr.c (main): Likewise.
48271 2018-09-11  Paul Eggert  <eggert@cs.ucla.edu>
48273         xstrtol: fix missing-TYPE_SIGNED typo
48274         * lib/xstrtol.c (TYPE_SIGNED): New macro, duplicating intprops.h.
48276 2018-09-10  Paul Eggert  <eggert@cs.ucla.edu>
48278         timespec: fix resolution confusion
48279         In normal usage, clock resolution is given in seconds, but the
48280         code was mistakenly using inverse seconds and calling it
48281         “resolution”.  Fix this, partly by renaming two identifiers.
48282         The old names will be kept for a bit, to ease transition.
48283         * lib/timespec.h (TIMESPEC_HZ, LOG10_TIMESPEC_HZ):
48284         New constants, replacing TIMESPEC_RESOLUTION and
48285         LOG10_TIMESPEC_RESOLUTION, which are now obsolescent.
48286         All uses changed.
48288 2018-09-09  Paul Eggert  <eggert@cs.ucla.edu>
48290         mktime: simplify in prep for glibc merge
48291         * lib/mktime.c, lib/timegm.c [_LIBC]:
48292         Include mktime-internal.h (a small file just for glibc)
48293         instead of using a typedef.
48295 2018-09-07  Paul Eggert  <eggert@cs.ucla.edu>
48297         intprops: minor clarification of code
48298         * lib/intprops.h (_GL_BINARY_OP_OVERFLOW):
48299         Use _GL_INT_CONVERT rather than reinventing it.
48301 2018-09-07  Bruno Haible  <bruno@clisp.org>
48303         Fix a comment.
48304         * tests/test-posix_spawn3.c (parent_main): Fix typo in comment.
48306 2018-09-07  Bruno Haible  <bruno@clisp.org>
48308         posix_spawn_file_actions_addchdir: Add tests.
48309         * tests/test-posix_spawn_file_actions_addchdir.c: New file.
48310         * tests/test-posix_spawn4.c: New file.
48311         * modules/posix_spawn_file_actions_addchdir-tests: New file.
48313 2018-09-07  Bruno Haible  <bruno@clisp.org>
48315         posix_spawn_file_actions_addchdir: New module.
48316         Suggested by Eric Blake in
48317         <https://lists.gnu.org/archive/html/bug-findutils/2018-09/msg00007.html>.
48318         * lib/spawn.in.h (posix_spawn_file_actions_addchdir): New declaration.
48319         * lib/spawn_int.h (struct __spawn_action): Add tag 'spawn_do_chdir' and
48320         union member 'chdir_action'.
48321         * lib/spawn_faction_addchdir.c: New file.
48322         * lib/spawni.c (__spawni): Implement the spawn_do_chdir action.
48323         * lib/spawn_faction_addclose.c: Test REPLACE_POSIX_SPAWN instead of
48324         HAVE_WORKING_POSIX_SPAWN.
48325         * lib/spawn_faction_adddup2.c: Likewise.
48326         * lib/spawn_faction_addopen.c: Likewise.
48327         * m4/posix_spawn_faction_addchdir.m4: New file.
48328         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test whether module
48329         'posix_spawn_file_actions_addchdir' is present and whether
48330         posix_spawn_file_actions_addchdir_np exists. Define REPLACE_POSIX_SPAWN
48331         instead of HAVE_WORKING_POSIX_SPAWN.
48332         * m4/spawn_h.m4 (gl_SPAWN_H): Test whether
48333         posix_spawn_file_actions_addchdir is declared.
48334         (gl_SPAWN_H_DEFAULTS): Initialize
48335         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
48336         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
48337         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR.
48338         * modules/spawn (Makefile.am): Substitute
48339         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
48340         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
48341         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR.
48342         * modules/posix_spawn_file_actions_addchdir: New file.
48343         * modules/posix_spawn_file_actions_addclose (Depends-on,
48344         configure.ac): Test also REPLACE_POSIX_SPAWN.
48345         * modules/posix_spawn_file_actions_adddup2 (Depends-on,
48346         configure.ac): Likewise.
48347         * modules/posix_spawn_file_actions_addopen (Depends-on,
48348         configure.ac): Likewise.
48349         * tests/test-spawn-c++.cc (posix_spawn_file_actions_addchdir): Check
48350         signature.
48351         * doc/posix-functions/posix_spawn.texi: Mention the new module.
48352         * doc/posix-functions/posix_spawnp.texi: Likewise.
48354 2018-09-06  Bruno Haible  <bruno@clisp.org>
48356         stddef: Override max_align_t on NetBSD 8.0/x86.
48357         * m4/stddef_h.m4 (gl_STDDEF_H): When testing for max_align_t, test also
48358         the value of __alignof__ (max_align_t).
48359         * doc/posix-headers/stddef.texi: Mention the issue.
48361 2018-09-06  Bruno Haible  <bruno@clisp.org>
48363         fcntl: Fix F_DUPFD_CLOEXEC behaviour on Haiku.
48364         * lib/fcntl.c (rpl_fcntl): For F_DUPFD_CLOEXEC, don't even try the
48365         system fcntl.
48366         * doc/posix-functions/fcntl.texi: Document the issue.
48368 2018-09-06  Bruno Haible  <bruno@clisp.org>
48370         count-trailing-zeros tests: Rely on limits-h module.
48371         * tests/test-count-trailing-zeros.c (ULLONG_MAX): Remove fallback
48372         definition.
48373         * modules/count-trailing-zeros-tests (Depends-on): Add 'limits-h'.
48375 2018-09-06  Bruno Haible  <bruno@clisp.org>
48377         count-leading-zeros tests: Rely on limits-h module.
48378         * tests/test-count-leading-zeros.c (ULLONG_MAX): Remove fallback
48379         definition.
48380         * modules/count-leading-zeros-tests (Depends-on): Add 'limits-h'.
48382 2018-09-06  Bruno Haible  <bruno@clisp.org>
48384         count-one-bits tests: Rely on limits-h module.
48385         * tests/test-count-one-bits.c (ULLONG_MAX): Remove fallback definition.
48386         * modules/count-one-bits-tests (Depends-on): Add 'limits-h'.
48388 2018-09-06  Bruno Haible  <bruno@clisp.org>
48390         xstrtoll: Rely on limits-h module.
48391         * lib/xstrtol.c: Don't include intprops.h.
48392         (ULLONG_MAX, LLONG_MAX, LLONG_MIN): Remove fallback definitions.
48393         * modules/xstrtol (Depends-on): Remove 'intprops'.
48394         * modules/xstrtoll (Depends-on): Add 'limits-h'.
48396 2018-09-06  Bruno Haible  <bruno@clisp.org>
48398         strtoll, strtoull: Rely on limits-h module.
48399         * lib/strtol.c (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove macros.
48400         (ULLONG_MAX, LLONG_MAX, LLONG_MIN): Remove fallback definitions.
48401         * modules/strtoll (Depends-on): Add limits-h.
48402         * modules/strtoull (Depends-on): Likewise.
48404 2018-09-06  Bruno Haible  <bruno@clisp.org>
48406         intprops tests: Fix compilation error with pre-C99 compiler.
48407         * tests/test-intprops.c (verify_stmt): New macro.
48408         (VERIFY, main): Use it.
48410 2018-09-06  Bruno Haible  <bruno@clisp.org>
48412         limits-h: Provide numerical limits macros.
48413         * lib/limits.in.h (LLONG_MIN, LLONG_MAX, ULLONG_MAX): Define also for
48414         IRIX and for GCC.
48415         (WORD_BIT, LONG_BIT): Define.
48416         * m4/limits-h.m4 (gl_LIMITS_H): Set LIMITS_H to non-empty also when
48417         <limits.h> does not define LLONG_MAX or WORD_BIT.
48418         * tests/test-limits-h.c (TYPE_SIGNED, TYPE_WIDTH, TYPE_MINIMUM,
48419         TYPE_MAXIMUM): New macros, from intprops.h.
48420         Add tests for CHAR_BIT, WORD_BIT, LONG_BIT, <type>_MIN, and <type>_MAX.
48421         * doc/posix-headers/limits.texi: Document what the 'limits-h' module
48422         provides.
48424 2018-09-05  Bruno Haible  <bruno@clisp.org>
48426         fcntl: Don't access nonexistent optional argument.
48427         Reported by Frank Busse <f.busse@imperial.ac.uk> in
48428         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00018.html>.
48429         * lib/fcntl.c (rpl_fcntl): For actions that don't take an argument,
48430         don't consume an argument. For actions that take an 'int' argument,
48431         consume an 'int' argument.
48433 2018-09-05  Eric Blake  <eblake@redhat.com>
48435         doc: mention environ pitfall
48436         * doc/posix-functions/environ.texi (environ): Assigning NULL to
48437         environ is a glibc extension.
48439 2018-09-03  Bruno Haible  <bruno@clisp.org>
48441         gnulib-tool: Fix build order when $testsbase is a subdir of $sourcebase.
48442         Reported by Antoine Luong <antoine.luong@c-s.fr> in
48443         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00008.html>.
48444         * gnulib-tool (func_import): For the tests, set a dotfirst flag.
48445         (func_emit_lib_Makefile_am): Consider the dotfirst flag.
48446         (func_emit_tests_Makefile_am): Don't consider the dotfirst flag.
48448 2018-09-02  Paul Eggert  <eggert@cs.ucla.edu>
48450         mktime: fix unlikely race+overflow bug
48451         Problem reported by Alexandre Oliva in:
48452         https://sourceware.org/bugzilla/show_bug.cgi?id=16346
48453         * lib/mktime.c (__mktime_internal): Access *OFFSET only once,
48454         to avoid an unlikely race if the compiler delays a load and
48455         if this cascades into a signed integer overflow.
48457 2018-08-31  Paul Eggert  <eggert@cs.ucla.edu>
48459         mktime, timegm: simplify glibc time64_t
48460         * lib/mktime.c, lib/timegm.c (mktime_offset_t) [_LIBC]:
48461         Now long int, not time_t, since long int is the longstanding type
48462         for this in glibc and there is no need to change it even if time_t
48463         becomes 64 bits - even int would do, though this would be a change
48464         to the glibc generated code.  When this change is merged into
48465         glibc, it should simplify the time_t vs time64_t situation.
48467         mktime, timegm: simplify merge to glibc
48468         Move code around to make a merge to glibc easier to audit.
48469         This should not change behavior.
48470         * lib/mktime.c (NEED_MKTIME_INTERNAL, NEED_MKTIME_WINDOWS)
48471         (NEED_MKTIME_WORKING): Give default values to pacify -Wundef,
48472         which glibc uses.  Default NEED_MKTIME_WORKING to DEBUG_MKTIME, to
48473         simplify later conditionals; default the others to zero.  In uses
48474         of these conditionals, explicitly spell out how _LIBC affects
48475         things, so it’s easier to review from a glibc viewpoint.
48476         (my_tzset, __tzset) [!_LIBC]: New function and macro, to better
48477         compartmentalize tzset issues.  Move system-dependent tzsettish
48478         code here from mktime.
48479         (mktime): Move tzsettish code to my_tzset, and move
48480         localtime_offset to within mktime so that it doesn’t
48481         need a separate ifdef.
48483 2018-08-27  Paul Eggert  <eggert@cs.ucla.edu>
48485         intprops: avoid evaluation of some expressions
48486         This makes EXPR_SIGNED (e) easier to use, as it no longer
48487         evaluates the expression E.  Formerly, E was required to be free
48488         of side effects.
48489         * lib/intprops.h (_GL_INT_CONVERT, _GL_INT_NEGATE_CONVERT)
48490         (EXPR_SIGNED, TYPE_WIDTH, _GL_INT_MINIMUM, _GL_INT_MAXIMUM)
48491         (_GL_SIGNED_INT_MAXIMUM): Do not evaluate the expression arg.
48493 2018-08-23  Bruno Haible  <bruno@clisp.org>
48495         getcwd: Add cross-compilation guesses.
48496         Reported by Sergio Durigan Junior <sergiodj@redhat.com> in
48497         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00130.html>.
48498         Based on a patch by Paul Eggert.
48499         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Add cross-compilation
48500         guesses for all GNU systems.
48502 2018-08-19  Bruno Haible  <bruno@clisp.org>
48504         glob-h: Formalize side effects from other modules.
48505         * m4/glob_h.m4 (gl_REPLACE_GLOB_H): New macro.
48506         * m4/glob.m4 (gl_GLOB): Invoke it.
48508         fnmatch-h: Formalize side effects from other modules.
48509         * m4/fnmatch_h.m4 (gl_REPLACE_FNMATCH_H): New macro.
48510         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Invoke it.
48512         limits-h: Formalize side effects from other modules.
48513         * m4/limits-h.m4 (gl_REPLACE_LIMITS_H): New macro.
48514         * m4/stdint.m4 (gl_STDINT_H): Invoke it.
48516 2018-08-19  Bruno Haible  <bruno@clisp.org>
48518         getpass: Move declaration to <unistd.h>.
48519         * lib/unistd.in.h (getpass): New declaration.
48520         * lib/getpass.h: Replace with a stub that just includes <unistd.h>.
48521         * m4/getpass.m4 (gl_FUNC_GETPASS): Declare through AC_DEFUN_ONCE.
48522         Require gl_UNISTD_H_DEFAULTS. Don't test whether getpass is declared.
48523         (gl_FUNC_GETPASS_GNU): Require gl_UNISTD_H_DEFAULTS and gl_FUNC_GETPASS.
48524         On glibc systems, don't set REPLACE_GETPASS to 1.
48525         * modules/getpass (Depends-on): Add 'unistd'.
48526         (configure.ac): Test also REPLACE_GETPASS. Define a module indicator.
48527         (Include): Specify <unistd.h> instead of "getpass.h".
48528         * modules/getpass-gnu (Depends-on): Merely depend on 'getpass'.
48529         (configure.ac): Sync with the configure.ac section of modules/getpass.
48530         (Include): Specify <unistd.h> instead of "getpass.h".
48531         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether getpass is declared.
48532         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETPASS, HAVE_GETPASS,
48533         REPLACE_GETPASS.
48534         * modules/unistd (Makefile.am): Substitute GNULIB_GETPASS, HAVE_GETPASS,
48535         REPLACE_GETPASS.
48536         * tests/test-unistd-c++.cc: Test also the declaration of 'getpass'.
48537         * doc/glibc-functions/getpass.texi: A length limit exists also on uClibc
48538         and musl.
48539         * NEWS: Mention the change.
48541 2018-08-19  Bruno Haible  <bruno@clisp.org>
48543         glob: Fix over-optimization due to attribute __nonnull__.
48544         * lib/glob.c (_GL_ARG_NONNULL): Define to empty.
48546 2018-08-19  Bruno Haible  <bruno@clisp.org>
48548         glob: Fix another compilation error when glob.h is not replaced.
48549         Reported by Reuben Thomas <rrt@sc3d.org> in
48550         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00112.html>.
48551         * m4/glob.m4 (gl_GLOB): Set GLOB_H to non-empty when needed.
48552         * m4/glob_h.m4 (gl_GLOB_H): Define through AC_DEFUN_ONCE.
48554 2018-08-18  Bruno Haible  <bruno@clisp.org>
48556         fnmatch: Avoid conflicting macro definitions of 'fnmatch'.
48557         Reported by Reuben Thomas <rrt@sc3d.org> in
48558         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00108.html>.
48559         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): Don't define 'fnmatch' as a macro
48560         in config.h.
48562 2018-08-18  Bruno Haible  <bruno@clisp.org>
48564         Avoid -Wcast-function-type warnings from casts after GetProcAddress.
48565         Reported by Andy Moreton <andrewjmoreton@gmail.com> in
48566         <https://lists.gnu.org/archive/html/emacs-devel/2018-08/msg00468.html>.
48567         Solution proposed by Eli Zaretskii.
48568         * lib/getaddrinfo.c (GetProcAddress): Cast result to 'void *' first.
48569         * lib/gettimeofday.c (GetProcAddress): Likewise.
48570         * lib/link.c (GetProcAddress): Likewise.
48571         * lib/physmem.c (GetProcAddress): Likewise.
48572         * lib/poll.c (GetProcAddress): Likewise.
48573         * lib/select.c (GetProcAddress): Likewise.
48574         * lib/stat-w32.c (GetProcAddress): Likewise.
48576 2018-08-18  Bruno Haible  <bruno@clisp.org>
48578         glob: Fix another compilation error when glob.h is not replaced.
48579         Reported and fix proposed by Reuben Thomas <rrt@sc3d.org> again.
48580         * lib/globfree.c: Include <libc-config.h>.
48582 2018-08-18  Bruno Haible  <bruno@clisp.org>
48584         glob: Fix compilation error when glob.h is not replaced.
48585         Reported and fix proposed by Reuben Thomas <rrt@sc3d.org> in
48586         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00096.html>.
48587         * lib/glob_pattern_p.c: Include <libc-config.h>.
48588         * modules/glob (Depends-on): Add libc-config.
48590 2018-08-18  Bruno Haible  <bruno@clisp.org>
48592         scratch_buffer: Add tests.
48593         * tests/test-scratch-buffer.c: New file.
48594         * modules/scratch_buffer-tests: New file.
48596 2018-08-18  Bruno Haible  <bruno@clisp.org>
48598         scratch_buffer: Fix include file.
48599         Reported by Reuben Thomas <rrt@sc3d.org> in
48600         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00082.html>.
48601         * lib/scratch_buffer.h: Include <libc-config.h> first. Add
48602         double-inclusion guard.
48604 2018-08-18  Bruno Haible  <bruno@clisp.org>
48606         glob-h: Revert Paul Eggert's revert.
48607         * m4/glob_h.m4: Revert to previous state.
48608         * modules/glob-h: Likewise.
48610 2018-08-18  Paul Eggert  <eggert@cs.ucla.edu>
48612         glob-h: always build glob.h
48613         This works around a problem reported by Reuben Thomas in:
48614         http://lists.gnu.org/r/bug-gnulib/2018-08/msg00079.html
48615         This workaround always builds glob.h, even on platforms that
48616         do not need it; perhaps this could be improved someday.
48617         * m4/glob_h.m4 (gl_GLOB_H): Do not set or use GLOB_H, since glob.h
48618         is always created now.
48619         * modules/glob-h (BUILT_SOURCES, glob.h): Always build glob.h.
48621 2018-08-13  Bruno Haible  <bruno@clisp.org>
48623         monetary: Simplify m4 code.
48624         * m4/monetary_h.m4 (gl_MONETARY_H): Define through AC_DEFUN_ONCE.
48625         (gl_MONETARY_H_BODY): Inline into gl_MONETARY_H. Remove macro.
48627 2018-08-13  Bruno Haible  <bruno@clisp.org>
48629         fnmatch, fnmatch-gnu: Fix compilation error on Mac OS X.
48630         Reported by Jeroen Meijer <jjgmeijer@gmail.com> in
48631         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00046.html>
48632         and by Paul J. Lucas <paul@lucasmail.org> in
48633         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00069.html>.
48634         * m4/fnmatch_h.m4 (gl_FNMATCH_H): Define through AC_DEFUN_ONCE.
48636 2018-08-11  Bruno Haible  <bruno@clisp.org>
48638         setlocale: Trivial simplification.
48639         * lib/setlocale.c (setlocale_unixlike): Remove redundant #if.
48641 2018-08-11  Paul Eggert  <eggert@cs.ucla.edu>
48643         verify: port 'assume' to traditional tools
48644         * lib/verify.h (assume): Port better to Oracle Studio 12.6
48645         and other tools that use /*NOTREACHED*/ comments.
48647 2018-08-10  Bruno Haible  <bruno@clisp.org>
48649         fnmatch-gnu: Fix compilation error in C++ namespace mode on Mac OS X.
48650         * modules/fnmatch-gnu (configure.ac): Invoke gl_MODULE_INDICATOR.
48651         * lib/fnmatch.in.h (fnmatch): Skip _GL_CXXALIASWARN if module
48652         'fnmatch-gnu' is in use.
48654 2018-08-07  Bruno Haible  <bruno@clisp.org>
48656         glob-h: Add tests.
48657         * tests/test-glob-h.c: New file, partially based on tests/test-glob.c.
48658         * tests/test-glob.c: Reorder #includes. Remove tests that are moved to
48659         tests/test-glob-h.c.
48660         * modules/glob-h-tests: New file.
48661         * tests/test-glob-h-c++.cc: Renamed from tests/test-glob-c++.cc. Add
48662         conditions.
48663         * modules/glob-h-c++-tests: Renamed from modules/glob-c++-tests.
48664         * modules/glob-tests (Depends-on): Remove glob-c++-tests.
48666 2018-08-07  Bruno Haible  <bruno@clisp.org>
48668         glob-h: New module.
48669         * lib/glob.in.h: Use nearly the usual gnulib idioms for header file
48670         replacements.
48671         * lib/glob.c: Include <config.h>.
48672         * m4/glob_h.m4: New file.
48673         * m4/glob.m4 (gl_GLOB): Require gl_GLOB_H. Remove code that is moved to
48674         glob_h.m4. Set HAVE_GLOB, REPLACE_GLOB, HAVE_GLOB_PATTERN_P,
48675         REPLACE_GLOB_PATTERN_P as appropriate.
48676         (gl_PREREQ_GLOB): Don't require AC_C_RESTRICT and
48677         AC_USE_SYSTEM_EXTENSIONS, now done through module 'glob-h'.
48678         * modules/glob-h: New file.
48679         * modules/glob (Files): Remove lib/glob.in.h, lib/glob-libc.h.
48680         (Dependencies): Add glob-h. Remove extensions, snippet/*, libc-config,
48681         lstat, sys_stat. Change conditions.
48682         (configure.ac): Test HAVE_GLOB, REPLACE_GLOB, HAVE_GLOB_PATTERN_P,
48683         REPLACE_GLOB_PATTERN_P. Set module indicator.
48684         (Makefile.am): Remove code that is moved to glob-h.
48685         * doc/posix-headers/glob.texi: Mention the 'glob-h' module.
48686         * modules/posixcheck (Depends-on): Add glob-h.
48688 2018-08-06  Bruno Haible  <bruno@clisp.org>
48690         Force generation of substitute .h file when C++ support is enabled.
48691         * m4/ansi-c++.m4 (gl_ANSI_CXX): New macro.
48692         * modules/ansi-c++-opt (configure.ac): Just require gl_ANSI_CXX.
48693         * m4/fnmatch_h.m4 (gl_FNMATCH_H): If C++ support is enabled, set
48694         FNMATCH_H to non-empty.
48695         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): If C++ support is enabled, set
48696         ICONV_H to non-empty.
48697         * m4/monetary_h.m4 (gl_MONETARY_H_BODY): If C++ support is enabled, set
48698         MONETARY_H to non-empty.
48699         * m4/utime_h.m4 (gl_UTIME_H): If C++ support is enabled, set UTIME_H to
48700         non-empty.
48702 2018-08-06  Bruno Haible  <bruno@clisp.org>
48704         fnmatch-h: Fix test compilation error on mingw (regression from today).
48705         * lib/fnmatch.in.h: Fix conditions.
48707 2018-08-06  Bruno Haible  <bruno@clisp.org>
48709         sys_resource: Relicense under LGPLv2+.
48710         John Malmberg's approval is in
48711         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00031.html>.
48712         * modules/sys_resource (License): Change to LGPLv2+.
48714 2018-08-06  Bruno Haible  <bruno@clisp.org>
48716         fnmatch-h: Add tests.
48717         * tests/test-fnmatch-h.c: New file.
48718         * modules/fnmatch-h-tests: New file.
48719         * tests/test-fnmatch-h-c++.cc: New file.
48720         * modules/fnmatch-h-c++-tests: New file.
48722 2018-08-06  Bruno Haible  <bruno@clisp.org>
48724         fnmatch-h: New module.
48725         * lib/fnmatch.in.h: Use the usual gnulib idioms for header file
48726         replacements.
48727         (FNM_*): Don't redefine if fnmatch exists and we are not overriding it.
48728         (fnmatch): Use the usual gnulib idiom for function declarations. Enable
48729         'posixcheck' warning.
48730         * m4/fnmatch_h.m4: New file.
48731         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Require gl_FNMATCH_H. Remove
48732         code that is moved to fnmatch_h.m4. When fnmatch does not exist, don't
48733         bother testing whether it is working. Set HAVE_FNMATCH, REPLACE_FNMATCH
48734         as appropriate.
48735         * modules/fnmatch-h: New file.
48736         * modules/fnmatch (Files): Remove lib/fnmatch.in.h.
48737         (Dependencies): Add fnmatch-h. Remove extensions, snippet/*. Change
48738         conditions.
48739         (configure.ac): Test HAVE_FNMATCH and REPLACE_FNMATCH. Set module
48740         indicator.
48741         (Makefile.am): Remove code that is moved to fnmatch-h.
48742         * modules/fnmatch-gnu (configure.ac): Test HAVE_FNMATCH and
48743         REPLACE_FNMATCH.
48744         * doc/posix-headers/fnmatch.texi: Mention the 'fnmatch-h' module.
48745         * modules/posixcheck (Depends-on): Add fnmatch-h.
48747 2018-08-06  Bruno Haible  <bruno@clisp.org>
48749         Enable more C++ tests.
48750         * modules/inttypes-tests (Depends-on): Add inttypes-c++-tests.
48751         * modules/monetary-tests (Depends-on): Add monetary-c++-tests.
48752         * modules/strings-tests (Depends-on): Add strings-c++-tests.
48753         * modules/sys_resource-tests (Depends-on): Add sys_resource-c++-tests.
48754         * modules/utime-h-tests (Depends-on): Add utime-h-c++-tests.
48756 2018-08-06  Bruno Haible  <bruno@clisp.org>
48758         getopt-posix, utime-h: Ensure the .h file gets regenerated when needed.
48759         * modules/getopt-posix (Makefile.am): Add Makefile dependency for
48760         getopt.h.
48761         * modules/utime-h (Makefile.am): Add Makefile dependency for utime.h.
48763 2018-08-05  Bruno Haible  <bruno@clisp.org>
48765         utime-h: Generate header file when module 'posixcheck' is in use.
48766         * m4/utime_h.m4 (gl_UTIME_H): If module 'posixcheck' is in use, set
48767         UTIME_H to non-empty.
48769 2018-08-05  Bruno Haible  <bruno@clisp.org>
48771         monetary: Generate header file when module 'posixcheck' is in use.
48772         * m4/monetary_h.m4 (gl_MONETARY_H_BODY): If module 'posixcheck' is in
48773         use, set MONETARY_H to non-empty.
48775 2018-08-05  Bruno Haible  <bruno@clisp.org>
48777         iconv-h: Generate header file when module 'posixcheck' is in use.
48778         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): If module 'posixcheck' is in use,
48779         set ICONV_H to non-empty.
48781 2018-08-05  Bruno Haible  <bruno@clisp.org>
48783         Optimize the "checking whether ... is declared without a macro" checks.
48784         Suggested by Paul Eggert in
48785         <https://lists.gnu.org/archive/html/bug-gnulib/2011-01/msg00339.html>.
48786         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Expand to nothing if the
48787         Gnulib module 'posixcheck' is not in use.
48789 2018-08-05  Bruno Haible  <bruno@clisp.org>
48791         iconv-h: Enable 'posixcheck' warnings.
48792         * m4/iconv_h.m4 (gl_ICONV_H): Check for declarations of iconv and
48793         iconv_open.
48794         * lib/iconv.in.h (iconv_open, iconv): Use _GL_WARN_ON_USE.
48796 2018-08-05  Bruno Haible  <bruno@clisp.org>
48798         Fix link error regarding 'rpl_environ' (regression from 2012-11-21).
48799         * m4/extern-inline.m4: Add more comments.
48800         * lib/warn-on-use.h (_GL_WARN_ON_USE_ATTRIBUTE): New macro.
48801         * lib/unistd.in.h (rpl_environ): Use it instead of _GL_WARN_ON_USE.
48802         * lib/math.in.h (_GL_WARN_REAL_FLOATING_DECL): Likewise.
48804 2018-08-04  Bruno Haible  <bruno@clisp.org>
48806         New module 'posixcheck'.
48807         * modules/posixcheck: New file.
48808         * m4/posixcheck.m4: New file.
48809         * doc/gnulib-tool.texi (Finding POSIX substitutes): New section.
48810         (Which modules?): Reference it.
48812 2018-08-01  Assaf Gordon  <assafgordon@gmail.com>
48814         dfa: fix memory leak
48815         * lib/dfa.c (dfafree): Add missing free() on dfa->superset.
48817 2018-08-01  Paul Eggert  <eggert@cs.ucla.edu>
48819         ieee754-h: new module
48820         It looks like Emacs can use this for some NaN processing.
48821         Emacs uses it only on double NaNs so it should be safe.
48822         * MODULES.html.sh (func_all_modules): Add ieee754-h.
48823         * config/srclist.txt: Mention ieee754.h in a comment.
48824         * doc/glibc-headers/ieee754.texi (ieee754.h):
48825         Gnulib now has a substitute that should work
48826         except for long double and for non-IEEE platforms.
48827         * lib/ieee754.in.h, m4/ieee754-h.m4, modules/ieee754-h:
48828         * modules/ieee754-h-tests, tests/test-ieee754-h.c: New files.
48830 2018-07-27  Bruno Haible  <bruno@clisp.org>
48832         iswcntrl: Mention minor problem on macOS.
48833         * doc/posix-functions/iswcntrl.texi: Mention oddity on macOS.
48835 2018-07-26  Colin Watson  <cjwatson@debian.org>
48837         bootstrap, gnulib-tool: fix translations rsync
48838         Previously, we created files such as $pobase/Makefile.in.in and then the
48839         subsequent rsync would immediately delete them.
48840         * build-aux/bootstrap (po_download_command_format): Avoid deleting
48841         non-.po files in target directory when rsyncing translations.
48842         * gnulib-tool (func_import): Likewise.
48843         * pygnulib/GLImport.py (GLImport.execute): Likewise.
48845 2018-07-25  Jim Meyering  <meyering@fb.com>
48847         bootstrap: reinstate definition fo gnulib_mk.
48848         That variable is used at least by cppi.
48849         * build-aux/bootstrap (gnulib_mk): Restore definition.
48850         This reverts the deletion from v0.1-1844-gc66dba9ba.
48852 2018-07-23  Bruno Haible  <bruno@clisp.org>
48854         doc: For module names, use texinfo markup @code{} or @samp{}.
48855         * doc/alloca.texi: Mark gnulib module names with @code.
48856         * doc/alloca-opt.texi: Likewise.
48857         * doc/quote.texi: Likewise.
48858         * doc/posix-functions/freopen.texi: Likewise.
48859         * doc/posix-functions/open.texi: Likewise.
48860         * doc/posix-functions/readlink.texi: Likewise.
48861         * doc/posix-functions/readlinkat.texi: Likewise.
48862         * doc/posix-functions/stdout.texi: Likewise.
48863         * doc/posix-functions/stderr.texi: Likewise.
48864         * doc/posix-functions/unlink.texi: Likewise.
48865         * doc/posix-functions/unlinkat.texi: Likewise.
48866         * doc/posix-functions/utime.texi: Likewise.
48867         * doc/posix-functions/utimensat.texi: Likewise.
48868         * doc/posix-functions/utimes.texi: Likewise.
48869         * doc/posix-headers/stdint.texi: Likewise.
48870         * doc/glibc-functions/futimesat.texi: Likewise.
48871         * doc/glibc-functions/lutimes.texi: Likewise.
48872         * doc/glibc-functions/memmem.texi: Likewise.
48874 2018-07-23  Werner LEMBERG  <wl@gnu.org>
48876         doc: Avoid some overfull lines in the TeX output.
48877         * doc/glibc-functions/futimesat.texi: Replace a long @code with a
48878         @example.
48879         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Insert a
48880         newline before the long URL.
48881         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Likewise.
48882         * doc/relocatable-maint.texi: Use @smallexample instead of @example.
48883         Add line breaks in code snippets.
48885 2018-07-17  Paul Eggert  <eggert@cs.ucla.edu>
48887         hard-locale: simplify by removing hard-locale.m4
48888         * m4/hard-locale.m4: Remove.
48889         * modules/hard-locale (Files): Remove m4/hard-locale.m4.
48890         (configure.ac): Do not call gl_HARD_LOCALE.
48892         gnulib-tool: limit line length for git send-email
48893         * gnulib-tool (func_import): Break actioncmd log line
48894         into multiple lines.
48896 2018-07-16  Bruno Haible  <bruno@clisp.org>
48898         ffs: Ensure declaration on mingw.
48899         Reported by Daniel P. Berrangé <berrange@redhat.com>
48900         in https://lists.gnu.org/archive/html/bug-gnulib/2018-07/msg00061.html.
48901         * m4/ffs.m4 (gl_FUNC_FFS): Check whether ffs() not only exists but is
48902         also declared.
48904 2018-07-13  Paul Eggert  <eggert@cs.ucla.edu>
48906         regex-tests: add dependency
48907         * modules/regex-tests (Depends-on): Add gettext-h.
48908         This is needed given the recent changes to regex,
48909         which no longer depends on gettext-h.
48911 2018-07-06  Paul Eggert  <eggert@cs.ucla.edu>
48913         regex: now in sync with glibc
48914         * config/srclist.txt: Gnulib and glibc regex code
48915         are synchronized again.
48917 2018-07-05  Paul Eggert  <eggert@cs.ucla.edu>
48919         renameatu: rename from renameat2
48920         It's looking like Glibc will add a renameat2 function
48921         that is incompatible with Gnulib renameat2; see:
48922         https://sourceware.org/ml/libc-alpha/2018-07/msg00064.html
48923         To help avoid future confusion, rename renameat2 to something else.
48924         Use the name 'renameatu', as the Gnulib function is close to the
48925         Glibc function.  Perhaps someday there will also be a renameat2
48926         Gnulib module, which mimicks the future glibc renameat2, but that
48927         can wait as nobody seems to need such a module now.
48928         * NEWS: Mention this.
48929         * lib/renameatu.c: Rename from lib/renameat2.c.
48930         * lib/renameatu.h: Rename from lib/renameat2.h.
48931         * modules/renameatu: Rename from modules/renameat2.
48932         * modules/renameatu-tests: Rename from modules/renameat2-tests.
48933         All uses of "renameat2" in identifiers or file name
48934         changed to "renameatu", except for two instances in
48935         lib/renameatu.c that deal with the Linux kernel's
48936         renameat2 syscall.
48938 2018-07-04  Paul Eggert  <eggert@cs.ucla.edu>
48940         gnulib-tool: minor tweaks for --gnu-make
48941         * gnulib-tool: Do not allow --gnu-make in test modes,
48942         since they all require automake.
48943         (func_emit_lib_Makefile_am): Don’t emit automake comment
48944         if --gnu-make.
48946         regex: work around conditional-dependencies glitch
48947         * modules/regex (Depends-on): Add langinfo.
48948         Without this change, I had problems building an experimental
48949         version of GNU Emacs.  The symptom of the bug was a message
48950         ‘./configure: line 12726: test: =: unary operator expected’.
48951         This was due to a line in gl_FUNC_NL_LANGINFO that invokes
48952         ‘test $HAVE_LANGINFO_CODESET = 1’ even though HAVE_LANGINFO_CODESET
48953         was unset.  Although gl_FUNC_NL_LANGINFO has
48954         ‘AC_REQUIRE([gl_LANGINFO_H])’ and gl_LANGINFO_H always sets
48955         HAVE_LANGINFO_CODESET to 0 or 1, gnulib-tool with
48956         --conditional-dependencies sometimes arranges for the
48957         gl_FUNC_NL_LANGINFO code to be executed before the gl_LANGINFO_H
48958         code.  Since the regex code includes <langinfo.h> it should be
48959         depending on the langinfo module anyway, and this happens to work
48960         around the bug, so install that as a workaround for now.  To
48961         reproduce the original problem, run the following shell script on
48962         the version of Gnulib just before this patch was installed.
48963                 rm -fr foo
48964                 mkdir foo
48965                 cat >foo/configure.ac <<'EOF'
48966                 AC_INIT(GNU Emacs, 27.0.50, bug-gnu-emacs@gnu.org, , https://www.gnu.org/software/emacs/)
48967                 gl_EARLY
48968                 gl_INIT
48969                 AC_OUTPUT
48970                 EOF
48971                 ./gnulib-tool --import --conditional-dependencies --gnu-make --dir foo regex
48972                 ./gnulib-tool --copy build-aux/install-sh foo/install-sh
48973                 ./gnulib-tool --copy build-aux/config.sub foo/config.sub
48974                 ./gnulib-tool --copy build-aux/config.guess foo/config.guess
48975                 cd foo
48976                 aclocal -I m4
48977                 autoconf
48978                 ./configure --with-included-regex
48980 2018-07-01  Paul Eggert  <eggert@cs.ucla.edu>
48982         wchar: fix bug when checking for ‘inline’
48983         I discovered this when looking into using the regex module
48984         with Emacs.
48985         * m4/wchar_h.m4 (gl_WCHAR_H_INLINE_OK): Fix bug introduced in
48986         2016-08-17T23:09:38Z!skunk@iSKUNK.ORG; the code compiled
48987         conftest1.c and conftest2.c but these files were not created.
48988         As far as I can see, this check never worked and nobody reported
48989         it until now, which is a bit worrisome.
48991 2018-06-30  Jim Meyering  <meyering@fb.com>
48993         bootstrap: s/--option val/--option=val/
48994         * build-aux/bootstrap (gnulib_tool_options): Change the
48995         spelling of "--option val" pairs to "--option=val", for
48996         aesthetics, and also so that this file no longer triggers
48997         a common help2man syntax-check warning when copied into
48998         projects like grep, gzip, etc.
49000 2018-07-01  Paul Eggert  <eggert@cs.ucla.edu>
49002         manywarnings: omit -Wswitch-default
49003         This should make things more consistent, as we already ignore
49004         -Wswitch-enum.  Problem reported by Reuben Thomas; see:
49005         https://lists.gnu.org/r/bug-gnulib/2018-05/msg00179.html
49006         * build-aux/g++-warning.spec, build-aux/gcc-warning.spec:
49007         Add -Wswitch-default.
49008         * m4/manywarnings-c++.m4 (gl_MANYWARN_ALL_GCC_CXX_IMPL):
49009         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
49010         Remove -Wswitch-default.
49012         regex: revert most trimming
49013         Problems reported by Bruno Haible in:
49014         https://lists.gnu.org/r/bug-gnulib/2018-07/msg00001.html
49015         * modules/regex (Depends-on): Add lock, memcmp, memmove,
49016         and wctype back in.  lock because regex users shouldn’t
49017         need to know that regex needs locking, and the rest because
49018         gnulib-tool should ordinarily ignore them anyway.
49020 2018-06-30  Paul Eggert  <eggert@cs.ucla.edu>
49022         regex: trim module dependencies
49023         * modules/regex (Depends-on): Remove gettext-h and lock,
49024         since the regex code should work OK without these modules,
49025         and Emacs uses it that way.  Also remove memcmp, memmove,
49026         and wctype, as these modules are obsolete and should not be
49027         needed any more.
49029 2018-06-29  Paul Eggert  <eggert@cs.ucla.edu>
49031         regex: glibc does not use intprops.h
49032         Maybe we can talk glibc into using intprops.h someday, but
49033         now doesn’t seem to be a good time.
49034         * lib/regcomp.c (TYPE_SIGNED): Remove; regex_internal.h now defines.
49035         * lib/regex_internal.h [_LIBC]: Do not include intprops.h.
49036         (TYPE_SIGNED, INT_ADD_WRAPV): New macros.
49038 2018-06-28  Paul Eggert  <eggert@cs.ucla.edu>
49040         regex: port to recently proposed glibc regex merge
49041         This patch is inspired by Adhemerval Zanella's recent proposal
49042         https://www.sourceware.org/ml/libc-alpha/2018-06/msg00905.html
49043         to merge glibc and Gnulib regex.  It aims to simplify the merge on
49044         the glibc side, without keeping Gnulib portable.
49045         * lib/regex.h: Fix a problem with glibc installed-header checking,
49046         as follows:
49047         (_Restrict_): Prefer __restrict if defined or if GCC 2.95 or later.
49048         (_Restrict_arr_): Prefer __restrict_arr if defined,
49049         otherwise prefer _Restrict_ if C99 or GCC 3.1 or later (but not C++).
49050         * lib/regex_internal.c (re_string_realloc_buffers, build_wcs_buffer)
49051         (build_wcs_upper_buffer, build_upper_buffer)
49052         (re_string_translate_buffer, re_string_context_at):
49053         Move decls here from lib/regex_internal.h, for glibc internal tests.
49054         (build_wcs_upper_buffer): Use __wcrtomb, not wcrtomb, fixing
49055         glibc BZ #18496.
49056         * lib/regex_internal.h (lock_fini) [_LIBC]: Cast to 0 to pacify
49057         -Wunused-value.
49058         (bitset_set, bitset_clear, bitset_contain, bitset_empty)
49059         (bitset_set_all, bitset_copy, bitset_not, bitset_merge)
49060         (bitset_mask): Now static inline, and without any __attribute__
49061         ((unused)) decoration, for glibc internal tests.
49063 2018-06-25  Bruno Haible  <bruno@clisp.org>
49065         threadlib: Fix LIBMULTITHREAD on platforms where --as-needed is enabled.
49066         Reported by Erik Auerswald <auerswal@unix-ag.uni-kl.de>
49067         in <https://lists.gnu.org/archive/html/coreutils/2018-06/msg00063.html>.
49068         * m4/threadlib.m4 (gl_THREADLIB_BODY): Check whether the linker supports
49069         --as-needed/--no-as-needed and --push-state/--pop-state. When defining
49070         USE_POSIX_THREADS_WEAK or USE_SOLARIS_THREADS_WEAK or
49071         USE_PTH_THREADS_WEAK, define LIBMULTITHREAD in such a way that -lpthread
49072         / -lthread / -lpth does not get optimized away by a preceding
49073         --as-needed option.
49075 2018-06-25  Bruno Haible  <bruno@clisp.org>
49077         Continue to use spaces for indentation, not tabs.
49078         * MODULES.html.sh: Untabify.
49079         * doc/regex.texi: Likewise.
49080         * lib/acl-internal.c: Likewise.
49081         * lib/dfa.c: Likewise.
49082         * lib/exclude.c: Likewise.
49083         * lib/exclude.h: Likewise.
49084         * lib/get-permissions.c: Likewise.
49085         * lib/gettimeofday.c: Likewise.
49086         * lib/parse-datetime.y: Likewise.
49087         * lib/pselect.c: Likewise.
49088         * lib/set-permissions.c: Likewise.
49089         * lib/time.in.h: Likewise.
49090         * m4/canonicalize.m4: Likewise.
49091         * m4/gc.m4: Likewise.
49092         * m4/gnulib-common.m4: Likewise.
49093         * m4/pthread_sigmask.m4: Likewise.
49094         * m4/vararrays.m4: Likewise.
49095         * tests/test-digest.h: Likewise.
49096         * tests/test-fcntl-h.c: Likewise.
49097         * tests/test-timespec.c: Likewise.
49098         * tests/uniwbrk/test-uc-wordbreaks.c: Likewise.
49100 2018-06-25  Bruno Haible  <bruno@clisp.org>
49102         manywarnings: Don't enable -Wjump-misses-init warnings by default.
49103         * build-aux/gcc-warning.spec: Add -Wjump-misses-init.
49104         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C)): Remove
49105         -Wjump-misses-init.
49107 2018-06-25  Jim Meyering  <meyering@fb.com>
49109         acl-internal.h: remove _GL_ATTRIBUTE_CONST on void function
49110         * lib/acl-internal.h (free_permission_context): Remove that
49111         attribute directive.  Otherwise, it would provoke this from GCC 9:
49112         lib/acl-internal.h:300:3: error: 'const' attribute on function \
49113           returning 'void' [-Werror=attributes]
49115 2018-06-24  Jim Meyering  <meyering@fb.com>
49117         parse-datetime: accommodate gcc-4.8.5
49118         Bruno Haible reported the build failure in
49119         https://lists.gnu.org/r/bug-gnulib/2018-06/msg00066.html
49120         * lib/parse-datetime.y (parse_datetime2): Remove leading "static"
49121         on declaration of new local.
49123 2018-06-24  Bruno Haible  <bruno@clisp.org>
49125         af_alg: Fail in continuable manner on Linux/powerpc64le.
49126         Reported by Assaf Gordon <assafgordon@gmail.com>
49127         in <https://lists.gnu.org/archive/html/coreutils/2018-06/msg00034.html>.
49128         * lib/af_alg.c (afalg_stream): On non-seekable streams, try a single-
49129         byte send() as the first round.
49131 2018-06-24  Bruno Haible  <bruno@clisp.org>
49133         af_alg: Fix state of stream after sendfile() succeeds.
49134         * lib/af_alg.c (afalg_stream): Invoke fflush and lseek, to ensure that
49135         the stream is correctly positioned afterwards.
49136         * modules/crypto/af_alg (Depends-on): Add fflush.
49137         * tests/test-digest.h (test_digest_on_files): Verify that after the
49138         operation the stream is positioned at end of file.
49140 2018-06-24  Jim Meyering  <meyering@fb.com>
49142         canon-host: take GCC9's advice rather than ignoring warning
49143         Pádraig Brady suggested not to ignore this GCC9 advice.
49144         * lib/canon-host.c: Undo preceding change.
49145         * lib/canon-host.h: Instead, declare with _GL_ATTRIBUTE_MALLOC.
49147         parse-datetime.y: avoid spurious GCC 9 warning
49148         * lib/parse-datetime.y (parse_datetime2): Save RELATIVE_TIME_0 into
49149         a function local prior to the first "goto fail".  The prior use would
49150         evoke this:
49151         parse-datetime.y: In function 'parse_datetime2':
49152         parse-datetime.y:1791:19: error: jump skips variable initialization \
49153           [-Werror=jump-misses-init]
49154         parse-datetime.y:2385:2: note: label 'fail' defined here
49155         parse-datetime.y:188:43: note: '({anonymous})' declared here
49156         parse-datetime.y:1841:12: note: in expansion of macro 'RELATIVE_TIME_0'
49158         canon-host.c: avoid spurious GCC 9 warning
49159         * lib/canon-host.c: Suppress GCC9's -Wsuggest-attribute=malloc.
49161         manywarnings: accommodate GCC 9.0-pre: remove -Wchkp and -Wabi
49162         * build-aux/gcc-warning.spec: Add them here, each with an explanation.
49163         * m4/manywarnings.m4: Remove them.
49164         Otherwise, building coreutils, I would see this:
49165         cc1: error: deprecated command line option '-Wchkp' [-Werror]
49166         cc1: error: -Wabi won't warn about anything [-Werror=abi]
49167         cc1: note: -Wabi warns about differences from the most up-to-date ABI,\
49168           which is also used by default
49169         cc1: note: use e.g. -Wabi=11 to warn about changes from GCC 7
49171 2018-06-24  Bruno Haible  <bruno@clisp.org>
49173         af_alg tests: Add another test.
49174         * tests/test-digest.h (test_digest_on_files): Also check a large file
49175         with a skipped header.
49176         * tests/test-md5.c: Include macros.h.
49177         * tests/test-sha1.c: Likewise.
49178         * tests/test-sha256.c: Likewise.
49179         * tests/test-sha512.c: Likewise.
49180         * modules/crypto/md5-tests (Files): Add tests/macros.h.
49181         * modules/crypto/sha1-tests (Files): Likewise.
49182         * modules/crypto/sha256-tests (Files): Likewise.
49183         * modules/crypto/sha512-tests (Files): Likewise.
49185 2018-06-24  Pádraig Brady  <P@draigBrady.com>
49187         maint: clarify comments about sticky EOF
49188         * lib/af_alg.c: Be more direct that we can't
49189         assume stickiness of EOF for portability reasons.
49190         * lib/md5.c: Clarify that this isn't just a glibc issue.
49191         * lib/sha1.c: Likewise.
49192         * lib/sha256.c: Likewise.
49193         * lib/sha512.c: Likewise.
49195 2018-06-24  Bruno Haible  <bruno@clisp.org>
49197         af_alg: Comment and style improvements.
49198         * lib/af_alg.c (alg_socket): Use 'size_t' as index into a string.
49199         (afalg_buffer, afalg_stream): Improve comments.
49201 2018-06-24  Pádraig Brady  <P@draigBrady.com>
49203         af_alg: disable kernel hash functions by default
49204         All the kernel routines were seen to be significantly slower
49205         with these relatively recent components on an i3-2310M system:
49206           kernel-4.10.6-200.fc25.x86_64
49207           openssl-1.0.2m-1.fc25.x86_64
49208         sha1 was nearly twice as slow in the kernel for example.
49209         Further considerations why this should not be the default, at:
49210         https://lists.gnu.org/r/coreutils/2018-06/msg00034.html
49212         * m4/af_alg.m4: Require --with-linux-crypto to enable.
49213         * m4/gl-openssl.m4: Tweak accordingly.
49215 2018-06-24  Pádraig Brady  <P@draigBrady.com>
49217         af_alg: avoid hangs when reading from streams
49218         * lib/af_alg.c (afalg_stream): Don't assume EOF is sticky,
49219         and thus avoid doing a fread() when feof() is set.
49220         * lib/md5.c: Ensure feof() is called before fread().
49221         * lib/sha1.c: Likewise.
49222         * lib/sha256.c: Likewise.
49223         * lib/sha512.c: Likewise.
49225 2018-06-24  Pádraig Brady  <P@draigBrady.com>
49227         af_alg: fix error handling when hash not returned
49228         * lib/af_alg.c (afalg_stream): Handle the case where we've
49229         successfully written data to the kernel in the read/write loop,
49230         but the kernel doesn't respond with the hash.
49232 2018-06-24  Paul Eggert  <eggert@cs.ucla.edu>
49234         libc-config: merge from glibc
49235         * lib/cdefs.h (__inline, __restrict):
49236         Copy from current glibc.  This fixes glibc bug 17721,
49237         which Gnulib had already fixed in a different way.
49238         (__nonnull): Lessen the distance from glibc by using the
49239         glibc definition inside an ‘#ifndef __nonnull’.
49240         (__attribute_nonstring__): New macro, copied from
49241         current glibc.
49242         * lib/libc-config.h (__attribute_nonstring__): New undef.
49243         (__restrict): Remove; workaround no longer needed.
49244         Keep the __inline workaround, though, as it uses HAVE___INLINE to
49245         support more compilers than the glibc __inline can.
49247 2018-06-24  Bruno Haible  <bruno@clisp.org>
49249         mbrtowc, wcwidth: Fix MT-safety bug (regression from 2018-06-23).
49250         * lib/mbrtowc.c (enc_t): New enum type.
49251         (locale_enc, locale_enc_cached): New functions.
49252         (mbrtowc): Eliminate static variables. Use locale_enc_cached instead.
49253         * lib/wcwidth.c (is_locale_utf8, is_locale_utf8_cached): New functions.
49254         (wcwidth): Eliminate static variables. Use is_locale_utf8_cached
49255         instead.
49256         * m4/mbrtowc.m4 (gl_PREREQ_MBRTOWC): Require AC_C_INLINE.
49257         * m4/wcwidth.m4 (gl_PREREQ_WCWIDTH): New macro.
49258         * modules/wcwidth (configure.ac): Invoke it.
49260 2018-06-24  Bruno Haible  <bruno@clisp.org>
49262         wchar-single: Fix test failure in wcwidth tests.
49263         * tests/test-wcwidth.c (main): If the wchar-single module is present,
49264         skip the tests in the C locale.
49266 2018-06-23  Pádraig Brady  <P@draigBrady.com>
49268         crypto: mention --without-linux-crypto in --with-openssl --help
49269         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Mention that linux crypto
49270         routines take precedence in --with-openssl help output.
49272 2018-06-23  Pádraig Brady  <P@draigBrady.com>
49274         wchar-single: a new module to enable optimizations in wchar replacements
49275         * lib/mbrtowc.c (mbrtowc): Only check locale_charset() once if
49276         GNULIB_WCHAR_SINGLE is enabled.
49277         * lib/wcwidth.c (wcwidth): Likewise.
49279 2018-06-23  Bruno Haible  <bruno@clisp.org>
49281         libc-config: Fix conflict with FreeBSD include files.
49282         * lib/cdefs.h (__nonnull): Remove definition.
49283         * lib/libc-config.h (__nonnull): Remove undefinition.
49285 2018-06-21  Paul Eggert  <eggert@cs.ucla.edu>
49287         random_r: do not crash if state is unaligned
49288         Problem reported by Bruce Korb in:
49289         https://lists.gnu.org/r/bug-gnulib/2018-06/msg00030.html
49290         I reproduced the crash on 32-bit sparc with Oracle Studio 12.6
49291         with 'cc -O2 -xmemalign=8s'.
49292         * lib/random_r.c: Include string.h, for memcpy.
49293         (get_int32, set_int32): New functions.
49294         (__srandom_r, __initstate_r, __setstate_r, __random_r):
49295         Use them to avoid assumption that state pointer is aligned.
49296         (__random_r): Avoid integer overflow if INT_MAX == UINT32_MAX.
49297         * tests/test-random_r.c (test_failed): New function.
49298         (main): Use it, to test for alignment bugs.
49300         random_r: omit unnecessary include
49301         * lib/random_r.c: Do not include limits.h.
49303         random, random_r: merge from glibc
49304         * lib/random.c, lib/random_r.c:
49305         Include libc-config.h if !_LIBC, not config.h unilaterally.
49306         * lib/random.c:
49307         Do not include stdint.h or time.h; not needed.
49308         Include libc-lock.h if _LIBC, and define substitute macros otherwise.
49309         (unsafe_state): Rename from generator.  All uses changed.
49310         Use C99-style initializers.
49311         (__random, __srandom, __initstate, __setstate): Rename from
49312         non-underscored version, but define it to non-underscored version
49313         on Gnulib.  Add a lock.
49314         * lib/random_r.c (__srandom_r, __initstate_r, __setstate_r, __random_r):
49315         Likewise.
49316         Do not include <stdint.h>; not needed since stdlib.h defines int32_t.
49317         (weak_alias, __set_errno) [!_LIBC]: Remove; now done by libc-config.
49318         (__srandom_r): Use int32_t instead of long int where int32_t will do.
49319         (__random_r): Use uint32 to fix glibc bug 17343.
49320         * modules/random, modules/random_r (Depends-on): Add libc-config.
49321         Depend on stdint only if $HAVE_RANDOM = 0.
49323 2018-06-19  Jim Meyering  <meyering@fb.com>
49325         README-release: also run any check-very-expensive tests
49326         * top/README-release: Adjust instructions so they run the
49327         check-very-expensive tests when there is such a target.
49329 2018-06-18  Bruno Haible  <bruno@clisp.org>
49331         pthread_rwlock_rdlock: Add comments regarding glibc behaviour.
49332         * m4/pthread_rwlock_rdlock.m4: Add comment.
49333         * doc/posix-functions/pthread_rwlock_rdlock.texi: Mention that rwlocks
49334         are reader-preferring in glibc.
49335         * doc/posix-functions/pthread_rwlock_tryrdlock.texi: Likwise.
49336         * doc/posix-functions/pthread_rwlock_timedrdlock.texi: Likewise.
49338 2018-06-17  Paul Eggert  <eggert@cs.ucla.edu>
49340         crypto: use byteswap
49341         * lib/md4.c, lib/md5.c, lib/sha1.c, lib/sha256.c, lib/sha512.c:
49342         * lib/sm3.c: Include <byteswap.h>.
49343         (SWAP): Use its macros rather than reinventing the wheel.
49344         * modules/crypto/md4, modules/crypto/md5-buffer:
49345         * modules/crypto/sha1-buffer, modules/crypto/sha256-buffer:
49346         * modules/crypto/sha512-buffer, modules/crypto/sm3:
49347         (Depends-on): Add byteswap.
49349 2018-06-17  Pádraig Brady  <P@draigBrady.com>
49351         gendocs.sh: fix support for legacy --texi2html
49352         * build-aux/gendocs.sh: Restrict use of TOP_NODE_UP_URL
49353         to the default makeinfo invocation.
49354         Reported by Bruce Korb
49356 2018-06-17  Bruno Haible  <bruno@clisp.org>
49358         gettext po infrastructure: Update from current gettext git.
49359         Reported by Akim Demaille <akim@lrde.epita.fr>.
49360         * build-aux/po/Makefile.in.in: Update from current gettext git.
49361         * build-aux/po/remove-potcdate.sin: Likewise.
49362         * config/srclist.txt: Temporarily disable sync for these files.
49364 2018-06-17  Bruno Haible  <bruno@clisp.org>
49366         getloadavg: Return 0 on Windows without Cygwin.
49367         * lib/getloadavg.c: Don't assume that the symbol WINDOWS32 is defined.
49369 2018-06-17  Paul Smith  <psmith@gnu.org>
49371         getloadavg: Allow building on Windows without Cygwin
49372         * lib/getloadavg.c: Reinstate ifdef for HAVE_UNISTD_H.
49373         * m4/getloadavg.m4: Check for unistd.h.
49375 2018-06-03  Paul Eggert  <eggert@cs.ucla.edu>
49377         Port crypto/af_alg to GCC 4.8.4
49378         Problem reported by Peter Simons in:
49379         https://lists.gnu.org/r/bug-gnulib/2018-06/msg00002.html
49380         * modules/crypto/af_alg (Depends-on): Add c99 if USE_AF_ALG.
49382 2018-05-27  Colin Watson  <cjwatson@debian.org>
49384         bootstrap: document source fetching in --help
49385         * build-aux/bootstrap (usage): Document how Gnulib sources are fetched.
49387 2018-04-09  Colin Watson  <cjwatson@debian.org>
49389         bootstrap: allow non-submodule control of gnulib
49390         * build-aux/bootstrap: Honour GNULIB_URL and GNULIB_REVISION in
49391         bootstrap.conf when fetching gnulib using "git clone" or via
49392         GNULIB_SRCDIR.
49394 2018-05-21  Paul Eggert  <eggert@cs.ucla.edu>
49396         crypto: omit stream ops Emacs doesn’t need
49397         * lib/md5.c (md5_stream):
49398         * lib/sha1.c (sha1_stream):
49399         * lib/sha256.c (shaxxx_stream, sha256_stream, sha224_stream):
49400         * lib/sha512.c (shaxxx_stream, sha512_stream, sha384_stream):
49401         Compile stream functions only if GL_COMPILE_CRYPTO_STREAM is
49402         defined.  Emacs needs this, as it does not use the stream
49403         operations and doesn’t need all the af_alg stuff we’ve recently
49404         added.  Perhaps a similar change is needed to the other crypto
49405         modules, but this patch changes only those needed for Emacs.
49406         * modules/crypto/md5-buffer, modules/crypto/sha1-buffer:
49407         * modules/crypto/sha256-buffer, modules/crypto/sha512-buffer:
49408         New modules, used by Emacs.
49409         * modules/crypto/md5, modules/crypto/sha1, modules/crypto/sha256:
49410         * modules/crypto/sha512: Rewrite to depend on the new modules.
49412 2018-05-20  Pádraig Brady  <P@draigBrady.com>
49414         fts: avoid a memory leak edge case
49415         * lib/fts.c (fts_open): Set an appropriate fts_level
49416         so that an immediate fts_close() will free the allocation.
49417         * tests/test-fts.c (fts_dealloc): Add a test case which
49418         will trigger under valgrind or address sanitizer.
49419         Fixes https://bugs.gnu.org/31439
49421 2018-05-20  Bruno Haible  <bruno@clisp.org>
49423         wcwidth tests: Fix link error.
49424         * modules/wcwidth-tests (Makefile.am): Link test-wcwidth against
49425         $(LIBUNISTRING).
49427 2018-05-20  Bruno Haible  <bruno@clisp.org>
49429         regex: Fix "error: possibly undefined macro: gl_GLIBC21".
49430         * modules/regex (Files): Add m4/glibc21.m4.
49432 2018-05-20  Bruno Haible  <bruno@clisp.org>
49434         localcharset: Optimize.
49435         * lib/localcharset.c (alias_table): Comment out no-op mappings for
49436         platforms where these don't matter. This reduces the table size,
49437         which in turn reduces the lookup time.
49439 2018-05-19  Bruno Haible  <bruno@clisp.org>
49441         localcharset: Map the locale encodings found in newer OSes.
49442         * lib/localcharset.c (alias_table): Add mapping for locale encodings
49443         found in FreeBSD 11, NetBSD 7, Solaris 10, Openindiana, HP-UX 11.31,
49444         IRIX 6.5, Minix 3.3.
49445         * lib/localcharset.h: Update comments accordingly. Also for Cygwin 2.9.
49447 2018-05-19  Bruno Haible  <bruno@clisp.org>
49449         localcharset: Move mapping tables into the code. Use a binary search.
49450         * lib/localcharset.h: Document the GNU canonical names for character
49451         encodings here.
49452         * lib/localcharset.c: Don't include <fcntl.h>, <unistd.h>,
49453         relocatable.h, configmake.h.
49454         (O_NOFOLLOW, ISSLASH, DIRECTORY_SEPARATOR, getc, volatile): Remove
49455         macros.
49456         (charset_aliases): Remove variable.
49457         (get_charset_aliases): Remove function.
49458         (struct table_entry): New type.
49459         (alias_table, locale_table): New constants.
49460         (locale_charset): Use the alias_table or locale_table to get the
49461         canonicalized encoding name.
49462         * lib/config.charset: Remove file.
49463         * lib/ref-add.sin: Remove file.
49464         * lib/ref-del.sin: Remove file.
49465         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't require gl_FCNTL_O_FLAGS,
49466         AC_CANONICAL_HOST, gl_GLIBC21. Don't check for getc_unlocked.
49467         * modules/localcharset (Notice): Remove.
49468         (Files): Remove config.charset, ref-add.sin, ref-del.sin, fcntl-o.m4,
49469         glibc21.m4.
49470         (Depends-on): Remove configmake.
49471         (configure.ac): Define LOCALCHARSET_TESTS_ENVIRONMENT to empty.
49472         (Makefile.am): Simplify.
49473         * build-aux/prefix-gnulib-mk: Remove special code for the removed files.
49475 2018-05-19  Bruno Haible  <bruno@clisp.org>
49477         localcharset: Add a manual test.
49478         * tests/test-localcharset.c: New file.
49479         * modules/localcharset-tests: New file.
49481 2018-05-19  Bruno Haible  <bruno@clisp.org>
49483         localcharset: Remove support for obsolete platforms.
49484         * lib/config.charset: Remove support for Linux/libc5, glibc-2.0.x, and
49485         Mac OS X 10.2. Comment out dubious entry for Solaris.
49487 2018-05-19  Jim Meyering  <meyering@fb.com>
49489         gnupload: adjust comment
49490         * build-aux/gnupload: Add FIXME-2020 comment, to make it slightly
49491         more likely we'll remove the just-added code in a year or two.
49493 2018-05-19  Bruno Haible  <bruno@clisp.org>
49495         gnupload: Fix "gpg-agent is not available in this session" error.
49496         * build-aux/gnupload (GPG): Pick the right GNUPG executable to use.
49498 2018-05-16  Paul Eggert  <eggert@cs.ucla.edu>
49500         crypto/af_alg: fix --help
49501         * m4/af_alg.m4: Avoid spurious newline in --help output.
49503 2018-05-13  Bruno Haible  <bruno@clisp.org>
49505         nl_langinfo: Fix compilation error on Android.
49506         * lib/nl_langinfo.c (nl_langinfo): Define values for the items GROUPING,
49507         INT_CURR_SYMBOL, etc. only if these items are defined.
49509 2018-05-13  Bruno Haible  <bruno@clisp.org>
49511         truncate: Fix compilation error on Android.
49512         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Test also whether 'truncate' is
49513         declared. Set HAVE_DECL_TRUNCATE, not HAVE_TRUNCATE.
49514         * lib/unistd.in.h (truncate): Test HAVE_DECL_TRUNCATE, not
49515         HAVE_TRUNCATE.
49516         * modules/truncate: Likewise.
49517         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_TRUNCATE,
49518         not HAVE_TRUNCATE.
49519         * modules/unistd (Makefile.am): Substitute HAVE_DECL_TRUNCATE, not
49520         HAVE_TRUNCATE.
49521         * doc/posix-functions/truncate.texi: Mention the issue.
49523 2018-05-13  Bruno Haible  <bruno@clisp.org>
49525         pthread: Fix compilation error on Android.
49526         * lib/pthread.in.h: Use _GL_ALREADY_INCLUDING_PTHREAD_H to shortcut
49527         recursive inclusion of this file.
49529 2018-05-13  Bruno Haible  <bruno@clisp.org>
49531         posix_spawn: Fix compilation error on Android.
49532         * lib/spawn.in.h (posix_spawnattr_t): Consider also the case
49533         HAVE_POSIX_SPAWNATTR_T = 1 && HAVE_POSIX_SPAWN = 0.
49534         (posix_spawn_file_actions_t): Consider also the case
49535         HAVE_POSIX_SPAWN_FILE_ACTIONS_T = 1 && HAVE_POSIX_SPAWN = 0.
49537 2018-05-13  Bruno Haible  <bruno@clisp.org>
49539         tsearch: Move from K&R C to ANSI C.
49540         * lib/tsearch.c (tfind): Convert definition to ANSI C.
49542 2018-05-13  Bruno Haible  <bruno@clisp.org>
49544         tsearch: Fix compilation error on Android.
49545         * lib/search.in.h (twalk): Declare when HAVE_TWALK, not HAVE_TSEARCH,
49546         is 0.
49547         (GNULIB_defined_tsearch, GNULIB_defined_twalk): New macros.
49548         * lib/tsearch.c (tsearch, tfind, tdelete): Define only if
49549         GNULIB_defined_tsearch is true.
49550         (twalk): Define only if GNULIB_defined_twalk is true.
49551         * modules/tsearch (configure.ac): Compile tsearch.c also if HAVE_TWALK
49552         is 0.
49553         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Set HAVE_TWALK.
49554         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize HAVE_TWALK.
49555         * modules/search (Makefile.am): Substitute HAVE_TWALK.
49557 2018-05-13  Bruno Haible  <bruno@clisp.org>
49559         imaxdiv: Fix compilation error on Android.
49560         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Set HAVE_IMAXDIV_T to 0 if imaxdiv_t
49561         is not defined.
49562         * lib/inttypes.in.h (imaxdiv_t): Define if HAVE_IMAXDIV_T, not
49563         HAVE_DECL_IMAXDIV, is 0.
49564         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Initialize HAVE_IMAXDIV_T.
49565         * modules/inttypes-incomplete (Makefile.am): Substitute HAVE_IMAXDIV_T.
49567 2018-05-13  Bruno Haible  <bruno@clisp.org>
49569         Support selective inclusion mechanism of recent mingw.org header files.
49570         Reported by Eli Zaretskii <eliz@gnu.org>.
49571         * lib/sys_types.in.h: On mingw, when __need_off_t, __need___off64_t,
49572         __need_ssize_t, or __need_time_t is defined, just include the system's
49573         <sys/types.h>.
49574         * lib/locale.in.h: On mingw, when __need_locale_t is defined, just
49575         include the system's <locale.h>.
49577 2018-05-13  Bruno Haible  <bruno@clisp.org>
49579         Avoid compilation error due to 'mmap' on Android.
49580         * lib/vma-iter.c (_FILE_OFFSET_BITS): Undefine on Android.
49581         * lib/get-rusage-as.c (_FILE_OFFSET_BITS): Likewise.
49582         * tests/zerosize-ptr.h (_FILE_OFFSET_BITS, __USE_FILE_OFFSET64):
49583         Undefine on Android.
49585 2018-05-13  Bruno Haible  <bruno@clisp.org>
49587         Add cross-compilation guesses for Linux systems without glibc.
49588         * m4/chown.m4 (AC_FUNC_CHOWN): Add cross-compilation guess for Linux.
49589         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
49590         * m4/link.m4 (gl_FUNC_LINK): Likewise.
49591         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
49592         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
49593         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
49594         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
49595         * m4/mknod.m4 (gl_FUNC_MKNOD): Likewise.
49596         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
49597         * m4/readlink.m4 (gl_FUNC_READLINK): Likewise.
49598         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
49599         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
49600         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
49601         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
49602         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
49603         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
49604         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
49605         * m4/utimens.m4 (gl_UTIMENS): Likewise.
49607 2018-05-13  Bruno Haible  <bruno@clisp.org>
49609         getpagesize: Fix compilation error on Android.
49610         * m4/getpagesize.m4 (gl_CHECK_FUNC_GETPAGESIZE): New macro.
49611         (gl_FUNC_GETPAGESIZE): Invoke it instead of AC_CHECK_FUNC.
49612         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Don't invoke
49613         AC_CHECK_FUNC. Instead, invoke gl_CHECK_FUNC_GETPAGESIZE and define
49614         HAVE_GETPAGESIZE accordingly.
49615         * modules/getcwd (Files): Add m4/getpagesize.m4.
49617 2018-05-13  Bruno Haible  <bruno@clisp.org>
49619         tcgetsid: Fix compilation error on Android.
49620         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Use AC_LINK_IFELSE instead of
49621         AC_CHECK_FUNC.
49623 2018-05-13  Bruno Haible  <bruno@clisp.org>
49625         getpass: Fix configure test for Android.
49626         * m4/getpass.m4 (gl_PREREQ_GETPASS): Use AC_LINK_IFELSE instead of
49627         AC_CHECK_FUNC.
49629 2018-05-13  Bruno Haible  <bruno@clisp.org>
49631         ffs: Fix compilation error on Android.
49632         * m4/ffs.m4 (gl_FUNC_FFS): Use AC_LINK_IFELSE instead of AC_CHECK_FUNC.
49634 2018-05-13  Bruno Haible  <bruno@clisp.org>
49636         mkfifo: Fix compilation error on Android.
49637         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Use AC_LINK_IFELSE instead of
49638         AC_CHECK_FUNC.
49640 2018-05-13  Bruno Haible  <bruno@clisp.org>
49642         c-strtod: Fix configure test for Android.
49643         * m4/c-strtod.m4 (gl_C_STRTOD): Use AC_LINK_IFELSE instead of
49644         AC_CHECK_FUNC.
49646 2018-05-13  Bruno Haible  <bruno@clisp.org>
49648         random: Fix compilation error on Android.
49649         * m4/random.m4 (gl_FUNC_RANDOM): Use AC_LINK_IFELSE instead of
49650         AC_CHECK_FUNC.
49652 2018-05-13  Bruno Haible  <bruno@clisp.org>
49654         grantpt: Fix compilation error on Android.
49655         * m4/grantpt.m4 (gl_FUNC_GRANTPT): Use AC_LINK_IFELSE instead of
49656         AC_CHECK_FUNC.
49658 2018-05-13  Bruno Haible  <bruno@clisp.org>
49660         stdioext: Fix compilation errors with newer Android headers.
49661         * lib/stdio-impl.h (fp_, fp_ub): Define differently for Android.
49662         (__SLBF, __SNBF, __SRD, __SWR, __SRW, __SEOF, __SERR, __SOFF): Define
49663         fallbacks for Android.
49664         * lib/fpending.c: Update comments.
49665         * lib/fpurge.c: Likewise.
49666         * lib/freadable.h: Likewise.
49667         * lib/freadable.c: Likewise.
49668         * lib/freadahead.c: Likewise.
49669         * lib/freading.h: Likewise.
49670         * lib/freadptr.c: Likewise.
49671         * lib/fseterr.c: Likewise.
49672         * lib/fwritable.h: Likewise.
49673         * lib/fwritable.c: Likewise.
49674         * lib/fwriting.h: Likewise.
49675         * lib/fwriting.c: Likewise.
49677 2018-05-13  Bruno Haible  <bruno@clisp.org>
49679         doc: Add info about Android versions 2.0 to 8.1.
49680         * doc/**/*.texi: Add info about functions in all released versions of
49681         Bionic.
49683 2018-05-12  Bruno Haible  <bruno@clisp.org>
49685         fseeko: On mingw, don't use the hidden function _fseeki64.
49686         Reported by Eli Zaretskii <eliz@gnu.org>.
49687         * m4/fseeko.m4 (gl_PREREQ_FSEEKO): Test whether _fseeki64 is declared.
49688         * lib/fseeko.c (fseeko): Use _fseeki64 only if it is declared.
49690 2018-05-12  Bruno Haible  <bruno@clisp.org>
49692         glob: Choose 'dirent_type' in a way that works better on mingw.
49693         Reported and suggested by Eli Zaretskii <eliz@gnu.org>.
49694         * lib/glob.c (dirent_type): Define as uint_fast32_t.
49696 2018-05-12  Bruno Haible  <bruno@clisp.org>
49698         execute, spawn-pipe: Avoid warning about redefining 'close'.
49699         Reported by Eli Zaretskii <eliz@gnu.org>.
49700         * lib/execute.c: Undefine 'close' before redefining it.
49701         * lib/spawn-pipe.c: Likewise.
49703 2018-05-12  Bruno Haible  <bruno@clisp.org>
49705         nanosleep: Avoid test failure on mingw when it has nanosleep.
49706         Reported by Eli Zaretskii <eliz@gnu.org>.
49707         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check whether alarm() exists.
49708         If it does not exist, use a simpler test program that does not call
49709         alarm().
49711 2018-05-10  Bruno Haible  <bruno@clisp.org>
49713         lock, cond, thread, tls: Use a different symbol as libpthread witness.
49714         Reported by Devin Hussey <husseydevin@gmail.com>.
49715         Based on a patch by Paul Eggert.
49716         * lib/glthread/lock.h (pthread_in_use): Use 'pthread_mutexattr_gettype'
49717         as witness of libpthread.
49718         * lib/glthread/cond.h (pthread_in_use): Likewise.
49719         * lib/glthread/thread.h (pthread_in_use): Likewise.
49720         * lib/glthread/tls.h (pthread_in_use): Likewise.
49722 2018-05-10  Bruno Haible  <bruno@clisp.org>
49724         cond tests: Fix compilation error on Solaris.
49725         * tests/test-cond.c: Include <unistd.h> before defining 'yield' as a
49726         macro.
49728 2018-05-10  Bruno Haible  <bruno@clisp.org>
49730         doc: Add partial info about Android 4.3.
49731         * doc/*-functions/*.texi: Add info about functions that were added
49732         to Bionic between Android 4.3 and Android 9.0.
49734 2018-05-10  Bruno Haible  <bruno@clisp.org>
49736         doc: Add info about Android 9.0.
49737         * doc/**/*.texi: Add info about functions and headers in Bionic from
49738         Android 9.0.
49740 2018-05-09  Paul Eggert  <eggert@cs.ucla.edu>
49742         af_alg: fix my typo in afalg_buffer
49743         * lib/af_alg.c (afalg_buffer): Fix typo I recently introduced.
49744         (afalg_stream): Simplify and avoid the need for a runtime test
49745         at the end.
49747         af_alg: recover better from crypto failures
49748         * lib/af_alg.c (afalg_stream): Recover from crypto failures if the
49749         input stream is seekable, by repositioning the stream back to
49750         where it was, possibly by just calling sendfile with an offset
49751         arg.  This lets us return -EAFNOSUPPORT instead of -EIO in some
49752         cases, which lets our callers try again with user-mode code.
49753         * modules/crypto/af_alg (Depends-on): Depend on fseeko and ftello
49754         instead of on fflush and lseek.
49756         af_alg: distiguish I/O errors better
49757         * lib/af_alg.c (afalg_buffer, afalg_stream): Return -EAFNOSUPPORT,
49758         not -EIO, if it’s OK for the caller to try again with user-mode code.
49759         (afalg_stream) [!_WIN32 || __CYGWIN__]: Return -EIO (not possibly
49760         some other error number) if fflush fails, as the caller should not
49761         try again that case.
49763         af_alg: avoid gotos
49764         * lib/af_alg.c (afalg_buffer, afalg_stream): Rewrite to avoid
49765         gotos, as they were a source of unreliability and made the code a
49766         bit harder to follow.
49768         af_alg: don’t leak file descriptors into children
49769         * lib/af_alg.c (alg_socket): Use SOCK_CLOEXEC when creating sockets.
49770         This code should be compiled only on recent GNU/Linux platforms
49771         so we shouldn’t have to also depend on the accept4 module.
49773         af_alg: coalesce socket creation
49774         * lib/af_alg.c (alg_socket): New function.
49775         (afalg_buffer, afalg_stream): Use it.  This avoids some
49776         code duplication and gotos.
49778         af_alg: fix file descriptor leak
49779         * lib/af_alg.c (afalg_stream): Close leak.
49781         af_alg: Pacify --enable-gcc-warnings on GCC 8
49782         * lib/af_alg.c (afalg_buffer, afalg_stream): Reorder local decls
49783         and checking to pacify gcc -Wjump-misses-init on GCC 8.
49785 2018-05-07  Paul Eggert  <eggert@cs.ucla.edu>
49787         af_alg: Pacify --enable-gcc-warnings
49788         Problem reported by Assaf Gordon in:
49789         https://lists.gnu.org/r/bug-gnulib/2018-05/msg00041.html
49790         * lib/af_alg.c (afalg_buffer): Move local decls to pacify
49791         gcc -Wjump-misses-init.
49792         * lib/sha512.c (shaxxx_stream): Now static.
49794 2018-05-06  Bruno Haible  <bruno@clisp.org>
49796         af_alg: Add ability to use Linux kernel crypto API on data in memory.
49797         * lib/af_alg.h (afalg_buffer): New declaration.
49798         * lib/af_alg.c (afalg_buffer): New function.
49800 2018-05-06  Bruno Haible  <bruno@clisp.org>
49802         af_alg: Avoid warnings.
49803         * lib/af_alg.h (afalg_stream): Mark fallback declaration as inline.
49804         * m4/af_alg.m4 (gl_AF_ALG): Require AC_C_INLINE.
49806 2018-05-06  Bruno Haible  <bruno@clisp.org>
49808         crypto/{md5,sha1,sha256,sha512} tests: Add benchmarks.
49809         * tests/bench-digest.h: New file.
49810         * tests/bench-md5.c: New file.
49811         * tests/bench-sha1.c: New file.
49812         * tests/bench-sha224.c: New file.
49813         * tests/bench-sha256.c: New file.
49814         * tests/bench-sha384.c: New file.
49815         * tests/bench-sha512.c: New file.
49816         * modules/crypto/md5-tests (Files): Add tests/bench-md5.c,
49817         tests/bench-digest.h.
49818         (Depends-on): Add getrusage, gettimeofday.
49819         (Makefile.am): Add variables to build bench-md5.
49820         * modules/crypto/sha1-tests (Files): Add tests/bench-sha1.c,
49821         tests/bench-digest.h.
49822         (Depends-on): Add getrusage, gettimeofday.
49823         (Makefile.am): Add variables to build bench-sha1.
49824         * modules/crypto/sha256-tests (Files): Add tests/bench-sha224.c,
49825         tests/bench-sha256.c, tests/bench-digest.h.
49826         (Depends-on): Add getrusage, gettimeofday.
49827         (Makefile.am): Add variables to build bench-sha224, bench-sha256.
49828         * modules/crypto/sha512-tests (Files): Add tests/bench-sha384.c,
49829         tests/bench-sha512.c, tests/bench-digest.h.
49830         (Depends-on): Add getrusage, gettimeofday.
49831         (Makefile.am): Add variables to build bench-sha384, bench-sha512.
49833 2018-05-06  Bruno Haible  <bruno@clisp.org>
49835         af_alg: Fix a resource leak.
49836         * lib/af_alg.c (afalg_stream): Close socket before returning -EINVAL.
49837         New local variable 'result'.
49839 2018-05-06  Bruno Haible  <bruno@clisp.org>
49841         af_alg: Fix bug with streams that are not at position 0.
49842         * lib/af_alg.c (afalg_stream): Before sendfile, invoke fflush. Don't
49843         assume that the stream is positioned at position 0.
49844         * lib/af_alg.h (afalg_stream): Mention restriction regarding the state
49845         of the stream.
49846         * lib/md5.h (md5_stream): Likewise.
49847         * lib/sha1.h (sha1_stream): Likewise.
49848         * lib/sha256.h (sha256_stream, sha224_stream): Likewise.
49849         * lib/sha512.h (sha512_stream, sha384_stream): Likewise.
49850         * modules/crypto/af_alg (Depends-on): Add fflush, lseek.
49852         crypto/{md5,sha1,sha256,sha512} tests: Enhance test.
49853         * tests/test-digest.h (test_digest_on_files): Add a test with a FILE
49854         stream that is not positioned at the beginning.
49856 2018-05-06  Bruno Haible  <bruno@clisp.org>
49858         af_alg: Add configure option to enable/disable use of Linux crypto API.
49859         Suggested by Assaf Gordon <assafgordon@gmail.com>.
49860         * m4/af_alg.m4 (gl_AF_ALG): Add AC_ARG_WITH invocation. Define C macro
49861         USE_LINUX_CRYPTO_API.
49862         * lib/af_alg.h: Test USE_LINUX_CRYPTO_API, not HAVE_LINUX_IF_ALG_H.
49863         * lib/af_alg.c: Likewise.
49865 2018-05-06  Bruno Haible  <bruno@clisp.org>
49867         Followup to 'af_alg: New module.'.
49868         * modules/crypto/md5 (Depends-on): Remove sys_socket, sys_stat.
49869         * modules/crypto/sha1 (Depends-on): Likewise.
49870         * modules/crypto/sha256 (Depends-on): Likewise.
49871         * modules/crypto/sha512 (Depends-on): Likewise.
49873 2018-05-05  Paul Eggert  <eggert@cs.ucla.edu>
49875         crypto/{md5,sha1,sha256,sha512}: simplify
49876         * lib/md5.c (md5_stream):
49877         * lib/sha1.c (sha1_stream):
49878         * lib/sha256.c (shaxxx_stream):
49879         Simplify, partly by assuming C99.
49880         * lib/sha256.c (shaxxx_stream):
49881         New function, which implements both sha256 and sha224.
49882         Simplify, partly by assuming C99.
49883         (sha256_stream, sha224_stream):
49884         Use it to avoid code duplication, removing a FIXME.
49885         * lib/sha512.c (shaxxx_stream, sha512_stream, sha384_stream):
49886         Likewise.
49888         af_alg: Improve comments.
49889         * lib/af_alg.h: Use imperatives and tighten up wording.
49891 2018-05-05  Bruno Haible  <bruno@clisp.org>
49893         af_alg: Improve comments.
49894         * lib/af_alg.c (afalg_stream): Improve comment about kernel bug.
49896 2018-05-05  Bruno Haible  <bruno@clisp.org>
49898         af_alg: New module.
49899         * lib/af_alg.h: Test HAVE_* macro through '#if', not '#ifdef'.
49900         * lib/af_alg.c: Include "af_alg.h" before the other header files.
49901         * lib/md5.c: Include "af_alg.h" unconditionally.
49902         (md5_stream): Invoke afalg_stream unconditionally.
49903         * lib/sha1.c: Include "af_alg.h" unconditionally.
49904         (sha1_stream): Invoke afalg_stream unconditionally.
49905         * lib/sha256.c: Include "af_alg.h" unconditionally.
49906         (sha256_stream, sha224_stream): Invoke afalg_stream unconditionally.
49907         * lib/sha512.c: Include "af_alg.h" unconditionally.
49908         (sha512_stream, sha384_stream): Invoke afalg_stream unconditionally.
49909         * m4/af_alg.m4: Renamed from m4/linux-if-alg.m4.
49910         (gl_AF_ALG): Renamed from gl_LINUX_IF_ALG_H.
49911         * modules/crypto/af_alg: New file.
49912         * modules/crypto/md5 (Files): Remove files that are now in the
49913         'crypto/af_alg' module.
49914         (Depends-on): Add crypto/af_alg.
49915         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
49916         (Makefile.am): Don't mention af_alg.c here.
49917         * modules/crypto/sha1 (Files): Remove files that are now in the
49918         'crypto/af_alg' module.
49919         (Depends-on): Add crypto/af_alg.
49920         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
49921         (Makefile.am): Don't mention af_alg.c here.
49922         * modules/crypto/sha256 (Files): Remove files that are now in the
49923         'crypto/af_alg' module.
49924         (Depends-on): Add crypto/af_alg.
49925         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
49926         (Makefile.am): Don't mention af_alg.c here.
49927         * modules/crypto/sha512 (Files): Remove files that are now in the
49928         'crypto/af_alg' module.
49929         (Depends-on): Add crypto/af_alg.
49930         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
49931         (Makefile.am): Don't mention af_alg.c here.
49933 2018-05-05  Paul Eggert  <eggert@cs.ucla.edu>
49935         crypto tests: pacify GCC
49936         * tests/test-digest.h (test_digest_on_files):
49937         Don’t assume digest size fits in int (!).
49939         af_alg: minor style improvements
49940         * lib/af_alg.c (afalg_stream): Prefer C99 style
49941         decl-after-statement, since we’re already assuming C99.  Clarify
49942         by strengthening the bind test and omit unnecessary assignment.
49944 2018-05-05  Bruno Haible  <bruno@clisp.org>
49946         af_alg: Fix bug on empty files.
49947         * lib/af_alg.c (afalg_stream): Ignore the kernel's result if the input
49948         stream is empty.
49950 2018-05-05  Paul Eggert  <eggert@cs.ucla.edu>
49952         sys-limits.h: new file for crypto and safe I/O
49953         * lib/af_alg.c: Include sys-limits.h.
49954         (MAX_RW_COUNT): Remove.  Use replaced by SYS_BUFSIZE_MAX.
49955         (afalg_stream): Also reject negative sizes for sendfile; they
49956         should not happen and the code is a bit cleaner and faster this way.
49957         * lib/safe-read.c: Include sys-limits.h.
49958         (BUGGY_READ_MAXIMUM): Remove.  All uses replaced by SYS_BUFSIZE_MAX.
49959         * lib/sys-limits.h: New file, with values and commentary derived
49960         from the old safe-read.c and from GNU Emacs sysdep.c.
49961         * modules/crypto/md5, modules/crypto/sha1, modules/crypto/sha256:
49962         * modules/crypto/sha512, modules/safe-read, modules/safe-write:
49963         Add lib/sys-limits.h to Files section.
49965 2018-05-05  Bruno Haible  <bruno@clisp.org>
49967         af_alg: Improve function signature.
49968         * lib/af_alg.h (afalg_stream): Swap second and third argument.
49969         * lib/af_alg.c (afalg_stream): Likewise.
49970         * lib/md5.c, lib/sha1.c, lib/sha256.c, lib/sha512.c: Callers changed.
49972 2018-05-05  Bruno Haible  <bruno@clisp.org>
49974         crypto/{md5,sha1,sha256,sha512}: Fix compilation error (S_TYPEISTMO).
49975         * modules/crypto/md5 (Depends-on): Add 'sys_stat'.
49976         * modules/crypto/sha1 (Depends-on): Likewise.
49977         * modules/crypto/sha256 (Depends-on): Likewise.
49978         * modules/crypto/sha512 (Depends-on): Likewise.
49980 2018-05-05  Bruno Haible  <bruno@clisp.org>
49982         crypto/{md5,sha1,sha256,sha512}: Fix module description.
49983         * modules/crypto/md5 (Depends-on): Add 'sys_socket'.
49984         * modules/crypto/sha1 (Depends-on): Likewise.
49985         * modules/crypto/sha256 (Depends-on): Likewise.
49986         * modules/crypto/sha512 (Depends-on): Likewise.
49988 2018-05-05  Bruno Haible  <bruno@clisp.org>
49990         af_alg: Add documentation.
49991         * lib/af_alg.h: Add comments.
49993 2018-05-05  Bruno Haible  <bruno@clisp.org>
49995         sha512: Add tests.
49996         * tests/test-sha512.c: New file.
49997         * modules/crypto/sha512-tests: New file.
49999 2018-05-05  Bruno Haible  <bruno@clisp.org>
50001         sha256: Add tests.
50002         * tests/test-sha256.c: New file.
50003         * modules/crypto/sha256-tests: New file.
50005 2018-05-05  Bruno Haible  <bruno@clisp.org>
50007         sha1 tests: Add test for sha1_stream.
50008         * tests/test-sha1.c: Include test-digest.h.
50009         (main): Invoke test_digest_on_files on 'sha1_stream'.
50010         * modules/crypto/sha1-tests (Files): Add tests/test-digest.h.
50012 2018-05-05  Bruno Haible  <bruno@clisp.org>
50014         md5 tests: Add test for md5_stream.
50015         * tests/test-digest.h: New file.
50016         * tests/test-md5.c: Include test-digest.h.
50017         (main): Invoke test_digest_on_files on 'md5_stream'.
50018         * modules/crypto/md5-tests (Files): Add tests/test-digest.h.
50020 2018-04-28  Matteo Croce  <mcroce@redhat.com>
50022         md5sum: Use AF_ALG when available.
50023         * lib/md5.c: Include af_alg.h.
50024         (md5_stream): Use afalg_stream when available.
50025         * modules/crypto/md5 (Files): Add the af_alg files.
50026         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
50027         (Makefile.am): Add af_alg.c.
50029 2018-04-28  Matteo Croce  <mcroce@redhat.com>
50031         sha512sum: Use AF_ALG when available.
50032         * lib/sha512.c: Include af_alg.h.
50033         (sha512_stream, sha384_stream): Use afalg_stream when available.
50034         * modules/crypto/sha512 (Files): Add the af_alg files.
50035         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
50036         (Makefile.am): Add af_alg.c.
50038 2018-04-28  Matteo Croce  <mcroce@redhat.com>
50040         sha256sum: Use AF_ALG when available.
50041         * lib/sha256.c: Include af_alg.h.
50042         (sha256_stream, sha224_stream): Use afalg_stream when available.
50043         * modules/crypto/sha256 (Files): Add the af_alg files.
50044         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
50045         (Makefile.am): Add af_alg.c.
50047 2018-04-28  Matteo Croce  <mcroce@redhat.com>
50049         sha1sum: Use AF_ALG when available.
50050         * lib/af_alg.h: New file.
50051         * lib/af_alg.c: New file.
50052         * lib/sha1.c: Include af_alg.h.
50053         (sha1_stream): Use afalg_stream when available.
50054         * m4/linux-if-alg.m4: New file.
50055         * modules/crypto/sha1 (Files): Add the new files.
50056         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
50057         (Makefile.am): Add af_alg.c.
50059 2018-05-05  Bruno Haible  <bruno@clisp.org>
50061         all: Replace more http URLs by https URLs.
50062         * lib/localename.c: Use https: URL.
50063         * lib/timespec.h: Likewise.
50065 2018-05-03  Paul Eggert  <eggert@cs.ucla.edu>
50067         maint: port more modules to GCC 8
50068         * lib/dirname.h (base_name):
50069         * lib/exclude.h (new_exclude):
50070         * lib/xstrndup.h (xstrndup):
50071         Add malloc attribute.
50072         * lib/readutmp.c: Pacify GCC 8 about safe use of strncpy.
50073         * lib/sig-handler.h (get_handler) [SA_SIGINFO]: Simplify.
50074         This pacifies GCC 8.
50075         * m4/gnulib-common.m4 (gl_COMMON_BODY):
50076         Define _GL_ATTRIBUTE_MALLOC here.  All other definitions removed.
50078 2018-05-03  Bruno Haible  <bruno@clisp.org>
50080         Simplify code. Drop support for Borland C++ on Windows.
50081         Reported by Gisle Vanem <gisle.vanem@gmail.com>.
50082         * lib/accept4.c: Simplify 'defined _WIN32 || defined __WIN32__' to just
50083         'defined _WIN32'.
50084         * lib/canonicalize-lgpl.c: Likewise.
50085         * lib/classpath.c: Likewise.
50086         * lib/clean-temp.c: Likewise.
50087         * lib/csharpexec.c: Likewise.
50088         * lib/ctime.c: Likewise.
50089         * lib/dosname.h: Likewise.
50090         * lib/dup2.c: Likewise.
50091         * lib/errno.in.h: Likewise.
50092         * lib/error.c: Likewise.
50093         * lib/euidaccess.c: Likewise.
50094         * lib/execute.c: Likewise.
50095         * lib/fcntl.in.h: Likewise.
50096         * lib/fcntl.c: Likewise.
50097         * lib/filename.h: Likewise.
50098         * lib/findprog.c: Likewise.
50099         * lib/flock.c: Likewise.
50100         * lib/fopen.c: Likewise.
50101         * lib/freopen.c: Likewise.
50102         * lib/fstat.c: Likewise.
50103         * lib/fsync.c: Likewise.
50104         * lib/gc-gnulib.c: Likewise.
50105         * lib/get-rusage-data.c: Likewise.
50106         * lib/getaddrinfo.c: Likewise.
50107         * lib/getdelim.c: Likewise.
50108         * lib/getdtablesize.c: Likewise.
50109         * lib/gethostname.c: Likewise.
50110         * lib/getlogin.c: Likewise.
50111         * lib/getlogin_r.c: Likewise.
50112         * lib/getopt.c: Likewise.
50113         * lib/getpagesize.c: Likewise.
50114         * lib/getpass.c: Likewise.
50115         * lib/getrusage.c: Likewise.
50116         * lib/gettimeofday.c: Likewise.
50117         * lib/glob.c: Likewise.
50118         * lib/inttypes.in.h: Likewise.
50119         * lib/isapipe.c: Likewise.
50120         * lib/javaexec.c: Likewise.
50121         * lib/link.c: Likewise.
50122         * lib/localcharset.c: Likewise.
50123         * lib/localename.h: Likewise.
50124         * lib/localename.c: Likewise.
50125         * lib/localtime.c: Likewise.
50126         * lib/lseek.c: Likewise.
50127         * lib/mbsinit.c: Likewise.
50128         * lib/mkdir.c: Likewise.
50129         * lib/msvc-nothrow.h: Likewise.
50130         * lib/nanosleep.c: Likewise.
50131         * lib/nl_langinfo.c: Likewise.
50132         * lib/nonblocking.c: Likewise.
50133         * lib/nproc.c: Likewise.
50134         * lib/open.c: Likewise.
50135         * lib/openpty.c: Likewise.
50136         * lib/pathmax.h: Likewise.
50137         * lib/pipe-filter-aux.c: Likewise.
50138         * lib/pipe-filter-gi.c: Likewise.
50139         * lib/pipe-filter-ii.c: Likewise.
50140         * lib/pipe.c: Likewise.
50141         * lib/pipe2.c: Likewise.
50142         * lib/poll.c: Likewise.
50143         * lib/popen.c: Likewise.
50144         * lib/posix_openpt.c: Likewise.
50145         * lib/printf-parse.c: Likewise.
50146         * lib/progreloc.c: Likewise.
50147         * lib/putenv.c: Likewise.
50148         * lib/read.c: Likewise.
50149         * lib/relocatable.c: Likewise.
50150         * lib/rename.c: Likewise.
50151         * lib/same-inode.h: Likewise.
50152         * lib/secure_getenv.c: Likewise.
50153         * lib/select.c: Likewise.
50154         * lib/sethostname.c: Likewise.
50155         * lib/setlocale.c: Likewise.
50156         * lib/sigaction.c: Likewise.
50157         * lib/sigprocmask.c: Likewise.
50158         * lib/sleep.c: Likewise.
50159         * lib/spawn-pipe.h: Likewise.
50160         * lib/spawn-pipe.c: Likewise.
50161         * lib/spawni.c: Likewise.
50162         * lib/stat-time.h: Likewise.
50163         * lib/stat-w32.c: Likewise.
50164         * lib/stat.c: Likewise.
50165         * lib/stdio.in.h: Likewise.
50166         * lib/stdio-impl.h: Likewise.
50167         * lib/stdio-read.c: Likewise.
50168         * lib/stdio-write.c: Likewise.
50169         * lib/stdlib.in.h: Likewise.
50170         * lib/strerror_r.c: Likewise.
50171         * lib/strftime-fixes.c: Likewise.
50172         * lib/sys_stat.in.h: Likewise.
50173         * lib/sys_types.in.h: Likewise.
50174         * lib/sys_wait.in.h : Likewise.
50175         * lib/system-quote.h: Likewise.
50176         * lib/system-quote.c: Likewise.
50177         * lib/tmpdir.c: Likewise.
50178         * lib/tzset.c: Likewise.
50179         * lib/uname.c: Likewise.
50180         * lib/unistd.in.h: Likewise.
50181         * lib/utime.in.h: Likewise.
50182         * lib/utime.c: Likewise.
50183         * lib/utimecmp.c: Likewise.
50184         * lib/utimens.c: Likewise.
50185         * lib/vasnprintf.c: Likewise.
50186         * lib/vma-iter.h: Likewise.
50187         * lib/vma-iter.c: Likewise.
50188         * lib/wait-process.c: Likewise.
50189         * lib/wcsftime.c: Likewise.
50190         * lib/wctype.in.h: Likewise.
50191         * lib/write.c: Likewise.
50192         * tests/nap.h: Likewise.
50193         * tests/test-cloexec.c: Likewise.
50194         * tests/test-dup-safer.c: Likewise.
50195         * tests/test-dup2.c: Likewise.
50196         * tests/test-dup3.c: Likewise.
50197         * tests/test-fcntl.c: Likewise.
50198         * tests/test-get-rusage-data.c: Likewise.
50199         * tests/test-getaddrinfo.c: Likewise.
50200         * tests/test-getlogin.h: Likewise.
50201         * tests/test-isatty.c: Likewise.
50202         * tests/test-localename.c: Likewise.
50203         * tests/test-mbrtowc-w32.c: Likewise.
50204         * tests/test-nonblocking.c: Likewise.
50205         * tests/test-nonblocking-pipe-main.c: Likewise.
50206         * tests/test-nonblocking-socket-main.c: Likewise.
50207         * tests/test-nonblocking-socket.h: Likewise.
50208         * tests/test-pipe.c: Likewise.
50209         * tests/test-pipe2.c: Likewise.
50210         * tests/test-poll.c: Likewise.
50211         * tests/test-pthread_sigmask1.c: Likewise.
50212         * tests/test-select.h: Likewise.
50213         * tests/test-sethostname2.c: Likewise.
50214         * tests/test-sigprocmask.c: Likewise.
50215         * tests/test-spawn-pipe-child.c: Likewise.
50216         * tests/test-stat-time.c: Likewise.
50217         * tests/test-system-quote-main.c: Likewise.
50218         * tests/test-utimens-common.h: Likewise.
50219         * tests/test-wcrtomb-w32.c: Likewise.
50220         * m4/csharpexec.m4 (gt_CSHARPEXEC): Likewise.
50221         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
50222         * m4/javacomp.m4 (gt_JAVACOMP): Likewise.
50223         * m4/javaexec.m4 (gt_JAVAEXEC): Likewise.
50224         * m4/locale-ar.m4 (gt_LOCALE_AR): Likewise.
50225         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
50226         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
50227         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
50228         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
50229         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Likewise.
50230         * m4/nocrash.m4 (GL_NOCRASH): Likewise.
50231         * m4/pathmax.m4 (gl_PATHMAX_SNIPPET): Likewise.
50232         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Likewise.
50233         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
50234         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Likewise.
50235         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
50237 2018-05-02  Bruno Haible  <bruno@clisp.org>
50239         localename: Fix test failures on mingw.
50240         * lib/localename.c (gl_locale_name_thread): Remove code specific to
50241         native Windows.
50242         (gl_locale_name_posix): Move code specific to native Windows here.
50243         * tests/test-localename.c (test_locale_name, test_locale_name_posix):
50244         Accept result without charset suffix, as it appears on mingw.
50246 2018-04-28  Paul Smith  <psmith@gnu.org>
50248         bootstrap: Avoid gnulib operations if not needed
50249         * build-aux/bootstrap: Remove unused variable gnulib_mk.
50250         Set $gnulib_extra_files early so it can be overridden in .conf.
50251         Remove redundant --import flag from $gnulib_tool_options.
50252         Set $use_gnulib to false if no gnulib modules or files are needed.
50253         If $use_gnulib is false, don't do anything related to gnulib.
50254         A lot of this is just whitespace (indentation) changes.
50256 2018-04-27  Paul Eggert  <eggert@cs.ucla.edu>
50258         manywarnings: port to GCC 8.0
50259         * build-aux/gcc-warning.spec: Add -Wcatch-value,
50260         -Wclass-memaccess, -Wdo-subscript, -Wextra-semi.  Adjust to the
50261         fact that the GCC help message now mentions operands for
50262         -Warray-bounds, -Wformat, -Wformat-overflow, -Wformat-truncation,
50263         -Wimplicit-fallthrough, -Wplacement-new, -Wshift-overflow,
50264         -Wstrict-aliasing, -Wstrict-overflow, -Wstringop-overflow,
50265         and -Wunused-const-variable.
50266         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wattribute-alias,
50267         -Wcast-align=strict, -Wcast-function-type, -Wif-not-aligned,
50268         -Wmissing-attributes, -Wmultistatement-macros,
50269         -Wpacked-not-aligned, -Wsizeof-pointer-div, -Wstringop-truncation,
50270         -Wsuggest-attribute=cold, -Wsuggest-attribute=malloc.
50272 2018-04-24  Bruno Haible  <bruno@clisp.org>
50274         sys_socket: Make SO_REUSEPORT available across platforms.
50275         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
50276         * lib/sys_socket.in.h (SO_REUSEPORT): New macro.
50277         * doc/posix-headers/sys_socket.texi: Mention the issue.
50278         * tests/test-poll.c (SO_REUSEPORT): Remove.
50279         * tests/test-select.h: Include <sys/socket.h>.
50280         (SO_REUSEPORT): Remove.
50281         * modules/select-tests (Depends-on): Add 'sys_socket'.
50283 2018-04-21  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
50285         localcharset: short-circuit the search for an alias on a Mac
50286         * lib/localcharset.c (get_charset_aliases): Add a tautological
50287         UTF-8 entry to speed up the search for this case.
50288         Most machines default to a UTF-8 locale nowadays, so begin the
50289         list of aliases with a dummy UTF-8 entry so it will be found
50290         immediately and a time-consuming search through the rest of
50291         the list is avoided.
50293 2018-04-11  Paul Eggert  <eggert@cs.ucla.edu>
50295         fts: add comment
50296         * lib/fts.c (fts_build): Explain why ==, not >.
50297         See remark by Bernhard Voelker in:
50298         https://lists.gnu.org/r/bug-gnulib/2018-04/msg00041.html
50300         fts: fix bug in find across filesystems
50301         This fixes a bug I introduced last summer.
50302         Problem reported by Kamil Dudka in:
50303         https://lists.gnu.org/r/bug-gnulib/2018-04/msg00033.html
50304         * lib/fts.c (filesystem_type, dirent_inode_sort_may_be_useful)
50305         (leaf_optimization):
50306         New arg for file descriptor.  All callers changed.
50307         (fts_build): Check for whether inodes should be sorted
50308         before closing the directory.
50310 2018-04-07  Bruno Haible  <bruno@clisp.org>
50312         unicase/u*-context: Fix link errors with libunistring <= 0.9.9.
50313         Reported by Genki Sky <sky@genki.is>.
50314         * modules/unicase/u8-prefix-context (configure.ac): Require libunistring
50315         version 0.9.10 or newer.
50316         * modules/unicase/u8-suffix-context (configure.ac): Likewise.
50317         * modules/unicase/u16-prefix-context (configure.ac): Likewise.
50318         * modules/unicase/u16-suffix-context (configure.ac): Likewise.
50319         * modules/unicase/u32-prefix-context (configure.ac): Likewise.
50320         * modules/unicase/u32-suffix-context (configure.ac): Likewise.
50322 2018-04-07  Bruno Haible  <bruno@clisp.org>
50324         execute: Update comment.
50325         * lib/execute.h (execute): Refer to spawn-pipe.h, not pipe.h.
50327 2018-04-05  Paul Eggert  <eggert@cs.ucla.edu>
50329         fts: treat CIFS like NFS
50330         Problem reported by Kamil Dudka in:
50331         https://lists.gnu.org/r/bug-gnulib/2018-04/msg00015.html
50332         * lib/fts.c (S_MAGIC_CIFS): New macro.
50333         (dirent_inode_sort_may_be_useful, leaf_optimization):
50334         Treat CIFS like NFS.
50336 2018-03-28  Bruno Haible  <bruno@clisp.org>
50338         c-stack: Fix possible build failure on some platforms.
50339         * lib/c-stack.c (die): Define whenever this function is referenced.
50341 2018-03-28  Paul Eggert  <eggert@cs.ucla.edu>
50343         time_rz: fix workaround for Mac OS X 10.6 infloop
50344         Problems reported by Charles A. Roelli (Bug#27736#117).
50345         * m4/time_rz.m4 (gl_TIME_RZ): Use a slightly different timestamp.
50346         Also, discard output, which clutters the 'configure' log.
50348 2018-03-27  Paul Eggert  <eggert@cs.ucla.edu>
50350         havelib: port to Solaris 10 /bin/sh
50351         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Use 'test ! EXPR'
50352         instead of '! test EXPR'.
50354 2018-03-26  Paul Eggert  <eggert@cs.ucla.edu>
50356         time_rz: work around Mac OS X 10.6 infloop
50357         * doc/posix-functions/localtime.texi:
50358         * doc/posix-functions/localtime_r.texi: Mention the bug.
50359         * lib/time_rz.c (localtime_rz): Work around the bug.  It’d be
50360         better to fix localtime and localtime_r instead, but that would be
50361         more work and is not needed to fix the Emacs problem.
50362         * m4/time_rz.m4 (gl_TIME_RZ): Detect the bug.
50364 2018-03-24  Jim Meyering  <meyering@fb.com>
50366         test-version-etc.sh: don't use diff directly: use init.sh's compare
50367         We'd rather not sacrifice readable "diff -u" output even for
50368         "diff -c" output (not supported by busybox) or for even less
50369         readable ed-style "diff" output.  So use init.sh's compare function
50370         * tests/test-version-etc.sh: Source init.sh and add "." to path.
50371         Remove "./" from invocation of test-version-etc, so we use path.
50372         And s/diff/compare/.
50373         * modules/version-etc-tests (Depends-on): Add test-framework-sh,
50374         to get init.sh.
50375         Prompted by Eric Blake's comments in
50376         https://lists.gnu.org/r/sed-devel/2018-03/msg00015.html
50378 2018-03-24  Bruno Haible  <bruno@clisp.org>
50380         javacomp-script, javacomp: Add support for Java 10.
50381         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 10 and
50382         target-version 10.
50383         * lib/javaversion.h: Update comments.
50384         * lib/javacomp.c (default_target_version, SOURCE_VERSION_BOUND,
50385         source_version_index, get_goodcode_snippet, get_failcode_snippet,
50386         TARGET_VERSION_BOUND, target_version_index,
50387         corresponding_classfile_version): Accept source_version 10 and
50388         target_version 10.
50389         * lib/javacomp.h: Update comments accordingly.
50391 2018-03-24  Bruno Haible  <bruno@clisp.org>
50393         javacomp-script, javacomp: Update comments.
50394         * m4/javacomp.m4: Update comments regarding gcj.
50395         * lib/javacomp.h: Likewise.
50397 2018-03-24  Bruno Haible  <bruno@clisp.org>
50399         javacomp-script, javacomp: Fix support for Java 7, 8, 9.
50400         * lib/javaversion.h: Update comments.
50401         * lib/javacomp.h: Likewise.
50402         * lib/javacomp.c (default_target_version, source_version_index,
50403         get_goodcode_snippet, get_failcode_snippet): Recognize "9" instead of
50404         "1.9".
50405         (TARGET_VERSION_BOUND): Bump to 9.
50406         (target_version_index, corresponding_classfile_version): Recognize "9"
50407         instead of "1.9".
50408         (get_source_version_for_javac): New function.
50409         (is_envjavac_nongcj_usable, is_javac_usable): Add
50410         source_version_for_javac argument.
50411         (compile_java_class): Determine and pass source_version_for_javac.
50412         * m4/javacomp.m4: Recognize version '9' instead of '1.9'. When invoking
50413         $JAVAC or javac, pass '-source 1.6' instead of '-source 1.5' when
50414         appropriate.
50416 2018-03-23  Jim Meyering  <meyering@fb.com>
50418         test-version-etc.sh: port to diff without -c
50419         * tests/test-version-etc.sh: Don't use diff's -c option.
50420         This caused spurious test failure on Alpine Linux, which
50421         uses busybox's diff. Reported by Assaf Gordon in
50422         https://lists.gnu.org/r/sed-devel/2018-03/msg00013.html
50424 2018-03-23  Paul Eggert  <eggert@cs.ucla.edu>
50426         c-stack: port to recent GCC build
50427         Problem reported by The Fireplace (Bug#30913).
50428         * lib/c-stack.c (die): Define only if used.
50430 2018-03-20  Bruno Haible  <bruno@clisp.org>
50432         euidaccess: Port to native Windows.
50433         * lib/euidaccess.c (euidaccess): On native Windows, just use _access().
50434         * posix-modules (exclude_for_mingw): Remove 'euidaccess'.
50436 2018-03-19  Bruno Haible  <bruno@clisp.org>
50438         javacomp: Add support for Java 7, 8, 9.
50439         * lib/javacomp.c (default_target_version, SOURCE_VERSION_BOUND,
50440         source_version_index, get_goodcode_snippet, get_failcode_snippet,
50441         corresponding_classfile_version): Accept source_version 1,7, 1.8, 1.9
50442         and target_version 1,7, 1.8, 1.9.
50443         * lib/javacomp.h: Update comments accordingly.
50445 2018-03-19  Bruno Haible  <bruno@clisp.org>
50447         javacomp-script: Add support for Java 9.
50448         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 1.9 and
50449         target-version 1.9.
50451 2018-03-16  Bruno Haible  <bruno@clisp.org>
50453         glob: Don't compile replacements on recent glibc systems.
50454         * lib/glob.in.h: Use the usual idiom for the double-inclusion guard. If
50455         REPLACE_GLOB is 0, include the system's <glob.h> and use
50456         _GL_CXXALIAS_SYS.
50457         * m4/glob.m4 (gl_GLOB): Set REPLACE_GLOB instead of GLOB_H. Accept
50458         _GNU_GLOB_INTERFACE_VERSION 2 as well. Delete the file conf$$-globtest
50459         inside the AC_RUN_IFELSE block. Remove GL_GENERATE_GLOB_H conditional.
50460         * modules/glob (Dependencies): Test REPLACE_GLOB instead of GLOB_H.
50461         Remove snippet/warn-on-use.
50462         (configure.ac): Test REPLACE_GLOB instead of GLOB_H.
50463         (Makefile.am): Create glob.h always. Update list of substitutions in
50464         glob.h. Don't depend on $(WARN_ON_USE_H).
50466 2018-03-16  Bruno Haible  <bruno@clisp.org>
50468         glob: Fix link error on native Windows.
50469         * modules/glob (Depends-on): Add 'lstat'.
50471 2018-03-15  Bruno Haible  <bruno@clisp.org>
50473         glob: Fix compilation error in C++ mode.
50474         * lib/glob.in.h (_Restrict_): Define, like in regex.h and spawn.in.h.
50476 2018-03-15  Bruno Haible  <bruno@clisp.org>
50478         host-cpu-c-abi: Support for RISC-V CPU.
50479         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Recognize the various
50480         riscv32 and riscv64 ABIs.
50481         References:
50482         https://github.com/riscv/riscv-toolchain-conventions
50483         https://gcc.gnu.org/onlinedocs/gcc-7.3.0/gcc/RISC-V-Options.html
50484         https://gnu-mcu-eclipse.github.io/toolchain/riscv/
50486 2018-03-08  Paul Eggert  <eggert@cs.ucla.edu>
50488         fflush: be more paranoid about libio.h change
50489         Suggested by Eli Zaretskii in:
50490         https://lists.gnu.org/r/emacs-devel/2018-03/msg00270.html
50491         * lib/fbufmode.c (fbufmode):
50492         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
50493         (disable_seek_optimization, rpl_fflush):
50494         * lib/fpending.c (__fpending):
50495         * lib/fpurge.c (fpurge):
50496         * lib/freadable.c (freadable):
50497         * lib/freadahead.c (freadahead):
50498         * lib/freading.c (freading):
50499         * lib/freadptr.c (freadptr):
50500         * lib/freadseek.c (freadptrinc):
50501         * lib/fseeko.c (fseeko):
50502         * lib/fseterr.c (fseterr):
50503         * lib/fwritable.c (fwritable):
50504         * lib/fwriting.c (fwriting):
50505         Look at _IO_ftrylockfile as well as at _IO_EOF_SEEN.
50507 2018-03-07  Paul Eggert  <eggert@cs.ucla.edu>
50509         maint: write-file-hooks -> before-save-hook
50510         write-file-hooks is obsolete since Emacs 22.1 (released June 2007) and
50511         it's time to use the recommended replacement.
50512         Problem reported by Glenn Morris in:
50513         https://lists.gnu.org/r/bug-gnulib/2018-03/msg00008.html
50514         * build-aux/announce-gen, build-aux/bootstrap:
50515         * build-aux/do-release-commit-and-tag, build-aux/gendocs.sh:
50516         * build-aux/git-version-gen, build-aux/gitlog-to-changelog:
50517         * build-aux/gnu-web-doc-update, build-aux/gnupload:
50518         * build-aux/move-if-change, build-aux/prefix-gnulib-mk:
50519         * build-aux/update-copyright, build-aux/useless-if-before-free:
50520         * build-aux/vc-list-files:
50521         Update hook usage for files where Gnulib is the canonical source.
50523 2018-03-05  Paul Eggert  <eggert@cs.ucla.edu>
50525         binary-io: pacify gcc -Wunused-parameter
50526         Problem reported by Reuben Thomas in:
50527         https://lists.gnu.org/r/bug-gnulib/2018-03/msg00005.html
50528         * lib/binary-io.h (__gl_setmode, __gl_setmode_check):
50529         Use _GL_UNUSED where appropriate.
50531         fflush: adjust to glibc 2.28 libio.h removal
50532         Problem reported by Daniel P. Berrangé in:
50533         https://lists.gnu.org/r/bug-gnulib/2018-03/msg00000.html
50534         * lib/fbufmode.c (fbufmode):
50535         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
50536         (disable_seek_optimization, rpl_fflush):
50537         * lib/fpending.c (__fpending):
50538         * lib/fpurge.c (fpurge):
50539         * lib/freadable.c (freadable):
50540         * lib/freadahead.c (freadahead):
50541         * lib/freading.c (freading):
50542         * lib/freadptr.c (freadptr):
50543         * lib/freadseek.c (freadptrinc):
50544         * lib/fseeko.c (fseeko):
50545         * lib/fseterr.c (fseterr):
50546         * lib/fwritable.c (fwritable):
50547         * lib/fwriting.c (fwriting):
50548         Check _IO_EOF_SEEN instead of _IO_ftrylockfile.
50549         * lib/stdio-impl.h (_IO_IN_BACKUP) [_IO_EOF_SEEN]:
50550         Define if not already defined.
50552 2018-02-27  Paul Eggert  <eggert@cs.ucla.edu>
50554         environ: fix link error on 32-bit Cygwin
50555         Problem reported for GNU Emacs by Ken Brown in:
50556         https://lists.gnu.org/r/emacs-devel/2018-02/msg00765.html
50557         * lib/unistd.in.h (environ) [__i386__]: Do not redeclare.
50559 2018-02-24  Bruno Haible  <bruno@clisp.org>
50561         mbrtowc tests: Fix regression on glibc.
50562         Reported by Bernhard Voelker.
50563         * tests/test-mbrtowc.c (main): Fix expected value of wc.
50565 2018-02-24  Bruno Haible  <bruno@clisp.org>
50567         striconveha, uniconv/*: Avoid test failures on musl libc.
50568         * tests/iconvsupport.c: New file.
50569         * tests/test-striconveha.c (main): Skip autodetect_jp tests if iconv()
50570         does not support the ISO-2022-JP-2 encoding.
50571         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
50572         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
50573         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
50574         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
50575         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
50576         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
50577         * modules/striconveha-tests (Files): Add tests/iconvsupport.c.
50578         (Makefile.am): Link test-striconveha with iconvsupport.o.
50579         * modules/uniconv/u8-conv-from-enc-tests (Files): Add
50580         tests/iconvsupport.c.
50581         (Makefile.am): Link test-u8-conv-from-enc with iconvsupport.o.
50582         * modules/uniconv/u8-strconv-from-enc-tests (Files): Add
50583         tests/iconvsupport.c.
50584         (Makefile.am): Link test-u8-strconv-from-enc with iconvsupport.o.
50585         * modules/uniconv/u16-conv-from-enc-tests (Files): Add
50586         tests/iconvsupport.c.
50587         (Makefile.am): Link test-u16-conv-from-enc with iconvsupport.o.
50588         * modules/uniconv/u16-strconv-from-enc-tests (Files): Add
50589         tests/iconvsupport.c.
50590         (Makefile.am): Link test-u16-strconv-from-enc with iconvsupport.o.
50591         * modules/uniconv/u32-conv-from-enc-tests (Files): Add
50592         tests/iconvsupport.c.
50593         (Makefile.am): Link test-u32-conv-from-enc with iconvsupport.o.
50594         * modules/uniconv/u32-strconv-from-enc-tests (Files): Add
50595         tests/iconvsupport.c.
50596         (Makefile.am): Link test-u32-strconv-from-enc with iconvsupport.o.
50598 2018-02-24  Bruno Haible  <bruno@clisp.org>
50600         localename: Add support for musl libc.
50601         * m4/localename.m4 (gl_LOCALENAME): Check for <langinfo.h>.
50602         * lib/localename.c (gl_locale_name_thread_unsafe): Use NL_LOCALE_NAME
50603         on Linux platforms which define NL_LOCALE_NAME.
50605 2018-02-24  Bruno Haible  <bruno@clisp.org>
50607         mbrtowc tests: Don't make assumptions about the charset the C locale.
50608         * tests/test-mbrtowc.c (main): For bytes >= 0x80, don't assume a
50609         particular mapping in the C locale.
50611 2018-02-24  Bruno Haible  <bruno@clisp.org>
50613         ptsname_r: Don't expect that this function sets errno.
50614         * tests/test-ptsname_r.c (test_errors): Don't test errno after return
50615         from ptsname_r().
50616         * doc/glibc-functions/ptsname_r.texi: Mention the issue.
50618 2018-02-23  Bruno Haible  <bruno@clisp.org>
50620         xmalloca: pacify gcc -Wbad-function-cast
50621         * lib/xmalloca.h (xmalloca): Insert intermediate cast here as well.
50623 2018-02-23  Paul Eggert  <eggert@cs.ucla.edu>
50625         nl_langinfo: pacify gcc -Wunused-function
50626         * lib/nl_langinfo.c (ctype_codeset): Do not define if
50627         REPLACE_NL_LANGINFO && !GNULIB_defined_CODESET, as it is unused in
50628         this case.  Without this change, I got a diagnostic when building
50629         coreutils on Fedora 27 with gcc 7.3.1 20180130.
50631         same: pacify gcc -Wunused-variable
50632         * lib/same.c (same_nameat) [!CHECK_TRUNCATION]:
50633         Omit unused variable.
50635         malloca: pacify gcc -Wbad-function-cast
50636         * lib/malloca.h (malloca): Pacify gcc -Wbad-function-cast
50637         diagnostic that I got on Fedora 27 with gcc 7.3.1 20180130.
50638         To pacify GCC, I had to cast alloca’s result to some type other
50639         than void * before casting that to uintptr_t.
50641 2018-02-20  Paul Eggert  <eggert@cs.ucla.edu>
50643         utimecmp: new function utimecmpat
50644         * lib/utimecmp.c: Include fcntl.h, sys/stat.h and dirname.h.
50645         Do not include utimens.h.
50646         (utimecmpat): New function, generalizing utimecmp.
50647         (utimecmp): Now a thin layer around utimecmpat.
50648         * modules/utimecmp (Depends-on): Depend on dirname-lgpl, fstatat,
50649         utimensat instead of on lstat and utimens.
50651         same: new function same_nameat
50652         * lib/same.c: Include fcntl.h.
50653         * lib/same.c (same_nameat): New function, generalizing same_name.
50654         (same_name): Now a thin layer around same_nameat.
50655         * m4/same.m4 (gl_SAME): Check for fpathconf, not pathconf.
50656         * modules/same (Depends-on): Depend on fstatat, openat.
50658 2018-02-18  Eric Gallager  <egall@gwmail.gwu.edu>  (tiny change)
50660         warnings: Add support for Objective C.
50661         * m4/warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS(Objective C)): New
50662         macro.
50664 2018-02-17  Bruno Haible  <bruno@clisp.org>
50666         lock: Fix test-once1 crash on FreeBSD11.
50667         * lib/glthread/lock.h: On FreeBSD, test the weak value of the symbol
50668         'pthread_create', not 'pthread_cancel'.
50670 2018-02-17  Bruno Haible  <bruno@clisp.org>
50672         lock: Add test of gl_once.
50673         * tests/test-once.c: New file.
50674         * modules/lock-tests (Files): Add it.
50675         (Makefile.am): Build and test programs 'test-once1' and 'test-once2'.
50677 2018-02-17  Bruno Haible  <bruno@clisp.org>
50679         thread: Fix compilation error on IRIX.
50680         * lib/glthread/thread.h: Include <unistd.h>. Include <signal.h> when
50681         needed; include it outside the C++ extern "C" {} block.
50682         * doc/posix-headers/pthread.texi: Mention the problem with
50683         pthread_atfork on IRIX.
50685 2018-02-04  Bruno Haible  <bruno@clisp.org>
50687         nl_langinfo: Override the system's nl_langinfo() when needed.
50688         Reported by Jim Meyering.
50689         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Set REPLACE_NL_LANGINFO=1
50690         also when HAVE_LANGINFO_T_FMT_AMPM or HAVE_LANGINFO_ALTMON is 0.
50692 2018-02-04  Bruno Haible  <bruno@clisp.org>
50694         signal-h, monetary, strings: Fix build failure in some cases.
50695         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
50696         * modules/signal-h (Makefile.am): In the GNULIB_* substitutions, use '/'
50697         as delimiter in sed command, not '|'.
50698         * modules/monetary (Makefile.am): Likewise.
50699         * modules/strings (Makefile.am): Likewise.
50701 2018-02-03  Jim Meyering  <meyering@fb.com>
50703         maint.mk: exempt "/proc/filesystems" from "file system" syntax check
50704         * top/maint.mk (sc_file_system): Don't complain about
50705         "/proc/filesystems".
50707 2018-02-03  Bruno Haible  <bruno@clisp.org>
50709         stdlib: Fix compilation error on OpenIndiana.
50710         * lib/stdlib.in.h: Before including <sys/loadavg.h>, include
50711         <sys/time.h>.
50712         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
50713         * m4/getloadavg.m4 (gl_GETLOADAVG): Likewise.
50715 2018-02-03  Bruno Haible  <bruno@clisp.org>
50717         host-cpu-c-abi: Avoid use of 'grep -E' on OpenIndiana.
50718         * m4/asm-underscore.m4 (gl_ASM_SYMBOL_PREFIX): Require AC_PROG_EGREP,
50719         and use $EGREP instead of 'grep -E'.
50720         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Use 'grep' instead of
50721         'grep -E'.
50723 2018-02-02  Paul Eggert  <eggert@cs.ucla.edu>
50725         malloca: Add a compile-time verification.
50726         * lib/malloca.c (small_t): Verify that it is wide enough.
50727         * modules/malloca (Depends-on): Add verify.
50729 2018-02-02  Bruno Haible  <bruno@clisp.org>
50731         malloca: Add an argument check.
50732         Suggested by Paul Eggert.
50733         * lib/malloca.c (freea): Check against an invalid argument.
50735 2018-02-02  Bruno Haible  <bruno@clisp.org>
50737         localename: Add support for OpenIndiana.
50738         * lib/localename.c (gl_locale_name_thread_unsafe): Add code for
50739         Solaris 11 variants with uselocale() but without getlocalename_l().
50741 2018-02-02  Bruno Haible  <bruno@clisp.org>
50743         malloca, xmalloca: Make multithread-safe.
50744         Reported by Florian Weimer <fweimer@redhat.com>.
50745         Implements an idea by Ondřej Bílka <neleai@seznam.cz>.
50746         * lib/malloca.h (malloca): In the stack allocation case, return a
50747         pointer that is a multiple of 2 * sa_alignment_max.
50748         (sa_increment): Remove enum item.
50749         * lib/xmalloca.h (xmalloca): In the stack allocation case, return
50750         a pointer that is a multiple of 2 * sa_alignment_max.
50751         * lib/malloca.c (NO_SANITIZE_MEMORY): Remove macro.
50752         (MAGIC_NUMBER, MAGIC_SIZE, preliminary_header, HEADER_SIZE, header,
50753         HASH_TABLE_SIZE, mmalloca_results): Remove.
50754         (small_t): New type.
50755         (mmalloca, free): Rewritten.
50756         * lib/malloca.valgrind: Remove file.
50757         * modules/malloca (Files): Remove it.
50758         (Depends-on): Remove verify.
50760 2018-01-31  Bruno Haible  <bruno@clisp.org>
50762         environ: Fix link error on 64-bit Cygwin.
50763         * lib/unistd.in.h (environ): On Cygwin, redeclare with the
50764         __declspec(dllimport) attribute.
50765         * doc/posix-functions/environ.texi: Mention the Cygwin problem.
50767 2018-01-30  Bruno Haible  <bruno@clisp.org>
50769         get-rusage-data: Add support for Minix 3.
50770         * lib/get-rusage-data.c (get_rusage_data): Return 0 on Minix.
50772 2018-01-30  Bruno Haible  <bruno@clisp.org>
50774         vma-iter: Add support for Minix 3.
50775         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define on Minix.
50776         * lib/vma-iter.c: On Minix, read /proc/<pid>/map.
50778 2018-01-27  Bruno Haible  <bruno@clisp.org>
50780         Fix malfunction of socket functions on HP-UX in 64-bit mode.
50781         * m4/socketlib.m4 (gl_SOCKETLIB): Add comment.
50782         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define
50783         _HPUX_ALT_XOPEN_SOCKET_API.
50784         * modules/accept (Depends-on): Add 'extensions'.
50785         * modules/getpeername (Depends-on): Likewise.
50786         * modules/getsockname (Depends-on): Likewise.
50787         * modules/getsockopt (Depends-on): Likewise.
50788         * modules/recvfrom (Depends-on): Likewise.
50789         * doc/posix-functions/accept.texi: Mention the HP-UX socklen_t problem.
50790         * doc/posix-functions/getpeername.texi: Likewise.
50791         * doc/posix-functions/getsockname.texi: Likewise.
50792         * doc/posix-functions/getsockopt.texi: Likewise.
50793         * doc/posix-functions/recvfrom.texi: Likewise.
50795 2018-01-27  Bruno Haible  <bruno@clisp.org>
50797         getsockname tests: More tests.
50798         * tests/test-getsockname.c (open_server_socket): New function, mostly
50799         copied from test-poll.c.
50800         (main): Check that getsockname fills in addr.
50801         * modules/getsockname-tests (Depends-on): Add the necessary
50802         dependencies.
50803         (test_getsockname_LDADD): Link with $(INET_PTON_LIB).
50805 2018-01-26  Paul Eggert  <eggert@cs.ucla.edu>
50807         manywarnings: fix maintainer comment
50808         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Fix comment so that
50809         it does not mistakenly think that ‘-1)’ is an option.
50811 2018-01-26  Bruno Haible  <bruno@clisp.org>
50813         langinfo: Fix last commit.
50814         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
50815         * modules/langinfo (Makefile.am): Substitute HAVE_LANGINFO_ALTMON.
50817 2018-01-24  Bruno Haible  <bruno@clisp.org>
50819         langinfo, nl_langinfo: Add support for alternative month names.
50820         * m4/langinfo_h.m4 (gl_LANGINFO_H): Define HAVE_LANGINFO_ALTMON.
50821         * lib/langinfo.in.h (ALTMON_1...ALTMON_12): New macros.
50822         * lib/nl_langinfo.c (rpl_nl_langinfo): Treat ALTMON_i like MON_i.
50823         * tests/test-nl_langinfo.c (main): Test ALTMON_*.
50824         * doc/posix-headers/langinfo.texi: Document support of ALTMON_*.
50825         * doc/posix-functions/nl_langinfo.texi: Likewise.
50827 2018-01-23  Paul Eggert  <eggert@cs.ucla.edu>
50829         Merge strftime.c changes from glibc
50830         This incorporates:
50831         2017-11-14 [BZ #10871] Implement alternative month names
50832         2017-11-14 [BZ #10871] Abbreviated alternative month names (%Ob)
50833         2017-06-20 Use locale_t, not __locale_t, throughout glibc
50834         * lib/nstrftime.c (ABALTMON_1) [!COMPILE_WIDE]: New macro.
50835         (LOCALE_PARAM) [_LIBC && USE_IN_EXTENDED_LOCALE_MODEL]:
50836         Use locale_t, not __locale_t.
50837         (a_altmonth, f_altmonth, aam_len) [_NL_CURRENT]: New macros.
50838         (__strftime_internal): Add support for alternate months.
50840 2018-01-23  Bruno Haible  <bruno@clisp.org>
50842         doc: Mention another prerequisite for using Gnulib.
50843         Reported at <https://stackoverflow.com/questions/48378214/>.
50844         * doc/gnulib-tool.texi (Initial import): Mention requirement to use
50845         AC_CONFIG_HEADERS.
50847 2018-01-22  Mathieu Lirzin  <mthl@gnu.org>
50849         build: GuixSD doesn't have /bin/bash
50850         * Makefile (SHELL): Search 'bash' in the PATH environment variable.
50852 2018-01-21  Bruno Haible  <bruno@clisp.org>
50854         Avoid test failures on Microsoft Windows Subsystem for Linux.
50855         * tests/test-fcntl.c (main): Allow a different errno.
50856         * tests/test-rename.h (test_rename): Likewise.
50857         * tests/test-renameat.c (main): Likewise.
50858         * tests/test-renameat2.c (main): Likewise.
50860 2018-01-14  Paul Eggert  <eggert@cs.ucla.edu>
50862         filenamecat: make base a suffix of result
50863         * lib/filenamecat-lgpl.c (longest_relative_suffix): Remove.
50864         (mfile_name_concat): Always make BASE a suffix of the result, as
50865         cp expects this.  To implement this, separate with '.' instead of
50866         '/' in some rare cases.  Clarify spec to say ./BASE not BASE.
50867         * tests/test-filenamecat.c (main): Adjust tests to match
50868         current behavior.  Check that BASE_IN_RESULT points to
50869         a copy of BASE and is a suffix of the resultk, and that DIR
50870         is a prefix of the result that is no longer than the prefix
50871         indicated by BASE_IN_RESULT.
50873 2018-01-04  Mathieu Lirzin  <mthl@gnu.org>
50875         update-copyright: Handle use of ©
50876         * build-aux/update-copyright ($circle_c_re): Update regex to
50877         handle use of © in headers.
50879 2018-01-04  Tim Rühsen  <tim.ruehsen@gmx.de>
50881         Fix -Wundef warning in user-included header lib/cdefs.h.
50882         * lib/cdefs.h: Check if defined before using __USE_FORTIFY_LEVEL.
50884 2018-01-04  Bruno Haible  <bruno@clisp.org>
50886         pthread_sigmask: Avoid compilation error on mingw.
50887         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
50888         * lib/signal.in.h (pthread_sigmask): Don't declare it it's defined as a
50889         macro.
50891 2018-01-03  Paul Eggert  <eggert@cs.ucla.edu>
50893         test-framework-sh: ‘ps -ef’, not ‘ps ef’
50894         * tests/init.sh (rand_bytes_): Put ‘-’ before new-style ps options.
50895         Suggested by Bob Proulx (Bug#29968).
50896         * build-aux/mktempd (rand_bytes): Make it like tests/init.sh.
50898 2018-01-02  Eric Blake  <eblake@redhat.com>
50900         stat-time: silence -Wunused-parameter regression
50901         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime):
50902         Prefer attribute over cast-to-void.
50903         (stat_time_normalize): Mark st as potentially unused.
50905 2018-01-02  Paul Eggert  <eggert@cs.ucla.edu>
50907         test-framework-sh: avoid netstat
50908         Problem reported by Kristýna Streitová (Bug#29947).
50909         * tests/init.sh (rand_bytes_): Stop using netstat, as it's
50910         deprecated on SuSE and it's not that important anyway.
50912 2018-01-01  Jim Meyering  <meyering@fb.com>
50914         update-copyright: add code to handle more special cases
50915         After running "make update-copyright" this year, five files
50916         required additional manual changes.  Automate those adjustments
50917         for next year.
50918         * Makefile (_year_and_prev): Define.
50919         (update-copyright): Add perl commands to induce this year's post-
50920         update-copyright adjustments.
50922 2018-01-01  Paul Eggert  <eggert@cs.ucla.edu>
50924         version-etc: new year
50925         * build-aux/gendocs.sh (version):
50926         * doc/gendocs_template:
50927         * doc/gendocs_template_min:
50928         * doc/gnulib.texi:
50929         * lib/version-etc.c (COPYRIGHT_YEAR):
50930         Update copyright dates by hand in templates and the like.
50932         maint: fix 'make update-copyright'
50933         * Makefile (update-copyright): Adjust to 2016-11-23 change
50934         to config/srclist-update, which changed the format of srclist.txt.
50936 2017-12-30  Paul Eggert  <eggert@cs.ucla.edu>
50938         chdir-safer: remove this module
50939         * MODULES.html.sh (func_all_modules): Remove chdir-safer.
50940         * NEWS: Document removal.
50941         * lib/chdir-safer.c, lib/chdir-safer.h, m4/afs.m4, m4/chdir-safer.m4:
50942         * modules/chdir-safer: Remove these files.
50944 2017-12-29  Samuel Thibault  <samuel.thibault@gnu.org>
50946         Add cross-compilation results for GNU/Hurd.
50947         * m4/calloc.m4: Add GNU/Hurd guess.
50948         * m4/cbrtl.m4: Likewise.
50949         * m4/ceil.m4: Likewise.
50950         * m4/ceilf.m4: Likewise.
50951         * m4/ceill.m4: Likewise.
50952         * m4/chown.m4: Likewise.
50953         * m4/duplocale.m4: Likewise.
50954         * m4/exp2l.m4: Likewise.
50955         * m4/expm1.m4: Likewise.
50956         * m4/fchdir.m4: Likewise.
50957         * m4/floor.m4: Likewise.
50958         * m4/floorf.m4: Likewise.
50959         * m4/fmod.m4: Likewise.
50960         * m4/fmodf.m4: Likewise.
50961         * m4/fmodl.m4: Likewise.
50962         * m4/getcwd.m4: Likewise.
50963         * m4/getgroups.m4: Likewise.
50964         * m4/gettimeofday.m4: Likewise.
50965         * m4/hypot.m4: Likewise.
50966         * m4/hypotf.m4: Likewise.
50967         * m4/hypotl.m4: Likewise.
50968         * m4/link-follow.m4: Likewise.
50969         * m4/link.m4: Likewise.
50970         * m4/linkat.m4: Likewise.
50971         * m4/log.m4: Likewise.
50972         * m4/log10.m4: Likewise.
50973         * m4/log10f.m4: Likewise.
50974         * m4/log1p.m4: Likewise.
50975         * m4/log1pf.m4: Likewise.
50976         * m4/log1pl.m4: Likewise.
50977         * m4/log2.m4: Likewise.
50978         * m4/log2f.m4: Likewise.
50979         * m4/logf.m4: Likewise.
50980         * m4/lstat.m4: Likewise.
50981         * m4/malloc.m4: Likewise.
50982         * m4/mbrlen.m4: Likewise.
50983         * m4/mbrtowc.m4: Likewise.
50984         * m4/mkdir.m4: Likewise.
50985         * m4/mkfifo.m4: Likewise.
50986         * m4/mknod.m4: Likewise.
50987         * m4/mkstemp.m4: Likewise.
50988         * m4/modf.m4: Likewise.
50989         * m4/modff.m4: Likewise.
50990         * m4/modfl.m4: Likewise.
50991         * m4/printf.m4: Likewise.
50992         * m4/pselect.m4: Likewise.
50993         * m4/ptsname.m4: Likewise.
50994         * m4/putenv.m4: Likewise.
50995         * m4/readlink.m4: Likewise.
50996         * m4/realloc.m4: Likewise.
50997         * m4/remainder.m4: Likewise.
50998         * m4/remainderf.m4: Likewise.
50999         * m4/remainderl.m4: Likewise.
51000         * m4/rmdir.m4: Likewise.
51001         * m4/round.m4: Likewise.
51002         * m4/roundf.m4: Likewise.
51003         * m4/roundl.m4: Likewise.
51004         * m4/select.m4: Likewise.
51005         * m4/setenv.m4: Likewise.
51006         * m4/signbit.m4: Likewise.
51007         * m4/sleep.m4: Likewise.
51008         * m4/stat.m4: Likewise.
51009         * m4/strerror.m4: Likewise.
51010         * m4/strtok_r.m4: Likewise.
51011         * m4/symlink.m4: Likewise.
51012         * m4/symlinkat.m4: Likewise.
51013         * m4/trunc.m4: Likewise.
51014         * m4/truncf.m4: Likewise.
51015         * m4/truncl.m4: Likewise.
51016         * m4/tzset.m4: Likewise.
51017         * m4/ungetc.m4: Likewise.
51018         * m4/usleep.m4: Likewise.
51019         * m4/wcwidth.m4: Likewise.
51021 2017-12-28  Bruno Haible  <bruno@clisp.org>
51023         gnulib-tool: Make --conditional-dependencies work better.
51024         Reported by Dmitry Selyutin <ghostman.sd@gmail.com>.
51025         * gnulib-tool (Options): Don't reject the combination of
51026         --conditional-dependencies with --with-tests.
51027         (func_emit_autoconf_snippets): Add argument referenceable_modules.
51028         Don't reference $modules.
51029         (func_import, func_create_testdir): Pass it.
51031 2017-12-19  Paul Eggert  <eggert@cs.ucla.edu>
51033         regex: use re_malloc etc. consistently
51034         Problem and original patch reported by Arnold Robbins in:
51035         https://sourceware.org/ml/libc-alpha/2017-12/msg00241.html
51036         * lib/regcomp.c (re_comp):
51037         * lib/regexec.c (push_fail_stack, build_trtable, match_ctx_clean):
51038         Use re_malloc/re_realloc/re_free instead of malloc/realloc/free.
51040 2017-12-15  Tim Rühsen  <tim.ruehsen@gmx.de>
51041             Paul Eggert  <eggert@cs.ucla.edu>
51043         glob: Silence warning about void pointer arithmetic.
51044         * lib/glob.c (glob): Use a 'char *', not a 'void *', in pointer
51045         arithmetic.
51047 2017-12-15  Bruno Haible  <bruno@clisp.org>
51049         spawn-pipe: Silence a clang warning.
51050         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
51051         * lib/spawn-pipe.c: Disable clang -Wconditional-uninitialized warnings
51052         in this file.
51054 2017-12-12  Paul Eggert  <eggert@cs.ucla.edu>
51056         explicit_bzero: port to macOS + Clang 9.0.0
51057         Problem reported by Marcus Johnson (Bug#29658).
51058         * lib/explicit_bzero.c (explicit_bzero) [__clang__]:
51059         Don’t use asm.
51061 2017-12-11  Reuben Thomas  <rrt@sc3d.org>
51063         doc: Improve explanation of supporting relocatable libraries.
51064         * doc/relocatable-maint.texi (Supporting Relocation): Explain
51065         properly how to build the relocatable module for
51066         libraries. (Method and example code from Bruno Haible.)
51068 2017-12-11  Reuben Thomas  <rrt@sc3d.org>
51070         doc: Use better texinfo tags in a few cases.
51071         * doc/gnulib.texi (Extending Gnulib): Use @option or @command
51072         instead of @samp in a few places.
51074 2017-12-11  Bruno Haible  <bruno@clisp.org>
51076         unistr/base: Update comment.
51077         * lib/unistr.in.h: Update comment about u*_mbtouc_unsafe functions.
51079 2017-12-10  Pádraig Brady  <P@draigBrady.com>
51081         test-faccessat.c: unlink temp file to avoid subsequent test failure
51082         * tests/test-faccessat.c: Remove the file to avoid failure
51083         to open the file on subsequent runs due to being created
51084         with no permissions.
51086 2017-12-10  Bruno Haible  <bruno@clisp.org>
51088         doc: New sect. "Modifying the build rules of a Gnulib import directory".
51089         * doc/gnulib-tool.texi (Modified build rules): New node.
51091 2017-12-10  Bruno Haible  <bruno@clisp.org>
51093         doc: Tweak wording.
51094         * doc/gnulib-tool.texi (Multiple instances): Talk about "programs", not
51095         "binaries".
51097 2017-12-05  Sam Steingold  <sds@gnu.org>
51098             Bruno Haible  <bruno@clisp.org>
51100         no-c++: Avoid "egrep: repetition-operator operand invalid" error.
51101         * m4/no-c++.m4 (gt_NO_CXX): Don't use '+' characters nor spaces in the
51102         AC_EGREP_CPP pattern.
51104 2017-12-03  Bruno Haible  <bruno@clisp.org>
51106         all: Replace more http URLs by https URLs.
51107         * lib/sm3.h, lib/sm3.c, tests/test-sm3.c: Use https: URL.
51108         * lib/unigbrk/u-grapheme-breaks.h: Likewise.
51109         * lib/unigbrk/uc-grapheme-breaks.c: Likewise.
51110         * tests/unigbrk/test-uc-grapheme-breaks.c: Likewise.
51112 2017-11-28  Paul Eggert  <eggert@cs.ucla.edu>
51114         Port better to CentOS 5
51115         Problems reported by Tom G. Christensen in:
51116         https://lists.gnu.org/r/bug-gnulib/2017-11/msg00053.html
51117         * doc/glibc-functions/strverscmp.texi (strverscmp):
51118         Document strverscmp bug with glibc 2.9 and earlier.
51119         * doc/posix-functions/tzset.texi (tzset):
51120         Document that TZ with angle brackets is POSIX-2001 and later.
51121         * tests/test-nstrftime.c: Include unistd.h.
51122         (TZ_ANGLE_BRACKETS_SHOULD_WORK): New macro.
51123         (TZ): Use it to skip tests with angle brackets in TZ,
51124         for older systems.
51126         stat: add missing module dependencies
51127         * modules/lstat, modules/stat, modules/utimensat (Depends-on):
51128         Add stat-time.
51130 2017-11-28  Benno Schulenberg  <bensberg@telfort.nl>
51132         stat: fix compilation failure on macOS Sierra
51133         Reported by Marius Schamschula <mschamschula@gmail.com> in:
51134         https://savannah.gnu.org/bugs/?52546
51135         * lib/stat.c: Add missing include of stat-time.h.
51137 2017-11-28  Jim Meyering  <meyering@fb.com>
51139         test-faccessat.c: correct BASE definition to avoid parallel test failure
51140         * tests/test-faccessat.c (BASE): Define using this file's name, not
51141         that of test-lstat.c.  Using the latter caused this test to fail
51142         sometimes when run concurrently with test-lstat.
51144 2017-11-27  Daiki Ueno  <ueno@gnu.org>
51146         unicase: fix VPATH build
51147         * modules/unicase/special-casing (Makefile.am): Ensure that the
51148         base directory is created when generating
51149         unicase/special-casing.h.
51151 2017-11-27  Daiki Ueno  <ueno@gnu.org>
51153         libunistring: update to Unicode 9.0.0
51154         * lib/gen-uni-tables.c (fill_properties): Recognize
51155         Sentence_Terminal and Prepended_Concatenation_Mark.
51156         (is_property_default_ignorable_code_point): Exclude U+08E2.
51157         (fill_arabicshaping): Allow missing whitespace when parsing;
51158         recognize "AFRICAN FEH", "AFRICAN QAF", and "AFRICAN MOON".
51159         (output_blocks): Increase the element size of the level1 table to
51160         accommodate more blocks.
51161         (get_lbp): Recognize ZWJ, E_Base, and E_Modifier characters;
51162         Update each class according to the standard.
51163         (get_wbp): Recognize ZWJ, E_Base, E_Modifier, Glue_After_Zwj, and
51164         E_Base_GAZ characters.
51165         (output_gbp_table): Recognize ZWJ, E_Base, E_Modifier,
51166         Glue_After_Zwj, and E_Base_GAZ characters.
51167         * lib/unictype.in.h (UC_JOINING_GROUP_AFRICAN_FEH)
51168         (UC_JOINING_GROUP_AFRICAN_QAF, UC_JOINING_GROUP_AFRICAN_MOON): New
51169         enum value.
51170         * lib/unilbrk/lbrktables.h (LBP_ZWJ, LBP_EB, LBP_EM): New enum
51171         value.
51172         * lib/unilbrk/lbrktables.c (unilbrk_table): Extend the table with
51173         LBP_ZWJ, LBP_EB, and LBP_EM.
51174         * lib/uniwbrk.in.h (WBP_ZWJ, WBP_EB, WBP_EM, WBP_GAZ, WBP_EBG): New
51175         enum value.
51176         * lib/uniwbrk/u-wordbreaks.h: Implement WB3c, WB15, and WB16.
51177         * lib/uniwbrk/wbrktable.h (uniwbrk_prop_index): New variable
51178         declaration.
51179         * lib/uniwbrk/wbrktable.c (uniwbrk_prop_index): New variable.
51180         (uniwbrk_table): Implement WB14.
51181         * tests/uniwbrk/test-uc-wordbreaks.c (wordbreakproperty_to_string):
51182         Check WBP_ZWJ, WBP_EB, WBP_EM, WBP_GAZ, and WBP_EBG.
51183         * modules/unigbrk/u{32,16,8}-grapheme-breaks: No longer depend on
51184         uc-is-grapheme-break.
51185         * modules/unigbrk/uc-grapheme-breaks: New module.
51186         * modules/unigbrk/uc-grapheme-breaks-tests: New module.
51187         * lib/unigbrk.in.h (GBP_ZWJ, GBP_EB, GBP_EM, GBP_GAZ, GBP_EBG): New
51188         enum value.
51189         (uc_grapheme_breaks): New function, replacing uc_is_grapheme_break.
51190         * lib/unigbrk/u-grapheme-breaks.h: New file.
51191         * lib/unigbrk/u{32,16,8}-grapheme-breaks.c: Rewrite using
51192         u-grapheme-breaks.h instead of uc_is_grapheme_break.
51193         * lib/unigbrk/uc-grapheme-breaks.c: New file.
51194         * lib/unigbrk/uc-is-grapheme-break.c: Partially update to TR29 rev
51195         29.
51196         * tests/unigbrk/test-uc-gbrk-prop.c
51197         (graphemebreakproperty_to_string): Check GBP_ZWJ, GBP_EB, GBP_EM,
51198         GBP_GAZ, and GBP_EBG.
51199         * tests/unigbrk/test-uc-grapheme-breaks.c: New test.
51200         * tests/unigbrk/test-uc-is-grapheme-break.c
51201         (graphemebreakproperty_to_string): Check GBP_ZWJ, GBP_EB, GBP_EM,
51202         GBP_GAZ, and GBP_EBG.
51203         (main): Skip unsupported rules involving 3 or more characters,
51204         namely GB10, GB12, and GB13.
51205         * lib/uniwidth/width.c (nonspacing_table_data): Update.
51206         * all generated files under lib/uni* and tests/uni*: Regenerate.
51207         * all the affected modules: Bump version.
51209 2017-11-26  Bruno Haible  <bruno@clisp.org>
51211         strfmon_l: Fix compilation error with glibc 2.5.
51212         Reported by Tom G. Christensen <tgc@jupiterrise.com>
51213         in <https://lists.gnu.org/r/bug-gnulib/2017-11/msg00051.html>.
51214         * lib/monetary.in.h: Include also <locale.h>.
51216 2017-11-24  Paul Eggert  <eggert@cs.ucla.edu>
51218         posixtm: remove PDS_LEADING_YEAR
51219         This changes the API slightly, in a hopefully-innocuous way.
51220         Without this change the code had undefined behavior when a
51221         caller specified neither PDS_LEADING_YEAR nor PDS_TRAILING_YEAR.
51222         Problem reported by Pádraig Brady in:
51223         https://lists.gnu.org/r/bug-gnulib/2017-11/msg00048.html
51224         * NEWS: Mention this.
51225         * lib/posixtm.c (posix_time_parse): Treat the absence of
51226         PDS_TRAILING_YEAR as if PDS_LEADING_YEAR were present.
51227         * lib/posixtm.h (PDS_LEADING_YEAR): Remove (actually, leave it
51228         present, but define it as zero, for compatibility with existing
51229         source code).  All other PDS_* values moved up.
51230         * tests/test-posixtm.c (LY): New macro.
51231         (T): Use it.  Do not expect a particular numeric encoding
51232         for PDS_CENTURY etc.
51234 2017-11-23  Paul Eggert  <eggert@cs.ucla.edu>
51236         stat: work around Solaris bug with tv_nsec < 0
51237         * doc/posix-functions/fstat.texi (fstat):
51238         * doc/posix-functions/fstatat.texi (fstatat):
51239         * doc/posix-functions/lstat.texi (lstat):
51240         * doc/posix-functions/stat.texi (stat):
51241         Mention Solaris 11 bug.
51242         * lib/fstat.c, lib/fstatat.c, lib/lstat.c: Include stat-time.h.
51243         * lib/fstat.c (rpl_fstat) [!WINDOWS_NATIVE]:
51244         * lib/lstat.c (rpl_lstat):
51245         * lib/stat.c (rpl_stat):
51246         Normalize resulting timestamps.
51247         * lib/fstatat.c (normal_fstatat): New function.
51248         (rpl_fstatat): Use it.
51249         * lib/stat-time.h: Include intprops.h, errno.h, stddef.h.
51250         (stat_time_normalize): New function.
51251         * m4/fstat.m4 (gl_FUNC_FSTAT):
51252         * m4/fstatat.m4 (gl_FUNC_FSTATAT):
51253         * m4/lstat.m4 (gl_FUNC_LSTAT):
51254         * m4/stat.m4 (gl_FUNC_STAT):
51255         Replace on Solaris.
51256         * modules/fstat (Depends-on):
51257         * modules/fstatat (Depends-on):
51258         Add stat-time.
51259         * modules/stat-time (Depends-on): Add errno, intprops.
51261 2017-11-22  Paul Eggert  <eggert@cs.ucla.edu>
51263         regex: merge from glibc
51264         * lib/regcomp.c (init_word_char): Add comments.
51266 2017-11-20  Paul Eggert  <eggert@cs.ucla.edu>
51268         regex: merge from glibc
51269         * lib/regcomp.c (__regcomp, __regfree) [_LIBC]: Now hidden.
51270         * lib/regex_internal.h (internal_function): Remove.
51271         All uses removed.
51273 2017-11-20  Bruno Haible  <bruno@clisp.org>
51275         crypto/gc-sm3: Fix buffer overrun.
51276         * lib/gc-gnulib.c (MAX_DIGEST_SIZE): Bump to 32.
51277         Reported by Coverity.
51279 2017-11-12  Jim Meyering  <meyering@fb.com>
51281         maint: shorten https://lists.gnu.org/archive/html/... links
51282         Each /archive/html/ part can be replace with /r/.
51283         Run this to induce the change:
51284         git grep -l archive/html|xargs perl -pi -e 's,/archive/html/,/r/,g'
51285         * ChangeLog: Perform that substitution.
51286         * Makefile: Likewise.
51287         * STATUS-libposix: Likewise.
51288         * build-aux/bootstrap: Likewise.
51289         * doc/maintain.texi: Likewise.
51290         * gnulib-tool: Likewise.
51291         * lib/allocator.h: Likewise.
51292         * lib/argp-ba.c: Likewise.
51293         * lib/argp-pv.c: Likewise.
51294         * lib/canon-host.c: Likewise.
51295         * lib/canonicalize-lgpl.c: Likewise.
51296         * lib/float.in.h: Likewise.
51297         * lib/fstat.c: Likewise.
51298         * lib/getdelim.c: Likewise.
51299         * lib/getprogname.c: Likewise.
51300         * lib/glthread/thread.h: Likewise.
51301         * lib/intprops.h: Likewise.
51302         * lib/mbsrtowcs-state.c: Likewise.
51303         * lib/safe-read.c: Likewise.
51304         * lib/signal.in.h: Likewise.
51305         * lib/stat.c: Likewise.
51306         * lib/stdbool.in.h: Likewise.
51307         * lib/stdio-impl.h: Likewise.
51308         * lib/stdio.in.h: Likewise.
51309         * lib/sysexits.in.h: Likewise.
51310         * lib/timespec.h: Likewise.
51311         * lib/wcsrtombs-state.c: Likewise.
51312         * m4/alloca.m4: Likewise.
51313         * m4/extern-inline.m4: Likewise.
51314         * m4/fstatat.m4: Likewise.
51315         * m4/gnulib-common.m4: Likewise.
51316         * m4/lib-ignore.m4: Likewise.
51317         * m4/printf.m4: Likewise.
51318         * m4/regex.m4: Likewise.
51319         * m4/stat-size.m4: Likewise.
51320         * m4/std-gnu11.m4: Likewise.
51321         * m4/stdbool.m4: Likewise.
51322         * m4/sys_types_h.m4: Likewise.
51323         * m4/threadlib.m4: Likewise.
51324         * m4/vararrays.m4: Likewise.
51325         * pygnulib/GLImport.py: Likewise.
51326         * tests/test-exp.h: Likewise.
51327         * tests/test-exp2.h: Likewise.
51328         * tests/test-expm1.h: Likewise.
51329         * tests/test-fflush2.c: Likewise.
51330         * tests/test-getopt_long.h: Likewise.
51331         * tests/test-intprops.c: Likewise.
51332         * tests/test-log.h: Likewise.
51333         * tests/test-log10.h: Likewise.
51334         * tests/test-log1p.h: Likewise.
51335         * tests/test-log2.h: Likewise.
51336         * tests/test-printf-posix.h: Likewise.
51337         * tests/test-regex.c: Likewise.
51338         * tests/test-snprintf-posix.h: Likewise.
51339         * tests/test-sprintf-posix.h: Likewise.
51340         * tests/test-stdalign.c: Likewise.
51341         * tests/test-stdbool.c: Likewise.
51342         * tests/test-vasnprintf-posix.c: Likewise.
51343         * tests/test-vasprintf-posix.c: Likewise.
51344         * top/maint.mk: Likewise.
51346 2017-11-12  Bruno Haible  <bruno@clisp.org>
51348         faccessat: Make the last change more robust.
51349         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Require
51350         gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK. Treat "guessing yes" like "yes".
51352 2017-11-11  Paul Eggert  <eggert@cs.ucla.edu>
51354         faccessat: port to macOS (Bug#29231)
51355         macOS faccessat has the same bug that lstat does: if the file
51356         name ends in '/' it ignores the trailing slash.
51357         Problem reported for Emacs by Vincent Zhang.
51358         * doc/posix-functions/faccessat.texi (faccessat): Document this.
51359         * lib/faccessat.c (_GL_INCLUDING_UNISTD_H): Define and undef
51360         around the initial includes.  Include errno.h, string.h, sys/stat.h.
51361         (orig_faccessat) [HAVE_FACCESSAT]: New function.
51362         Include "unistd.h" after defining it.
51363         (rpl_faccessat) [HAVE_FACCESSAT]: New implementation.
51364         * lib/unistd.in.h (faccessat) [REPLACE_FACCESSAT]:
51365         Handle in the usual way.
51366         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Replace faccessat if
51367         lstat dereferences symlinks, since faccessat is likely to
51368         have the same problem.
51369         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Default REPLACE_ACCESSAT.
51370         * modules/faccessat (Depends-on): Add fstatat.
51371         Depend if REPLACE_FACCESSAT is 1, too.
51372         (configure.ac): Link if REPLACE_FACCESSAT is 1.
51373         * modules/faccessat-tests (Depends-on): Add symlink.
51374         * modules/unistd (unistd.h): Substitute REPLACE_FACCESSAT.
51375         * tests/test-faccessat.c (main): Test for the bug.
51377 2017-11-11  Bruno Haible  <bruno@clisp.org>
51379         getprogname: Fix compilation error on IRIX.
51380         * lib/getprogname.c (getprogname) [__sgi]: Fix type of local variable
51381         'namesize'.
51383 2017-11-11  Bruno Haible  <bruno@clisp.org>
51385         year2038: Tweak last patch.
51386         * m4/year2038.m4 (gl_YEAR2038): Correct indentation.
51388 2017-11-06  Paul Eggert  <eggert@cs.ucla.edu>
51390         year2038: be more insistent about 64-bit time_t
51391         Applications requiring access to arbitrary files should not be
51392         built with 32-bit time_t on hosts that have 64-bit timestamps,
51393         as this can lead to real trouble at runtime.
51394         * m4/year2038.m4 (gl_YEAR2038): Do not require AC_CANONICAL_HOST.
51395         Check on all systems, not just MinGW.  Use a heuristic involving
51396         TIME_T_32_BIT_OK, cross_compiling, and the touch command to
51397         output a failure or just a warning, to make it more likely that
51398         builders will select 64-bit time_t.
51400 2017-11-05  Paul Eggert  <eggert@cs.ucla.edu>
51402         havelib: fix typo in previous change
51403         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Fix typo.
51405         Don’t use AC_EGREP_CPP if affected by CFLAGS
51406         * m4/float_h.m4 (gl_FLOAT_H):
51407         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI):
51408         * m4/lib-ld.m4 (AC_LIB_PROG_LD):
51409         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB):
51410         * m4/year2038.m4 (gl_YEAR2038):
51411         Prefer AC_COMPILE_IFELSE to AC_EGREP_CPP when testing conditions
51412         likely to be affected by the choice of CFLAGS, since CFLAGS are
51413         not used by AC_EGREP_CPP.  Without this patch, ‘./configure
51414         CFLAGS="-m32"’ fails on gzip with GNU/Linux x86-64.
51416         fstatat: pacify GCC on unusual platform
51417         * lib/fstatat.c (orig_fstatat) [!HAVE_WORKING_FSTATAT_ZERO_FLAG]:
51418         Omit, as it’s unused in this case.
51420 2017-10-29  Paul Eggert  <eggert@cs.ucla.edu>
51422         timespec: prefer ‘assume’ to ‘assure’
51423         This avoids some runtime tests.  The rest of the module makes
51424         similar assumptions and there is little point to testing here.
51425         * lib/timespec.h: Include verify.h instead of assure.h.
51426         (timespec_cmp): Use ‘assume’, not ‘assure’.
51427         Also, remove an unnecessary cast to ‘int’, as lots of other
51428         code in this module now causes -Wconversion to complain, and
51429         this is a problem with -Wconversion not with the code.
51431         * modules/timespec (Depends-on): Depend on ‘verify’, not ‘assure’.
51433         Port recent gnulib-tool change to Dash
51434         * gnulib-tool (func_create_testdir): Don't assume that the shell
51435         retokenizes after expanding "$@" inside the call to
51436         func_execute_command.  Dash 0.5.8-2.1ubuntu2 does not.
51438 2017-10-27  Jim Meyering  <meyering@fb.com>
51440         timespec.h: use "assure" to avoid a spurious warning
51441         * lib/timespec.h: Include "assure.h" and use it to help
51442         gcc7's -Wstrict-overflow avoid a false positive warning
51443         for a use in coreutils' ls.c.  Suggested by Paul Eggert in
51444         https://lists.gnu.org/r/bug-gnulib/2017-10/msg00007.html
51445         * modules/timespec (Depends-on): Add assure.
51447 2017-10-29  Bruno Haible  <bruno@clisp.org>
51449         Avoid several test failures with traditional locales on Haiku.
51450         * m4/locale-ar.m4 (gt_LOCALE_AR): On BeOS and Haiku, set LOCALE_AR=none.
51451         * m4/locale-fr.m4 (gt_LOCALE_FR): On BeOS and Haiku, set LOCALE_FR=none.
51452         * m4/locale-ja.m4 (gt_LOCALE_JA): On BeOS and Haiku, set LOCALE_JA-none.
51453         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): On BeOS and Haiku, set
51454         LOCALE_ZH_CN=none.
51456 2017-10-29  Bruno Haible  <bruno@clisp.org>
51458         strerror_r-posix: Fix behaviour and test failure on Haiku.
51459         * lib/strerror_r.c (strerror_r): Don't assume that valid error numbers
51460         are positive. Work around return value 0 instead of ERANGE on Haiku.
51461         For unknown error numbers, use a format string consistent with perror().
51462         * doc/posix-functions/strerror_r.texi: Mention the Haiku problem.
51463         * tests/test-strerror_r.c (main): Don't assume that valid error numbers
51464         are positive.
51466 2017-10-29  Bruno Haible  <bruno@clisp.org>
51468         get-rusage-data: Avoid crash on Haiku.
51469         * lib/get-rusage-data.c: Avoid the setlimit-based implementation.
51471 2017-10-29  Bruno Haible  <bruno@clisp.org>
51473         get-rusage-as: Avoid crash on Haiku.
51474         * lib/get-rusage-as.c: Avoid the setlimit-based implementation.
51476 2017-10-29  Bruno Haible  <bruno@clisp.org>
51478         ilogbl: Ensure replacement on Haiku.
51479         * m4/ilogbl.m4 (gl_FUNC_ILOGBL): Invoke gl_FUNC_ILOGBL_WORKS and set
51480         REPLACE_ILOGBL if ilogbl does not work.
51481         (gl_FUNC_ILOGBL_WORKS): New macro.
51482         * lib/math.in.h (ilogbl): Replace if REPLACE_ILOGBL is 1.
51483         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_ILOGBL.
51484         * modules/math (Makefile.am): Substitute REPLACE_ILOGBL.
51485         * modules/ilogbl (Depends-on, configure.ac): Consider REPLACE_ILOGBL.
51486         * doc/posix-functions/ilogbl.texi: Mention the Haiku problem.
51488 2017-10-29  Bruno Haible  <bruno@clisp.org>
51490         expl: Ensure replacement on Haiku.
51491         * m4/expl.m4 (gl_FUNC_EXPL): Test whether an expl() return value is
51492         zero.
51493         * doc/posix-functions/expl.texi: Mention the Haiku problem.
51495 2017-10-29  Bruno Haible  <bruno@clisp.org>
51497         math: Fix test failure on Haiku.
51498         * lib/math.in.h (FP_ILOGB0, FP_ILOGBNAN): Override on Haiku.
51499         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Update accordingly.
51500         * m4/ilogbf.m4 (gl_FUNC_ILOGBF_WORKS): Likewise.
51501         * doc/posix-headers/math.texi: Mention the Haiku problem.
51503 2017-10-29  Bruno Haible  <bruno@clisp.org>
51505         gnulib-tool: Avoid unnecessary config.h.in remaking in testdirs.
51506         * gnulib-tool (func_create_testdir): Use workaround against 'autoheader'
51507         bug reported at <https://savannah.gnu.org/support/index.php?109406>.
51509 2017-10-29  Bruno Haible  <bruno@clisp.org>
51511         crypto/*: Verify that the header file is self-contained.
51512         * tests/test-gc-*.c: Include the module's header file immediately after
51513         <config.h>.
51514         * tests/test-hmac-*.c: Likewise.
51515         * tests/test-arcfour.c: Likewise.
51516         * tests/test-arctwo.c: Likewise.
51517         * tests/test-des.c: Likewise.
51518         * tests/test-md2.c: Likewise.
51519         * tests/test-md4.c: Likewise.
51520         * tests/test-md5.c: Likewise.
51521         * tests/test-rijndael.c: Likewise.
51522         * tests/test-sha1.c: Likewise.
51523         * tests/test-sm3.c: Likewise.
51525 2017-10-29  Jia Zhang  <qianyue.zj@alibaba-inc.com>
51526             Bruno Haible  <bruno@clisp.org>
51528         crypto/gc: fix build failure with -Werror=suggest-attribute=const
51529         * lib/gc.h (gc_hash_digest_length): Mark with 'const' attribute.
51531 2017-10-29  Jia Zhang  <qianyue.zj@alibaba-inc.com>
51533         New module: crypto/gc-sm3
51534         * lib/gc.h: Declare SM3-related stuffs.
51535         * lib/gc-gnulib.c: Support sm3 in internal functions.
51536         * lib/gc-libgcrypt.c: Support sm3 with libgcrypt.
51537         * m4/gc-sm3.m4: m4 file for gc-sm3 module.
51538         * modules/crypto/gc-sm3: Define gc-sm3 module.
51539         * tests/test-gc-sm3.c: Implement SM3 test case with libgcrypt.
51540         * modules/crypto/gc-sm3-tests: Define gc-sm3 test module.
51541         * MODULES.html.sh: List gc-sm3 module.
51543 2017-10-29  Bruno Haible  <bruno@clisp.org>
51545         random, random_r: Mention different prototypes on Haiku.
51546         * doc/posix-functions/random.texi: Mention different prototype on Haiku.
51547         * doc/glibc-functions/random_r.texi: Likewise.
51548         * doc/glibc-functions/initstate_r.texi: Likewise.
51549         * doc/glibc-functions/setstate_r.texi: Likewise.
51551 2017-10-28  Bruno Haible  <bruno@clisp.org>
51553         posix_spawn: Avoid spurious message in configure output.
51554         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Discard stderr output from
51555         'cmp' command.
51557 2017-10-28  Bruno Haible  <bruno@clisp.org>
51559         inet_ntop, inet_pton: Determine needed library correctly on Haiku.
51560         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Search also in libnetwork.
51561         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
51563 2017-10-28  Bruno Haible  <bruno@clisp.org>
51565         ioctl: Override non-POSIX declaration on Haiku.
51566         * m4/ioctl.m4 (gl_FUNC_IOCTL): Include also <unistd.h>.
51567         * lib/sys_ioctl.in.h: Add comment about Haiku.
51568         * doc/posix-functions/ioctl.texi: Mention Haiku problem.
51569         * doc/glibc-headers/sys_ioctl.texi: Likewise.
51571 2017-10-28  Bruno Haible  <bruno@clisp.org>
51573         crypto/sm3: Add overview documentation to the .h file.
51574         * lib/sm3.h: Add comments.
51576 2017-10-28  Jia Zhang  <qianyue.zj@alibaba-inc.com>
51578         New module: crypto/sm3
51579         This new module can be used to compute SM3 message digest of files or
51580         memory blocks according to the specification GM/T 004-2012
51581         Cryptographic Hash Algorithm SM3, published by State Cryptography
51582         Administration, China.
51583         The official SM3 cryptographic hash algorithm specification is
51584         available at
51585         http://www.sca.gov.cn/sca/xwdt/2010-12/17/content_1002389.shtml
51586         * lib/sm3.h: Declare the APIs of sm3 module.
51587         * lib/sm3.c: Implement SM3 hash algorithm.
51588         * m4/sm3.m4: m4 file for sm3 module.
51589         * modules/crypto/sm3: Define sm3 module.
51590         * tests/test-sm3.c: Implement SM3 test case.
51591         * modules/crypto/sm3-tests: Define sm3 test module.
51592         * MODULES.html.sh: List sm3 module.
51594 2017-10-28  Jia Zhang  <qianyue.zj@alibaba-inc.com>
51596         gc-libgcrypt: fix undefined enum type in switch statement
51597         Resolve the following build failure:
51598         lib/gc-libgcrypt.c: In function 'gc_hash_open':
51599         lib/gc-libgcrypt.c:317:5: error: case value '0' not in enumerated type
51600         'Gc_hash_mode {aka enum Gc_hash_mode}' [-Werror=switch]
51601              case 0:
51602              ^~~~
51603         * lib/gc.h (enum Gc_hash_mode): Add value GC_NULL.
51604         * lib/gc-libgcrypt.c (gc_hash_open): Use this enum value instead of 0.
51606 2017-10-28  Jia Zhang  <qianyue.zj@alibaba-inc.com>
51608         gc-libgcrypt: fix assignment error due to -Werror=pointer-sign
51609         Resolve the following build failure:
51610         lib/gc-libgcrypt.c: In function 'gc_hash_read':
51611         lib/gc-libgcrypt.c:460:14: error: pointer targets in assignment differ
51612         in signedness [-Werror=pointer-sign]
51613             digest = gcry_md_read (ctx->gch, 0);
51614                    ^
51615         * lib/gc-libgcrypt.c (gc_hash_read): Cast result of gcry_md_read.
51617 2017-10-26  Bruno Haible  <bruno@clisp.org>
51619         havelib: Fix value of LD for 32-bit compilation on NetBSD/sparc64.
51620         * m4/lib-ld.m4 (AC_LIB_PROG_LD): On NetBSD/sparc64 with CC="gcc -m32",
51621         set LD to '/usr/bin/ld -m elf32_sparc', not '/usr/bin/ld'.
51623 2017-10-21  Paul Eggert  <eggert@cs.ucla.edu>
51625         glob: fix another heap buffer overflow
51626         Problem reported by Tim Rühsen in:
51627         https://sourceware.org/bugzilla/show_bug.cgi?id=22332
51628         * lib/glob.c (glob): Avoid buffer overrun when unescaping.
51630 2017-10-19  Paul Eggert  <eggert@cs.ucla.edu>
51632         quotearg: pacify compiler re unsigned
51633         * lib/quotearg.c (quotearg_n_options):
51634         Rewrite to avoid diagnostic from overly-picky compiler.
51635         Problem reported by Sami Kerola in:
51636         https://lists.gnu.org/r/bug-gnulib/2017-10/msg00060.html
51638         glob: fix heap buffer overflow
51639         * lib/glob.c (glob): Fix off-by-one error introduced into
51640         glibc in commit dd7d45e838a42b0ed470c44b55901ea98d0c2bab
51641         dated 1997-10-29 20:33:40.  Problem reported by Tim Rühsen in:
51642         https://sourceware.org/bugzilla/show_bug.cgi?id=22320
51643         Fix suggested by Bruno Haible.
51645 2017-10-18  Paul Eggert  <eggert@cs.ucla.edu>
51647         glob: pacify fuzzer for mempcpy
51648         Problem reported by Tim Rühsen in:
51649         https://lists.gnu.org/r/bug-gnulib/2017-10/msg00054.html
51650         * lib/glob.c (glob): Do not pass NULL to mempcpy.
51652 2017-10-12  Bruno Haible  <bruno@clisp.org>
51654         doc: Fix syntax error (regression from 2017-10-03).
51655         * doc/posix-functions/strncpy.texi: Fix syntax error.
51657 2017-10-12  Bruno Haible  <bruno@clisp.org>
51659         doc: Update for Solaris 11.3.
51660         * doc/**/*.texi: For bugs that exist in both Solaris 11.0 and 11.3,
51661         mention Solaris 11.3.
51662         * m4/log2.m4: Fix comments.
51663         * m4/log2f.m4: Likewise.
51664         * m4/printf.m4: Update comments.
51665         * m4/rename.m4: Likewise.
51666         * m4/strncat.m4: Likewise.
51668         all: Write "Solaris 11.0" instead of "Solaris 11 2011-11".
51670 2017-10-10  Bruno Haible  <bruno@clisp.org>
51672         doc: Improve doc about ioctl.
51673         * doc/posix-functions/ioctl.texi: Fix list of platforms with non-POSIX
51674         prototype.
51676 2017-10-09  Bruno Haible  <bruno@clisp.org>
51678         wcwidth: Don't use obsolete syntax of 'test'.
51679         Reported by Eric Blake.
51680         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Don't optimize two 'test'
51681         invocations into one, as POSIX marks '-a' and '-o' as "obsolescent".
51683 2017-10-09  Bruno Haible  <bruno@clisp.org>
51685         getopt-posix: Fix build failure when using ac_cv_header_getopt_h=no.
51686         Reported by Christian Ehrhardt <christian.ehrhardt@canonical.com>
51687         and Daniel P. Berrange <berrange@redhat.com>.
51688         * lib/unistd.in.h (getopt): Don't attempt to avoid namespace pollution
51689         on glibc systems. The getopt-pfx-core.h file declares exactly what
51690         unistd.h needs, nothing more.
51692 2017-10-08  Bruno Haible  <bruno@clisp.org>
51694         vma-iter: Improve support for FreeBSD.
51695         * lib/vma-iter.c (vma_iterate_proc): New function, extracted from
51696         vma_iterate.
51697         (vma_iterate): Use it. For FreeBSD, try vma_iterate_bsd first.
51699 2017-10-08  Bruno Haible  <bruno@clisp.org>
51701         vma-iter: Fix truncated result on NetBSD (regression from 2017-10-07).
51702         * lib/vma-iter.c (MIN_LEFTOVER): Define to 1, not 0.
51704 2017-10-07  KO Myung-Hun  <komh@chollian.net>
51706         test-framework-sh: Fix 'invalid path dir' error.
51707         On OS/2, a path separator is ';' not ':'. And ':' is used as a
51708         separator between a drive letter and directory parts.
51709         As a result, an absolute path such as x:/path/to/dir on OS/2 is
51710         treated as an invalid path dir.
51711         * tests/init.sh (PATH_SEPARATOR): Set at startup.
51712         (path_prepend_): '?:*' is also an absolute path. Use $PATH_SEPARATOR
51713         instead of hard coded ':'.
51715 2017-10-07  Bruno Haible  <bruno@clisp.org>
51717         vma-iter: Fix truncated result on Linux (regression from 2017-09-26).
51718         * lib/vma-iter.c (MIN_LEFTOVER): New macro.
51719         (STACK_ALLOCATED_BUFFER_SIZE): Set to a minimal value if not needed.
51720         (rof_open): On Linux, do multiple read() calls and make sure
51721         MIN_LEFTOVER bytes are left when read() returns.
51723 2017-10-07  Bruno Haible  <bruno@clisp.org>
51725         vma-iter: Improve support for GNU/Hurd.
51726         * lib/vma-iter.c (vma_iterate): On GNU/Hurd, use the Mach vm_region()
51727         API, not the /proc file system.
51729 2017-10-07  Bruno Haible  <bruno@clisp.org>
51731         test-framework-sh: Don't require bash on Windows and OS/2.
51732         Reported by KO Myung-Hun.
51733         * tests/test-init.sh: Use 'shopt' only when running in bash.
51735 2017-10-06  KO Myung-Hun  <komh@chollian.net>
51737         wcwidth: check a macro version of wcwidth () as well
51738         * lib/wchar.in.h: Revert commit from 2016-01-14.
51739         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test if wcwidth is a macro.
51741 2017-10-06  Bruno Haible  <bruno@clisp.org>
51743         getopt-posix: Clarify copyright header.
51744         * lib/getopt.in.h: Don't state that gnulib is under LGPL.
51745         * lib/getopt-pfx-core.h: Likewise.
51746         * lib/getopt-pfx-ext.h: Likewise.
51747         * lib/getopt-cdefs.in.h: Likewise.
51749 2017-10-03  Bruno Haible  <bruno@clisp.org>
51751         Fix warning "`gl_HOST_CPU_C_ABI' was expanded before it was required".
51752         * modules/host-cpu-c-abi (configure.ac): Require, don't invoke
51753         gl_HOST_CPU_C_ABI.
51755 2017-10-03  Bruno Haible  <bruno@clisp.org>
51757         doc: warn about misuse of strncpy and wcsncpy.
51758         * doc/posix-functions/strcpy.texi: Describe requirements on prior
51759         memory allocation.
51760         * doc/posix-functions/wcscpy.texi: Likewise.
51761         * doc/posix-functions/strncpy.texi: Describe what this function is not
51762         useful for.
51763         * doc/posix-functions/wcsncpy.texi: Likewise.
51765 2017-10-02  Paul Eggert  <eggert@cs.ucla.edu>
51767         fsuage: fix typo in previous change
51768         * lib/fsusage.c: Remove stray include of full-read.h.
51769         Problem reported by Sam Steingold for macOS (Bug#28669).
51771 2017-10-01  Paul Eggert  <eggert@cs.ucla.edu>
51773         fsusage: remove SVR2 support
51774         SVR2 was obsolete by 1986 and is no longer supported by anybody,
51775         and its code was getting in the way of use of this module by
51776         Emacs, which has its own ‘read’ function anyway.
51777         * lib/fsusage.c: Do not include sys/filsys.h.
51778         (get_fs_usage): Remove SVR2-specific code.
51779         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE):
51780         Do not test for sys/filsys.h or set STAT_READ_FILSYS.
51781         * modules/fsusage (Depends-on): Do not depend on full-read.
51783         Simplify autoupdate of licenses
51784         * config/srclistvars.sh (GNUWWWLICENSES): Move to a more-typical
51785         place.
51787 2017-10-01  Bruno Haible  <bruno@clisp.org>
51789         vma-iter: Add support for GNU/Hurd.
51790         * lib/vma-iter.c: Treat GNU/Hurd like Linux.
51791         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on GNU/kFreeBSD.
51793 2017-09-30  Bruno Haible  <bruno@clisp.org>
51795         vma-iter: Make it work on 32-bit Solaris with module 'largefile'.
51796         * modules/vma-iter: Don't test for sys/procfs.h, as this test would
51797         fail when module 'largefile' is in use.
51798         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Don't test HAVE_SYS_PROCFS_H.
51799         * lib/vma-iter.c: Undefine _FILE_OFFSET_BITS early.
51800         Don't test HAVE_SYS_PROCFS_H.
51802 2017-09-30  Bruno Haible  <bruno@clisp.org>
51804         havelib: Make it work for CC="gcc -m32" (regression from 2017-02-19).
51805         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Require gl_HOST_CPU_C_ABI.
51806         When $CC produces 32-bit code, set acl_libdirstem to 'lib', not 'lib64'.
51807         * modules/havelib (Depends-on): Add host-cpu-c-abi.
51809 2017-09-30  Bruno Haible  <bruno@clisp.org>
51811         uniname/uniname: Don't assume C99 compiler (regression from 2015-02-16).
51812         * lib/uniname/uniname.c (unicode_name_character): Add braces around
51813         scope of local variables.
51815 2017-09-28  Bruno Haible  <bruno@clisp.org>
51817         string: code style
51818         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Reorder list of
51819         substitutable variables.
51820         * modules/string (Makefile.am): Likewise.
51822 2017-09-26  Bruno Haible  <bruno@clisp.org>
51824         uniname/uniname-tests: Tighten code.
51825         * tests/uniname/test-uninames.c (fill_names, fill_aliases): Merge two
51826         local variables into one.
51828 2017-09-26  Bruno Haible  <bruno@clisp.org>
51830         vma-iter: Improvements for Linux and BSD platforms.
51831         - Add support for DragonFly BSD.
51832         - Make it more reliable on Linux, GNU/kFreeBSD, FreeBSD, NetBSD.
51833         * lib/vma-iter.c (struct rofile, rof_open, rof_peekchar, rof_close):
51834         Read the entire file into memory in a single system call.
51835         (vma_iterate): Update. Read from /proc on DragonFly BSD like on FreeBSD.
51836         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on DragonFly BSD.
51838 2017-09-26  Bruno Haible  <bruno@clisp.org>
51840         vma-iter: Provide the protection flags on FreeBSD.
51841         * lib/vma-iter.c (vma_iterate) [FreeBSD]: When reading from /proc,
51842         skip three fields between the addresses and the protection flags.
51844 2017-09-26  Paul Eggert  <eggert@cs.ucla.edu>
51846         glob: remove bogus extern decl
51847         * lib/glob.c (__glob_pattern_type): Remove now-spurious
51848         extern declaration.  Problem reported by Adhemerval Zanella in:
51849         https://sourceware.org/ml/libc-alpha/2017-09/msg00972.html
51851 2017-09-25  Paul Eggert  <eggert@cs.ucla.edu>
51853         uniname/uniname-tests: integer overflow fix
51854         * tests/uniname/test-uninames.c (fill_names, fill_aliases):
51855         Check for integer overflow.
51857         duplocale-tests: fix unlikely crash
51858         * tests/test-duplocale.c (get_locale_dependent_values):
51859         Don’t crash with absurdly long month names.
51861         maint: fix overflow checking in nap.h
51862         * modules/chown-tests:
51863         * modules/fchownat-tests, modules/fdutimensat-tests:
51864         * modules/futimens-tests, modules/lchown-tests:
51865         * modules/stat-time-tests, modules/utime-tests:
51866         * modules/utimens-tests, modules/utimensat-tests:
51867         Depend on intprops.
51868         * tests/nap.h: Include intprops.h.
51869         (diff_timespec): Handle overflow properly.
51871         sys_types: update URL
51872         * m4/sys_types_h.m4: Use https: URL.
51874         parse-datetime: fix dependency
51875         * modules/parse-datetime (Depends-on): Depend
51876         on nstrftime, not strftime.
51878         parse-datetime, posixtm: avoid uninit access
51879         * lib/parse-datetime.y (parse_datetime2):
51880         * lib/posixtm.c (posixtime):
51881         Do not access uninitialized storage, even though the resulting
51882         value is never used.
51884 2017-09-25  Bruno Haible  <bruno@clisp.org>
51886         vma-iter: Improvements for BSD platforms.
51887         - Add support for GNU/kFreeBSD.
51888         - Make it work on FreeBSD and NetBSD even when /proc is not mounted.
51889         - Speed up on OpenBSD.
51890         * lib/vma-iter.c (struct rofile, rof*): Define also on GNU/kFreeBSD.
51891         (vma_iterate_bsd): New function.
51892         (vma_iterate): Use it as fallback on FreeBSD and NetBSD. Use it as
51893         first choice on OpenBSD. Treat GNU/kFreeBSD like Linux.
51894         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on GNU/kFreeBSD.
51895         * modules/vma-iter (configure.ac): Require AC_C_INLINE.
51897 2017-09-23  Bruno Haible  <bruno@clisp.org>
51899         strfmon_l: New module.
51900         * modules/strfmon_l: New file.
51901         * lib/strfmon_l.c: New file.
51902         * m4/strfmon_l.m4: New file.
51903         * doc/posix-functions/strfmon_l.texi: Mention the new module.
51904         * modules/strfmon_l-tests: New file.
51905         * tests/test-strfmon_l.c: New file.
51907         monetary: New module.
51908         * modules/monetary: New file.
51909         * lib/monetary.in.h: New file.
51910         * m4/monetary_h.m4: New file.
51911         * doc/posix-headers/monetary.texi: Mention the new module.
51912         * modules/monetary-tests: New file.
51913         * tests/test-monetary.c: New file.
51914         * modules/monetary-c++-tests: New file.
51915         * tests/test-monetary-c++.cc: New file.
51916         * modules/duplocale-tests (configure.ac): Use AC_CHECK_HEADERS_ONCE.
51918 2017-09-23  Bruno Haible  <bruno@clisp.org>
51920         duplocale tests: Fix test crash on Linux/x86.
51921         * tests/test-duplocale.c (test_with_uselocale): Disconnect the mixed2
51922         locale from the current thread before freeing it.
51924 2017-09-21  Paul Eggert  <eggert@cs.ucla.edu>
51926         mktime: port to OpenVMS
51927         Problem reported by John E. Malmberg in:
51928         https://lists.gnu.org/r/bug-gnulib/2017-09/msg00100.html
51929         * m4/mktime.m4 (TIME_T_IS_SIGNED): Default to 0.
51931 2017-09-16  Paul Eggert  <eggert@cs.ucla.edu>
51933         manywarnings: port to GCC on 64-bit MS-Windows
51934         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Work better if
51935         LONG_MAX < PTRDIFF_MAX.  Problem reported by Richard Copley in:
51936         https://lists.gnu.org/r/emacs-devel/2017-09/msg00392.html
51938 2017-09-13  Bruno Haible  <bruno@clisp.org>
51940         all: Replace many more http URLs by https URLs. Update stale URLs.
51941         * users.txt: Remove mention of 'newts'.
51942         * lib/localename.c: Update comment about LANG_SOTHO.
51944 2017-09-13  Paul Eggert  <eggert@cs.ucla.edu>
51946         all: Replace many http URLs by https URLs.
51948 2017-09-12  Bruno Haible  <bruno@clisp.org>
51950         doc: Prefer https URLs where possible.
51951         * doc/**/*.texi: Use https URLs instead of http URLs where possible.
51952         * doc/ld-output-def.texi: Remove unavailable URL.
51954 2017-09-12  Paul Eggert  <eggert@cs.ucla.edu>
51956         maintainer-makefile: FTP -> HTTPS
51957         * top/maint.mk (url_dir_list, ftp-gnu): Use HTTPS protocol instead
51958         of FTP, which is planned to be decommissioned on 2017-11-01.
51960 2017-09-12  Tim Rühsen  <tim.ruehsen@gmx.de>  (tiny change)
51962         libc-config: Fix __GNUC_PREREQ macro.
51963         * lib/libc-config.h (__GNUC_PREREQ): Use __GNUC_MINOR__, not
51964         __GNUC_MINOR.
51966 2017-09-09  Bruno Haible  <bruno@clisp.org>
51968         gnulib-tool: Simplify commit from 2015-08-20.
51969         * gnulib-tool (func_add_or_update): Remove local variable
51970         is_binary_file.
51972 2017-09-08  Bruno Haible  <bruno@clisp.org>
51974         stddef: Avoid conflict with system-defined max_align_t.
51975         The configure-determined HAVE_MAX_ALIGN_T may not always be accurate.
51976         Reported by Werner Lemberg <wl@gnu.org> in
51977         <https://lists.gnu.org/r/bug-gnulib/2017-08/msg00185.html>.
51978         * lib/stddef.in.h (rpl_max_align_t): Renamed from max_align_t.
51979         (max_align_t): Define as a macro.
51980         (GNULIB_defined_max_align_t): New macro. Guards against multiple
51981         definitions of rpl_max_align_t in different copies of gnulib-generated
51982         <stddef.h>.
51984 2017-09-05  Paul Eggert  <eggert@cs.ucla.edu>
51986         libc-config: port to MSVC
51987         Problems reported by Gisle Vanem in:
51988         http://lists.gnu.org/r/bug-gnulib/2017-09/msg00016.html
51989         * lib/libc-config.h (__inline): Don't define if HAVE___INLINE.
51990         (libc_hidden_proto): Stick to Standard C syntax for varargs macro.
51991         * m4/__inline.m4: New file.
51992         * modules/libc-config (Files): Add it.
51993         (Depends-on): Use it.
51995         glob: Use enum for __glob_pattern_type result
51996         From a patch proposed by Adhemerval Zanella in:
51997         https://sourceware.org/ml/libc-alpha/2017-09/msg00212.html
51998         * lib/glob_internal.h (GLOBPAT_NONE, GLOBPAT_SPECIAL)
51999         (GLOBPAT_BACKSLASH, GLOBPAT_BRACKET): New constants.
52000         * lib/glob_internal.h (__glob_pattern_type):
52001         * lib/glob.c (glob):
52002         * lib/glob_pattern_p.c (__glob_pattern_p):
52003         Use them.
52005         glob: fix for use in glibc
52006         Problem reported by Adhemerval Zanella in:
52007         https://sourceware.org/ml/libc-alpha/2017-09/msg00213.html
52008         * lib/glob.c (DT_UNKNOWN, DT_DIR, DT_LINK):
52009         Do not redefine if _LIBC.
52011 2017-09-02  Paul Eggert  <eggert@cs.ucla.edu>
52013         glob: fix bugs with long login names
52014         Problem reported by Adhemerval Zanella in:
52015         https://sourceware.org/ml/libc-alpha/2017-08/msg00455.html
52016         * lib/glob.c (GET_LOGIN_NAME_MAX): Remove.
52017         (glob): Use the same scratch buffer for both getlogin_r and
52018         getpwnam_r.  Don’t require preallocation of the login name.  This
52019         simplifies storage allocation, and corrects the handling of
52020         long login names.
52022 2017-09-02  Bruno Haible  <bruno@clisp.org>
52024         dirent: Update doc.
52025         * doc/posix-headers/dirent.texi: More concrete list of platforms.
52027 2017-09-02  Paul Eggert  <eggert@cs.ucla.edu>
52029         glob: fix getpwnam_r errno typo
52030         * lib/glob.c (glob): Fix longstanding misuse of errno after
52031         getpwnam_r, which returns an error number rather than setting
52032         errno.
52034         glob: fix typo in recent change
52035         * lib/glob.c (glob) [!HAVE_GETPWNAM_R && !_LIBC]:
52036         Fix recently-introduced typo.
52038 2017-09-02  Paul Eggert  <eggert@cs.ucla.edu>
52040         glob: don't save and restore errno unnecessarily
52041         * lib/glob.c (glob): Don't save and restore errno
52042         merely because we have getpwnam_r.
52044         glob: don't assume getpwnam_r
52045         * lib/glob.c (glob): Port recent patches to platforms
52046         lacking getpwnam_r.
52048         scratch_buffer: don’t use private glibc API
52049         Suggested by Florian Weimer in:
52050         http://lists.gnu.org/r/bug-gnulib/2017-09/msg00004.html
52051         * lib/scratch_buffer.h: Rename to lib/malloc/scratch_buffer.h.
52052         * lib/scratch_buffer_grow.c: Rename to
52053         lib/malloc/scratch_buffer_grow.c.
52054         * lib/scratch_buffer_grow_preserve.c: Rename to
52055         lib/malloc/scratch_buffer_grow_preserve.c.
52056         * lib/scratch_buffer_set_array_size.c: Rename to
52057         lib/malloc/scratch_buffer_set_array_size.c.
52058         * lib/scratch_buffer.h: New file.
52059         * modules/scratch_buffer (Files, Makefile.am):
52060         Adjust to source-file renaming.
52062 2017-09-01  Paul Eggert  <eggert@cs.ucla.edu>
52064         glob: use scratch_buffer instead of extend_alloca
52065         Much of the lib/glob.c part of this patch comes from a glibc patch
52066         proposed by Adhemerval Zanella in:
52067         https://sourceware.org/ml/libc-alpha/2017-08/msg00456.html
52068         * lib/glob.c: Do not include <config.h>, since <libc-config.h>,
52069         included via glob.h, does this for us now.
52070         (__set_errno): Remove, as libc-config does this for us now.
52071         Include <scratch_buffer.h>.
52072         (GETPW_R_SIZE_MAX): Remove.
52073         (glob): Use struct scratch_buffer instead of extend_alloca.
52074         * lib/glob.in.h: Include libc-config.h rather than
52075         including <sys/cdefs.h> conditionally.
52076         (__BEGIN_DECLS, __END_DECLS, __THROW, __THROWNL, attribute_hidden)
52077         (__glibc_unlikely, __restrict, weak_alias):
52078         Remove, as libc-config does this for us now.
52079         * m4/glob.m4 (gl_PREREQ_GLOB):
52080         Remove sys/cdefs.h tests; no longer needed.
52081         * modules/glob (Depends-on): Add libc-config, scratch_buffer.
52082         (glob.h): Do not replace HAVE_SYS_CDEFS_H.
52084         scratch_buffer: new module
52085         * lib/scratch_buffer.h, lib/scratch_buffer_grow.c:
52086         * lib/scratch_buffer_grow_preserve.c:
52087         * lib/scratch_buffer_set_array_size.c:
52088         New files, copied from glibc with very minor changes that can be
52089         copied back.
52090         * modules/scratch_buffer: New file.
52092         libc-config: new module
52093         * MODULES.html.sh: Add libc-config.
52094         * lib/cdefs.h: New file, copied from the GNU C Library with very
52095         minor changes that can be copied back.
52096         * lib/libc-config.h, modules/libc-config: New files.
52098 2017-08-31  Paul Eggert  <eggert@cs.ucla.edu>
52100         glob: match dangling symlinks
52101         This fixes a bug I inadvertently introduced to Gnulib when I
52102         merged glibc glob back into gnulib on 2007-10-16.  This fix is
52103         inspired by a patch proposed for glibc by Adhemerval Zanella in:
52104         https://sourceware.org/ml/libc-alpha/2017-08/msg00446.html
52105         * doc/posix-functions/glob.texi: Update list of affected platforms.
52106         * lib/glob.c (__lstat64): New macro.
52107         (is_dir): New function.
52108         (glob, glob_in_dir): Match symlinks even if they are dangling.
52109         (link_stat, link_exists_p): Remove.  All uses removed.
52110         * lib/glob.in.h (__attribute_noinline__): Remove; no longer used.
52111         * m4/glob.m4 (gl_PREREQ_GLOB): Do not check for fstatat.
52112         * modules/glob-tests (Depends-on): Add symlink.
52113         * tests/test-glob.c: Include errno.h, unistd.h.
52114         (BASE): New macro.
52115         (main): Test dangling symlinks, if symlinks are supported.
52117         glob, backupfile: inode 0 is a valid inode number
52118         * doc/posix-functions/readdir.texi (readdir):
52119         * doc/posix-headers/dirent.texi (dirent.h):
52120         Document more readdir portability issues.
52121         * lib/backupfile.c (REAL_DIR_ENTRY): Remove.
52122         (numbered_backup): Don’t treat inode 0 any differently from
52123         other inode values.
52124         * lib/glob.c (struct readdir_result): Remove skip_entry member.
52125         (readdir_result_skip_entry, D_INO_TO_RESULT): Remove.
52126         All uses removed.
52127         * modules/glob (Depends-on): Remove d-ino.
52129         glob: simplify symlink detection
52130         * lib/glob.c (dirent_type): New type.  Use uint_fast8_t not
52131         uint8_t, as C99 does not require uint8_t.
52132         (struct readdir_result): Use it.  Do not define skip_entry unless
52133         it is needed; this saves a byte on platforms lacking d_ino.
52134         (readdir_result_type, readdir_result_skip_entry):
52135         New functions, replacing ...
52136         (readdir_result_might_be_symlink, readdir_result_might_be_dir):
52137         ... these functions, which were removed.  This makes the callers
52138         easier to read.  All callers changed.
52139         (D_INO_TO_RESULT): Now empty if there is no d_ino.
52141 2017-08-30  Pádraig Brady  <P@draigBrady.com>
52143         fts-tests: tag as a longrunning-test so not included by default
52144         * modules/fts-tests: This test takes about 20s on current systems,
52145         and uses about 285M of space on ext4.
52147 2017-08-30  Pádraig Brady  <P@draigBrady.com>
52149         renameat2: fix compilation on alpine linux
52150         * m4/renameat.m4: Check for <linux/fs.h> presence.
52151         * lib/renameat2.h: Only include <linux/fs.h> if present.
52152         Reported by Assaf Gordon on Alpine Linux.
52154 2017-08-24  Paul Eggert  <eggert@cs.ucla.edu>
52156         glob: try to port recent changes to MS-Windows
52157         Problem reported by Bruno Haible in:
52158         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00170.html
52159         * lib/glob.c (__glob_pattern_p) [!_LIBC]: Move from here ...
52160         * lib/glob.in.h (__glob_pattern_p): ... to here.
52162 2017-08-24  Eric Blake  <eblake@redhat.com>
52164         warnings: fix compilation with old autoconf
52165         * m4/warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C))
52166         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C++)): Use m4_defun rather than
52167         AC_DEFUN.
52168         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C))
52169         (gl_MANYWARN_ALL_GCC(C++)): Likewise.
52171 2017-08-24  Bruno Haible  <bruno@clisp.org>
52173         glob: Fix compilation error on NetBSD 7.0 and OpenBSD 6.0.
52174         * modules/glob (Depends-on): Add c99.
52176 2017-08-24  Paul Eggert  <eggert@cs.ucla.edu>
52178         glob: fix typo that broke platforms lacking d_ino
52179         This typo also hurt performance on GNU/Linux and similar hosts.
52180         * lib/glob.c (D_INO_TO_RESULT): Fix typo (reversed ifdef)
52181         in previous change.
52183 2017-08-23  Paul Eggert  <eggert@cs.ucla.edu>
52185         glob: merge from glibc with Zanella glob changes
52186         Merge glob from glibc, with changes for glob proposed
52187         by Adhemerval Zanella in the thread starting here:
52188         https://sourceware.org/ml/libc-alpha/2017-08/msg01079.html
52189         plus some fixes for this merge.
52190         * lib/glob_internal.h, lib/glob_pattern_p.c, lib/globfree.c:
52191         New files, ported from glibc.
52192         * lib/glob-libc.h (_Restrict_): Remove.  All uses replaced
52193         with __restrict.
52194         (__size_t): Remove.  All uses replaced by size_t.
52195         (size_t): Define by defining __need_size_t and including <stddef.h>.
52196         This should work even in non-glibc platforms, where any name
52197         pollution is OK.
52198         Use __USE_MISC instead of __USE_BSD || __USE_GNU.
52199         (struct stat64): Don’t worry about __GLOB_GNULIB.
52200         (glob, globfree, glob_pattern_p): Remove macros for
52201         __USE_FILE_OFFSET64 && __GNUC__ < 2 && !defined __GLOB_GNULIB
52202         case.  Remove _GL_ARG_NONNULL as GNU behavior is to accept NULL
52203         but set errno.
52204         * lib/glob.c (_GL_ARG_NONNULL) [!_LIBC]: Remove.  All uses
52205         removed since the glibc behavior works on null pointers.
52206         Do not include stdio.h; old SunOS is irrelevant now.
52207         Do not worry about GLOB_ONLY_P as we now mimic glibc here.
52208         Include glob_internal.h.
52209         (D_INO_TO_RESULT): Depend on (_LIBC || D_INO_IN_DIRENT), not
52210         ((POSIX || WINDOWS32) && !__GNU_LIBRARY__).  The latter probably
52211         worked only coincidentally.
52212         (attribute_hidden, __attribute_noinline__, __glibc_unlikely):
52213         Remove macros; now done in glob.in.h.
52214         (size_add_wrapv): Do not use __builtin_add_overflow if __ICC.
52215         (glob): Properly initialize glob structure with
52216         GLOB_BRACE|GLOB_DOOFFS (bug 20707).
52217         Remove old code using SHELL since Bash no longer
52218         uses this.
52219         (glob, prefix_array): Separate MS code better.
52220         (glob, glob_in_dir): Use C99 decls before statements when glibc
52221         does.
52222         (glob_in_dir): Remove old Amiga and VMS code.
52223         (globfree, __glob_pattern_type, __glob_pattern_p): Move to
52224         separate files.
52225         * lib/glob.in.h (attribute_hidden, __attribute_noinline__)
52226         (__glibc_unlikely):
52227         Move here from glob.c.
52228         (__restrict): New macro here, replacing the _Restrict_ in glob.c.
52229         (weak_alias): New macro.
52230         (__size_t): Remove.  All uses replaced by size_t.
52231         * modules/d-ino (License): Now LGPLv2+, for compatibility with glob.
52232         * modules/glob (Files): Add +lib/glob_internal.h,
52233         lib/glob_pattern_p.c, lib/globfree.c.
52234         (Depends-on): Remove snippet/arg-nonnull.
52236 2017-08-22  Paul Eggert  <eggert@cs.ucla.edu>
52238         glob: port to clang's Undefined Sanitizer
52239         Problem reported by Tim Rühsen in:
52240         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00144.html
52241         * lib/glob.c (FLEXIBLE_ARRAY_MEMBER) [_LIBC]: Define to empty.
52242         (glob_in_dir): Do not rely on undefined behavior in accessing
52243         struct members beyond their bounds.  Use a flexible array member
52244         instead.
52246 2017-08-21  Paul Eggert  <eggert@cs.ucla.edu>
52248         vc-list-files: port to Solaris 10
52249         * build-aux/vc-list-files: Don't assume test -e works.
52251 2017-08-21  Karl Berry  <karl@freefriends.org>
52253         * doc/posix-functions/srandom.texi (srandom): typo }.
52255 2017-08-20  Paul Eggert  <eggert@cs.ucla.edu>
52257         git-version-gen: port to Solaris 10
52258         Problem reported by Dagobert Michelsen in:
52259         http://lists.gnu.org/r/grep-devel/2017-08/msg00002.html
52260         * build-aux/git-version-gen (v_from_git):
52261         Use expr instead of shell substitution.
52263 2017-08-19  Bruno Haible  <bruno@clisp.org>
52265         host-cpu-c-abi: Improve detection of MIPS ABI.
52266         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): For MIPS, test the value of
52267         _MIPS_SIM.
52269 2017-08-17  Bruno Haible  <bruno@clisp.org>
52271         hypot tests: Fix test failure on FreeBSD 11.0/x86.
52272         * tests/test-hypot.h (test_function): Declare z as 'volatile'.
52274 2017-08-17  Bruno Haible  <bruno@clisp.org>
52276         float: Fix LDBL_MIN value on FreeBSD/x86.
52277         * lib/float.in.h (LDBL_MIN) [__FreeBSD__]: Add more precision.
52279 2017-08-17  Bruno Haible  <bruno@clisp.org>
52281         random: Fix test compilation failure on Cygwin 1.5.25.
52282         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_INITSTATE,
52283         HAVE_DECL_SETSTATE.
52284         * m4/random.m4 (gl_FUNC_RANDOM): Test whether initstate and setstate are
52285         declared.
52286         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_INITSTATE,
52287         HAVE_DECL_SETSTATE.
52288         * lib/stdlib.in.h (initstate): Declare also if HAVE_DECL_INITSTATE is 0.
52289         (setstate): Declare also if HAVE_DECL_SETSTATE is 0.
52290         * doc/posix-functions/initstate.texi: Mention the Cygwin 1.5.x problem.
52291         * doc/posix-functions/random.texi: Likewise.
52292         * doc/posix-functions/setstate.texi: Likewise.
52293         * doc/posix-functions/srandom.texi: Likewise.
52295 2017-08-16  Bruno Haible  <bruno@clisp.org>
52297         stdnoreturn: Fix test compilation failure on Cygwin.
52298         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): On Cygwin, use gnulib's
52299         <stdnoreturn.h> replacement.
52300         * lib/stdnoreturn.in.h (noreturn): Treat Cygwin like MSVC.
52301         * doc/posix-headers/stdnoreturn.texi: Mention the Cygwin problem.
52303 2017-08-16  Bruno Haible  <bruno@clisp.org>
52305         thread: Fix conflict with pthread_sigmask module.
52306         * lib/glthread/thread.h (pthread_sigmask): Don't declare it weak if
52307         it's defined as a macro.
52308         * modules/thread (Depends-on): Add pthread_sigmask.
52310 2017-08-16  Paul Eggert  <eggert@cs.ucla.edu>
52312         rename: port better to NetBSD
52313         * doc/posix-functions/rename.texi (rename): NetBSD 7
52314         does not have the link-count bug.
52315         * m4/rename.m4 (gl_FUNC_RENAME): Don’t consider NetBSD to be
52316         broken merely because rename ("a", "b") removes "a" when the two
52317         names are hard links to the same file.
52319 2017-08-16  Bruno Haible  <bruno@clisp.org>
52321         iconv_open, uni*: Add support for VPATH builds with OpenBSD 'make'.
52322         * modules/iconv_open (Makefile.am): In the rules that use gperf, prefix
52323         the target file names with '$(srcdir)/'.
52324         * modules/unicase/locale-language (Makefile.am): Likewise.
52325         * modules/unicase/special-casing (Makefile.am): Likewise.
52326         * modules/unictype/bidiclass-byname (Makefile.am): Likewise.
52327         * modules/unictype/category-byname (Makefile.am): Likewise.
52328         * modules/unictype/combining-class-byname (Makefile.am): Likewise.
52329         * modules/unictype/joininggroup-byname (Makefile.am): Likewise.
52330         * modules/unictype/joiningtype-byname (Makefile.am): Likewise.
52331         * modules/unictype/property-byname (Makefile.am): Likewise.
52332         * modules/unictype/scripts (Makefile.am): Likewise.
52333         * modules/uninorm/composition (Makefile.am): Likewise.
52335 2017-08-16  Bruno Haible  <bruno@clisp.org>
52337         nonblocking-socket tests: Fix failure on OpenBSD 6.0.
52338         * tests/test-nonblocking-socket.h (SOCKET_DATA_BLOCK_SIZE): Increase
52339         value for OpenBSD.
52341 2017-08-16  Bruno Haible  <bruno@clisp.org>
52343         rename, renameat: Update doc regarding NetBSD.
52344         * doc/posix-functions/rename.texi: Clarify that when using
52345         -D_XOPEN_SOURCE=500 on NetBSD 7.0, the hard link bug is gone.
52346         * doc/posix-functions/renameat.texi: Be more precise about NetBSD
52347         version.
52349 2017-08-15  Paul Eggert  <eggert@cs.ucla.edu>
52351         renameat2: port better to macOS
52352         * lib/renameat2.c (renameat2): Use renameatx_np if available.
52354         futimens: don’t assume struct timespec layout
52355         * m4/futimens.m4 (gl_FUNC_FUTIMENS):
52356         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT):
52357         * tests/test-fdutimensat.c (main):
52358         * tests/test-futimens.h (test_futimens):
52359         * tests/test-lutimens.h (test_lutimens):
52360         * tests/test-utimens.h (test_utimens):
52361         * tests/test-utimensat.c (main):
52362         Don’t assume that struct timespec is a two-member structure in
52363         tv_sec, tv_nsec order.  Although this is true on all platforms we
52364         know about, POSIX does not guarantee it.
52366         rename: document+test NetBSD rename
52367         Test failure reported by Bruno Haible in:
52368         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00104.html
52369         This is an area where NetBSD is better-behaved than POSIX,
52370         so allow the NetBSD behavior in tests.
52371         * doc/posix-functions/rename.texi:
52372         * doc/posix-functions/renameat.texi: Document NetBSD behavior.
52373         * tests/test-rename.h (test_rename): Allow NetBSD behavior.
52375 2017-08-15  Bruno Haible  <bruno@clisp.org>
52377         renameat: Ensure declaration in <stdio.h> on NetBSD.
52378         * lib/stdio.in.h: Include <unistd,h> also on NetBSD.
52379         * doc/posix-functions/renameat.texi: Mention this problem.
52381 2017-08-15  Bruno Haible  <bruno@clisp.org>
52383         duplocale: Work around NetBSD 7.0 bug.
52384         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Test against the NetBSD 7.0 bug.
52385         * lib/duplocale.c: Add comment about NetBSD problem.
52386         * doc/posix-functions/duplocale.texi: Mention the NetBSD problem.
52388 2017-08-15  Bruno Haible  <bruno@clisp.org>
52390         duplocale tests: Verify use with *_l functions.
52391         * modules/duplocale-tests (configure.ac): Test for uselocale and
52392         some *_l functions.
52393         * tests/test-duplocale.c (test_with_uselocale): New function, extracted
52394         from main.
52395         (get_locale_dependent_values_from, test_with_locale_parameter): New
52396         functions.
52397         (main): Test both test_with_uselocale and test_with_locale_parameter.
52399 2017-08-15  Bruno Haible  <bruno@clisp.org>
52401         extensions: Enable NetBSD specific extensions.
52402         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define _NETBSD_SOURCE.
52404 2017-08-14  Bruno Haible  <bruno@clisp.org>
52406         open, openat: Update doc about O_CLOEXEC.
52407         * doc/posix-functions/open.texi: More concrete list of platforms.
52408         * doc/posix-functions/openat.texi: Likewise.
52410 2017-08-14  Paul Eggert  <eggert@cs.ucla.edu>
52412         open: support O_CLOEXEC
52413         * NEWS, doc/posix-functions/open.texi:
52414         * doc/posix-functions/openat.texi: Document this.
52415         * lib/fcntl.in.h (O_CLOEXEC): Default to a nonzero value.
52416         (GNULIB_defined_O_CLOEXEC): New symbol.
52417         * lib/open.c: Include cloexec.h.
52418         (open): Support O_CLOEXEC.
52419         * lib/openat.c: Include cloexec.h.
52420         (rpl_openat): Support O_CLOEXEC.
52421         * lib/popen-safer.c: Do not include cloexec.h.
52422         (open_noinherit): Remove.
52423         (popen_safer): Use O_CLOEXEC instead of set_cloexec_flag.
52424         * lib/save-cwd.c: Do not include cloexec.h.
52425         (save_cwd): Use O_CLOEXEC instead of set_cloexec_flag.
52426         * m4/open-cloexec.m4: New file.
52427         * m4/open.m4 (gl_FUNC_OPEN): Require gl_PREPROC_O_CLOEXEC.
52428         Replace 'open' if O_CLOEXEC is not present.
52429         * m4/openat.m4 (gl_FUNC_OPENAT): Require gl_PREPROC_O_CLOEXEC.
52430         Replace 'openat' if O_CLOEXEC is not present.
52431         * modules/freopen (Depends-on): Depend on 'open' if replacing freopen.
52432         * modules/open (Files): Add m4/open-cloexec.m4.
52433         (Depends-on): Depend on cloexec if replacing 'open'.
52434         * modules/openat (Files): Add m4/open-cloexec.m4.
52435         (Depends-on): Depend on cloexec if replacing openat.
52436         * modules/popen-safer (Depends-on): Remove cloexec.
52437         * modules/save-cwd (Depends-on): Remove cloexec, and add
52438         fd-safer-flag and 'open'.
52440 2017-08-13  Paul Eggert  <eggert@cs.ucla.edu>
52442         reallocarray: minor fixes
52443         * doc/glibc-functions/reallocarray.texi: Update version numbers.
52444         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY): Don't trust _cv_ contents.
52445         * modules/reallocarray (License): Change from GPL to LGPL.
52446         * tests/test-reallocarray.c (main): Fix ENOMEM typo.
52447         Indent properly and don't use tabs.
52449 2017-08-13  Darshit Shah  <darnir@gnu.org>
52451         reallocarray: New module
52452         reallocarray is a new function in glibc 2.26 to safely allocate an array
52453         of memory locations with integer overflow protection.
52454         * MODULES.html.sh: Add reallocarray.
52455         * doc/glibc-functions/reallocarray.texi: Documentation for reallocarray.
52456         * lib/reallocarray.c: New file to implement module reallocarray.
52457         * lib/stdlib.in.h: Add function declarations for reallocarray.
52458         * m4/reallocarray.m4: New file.
52459         * m4/stdlib_h.m4: Declare reallocarray.
52460         * modules/reallocarray: New file.
52461         * modules/reallocarray-test: New file.
52462         * modules/stdlib: Coerce stdlib.h to export reallocarray.
52463         * tests/test-reallocarray.c: New test.
52465 2017-08-12  Paul Eggert  <eggert@cs.ucla.edu>
52467         dirent-safer: fix cloexec race
52468         * lib/opendir-safer.c: Include fcntl.h instead of unistd-safer.h.
52469         (opendir_safer): Use F_DUPFD_CLOEXEC.
52470         * modules/dirent-safer (Depends-on): Add fcntl.  Remove unistd-safer.
52471         * tests/test-dirent-safer.c: Do not include unistd-safer.h,
52472         as it is no longer a prerequisite.  Use F_DUPFD_CLOEXEC
52473         instead of dup_safer.
52475         fts: fix cloexec races
52476         * lib/fts.c [!_LIBC]: Do not include dirent--.h, unistd--.h, cloexec.h.
52477         (opendirat, diropen): Use O_CLOEXEC instead of set_cloexec_flag.
52478         (fts_build): Use F_DUPD_CLOEXEC rinstad of set_cloexec_flag.
52479         (fd_ring_check): Set cloexec flag on new file descriptors.
52480         (fts_build, fd_ring_check): While we’re at it, make sure the
52481         resulting file descriptor is not 0, 1, or 2, since that is easy.
52483 2017-08-11  Bruno Haible  <bruno@clisp.org>
52485         fts tests: Fix link error.
52486         Reported by Tom G. Christensen in
52487         https://lists.gnu.org/r/bug-gnulib/2017-08/msg00078.html
52488         * modules/fts-tests (Makefile.am): Link test-fts against LIBINTL.
52490 2017-08-10  Paul Eggert  <eggert@cs.ucla.edu>
52492         fts: port recent changes to CentOS 6
52493         Problem reported by Tom G. Christensen in:
52494         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00064.html
52495         * lib/fts.c (fsword): New type.
52496         (struct dev_type, filesystem_type): Use it.
52497         * m4/fts.m4 (gl_FUNC_FTS_CORE): Check for __fsword_t.
52498         Also, check for f_type only if fstatfs and sys/vfs.h work.
52500 2017-08-09  Paul Eggert  <eggert@cs.ucla.edu>
52502         tempname: do not depend on secure_getenv
52503         Excess dependency noted by Eli Zaretskii (Bug#28023#17).
52504         * lib/tempname.c (__secure_getenv) [!_LIBC]: Remove; unused.
52505         * modules/tempname (Depends-on): Remove secure_getenv.
52507 2017-08-08  Paul Eggert  <eggert@cs.ucla.edu>
52509         extensions: add _OPENBSD_SOURCE
52510         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define _OPENBSD_SOURCE.
52512 2017-08-06  Reuben Thomas  <rrt@sc3d.org>
52513             Bruno Haible  <bruno@clisp.org>
52515         manywarnings: Add support for C++.
52516         * build-aux/g++-warning.spec: New file.
52517         * m4/manywarnings-c++.m4: New file.
52518         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C++)): New macro, that
52519         redirects to manywarnings-c++.m4.
52520         * modules/manywarnings (Files): Add m4/manywarnings-c++.m4.
52522 2017-08-06  Paul Eggert  <eggert@cs.ucla.edu>
52524         git-version-gen: another fix for tags with "-"
52525         * build-aux/git-version-gen: Improve fix for tags containing "-".
52526         Suggested by Markus Armbruster in:
52527         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00034.html
52529 2017-08-06  Bruno Haible  <bruno@clisp.org>
52531         warnings, manywarnings: Add support for multiple languages, not just C.
52532         * warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS_IMPL): Renamed from
52533         gl_UNKNOWN_WARNINGS_ARE_ERRORS.
52534         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C)): New macro.
52535         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C++)): New macro.
52536         (gl_UNKNOWN_WARNINGS_ARE_ERRORS): Dispatch to
52537         gl_UNKNOWN_WARNINGS_ARE_ERRORS(_AC_LANG).
52538         (gl_WARN_ADD): Require the gl_UNKNOWN_WARNINGS_ARE_ERRORS specialization
52539         of the current language. If C++ is the current language, modify
52540         WARN_CXXFLAGS instead of WARN_CFLAGS.
52541         * manywarnings.m4 (gl_MANYWARN_ALL_GCC(C)): New macro, extracted from
52542         gl_MANYWARN_ALL_GCC.
52543         (gl_MANYWARN_ALL_GCC): Dispatch to gl_MANYWARN_ALL_GCC(_AC_LANG).
52545 2017-08-06  Markus Armbruster  <armbru@pond.sub.org>
52547         git-version-gen: Fix for tags containing '-'
52549         Really old versions of git-describe (before v1.5.0, Feb 2007)
52550         don't have the number of commits in their long format output,
52551         i.e. where modern 'git describe --abbrev=4 --match="v*"' prints
52552         "v0.1-1494-g124b9", they print "v0.1-1494-g124b9".  git-version-gen
52553         recognizes both patterns, and normalizes the old format to the new one.
52555         Unfortunately, this normalization code gets confused when the tag
52556         contains '-'.  Reproducer:
52558             $ git-tag -m test v0.2-rc1
52559             $ build-aux/git-version-gen .tarball-version; echo
52560             build-aux/git-version-gen: WARNING: git rev-list failed
52561             UNKNOWN
52563         We take exact tag "v0.2-rc1" for the old format, extract the presumed
52564         tag "v0.2" from it, then run "git rev-list v0.2..HEAD" to count
52565         commits since tha tag.  Fails, because tag "v0.2" does not exist.
52567         * git-version-gen: We could perhaps drop support for versions from
52568         more than a decade ago.  But tightening the pattern match is easy
52569         enough, so do that.  Still breaks when you use version tags ending in
52570         something matching -g????, but you arguably get what you deserve then.
52572 2017-08-05  Paul Eggert  <eggert@cs.ucla.edu>
52574         valgrind-tests: use ls, and cache
52575         * m4/valgrind-tests.m4: Test ls, not bash.
52576         Problem reported by Reuben Thomas.
52577         Also, cache the result so that it can be overridden.
52579 2017-08-04  Paul Eggert  <eggert@cs.ucla.edu>
52581         manywarnings: port to 64-bit GCC builds of Emacs
52582         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Compute max safe
52583         object size rather than hardwiring 2147483647.  This is needed to
52584         build GNU Emacs, which has one conditional (and used
52585         only-in-theory) call to malloc with a literal greater than
52586         2147483647.
52588 2017-08-04  Bruno Haible  <bruno@clisp.org>
52590         Relax the license of some modules with no runtime code.
52591         * modules/std-gnu11 (License): Set to 'unlimited'.
52592         * modules/c99 (License): Likewise.
52593         Reported by Reuben Thomas <rrt@sc3d.org>.
52594         * modules/d-ino (License): Set to 'LGPL'.
52595         * modules/host-os (License): Likewise.
52596         * modules/longlong (License): Likewise.
52598 2017-08-03  Paul Eggert  <eggert@cs.ucla.edu>
52600         renameat2: port to RHEL 7 + NFS
52601         * lib/renameat2.c (renameat2) [SYS_renameat2]:
52602         Port to RHEL 7 + NFS.  Problem reported by Ted Zlatanov in:
52603         http://lists.gnu.org/r/emacs-devel/2017-08/msg00082.html
52605 2017-08-02  Paul Eggert  <eggert@cs.ucla.edu>
52607         renameat2: port to non-renameat platforms
52608         Problem reported for MSVC-2015 by Gisle Vanem in:
52609         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00001.html
52610         * lib/renameat2.c [!HAVE_RENAMEAT]: Include <sys/stat.h> here too.
52611         (renameat2) [!HAVE_RENAMEAT]: Fix typo in arg passing.
52613 2017-08-01  Paul Eggert  <eggert@cs.ucla.edu>
52615         manywarnings: port to 32-bit GCC bug
52616         Problem reported by Pino Toscano in:
52617         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00150.html
52618         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Use 2**31 - 1,
52619         not 2**63 - 1, to work around the following GCC bug:
52620         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81650
52622 2017-07-30  Paul Eggert  <eggert@cs.ucla.edu>
52624         backupfile: new function to validate backup suffix
52625         * lib/backupfile.c (set_simple_backup_suffix): New function.
52626         (backupfile_internal): Use it.
52628         canonicalize: fix EOVERFLOW commentary
52629         Problem reported by Bruno Haible in:
52630         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00147.html
52631         * lib/canonicalize.c (canonicalize_filename_mode):
52632         * lib/canonicalize-lgpl.c (__realpath): Fix comments.
52634         Don't interpret EOVERFLOW to mean nonexistence
52635         * lib/fts.c (fts_stat): If lstat fails, report its errno, which
52636         may be EOVERFLOW; this is likely more useful than reporting the
52637         stat errno.
52638         * lib/glob.c (link_stat): Rename from link_exists2_p and
52639         return -1/0 instead of 0/1.  Caller changed.
52640         * lib/glob.c (link_exists_p):
52641         * lib/renameat2.c (rename_noreplace, renameat2):
52642         * lib/tempname.c (try_nocreate):
52643         If errno == EOVERFLOW then the directory entry exists, so do not
52644         act as if it does not exist.
52646         backup-rename: new module
52647         It is like backupfile, except it avoids some race conditions,
52648         and it does not output to stderr or exit.
52649         * MODULES.html.sh: Add backup-rename.
52650         * lib/backup-find.c, lib/backup-internal.h, lib/backup-rename.c:
52651         * modules/backup-rename: New files.
52652         * lib/backupfile.c: Turn this into an internals file, which
52653         contains code common to backupfile and backup_rename.  Include
52654         backupfile-internal.h instead of backupfile.h.  Do not include
52655         argmatch.h or xalloc.h: include xalloc-oversized.h.  Include
52656         renameat2.h and fcntl.h.
52657         (BACKUP_NOMEM): New constant.
52658         (numbered_backup): New args BASE_OFFSET and *DIRPP.  Do not exit
52659         on memory exhaustion; just return BACKUP_NOMEM.  Caller changed.
52660         (backupfile_internal): Rename from find_backup_file_name.
52661         Support new arg RENAME.
52662         (backup_args, backup_types, get_version, xget_version):
52663         Move to lib/backup-find.c.
52664         * lib/backupfile.h (backup_file_rename): New decl.
52665         * modules/backupfile (Files): Add lib/backup-internal.h,
52666         lib/backup-find.c.
52667         (Depends-on): Add dirfd, fcntl, renameat2.
52668         (lib_SOURCES): Add backup-find.c.
52670         renameat2: port better to older Solaris
52671         * lib/renameat2.c (renameat2): Set ret_val properly on old Solaris.
52672         Add goto to use a label, to silence picky compilers.
52674         fts-tests: port to gcc -Wwrite-strings
52675         * tests/test-fts.c (base, base_d): New static vars.
52676         (argv, remove_tree, main): Use them.
52678 2017-07-26  Reuben Thomas  <rrt@sc3d.org>
52680         relocatable-lib{,-lgpl}: improve documentation
52681         * doc/relocatable-maint.texi: Document use of relocatable-lib{,-lgpl}.
52682         Various other updates.
52684 2017-07-30  Reuben Thomas  <rrt@sc3d.org>
52685             Bruno Haible  <bruno@clisp.org>
52687         relocatable-lib{,-lgpl}: add Valgrind suppressions
52688         * lib/relocatable.valgrind: New file.
52689         * modules/relocatable-lib (Files): Add relocatable.valgrind.
52690         * modules/relocatable-lib-lgpl: Likewise.
52692 2017-07-26  Reuben Thomas  <rrt@sc3d.org>
52694         relocatable: Make the license on the sources the GPL.
52695         * lib/relocatable.h, lib/relocatable.c: Change the copyright notice from
52696         LGPL, which was a special case so that the relocatable source files
52697         could be used without gnulib-tool, to GPL. They can still be used under
52698         the LGPL, using the --lgpl option to gnulib-tool.
52700 2017-07-30  Bruno Haible  <bruno@clisp.org>
52702         host-cpu-c-abi: Detect ILP32 ABI on IA-64 HP-UX.
52703         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Distinguish ia64-ilp32
52704         from ia64. For arm64, test only __aarch64__, as __ARM_64BIT_STATE and
52705         __ARM_PCS_AAPCS64 are not reliable indicators: they are not defined on
52706         Ubuntu 14.04 (gcc 4.8.4) and Debian 8 (gcc 4.9.2).
52708 2017-07-27  Paul Eggert  <eggert@cs.ucla.edu>
52710         faccessat: document AT_SYMLINK_NOFOLLOW issue
52711         * doc/posix-functions/faccessat.texi: Modernize platform list.
52712         Document AT_SYMLINK_NOFOLLOW limitation.
52714         renameat2: port to Solaris 10
52715         * lib/renameat2.c (rename_noreplace): Use lstat, not faccessat
52716         with AT_SYMLINK_NOFOLLOW (which is not portable).
52717         (renameat): Undef before using, to avoid endless recursion when
52718         the replacement renameat calls renameat2 which calls the
52719         replacement renameat.
52720         (renameat2): Use lstatat, not faccessat with AT_SYMLINK_NOFOLLOW.
52721         * modules/renameat2 (Depends-on): Remove faccessat.
52722         * modules/renameat-tests (test_renameat_LDADD):
52723         * modules/renameat2-tests (test_renameat2_LDADD):
52724         Remove $(LIB_EACCESS).
52726         renameat2: new module
52727         Although the Linux syscall renameat2 is not in glibc (yet?), it is
52728         useful to have access to its RENAME_NOREPLACE flag.
52729         * MODULES.html.sh (func_all_modules): Add renameat2.
52730         * lib/renameat2.c, lib/renameat2.h, modules/renameat2:
52731         * modules/renameat2-tests, tests/test-renameat2.c: New files.
52732         * lib/renameat.c (renameat): Move most of the implementation
52733         to renameat2, and just call renameat2.
52734         * modules/renameat (Files): Remove lib/at-func2.c.
52735         (Depends-on): Depend only on renameat2.
52736         (Include): Remove <fcntl.h>.
52737         * modules/renameat-tests (test_renameat_LDADD): Add $(LIB_EACCESS),
52738         since renameat (via renameat2) might use faccessat.
52740 2017-07-27  Erik Skultety <eskultet@redhat.com>  (tiny change)
52742         vc-list-files: Adjust the script to support git worktrees
52743         * build-aux/vc-list-files: Require existence, not directory.
52745 2017-07-26  Paul Eggert  <eggert@cs.ucla.edu>
52747         doc: bring MODULES.html.sh up to date
52748         Somehow a few months ago we stopped updating MODULES.html.sh.
52749         I don’t recall explicitly deciding this, so I updated it now.
52750         Alternatively I suppose we could remove it.
52751         * MODULES.html.sh: Add builtin-expect, c99, ctime, explicit_bzero,
52752         localtime, localtime-buffer, noreturn, nstrftime, strftime-fixes,
52753         truncate, utime, utime-h, windows-stat-inodes,
52754         windows-stat-override, windows-stat-timespec, year2038.  Sort.
52756 2017-07-26  Jim Meyering  <meyering@fb.com>
52758         fprintftime: fix build-break caused by recent renaming
52759         * lib/fprintftime.c: Include "nstrftime.c", not the now-renamed
52760         "strftime.c".
52761         * modules/fprintftime: Depend directly on nstrftime.
52763 2017-07-26  Paul Eggert  <eggert@cs.ucla.edu>
52765         regex: work with GCC7's -Werror=implicit-fallthrough=
52766         * lib/regex_internal.h (FALLTHROUGH): New macro.
52767         * lib/regcomp.c (peek_token_bracket, parse_expression):
52768         * lib/regexec.c (check_node_accept): Use it.
52770 2017-07-24  Paul Eggert  <eggert@cs.ucla.edu>
52772         fts: simplify fts_build
52773         * lib/fts.c (fts_build): Simplify, and be lazier about
52774         calling leaf_optimization.
52776         fts: three levels of leaf optimization
52777         * lib/fts.c (enum leaf_optimization): New type with three values.
52778         (S_MAGIC_AFS): New macro.  Sort them.
52779         (leaf_optimization): Rename from leaf_optimization_applies, and
52780         return enum leaf_optimization instead of bool.  All uses changed.
52781         Add cases for unknown type and for AFS.
52782         (fts_build): Don’t rely on link counts if NO_LEAF_OPTIMIZATION.
52784         fts: cache dirent_inode_sort_may_be_useful too
52785         * lib/fts.c (struct dev_type): New struct.
52786         (DEV_TYPE_HT_INITIAL_SIZE): New constant.
52787         (dev_type_hash, dev_type_compare, filesystem_type): New functions.
52788         (dirent_inode_sort_may_be_useful, leaf_optimization_applies):
52789         Now takes FTSENT const *, not int.  All uses changed.  Use
52790         filesystem_type to cache.
52791         (link_count_optimize_ok): Remove.  Caller changed to use
52792         leaf_optimization_applies, which now uses shared cache.
52794         fts: introduce MIN_DIR_NLINK
52795         * lib/fts.c (MIN_DIR_NLINK): New constant.
52796         Use it instead of 2, whenever we are talking about link counts.
52798         fts: nlink_t signedness fixups
52799         * lib/fts.c (fts_open): Set rootparent n_dirs_remaining to -1
52800         so that root need not be a special case later.
52801         (fts_read): Remove now-redundant test for fts_level.
52802         Do not assume that nlink_t is signed.
52803         (fts_build): Remove useless decrement of nlinks.
52804         (fts_stat): Avoid unlikely signed integer overflow later, if
52805         nlink_t is signed.
52807         fts-tests: new module
52808         * modules/fts-tests, tests/test-fts.c: New files.
52810 2017-07-23  Bruno Haible  <bruno@clisp.org>
52812         Rename module 'strftime' to 'nstrftime'.
52813         * m4/nstrftime.m4: Renamed from m4/strftime.m4.
52814         * lib/nstrftime.c: Renamed from lib/strftime.c.
52815         * modules/nstrftime: Renamed from modules/strftime.
52816         (Files, Makefile.am): Update.
52817         * tests/test-nstrftime.c: Renamed from tests/test-strftime.c.
52818         Fix comment.
52819         * modules/nstrftime-tests: Renamed from modules/strftime-tests.
52820         (Files, Makefile.am): Update.
52821         * modules/strftime: New file, an obsolete indirection.
52822         * doc/posix-functions/strftime.texi: Update reference.
52823         * config/srclist.txt: Update info.
52824         * NEWS: Mention the change.
52826 2017-07-21  Tim Rühsen  <tim.ruehsen@gmx.de>
52828         malloca: Silence a warning from clang's memory sanitizer.
52829         * lib/malloca.c (NO_SANITIZE_MEMORY): New macro.
52830         (freea): Use it.
52832 2017-07-18  Bruno Haible  <bruno@clisp.org>
52834         host-cpu-c-abi: Fix detection of MIPS ABI.
52835         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): For MIPS, really test the
52836         ABI, not the CPU instruction set.
52838 2017-07-16  Paul Eggert  <eggert@cs.ucla.edu>
52840         explicit_bzero: new module
52841         The explicit_bzero function has been added to glibc.
52842         This module is intended to supports its use in GNU programs.
52843         * doc/glibc-functions/explicit_bzero.texi, lib/explicit_bzero.c:
52844         * m4/explicit_bzero.m4, modules/explicit_bzero:
52845         New files.
52846         * doc/gnulib.texi (Glibc string.h): Link to new doc.
52847         * lib/string.in.h (explicit_bzero): Declare.
52848         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Add defaults for it.
52849         * modules/string (string.h): Substitute its vars.
52851 2017-07-16  Bruno Haible  <bruno@clisp.org>
52853         threadlib: Support static linking.
52854         * m4/threadlib.m4 (gl_THREADLIB_BODY): When static linking is in use,
52855         set gl_cv_have_weak to 'no'.
52857 2017-07-16  Bruno Haible  <bruno@clisp.org>
52859         unicase/locale-language: Fix link dependencies.
52860         * modules/unicase/locale-language (Link): New section.
52861         * modules/unicase/locale-language-tests (Makefile.am): Link
52862         test-locale-language program with $(LIBTHREAD).
52864 2017-07-15  John E. Malmberg  <wb8tyw@gmail.com>
52866         sys_socket: Add support for OpenVMS.
52867         * lib/sys_socket.in.h [__VMS]: Define CMSG_SPACE, CMSG_LEN.
52868         * doc/posix-headers/sys_socket.texi: Mention OpenVMS issues.
52870 2017-07-15  John E. Malmberg  <wb8tyw@gmail.com>
52872         sys_resource: Add support for OpenVMS.
52873         * lib/resource.in.h [__VMS]: Define RUSAGE_SELF, RUSAGE_CHILDREN.
52874         * doc/posix-headers/sys_resource.texi: Mention OpenVMS issues.
52876 2017-07-15  John E. Malmberg  <wb8tyw@gmail.com>
52877             Bruno Haible  <bruno@clisp.org>
52879         math: Add support for OpenVMS.
52880         * lib/math.in.h [__VMS]: Include <fp.h>.
52881         * doc/posix-headers/math.texi: Mention OpenVMS issues.
52883 2017-07-15  Bruno Haible  <bruno@clisp.org>
52885         getdtablesize: Add minimal support for OpenVMS.
52886         Reported by John E. Malmberg <wb8tyw@qsl.net>.
52887         * modules/getdtablesize (Description): Fix.
52888         * lib/getdtablesize.c: Fix comment.
52889         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Don't replace the
52890         getdtablesize() function, even though the test fails.
52891         * doc/glibc-functions/getdtablesize.texi: Reference SUSv2. Describe
52892         limitation on OpenVMS.
52894 2017-07-13  Bruno Haible  <bruno@clisp.org>
52896         Revisit cross-compilation guesses.
52897         * m4/wctype_h.m4 (gl_WCTYPE_H): Add comment.
52899 2017-07-13  Bruno Haible  <bruno@clisp.org>
52901         Improve cross-compilation guesses for native Windows.
52902         * m4/btowc.m4 (gl_FUNC_BTOWC): Add cross-compilation guess for native
52903         Windows.
52904         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Likewise.
52905         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Likewise.
52906         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Likewise.
52907         * m4/cbrtf.m4 (gl_FUNC_CBRTF_WORKS): Likewise.
52908         * m4/cbrtl.m4 (gl_FUNC_CBRTL, gl_FUNC_CBRTL_WORKS): Likewise.
52909         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
52910         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
52911         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
52912         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
52913         * m4/dup.m4 (gl_FUNC_DUP): Likewise.
52914         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
52915         * m4/exp2.m4 (gl_FUNC_EXP2_WORKS): Likewise.
52916         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
52917         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
52918         * m4/expm1f.m4 (gl_FUNC_EXPM1F_WORKS): Likewise.
52919         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Likewise.
52920         * m4/fabsl.m4 (gl_FUNC_FABSL_WORKS): Likewise.
52921         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
52922         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Likewise.
52923         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
52924         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
52925         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
52926         * m4/fma.m4 (gl_FUNC_FMA_WORKS): Likewise.
52927         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Likewise.
52928         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Likewise.
52929         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
52930         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
52931         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
52932         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Likewise.
52933         * m4/frexpf.m4 (gl_FUNC_FREXPF_WORKS): Likewise.
52934         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
52935         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Likewise.
52936         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
52937         * m4/hypotf.m4 (gl_FUNC_HYPOTF, gl_FUNC_HYPOTF_WORKS): Likewise.
52938         * m4/hypotl.m4 (gl_FUNC_HYPOTL, gl_FUNC_HYPOTL_WORKS): Likewise.
52939         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Likewise.
52940         * m4/ilogbf.m4 (gl_FUNC_ILOGBF_WORKS): Likewise.
52941         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
52942         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
52943         * m4/isnanf.m4 (gl_ISNANF_WORKS): Likewise.
52944         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
52945         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Likewise.
52946         * m4/log.m4 (gl_FUNC_LOG, gl_FUNC_LOG_WORKS): Likewise.
52947         * m4/logf.m4 (gl_FUNC_LOGF, gl_FUNC_LOGF_WORKS): Likewise.
52948         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
52949         * m4/log10.m4 (gl_FUNC_LOG10, gl_FUNC_LOG10_WORKS): Likewise.
52950         * m4/log10f.m4 (gl_FUNC_LOG10F, gl_FUNC_LOG10F_WORKS): Likewise.
52951         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Likewise.
52952         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
52953         * m4/log1pf.m4 (gl_FUNC_LOG1PF, gl_FUNC_LOG1PF_WORKS): Likewise.
52954         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Likewise.
52955         * m4/log2.m4 (gl_FUNC_LOG2, gl_FUNC_LOG2_WORKS): Likewise.
52956         * m4/log2f.m4 (gl_FUNC_LOG2F, gl_FUNC_LOG2F_WORKS): Likewise.
52957         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Likewise.
52958         * m4/logb.m4 (gl_FUNC_LOGB_WORKS): Likewise.
52959         * m4/logbf.m4 (gl_FUNC_LOGBF_WORKS): Likewise.
52960         * m4/logbl.m4 (gl_FUNC_LOGBL_WORKS): Likewise.
52961         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
52962         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT, gl_MBRTOWC_C_LOCALE): Likewise.
52963         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
52964         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
52965         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Likewise.
52966         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
52967         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
52968         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
52969         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
52970         * m4/perror.m4 (gl_FUNC_PERROR): Likewise.
52971         * m4/popen.m4 (gl_FUNC_POPEN): Likewise.
52972         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE,
52973         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2,
52974         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): Likewise.
52975         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Likewise.
52976         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
52977         * m4/regex.m4 (gl_REGEX): Likewise.
52978         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
52979         * m4/remainderf.m4 (gl_FUNC_REMAINDERF,
52980         gl_FUNC_REMAINDERF_WORKS): Likewise.
52981         * m4/remainderl.m4 (gl_FUNC_REMAINDERL,
52982         gl_FUNC_REMAINDERL_WORKS): Likewise.
52983         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
52984         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
52985         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
52986         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
52987         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
52988         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
52989         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
52990         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
52991         * m4/sqrtl.m4 (gl_FUNC_SQRTL_WORKS): Likewise.
52992         * m4/stdint.m4 (gl_STDINT_H): Likewise.
52993         * m4/strerror.m4 (gl_FUNC_STRERROR_0): Likewise.
52994         * m4/strncat.m4 (gl_FUNC_STRNCAT): Likewise.
52995         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
52996         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
52997         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
52998         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
52999         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
53000         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
53001         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
53002         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
53003         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
53004         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
53005         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
53006         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
53007         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
53008         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
53009         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
53010         Likewise.
53011         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
53012         * m4/chown.m4 (AC_FUNC_CHOWN): Add cross-compilation guess for native
53013         Windows. Enable also on Autoconf 2.70.
53014         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE,
53015         gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE,
53016         gl_PRINTF_DIRECTIVE_A, gl_PRINTF_DIRECTIVE_F, gl_PRINTF_DIRECTIVE_N,
53017         gl_PRINTF_DIRECTIVE_LS, gl_PRINTF_FLAG_LEFTADJUST, gl_PRINTF_FLAG_ZERO,
53018         gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
53019         gl_SNPRINTF_DIRECTIVE_N, gl_SNPRINTF_SIZE1): Add cross-compilation guess
53020         for native Windows.
53021         (gl_PRINTF_POSITIONS, gl_PRINTF_FLAG_GROUPING,
53022         gl_VSNPRINTF_ZEROSIZE_C99): Add comment.
53024 2017-07-13  Bruno Haible  <bruno@clisp.org>
53026         Improve cross-compilation guesses for native Windows.
53027         * m4/memchr.m4 (gl_FUNC_MEMCHR): Add cross-compilation guess for native
53028         Windows.
53029         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Don't use internals of
53030         memchr.m4.
53031         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Likewise.
53033 2017-07-13  Bruno Haible  <bruno@clisp.org>
53035         Improve cross-compilation guesses for native Windows.
53036         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Add cross-compilation guess for
53037         native Windows.
53038         (gl_FUNC_FFLUSH): Update accordingly.
53039         * m4/fclose.m4 (gl_FUNC_FCLOSE): Likewise.
53040         * m4/fseeko.m4 (gl_FUNC_FFLUSH_STDIN): Likewise.
53042 2017-07-11  Bruno Haible  <bruno@clisp.org>
53044         More systematic m4 quoting and indentation.
53045         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Quote systematically.
53046         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
53047         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
53048         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
53049         * m4/host-os.m4 (gl_HOST_OS): Likewise.
53050         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H,
53051         gl_WINSIZE_IN_PTEM): Likewise.
53052         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Likewise.
53053         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Likewise.
53054         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
53055         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Quote systematically.
53056         Correct indentation.
53057         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
53058         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
53059         * m4/jm-winsz2.m4 (gl_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL): Likewise.
53060         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
53061         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
53062         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
53064 2017-07-10  Bruno Haible  <bruno@clisp.org>
53066         round, roundf: Avoid compiler warning in configure test.
53067         * m4/round.m4 (gl_FUNC_ROUND): Use 'return' instead of exit().
53068         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
53070 2017-07-10  Bruno Haible  <bruno@clisp.org>
53072         getlogin tests: Avoid #ifdefs when sharing code between modules.
53073         * modules/getlogin_r-tests (Files): Add tests/test-getlogin.h.
53074         * modules/getlogin-tests (Files): Likewise. Remove
53075         tests/test-getlogin_r.c.
53076         * tests/test-getlogin.h: Extracted from tests/test-getlogin_r.c.
53077         * tests/test-getlogin.c: Extracted from tests/test-getlogin_r.c.
53078         * tests/test-getlogin_r.c: Include test-getlogin.h. Omit code that tests
53079         getlogin().
53081 2017-07-10  Paul Eggert  <eggert@cs.ucla.edu>
53083         getlogin: don’t assume one name per uid
53084         Problem reported by Wolfgang F. Muthmann (Bug#27640).
53085         * modules/getlogin-tests (Files): Add tests/test-getlogin_r.c.
53086         (ttyname): Remove test.
53087         * modules/getlogin_r-tests (ttyname): Remove test.
53088         * tests/test-getlogin.c: Replace this near-clone of test-getlogin_r.c
53089         with ‘#define TEST_LOGIN’ followed by ‘#include "test-getlogin_r.c"’.
53090         * tests/test-getlogin_r.c: If TEST_GETLOGIN is defined, test
53091         getlogin rather than getlogin_r.  This avoids code duplication.
53092         (main): Use isatty and fstat rather than ttyname and stat.
53093         Use getpwnam instead of getpwuid, to be portable to test platforms
53094         that have multiple login names for the same uid.
53096 2017-07-10  Tim Rühsen  <tim.ruehsen@gmx.de>
53097             Bruno Haible  <bruno@clisp.org>
53099         glob: Fix more memory leaks.
53100         * lib/glob.c (glob): Use 'goto out' in order to free dirname before
53101         returning.
53102         Reported by Tim Rühsen.
53104 2017-07-10  Bruno Haible  <bruno@clisp.org>
53106         Make sure $host and $host_os are defined when used.
53107         * m4/argz.m4 (gl_FUNC_ARGZ): Require AC_CANONICAL_HOST.
53108         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Likewise.
53109         * m4/csharpexec.m4 (gt_CSHARPEXEC): Likewise.
53110         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
53111         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
53112         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Likewise.
53113         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
53114         * m4/opendir.m4 (gl_FUNC_OPENDIR): Likewise.
53115         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
53116         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
53117         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Likewise.
53118         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Likewise.
53119         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
53120         * m4/ceill.m4 (gl_FUNC_CEILL): Require AC_CANONICAL_HOST outside the
53121         m4_ifdef block.
53123 2017-07-09  Bruno Haible  <bruno@clisp.org>
53125         *printf: Fix cross-compilation guess for Solaris.
53126         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): Fix copy-and-paste mistake from
53127         2010-12-21.
53129 2017-07-07  Paul Eggert  <eggert@cs.ucla.edu>
53130             Bruno Haible  <bruno@clisp.org>
53132         vasnprintf: port to macOS 10.13
53133         Problem reported by comex in:
53134         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00056.html
53135         * lib/vasnprintf.c (VASNPRINTF): Don’t use %n on macOS.
53137 2017-07-06  Bruno Haible  <bruno@clisp.org>
53139         imaxdiv tests: Fix logic.
53140         * tests/test-imaxdiv.c (main): Use == instead of =.
53141         Reported by Coverity.
53143 2017-07-06  Bruno Haible  <bruno@clisp.org>
53145         uninorm/filter: Fix use-after-free bug.
53146         * lib/uninorm/uninorm-filter.c (uninorm_filter_write): Maintain
53147         sortbuf == filter->sortbuf invariant.
53148         Reported by Coverity.
53150 2017-07-06  Bruno Haible  <bruno@clisp.org>
53152         glob: Fix more memory leaks.
53153         * lib/glob.c (glob): Free dirname before returning.
53154         Reported by Coverity and Tim Rühsen.
53156 2017-07-06  Paul Eggert  <eggert@cs.ucla.edu>
53158         parse-datetime: fix uninit var bug
53159         Reported by Bruno Haible in:
53160         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00038.html
53161         * lib/parse-datetime.y (parse_datetime2): Do not use
53162         uninitialized.
53164 2017-07-05  Bruno Haible  <bruno@clisp.org>
53166         doc: Update for MSVC 14.
53167         * doc/posix-headers/*.texi: Add info about MSVC 14.
53168         * doc/posix-functions/*.texi: Likewise.
53169         * doc/pastposix-functions/*.texi: Likewise.
53170         * doc/glibc-headers/*.texi: Likewise.
53171         * doc/glibc-functions/*.texi: Likewise.
53173 2017-07-05  Bruno Haible  <bruno@clisp.org>
53175         sched: Fix build failure on native Windows (regression from 2017-06-19).
53176         * m4/sched_h.m4 (gl_SCHED_H): Set HAVE_STRUCT_SCHED_PARAM always.
53178 2017-07-03  John E. Malmberg  <wb8tyw@gmail.com>
53180         stdioext: Port to OpenVMS.
53181         * lib/stdio-impl.h: OpenVMS uses struct _iobuf for FILE information.
53182         * lib/fpending.c (fpending): Remove non-working VMS specific code.
53183         * lib/fbufmode.c (fbufmode): Fix _IOLBF test to use fp_ macro.
53184         * lib/fflush.c (clear_ungetc_buffer): Add OpenVMS to comments.
53185         * lib/fpurge.c (fpurge): Likewise.
53186         * lib/freadable.c (freadable): Likewise.
53187         * lib/freadahead.c (freadahead): Likewise.
53188         * lib/freading.c (freading): Likewise.
53189         * lib/freadptr.c (freadptr): Likewise.
53190         * lib/freadseek.c (freadseek): Likewise.
53191         * lib/fseeko.c (fseeko): Likewise.
53192         * lib/fseterr.c (fseterr): Likewise.
53193         * lib/fwritable.c (fwriteable): Likewise.
53194         * lib/fwriting.c (fwriting): Likewise.
53196 2017-07-01  Benno Schulenberg  <bensberg@telfort.nl>
53198         glob: Declare variables at the very start of their scope.
53199         * lib/glob.c (convert_dirent, convert_dirent64): Give each fragment
53200         its separate scope, so the functions will compile on Haiku.
53202 2017-07-01  Bruno Haible  <bruno@clisp.org>
53204         logbl: Work around a glibc bug on PowerPC64LE.
53205         * m4/logbl.m4 (gl_FUNC_LOGBL_WORKS): Test also negative subnormal
53206         numbers.
53207         * doc/posix-functions/logbl.texi: Update.
53209 2017-06-29  Bruno Haible  <bruno@clisp.org>
53211         stat, fstat: Compile stat-w32.c only on platforms that need it.
53212         Suggested by Paul Eggert.
53213         * modules/stat (configure.ac): Request stat-w32.o only on native
53214         Windows.
53215         * modules/fstat (configure.ac): Likewise.
53217 2017-06-25  Bruno Haible  <bruno@clisp.org>
53219         stat: Improve last change.
53220         * lib/stat-w32.c: Revert last change. Use generic idiom instead.
53222 2017-06-25  Paul Eggert  <eggert@cs.ucla.edu>
53224         stat: port to xlc 12.01
53225         * lib/stat-w32.c: Always include <sys/types.h>.  Otherwise, xlc
53226         12.01 complains "Compilation unit is empty."
53228 2017-06-24  Paul Eggert  <eggert@cs.ucla.edu>
53230         xalloc-oversized: port to icc
53231         * lib/xalloc-oversized.h (xalloc_oversized): Do not use
53232         __builtin_mul_overflow if ICC is defined, as this results in
53233         "undefined reference to `__builtin_mul_overflow'" with icc 17.0.2
53234         20170213.
53236 2017-06-19  Bruno Haible  <bruno@clisp.org>
53238         classpath: Avoid including config.h twice, as it produces warnings.
53239         Reported by John E. Malmberg <wb8tyw@gmail.com>.
53240         * lib/classpath.h: Conditionalize the include of config.h.
53242 2017-06-19  Bruno Haible  <bruno@clisp.org>
53243             John E. Malmberg  <wb8tyw@gmail.com>  (tiny change)
53245         sched: Fix compilation failure on OpenVMS.
53246         * m4/sched_h.m4 (gl_SCHED_H): Require AC_CANONICAL_HOST. On OpenVMS,
53247         test whether <pthread.h> exists and defines struct sched_param.
53248         * lib/sched.in.h: On OpenVMS, include <pthread.h>.
53250 2017-06-17  Paul Eggert  <eggert@cs.ucla.edu>
53252         diffseq: port to GCC 7 with --enable-gcc-warnings
53253         * lib/diffseq.h (diag): Use an if, not an ifdef, for most of the
53254         heuristic check.  This way, GCC 7 with --enable-gcc-warnings does
53255         not complain about big_snake being defined but not used.
53257 2017-06-15  Bruno Haible  <bruno@clisp.org>
53259         gettext-h: Update theoretical condition for use of variable size arrays.
53260         Reported by Paul Eggert.
53261         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Extend comment
53262         to include the theoretical condition for availability of variable size
53263         arrays, if we could trust the value of __STDC_VERSION__.
53265 2017-06-12  Bruno Haible  <bruno@clisp.org>
53267         Relicense some modules under LGPLv2+.
53268         Daiki Ueno's approval is in
53269         https://lists.gnu.org/r/bug-gnulib/2017-06/msg00058.html.
53270         * modules/uniwidth/base (License): Change to LGPLv2+.
53271         * modules/uniwidth/width (License): Likewise.
53273 2017-06-11  Bruno Haible  <bruno@clisp.org>
53275         localename: Fix test failure on DragonFly BSD.
53276         * lib/localename.c (gl_locale_name_thread_unsafe): Treat DragonFly BSD
53277         like FreeBSD.
53279 2017-06-11  Bruno Haible  <bruno@clisp.org>
53281         float: Fix 'float' and 'isinf' failures on DragonFly BSD.
53282         * m4/float_h.m4 (gl_FLOAT_H): Treat DragonFly BSD like FreeBSD.
53283         * lib/float.in.h: Likewise.
53284         * m4/fmal.m4, m4/frexpl.m4, m4/logbl.m4: Update accordingly.
53286 2017-06-11  Bruno Haible  <bruno@clisp.org>
53288         gnulib-tool: Clean up after autotools.
53289         * gnulib-tool (func_create_testdir, func_create_megatestdir): Remove
53290         useless directory left over by the Autotools.
53292 2017-06-11  Paul Eggert  <eggert@cs.ucla.edu>
53294         getopt-posix: port to glibc 2.25.90
53295         Problem reported by Daniel P. Berrange in:
53296         http://lists.gnu.org/r/bug-gnulib/2017-06/msg00003.html
53297         * lib/getopt-pfx-core.h (_GETOPT_CORE_H):
53298         * lib/getopt-pfx-ext.h (_GETOPT_EXT_H):
53299         #undef if __GETOPT_PREFIX is defined.
53301 2017-06-11  Bruno Haible  <bruno@clisp.org>
53303         strtod-obsolete: Fix license.
53304         * modules/strtod-obsolete (License): Change to LGPL.
53306 2017-06-10  Jim Meyering  <meyering@fb.com>
53308         maint: update to work with GCC7's -Werror=implicit-fallthrough=
53309         * lib/savewd.c (FALLTHROUGH): Define.
53310         (savewd_save, savewd_restore): Use this, rather than a comment,
53311         whenever one switch case falls through into the next.
53313 2017-06-08  Bruno Haible  <bruno@clisp.org>
53315         host-cpu-c-abi: Support for aarch64 ILP32 ABI.
53316         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Recognize the aarch64 ILP32
53317         ABI. Set HOST_CPU_C_ABI=arm64-ilp32 and define __arm64_ilp32__ in this
53318         case.
53320 2017-06-08  Paul Eggert  <eggert@cs.ucla.edu>
53322         doc: remove robots, add prereqs
53323         * doc/build-automation.texi, doc/gnulib.texi: Mention prereqs for
53324         builds.  Simon's robot site does not seem to be up, so remove
53325         mentions of it for now.
53327 2017-06-08  Bruno Haible  <bruno@clisp.org>
53329         gnulib-tool: Fix bug in func_symlink_if_changed, from 2006-11-13.
53330         * gnulib-tool (func_symlink_target): New function, extracted from
53331         func_symlink.
53332         (func_symlink, func_symlink_if_changed): Use it.
53334 2017-06-08  Bruno Haible  <bruno@clisp.org>
53336         gnulib-tool: Fix bug in func_ln_s, from 2016-01-15.
53337         * gnulib-tool (func_ln_s): Determine cp_src correctly.
53339 2017-06-07  Bruno Haible  <bruno@clisp.org>
53341         canonicalize-lgpl: Avoid conflict with gnulib 'getcwd' module on VMS.
53342         Reported by John E. Malmberg <wb8tyw@gmail.com> in
53343         <https://lists.gnu.org/r/bug-gnulib/2017-06/msg00029.html>.
53344         * lib/canonicalize-lgpl.c (__getcwd): On VMS, when using gnulib's getcwd
53345         override, pass 2 arguments to getcwd, not 3.
53347 2017-06-04  Paul Eggert  <eggert@cs.ucla.edu>
53349         same-inode: port better to VMS 8.2 and later
53350         Problem reported by John E. Malmberg in:
53351         http://lists.gnu.org/r/bug-gnulib/2017-06/msg00005.html
53352         * lib/same-inode.h (SAME_INODE) [__VMS && 80200000 <= __CRTL_VER]:
53353         Use the usual POSIX definition.
53354         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Define _USE_STD_STAT.
53356 2017-06-01  Paul Eggert  <eggert@cs.ucla.edu>
53358         error: fix POSIX violation for va_end
53359         Problem reported by Bruno Haible in:
53360         http://lists.gnu.org/r/bug-gnulib/2017-06/msg00001.html
53361         * lib/error.c (error_tail): Do not call va_end here.
53362         (error, error_at_line): Call it here instead.
53364 2017-05-28  Bruno Haible  <bruno@clisp.org>
53366         c-strtod: Make it usable in C++ mode.
53367         * lib/c-strtod.h: Add 'extern "C"' marker for C++.
53369 2017-05-25  Jim Meyering  <meyering@fb.com>
53371         quotearg: fix compilation failure due to FALLTHROUGH misuse
53372         * lib/quotearg.c (quotearg_buffer_restyled): Revert one FALLTHROUGH
53373         macro back to /* fall through */ comment.  The macro can apply only
53374         to a following case statement.  Reported by Assaf Gordon.
53376 2017-05-25  Paul Eggert  <eggert@cs.ucla.edu>
53378         intprops: port to recent icc
53379         Port to icc (ICC) 17.0.4 20170411, which defines __GNUC__ to be 5
53380         but does not support __builtin_add_overflow etc.
53381         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW) [__ICC]:
53382         Define to 0.
53384 2017-05-23  Karl Berry  <karl@freefriends.org>
53386         * config/srclist.txt (iconv.m4): sync broken, comment out
53387         until (hopefully) the next gettext release.
53389 2017-05-22  Bjarni Ingi Gislason  <bjarniig@rhi.hi.is>
53391         Remove repeated words in comments.
53393 2017-05-22  Bernhard Voelker  <mail@bernhard-voelker.de>
53395         fallthrough: reinstate a FALLTHROUGH instance in quotearg
53396         quotearg.c: Reinstate this instance which is significant
53397         when the if branch is not taken.
53399 2017-05-21  Bruno Haible  <bruno@clisp.org>
53401         gnulib-tool: Add options to create hard links.
53402         * gnulib-tool (func_usage): Document options --hardlink,
53403         --local-hardlink, --more-hardlinks.
53404         (func_symlink): Renamed from func_ln.
53405         (func_symlink_if_changed): Renamed from func_ln_if_changed.
53406         (func_hardlink): New function.
53407         (copymode, lcopymode): New variables.
53408         (symbolic, lsymbolic): Remove variables.
53409         (Options): Implement options --hardlink, --local-hardlink,
53410         --more-hardlinks.
53411         (func_should_link): Renamed from func_should_symlink. Set copyaction.
53412         (func_add_file, func_update_file): Update invocation of
53413         func_should_link. Invoke func_hardlink when appropriate.
53414         (func_import): Update comments.
53415         (func_create_testdir): Update invocation of func_should_link. Invoke
53416         func_hardlink when appropriate.
53417         Finally, invoke 'git update-index --refresh' to mitigate the effects of
53418         the hard links on git.
53420 2017-05-20  Bruno Haible  <bruno@clisp.org>
53422         argp: Simplify bit manipulation.
53423         * lib/argp-parse.c (parser_parse_opt): Use &, |, ~ instead of shifts
53424         on a signed integer type.
53426 2017-05-20  Bruno Haible  <bruno@clisp.org>
53428         Avoid wrong configure results with gcc -fsanitize=address.
53429         This completes the work done on 2016-02-06 on this topic.
53430         * m4/memmem.m4 (gl_FUNC_MEMMEM): Free allocated memory before returning.
53431         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
53432         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
53433         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
53434         * m4/fopen.m4 (gl_FUNC_FOPEN): Close allocated FILE streams before
53435         returning.
53436         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Likewise.
53437         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
53438         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
53439         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
53440         * m4/signbit.m4 (gl_FLOATTYPE_SIGN_LOCATION): Likewise.
53441         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
53442         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Close allocated FILE streams and
53443         free allocated memory before returning.
53444         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
53445         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Close allocated DIR
53446         objects before returning.
53447         * m4/iconv.m4 (AM_ICONV_LINK): Close allocated iconv_t handles before
53448         returning.
53450 2017-05-20  Bruno Haible  <bruno@clisp.org>
53452         gnulib-tool: Don't create hard links between gnulib and its testdirs.
53453         * gnulib-tool (func_create_testdir): Don't invoke 'ln'.
53455 2017-05-20  Bruno Haible  <bruno@clisp.org>
53457         argp, tsearch tests: Fix file list.
53458         * modules/argp-tests (Files): Add tests/macros.h.
53459         * modules/tsearch-tests (Files): Likewise.
53461 2017-05-20  Bruno Haible  <bruno@clisp.org>
53463         getopt-posix tests: Remove redundant include.
53464         * tests/test-getopt.h: Don't include "macros.h". It's already included
53465         by tests/test-getopt-main.h.
53467 2017-05-19  Jim Meyering  <meyering@fb.com>
53469         dfa: two small simplifications
53470         * lib/dfa.c (build_state): Avoid repeating longer expressions.
53472 2017-05-18  Jim Meyering  <meyering@fb.com>
53474         fallthrough: update for GCC 7/8
53475         * lib/quotearg.c (FALLTHROUGH): New macro.
53476         Use it whenever one switch case falls through into the next,
53477         replacing "/* Fall through */" comments.  This exposed one
53478         instance of an unwarranted "fall through" comment: unwarranted
53479         because it preceded a "goto" label not a case statement.
53480         * lib/freopen-safer.c (freopen_safer): Likewise.
53481         * lib/fts.c (leaf_optimization_applies): Likewise.
53482         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Likewise.
53483         * tests/test-getopt_long.h (getopt_long_loop): Likewise.
53484         * tests/test-tsearch.c (mangle_tree): Likewise.  Also include
53485         tests/macros.h for the definition.
53486         * tests/test-argp.c (group1_parser): Likewise.
53487         * tests/test-getopt.h (getopt_loop): Likewise.
53489 2017-05-19  Paul Eggert  <eggert@cs.ucla.edu>
53491         argp: fix shift bug
53492         * lib/argp-parse.c (parser_parse_opt): Rework to avoid undefined
53493         behavior on shift overflow, caught by gcc -fsanitize=undefined.
53495         argp: fix pointer-subtraction bug
53496         * lib/argp-help.c (hol_append): Don’t subtract pointers to
53497         different arrays, as this can run afoul of -fcheck-pointer-bounds.
53498         See the thread containing Bruno Haible’s report in:
53499         http://lists.gnu.org/r/bug-gnulib/2017-05/msg00171.html
53501 2017-05-19  Bruno Haible  <bruno@clisp.org>
53503         printf-posix tests: Avoid test failure with "gcc --coverage".
53504         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
53505         * tests/test-printf-posix2.c (main): Test a width of 10000000 rather
53506         than 5000000.
53507         * tests/test-fprintf-posix2.c (main): Likewise.
53509 2017-05-19  Paul Eggert  <eggert@cs.ucla.edu>
53511         closeout: don’t close stderr when sanitizing
53512         * NEWS: Document this.
53513         * lib/closeout.c (__has_feature): New macro, if not already defined.
53514         (SANITIZE_ADDRESS): New constant.
53515         (close_stdout): Don’t close stderr if sanitizing addresses.
53517 2017-05-19  Bruno Haible  <bruno@clisp.org>
53519         get-rusage-data tests: Avoid failure on Linux/glibc.
53520         * tests/test-get-rusage-data.c (main): Don't expect a strict increase
53521         on glibc systems.
53523 2017-05-18  Bruno Haible  <bruno@clisp.org>
53525         localename: Include necessary header files on Cygwin.
53526         * lib/localename.c [__CYGWIN__]: Include <langinfo.h>, since this is
53527         where NL_LOCALE_NAME is defined.
53529 2017-05-18  Bruno Haible  <bruno@clisp.org>
53531         gettext: Update macros from gettext git.
53532         * m4/intldir.m4: Require Autoconf >= 2.60.
53533         * m4/progtest.m4: Fix typos in copyright notice.
53535 2017-05-18  Bruno Haible  <bruno@clisp.org>
53537         copy-file tests: Fix link error (regression from 2017-05-01).
53538         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
53539         * modules/copy-file-tests (Makefile.am): Link test-copy-file with
53540         $(LIB_CLOCK_GETTIME).
53542 2017-05-18  Bruno Haible  <bruno@clisp.org>
53544         unicase/special-casing: Fix incompatibility with gperf-3.0.4
53545         (regression from 2017-02-13).
53546         * lib/unicase/special-casing.in.h: Renamed from
53547         lib/unicase/special-casing.h.
53548         * modules/unicase/special-casing (Files): Add
53549         lib/unicase/special-casing.in.h. Remove lib/unicase/special-casing.h.
53550         (Makefile.am): Add rule for generating unicase/special-casing.h.
53551         Update BUILT_SOURCES and MOSTLYCLEANFILES accordingly.
53552         * lib/unicase/special-casing.c: Include "unicase/special-casing.h",
53553         not "special-casing.h".
53554         * lib/unicase/u*.c: Likewise.
53556 2017-05-17  Bruno Haible  <bruno@clisp.org>
53558         README: Don't ask people to read a TeXinfo file.
53559         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
53560         * README: Tell people how to read the HTML formatted manual.
53562 2017-05-16  Tim Rühsen  <tim.ruehsen@gmx.de>
53564         parse-datetime: Fix memleak
53565         * lib/parse-datetime.y (parse_datetime2): Cleanup on
53566         localtime_rz() failure.
53568 2017-05-16  Bruno Haible  <bruno@clisp.org>
53570         javacomp: Fix handle leak.
53571         Found by Coverity.
53572         * lib/javacomp.c (get_classfile_version): Close fd before returning.
53574 2017-05-16  Bruno Haible  <bruno@clisp.org>
53576         relocate: Make it easier to reclaim allocated memory.
53577         * lib/relocatable.h (relocate2): New declaration/macro.
53578         * lib/relocatable.c (relocate2): New function.
53579         * doc/relocatable-maint.texi (Supporting Relocation): Mention the
53580         relocate2 function.
53581         * lib/localcharset.c (relocate2): Define fallback.
53582         (get_charset_aliases): Invoke relocate2 instead of relocate. Free the
53583         allocated memory.
53584         * lib/javaversion.c (relocate2): Define fallback.
53585         (javaexec_version): Invoke relocate2 instead of relocate. Free the
53586         allocated memory.
53588 2017-05-16  Bruno Haible  <bruno@clisp.org>
53590         relocate: Simplify EMX specific code.
53591         * lib/relocatable.c (relocate): Assume pathname is non-NULL. Use
53592         ISSLASH macro consistently. Avoid dangerous string concatenation idiom.
53594 2017-05-16  Bruno Haible  <bruno@clisp.org>
53596         sigpipe tests: Fix file list.
53597         * modules/sigpipe-tests (Files): Add tests/macros.h.
53599 2017-05-16  Paul Eggert  <eggert@cs.ucla.edu>
53601         manywarnings: update for GCC 7
53602         * build-aux/gcc-warning.spec:
53603         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
53604         Add GCC 7 warnings, notably -Wimplicit-fallthrough=5, which
53605         requires a non-comment fallthrough attribute.  This is a bit
53606         cleaner than the comment versions.
53607         * lib/strftime.c, lib/dfa.c, lib/fnmatch.c, lib/mbrtowc.c:
53608         * lib/vasnprintf.c, tests/macros.h (FALLTHROUGH): New macro.
53609         Use it whenever one switch case falls through into the next.
53610         * lib/fnmatch_loop.c, tests/test-mbrtowc.c, tests/test-sigpipe.c:
53611         Use FALLTHROUGH macro.
53613 2017-05-15  Bruno Haible  <bruno@clisp.org>
53615         gnulib-tool: Fix generated code when libtests contains module 'alloca'.
53616         * gnulib-tool (func_emit_tests_Makefile_am): For libtests.a, use
53617         @ALLOCA@, not @LTALLOCA@.
53619 2017-05-15  Bruno Haible  <bruno@clisp.org>
53621         sys_select: Avoid "was expanded before it was required" warning.
53622         * modules/sys_select (configure.ac): Require, not invoke,
53623         gl_HEADER_SYS_SELECT.
53625 2017-05-14  Paul Eggert  <eggert@cs.ucla.edu>
53627         gnulib-tool: improve GNU Make debugging
53628         * gnulib-tool (func_emit_lib_Makefile_am): Omit unnecessary echo.
53629         Report autoconf diagnostics when it fails, in the output makefile.
53631 2017-05-14  Bruno Haible  <bruno@clisp.org>
53633         stat-time tests: Improve comment.
53634         * tests/test-stat-time.c: Add hyperlink, from Paul Eggert.
53636 2017-05-14  Bruno Haible  <bruno@clisp.org>
53638         same-inode: Adapt for windows-stat-inodes.
53639         * lib/same-inode.h: Include <sys/types.h>.
53640         (SAME_INODE) [_GL_WINDOWS_STAT_INODES]: Define specifically.
53641         * modules/same-inode (Depends-on): Add sys_types.
53643 2017-05-14  Bruno Haible  <bruno@clisp.org>
53645         windows-stat-inodes: New module.
53646         * m4/windows-stat-inodes.m4: New file.
53647         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Set WINDOWS_STAT_INODES.
53648         * modules/sys_types (Makefile.am): Substitute WINDOWS_STAT_INODES.
53649         * lib/sys_types.in.h [WINDOWS_STAT_INODES]: Override dev_t and ino_t.
53650         (_GL_WINDOWS_STAT_INODES): New macro.
53651         * lib/stat-w32.c: Set _WIN32_WINNT. Include <string.h>, verify.h.
53652         (GetFileInformationByHandleExFunc): New variable.
53653         (initialize): Initialize it.
53654         (_gl_fstat_by_handle) [_GL_WINDOWS_STAT_INODES]: Initialize st_dev and
53655         st_ino appropriately.
53656         * lib/stat.c (rpl_stat): Use the directory entry based approach only as
53657         a fallback, because it does not provide st_dev and st_ino values.
53658         * modules/fstat (Depends-on): Add 'verify'.
53659         * modules/windows-stat-inodes: New file.
53660         * doc/windows-stat-inodes.texi: New file.
53661         * doc/gnulib.texi: Include it.
53662         * doc/posix-headers/sys_stat.texi: Mention the new module.
53664 2017-05-14  Bruno Haible  <bruno@clisp.org>
53666         stat-time tests: Workaround for native Windows.
53667         * tests/test-stat-time.c: Include <stdio.h>, <time.h>.
53668         (filename_stamp1, filename_testfile, filename_stamp2, filename_stamp3):
53669         New variables.
53670         (initialize_filenames): New function.
53671         (main): Invoke it.
53672         (cleanup, prepare_test): Update.
53674 2017-05-14  Bruno Haible  <bruno@clisp.org>
53676         stat-time: Adapt for windows-stat-timespec.
53677         * lib/stat-time.h (get_stat_birthtime) [_GL_WINDOWS_STAT_TIMESPEC]: Use
53678         entire st_ctim field.
53680 2017-05-13  Jim Meyering  <meyering@fb.com>
53682         maint.mk: update regex to reflect 2013 addition of "assume" to verify.h
53683         * top/maint.mk (sc_prohibit_verify_without_use): Don't reject a source
53684         file that uses the assume macro, claiming that verify.h is unused.
53686 2017-05-13  Bruno Haible  <bruno@clisp.org>
53688         Use symbolic values for _WIN32_WINNT.
53689         * lib/ftruncate.c (_WIN32_WINNT): Use symbolic value _WIN32_WINNT_WIN2K.
53690         * lib/sethostname.c (_WIN32_WINNT): Likewise.
53692 2017-05-13  Bruno Haible  <bruno@clisp.org>
53694         year2038: New module.
53695         * m4/year2038.m4: New file.
53696         * modules/year2038: New file.
53697         * doc/year2038.texi: New file.
53698         * doc/gnulib.texi: Include it.
53700 2017-05-13  Bruno Haible  <bruno@clisp.org>
53702         largefile: Simplify.
53703         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Remove unused definition
53704         of _GL_WINDOWS_64_BIT_ST_SIZE.
53706 2017-05-13  Bruno Haible  <bruno@clisp.org>
53708         largefile: Improve and document.
53709         * m4/largefile.m4 (gl_LARGEFILE): Set WINDOWS_64_BIT_ST_SIZE to 0 if
53710         the mingw headers already define 'stat' appropriately.
53711         * modules/largefile (Description): Clarify.
53712         * doc/largefile.texi: New file.
53713         * doc/gnulib.texi: Include it.
53714         * doc/posix-headers/sys_types.texi: Update.
53716 2017-05-13  Bruno Haible  <bruno@clisp.org>
53718         truncate: New module.
53719         * lib/unistd.in.h (truncate): New declaration.
53720         * lib/truncate.c: New file.
53721         * m4/truncate.m4: New file.
53722         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether 'truncate' is declared.
53723         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_TRUNCATE, HAVE_TRUNCATE,
53724         REPLACE_TRUNCATE.
53725         * modules/unistd (Makefile.am): Substitute GNULIB_TRUNCATE,
53726         HAVE_TRUNCATE, REPLACE_TRUNCATE.
53727         * modules/truncate: New file.
53728         * tests/test-unistd-c++.cc (truncate): Test signature.
53729         * doc/posix-functions/truncate.texi: Mention the new module.
53731         * tests/test-truncate.c: New file.
53732         * modules/truncate-tests: New file.
53734 2017-05-13  Bruno Haible  <bruno@clisp.org>
53736         windows-stat-timespec: New module.
53737         * modules/windows-stat-timespec: New file.
53738         * m4/windows-stat-timespec.m4: New file.
53739         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Set WINDOWS_STAT_TIMESPEC.
53740         * modules/sys_stat (Makefile.am): Substitute WINDOWS_STAT_TIMESPEC.
53741         * lib/sys_stat.in.h (struct stat) [WINDOWS_STAT_TIMESPEC]: Declare with
53742         fields st_atim, st_mtim, st_ctim.
53743         (st_atime, st_mtime, st_ctime): Define as macros.
53744         (_GL_WINDOWS_STAT_TIMESPEC): New macro.
53745         * lib/stat-w32.h (_gl_convert_FILETIME_to_timespec)
53746         [_GL_WINDOWS_STAT_TIMESPEC]: New declaration.
53747         * lib/stat-w32.c (_gl_convert_FILETIME_to_timespec)
53748         [_GL_WINDOWS_STAT_TIMESPEC]: New function.
53749         (_gl_convert_FILETIME_to_POSIX): Adjust coding style.
53750         (_gl_fstat_by_handle): If _GL_WINDOWS_STAT_TIMESPEC, convert the
53751         FILETIME to 'struct timespec', not 'time_t'.
53752         * lib/stat.c (rpl_stat): If _GL_WINDOWS_STAT_TIMESPEC, convert the
53753         FILETIME to 'struct timespec', not 'time_t'.
53754         * lib/stat-time.h (STAT_TIMESPEC): Define also if
53755         _GL_WINDOWS_STAT_TIMESPEC.
53756         * doc/windows-stat-timespec.texi: New file.
53757         * doc/gnulib.texi: Include it.
53759 2017-05-13  Bruno Haible  <bruno@clisp.org>
53761         windows-stat-override: New module.
53762         * lib/sys_stat.in.h (stat) [GNULIB_OVERRIDES_STRUCT_STAT]: Provide own
53763         definition. Define GNULIB_defined_struct_stat.
53764         (fstat, fstatat, lstat, stat) [GNULIB_OVERRIDES_STRUCT_STAT]: Provoke
53765         link error if this symbol is used and the corresponding module is not
53766         in use.
53767         (_stat64, _stat32i64, _stati64, _stat32, _stat64i32): Don't redefine if
53768         GNULIB_OVERRIDES_STRUCT_STAT.
53769         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
53770         GNULIB_OVERRIDES_STRUCT_STAT.
53771         * modules/sys_stat (Makefile.am): Substitute
53772         GNULIB_OVERRIDES_STRUCT_STAT.
53773         * modules/windows-stat-override: New file.
53775 2017-05-13  Bruno Haible  <bruno@clisp.org>
53777         fstat: Fix module dependency conditions.
53778         * modules/fstat (Depends-on): Fix typo.
53780 2017-05-13  Bruno Haible  <bruno@clisp.org>
53782         stat, fstat: Complete removal of old native Windows code.
53783         * lib/stat.c: Remove old macrology for WINDOWS_NATIVE.
53784         * lib/fstat.c: Likewise.
53785         * lib/stat-w32.c: Likewise.
53787 2017-05-13  Bruno Haible  <bruno@clisp.org>
53789         stat: Complete removal of REPLACE_FUNC_STAT_DIR code.
53790         * lib/stat.c: Remove all REPLACE_FUNC_STAT_DIR code.
53792 2017-05-11  Paul Eggert  <eggert@cs.ucla.edu>
53794         getopt-posix: port to mingw
53795         * lib/getopt.c (flockfile, funlockfile): Define on mingw.
53796         Problem reported by Daniel P. Berrage in:
53797         http://lists.gnu.org/r/bug-gnulib/2017-05/msg00086.html
53799 2017-05-11  Bruno Haible  <bruno@clisp.org>
53801         gettimeofday: Increase precision on mingw.
53802         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Require AC_CANONICAL_HOST.
53803         Set REPLACE_GETTIMEOFDAY to 1 on mingw.
53804         * lib/gettimeofday.c (gettimeofday): On native Windows, use the
53805         GetSystemTimePreciseAsFileTime based implementation always.
53806         * doc/posix-functions/gettimeofday.texi: Mention precision problem on
53807         mingw.
53809 2017-05-11  Bruno Haible  <bruno@clisp.org>
53811         poll: Fix confusion between SOCKETs and FDs on native Windows.
53812         Fix proposed by Daniel P. Berrange <berrange@redhat.com>.
53813         * lib/poll.c [WINDOWS_NATIVE]: Undefine select.
53815 2017-05-11  Bruno Haible  <bruno@clisp.org>
53817         doc: Clarify doc about socket functions on native Windows.
53818         This reworks doc that was added on 2008-09-29.
53819         * doc/posix-functions/select.texi: Fix copy-and-paste mistake and use
53820         clearer wording.
53821         * doc/posix-functions/accept.texi: Use clearer wording.
53822         * doc/posix-functions/bind.texi: Likewise.
53823         * doc/posix-functions/connect.texi: Likewise.
53824         * doc/posix-functions/getpeername.texi: Likewise.
53825         * doc/posix-functions/getsockname.texi: Likewise.
53826         * doc/posix-functions/getsockopt.texi: Likewise.
53827         * doc/posix-functions/ioctl.texi: Likewise.
53828         * doc/posix-functions/listen.texi: Likewise.
53829         * doc/posix-functions/recv.texi: Likewise.
53830         * doc/posix-functions/recvfrom.texi: Likewise.
53831         * doc/posix-functions/send.texi: Likewise.
53832         * doc/posix-functions/sendto.texi: Likewise.
53833         * doc/posix-functions/setsockopt.texi: Likewise.
53834         * doc/posix-functions/shutdown.texi: Likewise.
53835         * doc/posix-functions/socket.texi: Likewise.
53837 2017-05-10  Bruno Haible  <bruno@clisp.org>
53839         poll: Fix link error on native Windows.
53840         * lib/poll.c [WINDOWS_NATIVE]: Undefine recv.
53842 2017-05-10  Bruno Haible  <bruno@clisp.org>
53844         time: Fix missing initialization of HAVE_TIMEZONE_T.
53845         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_TIMEZONE_T
53846         here...
53847         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): ... not here.
53848         * m4/time_rz.m4 (gl_TIME_RZ): Require gl_HEADER_TIME_H_DEFAULTS, not
53849         gl_HEADER_SYS_TIME_H_DEFAULTS.
53850         * modules/time_rz (Depends-on): Add 'time'. Remove useless quoting.
53851         (configure.ac): Remove useless quoting.
53853 2017-05-10  Bruno Haible  <bruno@clisp.org>
53855         Implement a way to opt out from MSVC support, part 2.
53856         * modules/msvc-inval (Include): Document recommended idiom.
53857         * modules/msvc-nothrow (Include): Likewise.
53859         Implement a way to opt out from MSVC support.
53860         This is useful for Emacs.
53861         * modules/msvc-nothrow (configure.ac): Invoke gl_MODULE_INDICATOR.
53862         * lib/accept4.c: Include <io.h> as an alternative to msvc-nothrow.h.
53863         * lib/error.c: Likewise.
53864         * lib/fcntl.c: Likewise.
53865         * lib/flock.c: Likewise.
53866         * lib/fstat.c: Likewise.
53867         * lib/fsync.c: Likewise.
53868         * lib/ioctl.c: Likewise.
53869         * lib/isapipe.c: Likewise.
53870         * lib/lseek.c: Likewise.
53871         * lib/nonblocking.c: Likewise.
53872         * lib/poll.c: Likewise.
53873         * lib/select.c: Likewise.
53874         * lib/sockets.h: Likewise.
53875         * lib/sockets.c: Likewise.
53876         * lib/stdio-read.c: Likewise.
53877         * lib/stdio-write.c: Likewise.
53878         * lib/utimens.c: Likewise.
53879         * lib/w32sock.h: Likewise.
53880         * lib/w32spawn.h: Likewise.
53881         * tests/test-cloexec.c: Likewise.
53882         * tests/test-dup-safer.c: Likewise.
53883         * tests/test-dup2.c: Likewise.
53884         * tests/test-dup3.c: Likewise.
53885         * tests/test-fcntl.c: Likewise.
53886         * tests/test-pipe.c: Likewise.
53887         * tests/test-pipe2.c: Likewise.
53888         * lib/ftruncate.c: Likewise.
53889         (chsize_nothrow): Renamed from chsize.
53890         * lib/msvc-nothrow.c: Don't include msvc-inval.h if
53891         HAVE_MSVC_INVALID_PARAMETER_HANDLER is not defined.
53892         * lib/close.c: Likewise.
53893         * lib/dup.c: Likewise.
53894         * lib/fclose.c: Likewise.
53895         * lib/raise.c: Likewise.
53896         * tests/test-fgetc.c: Likewise.
53897         * tests/test-fputc.c: Likewise.
53898         * tests/test-fread.c: Likewise.
53899         * tests/test-fwrite.c: Likewise.
53900         * lib/getdtablesize.c: Likewise.
53901         (_setmaxstdio_nothrow): Renamed from _setmaxstdio.
53902         * lib/isatty.c: Don't include msvc-inval.h if
53903         HAVE_MSVC_INVALID_PARAMETER_HANDLER is not defined.
53904         Include <io.h> as an alternative to msvc-nothrow.h.
53905         * lib/read.c: Likewise.
53906         * lib/write.c: Likewise.
53907         * lib/dup2.c: Likewise.
53908         (dup2_nothrow): New function.
53909         (ms_windows_dup2): Use it.
53910         * m4/close.m4 (gl_FUNC_CLOSE): Invoke gl_MSVC_INVAL and test
53911         HAVE_MSVC_INVALID_PARAMETER_HANDLER only if gl_MSVC_INVAL is defined.
53912         * m4/dup.m4 (gl_FUNC_DUP): Likewise.
53913         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Likewise.
53914         * m4/raise.m4 (gl_FUNC_RAISE): Likewise.
53915         * m4/read.m4 (gl_FUNC_READ): Likewise.
53916         * m4/write.m4 (gl_FUNC_WRITE): Likewise.
53917         * doc/windows-without-msvc.texi: New file.
53918         * doc/gnulib.texi (Native Windows Support without MSVC Support): New
53919         section.
53921 2017-05-10  Bruno Haible  <bruno@clisp.org>
53923         wait-process: Adjust native Windows support.
53924         * lib/wait-process.c: Use the usual condition for recognizing a native
53925         Windows platform.
53927 2017-05-10  Bruno Haible  <bruno@clisp.org>
53929         doc: New chapter "Native Windows Support".
53930         * doc/gnulib.texi (Native Windows Support): New chapter.
53931         * doc/windows-libtool.texi: Small wording changes.
53932         * doc/windows-sockets.texi: Small wording and formatting changes.
53934 2017-05-10  Bruno Haible  <bruno@clisp.org>
53936         doc: Move section "Library version handling".
53937         * doc/gnulib.texi: Move section "Library version handling"
53938         from chapter "Miscellaneous Notes" to chapter "Particular Modules".
53940 2017-05-10  Bruno Haible  <bruno@clisp.org>
53942         doc: Move section "Running self-tests under valgrind".
53943         * doc/gnulib.texi: Move section "Running self-tests under valgrind"
53944         from chapter "Particular Modules" to chapter "Miscellaneous Notes".
53946 2017-05-10  Bruno Haible  <bruno@clisp.org>
53948         doc: New chapter "Build Infrastructure Modules".
53949         * doc/gnulib.texi (Build Infrastructure Modules): New chapter.
53951 2017-05-10  Bruno Haible  <bruno@clisp.org>
53953         Prepare for reordering sections in the manual.
53954         * doc/gnulib.texi: Move several sections to separate files. Include
53955         these files.
53956         * doc/out-of-memory.texi: New file, extracted from doc/gnulib.texi.
53957         * doc/obsolete.texi: Likewise.
53958         * doc/extra-tests.texi: Likewise.
53959         * doc/transversal.texi: Likewise.
53960         * doc/namespace.texi: Likewise.
53961         * doc/check-version.texi: Likewise.
53962         * doc/windows-sockets.texi: Likewise.
53963         * doc/windows-libtool.texi: Likewise.
53964         * doc/licenses-texi.texi: Likewise.
53965         * doc/build-automation.texi: Likewise.
53966         * doc/c-locale.texi: Likewise.
53968 2017-05-10  Bruno Haible  <bruno@clisp.org>
53970         Fix instructions how to update manual on www.gnu.org.
53971         * doc/README: Add -I option, so that texi2dvi finds texinfo.tex.
53973 2017-05-09  Bruno Haible  <bruno@clisp.org>
53975         tzset: Expand comment about TZ problem on native Windows.
53976         * lib/tzset.c (tzset): Elaborate comment, based on explanations by
53977         Paul Eggert.
53978         * lib/ctime.c (rpl_ctime): Likewise.
53979         * lib/localtime.c (rpl_localtime): Likewise.
53980         * lib/mktime.c (mktime): Likewise.
53981         * lib/strftime-fixes.c (rpl_strftime): Likewise.
53982         * lib/wcsftime.c (rpl_wcsftime): Likewise.
53984 2017-05-08  Paul Eggert  <eggert@cs.ucla.edu>
53986         intprops: don’t depend on ‘verify’
53987         Problem reported by Ævar Arnfjörð Bjarmason in:
53988         http://lists.gnu.org/r/bug-gnulib/2017-05/msg00054.html
53989         * lib/intprops.h: Do not include verify.h, and move compile-time
53990         checks from here ...
53991         * tests/test-intprops.c (main): ... to here, if they’re not here
53992         already.  Check widths of other standard integer types.
53993         * modules/intprops (Depends-on): Remove ‘verify’.
53995 2017-05-07  Bruno Haible  <bruno@clisp.org>
53997         utimens: On native Windows, support 100ns resolution also if fd < 0.
53998         * lib/utime.in.h: Include <time.h>.
53999         (_gl_utimens_windows): New declaration.
54000         * lib/utime.c (_gl_utimens_windows): New function, based on utime.
54001         (utime): Invoke it.
54002         * lib/utimens.c (fdutimens): On native Windows, call _gl_utimens_windows
54003         instead of utime.
54004         * modules/utime (Depends-on): Add 'time'.
54006 2017-05-07  Bruno Haible  <bruno@clisp.org>
54008         utimens: Improve error code on native Windows.
54009         * lib/utimens.c (fdutimens): If fd was not opened with O_RDWR, fail with
54010         error code EACCES, not EINVAL.
54012 2017-05-07  Bruno Haible  <bruno@clisp.org>
54014         utime: Handle more Windows error codes.
54015         * lib/utime.c (utime): Handle ERROR_BAD_NETPATH.
54016         Based on explanations by Billy O'Neal.
54018 2017-05-05  Bruno Haible  <bruno@clisp.org>
54020         crypto/rijndael: Fix "strict-aliasing rules" warnings, alignment issues.
54021         * lib/rijndael-api-fst.c (rijndaelBlockEncrypt): Declare 'block' as a
54022         union.
54023         (rijndaelPadEncrypt, rijndaelBlockDecrypt): Likewise.
54024         (rijndaelPadDecrypt): Likewise. Use local variable 'iv' to cache the
54025         value of cipher->IV.
54027 2017-05-05  Bruno Haible  <bruno@clisp.org>
54029         wctype-h-c++-tests: Update.
54030         * tests/test-wctype-h-c++.cc: Reorder to match lib/wchar.in.h.
54032 2017-05-05  Bruno Haible  <bruno@clisp.org>
54034         wchar-c++-tests: Update.
54035         * tests/test-wchar-c++.cc (wcsftime): Declare, missing since 2017-04-30.
54037 2017-05-05  Bruno Haible  <bruno@clisp.org>
54039         utime-h-c++-tests: New module.
54040         * tests/test-utime-h-c++.cc: New file.
54041         (utime): Declare, missing since 2017-04-30.
54042         * modules/utime-h-c++-tests: New file.
54044 2017-05-05  Bruno Haible  <bruno@clisp.org>
54046         unistd-c++-tests: Update.
54047         * tests/test-unistd-c++.cc (isatty): Declare, missing since 2012-01-03.
54048         (read): Declare, missing since 2011-04-15.
54049         (sethostname): Declare, missing since 2011-12-03.
54051 2017-05-05  Bruno Haible  <bruno@clisp.org>
54053         time-c++-tests: Update.
54054         * tests/test-time-c++.cc (tzset): Declare, missing since 2017-05-01.
54055         (localtime, gmtime): Declare, missing since 2017-04-30.
54056         (ctime): Declare, missing since 2017-04-30.
54057         (strftime): Declare, missing since 2017-04-30.
54058         (tzalloc, tzfree, localtime_rz, mktime_z): Declare, missing since
54059         2015-07-24.
54061 2017-05-05  Bruno Haible  <bruno@clisp.org>
54063         sys_resource-c++-tests: New module.
54064         * tests/test-sys_resource-c++.cc: New file.
54065         (getrusage): Declare, missing since 2012-04-13.
54066         * modules/sys_resource-c++-tests: New file.
54068 2017-05-05  Bruno Haible  <bruno@clisp.org>
54070         strings-c++-tests: New module.
54071         * tests/test-strings-c++.cc: New file.
54072         (ffs): Declare, missing since 2011-07-12.
54073         * modules/strings-c++-tests: New file.
54075 2017-05-05  Bruno Haible  <bruno@clisp.org>
54077         string-c++-tests: Update.
54078         * tests/test-string-c++.cc (ffsl): Declare, missing since 2011-07-15.
54079         (ffsll): Declare, missing since 2011-07-15.
54081 2017-05-05  Bruno Haible  <bruno@clisp.org>
54083         stdlib-c++-tests: Update.
54084         * tests/test-stdlib-c++.cc (posix_openpt): Declare, missing since
54085         2011-10-18.
54086         (ptsname_r): Declare, missing since 2011-11-07.
54087         (qsort_r): Declare, missing since 2014-08-29.
54088         (random, srandom, initstate, setstate): Declare, missing since
54089         2012-01-14.
54090         (secure_getenv): Declare, missing since 2013-02-05.
54092 2017-05-05  Bruno Haible  <bruno@clisp.org>
54094         stdio-c++-tests: Update.
54095         * tests/test-stdio-c++.cc (pclose): Declare, missing since 2011-09-18.
54097 2017-05-05  Bruno Haible  <bruno@clisp.org>
54099         signal-h-c++-tests: Update.
54100         * tests/test-signal-h-c++.cc (raise): Remove redundant declaration.
54102 2017-05-05  Bruno Haible  <bruno@clisp.org>
54104         math-c++-tests: Update.
54105         * tests/test-math-c++.cc (fmaf): Declare, missing since 2011-10-17.
54106         (fma): Declare, missing since 2011-10-17.
54107         (fmal): Declare, missing since 2011-10-17.
54109 2017-05-05  Bruno Haible  <bruno@clisp.org>
54111         locale-c++-tests: Update.
54112         * tests/test-locale-c++.cc (localeconv): Declare, missing since
54113         2012-03-25.
54115 2017-05-05  Bruno Haible  <bruno@clisp.org>
54117         inttypes-c++-tests: New module.
54118         * tests/test-inttypes-c++.cc: New file.
54119         (strtoimax): Declare, missing since 2012-01-05.
54120         (strtoumax): Declare, missing since 2012-01-05.
54121         * modules/inttypes-c++-tests: New file.
54123 2017-05-05  Bruno Haible  <bruno@clisp.org>
54125         dirent-c++-tests: Update.
54126         * tests/test-dirent-c++.cc (readdir): Declare, missing since 2011-09-13.
54127         (rewinddir): Declare, missing since 2011-09-13.
54128         (dirfd): Declare, missing since 2010-03-08.
54130 2017-05-04  Bruno Haible  <bruno@clisp.org>
54132         argp: Fix mistake in 2017-04-23 commit.
54133         * lib/argp-help.c (__argp_failure): If GNULIB_STRERROR_R_POSIX is set,
54134         assume that strerror_r returns 'int', not 'char *'.
54136 2017-05-04  Reuben Thomas  <rrt@sc3d.org>
54138         argp: Fix typo.
54139         * lib/argp-help.c (argp_doc): Fix spelling mistake in comment.
54141 2017-05-02  Paul Eggert  <eggert@cs.ucla.edu>
54143         utimens: port to Emacs + MS-Windows
54144         Skip the new MS-Windows-specific code if Emacs.
54145         * lib/utimens.c [EMACS_CONFIGUATION]:
54146         Avoid new MS-Windows-specific code.
54147         (USE_SETFILETIME): New macro.
54148         (fdutimens): Use it.
54150 2017-05-01  Paul Eggert  <eggert@cs.ucla.edu>
54152         tzset: update doc for TZ problems on MS-Windows
54153         * doc/posix-functions/ctime.texi,  doc/posix-functions/daylight.texi:
54154         * doc/posix-functions/localtime.texi, doc/posix-functions/mktime.texi:
54155         * doc/posix-functions/strftime.texi, doc/posix-functions/timezone.texi:
54156         * doc/posix-functions/tzname.texi, doc/posix-functions/tzset.texi:
54157         * doc/posix-functions/wcsftime.texi:
54158         Mention some issues with TZ under MS-Windows.
54160 2017-05-01  Bruno Haible  <bruno@clisp.org>
54162         copy-file: Fix build error on mingw.
54163         * modules/copy-file (Depends-on): Add 'close'.
54165 2017-05-01  Bruno Haible  <bruno@clisp.org>
54167         tzset: Work around TZ problem on native Windows.
54168         * m4/tzset.m4 (gl_FUNC_TZSET): Require AC_CANONICAL_HOST. On native
54169         Windows, set REPLACE_TZSET to 1.
54170         * lib/tzset.c (tzset): On native Windows, fix TZ if necessary, and
54171         invoke '_tzset' instead of 'tzset'.
54172         * doc/posix-functions/tzset.texi: Mention the native Windows workaround.
54174         * modules/time_rz (Depends-on): Add tzset.
54175         * lib/time_rz.c (tzset): Remove fallback definition.
54176         * m4/time_rz.m4 (gl_TIME_RZ): Don't test for tzset.
54178 2017-05-01  Bruno Haible  <bruno@clisp.org>
54180         mktime: Fix dependencies.
54181         * modules/mktime (Depends-on): Add 'time'.
54183 2017-05-01  Bruno Haible  <bruno@clisp.org>
54185         New module 'localtime-buffer', split off from module 'gettimeofday'.
54186         * lib/localtime-buffer.h: New file.
54187         * lib/localtime-buffer.c: New file, extracted from lib/gettimeofday.c.
54188         * lib/time.in.h (tzset): New declaration.
54189         (localtime, gmtime): Don't test GNULIB_GETTIMEOFDAY.
54190         * lib/tzset.c: New file, extracted from lib/gettimeofday.c.
54191         * lib/gettimeofday.c: Include localtime-buffer.h. Remove code that was
54192         moved to lib/localtime-buffer.c or lib/tzset.c.
54193         * m4/localtime-buffer.m4: New file.
54194         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_TZSET,
54195         HAVE_TZSET, REPLACE_TZSET.
54196         * m4/tzset.m4 (gl_FUNC_TZSET): Move code from m4/gettimeofday.m4 to
54197         here, with modifications. Set HAVE_TZSET, REPLACE_TZSET. Invoke
54198         gl_LOCALTIME_BUFFER_NEEDED.
54199         (gl_FUNC_TZSET_CLOBBER): Don't require gl_HEADER_SYS_TIME_H; not needed
54200         since 2007-01-18.
54201         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Remove code that deals with
54202         tzset.
54203         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Require gl_LOCALTIME_BUFFER_DEFAULTS.
54204         Invoke gl_LOCALTIME_BUFFER_NEEDED instead of
54205         gl_GETTIMEOFDAY_REPLACE_LOCALTIME.
54206         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Remove macro.
54207         * modules/localtime-buffer: New file.
54208         * modules/time (Depends-on): Remove 'gettimeofday'.
54209         (Makefile.am): Substitute GNULIB_TZSET, HAVE_TZSET,
54210         REPLACE_TZSET. Don't substitute GNULIB_GETTIMEOFDAY.
54211         * modules/tzset (Description): Enable hyperlink to POSIX spec.
54212         (Files): Add lib/tzset.c.
54213         (Depends-on): Remove gettimeofday. Add localtime-buffer, time.
54214         (configure.ac): Arrange to conditionally compile lib/tzset.c. Invoke
54215         gl_TIME_MODULE_INDICATOR.
54216         * modules/gettimeofday (Depends-on): Add localtime-buffer.
54218 2017-05-01  Bruno Haible  <bruno@clisp.org>
54220         copy-file: Preserve sub-second time stamps.
54221         * lib/copy-file.c: Include stat-time.h, utimens.h instead of <utime.h>.
54222         (qcopy_file_preserving): Use 'struct timespec' and utimens() to
54223         transport the time stamps from the original file to the destination
54224         file.
54225         * m4/copy-file.m4 (gl_COPY_FILE): Don't test for utime, utimes.
54226         * modules/copy-file (Depends-on): Add stat-time, utimns instead of
54227         utime-h.
54229 2017-05-01  Bruno Haible  <bruno@clisp.org>
54231         wctype-t: Fix problems if <wchar.h> gets included after <wctype.h>.
54232         * lib/wctype.in.h: Include not only <ctype.h> but also <wchar.h>. Do so
54233         also on MSVC.
54234         Reported by Eli Zaretskii <eliz@gnu.org>.
54236 2017-05-01  Bruno Haible  <bruno@clisp.org>
54238         wchar: Fix compilation error with the original mingw.org mingw.
54239         * lib/wchar.in.h (rpl_wint_t): If <crtdefs.h> does not exist, include
54240         <stddef.h> instead.
54241         * m4/wint_t.m4 (gl_TYPE_WINT_T_PREREQ): New macro, extracted from
54242         gl_WCTYPE_H.
54243         * m4/wctype_h.m4 (gl_WCTYPE_H): Don't set HAVE_CRTDEFS_H here; require
54244         gl_TYPE_WINT_T_PREREQ instead.
54245         * m4/wchar_h.m4 (gl_WCHAR_H): Require gl_TYPE_WINT_T_PREREQ.
54246         * modules/wchar (Makefile.am): Substitute HAVE_CRTDEFS_H.
54247         Reported by Eli Zaretskii <eliz@gnu.org>.
54249 2017-04-30  Bruno Haible  <bruno@clisp.org>
54251         utimecmp: Add support for native Windows.
54252         * lib/utimecmp.c (SYSCALL_RESOLUTION): Set to 100 on native Windows.
54254 2017-04-30  Bruno Haible  <bruno@clisp.org>
54256         utimens: Add support for native Windows.
54257         * lib/utimens.c: Include <windows.h>, msvc-nothrow.h.
54258         (fdutimens): Provide a native Windows implementation, like utime.c with
54259         added tv_nsec support.
54260         * modules/utimens (Depends-on): Add msvc-nothrow, utime.
54261         Suggested by Tim Rühsen <tim.ruehsen@gmx.de>.
54263 2017-04-30  Bruno Haible  <bruno@clisp.org>
54265         wcsftime: New module.
54266         * lib/wchar.in.h (wcsftime): New declaration.
54267         * lib/wcsftime.c: New file.
54268         * m4/wcsftime.m4: New file.
54269         * m4/wchar_h.m4 (gl_WCHAR_H): Test for wcsftime declaration.
54270         (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_WCSFTIME,
54271         HAVE_WCSFTIME, REPLACE_WCSFTIME.
54272         * modules/wchar (Makefile.am): Substitute GNULIB_WCSFTIME,
54273         HAVE_WCSFTIME, REPLACE_WCSFTIME.
54274         * modules/wcsftime: New file.
54275         * doc/posix-functions/wcsftime.texi: Mention the new module.
54277 2017-04-30  Bruno Haible  <bruno@clisp.org>
54279         strftime-fixes: New module.
54280         * lib/time.in.h (strftime): New declaration.
54281         * lib/strftime-fixes.c: New file.
54282         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Inline gl_FUNC_STRFTIME macro.
54283         (gl_FUNC_STRFTIME): Remove macro.
54284         * m4/strftime-fixes.m4: New file.
54285         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_STRFTIME,
54286         REPLACE_STRFTIME.
54287         * modules/time (Makefile.am): Substitute GNULIB_STRFTIME,
54288         REPLACE_STRFTIME.
54289         * modules/strftime-fixes: New file.
54290         * doc/posix-functions/strftime.texi: Mention the new module.
54292 2017-04-30  Bruno Haible  <bruno@clisp.org>
54294         mktime: Work around TZ problem on native Windows.
54295         * lib/mktime.c: Add #ifs to make the algorithmic workaround independent
54296         from the native Windows workaround.
54297         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): New macro, extracted from
54298         gl_FUNC_MKTIME. If guessing, set gl_cv_func_working_mktime to
54299         'guessing no'.
54300         (gl_FUNC_MKTIME): Require it. Require AC_CANONICAL_HOST.
54301         Set REPLACE_MKTIME to 1 on native Windows. Define NEED_MKTIME_WORKING,
54302         NEED_MKTIME_WINDOWS.
54303         (gl_FUNC_MKTIME_INTERNAL): Require gl_FUNC_MKTIME_WORKS, not
54304         gl_FUNC_MKTIME. Set WANT_MKTIME_INTERNAL, not REPLACE_MKTIME. Define
54305         NEED_MKTIME_INTERNAL.
54306         * m4/timegm.m4 (gl_FUNC_TIMEGM): Require gl_FUNC_MKTIME_WORKS, not
54307         gl_FUNC_MKTIME. Cope with 'guessing yes' value.
54308         * modules/mktime-internal (configure.ac): Test WANT_MKTIME_INTERNAL,
54309         not REPLACE_MKTIME.
54310         * doc/posix-functions/mktime.texi: Mention the native Windows
54311         workaround.
54313 2017-04-30  Bruno Haible  <bruno@clisp.org>
54315         localtime: New module.
54316         * lib/time.in.h (localtime): Declare also if requested by module
54317         'localtime'.
54318         * lib/localtime.c: New file.
54319         * m4/localtime.m4: New file.
54320         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_LOCALTIME.
54321         * modules/time (Makefile.am): Substitute GNULIB_LOCALTIME.
54322         * modules/localtime: New file.
54323         * doc/posix-functions/localtime.texi: Mention the new module.
54325 2017-04-30  Bruno Haible  <bruno@clisp.org>
54327         ctime: New module.
54328         * lib/time.in.h (ctime): New declaration.
54329         * lib/ctime.c: New file.
54330         * m4/ctime.m4: New file.
54331         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_CTIME,
54332         REPLACE_CTIME.
54333         * modules/time (Makefile.am): Substitute GNULIB_CTIME, REPLACE_CTIME.
54334         * modules/ctime: New file.
54335         * doc/posix-functions/ctime.texi: Mention the new module.
54337 2017-04-30  Bruno Haible  <bruno@clisp.org>
54339         gettimeofday: Provide higher resolution on native Windows.
54340         * lib/gettimeofday.c: Don't include <sys/timeb.h>.
54341         (GetSystemTimePreciseAsFileTimeFuncType): New variable.
54342         (initialize): Initialize it.
54343         (gettimeofday) [WINDOWS_NATIVE]: Use it, and convert from FILETIME to
54344         'struct timeval'. Don't use _ftime().
54345         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): Don't test for
54346         <sys/timeb.h> and _ftime.
54348 2017-04-30  Bruno Haible  <bruno@clisp.org>
54350         Document the problem with the Cygwin environment variable TZ.
54351         * doc/posix-functions/tzset.texi: Add note about TZ.
54352         * doc/posix-functions/ctime.texi: Likewise.
54353         * doc/posix-functions/localtime.texi: Likewise.
54354         * doc/posix-functions/mktime.texi: Likewise.
54355         * doc/posix-functions/strftime.texi: Likewise.
54356         * doc/posix-functions/wcsftime.texi: Likewise.
54357         * doc/pastposix-functions/ftime.texi: Likewise.
54359 2017-04-30  Bruno Haible  <bruno@clisp.org>
54361         utime-tests: New module.
54362         * tests/test-utime.c: New file, based on tests/test-utimens.h.
54363         * tests/test-utimens-common.h: Include <sys/stat.h>.
54364         * modules/utime-tests: New file.
54366 2017-04-29  Bruno Haible  <bruno@clisp.org>
54368         utime: New module.
54369         * lib/utime.in.h: Add comment for snippets.
54370         (utime): New declaration.
54371         * lib/utime.c: New file.
54372         * m4/utime.m4: New file.
54373         * m4/utime_h.m4 (gl_UTIME_H): Test for utime declaration.
54374         (gl_UTIME_H_DEFAULTS): Initialize GNULIB_UTIME, HAVE_UTIME,
54375         REPLACE_UTIME.
54376         * modules/utime-h (Depends-on): Add snippets.
54377         (Makefile.am): Substitute GNULIB_UTIME, HAVE_UTIME, REPLACE_UTIME.
54378         Insert snippets.
54379         * modules/utime: New file.
54380         * doc/posix-functions/utime.texi: Mention the new module.
54382 2017-04-29  Bruno Haible  <bruno@clisp.org>
54384         utime-h: Modernize handling of 'struct utimbuf'.
54385         * lib/utime.in.h: Include next <utime.h> if it exists.
54386         (utimbuf): Define to _utimbuf on native Windows.
54387         * m4/utime_h.m4 (gl_UTIME_H): Check for prerequisites of include_next.
54388         Set UTIME_H on native Windows.
54389         (gl_UTIME_MODULE_INDICATOR, gl_HEADER_UTIME_H_DEFAULTS): New macros.
54390         * modules/utime-h (Depends-on): Add include_next.
54391         (Makefile.am): Substitute also HAVE_UTIME_H, INCLUDE_NEXT,
54392         PRAGMA_SYSTEM_HEADER, PRAGMA_COLUMNS, NEXT_UTIME_H.
54394         * lib/utimens.c (utimbuf): Remove fallback definition.
54395         * m4/utimens.m4 (gl_UTIMENS): Don't require
54396         gl_CHECK_TYPE_STRUCT_UTIMBUF.
54397         * m4/utimbuf.m4: Remove file.
54398         * modules/utimens (Files): Remove m4/utimbuf.m4.
54400 2017-04-29  Bruno Haible  <bruno@clisp.org>
54402         Make use of module 'utime-h'.
54403         * modules/copy-file (Depends-on): Add utime-h.
54404         * lib/copy-file.c: Assume that <utime.h> exists.
54405         * m4/copy-file.m4 (gl_COPY_FILE): Don't test for <utime.h>.
54407         * modules/utimens (Depends-on): Add utime-h.
54408         * lib/utimens.c: Assume that <utime.h> exists.
54410 2017-04-29  Bruno Haible  <bruno@clisp.org>
54412         utime-h: New module.
54413         * m4/utime_h.m4: New file.
54414         * lib/utime.in.h: New file.
54415         * modules/utime-h: New file.
54416         * doc/posix-headers/utime.texi: Mention the new module.
54418         * tests/test-utime-h.c: New file.
54419         * modules/utime-h-tests: New file.
54421 2017-04-30  Bruno Haible  <bruno@clisp.org>
54423         Fix a few typos.
54424         * m4/fstat.m4 (gl_FUNC_FSTAT): Require AC_CANONICAL_HOST.
54425         * m4/stat.m4 (gl_FUNC_STAT): Fix comment.
54426         * doc/posix-functions/fstat.texi: Fix a plural typo.
54427         * doc/posix-functions/stat.texi: Likewise.
54428         * m4/include_next.m4: Update comments.
54430 2017-04-29  Bruno Haible  <bruno@clisp.org>
54432         error: Fix mistake in 2017-04-23 commit.
54433         * lib/error.c (print_errno_message): If GNULIB_STRERROR_R_POSIX is set,
54434         assume that strerror_r returns 'int', not 'char *'.
54436 2017-04-29  Bruno Haible  <bruno@clisp.org>
54438         stat: Fix time_t values and other problems on native Windows platforms.
54439         * doc/posix-functions/stat.texi: Mention the problem with the Microsoft
54440         implementations of stat().
54441         * lib/stat.c: Include filename.h instead of dosname.h. Include
54442         malloca.h, stat-w32.h.
54443         (is_unc_root): New function.
54444         (rpl_stat): New implementation for native Windows. Remove
54445         REPLACE_FUNC_STAT_DIR code.
54446         * m4/stat.m4 (gl_FUNC_STAT): On native Windows, set REPLACE_STAT always.
54447         Don't define REPLACE_FUNC_STAT_DIR.
54448         (gl_PREREQ_STAT): Require gl_HEADER_SYS_STAT_H.
54449         * modules/stat (Files): Add lib/stat-w32.h, lib/stat-w32.c.
54450         (Depends-on): Remove dosname. Add filename, malloca.
54451         (configure.ac): Also compile lib/stat-w32.c.
54453 2017-04-29  Bruno Haible  <bruno@clisp.org>
54455         fstat: Fix time_t values on native Windows platforms.
54456         * doc/posix-functions/fstat.texi: Mention the problem with st_*time.
54457         * lib/stat-w32.h: New file.
54458         * lib/stat-w32.c: New file.
54459         * lib/fstat.c: Don't include msvc-inval.h. Include msvc-nothrow.h,
54460         stat-w32.h instead.
54461         (fstat_nothrow): Remove function.
54462         (rpl_fstat): Implement by means of _gl_fstat_by_handle.
54463         * m4/fstat.m4 (gl_FUNC_FSTAT): On native Windows, set REPLACE_FSTAT
54464         always.
54465         (gl_PREREQ_FSTAT): Require gl_HEADER_SYS_STAT_H.
54466         * modules/fstat (Files): Add lib/stat-w32.h, lib/stat-w32.c.
54467         (Depends-on): Remove msvc-inval. Add pathmax, msvc-nothrow.
54468         (configure.ac): Also compile lib/stat-w32.c.
54470 2017-04-29  Paul Eggert  <eggert@cs.ucla.edu>
54472         getopt: port to Solaris 10 with circa-1997 glibc getopt.h
54473         Problem reported by Assaf Gordon and Gavin Smith in:
54474         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00157.html
54475         * lib/getopt-pfx-ext.h (_getopt_internal) [__GETOPT_PREFIX]:
54476         #define this, too.
54478 2017-04-29  Bruno Haible  <bruno@clisp.org>
54480         strerror_r-posix: Fixes for MSVC 14.
54481         * lib/strerror_r.c: Include <stdarg.h>.
54482         (strerror_r): Provide error messages for errno values 100...140.
54483         * doc/posix-functions/strerror_r.texi: Mention the MSVC 14 problem.
54485 2017-04-28  Bruno Haible  <bruno@clisp.org>
54487         noreturn: New module.
54488         * lib/noreturn.h: New file.
54489         * modules/noreturn: New file.
54490         * tests/test-noreturn.c: New file.
54491         * modules/noreturn-tests: New file.
54492         * tests/test-noreturn-c++.cc: New file.
54493         * modules/noreturn-c++-tests: New file.
54495 2017-04-27  Bruno Haible  <bruno@clisp.org>
54497         wctype-h: Fix compilation error with the original mingw.org mingw.
54498         * m4/wctype_h.m4 (gl_WCTYPE_H): Test for <crtdefs.h>. Set
54499         HAVE_CRTDEFS_H.
54500         * modules/wctype-h (Makefile.am): Substitute HAVE_CRTDEFS_H.
54501         * lib/wctype.in.h (rpl_wint_t): If <crtdefs.h> does not exist, include
54502         <stddef.h> instead.
54503         Reported and proposed by Eli Zaretskii <eliz@gnu.org>.
54505 2017-04-26  Pádraig Brady  <P@draigBrady.com>
54507         nap.h: Fix compilation on non windows platforms
54508         * tests/nap.h: Move misplaced endif.
54510 2017-04-26  Pádraig Brady  <P@draigBrady.com>
54511         and Paul Eggert  <eggert@cs.ucla.edu>
54513         time_rz: fix heap buffer overflow vulnerability
54514         Reported and analyzed at https://bugzilla.redhat.com/CVE-2017-7476
54515         * lib/time_rz.c (save_abbr): Rearrange the calculation determining
54516         whether there is enough buffer space available, thus avoiding
54517         the problematic promotion of signed to unsigned causing an invalid
54518         comparison when zone_copy is more than ABBR_SIZE_MIN bytes beyond
54519         the start of the buffer.
54520         * tests/test-parse-datetime.c (main): Add a test case written by
54521         Paul Eggert, which overwrites enough of the heap so that
54522         standard glibc will fail with "free(): invalid pointer"
54523         without the patch applied.
54525 2017-04-26  Paul Eggert  <eggert@cs.ucla.edu>
54527         xalloc: add missing integer overflow check
54528         * lib/xalloc.h (x2nrealloc): Also check for multiplication
54529         overflow when P is null.
54531 2017-04-25  Paul Eggert  <eggert@cs.ucla.edu>
54533         parse-datetime: make it standalone
54534         * lib/parse-datetime.y: Include <stdarg.h>, for va_start etc.
54535         (_GL_ATTRIBUTE_FORMAT): New macro.
54536         These are needed to get './gnulib-tool --test parse-datetime' to work.
54538 2017-04-23  Bruno Haible  <bruno@clisp.org>
54540         nap.h: Port to native Windows.
54541         * tests/nap.h (nap_get_stat): Renamed from get_stat. Remove argument fd;
54542         use nap_fd instead. On native Windows, close and reopen nap_fd.
54543         (nap_works): Don't compare the ctimes, because on native Windows, these
54544         are the creation times.
54545         (nap): Update.
54547 2017-04-23  Bruno Haible  <bruno@clisp.org>
54549         nap.h: Fix logic.
54550         * tests/nap.h (nap): Avoid signed integer overflow in loop.
54552 2017-04-23  Bruno Haible  <bruno@clisp.org>
54554         Fix conflict between strerror_r-posix module and AC_FUNC_STRERROR_R.
54555         * modules/strerror_r-posix (configure.ac): Invoke gl_MODULE_INDICATOR.
54556         * lib/error.c: Test GNULIB_STRERROR_R_POSIX before testing
54557         HAVE_DECL_STRERROR_R, HAVE_STRERROR_R, or STRERROR_R_CHAR_P.
54558         * lib/argp-help.c (__argp_failure): Likewise.
54560 2017-04-23  Bruno Haible  <bruno@clisp.org>
54562         strerror_r-posix: Revert commits from 2016-10-16,2016-11-04,2016-11-14.
54563         * m4/strerror_r.m4: Revert changes since 2016-10-16.
54564         * lib/strerror_r.c: Likewise.
54566 2017-04-23  Paul Eggert  <eggert@cs.ucla.edu>
54568         Target a C99 subset, not a C89 subset
54569         For many years Gnulib has targeted C89 and has resisted using C99
54570         features, as some Gnulib-using programs still wanted to target
54571         C89.  As this no longer seems to be the case, relax the porting
54572         requirements to allow some C99 features.  This is merely a change
54573         to the documentation, to give other Gnulib developers a chance to
54574         weigh in on the topic.
54575         * doc/extern-inline.texi (extern inline):
54576         * doc/gnulib-readme.texi (Portability guidelines):
54577         * doc/gnulib-tool.texi (Initial import):
54578         * doc/gnulib.texi (Header files):
54579         Modernize to talk about C99 and C11 instead of C89 and C99.
54580         * doc/gnulib-readme.texi (Portability guidelines):
54581         Now a section, not merely a subsection, so that it
54582         can be split up.  Modernize a bit.
54583         (C language versions, C99 features assumed)
54584         (C99 features avoided):
54585         New sections.
54587 2017-04-23  Bruno Haible  <bruno@clisp.org>
54589         doc: New section "Modules that modify the way other modules work".
54590         * doc/gnulib.texi (Modules that modify the way other modules work): New
54591         section.
54593 2017-04-23  Bruno Haible  <bruno@clisp.org>
54595         stat-time: Update comments.
54596         * lib/stat-time.h: Fix reference regarding st_ctime on Windows.
54597         * tests/test-utimens-common.h: Add reference regarding st_ctime on
54598         Windows.
54600 2017-04-01  Bruno Haible  <bruno@clisp.org>
54602         glob: Fix more memory leaks.
54603         * lib/glob.c (glob): Free allocated memory before returning.
54604         Reported by Coverity via Tim Rühsen.
54606 2017-04-22  Paul Eggert  <eggert@cs.ucla.edu>
54608         poll: improve fast check for out-of-range NFD
54609         * lib/poll.c: Do not include intprops.h.
54610         (poll): Compare NFD to INT_MAX, not to TYPE_MAXIMUM (nfds_t) / 2.
54611         * modules/poll (Depends-on): Remove intprops.
54613         ftoastr: cite a newer paper
54614         * lib/ftoastr.c (FTOASTR): In comment, cite Andrysco et al. 2016
54615         instead of Loitsch 2010.
54617 2017-04-22  Bruno Haible  <bruno@clisp.org>
54619         poll: Enable argument check also in the Windows implementation.
54620         * lib/poll.c (poll) [WINDOWS_NATIVE]: Check value of nfd correctly.
54621         Reported by Paul Eggert.
54623 2017-04-22  Bruno Haible  <bruno@clisp.org>
54625         getlogin_r: Work around bug in Mac OS X 10.12.
54626         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Test also against the Mac OS X
54627         bug.
54628         * lib/getlogin_r.c (getlogin_r): When getlogin_r returns a string of the
54629         given size minus 1, call getlogin_r a second time, on a larger buffer.
54630         * modules/getlogin_r (Depends-on): Add malloca.
54631         * doc/posix-functions/getlogin_r.texi: Mention the Mac OS X bug.
54633 2017-04-22  Paul Eggert  <eggert@cs.ucla.edu>
54635         parse-datetime: fix %z and prefer signed int
54636         %z problem reported by Pádraig Brady in:
54637         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00103.html
54638         While fixing it, I decided to prefer signed ints to size_t, as
54639         they are less error-prone (e.g., ubsan catches overflow).
54640         * lib/parse-datetime.y (textint, parser_control, lookup_word, yylex)
54641         (parse_datetime2): Prefer ptrdiff_t to size_t for sizes and object
54642         counts, since signed integers make for better debugging.
54643         (date): Don’t assume %z works in printf formats.
54644         (debug_strfdatetime, debug_strfdate, debug_strftime): Use int for
54645         sizes of buffers known to be small, e.g., because we’re using snprintf.
54646         (parse_datetime2): Simplify call to debug_mktime_not_ok.
54648 2017-04-22  Bruno Haible  <bruno@clisp.org>
54650         *printf: Work around rounding bug on Mac OS X.
54651         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Test for Mac OS X 10.12 bug.
54652         * doc/posix-functions/*printf.texi: Mention the rounding bugs of
54653         Mac OS X and FreeBSD.
54654         * doc/glibc-functions/*printf.texi: Likewise.
54656 2017-04-22  Bruno Haible  <bruno@clisp.org>
54658         vasnprintf tests: Avoid warnings.
54659         * tests/test-vasnprintf-posix3.c (test_function, my_asnprintf,
54660         test_vasnprintf, test_asnprintf): Don't define if there's nothing to
54661         test.
54663 2017-04-22  Bruno Haible  <bruno@clisp.org>
54665         sys_file tests: Avoid warning.
54666         * tests/test-sys_file.c (main): Add a default clause to the switch
54667         statement.
54669 2017-04-22  Bruno Haible  <bruno@clisp.org>
54671         sethostname: Update doc.
54672         * doc/glibc-functions/sethostname.texi: Mention differing prototype on
54673         Mac OS X.
54675 2017-04-22  Bruno Haible  <bruno@clisp.org>
54677         quotearg tests: Avoid warnings.
54678         * tests/test-quotearg.c: Don't include test-quotearg.h if ENABLE_NLS is
54679         false.
54681 2017-04-22  Bruno Haible  <bruno@clisp.org>
54683         poll: Enable argument check.
54684         * lib/poll.c: Include intprops.h.
54685         (poll): Check value of nfd correctly.
54686         * modules/poll (Depends-on): Add intprops.
54688 2017-04-22  Bruno Haible  <bruno@clisp.org>
54690         get-rusage-data: Avoid warnings on Mac OS X.
54691         * lib/get-rusage-data.c: On Mac OS X, don't define
54692         get_rusage_data_via_setrlimit nor get_rusage_data_via_iterator.
54693         (get_rusage_data) [Mac OS X]: Just return 0.
54695 2017-04-22  Bruno Haible  <bruno@clisp.org>
54697         xbinary-io: Fix build error.
54698         * modules/xbinary-io (Depends-on): Add gettext-h.
54699         * lib/xbinary-io.c: Include gettext.h and define _().
54700         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
54701         <https://lists.gnu.org/r/bug-gnulib/2017-04/msg00089.html>.
54703 2017-04-22  Paul Eggert  <eggert@cs.ucla.edu>
54705         parse-datetime: overflow and debug cleanups
54706         This long patch was triggered by this bug report from Ruediger Meier:
54707         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00028.html
54708         I fixed the bug he noted, then found some others nearby, and then
54709         still others.  Oh my goodness, there were a lot of bugs.  I cleaned
54710         up some of the code to follow GNU standards while I was at it.
54711         * lib/parse-datetime.y (ISDIGIT): Remove; all callers changed to
54712         use c_isdigit.
54713         (EPOCH_YEAR): Remove; unused.
54714         (TM_YEAR_BASE): Now an enum rather than a macro.
54715         (HOUR, debug_strfdatetime): Multiply hour by 3600, not 60, to get
54716         time zone offset, since timezones now are in terms of seconds and
54717         not minutes.
54718         (long_time_t): Remove.  All uses replaced by time_t or intmax_t as
54719         appropriate.  Verify that intmax_t is wide enough.
54720         (time_overflow, time_zone_str): New functions, used to deal
54721         more reliably with overflow.
54722         (dbg_printf): Add printf attribute, to help catch integer width errors.
54723         (textint, relative_time, parser_control, time_zone_hhmm, set_hhmmss)
54724         (%union, to_hour, yylex, parse_datetime2):
54725         Use intmax_t instead of long int and/or long_time_t.
54726         All uses changed.
54727         (DBGBUFSIZE): Move earlier.
54728         (relative_time, set_hhmmss, parser_control):
54729         Just use int for nanoseconds and for time zones; that’s wide enough.
54730         (parser_control): Use bool for members like year_seen that can
54731         be booleans instead of counters.  All uses changed.
54732         Remove debug_default_input_timezone; no longer needed.
54733         All uses removed.
54734         (apply_relative_time): Return a bool overflow flag.
54735         All uses changed to check for overflow.
54736         (apply_relative_time, zone, date, relunit, relunit_snumber)
54737         (signed_seconds, unsigned_seconds, yylex, parse_datetime2):
54738         Check for integer overflow portably.
54739         (str_days): Use just int for N, as it’s wide enough.
54740         Prefer 2D char arrays to arrays of char * when it looks like
54741         2D is a win on typical platforms.
54742         Prefer snprintf to strncpy/strncat, for simplicity;
54743         all buffers are smaller than INT_MAX so this is safe.
54744         (TIME_ZONE_BUFSiZE, TM_YEAR_BUFSIZE): New constants.
54745         (debug_print_current_time): Don’t assume tv_nsec is of type long,
54746         as this is not true on x32.  Output "." before any nanoseconds.
54747         (debug_print_current_time, parse_datetime2):
54748         Output local zones using a more-consistent format.
54749         (debug_print_current_time, date, parse_datetime2):
54750         (main) [TEST]:
54751         Don’t assume time_t is the same width as long.
54752         (print_rel_part): New function, replacing ...
54753         (PRINT_REL_PART): ... this macro, which was removed.  All uses changed.
54754         (debug_print_relative_time): Use bool for boolean.
54755         (local_zone): dsts_seen now counts only tDST instances.
54756         (date): Fix printf of size_t to use %z.  Do not assume numeric
54757         tokens have negative values merely because the context suggests
54758         a syntax with "-" separating tokens.
54759         (time_zone_hhmm): Return bool success indicator, which checks for
54760         overflow.  Store result into PC->time_zone instead.  All callers
54761         changed.
54762         (tm_year_str): New function.  Return a bool success indicator and
54763         store the result into a buffer.  All callers changed.  Output the
54764         numerically correct string even if adding 1900 to the year would
54765         overflow.
54766         (to_tm_year): New function, replacing the old to_year.  All
54767         callers changed.
54768         (tm_diff): Sync with glibc.
54769         (lookup_word): Use to_uchar instead of doing it by hand.
54770         (TZBUFSIZE): Now local to the only function that needs it.
54771         (debug_strfdatetime): Simplify now that time zones are int seconds.
54772         (debug_strfdate): Work even if tm_year + 1900 would overflow.
54773         (get_effective_timezone): Remove.  All uses removed.
54774         (parse_datetime2): Use fprintf in pieces instead of snprintfing
54775         to a fixed-size buffer.  Don’t assume that gmtime succeeds iff
54776         localtime succeeds.  Use tm_gmtoff if available.  Simplify how
54777         ‘goto fail;’ works in conjunction with the ‘ok’ flag.
54778         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Don’t define
54779         TIME_T_FITS_IN_LONG_INT, as it is no longer needed.
54780         * modules/parse-datetime (Depends-on): Add inttypes.
54782 2017-04-21  Bruno Haible  <bruno@clisp.org>
54784         gettext-h: Avoid -Wundef warning.
54785         * lib/gettext.h: Test the value of ENABLE_NLS only if it is defined.
54786         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
54787         <https://lists.gnu.org/r/bug-gnulib/2017-04/msg00022.html>.
54789 2017-04-05  Tim Rühsen  <tim.ruehsen@gmx.de>
54791         error: Avoid "function declaration isn't a prototype" warning.
54792         * lib/error.c (strerror_r): Turn K&R C prototype to an ANSI C prototype.
54794 2017-04-21  Bruno Haible  <bruno@clisp.org>
54796         vasnprintf: Fix for MSVC 14.
54797         * lib/vasnprintf.c (USE_MSVC__SNPRINTF): New macro.
54798         Everywhere, use !HAVE_SNPRINTF_RETVAL_C99 || USE_MSVC__SNPRINTF instead
54799         of !HAVE_SNPRINTF_RETVAL_C99.
54801 2017-04-21  Bruno Haible  <bruno@clisp.org>
54803         mbrtowc tests: Fix test failures on MSVC 14.
54804         * tests/test-mbrtowc-w32.c (test_one_locale): Accept MSVC's conversion
54805         behaviour for invalid input.
54807 2017-04-21  Bruno Haible  <bruno@clisp.org>
54809         mbsinit: Fix for MSVC 14.
54810         * lib/mbsinit.c (mbsinit): If GNULIB_defined_mbstate_t, provide an
54811         implementation that is in sync with mbrtowc.c. On other platforms, use
54812         an adequate ad-hoc implementation.
54814 2017-04-21  Bruno Haible  <bruno@clisp.org>
54816         Fix test-mbrtowc5.sh failure on native Windows.
54817         * lib/setlocale.c (setlocale_unixlike): Accept "POSIX" as an alias for
54818         "C".
54820 2017-04-21  Bruno Haible  <bruno@clisp.org>
54822         Avoid accidental use of native Windows APIs on Cygwin.
54823         * lib/getaddrinfo.c (WINDOWS_NATIVE): Don't define on Cygwin.
54824         * lib/localcharset.c (WINDOWS_NATIVE): Likewise.
54825         * lib/localename.c (WINDOWS_NATIVE): Likewise.
54827 2017-04-20  Bruno Haible  <bruno@clisp.org>
54829         Remove red warnings from the generated MODULES.html.
54830         * modules/fcntl (Description): Disambiguate function references.
54831         * modules/getcwd-lgpl (Description): Likewise.
54832         * modules/hostent (Description): Likewise.
54833         * modules/servent (Description): Likewise.
54834         * modules/tempname (Description): Likewise.
54836 2017-04-20  Bruno Haible  <bruno@clisp.org>
54838         verify tests: Fix spurious failure with parallel make.
54839         * gnulib-tool (func_emit_tests_Makefile_am): Emit initialization of
54840         EXTRA_PROGRAMS.
54841         * tests/test-verify.sh: Build test-verify-try.o, not test-verify.o.
54842         * tests/test-verify-try.c: New file.
54843         * modules/verify-tests (Files): Add it.
54844         (EXTRA_PROGRAMS): Add test-verify-try.
54845         (MOSTLYCLEANFILES): Update accordingly.
54846         Reported by Adam James Stewart <ajstewart@anl.gov>.
54848 2017-04-18  Bruno Haible  <bruno@clisp.org>
54850         vma-iter: Fix compilation error on Solaris 7.
54851         * lib/vma-iter.c (vma_iterate): Treat missing MAP_ANONYMOUS on Solaris
54852         like on IRIX, OSF/1.
54853         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
54855 2017-04-18  Bruno Haible  <bruno@clisp.org>
54857         vma-iter: Fix conflict with module 'largefile' on 32-bit Solaris 9.
54858         * modules/vma-iter (configure.ac): Test whether <sys/procfs.h> can be
54859         included.
54860         * lib/vma-iter.c: On Solaris, test HAVE_SYS_PROCFS_H before including
54861         <sys/procfs.h>.
54862         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Don't define on Solaris when
54863         <sys/procfs.h> cannot be included.
54864         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
54866 2017-04-18  Bruno Haible  <bruno@clisp.org>
54868         getopt-gnu: Add comments.
54869         * m4/getopt.m4 (gl_FUNC_GETOPT_GNU): Add comments.
54870         * modules/getopt-gnu (configure.ac): Likewise.
54872 2017-04-16  Paul Eggert  <eggert@cs.ucla.edu>
54874         regex: port better to Solaris 10
54875         Solaris 10 <locale.h> includes <libintl.h>, which #defines
54876         gettext, and this causes a double #define.
54877         Problem reported by Gavin Smith in:
54878         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00056.html
54879         * lib/regex_internal.h (gettext): #undef before #defining.
54881 2017-04-15  Paul Eggert  <eggert@Penguin.CS.UCLA.EDU>
54883         intprops: improve comments
54884         * lib/intprops.h: Improve and shorten commentary.
54885         For the record, if we ever run into a pedantic compiler that
54886         behaves differently from GCC when converting an out-of-range value
54887         to a signed integer, we can work around the problem with something
54888         like the following code, where UCT is the signed counterpart of T
54889         (UCT is sometimes narrower than UT) and all callers are changed
54890         accordingly:
54891         #if __SUNPRO_C <= 0x5120
54892         # define _GL_INT_OP_WRAPV_VIA_UNSIGNED(a, b, op, uct, ut, t) \
54893            ((t) ((ut) (a) op (ut) (b)))
54894         #else
54895         # define _GL_INT_OP_WRAPV_VIA_UNSIGNED(a, b, op, uct, ut, t) \
54896            (TYPE_MINIMUM (t) <= (uct) ((ut) (a) op (ut) (b)) \
54897             ? ((t) (uct) (((ut) (a) op (ut) (b)) - TYPE_MINIMUM (t)) \
54898                + TYPE_MINIMUM (t)) \
54899             : (t) (uct) ((ut) (a) op (ut) (b)))
54900         #endif
54902 2017-04-14  Paul Eggert  <eggert@Penguin.CS.UCLA.EDU>
54904         intprops: try to avoid tickling similar bugs
54905         * lib/intprops.h (_GL_INT_OP_CALC): Document that UT no longer
54906         needs to be the same width as T; it can be wider.
54907         Change callers so that UT is at least as wide as unsigned int,
54908         as I suspect that this is less likely to run into compiler bugs.
54910         intprops: port to Oracle Studio 12.3 x86
54911         Problem reported by Gavin Smith in:
54912         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00049.html
54913         * lib/intprops.h (_GL_INT_OP_WRAPV_VIA_UNSIGNED):
54914         Convert unsigned to signed via the usual rather than the standard way,
54915         to avoid a compiler bug in Oracle Studio 12.3 x86.
54917 2017-04-08  Paul Eggert  <eggert@cs.ucla.edu>
54919         getopt: prefer - to _ in new file names
54920         * lib/getopt-cdefs.in.h: Rename from lib/getopt_cdefs.in.h.
54921         * lib/getopt-core.h: Rename from lib/getopt_core.h.
54922         * lib/getopt-ext.h: Rename from lib/getopt_ext.h.
54923         * lib/getopt-pfx-core.h: Rename from lib/getopt_pfx_core.h.
54924         * lib/getopt-pfx-ext.h: Rename from lib/getopt_pfx_ext.h.
54925         All uses changed.
54927         getopt: port recent getopt changes to macOS
54928         Problem reported by Harald Maier (Bug#26398).
54929         The macOS C compiler uses __nonnull for its own purposes and that
54930         clashes with glibc's __nonnull.
54931         * lib/getopt.in.h: Add comment for _GL_ARG_NONNULL snippet.
54932         * lib/getopt_cdefs.in.h (__nonnull): Remove.
54933         * lib/getopt_core.h (getopt):
54934         * lib/getopt_ext.h (getopt_long, getopt_long_only):
54935         Use _GL_ARG_NONNULL, not __nonnull.
54936         * lib/unistd.in.h: Move snippet hooks to before where the getopt
54937         .h files are included, so that _GL_ARG_NONNULL is defined in time.
54938         * modules/getopt-posix (Depends-on): Add snippet/arg-nonnull.
54939         (getopt.h): Interpolate _GL_ARG_NONNULL snippet.
54941 2017-04-06  Paul Eggert  <eggert@cs.ucla.edu>
54943         getopt-gnu: omit some duplicate code
54944         * m4/getopt.m4 (gl_FUNC_GETOPT_GNU): Don’t require
54945         gl_FUNC_GETOPT_POSIX, as the configure.ac code generated by
54946         gnulib-tool already does this.
54947         * modules/getopt-gnu (configure.ac): Omit code duplicated from
54948         getopt-posix, which we depend on.
54950         getopt-posix: use angle-bracket include
54951         * lib/getopt1.c: Include <config.h>, not "config.h".
54953 2017-04-06  Zack Weinberg  <zackw@panix.com>
54955         getopt: annotate files with relationship to glibc
54957         As the final act in this patchset, adjust the message at the top of
54958         each file to indicate which files are synced with glibc.  (This has
54959         already been done for most of the headers.)
54961         * lib/getopt.c, lib/getopt1.c, lib/getopt_int.h:
54962         Mention in top-of-file boilerplate that these files are shared
54963         between glibc and gnulib.
54966         getopt: split up getopt.in.h and eliminate __need_getopt
54968         Over in glibc, all of the __need macros are being phased out in favor
54969         of small headers that declare only the necessary components, as this
54970         is much simpler and less prone to bugs.  As getopt is shared with
54971         glibc, gnulib needs to do the same for __need_getopt.
54973         __need_getopt is misnamed; what it really means is "we want only the
54974         getopt features specified in POSIX, not the GNU extensions".  glibc
54975         placed the "meat" of getopt.h into getopt_core.h and getopt_ext.h;
54976         these files can be shared verbatim with gnulib.  The portability
54977         wrapper, on the other hand, they have renounced altogether; glibc's
54978         getopt.h will no longer be shared with gnulib at all.  In exchange,
54979         certain glibc-specific quirks (having to do with __posix_getopt) no
54980         longer need appear in gnulib's headers at all.
54982         This patch merges getopt_core.h and getopt_ext.h from glibc, and
54983         splits up the current gnulib-side portability wrapper into three
54984         additional headers: getopt_pfx_core.h and getopt_pfx_ext.h handle
54985         __GETOPT_PREFIX for their respective headers, getopt_cdefs.in.h
54986         handles things like __BEGIN_DECLS and __THROW, and getopt.in.h and
54987         unistd.in.h just use them.  All new files are clearly marked with
54988         whether they are shared with glibc.
54990         * lib/getopt.in.h: Eliminate __need_getopt.  Break up into ...
54991         * lib/getopt_core.h, lib/getopt_ext.h: ... these new files shared
54992         with glibc, and ...
54993         * lib/getopt_cdefs.in.h, lib/getopt_pfx_core.h
54994         * lib/getopt_pfx_ext.h: ... these new files not shared with glibc.
54995         * lib/unistd.in.h: Include getopt_cdefs.h and getopt_pfx_core.h,
54996         instead of defining __need_getopt and including the full getopt.h.
54998         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): Check for sys/cdefs.h.
54999         Define substitution variables GETOPT_CDEFS_H and HAVE_SYS_CDEFS_H.
55000         * modules/getopt-posix (Files): Add new headers and sort list.
55001         (Depends-on): No longer need snippet/arg-nonnull.
55002         (Makefile.am): Generate getopt_cdefs.h.
55005         getopt: better handling of ambiguous options
55007         glibc's getopt uses alloca to construct a linked list of possibilities
55008         for an "ambiguous" long option.  In gnulib, malloc should be used
55009         instead.  Providing for both cases complicates things a fair bit.
55011         This patch rewrites ambiguous-option handling to use a boolean vector
55012         instead of a linked list.  There is then only one allocation that
55013         might need freeing; in glibc it can honor __libc_use_alloca as usual,
55014         and in gnulib we define __libc_use_alloca to always be false, so we
55015         don't need ifdefs in the middle of the function.  This should also be
55016         slightly more efficient in the normal case of long options being fully
55017         spelled out -- I think most people aren't even aware they _can_
55018         sometimes abbreviate long options.
55020         One interesting consequence is that the list of possibilities is now
55021         printed in exactly the order they appear in the list of long options,
55022         instead of the first possibility being shuffled to the end.
55024         (The patch looks bigger than it really is because there's a fair bit
55025         of reindentation and code rearrangement.)
55027         * lib/getopt.c: When used standalone, define __libc_use_alloca
55028         as always false and alloca to abort if called.
55029         (process_long_option): Rewrite handling of ambiguous long options
55030         to use a single boolean vector, not a linked list; use
55031         __libc_use_alloca to decide whether to allocate this using alloca.
55034         getopt: refactor long-option handling
55036         There were two copies of the bulk of the code to handle long options.
55037         Now there is only one.
55039         This change temporarily removes the logic to avoid using alloca when
55040         standalone; the next patch in the series will restore it.
55042         * lib/getopt.c (process_long_option): New function split out
55043         from _getopt_internal_r.
55044         (_getopt_internal_r): Replace both copies of the long-option
55045         processing code with calls to process_long_option.
55048         getopt: tidy up _getopt_initialize a bit
55050         _getopt_data.__posixly_correct is completely redundant to
55051         _getopt_data.__ordering, and some work that logically belongs in
55052         _getopt_initialize was being done by _getopt_internal_r, making the
55053         code harder to understand.
55055         As a side effect, getenv will no longer be called if the first
55056         character of the options string is '+' or '-', which is probably a
55057         Good Thing.  (Perhaps we should have a flag character that
55058         specifically asks for the permutation behavior?)
55060         * lib/getopt_int.h (_getopt_data): Remove __posixly_correct field.
55061         * lib/getopt.c (_getopt_internal_r): Move some initialization code...
55062         (_getopt_initialize): ...here. Don't set d->__posixly_correct.
55065         getopt: merge from glibc: repetition reduction
55067         The definitions of the entry point functions 'getopt' and
55068         '__posix_getopt' can be made substantially less repetitive with a
55069         helper macro.
55071         While I was merging the const-correctness changes from gnulib into
55072         glibc I noticed there are still some unnecessary casts in
55073         _getopt_internal_r.
55075         * lib/getopt.c (getopt, __posix_getopt): Eliminate repetition with
55076         a macro.  Consistently cast 'argv' to 'char **' when calling
55077         _getopt_internal.
55078         (_getopt_internal_r): Remove unnecessary casts when calling exchange.
55081         getopt: clean up error reporting
55083         getopt can print a whole bunch of error messages, and when used
55084         standalone (from gnulib) it uses fprintf to do that.  But fprintf is a
55085         cancellation point and getopt isn't, and also applying fprintf to a
55086         stream in wide-character mode is not allowed.  So every single error
55087         reporting case has an #ifdef _LIBC block in which it calls internal
55088         libc functions instead.  The counterpart patch series in glibc makes
55089         it possible to simplify all of that down to a set of #defines at the
55090         top of the file; core code is written as if it is safe to just call
55091         fprintf, flockfile, and funlockfile.  (One caveat: it's *not* safe to
55092         call any *other* stdio functions.)
55094         * lib/getopt.c: When _LIBC is defined, define fprintf to
55095         __fxprintf_nocancel, flockfile to _IO_flockfile, and funlockfile
55096         to _IO_funlockfile.  When neither _LIBC nor
55097         _POSIX_THREAD_SAFE_FUNCTIONS is defined, define flockfile and
55098         funlockfile as no-ops.
55099         (_getopt_internal_r): Remove all internal #ifdef _LIBC blocks; the
55100         standalone error-printing code can now be used for libc as well.
55101         Add an flockfile/funlockfile pair around one case where the error
55102         message is printed in several chunks.  Don't use fputc.
55105         getopt: fix fencepost error in ambiguous-W-option handling
55107         getopt_long contains an undocumented (AFAICT) feature in which, if you
55108         put "W;" in the short-options list, then '-W foo' and '-Wfoo' are
55109         treated as equivalent to '--foo'.  This is implemented with a partial
55110         second copy of the code for handling long options, and that code
55111         increments optind one too many times when recovering from an ambiguous
55112         abbreviated option, which can cause the main loop to walk past the end
55113         of argv and crash.
55115         I discovered this while writing a test case that tries to exercise all
55116         of getopt's error reporting paths; I wouldn't be surprised to learn
55117         that this feature is never used by real applications.
55119         * lib/getopt.c (_getopt_internal_r): Don't increment
55120         d->optind a second time when reporting ambiguous -W options.
55123         getopt: clean up getopt.c and getopt1.c file headers
55125         In getopt.c, there is no need to include wchar.h at all, and it is
55126         safe nowadays to assume that stdlib.h does declare getenv (several
55127         other gnulib modules make this assumption).
55129         In getopt1.c, the #ifdef _LIBC block at the top can be simplified
55130         by using "" inclusions consistently, and there is no actual need to
55131         include stdlib.h (except in the #ifdef TEST block, where it should be
55132         unconditional), nor to provide a backup definition of NULL at all.
55134         * lib/getopt1.c: Simplify #ifdeffage at top of file.
55135         Move inclusion of stdlib.h to #ifdef TEST block and make
55136         unconditional.  Do not define NULL.
55137         * lib/getopt.c: Don't include wchar.h. No need to declare getenv.
55138         * m4/getopt.m4 (gl_PREREQ_GETENV): Delete.
55139         * modules/getopt-gnu, modules/getopt-posix: Don't call
55140         gl_PREREQ_GETENV.
55143         getopt: harmonize comments with glibc
55145         The comments explaining how the behavior of 'getopt' varies depending
55146         on whether it's the standalone version and whether there are special
55147         characters at the beginning of the options string were inconsistent
55148         between gnulib and glibc, and also out of sync with the code.
55150         * lib/getopt.c, lib/getopt_int.h: Harmonize comments with glibc.
55153         getopt: remove USE_NONOPTION_FLAGS
55155         getopt includes code to parse an environment variable named
55156         _XXX_GNU_nonoption_argv_flags_ (where XXX is the current process's PID
55157         in decimal); but all of it has been #ifdefed out since 2001, with no
55158         official way to turn it back on.
55160         According to commentary in glibc's config.h.in, bash version 2.0
55161         set this environment variable to indicate argv elements that were
55162         the result of glob expansion and therefore should not be treated
55163         as options, but the feature was "disabled later" because "it
55164         caused problems".  According to bash's CHANGES file, "later" was
55165         release 2.01; it gives no more detail about what the problems
55166         were.
55168         Version 2.0 of bash was released on the last day of 1996, and version
55169         2.01 in June of 1997.  Twenty years later, I think it is safe to
55170         assume that this environment variable isn't coming back.
55172         * lib/getopt_int.h: Remove all #ifdef USE_NONOPTION_FLAGS blocks.
55173         * lib/getopt.c: Likewise. Also remove SWAP_FLAGS and the
55174         __libc_argc and __libc_argv externs, which were only used by
55175         #ifdef USE_NONOPTION_FLAGS blocks.
55178         getopt: tabify, in preparation for merge with glibc
55180         glibc sticks to the GNU default of indenting with a mix of
55181         8-column tabs and spaces; make the gnulib copy match.
55183         getopt.h is not included because it is *not* going to be merged in its
55184         present form.
55186         * getopt.c, getopt1.c, getopt_int.h: Tabify.
55188 2017-04-02  Bruno Haible  <bruno@clisp.org>
55190         relocatable-lib-lgpl: Fix link error (regression from 2011-06-16).
55191         * modules/relocatable-lib-lgpl (configure.ac): Add AC_LIBOBJ invocation,
55192         like it was done in modules/relocatable-lib on 2011-05-21 and in
55193         modules/relocatable-prog on 2011-08-15.
55194         Reported by Reuben Thomas <rrt@sc3d.org>.
55196 2017-03-31  Bruno Haible  <bruno@clisp.org>
55198         glob: Fix invalid free() call.
55199         * lib/glob.c (glob): Reset malloc_home_dir when assigning a pointer to
55200         static storage to home_dir.
55201         Reported by Coverity via Tim Rühsen.
55203 2017-03-31  Bruno Haible  <bruno@clisp.org>
55205         glob: Fix memory leaks.
55206         * lib/glob.c (glob): Free allocated memory before returning.
55207         Reported by Coverity via Tim Rühsen.
55209 2017-03-31  Bruno Haible  <bruno@clisp.org>
55211         md5, sha1, sha256, sha512: Add comments regarding correctness.
55212         * lib/md5.h (buflen): Add comments regarding range.
55213         * lib/sha1.h (buflen): Likewise.
55214         * lib/sha256.h (buflen): Likewise.
55215         * lib/sha512.h (buflen): Likewise.
55216         * lib/md5.c (md5_process_bytes): Add comment why memmove is not needed.
55217         * lib/sha1.c (sha1_process_bytes): Likewise.
55218         * lib/sha256.c (sha256_process_bytes): Likewise.
55219         * lib/sha512.c (sha512_process_bytes): Likewise.
55220         Reported by Coverity via Tim Rühsen.
55222 2017-03-22  Paul Eggert  <eggert@cs.ucla.edu>
55224         getopt: merge from glibc
55225         This does not change anything substantial; it merely simplifies
55226         hypothetical merges back to glibc.
55227         * lib/getopt.c, lib/getopt.in.h, lib/getopt1.c, lib/getopt_int.h:
55228         Change copyright notice to match what is in glibc.
55229         * lib/getopt.c: Reorder includes to match glibc.  Remove uses of
55230         USE_IN_LIBIO.  Remove 'register'.  In __LIBC code, use
55231         __open_memstream rather than open_memstream and __glibc_likely
55232         instead of __builtin_expect.
55233         * lib/getopt.in.h (__posix_getopt) [!__GETOPT_PREFIX]: New decl.
55235 2017-03-21  Paul Eggert  <eggert@cs.ucla.edu>
55237         dfa: make [0-9] faster in non-C locales
55238         Problem reported by John P. Linderman (Bug#26193).
55239         * lib/dfa.c (parse_bracket_exp): Remove redundant assignment.
55240         If both ends of the range are ASCII digits, do not worry about
55241         multi-character collating sequences and the like.  Be consistent
55242         about using isalpha as a precondition for setbit_case_fold_c.
55244 2017-03-19  Bruno Haible  <bruno@clisp.org>
55246         lock: Fix compilation error with HP-UX IA64 cc.
55247         * lib/glthread/lock.h (pthread_rwlockattr_setkind_np): Don't declare
55248         weak on non-glibc platforms.
55250 2017-03-19  Paul Eggert  <eggert@cs.ucla.edu>
55252         stdalign: tweak version# and test for HP-UX IA64
55253         Problems reported by Bruno Haible in:
55254         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00078.html
55255         * lib/stdalign.in.h (_Alignas):
55256         * m4/stdalign.m4 (gl_STDALIGN_H):
55257         Use octal, not decimal, for __HP_cc version.  Perhaps HP formerly
55258         used octal (as that is how they document it), but it is decimal in
55259         practice now and the ancient implementations no longer matter.
55260         * tests/test-stdalign.c (main) [__HP_cc && __ia64]: Skip test.
55262 2017-03-19  Bruno Haible  <bruno@clisp.org>
55264         vma-iter: Add support for Solaris.
55265         * lib/vma-iter.c (vma_iterate): On Solaris, use the /proc filesystem
55266         approach.
55267         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on Solaris.
55268         * lib/get-rusage-as.c: Update comment about Solaris.
55269         * lib/get-rusage-data.c: Likewise.
55271 2017-03-19  Bruno Haible  <bruno@clisp.org>
55273         vma-iter: Prefer HP-UX specific API on HP-UX.
55274         * lib/vma-iter.c (vma_iterate): Move HP-UX specific implementation up.
55275         * lib/vma-iter.h: Update.
55276         Just in case HP-UX ever implements mquery().
55278 2017-03-18  Paul Eggert  <eggert@cs.ucla.edu>
55280         stdalign: restore previous behavior for HP-UX IA64
55281         See Bruno Haible's email in:
55282         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00066.html
55283         which cites p 150 of a manual saying that 'aligned' works on Itanium.
55284         * lib/stdalign.in.h (_Alignas):
55285         Assume the '061200' applies to Itanium, not to PA-RISC.
55286         * m4/stdalign.m4 (gl_STDALIGN_H): Adjust to match stdalign.in.h.
55288 2017-03-17  Bruno Haible  <bruno@clisp.org>
55290         stat-time, timespec: Support use of the header files in C++ mode.
55291         * lib/stat-time.h: Add "C" linkage declaration.
55292         * lib/timespec.h: Likewise.
55294 2017-03-17  Bruno Haible  <bruno@clisp.org>
55296         stdalign: Make it work with HP-UX cc.
55297         * lib/stdalign.in.h (_Alignas): Don't define for HP-UX cc.
55298         * m4/stdalign.m4 (gl_STDALIGN_H): No need to enable the extra test
55299         for HP-UX cc.
55301 2017-03-17  Paul Eggert  <eggert@cs.ucla.edu>
55303         flexmember: try to detect HP-UX 11.31 cc bug
55304         Problem reported by Bruno Haible in:
55305         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00066.html
55306         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
55307         Attempt to detect bug in HP-UX 11.31 cc.
55309 2017-03-16  Bruno Haible  <bruno@clisp.org>
55311         stdint: Fix test compilation failure with HP-UX 11 cc.
55312         * lib/stdint.in.h (_STDINT_MIN): Remove macro.
55313         (_STDINT_UNSIGNED_MIN, _STDINT_SIGNED_MIN): New macros.
55314         (PTRDIFF_MIN, SIG_ATOMIC_MIN, WCHAR_MIN, WINT_MIN): Define using
55315         _STDINT_UNSIGNED_MIN, _STDINT_SIGNED_MIN.
55317 2017-03-14  Bruno Haible  <bruno@clisp.org>
55319         gnulib-tool: Don't produce a tests directory with only snippet .h files.
55320         * gnulib-tool (func_modules_transitive_closure_separately): If
55321         testsrelated_modules ends up with no "real" modules, aside from
55322         modules with applicability 'all', set it to empty.
55324 2017-03-14  Bruno Haible  <bruno@clisp.org>
55326         vma-iter: Add support for HP-UX.
55327         * modules/vma-iter (configure.ac): Check for 'pstat_getprocvm'.
55328         * lib/vma-iter.c (vma_iterate): On HP-UX, use pstat_getprocvm().
55329         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on HP-UX.
55330         * lib/get-rusage-as.c: Update comment about HP-UX.
55331         * lib/get-rusage-data.c: Likewise.
55332         (get_rusage_data): Use get_rusage_data_via_setrlimit.
55334 2017-03-14  Bruno Haible  <bruno@clisp.org>
55336         limits-h: Make it work with HP-UX cc.
55337         * lib/limits.in.h (LLONG_MIN, LLONG_MAX, ULLONG_MAX): Define if not
55338         defined.
55340 2017-03-14  Bruno Haible  <bruno@clisp.org>
55342         Fix test failures on DragonFlyBSD.
55343         * tests/test-localeconv.c (main): Treat DragonFlyBSD like FreeBSD.
55344         * tests/test-select.h (test_bad_fd): Likewise.
55345         * tests/test-get-rusage-data.c (main): Treat DragonFlyBSD like OpenBSD.
55347 2017-03-14  Bruno Haible  <bruno@clisp.org>
55349         freadahead: Silence warning on DragonFlyBSD.
55350         * lib/freadahead.c (__sreadahead): Declare ourselves.
55352 2017-03-14  Bruno Haible  <bruno@clisp.org>
55354         vma-iter: Add comment about AIX.
55355         * lib/vma-iter.c: Add comment about why this module is not implemented
55356         on AIX.
55358 2017-03-14  Paul Eggert  <eggert@cs.ucla.edu>
55360         snippets: move unadjusted snippet sources to lib
55361         Problem reported by Michal Privoznik in:
55362         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00039.html
55363         * lib/_Noreturn.h: Rename from build-aux/snippet/_Noreturn.h.
55364         * lib/arg-nonnull.h: Rename from build-aux/snippet/arg-nonnull.h.
55365         * lib/c++defs.h: Rename from build-aux/snippet/c++defs.h.
55366         * lib/unused-parameter.h: Rename from
55367         build-aux/snippet/unused-parameter.h.
55368         * lib/warn-on-use.h: Rename from build-aux/snippet/warn-on-use.h.
55369         * modules/snippet/_Noreturn (Files:, _NORETURN_H):
55370         * modules/snippet/arg-nonnull (Files:, ARG_NONNULL_H):
55371         * modules/snippet/c++defs (Files:, CXXDEFS_H):
55372         * modules/snippet/unused-parameter (Files:, UNUSED_PARAMETER_H):
55373         * modules/snippet/warn-on-use (Files: WARN_ON_USE_H):
55374         Adjust to file renamings.
55376 2017-03-14  Mathieu Lirzin  <mthl@gnu.org>
55378         gnulib-tool: don't automatically distribute files from top/
55379         * gnulib-tool (func_get_automake_snippet_unconditional): To be able to
55380         not distribute top/README-release by default, don't distribute files
55381         from top/ unconditionally.
55382         * modules/gnumakefile (Makefile.am): Distribute top/GNUmakefile.
55383         * modules/maintainer-makefile (Makefile.am): Distribute top/maint.mk.
55385 2017-03-14  Paul Eggert  <eggert@cs.ucla.edu>
55387         gnulib-tool: fix typo in comment output
55388         * gnulib-tool (func_import): Fix typo with previous change.
55390         snippets: work around GNU Make 3.82 VPATH
55391         When using 'gnulib-tool --gnu-make' on Emacs, and building
55392         the resulting tarball on Solaris 10 which bundles GNU Make 3.82,
55393         an out-of-source (VPATH) build failed because the sans-copyright
55394         snippet file was not built before the file that used it.
55395         Presumably this is some sort of VPATH thing.  Work around the
55396         problem by using the original snippet, i.e., don’t bother to
55397         remove its copyright notice.
55398         * modules/snippet/_Noreturn, modules/snippet/link-warning:
55399         Don’t assume Automake in comments.  Omit long-incorrect comment.
55400         * modules/snippet/arg-nonnull (BUILT_SOURCES, arg-nonnull.h)
55401         (MOSTLYCLEANFILES):
55402         * modules/snippet/c++defs (BUILT_SOURCES, c++defs.h)
55403         (MOSTLYCLEANFILES):
55404         * modules/snippet/unused-parameter (BUILT_SOURCES, unused-parameter.h)
55405         (MOSTLYCLEANFILES):
55406         * modules/snippet/warn-on-use (BUILT_SOURCES, warn-on-use.h)
55407         (MOSTLYCLEANFILES):
55408         Remove.
55409         * modules/snippet/arg-nonnull (ARG_NONNULL_H):
55410         * modules/snippet/c++defs (CXXDEFS_H):
55411         * modules/snippet/unused-parameter (UNUSED_PARAMETER_H):
55412         * modules/snippet/warn-on-use (WARN_ON_USE_H):
55413         Don’t bother to remove the copyright notice; just use the
55414         original snippet as-is.
55416 2017-03-13  Paul Eggert  <eggert@cs.ucla.edu>
55418         gnulib-tool: minor --gnu-make fixups
55419         * gnulib-tool (func_emit_lib_Makefile_am):
55420         Remove useless code that was a blind alley during implementation.
55421         Problem reported by Thien-Thi Nguyen in:
55422         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00029.html
55423         (func_import): Note the "--gnu-make" option in the output comment.
55425 2017-03-12  Paul Eggert  <eggert@cs.ucla.edu>
55427         gnulib-tool: new option --gnu-make
55428         This is for applications like GNU Emacs that use GNU Make
55429         features instead of Automake.
55430         * doc/gnulib-tool.texi (Initial import): Mention --gnu-make.
55431         * doc/gnulib.texi (Unit test modules, Build robot for gnulib):
55432         Do not assume Automake.
55433         * gnulib-tool (func_determine_path_separator)
55434         (func_modules_transitive_closure, func_update_file)
55435         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
55436         (func_import): Add support for --gnu-make.
55438 2017-03-11  Paul Eggert  <eggert@cs.ucla.edu>
55440         gnulib-common.m4: avoid aclocal.m4 bloat
55441         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB):
55442         Hide AM_PROG_AR from aclocal, so that aclocal does not
55443         install irrelevant macro definitions into aclocal.m4.
55445 2017-03-10  Bruno Haible  <bruno@clisp.org>
55447         vma-iter: Let callers know about error.
55448         * lib/vma-iter.h (vma_iterate): Return 'int', not 'void'.
55449         * lib/vma-iter.c (vma_iterate): Return -1 in case of error.
55451 2017-03-05  Bruno Haible  <bruno@clisp.org>
55453         Fix value of LD for 64-bit compilers on AIX.
55454         * m4/lib-ld.m4 (AC_LIB_PROG_LD): For 64-bit compilers on AIX
55455         ("gcc -maix64" and "xlc -q64"), add option -b64 to $LD.
55457 2017-03-04  Paul Eggert  <eggert@cs.ucla.edu>
55459         dtotimespec: simplify
55460         * lib/dtotimespec.c (dtotimespec): Simplify.
55462 2017-03-04  Bruno Haible  <bruno@clisp.org>
55464         test-calloc-gnu: Reenable test also for GCC 7.
55465         * tests/test-calloc-gnu.c (eight): New function.
55466         (main): Don't skip test; use eight() instead.
55468 2017-03-04  Jim Meyering  <meyering@fb.com>
55470         test-calloc-gnu: port to GCC7
55471         * tests/test-calloc-gnu.c (main) [__GNUC__ >= 7]: Skip a test
55472         that attempts to calloc more than SIZE_MAX bytes, because GCC7
55473         and newer would detect that at compilation time.
55475 2017-03-04  Bruno Haible  <bruno@clisp.org>
55477         tests: Avoid compiler warning about uses of null_ptr.
55478         * tests/null-ptr.h: New file.
55479         * tests/test-canonicalize.c: Include null-ptr.h.
55480         (null_ptr): Remove function.
55481         * tests/test-canonicalize-lgpl.c: Likewise.
55482         * tests/test-memmem.c: Likewise.
55483         * tests/test-ptsname_r.c: Likewise.
55484         * modules/canonicalize-tests (Files): Add tests/null-ptr.h.
55485         * modules/canonicalize-lgpl-tests: Likewise.
55486         * modules/memmem-tests: Likewise.
55487         * modules/ptsname_r-tests: Likewise.
55488         Reported by Jim Meyering.
55490 2017-03-03  Bruno Haible  <bruno@clisp.org>
55492         doc: Mention Mac OS X deficiencies regarding semaphores.
55493         * doc/posix-functions/sem_init.texi: Mention status on Mac OS X.
55494         * doc/posix-functions/sem_destroy.texi: Likewise.
55495         * doc/posix-functions/sem_getvalue.texi: Likewise.
55497 2017-03-03  Bruno Haible  <bruno@clisp.org>
55499         lock tests: Fix test failure on Mac OS X (regression from 2017-01-05).
55500         Reported by Assaf Gordon <assafgordon@gmail.com> via
55501         Pádraig Brady <P@draigBrady.com>.
55502         * tests/test-lock.c: On Mac OS X, use named semaphores, not unnamed
55503         semaphores.
55504         (USE_NAMED_SEMAPHORE, USE_UNNAMED_SEMAPHORE): New macros.
55505         (atomic_int_semaphore): New macro.
55507 2017-02-28  Bruno Haible  <bruno@clisp.org>
55509         perror tests: Tweak for z/OS.
55510         Reported by Daniel Richard G. <skunk@iskunk.org>.
55511         * tests/test-perror.sh: Don't fail z/OS style perror output.
55513 2017-02-26  Bruno Haible  <bruno@clisp.org>
55515         nproc: Refactor large function.
55516         * lib/nproc.c (num_processors_ignoring_omp): New function, extracted
55517         from num_processors.
55518         (num_processors): In this function, only deal with OMP.
55520 2017-02-26  Pádraig Brady  <P@draigBrady.com>
55522         nproc: adjust handling of OpenMP environment variables
55523         to match the return value from omp_get_num_threads(), i.e.:
55524          - honor OMP_THREAD_LIMIT without OMP_NUM_THREADS
55525          - Treat 0 as an invalid value and ignore
55526         Also remove the call to omp_get_num_threads() because
55527         it's ineffective without the omp pragmas in place.
55528         * lib/nproc.c (parse_omp_threads): Return 0 if specified,
55529         so that it can be ignored.
55530         (num_processors): Honor OMP_THREAD_LIMIT even without
55531         OMP_NUM_THREADS being set.  Also fix a typo in the environment
55532         variable being checked, from the previous recent commit.
55534 2017-02-26  Pádraig Brady  <P@draigBrady.com>
55536         nproc: support nested OMP_NUM_THREADS, and OMP_THREAD_LIMIT
55537         * lib/nproc.c (parse_omp_threads): A new function refactored
55538         from num_processors() to support parsing both of the
55539         above environment variables.
55540         (num_processors): Prefer using omp_get_num_threads() with [_OPENMP]
55541         to accurately reflect the current OpenMP nesting level.
55542         Also support the OMP_THREAD_LIMIT environment variable
55543         to limit the max value determined from OMP_NUM_THREADS.
55544         * modules/nproc: Depend on minmax header.
55545         Suggested by Oliver Heimlich.
55547 2017-02-25  Bruno Haible  <bruno@clisp.org>
55549         maintainer-makefile: Fix AC_PROG_SED with autoconf cache.
55550         * m4/gnulib-common.m4 (AC_PROG_SED): Fix AC_CACHE_CHECK invocation.
55552 2017-02-24  Paul Eggert  <eggert@cs.ucla.edu>
55554         ftoastr: port to -Wdouble-promotion
55555         Work around -Wdouble-promotion false alarm in recent GCCs.
55556         * lib/ftoastr.c (PROMOTED_FLOAT): New macro.
55557         (ftoastr_snprintf, FTOASTR): Use it.
55559 2017-02-21  Bruno Haible  <bruno@clisp.org>
55561         lock tests: Fix build failure on GNU/Hurd (regression from 2017-01-05).
55562         Reported by Rene Saavedra <rennes@openmailbox.org> in
55563         https://debbugs.gnu.org/cgi/bugreport.cgi?bug=25821 via Paul Eggert.
55564         * lib/glthread/lock.h: On glibc systems without
55565         PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP, use the fallback
55566         implementation of rwlocks.
55567         * lib/glthread/lock.c: Likewise.
55569 2017-02-20  Bruno Haible  <bruno@clisp.org>
55571         lock tests: Fix build failure on z/OS.
55572         Reported by Daniel Richard G. <skunk@iskunk.org>.
55573         * modules/lock-tests (configure.ac): Test for <semaphore.h>.
55574         * tests/test-lock.c (USE_SEMAPHORE): Don't set if <semaphore.h> does not
55575         exist.
55577 2017-02-19  Bruno Haible  <bruno@clisp.org>
55579         havelib: Prefer the search path of /usr/bin/gcc over the one of $CC.
55580         This helps when CC=clang.
55581         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Prefer the search path
55582         of /usr/bin/gcc.
55584         havelib: Support overriding the result of AC_LIB_PREPARE_MULTILIB.
55585         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Use AC_CACHE_CHECK.
55587 2017-02-19  Bruno Haible  <bruno@clisp.org>
55589         gnulib-tool: Avoid conflict of havelib-tests with --single-configure.
55590         * gnulib_tool (func_create_testdir): Avoid havelib-tests when
55591         --with-tests --single-configure is specified.
55593 2017-02-16  Tim Rühsen  <tim.ruehsen@gmx.de>
55595         users.txt: Update links, use HTTPS where possible
55596         * users.txt: Updated to HTTPS where possible,
55597         fixed some links to new locations.
55599 2017-02-16  Bruno Haible  <bruno@clisp.org>
55601         xbinary-io: Fix inlining.
55602         * lib/xbinary-io.c: Set XBINARY_IO_INLINE, not XSETMODE_INLINE.
55604 2017-02-16  Paul Eggert  <eggert@cs.ucla.edu>
55606         xbinary-io: rename from xsetmode
55607         This patch is taken from suggestions by Bruno Haible in:
55608         http://lists.gnu.org/r/bug-gnulib/2017-02/msg00060.html
55609         http://lists.gnu.org/r/bug-gnulib/2017-02/msg00061.html
55610         * lib/binary-io.c (__gl_setmode_check): Set errno to EINVAL,
55611         not ENOTTY, when it is an inappropriate device.
55612         * lib/binary-io.h (SET_BINARY): Resurrect.
55613         * lib/xbinary-io.c: Rename from lib/xsetmode.c.
55614         (xset_binary_mode_error): Rename from xsetmode_error.
55615         * lib/xbinary-io.h: Rename from lib/xsetmode.h.
55616         (xset_binary_mode): Rename from xsetmode.
55617         All uses changed.
55618         * modules/xbinary-io: Rename from modules/xsetmode.
55619         Update file names.
55620         * tests/test-binary-io.sh (tmpfiles): Remove no-longer-used file name.
55621         * NEWS: Update to match revised behavior.
55623 2017-02-15  Paul Eggert  <eggert@cs.ucla.edu>
55625         tests: Adjust to recent SET_BINARY change
55626         * tests/test-binary-io.c (main):
55627         * tests/test-binary-io.sh: Remove test for SET_BINARY.
55628         * tests/test-closein.c, tests/test-fflush2.c, tests/test-ftell.c:
55629         * tests/test-ftello.c, tests/test-nonblocking-pipe-child.c:
55630         * tests/test-yesno.c: Use set_binary_mode, not SET_BINARY.
55632         xsetmode: new module
55633         This is to fix a problem noted by Eric Blake.
55634         Code was using xfreopen to change files to binary mode, but this
55635         fails for stdout when in append mode.  Such code should use
55636         xsetmode instead.
55637         * NEWS: Document incompatible changes to binary-io module.
55638         * lib/binary-io.c (__gl_setmode_check) [__DJGPP__ || __EMX__]:
55639         New function.
55640         * lib/binary-io.h (__gl_setmode): Rename from set_binary_mode.
55641         (set_binary_mode): New function, which also checks for tty.
55642         * lib/xsetmode.c, lib/xsetmode.h, modules/xsetmode: New files.
55644 2017-02-14  Paul Eggert  <eggert@cs.ucla.edu>
55646         headers: fix begin-end typos
55647         * lib/mbfile.h, lib/se-selinux.in.h: Fix typos by replacing
55648         _GL_INLINE_HEADER_BEGIN with _GL_INLINE_HEADER_END.
55650         selinux-h: port to PGI 16.10
55651         * lib/se-selinux.in.h: Don't assume that include_next skips over
55652         duplicate -I DIR options.
55654         argp: port to PGI 16.10
55655         * lib/argp-pin.c (dummy): Declare as needed to make file nonempty.
55657 2017-02-13  Darshit Shah  <darnir@gnu.org>
55659         unicase: Update function protoype to match definition.
55660         * lib/unicase/special-casing.h (gl_unicase_special_lookup): Gperf 3.1
55661         uses 'size_t' as the datatype for the 'len' parameter in the functions
55662         it generates. Update the prototype specified here to match the newly
55663         generated function.
55665 2017-02-12  Bruno Haible  <bruno@clisp.org>
55667         times test: Avoid gcc warnings on Linux/x32.
55668         * tests/test-times.c (main): Really cast printf arguments from clock_t
55669         to 'long int'.
55671 2017-02-12  Paul Eggert  <eggert@cs.ucla.edu>
55673         glob: port better to emscripten
55674         Problem reported by Bruno Haible in:
55675         http://lists.gnu.org/r/bug-gnulib/2017-02/msg00031.html
55676         * lib/glob.c (glob): Don't assume HAVE_GETPWNAM_R || _LIBC.
55678 2017-02-11  Bruno Haible  <bruno@clisp.org>
55680         host-cpu-c-abi: Support for 64-bit AIX, 32-bit armhf on arm64, hppa64.
55681         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Define also HOST_CPU.
55682         For the x32 ABI on x86_64, set HOST_CPU_C_ABI to 'x86_64-x32' and define
55683         both __x86_64__ and __x86_64_x32__. For the ELFv2 ABI on powerpc64,
55684         define both __powerpc64__ and __powerpc64_elfv2__. Recognize 64-bit
55685         compilation on AIX. Recognize 32-bit compilation on arm64/Linux.
55686         Distinguish hppa64 from hppa.
55688 2017-02-10  Bruno Haible  <bruno@clisp.org>
55690         search: Don't assume that tsearch() exists if 'VISIT' is defined.
55691         * m4/search_h.m4 (gl_SEARCH_H): Determine HAVE_TYPE_VISIT.
55692         * modules/search (Makefile.am): Substitute HAVE_TYPE_VISIT.
55693         * lib/search.in.h (VISIT): Define if HAVE_TYPE_VISIT is 0.
55695 2017-02-09  Bruno Haible  <bruno@clisp.org>
55697         doc: Don't mention obsolete AC_LIBTOOL_WIN32_DLL macro.
55698         * doc/gnulib.texi (Libtool and Windows): Recommend
55699         LT_INIT([win32-dll]) instead of AC_LIBTOOL_WIN32_DLL.
55700         Reported by Reuben Thomas <rrt@sc3d.org>.
55702 2017-02-08  Paul Eggert  <eggert@cs.ucla.edu>
55704         stddef-tests: port to SIZE_MAX <= INT_MAX
55705         * tests/test-stddef.c: Include <limits.h>, for INT_MAX.
55706         Do not assume that INT_MAX < SIZE_MAX.
55708 2017-02-01  Bruno Haible  <bruno@clisp.org>
55710         lock tests: Fix link error.
55711         * modules/lock-tests (test_rwlock1_LDADD): Add @YIELD_LIB@.
55712         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
55714 2017-01-31  Bruno Haible  <bruno@clisp.org>
55716         lock: Fix link error (regression from 2017-01-05).
55717         * lib/glthread/lock.h [USE_POSIX_THREADS_WEAK]: Declare also
55718         pthread_rwlockattr_init, pthread_rwlockattr_setkind_np,
55719         pthread_rwlockattr_destroy weak.
55720         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
55722 2017-01-30  Paul Eggert  <eggert@cs.ucla.edu>
55724         Port to PGI 16.10 x86-64
55725         This patch fixes one real bug in gl_anylinked_list2.h, along with
55726         some minor glitches that are not bugs.  It does not silence PGI’s
55727         thousands of bogus warnings when compiling test-intprops.c.
55728         Fortunately, the warnings do not cause a failure.
55729         * lib/c-ctype.h (_C_CTYPE_LOWER_A_THRU_F_N, _C_CTYPE_LOWER_N):
55730         Rename parameter to avoid PGI warning about ‘#define f(n) 'n'’.
55731         My goodness, PGI goes back a long ways - this predates C89!
55732         * lib/gl_anylinked_list2.h (ASYNCSAFE): Fix bug caught by PGI.
55733         For example, ASYNCSAFE (const void *) should expand to
55734         ‘const void *volatile’, not to ‘volatile const void *’.
55735         * lib/spawn.in.h (POSIX_SPAWN_USEVFORK): Don't define if already defined.
55736         * lib/verify.h (verify) [!__GNUC__]:
55737         Use shorter albeit meaningless string to bypass silly compiler limits.
55738         * tests/infinity.h (Infinityf, Infinityd, Infinityl) [__PGI]:
55739         * tests/nan.h (NaNf, NaNd, NaNl):
55740         Use static functions to avoid misguided compiler diagnostics.
55741         Is there some reason we don’t use static functions on all platforms?
55743 2017-01-20  Paul Eggert  <eggert@cs.ucla.edu>
55745         parse-datetime: handle timezones reentrantly
55746         This API change was prompted by a report by Pádraig Brady in:
55747         https://bug.debian.org/851934#10
55748         To help fix the bug, make parse_datetime2 more reentrant.
55749         * NEWS: Document this incompatible change.
55750         * lib/parse-datetime.h, lib/parse-datetime.y (parse_datetime2):
55751         Add two arguments, the timezone and the timezone name.
55752         All callers changed.  If TZ="..." is specified, use it for
55753         calculating defaults.
55754         * lib/parse-datetime.y: Don't include xalloc.h or use xmalloc, as
55755         this code should be usable in a library.
55756         (mktime_ok, get_effective_timezone):
55757         Accept timezone arg too.  All callers changed.
55758         (get_tz): Remove.
55759         (get_effective_timezone): Check for failures.
55761 2017-01-20  Eric Blake  <eblake@redhat.com>
55763         localename: port to cygwin 2.6
55764         * lib/localename.c (gl_locale_name_thread_unsafe): Add clause for
55765         Cygwin.
55766         * modules/localename (Depends-on): Add extensions, since
55767         NL_LOCALE_NAME() is not visible without it.
55769 2017-01-17  Pádraig Brady  <P@draigBrady.com>
55771         parse-datetime: fix dependence on AC_PROG_SED
55772         * modules/parse-datetime: Use `sed` directly like all other modules.
55773         Reported by J William Piggott
55775 2017-01-16  Paul Eggert  <eggert@cs.ucla.edu>
55777         intprops: update doc URLs
55778         * doc/intprops.texi (Integer Range Overflow): Update URLs.
55780 2017-01-16  Bruno Haible  <bruno@clisp.org>
55782         host-cpu-c-abi: Add support for armhf, arm64, x32, s390x.
55783         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Require gl_C_ASM. On x86_64
55784         systems, distinguish x86_64 and x32. On arm systems, distinguish arm,
55785         armhf, arm64, and no longer distinguish arm and armel. On s390x systems,
55786         distinguish s390 and s390x.
55787         * modules/host-cpu-c-abi (Files): Add m4/asm-underscore.m4.
55788         * NEWS: Mention the change regarding 'armel'.
55790 2017-01-15  Paul Eggert  <eggert@cs.ucla.edu>
55792         localeinfo: case_folded_counterparts and WEOF
55793         * NEWS: Document this.
55794         * lib/localeinfo.c (case_folded_counterparts):
55795         First arg is now wint_t, not wchar_t.  This generalizes the
55796         function to also work on WEOF, where it returns 0.
55798         dfa: port to gcc -fsanitize=undefined
55799         * lib/dfa.c (copy): Don’t pass NULL with size 0 to memcpy,
55800         as this runs afoul of gcc -fsanitize=undefined.
55802 2017-01-14  Paul Eggert  <eggert@cs.ucla.edu>
55804         strftime: %z is -00 if unknown
55805         * lib/strftime.c (DO_TZ_OFFSET): Omit arg 'negative'; it's now
55806         the caller's responsibility to set 'negative_number'.  All uses changed.
55807         (__strftime_internal): Put '-' before a zero UTC offset if the time
55808         zone abbreviation starts with "-", which is the recently-introduced
55809         tzdb convention for an unknown UTC offset that is arbitrarily set to 0.
55810         * tests/test-strftime.c: Test for this.
55812 2017-01-10  Paul Eggert  <eggert@cs.ucla.edu>
55814         dfa: port to older GCC
55815         Problem reported by Assaf Gordon in:
55816         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00103.html
55817         * modules/c99: New module.  This merely attempts to use the latest
55818         C version, which should be enough to solve this particular problem.
55819         The idea is to document which Gnulib modules assume C99 or later.
55820         * modules/dfa (Depends-on): Add it.
55822 2017-01-10  Bruno Haible  <bruno@clisp.org>
55824         Update DEPENDENCIES.
55825         * DEPENDENCIES: List only https URLs. Update recommended version for
55826         autoconf, automake, gperf.
55828 2017-01-10  Jim Meyering  <meyering@fb.com>
55830         maint.mk: enforce spelling of "timestamp" (i.e., no space)
55831         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Also
55832         disallow /\btime\s+stamps?\b/.  Prefer "timestamp".
55834 2017-01-10  Paul Eggert  <eggert@cs.ucla.edu>
55836         dfa: minor simplification with emptyset
55837         * lib/dfa.c (build_state): Simplify by using emptyset.
55839 2017-01-09  Paul Eggert  <eggert@cs.ucla.edu>
55841         dfa: shrink constraints from 4 bits to 3
55842         * lib/dfa.c (newline_constraint, letter_constraint)
55843         (other_constraint, prev_newline_dependent)
55844         (prev_letter_dependent, NO_CONSTRAINT, BEGLINE_CONSTRAINT)
55845         (ENDLINE_CONSTRAINT, BEGWORD_CONSTRAINT, ENDWORD_CONSTRAINT)
55846         (LIMWORD_CONSTRAINT, NOTLIMWORD_CONSTRAINT):
55847         Constraints need only 3 bits, not 4.  Using smaller integers
55848         shrinks the code a bit and makes grep a tad faster on x86-64.
55850         dfa: omit unnecessary ptrdiff_t check
55851         * lib/dfa.c (alloc_position_set): Do not worry about ptrdiff_t
55852         overflow, since xnmalloc does that now.
55854         dfa: omit unnecessary allocation
55855         * lib/dfa.c (dfaanalyze): Do not allocate follow set, since
55856         an all-zero follow set works just fine.
55858         dfa: omit unused local
55859         * lib/dfa.c (build_state): Fix up recent change.
55861         maint: remove stray .texi files
55862         Although these were superseded by other files like
55863         doc/posix-functions/ctime.texi, the old files were not removed.
55864         * doc/ctime.texi, doc/inet_ntoa.texi: Remove.
55866 2017-01-08  Paul Eggert  <eggert@cs.ucla.edu>
55868         getprogname: fix port to IRIX
55869         * lib/getprogname.c (getprogname) [__sgi]:
55870         Don't dump core if malloc returns NULL.
55872         dfa: fix reallocation bug when matching newlines
55873         Problem reported for sed by S. Gilles (Bug#25390).
55874         * lib/dfa.c (realloc_trans_if_necessary): Move earlier.
55875         (dfastate): Reallocate before moving any newline transition ...
55876         (build_state): ... instead of reallocating here, where it is too late.
55878 2017-01-07  Tim Rühsen  <tim.ruehsen@gmx.de>  (tiny change)
55880         Avoid -Wundef warning about undefined WINDOWS_SOCKETS.
55881         * lib/sockets.h: Test if WINDOWS_SOCKETS is defined.
55883 2017-01-07  Tim Rühsen  <tim.ruehsen@gmx.de>  (tiny change)
55885         Avoid -Wundef warning about undefined __USE_FILE_OFFSET64.
55886         * lib/glob-libc.h: Test if __USE_FILE_OFFSET64 is defined.
55888 2017-01-07  Bruno Haible  <bruno@clisp.org>
55890         stdioext: Port to Minix 3.2 and newer.
55891         * lib/stdio-impl.h: Treat __minix like the newest NetBSD.
55892         * lib/fseeko.c (fseeko): Likewise.
55893         Reported by Nelson Beebe via Paul Eggert.
55895 2017-01-06  Paul Eggert  <eggert@cs.ucla.edu>
55897         getprogname: port to IRIX
55898         * lib/getprogname.c (getprogname): Port to IRIX.
55899         Based on an idea by Bastien Roucariès at:
55900         http://lists.gnu.org/r/bug-gnulib/2010-12/msg00096.html
55901         via code from Bruno Haible at:
55902         https://lists.gnu.org/r/bug-gnulib/2010-12/msg00249.html
55904         localename-tests: port to NetBSD 7
55905         Problem reported by Nelson H. F. Beebe.
55906         * tests/test-localename.c:
55907         Test newlocale and uselocale only if both exist.
55909         glob, intprops, xalloc: work around Clang bug
55910         Work around LLVM bug 16404, which is still not fixed.
55911         https://llvm.org/bugs/show_bug.cgi?id=16404
55912         Problem reported by Nelson H. F. Beebe.
55913         * lib/glob.c, lib/intprops.h, lib/xalloc-oversized.h (__has_builtin):
55914         Remove.
55915         * lib/glob.c (size_add_wrapv):
55916         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW, _GL_HAS_BUILTIN_OVERFLOW_P):
55917         * lib/xalloc-oversized.h (xalloc_oversized):
55918         Do not use overflow builtins if Clang.
55920         dfa: fix 'return' typo
55921         Problem reported by Nelson H. F. Beebe.
55922         * lib/dfa.c (merge): Fix typo that Sun compilers rejected.
55924 2017-01-05  Pádraig Brady  <P@draigBrady.com>
55926         parse-datetime: fix generated paths for coverage files
55927         * modules/parse-datetime: Adjust the paths for parse-datetime.y
55928         within parse-datetime.c, so that gcc generates appropriate .gcno
55929         files, allowing lcov to proceed without error.  Previously it
55930         would error trying to find "lib/lib/parse-datetime.y".
55932 2017-01-05  Pádraig Brady  <P@draigBrady.com>
55934         maint.mk: support parallel execution of coverage
55935         * top/maint.mk (coverage): Run dependencies serially,
55936         thus supporting parallel processing of each one,
55937         particularly build-coverage, which builds and runs tests.
55939 2017-01-05  Bruno Haible  <bruno@clisp.org>
55941         lock tests: Prefer semaphore over mutex.
55942         * tests/test-lock.c (USE_SEMAPHORE): New constant.
55943         (struct atomic_int, init_atomic_int, get_atomic_int_value,
55944         set_atomic_int_value) [USE_SEMAPHORE]: Define using a POSIX semaphore.
55945         Suggested by Torvald Riegel <triegel@redhat.com>.
55947 2017-01-05  Bruno Haible  <bruno@clisp.org>
55949         lock: Provide guarantee to avoid writer starvation for rwlocks.
55950         The rationale is: 1) Read-preferring read-write locks are prone to
55951         writer starvation if the number of reader threads multiplied by the
55952         percentage of time they have the lock held is too high. 2) Write-
55953         preferring read-write locks are the only reliable way to avoid this.
55954         3) There have been reports of 'test-lock' hanging on glibc systems
55955         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00009.html,
55956         and glibc indeed implements read-preferring rwlocks by default, see
55957         http://man7.org/linux/man-pages/man3/pthread_rwlockattr_setkind_np.3.html
55958         and https://sourceware.org/bugzilla/show_bug.cgi?id=13701 .
55959         * m4/pthread_rwlock_rdlock.m4: New file.
55960         * m4/lock.m4 (gl_LOCK): Invoke gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER.
55961         * lib/glthread/lock.h [USE_POSIX_THREADS]: Test
55962         HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER. Use a different implementation
55963         of rwlock initialization on glibc systems without
55964         HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER. Use a different implementation
55965         of rwlocks altogether on non-glibc systems without
55966         HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER.
55967         [USE_PTH_THREADS]: Use a different implementation of rwlocks altogether.
55968         * lib/glthread/lock.c [USE_POSIX_THREADS]
55969         (glthread_rwlock_init_for_glibc): New function.
55970         [USE_POSIX_THREADS] (glthread_rwlock_rdlock_multithreaded): Update
55971         comment.
55972         [USE_PTH_THREADS]: New implementation of rwlocks.
55973         [USE_WINDOWS_THREADS] (glthread_rwlock_rdlock_func): Prefer writers over
55974         readers.
55975         * modules/lock (Files): Add m4/pthread_rwlock_rdlock.m4.
55976         (Depends-on): Add 'extensions'.
55977         * tests/test-rwlock1.c: New file.
55978         * lock-tests (Files): Add it.
55979         (Depends-on): Add usleep.
55980         (Makefile.am): Add test-rwlock1 to the tests.
55982 2017-01-05  Bruno Haible  <bruno@clisp.org>
55984         thread: Fix pth port.
55985         * lib/glthread/thread.h (pth_init): Declare weak.
55986         (glthread_create, glthread_sigmask, glthread_join, gl_thread_self,
55987         gl_thread_exit): Make sure Pth is initialized before invoking any Pth
55988         function.
55990 2017-01-04  Assaf Gordon  <assafgordon@gmail.com>
55992         parse-datetime: fix debug message on lone year number
55993         Input dates such as
55994           date -d "Apr 11 22:59:00 2011"
55995         are parsed as date (Apr 11, with default year 2016), then time, then a
55996         number (2011). Based on the combination of previously seen tokens,
55997         'digits_to_date_time' determines 2011 to be a year value.
55998         This fixes the debug messages to correctly show the updated year.
55999         Before:
56000             $ date --debug -d 'Apr 11 22:59:00 2011'
56001             date: parsed date part: (Y-M-D) 2016-04-11
56002             date: parsed time part: 22:59:00
56003             date: parsed number part: today/this/now
56004         After:
56005             $ ./src/date --debug -d 'Apr 11 22:59:00 2011'
56006             date: parsed date part: (Y-M-D) 2016-04-11
56007             date: parsed time part: 22:59:00
56008             date: parsed number part: year: 2011
56009         * lib/parse-datetime.y (struct parser_control): Add 'year_seen',
56010         'debug_year_seen' member fields.
56011         (digits_to_date_time): Update 'year_seen' as needed.
56012         (debug_print_current_time): Inform about year updates.
56013         (parse_datetime2): Initialize year_seen,debug_year_seen member fields.
56015         parse-datetime: fix local timezone debug messages
56016         "Local timezones" are strings that affect only DST relative to the
56017         default timezone. The debug messages in parse-datetime.y printed
56018         wrong information when encountering local timezones.
56019         Examples:
56020         Here EET/EEST are time zones ('zone' token, with values +02:00/+03:00):
56021              TZ=Asia/Tokyo ./src/date --debug -d '2011-12-11 EET'
56022              TZ=Asia/Tokyo ./src/date --debug -d '2011-06-11 EEST'
56023         When the default timezone relates to the zone strings, EET/EEST are
56024         parsed as local timezones (tLOCAL_ZONE), and only change the DST
56025         value (0/1, respectively):
56026              TZ=Europe/Helsinki ./src/date --debug -d '2011-12-11 EET'
56027              TZ=Europe/Helsinki ./src/date --debug -d '2011-06-11 EEST'
56028         * lib/parse-datetime.y (debug_print_current_time): If local timezone
56029         was seen, inform about DST change, don't print actual timezone.
56030         (debug_strfdatetime): If local timezone was seen, use default timezone
56031         (and adjust as needed) instead of using incorrect timezone.
56032         (parse_datetime2): Use correct time-zone source string, and adjust
56033         default timezone as needed.
56035         parse-datetime: add debug warning about DST changes
56036         Incorrect date arithmetic due to daylight saving time (DST) are a
56037         common (false) bug report in coreutils.
56038         Detect two such cases and print a warning:
56039         1. year/month/day adjustments (performed on 'struct tm'),
56040            where 'mktime' returns a different isdst value.
56041         2. hour/minute/seconds/ns adjustments (performed on 'time_t'),
56042            where the result of 'localtime(3)' on the value will return a
56043            different isdst value.
56044         Note: DST changes could be harmless or unnoticeable.
56045         Examples (with 'TZ=America/New_York'):
56046         Unnoticeable: result is 2016-Dec-14
56047            $ date -d '2016-06-15 EDT + 6 months' +%b
56048            Dec
56049         Unnoticeable: result is 2016-Dec-15 11:00:00
56050            $ date -d '2016-06-15 12:00:00 EDT + 6 months' +%F
56051            2016-12-15
56052         This is unexpected:
56053            $ date -d '2016-06-01 EDT + 6 months' +%F
56054            2016-11-30
56055         The new debug warnings will show:
56056            $ ./src/date --debug -d '2016-06-01 EDT + 6 months' +%F
56057            ...
56058            date: warning: daylight saving time changed after date adjustment
56059            ...
56060         * lib/parse-datetime.y (parse_datetime2): Detect DST changes, and
56061         print an appropriate warning message.
56063         parse-datetime: add debug warning about date arithmetic
56064         Date arithmetic are done directly on the fields of 'struct tm',
56065         which can result in invalid dates. Normalization with 'mktime(3)'
56066         will then produce a different date - which might cause unexpected
56067         results.
56068         Examples:
56069           '2016-10-31 - 1 month' => 2016-09-31 normalized to 2016-10-01.
56070           '2016-02-29 + 1 year'  => 2017-02-29 normalized to 2017-03-01.
56071         Note that date normalization is not inherently wrong and not rejected,
56072         as it has legitimate uses:
56073           '2016-12-29 + 5 days' => 2016-12-34 noramlized to 2017-01-03.
56074         If the user asked to adjust months but 'mday' changed,
56075         or user asked to adjust years but 'month' changed - warn about it.
56076             $ ./src/date --debug -d '2016-10-31 - 1 month'
56077             ...
56078             date: warning: when adding relative months/years, \
56079                            it is recommended to specify the 15th of the month
56080             ...
56081             date: warning: month/year adjustment resulted in shifted dates:
56082             date:      adjusted Y M D: 2016 09 31
56083             date:    normalized Y M D: 2010 10 01
56084             ...
56085         * lib/parse-datetime.y (parse_datetime2): Detect such cases and print
56086         a warning message. Improve recommendation of when to use 15 of the
56087         month or noon for date arithmetic.
56089         parse-datetime: fix debug message of relative part after timezone
56090         Relative part (e.g '+8 days') after a timezone string was not
56091         reported (was only reported after a timezone number). Due to the
56092         parser's structure, timezone strings with numbers were handled
56093         separately.
56094         before:
56095              # Timezone number + relative part: OK
56096              $ ./src/date --debug +%F -d '2013-10-30 00:00:00 +00:00 -8 days'
56097              ...
56098              date: parsed relative part: -8 day(s)
56099              # Timezone string + relative part: missing
56100              $ ./src/date --debug +%F -d '2013-10-30 00:00:00 UTC -8 days'
56101              [ missing message ]
56102         After: messages are printed in both cases.
56103         * lib/parse-datetime.y ('zone' token): Call debug_print_relative_time.
56105         parse-datetime: fix incorrect debug message on lone number
56106         A lone number is an absolute value, not a relative time part.
56107         before:
56108            $ date --debug -d '20130101'
56109            date: parsed number part: today/this/now
56110         After:
56111            $ ./src/date --debug -d '20130101'
56112            date: parsed number part: (Y-M-D) 2013-01-01
56113         * lib/parse-datetime.y ('item'/'number' tokens): Call
56114         'debug_print_current_time' instead of 'debug_print_relative_time'.
56116 2017-01-02  Paul Eggert  <eggert@cs.ucla.edu>
56118         doc: modernize for C11 etc.
56119         * doc/gnulib-readme.texi (Portability guidelines): Modernize a bit
56120         for C11, MinGW, etc.  This responds to Paul Smith's question in:
56121         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00014.html
56123         dfa: prefer functions to FETCH_WC macro
56124         * lib/dfa.c (FETCH_WC): Remove, replacing with ...
56125         (fetch_wc, bracket_fetch_wc): ... new functions.  These store the
56126         wint_t result into DFA->lex.wctok instead of to a separate arg.
56127         All callers changed.  Move more local decls closer to where
56128         they're used.
56130         dfa: narrow more local var scopes
56131         * lib/dfa.c: Move more local decls to be more local.
56133         dfa: remove duplicate assignment
56134         Problem reported by Bruno Haible in:
56135         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00007.html
56136         * lib/dfa.c (parse_bracket_exp): Simplify.
56138 2017-01-01  Paul Eggert  <eggert@cs.ucla.edu>
56140         dfa: simplify constraint-dependency checking
56141         * lib/dfa.c (prev_newline_constraint, prev_letter_constraint)
56142         (prev_other_constraint): Remove.
56143         (prev_newline_dependent, prev_letter_dependent):
56144         Simplify, to avoid an unnecessary bitwise AND operation.
56146         dfa: prefer functions and constants to macros
56147         * lib/dfa.c: Prefer constants to macros where either will do.
56148         (streq, isasciidigit, newline_constraint)
56149         (letter_constraint, other_constraint, succeeds_in_context)
56150         (prev_newline_constraint, prev_letter_constraint)
56151         (prev_other_constraint, prev_newline_dependent)
56152         (prev_letter_dependent, accepting, accepts_in_context):
56153         Now static functions instead of function-like macros.
56154         Use lower-case names accordingly.  All uses changed.
56156         dfa: narrow more local var scopes
56157         * lib/dfa.c: Move some more local decls down to nearer where
56158         they're needed.
56160 2016-12-31  Jim Meyering  <meyering@fb.com>
56162         dfa: narrow the scope of many local variables
56163         * lib/dfa.c: Now that we are no longer constrained to c89, move
56164         declarations of many variables (often indices) "down" into the
56165         scope(s) where used or to the point of definition.  This is a
56166         no-semantic-change diff.
56168 2017-01-01  Paul Eggert  <eggert@cs.ucla.edu>
56170         version-etc: new year
56171         * build-aux/gendocs.sh (version):
56172         * doc/gendocs_template:
56173         * doc/gendocs_template_min:
56174         * doc/gnulib.texi:
56175         * lib/version-etc.c (COPYRIGHT_YEAR):
56176         Update copyright dates by hand in templates and the like.
56177         * all files: Run 'make update-copyright'.
56179 2016-12-31  Eric Blake  <eblake@redhat.com>
56181         do-release-commit-and-tag: avoid shell syntax error
56182         * build-aux/do-release-commit-and-tag (curr_br): $branch can
56183         contain spaces when rebasing.
56185         maint.mk: hoist gnulib_dir definition earlier
56186         * top/maint.mk (gnulib_dir): Move near top of file.
56188 2016-12-31  Jim Meyering  <meyering@fb.com>
56190         maint.mk: do not always evaluate intprops-related shell
56191         * top/maint.mk (_intprops_names): Change := to just "=" to avoid
56192         using gnulib_dir undefined (gnulib_dir is defined later in the
56193         file, which will be fixed separately), and besides, there is no
56194         need to incur the cost of this shell invocation for every single
56195         use of this .mk file.  Reported by Eric Blake in
56196         https://lists.gnu.org/r/bug-gnulib/2016-12/msg00137.html
56198 2016-12-30  Jim Meyering  <meyering@fb.com>
56200         maint.mk: improve sc_prohibit_intprops_without_use
56201         * top/maint.mk (_intprops_names): Don't hard-code the list of
56202         symbol names.  Instead, derive it on the fly.
56204 2016-12-30  Paul Eggert  <eggert@cs.ucla.edu>
56206         dfa: shorten sbit, success
56207         * lib/dfa.c (struct regex_syntax.sbit):
56208         (struct dfa.success): Use char, not int, for array elements, since
56209         they are all in the range 0..7.
56211         dfa: simplify multibyte_prop etc.
56212         This follows up on a change made when dfa.c was in grep, namely grep
56213         commit c797046c7c13c2647182b919a79a4c5b4ecf82b1
56214         dated 2015-08-12 07:35:03 -0700, which removed unused multibyte support.
56215         That earlier simplification allows for some more simplification
56216         and trimming down here.
56217         * lib/dfa.c (struct mb_char_classes): New member nchars_alloc.
56218         (struct lexer_state): New mamber brack.
56219         (struct dfa, addtok_mb): multibyte_prop elements are now char, not int,
56220         since they must be in the range 0..3 now.
56221         Remove members mbcsets, nmbcsets, mbcsets_alloc, since
56222         the brack member now supersedes them.
56223         (parse_bracket_exp): Update dfa->lex.brack instead of dfa->mbcsets.
56224         (addtok): Use dfa->lex.brack instead of dfa->mbcsets.
56225         (dfaparse): Remove unnecessary initializations of already-0 storage.
56226         (free_mbdata): Free d->lex.brack.chars instead of d->mbcsets.
56227         (dfassbuild): No need to clear sup->mbcsets.
56229         dfa: minor performance tweak
56230         * lib/dfa.c (setbit_wc): Test < 0, not == EOF.
56232         dfa: wrap charclass inside a struct
56233         On my platform (gcc Ubuntu 5.4.0-6ubuntu1~16.04.4 x86-64,
56234         en_US.utf8 locale) this makes 'grep -Fi -f list.txt list.txt >out'
56235         about 5% faster, where list.txt is generated by 'aspell dump
56236         master | head -n 100000 >list.txt'.  See Bug#22239.
56237         * lib/dfa.c (charclass): Wrap inside a struct.  All uses changed.
56238         (CHARCLASS_INIT, tstbit, setbit, clrbit, zeroset, fillset, notset)
56239         (equal, emptyset, charclass_index, setbit_wc, setbit_case_fold_c):
56240         Adjust to this, e.g., by using charclass * rather than charclass.
56241         All callers changed as needed.
56242         (copyset): Remove.  All uses changed to simple assignment.
56243         (parse_bracket_exp): Use zeroset instead of memset.
56245 2016-12-30  Jim Meyering  <meyering@fb.com>
56247         maint.mk: update list of intprops.h symbol names
56248         * top/maint.mk (_intprops_names): Regenerate the list of symbol names.
56249         This avoids a false failure of the sc_prohibit_intprops_without_use
56250         rule in grep.
56252 2016-12-29  Eric Blake  <eblake@redhat.com>
56254         getopt: fix parallel test failure
56255         * tests/test-getopt-posix.c (TEST_GETOPT_TMP_NAME): Set name.
56256         * tests/test-getopt-gnu.c (TEST_GETOPT_TMP_NAME): Likewise.
56257         * tests/test-getopt-main.h (main): Use different file names
56258         in case test-getopt-gnu and test-getopt-posix run in parallel.
56260 2016-12-29  Paul Eggert  <eggert@cs.ucla.edu>
56262         xalloc: x2nrealloc check for ptrdiff_t overflow
56263         * lib/xalloc.h (x2nrealloc): Check for ptrdiff_t overflow, too.
56264         * modules/xalloc, modules/xvasprintf (Depends-on): Add stdint.
56266 2016-12-24  Bruno Haible  <bruno@clisp.org>
56268         lock test: Fix performance problem on multi-core machines.
56269         * tests/test-lock.c (USE_VOLATILE): New macro.
56270         (struct atomic_int): New type.
56271         (init_atomic_int, get_atomic_int_value, set_atomic_int_value): New
56272         functions.
56273         (lock_checker_done, rwlock_checker_done, reclock_checker_done): Define
56274         as 'struct atomic_int'.
56275         (lock_checker_thread, test_lock, rwlock_checker_thread, test_rwlock,
56276         reclock_checker_thread, test_recursive_lock): Use the new functions.
56277         Reported by Eric Blake in
56278         https://www.redhat.com/archives/libvir-list/2012-March/msg00854.html
56279         and by Pádraig Brady in
56280         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00117.html.
56282 2016-12-19  Bruno Haible  <bruno@clisp.org>
56284         vma-iter: Fix endless loop on 64-bit Windows.
56285         * lib/vma-iter.c (vma_iterate): On Windows, use 'uintptr_t' instead of
56286         'unsigned long'.
56288 2016-12-19  Bruno Haible  <bruno@clisp.org>
56290         stdint: Fix WINT_MAX to match the gnulib provided wint_t on minw.
56291         * m4/wint_t.m4 (gt_TYPE_WINT_T): Define GNULIB_OVERRIDES_WINT_T here.
56292         * m4/stdint.m4 (gl_STDINT_H): Don't define GNULIB_OVERRIDES_WINT_T.
56293         Invoke gt_TYPE_WINT_T instead.
56294         (gl_STDINT_TYPE_PROPERTIES): Test GNULIB_OVERRIDES_WINT_T.
56295         * modules/stdint (Files): Add m4/wint_t.m4.
56296         * modules/wchar (Makefile.am): Substitute GNULIB_OVERRIDES_WINT_T.
56297         * modules/wctype-h (Makefile.am): Likewise.
56298         * lib/wchar.in.h (wint_t): Override if GNULIB_OVERRIDES_WINT_T is set,
56299         not only on MSVC.
56300         * lib/wctype.in.h (wint_t): Likewise.
56302 2016-12-19  Paul Eggert  <eggert@cs.ucla.edu>
56304         getopt-posix-tests: fix Makefile typo
56305         * modules/getopt-posix-tests (test_getopt_posix_LDADD):
56306         Fix typo: the last ‘_’ was missing in the name.
56307         I suspect that the typo explains this build failure:
56308         https://buildfarm.opencsw.org/buildbot/builders/ggrep-solaris10-sparc/builds/39
56309         although I can’t reproduce the problem on Solaris 10 sparc.
56311 2016-12-18  Paul Eggert  <eggert@cs.ucla.edu>
56313         dfa: improve worst-case 'replace' performance
56314         See my note in Bug#22357#71.
56315         * lib/dfa.c (insert, delete): Rework to avoid duplicate test.
56316         (merge_constrained): New function, which is like
56317         the old 'merge' function, except with a new argument C2.
56318         Simplify the body by avoiding the need for different sections
56319         of code depending on whether one input is exhausted.
56320         (merge): Use the new function.
56321         (delete): Return the constraint of the deleted position,
56322         not the entire position.  Caller changed.
56323         (replace): Change from O(N*(N + log N)) to O(N log N) algorithm.
56325 2016-12-18  Norihiro Tanaka  <noritnk@kcn.ne.jp>
56327         dfa: performance improvement for removal of epsilon closure
56328         See Bug#22357#32.
56329         * lib/dfa.c (delete): Use binary search to find deleted index.
56330         (replace): New function.  It replaces a position with the followed set.
56331         (epsclosure): Replace it with a new algorithm.  Update caller.
56333 2016-12-18  Bruno Haible  <bruno@clisp.org>
56335         Split tests for getopt-posix and getopt-gnu.
56336         * tests/test-getopt-posix.c: New file.
56337         * tests/test-getopt-gnu.c: New file, with code from test-getopt.c.
56338         * tests/test-getopt-main.h: Renamed from tests/test-getopt.c. Remove
56339         stuff moved to test-getopt-gnu.c. Test TEST_GETOPT_GNU instead of
56340         GNULIB_TEST_GETOPT_GNU.
56341         * modules/getopt-posix-tests (Files): Add test-getopt-posix.c,
56342         test-getopt-main.h. Remove test-getopt.c, test-getopt_long.h.
56343         (Makefile.am): Test test-getopt-posix instead of test-getopt.
56344         * modules/getopt-gnu-tests: New file.
56345         * modules/getopt-gnu (configure.ac): Don't define GNULIB_TEST_GETOPT_GNU.
56347 2016-12-18  Bruno Haible  <bruno@clisp.org>
56349         posix-modules: Add options for specific platforms.
56350         * posix-modules (func_usage): Document options --for-mingw, --for-msvc.
56351         (exclude_for_mingw, exclude_for_msvc, exclude): New variables.
56352         Invoke func_tmpdir. Filter out the excludes.
56354 2016-12-18  Bruno Haible  <bruno@clisp.org>
56356         getopt: Fix link error for users of getopt() in <unistd.h>.
56357         * lib/getopt.in.h (getopt etc.): Do the macro definitions also when
56358         __need_getopt is defined. Undefine all macros before defining them.
56359         * modules/getopt (Include): Clarify that including <unistd.h> is also
56360         OK.
56361         * tests/test-getopt.c: Add comment.
56363 2016-12-17  Bruno Haible  <bruno@clisp.org>
56365         getaddrinfo tests: Avoid compilation error on MSVC.
56366         * tests/test-getaddrinfo.c: Don't check the prototypes of freeaddrinfo,
56367         getaddrinfo on native Windows.
56369 2016-12-17  Bruno Haible  <bruno@clisp.org>
56371         getlogin, getlogin_r: Fix link errors on MSVC.
56372         * m4/getlogin.m4 (gl_LIB_GETLOGIN): New macro.
56373         * modules/getlogin (configure.ac): Require gl_LIB_GETLOGIN.
56374         (Link): New section.
56375         * modules/getlogin_r (Files): Add m4/getlogin.m4.
56376         (configure.ac): Require gl_LIB_GETLOGIN.
56377         (Link): New section.
56378         * NEWS: Mention the new link requirements.
56379         * modules/getlogin-tests (test_getlogin_LDADD): New variable.
56380         * modules/getlogin_r-tests (test_getlogin_r_LDADD): New variable.
56382 2016-12-17  Bruno Haible  <bruno@clisp.org>
56384         Un-deprecate the 'progname' module.
56385         * NEWS: Describe the appropriate use-cases of 'progname' versus
56386         'getprogname'. Based on discussion summary at
56387         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00105.html
56389 2016-12-17  Bruno Haible  <bruno@clisp.org>
56391         Reorganize NEWS a bit.
56392         * NEWS: Move some not so important changes away from section
56393         "Important Notes".
56395 2016-12-17  Bruno Haible  <bruno@clisp.org>
56397         tanhf: Avoid redefinition error on MSVC.
56398         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_TANHF.
56399         * m4/tanhf.m4 (gl_FUNC_TANHF): Set REPLACE_TANHF to 1 if the function
56400         may be defined as an inline function.
56401         * modules/math (Makefile.am): Substitute REPLACE_TANHF.
56402         * lib/math.in.h (tanhf): Override if REPLACE_TANHF is 1.
56404 2016-12-17  Bruno Haible  <bruno@clisp.org>
56406         tanf: Avoid redefinition error on MSVC.
56407         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_TANF.
56408         * m4/tanf.m4 (gl_FUNC_TANF): Set REPLACE_TANF to 1 if the function
56409         may be defined as an inline function.
56410         * modules/math (Makefile.am): Substitute REPLACE_TANF.
56411         * lib/math.in.h (tanf): Override if REPLACE_TANF is 1.
56413 2016-12-17  Bruno Haible  <bruno@clisp.org>
56415         sqrtf: Avoid redefinition error on MSVC.
56416         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_SQRTF.
56417         * m4/sqrtf.m4 (gl_FUNC_SQRTF): Set REPLACE_SQRTF to 1 if the function
56418         may be defined as an inline function.
56419         * modules/math (Makefile.am): Substitute REPLACE_SQRTF.
56420         * lib/math.in.h (sqrtf): Override if REPLACE_SQRTF is 1.
56422 2016-12-17  Bruno Haible  <bruno@clisp.org>
56424         sinhf: Avoid redefinition error on MSVC.
56425         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_SINHF.
56426         * m4/sinhf.m4 (gl_FUNC_SINHF): Set REPLACE_SINHF to 1 if the function
56427         may be defined as an inline function.
56428         * modules/math (Makefile.am): Substitute REPLACE_SINHF.
56429         * lib/math.in.h (sinhf): Override if REPLACE_SINHF is 1.
56431 2016-12-17  Bruno Haible  <bruno@clisp.org>
56433         sinf: Avoid redefinition error on MSVC.
56434         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_SINF.
56435         * m4/sinf.m4 (gl_FUNC_SINF): Set REPLACE_SINF to 1 if the function
56436         may be defined as an inline function.
56437         * modules/math (Makefile.am): Substitute REPLACE_SINF.
56438         * lib/math.in.h (sinf): Override if REPLACE_SINF is 1.
56440 2016-12-17  Bruno Haible  <bruno@clisp.org>
56442         logf: Avoid redefinition error on MSVC.
56443         * m4/logf.m4 (gl_FUNC_LOGF): Set REPLACE_LOGF to 1 if the function
56444         may be defined as an inline function.
56446 2016-12-17  Bruno Haible  <bruno@clisp.org>
56448         log10l: Avoid redefinition error on MSVC.
56449         * m4/log10l.m4 (gl_FUNC_LOG10L): Set REPLACE_LOG10L to 1 if the function
56450         may be defined as an inline function.
56452 2016-12-17  Bruno Haible  <bruno@clisp.org>
56454         log10f: Avoid redefinition error on MSVC.
56455         * m4/log10f.m4 (gl_FUNC_LOG10F): Set REPLACE_LOG10F to 1 if the function
56456         may be defined as an inline function.
56458 2016-12-17  Bruno Haible  <bruno@clisp.org>
56460         hypotl: Avoid redefinition error on MSVC.
56461         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Set REPLACE_HYPOTL to 1 if the function
56462         may be defined as an inline function.
56464 2016-12-17  Bruno Haible  <bruno@clisp.org>
56466         hypotf: Avoid redefinition error on MSVC.
56467         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Set REPLACE_HYPOTF to 1 if the function
56468         may be defined as an inline function.
56470 2016-12-17  Bruno Haible  <bruno@clisp.org>
56472         fmodl: Avoid redefinition error on MSVC.
56473         * m4/fmodl.m4 (gl_FUNC_FMODL): Set REPLACE_FMODL to 1 if the function
56474         may be defined as an inline function.
56476 2016-12-17  Bruno Haible  <bruno@clisp.org>
56478         fmodf: Avoid redefinition error on MSVC.
56479         * m4/fmodf.m4 (gl_FUNC_FMODF): Set REPLACE_FMODF to 1 if the function
56480         may be defined as an inline function.
56482 2016-12-17  Bruno Haible  <bruno@clisp.org>
56484         expf: Avoid redefinition error on MSVC.
56485         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_EXPF.
56486         * m4/expf.m4 (gl_FUNC_EXPF): Set REPLACE_EXPF to 1 if the function
56487         may be defined as an inline function.
56488         * modules/math (Makefile.am): Substitute REPLACE_EXPF.
56489         * lib/math.in.h (expf): Override if REPLACE_EXPF is 1.
56491 2016-12-17  Bruno Haible  <bruno@clisp.org>
56493         coshf: Avoid redefinition error on MSVC.
56494         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_COSHF.
56495         * m4/coshf.m4 (gl_FUNC_COSHF): Set REPLACE_COSHF to 1 if the function
56496         may be defined as an inline function.
56497         * modules/math (Makefile.am): Substitute REPLACE_COSHF.
56498         * lib/math.in.h (coshf): Override if REPLACE_COSHF is 1.
56500 2016-12-17  Bruno Haible  <bruno@clisp.org>
56502         cosf: Avoid redefinition error on MSVC.
56503         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_COSF.
56504         * m4/cosf.m4 (gl_FUNC_COSF): Set REPLACE_COSF to 1 if the function
56505         may be defined as an inline function.
56506         * modules/math (Makefile.am): Substitute REPLACE_COSF.
56507         * lib/math.in.h (cosf): Override if REPLACE_COSF is 1.
56509 2016-12-17  Bruno Haible  <bruno@clisp.org>
56511         atan2f: Avoid redefinition error on MSVC.
56512         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ATAN2F.
56513         * m4/atan2f.m4 (gl_FUNC_ATAN2F): Set REPLACE_ATAN2F to 1 if the function
56514         may be defined as an inline function.
56515         * modules/math (Makefile.am): Substitute REPLACE_ATAN2F.
56516         * lib/math.in.h (atan2f): Override if REPLACE_ATAN2F is 1.
56518 2016-12-17  Bruno Haible  <bruno@clisp.org>
56520         atanf: Avoid redefinition error on MSVC.
56521         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ATANF.
56522         * m4/atanf.m4 (gl_FUNC_ATANF): Set REPLACE_ATANF to 1 if the function
56523         may be defined as an inline function.
56524         * modules/math (Makefile.am): Substitute REPLACE_ATANF.
56525         * lib/math.in.h (atanf): Override if REPLACE_ATANF is 1.
56527 2016-12-17  Bruno Haible  <bruno@clisp.org>
56529         asinf: Avoid redefinition error on MSVC.
56530         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ASINF.
56531         * m4/asinf.m4 (gl_FUNC_ASINF): Set REPLACE_ASINF to 1 if the function
56532         may be defined as an inline function.
56533         * modules/math (Makefile.am): Substitute REPLACE_ASINF.
56534         * lib/math.in.h (asinf): Override if REPLACE_ASINF is 1.
56536 2016-12-17  Bruno Haible  <bruno@clisp.org>
56538         acosf: Avoid redefinition error on MSVC.
56539         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ACOSF.
56540         * m4/acosf.m4 (gl_FUNC_ACOSF): Set REPLACE_ACOSF to 1 if the function
56541         may be defined as an inline function.
56542         * modules/math (Makefile.am): Substitute REPLACE_ACOSF.
56543         * lib/math.in.h (acosf): Override if REPLACE_ACOSF is 1.
56545 2016-12-17  Bruno Haible  <bruno@clisp.org>
56547         Avoid redefinition errors on MSVC.
56548         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): Set REPLACE_SNPRINTF to 1 if
56549         the function may be defined as an inline function.
56550         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): Set REPLACE_VSNPRINTF to 1 if
56551         the function may be defined as an inline function.
56553 2016-12-17  Bruno Haible  <bruno@clisp.org>
56555         Avoid redefinition errors on MSVC.
56556         * lib/stdio.in.h: Include <stdlib.h> and <io.h> when necessary.
56557         * lib/unistd.in.h: Include <stdio.h> when necessary.
56559 2016-12-17  Bruno Haible  <bruno@clisp.org>
56561         stdint: Fix WINT_MAX to match the gnulib provided wint_t on MSVC.
56562         * m4/stdint.m4 (gl_STDINT_H): Define GNULIB_OVERRIDES_WINT_T.
56563         * modules/stdint (Makefile.am): Substitute GNULIB_OVERRIDES_WINT_T.
56564         * lib/stdint.in.h [GNULIB_OVERRIDES_WINT_T]: Redefine WINT_MIN and
56565         WINT_MAX.
56567 2016-12-17  Bruno Haible  <bruno@clisp.org>
56569         Avoid autoconf warning.
56570         * modules/frexpl (configure.ac): Require, not invoke, gl_FUNC_FREXPL.
56571         * modules/frexp (configure.ac): Require, not invoke, gl_FUNC_FREXP.
56573 2016-12-17  Bruno Haible  <bruno@clisp.org>
56575         fpending: Revert workaround against Emacs bug.
56576         * lib/stdio-impl.h [__MINGW32__]: Revert conditional.
56577         The Emacs bug is fixed by Eli Zaretskii in
56578         http://lists.gnu.org/r/emacs-devel/2016-12/msg00715.html
56580 2016-12-17  Bruno Haible  <bruno@clisp.org>
56582         getlogin_r tests: Port to mingw.
56583         * tests/test-getlogin_r.c: Don't include <pwd.h> on native Windows. Fixes
56584         regression introduced on 2014-05-19.
56586 2016-12-17  Bruno Haible  <bruno@clisp.org>
56588         getlogin: Port to newer mingw.
56589         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_GETLOGIN.
56590         * m4/getlogin.m4 (gl_FUNC_GETLOGIN): Set HAVE_DECL_GETLOGIN.
56591         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETLOGIN, not
56592         HAVE_GETLOGIN.
56593         * lib/unistd.in.h (getlogin): Test HAVE_DECL_GETLOGIN, not
56594         HAVE_GETLOGIN.
56595         * doc/posix-functions/getlogin.texi: Mention the issue.
56596         * tests/test-getlogin.c: Don't include <pwd.h> on native Windows. Fixes
56597         regression introduced on 2014-05-14.
56599 2016-12-16  Paul Eggert  <eggert@cs.ucla.edu>
56601         builtin-expect: improve port to IBM XL C
56602         Problem reported for z/OS by Daniel Richard G. in:
56603         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00079.html
56604         * m4/builtin-expect.m4 (gl___BUILTIN_EXPECT):
56605         Test for <builtins.h> directly.
56607         builtin-expect: port to IBM XL C
56608         Problem reported for z/OS by Daniel Richard G. in:
56609         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00074.html
56610         * m4/builtin-expect.m4 (gl___BUILTIN_EXPECT):
56611         Also allow __builtin_expect defined via a standard include file.
56613         regex: fix dependency
56614         Problem reported by Bruno Haible in:
56615         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00073.html
56616         * modules/regex: Depend on builtin-expect.
56618         builtin-expect: new module
56619         Fix fnmatch to use it.
56620         Problem reported for z/OS by Daniel Richard G.
56621         * lib/fnmatch.c (__builtin_expect):
56622         * lib/glob.c (__builtin_expect):
56623         * lib/grantpt.c (__builtin_expect) [!_LIBC]:
56624         * lib/memmem.c (__builtin_expect) [!_LIBC]:
56625         * lib/scandir.c (__builtin_expect):
56626         * lib/strstr.c (__builtin_expect) [!_LIBC]:
56627         Remove macro; config.h now does this.
56628         * lib/gl_anytreehash_list1.h (add_to_bucket):
56629         * lib/regex_internal.h (BE):
56630         Assume __builtin_expect.
56631         * m4/builtin-expect.m4, modules/builtin-expect: New files.
56632         * modules/avltreehash-list, modules/fnmatch, modules/glob:
56633         * modules/grantpt, modules/memmem-simple, modules/rbtreehash-list:
56634         * modules/scandir, modules/strstr-simple:
56635         Depend on builtin-expect.
56637 2016-12-15  Bruno Haible  <bruno@clisp.org>
56639         init.sh: Add possibility to not delete temporary files.
56640         * tests/init.sh (remove_tmp_): If the environment variable KEEP is set
56641         to yes, don't erase the temporary directory.
56643 2016-12-16  Paul Eggert  <eggert@cs.ucla.edu>
56645         regex: fix integer-overflow bug in never-used code
56646         Problem reported by Clément Pit–Claudel in:
56647         http://lists.gnu.org/r/emacs-devel/2016-12/msg00654.html
56648         * lib/regex_internal.h: Include intprops.h.
56649         * lib/regexec.c (re_search_2_stub): Use it to avoid undefined
56650         behavior on integer overflow.
56651         * modules/regex (Depends-on): Add intprops.
56653         fpending: fix port to MinGW on Emacs
56654         * lib/stdio-impl.h [__MINGW32__]: Do not include errno.h.
56655         Problem reported by Eli Zaretskii in:
56656         http://lists.gnu.org/r/emacs-devel/2016-12/msg00642.html
56657         Is Plan 9 still a valid porting target, anyway?
56659 2016-12-15  Paul Eggert  <eggert@cs.ucla.edu>
56661         safe-alloc: use xalloc-oversized
56662         * lib/safe-alloc.c: Include xalloc-oversized.h.
56663         (safe_alloc_oversized): Remove.  All uses changed to xalloc_oversized.
56664         * modules/safe-alloc (Depends-on): Add xalloc-oversized.
56666         xalloc: do not exceed PTRDIFF_MAX
56667         * lib/xmalloc.c (xcalloc) [HAVE_GNU_CALLOC]: Do not omit
56668         xalloc_oversized check, since objects larger than PTRDIFF_MAX
56669         bytes have pointer-subtraction problems.
56671         malloca: do not exceed PTRDIFF_MAX
56672         * lib/malloca.h: Include xalloc-oversized.
56673         (nmalloca): Use xalloc_oversized instead of rolling our own.
56674         * modules/malloca (Depends-on):
56675         * modules/relocatable-prog-wrapper (Depends-on):
56676         Add xalloc-oversized.
56678         quotearg: pacify GCC better
56679         * modules/quotearg (Depends-on): Add minmax, stdint.
56680         * lib/quotearg.c: Include minmax.h, stdint.h.
56681         (nslots): Now int, as there seems little point to going to extra
56682         work merely to support the INT_MAX slot, which nobody ever uses.
56683         (quotearg_n_options): Redo size-overflow checks to pacify GCC
56684         and to catch (mostly-theoretical) ptrdiff_t problems too.
56685         This can be done via one comparison.
56687 2016-12-14  Paul Eggert  <eggert@cs.ucla.edu>
56689         xalloc-oversized: check for PTRDIFF_MAX too
56690         This avoids undefined behavior when subtracting pointers to
56691         objects containing more than PTRDIFF_MAX bytes.
56692         * lib/xalloc-oversized.h (__xalloc_oversized, xalloc_oversized):
56693         Also return 1 if the result would exceed PTRDIFF_MAX>
56694         * modules/xalloc-oversized (Depends-on):
56695         Add stdint.
56697         dfa: fix glitches in previous commit
56698         Sorry, I don't know how I managed to commit the wrong version.
56699         * lib/dfa.c (MIN): Move up.
56700         (xpalloc): Now static.
56702         dfa: fix some unlikely integer overflows
56703         I found these while reviewing the recent Coverity-related fix.
56704         This patch changes part of dfa.c to prefer ptrdiff_t instead of
56705         size_t for object counts.  Using ptrdiff_t is the style typically
56706         used in Emacs; although it wastes a sign bit as sizes can never be
56707         negative, it makes -fsanitize=undefined more likely to catch
56708         integer overflows in index calculation, and nowadays the upside is
56709         typically more important than the downside.  Although perhaps the
56710         rest of dfa.c should be changed to prefer ptrdiff_t as well (much
56711         of dfa.c already does, since it uses state_num which is signed),
56712         that is a bigger change and is not needed to fix the bugs I found.
56713         * lib/dfa.c: Include stdint.h and intprops.h.
56714         (TOKEN_MAX): New macro.
56715         (position_set, struct mb_char_classes, struct dfa, maybe_realloc)
56716         (charclass_index, parse_bracket_exp, addtok, insert, merge)
56717         (realloc_trans_if_necessary, free_mbdata):
56718         Use ptrdiff_t instead of size_t for object counts related to xpalloc.
56719         This is safe because xpalloc checks that the sizes do not exceed
56720         either SIZE_MAX or PTRDIFF_MAX.
56721         (xpalloc): New function, mostly taken from Emacs.
56722         (maybe_realloc, copy, realloc_trans_if_necessary): Use it.
56723         (maybe_realloc): Add NITEMS_MAX to signature.  All callers changed.
56724         (charclass_index): Check for integer overflow in computing
56725         charclass index; it must not exceed TOKEN_MAX - CSET, as CSET is
56726         added to it later.
56727         (alloc_position_set): Check for integer overflow.  On typical
56728         platforms this check has zero overhead, since the constant
56729         expression is false.
56730         (realloc_trans_if_necessary):
56731         Remove assertion, which I hope Coverity no longer needs.
56733         * modules/dfa (Depends-on): Add intprops, stdint.
56735 2016-12-12  Jim Meyering  <meyering@fb.com>
56737         dfa: add an assertion to avoid coverity false positive
56738         * lib/dfa.c (realloc_trans_if_necessary): Otherwise, coverity
56739         warned that "newalloc1 - 2" could overflow.
56741 2016-12-13   Arnold D. Robbins  <arnold@skeeve.com>
56743         dfa: remove DFA_CASE_FOLD flag in favor of RE_ICASE
56744         * dfa.h (DFA_CASE_FOLD): Remove.
56745         * dfa.c (dfasyntax): Set dfa->syntax.case_fold based on RE_ICASE.
56747 2016-12-13  John W. Eaton  <gnu@jweaton.org>
56749         link: fix test to declare use of rename()
56750         * m4/link.m4 (gl_FUNC_LINK): Include <stdio.h> needed with
56751         -Werror=implicit-function-declaration
56753 2016-12-12  Bruno Haible  <bruno@clisp.org>
56755         fpending: Port to native Windows with MSVC.
56756         * lib/fpending.c: Include stdio-impl.h.
56757         (__fpending): Include all known implementations. Err out if it's not
56758         ported.
56759         * m4/fpending.m4 (gl_PREREQ_FPENDING): Remove macro.
56760         * modules/fpending (Files): Add lib/stdio-impl.h.
56761         (configure.ac): Don't invoke gl_PREREQ_FPENDING.
56763 2016-12-12  Bruno Haible  <bruno@clisp.org>
56765         stdioext: Port to native Windows with MSVC.
56766         * lib/stdio-impl.h (WINDOWS_OPAQUE_FILE): New macro.
56767         (struct _gl_real_FILE): New type.
56768         (fp_, _IOREAD, _IOWRT, _IORW, _IOEOF, _IOERR): New macros, for native
56769         Windows.
56770         * lib/fbufmode.c (fbufmode): Add code for native Windows.
56771         * lib/fflush.c (clear_ungetc_buffer): Treat native Windows like the
56772         other SystemV derived implementations.
56773         * lib/fpurge.c (fpurge): Likewise.
56774         * lib/freadable.c (freadable): Likewise.
56775         * lib/freadahead.c (freadahead): Likewise.
56776         * lib/freading.c (freading): Likewise.
56777         * lib/freadptr.c (freadptr): Likewise.
56778         * lib/freadseek.c (freadptrinc): Likewise.
56779         * lib/fseeko.c (fseeko): Likewise.
56780         * lib/fseterr.c (fseterr): Likewise.
56781         * lib/fwritable.c (fwritable): Likewise.
56782         * lib/fwriting.c (fwriting): Likewise.
56783         Reported by Gisle Vanem <gvanem@yahoo.no>.
56785 2016-12-11  Jim Meyering  <meyering@fb.com>
56787         non-recursive-gnulib-prefix-hack.m4: remove leading "(" in case stmt
56788         * m4/non-recursive-gnulib-prefix-hack.m4: That leading "(" happens
56789         to work with most shells, but not with the one provided by many
56790         Solaris 10 systems, so running configure with such a /bin/sh evokes
56791         e.g., "./configure: syntax error at line 33602: `(' unexpected".
56792         Reported by Assaf Gordon in
56793         https://lists.gnu.org/r/sed-devel/2016-12/msg00002.html
56795 2016-12-10  Bruno Haible  <bruno@clisp.org>
56797         threadlib: Optimize out runtime test on Solaris >= 10.
56798         * m4/threadlib.m4 (gl_THREADLIB_BODY): Don't set
56799         PTHREAD_IN_USE_DETECTION_HARD if configuring on Solaris 10 or newer.
56800         Reported by Peter Felecan at <https://savannah.gnu.org/bugs/?32087>.
56802 2016-12-10  Bruno Haible  <bruno@clisp.org>
56804         stdint: Update doc about Solaris 9.
56805         * doc/posix-headers/stdint.texi: Add info about Solaris 9.
56807 2016-12-09  Bruno Haible  <bruno@clisp.org>
56809         c-ctype tests: Fix link error on Solaris 9.
56810         * modules/c-ctype-tests (Depends-on): Add 'isblank'.
56811         Reported at <https://savannah.gnu.org/bugs/?46827>.
56813 2016-12-09  Paul Eggert  <eggert@cs.ucla.edu>
56815         dfa: fix performance bug that recomputes trans
56816         * lib/dfa.c (build_state): Fix performance bug introduced in Nov
56817         25 on-demand changes.  The bug caused build_state to reset all
56818         d->trans elements to -2 even when d->trans was already non-null.
56819         Use C99 style decls after statements in this function.
56821         same-inode: port to MinGW
56822         Here st_ino is always 0, so change the definition of SAME_INODE so
56823         that 1 means the two files are the same, 0 with st_ino != 0 means
56824         they differ, and 0 with st_ino == 0 means we don’t know.  Problem
56825         reported by Bruno Haible (Bug#25146).
56826         * doc/posix-headers/sys_stat.texi (sys/stat.h): Update.
56827         * lib/same-inode.h (SAME_INODE): Return 0 on MinGW.
56829 2016-12-04  Bruno Haible  <bruno@clisp.org>
56831         javacomp-script: Support Java 7 and 8.
56832         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 1.7, 1.8 and
56833         target-version 1.7, 1.8.
56835 2016-12-02  Daiki Ueno  <ueno@gnu.org>
56837         * gnulib-tool (func_import): Relax the regex used for "LGPLv3+ or
56838         GPLv2" rewriting.
56840 2016-12-02  Nikos Mavrogiannopoulos  <nmav@gnutls.org>
56842         * gnulib-tool (func_import): Adhere to the license guideline when
56843         rewriting the license text to "LGPLv3+ or GPLv2":
56844         https://www.gnu.org/prep/maintain/maintain.html#Licensing-of-GNU-Packages
56846 2016-12-02  Bruno Haible  <bruno@clisp.org>
56848         localcharset: Avoid theoretical buffer overrun.
56849         * lib/localcharset.c (locale_charset) [WINDOWS_NATIVE]: Don't use the
56850         return value from setlocale if it would lead to a buffer overrun.
56852 2016-12-01  Bruno Haible  <bruno@clisp.org>
56854         Relicense some modules under LGPLv2+.
56855         Kevin Cernekee's approval is in
56856         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00090.html.
56857         * modules/fseterr (License): Change to LGPLv2+.
56858         * modules/mbchar (License): Likewise.
56859         * modules/mbiter (License): Likewise.
56860         * modules/mbsnlen (License): Likewise.
56861         * modules/wcwidth (License): Likewise.
56863 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
56865         scandir: Fix _D_ALLOC_NAMLEN() on OS/2 kLIBC
56866         * lib/scandir.c (_D_ALLOC_NAMLEN): Consider the fields after d_name on
56867         OS/2 kLIBC.
56869 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
56871         alphasort, scandir: Port to OS/2 kLIBC
56872         * lib/alphasort.c (alphasort): Implement according to OS/2 kLIBC
56873         declaration.
56874         * lib/scandir.c (scandir): Add declaration for OS/2 kLIBC.
56876 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
56878         relocatable: Fix that /@unixroot prefix is not working on OS/2 kLIBC
56879         * lib/relocatable.c (relocate): Do not touch pathname if it is started
56880         with '/@unixroot'.
56882 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
56884         sys_socket: typedef sa_family_t correctly on OS/2 kLIBC
56885         * lib/sys_socket.in.h (sa_family_t): Typedef to unsigned char on
56886         OS/2 kLIBC unless TCPV40HDRS is defined.
56888 2016-11-29  Jim Meyering  <meyering@fb.com>
56890         dfa: avoid new infinite loop
56891         This would infloop: echo cx | LC_ALL=C grep -E 'c\b[x ]'
56892         * lib/dfa.c (dfastate): When constructing a new state table, we could
56893         initially declare that we had found a match, and later find that
56894         constraints eliminate that possibility, yet continue to use the
56895         now stale "matched" indicator.  That would lead to an infinite loop.
56896         The solution is to update "matched" when necessary.
56897         Introduced by commit v0.1-983-g403adf1.
56899 2016-11-27  Norihiro Tanaka  <noritnk@kcn.ne.jp>
56901         dfa: avoid match middle in multibyte character
56902         * lib/dfa.c (transit_state): If fails in matching single byte characters
56903         on a state including period expression in non-UTF8 multibyte locales,
56904         skip trailing bytes.
56905         (dfa_supported): Revert previous change.
56907 2016-11-27  Jim Meyering  <meyering@fb.com>
56909         dfa: avoid false match in non-UTF8 multibyte locales
56910         * lib/dfa.c (dfa_supported): Treat any non-UTF8 multibyte locale
56911         as "not supported" so that callers will resort to using regex-based
56912         matcher.  This will surely hurt performance, but correctness trumps
56913         performance here, and the affected locales are less and less relevant,
56914         these days.  See grep's bug report https://bugs.gnu.org/24975.
56916 2016-11-27  Mike Frysinger  <vapier@gentoo.org>
56918         ptsname_r: leverage AC_HEADER_MAJOR to provide major()
56919         * lib/ptsname_r.c: Include the appropriate headers.
56920         [__sun]: Delete sys/sysmacros.h include.
56921         [_AIX || __osf__]: Likewise.
56922         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Depend on AC_HEADER_MAJOR.
56924 2016-11-27  Pádraig Brady  <P@draigBrady.com>
56926         md4,md5,sha*: allow _STRING_INLINE_unaligned enable unaligned operation
56927         * lib/md4.c (md4_process_bytes): The existing define is made internal
56928         in recent versions of glibc, so also use this new public define.
56929         * lib/md5.c (md5_process_bytes): Likewise.
56930         * lib/sha1.c (sha1_process_bytes): Likewise.
56931         * lib/sha256.c (sha256_process_bytes): Likewise.
56932         * lib/sha512.c (sha512_process_bytes): Likewise.
56934 2016-11-27  Pádraig Brady  <P@draigBrady.com>
56936         maint: use a more standard return from mbrtowc test
56937         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): Don't return 1
56938         from the test program as this often indicates an
56939         unhandled case in the test program.
56940         (gl_MBRTOWC_INCOMPLETE_STATE): Likewise.
56941         (gl_MBRTOWC_SANITYCHECK): Likewise.
56942         (gl_MBRTOWC_NULL_ARG2): Likewise.
56943         (gl_MBRTOWC_NUL_RETVAL): Likewise.
56945 2016-11-26  Paul Eggert  <eggert@cs.ucla.edu>
56947         freopen: work around glibc bug with closed fd
56948         Work around glibc bug#15589, where freopen mishandles the case
56949         where stdin etc. are already closed.
56950         * doc/posix-functions/freopen.texi (freopen): Document the bug.
56951         * lib/freopen.c (_GL_ALREADY_INCLUDING_STDIO_H): Define this
56952         instead of __need_FILE, as the latter does not work with glibc.
56953         Include <fcntl.h>, for open flags.
56954         (rpl_freopen): Work around glibc bug.
56955         * m4/freopen.m4 (gl_FUNC_FREOPEN): Check for bug.
56956         * modules/freopen (Depends-on): Add fcntl-h.
56957         * tests/test-freopen.c (main): Test for bug.
56959 2016-11-25  Paul Eggert  <eggert@cs.ucla.edu>
56961         fnmatch: fix typo introduced on 2016-08-17
56962         This fixes the port to non-GCC compilers that lack __builtin_expect.
56963         * lib/fnmatch.c (__builtin_expect): Change A&&B to !A||B.
56965         dfa: simplify with new function fillset
56966         * lib/dfa.c (fillset): New function.
56967         Use it for clarity when applicable.
56969         dfa: fix glitches with on-demand states
56970         Also, adjust commentary to better match new code.
56971         Some of these glitches predate the recent change.
56972         * lib/dfa.c (dfaanalyze): Clear trcount here, so that it counts
56973         only non-initial states.
56974         (dfastate): Rename locals to better match new roles.
56975         Move them into nested scopes if this is easy.
56976         Omit unnecessary calls to zeroset.
56977         Simplify test for whether to throw in the positions of state 0.
56978         Omit C99-ism (decl after statement) since Gawk still wants C89.
56979         (build_state): Omit unnecessary test and assignment.
56980         Fix some confusion that counted transition tables inaccurately
56981         and could cause a memory leak.
56982         (dfaexec_main): Redo to make it clearer to the compiler that
56983         -1 and -2 are the only negative state numbers here.
56985 2016-11-25  Norihiro Tanaka  <noritnk@kcn.ne.jp>
56987         dfa: addition of new state on demand
56988         * src/dfa.c (dfastate): Add argument UC, the current input character.
56989         Fill only a group including the character in transition table.
56990         (realloc_trans_if_necessary): Add the dummy state which means that a
56991         transition table is assigned but the next state is not assigned.
56992         (build_state): Return the next state.  All callers updated.
56993         (transit_state_singlebyte): If we get the dummy state,
56994         fill the transition table.
56995         (dfaexec_main): Handle the dummy state.
56996         (free_mbdata, dfafree): Consider the dummy state.
56998 2016-11-24  Daiki Ueno  <ueno@gnu.org>
57000         srclist: sync with released gettext
57001         * config/srclist.txt: Set "release" option to the files under
57002         $GETTEXT.
57004 2016-11-24  Daiki Ueno  <ueno@gnu.org>
57006         srclist: add "release" option
57007         * config/srclist.txt: Change the format so that the first column
57008         of each line points to the top-level directory of the source
57009         archive.
57010         * config/srclist-update: Accept "release" option that checks files
57011         from the most recently tagged revision in the source archive.
57013 2016-11-21  Bruno Haible  <bruno@clisp.org>
57015         snippet/c++defs: Simplify _GL_CXXALIAS_* macros.
57016         * build-aux/snippet/c++defs.h [__cplusplus && GNULIB_NAMESPACE]
57017         (_GL_CXXALIAS_RPL_1, _GL_CXXALIAS_RPL_CAST_1,
57018         _GL_CXXALIAS_SYS, _GL_CXXALIAS_SYS_CAST, _GL_CXXALIAS_SYS_CAST2):
57019         Inline and remove member function 'rpl ()' of the wrapper struct.
57021 2016-11-20  Paul Eggert  <eggert@cs.ucla.edu>
57023         dfa: fix logic typo
57024         Problem reported by Stephane Chazelas (Bug#24973).
57025         * lib/dfa.c (using_simple_locale): Fix typo that caused some
57026         non-simple locales like fr_FR to be treated as simple.
57028 2016-11-20  Jim Meyering  <meyering@fb.com>
57030         fix test driver leaks: exclude, malloc, realloc
57031         * tests/test-exclude.c (main): Fix trivial leak.
57032         * tests/test-malloc-gnu.c (main): Likewise.
57033         * tests/test-realloc-gnu.c (main): Likewise.
57034         With these changes, grep's tests are now leak free.
57035         I.e., running them with ASAN elicits no failure:
57036           make CFLAGS='-O0 -ggdb3' AM_CFLAGS=-fsanitize=address \
57037             AM_LDFLAGS='-fsanitize=address -static-libasan' check
57039 2016-11-11  Bruno Haible  <bruno@clisp.org>
57041         libunistring: Relicense under dual "LGPLv3+ or GPLv2" license.
57042         * modules/libunistring: (License): Change from LGPL to
57043         "LGPLv3+ or GPLv2".
57044         * modules/libunistring-optional: Likewise.
57045         * modules/unicase/*: Likewise.
57046         * modules/uniconv/*: Likewise.
57047         * modules/unictype/*: Likewise.
57048         * modules/unigbrk/*: Likewise.
57049         * modules/unilbrk/*: Likewise.
57050         * modules/uniname/*: Likewise.
57051         * modules/uninorm/*: Likewise.
57052         * modules/unistdio/*: Likewise.
57053         * modules/unistr/*: Likewise.
57054         * modules/uniwbrk/*: Likewise.
57055         * modules/uniwidth/*: Likewise.
57057 2016-11-12  Bruno Haible  <bruno@clisp.org>
57059         Relicense some modules under LGPLv2+.
57060         Paul Eggert's approval is in
57061         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00037.html.
57062         Eric Blake's approval is in
57063         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00042.html.
57064         Ludovic Courtès's approval is in
57065         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00038.html.
57066         * modules/isnand-nolibm (License): Change to LGPLv2+.
57067         * modules/isnanf-nolibm (License): Likewise.
57068         * modules/isnanl-nolibm (License): Likewise.
57070 2016-11-19  Bruno Haible  <bruno@clisp.org>
57072         Relicense some modules under LGPLv2+.
57073         lib/float+.h is already under LGPLv2+ since 2007-07-13, per
57074         modules/vasnprintf.
57075         Paolo Bonzini's approval for lib/frexp.c and lib/frexpl.c is in
57076         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00074.html.
57077         All other significant changes to the files in lib/ of these modules
57078         are from me.
57079         * modules/memcmp2 (License): Change to LGPLv2+.
57080         * modules/amemxfrm (License): Likewise.
57081         * modules/fpieee (License): Likewise.
57082         * modules/fpucw (License): Likewise.
57083         * modules/frexp-nolibm (License): Likewise.
57084         * modules/frexpl-nolibm (License): Likewise.
57085         * modules/printf-frexp (License): Likewise.
57086         * modules/printf-frexpl (License): Likewise.
57087         * modules/printf-safe (License): Likewise.
57088         * modules/signbit (License): Likewise.
57090 2016-11-17  Bruno Haible  <bruno@clisp.org>
57092         Enable Unicode decoder safety unconditionally.
57093         * lib/unistr.in.h (u32_mbtouc_unsafe): Assume CONFIG_UNICODE_SAFETY.
57094         * lib/unistr/u8-mblen.c (u8_mblen): Likewise.
57095         * lib/unistr/u8-mbtouc-unsafe.c (u8_mbtouc_unsafe): Likewise.
57096         * lib/unistr/u8-mbtouc-unsafe-aux.c (u8_mbtouc_unsafe_aux): Likewise.
57097         * lib/unistr/u8-prev.c (u8_prev): Likewise.
57098         * lib/unistr/u8-strmblen.c (u8_strmblen): Likewise.
57099         * lib/unistr/u8-strmbtouc.c (u8_strmbtouc): Likewise.
57100         * lib/unistr/u16-mblen.c (u16_mblen): Likewise.
57101         * lib/unistr/u16-mbtouc-unsafe.c (u16_mbtouc_unsafe): Likewise.
57102         * lib/unistr/u16-mbtouc-unsafe-aux.c (u16_mbtouc_unsafe_aux): Likewise.
57103         * lib/unistr/u16-prev.c (u16_prev): Likewise.
57104         * lib/unistr/u16-strmblen.c (u16_strmblen): Likewise.
57105         * lib/unistr/u16-strmbtouc.c (u16_strmbtouc): Likewise.
57106         * lib/unistr/u32-mblen.c (u32_mblen): Likewise.
57107         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Likewise.
57108         * lib/unistr/u32-prev.c (u32_prev): Likewise.
57109         * lib/unistr/u32-next.c (u32_next): Likewise.
57110         * lib/unistr/u32-strmblen.c (u32_strmblen): Likewise.
57111         * lib/unistr/u32-strmbtouc.c (u32_strmbtouc): Likewise.
57112         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
57113         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
57114         * tests/unistr/test-u16-prev.c (check_invalid): Enable the
57115         CONFIG_UNICODE_SAFETY tests unconditionally.
57116         * tests/unistr/test-u32-mblen.c (main): Likewise.
57117         * tests/unistr/test-u32-mbtouc.h (test_function): Likewise.
57118         * tests/unistr/test-u32-prev.c (check_invalid): Likewise.
57119         * tests/unistr/test-u32-next.c (main): Likewise.
57120         * tests/unistr/test-u32-strmblen.c (main): Likewise.
57121         * tests/unistr/test-u32-strmbtouc.c (main): Likewise.
57122         * tests/unistr/test-u32-mbtouc.c (FULL_SAFETY): Remove macro.
57123         * lib/unistr/u8-check.c (u8_check): Remove old dead code.
57124         * lib/unistr/u8-mbtouc.c (u8_mbtouc): Likewise.
57125         * lib/unistr/u8-mbtouc-aux.c (u8_mbtouc_aux): Likewise.
57126         * lib/unistr/u8-mbtoucr.c (u8_mbtoucr): Likewise.
57127         * lib/unistr/u8-uctomb.c (u8_uctomb): Likewise.
57128         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Likewise.
57129         * lib/unistr/u16-check.c (u16_check): Update comment.
57130         * NEWS: Mention the changes that callers should be aware of.
57132 2016-11-19  Bruno Haible  <bruno@clisp.org>
57134         relocatable-prog-wrapper: Fix breakage on Cygwin.
57135         * modules/relocatable-prog-wrapper (Files): Add lib/stat.c, lib/lstat.c.
57136         (Depends-on): Remove intprops.
57137         * lib/relocwrapper.c: Update dependency tree.
57138         (strerror): Undefine.
57139         * build-aux/install-reloc (func_create_wrapper): Do not compile
57140         strerror.c and strerror-override.c. Erase stat.o and lstat.o.
57142 2016-11-19  Bruno Haible  <bruno@clisp.org>
57144         strerror: Make it compile in C++ mode.
57145         * lib/strerror.c (strerror): Ignore the return value of memcpy().
57147 2016-11-15  Pedro Alves  <palves@redhat.com>
57149         sys_time: add gnulib::timeval for C++
57150         * lib/sys_time.in.h [__cplusplus && defined GNULIB_NAMESPACE]:
57151         Define "timeval" in the GNULIB_NAMESPACE namespace, and #undef any
57152         timeval macro.
57154 2016-11-14  Pedro Alves  <palves@redhat.com>
57156         snippet/c++defs: fix real-floating arg functions in C++ mode
57157         Also, define isfinite, isinf, isnan, signbit in the gnulib
57158         namespace instead of in the global namespace.
57159         * build-aux/snippet/c++defs.h (_GL_BEGIN_NAMESPACE)
57160         (_GL_END_NAMESPACE): New.
57161         * lib/math.in.h (_GL_MATH_CXX_REAL_FLOATING_DECL_2): Use them.
57162         (isfinite, isinf, isnan, signbit) [__cplusplus &&
57163         GNULIB_NAMESPACE]: Define them in the GNULIB_NAMESPACE namespace
57164         instead of in the global namespace.
57165         * tests/test-math-c++.cc: Check that the isfinite, isinf, isnan,
57166         signbit overloads exist in the GNULIB_NAMESPACE namespace, instead
57167         of in the global namespace.
57169 2016-11-13  Jim Meyering  <meyering@fb.com>
57171         strftime: don't use __THROW
57172         Each use of __THROW would provoke this from gcc-7-to-be:
57174           lib/strftime.c:371:1: warning: '__leaf__' attribute has no effect \
57175             on unit local functions [-Wattributes]
57176           static int iso_week_days (int, int) __THROW;
57177           ^~~~~~
57178         * lib/strftime.c (__THROW): Don't define.
57179         Remove each use of __THROW.
57180         * lib/strftime.c (memcpy_lowcase, memcpy_uppcase): Remove __THROW.
57181         (tm_diff, iso_week_days, __strftime_internal): Likewise.
57183 2016-11-14  Paul Eggert  <eggert@union>
57185         obstack: port to gcc -fcheck-pointer-bounds
57186         Problem found by 'make check' failure on bleeding-edge coreutils
57187         on an MPX-enabled CPU (Intel Core i3-7100U) running GCC (Ubuntu
57188         6.2.0-5ubuntu12), configured via "./configure
57189         --enable-gcc-warnings CFLAGS='-mmpx -fcheck-pointer-bounds -g3
57190         -O2' LDFLAGS='-static-libmpx -static-libmpxwrappers'".
57191         * lib/obstack.h (__FLEXIBLE_ARRAY_MEMBER):
57192         New macro, copied from fts_.h.
57193         (struct _obstack_chunk.contents): Use it.
57195 2016-11-14  Eric Blake  <eblake@redhat.com>
57197         strerror_r-posix: Another fix, for HAVE_DECL_STRERROR_R on mingw.
57198         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R, gl_FUNC_STRERROR_R_WORKS):
57199         Avoid _ONCE variants, which may supply a conflicting AC_DEFINE().
57201 2016-11-14  Pádraig Brady  <P@draigBrady.com>
57203         strptime: fix compile error in recent change
57204         * lib/strptime.c (__strptime_internal): Fix ported code.
57206 2016-11-11  Bruno Haible  <bruno@clisp.org>
57208         gnulib-tool: Support for the dual "LGPLv3+ or GPLv2" license.
57209         * gnulib-tool (--lgpl): Accept value 3orGPLv2.
57210         (func_import): Extend determination of license_incompatibilities.
57211         (func_create_testdir): Extend table of license compatibility. Handle
57212         also the licenses GPLv3+, GPL, LGPLv3+.
57214 2016-11-12  Paul Eggert  <eggert@cs.ucla.edu>
57216         strftime: tune %q
57217         * lib/strftime.c (__strftime_internal): Assume tp->tm_mon is in range.
57219         Merge strftime.c changes from glibc
57220         This incorporates:
57221         2007-10-16 [BZ #5184] Add tzset_called argument
57222         2008-06-13 [BZ #6612] pass reference to tzset_called around
57223         2009-10-30 Implement Burmese language locale for Myanmar
57224         2010-01-09 Add support for XPG7 testing
57225         2015-09-26 [BZ #18985] out of range data to strftime() causes a segfault
57226         2015-10-20 Convert miscellaneous function definitions to prototype style
57227         * lib/strftime.c: Copy glibc license, since gnulib-tool rewrites
57228         it anyway and this lessens the difference between gnulib and glibc.
57229         (USE_IN_EXTENDED_LOCALE_MODEL) [_LIBC]: Define.
57230         (__THROW): Define if standard headers do not.
57231         (LOCALE_PARAM): Rename from LOCALE_PARAM_PROTO.  All uses changed.
57232         (memcpy_locase, memcpy_uppcase, tm_diff, __strftime_internal):
57233         Declare with __THROW.
57234         (__strftime_internal): Rename from strftime_case_. Add arg for
57235         whether tzset is called.  All uses changed.  Call tzset at most
57236         once.  Allow %OC, for Burmese.
57237         (a_wkday, f_wkday, a_month, f_month) [_NL_CURRENT]:
57238         Don't assume values are in range.
57240 2016-11-12  Eric Blake  <eblake@redhat.com>
57242         strerror_r-posix: Fix override of AC_FUNC_STRERROR_R
57243         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): New override.
57244         (gl_FUNC_STRERROR_R): Don't reuse AC_DEFINE() with a potentially
57245         different value.
57247 2006-11-12  Pedro Alves  <palves@redhat.com>
57249         Fix gnulib C++ namespace support and std::frexp
57250         * lib/math.in.h (frexp): Use _GL_CXXALIASWARN1 instead of
57251         _GL_CXXALIASWARN.
57253 2006-11-12  Pedro Alves  <palves@redhat.com>
57255         GNULIB_NAMESPACE::func need not pull in rpl_func
57256         * build-aux/snippet/c++defs.h [__cplusplus && GNULIB_NAMESPACE]
57257         (_GL_CXXALIAS_RPL_1, _GL_CXXALIAS_RPL_CAST_1, _GL_CXXALIAS_SYS)
57258         (_GL_CXXALIAS_SYS_CAST, _GL_CXXALIAS_SYS_CAST2): Define a wrapper
57259         struct instead of a function pointer.
57261 2016-11-09  Frediano Ziglio  <fziglio@redhat.com>
57263         manywarnings: fix -Wno-missing-field-initializers detection
57264         * m4/manywarnings.m4: Fix -Wno-missing-field-initializers detection
57265         to be independent of -Wunused-variable.  I.E. ensure the latter
57266         warning doesn't occur so that detection of the former is accurate.
57268 2016-11-05  Pádraig Brady  <pbrady@fb.com>
57270         strftime,strptime: support %q to represent the quarter
57271         * lib/strftime.c (strftime_case_): Add %q case.
57272         * lib/strptime.c (__strptime_internal): Likewise.
57273         * tests/test-strftime.c (quarter_test): A new test case.
57275 2016-11-03  Eric Blake  <eblake@redhat.com>
57277         bootstrap: Fix get_version() for AIX 5.3
57278         * build-aux/bootstrap (get_version): Factor out sed script, since
57279         indented comments choke AIX 5.3 sed.
57280         Reported-by: Michael Felt <aixtools@gmail.com>
57282 2016-11-03  Paul Eggert  <eggert@cs.ucla.edu>
57284         intprops: port to older XL C
57285         Problem reported by Alexander Samoilov in:
57286         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00166.html
57287         http://savannah.nongnu.org/bugs/?49448
57288         * lib/intprops.h (_GL_HAVE___TYPEOF__) [__IBM__TYPEOF__]:
57289         Define to 1 only for XL C 12.1 or later, since this bug
57290         occurs in XL C for AIX 6.0 but not in 12.1.
57292 2016-11-02  Pádraig Brady  <P@draigBrady.com>
57294         backupfile: initialize default suffix within the implementation
57295         * lib/backupfile.c (find_backup_file_name): Initialize the
57296         global variable here, to simplify usage, and to only call
57297         getenv() when needed.
57299 2016-11-01  Paul Eggert  <eggert@cs.ucla.edu>
57301         futimens: remove FIXME for old Linux kernels
57302         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Belatedy do a "simplify
57303         this in 2012" FIXME, like that for utimensat.
57305         utimensat: remove FIXME for old Linux kernels
57306         * lib/utimensat.c (rpl_utimensat): Update FIXME comment.
57307         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Belatedy do a "simplify
57308         this in 2012" FIXME, by assuming the file system bug is absent
57309         unless demonstrated to be present.  We no longer need to worry
57310         about Linux kernel 2.6.32 when building with newer kernels.
57312 2016-10-16  Bruno Haible  <bruno@clisp.org>
57314         qsort_r: Fix macrology for platforms that lack the function.
57315         * m4/stdlib_h.m4 (gl_STDLIB_H): Check for qsort_r.
57316         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_QSORT_R.
57317         * modules/stdlib (Makefile.am): Substitute HAVE_QSORT_R.
57318         * lib/stdlib.in.h (qsort_r): Provide declaration if the function does
57319         not exist.
57320         * m4/qsort_r.m4 (gl_FUNC_QSORT_R): Use AC_CHECK_FUNCS to test whether
57321         the function exists.
57322         * modules/qsort_r: Add comments.
57324 2016-10-26  Paul Eggert  <eggert@cs.ucla.edu>
57326         sys_types: fix Texinfo typos
57327         * doc/glibc-functions/gnu_dev_major.texi:
57328         * doc/glibc-functions/gnu_dev_makedev.texi:
57329         * doc/glibc-functions/gnu_dev_minor.texi: Fix typos.
57331 2016-10-26  John David Anglin  <dave.anglin@bell.net>
57333         getprogname: port to HP-UX
57334         See Bug#24805.
57335         * lib/getprogname.c (getprogname) [__hpux]: Port.
57336         * tests/test-getprogname.c (STREQ) [__hpux]:
57337         Special-case for HP-UX limitations on program name length.
57339 2016-10-20  Bruno Haible  <bruno@clisp.org>
57341         Update doc about target platforms.
57342         * doc/gnulib-intro.texi (Target Platforms): Update list.
57344 2016-10-15  Bruno Haible  <bruno@clisp.org>
57346         opendir, readdir, closedir: Relicense under LGPLv2+.
57347         * modules/opendir (License): Change to LGPLv2+.
57348         * modules/readdir (License): Likewise.
57349         * modules/closedir (License): Likewise.
57351 2016-10-16  Bruno Haible  <bruno@clisp.org>
57353         Fix conflict between strerror_r-posix module and AC_FUNC_STRERROR_R.
57354         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Override the values set by the
57355         AC_FUNC_STRERROR_R macro. Define HAVE_DECL_STRERROR_R_ORIG.
57356         * lib/strerror_r.c: Use HAVE_DECL_STRERROR_R_ORIG instead of
57357         HAVE_DECL_STRERROR_R.
57359 2016-10-16  Bruno Haible  <bruno@clisp.org>
57361         Make the 'argp' module work without the 'error' module.
57362         * m4/argp.m4 (gl_ARGP): Require AC_FUNC_STRERROR_R.
57364 2016-10-25  Paul Eggert  <eggert@cs.ucla.edu>
57366         diffseq: restore TOO_EXPENSIVE heuristic
57367         * lib/diffseq.h: Problem with diffutils reported by Andreas Schwab
57368         (Bug#24715).  The simplest solution is to restore the
57369         TOO_EXPENSIVE heuristic that I added to GNU diff in 1993, while
57370         using a higher threshold to avoid Bug#16848 on smaller files.
57371         * lib/diffseq.h (struct context): Restore member too_expensive.
57372         (struct partition): Restore members lo_minimal, hi_minimal.
57373         (diag, compareseq): Restore arg find_minimal.  All uses changed.
57374         (diag): Restore the TOO_EXPENSIVE heuristic that I added back in
57375         1993 to make 'diff' run faster (but not as well) on large inputs,
57376         but use a threshold of 4096 instead of the old 256.
57377         * lib/fstrcmp.c (strcmp_bounded):
57378         * lib/git-merge-changelog.c (compute_differences):
57379         Adjust to diffseq.h changes.
57381 2016-10-22  Bruno Haible  <bruno@clisp.org>
57383         iconv: Avoid compilation error when bootstrapping GNU libiconv.
57384         * m4/iconv.m4 (AM_ICONV): When the system does not have an iconv()
57385         declaration yet, define ICONV_CONST to empty.
57387 2016-10-15  Bruno Haible  <bruno@clisp.org>
57389         Avoid gnulib-tool warnings about the dependencies of 'parse-datetime'.
57390         * gnulib-tool (func_get_license): Special-case the 'parse-datetime'
57391         module.
57393 2016-10-16  Bruno Haible  <bruno@clisp.org>
57395         system-quote tests: Avoid compiler warning on AIX.
57396         * tests/test-system-quote-child.c (fopen): Redefine like the system's
57397         <stdio.h> does.
57399 2016-10-16  Bruno Haible  <bruno@clisp.org>
57401         Fix some "gcc -Wall" warnings.
57402         * tests/test-ffsl.c (main): Use variable x, not i.
57403         * tests/test-posix_spawn3.c (parent_main): Consider the return value of
57404         freopen.
57405         * tests/test-sethostname1.c (main): Explicitly ignore the return value
57406         of sethostname.
57408 2016-10-16  Bruno Haible  <bruno@clisp.org>
57410         gnulib-tool: Make --create-testdir on all modules work again.
57411         * gnulib-tool (func_create_testdir): Don't include the
57412         non-recursive-gnulib-prefix-hack module.
57414 2016-10-21  Daiki Ueno  <ueno@gnu.org>
57416         libunistring: change the maintainer to 'all'
57417         * modules/gen-uni-tables, modules/libunistring:
57418         * modules/ucs4-utf16, modules/ucs4-utf8, modules/unicodeio:
57419         * modules/unitypes, modules/utf16-ucs4, modules/utf16-ucs4-unsafe:
57420         * modules/utf8-ucs4, modules/utf8-ucs4-unsafe:
57421         * modules/unicase/*, modules/uniconv/*, modules/unictype/*:
57422         * modules/unilbrk/*, modules/uniname/*, modules/uninorm/*:
57423         * modules/unistdio/*, modules/unistr/*, modules/uniwbrk/*:
57424         * modules/uniwidth/*: Change the maintainer to 'all'.
57426 2016-10-16  Bruno Haible  <bruno@clisp.org>
57428         Simplify "configure: checking ..." messages.
57429         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use AC_MSG_CHECKING instead of
57430         AC_MSG_NOTICE.
57431         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
57433 2016-10-20  Paul Eggert  <eggert@cs.ucla.edu>
57435         quotearg-tests: pacify gcc -Wall
57436         Problem reported by Bruno Haible in:
57437         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00066.html
57438         * tests/test-quotearg-simple.c (use_quote_double_quotes): Move here ...
57439         * tests/test-quotearg.h: ... from here.
57441 2016-10-20  Pádraig Brady  <P@draigBrady.com>
57443         canonicalize-lgpl: fix for missing SIZE_MAX on older systems
57444         * lib/canonicalize-lgpl.c [SIZE_MAX]: Define if needed.
57445         Needed on Centos <= 4.
57447 2016-10-20  Jim Meyering  <meyering@fb.com>
57449         printf.m4: fix a bug in detecting printf %j support
57450         * m4/printf.m4 (gl_PRINTF_SIZES_C99): Fail any system for which
57451         uintmax_t is defined in neither stdint.h nor inttypes.h.
57452         Before, this macro might have mistakenly set
57453         gl_cv_func_printf_sizes_c99=yes on such a system.
57454         Spotted by Zev Weiss.
57456 2016-10-19  Paul Eggert  <eggert@cs.ucla.edu>
57458         sched: substitute HAVE_SYS_CDEFS_H too
57459         Problem reported by Tom G. Christensen in:
57460         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00084.html
57461         * m4/sched_h.m4 (gl_SCHED_H): Set and substitute HAVE_SYS_CDEFS_H.
57462         * modules/sched (Depends-on): Substitute HAVE_SYS_CDEFS_H.
57464 2016-10-19  Pádraig Brady  <P@draigBrady.com>
57466         quotearg: never write beyond the returned length
57467         * lib/quotearg.c (quotearg_buffer_restyled): Switch to a read-only
57468         scan of the string when we initially encounter a single quote when
57469         shell quoting, so that if we then switch to a more concise quoting method
57470         we will not have written beyond that returned length.
57471         This is significant for sh-quote, which has separate routines
57472         to determine the length and do the actual quoting.
57473         * tests/test-quotearg.h: Reinstate the buffer bounds checking
57474         now that we never write more than the returned length.
57476 2016-10-18  Bruno Haible  <bruno@clisp.org>
57478         getprogname tests: Avoid failure in packages that use libtool.
57479         * tests/test-getprogname.c (main): Strip "lt-" prefix.
57480         Based on a patch by Jim Meyering.
57482 2016-10-16  Bruno Haible  <bruno@clisp.org>
57484         getprogname: Fix test failure on Cygwin. Comments.
57485         * lib/getprogname.h: Add comments.
57486         * lib/getprogname.c: Add comments. Fix #elif indentation.
57487         * tests/test-getprogname.c (main): On Cygwin, expect a result without
57488         ".exe" suffix.
57490 2016-10-16  Bruno Haible  <bruno@clisp.org>
57492         Make sure the libunistring detection rejects older versions with a
57493         known bug.
57494         * modules/unistr/u8-strtok (configure.ac): Bump required version.
57495         * modules/unistr/u16-strtok (configure.ac): Likewise.
57496         * modules/unistr/u32-strtok (configure.ac): Likewise.
57498 2016-10-18  Bruno Haible  <bruno@clisp.org>
57500         sh-quote, system-quote: revert regression of unit test.
57501         * tests/test-sh-quote.c (check_one): Do detect buffer overruns.
57502         * tests/test-system-quote-main.c (check_one): Likewise.
57504 2016-10-16  Pádraig Brady  <P@draigBrady.com>
57506         quotearg: fix stale tests
57507         * tests/test-quotearg.c [locale_results]: Add the missing str7
57508         entries to the expected results.
57509         * tests/test-system-quote-main.c (check_one): Don't enforce that we
57510         don't write beyond the returned length, since that's no longer the
57511         case if we switch to a more concise quoting style.
57512         * tests/test-sh-quote.c (check_one): Likewise.
57513         (main): Adjust for the new more concise quoting style.
57514         Reported by Bruno Haible.
57516 2016-10-16  Jim Meyering  <meyering@fb.com>
57518         non-recursive-gnulib-prefix-hack: fix inconsequential typo
57519         * m4/non-recursive-gnulib-prefix-hack.m4: Change a hard-coded "lib"
57520         to "$1".  This macro is always invoked with $1 == lib.
57521         Spotted by Bruno Haible
57523 2016-10-16  Bruno Haible  <bruno@clisp.org>
57525         Fix a test crash.
57526         * tests/test-duplocale.c (main): Skip the test if the 'newlocale' call
57527         fails.
57529 2016-10-16  Pádraig Brady  <P@draigBrady.com>
57531         test-limits-h: suppress -Woverlength-strings
57532         * tests/test-limits-h.c [__GNUC__]: Ignore -Woverlength-strings.
57534 2016-10-15  Bruno Haible  <bruno@clisp.org>
57536         gettime, timespec, utimens: Relicense under LGPL.
57537         * modules/gettime (License): Change to LGPL.
57538         * modules/timespec (License): Likewise.
57539         * modules/utimens (License): Likewise.
57541 2016-10-14  Bruno Haible  <bruno@clisp.org>
57542             Pádraig Brady  <P@draigBrady.com>
57544         canonicalize-lgpl: Support the case path_max > INT_MAX.
57545         * lib/canonicalize-lgpl.c (__realpath): Declare n as ssize_t, not int.
57546         Fix overflow check, for platforms where 'size_t' is larger than 'long'.
57548 2016-10-13  Jim Meyering  <meyering@fb.com>
57550         getprogname: IBM z/OS: avoid NULL-dereference
57551         * lib/getprogname.c (getprogname) [__MVS__]: Don't dereference NULL
57552         upon strdup failure.
57554 2016-10-12  Jim Meyering  <meyering@fb.com>
57556         test-stdint: use _GL_VERIFY rather than "verify" for some tests
57557         * tests/test-stdint.c (verify_width): Implement with _GL_VERIFY
57558         and an abbreviated diagnostic rather than verify with the full one,
57559         because the full-length strings would evoke warnings from gcc with
57560         -Woverlength-strings.
57562 2016-10-13  Paul Eggert  <eggert@cs.ucla.edu>
57564         stdint: port SIZE_MAX to glibc s390
57565         Problem reported by Eric Blake in:
57566         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00031.html
57567         * doc/posix-headers/stdint.texi (stdint.h): Document the fix.
57568         * m4/stdint.m4 (gl_STDINT_H): Check that SIZE_MAX has the
57569         correct type, if possible.
57571 2016-10-13  Daniel Richard G.  <skunk@iSKUNK.ORG>
57573         getprogname: port to IBM z/OS
57574         * lib/getprogname.c (getprogname): Use w_getpsent() to get the name.
57576 2016-10-11  Jim Meyering  <meyering@fb.com>
57578         maint: remove stray space after "." in AC_DEFINE comment.
57579         * m4/st_dm_mode.m4 (AC_STRUCT_ST_DM_MODE): Remove space-after-".".
57580         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
57582 2016-10-05  Jim Meyering  <meyering@fb.com>
57584         long-options: avoid new GCC 7 warning from -Wimplicit-fallthrough
57585         * lib/long-options.c (parse_long_options): Add a break statement
57586         to avoid this new warning/failure:
57587         $ CFLAGS='-O -Werror=implicit-fallthrough' ./gnulib-tool \
57588           --create-testdir --dir=/t/x --with-tests --test long-options
57589         ../../gllib/long-options.c: In function 'parse_long_options':
57590         ../../gllib/long-options.c:66:12: error: this statement may \
57591           fall through [-Werror=implicit-fallthrough]
57592                    (*usage_func) (EXIT_SUCCESS);
57593                    ~^~~~~~~~~~~~~~~~~~~~~~~~~~~
57595 2016-10-05  Jim Meyering  <meyering@fb.com>
57597         utimecmp: avoid new GCC 7 warning from -Wbool-operation
57598         Testing this module would fail when using GCC 7 like this:
57599         $ CFLAGS='-O -Werror=bool-operation' ./gnulib-tool --create-testdir \
57600           --dir=/tmp/x --with-tests --test utimecmp
57601         ../../gllib/utimecmp.c: In function ‘utimecmp’:
57602         ../../gllib/utimecmp.c:291:36: error: ‘~’ on a boolean expression \
57603           [-Werror=bool-operation]
57604                          time_t s = src_s & ~ (res == 2 * BILLION);
57605                                             ^
57606         ../../gllib/utimecmp.c:370:16: error: ‘~’ on a boolean expression \
57607           [-Werror=bool-operation]
57608                src_s &= ~ (res == 2 * BILLION);
57609                         ^
57610         * lib/utimecmp.c (utimecmp): Do not apply "~" to a boolean.
57611         Instead, make it explicit that we intend to apply it to 0 or 1.
57613 2016-10-10  Norihiro Tanaka  <noritnk@kcn.ne.jp>
57615         dfa: save memory for states
57616         * src/dfa (dfaexec_main): Beginning of dfa execution, release caches of
57617         states if dfa has a lot of caches.
57619 2016-10-10  Eli Zaretskii  <eliz@gnu.org>
57621         wchar, wctype-h: fix for MinGW 3.22.2
57622         * lib/wchar.in.h [__MINGW32__]: Add one more condition for
57623         special invocation, to fix issues with MinGW 3.22.2 wchar.h
57624         when included from <string.h>.
57625         * lib/wctype.in.h [__MINGW32__]: Add special invocation
57626         convention for MinGW 3.22.2, to solve issues with their
57627         wctype.h when included from <ctype.h>.
57629 2016-10-05  Jim Meyering  <meyering@fb.com>
57631         long-options: avoid new GCC 7 warning from -Wimplicit-fallthrough
57632         * lib/long-options.c (parse_long_options): Add a break statement
57633         to avoid this new warning/failure:
57634         $ CFLAGS='-O -Werror=implicit-fallthrough' ./gnulib-tool \
57635           --create-testdir --dir=/t/x --with-tests --test long-options
57636         ../../gllib/long-options.c: In function ‘parse_long_options’:
57637         ../../gllib/long-options.c:66:12: error: this statement may \
57638           fall through [-Werror=implicit-fallthrough]
57639                    (*usage_func) (EXIT_SUCCESS);
57640                    ~^~~~~~~~~~~~~~~~~~~~~~~~~~~
57642         utimecmp: avoid new GCC 7 warning from -Wbool-operation
57643         Testing this module would fail when using GCC 7 like this:
57644         $ CFLAGS='-O -Werror=bool-operation' ./gnulib-tool --create-testdir \
57645           --dir=/tmp/x --with-tests --test utimecmp
57646         ../../gllib/utimecmp.c: In function ‘utimecmp’:
57647         ../../gllib/utimecmp.c:291:36: error: ‘~’ on a boolean expression \
57648           [-Werror=bool-operation]
57649                          time_t s = src_s & ~ (res == 2 * BILLION);
57650                                             ^
57651         ../../gllib/utimecmp.c:370:16: error: ‘~’ on a boolean expression \
57652           [-Werror=bool-operation]
57653                src_s &= ~ (res == 2 * BILLION);
57654                         ^
57655         * lib/utimecmp.c (utimecmp): Do not apply "~" to a boolean.
57656         Instead, make it explicit that we intend to apply it to 0 or 1.
57658 2016-10-03  Pádraig Brady  <P@draigBrady.com>
57660         quotearg: minimize shell quoting using double quotes
57661         * lib/quotearg.c (quotearg_buffer_restyled): If an ASCII single
57662         quote in encountered then use double quotes (c style quoting)
57663         when possible, as it simplifies the quoting.
57664         * tests/test-quotearg-simple.c: Add test cases.
57665         * tests/test-quotearg.h (use_quotearg_buffer): Adjust to account
57666         for the fact we now may write beyond the returned length.
57668 2016-10-02  Jim Meyering  <meyering@fb.com>
57670         vasnprintf.c: avoid spurious warning from GCC 7
57671         The presence of cpp directives renders this "FALLTHROUGH" comment
57672         ineffective, so does not suppress the -Wimplicit-fallthrough warning
57673         from GCC 7 built from git on 2016-10-02.
57674         * lib/vasnprintf.c (VASNPRINTF): Move comment down past two cpp
57675         directives, so that it takes effect once again.  This is clearly
57676         not a proper change, and I will revert it once this bug is fixed:
57677         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77817
57679 2016-10-01  Jim Meyering  <meyering@fb.com>
57681         getprogname: correct the test for a __progname variable
57682         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Use AC_CACHE_CHECK
57683         and AC_LINK_IFELSE to check for a global __progname.  If found,
57684         define HAVE_VAR___PROGNAME.
57685         * lib/getprogname.c (getprogname): Reflect the new name of the
57686         feature- checked preprocessor symbol:
57687         s/HAVE_DECL___PROGNAME/HAVE_VAR___PROGNAME/
57689 2016-09-28  Jim Meyering  <meyering@fb.com>
57691         u8-uctomb-aux.c: build: placate GCC 7's new -Wimplicit-fallthrough
57692         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Mark each end of
57693         fall-through case with a /* fallthrough */ comment.
57695         dfa: build: avoid warning from GCC 7's new -Wimplicit-fallthrough
57696         * lib/dfa.c (dfassbuild): Mark the end of this case with a
57697         /* fallthrough */ comment.
57699         getprogname: avoid __progname vs program_invocation_short_name pitfall
57700         I.e., don't let the OpenBSD 5.1 fix induce failure when using newer
57701         glibc.  Would have caused failure with Fedora 25's glibc-2.24-3, but
57702         not with Fedora 24's glibc-2.23.1-10.
57703         * lib/getprogname.c (__progname): Move this declaration down...
57704         (getprogname): ... into the #elif block where used, and make it
57705         explicitly "extern".
57707         getprogname: port to OpenBSD 5.1
57708         * lib/getprogname.c (__progname) [HAVE_DECL___PROGNAME]: Declare.
57709         (getprogname) [HAVE_DECL___PROGNAME]: Return __progname or "?".
57710         * modules/getprogname (configure.ac): Move most of this code...
57711         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): ... to this function,
57712         increment serial number, and add a test for __progname.
57713         https://bugs.gnu.org/24562
57714         Reported by Nelson H. F. Beebe.
57716 2016-09-24  Paul Eggert  <eggert@cs.ucla.edu>
57718         sched: port to GCC 6.2.1 on macOS Sierra
57719         Problem reported by Denis Davydov in:
57720         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00056.html
57721         * lib/sched.in.h [HAVE_SYS_CDEFS_H]:
57722         Include <sys/cdefs.h> before <sched.h>.
57723         * m4/nproc.m4 (gl_PREREQ_NPROC): Include errno.h before sched.h,
57724         so that we needn’t worry about the sched.h include bug here.
57725         * m4/sched_h.m4 (gl_SCHED_H): Check for sys/cdefs.h,
57726         and include it before <sched.h> if it exists, when
57727         checking for <sched.h>.
57729         tests/init.sh: port Alpine fix to AIX 7.1
57730         * tests/init.sh (compare_): When attempting to use diff -U3,
57731         prefer diff -u to -U3 to -c to plain diff.  Do not insist on
57732         diff -u not outputting a space after leading '+', as the users
57733         of 'compare' should not be that picky about its output format.
57734         In the AIX 7.1 case, return with diff exit status (or with 2 if
57735         trouble), instead of some random nonzero exit status.
57736         * tests/test-init.sh (test_compare): Remove space after leading
57737         '+', so that AIX 7.1 'diff' passes the test.
57739 2016-09-22  Paul Eggert  <eggert@cs.ucla.edu>
57741         nl_langinfo: pacify GCC
57742         * lib/nl_langinfo.c (ctype_codeset): Remove unused local.
57743         (rpl_nl_langinfo): Cast string literals to char *, to pacify GCC.
57745         stdint: also set GL_GENERATE_LIMITS_H
57746         Problem reported by Jim Meyering in:
57747         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00052.html
57748         * m4/stdint.m4 (gl_STDINT_H): Also redo the AM_CONDITIONAL.
57750         limits-h, stdint: Don't assume extensions, fix typo
57751         * m4/limits-h.m4 (gl_LIMITS_H):
57752         * m4/stdint.m4 (gl_STDINT_H):
57753         Don't assume AC_USE_SYSTEM_EXTENSIONS.
57754         * m4/stdint.m4 (gl_STDINT_H): Fix typo in setting of LIMITS_H,
57755         reported by Jim Meyering in:
57756         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00050.html
57758 2016-09-21  Jim Meyering  <meyering@fb.com>
57760         getprogname: port to AIX
57761         * lib/getprogname.c (getprogname) [_AIX]: Use getpid, getprocs64
57762         and strdup to obtain a short program name string.  Using code from
57763         Bruno Haible and an idea from Bastien ROUCARIÈS, in
57764         https://lists.gnu.org/r/bug-gnulib/2010-12/msg00249.html
57765         Assaf Gordon reported that this new file would fail to compile on
57766         AIX-7.1 32bit.
57768 2016-09-16  Paul Eggert  <eggert@cs.ucla.edu>
57770         extensions: fix typo in comment
57771         * m4/extensions.m4: Sync from Autoconf master.
57773         stdint: support new _WIDTH macros
57774         * doc/posix-headers/stdint.texi: Document this.
57775         * lib/stdint.in.h: Add support for INTMAX_WIDTH. etc.
57776         * m4/stdint.m4 (gl_STDINT_H): Require gl_LIMITS_H.  Check for
57777         support for INTMAX_WIDTH, etc. as well as for support for just C99.
57778         * modules/stdint (Depends-on): Add limits-h.
57779         (Makefile.am): Substitute HAVE_C99_STDINT_H.
57780         * modules/stdint-tests (Depends-on): Add extensions, so that
57781         INTMAX_MAX etc. are defined.
57782         * tests/test-stdint.c: Verify the new macros.
57784         limits-h: new module
57785         This adds ISO/IEC TS 18661-1:2014 support to limits.h.
57786         * MODULES.html.sh: Add limits-h,and move size_max to stdint section.
57787         * doc/posix-headers/limits.texi: Document new module.
57788         * lib/limits.in.h, m4/limits-h.m4, modules/limits-h:
57789         * modules/limit-h-tests, tests/test-limits-h.c: New files.
57791         stdio: don't redefine __USE_MINGW_ANSI_STDIO
57792         * m4/stdio_h.m4 (gl_STDIO_H): Don't define __USE_MINGW_ANSI_STDIO
57793         if it is already defined.  Apparently GNU Emacs relies on this.  See:
57794         http://lists.gnu.org/r/emacs-devel/2016-09/msg00416.html
57796 2016-09-15  Eric Blake  <eblake@redhat.com>
57798         sys_types: avoid glibc 2.25 warnings about major()
57799         * m4/sys_types_h.m4 (AC_HEADER_MAJOR): Replace broken version in
57800         older autoconf.
57801         * doc/posix-headers/sys_types.texi (sys/types.h): Document fix.
57802         * doc/glibc-functions/gnu_dev_major.texi (gnu_dev_major): Likewise.
57803         * doc/glibc-functions/gnu_dev_makedev.texi (gnu_dev_makedev): Likewise.
57804         * doc/glibc-functions/gnu_dev_minor.texi (gnu_dev_minor): Likewise.
57806         mountlist: include sysmacros.h for glibc
57807         * m4/mountlist.m4 (gl_PREREQ_MOUTLIST_EXTRA): Include
57808         AC_HEADER_MAJOR.
57809         * lib/mountlist.c (includes): Use correct headers.
57811 2016-09-15  Paul Eggert  <eggert@cs.ucla.edu>
57813         extensions: port to more ISO C TSes
57814         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Sync from Autoconf
57815         master, to add support for more recent ISO C TRs and TSes.
57817 2016-09-13  Paul Eggert  <eggert@cs.ucla.edu>
57819         intprops: new macro TYPE_WIDTH
57820         * lib/intprops.h (TYPE_WIDTH): New macro.
57821         (TYPE_MAXIMUM, _GL_SIGNED_INT_MAXIMUM, INT_STRLEN_BOUND):
57822         * lib/ftoastr.h (_GL_FLOAT_DIG_BITS_BOUND):
57823         * lib/parse-datetime.y (parse_datetime2):
57824         Use it.
57826         extensions: port to recent ISO C TRs
57827         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
57828         Sync from Autoconf master, to add support for recent ISO C TRs.
57829         * m4/stdio_h.m4 (gl_STDIO_H): Define __USE_MINGW_ANSI_STDIO here,
57830         since AC_USE_SYSTEM_EXTENSIONS no longer does that as
57831         the MinGW option is not an extension.
57833 2016-09-11  Paul Eggert  <eggert@cs.ucla.edu>
57835         dfa: port to Solaris 9
57836         Problems reported by Tom G. Christensen in:
57837         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00031.html
57838         * modules/dfa (Depends-on): Add isblank.
57839         * modules/dfa-tests (dfa_match_aux_LDADD):
57840         Rename from test_stat_LDADD, to fix typo.
57841         * tests/dfa-match.sh: Don't require 'timeout'; use it if available.
57843 2016-09-10  Jim Meyering  <meyering@fb.com>
57845         strverscmp: avoid link failure on OS X
57846         * lib/strverscmp.c [!weak_alias]: Define __strverscmp to strverscmp.
57847         Reported by Assaf Gordon in https://bugs.gnu.org/24256#26
57849 2016-08-16  Jim Meyering  <meyering@fb.com>
57851         dfa: new module, importing grep's DFA matcher
57852         Since grep's DFA matcher is now being used by two gnulib-enabled
57853         projects, grep and sed, it makes sense to version-control its
57854         sources and unit tests in one place: here.
57855         * modules/dfa: New module.
57856         * modules/dfa-tests: New file.
57857         * lib/dfa.c: New file, from grep.
57858         * lib/dfa.h: Likewise.
57859         * lib/localeinfo.c: Likewise.
57860         * lib/localeinfo.h: Likewise.
57861         * tests/dfa-match-aux.c: Likewise.
57862         * tests/dfa-invalid-char-class.sh: Likewise.
57863         * tests/dfa-match.sh: Likewise, with minor changes.
57864         * MODULES.html.sh (Misc): Add "dfa" to this list.
57866 2016-09-09  Jim Meyering  <meyering@fb.com>
57868         getprogname-tests: don't depend on assert-h
57869         * modules/getprogname-tests (Depends-on): Remove assert-h.
57870         It was not needed, and in fact would cause build failure for
57871         coreutils on some systems.  Reported by Assaf Gordon in https:
57872         //lists.gnu.org/r/coreutils/2016-09/msg00016.html
57874 2016-09-07  Jim Meyering  <meyering@fb.com>
57876         getprogname-tests: work also when EXEEXT is nonempty
57877         * modules/getprogname-tests (Makefile.am): Define EXEEXT.
57878         * tests/test-getprogname.c (main): Use it.
57879         Suggested by Gisle Vanem.
57881 2016-09-07  Gisle Vanem  <gvanem@yahoo.no>
57883         getprogname: fix errors in previous change
57884         * lib/getprogname.c (getprogname) [HAVE_GETEXECNAME]:
57885         s/program_invocation_name/base/
57886         [HAVE_DECL___ARGV]: Handle NULL __argv or __argv[0].
57888 2016-09-08  Pádraig Brady  <P@draigBrady.com>
57890         parse-datetime: restrict debug output to input string
57891         * lib/parse-datetime.y (parse_datetime2): If we parse
57892         all of the input but determine it's invalid, ensure
57893         we don't output the now invalid input pointer.
57894         This issue was seen with `date -d 'now +1'`.
57896 2016-09-07  Paul Eggert  <eggert@cs.ucla.edu>
57898         flexmember: new macro FLEXALIGNOF
57899         * lib/flexmember.h: Include <stddef.h>, for offsetof.
57900         (FLEXALIGNOF): Rename from _GL_XALLOC_ALIGNOF, as Emacs can use
57901         this macro.  Update comments.
57903 2016-09-07  Jim Meyering  <meyering@fb.com>
57905         getprogname: port to systems with __argv (mingw, msvc)
57906         * lib/getprogname.c (getprogname): Include "dirname.h" and use
57907         last_component: more general than open coding it with hard-coded "/".
57908         * lib/getprogname.h (getprogname): Prefer "char const *" consistently.
57909         * modules/getprogname (Depends-on): Add dirname-lgpl.
57910         (configure.ac): Check for __argv in <stdlib.h>.
57911         * modules/getprogname-tests: New file.
57912         * tests/test-getprogname.c: New file.
57913         Suggested by Gisle Vanem in
57914         https://lists.gnu.org/r/bug-gnulib/2016-09/msg00014.html
57916 2016-09-07  Paul Eggert  <eggert@cs.ucla.edu>
57918         flexmember: port better to GCC + valgrind
57919         With a char[] flexible array member in a struct with nontrivial
57920         alignment, GCC-generated code can access past the end of the
57921         array, because GCC assumes there are padding bytes to get the
57922         struct aligned.  So the common idiom of malloc (offsetof (struct
57923         s, m), n) does not properly allocate an n-byte trailing member, as
57924         malloc’s argument should be the next multiple of alignof (struct s).
57925         See GCC Bug#66661: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66661
57926         Although C11 apparently permits this GCC optimization (i.e., there
57927         was a bug in Gnulib not in GCC), possibly this is a defect in C11.
57928         See the thread containing:
57929         https://gcc.gnu.org/ml/gcc-patches/2016-09/msg00317.html
57930         * lib/flexmember.h: New file.
57931         * lib/fnmatch.c, lib/fts.c, lib/glob.c, lib/idcache.c:
57932         * lib/localename.c, lib/time_rz.c:
57933         Include flexmember.h.
57934         * lib/fnmatch_loop.c (struct patternlist):
57935         * lib/localename.c (struct hash_node):
57936         Use FLEXIBLE_ARRAY_MEMBER.
57937         * lib/fnmatch_loop.c (EXT):
57938         * lib/fts.c (fts_alloc):
57939         * lib/glob.c (glob_in_dir):
57940         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
57941         * lib/localename.c (gl_lock_define_initialized):
57942         * lib/time_rz.c (tzalloc):
57943         Use FLEXSIZEOF instead of offsetof.
57944         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
57945         Check that the size of the struct can be taken.
57946         * modules/flexmember (Files): Add lib/flexmember.h.
57947         * modules/fnmatch, modules/glob, modules/localename (Depends-on):
57948         Add flexmember.
57950 2016-09-06  Paul Eggert  <eggert@cs.ucla.edu>
57952         getprogname: port to Solaris 10
57953         * lib/getprogname.c: Include stdlib.h, for getexecname decl.
57954         (getprogname) [HAVE_GETEXECNAME]: Use that, for Solaris 10.
57955         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Check for getexecname.
57957         stdalign: correct mistake in alignof doc
57958         Problem reported by Joseph Myers in:
57959         https://gcc.gnu.org/ml/gcc-patches/2016-09/msg00340.html
57960         * doc/posix-headers/stdalign.texi: Do not imply that C11 prohibits
57961         alignof(S) where S is a structure containing a flexible array
57962         member.  The Gnulib substitute does not support this, but C11 does.
57964 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
57966         main.mk: remove sc_program_name, since there is no more need to
57967         use set_program_name in tools (getprogname is enough for most
57968         of the cases).
57969         * cfg.mk (local-checks-to-skip): Remove sc_program_name.
57970         * top/maint.mk (sc_program_name): Remove.
57972 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
57974         Port tests away from progname, since modules that need the
57975         program name already depend on getprogname.
57976         * modules/acl-tests (Depends-on): Remove progname.
57977         * modules/argmatch (Depends-on): Likewise.
57978         * modules/argmatch-tests (Depends-on): Likewise.
57979         * modules/argp-tests (Depends-on): Likewise.
57980         * modules/argp-version-etc-tests (Depends-on): Likewise.
57981         * modules/array-list-tests (Depends-on): Likewise.
57982         * modules/array-oset-tests (Depends-on): Likewise.
57983         * modules/avltree-list-tests (Depends-on): Likewise.
57984         * modules/avltree-oset-tests (Depends-on): Likewise.
57985         * modules/avltreehash-list-tests (Depends-on): Likewise.
57986         * modules/carray-list-tests (Depends-on): Likewise.
57987         * modules/copy-file-tests (Depends-on): Likewise.
57988         * modules/exclude-tests (Depends-on): Likewise.
57989         * modules/fchownat-tests (Depends-on): Likewise.
57990         * modules/fdopendir-tests (Depends-on): Likewise.
57991         * modules/filenamecat-tests (Depends-on): Likewise.
57992         * modules/fstatat-tests (Depends-on): Likewise.
57993         * modules/fstrcmp-tests (Depends-on): Likewise.
57994         * modules/linked-list-tests (Depends-on): Likewise.
57995         * modules/linkedhash-list-tests (Depends-on): Likewise.
57996         * modules/mkdirat-tests (Depends-on): Likewise.
57997         * modules/nonblocking-pipe-tests (Depends-on): Likewise.
57998         * modules/nonblocking-socket-tests (Depends-on): Likewise.
57999         * modules/obstack-printf-tests (Depends-on): Likewise.
58000         * modules/openat-tests (Depends-on): Likewise.
58001         * modules/parse-datetime-tests (Depends-on): Likewise.
58002         * modules/pipe-filter-gi-tests (Depends-on): Likewise.
58003         * modules/pipe-filter-ii-tests (Depends-on): Likewise.
58004         * modules/quotearg-simple-tests (Depends-on): Likewise.
58005         * modules/quotearg-tests (Depends-on): Likewise.
58006         * modules/rbtree-list-tests (Depends-on): Likewise.
58007         * modules/rbtree-oset-tests (Depends-on): Likewise.
58008         * modules/rbtreehash-list-tests (Depends-on): Likewise.
58009         * modules/spawn-pipe-tests (Depends-on): Likewise.
58010         * modules/system-quote-tests (Depends-on): Likewise.
58011         * modules/uniname/uniname-tests (Depends-on): Likewise.
58012         * modules/uninorm/nfc-tests (Depends-on): Likewise.
58013         * modules/uninorm/nfd-tests (Depends-on): Likewise.
58014         * modules/uninorm/nfkc-tests (Depends-on): Likewise.
58015         * modules/uninorm/nfkd-tests (Depends-on): Likewise.
58016         * modules/unistdio/u16-vsnprintf-tests (Depends-on): Likewise.
58017         * modules/unistdio/u16-vsprintf-tests (Depends-on): Likewise.
58018         * modules/unistdio/u32-vsnprintf-tests (Depends-on): Likewise.
58019         * modules/unistdio/u32-vsprintf-tests (Depends-on): Likewise.
58020         * modules/unistdio/u8-vsnprintf-tests (Depends-on): Likewise.
58021         * modules/unistdio/u8-vsprintf-tests (Depends-on): Likewise.
58022         * modules/unistdio/ulc-vsnprintf-tests (Depends-on): Likewise.
58023         * modules/unistdio/ulc-vsprintf-tests (Depends-on): Likewise.
58024         * modules/unlinkat-tests (Depends-on): Likewise.
58025         * modules/version-etc-tests (Depends-on): Likewise.
58026         * modules/xalloc-die-tests (Depends-on): Likewise.
58027         * modules/xmemdup0-tests (Depends-on): Likewise.
58028         * modules/xprintf-posix-tests (Depends-on): Likewise.
58029         * modules/xvasprintf-tests (Depends-on): Likewise.
58030         * tests/test-argmatch.c: Do not include progname.h.
58031         (main) Stop calling set_program_name.
58032         * tests/test-argp-version-etc.c: Likewise.
58033         * tests/test-argp.c: Likewise.
58034         * tests/test-argv-iter.c: Likewise.
58035         * tests/test-array_list.c: Likewise.
58036         * tests/test-array_oset.c: Likewise.
58037         * tests/test-avltree_list.c: Likewise.
58038         * tests/test-avltree_oset.c: Likewise.
58039         * tests/test-avltreehash_list.c: Likewise.
58040         * tests/test-carray_list.c: Likewise.
58041         * tests/test-copy-acl.c: Likewise.
58042         * tests/test-copy-file.c: Likewise.
58043         * tests/test-exclude.c: Likewise.
58044         * tests/test-fchownat.c: Likewise.
58045         * tests/test-fdopendir.c: Likewise.
58046         * tests/test-filenamecat.c: Likewise.
58047         * tests/test-fstatat.c: Likewise.
58048         * tests/test-fstrcmp.c: Likewise.
58049         * tests/test-linked_list.c: Likewise.
58050         * tests/test-linkedhash_list.c: Likewise.
58051         * tests/test-mkdirat.c: Likewise.
58052         * tests/test-nonblocking-pipe-main.c: Likewise.
58053         * tests/test-nonblocking-socket-main.c: Likewise.
58054         * tests/test-obstack-printf.c: Likewise.
58055         * tests/test-openat.c: Likewise.
58056         * tests/test-parse-datetime.c: Likewise.
58057         * tests/test-pipe-filter-gi1.c: Likewise.
58058         * tests/test-pipe-filter-gi2-main.c: Likewise.
58059         * tests/test-pipe-filter-ii1.c: Likewise.
58060         * tests/test-pipe-filter-ii2-main.c: Likewise.
58061         * tests/test-quotearg-simple.c: Likewise.
58062         * tests/test-quotearg.c: Likewise.
58063         * tests/test-rbtree_list.c: Likewise.
58064         * tests/test-rbtree_oset.c: Likewise.
58065         * tests/test-rbtreehash_list.c: Likewise.
58066         * tests/test-sameacls.c: Likewise.
58067         * tests/test-set-mode-acl.c: Likewise.
58068         * tests/test-spawn-pipe-main.c: Likewise.
58069         * tests/test-system-quote-main.c: Likewise.
58070         * tests/test-unlinkat.c: Likewise.
58071         * tests/test-version-etc.c: Likewise.
58072         * tests/test-xalloc-die.c: Likewise.
58073         * tests/test-xfprintf-posix.c: Likewise.
58074         * tests/test-xmemdup0.c: Likewise.
58075         * tests/test-xprintf-posix.c: Likewise.
58076         * tests/test-xvasprintf.c: Likewise.
58077         * tests/uniname/test-uninames.c: Likewise.
58078         * tests/uninorm/test-u32-nfc-big.c: Likewise.
58079         * tests/uninorm/test-u32-nfd-big.c: Likewise.
58080         * tests/uninorm/test-u32-nfkc-big.c: Likewise.
58081         * tests/uninorm/test-u32-nfkd-big.c: Likewise.
58082         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
58083         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
58084         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
58085         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
58086         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
58087         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
58088         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
58089         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
58090         * tests/test-c-stack.c: (program_name): Do not define.
58091         (main): Do not set program_name.
58092         * tests/test-closein.c: Likewise.
58093         * tests/test-xstrtol.c: Likewise.
58094         * tests/test-yesno.c: Likewise.
58096 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
58098         Port modules to use getprogname explicitly, instead of requiring
58099         progname to be used (or program_name to be provided).
58100         * lib/argmatch.c: Do not include progname.h.
58101         [TEST] (program_name): Do not define.
58102         [TEST] (main): Call getprogname instead of using program_name.
58103         * lib/c-stack.c: Do not include progname.h.
58104         (program_name): Do not define.
58105         (die): Call getprogname instead of using program_name.
58106         * lib/chdir-long.c: Do not include progname.h.
58107         [TEST_CHDIR] (main): Do not set program_name.
58108         * lib/error.c [!_LIBC]: Include progname.h.
58109         [!_LIBC] (program_name): Define using getprogname.
58110         * lib/euidaccess.c: Do not include progname.h.
58111         [TEST] (main): Do not set program_name.
58112         * lib/git-merge-changelog.c: Include getprogname.h instead of
58113         progname.h.
58114         (usage): Call getprogname instead of using program_name.
58115         (main): Likewise.  Stop calling set_program_name.
58116         * lib/group-member.c: Do not include progname.h.
58117         [TEST] (main): Do not set program_name.
58118         * modules/argmatch (Depends-on): Add getprogname.
58119         * modules/c-stack (Depends-on): Likewise.
58120         * modules/error (Depends-on): Likewise.
58121         * modules/git-merge-changelog (Depends-on): Likewise.
58122         Also remove progname.
58124 2016-09-05  Pino Toscano  <ptoscano@redhat.com>
58126         * NEWS: Document the deprecation of the 'progname' module.
58128 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
58130         getprogname: new module
58131         This provides a LGPL module for getting the name of the current
58132         program, using the same API found on *BSD systems.
58133         * lib/getprogname.c, lib/getprogname.h, m4/getprogname.m4:
58134         * modules/getprogname: New files.
58135         * MODULES.html.sh (Misc): Add getprogname.
58137 2016-09-02  Jim Meyering  <meyering@fb.com>
58139         manywarnings: add -fno-common
58140         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -fno-common
58141         to the list.  Quoting the manual, "Compiling with -fno-common is
58142         useful on targets for which it provides better performance, or if
58143         you wish to verify that the program will work on other systems that
58144         always treat uninitialized variable declarations this way [putting
58145         it in the data section]."  If diffutils had been using this sooner,
58146         it would have prevented this duplicate declaration issue:
58147         http://git.sv.gnu.org/cgit/diffutils.git/commit/?id=v3.4-10-gc2dc91f
58149 2016-08-31  Simon Josefsson  <simon@josefsson.org>
58151         parse-datetime: Fix typo.
58152         * lib/parse-datetime.y (parse_datetime2): Fix typo.
58154 2016-08-30  Paul Eggert  <eggert@cs.ucla.edu>
58156         intprops: tune INT_NEGATE_OVERFLOW for GCC 5 and 6
58157         * lib/intprops.h (INT_NEGATE_OVERFLOW): Tune for platforms like
58158         GCC 5 and 6 that have __builtin_sub_overflow but not
58159         __builtin_sub_overflow_p.  With the recent changes, these
58160         platforms are a tiny bit faster with the INT_NEGATE_RANGE_OVERFLOW
58161         implementation than with INT_SUBTRACT_OVERFLOW implementation,
58162         since the former needs just one runtime comparison whereas the
58163         latter needs two.
58165         strverscmp: sync with glibc
58166         Although this doesn't exactly synchronize with glibc
58167         byte-for-byte, it makes the code behave the same as glibc.
58168         * lib/strverscmp.c (S_I, S_F, S_Z): Now masks, not powers of 2.
58169         (ISDIGIT): Remove, as glibc is sticking with isdigit, and the
58170         difference shouldn't matter in practical use.  All uses changed
58171         back to isdigit.
58172         (__strverscmp, strverscmp): Use new glibc method for weak aliases.
58173         (next_state): Now unsigned char array; redo elements.
58174         (result_type): Now signed char array; redo elements.
58175         (__strverscmp): Fix glibc bug 9913 by using new states.
58176         * tests/test-strverscmp.c (main): Test glibc bug 9913.
58178 2016-08-29  Jim Meyering  <meyering@fb.com>
58180         xalloc-oversized.h: port __builtin_mul_overflow change to GCC 6.2.0
58181         * lib/xalloc-oversized.h: Port this change to GCC 6.2.0, too,
58182         similarly to how it was done to intprops.h.
58184 2016-08-29  Paul Eggert  <eggert@cs.ucla.edu>
58186         intprops.h: port recent changes to GCC 6.2.0
58187         * lib/intprops.h (__has_builtin): Move earlier.
58188         (_GL_HAS_BUILTIN_OVERFLOW): Rename from
58189         _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL and don't worry about whether
58190         the last argument can be null.  All uses changed.
58191         (_GL_HAS_BUILTIN_OVERFLOW_P): Also test __has_builtin.
58192         (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW, _GL_MULTIPLY_OVERFLOW):
58193         Don't try to use 3rd arg null, as this doesn't work on GCC 6.2.0
58194         and it's not clear which GCC versions it works for.
58195         (_GL_INT_OP_WRAPV): Use _GL_HAS_BUILTIN_OVERFLOW instead of
58196         its definiens.
58198         intprops.h: use __typeof__ with GCC 7
58199         * lib/intprops.h (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW)
58200         (_GL_MULTIPLY_OVERFLOW): Use __typeof__ as in the GCC manual.
58201         This avoids computing the expression's value (which might overflow!).
58203 2016-08-29  Jim Meyering  <meyering@fb.com>
58205         intprops.h, xalloc-oversized.h: work with gcc 7
58206         In gcc 6, __builtin_add_overflow, __builtin_sub_overflow and
58207         __builtin_mul_overflow each accept a NULL pointer as the third
58208         argument.  However in gcc 7, that is no longer accepted.
58209         Instead, one must use the "_p"-suffixed names, with which, the
58210         third parameter is no longer a pointer.
58211         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_WITH_NULL): Correct
58212         the definition: not true for gcc 7 and subsequent.
58213         (_GL_HAS_BUILTIN_OVERFLOW_P): Define.
58214         (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW, _GL_MULTIPLY_OVERFLOW):
58215         Provide new definitions for gcc 7 and subsequent.
58216         * lib/xalloc-oversized.h (xalloc_oversized): Provide a definition
58217         that works with gcc-7.
58219         intprops.h: fix missing-backslash problems
58220         * lib/intprops.h (_GL_ADD_OVERFLOW): Add backslash.
58221         (_GL_SUBTRACT_OVERFLOW,_GL_MULTIPLY_OVERFLOW): Likewise.
58223 2016-08-24  Paul Eggert  <eggert@cs.ucla.edu>
58225         intprops: fix paren typo on old platforms
58226         Problem reported by John E. Malmberg in: https://bugs.gnu.org/24300#13
58227         * lib/intprops.h (_GL_INT_OP_WRAPV_LONGISH)
58228         [__GNUC__ < 5 && !__has_builtin (__builtin_add_overflow)
58229         && (__STDC_VERSION__ < 201112 || _GL__GENERIC_BOGUS)
58230         && !defined LLONG_MAX]:
58231         Remove stray paren.
58233         intprops: port to OpenVMS
58234         Problem reported by John E. Malmberg in: https://bugs.gnu.org/24300
58235         * doc/posix-headers/limits.texi: Document the problem.
58236         * lib/intprops.h (LLONG_MAX, LLONG_MIN) [__INT64_MAX]:
58237         Define if not already defined.
58239 2016-08-19  Assaf Gordon  <assafgordon@gmail.com>
58241         parse-datetime: improve debug implementation
58242         Follow-up to commit 12ad79069 ("add optional debug printing").
58243         Improve parse-datetime's debug implementation: remove macros,
58244         replace global debug flag variable with a function parameter,
58245         use nstrftime for formatting.
58246         See: https://lists.gnu.org/r/bug-gnulib/2016-08/msg00021.html
58247         * lib/parse-datetime.h: (parse_datetime_debug): Remove global extern.
58248         (parse_datetime2): New function, accepts 'flags' parameter, supporting
58249         debug flag. Existing interface 'parse_datetime' left unmodified.
58250         * lib/parse-datetime.c: (parse_datetime_debug): Remove global variable.
58251         (struct parser_control): add 'parse_datetime_debug' member variable.
58252         (parse_datetime): Call new function 'parse_datetime2' without debug.
58253         (parse_datetime2): Adapted from previous 'parse_datetime', initialize
58254         pc.parse_datetime_debug variable as needed.
58255         (to_year): Accept new flags parameter, instead of using global variable.
58256         (debug_print_current_time,debug_print_relative_time,debug_mktime_not_ok):
58257         use struct 'debug' variable instead of global variable.
58258         (DEBUG,DEBUG_PRINT_CURRENT_TIME,DEBUG_PRINT_RELATIVE_TIME,
58259         DEBUG_MKTIME_NOT_OK,PROGRESS,PROGRESS0): Remove macros. Call
58260         correspnding functions directly instead of using macros.
58261         * modules/parse-datetime: Add gnulib's strftime module.
58263 2016-08-19  Daniel Richard G.  <skunk@iSKUNK.ORG>
58265         c-strcase-tests: port to EBCDIC
58266         * tests/test-c-strncasecmp.c: Allow two c_strncasecmp calls
58267         which assume ASCII encoding semantics to run only in ASCII
58268         mode, as they fail in EBCDIC.
58270         sigpipe-tests: fix typo
58271         * tests/test-sigpipe.sh: C, not B.
58273 2016-08-18  Paul Eggert  <eggert@cs.ucla.edu>
58275         canonicalize-lgpl: fix errno after malloca fails
58276         This fixes a typo I recently introduced.  Suggested by Bruno Haible in:
58277         http://lists.gnu.org/r/bug-gnulib/2016-08/msg00039.html
58278         * lib/canonicalize-lgpl.c (__realpath):
58279         Don't assume malloca sets errno on failure.
58281 2016-08-17  Paul Eggert  <eggert@cs.ucla.edu>
58283         strtod: port errno handling to z/OS
58284         * lib/strtod.c (strtod): Save and restore errno more reliably.
58286 2016-08-17  Daniel Richard G.  <skunk@iSKUNK.ORG>
58288         strtod: port to z/OS
58289         * lib/strtod.c (strtod): Address a couple quirks in the z/OS
58290         implementation.
58292 2016-08-17  Paul Eggert  <eggert@cs.ucla.edu>
58294         strtod: port to z/OS
58295         * lib/strtod.c (strtod): Address a couple quirks in the z/OS
58296         implementation.
58298         regex, string: rename to avoid '__string'
58299         * lib/regex.h, lib/string.in.h: Do not use the identifier
58300         '__string', as it is effectively reserved by string.h on z/OS.
58302         c-strcase-tests, wcwidth-tests: depend on c-ctype
58303         * modules/c-strcase-tests, modules/wcwidth-tests (Depends-on):
58304         Add c-ctype.
58306 2016-08-17  Daniel Richard G.  <skunk@iSKUNK.ORG>
58308         thread: port to z/OS
58309         * lib/glthread/thread.c, lib/glthread/thread.h:
58310         Rudimentary gl_thread support for z/OS.
58312         maint: port tests to z/OS errno behavior
58313         * tests/test-nonblocking-reader.h:
58314         * tests/test-nonblocking-writer.h:
58315         Accommodate z/OS errno code preferences. (I believe this should
58316         still be within spec; IBM is good at following the letter if not
58317         the spirit of such things.)
58319         maint: preprocessor changes to support z/OS
58320         * lib/alloca.in.h, lib/fnmatch.c, lib/get-rusage-as.c:
58321         * lib/glob.c, lib/math.in.h, lib/ptsname_r.c:
58322         * tests/infinity.h, tests/nan.h, tests/test-canonicalize-lgpl.c:
58323         * tests/test-nonblocking-pipe.h:
58325         fclose, strstr-simple, wchar: port to z/OS
58326         * m4/fclose.m4, m4/strstr.m4, m4/wchar_h.m4:
58327         Changes to the Autoconf M4 code to support z/OS.  Note that
58328         fclose() is broken in a different way on z/OS than it is on other
58329         systems, thus the special-case in fclose.m4.
58331         iconv_open-utf-tests, iconv-tests: port to EBCDIC
58332         * tests/test-iconv-utf.c, tests/test-iconv.c:
58333         Added appropriately conditional #pragmas so that the test strings
58334         in test-iconv-utf.c are correctly interpreted in ASCII instead of
58335         EBCDIC (i.e. 'J' == 0x4A and not 0xD1). This issue could be
58336         addressed in a more portable way by simply rewriting all the ASCII
58337         literal characters as octal escapes, but then you would lose the
58338         partial readability that the strings have now. Also, iconv_open()
58339         on z/OS does not recognize "ISO-8859-1", but "ISO8859-1" works.
58341         c-strcase-tests, wcwidth-tests: port to EBCDIC
58342         * tests/test-c-strcasecmp.c: Include c-ctype.h.
58343         (main) [!C_CTYPE_ASCII]: Skip tests that assume ASCII.
58344         * tests/test-wcwidth.c: Likewise.
58346 2016-08-17  Paul Eggert  <eggert@cs.ucla.edu>
58348         stdbool: don't require _Bool for C++
58349         Problem reported by David Seifert in:
58350         http://lists.gnu.org/r/bug-gnulib/2016-06/msg00005.html
58351         * NEWS, doc/posix-headers/stdbool.texi (stdbool.h): Document this.
58352         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Make the check
58353         more-forgiving for C++, in that it requires only 'bool'.  Be a bit
58354         stricter about checking that bool and _Bool are compatible in C.
58356 2016-08-16  Paul Eggert  <eggert@cs.ucla.edu>
58358         getdelim: remove dependency on realloc-posix
58359         * lib/canonicalize-lgpl.c (alloc_failed)
58360         [!FUNC_REALPATH_WORKS || defined _LIBC]: New function,
58361         (__realpath) [!FUNC_REALPATH_WORKS || defined _LIBC]: Use it.
58362         Use __set_errno where needed, for consistency.
58363         * lib/getdelim.c (alloc_failed): New function.
58364         (getdelim): Use it.
58366 2016-08-09  Assaf Gordon  <assafgordon@gmail.com>
58368         parse-datetime: add optional debug printing
58369         Print parsing information, warnings, and errors to stderr.
58370         * lib/parse-datetime.h (parse_datetimte_debug): New global variable.
58371         * lib/parse-datetime.y:
58372         (DEBUG_*):  Macros calling debug functions if debugging is enabled.
58373         (PROGRESS*): Same as DEBUG, for progress reporting.
58374         (dbg_printf): Print message to stderr, with 'date' prefix.
58375         (struct parser_control): Add 'debug_*_seen' variables.
58376         (str_days): Converts day ordinal/number to string (e.g. 'last wed').
58377         (debug_print_current_time, debug_print_relateive_time): Prints the
58378         current/relative date/time value of parser_control.
58379         (YACC parser syntax): Print parsed parts with DEBUG_* macros.
58380         (to_year): Warn about 2-digit year parsing.
58381         (yylex):   Warn about unrecognized words.
58382         (get_effective_timezone): Returns current timezone in minutes.
58383         (debug_strf{time,date,datetime}): Convert 'struct tm' to string as
58384         clearly and unambigiously as possible.
58385         (debug_mktime_not_ok): Print detailed information about failed
58386         date/time values.
58387         (parse_datetime): Add DEBUG messages for failures, warnings. Add
58388         PROGRESS messages for status messages.
58389         * modules/parse-datetime: Add 'timegm', 'gettext-h' dependencies.
58391 2016-08-06  Jim Meyering  <meyering@fb.com>
58393         tests/init.sh: exclude dash with bad "local" semantics
58394         * tests/init.sh (gl_shell_test_script_): Add a function to
58395         eliminate a shell like "dash" (unlike bash, zsh) that has
58396         surprising/risky "local var='...'" semantics.  Inspired by
58397         the problem and discussion in https://bugs.gnu.org/24116#11.
58399 2016-08-02  Ján Tomko  <jtomko@redhat.com>
58401         maint.mk: expand the prohibit_doubled_word regex
58402         This check has a static list of words that are checked for
58403         repetitions.  Expand it before running the perl script to
58404         avoid using expensive captures.  This decreases the cost
58405         for libvirt from 1.66s to 0.66s.
58406         * top/maint.mk (prohibit_doubled_word_expanded_): Define.
58407         (sc_prohibit_doubled_word): Use it.
58409 2016-07-26  Ján Tomko  <jtomko@redhat.com>
58411         useless-if-before-free: skip non-matching lines early
58412         * build-aux/useless-if-before-free: First match each line with the
58413         simple/quick /\bif\b/ and reject if there is no match. This often
58414         saves the cost of the much more involved regular expression.
58415         For libvirt, this decreases the cost from 1.44s to 1.02s.
58417 2016-07-26  Ján Tomko  <jtomko@redhat.com>
58419         maint.mk: speed up sc_po_check
58420         sc_po_check would skip files based on their names, or on the
58421         existence of files with derived names. Rewrite it to use perl
58422         instead of shell to make the check faster.
58423         * top/maint.mk (perl_translatable_files_list_): Define.
58424         (sc_po_check): Use it.
58426 2016-07-30  Ján Tomko  <jtomko@redhat.com>
58428         maint.mk: speed up require_config_h_first
58429         Instead of spawning three processes per file,
58430         rewrite the check in perl and run it once for all the files.
58431         * top/maint.mk (perl_config_h_first_): Define.
58432         (sc_require_config_h_first): Use it in place of shell code.
58434 2016-07-26  Ján Tomko  <jtomko@redhat.com>
58436         maint.mk: speed up sc_po_check
58437         sc_po_check would skip files based on their names, or on the
58438         existence of files with derived names. Rewrite it to use perl
58439         instead of shell to make the check faster.
58440         * top/maint.mk (perl_translatable_files_list_): Define.
58441         (sc_po_check): Use it.
58443 2016-07-15  Paul Eggert  <eggert@cs.ucla.edu>
58445         obstack: pacify GCC 6 with -Wnull-dereference
58446         Problem reported by Assaf Gordon in:
58447         http://lists.gnu.org/r/bug-gnulib/2016-07/msg00028.html
58448         * lib/obstack.c, lib/obstack.h (obstack_alloc_failed_handler):
58449         Declare with __attribute_noreturn__.
58450         * lib/obstack.h (__attribute_noreturn__): New macro.
58452 2016-07-13  Eric Blake  <eblake@redhat.com>
58454         doc: mention glibc, OS X, Cygwin [S]SIZE_MAX buglet
58455         * doc/posix-headers/stdint.texi (stdint.h): Document the bugs.
58456         * doc/posix-headers/limits.texi (limits.h): Document the bugs.
58458 2016-07-13  Paul Eggert  <eggert@cs.ucla.edu>
58460         doc: mention glibc SSIZE_MAX buglet
58461         * doc/posix-headers/limits.texi (limits.h): Document the bug.
58463 2016-07-04  Martin Kletzander  <mkletzan@redhat.com>
58465         printf-posix: Fix mingw build
58466         Commit 54615b95ff238e235e806855efc46a9abad09f2e changed the regular
58467         expression for detecting C symbol prefixes but forgot to qoute square
58468         brackets in the command line arguments for grep.  That way when
58469         building with mingw the condition was false although it ought to be
58470         true instead.  In particular scenarios this led to the following
58471         compile error:
58473             Cannot export rpl_printf: symbol not found
58474             Cannot export rpl_scanf: symbol not found
58475             collect2: error: ld returned 1 exit status
58477         Fix this by properly quoting square brackets.
58479 2016-07-03  Paul Eggert  <eggert@cs.ucla.edu>
58481         mktime: call tzset as per POSIX
58482         Problem reported by Ludovic Courtès in:
58483         http://lists.gnu.org/r/bug-gnulib/2016-06/msg00068.html
58484         * lib/mktime.c (mktime) [!_LIBC && HAVE_TZSET]: Call tzset.
58485         * m4/mktime.m4 (gl_FUNC_MKTIME): Check for tzset.
58487 2016-06-26  Pádraig Brady  <P@draigBrady.com>
58489         fts: handle readdir() errors
58490         * lib/fts.c (fts_build): readdir(3) returns NULL when finished,
58491         but also upon error when it will also set errno.  Therefore
58492         flag the error case from readdir().  We treat the case where
58493         no items are read the same as if the dir can't be accessed,
58494         i.e. by setting fts_errno to FTS_DNR.
58496 2016-06-24  Paul Eggert  <eggert@cs.ucla.edu>
58498         intprops: port better to GCC 7
58499         GCC 7 __builtin_add_overflow supports a new usage form, where the
58500         last argument is a null pointer, and which merely returns 1 if an
58501         overflow would occur.  This is a constant expression if all
58502         arguments are constants, and should generate faster code when code
58503         needs to be generated.
58504         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_WITH_NULL): New macro.
58505         (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW, _GL_MULTIPLY_OVERFLOW):
58506         Use builtin operations if available.
58507         (INT_NEGATE_OVERFLOW): Prefer INT_SUBTRACT_OVERFLOW if builtin
58508         operations are available, as it's almost surely faster.
58510 2016-06-23  Paul Eggert  <eggert@cs.ucla.edu>
58512         intprops-test: port to GCC 6
58513         * tests/test-intprops.c: Ignore -Woverflow if any GCC version,
58514         since the bug is not fixed in GCC 6.1.
58516 2016-06-13  Paul Eggert  <eggert@cs.ucla.edu>
58518         xalloc-oversized: port to GCC 7; fewer warnings
58519         GCC 7 will have a better way to deal with integer overflow.
58520         Plus, fix a warnings problem reported by Tim Ruehsen in:
58521         http://lists.gnu.org/r/bug-gnulib/2016-06/msg00022.html
58522         * lib/xalloc-oversized.h (__xalloc_oversized): New macro.
58523         (xalloc_oversized): Use plain __builtin_mul_overflow if GCC 7 or later.
58524         For GCC 5, use __xalloc_oversized if both args are constants,
58525         or if pedantic.
58527 2016-06-08  Paul Eggert  <eggert@cs.ucla.edu>
58529         regex: port to Sun C
58530         Reported by Daiki Ueno.
58531         * lib/regcomp.c (regcomp, regerror): Use _Restrict_, not
58532         __restrict, in prototype.  This fixes a problem I introduced in
58533         the 2016-02-19 merge from glibc.
58535 2016-05-31  Paul Eggert  <eggert@cs.ucla.edu>
58537         stdbool: Restore __bool_true_false_are_defined check
58538         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL):
58539         __bool_true_false_are_defined is still defined, even with C++11.
58541 2016-05-31  David Seifert  <soap@gentoo.org>  (tiny change)
58543         stdbool: Port AC_CHECK_HEADER_STDBOOL to C++11
58544         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Port to C++11.
58546 2016-05-30  Paul Eggert  <eggert@cs.ucla.edu>
58548         Use GCC_LINT, not lint
58549         FreeBSD and Cygwin #define _Noreturn to empty if 'lint' is defined.
58550         Problem reported by Ken Brown in: http://bugs.gnu.org/23640
58551         * doc/posix-headers/stdnoreturn.texi (stdnoreturn.h):
58552         Document problem with lint and _Noreturn.
58553         * lib/diffseq.h (IF_LINT, IF_LINT2):
58554         * lib/fts.c (sccsid):
58555         * lib/getndelim2.c (IF_LINT):
58556         * lib/gl_anylinked_list2.h (gl_linked_iterator)
58557         (gl_linked_iterator_from_to):
58558         * lib/gl_anytree_list2.h (gl_tree_iterator)
58559         (gl_tree_iterator_from_to):
58560         * lib/gl_anytree_oset.h (gl_tree_iterator):
58561         * lib/gl_array_list.c (gl_array_iterator)
58562         (gl_array_iterator_from_to):
58563         * lib/gl_array_oset.c (gl_array_iterator):
58564         * lib/gl_carray_list.c (gl_carray_iterator)
58565         (gl_carray_iterator_from_to):
58566         * lib/idcache.c:
58567         * lib/inet_ntop.c (IF_LINT):
58568         * lib/regcomp.c (build_charclass_op, create_tree):
58569         * lib/regex_internal.c (re_acquire_state)
58570         (re_acquire_state_context):
58571         * lib/trigl.c (rcsid):
58572         * lib/trim.c (IF_LINT):
58573         * lib/vasnprintf.c (IF_LINT):
58574         * lib/verify.h (assume):
58575         Treat GCC_LINT like lint.
58577 2016-05-29  Bruno Haible  <bruno@clisp.org>
58579         secure_getenv: Port to many more platforms.
58580         * m4/secure_getenv.m4 (gl_PREREQ_SECURE_GETENV): Also check for get*id
58581         functions.
58582         * lib/secure_getenv.c (secure_getenv): Add alternate implementations
58583         for non-BSD Unix platforms and for native Windows.
58584         * doc/glibc-functions/secure_getenv.texi: Remove known issue.
58585         Prompted by a request from Nikos Mavrogiannopoulos.
58587 2016-05-27  Eric Blake  <eblake@redhat.com>
58589         canonicalize: Fix broken probe for realpath.
58590         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Fix regression
58591         in logic introduced in 54615b95.
58593 2016-05-26  Eric Blake  <eblake@redhat.com>
58595         unsetenv: relax to LGPLv2+
58596         * modules/unsetenv (License): Match setenv license.
58598 2016-05-20  Ludovic Courtès  <ludo@gnu.org>
58600         gendocs.sh: Set default TOP_NODE_UP_URL in HTML output.
58601         Suggested by Gavin Smith <gavinsmith0123@gmail.com>.
58602         Reported by myglc2 <myglc2@gmail.com> in <http://bugs.gnu.org/22651>.
58603         * build-aux/gendocs.sh (MANUAL_TITLE, PACKAGE, EMAIL)
58604         (commonarg, dirargs, dirs, infoarg, generate_ascii)
58605         (generate_html, generate_info, generate_tex, outdir)
58606         (source_extra, split, srcfile, texarg): Move above 'version'.
58607         (htmlarg): Likewise, and add "-c TOP_NODE_UP_URL=/manual".
58609 2016-05-17  Paul Eggert  <eggert@cs.ucla.edu>
58611         manywarnings: update for GCC 6.1
58612         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
58613         Add GCC 6.1 options that apply to C.
58614         * build-aux/gcc-warning.spec: Add GCC 6.1 options that
58615         do not apply to C, are obsolescent, etc.
58617 2016-05-12  Paul Eggert  <eggert@cs.ucla.edu>
58619         glob: size_t overflow checks
58620         * lib/glob.c (__has_builtin): New macro.
58621         (size_add_wrapv, glob_use_alloca): New static functions.
58622         (glob, glob_in_dir): Check for size_t overflow in several places,
58623         and fix some size_t checks that were not quite right.
58625         glob: don't assume INT_MAX < SIZE_MAX
58626         * lib/glob.c (glob): Prefer SIZE_MAX to ~((size_t) 0), as the
58627         latter is not portable to (probably theoretical) hosts where
58628         SIZE_MAX <= INT_MAX.
58630 2016-05-09  Bruno Haible  <bruno@clisp.org>
58632         Fix undefined behaviour in gettext.h.
58633         * lib/gettext.h (dcpgettext_expr, dcnpgettext_expr): Avoid accessing a
58634         pointer's value after the storage it points to has been freed.
58635         Reported by Michael Pyne in https://savannah.gnu.org/bugs/?47847.
58636         Spotted by Coverity.
58638 2016-05-08  Paul Eggert  <eggert@cs.ucla.edu>
58640         git-version-gen: avoid undefined shift
58641         Problem reported by Mosè Giordano in:
58642         http://lists.gnu.org/r/bug-gnulib/2016-05/msg00012.html
58643         * build-aux/git-version-gen: Avoid undefined behavior if invoked
58644         with --prefix or --fallback but without a later argument.  While
58645         we're at it, omit unnecessary quotes.
58647 2016-05-04  Paul Eggert  <eggert@cs.ucla.edu>
58649         glob: merge glibc changes into lib/glob.c
58650         * lib/glob.c (glob_in_dir): Sync with glibc/posix/glob.c,
58651         dated 2016-05-04 12:09:35 2016 +0200.  Here are the changes:
58652         2016-05-04 CVE-2016-1234: glob: Do not copy d_name field of
58653           struct dirent [BZ #19779]
58654         2016-04-29 glob: Simplify the interface for the GLOB_ALTDIRFUNC
58655           callback gl_readdir
58656         2015-10-20 Convert miscellaneous function definitions to prototype style
58657         2015-10-20 Convert 113 more function definitions to prototype style
58658           (files with assertions)
58659         2015-06-12 Fix getlogin_r namespace (bug 18527).
58660         2014-02-10 Use glibc_likely instead __builtin_expect.
58661         2013-10-20 When glob pattern contains a trailing slash match only
58662           directories. Fixes bug 10278.
58663         2013-09-04 glob: silence -Wattribute warnings
58664         2013-06-07 Avoid use of "register" as optimization hint.
58665         2012-09-25 Use size_t instead of int for internal variables in glob
58666           (bug 14621)
58667         2011-07-20 Check for overflows in expressions
58668         2011-05-28 Remove unused variable
58669         2011-05-22 Add a few more alloca size checks
58670         2010-03-27 Whitespace fixes
58671         2010-03-27 Fix one more issue with the glob patch
58672         2010-03-24 Fix glob with empty pattern
58673         2008-05-27 Remove useless more "if" tests before "free"
58674         * modules/glob (Depends-on): Add stdint.
58676 2016-05-01  Paul Eggert  <eggert@cs.ucla.edu>
58678         mktime: port to stricter signed overflow checking
58679         * lib/mktime.c: Omit 'pragma GCC optimize ("wrapv")'.
58680         (long_int): Require width for INT_MAX * 3 * (seconds per year),
58681         instead of merely for INT_MAX * 2.  In practice platforms that
58682         do the latter also do the former.
58683         (TIME_T_MIN, TIME_T_MAX, TIME_T_MIDPOINT, SHR): Remove.
58684         (shr): New static function, replacing SHR.  All uses changed.
58685         (mktime_min, mktime_max): New constants, replacing TIME_T_MIN
58686         and TIME_T_MAX.  All uses changed.
58687         (ydhms_diff, guess_time_tm, ranged_convert, __mktime_internal):
58688         Use long_int, not time_t.
58689         (long_int_avg): New static function, replacing time_t_avg.
58690         All uses changed.  Round toward positive infinity, as that
58691         generates slightly better code.
58692         (time_t_add_ok, time_t_int_add_ok): Remove.  All uses replaced
58693         by INT_ADD_WRAPV.
58694         (guess_time_tm): Accept time, not a pointer to it.  All uses changed.
58695         (convert_time): New static function.
58696         (ranged_convert): Use it
58697         (ranged_convert): Check for *T out of [mktime_min, mktime_max] range.
58698         Use simpler test for loop exit.
58699         (__mktime_internal): Store negative of guessed offset, to simplify
58700         overflow checking.  Remove no-longer-needed test for small time_t
58701         overflows.
58703         mktime: speed up DEBUG_MKTIME benchmarks
58704         Call tzset just once, at the start, rather than for every test
58705         case.  This lets us measure the CPU cost of mktime as opposed to
58706         that of tzset.  This is relevant when TZ is not set and glibc is
58707         being used.  This speeds up tests by a factor of 40 on my Fedora
58708         23 x86-64 platform.
58709         * lib/mktime.c (main) [DEBUG_MKTIME]: Call localtime at the start,
58710         to call tzset and as a sanity check.  Later on, use localtime_r
58711         instead of localtime.
58713         mktime: resurrect DEBUG_MKTIME testing
58714         * lib/mktime.c [DEBUG_MKTIME]: Do not include <config.h>.
58715         Include <string.h>, for strcmp.
58717         mktime: simplify DEBUG_MKTIME
58718         * lib/mktime.c (DEBUG_MKTIME): Define to 0 if not defined.
58719         Simplify later usage accordingly.
58721         Port mktime_internal offset to unsigned time_t
58722         This avoids some assumptions about wraparound arithmetic on
58723         signed integer overflow.
58724         * lib/mktime-internal.h (mktime_offset_t): New type.
58725         (mktime_internal): Use it in decl.
58726         * lib/mktime.c, lib/timegm.c (mktime_offset_t) [_LIBC]: New type.
58728         * lib/mktime.c (__mktime_internal, localtime_offset):
58729         * lib/timegm.c (timegm): Use it.
58730         * m4/mktime.m4 (gl_TIME_T_IS_SIGNED): New macro.
58731         (gl_FUNC_MKTIME): Require it.
58733 2016-04-27  Paul Eggert  <eggert@cs.ucla.edu>
58735         xstrtol: prohibit monstrosities like "1bB"
58736         Problem reported by Young Mo Kang in: http://bugs.gnu.org/23388
58737         * lib/xstrtol.c (__xstrtol): Allow trailing second suffixes like
58738         "B" only if the first suffix needs a base.
58739         * tests/test-xstrtol.sh: Test this.
58741 2016-04-21  Pádraig Brady  <P@draigBrady.com>
58743         xstrtod: reinstate setting of *result upon ERANGE
58744         * lib/xstrtod.c (XSTRTOD): The user may decide to use
58745         the returned limits upon ERANGE, so allow and document that.
58747 2016-04-20  Tino Calancha  <f92capac@gmail.com>  (tiny change)
58749         xstrtod: modify *result only if no errors
58750         * lib/xstrtod.c (XSTRTOD).
58752 2016-04-19  Paul Eggert  <eggert@cs.ucla.edu>
58754         btowc: document problems in C locale
58755         * doc/posix-functions/btowc.texi (btowc): Mention incompatibility
58756         with mbrtowc.  See: http://bugs.gnu.org/23269#32
58758 2016-04-13  Paul Eggert  <eggert@cs.ucla.edu>
58760         mktime: improve integer overflow checking
58761         * lib/mktime.c: Include stdbool.h, intprops.h, verify.h.
58762         (WRAPV): Remove; no longer needed.
58763         (verify): Remove.  Replace all uses with call to verify.h 'verify'.
58764         (TYPE_IS_INTEGER, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
58765         Remove.  Use intprops.h defns instead.
58766         (leapyear, isdst_differ, time_t_add_ok, time_t_int_ok):
58767         Use bool for Boolean, for clarity.
58768         (time_t_add_ok, time_t_int_add_ok): Use INT_ADD_WRAPV to
58769         detect integer overflow.
58770         * modules/mktime (Depends-on): Add intprops, stdbool, verify.
58772         intprops: check two's complement assumption
58773         Suggested by Eric Blake in:
58774         http://lists.gnu.org/r/bug-gnulib/2016-04/msg00016.html
58775         * lib/intprops.h: Include <verify.h>.  Verify that signed char,
58776         short, int, long, and (if available) long long are two's complement.
58777         * modules/intprops (Depends-on): Add 'verify'.
58779         intprops, mktime, strtol: assume two's complement
58780         These macros were not portable to every conforming C11 ones'
58781         complement platform.  It's not worth the hassle of porting to some
58782         platforms that use ones' complement or signed magnitude, as such
58783         platforms are almost purely theoretical nowadays and porting even
58784         to some of them makes the code harder to review for little
58785         practical benefit.  Problem reported by Florian Weimer in:
58786         https://sourceware.org/ml/libc-alpha/2016-04/msg00295.html
58787         * lib/intprops.h (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT)
58788         (TYPE_SIGNED_MAGNITUDE, _GL_INT_TWOS_COMPLEMENT):
58789         * lib/mktime.c (TYPE_TWOS_COMPLEMENT):
58790         * lib/strtol.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT)
58791         (TYPE_SIGNED_MAGNITUDE):
58792         Remove.  All uses rewritten to assume two's complement, which is
58793         all we can reasonably test nowadays anyway.
58794         * top/maint.mk (_intprops_names): Remove the removed macros.
58796 2016-04-11  Paul Eggert  <eggert@cs.ucla.edu>
58798         stdint: port to strict C11 left shift
58799         * lib/stdint.in.h (_STDINT_MIN, _STDINT_MAX):
58800         Pacify clang -Wshift-negative-value, which should be an issue only
58801         on clang setups where stdint.h does not conform to C11 or to C++11.
58802         Problem reported by Philipp Stephani in: http://bugs.gnu.org/23261
58804 2016-04-09  Paul Eggert  <eggert@penguin.cs.ucla.edu>
58806         mbrtowc: work around glibc bug#19932
58807         Fix mbrtowc so that it never returns -1 in the C locale,
58808         as this conflicts with a future version of POSIX
58809         http://austingroupbugs.net/view.php?id=663#c2738
58810         and causes problems with GNU grep: http://bugs.gnu.org/23234
58811         See glibc bug 19932:
58812         https://sourceware.org/bugzilla/show_bug.cgi?id=19932
58813         * doc/posix-functions/mbrlen.texi (mbrlen):
58814         * doc/posix-functions/mbrtowc.texi (mbrtowc):
58815         Document the glibc bug.
58816         * lib/mbrtowc.c [C_LOCALE_MAYBE_EILSEQ]:
58817         Include hard-locale.h, locale.h.
58818         (rpl_mbrtowc): Work around the C_LOCALE_MAYBE_EILSEQ bug,
58819         if the bug is possible.
58820         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): New macro.
58821         (gl_FUNC_MBRTOWC): Use it, and define C_LOCALE_MAYBE_EILSEQ as needed.
58822         * modules/hard-locale (License): Now LGPLv2+, for mbrtowc.
58823         * modules/mbrtowc (Depends-on): Add hard-locale.
58824         * modules/mbrtowc-tests (Files, TESTS): Add tests/test-mbrtowc5.sh.
58825         * tests/test-mbrtowc.c (main): Test for bug fix if arg is '5'.
58826         * tests/test-mbrtowc5.sh: New file.
58828 2016-04-03  Pedro Alves  <palves@redhat.com>
58830         stdint: detect good enough pre-C++11 stdint.h in C++ mode
58831         When gnulib is configured in C++ mode for a system with a working C99
58832         implementation of stdint.h that predates C++11, gnulib ends up
58833         substituting stdint.h anyway.  This works on most targets, but on e.g.,
58834         64-bit MinGW, it doesn't, as gnulib's substitute assumes LP64, while
58835         MinGW is LLP64.  Instead of trying to detect the right types, detect
58836         good-enough-pre-C++11 stdint.h and in such case define
58837         __STDC_CONSTANT_MACROS/__STDC_LIMIT_MACROS in config.h.
58838         * m4/stdint.m4 (gl_STDINT_H): Always define __STDC_CONSTANT_MACROS
58839         / __STDC_LIMIT_MACROS while checking whether the system stdint.h
58840         conforms to C99.  If it does, check whether it hides symbols
58841         behind the __STDC_{CONSTANT|LIMIT}_MACROS macros.  Then if it
58842         does, define those macros in config.h.
58844 2016-04-03  Paul Eggert  <eggert@cs.ucla.edu>
58846         argp: merge changes from glibc
58847         Among other things, this should fix problems found by a Coverity
58848         scan and reported by Andrei Borzenkov:
58849         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00015.html
58850         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00016.html
58851         * lib/argp-ba.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h:
58852         * lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h:
58853         * lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c:
58854         * lib/argp.h:
58855         Merge changes from glibc.
58856         * tests/test-argp-2.sh: Adjust to match new behavior.
58858 2016-04-01  Paul Eggert  <eggert@cs.ucla.edu>
58860         stddef: support configuring with g++
58861         Problem reported by Ángel González in:
58862         http://lists.gnu.org/r/bug-gnulib/2016-04/msg00003.html
58863         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS, max_align_t):
58864         Do not define if _GCC_MAX_ALIGN_T is defined.
58866 2016-03-25  Paul Eggert  <eggert@cs.ucla.edu>
58868         test-framework-sh: minor cleanups
58869         * tests/init.sh (testdir_prefix_): Output a trailing newline,
58870         since strictly speaking POSIX requires this.
58871         (setup_): Do not use the variable 'fail', as that makes the
58872         trace output harder to read ('fail' is typically used by
58873         tests to mean the test failed).  Treat // portably.
58874         Check that new directory is not merely a sibling of the tmp dir.
58875         Avoid unnecessary invocation of tr.
58877         test-framework-sh: revert port to NetBSD 7.0
58878         It was a false alarm; I misinterpreted Assaf Gordon's report.
58879         * tests/init.sh (testdir_prefix_, pfx_, template_length_):
58880         Restore.
58881         (test_dir_): Adjust to mktempd_ change.
58882         (mktempd_): Restore 2nd arg.  Use -t again.
58883         (base_template_, template_, nx_): Resurrect old code.
58885         Port better to Alpine Linux
58886         Its diff implementation does not support -c, but does support -U3.
58887         Problem reported by Assaf Gordon in: http://bugs.gnu.org/23107#13
58888         * tests/init.sh (diff_opt_): New var.
58889         (compare_): Prefer diff -U3 to diff -c to plain diff.
58891 2016-03-24  Paul Eggert  <eggert@cs.ucla.edu>
58893         test-framework-sh: port to NetBSD 7.0
58894         Problem reported by Assaf Gordon in: http://bugs.gnu.org/23107#13
58895         * tests/init.sh (testdir_prefix_, pfx_, template_length_):
58896         Remove.  All uses removed.
58897         (test_dir_): Adjust to mktempd_ change.
58898         (mktempd_): Omit 2nd arg.  Stop using -t, as it is not portable.
58899         (base_template_, template_, nx_): Simplify by hardcoding.
58901 2016-03-22  Paul Eggert  <eggert@cs.ucla.edu>
58903         gitlog-to-changelog: suppress ignored chatter
58904         * build-aux/gitlog-to-changelog: Do not warn about skipping
58905         an SHA if it would have been ignored anyway.
58907 2016-03-22  Geert Janssens  <janssens-geert@telenet.be>
58909         setlocale: add "sv" to Windows language table
58910         * lib/setlocale.c (language_table) [W32]: Add "sv".
58911         Reported in <https://savannah.gnu.org/bugs/?44588>.
58913 2016-03-21  Paul Eggert  <eggert@cs.ucla.edu>
58915         sys_select: port to new Cygwin
58916         Problem reported by Ken Brown in:
58917         https://lists.gnu.org/r/bug-gnulib/2016-03/msg00054.html
58918         * lib/sys_select.in.h [__CYGWIN__]: Avoid "unknown type name"
58919         diagnostics.
58921 2016-03-17  Jim Meyering  <meyering@fb.com>
58923         test-userspec.c: do not trigger gcc's new -Wmisleading-indentation
58924         * tests/test-userspec.c (main): Remove unnecessary braces and fix
58925         misleading indentation. Here is the diagnostic gcc-6.0-to-be issued:
58926           test-userspec.c:176:9: error: statement is indented as if it were \
58927             guarded by... [-Werror=misleading-indentation]
58928                    {
58929                    ^
58930           test-userspec.c:173:7: note: ...this 'if' clause, but it is not
58931                  if (!diag && !T[i].result)
58932                  ^~
58934 2016-03-15  Paul Eggert  <eggert@cs.ucla.edu>
58936         time_rz: port to clang -Wunused-const-variable
58937         * lib/time_rz.c (TZ): Remove.  All uses removed.
58939         std-gnu11: improve clang support
58940         * m4/std-gnu11.m4: Sync with autoconf, incorporating:
58941         2016-03-15 Also try clang
58942         2016-03-15 Port C11 and C++11 testing to clang
58944         select: port more to Intel 2016.1.150 compiler
58945         Problem reported by Balázs Hajgató in:
58946         http://lists.gnu.org/r/bug-gnulib/2016-03/msg00036.html
58947         * m4/select.m4 (gl_FUNC_SELECT): Require AC_C_RESTRICT.
58949 2016-03-14  Paul Eggert  <eggert@cs.ucla.edu>
58951         select: try to port to 2016.1.150 compiler
58952         Problem reported by Balázs Hajgató in:
58953         http://lists.gnu.org/r/bug-gnulib/2016-03/msg00026.html
58954         * lib/sys_select.in.h (select): Use 'restrict' on arguments where
58955         POSIX specifies 'restrict'.
58957 2016-03-13  Paul Eggert  <eggert@cs.ucla.edu>
58959         localename-tests: memory allocation fixes
58960         * tests/test-localename.c (test_locale_name)
58961         (test_locale_name_thread): Don't call freelocale on a locale
58962         that was the base of a successful newlocale, as that
58963         results in a double free.  Problem reported by Assaf Gordon.
58964         (test_locale_name_thread): Free saved names after use, to pacify
58965         gcc -fsanitize=address.
58967 2016-03-08  Paul Eggert  <eggert@cs.ucla.edu>
58969         intprops: make .h file license match module
58970         * lib/intprops.h: Change the license wording to match glibc format.
58971         This is what is in modules/intprops anyway.  See:
58972         https://sourceware.org/bugzilla/show_bug.cgi?id=19738#c8
58974 2016-03-08  Eric Blake  <eblake@redhat.com>
58976         acl: fix missing return on Cygwin
58977         * lib/set-permissions.c (set_acls) [HAVE_FACL && GETACL]: Don't
58978         fall off end of function. Fixes http://bugs.gnu.org/22949
58980 2016-03-05  Bruno Haible  <bruno@clisp.org>
58982         extern-inline: port to PGI CC
58983         * m4/extern-inline.m4 (gl_EXTERN_INLINE): For PGI CC, don't use the
58984         keyword 'inline'.
58985         Reported by Adam James Stewart in:
58986         http://lists.gnu.org/r/bug-gnulib/2016-03/msg00006.html
58988 2016-02-20  Paul Eggert  <eggert@cs.ucla.edu>
58990         signbit: port back to pre-C++11 GCC
58991         * lib/math.in.h (signbit): Do previous change only if
58992         __cplusplus < 201103.  See Jonathan Wakely in:
58993         https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/UY3VX3W7XEXYTUKHG5BALU4ACUD7ZLGE/
58995 2016-02-19  Kamil Dudka  <kdudka@redhat.com>
58997         mountlist: recognize autofs-mounted remote file systems, too
58998         Originally reported at: https://bugzilla.redhat.com/1309247
58999         * lib/mountlist.c (ME_REMOTE): Return true if a file system is named
59000         "-hosts" because it is used by autofs to mount remote file systems.
59002 2016-02-19  Paul Eggert  <eggert@cs.ucla.edu>
59004         signbit: port to C++ with GCC 6
59005         * lib/math.in.h (signbit) [__cplusplus]:
59006         Do not replace with GCC builtin.  Reported by Orion Poplawski in:
59007         http://lists.gnu.org/r/bug-gnulib/2016-02/msg00005.html
59009         * lib/regex_internal.h (IDX_MAX) [_REGEX_LARGE_OFFSETS]: Now SSIZE_MAX.
59011         regex: make it closer to libc
59012         Make Idx a signed type, rather than possibly unsigned.
59013         The unsignedness was not really buying us anything, since the code
59014         overflows for other reasons before getting to PTRDIFF_MAX.  Making
59015         it signed allows us to use -1 and -2 with abandon, like libc does,
59016         thus lessening the number of differences between gnulib and libc.
59017         Also, it should help avoid gratuitous warnings like the one
59018         reported by Nelson H. F. Beebe in: http://bugs.gnu.org/22702
59019         * lib/regex.h (__re_idx_t): Remove.  All uses changed to regoff_t.
59022         regex: merge patches from libc
59024         2015-10-21  Joseph Myers  <joseph@codesourcery.com>
59025         2015-10-20  Joseph Myers  <joseph@codesourcery.com>
59026         Convert miscellaneous function definitions to prototype style.
59027         * lib/regcomp.c (re_compile_pattern, re_set_syntax)
59028         (re_compile_fastmap, regcomp, regerror, regfree, re_comp):
59029         * lib/regexec.c (regexec, re_match, re_search, re_match_2, re_search_2)
59030         (re_search_2_stub, re_search_stub, re_set_registers, re_exec)
59031         (re_search_internal):
59032         Convert to prototype-style function definition.
59033         Use internal_function for internal functions.
59035 2016-02-10  Paul Eggert  <eggert@cs.ucla.edu>
59037         stdalign: port to older HP and IBM cc
59038         * lib/stdalign.in.h (_Alignas): Port better to older HP and IBM
59039         C compilers, by checking their version numbers.  These version
59040         numbers appear in MariaDB and in Qt code that dates way back and
59041         that conditiionally uses the 'aligned' attribute.
59043 2016-02-09  Paul Eggert  <eggert@cs.ucla.edu>
59045         stdalign: port to clang 3.7.0
59046         Problem reported by Herbert J. Skuhra in:
59047         http://lists.gnu.org/r/emacs-devel/2016-02/msg00476.html
59048         * lib/stdalign.in.h (alignas): Fix typo that prevented 'alignas'
59049         from being defined on clang 3.7.0, which has a buggy stdalign.h.  See:
59050         https://llvm.org/bugs/show_bug.cgi?id=26547
59052 2016-02-08  Paul Eggert  <eggert@cs.ucla.edu>
59054         readdir_r: now obsolescent
59055         * doc/posix-functions/readdir_r.texi (readdir_r): Now obsolescent.
59056         * lib/mountlist.c (read_file_system_list): Add a FIXME.
59058 2016-02-06  Paul Eggert  <eggert@cs.ucla.edu>
59060         misc: port better to gcc -fsanitize=address
59061         Without these patches, ./configure CFLAGS='-fsanitize=address'
59062         would compute incorrect values.  This patch fixes some (but not all)
59063         test failures with recent glibc, with this configuration.
59064         * m4/acl.m4 (gl_ACL_GET_FILE):
59065         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
59066         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS):
59067         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO):
59068         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE):
59069         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
59070         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
59071         * m4/getgroups.m4 (gl_FUNC_GETGROUPS):
59072         * m4/getline.m4 (gl_FUNC_GETLINE):
59073         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
59074         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF):
59075         * m4/regex.m4 (gl_REGEX):
59076         * m4/strndup.m4 (gl_FUNC_STRNDUP):
59077         * tests/test-calloc-gnu.c (main):
59078         * tests/test-duplocale.c (main):
59079         * tests/test-getgroups.c (main):
59080         * tests/test-getline.c (main):
59081         * tests/test-inttostr.c (main):
59082         * tests/test-localename.c (test_locale_name)
59083         (test_locale_name_thread, test_locale_name_environ)
59084         (test_locale_name_default):
59085         * tests/test-regex.c (main):
59086         * tests/test-setlocale1.c (main):
59087         * tests/test-stat.h (test_stat_func):
59088         Free heap-allocated storage before exiting.
59089         * m4/asm-underscore.m4 (gl_ASM_SYMBOL_PREFIX):
59090         Don't match *_foo symbols inserted by AddressSanitizer.
59091         * tests/test-regex.c, tests/test-stat.c: Include stdlib.h, for 'free'.
59093 2016-02-02  Jim Meyering  <meyering@fb.com>
59095         verify-tests: also remove stray test-verify.Tpo
59096         * modules/verify-tests (Makefile.am): Arrange for "make clean"
59097         to remove the test-verify.Tpo file that is left behind by
59098         the automake-generated rule upon compilation failure.
59099         Otherwise, that .Tpo file would cause a failed "make distcheck"
59100         at least for grep.
59102 2016-02-02  Paul Eggert  <eggert@cs.ucla.edu>
59104         std-gnu11: new module
59105         This makes it easier for applications to prefer C11 and C++11
59106         to older variants, when compiling C and C++ code.
59107         Unlike most m4/*.m4 files, m4/std-gnu11.m4 is GPLed, as it copies
59108         a nontrivial chunk of GPLed Autoconf source code.
59109         * COPYING: Mention the m4/*.m4 copyright situation.
59110         * MODULES.html.sh (std-gnu11): New module.
59111         * m4/std-gnu11.m4, modules/std-gnu11: New files.
59113 2016-01-25  Paul Eggert  <eggert@cs.ucla.edu>
59115         get-permissions, strftime: fix grammar in comments
59116         * lib/get-permissions.c, lib/strftime.c: Merge into the comments
59117         some grammar fixes Alan Mackenzie made to GNU Emacs.
59119 2016-01-25  Daiki Ueno  <ueno@gnu.org>
59121         gettext: mark as obsolete
59122         Suggested by Paul Eggert in:
59123         https://lists.gnu.org/r/bug-gnulib/2016-01/msg00101.html
59124         * modules/gettext (Status): Mark as obsolete.
59125         (Notice): Suggest to use 'gettext-h' instead.
59126         * modules/gettext-h (Description): Suggest GNU gettext, instead of
59127         the 'gettext' module.
59129 2016-01-24  Paul Eggert  <eggert@cs.ucla.edu>
59131         gnulib-tool: don't give up on ln -s so easily
59132         * gnulib-tool (func_ln_s): Don't give up on a later ln -s merely
59133         because an earlier one failed.  The targets could be on different
59134         file systems.  Problem reported by KO Myung-Hun in:
59135         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00081.html
59137         closedir: fix OS/2-related typos
59138         Problem reported by KO Myung-Hun in:
59139         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00107.html
59140         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Fix a couple of typos
59141         in the last couple of changes.
59143 2016-01-24  KO Myung-Hun  <komh78@gmail.com>
59145         openat_proc_name: fix that last '/' is overwritten on OS/2 kLIBC
59146         * lib/openat-proc.c (openat_proc_name): Increase dirlen by 1 after
59147         copying a directory.
59149 2016-01-24  Paul Eggert  <eggert@cs.ucla.edu>
59151         regex: treat [x] as x if x is a unibyte encoding error
59152         Problem reported by Aharon Robbins in:
59153         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00091.html
59154         * lib/regcomp.c (parse_byte) [!_LIBC && RE_ENABLE_I18N]: New function.
59155         (build_range_exp) [!_LIBC && RE_ENABLE_I18N]: Use it.
59157         closedir, dirfd, opendir: port to OpenSolaris 5.10
59158         * m4/closedir.m4 (gl_FUNC_CLOSEDIR):
59159         * m4/dirfd.m4 (gl_FUNC_DIRFD):
59160         * m4/opendir.m4 (gl_FUNC_OPENDIR):
59161         Don't use ${word##pat} substitution, as it doesn't work in
59162         OpenSolaris 5.10 /bin/sh.  Problem reported by Assaf Gordon in:
59163         http://bugs.gnu.org/22443#11
59165 2016-01-23  Paul Eggert  <eggert@cs.ucla.edu>
59167         bootstrap: use American spelling
59168         * build-aux/bootstrap: Honor American spelling.
59170 2016-01-22  Karl Berry  <karl@freefriends.org>
59172         * doc/posix-functions/localtime.texi,
59173         * doc/posix-functions/localtime_r.texi: @item needed for @itemize text.
59175 2016-01-21  Bruno Haible  <bruno@clisp.org>
59177         hash-pjw-bare: fix comment
59178         * lib/hash-pjw-bare.h (hash_pjw_bare): Fix comment.
59180         wcwidth: Replace also on OpenBSD 5.8
59181         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check the value of wcwidth(0xFF1A).
59182         * doc/posix-functions/wcwidth.texi: Update.
59184 2016-01-20  Pádraig Brady  <P@draigBrady.com>
59186         gnu-web-doc-update: fix addition of new files
59187         If there were already added (emnpty) dirs,
59188         then cvs aborts the add with the message:
59189           cvs [add aborted]: there is a version in <./dirname> already
59190         * build-aux/gnu-web-doc-update: Add directories separately
59191         to the addition of files, to avoid the above issue
59192         impacting the addition of files.
59194 2016-01-19  Daiki Ueno  <ueno@gnu.org>
59196         utimens-tests: avoid pulling gettext .m4 files
59197         Although this is not the right fix to the original problem:
59198         http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html
59199         it makes it possible again for consumer projects to use arbitrary
59200         version of gettext, through the steps described at:
59201         http://www.gnu.org/software/gnulib/manual/html_node/gettextize-and-autopoint.html
59202         See here for details:
59203         https://lists.gnu.org/r/bug-gnulib/2016-01/msg00079.html
59204         * modules/futimens-tests (Depends-on): Add 'gettext-h' in place of
59205         'gettext'.
59206         * modules/utimens-tests (Depends-on): Add 'gettext-h' in place of
59207         'gettext'.
59209 2016-01-18  Paul Eggert  <eggert@cs.ucla.edu>
59211         regex: pacify static checkers
59212         Problem and draft fix reported by Aharon Robbins in:
59213         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00082.html
59214         * lib/regcomp.c (build_charclass_op, create_tree) [lint]:
59215         Clear memory to pacify static checkers.
59217         regex: fix [ diagnostic
59218         Problem and fix reported by Aharon Robbins in:
59219         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00082.html
59220         * lib/regcomp.c (REG_EBRACK_IDX): Fix misleading diagnostic about [.
59222         regex: fix memory leaks
59223         Problem and draft fix reported by Aharon Robbins in:
59224         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00082.html
59225         * lib/regcomp.c (build_range_exp, build_charclass_op)
59226         * lib/regex_internal.c (re_dfa_add_node):
59227         Fix memory leak on failure.
59229 2016-01-18  Pádraig Brady  <P@draigBrady.com>
59231         fts: don't unconditionally use leaf optimization for NFS
59232         NFS st_nlink are not accurate on all implementations,
59233         leading to aborts() if that assumption is made.
59234         See <https://bugzilla.redhat.com/1299169>
59235         * lib/fts.c (leaf_optimization_applies): Remove NFS from
59236         the white list, and document the issue.
59238 2016-01-15  Paul Eggert  <eggert@cs.ucla.edu>
59239             KO Myung-Hun  <komh@chollian.net>
59241         gnulib-tool: don't assume ln -s works
59242         * gnulib-tool (func_ln_s): New function.
59243         (func_ln): Use it.
59245 2016-01-15  KO Myung-Hun  <komh@chollian.net>
59247         utimes: detect utimes() correctly on OS/2 kLIBC
59248         utimes() of OS/2 kLIBC has some limitations.
59249         1. OS/2 itself supports a file date since 1980 year in local time.
59250         2. OS/2 itself supports only even seconds for a file time.
59251         3. utimes() of OS/2 kLIBC does not work on an opened file.
59252         * m4/utimes.m4: Detect utimes() correctly on OS/2 kLIBC.
59253         * doc/posix-functions/utimes.texi: Document the above limitations of
59254         utimes() on OS/2 kLIBC.
59256 2016-01-15  Paul Eggert  <eggert@cs.ucla.edu>
59257             KO Myung-Hun  <komh@chollian.net>
59259         openat_proc_name: port to OS/2 kLIBC
59260         OS/2 kLIBC provides a function to retrive a path from a fd. Use it
59261         instead of /proc/self/fd.
59262         * lib/openat-proc.c (openat_proc_name):
59263         Don't assume file name length is less than INT_MAX.
59264         Port to OS/2 kLIBC with __libc_Back_ioFHToPath().
59266 2016-01-14  KO Myung-Hun  <komh@chollian.net>
59268         stdint: check _INTPTR_T_DECLARED for intptr_t etc.
59269         OS/2 kLIBC's stdint.h defines _INTPTR_T_DECLARED and needs its own
59270         definitions of intptr_t and uintptr_t (which use int and unsigned)
59271         to avoid clashes with declarations of system functions like sbrk.
59272         * lib/stdint.in.h (intptr_t, uintptr_t): Check
59273         _INTPTR_T_DECLARED before defining them.
59275         opendir, closedir, dirfd, fdopendir: port to OS/2 kLIBC
59276         * lib/closedir.c (closedir): Unregister fd if closedir() succeeds.
59277         * lib/dirent.in.h (_gl_register_dirp_fd, _gl_unregister_dirp_fd):
59278         Declare on kLIBC.
59279         * lib/dirfd.c (struct dirp_fd_list): New. Structures to keep track of
59280         fd associated with dirp.
59281         (_gl_register_dirp_fd): New. Register fd associated with dirp to
59282         dirp_fd_list.
59283         (_gl_unregister_dirp_fd): New. Unregister fd with closing it.
59284         (dirfd): Implemented for kLIBC.
59285         * lib/fdopendir.c (fdopendir): Implemented for kLIBC.
59286         * lib/opendir.c (opendir): New. Register fd and dirp pair if open()
59287         succeeds.
59288         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Replace if OS/2.
59289         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
59290         (REPLACE_DIRFD): Define to 1 if replaced.
59291         * m4/opendir.m4 (gl_FUNC_OPENDIR): Likewise.
59292         * modules/closedir (Depends-on): Add dirfd.
59293         * modules/dirfd (Depends-on): Add 'test $REPLACE_DIRFD = 1' to errno
59294         condition.
59295         (configure.ac): Add dirfd to LIBOBJS if $REPLACE_DIRFD = 1 as well.
59296         * modules/opendir (Depends-on): Add dirfd.
59298         dup, dup2, fcntl: support a directory fd on OS/2 kLIBC
59299         On OS/2 kLIBC, dup(), dup2() and fcntl() do not work on a directory fd.
59300         * lib/dup.c (dup_nothrow): New.
59301         * lib/dup2.c (klibc_dup2dirfd): New. dup2() for a directory fd.
59302         (klibc_dup2): New.
59303         * lib/fcntl.c (klibc_fcntl): New.
59304         * m4/dup.m4 (gl_FUNC_DUP): Check if dup() works on a directory fd.
59305         * m4/dup2.m4 (gl_FUNC_DUP2): Check if dup2() works on a directory fd.
59306         * m4/fcntl.m4 (gl_FUNC_FCNTL): Check if F_DUPFD works on a directory
59307         fd.
59309         pipe_filter_ii_execute: port to OS/2 kLIBC
59310         Pipes on kLIBC do not support O_NONBLOCK like Win32.
59311         * lib/pipe-filter-ii.c (start_wrapper, _beginthreadex, CloseHandle,
59312         WaiForSingleObject, WaitForMultipleObjects): New on OS/2 kLIBC.
59313         Reuse Win32 code on OS/2 kLIBC.
59314         * lib/spawn-pipe.c: Reuse Win32 code on OS/2 kLIBC.
59315         * lib/w32spawn.h: Do not include windows.h on OS/2 kLIBC.
59317         wchar: fix "conflicting types" error for __wcwidth on OS/2 kLIBC
59318         On OS/2 kLIBC, wcwidth is a macro that expands to the name of a
59319         static inline function.  The implementation of wcwidth in wcwidth.c
59320         causes a "conflicting types" error.
59321         * lib/wchar.in.h: Undefine wcwidth on OS/2 kLIBC.
59323         w32spawn: clear SHELL_SPECIAL_CHARS and SHELL_SPACE_CHAR on OS/2 kLIBC
59324         spawn() on OS/2 kLIBC is not silly like one on Windows
59325         * libc/w32spawn.h (SHELL_SPECIAL_CHARS, SHELL_SPACE_CHAR): Set both to
59326         empty string on OS/2 kLIBC.
59328         pipe-filter-aux: undefine HAVE_SELECT on KLIBC
59329         On OS/2 kLIBC, select() works only on sockets.
59330         * lib/pipe-filter-aux.h (HAVE_SELECT): Undefine on OS/2 kLIBC.
59332         binary-io: don't put fd in binary mode if it is a console on EMX
59333         * lib/binary-io.h (SET_BINARY): Don't put fd in binary mode if it is
59334         a console on EMX.
59336 2016-01-15  Pádraig Brady  <P@draigBrady.com>
59338         doc: mention unfixed issues with unsupported localtime() values
59339         * doc/posix-functions/localtime.texi: Mention that FreeBSD 10
59340         returns nonsense for localtime(2^56).
59341         * doc/posix-functions/localtime_r.texi: Likewise.
59343 2016-01-14  Pádraig Brady  <P@draigBrady.com>
59345         doc: mention setlocale() issues on OpenBSD
59346         * doc/posix-functions/setlocale.texi: Mention setlocale(LC_ALL,"")
59347         never fails, and the need to check categories individually.
59349 2016-01-14  Pádraig Brady  <P@draigBrady.com>
59351         sig2str: list all signals on FreeBSD >= 7
59352         FreeBSD >= 7 is contravening POSIX by not defining NSIG
59353         to the maximal statically defined signal value.
59354         It does define _SIG_MAXSIG though, so base SIGNUM_BOUND on that.
59355         * lib/sig2str.h (SIGNUM_BOUND): Define to (_SIG_MAXSIG - 2)
59356         where available, even when NSIG is defined.
59358 2016-01-13  Paul Eggert  <eggert@cs.ucla.edu>
59360         acl-permissions: port to USE_ACL==0 platforms
59361         I ran into this problem when building bleeding-edge GNU Emacs
59362         with gcc -fsanitize=address on Fedora 23.  On this platform
59363         the ACL library does not pass the 'configure' test and Emacs
59364         then does not build due in part to what appear to be typos in the
59365         ACL part of Gnulib.
59366         * lib/acl-internal.c (free_permission_context):
59367         * lib/acl-internal.h (struct permission_context):
59368         Test whether USE_ACL is nonzero, not whether it is defined.
59370 2016-01-12  Martin Sebor  <msebor@redhat.com>
59372         mktime: rename macro to avoid glibc clash
59373         * lib/mktime.c [DEBUG] (DEBUG): Rename to DEBUG_MKTIME.  See:
59374         https://sourceware.org/ml/libc-alpha/2016-01/msg00267.html
59376 2016-01-12  Paul Eggert  <eggert@cs.ucla.edu>
59378         Port "$@" to OpenIndiana ksh93
59379         In http://lists.gnu.org/r/bug-autoconf/2015-12/msg00000.html
59380         Pavel Raiskup reports that ${1+"$@"} runs afoul of a bug in /bin/sh
59381         (derived from ksh 93t+ 2010-03-05).  ${1+"$@"} works around an ancient
59382         bug long-dead shells, so remove the workaround.
59383         * build-aux/announce-gen, build-aux/do-release-commit-and-tag:
59384         * build-aux/gitlog-to-changelog, build-aux/gnu-web-doc-update:
59385         * build-aux/prefix-gnulib-mk, build-aux/update-copyright:
59386         * build-aux/useless-if-before-free, tests/test-update-copyright.sh:
59387         Use "$@" instead of ${1+"$@"}.
59389         Port Universal Time settings to strict POSIX
59390         * build-aux/announce-gen, build-aux/bootstrap:
59391         * build-aux/do-release-commit-and-tag, build-aux/git-version-gen:
59392         * build-aux/gitlog-to-changelog, build-aux/gnu-web-doc-update:
59393         * build-aux/gnupload, build-aux/mkinstalldirs:
59394         * build-aux/move-if-change, build-aux/prefix-gnulib-mk:
59395         * build-aux/update-copyright, build-aux/useless-if-before-free:
59396         * build-aux/vc-list-files, tests/test-strftime.c:
59397         Use TZ="UTC0", not TZ="UTC".  Either works on GNU platforms,
59398         but POSIX says the behavior of TZ="UTC" is undefined.
59400 2016-01-02  Paul Eggert  <eggert@cs.ucla.edu>
59402         msvc-inval: fix problem with unset shell var
59403         Problem reported by Karl Berry in:
59404         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00004.html
59405         * modules/msvc-inval (Depends-on):
59406         AC_REQUIRE gl_MSVC_INVAL instead of merely calling it.
59407         * modules/msvc-nothrow (Depends-on): Likewise for gl_MSVC_NOTHROW.
59409 2016-01-01  Pádraig Brady  <P@draigBrady.com>
59411         tests: for compare_(), use cmp -s where available
59412         * tests/init.sh (compare_): Only fall back to cmp without
59413         the POSIX defined -s option, where this is not available.
59415 2016-01-01  Paul Eggert  <eggert@cs.ucla.edu>
59417         version-etc: new year
59418         * build-aux/gendocs.sh (version):
59419         * doc/gendocs_template:
59420         * doc/gendocs_template_min:
59421         * doc/gnulib.texi:
59422         * lib/version-etc.c (COPYRIGHT_YEAR):
59423         Update copyright dates by hand in templates and the like.
59424         * all files: Run 'make update-copyright'.
59426 2015-12-31  Paul Eggert  <eggert@cs.ucla.edu>
59428         human: fix output buffer overrun by 1
59429         * lib/human.c (human_readable): Fix off-by-one typo in buffer
59430         calculation that could lead to a one-byte buffer overrun.
59432 2015-12-28  Daiki Ueno  <ueno@gnu.org>
59434         maint: fix operator precedence in mbrtowc test
59435         This is a fix for test breakage introduced by commit 45228d96; the
59436         equality expression must be parenthesized when negated with '!',
59437         otherwise we always get:
59439           test-mbrtowc.c:49: assertion 'ret == (size_t)(-2)' failed
59441         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT): Negate the entire expression.
59442         * m4/mbrlen.m4 (gl_MBRLEN_EMPTY_INPUT): Likewise.
59444 2015-12-23  James Youngman  <jay@gnu.org>
59446         regexprops-generic: update from regex.h
59447         * doc/regexprops-generic.texi: update by running the regexprops binary
59448         from findutils (the command line is 'regexprops "Regular Expressions"
59449         generic').  The recent (ish) change (5a5a9388) to regex.h aligning
59450         gnulib with GNU grep had made this document out-of-date.
59452 2015-12-23  Pádraig Brady  <P@draigBrady.com>
59454         strftime-tests: avoid false failure on OS X
59455         * tests/test-strftime.c (struct localtime_rz_test): Add an
59456         ahistorical member which is used to warn rather than fail
59457         when tm_isdst isn't set for such entries.  This is the case for
59458         "1970-01-01 13:00:00 +1300 (NZDT)" on Darwin 13/14 at least.
59460 2015-12-20  Kamil Dudka  <kdudka@redhat.com>
59462         fts: ensure leaf optimization is used for NFS
59463         NFS provides usable dirent.d_type but not necessarily for all entries
59464         of large directories.  See <https://bugzilla.redhat.com/1252549>
59465         * lib/fts.c (leaf_optimization_applies): Append NFS on the white list.
59467 2015-12-20  Pádraig Brady  <P@draigBrady.com>
59469         fts: enable leaf optimization for XFS
59470         XFS provides usable dirent.d_type only for DT_DIR,
59471         but the noleaf optimization still applies.
59472         * lib/fts.c (leaf_optimization_applies): Add XFS to the white list.
59474 2015-12-17  Paul Eggert  <eggert@cs.ucla.edu>
59476         intprops: comment fix
59477         * lib/intprops.h: Fix comment.  Reported by Pádraig Brady in:
59478         http://lists.gnu.org/r/bug-gnulib/2015-12/msg00013.html
59480         intprops-test: work around GCC bug 68971
59481         Problem reported by Pádraig Brady in:
59482         http://lists.gnu.org/r/bug-gnulib/2015-12/msg00011.html
59483         * tests/test-intprops.c: Ignore -Woverflow in GCC 6 and earlier.
59484         (main): Add a case that better tests 64-bit long in this area.
59486 2015-12-09  Pavel Raiskup  <praiskup@redhat.com>
59488         gnulib-tool: allow multiple --local-dir usage
59489         * gnulib-tool: Use --local-dir to construct compound
59490         $local_gnulib_path path instead of $local_gnulib_dir.  Determine
59491         PATH_SEPARATOR early.
59492         (local_gnulib_dir): Rename into $local_gnulib_path everywhere.
59493         (func_gnulib_dir): Cut out PATH_SEPARATOR detection code into
59494         func_determine_path_separator because that needs to be detected
59495         earlier now.
59496         (func_determine_path_separator): New function.
59497         (func_path_foreach, func_path_foreach_inner): New functions.
59498         (func_path_prepend, func_path_append): Likewise.
59499         (func_lookup_local_file, func_lookup_local_file_cb): Likewise.
59500         (func_lookup_file, func_all_modules): Use new functions to work
59501         with local_gnulib_path.
59502         (func_modules_in_dir, func_exists_module): New callbacks for
59503         func_path_foreach.
59504         (func_exists_module, func_get_tests_module): Likewise.
59505         (func_is_local_file, func_should_symlink): New helper methods.
59506         (func_add_file, func_update_file): Use new func_should_symlink
59507         instead, DRY.
59508         (func_reconstruct_cached_local_gnulib_path): New helper.
59509         (func_reconstruct_cached_dir): New callback.
59510         (func_import): The cached_local_gnulib_dir renamed to
59511         cached_local_gnulib_path similarly to local_gnulib_dir.
59512         Use new func_reconstruct_cached_local_gnulib_path.
59513         (func_count_relative_local_gnulib_path): New sub-method.
59514         (func_create_testdir): Use func_should_symlink, DRY.
59515         (func_create_megatestdir): Use new functions to work with
59516         local_gnulib_path correctly.
59517         (func_append_local_dir): New helper.
59519 2015-12-08  Pádraig Brady  <P@draigBrady.com>
59521         fix freadptr to work with ungetc on all uClibc configs
59522         Reported at https://bugs.busybox.net/show_bug.cgi?id=4099
59523         where GNU coreutils cut(1) generates invalid output on uClibc
59524         when __UCLIBC_HAS_STDIO_GETC_MACRO__ is not defined.
59525         * lib/freadptr.c (freadptr): Return NULL if there are
59526         ungotten chars.  In this case freadseek() will iterate
59527         again to process the ungotten character.
59529 2015-11-13  Paul Eggert  <eggert@cs.ucla.edu>
59531         xalloc-oversized: improve performance with GCC 5
59532         * lib/xalloc-oversized.h (xalloc_oversized):
59533         Improve performance with GCC 5 by using __builtin_mul_overflow.
59535 2015-11-10  Paul Eggert  <eggert@cs.ucla.edu>
59537         intprops: new public macro EXPR_SIGNED
59538         Emacs can use this macro, so make it public.
59539         * doc/intprops.texi (Arithmetic Type Properties): Rename from
59540         'Integer Type Determination', since some of these macros apply
59541         to non-integer types.  Clarify what kinds of constant expressions
59542         these macros return.  Say when the arguments can be non-integers.
59543         Mention newly published macro EXPR_SIGNED.
59544         * lib/intprops.h (EXPR_SIGNED): Rename from _GL_INT_SIGNED, to
59545         make it public.  All uses changed.
59547         intprops: fix typo in clang port
59548         * lib/intprops.h (_GL_INT_OP_WRAPV): Fix misspelling of
59549         '__builtin_add_overflow' that is not caught by compiler.
59551 2015-11-05  Paul Eggert  <eggert@cs.ucla.edu>
59553         test-timespec: fix typo in previous change
59554         * tests/test-timespec.c (main): Fix typo that reduced test quality.
59556         timespec-sub: fix overflow bug; add tests
59557         * lib/timespec-add.c (timespec_add):
59558         * lib/timespec-sub.c (timespec_sub):
59559         Work even if time_t is narrower than int (a theoretical
59560         possibility).  Redo code for a bit more clarity.
59561         * lib/timespec-sub.c (timespec_sub):
59562         Fix off-by-2 bug if a.tv_sec == TYPE_MINIMUM (time_t) and 0 < b.tv_sec.
59563         * modules/timespec-tests, tests/test-timespec.c: New files.
59565         intprops-test: suppress -Woverlength-strings
59566         Problem reported by Pádraig Brady in:
59567         http://lists.gnu.org/r/bug-gnulib/2015-11/msg00008.html
59568         It is not worth the hassle to port this test to compilers that
59569         cannot handle long strings in diagnostics.
59570         * tests/test-intprops.c [__GNUC__]: Ignore -Woverlength-strings.
59572 2015-11-03  Pádraig Brady  <P@draigBrady.com>
59574         quotearg: add quotearg_n_style_colon()
59575         This quotes with default options of the specified style,
59576         but with quoting enabled for instances of ':'.
59577         * lib/quotearg.h (quotearg_n_style_colon): Description and declaration.
59578         * lib/quotearg.c (quotearg_n_style_colon): New function implementation.
59580 2015-11-04  Paul Eggert  <eggert@cs.ucla.edu>
59582         intprops: revise _WRAPV macros, revert _OVERFLOW
59583         The incompatible changes to the _OVERFLOW macros were too much of
59584         a hassle in practice, so revert them.  Instead, change the new
59585         _WRAPV macros to make them closer in behavior to GCC 5's new
59586         builtin_add_overflow etc. functions.  No other software was using
59587         these newly-added macros yet, so this should be OK.
59588         * NEWS: Revert previous change, since the incompatible change
59589         has been reverted, and nobody used the incompatible version.
59590         * doc/intprops.texi (Wraparound Arithmetic, Integer Type Overflow):
59591         Document revised behavior.
59592         (Integer Range Overflow): Adjust example to match above revisions.
59593         * lib/intprops.h (INT_ADD_OVERFLOW, INT_SUBTRACT_OVERFLOW)
59594         (INT_MULTIPLY_OVERFLOW): Revert previous change, so that
59595         these can be used in integer constant expressions again.
59596         (INT_CONST_ADD_OVERFLOW, INT_CONST_SUBTRACT_OVERFLOW)
59597         (INT_CONST_MULTIPLY_OVERFLOW): Remove, as these are no longer
59598         needed.
59599         (INT_CONST_ADD_WRAPV, INT_CONST_SUBTRACT_WRAPV)
59600         (INT_NEGATE_WRAPV, INT_CONST_MULTIPLY_WRAPV, INT_DIVIDE_WRAPV)
59601         (INT_REMAINDER_WRAPV, INT_LEFT_SHIFT_WRAPV):
59602         Remove, as they did not seem that useful.
59603         (INT_ADD_WRAPV, INT_SUBTRACT_WRAPV, INT_MULTIPLY_WRAPV)
59604         (_GL_INT_OP_WRAPV, _GL_INT_OP_WRAPV_LONGISH)
59605         (_GL_INT_OP_WRAPV_VIA_UNSIGNED):
59606         Support new semantics.
59607         (__has_builtin): New macro, if not alreay defined.
59608         (_GL__GENERIC_BOGUS, _GL_INT_OP_CALC, _GL_INT_OP_CALC1): New macros.
59609         * tests/test-intprops.c (INT_CONST_DIVIDE_OVERFLOW)
59610         (INT_CONST_REMAINDER_OVERFLOW, INT_CONST_LEFT_SHIFT_OVERFLOW)
59611         (INT_CONST_DIVIDE_WRAPV, INT_CONST_REMAINDER_WRAPV)
59612         (INT_CONST_LEFT_SHIFT_WRAPV): Remove.
59613         (CHECK_SBINOP, CHECK_SSUM, CHECK_SUM1, CHECK_SSUM1)
59614         (CHECK_SDIFFERENCE, CHECK_SPRODUCT, CHECK_PRODUCT1, CHECK_SPRODUCT1):
59615         New macros.
59616         (CHECK_BINOP, CHECK_UNOP, main, CHECK_SUM): Test new behavior.
59618 2015-11-03  Jim Meyering  <meyering@fb.com>
59620         intprops: add parentheses for when OP has precedence lower than "-"
59621         * lib/intprops.h (_GL_INT_OP_WRAPV_VIA_UNSIGNED): In "a OP b - c",
59622         "a OP b" must be parenthesized for when OP is like "<<", which has
59623         lower precedence than the following "-". Reported by Pádraig Brady.
59625 2015-11-03  Pádraig Brady  <P@draigBrady.com>
59627         quotearg: constify get_quoting_style parameters
59628         * lib/quotearg.h (get_quoting_style): Mark parameter as const.
59629         * lib/quotearg.c (get_quoting_style): Likewise.
59631 2015-11-02  Pádraig Brady  <P@draigBrady.com>
59633         quotearg: add support for $'' shell escaping
59634         * lib/quotearg.h: Add "shell-escape" and "shell-escape-always"
59635         items and descriptions.
59636         * lib/quotearg.c (quotearg_buffer_restyled): Add support for the
59637         above types by quoting like "shell", but using $'...' syntax
59638         for non printable characters, which should provide unambiguous
59639         printable output for any input.
59640         * tests/test-quotearg-simple.c: Update accordingly.
59642 2015-11-02  Pádraig Brady  <P@draigBrady.com>
59644         maint: use a more standard return from mbrtowc test
59645         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT): Don't return 1
59646         from the test program as this is non standard and often
59647         indicates an unhandled case in the test program.
59648         * m4/mbrlen.m4 (gl_MBRLEN_EMPTY_INPUT): Likewise.
59650 2015-10-30  Paul Eggert  <eggert@cs.ucla.edu>
59652         intprops: add WRAPV and const flavors for GCC 5
59653         If available, use GCC 5's builtin functions for efficient integer
59654         overflow checking.  Also, add macros like INT_ADD_WRAPV efficently
59655         and safely compute the low-order bits of the correct answer.
59656         A downside of these efficient functions is that they cannot be
59657         used in constant expressions, so add macros like INT_CONST_ADD_OVERFLOW
59658         and INT_CONST_ADD_WRAPV that can be used even in constant expressions.
59659         * NEWS: Document the incompatible changes to INT_ADD_OVERFLOW etc.
59660         * doc/intprops.texi (Integer Properties, Integer Type Overflow):
59661         Document the changes.
59662         (Wraparound Arithmetic): New section.
59663         (Integer Range Overflow):
59664         Put this subsection last, since it's least useful.
59665         * lib/intprops.h (INT_CONST_ADD_OVERFLOW)
59666         (INT_CONST_SUBTRACT_OVERFLOW, INT_CONST_MULTIPLY_OVERFLOW):
59667         New macros, with the meaning that INT_ADD_OVERFLOW etc. used to have.
59668         (INT_CONST_ADD_WRAPV, INT_CONST_SUBTRACT_WRAPV)
59669         (INT_NEGATE_WRAPV, INT_CONST_MULTIPLY_WRAPV, INT_DIVIDE_WRAPV)
59670         (INT_REMAINDER_WRAPV, _GL_INT_OP_WRAPV, _GL_EXPR_CAST)
59671         (_GL_INT_OP_WRAPV_LONGISH, INT_ADD_WRAPV, INT_SUBTRACT_WRAPV)
59672         (INT_MULTIPLY_WRAPV, _GL_OP_OVERFLOW, _GL_OP_WRAPV, _GL_OP_WRAPV_GENSYM):
59673         New macros.
59674         (INT_ADD_OVERFLOW, INT_SUBTRACT_OVERFLOW, INT_MULTIPLY_OVERFLOW):
59675         Generate calls to GCC builtins if available, for speed.
59676         * tests/test-intprops.c (INT_CONST_DIVIDE_OVERFLOW)
59677         (INT_CONST_REMAINDER_OVERFLOW, INT_CONST_LEFT_SHIFT_OVERFLOW)
59678         (INT_CONST_DIVIDE_WRAPV, INT_CONST_REMAINDER_WRAPV)
59679         (INT_CONST_LEFT_SHIFT_WRAPV): New macros.
59680         (main, CHECK_BINOP, CHECK_UNOP, CHECK_SUM, CHECK_PRODUCT)
59681         (CHECK_QUOTIENT, CHECK_REMAINDER):
59682         Test WRAPV and CONST flavors (when available) too.
59684 2015-10-30  Pádraig Brady  <P@draigBrady.com>
59686         doc: use extended timezone format in iso-8601 example
59687         * doc/parse-datetime.texi: The standard states that extended format
59688         is to be used consistently throughout.
59689         Note that lib/parse-datetime.y can handle either tz format.
59691 2015-10-25  Paul Eggert  <eggert@cs.ucla.edu>
59693         stdalign: port to Sun C 5.9
59694         * doc/posix-headers/stdalign.texi: Document this.
59695         * lib/stdalign.in.h (_Alignas): Sun C 5.9 also supports
59696         __attribute__ ((__aligned__ (...))).
59698 2015-10-20  Paul Eggert  <eggert@cs.ucla.edu>
59700         time_rz: fix comment about tzalloc
59701         * lib/time_rz.c (tzalloc): Fix comment.
59703 2015-10-18  Paul Eggert  <eggert@cs.ucla.edu>
59705         stdalign: work around pre-4.9 GCC x86 bug
59706         * lib/stdalign.in.h (_Alignof): Work around bug in pre-4.9 GCC on
59707         x86, when -std=gnu11 is used.  Problem reported by Jim Meyering in:
59708         http://lists.gnu.org/r/bug-gnulib/2015-10/msg00038.html
59710 2015-10-18  Pádraig Brady  <P@draigBrady.com>
59712         maint.mk: sc_tight_scope: remove extraneous expressions
59713         * top/maint.mk (tight_scope): This is not really required since
59714         commit 3ef58f46 as sed_wrap ensures we don't get an empty expression
59715         that matches all nm entries.  But it does remove extraneous entries
59716         that may be confusing or cause issue in future maintenance.
59718 2015-10-18  Paul Eggert  <eggert@cs.ucla.edu>
59720         time_rz: return NULL if localtime_r fails
59721         * lib/time_rz.c (localtime_rz): Return NULL if localtime_r fails,
59722         while still attempting to pacify bleeding-edge GCC.
59724         fts: port to C11 alignof
59725         * doc/posix-headers/stdalign.texi (stdalign.h):
59726         Document the C11 restriction.
59727         * lib/fts.c: Include stddef.h, for max_align_t.
59728         (fts_alloc): Align using max_align_t, not FTSENT.
59729         * modules/fts (Depends-on): Add stddef.
59731 2015-10-18  Jim Meyering  <meyering@fb.com>
59733         time_rz: avoid warning from bleeding-edge gcc's -Wnonnull
59734         Compiling with gcc version 6.0.0 20151017 (experimental) (GCC), I
59735         would see this:
59737         lib/time_rz.c: In function 'localtime_rz':
59738         lib/time_rz.c:292:15: error: nonnull argument 'tm' compared to NULL \
59739           [-Werror=nonnull]
59740                    if (tm && !save_abbr (tz, tm))
59741                        ^
59743         That was complaining about "tm" because it is a parameter that was
59744         declared with the __nonnull__ attribute.
59745         * lib/time_rz.c (localtime_rz): Don't bother setting "tm" to the
59746         result of localtime_r.
59748 2015-10-17  Jim Meyering  <meyering@fb.com>
59750         maint.mk: _gl_TS_function_match: fix "extern" name extracting regexp
59751         * top/maint.mk (_gl_TS_function_match): This heuristic extern-function-
59752         name-extraction regexp mistakenly used \S+, and would mistakenly
59753         extract "*F" from "extern int *F()" rather than the desired "F".
59754         Use \w+ instead.
59756 2015-10-17  Jim Meyering  <meyering@fb.com>
59758         maint.mk: sc_tight_scope: factor and support OS X
59759         * top/maint.mk (_gl_tight_scope): Address three issues:
59760         - factor out four instances of code that wraps a string in "^...$"
59761         - allow nm-reported symbol names to have an optional leading "_"
59762         - add "main" to the list of ignored variable names, because on os x,
59763         "main" has nm-reported type "S" in the variable-checking section.
59765 2015-10-16  Dmitry Smirnov  <onlyjob@member.fsf.org>
59767         safe-alloc-tests: fix typo in license header
59768         * tests/test-safe-alloc.c: Mention LGPL 2.1, not 3.1
59770 2015-10-15  Simon Reinhardt  <simon@keinstein.org>
59772         copy-file: fix mem leak in error case
59773         * lib/copy-file.c (qcopy_file_preserving): Free the 32KiB buffer
59774         upon error opening or performing I/O to the src and dest files.
59776 2015-10-15  Mike Frysinger  <vapier@chromium.org>
59778         localename: control langinfo.h inclusion
59779         This header is only used to work around buggy behavior in old
59780         versions of glibc, so do not include it all the time.  Otherwise
59781         we get build failures on systems that do not provide langinfo.h.
59782         * lib/localename.c: Wrap langinfo.h include with same ifdefs used
59783         in the source later on.
59784         The patch was originally submitted to gettext as:
59785         https://lists.gnu.org/r/bug-gettext/2015-10/msg00011.html
59787 2015-10-13  Paul Eggert  <eggert@cs.ucla.edu>
59789         binary-io, math, pthread, sys_socket, u64, unistd: port to strict C
59790         * lib/binary-io.c, lib/math.c, lib/pthread.c, lib/sys_socket.c:
59791         * lib/u64.c, lib/unistd.c:
59792         Append 'typedef int dummy;', to pacify compilers that are picky
59793         about empty translation units.
59795 2015-10-12  Pino Toscano  <ptoscano@redhat.com>
59797         accept4-tests: fix to avoid non portable flags
59798         * tests/test-accept4.c (main): Pass only SOCK_* flags to accept4(),
59799         as they are the only documented ones, and passing others may trigger
59800         EINVAL (seen on FreeBSD 10.1-RELEASE).
59801         * doc/glibc-functions/accept4.texi: Mention that we don't provide
59802         the SOCK_CLOEXEC or SOCK_NONBLOCK defines.
59804 2015-10-06  Pavel Raiskup  <praiskup@redhat.com>
59806         gnulib-tool: fix tests of 'extensions' module
59807         This complements f8fe25fab60e3c687a124 commit.
59808         * gnulib-tool (func_emit_pre_early_macros): New function, it wraps
59809         emitting of initial gl_EARLY macros.
59810         (func_import, func_create_testdir): All dumps of gl_PROG_AR_RANLIB
59811         replaced with func_emit_pre_early_macros call.
59813 2015-10-06  Paul Eggert  <eggert@cs.ucla.edu>
59815         unicase/locale-language: fix typo in utf-8 cookie
59816         * lib/unicase/locale-languages.gperf: Fix gperf input file format.
59817         Problem reported by Zbigniew Jędrzejewski-Szmek.
59819 2015-10-02  Paul Eggert  <eggert@cs.ucla.edu>
59821         xalloc: do not worry about GCC 5 warning on 32 bit
59822         * lib/xalloc.h: Revert previous change.
59823         I found a better way to fix this in coreutils.
59825 2015-10-02  Pádraig Brady  <P@draigBrady.com>
59827         xalloc: avoid GCC 5.1 warning on 32 bit
59828         * lib/xalloc.h: Disable -Wstrict-overflow for uses of
59829         xalloc_oversized(), which was seen to give this warning
59830         on GCC 5.1 on 32 bit: "assuming signed overflow does not occur
59831         when simplifying conditional".
59833 2015-10-02  Daiki Ueno  <ueno@gnu.org>
59835         uniname/uniname-tests: avoid compiler warnings
59836         * tests/uniname/test-uninames.c (fill_names, fill_aliases): Remove
59837         unused local variables.
59838         (test_alias_lookup): Fix alias name display in failure cases.
59840 2015-09-26  Paul Eggert  <eggert@cs.ucla.edu>
59842         c-ctype: do not worry about EBCDIC + char signed
59843         Drop support for EBCDIC with char being signed, as this breaks too
59844         many programs.  Problem reported by Ben Pfaff in:
59845         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00053.html
59846         * lib/c-ctype.h: Verify that we are not using EBCDIC with
59847         char being signed.
59848         (_C_CTYPE_LOWER_A_THRU_F_N): New macro.
59849         (_C_CTYPE_LOWER_N, _C_CTYPE_A_THRU_F): Use it.
59850         (_C_CTYPE_DIGIT, _C_CTYPE_LOWER, _C_CTYPE_PUNCT, _C_CTYPE_UPPER):
59851         (c_isascii, c_isgraph, c_isprint, c_ispunct, c_tolower, c_toupper):
59852         * tests/test-c-ctype.c (test_all):
59853         Simplify by assuming standard char values cannot be negative.
59854         * tests/test-c-ctype.c (NCHARS, to_char): Remove; all uses removed.
59856 2015-09-25  Paul Eggert  <eggert@cs.ucla.edu>
59858         c-ctype: port better to z/OS EBCDIC
59859         Problems reported by Daniel Richard G. in:
59860         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00050.html
59861         * lib/c-ctype.h (_C_CTYPE_CNTRL): Rewrite in terms of
59862         the C standard escapes and _C_CTYPE_OTHER_CNTRL.
59863         (_C_CTYPE_OTHER_CNTRL): New macro.
59864         * tests/test-c-ctype.c (test_all): Test from CHAR_MIN, not
59865         from SCHAR_MIN, as the functions are defined only from values
59866         promoted from char or from unsigned char, not necessarily from
59867         signed char.
59869 2015-09-25  Pavel Raiskup  <praiskup@redhat.com>
59871         gnulib-common.m4: fix gl_PROG_AR_RANLIB/AM_PROG_AR clash
59873         The gl_PROG_AR_RANLIB (it is always called by gl_EARLY) sets AR
59874         and ARFLAGS variables.  Doing this unconditionally could break
59875         later Automake's AM_PROG_AR invocation (at least it's
59876         AC_CHECK_TOOLS call to detect correct 'ar' binary).
59878         Original purpose of the gl_PROG_AR_RANLIB was only to handle the
59879         Amsterdam Compiler Kit, so make the previous code to have effects
59880         only on ACK, and rather automatically call the Automake's
59881         AM_PROG_AR as soon as possible to decide other cases.
59883         References:
59884         http://lists.gnu.org/r/bug-gnulib/2015-07/msg00001.html
59886         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): AC_BEFORE AM_PROG_AR.
59887         Set the AR/ARFLAGS to ACK defaults OR call AM_PROG_AR.  If neither
59888         is possible, keep setting AR/ARFLAGS to reasonable defaults.
59889         * gnulib-tool (func_import): Put the gl_USE_SYSTEM_EXTENSIONS
59890         right before gl_PROG_AR_RANLIB into gnulib-comp.m4 (if the
59891         'extensions' module is used.
59892         * modules/extensions (configure.ac-early): Remove as this snippet
59893         is added to gnulib-comp.m4 earlier anyway.
59895 2015-09-25  Paul Eggert  <eggert@cs.ucla.edu>
59897         sockets: MS Windows initalization fixes
59898         Problem reported by Test User in:
59899         http://lists.gnu.org/r/help-shishi/2015-09/msg00001.html
59900         * lib/sockets.h (SOCKETS_1_0, SOCKETS_2_0, SOCKETS_2_1):
59901         Correct the endianness.
59902         * lib/sockets.c (gl_sockets_startup): Return 2 on any version
59903         number mismatch, not just on <.  Cleanup before any such failure.
59905 2015-09-25  Mats Erik Andersson  <gnu@gisladisker.se>
59907         gc: fix detection of installed libgcrypt version
59908         * m4/gc.m4: Use AM_PATH_LIBCRYPT to test for libcrypt versions
59909         at least as recent as 1.4.4.  The previously used macro is not
59910         available now, since modules were removed in version 1.6.0.
59912 2015-09-25  Paul Eggert  <eggert@cs.ucla.edu>
59914         c-ctype: rewrite to use inline functions
59915         This simplifies maintenance, since it makes for just one
59916         implementation of each function, letting the compiler have the fun
59917         of optimization.  In practice this works well nowadays with GCC.
59918         E.g., c_isascii might need only three instructions even though the
59919         source code lists every ASCII character individually in a large
59920         switch statement.
59921         Also, fix some z/OS porting bugs reported by Daniel Richard G. in:
59922         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00037.html
59923         * NEWS: Document the API change.
59924         * lib/c-ctype.c: Drastically simplify, since this now just expands
59925         inline functions.
59926         * lib/c-ctype.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
59927         (C_CTYPE_INLINE): New macro.
59928         (C_CTYPE_CONSECUTIVE_DIGITS, C_CTYPE_CONSECUTIVE_LOWERCASE)
59929         (C_CTYPE_CONSECUTIVE_UPPERCASE): Remove.
59930         Verify that either ASCII or EBCDIC is being used.
59931         (_C_CTYPE_SIGNED_EBCDIC, _C_CTYPE_CNTRL, _C_CTYPE_A_THRU_F_N)
59932         (_C_CTYPE_DIGIT_N, _C_CTYPE_LOWER_N, _C_CTYPE_UPPER_N)
59933         (_C_CTYPE_CASES, _C_CTYPE_A_THRU_F, _C_CTYPE_DIGIT, _C_CTYPE_LOWER)
59934         (_C_CTYPE_UPPER, _C_CTYPE_PUNCT_PLAIN):
59935         New private macros.
59936         (_C_CTYPE_CNTRL): In EBCDIC, '\x07' is a control, not '\xff'.
59937         (c_isalnum, c_isalpha, c_isascii, c_isblank, c_iscntrl, c_isdigit)
59938         (c_isgraph, c_islower, c_isprint, c_ispunct, c_isspace, c_isupper)
59939         (c_isxdigit, c_tolower, c_toupper): Now inline functions.
59940         (c_tolower, c_toupper): When converting, return the unsigned char,
59941         as that is what z/OS does.
59942         * lib/c-strcaseeq.h (CASEEQ): Simplify in the light of the removal
59943         of some c-ctype.h macros.
59944         * modules/c-ctype (Depends-on): Add extern-inline; remove verify.
59945         * tests/test-c-ctype.c (test_all): Fix test for c_toupper and
59946         c_tolower promotion to be compatible with z/OS.
59948 2015-09-24  Pavel Raiskup  <praiskup@redhat.com>
59950         gitlog-to-changelog: trim only trailing whitespaces
59951         This is fix for --format regression introduced by commit
59952         2b93079a5d1baa4d;  it caused that --format='%s%n%n%b%n' (see the
59953         doubled %n string) had no effect anymore.  This format
59954         specification has been used e.g. by GNU paxuitils (commit
59955         edfd8bcc3).
59957         * build-aux/gitlog-to-changelog (main): Stop squashing multiple
59958         newlines in commmit messages.
59960 2015-09-23  Paul Eggert  <eggert@cs.ucla.edu>
59962         Test that c_iscntrl agrees with iscntrl, etc.
59963         Suggested by Daniel Richard G. in:
59964         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00034.html
59965         * modules/c-ctype-tests (Depends-on): Add ctype.
59966         * tests/test-c-ctype.c: Include <ctype.h>.
59967         (NCHARS): New constant.
59968         (test_agree_with_C_locale): New function.
59969         (main): Use it.
59970         (test_all): Use named constants.
59972         c-ctype: improve c_isascii testing
59973         * tests/test-c-ctype.c (test_all): Port c_isascii test to EBCDIC.
59974         Add a test to count the number of ASCII characters.
59976 2015-09-22  Paul Eggert  <eggert@cs.ucla.edu>
59978         savewd: remove SAVEWD_CHDIR_READABLE
59979         It was problematic in the light of file systems that ignore umask.
59980         Problem reported by Sebastian Unger in: http://bugs.gnu.org/21534
59981         * NEWS: Document this.
59982         * lib/mkancesdirs.c (mkancesdirs): MAKE_DIR now returns 0 if
59983         successful, -1 (setting errno) on failure, rather than something
59984         more complicated than that.
59985         * lib/mkdir-p.c (make_dir_parents):
59986         Do not use SAVEWD_CHDIR_READABLE.
59987         * lib/savewd.c (savewd_chdir):
59988         Remove support for SAVEWD_CHDIR_READABLE.
59989         * lib/savewd.h (SAVEWD_CHDIR_READABLE): Remove.
59991         c-ctype: port better to EBCDIC
59992         Problems reported by Daniel Richard G. in
59993         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00020.html
59994         * lib/c-ctype.c: Include <limits.h>, for CHAR_MIN and CHAR_MAX.
59995         Include "verify.h".
59996         (C_CTYPE_ASCII, C_CTYPE_CONSECUTIVE_DIGITS)
59997         (C_CTYPE_CONSECUTIVE_LOWERCASE, C_CTYPE_CONSECUTIVE_UPPERCASE):
59998         Define as enum constants with value false, if not defined, so that
59999         code can use 'if' instead of 'ifdef'.  Using 'if' helps make the
60000         code more portable, as both branches of the 'if' are compiled on
60001         all platforms.
60002         (C_CTYPE_EBCDIC): New constant.
60003         Verify that the character set is either ASCII or EBCDIC.
60004         (to_char): New static function.
60005         (c_isascii, c_iscntrl):
60006         Assume standard control-character assignments for EBCDIC.
60007         (c_isalnum, c_isalpha, c_isdigit, c_islower, c_isgraph, c_isprint)
60008         (c_ispunct, c_isupper, c_isxdigit, c_tolower, c_toupper):
60009         Rewrite to use 'if' instead of 'ifdef'.
60010         Use to_char if non-ASCII.  Prefer <= to >=.
60011         Prefer true and false to 1 and 0, for booleans.
60012         (c_iscntrl): Use 'if', not 'ifdef'.
60013         * modules/c-ctype (Depends-on): Add verify.
60014         * tests/test-c-ctype.c: Include <limits.h>, for CHAR_MIN
60015         (to_char): New function.
60016         (test_all): Port to EBCDIC.  Add some more tests, e.g., for c_ispunct.
60018 2015-09-21  Pádraig Brady  <P@draigBrady.com>
60020         nanosleep: fix return code for interrupted replacement
60021         * lib/nanosleep.c (nanosleep): In the replaced nanosleep, ensure
60022         that we return -1 in the case the call is interrupted by a signal,
60023         rather than the current value of 1.
60024         Diagnosed and tested by Daniel Richard G.
60026 2015-09-19  Paul Eggert  <eggert@cs.ucla.edu>
60028         Diagnose ERE '()|\1'
60029         Problem reported by Hanno Böck in: http://bugs.gnu.org/21513
60030         * lib/regcomp.c (parse_reg_exp): While parsing alternatives, keep
60031         track of the set of previously-completed subexpressions available
60032         before the first alternative, and restore this set just before
60033         parsing each subsequent alternative.  This lets us diagnose the
60034         invalid back-reference in the ERE '()|\1'.
60036         regex: merge patches from libc
60038         2015-09-08  Joseph Myers  <joseph@codesourcery.com>
60039         Move bits/libc-lock.h and bits/libc-lockP.h out of bits/ (bug 14912).
60040         * lib/regex_internal.h:
60041         Include <libc-lock.h> instead of <bits/libc-lock.h>.
60043         2015-06-09  Joseph Myers  <joseph@codesourcery.com>
60044         Fix regcomp wcscoll, wcscmp namespace (bug 18497).
60045         * lib/regcomp.c (build_range_exp): Call __wcscoll instead of
60046         wcscoll.
60047         * lib/regexec.c (check_node_accept_bytes): Likewise.
60049         2015-06-05  Joseph Myers  <joseph@codesourcery.com>
60050         Fix regex wcrtomb namespace (bug 18496).
60051         * lib/regex_internal.c (build_wcs_upper_buffer): Call __wcrtomb
60052         instead of wcrtomb.
60054         2015-06-05  Joseph Myers  <joseph@codesourcery.com>
60055         Fix regex wctype namespace (bug 18495).
60056         * lib/regcomp.c (re_compile_fastmap_iter): Call __towlower
60057         instead of towlower.
60058         * lib/regex_internal.c (build_wcs_upper_buffer): Call __iswlower
60059         instead of iswlower.  Call __towupper instead of towupper.
60060         * lib/regex_internal.h (IS_WIDE_WORD_CHAR): Call __iswalnum
60061         instead of iswalnum.
60063         2015-01-07  Chris Metcalf  <cmetcalf@ezchip.com>
60064         * lib/regcomp.c (parse_bracket_exp): Initialize type to
60065         COLL_SYM in a couple of places to avoid uninitialized variable
60066         wanings on tilegx gcc 4.8.2.
60068         2014-11-24  Siddhesh Poyarekar  <siddhesh@redhat.com>
60069         * lib/regex_internal.h: Remove NOT_IN_libc.
60071         2014-11-17  Andreas Schwab  <schwab@suse.de>
60072         * lib/regex_internal.h: Don't include <locale/elem-hash.h>.
60074         2014-09-11  Roland McGrath  <roland@hack.frob.com>
60075         Move findidx nested functions to top-level.
60076         * lib/regcomp.c [_LIBC]: #include <locale/weight.h>.
60077         (build_equiv_class) [_LIBC]: Don't #include it inside the function.
60078         Pass new arguments to findidx.
60079         * lib/regexec.c [RE_ENABLE_I18N] [_LIBC]: #include <locale/weight.h>.
60080         [RE_ENABLE_I18N] (check_node_accept_bytes) [_LIBC]:
60081         Don't #include it inside the function.  Pass new arguments to findidx.
60082         * lib/regex_internal.h:
60083         [!NOT_IN_libc] [_LIBC]: #include <locale/weight.h>.
60084         (re_string_elem_size_at): Don't #include it inside the function.
60085         Pass new arguments to findidx.
60087         2014-08-01  Siddhesh Poyarekar  <siddhesh@redhat.com>
60088         Check if DEBUG is defined in regex_internal.c
60089         * lib/regex_internal.c: Check if DEBUG is defined and is set.
60091 2015-09-08   Assaf Gordon  <assafgordon@gmail.com>
60093         ceill: detect buggy OpenBSD implementation
60094         * m4/ceill.m4 (gl_FUNC_CEILL): Detect buggy openBSD implementation
60095         which returns zero for small values.  Discussed here:
60096         http://lists.gnu.org/r/bug-gnulib/2015-08/msg00010.html
60098 2015-09-08  Dave Chiluk  <chiluk@canonical.com>
60100         mountlist: add me_mntroot field on Linux machines
60101         * lib/mountlist.c (read_file_system_list): Populate me_mntroot in
60102         mount_entry so Linux machines based on /proc/self/mountinfo can
60103         distinguish between bind mounts and original mounts.  In reality bind
60104         mounts aren't treated differently than mountroot=/ mounts by the
60105         kernel, but the user often wants these bind mounts distinguished.
60106         * lib/mountlist.h (struct mount_entry): Add me_mntroot element.
60107         More details at https://pad.lv/1432871
60109 2015-09-08  Christian Egli  <christian.egli@sbs.ch>
60111         doc: Describe to use multiple instances of gnulib
60112         * doc/gnulib-tool.texi: Add a section to the manual outlining how two
60113         instances of gnulib with different modules can be used, for example one
60114         for a lib and another one for associated tools.
60116 2015-09-01  Pádraig Brady  <P@draigBrady.com>
60118         base32: mark function as __attribute__ const
60119         * lib/base32.h (isbase32): Mark __attribute__ const as
60120         suggested by GCC, and consistent with the base64 module.
60122 2015-08-20  Daiki Ueno  <ueno@gnu.org>
60124         gnulib-tool: don't transform binary files with sed
60125         * gnulib-tool (func_add_or_update): Don't apply sed_transform_* to
60126         .mo and .class files.
60127         Reported by Denis Denisov.
60129 2015-08-10  Daiki Ueno  <ueno@gnu.org>
60131         gperf: respect silent rules
60132         * modules/gperf (Makefile.am): Define V_GPERF, V_GPERF_, and
60133         V_GPERF_0 for silent rules.
60134         * modules/iconv_open (Makefile.am): Use V_GPERF.
60135         * modules/unicase/locale-language (Makefile.am): Likewise.
60136         * modules/unicase/special-casing (Makefile.am): Likewise.
60137         * modules/unictype/category-byname (Makefile.am): Likewise.
60138         * modules/unictype/combining-class-byname (Makefile.am): Likewise.
60139         * modules/unictype/joininggroup-byname (Makefile.am): Likewise.
60140         * modules/unictype/joiningtype-byname (Makefile.am): Likewise.
60141         * modules/unictype/property-byname (Makefile.am): Likewise.
60142         * modules/unictype/scripts (Makefile.am): Likewise.
60143         * modules/uninorm/composition (Makefile.am): Likewise.
60145 2015-08-03  Paul Eggert  <eggert@cs.ucla.edu>
60147         Improve port of stdalign to C++11
60148         Problem reported by Sundaram in:
60149         http://lists.gnu.org/r/bug-gnulib/2015-08/msg00003.html
60150         * lib/stdalign.in.h (alignof, alignas): Don't define if C++11 or newer.
60151         (__alignas_is_defined): Define if C++11 or newer.
60153 2015-08-01  Assaf Gordon  <assafgordon@gmail.com>  (tiny change)
60155         pmccabe2html: fix gawk regex escaping
60156         * build-aux/pmccabe2html: Add one more backslash to properly
60157         escape the gsub replacement value.  Fixes this error:
60158         gawk: ./build-aux/pmccabe2html:425: \
60159         warning: escape sequence `\&' treated as plain `&'
60161 2015-07-29  Paul Eggert  <eggert@cs.ucla.edu>
60163         time_rz: port to pedantic memcpy
60164         * lib/time_rz.c (tzalloc): Pacify pedantic memcpy implementations
60165         that reject memcpy (..., NULL, 0).
60167 2015-07-27  Paul Eggert  <eggert@cs.ucla.edu>
60169         time_rz: port better to MinGW
60170         Don't change tzname, as this makes MinGW dump core (Bug#21020).
60171         Instead, store the tzname copy in the struct tm_zone object.
60172         Problem reported by Eli Zaretskii in: http://bugs.gnu.org/21020#48
60173         * lib/strftime.c [!_LIBC]:
60174         * lib/time_rz.c: Include time-internal.h.
60175         * lib/strftime.c (strftime_case_) [!HAVE_TM_ZONE]: Infer the zone
60176         name from *TZ rather than from TZNAME, doable because *TZ now has
60177         a tzname_copy member.
60178         * lib/time-internal.h: New file, with contents taken from
60179         lib/time_rz.c.  It's separate because strftime.c now accesses
60180         struct tm_zone members.
60181         (struct tm_zone) [HAVE_TZNAME && !HAVE_TM_ZONE]:
60182         New member tzname_copy.
60183         * lib/time_rz.c (struct tm_zone): Move to time-internal.h.
60184         (tzalloc) [HAVE_TZNAME && !HAVE_TM_ZONE]:
60185         Initialize tzname_copy member.
60186         (save_abbr) [HAVE_TZNAME && !HAVE_TM_ZONE]: Save abbreviation
60187         in tzname_copy member.
60188         (revert_tz) [HAVE_TZNAME]: Remove no-longer-needed tzname saving.
60189         (restore_tzname): Remove; no longer needed.  All calls removed.
60190         * modules/time_rz (Files): Add lib/time-internal.h.
60192         time: port __need_time_t to MinGW
60193         * lib/time.in.h (__need_time_t): Do not treat specially on MinGW.
60194         Fix reported by Eli Zaretskii in: http://bugs.gnu.org/21020#36
60196 2015-07-25  Paul Eggert  <eggert@cs.ucla.edu>
60198         strftime: fix newly-introduced bug on Solaris
60199         * lib/strftime.c (strftime_case_): Set the local variable 'zone'
60200         consistently at the start, rather than doing some of the setup at
60201         the start and some in the %Z format spec.  This is cleaner, and
60202         works better with time_rz on platforms like Solaris where struct
60203         tm lacks a tm_zone member, as when !HAVE_TM_GMTOFF %z's calls to
60204         mktime_z and localtime_rz can mess up the tzname cache.
60206         test-strftime: test for Solaris bug
60207         * modules/strftime-tests (Depends-on): Add strerror.
60208         * tests/test-strftime.c: Include <errno.h>.
60209         (posixtm_test): New function, containing the old 'main'.
60210         (struct tzalloc_test, struct localtime_rz_test): New types.
60211         (TZ, LT): New static vars.
60212         (tzalloc_test): New function.
60213         (main): Rewrite in terms of posixtm_test and tzalloc_test.
60215         time_rz: port to Solaris etc.
60216         Works around a tzname problem on platforms like Solaris that have
60217         tzname but not tm_zone, by setting tzname at the appropriate time
60218         and restoring it later.
60219         * lib/time_rz.c (tzname_address, tzname_value) [HAVE_TZNAME]:
60220         New static vars.
60221         (save_abbr) [HAVE_TZNAME]: Set them.
60222         (revert_tz) [HAVE_TZNAME]: Clear or use them.
60223         (restore_tzname): New function.
60224         (localtime_rz, mktime_z): Use it.
60226         time_rz: now LGPL
60227         * modules/time_rz (License): Now LGPL, because strftime depends on it.
60229         time_rz: make a constant 'const'
60230         * lib/time_rz.c (local_tz): Now const.
60232         time_rz: fix off-by-one typo
60233         * lib/time_rz.c (extend_abbrs): Fix off-by-one typo.
60235 2015-07-23  Paul Eggert  <eggert@cs.ucla.edu>
60237         fprintftime, strftime: use timezone_t args
60238         * NEWS: Document the change.
60239         * lib/fprintftime.h (fprintftime):
60240         * lib/strftime.c (extra_args) [my_strftime]:
60241         * lib/strftime.h (nstrftime):
60242         Time zone arg is now of type timezone_t, not int.
60243         * lib/strftime.c (mktime_z) [_LIBC]: New macro.
60244         (__gmtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: Remove; no longer used.
60245         (my_strftime) [emacs && !my_strftime]:
60246         (emacs_strftimeu) [emacs && !FPRINTFTIME]:
60247         Remove; Emacs doesn't need this any more.
60248         (HAVE_TZSET) [my_strftime]: Unset, since we no longer want
60249         fprintftime and nstrftime to call tzset.
60250         (ut) [!my_strftime]: Remove, replacing with ...
60251         (tz) [!my_stftime]: ... this new macro.  All uses changed.
60252         (strftime_case_): Use localtime_rz and mktime_z instead
60253         of localtime_r and mktime.
60254         * modules/fprintftime (Depends-on): Add time_rz.
60255         * modules/strftime (Depends-on): Add time_rz.  Remove time_r.
60256         * tests/test-strftime.c (main): Adjust to new nstrftime API.
60258         time_rz: new module
60259         * MODULES.html.sh: Add time_rz.
60260         * lib/time_rz.c, m4/time_rz.m4, modules/time_rz: New files.
60261         * lib/time.in.h (timezone_t, tzalloc, tzfree, localtime_rz, mktime_z):
60262         New decls if _GNU_SOURCE && @GNULIB_TIME_RZ@ && ! @HAVE_TIMEZONE_T@.
60263         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS):
60264         New var HAVE_TIMEZONE_T (default 0).
60265         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS):
60266         New var GNULIB_TIME_RZ (default 0).
60267         * modules/time (time.h): Substitute the new vars.
60269         flexmember: license is now unlimited
60270         * modules/flexmember (License): Change to unlimited,
60271         since its only source file gives an unlimited license.
60273 2015-07-15  Eric Blake  <eblake@redhat.com>
60275         maint: update copyright paper procedures
60276         * config/srclist.txt: Drop outdated files.
60277         * doc/Copyright/conditions.txt: Update to latest.
60278         * doc/Copyright/assign.changes.manual: Delete.
60279         * doc/Copyright/assign.future.manual: Likewise.
60280         * doc/Copyright/assign.manual: Likewise.
60281         * doc/Copyright/assign.translation.manual: Likewise.
60282         * doc/Copyright/disclaim.changes.manual: Likewise.
60283         * doc/Copyright/disclaim.manual: Likewise.
60284         * doc/Copyright/disclaim.program: Likewise.
60286 2015-07-07  Daiki Ueno  <ueno@gnu.org>
60288         localename: fix link error on Illumos
60289         Illumos defines __sun, but does not have getlocalename_l nor the
60290         equivalent.  This partially reverts commit 387c214.
60291         * m4/localename.m4 (gl_LOCALENAME): Check if getlocalename_l is
60292         available, as well as uselocale.
60293         * lib/localename.c [HAVE_USELOCALE && __sun]: Don't fallback to
60294         use getlocalename_l if it is not available.
60296 2015-07-07  Daiki Ueno  <ueno@gnu.org>
60298         unistr/uN-strtok-tests: avoid a trivial leak
60299         * tests/unistr/test-u-strtok.h (test_u_strtok): Untabify.  Free
60300         input and delim after the multibyte delimiter tests.
60302 2015-07-04  Paul Eggert  <eggert@cs.ucla.edu>
60304         file-has-acl, acl-permissions: fix HP-UX typos
60305         Problem reported by John David Anglin in: http://bugs.gnu.org/20979
60306         * lib/file-has-acl.c (file_has_acl):
60307         * lib/set-permissions.c (context_acl_from_mode)
60308         (context_aclv_from_mode, set_acls):
60309         Fix some obvious typos when HAVE_GETCL /* HP-UX */.
60310         They were introduced by the recent ACL changes.
60312         regex: match current GNU grep behavior
60313         These symbols have not matched GNU grep behavior for quite some time.
60314         Fix prompted by Balazs Kezes bug report at: http://bugs.gnu.org/20974
60315         * lib/regex.h (RE_SYNTAX_GREP, RE_SYNTAX_EGREP):
60316         Change to match current GNU behavior.
60317         Simplify by expressing it as differences from POSIX BREs and EREs.
60318         (RE_SYNTAX_POSIX_EGREP): No longer differs from GNU behavior.
60320 2015-07-03  Jim Meyering  <meyering@fb.com>
60322         set-permissions.c: adjust acl_from_mode's cpp guard
60323         * lib/set-permissions.c (acl_from_mode): Guard with #ifdef
60324         directives identical to those guarding the sole use.
60325         Otherwise, on some systems, we'd get a warning about
60326         the function being defined but not used.
60327         Also, filter through cppi to correct misleading indentation
60328         of cpp directives.
60330 2015-07-03  Pádraig Brady  <P@draigBrady.com>
60332         tests: restrict shells to those that support 'local'
60333         The local keyword is very widely supported and used
60334         in tests in coreutils and grep at least.  Therefore
60335         restrict to testing with shells that support it.
60336         This mainly excludes /bin/sh on Solaris.
60337         * tests/init.sh (gl_shell_test_script_): Add a test for 'local'.
60339 2015-07-03  Seiya Kawashima  <skawashima@uchicago.edu>  (tiny change)
60340         and Daiki Ueno  <ueno@gnu.org>
60342         unistr/uN-strtok: handle multibyte delimiters
60343         Previously, uN_strtok moved PTR to the next unit to the token end.
60344         When DELIM contained a multibyte character, the new position could
60345         be a middle of a multibyte character.
60346         * lib/unistr/u-strtok.h (FUNC): Place PTR at the next character
60347         after the token.
60348         * lib/unistr/u8-strtok.c (U_STRMBLEN): New macro.
60349         * lib/unistr/u16-strtok.c (U_STRMBLEN): New macro.
60350         * lib/unistr/u32-strtok.c (U_STRMBLEN): New macro.
60351         * modules/unistr/u8-strtok (Depends-on): Depend on
60352         unistr/u8-strmblen.
60353         * modules/unistr/u16-strtok (Depends-on): Depend on
60354         unistr/u16-strmblen.
60355         * modules/unistr/u32-strtok (Depends-on): Depend on
60356         unistr/u32-strmblen.
60357         * tests/unistr/test-u-strtok.h: New file.
60358         * tests/unistr/test-u8-strtok.c: New file.
60359         * tests/unistr/test-u16-strtok.c: New file.
60360         * tests/unistr/test-u32-strtok.c: New file.
60361         * modules/unistr/u8-strtok-tests: New file.
60362         * modules/unistr/u32-strtok-tests: New file.
60363         * modules/unistr/u16-strtok-tests: New file.
60365 2015-07-02  Friedrich Haubensak  <hsk@fli-leibniz.de>
60367         update-copyright: fix test failure with perl >= 5.22 (trivial)
60368         * build-aux/update-copyright: Escape a literal left curly bracket,
60369         required with perl >= 5.22
60371 2015-07-02  Daiki Ueno  <ueno@gnu.org>
60373         u{16,32}-strstr-tests: relax timeout condition
60374         On slower platforms (e.g., Solaris 10/SPARC), u{16,32}-strstr
60375         tests can take longer than 5 seconds to complete.
60376         Reported by Dagobert Michelsen in:
60377         https://lists.gnu.org/r/bug-libunistring/2015-06/msg00006.html
60378         * tests/unistr/test-u16-strstr.c (main): Increase timeout from 5
60379         seconds to 10 seconds.
60380         * tests/unistr/test-u32-strstr.c (main): Likewise.
60382 2015-07-01  Pavel Raiskup  <praiskup@redhat.com>
60384         gnulib-common.m4: change the ARFLAGS default to 'cr'
60385         In some GNU/Linux distributions people started to compile 'ar'
60386         binary with --enable-deterministic-archives (binutils project).
60387         That, however, in combination with previous autotools long time
60388         working default AR{_,}FLAGS=cru causes warnings on such
60389         installations:
60390         ar: `u' modifier ignored since `D' is the default (see `U')
60391         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): Set ARFLAGS='cr' if not
60392         set already.
60394 2015-07-01  Pavel Raiskup  <praiskup@redhat.com>
60396         selinux-h: avoid double free after *getfilecon()
60397         Originally reported by Ben Shelton on bug-tar:
60398         http://lists.gnu.org/r/bug-tar/2015-04/msg00009.html
60399         * lib/getfilecon.c (map_to_failure): Set the already freed '*con'
60400         pointer to NULL.  Man getfilecon(3) says that any non-NULL '*con'
60401         param should be freed by freecon(3) (regardless the return value).
60403 2015-07-01  Pavel Fedin  <p.fedin@samsung.com>
60405         fix pty related tests issues on Windows (trivial)
60406         * lib/grantpt.c (grantpt): grantpt.c seems to be never used on Windows,
60407         however it's still present in tests/ subdirectory of the final project.
60408         Therefore avoid it to pass `make check`.
60409         * tests/test-openpty.c (main): Windows has no PTYs and gnulib's openpty()
60410         will just return -ENOSYS, so avoid this non applicable test allowing
60411         the build to proceed.
60413 2015-07-01  Pádraig Brady  <P@draigBrady.com>
60415         acl: fix definition of acl_from_mode on FreeBSD
60416         This was causing basic coreutils copy operations to fail
60417         with ENOTSUP or ENOENT error messages.
60418         * lib/acl-internal.h (acl_from_mode): Only define when
60419         ! defined HAVE_ACL_FROM_TEXT.  That allows the version
60420         of acl_from_mode() defined in lib/set-permissions.c to
60421         be used on FreeBSD at least.
60422         * lib/set-permissions.c: Fix up comment spelling,
60423         and a redundant variable assignment; noticed in passing.
60425 2015-06-30  Pádraig Brady  <P@draigBrady.com>
60427         readutmp: port to FreeBSD >= 9
60428         * lib/readutmp.h: Map utmpxname() to setutxdb().
60429         With that coreutils who(1) and pinky(1) tests pass.
60431 2015-06-30  Paul Eggert  <eggert@cs.ucla.edu>
60433         mgetgroups: port to strict OS X
60434         The previous fix wasn't working, so use a bigger hammer (Bug#20923).
60435         * lib/mgetgroups.c: Ignore -Wpointer-sign diagnostics.
60436         (getgrouplist_gids) [HAVE_GETGROUPLIST]: Remove.  All uses removed.
60437         * m4/mgetgroups.m4 (gl_MGETGROUPS): Revert recent changes.
60439 2015-06-29  Paul Eggert  <eggert@cs.ucla.edu>
60441         mgetgroups: port to strict OS X
60442         * doc/glibc-functions/getgrouplist.texi (getgrouplist):
60443         Document the getgrouplist problem.
60444         * lib/mgetgroups.c (getgrouplist_gids) [HAVE_GETGROUPLIST]:
60445         New macro.
60446         (mgetgroups): Use it.
60447         * m4/mgetgroups.m4 (gl_MGETGROUPS):
60448         Check for OS X signature for getgrouplist.
60450 2015-06-29  Jim Meyering  <meyering@fb.com>
60452         linkat: fix invalid definition of LINKAT_SYMLINK_NOTSUP on OS X
60453         It started like this when building coreutils' latest on OS X,
60454         invoking ./configure with a nonempty --cache=.cache:
60456           lib/linkat.c:46:42: error: operator '||' has no right operand
60457           lib/linkat.c: In function 'rpl_linkat':
60458           lib/linkat.c:330:27: error: #if with no expression
60460         Here's linkat.c's line 46:
60462           #if !HAVE_LINKAT || LINKAT_SYMLINK_NOTSUP
60464         Here's some context:
60466           $ grep linkat_nofoll .cache
60467           gl_cv_func_linkat_nofollow=${gl_cv_func_linkat_nofollow=no}
60468           $ grep LINKAT_SYM lib/config.h
60469           #define LINKAT_SYMLINK_NOTSUP
60471         The problem is that m4/linkat.m4's gl_FUNC_LINKAT
60472         uses AC_CACHE_CHECK to set LINKAT_SYMLINK_NOTSUP,
60473         but that violates a tenet of AC_CACHE_CHECK: it must
60474         have no side effect other than setting its cache variable.
60476         What happens is that when the cache is set, we'd skip the
60477         code in that AC_CACHE_CHECK call, and leave LINKAT_SYMLINK_NOTSUP
60478         defined to whatever value it happened to have in configure's
60479         environment.  In my case, it was not defined, so this later code:
60481           AC_DEFINE_UNQUOTED([LINKAT_SYMLINK_NOTSUP], [$LINKAT_SYMLINK_NOTSUP],
60482             [Define to 1 if linkat can create hardlinks to symlinks])
60484         would emit code with an empty RHS.
60486         * m4/linkat.m4 (gl_FUNC_LINKAT): Move the setting of
60487         $LINKAT_SYMLINK_NOTSUP out of the AC_CACHE_CHECK code block.
60489 2015-06-28  Jim Meyering  <meyering@fb.com>
60491         mountlist: avoid an unused-label warning on OS X
60492         * lib/mountlist.c (read_file_system_list) [MOUNTED_GETMNTINFO]:
60493         Building on OS X, I saw a warning about the "free_then_fail" label
60494         being unused.  Give it the _GL_UNUSED_LABEL attribute.
60496         error.c: correct printf-style format: %d -> %u
60497         * lib/error.c (error_at_line): Correct __fxprintf format to use %u,
60498         rather than %d, to match the type of "line_number", unsigned int.
60500 2015-06-25  Pádraig Brady  <P@draigBrady.com>
60502         fts: avoid reading beyond the heap allocation
60503         GCC 5.1.1 with -O2 and -fsanitize=address reports
60504         a read of size 4 from a heap object of size 3 is indeed invalid,
60505         though this may be due to incorrect padding assumptions by GCC, see:
60506         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66661
60507         * lib/fts.c (fts_alloc): Increase allocation to alignof(FTSENT).
60508         * modules/fts: Depend on stdalign.
60510 2015-06-24  Pádraig Brady  <P@draigBrady.com>
60512         savedir: avoid undefined behavior in qsort call
60513         GCC 5.1.1 -fsanitize=undefined with glibc 2.21 is returning:
60514         "runtime error: null pointer passed as argument 1,
60515          which is declared to never be null"
60516         * lib/savedir.c (streamsavedir): Avoid the call with no entries.
60518 2015-06-24  Pádraig Brady  <P@draigBrady.com>
60520         userspec: avoid undefined behavior in gettext call
60521         GCC 5.1.1 -fsanitize=undefined with glibc 2.21 is returning:
60522         "runtime error: null pointer passed as argument 2,
60523          which is declared to never be null"
60524         * lib/userspec.c (parse_with_separator): Avoid passing NULL to gettext()
60526 2015-06-20  Glenn Morris  <rgm@gnu.org>
60528         gitlog-to-changelog: improve gitmerge.el commits
60529         Let the Emacs ChangeLog generation process exclude "skipped"
60530         messages from merge commits (Bug#20717).
60531         * build-aux/gitlog-to-changelog: Handle gitmerge.el skipped commits.
60533 2015-06-20  Paul Eggert  <eggert@cs.ucla.edu>
60535         wchar: fix MinGW compilation warnings
60536         This lets Texinfo compile cleanly.  See Eli Zaretskii in:
60537         http://lists.gnu.org/r/bug-gnulib/2015-06/msg00050.html
60538         * lib/wchar.in.h: Do not use special invocation convention on MinGW.
60540 2015-06-20  Daiki Ueno  <ueno@gnu.org>
60542         uniname/uniname-tests: use pristine data files
60543         For copyright and maintenance reasons, use the data files from UCD
60544         without modification.
60545         * tests/uniname/test-uninames.c (FIELDLEN): Remove.
60546         (getfield): Remove.
60547         (aliases_count): New global variable.
60548         (fill_names): Skip comments and empty lines in the input.  Don't
60549         use getfield.
60550         (fill_aliases): Likewise.
60551         (main): Change the expected command line arguments to:
60552         NAMES... ["--" ALIASES...].
60553         * tests/uniname/test-uninames.sh: Adjust to the change in
60554         test-uninames.c.
60555         * tests/uniname/UnicodeDataNames.txt: Remove.
60556         * tests/uniname/UnicodeData.txt: New file, from Unicode 8.0.0.
60557         * tests/uniname/NameAliases.txt: Use the pristine copy of the data
60558         file from Unicode 8.0.0.
60560 2015-06-19  Pádraig Brady  <P@draigBrady.com>
60562         linked-list, linkedhash-list: avoid compiler warnings
60563         * lib/gl_anytree_list2.h: Add _GL_ATTRIBUTE_PURE to avoid
60564         -Werror=suggest-attribute=pure (from GCC 5.1.1).
60566 2015-06-19  Daiki Ueno  <ueno@gnu.org>
60568         libunistring: bump minimum version to 0.9.6
60569         * all modules depending on updated Unicode data: Regenerate.
60570         The modules are listed by a script that does:
60571         - for each file listed by: git show --oneline --name-only 705f4efc
60572           - deduce the containing modules, based on "Files:"
60573         - deduce the modules which depend on the containing modules, based
60574           on "Depends-on:"
60576 2015-06-18  Daiki Ueno  <ueno@gnu.org>
60578         uniname/uniname: update to Unicode 8.0.0
60579         * lib/uniname/uninames.h: Regenerate.
60580         * tests/uniname/NameAliases.txt: Update from Unicode 8.0.0.
60581         * tests/uniname/UnicodeDataNames.txt: Update from Unicode 8.0.0.
60583 2015-06-18  Daiki Ueno  <ueno@gnu.org>
60585         libunistring: update to Unicode 8.0.0
60586         * lib/gen-uni-tables.c (SIZEOF): New macro.
60587         (output_numeric): Increase the maximum number of fractions from
60588         128 to 160.  Increase the level3 value width from 7 bits to 8
60589         bits.  Use SIZEOF instead of a hard-coded integer.
60590         (output_blocks): Decrease the cut-off threshold from 0x30000 to
60591         0x28000.
60592         (fill_blocks): Increase the maximum number of blocks from 256 to
60593         384.  Use SIZEOF instead of a hard-coded integer.
60594         (get_lbp): Adjust to new characters added in Unicode 8.0.0.
60595         * lib/unictype/numeric.c (uc_numeric_value): Adjust the level3
60596         value width.
60597         * lib/unilbrk/lbrktables.c (unilbrk_table): Implement LBP21b and
60598         a new case added to LBP22.
60599         * lib/uniwidth/width.c (nonspacing_table_data): Add U+08E3,
60600         U+A69E, U+FE2E..U+FE2F, U+111CA..U+111CC, U+11300,
60601         U+115DC..U+115DD, U+1171D..U+1171F, U+11722..U+11725,
60602         U+11727..U+1172B, U+1DA00..U+1DA36, U+1DA3B..U+1DA6C, U+1DA75,
60603         U+1DA84, U+1DA9B..U+1DA9F, and U+1DAA1..U+1DAAF.
60604         * tests/uniwidth/test-uc_width2.sh: Same updates as in
60605         lib/uniwidth/width.c.
60606         * all generated files under lib/uni* and tests/uni*: Regenerate.
60608 2015-06-16  Pádraig Brady  <P@draigBrady.com>
60610         gnu-web-doc-update: add --mirror to remove stale files
60611         * build-aux/gnu-web-doc-update: Add a --mirror option to remove
60612         out of date files from the CVS server.  Since this is usually
60613         appropriate, a prompt is given when the option is not specified,
60614         along with the `cvs remove` command that would be run.
60616 2015-06-06  Paul Eggert  <eggert@cs.ucla.edu>
60618         acl-permissions: pacify -Wsuggest-attribute=const
60619         Problem reported by Masanari Iida in: http://bugs.gnu.org/20753
60620         * lib/acl-internal.h (free_permission_context):
60621         Declare with attribute const if ! (defined USE_ACL &&
60622         (HAVE_ACL_GET_FILE || defined GETACL)).
60624         fsync: document AIX misbehavior
60625         * doc/posix-functions/fsync.texi (fsync):
60626         Document failure on AIX with read-only file descriptor.
60628 2015-06-05  Jonathan Perkin  <jperkin@joyent.com>  (tiny change)
60630         stdio: Don't redefine gets when using C++
60631         * lib/stdio.in.h (gets): Disable warning on C++.
60633 2015-06-05  Paul Eggert  <eggert@cs.ucla.edu>
60635         acl-permissions: port to AIX, C89 HP-UX
60636         Problems reported by Michael Felt.
60637         * lib/file-has-acl.c (file_has_acl) [HAVE_STATACL]:
60638         * lib/get-permissions.c (get_permissions) [USE_ACL && HAVE_STATACL]:
60639         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]:
60640         * lib/set-permissions.c (set_acls) [HAVE_ACLX_GET && ACL_AIX_WIP]:
60641         Add cast for AIX, whose system calls are declared to accept
60642         char * even though the arguments are really char const *.
60643         * lib/get-permissions.c (get_permissions):
60644         If USE_ACL && HAVE_GETACL /* HP-UX */, don't assume C99.
60645         If USE_ACL && HAVE_STATACL /* older AIX */, add missing decl
60646         that broke a build.
60647         * lib/mountlist.c (read_file_system_list) [MOUNTED_VMOUNT]:
60648         Rework types to pacify xlc.
60650 2015-06-03  Pádraig Brady  <P@draigBrady.com>
60652         vasprintf-posix: avoid compiling vasnprintf where possible
60653         * modules/vasprintf-posix: Avoid compiling the large vasnprintf
60654         module where not required.  For example on a GNU/Linux system
60655         when gnulib-tool is run with the --conditional-dependencies option.
60657 2015-06-02  Pádraig Brady  <P@draigBrady.com>
60659         file-has-acl: fix build on Mac OS X 10
60660         This reverts commit f1b37e3a which doesn't work on Mac OS X >= 10.4
60661         which has an incompatible 6 parameter getxattr() call.
60662         * doc/glibc-functions/getxattr.texi: Mention the divergent getxattr()
60663         call on Mac OS X >= 10.4.
60664         * doc/glibc-functions/fgetxattr.texi: Likewise.
60665         * lib/file-has-acl.c: Revert to more complete combined check.
60666         * m4/acl.m4 (gl_FILE_HAS_ACL): Likewise.
60667         Reported by Jack Howarth.
60669 2015-06-02  Pádraig Brady  <P@draigBrady.com>
60671         prefix-gnulib-mk: remove no longer needed special case
60672         * build-aux/prefix-gnulib-mk (prefix): Since commit e3704b9c,
60673         continued lib_SOURCES lines are no longer present,
60674         so special case handling of such entries is not required.
60676 2015-06-01  Pádraig Brady  <P@draigBrady.com>
60678         acl: don't depend on the deprecated qacl module
60679         * modules/acl (Depends-on): Use q{copy,set}-acl instead.
60681 2015-06-01  Pádraig Brady  <P@draigBrady.com>
60683         gnulib-tool: concatenate lib_SOURCES to a single line
60684         * gnulib-tool: Refactor the line merging sed logic,
60685         and use that to output a single lib_SOURCES line for each module.
60686         gnulib using projects often postprocess this output to prepend
60687         subdir paths to each item, and having a single line simplifies this
60688         processing allowing better decoupling from the gnulib-tool output.
60690 2015-06-01  Pavel Fedin  <p.fedin@samsung.com>
60692         pthread_sigmask: discount system version if a simple macro (trivial)
60693         MinGW64 has: #define pthread_sigmask(H, S1, S2) 0
60694         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Call the
60695         function to ensure it's available.
60697 2015-05-31  Pádraig Brady  <P@draigBrady.com>
60699         readlinkat: avoid OS X 10.10 trailing slash bug
60700         * doc/posix-functions/readlink.texi: Mention that OS X 10.10
60701         has this bug.
60702         * doc/posix-functions/readlinkat.texi: Likewise.  Also mention
60703         that OS X 10.10 has this function.
60704         * lib/readlinkat.c (rpl_readlinkat): Handle the trailing slash bug,
60705         as done for readlink().
60706         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Check for the readlink()
60707         trailing slash bug, and assume readlinkat() has the same issue.
60708         Also fix a typo where $gl_cv_decl_readlink_works was tested,
60709         rather than the correct $gl_cv_decl_readlinkat_works.
60711 2015-05-29  Andreas Gruenbacher  <andreas.gruenbacher@gmail.com>
60713         acl-permissions: Fix build on Mac OS X and older AIX (Bug#20681)
60714         * lib/set-permissions.c (set_acls): Fix more errors introduced in the acl
60715         module rewrite.
60717         acl-permissions: Fix build on Solaris and Cygwin
60718         Reported by Tom G. Christensen <tgc@jupiterrise.com>:
60719         * lib/set-permissions.c (set_acls): The count, entries, ace_count, and
60720         ace_entries variables have moved into struct permission_context but
60721         they were still accessed as local variables here.
60723 2015-05-29  Pádraig Brady  <P@draigBrady.com>
60725         linkat: avoid OS X 10.10 trailing slash with symlink bug
60726         On Darwin 14.3.0 linkat(,"path1",,"dangling_symlink/",)
60727         causes the symlink to be dereferenced, and if it points
60728         to a non existent file, that file will be created as
60729         a hard link to "path1".
60730         This fixes a test failure in test-linkat.c.
60731         * m4/linkat.m4 (gl_FUNC_LINKAT): Augment the test with
60732         this case.  The existing workaround in linkat.c for
60733         trailing slash issues, suffices for this case.
60734         * doc/posix-functions/linkat.texi: Add OS X 10.10 to
60735         the list of platforms with trailing slash issues.
60737 2015-05-28  Pádraig Brady  <P@draigBrady.com>
60739         unlinkat: handle ignoring of ".." on Darwin 14
60740         * lib/unlinkat.c: unlinkat() has the same bug as unlink()
60741         on Mac OS X 10.10, where it ignores paths with a trailing "..",
60742         so handle in the same manner.
60743         * m4/unlinkat.m4: Comment on this Darwin issue.
60744         * doc/posix-functions/unlink.texi: Update the latest version
60745         where the issue was seen.
60746         * doc/posix-functions/unlinkat.texi: Mention this issue.
60747         Fixes a test failure in test-unlinkat.c.
60749 2015-05-27  Paul Eggert  <eggert@cs.ucla.edu>
60751         qacl: split into qcopy-acl and qset-acl
60752         Emacs needs the former, but not the latter.
60753         * modules/acl-permissions: New file, containing most of the old qacl.
60754         * modules/file-has-acl (Depends-on): Depend on acl-permissions, not qacl.
60755         * modules/qacl: Now merely depends on qcopy-acl and qset-acl.
60756         * modules/qcopy-acl, modules/qset-acl: New files.
60757         * MODULES.html.sh (File system functions):
60758         Mention the new modules, and mention qacl while we're at it.
60760 2015-05-27  Glenn Morris  <rgm@gnu.org>
60762         gitlog-to-changelog: new option --ignore-line
60763         (This patch is imported from the GNU Emacs master.)
60764         This option ignores individual commit lines matching a pattern.
60765         * build-aux/gitlog-to-changelog: Add --ignore-line option.
60767 2015-05-27  Andreas Gruenbacher  <agruenba@redhat.com>
60769         qacl: Reimplement qset_acl and qcopy_acl (Bug#20666)
60770         Implement get_permissions and set_permissions primitives for getting all
60771         the permissions of a file, storing them, and later setting them. (In the
60772         minimal case, the permissions consist only of a file mode.) Reimplement
60773         qset_acl and qcopy_acl based on these new primitives: this avoids code
60774         duplication and makes error handling more consistent.
60775         The Solaris and Cygwin code still uses duplicate code paths for setting
60776         a file mode while making sure that no acls exist and setting an explicit
60777         acl; this is no worse than before, but could be cleaned up.  The AIX
60778         code still doesn't read ACLs, it only makes sure that acls don't get in
60779         the way when setting a file mode.
60780         * lib/acl-internal.h (struct permission_context): New data structure.
60781         (get_permissions, set_permissions, free_permission_context): Declare.
60782         * lib/acl-internal.c (free_permission_context): New helper function.
60783         * lib/get-permissions.c (get_permissions): New helper function split off
60784         from qcopy_acl.
60785         * lib/set-permissions.c: (set_acls_from_mode): On Solaris, Cygwin, and
60786         AIX, set a file's permissions based only on a file mode.
60787         (acl_from_mode, context_acl_from_mode, context_aclv_from_mode): All
60788         other platforms construct a temporary acl from the file mode and set
60789         that acl in the same way as setting an acl read from the source file.
60790         This should help avoid code duplication and inconsistent / buggy
60791         behavior.
60792         (set_acls): New helper function Split off from qcopy_acl.
60793         (chmod_or_fchmod): Moved here from qset-acl.c.
60794         (set_permissions): New helper function.
60795         * lib/qcopy-acl.c (qcopy_acl): Rewrite using get_permissions and
60796         set_permissions.
60797         * lib/qset-acl.c (qset_acl): Rewrite using set_permissions.
60798         * modules/qacl: Add get-permissions.c and set-permissions.c.
60800         file-has-acl: Split feature tests again (Bug#20667)
60801         * lib/file-has-acl.c: Instead of testing for
60802         XATTR_NAME_POSIX_ACL_ACCESS and XATTR_NAME_POSIX_ACL_DEFAULT,
60803         define them when needed.
60804         * m4/acl.m4 (gl_FILE_HAS_ACL): With that, Paul's
60805         GETXATTR_WITH_POSIX_ACLS change shouldn't be needed anymore.
60807 2015-05-27  Pádraig Brady  <P@draigBrady.com>
60809         string: fix build failure on BSD/OSX with FORTIFY_SOURCE
60810         This avoids a conflict with "FORTIFY_SOURCE" variants
60811         of the string functions when they're replaced on NetBSD-6.0.1
60812         and Darwin-14.3.0 at least.
60813         * lib/string.in.h: Avoid including our "lib/string.h" while
60814         including the system <string.h>.
60816 2015-05-26  Eric Blake  <eblake@redhat.com>
60818         stdio: limit __gnu_printf__ witness to gcc 4.4+
60819         * lib/error.h (_GL_ATTRIBUTE_SPEC_PRINTF): Move gcc version probe...
60820         * m4/stdio_h.m4 (gl_STDIO_H): ...here.
60822         error: use correct printf attributes on mingw
60823         * lib/stdio.in.h (_GL_ATTRIBUTE_SPEC_PRINTF): New define.
60825         inttypes: force correct mingw PRIdMAX even without <stdio.h>
60826         * modules/inttypes (Depends-on): Require extensions, so that mingw
60827         always uses GNU style inttypes.
60828         * lib/inttypes.in.h: On mingw, include <stdio.h>.
60830         stdio: fix probe on mingw under gcc 5.1
60831         * m4/stdio_h.m4 (gl_STDIO_H): Change to compile test, to work
60832         around new gcc preprocessor rules.
60834 2015-05-07  Glenn Morris  <rgm@gnu.org>
60836         gitlog-to-changelog: parse "Tiny-change"
60837         * build-aux/gitlog-to-changelog: Treat "Tiny-change" like
60838         "Copyright-paperwork-exempt".  (Bug#20324)
60840 2015-05-06  Pádraig Brady  <P@draigBrady.com>
60842         doc: document glibc posix_fallocate() issues
60843         * doc/posix-functions/posix_fallocate.texi: Mention the
60844         glibc efficiency problems and issues with NFS.
60846 2015-05-05  Karl Berry  <karl@freefriends.org>
60848         * build-aux/gendocs.sh (usage): document new css default
60849         for HTML (--htmlarg).
60851 2015-04-29  Paul Eggert  <eggert@cs.ucla.edu>
60853         extern-inline: no need for workaround in GCC 5.1
60854         * doc/extern-inline.texi (extern inline):
60855         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
60856         GCC bugs 54113 and 63877 are fixed in GCC 5.1, so don't work
60857         around these bugs in GCC 5.1 and later.  Maybe in a decade or
60858         two we can remove these workarounds.
60860 2015-04-28  Pádraig Brady  <P@draigBrady.com>
60862         eealloc, pagealign_alloc, xalloc: avoid clang warnings
60863         Avoid [-Wunknown-attributes] warnings like:
60864         warning: unknown attribute '__alloc_size__' ignored
60865         * lib/xalloc.h: Don't use the __alloc_size__  attribute
60866         with clang, as support has been fully removed as of clang 3.5:
60867         https://github.com/llvm-mirror/clang/commit/c047507a
60868         * lib/eealloc.h: Likewise.
60869         * lib/pagealign_alloc.h: Likewise.
60871 2015-04-27  Paul Eggert  <eggert@cs.ucla.edu>
60873         tests: pacify GCC 5.1's stricter printf checking
60874         * tests/test-dirname.c (main):
60875         * tests/test-getaddrinfo.c (simple):
60876         * tests/test-getlogin.c (main):
60877         * tests/test-getndelim2.c (main):
60878         * tests/test-inttostr.c (CK):
60879         * tests/test-md5.c (main):
60880         * tests/test-read-file.c (main):
60881         * tests/test-sha1.c (main):
60882         Fix mismatches between printf format and value signedness.
60883         * tests/test-inttostr.c (FMT, CAST_VAL, V_min, V_max):
60884         Remove, as CAST_VAL always returned a value of type uintmax_t.
60886         fts: port to GCC 5.1 with --enable-gcc-warnings
60887         Without this fix, GCC 5.1 (correctly) warns about a subscript
60888         error on the fts_name component of FTSENT.  It's actually a
60889         flexible member, so define it that way on C99 or later hosts.
60890         * lib/fts.c (fts_alloc): Use offsetof, not sizeof, for a
60891         structure that now has a flexible array member.
60892         * lib/fts_.h (__FLEXIBLE_ARRAY_MEMBER): New macro.
60893         (FTSENT): fts_name is now flexible on C99-or-later platforms.
60894         * modules/fts (Depends-on): Add flexmember.
60896 2015-04-26  Paul Eggert  <eggert@cs.ucla.edu>
60898         file-has-acl: port to CentOS 6
60899         Problem reported by Tom G. Christensen in:
60900         http://lists.gnu.org/r/bug-gnulib/2015-04/msg00074.html
60901         * lib/file-has-acl.c: Use GETXATTR_WITH_POSIX_ACLS instead of a
60902         combination of HAVE_SYS_XATTR_H, HAVE_LINUX_XATTR_H, and
60903         HAVE_GETXATTR.
60904         * m4/acl.m4 (gl_FILE_HAS_ACL): Test fot the entire combination of
60905         linux/xattr.h, sys/xattr.h, getxattr, XATTR_NAME_POSIX_ACL_ACCESS,
60906         and XATTR_NAME_POSIX_ACL_DEFAULT, since that's what
60907         file-has-acl.c actually needs.
60909 2015-04-26  Pádraig Brady  <P@draigBrady.com>
60911         file-has-acl: always return false when ACLs aren't supported
60912         * lib/file-has-acl.c (file_has_acl): Consistent with other paths,
60913         change the GNU/Linux getxattr path, to transform "not supported"
60914         errors to a false return rather than an error.  This is handled
60915         within file_has_acl() due to the platform specific tests to
60916         determine if ACLs are not supported.
60918 2015-04-25  Paul Eggert  <eggert@cs.ucla.edu>
60920         gettext: propagate po/Makefile.in.in too
60921         * build-aux/po/Makefile.in.in: Copy from latest gettext.
60922         * config/srclist.txt: In build-aux/po, copy Makefile.in.in and
60923         remove-potcdate.sin from $GETTEXT.  This fixes a version mismatch
60924         between Makefile.in.in and the gettext-runtime m4 files.
60926 2015-04-24  Paul Eggert  <eggert@cs.ucla.edu>
60928         file-has-acl: new module, split from acl
60929         And add a new module file-has-acl-tests to match.
60930         I ran into a problem with the recent changes to the acl module,
60931         as they introduced a typo 'test use_xattrs = 0' into 'configure'.
60932         When using the fixed version with Emacs, I discovered that
60933         file-has-acl wasn't separated out well enough for Emacs (e.g., it
60934         had multiple libraries, but needed only one), so I fixed that too.
60935         * NEWS: Document this incompatible change.
60936         * modules/file-has-acl, modules/file-has-acl-tests: New files.
60937         * m4/acl.m4 (gl_FUNC_ACL_ARG): New macro, split from gl_FUNC_ACL.
60938         Initialize gl_need_lib_has_acl.
60939         (gl_FUNC_ACL): Require it.
60940         Simplify use of 'test'.  Set LIB_HAS_ACL if gl_need_lib_has_acl.
60941         Move the file-has-acl.c-relevant stuff to ...
60942         (gl_FILE_HAS_ACL): ... this new macro.  Rewrite to fix 'test
60943         use_xattrs = 0' typo, and omit some needless work.  Set
60944         gl_need_lib_has_acl=1 if we'll need LIB_HAS_ACL to be set
60945         when gl_FUNC_ACL is called.
60946         * modules/acl (Files, lib_SOURCES): Remove lib/file-has-acl.c.
60947         (Link): Remove $(LIB_HAS_ACL).
60948         * modules/acl-tests (Files, Depends-on, configure.ac, TESTS)
60949         (check_PROGRAMS): Move stuff relevant to file-has-acl to
60950         modules/file-has-acl-tests.
60951         (test_file_has_acl_LDADD): Move to modules/file-has-acl-tests.
60953         manywarnings: add GCC 5.1 warnings
60954         * build-aux/gcc-warning.spec: Add -Wabi=, -Warray-bounds,
60955         -Warray-bounds=, -Wc++14-compat, -Wc90-c99-compat,
60956         -Wc99-c11-compat, -Wshadow-ivar, -Wsized-deallocation,
60957         -Wsuggest-override, -Wuse-without-only.  Change
60958         -Wnormalized=... operands to match 5.1.
60959         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wbool-compare,
60960         -Wchkp, -Wdesignated-init, -Wdiscarded-array-qualifiers,
60961         -Wdiscarded-qualifiers, -Wformat-signedness,
60962         -Wincompatible-pointer-types, -Wint-conversion,
60963         -Wlogical-not-parentheses, -Wmemset-transposed-args, -Wodr,
60964         -Wshift-count-negative, -Wshift-count-overflow,
60965         -Wsizeof-array-argument, -Wsuggest-final-methods,
60966         -Wsuggest-final-types, -Wswitch-bool.  Remove -Warray-bounds,
60967         and add -Warray-bounds=2 as a special case.
60969 2015-04-21  Simon Josefsson  <simon@josefsson.org>
60971         doc: update FDL template to match FDL examples.
60972         * doc/alloca-opt.texi:
60973         * doc/alloca.texi:
60974         * doc/c-ctype.texi:
60975         * doc/c-strcase.texi:
60976         * doc/c-strcaseeq.texi:
60977         * doc/c-strcasestr.texi:
60978         * doc/c-strstr.texi:
60979         * doc/c-strtod.texi:
60980         * doc/c-strtold.texi:
60981         * doc/ctime.texi:
60982         * doc/error.texi:
60983         * doc/gcd.texi:
60984         * doc/gnulib-tool.texi:
60985         * doc/inet_ntoa.texi:
60986         * doc/intprops.texi:
60987         * doc/lib-symbol-visibility.texi:
60988         * doc/maintain.texi:
60989         * doc/parse-datetime.texi:
60990         * doc/quote.texi:
60991         * doc/regexprops-generic.texi:
60992         * doc/standards.texi: Remove spurious 'with' in FDL license
60993         template.
60995 2015-04-21  Paul Eggert  <eggert@cs.ucla.edu>
60997         lstat: fix cross-compilation 'ln -s' problem
60998         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK):
60999         Have the test program call 'symlink' rather than a separate
61000         script run 'ln -s'; this is more likely to work in
61001         cross-compilation environments.  Reported by Pavel Fedin in:
61002         http://lists.gnu.org/r/bug-gnulib/2015-04/msg00060.html
61004 2015-04-16  Ludovic Courtès  <ludo@gnu.org>
61006         gendocs.sh: default to a common CSS style sheet for HTML output
61007         * build-aux/gendocs.sh (htmlarg): Change default value.
61009 2015-04-15  Mats Erik Andersson  <gnu@gisladisker.se>
61011         gnulib-tool: output bold attribute more portably
61012         * gnulib-tool (func_show_module_list): Change hexadecimal
61013         numbers to octal in BOLD_ON and BOLD_OFF.  The use of hex
61014         encoded numbers as arguments to `printf' is not portable,
61015         and is not claimed by POSIX.  This is the case with FreeBSD.
61017 2015-04-15  Andreas Gruenbacher  <andreas.gruenbacher@gmail.com>
61019         qacl: Simplify HP-UX acl_nontrivial check
61020         * lib/acl-internal.c: Remove struct stat parameter from HP-UX's version of
61021         acl_nontrivial. Check if the acl has at most three entries instead (it must
61022         have exactly three entries according to the HP-UX documentation). Ignore
61023         uids and gids as long as an entry is either for a user (i.e., the owner),
61024         a group (i.e., the owning group), or others.
61025         * lib/acl-internal.h: Change HP-UX's acl_nontrivial prototype.
61026         * lib/qcopy-acl.c (qcopy_acl): With that, we no longer need to stat the file.
61028 2015-04-15  Andreas Gruenbacher   <andreas.gruenbacher@gmail.com>
61030         acl: On Linux, check for acls without libacl
61031         On Linux, use the getxattr syscall instead of the acl_extended_file libacl
61032         library function to check for the presence of acls, avoiding a library.
61033         * lib/file-has-acl.c: Include xattr headers if we have them.
61034         (file_has_acl): On Linux, use getxattr().
61035         * m4/acl.m4 (gl_FUNC_ACL): Define LIB_HAS_ACL as the libraries to link with for
61036         file_has_acl(). Check for xattr headers and getxattr().
61038 2015-04-14  Ángel González  <keisial@gmail.com>
61040         tempname: avoid unused parameter warnings (trivial)
61041         * lib/tempname.c (try_dir): Tag with __GL_UNUSED.
61042         (try_nocreate): Likewise.
61044 2015-04-14  HIRAMATSU Yoshifumi  <hiramatu@boreas.dti.ne.jp>
61046         fseeko: fix build failure on NetBSD >= 6 (trivial)
61047         * lib/fseeko.c (feeko): NetBSD 6 changed the definition of _offset
61048         from 'fpos_t struct' to __off_t, which is a typedef of __int64_t.
61050 2015-04-09  Paul Eggert  <eggert@cs.ucla.edu>
61052         gitlog-to-changelog: port to MS-Windows
61053         * build-aux/gitlog-to-changelog (git_dir_option):
61054         Use strftime with "%Y-%m-%d", not "%F", to avoid a bug in
61055         MS-Windows Perl.  Reported by Eli Zaretskii in:
61056         http://lists.gnu.org/r/emacs-devel/2015-04/msg00504.html
61058 2015-04-07  Karl Berry  <karl@gnu.org>
61060         gendocs: new option --tex for passing args to texi2dvi.
61061         * build-aux/gendocs.sh: new option --tex, default -t @finalout.
61062         (TEXI2DVI): cut to just command name.
61063         (usage): mention new option, and update copyright.
61064         <generate_tex>: use it.
61066 2015-04-07  Karl Berry  <karl@gnu.org>
61068         * config/srclistvars.sh (GETTEXT): new definition.
61069         * config/srclist.txt: use it for gettext .m4 files.
61070         Thread starting at http://lists.gnu.org/r/bug-gnulib/201
61071         and confirmed at http://lists.gnu.org/r/bug-gnulib/2015-02/msg00146.html
61072         and continuing into April.
61074 2015-04-07  Daiki Ueno  <ueno@gnu.org>
61076         uniname/uniname-tests: fix failure due to alias
61077         Reported by Jack Howarth in:
61078         <https://lists.gnu.org/r/bug-libunistring/2015-04/msg00000.html>.
61079         * tests/uniname/test-uninames.c (name_has_alias): New function.
61080         (test_inverse_lookup): Exclude character name with valid alias,
61081         from randomly generated character names.
61082         (main): Fill unicode_aliases before calling test functions.
61084 2015-04-03  Giuseppe Scrivano  <gscrivan@redhat.com>
61086         hash: remove deprecated hash_insert0 function
61087         * lib/hash.h (hash_insert0): Remove deprecated function.
61088         * lib/hash.c (hash_insert0): Likewise.
61090 2015-04-02  Pádraig Brady  <P@draigBrady.com>
61092         mountlist: remove dependency on libmount
61093         * lib/mountlist.c (read_file_system_list): Parse /proc/self/mountinfo
61094         directly, rather than depending on libmount, which has many
61095         dependencies due to its dependence on libselinux, as detailed at:
61096         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00063.html
61097         Note we restrict this to __linux__ as that's probably where this
61098         interface will remain.  If ever porting, it would be best
61099         to first pull the makedev() wrapper from coreutils to a gnulib module.
61100         Note also we don't add a getline dependency to the mountlist module,
61101         as all Linux versions are sufficient.
61103 2015-04-02  Paul Eggert  <eggert@cs.ucla.edu>
61105         stddef: port to pre-C11 GCC on x86
61106         On this platform, max_align_t should have an alignment of 8 even
61107         though the storage alignments of double, long, etc. max out at 4.
61108         Inspired by a comment of Andreas Schwab's here:
61109         https://sourceware.org/ml/libc-alpha/2015-04/msg00017.html
61110         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS) [!HAVE_MAX_ALIGN_T]: New macro.
61111         (max_align_t) [!HAVE_MAX_ALIGN_T]: Use it.
61112         * tests/test-stddef.c: Test __alignof__ too, if available.
61114 2015-03-24  Pádraig Brady  <P@draigBrady.com>
61116         quotearg-simple-tests: add missing gl_FUNC_MMAP_ANON dependency
61117         * modules/quotearg-simple-tests: Reference m4/mmap-anon.m4
61119 2015-03-24  Tobias Stoeckmann  <tobias@stoeckmann.org>
61121         yesno: make EOL optional in ENABLE_NLS case also (trival)
61122         * lib/yesno.c (yesno): Check for EOL before replacing.
61123         * tests/test-yesno.sh: Add a test case (test along with gettext).
61125 2015-03-22  Paul Eggert  <eggert@cs.ucla.edu>
61127         fdopendir-tests: test it does not close its arg
61128         * tests/test-fdopendir.c (main): Test that fdopendir does not
61129         close its argument.  From a suggestion by David Grayson in:
61130         http://lists.gnu.org/r/bug-gnulib/2015-03/msg00039.html
61132 2015-03-20  Paul Eggert  <eggert@cs.ucla.edu>
61134         gitlog-to-changelog: trim trailing white space
61135         * build-aux/gitlog-to-changelog (main):
61136         Trim trailing white space from commit message lines.
61137         This is helpful for processing the GNU Emacs repository,
61138         which dates back to 1985 and contains a lot of such lines.
61140         gitlog-to-changelog: new option --ignore-matching
61141         * build-aux/gitlog-to-changelog (usage, git_dir_option, main):
61142         Support new option --ignore-matching=PAT, which ignores all
61143         commit messages whose first line matches PAT.
61145 2015-03-19  Paul Eggert  <eggert@cs.ucla.edu>
61147         fdopendir: port better to MinGW
61148         * lib/fdopendir.c (fd_clone_opendir) [REPLACE_FCHDIR]:
61149         Use 'dup' if dirfd fails.  Suggested by Eli Zaretskii in:
61150         http://lists.gnu.org/r/bug-gnulib/2015-03/msg00033.html
61151         * modules/fdopendir (Depends-on): Add dirfd.
61153 2015-03-18  Paul Eggert  <eggert@cs.ucla.edu>
61155         fdopendir: fix typo in comment
61156         * lib/fdopendir.c (fdopendir_with_dup): REPLACE_FCHDIR was misspelled.
61158 2015-03-09  Eric Blake  <eblake@redhat.com>
61160         error: document all entry points provided
61161         * doc/glibc-functions/error_print_progname.texi
61162         (error_print_progname): Mention the error module.
61163         * doc/glibc-functions/error_at_line.texi (error_at_line):
61164         Likewise.
61165         * doc/glibc-functions/error_message_count.texi
61166         (error_message_count): Likewise.
61167         * doc/glibc-functions/error_one_per_line.texi
61168         (error_one_per_line): Likewise.
61170 2015-03-03  Paul Eggert  <eggert@cs.ucla.edu>
61172         vasnprintf: pacify clang 3.5.0
61173         Problem reported by Werner Lemberg in:
61174         http://lists.gnu.org/r/bug-gnulib/2015-03/msg00000.html
61175         * lib/vasnprintf.c (VASNPRINTF): Omit casts that clang objects to.
61176         The casts aren't needed, since the characters in question are ASCII.
61178 2015-02-24  Paul Eggert  <eggert@cs.ucla.edu>
61180         glob, etc.: port to MSVC v18 on MS-Windows 8.1
61181         * lib/dirent--.h (GNULIB_defined_opendir):
61182         * lib/dirent.in.h (GNULIB_defined_opendir)
61183         (GNULIB_defined_closedir):
61184         * lib/getcwd.c, lib/glob.c, lib/mountlist.c (opendir, closedir):
61185         #undef only if Gnulib defined it.
61187         poll: port to MSVC v18 on MS-Windows 8.1
61188         Problem reported by Gisle Vanem in:
61189         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00139.html
61190         * lib/poll.c: Always include <sys/select.h> and <sys/socket.h>.
61191         * modules/poll (Depends-on) [!HAVE_POLL || REPLACE_POLL]:
61192         Add sys_socket.
61194 2015-02-24  Pádraig Brady  <P@draigBrady.com>
61196         tests: support stderr verification with returns_()
61197         * tests/init.sh (returns_): Disable tracing for this wrapper
61198         function, so that stderr of the wrapped command is unchanged,
61199         allowing for verification of the contents.
61201 2015-02-24  Pavel Hrdina  <phrdina@redhat.com>
61203         passfd: avoid valgrind uninitalised data warning
61204         * lib/passfd.c (sendfd): Reset the msg_controllen of msghdr,
61205         to include just the fd we've initialized, rather than including
61206         the extra space used for alignment.
61208 2015-02-23  Paul Eggert  <eggert@cs.ucla.edu>
61210         uniwbrk/u32-wordbreaks-tests: fix copyright
61211         * tests/uniwbrk/test-uc-wordbreaks.c: Fix copyright date.
61213         dup2: doc and test for Android bug
61214         Reported by Kevin Cernekee in:
61215         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00125.html
61216         * doc/posix-functions/dup2.texi (dup2): Document the bug.
61217         * m4/dup2.m4 (gl_FUNC_DUP2): Test for the bug.
61219 2015-02-23  Kevin Cernekee  <cernekee@google.com>
61221         Replace dup2() on Android
61222         * m4/dup2.m4 (gl_FUNC_DUP2): Android implements dup2() using dup3().
61223         Since dup3(fd, fd) fails but dup2(fd, fd) should pass, test-dup2
61224         fails.  Using rpl_dup2() fixes this because it has an explicit test
61225         for this condition.
61227 2015-02-22  Paul Eggert  <eggert@cs.ucla.edu>
61229         Android doesn't define RLIM_SAVED_*
61230         Portability problem reported by Kevin Cernekee in:
61231         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00122.html
61232         * doc/posix-headers/sys_resource.texi (sys/resource.h):
61233         Mention the portability problem.
61234         * lib/getdtablesize.c (RLIM_SAVED_CUR, RLIM_SAVED_MAX):
61235         Define if not defined.
61236         * m4/dup2.m4 (gl_FUNC_DUP2):
61237         * m4/fcntl.m4 (gl_FUNC_FCNTL):
61238         Likewise.
61240 2015-02-21  Paul Eggert  <eggert@cs.ucla.edu>
61242         vasnprintf-posix-tests: use consistent test
61243         * tests/test-vasnprintf-posix.c (test_function):
61244         Use "<" in assert instead of "<=", for consistency with other tests.
61246 2015-02-20  Paul Eggert  <eggert@cs.ucla.edu>
61248         printf, isinf, etc.: noncanonical != NaN
61249         Do not require that isinf, printf, etc. treat noncanonical
61250         values as NaNs.  Instead, require only that they do not crash.
61251         Problem reported by Joseph Myers in:
61252         https://sourceware.org/ml/libc-alpha/2015-02/msg00244.html
61253         * doc/posix-functions/dprintf.texi (dprintf):
61254         * doc/posix-functions/fprintf.texi (fprintf):
61255         * doc/posix-functions/isfinite.texi (isfinite):
61256         * doc/posix-functions/isinf.texi (isinf):
61257         * doc/posix-functions/isnan.texi (isnan):
61258         * doc/posix-functions/printf.texi (printf):
61259         * doc/posix-functions/snprintf.texi (snprintf):
61260         * doc/posix-functions/sprintf.texi (sprintf):
61261         * doc/posix-functions/vdprintf.texi (vdprintf):
61262         * doc/posix-functions/vfprintf.texi (vfprintf):
61263         * doc/posix-functions/vprintf.texi (vprintf):
61264         * doc/posix-functions/vsnprintf.texi (vsnprintf):
61265         * doc/posix-functions/vsprintf.texi (vsprintf):
61266         Document this.
61267         * m4/isfinite.m4 (gl_ISFINITEL_WORKS):
61268         * m4/isinf.m4 (gl_ISINFL_WORKS):
61269         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS):
61270         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE):
61271         * tests/test-isfinite.c (test_isfinitel):
61272         * tests/test-isinf.c (test_isinfl):
61273         * tests/test-isnan.c (test_long_double):
61274         * tests/test-isnanl.h (main):
61275         * tests/test-snprintf-posix.h (test_function):
61276         * tests/test-sprintf-posix.h (test_function):
61277         * tests/test-vasnprintf-posix.c (test_function):
61278         * tests/test-vasprintf-posix.c (test_function):
61279         Test only that noncanonical values do not cause crashes, not that
61280         they are treated as NaNs.  In some cases this means a larger
61281         output buffer is needed.
61283 2015-02-20  Jaroslav Skarvada  <jskarvad@redhat.com>
61285         fts: remove redundant close() (trivial)
61286         * lib/fts.c (fts_read): Remove redundant call to close().
61287         Spotted by coverity.
61289 2015-02-20  Paul Eggert  <eggert@cs.ucla.edu>
61291         getdtablesize: port better for Android
61292         Problem reported by Kevin Cernekee in:
61293         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00112.html
61294         * doc/glibc-functions/getdtablesize.texi (getdtablesize): Mention bug.
61295         * lib/getdtablesize.c (getdtablesize): Don't fall back on _SC_OPEN_MAX.
61296         Instead, just use getrlimit, taking care to avoid Cygwin bug.
61298         poll: fixes for large fds
61299         * lib/poll.c (poll): Don't check directly for NFD too large.
61300         Don't rely on undefined behavior in FD_SET when an arg exceeds
61301         FD_SETSIZE.  Always set revents afterwards, even if to zero.
61302         * tests/test-poll.c (poll1): Set revents to -1 instead of 0,
61303         as that makes the test a bit stricter.
61305 2015-02-19  Kevin Cernekee  <cernekee@google.com>
61307         fcntl: Fix cross compiling
61308         * m4/fcntl.m4 (gl_FUNC_FCNTL): Assign the guessed result to the
61309         correct variable name (gl_cv_func_fcntl_f_dupfd_works).
61311 2015-02-18  Paul Eggert  <eggert@cs.ucla.edu>
61313         dup2, fcntl: cross-compile better for Android
61314         Problem reported by Kevin Cernekee in:
61315         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00109.html
61316         * m4/dup2.m4 (gl_FUNC_DUP2): Don't guess no when cross-compiling
61317         for a Linux kernel.  That kernel bug was fixed on 2009-05-11, and
61318         there's little need to cross-compile for older kernels nowadays.
61319         * m4/fcntl.m4 (gl_FUNC_FCNTL): When cross-compiling, guess no only
61320         for systems where the bug is known to occur (AIX, Cygwin, Haiku).
61322 2015-02-18  Pádraig Brady  <P@draigBrady.com>
61324         getopt: don't crash on memory exhaustion
61325         * lib/getopt.c (_getopt_internal_r): Use degraded diagnostics on
61326         memory exhaustion.  In the _LIBC case we use alloca() as is
61327         already done in glibc, so we don't need to consider the separate
61328         error path in that awkward case.  Also fix a memory leak when
61329         ambiguous options are present.
61330         Reported by Tobias Stoeckmann
61332 2015-02-17  Mike Miller  <mtmiller@ieee.org>
61334         tempname: allow compilation with C++ (trivial)
61335         * lib/tempname.h [C++]: Specify extern "C" linkage.
61336         * lib/tempname.h (try_tempname):
61337         * lib/tempname.c (__try_tempname, __gen_tempname):
61338         Rename 'try' to 'tryfunc'.
61340 2015-02-17  Paul Eggert  <eggert@cs.ucla.edu>
61342         dup2, fcntl: port to AIX
61343         * m4/dup2.m4 (gl_FUNC_DUP2):
61344         * m4/fcntl.m4 (gl_FUNC_FCNTL):
61345         Prefer getrusage (RLIM_NOFILE ...)/rlim_cur to sysconf (_SC_OPEN_MAX).
61346         The former works on AIX 7.1 but the latter does not.
61347         Also, this may work better with Android; see:
61348         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00100.html
61350 2015-02-16  Paul Eggert  <eggert@cs.ucla.edu>
61352         getdtablesize, dup2, fcntl: port to Android
61353         Problem reported by Kevin Cernekee in:
61354         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00092.html
61355         * doc/glibc-functions/getdtablesize.texi (getdtablesize):
61356         Mention that getdtablesize doesn't work on Android.
61357         * lib/getdtablesize.c: Use getrlimit substitute only if
61358         getdtablesize is declared.  This should suffice for Cygwin
61359         while not breaking Android.
61360         * m4/dup2.m4 (gl_FUNC_DUP2):
61361         * m4/fcntl.m4 (gl_FUNC_FCNTL):
61362         Prefer sysconf (_SC_OPEN_MAX) to getdtablesize, as the former is
61363         standardized but the latter is not, and sysconf works on Android.
61364         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE):
61365         Also check that getdtablesize is declared.
61366         This removes the need for a special case for Android.
61368 2015-02-16  Kevin Cernekee  <cernekee@google.com>
61370         localename: Implement gl_locale_name_thread_unsafe for Android
61371         * lib/localename.c: Android API level >= 21 supports two hardcoded
61372         locales: C (POSIX) and C.UTF-8.  Distinguish them by checking
61373         the internal __locale_t struct.
61375 2015-02-16  Kamil Dudka  <kdudka@redhat.com>
61377         fts: avoid crash when a cycle is added while traversing
61378         This could be triggered by auto-mounting a recursive bind mount.
61379         Reported by Michael Chapman in: https://bugzilla.redhat.com/1188498
61380         * lib/fts.c (fts_read): Avoid removing the original hash table item
61381         when leaving a directory that caused a cycle, and preserve the FTS_DC
61382         flag.
61384 2015-02-16  Daiki Ueno  <ueno@gnu.org>
61386         uniname/uniname: support character alias
61387         * lib/uniname/gen-uninames.lisp (main): New argument ALIASFILE.
61388         Generate one-way mapping from aliases to codepoints in the
61389         generated tables.  Special case variation selectors to reduce
61390         table size.
61391         * lib/uniname/uniname.c (unicode_character_name): Special case
61392         variation selectors.
61393         (unicode_name_character): Special case variation selectors and
61394         their aliases.
61395         * lib/uniname/uninames.h: Regenerate.
61396         * tests/uniname/NameAliases.txt: New file, taken from UCD 7.0.0.
61397         * modules/uniname/uniname-tests (Files): Add
61398         tests/uniname/NameAliases.txt.
61399         * tests/uniname/test-uninames.c: Mark as static.
61400         (ALIASLEN): Define.
61401         (struct unicode_alias): New struct.
61402         (unicode_aliases): New variable.
61403         (fill_aliases): New function.
61404         (test_alias_lookup): New test function.
61405         (main): Run the 'test_alias_lookup' test if the second argument is
61406         given.
61407         * tests/uniname/test-uninames.sh: Supply NameAliases.txt as the
61408         second argument.
61410 2015-02-11  Kevin Cernekee  <cernekee@google.com>
61412         Fix FILE struct compatibility with Android API level >= 21
61413         * lib/stdio-impl.h: Test explicitly for __ANDROID__ instead of
61414         __sferror.  Recent versions of Bionic's stdio.h no longer define
61415         __sferror.
61416         * lib/fbufmode.c: Likewise.
61417         * lib/fflush.c: Likewise.
61418         * lib/fpurge.c: Likewise.
61419         * lib/freadable.c: Likewise.
61420         * lib/freadahead.c: Likewise.
61421         * lib/freading.c: Likewise.
61422         * lib/freadptr.c: Likewise.
61423         * lib/freadseek.c: Likewise.
61424         * lib/fseeko.c: Likewise.
61425         * lib/fseterr.c: Likewise.
61426         * lib/fwritable.c: Likewise.
61428         Assume unbroken ungetc() on Android
61429         * m4/ungetc.m4: Add Android case to host OS check.  The ungetc()
61430         test case passed when running on an Android host, and the code
61431         hasn't really changed since 2009.
61433         getdtablesize: Fix Android build
61434         * m4/getdtablesize.m4: Add Android case to host OS check.  Recent NDK
61435         versions have this symbol in the .so library (at least 32-bit
61436         platforms) but are missing the declaration in the header file,
61437         causing the m4 logic to guess incorrectly.
61439         localename: Fix Android build
61440         * modules/localename (Depends-on): Add langinfo.
61442         getugroups: Fix Android build
61443         * lib/getugroups.c: Don't reference unsupported {get,set,end}grent
61444         functions.
61446         euidaccess: Fix Android build
61447         * modules/euidaccess (Depends-on): Add fcntl-h to ensure that
61448         AT_EACCESS gets declared.
61450         linkat_nofollow: Add fallback case for cross compiling
61451         * m4/linkat.m4: Guess no for Darwin, yes otherwise.
61453         net_if: Handle content-free <net/if.h> system headers
61454         * m4/net_if_h.m4: Check to make sure <net/if.h> actually defines
61455         struct if_nameindex.  If not, enable the replacement header.
61457         signal_h: Fix Android build
61458         * lib/signal.in.h: Add Android to the list of platforms that declare
61459         pthread_sigmask() in <pthread.h> instead of <signal.h>.
61461         duplocale: Fix Android build of duplocale-tests
61462         * modules/duplocale-tests (Depends-on): Add langinfo, as the header
61463         is included by test-duplocale.c (but not by duplocale.c).
61464         * modules/duplocale-tests (configure.ac): Check for monetary.h.
61465         * tests/test-duplocale.c: Skip test if monetary.h is absent.
61466         * doc/posix-headers/monetary.texi: Add Android to the list of
61467         platforms missing monetary.h.
61469 2015-02-11  Pádraig Brady  <P@draigBrady.com>
61471         tests: avoid recent -Werror=unused-variable regression in test-locale
61472         * tests/test-locale.c (main): Reference the variable to avoid the
61473         "unused variable" warning.
61475 2015-02-11  Pádraig Brady  <P@draigBrady.com>
61477         maint: various whitespace cleanups in tempname
61478         * lib/tempname.c: Normalize spacing and line length.
61479         * lib/tempname.h: Likewise.
61480         * modules/tempname: Likewise.
61482 2015-02-11  Pádraig Brady  <P@draigBrady.com>
61484         tests: provide returns_() to simplify exit status checking
61485         * tests/init.sh (returns_): A new function for use in tests,
61486         to allow for easier checking of return values, where you expect
61487         a command to exit with failure status.  By checking for a particular
61488         exit code, you don't hide any crashes for example.
61490 2015-02-11  Pádraig Brady  <P@draigBrady.com>
61492         mountlist: only use libmount when specified
61493         There are currently many shared libs dependencies introduced by
61494         libmount with associated runtime and virt mem overhead.
61495         Therefore don't enable by default.
61496         * m4/ls-mntd-fs.m4: Use --with-libmount to enable at build time.
61498 2015-02-08  Daiki Ueno  <ueno@gnu.org>
61500         uniname/unimame-tests: don't link with -lunistring
61501         * modules/uniname/uniname-tests (Makefile.am): Don't link against
61502         $(LIBUNISTRING).  Document the rationale why we need to
61503         conditionalize the test.
61505 2015-02-07  Paul Eggert  <eggert@cs.ucla.edu>
61507         fstrcmp: don't assume strlen < INT_MAX
61508         * lib/fstrcmp.c: Include stddef.h and stdint.h.
61509         (uintptr_t): Remove, as we're now assuming stdint.
61510         (OFFSET, EXTRA_CONTEXT_FIELDS, fstrcmp_bounded):
61511         Prefer ptrdiff_t to int when the value could exceed INT_MAX
61512         if the input string is long.
61513         (fstrcmp_bounded): Check for size-calculation overflow.  Prefer
61514         uintptr_t to size_t when the underlying value is a pointer casted
61515         to an unsigned integer.  Avoid unnecessary 'buffer != NULL' test.
61516         * modules/fstrcmp (Depends-on): Add stdint.
61518         diffseq: prefer ptrdiff_t to ssize_t
61519         * lib/diffseq.h: In commentary, prefer ptrdiff_t to ssize_t.
61520         ptrdiff_t is the natural type for signed indexes.
61521         On a few older platforms, ssize_t is narrower than size_t.
61523         xalloc: fix typo that suppressed warnings
61524         * lib/xalloc.h: Add missing _GL_INLINE_HEADER_END.
61525         This typo, introduced a couple of years ago, mistakenly suppressed
61526         some -Wsuggest-attribute=const, -Wmissing-prototypes, and
61527         -Wmissing-declarations warnings.
61529         full-read: fix license notice typo
61530         * lib/full-read.h: Remove a stray line in the license notice.
61531         Reported by Sam Ellis in: http://bugs.gnu.org/19808
61533         crypto/gc: fix a -Wswitch warning
61534         Reported by Bruce Korb in:
61535         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00046.html
61536         * lib/gc-gnulib.c (gc_hash_open): Fail faster if MODE is nonzero.
61538 2015-02-03  Pádraig Brady  <P@draigBrady.com>
61540         gnulib-tool: fix handling of patch(1) diagnostics
61541         * gnulib-tool: Send diagnostics from patch(1) to stderr,
61542         as otherwise gnulib-tool will reparse that output and attempt
61543         to lookup modules.
61545 2015-02-03  Pádraig Brady  <P@draigBrady.com>
61547         bootstrap: exit immediately upon gnulib-tool failure
61548         * build-aux/bootstrap: Exit immediately if gnulib-tool fails.
61549         This was noticed when gnulib-tool exited early due to failure
61550         to apply a patch in coreutils at http://hydra.nixos.org/eval/1172233,
61551         but various confusing errors were then given as the build proceeded.
61553 2015-02-02  Andreas Gruenbacher  <agruen@gnu.org>
61555         symlinkat: include all required header files
61556         * lib/symlinkat.c (HAVE_SYMLINK_AT): Add <sys/stat.h> for fstatat(),
61557         and string.h for strlen(), required at least on OS X 10.10 (Yosemite).
61558         Reported at https://savannah.gnu.org/bugs/index.php?44151
61559         and by Jack Howarth.
61561 2015-01-29  Pádraig Brady  <P@draigBrady.com>
61563         localename: support Solaris 12 and illumos
61564         * lib/localename.c (gl_locale_name_thread_unsafe): call
61565         getlocalename_l() on newer __sun platforms.
61566         Reported by Alexander Pyhalov.
61567         Fix suggested by Rich Burridge.
61569 2015-01-29  Alexander Pyhalov  <alp@rsu.ru>
61571         locale: fix tests on illumos (trivial)
61572         * tests/test-locale.c: LC_GLOBAL_LOCALE is a function call on illumos,
61573         so move from global scope to main().
61575 2015-01-24  Daiki Ueno  <ueno@gnu.org>
61577         unictype: avoid undefined left-shift behavior
61578         * lib/unictype/bidi_of.c (uc_bidi_class): Building libunistring with
61579         gcc's -fsanitize=shift and running its tests triggered:
61580           unictype/bidi_of.c:43:60: runtime error: left shift of 40167 by 16 \
61581             places cannot be represented in type 'int'
61582         Cast LHS to 'unsigned int' after integer promotion.
61583         * lib/unictype/categ_of.c (lookup_withtable): Likewise.
61584         * lib/unictype/joininggroup_of.c (uc_joining_group): Likewise.
61586 2015-01-20  Daiki Ueno  <ueno@gnu.org>
61588         libunistring: bump version of unitypes dependants
61589         Due to the header file search order, all the headers which depend
61590         on unitypes.h need to be generated, when the preinstalled
61591         libunistring is older.
61592         * modules/unicase/base (configure.ac): Bump minimum version to
61593         0.9.4.
61594         * modules/uniconv/base (configure.ac): Likewise.
61595         * modules/unilbrk/base (configure.ac): Likewise.
61596         * modules/uninorm/base (configure.ac): Likewise.
61597         * modules/unistdio/base (configure.ac): Likewise.
61598         * modules/unistr/base (configure.ac): Likewise.
61599         * modules/uniwbrk/base (configure.ac): Likewise.
61600         * modules/uniwidth/base (configure.ac): Likewise.
61602 2015-01-20  Daiki Ueno  <ueno@gnu.org>
61604         unictype/category-none: fix link with libunistring
61605         Since _UC_CATEGORY_NONE is not a public symbol, it will be
61606         prefixed with "libstring_" when compiled as part of libunistring.
61607         To avoid undefined symbol at link time, increase the minimum
61608         version when the dependant modules are updated.
61609         * modules/unictype/category-none (configure.ac): Bump minimum
61610         version to 0.9.5.
61612 2015-01-20  Daiki Ueno  <ueno@gnu.org>
61614         unitypes: fix build with installed libunistring
61615         The minimum version has not bumped after _UC_ATTRIBUTE_CONST and
61616         _UC_ATTRIBUTE_PURE were added to unitypes.in.h.
61617         * modules/unitypes (configure.ac): Bump minimum version to 0.9.4.
61619 2015-01-15  Paul Eggert  <eggert@cs.ucla.edu>
61621         time: port to MinGW32 3.21
61622         Problem reported by Eli Zaretskii in:
61623         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00042.html
61624         * lib/time.in.h:
61625         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC):
61626         * modules/time (Depends-on):
61627         Fall back on unistd.h if the other include files don't define
61628         struct timespec.
61630         update-copyright: apply to self
61631         * build-aux/update-copyright: Fix copyright date.  How ironic!
61633 2015-01-15  Daiki Ueno  <ueno@gnu.org>
61635         libunistring: update to Unicode 7.0.0
61636         * lib/unictype/joininggroup_byname.gperf: Add Straight Waw and
61637         Manichaean names.
61638         * lib/unictype/joininggroup_name.h: Likewise.
61639         * lib/unictype.in.h (UC_JOINING_GROUP_STRAIGHT_WAW)
61640         (UC_JOINING_GROUP_MANICHAEAN_ALEPH): New enumeration values.
61641         * lib/gen-uni-tables.c (UC_JOINING_GROUP_STRAIGHT_WAW)
61642         (UC_JOINING_GROUP_MANICHAEAN_*): New enumeration values.
61643         (fill_arabicshaping, joining_group_as_c_identifier): Support those
61644         enum values.
61645         (is_property_alphabetic): Accept newly added characters to
61646         cuneiform numeric signs.
61647         (is_property_default_ignorable_code_point): Reject U+0605.
61648         (FIELDLEN): Increase from 120 to 160.
61649         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0605,
61650         U+08FF, U+0C00, U+0C81, U+0D01, U+1AB0..U+1ABE, U+1BAC..U+1BAD,
61651         U+1CF8..U+1CF9, U+1DE7..U+1DF5, U+A9E5, U+AA7C, U+FE27..U+FE2D,
61652         U+102E0, U+10376..U+1037A, U+10AE5..U+10AE6, U+1107F, U+11173,
61653         U+1122F..U+11231, U+11234, U+11236..U+11237, U+112DF,
61654         U+112E3..U+112EA, U+11301, U+1133C, U+11340, U+11366..U+1136C,
61655         U+11370..U+11374, U+114B3..U+114B8, U+114BA, U+114BF..U+114C0,
61656         U+114C2..U+114C3, U+115B2..U+115B5, U+115BC..U+115C0,
61657         U+11633..U+1163A, U+1163D, U+1163F..U+11640, U+16AF0..U+16AF4,
61658         U+16B30..U+16B36, U+1BC9D..U+1BC9E, U+1BCA0..U+1BCA3, and
61659         U+1E8D0..U+1E8D6.
61660         (uc_width): Adjust nonspacing_table_ind boundary from 240 to 248.
61661         * tests/uniwidth/test-uc_width2.sh: Same updates as in
61662         lib/uniwidth/width.c.
61663         * all generated files under lib/uni* and tests/uni*: Regenerate.
61665 2015-01-14  Daiki Ueno  <ueno@gnu.org>
61667         libunistring: update to Unicode 6.3.0
61668         * lib/uniwbrk.in.h (WBP_DQ, WBP_SQ, WBP_HL): New enumeration values.
61669         * lib/uniwbrk/u-wordbreaks.h (FUNC): Support WB7a, WB7b, and WB7c.
61670         Update WB5, WB6, WB7, WB9, WB11, WB12, WB13a, and WB13b.
61671         * lib/uniwbrk/wbrktable.h (uniwbrk_table): Adjust table size.
61672         * lib/uniwbrk/wbrktable.c (uniwbrk_table): Support rule WB7a.
61673         Update WB5, WB9, WB10, WB13a, and WB13b.
61674         * tests/uniwbrk/test-uc-wordbreaks.c
61675         (wordbreakproperty_to_string): Support WBP_DQ, WBP_SQ, and WBP_HL.
61676         * lib/gen-uni-tables.c (UC_BIDI_LRI, UC_BIDI_RLI, UC_BIDI_FSI)
61677         (UC_BIDI_PDI): New enumeration values.
61678         (bidi_category_byname): Support those enum values.
61679         (is_WBP_MIDNUMLET): Exclude 0x0027 (SINGLE QUOTE), which is now a
61680         dedicated property assigned.
61681         (is_property_case_ignorable): Check 0x0027.
61682         (WBP_DQ, WBP_SQ, WBP_HL): New enumeration values.
61683         (get_wbp, debug_output_wbp, fill_org_wbp, debug_output_org_wbp)
61684         (output_wbp): Support those enum values.
61685         * lib/unictype.in.h (UC_BIDI_LRI, UC_BIDI_RLI, UC_BIDI_FSI)
61686         (UC_BIDI_PDI): New enumeration values.
61687         * lib/unictype/bidi_byname.gperf: Add those property names.
61688         * lib/uniwidth/width.c (nonspacing_table_data): Add U+061C,
61689         U+180E, U+1A1B, and U+2066..U+2069.
61690         * tests/uniwidth/test-uc_width2.sh: Same updates as in
61691         lib/uniwidth/width.c.
61692         * all generated files under lib/uni* and tests/uni*: Regenerate.
61694 2015-01-14  Daiki Ueno  <ueno@gnu.org>
61696         libunistring: update to Unicode 6.2.0
61697         * lib/unilbrk/lbrktables.h (LBP_RI): New enumeration value.
61698         (unilbrk_table): Adjust table size.
61699         * lib/unilbrk/lbrktables.c (unilbrk_table): Add a row and column
61700         for LBP_RI.
61701         * lib/uniwbrk.in.h (WBP_RI): New enumeration value.
61702         * lib/uniwbrk/u-wordbreaks.h (FUNC): Support rule WB13c.
61703         Normalize table index skipping ignored properties.
61704         * lib/uniwbrk/wbrktable.c (uniwbrk_table): Support WBP_RI.  Remove
61705         WBP_EXTEND and WBP_FORMAT, which are now computed without using
61706         the table.
61707         * lib/uniwbrk/wbrktable.h: Adjust table size.
61708         * lib/unigbrk.in.h (GBP_RI): New enumeration value.
61709         * lib/unigbrk/uc-is-grapheme-break.c (UC_IS_GRAPHEME_BREAK):
61710         Support rule GB8a.
61711         (UC_GRAPHEME_BREAKS_FOR, gb_table): Support GBP_RI.
61712         * tests/unigbrk/test-uc-is-grapheme-break.c
61713         (graphemebreakproperty_to_string): Support GBP_RI.
61714         * tests/uniwbrk/test-uc-wordbreaks.c
61715         (wordbreakproperty_to_string): Support WBP_RI.
61716         * lib/gen-uni-tables.c (LBP_RI): New enumeration value.
61717         (get_lbp, debug_output_lbp, fill_org_lbp, debug_output_org_lbp)
61718         (output_lbp): Support LBP_RI.  Adjust some characters changed from
61719         LBP_AL to LBP_ID.
61720         (output_lbp): Support LBP_RI.
61721         (WBP_RI): New enumeration value.
61722         (debug_output_wbp, fill_org_wbp, debug_output_org_wbp)
61723         (output_wbp): Support WBP_RI.
61724         (GBP_RI): New enumeration value.
61725         (output_gbp_test, fill_org_gbp): Support GBP_RI.
61726         * all generated files under lib/uni* and tests/uni*: Regenerate.
61728 2015-01-14  Daiki Ueno  <ueno@gnu.org>
61730         libunistring: update to Unicode 6.1.0
61731         * lib/gen-uni-tables.c (output_joining_group): Switch to
61732         3-level table to accommodate joining groups defined with higher
61733         codepoint value.  Since there are only 88 groups defined in
61734         Unicode 7.0.0, use 7-bit packed format for level3 entries.
61735         (get_lbp): Update for Unicode 6.1.0.
61736         * lib/unictype/joininggroup_of.c (uc_joining_group): Adjust to use
61737         3-level table.
61738         * lib/unictype/joininggroup_byname.gperf: Add Rohingya Yeh
61739         joining group name.
61740         * lib/unictype/joininggroup_name.h: Likewise.
61741         * lib/unilbrk/lbrktables.h (LBP_HL): New enumeration value.
61742         (unilbrk_table): Adjust table size.
61743         * lib/unilbrk/lbrktables.c (unilbrk_table): Add a row and column
61744         for LBP_HL.
61745         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0604,
61746         U+08E4..U+08FE, U+1BAB, U+1CF4, U+A674..U+A67B, U+A69F,
61747         U+AAEC..U+AAED, U+AAF6, U+11100..U+11102, U+11127..U+1112B,
61748         U+1112D..U+11134, U+11180..U+11181, U+111B6..U+111BE, U+116AB,
61749         U+116AD, U+116B0..U+116B5, U+116B7, U+16F8F..U+16F92.  Remove
61750         U+302E..U+302F.
61751         * tests/uniwidth/test-uc_width2.sh: Same updates as in
61752         lib/uniwidth/width.c.
61753         * all generated files under lib/uni* and tests/uni*: Regenerate.
61754         * modules/uni*/* (configure.ac): Bump minimum version to 0.9.5.
61756 2015-01-15  Daiki Ueno  <ueno@gnu.org>
61758         uniwbrk/u32-wordbreaks-tests: add conformance test
61759         * modules/uniwbrk/u32-wordbreaks-tests (Files): Add
61760         tests/uniwbrk/test-uc-wordbreaks.c,
61761         tests/uniwbrk/test-uc-wordbreaks.sh, and
61762         tests/uniwbrk/WordBreakTest.txt.
61763         (Makefile.am): Add uniwbrk/test-uc-wordbreaks.sh to $(TESTS), add
61764         test-uc-wordbreaks to $(check_PROGRAMS), and define
61765         test_uc_wordbreaks_SOURCES and test_uc_wordbreaks_LDADD.
61766         * tests/uniwbrk/test-uc-wordbreaks.sh: New file.
61767         * tests/uniwbrk/test-uc-wordbreaks.c: New file.
61769 2015-01-15  Daiki Ueno  <ueno@gnu.org>
61771         uniwbrk: ignore Extended/Format characters at BOL not BOS
61772         * lib/uniwbrk/u-wordbreaks.h (FUNC): Ignore Extend and Format
61773         characters if the previous character property is one of
61774         WBP_NEWLINE, WBP_CR, and WBP_LF.
61776 2015-01-11  Jim Meyering  <meyering@fb.com>
61778         test-strstr.c: avoid a trivial leak
61779         * tests/test-strstr.c (main): Free haystack.
61781         update-copyright: recognize groff's \(co marker
61782         * build-aux/update-copyright (circle_c_re): Also accept
61783         uses of \(co, as found in gzip.1.
61785 2015-01-08  Pádraig Brady  <P@draigBrady.com>
61787         maint.mk: fix compatibility with OS X nm
61788         * top/maint.mk (_gl_tight_scope): Use the -g option to
61789         show exported items rather than the -e option which is
61790         ignored on all platforms except OS X where it gives an error.
61791         Reported by Assaf Gordon.
61793 2015-01-07  KO Myung-Hun  <komh@chollian.net>
61795         localcharset: improve charset detection on OS/2
61796         Use system codepage when appropriate.  Map OS/2 codepages to
61797         GNU canonical charset names if possible.
61798         * lib/config.charset: Don't output aliases if "$os" is os2*.
61799         * lib/localcharset.c (get_charset_aliases) [OS2]: Hardcode the
61800         result for OS/2.
61801         (locale_charset) [OS2]: Use system codepage if codeset is omitted
61802         from the locale name which is neither "C" nor "POSIX".
61804 2015-01-06  Paul Eggert  <eggert@cs.ucla.edu>
61806         count-leading-zeros: use 64-bit intrinsics on 32-bit Windows
61807         This reverts the last patch but one, as it shouldn't be needed now
61808         that the typo is fixed.
61809         * lib/count-leading-zeros.h (count_leading_zeros_ll):
61810         * lib/count-trailing-zeros.h:
61811         * lib/count-one-bits.h:
61812         Go back to using 64-bit intrinsics.
61814         count-leading-zeros: fix pragma typos
61815         * lib/count-leading-zeros.h (_BitScanReverse, _BitScanReverse64):
61816         Fix typos in declaration of intrinsics when _MSC_VER.
61818 2015-01-06  Pádraig Brady  <P@draigBrady.com>
61820         count-leading-zeros: avoid 64-bit intrinsics on 32-bit Windows
61821         * lib/count-leading-zeros.h (count_leading_zeros_ll): Use 32 bit
61822         intrinsics in this case.
61823         * lib/count-trailing-zeros.h: Likewise.
61824         * lib/count-one-bits.h: Likewise.
61826 2015-01-06  Daiki Ueno  <ueno@gnu.org>
61828         uniname/uniname: update to Unicode 7.0.0
61829         To accommodate new characters added since Unicode 5.1.0, this
61830         changes the internal representation of codepoint ranges.
61831         Previously, we grouped codepoint ranges by manually assigned 4-bit
61832         tag, which only allowed 16 groups.  This removes the limitation by
61833         switching to binary search on a table.  For the detail rationale
61834         and the benchmark results, see:
61835         https://lists.gnu.org/r/bug-libunistring/2014-06/msg00001.html
61836         * lib/uniname/gen-uninames.lisp (unicode-char): Rename CODE member
61837         to INDEX, as it no longer represents a codepoint.
61838         (range): New struct.
61839         (main): Switch to intervals list from a bit-pattern based
61840         classification.
61841         * lib/uniname/uninames.h: Regenerate.
61842         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 7.0.0.
61843         * modules/uniname/base (configure.ac): Bump minimum version to
61844         0.9.5.
61845         * modules/uniname/uniname (configure.ac): Bump minimum version to
61846         0.9.5.
61848 2015-01-05  Eric Blake  <eblake@redhat.com>
61850         doc: update INSTALL from autoconf
61851         * doc/install.texi: Resync from autoconf.
61852         * doc/INSTALL: Reflect recent autoconf update.
61853         * doc/INSTALL.ISO: Likewise.
61854         * doc/INSTALL.UTF-8: Likewise.
61856         stdio: fix use of PRIdMAX on modern mingw
61857         * m4/stdio_h.m4 (gl_STDIO_H): Probe for printf flavor via inttypes.
61858         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM): Use result
61859         to work with modern mingw.
61861 2015-01-05  Daniel P. Berrange  <berrange@redhat.com>  (tiny change)
61863         pthread: detect git mingw builds with only partial pollution
61864         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for additional
61865         pollution, as seen temporarily in Fedora 21.
61867 2015-01-04  Paul Eggert  <eggert@cs.ucla.edu>
61869         lib-symbol-versions: cache script check
61870         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT):
61871         Cache the check for linker version scripts.
61872         From a suggestion by Christophe Curis in:
61873         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00011.html
61875 2015-01-04  Benno Schulenberg  <bensberg@justemail.net>
61877         maint: fix grammar nits in propername (trivial change)
61878         * lib/propername.h: Remove a mistaken comma and a duplicate "from",
61879         and use an adequate verb and tense.
61881 2015-01-02  Ludovic Courtès  <ludo@gnu.org>
61883         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
61884         * module/gendocs: Add 'doc/gendocs_template_min'.
61886         * build-aux/gendocs.sh: Change email addresses and upstream URLs
61887         from to Gnulib's.
61888         (scripturl, templateurl): Adjust accordingly.
61890 2015-01-01  Paul Eggert  <eggert@cs.ucla.edu>
61892         gendocs: copyright date and version fix
61893         Reported by Karl Berry in:
61894         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00002.html
61895         * build-aux/gendocs.sh, doc/gendocs_template, doc/gendocs_template_min:
61896         Fix copyright date.
61897         * build-aux/gendocs.sh (scriptversion): Update.
61899 2015-01-01  Karl Berry  <karl@gnu.org>
61901         * doc/install.texi,
61902         * build-aux/mdate-sh,
61903         * build-aux/depcomp,
61904         * build-aux/config.guess,
61905         * build-aux/config.sub,
61906         * build-aux/ar-lib,
61907         * build-aux/compile: revert copyright updates (some from last
61908         year) in slaved files.
61910 2015-01-01  Paul Eggert  <eggert@cs.ucla.edu>
61912         version-etc: new year
61913         * doc/gnulib.texi:
61914         * lib/version-etc.c (COPYRIGHT_YEAR): Update copyright date.
61915         * all files: Run 'make update-copyright'.
61917 2014-12-30  Pádraig Brady  <P@draigBrady.com>
61919         xstrtol: ensure errno is reset
61920         Since commit 3bf75404, on 26-09-1998, errno may not have been reset.
61921         Noticed with a spurious coreutils test failure on Darwin 14.0.0.
61923         * lib/xstrtol.c (__xstrtol): Always reset errno before returning.
61925 2014-12-28  Paul Eggert  <eggert@cs.ucla.edu>
61927         utimens: fix dependency typo
61928         * modules/utimens (Depends-on): Remove 'assure'.
61929         This bug was introduced in the recent 'assure' patch.
61931 2014-12-22  Eric Blake  <eblake@redhat.com>
61933         docs: mention why libgen.h is bad
61934         * doc/posix-headers/libgen.texi (libgen.h): Refer to dirname module.
61936 2014-12-20  Paul Eggert  <eggert@cs.ucla.edu>
61938         assure: new module
61939         This works better than 'assert' when compiling with -DNDEBUG,
61940         as it avoids some compiler diagnostics in that case.
61941         Reported by Norihiro Tanaka in:
61942         http://lists.gnu.org/r/bug-gnulib/2014-12/msg00215.html
61943         * MODULES.html.sh (func_all_modules): Add 'assure'.
61944         * lib/assure.h, modules/assure: New files.
61945         * lib/chdir-long.c, lib/cycle-check.c, lib/fchdir.c, lib/fts.c:
61946         * lib/poll.c, lib/savewd.c, lib/xstrtol.c:
61947         Prefer 'assure' to 'assert'.
61948         * lib/utimens.c: Stop using 'assert'; it wasn't helpful.
61949         * modules/chdir-long, modules/cycle-check, modules/fchdir:
61950         * modules/poll, modules/savewd, modules/utimens, modules/xstrtol:
61951         Depend on 'assure'.
61953 2014-12-16  Paul Eggert  <eggert@cs.ucla.edu>
61955         stdalign: port better to HP compilers
61956         * m4/stdalign.m4 (gl_STDALIGN_H): Try the test if __HP_cc or
61957         __HP_aCC are nonzero, to be consistent with the 2014-01-20 patch.
61959         stdalign: work around Apple GCC 4.0 bug
61960         Reported by David Fang in:
61961         http://lists.gnu.org/r/bug-gnulib/2014-12/msg00194.html
61962         * lib/stdalign.in.h (_Alignas):
61963         * m4/stdalign.m4 (gl_STDALIGN_H):
61964         Do not use aligned attribute with GCC 4.0 on Apple.
61966 2014-12-16  Pádraig Brady  <P@draigBrady.com>
61968         getcwd: fix test failure on OS X 10.9
61969         * m4/getcwd-path-max.m4: Avoid the replacement if it
61970         won't be effective due to the PATH_MAX limitation of lstat().
61971         (gl_cv_func_getcwd_path_max): Adjust to indicate this case.
61972         * m4/getcwd.m4 (gl_FUNC_GETCWD): Define HAVE_GETCWD_SHORTER
61973         for this case for use in tests, and also exclude this
61974         case when setting REPLACE_GETCWD.
61975         * tests/test-getcwd.c (test_long_name): Restrict the
61976         tested path length so that lstat() will not be passed
61977         a path greater than PATH_MAX.
61978         Also key a test condition on HAVE_OPENAT_SUPPORT rather
61979         than AT_FDCWD, since the latter is set unconditionally
61980         since Sep 2009 in commit 52c658e9.
61982 2014-12-14  Tim Rühsen  <tim.ruehsen@gmx.de>
61984         parse-datetime: avoid a compiler warning with byacc (trivial)
61985         * lib/parse-datetime.y (yylex): Use the same prototype in the
61986         function definition as the declaration, to avoid a -Wstrict-prototypes
61987         warning seen when using byacc.
61989 2014-12-12  Daiki Ueno  <ueno@gnu.org>
61991         unicase/locale-language-tests: fix LOCALE_FR test
61992         * tests/unicase/test-locale-language.sh: Really use $LOCALE_FR for
61993         a French locale with traditional encoding.
61994         Reported by umerqayam in:
61995         http://lists.gnu.org/r/bug-libunistring/2014-12/msg00000.html
61997 2014-12-12  Paul Eggert  <eggert@cs.ucla.edu>
61999         stddef: support C11's max_align_t
62000         * doc/posix-headers/stddef.texi (stddef.h): Document max_align_t.
62001         * lib/stddef.in.h (_@GUARD_PREFIX@_STDDEF_H) [__need_wint_t]:
62002         Do not undef, as that might cause max_align_t to be defined twice.
62003         Instead, change use to check for _GL_STDDEF_WINT_T too.
62004         (max_align_t) [!HAVE_MAX_ALIGN_T]: New decl.
62005         * m4/stddef_h.m4 (gl_STDDEF_H, gl_STDDEF_H_DEFAULTS):
62006         Check for max_align_t.
62007         * modules/stddef (stddef.h): Substitute HAVE_MAX_ALIGN_T.
62008         * modules/stddef-tests (Depends-on): Add stdalign.
62009         * tests/test-stddef.c: Test max_align_t.
62011 2014-12-11  Daiki Ueno  <ueno@gnu.org>
62013         unistd: fix iOS check conditional
62014         On Mac OS X 10.8, the TARGET_* macros are unconditonally defined
62015         as 0 or 1 in <TargetConditionals.h>, and the previous check always
62016         yielded true on non-iOS environment.
62017         * lib/unistd.in.h (environ) [__APPLE__]: Check the values of
62018         TARGET_OS_IPHONE and TARGET_IPHONE_SIMULATOR, instead of whether
62019         they are defined.
62021 2014-12-09  Paul Eggert  <eggert@cs.ucla.edu>
62023         posixtm: avoid compiler warning in a better way
62024         * lib/posixtm.c (IF_LINT): Remove.
62025         (year, posix_time_parse):
62026         Return true (not 0) if successful.  All callers changed.
62027         (posix_time_parse): Simplify to pacify GCC without need for IF_LINT.
62029 2014-12-08  KO Myung-Hun  <komh78@gmail.com>
62031         * lib/relocatable.c (relocate): Prepend $UNIXROOT to pathname if it is
62032         started with '/' on EMX.
62034 2014-12-08  KO Myung-Hun  <komh78@gmail.com>
62036         freopen: workaround freopen() on OS/2 kLIBC
62037         * lib/freopen.c (rpl_freopen): Workaround.
62038         * m4/freopen.m4: Add os2* case.
62040         get_shared_library_fullname: port to EMX
62041         * lib/relocatable.c: Define strcmp and strncmp to stricmp and strnicmp
62042         on EMX, respectively.
62043         (_DLL_InitTerm): New on EMX.
62044         (get_shared_library_fullname): Implement on EMX.
62046         find_executable: port to EMX
62047         * lib/progreloc.c (find_executable): Implement on EMX.
62049         sched: check struct sched_param in spawn.h as well
62050         * lib/sched.in.h: Include spawn.h on kLIBC.
62051         * lib/sched_h.m4: Check struct sched_param in spawn.h as well.
62053 2014-12-08  Martin Kletzander  <mkletzan@redhat.com>  (tiny change)
62055         bootstrap: Allow perl modules in $buildreq
62056         * build-aux/bootstrap: Add case for perl modules.
62058 2014-12-08  Pádraig Brady  <P@draigBrady.com>
62060         apply _GL_ATTRIBUTE_PURE to some inline functions
62061         clang 3.4.2 flagged these inline functions as pure
62062         * lib/savewd.h (savewd_errno): Set _GL_ATTRIBUTE_PURE.
62063         * lib/sig-handler.h (get_handler): Likewise.
62064         * lib/stat-time.h (get_stat_{a,c,m,birth}time{,_ns}): Likewise.
62065         * lib/timespec.h (timespec_cmp, timespec_sign): Likewise.
62067 2014-12-06  Pádraig Brady  <P@draigBrady.com>
62069         vasnprintf: fix potential use after free
62070         * lib/vasnprintf.c (VASNPRINTF): Fix free-memory read,
62071         flagged by clang-analyzer 3.4.2.
62073 2014-12-05  Pádraig Brady  <P@draigBrady.com>
62075         filevercmp, posixtm: avoid compiler warnings with -O3
62076         * lib/filevercmp.h (filevercmp): Tag with _GL_ATTRIBUTE_PURE
62077         * lib/posixtm.c: (IF_LINT): Define.
62078         (posix_time_parse): Use it to void a "may be used uninitialized"
62079         warning, seen only with -O3.
62081 2014-12-05  Bruno Haible  <bruno@clisp.org>
62083         Fix LDBL80_WORDS macro on big endian platforms.
62084         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Add missing parenthesis in
62085         LDBL80_WORDS macro.
62086         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
62087         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
62088         * tests/test-isfinite.c (test_isfinitel): Likewise.
62089         * tests/test-isinf.c (test_isinfl): Likewise.
62090         * tests/test-isnan.c (test_long_double): Likewise.
62091         * tests/test-isnanl.h (main): Likewise.
62092         * tests/test-snprintf-posix.h (LDBL80_WORDS): Add missing parenthesis.
62093         * tests/test-sprintf-posix.h (LDBL80_WORDS): Likewise.
62094         * tests/test-vasnprintf-posix.c (LDBL80_WORDS): Likewise.
62095         * tests/test-vasprintf-posix.c (LDBL80_WORDS): Likewise.
62096         Reported by Pádraig Brady.
62098 2014-12-02  KO Myung-Hun  <komh78@gmail.com>
62100         git-version-gen: do not print new line characters
62101         * build-aux/git-version-gen: Use printf instead of echo and tr.
62103         gnulib-tool: recognize x:* as an absolute path
62104         * gnulib-tool (func_gnulib_dir): Add ?:* case.
62105         (func_relconcat): Likewise.
62107 2014-12-02  Andrei Borzenkov  <arvidjaar@gmail.com>
62109         argp: avoid extraneous translation and mem leak with empty pre doc
62110         * lib/argp-help.c (argp_doc): Never translate the empty string,
62111         when "\v" is the first or last character of the string, as that
62112         has a reserved meaning to return the header info from a po file.
62113         This also fixes a small memory leak in the !post case.
62114         The issue can be seen with this command for example:
62115         LC_MESSAGES=en_US grub2-mknetdir --help
62117 2014-11-27  Daiki Ueno  <ueno@gnu.org>
62119         uniname/uniname-tests: skip if system's libunistring is used
62120         * modules/uniname/uniname-tests (Makefile.am): Skip test if
62121         uniname/uniname module is not compiled.
62123 2014-11-27  Pádraig Brady  <P@draigBrady.com>
62125         printf: fix configure check on big endian systems
62126         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Add missing bracket.
62128 2014-11-22  Daiki Ueno  <ueno@gnu.org>
62130         pipe-filter-gi, pipe-filter-ii: port to AIX
62131         On AIX 7.1, 'select' is defined as static and cannot be referred
62132         to from inline function.
62133         * lib/pipe-filter-aux.h (nointr_select): Remove, manually expand
62134         the definition...
62135         * lib/pipe-filter-gi.c (filter_loop): ...here, and...
62136         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): ...here.
62138 2014-11-20  Paul Eggert  <eggert@cs.ucla.edu>
62140         gitlog-to-changelog: add --until
62141         * build-aux/gitlog-to-changelog: Support new --until option.
62142         Need described by Eli Zaretskii in: http://bugs.gnu.org/19113
62144 2014-11-14  Paul Eggert  <eggert@cs.ucla.edu>
62146         extern-inline: update commentary about GCC bugs
62147         * m4/extern-inline.m4: Add another GCC bug number to comments.
62149 2014-11-13  Daiki Ueno  <ueno@gnu.org>
62151         gen-uni-tables: untabify
62152         * lib/gen-uni-tables.c: Untabify.
62154 2014-11-13  Daiki Ueno  <ueno@gnu.org>
62156         gen-uni-tables: check out-of-range values added to 3-level tables
62157         * lib/gen-uni-tables.c (output_category, output_bidi_category)
62158         (output_joining_type, output_ident_category): Check out-of-range
62159         values added to 3-level tables.
62161 2014-11-13  Daiki Ueno  <ueno@gnu.org>
62163         gen-uni-tables: utilize 'assert'
62164         * lib/gen-uni-tables.c: Include <assert.h>.
62165         (output_category, output_combclass, output_decimal_digit_test)
62166         (output_decimal_digit, output_digit_test, output_digit)
62167         (output_numeric, get_mirror_value, fill_properties)
62168         (fill_property30, is_property_alphabetic)
62169         (is_property_default_ignorable_code_point)
62170         (is_property_uppercase, is_property_lowercase)
62171         (is_property_cased, is_property_case_ignorable)
62172         (is_property_changes_when_lowercased, is_property_iso_control)
62173         (is_property_math, fill_arabicshaping, output_joining_group)
62174         (fill_scripts, fill_blocks, output_lbp, fill_org_wbp)
62175         (output_wbp, fill_org_gbp, get_decomposition)
62176         (output_decomposition, fill_composition_exclusions)
62177         (debug_output_composition_tables, output_composition_tables)
62178         (redistribute_casefolding_rules, output_casing_rules): Use
62179         'assert (EXPR);' instead of 'if (!EXPR) abort ();' for better error
62180         reporting.
62182 2014-11-13  Daiki Ueno  <ueno@gnu.org>
62184         gen-uni-tables: cosmetic improvements
62185         * lib/gen-uni-tables.c: Escape newlines in the Emacs file local
62186         variables specification.
62187         (is_outdigit): Remove unused function.
62189 2014-11-12  Jeroen Roovers  <jer@gentoo.org>  (tiny change)
62191         fcntl-h-tests: port to PA-RISC GNU/Linux
62192         * tests/test-fcntl-h.c (main): Check O_SYNC is different from O_DSYNC.
62194 2014-11-10  Paul Eggert  <eggert@cs.ucla.edu>
62196         fts: port to C89
62197         Problem reported for MSVC 16 by Gisle Vanem in:
62198         http://lists.gnu.org/r/bug-gnulib/2014-11/msg00027.html
62199         * lib/fts.c (fts_build): Avoid declaration before statement.
62201 2014-11-06  Paul Eggert  <eggert@cs.ucla.edu>
62203         unistd: port to iOS
62204         Problem reported by André Klitzing in:
62205         http://lists.gnu.org/r/bug-gnulib/2014-11/msg00013.html
62206         * lib/unistd.in.h (environ): Do not include crt_externs.h on iOS.
62208 2014-11-05  Paul Eggert  <eggert@cs.ucla.edu>
62210         obstack: do not reject malloc-style obstack_chunkfun, obstack_freefun
62211         Problem reported by Alan Modra in:
62212         http://lists.gnu.org/r/bug-gnulib/2014-11/msg00007.html
62213         * lib/obstack.h (obstack_chunkfun, obstack_freefun):
62214         Always cast the function arg, reverting this part of the previous
62215         change.
62217 2014-11-04  Paul Eggert  <eggert@cs.ucla.edu>
62219         obstack: avoid potentially-nonportable function casts
62220         * lib/obstack.c (CALL_CHUNKFUN, CALL_FREEFUN):
62221         Remove, replacing with ...
62222         (call_chunkfun, call_freefun): New static functions.
62223         All uses changed.  Avoid potentially-nonportable casts.
62224         (chunkfun_type, freefun_type): Remove typedefs; no longer used.
62225         (_obstack_begin_worker): Omit last two args, since they
62226         rely on potentially-nonportable casts.  All callers changed.
62227         * lib/obstack.h (_OBSTACK_CAST): New macro.
62228         Use it everywhere the old API used a potentially-nonportable cast.
62229         The new API doesn't cast.
62230         (struct obstack): Use unions rather than requiring
62231         potentially-nonportable casts.
62232         (obstack_chunkfun, obstack_freefun): Return void.
62234 2014-11-03  Alan Modra  <amodra@gmail.com>
62236         obstack: fix macro return values
62237         * lib/obstack.h (obstack_next_free): Return void *.
62238         (obstack_1grow_fast, obstack_blank_fast): Return void.
62239         For __GNUC__ macros:
62240         (obstack_1grow, obstack_blank): Remove now unnecessary (void) 0.
62241         For !__GNUC__ macros:
62242         (obstack_make_room, obstack_grow, obstack_grow0)
62243         (obstack_ptr_grow_fast, obstack_int_grow_fast): Return void.
62245 2014-11-03  Paul Eggert  <eggert@cs.ucla.edu>
62247         obstack: do not assume system-supplied obstack is size_t safe
62248         * m4/obstack.m4: New file.
62249         * modules/obstack (Files): Add it.
62251         obstack: port to platforms that #define __alignof__
62252         * lib/obstack.c: Include <alignof.h> if !defined __alignof__,
62253         not if !_LIBC.  We don't know of any platforms that #define
62254         __alignof__, but it might be useful in tests.  Conversely,
62255         glibc assumes GCC.
62257 2014-11-03  Pádraig Brady  <P@draigBrady.com>
62259         linkat: don't unconditionally replace on GNU/Linux
62260         * m4/linkat.m4 (gl_FUNC_LINKAT): The compile check for AT_SYMLINK_FOLLOW
62261         was redundant for a few reasons.  It was present to support compiling
62262         on new systems but running on the old narrow window of Linux 2.6.1[67].
62263         It setup and cleaned up test files which weren't actually used.
62264         On non __linux__ it compile tested AT_SYMLINK_FOLLOW, but that is
62265         implicit in the following check.
62267 2014-11-03  Pádraig Brady  <P@draigBrady.com>
62269         linkat: wrap to handle symlinks on OS X 10.10
62270         * m4/linkat.m4 (gl_FUNC_LINKAT): linkat() is available on Yosemite
62271         but not usable because it doesn't support creating hardlinks
62272         to symlinks.  Therefore add a generic test for this capability
62273         and fallback to our emulation if linkat() fails with ENOTSUP.
62275 2014-11-02  Paul Eggert  <eggert@cs.ucla.edu>
62277         open, openat: document nonstandard FreeBSD, NetBSD O_NOFOLLOW errno
62278         * doc/posix-functions/open.texi (open):
62279         * doc/posix-functions/openat.texi (openat):
62280         Document that these functions do not set errno to ELOOP when
62281         a symlink is opened with O_NOFOLLOW.
62283 2014-10-31  Paul Eggert  <eggert@cs.ucla.edu>
62285         obstack: add NEWS entry for recent incompatible changes
62286         * NEWS: Describe recent changes.
62288 2014-10-30  Pádraig Brady  <P@draigBrady.com>
62290         mountlist: don't use libmount to decide on dummy/remote
62291         * lib/mountlist.c (read_file_system_list): Don't use the libmount
62292         routines to determine whether a file system is dummy or remote,
62293         as they're not currently compatible.  For example the remoteness
62294         is determined on file system type (for which the list seems incomplete),
62295         rather than simply checking for a ':' in the device name.
62296         Also libmount currently determines that 'tmpfs' is a dummy file system
62297         even though it has associated storage.
62299 2014-10-29  Paul Eggert  <eggert@cs.ucla.edu>
62301         obstack: prefer __alignof__ to alignof
62302         This is for portability to pre-4.7 GCC when compiling glibc.
62303         See Joseph S. Myers in:
62304         http://sourceware.org/ml/libc-alpha/2014-10/msg00703.html
62305         * lib/obstack.c (__alignof__) [!_LIBC && !__GNUC__]:
62306         New macro, defined by including and using <alignof.h>.
62307         (MAX): New macro.
62308         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Redefine in terms of these.
62309         Do not use enums as they are not portable to some broken compilers.
62310         * modules/obstack (Depends-on): Depend on alignof, not stdalign.
62312         obstack: prefer alignof to calculating alignments by hand
62313         * lib/obstack.c: Include <stdalign.h>.
62314         (struct fooalign): Remove.
62315         (DEFAULT_ALIGNMENT): Use alignof rather than the old offsetof hack.
62316         * modules/obstack (Depends-on): Add stdalign.
62318 2014-10-28  Paul Eggert  <eggert@cs.ucla.edu>
62320         obstack: use size_t alignments and check for overflow
62321         * lib/obstack.c, lib/obstack.h (_obstack_begin, _obstack_begin_1):
62322         * lib/obstack.c (_obstack_begin_worker, _obstack_newchunk):
62323         * lib/obstack.h (struct obstack.alignment_mask):
62324         Use _OBSTACK_SIZE_T, not int, for alignments.
62325         * lib/obstack.c (_obstack_newchunk): Fail if the size calculation
62326         overflows, e.g., when adding the alignment.
62328 2014-10-29  Alan Modra  <amodra@gmail.com>
62330         obstack: 64-bit obstack support, part 3
62331         This finally enables full 64-bit obstack support.  The glibc
62332         shared library specific code is removed from obstack.c too, and
62333         the error handling code conditionally compiled under control of
62334         another macro, _OBSTACK_NO_ERROR_HANDLER.
62335         * lib/obstack.h: Include string.h earlier.
62336         (_OBSTACK_INTERFACE_VERSION): Define.
62337         (_OBSTACK_SIZE_T, _CHUNK_SIZE_T): Define as size_t for version 2.
62338         * lib/obstack.c: Don't include shlib-compat.h.
62339         (OBSTACK_INTERFACE_VERSION): Delete.
62340         (_OBSTACK_ELIDE_CODE): Rename from ELIDE_CODE.  Define when version 1
62341         glibc code is compatible with version 2.  Don't include stdio.h for
62342         __GNU_LIBRARY.
62343         (obstack_exit_failure, print_and_abort, obstack_alloc_failed_handler):
62344         Omit when _OBSTACK_NO_ERROR_HANDLER defined.  Include stdio.h here.
62345         (_obstack_compat, _obstack, _obstack_newchunk, obstack_free): Delete
62346         glibc shared library specific source.
62348         obstack: 64-bit obstack support, part 2
62349         This gets us 4G obstack support, without changing ABI
62350         compatibility, apart from possibly introducing some
62351         signed/unsigned comparison warnings in code that uses obstack.h.
62352         a) Replace "int" size parameters, return values, and macro local vars
62353            with _OBSTACK_SIZE_T, an "unsigned int" for now.
62354         b) Make obstack.chunk_size a _CHUNK_SIZE_T, an "unsigned long" for now.
62355         c) Make all obstack macros checking available room use obstack_room.
62356            "next_free + desired > chunk_limit" may wrap the lhs for chunks
62357            allocated near the top of memory.
62358         d) Use unsigned comparisons, and macro locals to support >2G on 32-bit.
62359         * lib/obstack.h (_OBSTACK_SIZE_T): Define.  Use throughout
62360         in place of "int" size parameters, return values and local vars.
62361         (_CHUNK_SIZE_T): Define.
62362         (struct obstack): Make chunk_size a _CHUNK_SIZE_T.  Make temp
62363         union use an _OBSTACK_SIZE_T integer type.
62364         For __GNUC__ versions of the following macros...
62365         (obstack_room): Rename local var.
62366         (obstack_make_room): Use obstack_room.
62367         (obstack_grow, obstack_grow0, obstack_1grow, obstack_ptr_grow,
62368         obstack_int_grow, obstack_blank): Likewise.
62369         (obstack_finish): Use unsigned comparison when comparing aligned
62370         next_free against chunk_limit.
62371         (obstack_free): Cast OBJ to remove possible const qualifier.
62372         For !__GNUC__ versions of the following macros...
62373         (obstack_make_room): Use obstack_room.
62374         (obstack_grow, obstack_grow0, obstack_1grow, obstack_ptr_grow,
62375         obstack_int_grow, obstack_blank): Likewise.
62376         (obstack_finish): Use unsigned comparision when comparing aligned
62377         next_free against chunk_limit.
62378         (obstack_free): Use temp.p and same comparisons as __GNUC__ version.
62379         * lib/obstack.c (_obstack_begin_worker): Make "size" parameter
62380         _OBSTACK_SIZE_T.
62381         (_obstack_begin, _obstack_begin_1): Likewise.
62382         (_obstack_newchunk): Likewise for length parameter.  Use size_t locals.
62383         (_obstack_memory_used): Return and use _OBSTACK_SIZE_T local.
62385         obstack: 64-bit obstack support, part 1
62386         a) Correct calls to alloc function, to use a size_t arg.  "long" is
62387            just wrong on targets like x86_64-mingw64 where "long" is 32 bits
62388            and "size_t" 64 bits.
62389         b) Consolidate _obstack_begin and _obstack_begin1 code.
62390         * lib/obstack.h (struct obstack <chunkfun>): Correct prototype to
62391         use "size_t" rather than "long".
62392         (_obstack_begin, _obstack_begin1): Likewise.
62393         (obstack_init, obstack_begin, obstack_specify_allocation_with_arg,
62394         obstack_chunkfun): Update alloc function casts.
62395         * lib/obstack.c (CALL_CHUNKFUN): Update chunkfun cast.
62396         (chunkfun_type, freefun_type): New typdefs.
62397         (_obstack_begin_worker): Split out from ..
62398         (_obstack_begin, _obstack_begin_1): ..here.
62400         obstack: tidy part 2
62401         a) Don't be concerned about "not polluting the namespace with stddef.h
62402            symbols" in obstack.h, since gnulib string.h includes stddef.h
62403            anyway, and it seems unlikely that anyone would care.
62404         b) Don't roll our own slow memcpy in _obstack_newchunk.
62405         c) Rename obstack_free to _obstack_free.  This makes the naming
62406            consistent with other obstack functions and obviates the need for
62407            __obstack_free.  Ancient obstack.c defined both obstack_free and
62408            _obstack_free.  We continue to do that for _LIBC via an alias.
62409         d) Miscellaneous macro fixes.  The expression used to test for gcc-2.8
62410            is clever, but nowadays gcc warns on undefined macros.  You'll get
62411            an undefined macro warning if simulating an old gcc with -U__GNUC__
62412            -U__GNUC_MINOR__ -D__GNUC__=1.
62413         * lib/obstack.h: Include stddef.h unconditionally.  Formatting fixes.
62414         (PTR_INT_TYPE): Delete, replace with ptrdiff_t.
62415         (__obstack_free): Delete, update refs.
62416         (_obstack_free): Rename from obstack_free.
62417         (__extension__): Avoid undefined macro warning for __GNUC_MINOR__.
62418         (obstack_object_size, obstack_room): Parenthesise !__GNUC__ versions.
62419         * lib/obstack.c: Don't include stddef.h.
62420         (COPYING_UNIT): Delete.
62421         (_obstack_begin): Formatting fix.
62422         (_obstack_newchunk): Use memcpy to move existing object to new chunk.
62423         (_obstack_free): Rename from __obstack_free, update alias.  Move
62424         undef of obstack_free to where it is needed.
62426         obstack: tidy part 1
62427         a) Rename temp fields.  temp.tempint and temp.tempptr just looks ugly
62428            to me, and result in overlong lines after later patches.
62429         b) Move error handling code, to avoid a forward declaration and to
62430            simplify later patches in this series.
62431         * lib/obstack.h (struct obstack <temp>): Rename fields of union
62432         and update all uses.
62433         * lib/obstack.c: Include stdlib.h earlier.
62434         (obstack_exit_failure, obstack_alloc_failed_handler): Move later
62435         in file.
62436         (print_and_abort): Remove now redundant forward declaration.
62438 2014-10-24  Paul Eggert  <eggert@cs.ucla.edu>
62440         socketlib, sockets, sys_socket: Use AC_REQUIRE to pacify autoconf.
62441         Without this change, in bleeding-edge fileutils Autoconf complains
62442         that gl_SOCKETLIB etc. are AC_REQUIREd after being invoked.
62443         * modules/socketlib (configure.ac): AC_REQUIRE gl_SOCKETLIB.
62444         * modules/sockets (configure.ac): AC_REQUIRE gl_SOCKETS.
62445         * modules/sys_socket (configure.ac): AC_REQUIRE gl_HEADER_SYS_SOCKET.
62447 2014-10-24  Daiki Ueno  <ueno@gnu.org>
62449         iconv: avoid false detection of non-working iconv
62450         The INBUF arguments of iconv can be either 'const char **'
62451         or 'char **'.  If CC is g++, the difference causes a compile error
62452         and thus leads to a false detection of non-working iconv.
62453         Reported by Eli Zaretskii and Werner LEMBERG in:
62454         <https://lists.gnu.org/r/bug-gnulib/2014-10/msg00023.html>.
62455         * m4/iconv.m4 (AM_ICONV_LINK): Try all possible argument types of
62456         iconv.  Bump serial number.
62458 2014-10-23  Pádraig Brady  <P@draigBrady.com>
62460         bootstrap: print more diagnostics for missing programs
62461         * build-aux/bootstrap: only suppress stderr when checking for
62462         alternative program names.  This supports programs issuing non
62463         standard error messages.
62465 2014-10-23  Pádraig Brady  <P@draigBrady.com>
62467         bootstrap: only update the gnulib submodule
62468         * build-aux/bootstrap: Restrict the "submodule update" command
62469         to the gnulib path.
62471 2014-10-18  Paul Eggert  <eggert@cs.ucla.edu>
62473         symlinkat: port to AIX 7.1
62474         * doc/posix-functions/symlinkat.texi (symlinkat):
62475         Mention AIX porting problem.
62476         * lib/symlinkat.c: Always include errno.h.
62477         (rpl_symlinkat) [HAVE_SYMLINKAT]: New function.
62478         * lib/unistd.in.h (symlinkat): Add replacement machinery.
62479         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Check symlinkat behavior.
62480         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_SYMLINKAT.
62481         * modules/symlinkat (Depends-on): Add fstatat if REPLACE_SYMLINKAT.
62482         (configure.ac): Also compile replacement if REPLACE_SYMLINKAT.
62483         * modules/unistd (unistd.h): Substitute REPLACE_SYMLINKAT.
62485         readlinkat: port to AIX 7.1
62486         * doc/posix-functions/readlink.texi (readlink):
62487         * doc/posix-functions/readlinkat.texi (readlinkat):
62488         Mention AIX porting problem.
62489         * lib/readlinkat.c (rpl_readlinkat) [HAVE_READLINKAT]:
62490         New function.
62491         * lib/unistd.in.h (readlinkat): Add replacement machinery.
62492         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Check readlinkat signature.
62493         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_READLINKAT.
62494         * modules/readlinkat (configure.ac): Also compile replacement
62495         if REPLACE_READLINKAT.
62496         * modules/unistd (unistd.h): Substitute REPLACE_READLINKAT.
62498 2014-10-12  Karl Berry  <karl@gnu.org>
62500         * doc/posix-functions/dirname.texi: remove spurious {.
62502 2014-09-28  Ben Pfaff  <blp@cs.stanford.edu>
62504         basename, dirname: Improve documentation.
62505         * doc/posix-functions/basename.texi: Mention dirname module and
62506         base_name() function.
62507         * doc/posix-functions/dirname.texi: Mention dir_name() and
62508         mdir_name() functions.
62509         Suggested by Werner LEMBERG <wl@gnu.org>.
62511 2014-09-24  Jim Meyering  <meyering@fb.com>
62513         exclude: declare exclude_patopts static
62514         * lib/exclude.c (exclude_patopts): Declare static,
62515         to avoid triggering a -Wmissing-prototypes warning.
62516         The alternative (declaring it in the .h file) would
62517         require publicizing the private "struct patopts".
62519 2014-09-21  Werner Lemberg  <wl@gnu.org>
62521         dirname: support compilation with C++
62522         * lib/dirname.h: Add necessary C linkage declarations.
62524 2014-09-16  Paul Eggert  <eggert@cs.ucla.edu>
62526         qsort_r: include <config.h>
62527         Problem reported by Tom G. Christensen in:
62528         http://lists.gnu.org/r/bug-gnulib/2014-09/msg00071.html
62529         * lib/qsort.c [!_LIBC]: Include <config.h> first.
62531 2014-09-16  Dylan Cali  <calid1984@gmail.com>
62533         avltree-list: avoid compiler warnings (trivial)
62534         * lib/gl_anytree_list2.h: Add _GL_ATTRIBUTE_PURE to avoid
62535         -Werror=suggest-attribute=pure.
62536         * lib/gl_array_list.c: Likewise.
62537         * lib/gl_avltree_list.c (gl_avltree_list_check_invariants): Add extern
62538         declaration to avoid -Werror=missing-prototypes.  This is not added
62539         to a header as only exported for tests.  Add (void) to the
62540         check_invariants() call to indicate we're discarding the result
62541         in this context which avoids -Werror=unused-value.  Note we don't
62542         use ignore_value here to avoid a dependency as we know we'll not
62543         be adding __attribute__((warn_unused_result)) to check_invariants().
62544         Add _GL_ATTRIBUTE_CONST to avoid -Werror=suggest-attribute=const.
62546 2014-09-15  Paul Eggert  <eggert@cs.ucla.edu>
62548         qsort_r: new module, for GNU-style qsort_r
62549         * m4/qsort_r.m4: New file.  Forgot to add this earlier.
62551 2014-09-15  Werner LEMBERG  <wl@gnu.org>
62553         strerror_r-posix: support compilation with C++
62554         * lib/strerror_r.c: Add necessary C linkage declarations.
62556 2014-09-11  Johannes Zarl  <johannes.zarl@jku.at>
62558         fcntl-h: fix compilation with Intel C++ compiler (trivial)
62559         * lib/fcntl.in.h: ICC has the same issue as GCC <= 4.2.
62561 2014-09-09  Fridolin Pokorny  <fpokorny@redhat.com>
62563         mountlist: use /proc/self/mountinfo when available
62564         Use libmount to propagate device IDs provided by Linux in
62565         /proc/self/mountinfo.  This will give more accurate output when
62566         using df in chroot'ed environments as the device IDs are not
62567         determined by stat() which may be inaccurate within the chroot.
62568         * lib/mountlist.c (read_file_system_list): Use the libmount routines
62569         from util-linux to parse "/proc/self/mountinfo" or fall back to
62570         standard getmntent() processing.
62571         * m4/ls-mntd-fs.m4: Check for libmount only when 1-argument
62572         getmntent() is used, as is the case on GNU/Linux.
62574 2014-09-07  Eric Wong  <normalperson@yhbt.net>
62576         users.txt: add cmogstored
62577         cmogstored has used gnulib since the beginning in 2012 to support
62578         GNU/Linux, FreeBSD, and GNU/kFreeBSD.
62580 2014-09-05  Mathieu Anquetin  <mathieu@anquetin.eu>
62582         Trivial change.
62583         * gnulib-tool: Use same options as build-aux/bootstrap to download
62584         PO files.
62586 2014-09-05  Mathieu Anquetin  <mathieu@anquetin.eu>
62588         Trivial change.
62589         * gnulib-tool: Fallback to wget when rsync of PO files fails.
62591 2014-09-04  Eric Blake  <eblake@redhat.com>
62593         maintainer-makefile: add syntax check for useless ';;'
62594         * top/maint.mk (sc_prohibit_double_semicolon): New rule.
62596 2014-09-04  Paul Eggert  <eggert@cs.ucla.edu>
62598         pthread, pthread_sigmask, threadlib: port to Ubuntu 14.04
62599         Problem reported by Assaf Gordon in:
62600         http://lists.gnu.org/r/bug-gnulib/2014-09/msg00023.html
62601         Apparently Ubuntu is doing some fancy link-time optimization
62602         that doesn't work with -lpthread but does work with -pthread.
62603         Work around the bug by preferring -pthread to -lpthread.
62604         * m4/pthread.m4 (gl_PTHREAD_CHECK):
62605         * m4/threadlib.m4 (gl_THREADLIB_BODY): Prefer -pthread to -lpthread.
62606         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
62607         Treat -pthread like -lpthread.
62609 2014-09-04  Eric Blake  <eblake@redhat.com>
62611         error: drop spurious semicolon
62612         * lib/error.c (__error_at_line): Fix ';;'.
62614 2014-09-02  Paul Eggert  <eggert@cs.ucla.edu>
62616         gnulib-common.m4: port to GCC 4.2.1 and Sun Studio 12 C++
62617         * m4/gnulib-common.m4 (AC_C_RESTRICT):
62618         Override AC_C_RESTRICT unconditionally.
62619         Update from autoconf, incorporating:
62620         2014-09-02 autoconf: port 'restrict' to GCC 4.2.1
62621         2009-01-28 Fix AC_C_RESTRICT for Sun Studio 12 C++.
62623 2014-09-01  Paul Eggert  <eggert@cs.ucla.edu>
62625         manywarnings: add GCC 4.9 warnings
62626         Also, make it easier to maintain this in the future.
62627         * build-aux/gcc-warning.spec: Add -Wabi-tag,
62628         -Wconditionally-supported, -Wdelete-incomplete,
62629         -Winherited-variadic-ctor, -Wvirtual-move-assign, -Wzerotrip.
62630         Remove duplicates.  Use tabs uniformly, as that's what 'cut' wants.
62631         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wdate-time,
62632         -Wopenmp-simd.  Use -fdiagnostics-show-option and -funit-at-a-time
62633         only for older GCC versions that need them.  Handle
62634         -Wnormalized=nfc specially, so that the 'comm' command used
62635         for maintenance doesn't get confused.
62637 2014-08-31  Paul Eggert  <eggert@cs.ucla.edu>
62639         vasnprintf: fix bugs in width computation
62640         * lib/vasnprintf.c (VASNPRINTF):
62641         Rework previous change, which introduced a bug,
62642         to avoid the warning in a different way.
62643         Avoid undefined behavior if the width arg is less than -INT_MAX.
62644         Avoid unnecessary use of HAS_WIDTH local.
62646 2014-08-31  Thien-Thi Nguyen  <ttn@gnu.org>  (tiny change)
62648         vasnprintf: Avoid signed/unsigned comparison warning.
62649         * lib/vasnprintf.c (VASNPRINTF): To calculate padding,
62650         compare end addr of generated string w/ maximum end addr.
62652 2013-08-30  Mats Erik Andersson  <gnu@gisladisker.se>  (tiny change)
62654         parse-datetime: Avoid pointer difference.
62655         * lib/parse-datetime.y (yylex): Compare pointer to end of buffer,
62656         instead of calculating difference of pointers.  This removes an
62657         annoying warning, devoid of any use.
62659 2014-08-29  Paul Eggert  <eggert@cs.ucla.edu>
62661         qsort_r: new module, for GNU-style qsort_r
62662         This works even on FreeBSD, which has an incompatible qsort_r API.
62663         * MODULES.html.sh: Add it.
62664         * doc/glibc-functions/qsort_r.texi: It's now supported.
62665         * lib/qsort.c: New file, taken from glibc with minor changes
62666         inside "#ifndef _LIBC" and with an unnecessary "#include <alloca.h>"
62667         removed.
62668         * lib/qsort_r.c: New file, compiled only on FreeBSD.
62669         * lib/stdlib.in.h (qsort_r): Declare in the usual way.
62670         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS):
62671         * modules/qsort_r, modules/qsort_r-tests: New files.
62672         * modules/stdlib (Makefile): Set up its defaults.
62673         * tests/test-qsort_r.c: New file.
62675 2014-08-08  Paul Eggert  <eggert@cs.ucla.edu>
62677         vla: new module
62678         GNU RCS can use this, mostly for documentation I expect.  See:
62679         http://lists.gnu.org/r/bug-gnulib/2014-08/msg00025.html
62680         * MODULES.html.sh: Add vla.
62681         * lib/vla.h, modules/vla: New files.
62683 2014-08-07  Daiki Ueno  <ueno@gnu.org>
62685         localename: make gl_locale_name_thread really thread-safe on Windows
62686         * lib/localename.c [WINDOWS_NATIVE && !IN_LIBINTL]: Include
62687         "glthread/lock.h".
62688         (get_lcid_lock) [WINDOWS_NATIVE]: New variable.
62689         (get_lcid) [WINDOWS_NATIVE]: Lock while looking for an LCID.
62691 2014-08-07  Paul Eggert  <eggert@cs.ucla.edu>
62693         getpass: don't assume struct termios
62694         Problem report and trivial fix by Jonas 'Sortie' Termansen in:
62695         http://lists.gnu.org/r/bug-gnulib/2014-08/msg00015.html
62696         * lib/getpass.c (getpass): Port to systems lacking struct termios.
62698         getdtablesize: fall back on sysconf (_SC_OPEN_MAX)
62699         Problem reported by Jonas 'Sortie' Termansen in:
62700         http://lists.gnu.org/r/bug-gnulib/2014-08/msg00023.html
62701         * lib/getdtablesize.c (getdtablesize) [_SC_OPEN_MAX]:
62702         Implement via sysconf for platforms that lack getdtablesize.
62704         vararrays: modernize AC_C_VARARRAYS for C11
62705         This backports a change I recently made to Autoconf.
62706         * m4/vararrays.m4 (AC_C_VARARRAYS): Define __STDC_NO_VLA__ if
62707         VLAs are not supported, as this is what C11 does.  The old macro
62708         HAVE_C_VARARRAYS is still defined if they are supported, but is
62709         now obsolescent.  Also, check for VLA bug in GCC 3.4.3.
62711 2014-08-07  Alessandro Degano  <degano@cern.ch>  (tiny change)
62713         relocatable-prog-wrapper: port gettext to OS X 10.8 + GCC 4.8.1
62714         * build-aux/install-reloc (func_create_wrapper): Also wrap
62715         strerror-override, stat, stat.
62717 2014-08-05  Paul Eggert  <eggert@cs.ucla.edu>
62719         sys_select: fix FD_ZERO problem on Solaris 10
62720         * lib/sys_select.in.h: Fix Solaris 10 bug where "#include
62721         <sys/time.h>" followed by "#include <sys/select.h>" caused FD_ZERO
62722         to expand to an expression that invoked memset without necessarily
62723         including <string.h>.  The problem was that the first include
62724         defined _SYS_TIME_H, causing the second include to short-circuit.
62725         Fix a similar problem with <sys/types.h> followed by <sys/select.h>.
62726         Also, fix what appears to be a cut-and-paste typo, by replacing
62727         _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H with
62728         _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TYPES_H.
62730         accept: document Solaris 10 type glitch
62731         * doc/posix-functions/accept.texi (accept): Mention that
62732         Solaris 10 'accept' takes void * last arg, not socklen_t *.
62734 2014-08-04  Paul Eggert  <eggert@cs.ucla.edu>
62736         extern-inline: port to FreeBSD, DragonFly
62737         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Also assume the bug
62738         is present if either __DragonFly__ or __FreeBSD__ is defined.
62739         FreeBSD problem reported by Andrey Borzenkov in:
62740         http://lists.gnu.org/r/bug-gnulib/2014-07/msg00104.html
62741         Also, worry about __APPLE__ only if __MACH__ is also defined,
62742         as this is more consistent with the rest of gnulib.
62743         (_GL_EXTERN_INLINE_STDHEADER_BUG): Rename this internal macro from
62744         _GL_EXTERN_INLINE_APPLE_BUG, since the bug is not limited to Apple.
62746 2014-08-01  Siddhesh Poyarekar  <siddhesh@redhat.com>
62748         regex: Make #if/#ifdef usage consistent for DEBUG
62749         * lib/regex_internal.c: Use "#if defined DEBUG && DEBUG" instead
62750         of the inconsistent usage of #if and #ifdef as that works with
62751         both Glibc and Gnulib's style.
62753 2014-07-31  Eric Blake  <eblake@redhat.com>
62755         openat-die: use _Noreturn markup
62756         * modules/openat-die (Depends-on): Add snippet/_Noreturn.
62757         * lib/openat-die.c (openat_save_fail, openat_restore_fail): Mark
62758         _Noreturn.
62760 2014-07-30  Eric Blake  <eblake@redhat.com>
62762         test-open: port to cygwin, which lacks Fortify
62763         * tests/test-open.h (ALWAYS_INLINE): New macro.
62764         (__always_inline): Don't abuse internal symbol on non-glibc.
62766 2014-07-19  Eli Zaretskii  <eliz@gnu.org>
62768         localename: Enforce declarations before statements.
62769         * localename.c (gl_locale_name_thread): Declare 'lcid' before the
62770         first statement.
62772 2014-07-18  Jim Meyering  <meyering@fb.com>
62774         test-userspec: don't look up numeric user names
62775         * tests/test-userspec.c: I found a system for which getpwnam("0")
62776         returned a pointer to a non-root user's entry, and that made the
62777         test fail.
62778         (T): Prefix each numeric input with "+", to inhibit lookup.
62780 2014-07-15  Eli Zaretskii  <eliz@gnu.org>
62782         localcharset, localename: MS-Windows support for non-default locales
62783         * lib/localcharset.c (locale_charset) [WINDOWS_NATIVE]: Before
62784         falling back on the default system codepage, try extracting
62785         the codepage from what 'setlocale' returns.  This allows to
62786         take into account changes of the codeset due to non-default
62787         locale set by a previous call to 'setlocale'.
62788         * lib/localename.c (LOCALE_NAME_MAX_LENGTH) [WINDOWS_NATIVE]:
62789         Define if not already defined.
62790         (enum_locales_fn, get_lcid) [WINDOWS_NATIVE]: New functions.
62791         (gl_locale_name_thread) [WINDOWS_NATIVE]: Produce the
62792         current locale by calling 'setlocale', then converting the
62793         locale name into LCID by calling 'get_lcid'.  This allows to
62794         take into account changes in the current locale from the
62795         default one, in contrast to GetThreadLocale.
62797 2014-07-14  Daiki Ueno  <ueno@gnu.org>
62799         announce-gen: avoid failure when Digest::SHA is installed
62800         When Digest::SHA is available, Digest::SHA1 is not loaded and thus
62801         Digest::SHA1->new in print_checksums fails.
62802         * build-aux/announce-gen (digest_classes): New associative array
62803         for available message digest implementations.
62804         (print_locations): Use it.
62806 2014-07-13  Pádraig Brady  <P@draigBrady.com>
62808         gettext: revert "update macros to version 0.19"
62809         This reverts commit 9b9370ca, as it currently requires that
62810         developers of any project that explicitly uses the gettext module
62811         or implicitly uses it through the utimens-tests or
62812         futimens-tests modules, use gettext >= 0.19.
62813         However there are some stability and availablity issues with
62814         that version at present.  We can reinstate this soon, when stability
62815         is addressed and packages are more readily available.
62817 2014-07-12  Jim Meyering  <meyering@fb.com>
62819         regex: don't deref NULL upon heap allocation failure
62820         * lib/regcomp.c (parse_dup_op): Handle duplicate_tree
62821         failure in one more place.
62822         To trigger the segfault, configure grep -with-included-regex,
62823         build it, and run these commands:
62824         ( ulimit -v 300000; echo a|src/grep -E a+++++++++++++++++++++ )
62825         I discovered this while replying to a private report from
62826         Jens Schleusener about excessive memory consumption by grep
62827         when using a regular expression like the one above.
62829 2014-07-11  Paul Eggert  <eggert@cs.ucla.edu>
62831         regex: fix memory leak in compiler
62832         Fix by Andreas Schwab in:
62833         https://sourceware.org/ml/libc-alpha/2014-06/msg00503.html
62834         * lib/regcomp.c (parse_reg_exp): Deallocate partially
62835         constructed tree before returning error.
62837 2014-07-10  Assaf Gordon  <assafgordon@gmail.com>
62839         announce-gen: avoid perl warnings
62840         * build-aux/announce-gen: add two minor checks to avoid
62841         "use of uninitialized value" warnings when command-line parameters are
62842         missing.
62844 2014-07-10  Assaf Gordon  <assafgordon@gmail.com>
62846         localename: avoid -Wsuggest-attribute={const,pure} warnings
62847         * lib/localename.c (string_has): Tag internal function as pure.
62848         * lib/localename.h (gl_locale_name_default): Tag extern declaration
62849         as const when appropriate.
62851 2014-07-10  Eli Zaretskii  <eliz@gnu.org>
62853         nl_langinfo: Fix last change.
62854         * lib/nl_langinfo.c (includes): Drop redundant include.
62856 2014-07-10  Siddhesh Poyarekar  <siddhesh@redhat.com>
62858         error: Fix -Wundef warnings in glibc
62859         * lib/error.c [_LIBC]: Define default macros for
62860         glibc.
62861         (print_errno_message) [defined HAVE_STRERROR_R || _LIBC]:
62862         Check _LIBC before STRERROR_R_CHAR_P.
62864         error: Sync from glibc master
62865         * lib/error.c [_LIBC]: Remove INTUSE usage.
62866         (error_tail): Remove unused macro ALLOCA_LIMIT.
62867         Fix potential buffer overflow.  Fix potential NULL dereference
62868         in strcmp.
62870 2014-07-09  Pavel Hrdina  <phrdina@redhat.com> (tiny change)
62872         nl_langinfo: fix build under mingw
62873         * lib/nl_langinfo.c (includes): Pick up <windows.h> for GetACP().
62875 2014-07-09  Andrew D Warshall  <warshall@99main.com>
62877         mountlist: do not classify a bind-mounted dir entry as "dummy"
62878         * m4/ls-mntd-fs.m4: Check for hasmntopt() on platforms with
62879         1-argument getmntent() (instead of assuming absence).
62881 2014-07-08  Eric Blake  <eblake@redhat.com>
62883         maint.mk: less syntax-check noise when SIGPIPE is ignored
62884         * top/maint.mk (_sc_header_without_use)
62885         (sc_require_config_h_first): Parse full list.
62887 2014-07-07  Eli Zaretskii  <eliz@gnu.org>
62888             Paul Eggert  <eggert@cs.ucla.edu>
62890         nl_langinfo: CODESET on MS-Windows and more items from localeconv
62891         * lib/langinfo.in.h (DECIMAL_POINT, THOUSANDS_SEP, GROUPING)
62892         (CURRENCY_SYMBOL, INT_CURR_SYMBOL, MON_DECIMAL_POINT)
62893         (MON_THOUSANDS_SEP, MON_GROUPING, POSITIVE_SIGN, NEGATIVE_SIGN)
62894         (FRAC_DIGITS, INT_FRAC_DIGITS, P_CS_PRECEDES, N_CS_PRECEDES)
62895         (P_SEP_BY_SPACE, N_SEP_BY_SPACE, P_SIGN_POSN, N_SIGN_POSN): Define.
62896         * lib/nl_langinfo.c: Include <locale.h> and <string.h> early.
62897         Include <stdio.h> if Microsoft Windows.
62898         Include <time.h> if !REPLACE_NL_LANGINFO.
62899         (ctype_codeset): New function, taken from rpl_nl_langinfo,
62900         and with improvements for Microsoft Windows.
62901         (rpl_nl_langinfo): Use it.
62902         (nl_langinfo) [!REPLACE_NL_LANGINFO]: Likewise.
62903         Compute the values of RADIXCHAR, THOUSEP, GROUPING, CRNCYSTR,
62904         INT_CURR_SYMBOL, MON_DECIMAL_POINT, MON_THOUSANDS_SEP,
62905         MON_GROUPING, POSITIVE_SIGN, NEGATIVE_SIGN, FRAC_DIGITS,
62906         INT_FRAC_DIGITS, P_CS_PRECEDES, N_CS_PRECEDES, P_SEP_BY_SPACE,
62907         N_SEP_BY_SPACE, P_SIGN_POSN, and N_SIGN_POSN from the
62908         corresponding values returned by 'localeconv'.  Compute the values
62909         of AM_STR, PM_STR, DAY_n, ABDAY_n, MON_n, and ABMON_n by calling
62910         'strftime' with a suitable struct tm value.
62912 2014-07-05  Paul Eggert  <eggert@cs.ucla.edu>
62914         Bruno Haible has stepped down as maintainer.
62915         See Karl Berry in:
62916         http://lists.gnu.org/r/bug-gnulib/2014-07/msg00004.html
62917         Daiki Ueno has volunteered to maintain libunistring; see:
62918         http://lists.gnu.org/r/bug-gnulib/2014-07/msg00005.html
62919         * modules/gen-uni-tables, modules/libunistring:
62920         * modules/libunistring-optional, modules/ucs4-utf16, modules/ucs4-utf8:
62921         * modules/unicase/base, modules/unicase/cased:
62922         * modules/unicase/empty-prefix-context:
62923         * modules/unicase/empty-suffix-context, modules/unicase/ignorable:
62924         * modules/unicase/locale-language, modules/unicase/special-casing:
62925         * modules/unicase/tocasefold, modules/unicase/tolower:
62926         * modules/unicase/totitle, modules/unicase/toupper:
62927         * modules/unicase/u16-casecmp, modules/unicase/u16-casecoll:
62928         * modules/unicase/u16-casefold, modules/unicase/u16-casemap:
62929         * modules/unicase/u16-casexfrm, modules/unicase/u16-ct-casefold:
62930         * modules/unicase/u16-ct-tolower, modules/unicase/u16-ct-totitle:
62931         * modules/unicase/u16-ct-toupper, modules/unicase/u16-is-cased:
62932         * modules/unicase/u16-is-casefolded, modules/unicase/u16-is-invariant:
62933         * modules/unicase/u16-is-lowercase, modules/unicase/u16-is-titlecase:
62934         * modules/unicase/u16-is-uppercase, modules/unicase/u16-prefix-context:
62935         * modules/unicase/u16-suffix-context, modules/unicase/u16-tolower:
62936         * modules/unicase/u16-totitle, modules/unicase/u16-toupper:
62937         * modules/unicase/u32-casecmp, modules/unicase/u32-casecoll:
62938         * modules/unicase/u32-casefold, modules/unicase/u32-casemap:
62939         * modules/unicase/u32-casexfrm, modules/unicase/u32-ct-casefold:
62940         * modules/unicase/u32-ct-tolower, modules/unicase/u32-ct-totitle:
62941         * modules/unicase/u32-ct-toupper, modules/unicase/u32-is-cased:
62942         * modules/unicase/u32-is-casefolded, modules/unicase/u32-is-invariant:
62943         * modules/unicase/u32-is-lowercase, modules/unicase/u32-is-titlecase:
62944         * modules/unicase/u32-is-uppercase, modules/unicase/u32-prefix-context:
62945         * modules/unicase/u32-suffix-context, modules/unicase/u32-tolower:
62946         * modules/unicase/u32-totitle, modules/unicase/u32-toupper:
62947         * modules/unicase/u8-casecmp, modules/unicase/u8-casecoll:
62948         * modules/unicase/u8-casefold, modules/unicase/u8-casemap:
62949         * modules/unicase/u8-casexfrm, modules/unicase/u8-ct-casefold:
62950         * modules/unicase/u8-ct-tolower, modules/unicase/u8-ct-totitle:
62951         * modules/unicase/u8-ct-toupper, modules/unicase/u8-is-cased:
62952         * modules/unicase/u8-is-casefolded, modules/unicase/u8-is-invariant:
62953         * modules/unicase/u8-is-lowercase, modules/unicase/u8-is-titlecase:
62954         * modules/unicase/u8-is-uppercase, modules/unicase/u8-prefix-context:
62955         * modules/unicase/u8-suffix-context, modules/unicase/u8-tolower:
62956         * modules/unicase/u8-totitle, modules/unicase/u8-toupper:
62957         * modules/unicase/ulc-casecmp, modules/unicase/ulc-casecoll:
62958         * modules/unicase/ulc-casexfrm, modules/unicodeio:
62959         * modules/uniconv/base, modules/uniconv/u16-conv-from-enc:
62960         * modules/uniconv/u16-conv-to-enc:
62961         * modules/uniconv/u16-strconv-from-enc:
62962         * modules/uniconv/u16-strconv-from-locale:
62963         * modules/uniconv/u16-strconv-to-enc:
62964         * modules/uniconv/u16-strconv-to-locale:
62965         * modules/uniconv/u32-conv-from-enc, modules/uniconv/u32-conv-to-enc:
62966         * modules/uniconv/u32-strconv-from-enc:
62967         * modules/uniconv/u32-strconv-from-locale:
62968         * modules/uniconv/u32-strconv-to-enc:
62969         * modules/uniconv/u32-strconv-to-locale:
62970         * modules/uniconv/u8-conv-from-enc, modules/uniconv/u8-conv-to-enc:
62971         * modules/uniconv/u8-strconv-from-enc:
62972         * modules/uniconv/u8-strconv-from-locale:
62973         * modules/uniconv/u8-strconv-to-enc:
62974         * modules/uniconv/u8-strconv-to-locale, modules/unictype/base:
62975         * modules/unictype/bidicategory-all:
62976         * modules/unictype/bidicategory-byname:
62977         * modules/unictype/bidicategory-name, modules/unictype/bidicategory-of:
62978         * modules/unictype/bidicategory-test, modules/unictype/bidiclass-all:
62979         * modules/unictype/bidiclass-byname:
62980         * modules/unictype/bidiclass-longname, modules/unictype/bidiclass-name:
62981         * modules/unictype/bidiclass-of, modules/unictype/bidiclass-test:
62982         * modules/unictype/block-all, modules/unictype/block-list:
62983         * modules/unictype/block-of, modules/unictype/block-test:
62984         * modules/unictype/category-C, modules/unictype/category-Cc:
62985         * modules/unictype/category-Cf, modules/unictype/category-Cn:
62986         * modules/unictype/category-Co, modules/unictype/category-Cs:
62987         * modules/unictype/category-L, modules/unictype/category-LC:
62988         * modules/unictype/category-Ll, modules/unictype/category-Lm:
62989         * modules/unictype/category-Lo, modules/unictype/category-Lt:
62990         * modules/unictype/category-Lu, modules/unictype/category-M:
62991         * modules/unictype/category-Mc, modules/unictype/category-Me:
62992         * modules/unictype/category-Mn, modules/unictype/category-N:
62993         * modules/unictype/category-Nd, modules/unictype/category-Nl:
62994         * modules/unictype/category-No, modules/unictype/category-P:
62995         * modules/unictype/category-Pc, modules/unictype/category-Pd:
62996         * modules/unictype/category-Pe, modules/unictype/category-Pf:
62997         * modules/unictype/category-Pi, modules/unictype/category-Po:
62998         * modules/unictype/category-Ps, modules/unictype/category-S:
62999         * modules/unictype/category-Sc, modules/unictype/category-Sk:
63000         * modules/unictype/category-Sm, modules/unictype/category-So:
63001         * modules/unictype/category-Z, modules/unictype/category-Zl:
63002         * modules/unictype/category-Zp, modules/unictype/category-Zs:
63003         * modules/unictype/category-all, modules/unictype/category-and:
63004         * modules/unictype/category-and-not, modules/unictype/category-byname:
63005         * modules/unictype/category-longname, modules/unictype/category-name:
63006         * modules/unictype/category-none, modules/unictype/category-of:
63007         * modules/unictype/category-or, modules/unictype/category-test:
63008         * modules/unictype/category-test-withtable:
63009         * modules/unictype/combining-class:
63010         * modules/unictype/combining-class-all:
63011         * modules/unictype/combining-class-byname:
63012         * modules/unictype/combining-class-longname:
63013         * modules/unictype/combining-class-name, modules/unictype/ctype-alnum:
63014         * modules/unictype/ctype-alpha, modules/unictype/ctype-blank:
63015         * modules/unictype/ctype-cntrl, modules/unictype/ctype-digit:
63016         * modules/unictype/ctype-graph, modules/unictype/ctype-lower:
63017         * modules/unictype/ctype-print, modules/unictype/ctype-punct:
63018         * modules/unictype/ctype-space, modules/unictype/ctype-upper:
63019         * modules/unictype/ctype-xdigit, modules/unictype/decimal-digit:
63020         * modules/unictype/digit, modules/unictype/joininggroup-all:
63021         * modules/unictype/joininggroup-byname:
63022         * modules/unictype/joininggroup-name, modules/unictype/joininggroup-of:
63023         * modules/unictype/joiningtype-all:
63024         * modules/unictype/joiningtype-byname:
63025         * modules/unictype/joiningtype-longname:
63026         * modules/unictype/joiningtype-name, modules/unictype/joiningtype-of:
63027         * modules/unictype/mirror, modules/unictype/numeric:
63028         * modules/unictype/property-all, modules/unictype/property-alphabetic:
63029         * modules/unictype/property-ascii-hex-digit:
63030         * modules/unictype/property-bidi-arabic-digit:
63031         * modules/unictype/property-bidi-arabic-right-to-left:
63032         * modules/unictype/property-bidi-block-separator:
63033         * modules/unictype/property-bidi-boundary-neutral:
63034         * modules/unictype/property-bidi-common-separator:
63035         * modules/unictype/property-bidi-control:
63036         * modules/unictype/property-bidi-embedding-or-override:
63037         * modules/unictype/property-bidi-eur-num-separator:
63038         * modules/unictype/property-bidi-eur-num-terminator:
63039         * modules/unictype/property-bidi-european-digit:
63040         * modules/unictype/property-bidi-hebrew-right-to-left:
63041         * modules/unictype/property-bidi-left-to-right:
63042         * modules/unictype/property-bidi-non-spacing-mark:
63043         * modules/unictype/property-bidi-other-neutral:
63044         * modules/unictype/property-bidi-pdf:
63045         * modules/unictype/property-bidi-segment-separator:
63046         * modules/unictype/property-bidi-whitespace:
63047         * modules/unictype/property-byname:
63048         * modules/unictype/property-case-ignorable:
63049         * modules/unictype/property-cased:
63050         * modules/unictype/property-changes-when-casefolded:
63051         * modules/unictype/property-changes-when-casemapped:
63052         * modules/unictype/property-changes-when-lowercased:
63053         * modules/unictype/property-changes-when-titlecased:
63054         * modules/unictype/property-changes-when-uppercased:
63055         * modules/unictype/property-combining:
63056         * modules/unictype/property-composite:
63057         * modules/unictype/property-currency-symbol:
63058         * modules/unictype/property-dash:
63059         * modules/unictype/property-decimal-digit:
63060         * modules/unictype/property-default-ignorable-code-point:
63061         * modules/unictype/property-deprecated:
63062         * modules/unictype/property-diacritic:
63063         * modules/unictype/property-extender:
63064         * modules/unictype/property-format-control:
63065         * modules/unictype/property-grapheme-base:
63066         * modules/unictype/property-grapheme-extend:
63067         * modules/unictype/property-grapheme-link:
63068         * modules/unictype/property-hex-digit:
63069         * modules/unictype/property-hyphen:
63070         * modules/unictype/property-id-continue:
63071         * modules/unictype/property-id-start:
63072         * modules/unictype/property-ideographic:
63073         * modules/unictype/property-ids-binary-operator:
63074         * modules/unictype/property-ids-trinary-operator:
63075         * modules/unictype/property-ignorable-control:
63076         * modules/unictype/property-iso-control:
63077         * modules/unictype/property-join-control:
63078         * modules/unictype/property-left-of-pair:
63079         * modules/unictype/property-line-separator:
63080         * modules/unictype/property-logical-order-exception:
63081         * modules/unictype/property-lowercase, modules/unictype/property-math:
63082         * modules/unictype/property-non-break:
63083         * modules/unictype/property-not-a-character:
63084         * modules/unictype/property-numeric:
63085         * modules/unictype/property-other-alphabetic:
63086         * modules/unictype/property-other-default-ignorable-code-point:
63087         * modules/unictype/property-other-grapheme-extend:
63088         * modules/unictype/property-other-id-continue:
63089         * modules/unictype/property-other-id-start:
63090         * modules/unictype/property-other-lowercase:
63091         * modules/unictype/property-other-math:
63092         * modules/unictype/property-other-uppercase:
63093         * modules/unictype/property-paired-punctuation:
63094         * modules/unictype/property-paragraph-separator:
63095         * modules/unictype/property-pattern-syntax:
63096         * modules/unictype/property-pattern-white-space:
63097         * modules/unictype/property-private-use:
63098         * modules/unictype/property-punctuation:
63099         * modules/unictype/property-quotation-mark:
63100         * modules/unictype/property-radical:
63101         * modules/unictype/property-sentence-terminal:
63102         * modules/unictype/property-soft-dotted:
63103         * modules/unictype/property-space:
63104         * modules/unictype/property-terminal-punctuation:
63105         * modules/unictype/property-test, modules/unictype/property-titlecase:
63106         * modules/unictype/property-unassigned-code-value:
63107         * modules/unictype/property-unified-ideograph:
63108         * modules/unictype/property-uppercase:
63109         * modules/unictype/property-variation-selector:
63110         * modules/unictype/property-white-space:
63111         * modules/unictype/property-xid-continue:
63112         * modules/unictype/property-xid-start:
63113         * modules/unictype/property-zero-width, modules/unictype/scripts:
63114         * modules/unictype/scripts-all, modules/unictype/syntax-c-ident:
63115         * modules/unictype/syntax-c-whitespace:
63116         * modules/unictype/syntax-java-ident:
63117         * modules/unictype/syntax-java-whitespace, modules/unigbrk/base:
63118         * modules/unigbrk/u16-grapheme-breaks:
63119         * modules/unigbrk/u16-grapheme-next, modules/unigbrk/u16-grapheme-prev:
63120         * modules/unigbrk/u32-grapheme-breaks:
63121         * modules/unigbrk/u32-grapheme-next, modules/unigbrk/u32-grapheme-prev:
63122         * modules/unigbrk/u8-grapheme-breaks, modules/unigbrk/u8-grapheme-next:
63123         * modules/unigbrk/u8-grapheme-prev, modules/unigbrk/uc-gbrk-prop:
63124         * modules/unigbrk/uc-is-grapheme-break:
63125         * modules/unigbrk/ulc-grapheme-breaks, modules/unilbrk/base:
63126         * modules/unilbrk/tables, modules/unilbrk/u16-possible-linebreaks:
63127         * modules/unilbrk/u16-width-linebreaks:
63128         * modules/unilbrk/u32-possible-linebreaks:
63129         * modules/unilbrk/u32-width-linebreaks:
63130         * modules/unilbrk/u8-possible-linebreaks:
63131         * modules/unilbrk/u8-width-linebreaks, modules/unilbrk/ulc-common:
63132         * modules/unilbrk/ulc-possible-linebreaks:
63133         * modules/unilbrk/ulc-width-linebreaks, modules/uniname/base:
63134         * modules/uniname/uniname, modules/uninorm/base:
63135         * modules/uninorm/canonical-decomposition:
63136         * modules/uninorm/compat-decomposition, modules/uninorm/composition:
63137         * modules/uninorm/decompose-internal, modules/uninorm/decomposing-form:
63138         * modules/uninorm/decomposition, modules/uninorm/decomposition-table:
63139         * modules/uninorm/filter, modules/uninorm/nfc, modules/uninorm/nfd:
63140         * modules/uninorm/nfkc, modules/uninorm/nfkd:
63141         * modules/uninorm/u16-normalize, modules/uninorm/u16-normcmp:
63142         * modules/uninorm/u16-normcoll, modules/uninorm/u16-normxfrm:
63143         * modules/uninorm/u32-normalize, modules/uninorm/u32-normcmp:
63144         * modules/uninorm/u32-normcoll, modules/uninorm/u32-normxfrm:
63145         * modules/uninorm/u8-normalize, modules/uninorm/u8-normcmp:
63146         * modules/uninorm/u8-normcoll, modules/uninorm/u8-normxfrm:
63147         * modules/unistdio/base, modules/unistdio/u-printf-args:
63148         * modules/unistdio/u16-asnprintf, modules/unistdio/u16-asprintf:
63149         * modules/unistdio/u16-printf-parse, modules/unistdio/u16-snprintf:
63150         * modules/unistdio/u16-sprintf, modules/unistdio/u16-u16-asnprintf:
63151         * modules/unistdio/u16-u16-asprintf, modules/unistdio/u16-u16-snprintf:
63152         * modules/unistdio/u16-u16-sprintf:
63153         * modules/unistdio/u16-u16-vasnprintf:
63154         * modules/unistdio/u16-u16-vasprintf:
63155         * modules/unistdio/u16-u16-vsnprintf:
63156         * modules/unistdio/u16-u16-vsprintf, modules/unistdio/u16-vasnprintf:
63157         * modules/unistdio/u16-vasprintf, modules/unistdio/u16-vsnprintf:
63158         * modules/unistdio/u16-vsprintf, modules/unistdio/u32-asnprintf:
63159         * modules/unistdio/u32-asprintf, modules/unistdio/u32-printf-parse:
63160         * modules/unistdio/u32-snprintf, modules/unistdio/u32-sprintf:
63161         * modules/unistdio/u32-u32-asnprintf:
63162         * modules/unistdio/u32-u32-asprintf, modules/unistdio/u32-u32-snprintf:
63163         * modules/unistdio/u32-u32-sprintf:
63164         * modules/unistdio/u32-u32-vasnprintf:
63165         * modules/unistdio/u32-u32-vasprintf:
63166         * modules/unistdio/u32-u32-vsnprintf:
63167         * modules/unistdio/u32-u32-vsprintf, modules/unistdio/u32-vasnprintf:
63168         * modules/unistdio/u32-vasprintf, modules/unistdio/u32-vsnprintf:
63169         * modules/unistdio/u32-vsprintf, modules/unistdio/u8-asnprintf:
63170         * modules/unistdio/u8-asprintf, modules/unistdio/u8-printf-parse:
63171         * modules/unistdio/u8-snprintf, modules/unistdio/u8-sprintf:
63172         * modules/unistdio/u8-u8-asnprintf, modules/unistdio/u8-u8-asprintf:
63173         * modules/unistdio/u8-u8-snprintf, modules/unistdio/u8-u8-sprintf:
63174         * modules/unistdio/u8-u8-vasnprintf, modules/unistdio/u8-u8-vasprintf:
63175         * modules/unistdio/u8-u8-vsnprintf, modules/unistdio/u8-u8-vsprintf:
63176         * modules/unistdio/u8-vasnprintf, modules/unistdio/u8-vasprintf:
63177         * modules/unistdio/u8-vsnprintf, modules/unistdio/u8-vsprintf:
63178         * modules/unistdio/ulc-asnprintf, modules/unistdio/ulc-asprintf:
63179         * modules/unistdio/ulc-fprintf, modules/unistdio/ulc-printf-parse:
63180         * modules/unistdio/ulc-snprintf, modules/unistdio/ulc-sprintf:
63181         * modules/unistdio/ulc-vasnprintf, modules/unistdio/ulc-vasprintf:
63182         * modules/unistdio/ulc-vfprintf, modules/unistdio/ulc-vsnprintf:
63183         * modules/unistdio/ulc-vsprintf, modules/unistr/base:
63184         * modules/unistr/u16-check, modules/unistr/u16-chr:
63185         * modules/unistr/u16-cmp, modules/unistr/u16-cmp2:
63186         * modules/unistr/u16-cpy, modules/unistr/u16-cpy-alloc:
63187         * modules/unistr/u16-endswith, modules/unistr/u16-mblen:
63188         * modules/unistr/u16-mbsnlen, modules/unistr/u16-mbtouc:
63189         * modules/unistr/u16-mbtouc-unsafe, modules/unistr/u16-mbtoucr:
63190         * modules/unistr/u16-move, modules/unistr/u16-next:
63191         * modules/unistr/u16-prev, modules/unistr/u16-set:
63192         * modules/unistr/u16-startswith, modules/unistr/u16-stpcpy:
63193         * modules/unistr/u16-stpncpy, modules/unistr/u16-strcat:
63194         * modules/unistr/u16-strchr, modules/unistr/u16-strcmp:
63195         * modules/unistr/u16-strcoll, modules/unistr/u16-strcpy:
63196         * modules/unistr/u16-strcspn, modules/unistr/u16-strdup:
63197         * modules/unistr/u16-strlen, modules/unistr/u16-strmblen:
63198         * modules/unistr/u16-strmbtouc, modules/unistr/u16-strncat:
63199         * modules/unistr/u16-strncmp, modules/unistr/u16-strncpy:
63200         * modules/unistr/u16-strnlen, modules/unistr/u16-strpbrk:
63201         * modules/unistr/u16-strrchr, modules/unistr/u16-strspn:
63202         * modules/unistr/u16-strstr, modules/unistr/u16-strtok:
63203         * modules/unistr/u16-to-u32, modules/unistr/u16-to-u8:
63204         * modules/unistr/u16-uctomb, modules/unistr/u32-check:
63205         * modules/unistr/u32-chr, modules/unistr/u32-cmp:
63206         * modules/unistr/u32-cmp2, modules/unistr/u32-cpy:
63207         * modules/unistr/u32-cpy-alloc, modules/unistr/u32-endswith:
63208         * modules/unistr/u32-mblen, modules/unistr/u32-mbsnlen:
63209         * modules/unistr/u32-mbtouc, modules/unistr/u32-mbtouc-unsafe:
63210         * modules/unistr/u32-mbtoucr, modules/unistr/u32-move:
63211         * modules/unistr/u32-next, modules/unistr/u32-prev:
63212         * modules/unistr/u32-set, modules/unistr/u32-startswith:
63213         * modules/unistr/u32-stpcpy, modules/unistr/u32-stpncpy:
63214         * modules/unistr/u32-strcat, modules/unistr/u32-strchr:
63215         * modules/unistr/u32-strcmp, modules/unistr/u32-strcoll:
63216         * modules/unistr/u32-strcpy, modules/unistr/u32-strcspn:
63217         * modules/unistr/u32-strdup, modules/unistr/u32-strlen:
63218         * modules/unistr/u32-strmblen, modules/unistr/u32-strmbtouc:
63219         * modules/unistr/u32-strncat, modules/unistr/u32-strncmp:
63220         * modules/unistr/u32-strncpy, modules/unistr/u32-strnlen:
63221         * modules/unistr/u32-strpbrk, modules/unistr/u32-strrchr:
63222         * modules/unistr/u32-strspn, modules/unistr/u32-strstr:
63223         * modules/unistr/u32-strtok, modules/unistr/u32-to-u16:
63224         * modules/unistr/u32-to-u8, modules/unistr/u32-uctomb:
63225         * modules/unistr/u8-check, modules/unistr/u8-chr:
63226         * modules/unistr/u8-cmp, modules/unistr/u8-cmp2, modules/unistr/u8-cpy:
63227         * modules/unistr/u8-cpy-alloc, modules/unistr/u8-endswith:
63228         * modules/unistr/u8-mblen, modules/unistr/u8-mbsnlen:
63229         * modules/unistr/u8-mbtouc, modules/unistr/u8-mbtouc-unsafe:
63230         * modules/unistr/u8-mbtoucr, modules/unistr/u8-move:
63231         * modules/unistr/u8-next, modules/unistr/u8-prev:
63232         * modules/unistr/u8-set, modules/unistr/u8-startswith:
63233         * modules/unistr/u8-stpcpy, modules/unistr/u8-stpncpy:
63234         * modules/unistr/u8-strcat, modules/unistr/u8-strchr:
63235         * modules/unistr/u8-strcmp, modules/unistr/u8-strcoll:
63236         * modules/unistr/u8-strcpy, modules/unistr/u8-strcspn:
63237         * modules/unistr/u8-strdup, modules/unistr/u8-strlen:
63238         * modules/unistr/u8-strmblen, modules/unistr/u8-strmbtouc:
63239         * modules/unistr/u8-strncat, modules/unistr/u8-strncmp:
63240         * modules/unistr/u8-strncpy, modules/unistr/u8-strnlen:
63241         * modules/unistr/u8-strpbrk, modules/unistr/u8-strrchr:
63242         * modules/unistr/u8-strspn, modules/unistr/u8-strstr:
63243         * modules/unistr/u8-strtok, modules/unistr/u8-to-u16:
63244         * modules/unistr/u8-to-u32, modules/unistr/u8-uctomb, modules/unitypes:
63245         * modules/uniwbrk/base, modules/uniwbrk/table:
63246         * modules/uniwbrk/u16-wordbreaks, modules/uniwbrk/u32-wordbreaks:
63247         * modules/uniwbrk/u8-wordbreaks, modules/uniwbrk/ulc-wordbreaks:
63248         * modules/uniwbrk/wordbreak-property, modules/uniwidth/base:
63249         * modules/uniwidth/u16-strwidth, modules/uniwidth/u16-width:
63250         * modules/uniwidth/u32-strwidth, modules/uniwidth/u32-width:
63251         * modules/uniwidth/u8-strwidth, modules/uniwidth/u8-width:
63252         * modules/uniwidth/width, modules/utf16-ucs4:
63253         * modules/utf16-ucs4-unsafe, modules/utf8-ucs4:
63254         * modules/utf8-ucs4-unsafe:
63255         Change maintainer from Bruno Haible to Daiki Ueno.
63256         This is my guess at the libunistring modules; please feel free
63257         to fix if I guessed incorrectly.
63258         * modules/accept4, modules/acl, modules/acos, modules/acosf:
63259         * modules/alignof, modules/amemxfrm, modules/ansi-c++-opt:
63260         * modules/areadlink, modules/array-list, modules/array-mergesort:
63261         * modules/array-oset, modules/asin, modules/asinf, modules/astrxfrm:
63262         * modules/atan, modules/atan2, modules/atan2f, modules/atanf:
63263         * modules/avltree-list, modules/avltree-oset, modules/avltreehash-list:
63264         * modules/binary-io, modules/bison-i18n, modules/btowc:
63265         * modules/c-ctype, modules/c-strcase, modules/c-strcaseeq:
63266         * modules/c-strcasestr, modules/c-strstr, modules/calloc-posix:
63267         * modules/canonicalize-lgpl, modules/careadlinkat, modules/carray-list:
63268         * modules/cbrt, modules/cbrt-ieee, modules/cbrtf, modules/cbrtf-ieee:
63269         * modules/cbrtl, modules/cbrtl-ieee, modules/ceil, modules/ceil-ieee:
63270         * modules/ceilf, modules/ceilf-ieee, modules/ceill, modules/ceill-ieee:
63271         * modules/chdir, modules/classpath, modules/clean-temp, modules/close:
63272         * modules/closedir, modules/concat-filename, modules/copy-file:
63273         * modules/copysign, modules/copysignf, modules/copysignl, modules/cos:
63274         * modules/cosf, modules/cosh, modules/coshf, modules/csharpcomp:
63275         * modules/csharpcomp-script, modules/csharpexec:
63276         * modules/csharpexec-script, modules/ctype, modules/diffseq:
63277         * modules/dprintf, modules/dprintf-posix, modules/dup:
63278         * modules/dup2-obsolete, modules/dup3, modules/duplocale:
63279         * modules/eealloc, modules/environ, modules/erf, modules/erfc:
63280         * modules/errno, modules/execute, modules/exp, modules/exp-ieee:
63281         * modules/exp2, modules/exp2-ieee, modules/exp2f, modules/exp2f-ieee:
63282         * modules/exp2l, modules/exp2l-ieee, modules/expf, modules/expf-ieee:
63283         * modules/expl, modules/expl-ieee, modules/expm1, modules/expm1-ieee:
63284         * modules/expm1f, modules/expm1f-ieee, modules/expm1l:
63285         * modules/expm1l-ieee, modules/fabs, modules/fabs-ieee, modules/fabsf:
63286         * modules/fabsf-ieee, modules/fabsl, modules/fabsl-ieee:
63287         * modules/fatal-signal, modules/fbufmode, modules/fchdir:
63288         * modules/fclose, modules/fd-hook, modules/fdopen, modules/filename:
63289         * modules/findprog, modules/findprog-lgpl, modules/floor:
63290         * modules/floor-ieee, modules/floorf, modules/floorf-ieee:
63291         * modules/floorl, modules/floorl-ieee, modules/fma, modules/fma-ieee:
63292         * modules/fmaf, modules/fmaf-ieee, modules/fmal, modules/fmal-ieee:
63293         * modules/fmod, modules/fmod-ieee, modules/fmodf, modules/fmodf-ieee:
63294         * modules/fmodl, modules/fmodl-ieee, modules/fopen, modules/fpieee:
63295         * modules/fprintf-posix, modules/fpucw, modules/fpurge:
63296         * modules/freadable, modules/freadahead, modules/freadptr:
63297         * modules/freadseek, modules/freopen, modules/frexp:
63298         * modules/frexp-ieee, modules/frexp-nolibm, modules/frexpf:
63299         * modules/frexpf-ieee, modules/frexpl, modules/frexpl-ieee:
63300         * modules/frexpl-nolibm, modules/fseek, modules/fseeko:
63301         * modules/fseterr, modules/fstat, modules/fstrcmp, modules/ftell:
63302         * modules/ftello, modules/full-read, modules/full-write:
63303         * modules/fwritable, modules/fwriteerror, modules/gcd:
63304         * modules/get-rusage-as, modules/get-rusage-data:
63305         * modules/getdtablesize, modules/getrusage, modules/gettext:
63306         * modules/gettext-h, modules/git-merge-changelog, modules/gperf:
63307         * modules/grantpt, modules/havelib, modules/host-cpu-c-abi:
63308         * modules/hostent, modules/hypot, modules/hypot-ieee, modules/hypotf:
63309         * modules/hypotf-ieee, modules/hypotl, modules/hypotl-ieee:
63310         * modules/iconv, modules/iconv-h, modules/iconv_open:
63311         * modules/iconv_open-utf, modules/idpriv-drop, modules/idpriv-droptemp:
63312         * modules/ilogb, modules/ilogbf, modules/ilogbl, modules/imaxabs:
63313         * modules/imaxdiv, modules/integer_length, modules/integer_length_l:
63314         * modules/integer_length_ll, modules/ioctl, modules/isatty:
63315         * modules/isblank, modules/isnand, modules/isnand-nolibm:
63316         * modules/isnanf, modules/isnanf-nolibm, modules/isnanl:
63317         * modules/isnanl-nolibm, modules/iswblank, modules/iswctype:
63318         * modules/j0, modules/j1, modules/javacomp, modules/javacomp-script:
63319         * modules/javaexec, modules/javaexec-script, modules/javaversion:
63320         * modules/jn, modules/langinfo, modules/ldd, modules/ldexp:
63321         * modules/ldexp-ieee, modules/ldexpf, modules/ldexpf-ieee:
63322         * modules/ldexpl, modules/ldexpl-ieee, modules/lgamma:
63323         * modules/lib-symbol-visibility, modules/libsigsegv:
63324         * modules/linked-list, modules/linkedhash-list, modules/list:
63325         * modules/localcharset, modules/locale, modules/localeconv:
63326         * modules/localename, modules/lock, modules/log, modules/log-ieee:
63327         * modules/log10, modules/log10-ieee, modules/log10f:
63328         * modules/log10f-ieee, modules/log10l, modules/log10l-ieee:
63329         * modules/log1p, modules/log1p-ieee, modules/log1pf:
63330         * modules/log1pf-ieee, modules/log1pl, modules/log1pl-ieee:
63331         * modules/log2, modules/log2-ieee, modules/log2f, modules/log2f-ieee:
63332         * modules/log2l, modules/log2l-ieee, modules/logb, modules/logb-ieee:
63333         * modules/logbf, modules/logbf-ieee, modules/logbl, modules/logbl-ieee:
63334         * modules/logf, modules/logf-ieee, modules/login_tty:
63335         * modules/logl-ieee, modules/malloc-posix, modules/malloca:
63336         * modules/mbchar, modules/mbfile, modules/mbiter, modules/mbmemcasecmp:
63337         * modules/mbmemcasecoll, modules/mbrlen, modules/mbrtowc:
63338         * modules/mbscasecmp, modules/mbscasestr, modules/mbschr:
63339         * modules/mbscspn, modules/mbsinit, modules/mbslen:
63340         * modules/mbsncasecmp, modules/mbsnlen, modules/mbsnrtowcs:
63341         * modules/mbspbrk, modules/mbspcasecmp, modules/mbsrchr:
63342         * modules/mbsrtowcs, modules/mbssep, modules/mbsspn, modules/mbsstr:
63343         * modules/mbstok_r, modules/mbswidth, modules/mbtowc, modules/mbuiter:
63344         * modules/memchr-obsolete, modules/memcmp2, modules/minmax:
63345         * modules/mkdtemp, modules/mkostemp, modules/mktime-internal:
63346         * modules/modf, modules/modf-ieee, modules/modff, modules/modff-ieee:
63347         * modules/modfl, modules/modfl-ieee, modules/msvc-inval:
63348         * modules/msvc-nothrow, modules/multiarch, modules/nextafter:
63349         * modules/nl_langinfo, modules/no-c++, modules/nocrash:
63350         * modules/nonblocking, modules/open, modules/opendir, modules/openmp:
63351         * modules/oset, modules/pclose, modules/pipe, modules/pipe-filter-gi:
63352         * modules/pipe-filter-ii, modules/pipe2, modules/poll-h:
63353         * modules/posix_spawn, modules/posix_spawn-internal:
63354         * modules/posix_spawn_file_actions_addclose:
63355         * modules/posix_spawn_file_actions_adddup2:
63356         * modules/posix_spawn_file_actions_addopen:
63357         * modules/posix_spawn_file_actions_destroy:
63358         * modules/posix_spawn_file_actions_init:
63359         * modules/posix_spawnattr_destroy, modules/posix_spawnattr_getflags:
63360         * modules/posix_spawnattr_getpgroup:
63361         * modules/posix_spawnattr_getschedparam:
63362         * modules/posix_spawnattr_getschedpolicy:
63363         * modules/posix_spawnattr_getsigdefault:
63364         * modules/posix_spawnattr_getsigmask, modules/posix_spawnattr_init:
63365         * modules/posix_spawnattr_setflags, modules/posix_spawnattr_setpgroup:
63366         * modules/posix_spawnattr_setschedparam:
63367         * modules/posix_spawnattr_setschedpolicy:
63368         * modules/posix_spawnattr_setsigdefault:
63369         * modules/posix_spawnattr_setsigmask, modules/posix_spawnp:
63370         * modules/pow, modules/powf, modules/printf-frexp:
63371         * modules/printf-frexpl, modules/printf-posix, modules/printf-safe:
63372         * modules/progname, modules/propername, modules/pselect:
63373         * modules/pthread_sigmask, modules/ptsname, modules/ptsname_r:
63374         * modules/qacl, modules/quotearg-simple, modules/raise, modules/random:
63375         * modules/rbtree-list, modules/rbtree-oset, modules/rbtreehash-list:
63376         * modules/read, modules/readdir, modules/readlink:
63377         * modules/realloc-posix, modules/regex-quote, modules/relocatable-lib:
63378         * modules/relocatable-lib-lgpl, modules/relocatable-perl:
63379         * modules/relocatable-prog, modules/relocatable-prog-wrapper:
63380         * modules/relocatable-script, modules/remainder:
63381         * modules/remainder-ieee, modules/remainderf, modules/remainderf-ieee:
63382         * modules/remainderl, modules/remainderl-ieee, modules/rewinddir:
63383         * modules/rint, modules/rint-ieee, modules/rintf, modules/rintf-ieee:
63384         * modules/rintl, modules/rintl-ieee, modules/round-ieee:
63385         * modules/roundf-ieee, modules/roundl-ieee, modules/safe-read:
63386         * modules/safe-write, modules/sched, modules/servent, modules/setenv:
63387         * modules/setlocale, modules/sh-quote, modules/shutdown:
63388         * modules/signal, modules/signbit, modules/sigpipe:
63389         * modules/sigpipe-die, modules/sigprocmask, modules/sin, modules/sinf:
63390         * modules/sinh, modules/sinhf, modules/size_max, modules/sleep:
63391         * modules/snippet/arg-nonnull, modules/snippet/c++defs:
63392         * modules/snippet/link-warning, modules/snippet/unused-parameter:
63393         * modules/snprintf, modules/snprintf-posix, modules/spawn:
63394         * modules/spawn-pipe, modules/sprintf-posix, modules/sqrt:
63395         * modules/sqrt-ieee, modules/sqrtf, modules/sqrtf-ieee:
63396         * modules/sqrtl-ieee, modules/stdalign, modules/stdarg:
63397         * modules/stdbool, modules/stpcpy, modules/stpncpy, modules/strcase:
63398         * modules/strcasestr, modules/strcasestr-simple, modules/strcspn:
63399         * modules/streq, modules/strerror_r-posix, modules/striconv:
63400         * modules/striconveh, modules/striconveha, modules/strncat:
63401         * modules/strnlen1, modules/strpbrk, modules/strtod-obsolete:
63402         * modules/sublist, modules/sys_resource, modules/sys_utsname:
63403         * modules/sys_wait, modules/system-posix, modules/system-quote:
63404         * modules/tan, modules/tanf, modules/tanh, modules/tanhf:
63405         * modules/tcgetsid, modules/termios, modules/threadlib, modules/tls:
63406         * modules/tmpdir, modules/towctrans, modules/trunc, modules/trunc-ieee:
63407         * modules/truncf, modules/truncf-ieee, modules/truncl:
63408         * modules/truncl-ieee, modules/ttyname_r, modules/uname:
63409         * modules/unlockpt, modules/unsetenv, modules/vasnprintf:
63410         * modules/vasnprintf-posix, modules/vasprintf, modules/vasprintf-posix:
63411         * modules/vdprintf, modules/vdprintf-posix, modules/vfprintf-posix:
63412         * modules/vfscanf, modules/vma-iter, modules/vprintf-posix:
63413         * modules/vscanf, modules/vsnprintf-posix, modules/vsprintf-posix:
63414         * modules/wait-process, modules/waitpid, modules/wcpcpy:
63415         * modules/wcpncpy, modules/wcrtomb, modules/wcscasecmp, modules/wcscat:
63416         * modules/wcschr, modules/wcscmp, modules/wcscoll, modules/wcscpy:
63417         * modules/wcscspn, modules/wcsdup, modules/wcslen, modules/wcsncasecmp:
63418         * modules/wcsncat, modules/wcsncmp, modules/wcsncpy, modules/wcsnlen:
63419         * modules/wcsnrtombs, modules/wcspbrk, modules/wcsrchr:
63420         * modules/wcsrtombs, modules/wcsspn, modules/wcsstr, modules/wcstok:
63421         * modules/wcswidth, modules/wcsxfrm, modules/wctob, modules/wctomb:
63422         * modules/wctrans, modules/wctype, modules/wcwidth, modules/wmemchr:
63423         * modules/wmemcmp, modules/wmemcpy, modules/wmemmove, modules/wmemset:
63424         * modules/write, modules/xconcat-filename, modules/xlist:
63425         * modules/xmalloca, modules/xoset, modules/xprintf-posix:
63426         * modules/xreadlink, modules/xsetenv, modules/xsize, modules/xstriconv:
63427         * modules/xstriconveh, modules/xsublist, modules/xvasprintf-posix:
63428         * modules/y0, modules/y1, modules/yn:
63429         Remove Bruno Haible as maintainer; if he's the sole maintainer,
63430         change the maintainer to 'all'.  Let's hope someone volunteers.
63432 2014-06-27  Paul Eggert  <eggert@cs.ucla.edu>
63434         mktime: merge #if/#ifdef usage from glibc
63435         * lib/mktime.c: Use "#if defined DEBUG && DEBUG", not "#if DEBUG",
63436         as that works with both Glibc's and Gnulib's style.
63437         See thread starting at Siddhesh Poyarekar's bug report at:
63438         http://lists.gnu.org/r/bug-gnulib/2014-06/msg00102.html
63440 2014-06-20  Alfred M. Szmidt  <ams@gnu.org>
63442         git-version-gen: improve option descriptions
63443         * build-aux/git-version-gen: Mention that --prefix and --fallback
63444         have a mandatory argument.
63446 2014-06-19  Paul Eggert  <eggert@penguin.cs.ucla.edu>
63448         regex: fix memory leak in compiler
63449         Fix by Andreas Schwab in:
63450         https://sourceware.org/ml/libc-alpha/2014-06/msg00462.html
63451         * lib/regcomp.c (parse_expression): Deallocate partially
63452         constructed tree before returning error.
63454         regex: merge patch from libc
63455         2014-02-12  Joseph Myers  <joseph@codesourcery.com>
63456         Combine __USE_BSD and __USE_SVID into __USE_MISC.
63457         * lib/regex.h [__USE_BSD]: Change condition to [__USE_MISC].
63459 2014-06-17  Paul Eggert  <eggert@cs.ucla.edu>
63461         acl: port to gcc -Wredundant-decls
63462         From a request by Dmitry Antipov in:
63463         http://lists.gnu.org/r/emacs-devel/2014-06/msg00263.html
63464         * lib/acl.h (_GL_ACL_H): New macro.  Protect entire contents with
63465         "#ifndef _GL_ACL_H".
63467 2014-06-11  Bruce Korb  <bkorb@gnu.org>
63468         Jim Meyering  <meyering@fb.com>
63470         parse-duration: eliminate 68-year duration limit
63471         * lib/parse-duration.c: Include "intprops.h".
63472         (TIME_MAX): Rename to MAX_DURATION and define to
63473         TYPE_MAXIMUM(time_t).
63474         * modules/parse-duration (Depends-on): Add intprops.
63475         Reported by Jonas 'Sortie' Termansen.
63477 2014-06-14  Paul Eggert  <eggert@cs.ucla.edu>
63479         pthread: don't assume AC_CANONICAL_HOST, port better to Solaris, etc.
63480         * modules/pthread (Depends-on): Add 'extensions', as it defines
63481         _POSIX_PTHREAD_SEMANTICS, which is needed on Solaris.
63482         (configure.ac-early): New section.
63483         * m4/pthread.m4 (gl_PTHREAD_CHECK): Revert previous change, as
63484         it is no longer needed.
63486 2014-06-14  Pádraig Brady  <P@draigBrady.com>
63488         pthread: define thread-safe macros on some platforms
63489         * m4/pthread.m4 (gl_PTHREAD_CHECK): Define macros needed
63490         for thread-safe operation on some platforms.
63492 2014-06-13  Paul Eggert  <eggert@cs.ucla.edu>
63494         regex: don't be multithreaded if USE_UNLOCKED_IO.
63495         Problem reported by Michael Felt in: http://bugs.gnu.org/17773
63496         * lib/regex_internal.h: Do not use multithreaded version if
63497         USE_UNLOCKED_IO is defined.  This is a hack, but it works
63498         around a porting bug with coreutils 8.22 on AIX 7.1.
63500 2014-06-11  Daiki Ueno  <ueno@gnu.org>
63502         gettext: update macros to version 0.19
63503         * m4/intl.m4, m4/po.m4: Update from gettext-0.19.  In particular,
63504         depend on gl_EXTERN_INLINE and drop support for older Bison
63505         versions.
63507 2014-06-10  Pádraig Brady  <P@draigBrady.com>
63509         select,poll: fix console handle check on windows 8
63510         lib/poll.c (IsConsoleHandle): Change from testing the lower
63511         2 bits of the handle to the more expensive but accurate syscall.
63512         lib/select.c: Likewise.
63514 2014-06-10  Eli Zaretskii  <eliz@gnu.org>
63516         select: fix waiting on anonymous pipes on MS-Windows
63517         * lib/select.c (rpl_select): Fall back to polling when select()
63518         indicates there is nothing to check, while due to the timeout not
63519         expiring, activity is indicated on one of the handles.
63520         Also clear the TIMEOUT argument if the timer does expire.
63522 2014-06-10  Eli Zaretskii  <eliz@gnu.org>
63524         times: fix to return non constant value on MS-Windows
63525         * lib/times.c (times): Don't use the process creation time,
63526         rather clock() which on windows returns the number of
63527         clock ticks since the process started.
63529 2014-06-09  Michael Goffioul  <michael.goffioul@gmail.com>
63531         isatty: fix to work on windows 8
63532         * lib/isatty.c (IsConsoleHandle): Change from testing the lower
63533         2 bits of the handle to the more expensive but accurate syscall.
63535 2014-06-07  Paul Eggert  <eggert@cs.ucla.edu>
63537         maint: fix typo in fdl.texi
63538         * doc/fdl.texi: Fix typo (missing '@').
63539         Somehow this was in fdl.texi but not fdl-1.3.texi.
63541 2014-06-06  Ben Walton  <bdwalton@gmail.com>
63543         mountlist: avoid hasmntopt const type warning on solaris
63544         * lib/mountlist.c: Solaris defines the OPT param of hasmntopt()
63545         with char * instead of const char *.  Passing the constant string
63546         "ignore" generates a compiler warning.  For Solaris cast MNT_IGNORE
63547         to avoid the warning.
63549 2014-06-04  Eric Blake  <eblake@redhat.com>
63551         maintainer-makefile: delete obsolete code
63552         * top/maint.mk (build_aux): Drop old code, as threatened.
63554         maintainer-makefile: avoid spurious error messages
63555         * top/maint.mk (syntax-check): Guard definition and use of
63556         $(shell) by whether Makefile is present.
63558 2014-06-03  Ben Walton  <bdwalton@gmail.com>
63560         rename: avoid unused-but-set-variable compiler warning
63561         * lib/rename.c (rpl_rename):  In the non-Win32 variant of rpl_rename,
63562         it is possible that dst_exists may be set but not used.  Mark it with
63563         the unused attribute to avoid compiler warnings.
63565 2014-06-02  Ben Walton  <bdwalton@gmail.com>
63567         rename: mark a label as potentially unused
63568         * lib/rename.c (rpl_rename): Avoid compiler warnings seen on Solaris,
63569         by marking the out label as potentially unused.
63570         * m4/gnulib-common.m4: Mention the need for the trailing ; for C++.
63572 2014-06-01  Paul Eggert  <eggert@cs.ucla.edu>
63574         gnulib-common.m4: Fix typo in _GL_UNUSED_LABEL.
63575         * m4/gnulib-common.m4 (_GL_UNUSED_LABEL): Omit trailing semicolon.
63577 2014-06-02  Ben Walton  <bdwalton@gmail.com>
63579         acl: apply pure attribute to two functions
63580         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial):
63581         Mark as "pure" as flagged by gcc 4.9 on Solaris 10.
63583 2014-06-01  Pádraig Brady  <P@draigBrady.com>
63585         gnulib-common.m4: add _GL_UNUSED_LABEL
63586         * m4/gnulib-common.m4: Add _GL_UNUSED_LABEL which is similar to
63587         _GL_UNUSED, but handles g++ < 4.5 not supporting this syntax.
63589 2014-05-31  Paul Eggert  <eggert@cs.ucla.edu>
63591         dup2, fcntl, fcntl-h: port to AIX 7.1
63592         This fixes some porting problems discovered when testing the latest
63593         grep snapshot on AIX 7.1.  I don't think if fixes any bugs
63594         in grep but it could be important for other applications.
63595         * doc/posix-functions/dup2.texi:
63596         * doc/posix-functions/fcntl.texi:
63597         * doc/posix-headers/fcntl.texi:
63598         Document AIX bugs.
63599         * lib/fcntl.in.h (O_CLOEXEC, O_NOFOLLOW, O_TTY_INIT) [_AIX]:
63600         Define to 0 if outside 'int' range.
63601         * m4/dup2.m4 (gl_FUNC_DUP2):
63602         * m4/fcntl.m4 (gl_FUNC_FCNTL):
63603         Check for getdtablesize.  If it's available, test a value just
63604         outside its range instead of testing 1000000.  When cross-compiling,
63605         guess that AIX will fail this improved test.
63607 2014-05-30  Paul Eggert  <eggert@cs.ucla.edu>
63609         printf, config.rpath: Port to FreeBSD 10.
63610         Problem reported by Tijl Coosemans in:
63611         http://lists.gnu.org/r/bug-gnulib/2014-05/msg00078.html
63612         * build-aux/config.rpath (hardcode_libdir_flag_spec)
63613         (hardcode_direct): Simplify FreeBSD configuration.
63614         (library_names_spec): Don't mishandle FreeBSD 10+.
63615         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE)
63616         (gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_F)
63617         (gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99)
63618         (gl_SNPRINTF_DIRECTIVE_N, gl_VSNPRINTF_ZEROSIZE_C99):
63619         Don't mishandle FreeBSD 10+ when cross-compiling.
63621         ftoastr: work around compiler bug in IBM xlc 12.1
63622         * lib/ftoastr.h (_GL_FLT_PREC_BOUND, _GL_DBL_PREC_BOUND)
63623         (_GL_LDBL_PREC_BOUND): Make these macros, not enums, to work
63624         around a compiler bug in IBM xlc 12.1.0.0: it complains
63625         '"ftoastr.c", line 80.37: 1506-045 (S) Undeclared identifier
63626         _GL_FLT_PREC_BOUND.'
63628 2014-05-30  Kieran Colford  <colfordk@gmail.com>
63630         valgrind-tests: fixed misleading help message
63631         * m4/valgrind-tests.m4: The help message generated by configure
63632         implied that valgrind was disabled by default, which it wasn't.
63633         Adjusted the help message using s/enable/disable/ to clarify.
63635 2014-05-30  Ulrich Weigand  <uweigand@de.ibm.com>
63637         isfinite, isinf, isnan tests: fix for little-endian PowerPC
63638         * tests/test-isfinite.c (test_isfinitel): Only manipulate the
63639         first double of a PowerPC "double double" pair.
63640         * tests/test-isinf.c (test_isinfl): Likewise.
63641         * tests/test-isnan.c (test_long_double): Likewise.
63642         * tests/test-isnanl.h (main): Likewise.
63643         * tests/test-signbit.c (test_signbitl): Likewise.
63645 2014-05-29  Paul Eggert  <eggert@cs.ucla.edu>
63647         exclude-tests: port to AIX 7.1
63648         * modules/exclude-tests (test_exclude_LDADD): Add $(LIBTHREAD).
63649         Needed on AIX 7.1 with xlc V12.1, otherwise it won't link because
63650         the regex code uses locks.
63652 2014-05-28  Paul Eggert  <eggert@cs.ucla.edu>
63654         pthread_sigmask, timer-time: use gl_THREADLIB only if needed
63655         Without this fix, Emacs would sometimes call sigprocmask instead
63656         of pthread_sigmask, which is a no-no in multithreaded applications.
63657         Problem reported by Jorgen Schaefer in <http://bugs.gnu.org/17561>.
63658         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
63659         Suppress check for pthread_sigmask working without -lpthread if
63660         the application always links with -lpthread.  Do not link with
63661         $LIBMULTITHREAD if gl_THREADLIB is not defined.
63662         * m4/timer_time.m4 (gl_TIMER_TIME):
63663         Require gl_THREADLIB only if it is defined.  Do not append
63664         $LIBMULTITHREAD to LIB_TIMER_TIME if gl_THREADLIB is not defined.
63666 2014-05-27  Sylvain Beucler  <beuc@beuc.net>.
63668         gnulib-tool: wget translations using --no-verbose rather than --quiet
63669         This allows the user to see error messages if any (--quiet hides them)
63670         * gnulib-tool: Invoke wget with --no-verbose, rather than --quiet.
63672 2014-05-27  Sylvain Beucler  <beuc@beuc.net>
63674         gnulib-tool: adjust translation wget to avoid a https redirection
63675         Context: http://translationproject.org/latest/gnulib redirects to
63676            https://translationproject.org/latest/gnulib/
63677         Rationale: if the user falls back to wget, she doesn't have rsync and
63678         is probably in a minimal build environment, where packages such as
63679         'ca-certificates' are missing as well, resulting in a failed (and
63680         difficult to detect since ignored) translation initial fetch.
63681         Consequently let's avoid https if possible, and add the missing
63682         trailing slash.  This also avoids an unnecessary 302 redirection.
63683         * gnulib-tool: Add trailing slash to gnulib URL.
63685 2014-05-22  Pádraig Brady  <P@draigBrady.com>
63687         getlogin_r-tests: check return value rather than errno
63688         * tests/test-getlogin_r.c (main): As per POSIX we should be
63689         verifying the return value from getlogin_r() rather than errno.
63691 2014-05-22  Pádraig Brady  <P@draigBrady.com>
63693         getlogin_r-tests: fix various issues in recent change
63694         * tests/test-getlogin_r.c: Include required headers that were
63695         missed in recent commit eec20b4e.
63696         Also consistently check the errno rather than the return value from
63697         getlogin_r as POSIX only specifies that non zero is returned on error.
63698         * modules/getlogin_r-tests (configure.ac): Add the check for ttyname().
63700 2014-05-21  Paul Eggert  <eggert@cs.ucla.edu>
63702         fchdir: port 'open' and 'close' redefinitions to AIX 7.1
63703         * lib/chown.c, lib/clean-temp.c, lib/copy-file.c, lib/execute.c:
63704         * lib/fsusage.c, lib/gc-gnulib.c, lib/javacomp.c, lib/mountlist.c:
63705         * lib/openat-proc.c, lib/pagealign_alloc.c, lib/progreloc.c:
63706         * lib/spawn-pipe.c:
63707         Do not #undef 'open' and 'close'.  AIX 7 does '#define open open64'
63708         and then 'int open64(const char *, int, ...);', which means the
63709         declaration for 'open' gets lost if we later '#undef open'.
63710         Discovered while building grep pretest 2.18.151-1c770 on AIX 7.1,
63711         where the compilation reported the non-fatal error "In function
63712         'openat_proc_name' ... warning: implicit declaration of function
63713         'open'".  In this case the error is relatively harmless, but in
63714         other cases it might not be so minor.
63716 2014-05-20  Paul Eggert  <eggert@cs.ucla.edu>
63718         xalloc: don't potentially generate invalid code for xmemdup calls
63719         * lib/xalloc.h (xmemdup): Do not mark with _GL_ATTRIBUTE_ALLOC, as
63720         this function can initialize the newly-allocated storage with new
63721         pointers, which means this function is not malloc-like.  See:
63722         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56955
63724 2014-05-19  Pádraig Brady  <P@draigBrady.com>
63726         getlogin_r-tests: avoid false failure under sudo/ssh etc.
63727         * tests/test-getlogin_r.c (main): Sync up with test-getlogin.c
63728         changes from commit 97249cf29 to not depend on environment variables.
63730 2014-05-18  Pádraig Brady  <P@draigBrady.com>
63732         getlogin-tests: avoid false failure under cron
63733         * tests/test-getlogin.c (main): Avoid verifying errnos from ttyname()
63734         since that's not what's under test.  Centos 6 was seen to return
63735         EINVAL for ttyname() when run from cron.
63737 2014-05-16  Jim Meyering  <meyering@fb.com>
63739         mbrtowc.m4: fix a comment typo
63740         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Fix typo s/2/-2/ in
63741         emitted documentation string.
63743 2014-05-16  Paul Eggert  <eggert@cs.ucla.edu>
63745         mbrlen, mbrtowc: fix bug with empty input
63746         * lib/mbrtowc.c (rpl_mbrtowc) [MBRTOWC_EMPTY_INPUT_BUG]: Fix the bug.
63747         * m4/mbrlen.m4 (gl_MBRLEN_EMPTY_INPUT): New macro.  It's not used,
63748         so this is mainly for documentation.
63749         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT): New macro.
63750         (gl_FUNC_MBRTOWC): Use it.
63751         * tests/test-mbrtowc.c (main): Test for the bug.
63753 2014-05-15  Paul Eggert  <eggert@cs.ucla.edu>
63755         doc: document mbrtowc and mbrlen problem with empty input
63756         * doc/posix-functions/mbrlen.texi (mbrlen):
63757         * doc/posix-functions/mbrtowc.texi (mbrtowc):
63758         Document portability problem when the input string is empty.  See:
63759         https://sourceware.org/bugzilla/show_bug.cgi?id=16950
63761         doc: document exec* = spawn+exit bug with non-Cygwin Windows platforms
63762         Problem reported by Eli Zaretskii in:
63763         http://lists.gnu.org/r/bug-grep/2014-05/msg00118.html
63764         * doc/posix-functions/execl.texi (execl):
63765         * doc/posix-functions/execle.texi (execle):
63766         * doc/posix-functions/execlp.texi (execlp):
63767         * doc/posix-functions/execv.texi (execv):
63768         * doc/posix-functions/execve.texi (execve):
63769         * doc/posix-functions/execvp.texi (execvp):
63770         Mention spawn+exit problem on non-Cygwin Windows platforms.
63772 2014-05-14  Guilherme de Almeida Suckevicz  <guito.linux@gmail.com>
63774         getlogin-tests: avoid false failure under sudo/ssh etc.
63775         * modules/getlogin-tests (configure.ac): Check for ttyname().
63776         * tests/test-getlogin.c (main): Don't depend on environment variables
63777         to correlate with getlogin(), since sudo and ssh etc. can tamper
63778         with the LOGNAME and USER env vars.  Instead lookup the name from
63779         the uid associated with the stdin tty.
63781 2014-05-11  Paul Eggert  <eggert@cs.ucla.edu>
63783         mbsstr, quotearg, xstrtol: pacify IRIX 6.5 cc
63784         These were found when building the latest grep snapshot on IRIX 6.5.
63785         * lib/mbsstr.c (knuth_morris_pratt_multibyte): Break "a=b=c;" into
63786         "b=c; a=b;", since IRIX 6.5 cc complains about the former if b is
63787         never used later.
63788         * lib/quotearg.c (quoting_options_from_style):
63789         * lib/xstrtol.c (__xstrtol):
63790         Use enum instead of 0, to pacify IRIX 6.5 cc.
63792 2014-04-18  Pádraig Brady  <P@draigBrady.com>
63794         gitlog-to-changelog: revert inclusion of git-log-fix file
63795         * build-aux/git-log-fix: Delete dummy file.
63796         * modules/gitlog-to-changelog: Don't reference (overwrite)
63797         the project specific git-log-fix file.
63799 2014-04-18  Assaf Gordon  <agordon@wi.mit.edu>
63801         maint.mk: Relax the copyright check to cater for non FSF projects
63802         * top/maint.mk (sc_copyright_check): Relax the check for $PACKAGE.texi
63803         to not require the "Free" suffix after the copyright years.
63805 2014-04-18  Natanael Copa  <ncopa@alpinelinux.org>
63807         physmem: use sysinfo on linux-gnu if _SC_PHYS_PAGES unavailable
63808         * lib/physmem.c (physmem_total): Some systems like musl libc don't yet
63809         support _SC_PHYS_PAGES.  Use the linux syscall sysinfo as fallback
63810         if _SC_PHYS_PAGES or _SC_PAGESIZE fails.
63811         (physmem_available): Likewise for _SC_AVPHYS_PAGES.
63813 2014-04-18  Paul Eggert  <eggert@cs.ucla.edu>
63815         exclude: port to strict C99
63816         Strict C does not allow converting a function pointer to void *
63817         and vice versa.  Pass a pointer to a function pointer instead.
63818         * lib/exclude.c (add_exclude_file):
63819         Pass the address of the function pointer.
63820         (call_addfn): And deference the address here, to match.
63822 2014-04-17  Paul Eggert  <eggert@cs.ucla.edu>
63824         regex: do not depend on malloc-gnu
63825         * modules/regex (Depends-on): Remove malloc-gnu.
63826         It's no longer needed, because of the 2012-12-29 patch
63827         "regex: port to hosts where malloc (0) == NULL".
63828         Reported by Nathan Kennedy in:
63829         http://lists.gnu.org/r/bug-gnulib/2014-04/msg00026.html
63831 2014-04-16  Assaf Gordon  <agordon@wi.mit.edu>
63833         expl: avoid incorrect expl(small_value) on OpenBSD 5.4
63834         * m4/expl.m4 (gl_FUNC_EXPL): Add a check for this condition.
63835         * doc/posix-functions/expl.texi: Mention the workaround.
63837 2014-04-12  Paul Eggert  <eggert@cs.ucla.edu>
63839         xalloc: allow x2nrealloc (P, PN, S) where P && !*PN
63840         * lib/xalloc.h (x2nrealloc): Extend slightly, to allow the current
63841         size to be zero even when the pointer is nonnull.  This
63842         accommodates the use case where P is malloc (0) and *PN is 0 on a
63843         host where malloc (0) yields nonnull.
63845 2014-04-09  Eric Blake  <eblake@redhat.com>
63847         fts: avoid unnecessary strlen calls
63848         * lib/fts.c (_D_EXACT_NAMLEN): Restore definition when needed.
63850 2014-04-09  Paul Eggert  <eggert@cs.ucla.edu>
63852         fts: avoid unnecessary strlen calls
63853         * lib/fts.c (fts_build): Go back to using _D_EXECT_NAMLEN
63854         when that can be faster than strlen.
63856 2014-03-26  Bernhard Voelker  <mail@bernhard-voelker.de>
63858         fts: avoid unnecessary strlen calls
63859         * lib/fts.c (_D_EXACT_NAMLEN): Remove macro.
63860         (fts_build): Store the length of the dp->d_name entry in a local variable
63861         instead of calling strlen() several times via the above, removed macro.
63862         For 'rm -rf some-dir' with e.g. 1M directory entries, this speeds up the
63863         run by ~4%, yet this reduces the execution time by about a third if run
63864         via "ltrace -c rm -rf some-dir".
63866 2014-03-27  Paul Eggert  <eggert@cs.ucla.edu>
63868         obstack: Remove ancient NeXTSTEP gcc support conditional
63869         This change will ease merging with glibc.  The "#if ... __NEXT__"
63870         causes a warning with -Wundef which glibc now enables by default.
63871         Problem reported by Will Newton in
63872         <http://lists.gnu.org/r/bug-gnulib/2014-03/msg00032.html>.
63873         glibc <sys/cdefs.h> now uses __extension__ for GCC 2.8 or later,
63874         so go with that.
63875         * lib/obstack.h (__extension__):
63877 2014-03-27  Paul Eggert  <eggert@cs.ucla.edu>
63879         obstack: merge with glibc changes
63880         * lib/obstack.c, lib/obstack.h: Merge from glibc.
63881         This is mostly indenting and commentary changes.
63882         Instances of 'register' have been removed.
63884 2014-03-26  Bernhard Voelker  <mail@bernhard-voelker.de>
63886         strftime: wrap macros in "do {...} while(0)"
63887         * lib/strftime.c (DO_NUMBER): Wrap multi-statement code block of
63888         this macro in "do {...} while(0)" to prevent false use as a
63889         single statement, e.g., in an un-braced "{}" else-block.
63890         (DO_SIGNED_NUMBER, DO_TZ_OFFSET, DO_NUMBER_SPACEPAD): Likewise.
63891         (strftime_case_): Remove 'else' after 'goto' - which was the
63892         only non-fatal, un-braced use of one of the above macros.
63893         Spotted by coverity (NESTING_INDENT_MISMATCH).
63895 2014-03-26  Bernhard Voelker  <mail@bernhard-voelker.de>
63897         modechange: avoid memory leaks for invalid octal modes
63898         * lib/modechange.c (mode_compile): During the parsing of
63899         notations like +40, free the 'mc' buffer for invalid mode
63900         strings like +17777 (greater than the maximum octal mode),
63901         =18 (bad octal mode characters) or u=1 ('affected' with
63902         octal modes).
63903         Reproducer, e.g.:
63904             $ valgrind --leak-check=full chmod +17777 file
63905         Introduced via the 2012-03-09 commit, 4730c3e3, "modechange:
63906         add notations +40, 00440, etc.".
63907         Spotted by coverity (RESOURCE_LEAK).
63909 2014-03-24  Paul Eggert  <eggert@cs.ucla.edu>
63911         gitlog-to-changelog: include a dummy git-log-fix file
63912         Problem reported by Nathan Stratton Treadway in:
63913         http://lists.gnu.org/r/bug-tar/2014-03/msg00082.html
63914         * build-aux/git-log-fix: New file.
63916 2014-03-13  Jim Meyering  <meyering@fb.com>
63918         gitlog-to-changelog: also include the file, git-log-fix
63919         * modules/gitlog-to-changelog (Files): Add git-log-fix.
63920         Reported by Assaf Gordon.
63922 2014-03-06  Paul Eggert  <eggert@cs.ucla.edu>
63924         regex: port to OS X 10.8.5 en_US.UTF-8 locale
63925         This fixes a bug when ignoring case and when comparing the
63926         titlecase letter 'Lj' (U+01C8 LATIN CAPITAL LETTER L WITH SMALL
63927         LETTER J) to the corresponding uppercase letter 'LJ' (U+01C7 LATIN
63928         CAPITAL LETTER LJ).  In the OS X 10.8.5 en_US.UTF-8 locale, the
63929         titlecase letter is neither lowercase nor uppercase, but
63930         uppercasing the titlecase letter (via towupper) yields the
63931         uppercase letter, so the two letters should match when ignoring case.
63932         Problem reported by Jim Meyering in <http://debbugs.gnu.org/16911#16>.
63933         * lib/regex_internal.c (build_wcs_upper_buffer, build_upper_buffer):
63934         Don't test whether a character is lowercase before uppercasing it.
63936 2014-03-04  Kevin Cernekee  <cernekee@gmail.com>
63938         stdint, read-file: fix missing SIZE_MAX on Android (tiny change)
63939         This is basically one of the options Bruno Haible proposed in:
63940         http://lists.gnu.org/r/bug-gnulib/2012-01/msg00282.html
63941         * lib/sys_types.in.h (_GL_INCLUDING_UNISTD_H): New macro.
63942         * lib/stdint.in.h: Use it.
63943         * modules/stdint (Depends-on): Add sys_types.
63945 2014-02-26  Pádraig Brady  <P@draigBrady.com>
63947         parse-datetime: fix crash or infloop in TZ="" parsing
63948         * lib/parse-datetime.y (parse_datetime): Break out of the
63949         TZ="" parsing loop once the second significant " is found.
63950         Also skip over any subsequent whitespace to be consistent
63951         with the non TZ= case.
63952         * tests/test-parse-datetime.c: Add test cases for TZ="" parsing.
63954 2014-02-26  Paul Eggert  <eggert@cs.ucla.edu>
63956         savedir: new symbol for fast-read version
63957         * lib/savedir.h (SAVEDIR_SORT_FASTREAD): New symbol, for programs
63958         like GNU cp that want to use SAVEDIR_SORT_INODE if available,
63959         SAVEDIR_SORT_NONE otherwise.  Problem reported by Bernhard Voelker in:
63960         http://lists.gnu.org/r/coreutils/2014-02/msg00037.html
63962 2014-02-25  Paul Eggert  <eggert@penguin.cs.ucla.edu>
63964         unistd: port readlink to Mac OS X 10.3.9
63965         * lib/unistd.in.h (_GL_INCLUDING_UNISTD_H): New macro, to work
63966         around self-include problem in Mac OS X 10.3.9 when combined with
63967         readlink module.  Problem reported by Klaus Zietler in
63968         <http://bugs.gnu.org/16825>.
63970 2014-02-23  Paul Eggert  <eggert@cs.ucla.edu>
63972         diffseq: remove TOO_EXPENSIVE heuristic
63973         Problem with diffutils reported by Vincent Lefevre in
63974         <http://bugs.gnu.org/16848>.  The simplest solution is to remove
63975         the TOO_EXPENSIVE heuristic that I added to GNU diff in 1993.
63976         Although appropriate for circa-1993 hardware, these days the heuristic
63977         seems to be more trouble than it's worth.
63978         * lib/diffseq.h: Modernize citations.
63979         (struct context): Remove member too_expensive.
63980         All uses changed.
63981         (struct partition): Remove members lo_minimal, hi_minimal.
63982         All uses changed.
63983         (diag, compareseq): Remove arg find_minimal.  All uses changed.
63984         (diag): Remove the TOO_EXPENSIVE heuristic that I added back in
63985         1993 to make 'diff' run faster (but not as well) on large inputs.
63986         These days, computers are fast enough that it's typically better
63987         to run slower but more accurately.
63988         * lib/fstrcmp.c: Remove duplicate comment.
63989         * lib/fstrcmp.c (strcmp_bounded):
63990         * lib/git-merge-changelog.c (compute_differences):
63991         Adjust to diffseq.h changes.
63992         * NEWS: Document the change.
63994         savedir: simplify by using stpcpy
63995         * lib/savedir.c (direntry_t): Remove size member.  All uses removed.
63996         (streamsavedir): Use stpcpy instead.
63997         * modules/savedir (Depends-on): Add stpcpy.
63999 2014-02-21  Pádraig Brady  <P@draigBrady.com>
64001         spawn: fix link error on uclibc
64002         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): use AC_SEARCH_LIBS,
64003         to incorporate -lrt if needed (on uclibc for example).
64004         * modules/posix_spawn: Reference the substituted LIB.
64006 2014-02-21  Thomas Petazzoni  <thomas.petazzoni@free-electrons.com>  (tiny change)
64007         timer: fix uClibc detection of threading
64008         * m4/time_time.m4 (gl_TIMER_TIME): Detect whether threads are
64009         enabled in uClibc.
64011 2014-02-21  Eric Blake  <eblake@redhat.com>
64013         maintainer-makefiles: provide AC_PROG_SED for older autoconf
64014         * m4/gnulib-common.m4 (AC_PROG_SED): Copy from newer autoconf.
64016 2014-02-21  Sergey Poznyakoff  <gray@gnu.org.ua>
64018         exclude: add support for posix regexps
64020         This commit adds support for POSIX extended regular expressions
64021         and fixes a long-standing memory leak (pattern buffer was never
64022         freed).  It also implements a new interface function to read
64023         exclude patterns from a FILE, which passes an additional parameter
64024         to its callback function, thereby allowing to preserve its state
64025         between invocations.
64027         * lib/exclude.c (struct patopts): Pack regex and pattern into union.
64028         (pattern_buffer): New struct.
64029         (exclude): New member patbuf.
64030         (exclude_add_pattern_buffer): New function.
64031         (free_exclude_segment): Free regexps.
64032         (free_exclude): Free allocated pattern buffers.
64033         (exclude_patopts): New function.
64034         (file_pattern_matches): Use exclude_patopts.
64035         (add_exclude): support regexps.
64036         (add_exclude_fp): New function.
64037         (add_exclude_file): Rewrite using add_exclude_fp.
64038         (fnmatch_pattern_has_wildcards): Support posix extended regexps.
64039         * lib/exclude.h (EXCLUDE_REGEX, EXCLUDE_ALLOC): New flags.
64040         (add_exclude_fp)
64041         (add_exclude_file): Rewrite using add_exclude_fp.
64042         (fnmatch_pattern_has_wildcards): Support posix extended regexps.
64043         * lib/exclude.h (EXCLUDE_REGEX, EXCLUDE_ALLOC): New flags.
64044         (add_exclude_fp)
64045         (exclude_add_pattern_buffer): New prototypes.
64046         * modules/exclude: Depends on regex and filename.
64048 2014-02-20  Eric Blake  <eblake@redhat.com>
64050         maintainer-makefiles: use $(SED) for syntax check
64051         * modules/maintainer-makefile (configure.ac): Check for sane sed.
64052         * top/maint.mk: Change sed to $(SED).
64054 2014-02-11  Sergey Poznyakoff  <gray@gnu.org.ua>
64055             Paul Eggert  <eggert@cs.ucla.edu>
64057         savedir: add sorting arg to savedir, streamsavedir; remove fdsavedir
64058         Patch based on an idea by Dick Streefland in
64059         <https://savannah.gnu.org/patch/?7892>.
64060         * NEWS: Document this.
64061         * lib/savedir.c (NAME_SIZE_DEFAULT): Remove.
64062         (direntry_t, comparison_function): New types.
64063         (direntry_cmp_name): New function.
64064         (direntry_cmp_inode) [D_INO_IN_DIRENT]: New function.
64065         (streamsavedir, savedir): New arg OPTION.
64066         (streamsavedir): Simplify memory allocation.
64067         (fdsavedir): Remove.
64068         * lib/savedir.h (enum savedir_option): New type.
64069         (streamsavedir, savedir): New arg OPTION.
64070         (fdsavedir): Remove.
64072 2014-02-05  Paul Eggert  <eggert@cs.ucla.edu>
64074         file-type: add support for doors and other less-common file types
64075         Problem with S_ISDOOR reported by Rich Burridge.
64076         * lib/file-type.c (file_type): Do S_ISLNK early too.  Do S_TYPEIS*
64077         macros before the rest.  Add S_ISCTG, S_ISDOOR, S_ISMPB, S_ISMPC,
64078         S_ISMPX, S_ISNAM, S_ISNWK, S_ISOFD, S_ISOFL, S_ISPORT, S_ISWHT.
64080 2014-01-23  Eric Blake  <eblake@redhat.com>
64082         pthread: work around winpthread header pollution on mingw
64083         * lib/time.in.h: Move pthread workarounds...
64084         * lib/pthread.in.h: ...here.
64085         * m4/pthread.m4 (gl_PTHREAD_CHECK): Also build pthread.h when we
64086         detect macro pollution on mingw.
64087         * doc/posix-headers/pthread.texi (pthread.h): Document the problems.
64089 2014-01-22  Paul Eggert  <eggert@cs.ucla.edu>
64091         qacl: check for fchmod
64092         * m4/acl.m4 (gl_FUNC_ACL): Check for fchmod, since acl-internal.h
64093         and qset-acl.c both use HAVE_FCHMOD.
64095 2014-01-20  Paul Eggert  <eggert@cs.ucla.edu>
64097         fdopen-tests: port to Tru64
64098         * tests/test-fdopen.c (main): Don't invoke fdopen on a file
64099         descriptor that is not open, as POSIX doesn't specify the
64100         resulting behavior and the test does not work on Tru64.
64101         Problem reported by Steven M. Schweda in:
64102         http://lists.gnu.org/r/bug-gnulib/2014-01/msg00079.html
64104         stdalign: port to HP-UX compilers
64105         * lib/stdalign.in.h (_Alignas): Use __attribute__ (__aligned__ (x))
64106         if __HP_cc or __HP_aCC are nonzero.
64108 2014-01-16  Paul Eggert  <eggert@cs.ucla.edu>
64110         strtoimax: port to platforms lacking 'long long'
64111         VMS's pre-C99 compiler lacks 'long long', so 'configure' doesn't
64112         check whether strtoll is declared, which causes the C file to
64113         wrongly report an error.  Problem reported by Steven M. Schweda in:
64114         http://lists.gnu.org/r/bug-diffutils/2014-01/msg00003.html
64115         * lib/strtoimax.c (strtoull):
64116         Declare only if HAVE_UNSIGNED_LONG_LONG_INT.
64117         (strtoll): Declare only if HAVE_LONG_LONG_INT.
64119 2014-01-16  Daniel Albers  <daniel@lbe.rs>  (tiny change)
64121         relocatable-perl: fix texi syntax
64122         * doc/relocatable-maint.texi: Escape braces.
64124 2014-01-09  Reuben Thomas  <rrt@sc3d.org>
64126         relocatable-perl: like relocatable-script, but for Perl scripts
64127         * build-aux/relocatable.pl.in: Add.
64128         * doc/relocatable-maint.texi: Add documentation.
64129         * modules/relocatable-perl: Add.
64131 2014-01-07  Paul Eggert  <eggert@cs.ucla.edu>
64133         tests: fix export bug in previous patch
64134         Problem reported by Jim Meyering.
64135         * tests/init.sh (re_shell): New var, which is exported instead of
64136         re_shell_.
64138         tests: simplify porting to Solaris 10 /bin/sh
64139         Some test cases in 'grep' need a shell that groks '$(';
64140         export re_shell_ for their benefit.  Problem reported for 'grep'
64141         by Dagobert Michelsen in <http://bugs.gnu.org/16380>.
64142         * tests/init.sh (re_shell_): Export if it's used.
64144 2014-01-06  Eric Blake  <eblake@redhat.com>
64146         md5, sha1, sha256, sha512: support older autoconf
64147         * m4/00gnulib.m4 (m4_divert_push): Wrap diversion stack
64148         for autoconf < 2.63b.
64150         include_next: port to autoconf 2.63
64151         * m4/gnulib-common.m4 (AS_VAR_COPY): Define if missing.
64153 2014-01-04  Jim Meyering  <meyering@fb.com>
64155         maint: add a gnulib-local rule to keep non-ascii out of .texi files
64156         * cfg.mk (sc_keep_gnulib_texi_files_mostly_ascii): New rule,
64157         so that "make sc_maint" will ding anyone who puts non-ascii
64158         in any of gnulib's .texi files.
64160 2014-01-03  Jim Meyering  <meyering@fb.com>
64162         freadable, fwritable, fwriting: declare with the "pure" attribute
64163         * lib/freadable.h (freadable): Declare with the "pure" attribute.
64164         * lib/fwritable.h (fwritable): Likewise.
64165         * lib/fwriting.h (fwriting): Likewise.
64166         Suggested by Bruno Haible.
64168         maint.mk: adapt openat.h-include-without-use test
64169         * top/maint.mk (sc_prohibit_openat_without_use): Also check for
64170         FCHMODAT_INLINE, FCHOWNAT_INLINE and STATAT_INLINE, to avoid
64171         failing on gnulib's own lib/{chmod,chown,stat}at.c files.
64172         With this change, running "make sc_maint" in gnulib's top-level
64173         directory now passes for me.
64175 2014-01-03  Paul Eggert  <eggert@cs.ucla.edu>
64177         doc: use ASCII in .texi files where UTF-8 isn't needed
64178         * doc/posix-functions/crypt.texi, doc/posix-functions/encrypt.texi:
64179         * doc/posix-functions/setkey.texi, doc/regex.texi:
64180         Use ASCII input, not UTF-8.
64182 2014-01-02  Jim Meyering  <meyering@fb.com>
64184         freading: declare with the "pure" attribute
64185         * lib/freading.h (freading): Declare with the "pure" attribute.
64187         manywarnings: remove -Wmudflap
64188         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Remove -Wmudflap, since
64189         it is no longer supported in gcc-4.9-to-be.
64191 2014-01-01  Paul Eggert  <eggert@cs.ucla.edu>
64193         relocatable-script: remove unused code
64194         Problem reported by Reuben Thomas in:
64195         http://lists.gnu.org/r/bug-gnulib/2013-12/msg00117.html
64196         * build-aux/relocatable.sh.in (func_tmpdir): Remove unused function.
64198 2014-01-01  Jim Meyering  <meyering@fb.com>
64200         maint: fix public-submodule-commit to work with newer git
64201         * top/maint.mk (public-submodule-commit): Remove excess quoting.
64202         We were over-quoting the test arguments, and somewhere prior to
64203         version 1.8.5.2.229, git stopped removing those excess quotes,
64204         which made the test fail, since the unexpanded strings would
64205         always differ; using GIT_TRACE=1 confirmed that the git merge-base
64206         command wasn't even being run.
64208 2014-01-01  Paul Eggert  <eggert@cs.ucla.edu>
64210         doc: update main copyright year
64211         * doc/gnulib.texi: Update copyright date.
64213 2014-01-01  Eric Blake  <eblake@redhat.com>
64215         version-etc: new year
64216         * lib/version-etc.c (COPYRIGHT_YEAR): Bump to 2014.
64217         * all files: run 'make update-copyright'
64219 2013-12-24  Eric Blake  <eblake@redhat.com>
64221         passfd: give nicer error for recvfd at eof
64222         * lib/passfd.c (recvfd): Fake ENOTCONN if other end closes early.
64223         * tests/test-passfd.c (main): Enhance test to cover this.
64225 2013-12-17  Paul Eggert  <eggert@cs.ucla.edu>
64227         gettimeofday: port recent C++ fix to Emacs
64228         Without this further patch, Emacs won't build due to
64229         the portcheck failing.  Also, this simplifies the patch a bit.
64230         * lib/time.in.h (localtime, gmtime): Don't replace unless
64231         GNULIB_GETTIMEOFDAY.  Treat them more like mktime.
64232         * lib/time.in.h (localtime, gmtime):
64233         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME):
64234         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS):
64235         * modules/time (time.h):
64236         Don't worry about the possibility of localtime and gmtime
64237         being absent; they're present in all C libraries we know about.
64238         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS):
64239         Don't assume sys_time is present and has been initialized.
64240         Instead, use a hack that should work even if it hasn't been.
64241         Don't use a portcheck for gmtime or localtime; this supports
64242         the hack.
64243         * modules/time (time.h): Substitute GNULIB_GETTIMEOFDAY.
64245 2013-12-17  John W. Eaton  <jwe@gnu.org>
64247         gettimeofday: fix C++ crosscompilation
64249         Never replace gmtime and localtime by macros when compiling with
64250         C++, this prevents <ctime> from being included.
64252         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Do not
64253         define gmtime and localtime as preprocessor macros.  Instead
64254         define some HAVE_GMTIME, HAVE_LOCALTIME, REPLACE_GMTIME, and
64255         REPLACE_LOCALTIME substitutions.
64256         * lib/time.in.h: Declare gmtime and localtime when needed.
64257         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): AC_SUBST HAVE_GMTIME,
64258         HAVE_LOCALTIME, REPLACE_GMTIME, and REPLACE_LOCALTIME.
64259         * modules/time: Depend on gettimeofday, and substitute the above
64260         variables in time.h.
64262 2013-12-17  Paul Eggert  <eggert@cs.ucla.edu>
64264         qacl: port to Windows better
64265         See Eli Zaretskii in
64266         <http://lists.gnu.org/r/emacs-devel/2013-12/msg00593.html>.
64267         * lib/file-has-acl.c (acl_access_nontrivial):
64268         Return -1 and set errno if !HAVE_ACL_FIRST_ENTRY &&
64269         !HAVE_ACL_TO_SHORT_TEXT && !HAVE_ACL_FREE_TEXT.
64271 2013-12-12  Alexander V. Lukyanov  <lav@netis.ru>
64273         md5, sha1, sha256, sha512: fix (trivial) compile error in c++ mode.
64274         * lib/gl_openssl.h: Cast void pointers to a specific type.
64276 2013-12-07  Pádraig Brady  <P@draigBrady.com>
64278         open-tests: fix build failure with -Werror=old-style-declaration
64279         * tests/test-open.h: Reorder the inline to avoid the issue.
64281 2013-12-07  Pádraig Brady  <P@draigBrady.com>
64283         md5, sha1, sha256, sha512: fix link error with partial libcrypto
64284         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Only clear LIB_CRYPTO at
64285         init time, so that if early checks find crypto routines,
64286         while the last does not, then @LIB_CRYPTO@ is replaced correctly,
64287         avoiding link failures.
64289 2013-12-07  Paul Eggert  <eggert@cs.ucla.edu>
64291         md5, sha1, sha256, sha512: add gl_SET_CRYPTO_CHECK_DEFAULT
64292         This provides a new way to specify the default for
64293         gl_CRYPTO_CHECK, one that is reflected in the --help message.
64294         Emacs uses this, as well as the old way.
64295         This attempts to implement a suggestion by Pádraig Brady in
64296         <http://lists.gnu.org/r/coreutils/2013-12/msg00080.html>.
64297         * m4/gl-openssl.m4(gl_SET_CRYPTO_CHECK_DEFAULT): New macro.
64298         (gl_CRYPTO_CHECK): Use it.  Mention the default in --help output.
64300         md5, sha1, sha256, sha512: add 'auto', and a way to specify default
64301         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK):
64302         Add support for a new option, --with-openssl=auto, which causes
64303         the library to be used if available and silently ignored if not.
64304         Add support to allow configure.ac to specify its own
64305         default, by setting with_openssl_default before invoking gl_INIT.
64307 2013-12-05  Paul Eggert  <eggert@cs.ucla.edu>
64309         open-tests: port to glibc with _FORTIFY_SOURCE and -O1
64310         Problem reported by Daiki Ueno in:
64311         http://lists.gnu.org/r/bug-gnulib/2013-06/msg00052.html
64312         * tests/test-open.h (__always_inline):
64313         New macro, if not already defined.
64314         (test_open): Use it.
64316 2013-12-04  Eric Blake  <eblake@redhat.com>
64318         include_next: minimize code duplication
64319         * modules/include_next (Depends-on): Add absolute-header.
64320         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Reuse
64321         gl_ABSOLUTE_HEADER_ONE instead of open-coding it.
64323 2013-12-04  Pádraig Brady  <P@draigBrady.com>
64325         getcwd: fix compile error in configure check
64326         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Include errno.h
64328 2013-12-04  Pádraig Brady  <P@draigBrady.com>
64330         regex: suppress core dumps from detection code
64331         * m4/regex.m4 (gl_REGEX): Catch the SIGABRT and convert to SIGTERM
64332         to suppress core dumps that may well occur on glibc systems.
64333         These core dumps might not be cleaned up automatically, or could
64334         trigger some system core dump handling logic.
64336 2013-12-03  Pádraig Brady  <P@draigBrady.com>
64338         md5, sha1, sha256, sha512: support mandating use of openssl
64339         * m4/gl-openssl.m4 (gl_crypto_check): Adjust the --with-openssl
64340         description, to list the now 3 separate options.  also don't
64341         mention the default=no, since this is implicit given the option
64342         is described as --with-openssl rather than --without-openssl.
64343         If projects change the default they're free to document that.
64344         with --with-openssl[=yes] we now error out when the specified
64345         hash algorithm is not available in libcrypto.
64347 2013-12-03  Ivailo  <xakepa10@gmail.com>
64349         test-xvasprintf: (trivial) fix to disable some -Wformat-security diags
64350         * tests/test-xvasprintf.c: Disable -Wformat-zero-length and
64351         -Wformat-nonliteral checks, as these edge cases are part of the test.
64353 2013-12-03  Eric Blake  <eblake@redhat.com>
64355         regex: avoid glibc deadlock during configure
64356         * m4/regex.m4 (gl_REGEX): Avoid recursive malloc deadlock when
64357         glibc bug 15078 in turn triggers bug 16159.
64358         Reported by Michal Privoznik.
64360 2013-12-02  Pádraig Brady  <P@draigBrady.com>
64362         md5, sha1, sha256, sha512: use openssl routines if available.
64363         --with-openssl the libcrypto md5, sha1, sha224, sha256, sha384, sha256
64364         routines will be used if available, requiring apps to link @LIB_CRYPTO@
64365         * lib/gl_openssl.h: Provide wrappers for specified openssl hash.
64366         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): New function to lookup libcrypto
64367         in the standard system location.
64368         * m4/sha1.m4: Call gl_CRYPTO_CHECK() for SHA1.
64369         * m4/sha256.m4: Likewise with SHA256.
64370         * m4/sha512.m4: Likewise with SHA512.
64371         * m4/md5.m4: Likewise with MD5.
64372         * m4/gc.m4: Ensure @LIB_CRYPTO@ set for tests.
64373         * lib/sha1.h: Include wrappers if HAVE_OPENSSL_SHA1.
64374         * lib/sha256.h: Likewise with SHA256.
64375         * lib/sha512.h: Likewise with SHA512.
64376         * lib/md5.h: Likewise with MD5.
64377         * lib/sha1.c: Exlude functionality if HAVE_OPENSSL_SHA1.
64378         * lib/sha256.c: Likewise with SHA256.
64379         * lib/sha512.c: Likewise with SHA512.
64380         * lib/md5.c: Likewise with MD5.
64381         * modules/crypto/sha1 (Link:): Add the new optional lib.
64382         (Depends-on:): Add dependency on extern-inline.
64383         * modules/crypto/sha256: Likewise.
64384         * modules/crypto/sha512: Likewise.
64385         * modules/crypto/md5: Likewise.
64386         * modules/crypto/sha1-tests: Reference the lib here too.
64387         * modules/crypto/md5-tests: Likewise.
64388         * modules/crypto/gc-des-tests: Likewise.
64389         * modules/crypto/gc-hmac-md5-tests: Likewise.
64390         * modules/crypto/gc-hmac-sha1-tests: Likewise.
64391         * modules/crypto/gc-hmac-sha256-tests: Likewise.
64392         * modules/crypto/gc-hmac-sha512-tests: Likewise.
64393         * modules/crypto/gc-md5-tests: Likewise.
64394         * modules/crypto/gc-pbkdf2-sha1-tests: Likewise.
64395         * modules/crypto/gc-sha1-tests: Likewise.
64396         * modules/crypto/gc-tests: Likewise.
64397         * modules/crypto/hmac-md5-tests: Likewise.
64398         * modules/crypto/hmac-sha1-tests: Likewise.
64399         * modules/crypto/hmac-sha256-tests: Likewise.
64400         * modules/crypto/hmac-sha512-tests: Likewise.
64402 2013-11-29  RV1971  <rv1971@web.de>
64404         base64: (trivial) fix compilation regression on some compilers
64405         * lib/base64.c: Don't return the void function,
64406         instead split to a separate return statement.
64408 2013-11-28  Paul Eggert  <eggert@cs.ucla.edu>
64410         ignore-value: revert previous code change
64411         * lib/ignore-value.h (ignore_value): Use __extension__ and
64412         __typeof__ only for GCC 3.4 and later.  Reported by Eric Blake in
64413         <http://lists.gnu.org/r/bug-gnulib/2013-11/msg00102.html>.
64414         Change the comment to try to explain this better.
64416 2013-11-27  Pádraig Brady  <P@draigBrady.com>
64418         selinux-h: improve stub types and add more stub functions
64420         * lib/se-selinux.in.h: Change security_context_t to a typedef
64421         rather than a define, as it's a pointer type and so is better
64422         as a typedef to avoid issues declaring multiple variables
64423         with the comma operator.  Also add stub for string_to_security_class().
64424         * lib/se-context.in.h: Add stub functions for
64425         context_{type,range,role,user}_get().
64427 2013-11-27  Paul Eggert  <eggert@cs.ucla.edu>
64429         ignore-value: prefer GCC version back through 2.0
64430         The code didn't match the comments, so I did a bit of software
64431         archaeology.  GCC 2.0 seems to support __extension__ and
64432         __typeof__, so fix both code and comments to use 2.0.
64433         * lib/ignore-value.h (ignore_value): Use __extension__ and
64434         __typeof__ for GCC 2.0 through 3.3, too.
64436 2013-11-25  Mats Erik Andersson  <gnu@gisladisker.se>
64438         pty: Activate the signature wrapper of forkpty.
64439         The intended preprocessor macro HAVE_FORKPTY is
64440         never defined, yet `lib/forkpty.c' depends on it.
64442         * m4/pty.m4 (gl_FUNC_FORKPTY): At completed analysis,
64443         apply AC_DEFINE_UNQUOTED to HAVE_FORKPTY with value
64444         $HAVE_FORKPTY for access to wrapper in `lib/forkpty.c'.
64446 2013-11-18  Jim Meyering  <meyering@fb.com>
64447         and Paul Eggert  <eggert@cs.ucla.edu>
64449         quotearg: don't attempt to store 1 << 31 into an "int"
64450         * lib/quotearg.c (quotearg_buffer_restyled): Building coreutils with
64451         gcc's new -fsanitize=undefined and running its tests triggered some
64452         new test failures due to undefined behavior, all with this diagnostic:
64453           lib/quotearg.c:629:62: runtime error: left shift of 1 by 31 places \
64454             cannot be represented in type int
64455         Rather than shifting "1" left to form a mask, shift the bits right and
64456         simply use "1" as the mask.
64458 2013-11-21  Paul Eggert  <eggert@cs.ucla.edu>
64460         error: depend on stdio
64461         Problem reported by Nikos Mavrogiannopoulos in
64462         <http://lists.gnu.org/r/bug-gnulib/2013-11/msg00084.html>
64463         * modules/error (Depends-on): Add stdio.
64465 2013-11-18  Ben Pfaff  <blp@cs.stanford.edu>
64467         * doc/relocatable-maint.texi (Supporting Relocation): Improve
64468         wording.
64469         Reported by Reuben Thomas <rrt@sc3d.org>.
64471 2013-11-13  Paul Eggert  <eggert@cs.ucla.edu>
64473         * lib/getgroups.c (posix_getgroups, getgroups) [__APPLE__]:
64474         New function and macro, to work around _DARWIN_C_SOURCE problem.
64475         Reported by Jack Howarth in <http://bugs.gnu.org/14463>.
64477 2013-11-11  Pádraig Brady  <P@draigBrady.com>
64479         base64: provide a fast path for encoding well sized buffers
64480         Avoid conditionals in the base64 encoding loop,
64481         which was seen to give 60% better throughput.
64482         * lib/base64.c (base64_encode_fast): A new function to be called
64483         when we don't want to NUL terminate, and we have enough space
64484         in the output to encode the given input.
64485         (base64_encode): Call the _fast() version when appropriate.
64486         Also remove a redundant mask with 0x3F on the first encoded byte.
64488 2013-11-08  Paul Eggert  <eggert@cs.ucla.edu>
64490         extern-inline: port better to OS X 10.9
64491         * m4/extern-inline.m4: Omit serial number; this file doesn't use them.
64492         (gl_EXTERN_INLINE): Do not suppress the use of extern inline on
64493         OS X 10.9, except for g++ where the bug is still present.
64494         See <http://trac.macports.org/ticket/41033>.
64496 2013-11-08  Eric Blake  <eblake@redhat.com>
64498         fpending: fix regression on DragonFly BSD
64499         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for declaration.
64500         * lib/fpending.h (__fpending): Don't declare twice.
64501         Reported by GW in
64502         <https://lists.gnu.org/r/bug-m4/2013-11/msg00000.html>
64504 2013-11-05  Jim Meyering  <meyering@fb.com>
64506         hash: relax license to LGPLv2+, for libguestfs
64507         * modules/hash (License): Change from GPL to LGPLv2+.
64509 2013-11-03  Paul Eggert  <eggert@cs.ucla.edu>
64511         intprops: port to Oracle Studio c99
64512         * lib/intprops.h (_GL_HAVE___TYPEOF__) [__SUNPRO_C && __STDC__]:
64513         Define to 0, to avoid diagnostics when Oracle Studio is pedantic.
64515 2013-10-31  Paul Eggert  <eggert@cs.ucla.edu>
64517         obstack: pacify HP C
64518         * lib/obstack.h (obstack_free) [!__GNUC__]: Rewrite to avoid
64519         warning "conversion from pointer to smaller integer" from HP
64520         C-ANSI-C - cc version B9007AA/B3910B A.06.26.  It's safe to assume
64521         C89 or later nowadays, so cast to void instead of int.  Privately
64522         reported by H.Merijn Brand.  Also, change header to match glibc's,
64523         to make checking against glibc easier.
64525 2013-10-29  Jim Meyering  <meyering@fb.com>
64527         maint.mk: prefer gpgv2 over gpgv
64528         * top/maint.mk (gpgv): Use gpgv2 if present, else gpgv.
64529         (gpg_key_ID): Use $(gpgv), rather than hard-coding "gpgv".
64530         Reported by Gary Vaughan.
64532 2013-10-30  Paul Eggert  <eggert@cs.ucla.edu>
64534         isnan: port to VAX
64535         Reported by John Klos for NetBSD-5/VAX in
64536         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00133.html>.
64537         * lib/isnan.c (IEEE_FLOATING_POINT): New macro, stolen from Emacs.
64538         (FUNC): Use it.
64540 2013-10-28  Jim Meyering  <meyering@fb.com>
64542         gnulib-tool: protect against CDPATH
64543         * gnulib-tool: Many "cd" built-in functions print a directory name
64544         to stdout when CDPATH is set, e.g.,
64545           $ bash -c 'CDPATH=/; cd tmp'
64546           /tmp
64547         Unset it, when possible.  Prompted by a comment from Bruce Korb.
64549         maint.mk: restore functionality removed by recent change...
64550         Sunday's change, v0.0-8062-g6b24f60, may have appeared correct from
64551         the context of a shallow-cloned gnulib repository: "git describe"
64552         would fail in such a directory.  However, that change made it so
64553         the reported gnulib revision no longer includes the version number
64554         or a commit count, even when run from a full clone.
64555         * top/maint.mk (gnulib-version): Use the full "git describe"
64556         output when possible, e.g., the form above, rather than the
64557         abbreviated, no-tag, no-commit-count string, and fall back to
64558         using a 10-byte hash, rather than the default minimal-length
64559         hash prefix, since while the minimal-length one may be fine today,
64560         it is likely not to be unique for very long.
64562 2013-10-26  Jim Meyering  <meyering@fb.com>
64564         maint.mk: fix "release" target to build _version
64565         This fixes a bug in README-release whereby following the outlined
64566         steps, one would publish a tarball whose programs would report
64567         --version output not consistent with the package version number.
64568         This bug caused grep-2.15 to produce a grep program whose
64569         --version option made it print 2.14.56-1e3d rather than 2.15.
64570         * top/maint.mk (release): Making this target build "_version"
64571         ensures that the new version number is reflected in configure.
64573 2013-10-21  Ben Pfaff  <blp@cs.stanford.edu>
64575         install-reloc: Support multi-binary installation.
64576         * build-aux/install-reloc: Support installing multiple programs in
64577         one invocation, as done by Automake starting with commit
64578         4295fe33eb23f (Multi-file install for PROGRAMS.).  From Bruno
64579         Haible <bruno@clisp.org>, archived at
64580         http://lists.debian.org/debian-bsd/2012/05/msg00032.html.
64581         Reported by Sylvain <beuc@gnu.org>.
64583 2013-10-21  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
64585         selinux-h: Really build without selinux when library is missing.
64586         * m4/selinux-selinux-h.m4: When the selinux library is missing, really
64587         continue without selinux, as already told in the warning message.
64589 2013-10-21  Jim Meyering  <meyering@fb.com>
64591         regex: also remove dependency on HAVE_WCSCOLL
64592         * lib/regex_internal.h: Remove final vestige of the wcscoll dependency.
64594 2013-10-21  Reuben Thomas  <rrt@sc3d.org>
64596         xfreopen: Fix typo. s/frepoen/freopen/
64597         * lib/xfreopen.c: Fix description.
64598         * modules/xfreopen: Likewise.
64600 2013-10-21  Jim Meyering  <meyering@fb.com>
64602         regex: don't depend on wcscoll
64603         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wcscoll.
64604         It is no longer used.
64606 2013-10-20  Jim Meyering  <meyering@fb.com>
64608         error: add the printf attribute to a static function
64609         * lib/error.c (error_tail): Add the printf attribute, to placate
64610         gcc's -Werror=suggest-attribute=format option.
64612 2013-09-30  Jim Meyering  <meyering@fb.com>
64614         fpending, obstack, strerror-override: use pure+const function attrs
64615         * lib/fpending.h (__fpending): Declare with the "pure" attribute.
64616         * lib/obstack.c (_obstack_allocated_p): Likewise.
64617         * lib/obstack.h (_obstack_memory_used): Likewise.
64618         (_obstack_memory_used): Likewise.
64619         * lib/strerror-override.h (strerror_override): Declare with
64620         the "const" attribute.
64622 2013-10-18  Eric Blake  <eblake@redhat.com>
64624         extern-inline: make safe for -Wundef usage
64625         Reported by Vladimir 'phcoder' Serbinenko in
64626         https://lists.gnu.org/r/bug-gnulib/2013-10/msg00078.html
64627         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Port to older gcc.
64629 2013-10-16  Paul Eggert  <eggert@cs.ucla.edu>
64631         mkfifo-tests, etc.: allow HP-UX 11.11 bug
64632         Problem reported by Daniel Richard G. in
64633         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00068.html>.
64634         * doc/posix-functions/mkfifo.texi (mkfifo):
64635         * doc/posix-functions/mkfifoat.texi (mkfifoat):
64636         * doc/posix-functions/mknod.texi (mknod):
64637         * doc/posix-functions/mknodat.texi (mknodat):
64638         Document the HP-UX 11.11 bug.
64639         * tests/test-mkfifo.h (test_mkfifo):
64640         Allow the HP-UX 11.11 bug.
64642 2013-10-14  Paul Eggert  <eggert@cs.ucla.edu>
64644         acl: allow cross-compilation to Gentoo
64645         Problem reported by Gabriel Marcano in
64646         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00058.html>.
64647         * m4/acl.m4 (gl_ACL_GET_FILE): When cross-compiling,
64648         test only whether it links.
64650 2013-10-13  Paul Eggert  <eggert@cs.ucla.edu>
64652         mgetgroups: remove dependency on realloc-gnu
64653         The dependency violates the comment in realloc-gnu, which
64654         says that tests can't depend on realloc-gnu; some tests depend
64655         on mgetgroups, so mgetgroups can't depend on realloc-gnu.
64656         Problem reported by Daniel Richard G. in
64657         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00056.html>.
64658         * lib/mgetgroups.c (mgetgroups): Don't call realloc (NULL, 0).
64659         * modules/mgetgroups (Depends-on): Depend on realloc-posix,
64660         not realloc-gnu.
64662 2013-10-12  Paul Eggert  <eggert@cs.ucla.edu>
64664         regex-tests: port to HP-UX 11.11
64665         Problem reported by Daniel Richard G. in
64666         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00052.html>.
64667         * modules/regex-tests (test_regex_LDADD): Add LIBTHREAD, LIB_PTHREAD.
64669 2013-10-10  Paul Eggert  <eggert@cs.ucla.edu>
64671         verify: document some 'assume' pitfalls
64672         * doc/verify.texi (Compile-time Assertions):
64673         Mention that 'assume (E)' can sometimes slow things down.
64674         Use CHAR_MAX + 1, not UCHAR_MAX + 1.
64676 2013-10-10  Eric Blake  <eblake@redhat.com>
64678         strtoumax: fix typo in previous commit.
64679         * modules/strtoumax (Depends-on): Fix typo.
64680         * modules/strtoimax (Depends-on): Likewise.
64682 2013-10-10  Paul Eggert  <eggert@cs.ucla.edu>
64684         strtoumax: port to Solaris 8
64685         This problem was introduced in the recent HP-UX patch.
64686         Reported by Tom G. Christensen in
64687         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00037.html>.
64688         * modules/strtoumax (Depends-on): Test HAVE_STRTOUMAX
64689         and REPLACE_STRTOUMAX rather than ac_cv_func_strtoumax.
64691 2013-10-09  Paul Eggert  <eggert@cs.ucla.edu>
64693         strtoimax, strtoumax: port to HP-UX 11.11
64694         Problem reported by Daniel Richard G. in
64695         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00023.html>.
64696         * lib/inttypes.in.h (strtoumax): Replace strtoumax if
64697         REPLACE_STRTOUMAX, thus treating it consistently with strtoimax.
64698         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Add default for
64699         REPLACE_STRTOUMAX.
64700         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX):
64701         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX):
64702         Replace the function if defined as a macro but not as a function.
64703         * modules/inttypes-incomplete (inttypes.h): Substitute
64704         REPLACE_STRTOUMAX.
64705         * modules/strtoumax (configure.ac): Replace strtoumax if
64706         REPLACE_STRTOUMAX.
64708 2013-10-08  Paul Eggert  <eggert@cs.ucla.edu>
64710         strtoimax: port to HP-UX 11.11
64711         Problem reported by Daniel Richard G.
64712         * lib/strtoimax.c (Strtoimax, Strtol, Strtoll): New macros.
64713         (strtoimax, strtol, strtoll) [UNSIGNED]: Remove, since
64714         they might clash with inttypes.h.
64716 2013-10-06  Paul Eggert  <eggert@cs.ucla.edu>
64718         New module 'count-trailing-zeros'.
64719         * MODULES.html.sh: Mention it.
64720         * lib/count-trailing-zeros.c, lib/count-trailing-zeros.h:
64721         * m4/count-trailing-zeros.m4, modules/count-trailing-zeros:
64722         * modules/count-trailing-zeros-tests:
64723         * tests/test-count-trailing-zeros.c:
64724         New files.
64726         count-leading-zeros: port to MSC; support types wider than 64 bits
64727         The ideas behind the MSC port are stolen from Emacs.
64728         * lib/count-leading-zeros.h:
64729         Don't include verify.h: it's no longer needed, as types wider than
64730         64 bits are now supported.
64731         (COUNT_LEADING_ZEROS): New arg MSC_BUILTIN, for better
64732         performance with MSC.  All uses changed.  Do not assume that TYPE
64733         has at most 64 bits.
64734         (count_leading_zeros_32): Assume 0 < X < 2**32, for speed.
64735         All uses changed.  Fold the subtraction from 31 into the table.
64737         count-one-bits: port to MSC; support types wider than 64 bits
64738         The ideas behind the MSC port are stolen from Emacs.
64739         * lib/count-one-bits.c (popcount_support) [_MSC_VER]: New variable.
64740         * lib/count-one-bits.h: Include limits.h, for CHAR_BIT.
64741         Don't include verify.h: it's no longer needed, as types wider than
64742         64 bits are now supported.
64743         (COUNT_ONE_BITS_GENERIC): New macro.
64744         (popcount_supported) [_MSC_VER]: New inline function.
64745         (COUNT_ONE_BITS): Use it.  New arg MSC_BUILTIN, for better
64746         performance with MSC.  All uses changed.  Do not assume that TYPE
64747         has at most 64 bits.
64748         * modules/count-one-bits (Depends-on): Do not depend on 'verify'.
64750 2013-10-06  Andrew Borodin  <aborodin@vmail.ru>
64752         mountlist: fix resource leak with MOUNTED_INTERIX_STATVFS
64753         * lib/mountlist.c (read_file_system_list): fix leak of directory
64754         streams in case of #ifdef MOUNTED_INTERIX_STATVFS.
64756 2013-10-06  Paul Eggert  <eggert@cs.ucla.edu>
64758         tests: improve diagnostic when an assertion fails
64759         * tests/macros.h (ASSERT): Report the assertion that failed.
64761 2013-10-02  Paul Eggert  <eggert@cs.ucla.edu>
64763         verify: new macro 'assume'
64764         This is taken from Emacs, and should be generally useful.
64765         * doc/verify.texi (assume): Document it.
64766         * lib/verify.h (assume): New macro.
64767         (__has_builtin): Expand to 0 if not defined.
64769 2013-09-26  Eric Blake  <eblake@redhat.com>
64771         dup2, dup3: work around another cygwin crasher
64772         * m4/dup2.m4 (gl_FUNC_DUP2): Expose the bug.
64773         * m4/dup3.m4 (gl_FUNC_DUP3): Likewise.
64774         * tests/test-dup2.c (main): Likewise.
64775         * lib/dup2.c (rpl_dup2): Use setdtablesize to avoid it.
64776         * lib/dup3.c (dup3): Likewise.
64777         * doc/posix-functions/dup2.texi (dup2): Document it.
64778         * doc/glibc-functions/dup3.texi (dup3): Likewise.
64780         getdtablesize: work around cygwin issue
64781         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Detect problem.
64782         * modules/getdtablesize (configure.ac): Build replacement.
64783         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set up a witness.
64784         * modules/unistd (Makefile.am): Expose the witness.
64785         * lib/unistd.in.h (getdtablesize): Declare replacement.
64786         * lib/getdtablesize.c (rpl_getdtablesize): Work around it.
64787         * tests/test-getdtablesize.c (main): Test it.
64788         * doc/glibc-functions/getdtablesize.texi (getdtablesize): Document it.
64790 2013-09-25  Mats Erik Andersson  <gnu@gisladisker.se>
64792         pmccabe2html: escaping of special characters
64793         Escape all '<', '>', and '&' in HTML output.
64794         * build-aux/pmccabe2html (html_fnc): Call gsub()
64795         instead of sub() to capture all '<', '>', and '&'.
64796         Neither of '<' and '>' is special in a regexp,
64797         so first arguments to gsub() are corrected. Also,
64798         in replacement strings, ampersand must be escaped.
64799         Finally, '&' must be handled first, then '<' and '>'.
64801 2013-09-24  Eric Blake  <eblake@redhat.com>
64803         manywarnings: enable nicer gcc warning messages
64804         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Older gcc requires
64805         some -f options for optimal warnings.
64807 2013-09-21  Jim Meyering  <meyering@fb.com>
64809         timespec: use the new TIMESPEC_RESOLUTION in a few more places
64810         * lib/timespec-add.c (timespec_add): Also replace 999999999
64811         with TIMESPEC_RESOLUTION - 1.
64812         * lib/timespec-sub.c (timespec_sub): Likewise.
64814 2013-09-23  Paul Eggert  <eggert@cs.ucla.edu>
64816         warnings: port --enable-gcc-warnings to Solaris Studio 12.3
64817         Problem reported by Dagobert Michelsen via Eric Blake in
64818         <http://lists.gnu.org/r/bug-gnulib/2013-09/msg00052.html>.
64819         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Use AC_LINK_IFELSE,
64820         not AC_COMPILE_IFELSE.
64822 2013-09-23  Eric Blake  <eblake@redhat.com>
64824         configmake: support new --runstatedir option
64825         * m4/configmake.m4 (gl_CONFIGMAKE_PREP): Substitute runstatedir
64826         even if autoconf was too old to provide the command line option.
64827         * modules/configmake (Makefile.am): Propagate it to .h file.
64829 2013-09-22  Paul Eggert  <eggert@cs.ucla.edu>
64831         ctype, string: depend on extern-inline
64832         This is needed to complete the recent OS X fixes.
64833         Also, fix related documentation as suggested by Eric Blake.
64834         * doc/posix-functions/isalnum.texi, doc/posix-functions/isalpha.texi:
64835         * doc/posix-functions/isascii.texi, doc/posix-functions/iscntrl.texi:
64836         * doc/posix-functions/isdigit.texi, doc/posix-functions/isgraph.texi:
64837         * doc/posix-functions/islower.texi, doc/posix-functions/isprint.texi:
64838         * doc/posix-functions/ispunct.texi, doc/posix-functions/isspace.texi:
64839         * doc/posix-functions/isupper.texi, doc/posix-functions/isxdigit.texi:
64840         * doc/posix-functions/toascii.texi, doc/posix-functions/tolower.texi:
64841         * doc/posix-functions/toupper.texi:
64842         List the 'ctype' gnulib module.
64843         * doc/posix-functions/strcat.texi, doc/posix-functions/strcpy.texi:
64844         * doc/posix-functions/strncpy.texi:
64845         List the 'string' gnulib module.
64846         * modules/memcpy, modules/memmove, modules/memset (Depends-on):
64847         Add string.
64848         * modules/ctype, modules/string (Depends-on): Add extern-inline.
64850 2013-09-19  Pádraig Brady  <P@draigBrady.com>
64852         userspec: support optional parameters to parse_user_spec()
64853         * lib/userspec.c (parse_user_spec): If the GID param is NULL,
64854         then avoid group processing and treat the full spec as a user.
64855         (parse_with_separator): Allow the USERNAME and GROUPNAME to
64856         be optional params (NULL), in which case they're ignored.
64858 2013-09-19  Paul Eggert  <eggert@cs.ucla.edu>
64860         timespec: new function make_timespec, and new constants
64861         * lib/timespec.h: Incorporate recent changes on the Emacs trunk.
64862         (TIMESPEC_RESOLUTION, LOG10_TIMESPEC_RESOLUTION): New constants.
64863         (make_timespec): New function.
64864         * lib/dtotimespec.c (dtotimespec):
64865         * lib/timespec-add.c (timespec_add):
64866         * lib/timespec-sub.c (timespec_sub):
64867         * lib/utimens.c (validate_timespec):
64868         * lib/utimensat.c (rpl_utimensat):
64869         Use these new constants and functions.
64871         stdio: OS X port of putc_unlocked + extern inline
64872         * lib/stdio.in.h (putc_unlocked): #undef on problematic Apple platforms.
64873         * doc/posix-functions/putc_unlocked.texi:
64874         * doc/posix-functions/putchar_unlocked.texi:
64875         Document this portability problem.
64877         signal: OS X port of sigaddset etc. + extern inline
64878         * lib/signal.in.h (sigaddset, sigdelset, sigemptyset, sigfillset)
64879         (sigismember): #undef on problematic Apple platforms.
64880         * doc/posix-functions/sigaddset.texi:
64881         * doc/posix-functions/sigdelset.texi:
64882         * doc/posix-functions/sigemptyset.texi:
64883         * doc/posix-functions/sigfillset.texi:
64884         * doc/posix-functions/sigismember.texi:
64885         Document this portability problem.
64887         extern-inline: do not always suppress extern inline on OS X
64888         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Suppress the use of
64889         extern inline on Apple only if the particular compile-time
64890         configuration is known to have the problem.
64891         (_GL_EXTERN_INLINE_APPLE_BUG): New private macro, to implement this.
64892         (_GL_EXTERN_INLINE_IN_USE): New macro, intended for use by
64893         other Gnulib modules.
64895         extern-inline: document fixes for ctype and wctype macros
64896         * doc/posix-functions/isalnum.texi, doc/posix-functions/isalpha.texi:
64897         * doc/posix-functions/isascii.texi, doc/posix-functions/isblank.texi:
64898         * doc/posix-functions/iscntrl.texi, doc/posix-functions/isdigit.texi:
64899         * doc/posix-functions/isgraph.texi, doc/posix-functions/islower.texi:
64900         * doc/posix-functions/isprint.texi, doc/posix-functions/ispunct.texi:
64901         * doc/posix-functions/isspace.texi, doc/posix-functions/isupper.texi:
64902         * doc/posix-functions/iswalnum.texi, doc/posix-functions/iswalpha.texi:
64903         * doc/posix-functions/iswcntrl.texi, doc/posix-functions/iswctype.texi:
64904         * doc/posix-functions/iswdigit.texi, doc/posix-functions/iswgraph.texi:
64905         * doc/posix-functions/iswlower.texi, doc/posix-functions/iswprint.texi:
64906         * doc/posix-functions/iswpunct.texi, doc/posix-functions/iswspace.texi:
64907         * doc/posix-functions/iswupper.texi, doc/posix-functions/iswxdigit.texi:
64908         * doc/posix-functions/isxdigit.texi, doc/posix-functions/toascii.texi:
64909         * doc/posix-functions/memcpy.texi, doc/posix-functions/memmove.texi:
64910         * doc/posix-functions/memset.texi, doc/posix-functions/stpcpy.texi:
64911         * doc/posix-functions/stpncpy.texi, doc/posix-functions/strcat.texi:
64912         * doc/posix-functions/strcpy.texi, doc/posix-functions/strncat.texi:
64913         * doc/posix-functions/strncpy.texi:
64914         * doc/posix-functions/tolower.texi, doc/posix-functions/toupper.texi:
64915         * doc/posix-functions/towlower.texi, doc/posix-functions/towupper.texi:
64916         Document that Gnulib fixes portability problems with these
64917         functions on OS X 10.8 and earlier when called from plain inline
64918         or extern inline functions.
64920 2013-09-17  Kevin Cernekee  <cernekee@gmail.com>
64922         fflush, freadahead, fseeko: Fix for Android
64923         Suggested by Bruno Haible in:
64924         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00306.html>
64925         * lib/stdio-impl.h: Use local __sfileext definition.
64927 2013-09-17  Mats Erik Andersson  <gnu@gisladisker.se>
64929         pmccabe2html: Portability to other awk versions.
64930         The functions systime() and strftime() are available
64931         in Gawk only.  Properly close two HTML-tags 'style'
64932         and 'span'.
64933         * build-aux/pmccabe2html (BEGIN): Store timing
64934         strings in EPOCH_TIME and CHRONOS_TIME.  Replace
64935         systime() in HTML_COMMENT.
64936         (html_header): Correctly close tag 'style'.
64937         (END): Replace strftime() by CHRONOS_TIME.  Close
64938         tag 'span' correctly, not as 'div'.
64940 2013-09-17  Mats Erik Andersson  <gnu@gisladisker.se>  (tiny change)
64942         getgroups: statement without effect
64943         * lib/getgroups.c (rpl_getgroups) [HAVE_GETGROUPS]:
64944         Change equality conditional to expected assignment.
64946 2013-09-09  Eric Blake  <eblake@redhat.com>
64948         glob: fix compilation
64949         * lib/glob.in.h (__THROW): Fix missing line in previous commit.
64951 2013-09-07  Eric Blake  <eblake@redhat.com>
64953         glob: fix build for platforms without __THROW
64954         * lib/glob.in.h (__THROW): Add definition again.
64956 2013-09-04  Anton Ovchinnikov  <revolver112@gmail.com>  (tiny change)
64958         regex-quote: fix buffer access out of bounds
64959         http://lists.gnu.org/r/bug-gnulib/2013-09/msg00001.html
64960         * lib/regex-quote.c (regex_quote_spec_pcre):
64961         Fix typo that resulted in an out-of-bounds read.
64963 2013-09-04  Eric Blake  <eblake@redhat.com>
64965         glob: avoid -Wattribute warnings on glibc
64966         * lib/glob.c (next_brace_sub, prefix_array, collated_compare): Use
64967         __THROWNL, not __THROW, on static functions.
64968         * lib/glob.in.h (__THROW): Adjust...
64969         (__THROWNL): ...accordingly.
64971 2013-08-28  Paul Eggert  <eggert@cs.ucla.edu>
64973         headers: check that _GL_INLINE_HEADER_BEGIN is defined
64974         Suggested by Bruce Korb in:
64975         http://lists.gnu.org/r/bug-gnulib/2013-08/msg00070.html
64976         * doc/extern-inline.texi (extern inline):
64977         Suggest checking that _GL_INLINE_HEADER_BEGIN is defined.
64978         * lib/acl-internal.h, lib/argp-fmtstream.h, lib/argp.h:
64979         * lib/binary-io.h, lib/bitrotate.h, lib/count-leading-zeros.h:
64980         * lib/count-one-bits.h, lib/eealloc.h, lib/execinfo.in.h:
64981         * lib/gethrxtime.h, lib/gl_list.h, lib/gl_oset.h, lib/gl_xlist.h:
64982         * lib/gl_xoset.h, lib/gl_xsublist.h, lib/glthread/cond.h:
64983         * lib/glthread/thread.h, lib/math.in.h, lib/mbchar.h, lib/mbfile.h:
64984         * lib/mbiter.h, lib/mbuiter.h, lib/openat.h, lib/pipe-filter-aux.h:
64985         * lib/priv-set.h, lib/pthread.in.h, lib/savewd.h, lib/se-context.in.h:
64986         * lib/se-selinux.in.h, lib/sig-handler.h, lib/stat-time.h:
64987         * lib/sys_socket.in.h, lib/timespec.h, lib/u64.h, lib/unistd.in.h:
64988         * lib/utimens.h, lib/wctype.in.h, lib/xalloc.h, lib/xsize.h:
64989         * lib/xtime.h:
64990         Check that _GL_INLINE_HEADER_BEGIN is defined.
64992 2013-08-29  Pádraig Brady  <P@draigBrady.com>
64994         bootstrap: remove the --version requirement from ancillary tools
64995         * build-aux/bootstrap (check_exists): A new refactored function to
64996         determine if a command exists.
64997         (find_tool): Use the new function which does not require the
64998         --version option to be supported.
64999         (check_versions): Use the new function.
65001 2013-08-26  Simon Josefsson  <simon@josefsson.org>
65003         gc: support HMAC-SHA256 and HMAC-SHA512.
65004         * lib/gc.h: Add gc_hmac_sha256 and gc_hmac_sha512.
65005         * lib/gc-libgcrypt.c (gc_hmac_sha256, gc_hmac_sha512): New
65006         functions.
65007         (gc_hmac_md5): Use symbolic constant.
65008         * lib/gc-gnulib.c: Include hmac.h for HMAC-SHA256/512 too.
65009         (gc_hmac_sha256, gc_hmac_sha512): New functions.
65010         * lib/hmac.h: Add hmac_sha256 and hmac_sha512 prototypes.
65011         * m4/sha256.m4: Protect against empty expansion.
65012         * m4/sha512.m4: Likewise.
65013         * lib/hmac-sha256.c: New file.
65014         * lib/hmac-sha512.c: Likewise.
65015         * m4/gc-hmac-sha256.m4: Likewise.
65016         * m4/gc-hmac-sha512.m4: Likewise.
65017         * m4/gc-sha256.m4: Likewise.
65018         * m4/gc-sha512.m4: Likewise.
65019         * modules/crypto/gc-hmac-sha256: Likewise.
65020         * modules/crypto/gc-hmac-sha256-tests: Likewise.
65021         * modules/crypto/gc-hmac-sha512: Likewise.
65022         * modules/crypto/gc-hmac-sha512-tests: Likewise.
65023         * modules/crypto/hmac-sha256: Likewise.
65024         * modules/crypto/hmac-sha256-tests: Likewise.
65025         * modules/crypto/hmac-sha512: Likewise.
65026         * modules/crypto/hmac-sha512-tests: Likewise.
65027         * tests/test-gc-hmac-sha256.c: Likewise.
65028         * tests/test-gc-hmac-sha512.c: Likewise
65029         * tests/test-hmac-sha256.c: Likewise.
65030         * tests/test-hmac-sha512.c: Likewise
65032 2013-08-24  Daiki Ueno  <ueno@gnu.org>
65034         * m4/intl.m4: Update from gettext-0.18.3.1, which fixes a misuse
65035         of AC_CHECK_DECLS.
65037 2013-08-23  Paul Eggert  <eggert@cs.ucla.edu>
65039         selinux-at: omit unnecessary include
65040         * lib/selinux-at.c: Don't include dosname.h; not needed, since
65041         this source file doesn't use its macros, and subsidiary files that
65042         use the macros already include it.
65044 2013-08-21  Eric Blake  <eblake@redhat.com>
65046         d-ino: avoid false negative on symlink
65047         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use lstat.
65048         Reported by Stephane Chazelas.
65050 2013-08-12  Mike Miller  <mtmiller@ieee.org>  (tiny change)
65052         bootstrap: port to OpenBSD sed
65053         * build-aux/bootstrap (insert_if_absent): Port to OpenBSD sed which
65054         does not interpret `-' as a file argument to mean stdin.
65056 2013-08-15  Eric Blake  <eblake@redhat.com>
65058         warnings: minor optimization
65059         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Use fewer processes.
65061         warnings: check -Wfoo rather than -Wno-foo
65062         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): If name begins with
65063         -Wno-, test if the compiler recognizes the positive form instead.
65065 2013-08-15  Karl Berry  <karl@gnu.org>
65067         * config/srclist-update: add option "doclicense" to placate
65068         pulling *.texi files from Emacs.  Write terse usage
65069         documentation at the top.
65071 2013-08-13  Paul Eggert  <eggert@cs.ucla.edu>
65073         xvasprintf-tests: port to GCC with hardening flags
65074         * tests/test-xvasprintf.c (test_xasprintf): Pass another arg to
65075         xasprintf, to pacify GCC.  Reported by Santiago Vila in:
65076         http://lists.gnu.org/r/bug-diffutils/2013-08/msg00002.html
65078 2013-08-11  Paul Eggert  <eggert@cs.ucla.edu>
65080         fpending: port to recent Cygwin change to stdio_ext.h
65081         Reported by LRN in
65082         <http://lists.gnu.org/r/bug-gnulib/2013-08/msg00028.html>.
65083         * lib/fpending.h: Don't worry about HAVE_DECL___FPENDING;
65084         just declare __fpending unless it's a macro.
65085         A duplicate decl shouldn't hurt.
65086         * m4/fpending.m4 (gl_FUNC_FPENDING): Check that an __fpending
65087         call compiles and links, instead of separately checking for
65088         decl and lib function.
65089         * modules/fpending (configure-ac):
65090         Adjust to fpending.m4's renaming of shell variable.
65092 2013-08-10  Paul Eggert  <eggert@cs.ucla.edu>
65094         sys_time: port to OpenBSD
65095         * lib/sys_time.in.h: Simply delegate to the system's header
65096         in the BSDish cases as well.  Problem reported by Mike Miller in
65097         <http://lists.gnu.org/r/bug-gnulib/2013-08/msg00016.html>.
65098         * tests/test-sys_select.c, tests/test-sys_time.c (verify_tv_sec_type):
65099         Allow platforms like 64-bit OpenBSD where timeval's tv_sec is
65100         wider than time_t.
65102 2013-08-09  Pádraig Brady  <P@draigBrady.com>
65104         bootstrap: support checksum utils having -c but not --status
65105         * build-aux/bootstrap: Only look for sha1sum if updating po files.
65106         Add sha1 to the list of supported checksum utils since it's now
65107         supported through adjustments below.
65108         (update_po_files): Remove the use of --status
65109         in a way that will suppress all error messages, but since this is
65110         only used to minimize updates, it shouldn't cause an issue.
65111         Exit early if there is a problem updating the po file checksums.
65112         (find_tool): Remove the check for --version support as this
65113         is optional as per commit 86186b17.  Don't even check for the
65114         presence of the command as if that is needed, it's supported
65115         through configuring prerequisites in bootstrap.conf.
65116         Prompt that when a tool isn't found, one can define an environment
65117         variable to add to the hardcoded search list.
65119 2013-08-05  Jim Meyering  <meyering@fb.com>
65121         regex: port to non-glibc/lock-using systems
65122         Since 29-05-2013 commit, 55ba71f4, compilation on a non-glibc
65123         system with GNULIB_LOCK would fail due to absence of the
65124         included "glthread/lock.h".  This would affect any package
65125         for which the "lock" module is used only by the regex module,
65126         and not explicitly used.
65127         * m4/regex.m4 (gl_PREREQ_REGEX): Require gl_GLIBC21.
65128         * modules/regex (Depends-on) [!GLIBC && $ac_use_included_regex]:
65129         Add a dependency on the "lock" module.
65131 2013-07-20  Daiki Ueno  <ueno@gnu.org>
65133         localecharset: make locale_charset thread-safe on Mac OS X
65134         * lib/localcharset.c (locale_charset) [DARWIN7]: Use MB_CUR_MAX_L
65135         instead of MB_CUR_MAX.
65137 2013-07-20  Daiki Ueno  <ueno@gnu.org>
65139         gettext: update to version 0.18.3
65140         * m4/intl.m4, m4/po.m4: Update from gettext-0.18.3.  In particular,
65141         require AC_PROG_SED to allow user to specify custom sed command when
65142         generating en@quot PO file.
65144 2013-07-18  Werner Lemberg  <wl@gnu.org>  (tiny change)
65146         bootstrap: use correct source when copying build-aux files
65147         * build-aux/bootstrap (gnulib_extra_files): This variable is
65148         relative to upstream gnulib layout, not downstream.
65150 2013-07-17  Paul Eggert  <eggert@cs.ucla.edu>
65152         tmpdir: fix bug in VMS port
65153         * lib/tmpdir.c (path_search) [__VMS]: Never add slash.
65154         See Steven M. Schweda in
65155         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00026.html>.
65157 2013-07-15  Paul Eggert  <eggert@cs.ucla.edu>
65159         tmpdir: port to VMS, to // != /, and to long dirs
65160         * lib/tmpdir.c (__libc_secure_getenv) [!_LIBC]: Rename from
65161         __secure_getenv, so that we're more like the glibc version.
65162         All uses changed.
65163         (path_search): Don't put slash after directory if __VMS.
65164         Problem reported by Steven M. Schweda in
65165         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00019.html>.
65166         Simplify code to add slash; no need for a loop.
65167         Do not remove trailing slash from "//".
65168         Do not assume dlen <= INT_MAX.
65170 2013-07-09  Paul Eggert  <eggert@cs.ucla.edu>
65172         regex: port to --with-included-regex --enable-gcc-warnings non-threaded
65173         * lib/regex_internal.h (lock_fini, lock_lock): Rework to avoid
65174         gcc warnings in the non-threaded case.  Reported by Charlie Brown in
65175         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00015.html>.
65177         accept4, dup3, pipe2: port to Cygwin
65178         Problem reported for Emacs by Ken Brown in <http://bugs.gnu.org/14821>.
65179         * lib/accept4.c (accept4) [O_BINARY]:
65180         * lib/dup3.c (dup3) [O_BINARY]:
65181         * lib/pipe2.c (pipe2) [O_BINARY]:
65182         Use set_binary_mode, not setmode.
65183         * lib/pipe2.c [!GNULIB_BINARY_IO]: Include binary-io.h.
65184         * modules/binary-io (Depends-on): Remove module indicator.
65185         These last two bits undo the previous change to pipe2 and binary-io.
65187 2013-07-09  Pádraig Brady  <P@draigBrady.com>
65189         mountlist: add support for deallocating returned list entries
65190         * lib/mountlist.c (free_mount_entry): A new exported function
65191         to deallocate a mount list entry.
65192         (read_file_system_list): Refactor to use the new deallocation function.
65193         Suggested by Anton Ovchinnikov.
65195 2013-07-07  Paul Eggert  <eggert@cs.ucla.edu>
65197         stdalign, verify: port to FreeBSD 9.1, to C11, and to C++11
65198         Problem reported by Ulrich Mueller in <http://bugs.gnu.org/14812>.
65199         * lib/stdalign.in.h (_Alignas, _Alignof):
65200         Port to FreeBSD 9.1, and to C11 and C++11.
65201         (_Alignas): Also support ICC.
65202         * lib/verify.h (_Static_assert): Undef if <stddef.h> defines it.
65203         * m4/stdalign.m4 (gl_STDALIGN_H): Port to ICC and to C++11.
65205 2013-07-06  Paul Eggert  <eggert@cs.ucla.edu>
65207         fnmatch: don't goto over declaration
65208         * lib/fnmatch_loop.c (FCT): Hoist local up one level, to avoid
65209         undefined behavior for goto over a declaration.
65210         Problem reported by Charlie Brown in
65211         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00009.html>.
65213         pipe2: decouple from binary-io a bit
65214         This is for Emacs, which needs pipe2 but not binary-io.
65215         * lib/pipe2.c [!GNULIB_BINARY_IO]: Don't include binary-io.h.
65216         * modules/binary-io (Depends-on): Add module indicator.
65218 2013-07-03  Eric Blake  <eblake@redhat.com>
65220         mgetgroups: relax license to LGPLv2+
65221         * modules/getugroups (License): Change from GPLv3+.
65222         * modules/mgetgroups (License): Likewise.
65223         * modules/getgroups (License): Change from LGPLv3+.
65225         xalloc-oversized: relax license to LGPLv2+
65226         * modules/xalloc-oversized (License): Change from GPLv3+.
65228         nproc: relax license to LGPLv2+
65229         * modules/nproc (License): Change from LGPLv3+.
65231         bootstrap: honor --no-git
65232         * build-aux/bootstrap: Don't even try to use git when user is
65233         pointing to a static checkout.
65235 2013-06-23  Paul Eggert  <eggert@cs.ucla.edu>
65237         ignore-value: port to gcc -pedantic
65238         * lib/ignore-value.h (ignore_value):
65239         Port to gcc -pedantic, by using __extension__.
65240         Reindent as per usual gnulib style nowadays.
65241         Simplify GCC version check.
65243 2013-06-21  Paul Eggert  <eggert@cs.ucla.edu>
65245         extern-inline: port to gcc -std=c89
65246         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
65247         Do not use __gnu_inline__ if pedantic and pre-C99.
65249 2013-06-18  Paul Eggert  <eggert@cs.ucla.edu>
65251         doc: document extern-inline
65252         * doc/extern-inline.texi: New file.
65253         * doc/gnulib.texi (alloca-opt): Include it.
65254         * m4/extern-inline.m4: Move some comments to documentation,
65255         and others closer to what they describe.
65257         doc: chatter less
65258         * doc/Makefile (NEWEST_GNULIB_TEXI_FILE): New macro.
65259         (updated-stamp): Use it.  This causes 'make' to output just
65260         one file name rather than zillions.
65262         fflush, fseeko: port to musl cross-compiles
65263         * lib/fseeko.c (fseeko): Assume that fflushing stdin works if
65264         on some implementation that (1) is not known to be buggy,
65265         (2) claims conformance to POSIX.1-2008 or later, and (3) is being
65266         cross-compiled to so we can't easily check for lack of
65267         conformance.  This is for cross-compiling to musl.
65268         Reported by Rich Felker in
65269         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00043.html>.
65270         * m4/fclose.m4 (gl_FUNC_FCLOSE):
65271         * m4/fflush.m4 (gl_FUNC_FFLUSH):
65272         * m4/fseeko.m4 (gl_FUNC_FSEEKO):
65273         Adjust to above change.
65274         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Set gl_cv_func_fflush_stdin
65275         to 'cross', not to 'no', when cross-compiling.  AC_DEFINE
65276         FUNC_FFLUSH_STDIN to 1, 0, -1 if fflushing stdin is known to work,
65277         known not to work, or unknown.
65279 2013-06-15  Paul Eggert  <eggert@cs.ucla.edu>
65281         msvc-inval: port to mingw-w64
65282         * lib/msvc-inval.c (gl_msvc_invalid_parameter_handler):
65283         Use __cdecl, not cdecl, for mingw-w64.  Reported by LRN in
65284         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00039.html>.
65286 2013-06-11  Paul Eggert  <eggert@cs.ucla.edu>
65288         getcwd-lgpl: port to Tru64
65289         * lib/getcwd-lgpl.c: Include <stdlib.h>, for malloc etc.
65290         Problem reported by Steven M. Schweda in
65291         <http://lists.gnu.org/r/bug-gzip/2013-06/msg00010.html>.
65293         tests: port large-fd POSIX spawn tests to OS X
65294         Problem reported by Daiki Ueno in
65295         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00031.html>.
65296         * tests/test-posix_spawn_file_actions_addclose.c:
65297         * tests/test-posix_spawn_file_actions_adddup2.c:
65298         * tests/test-posix_spawn_file_actions_addopen.c:
65299         Include <limits.h>, for OPEN_MAX, if available.
65300         (big_fd): New static function.
65301         (main): Use it.
65303 2013-06-04  Bernhard Voelker  <mail@bernhard-voelker.de>
65305         tests/nap.h: use an adaptive delay to avoid ctime update issues
65306         The recent change in nap.h (5191133e) decreased the probability of lost
65307         races to about a third, however such problems could still be observed
65308         in virtual machines and openSUSE's OBS.
65309         Before, nap() detected the needed time once empirically and then used
65310         that delay (together with a small correction multiplier) in further
65311         calls.  This problem has been reported and discussed several times,
65312         including guesses about possible kernel issues:
65313         https://lists.gnu.org/r/bug-gnulib/2013-04/msg00071.html
65314         http://lists.gnu.org/r/coreutils/2012-03/msg00088.html
65315         https://lists.gnu.org/r/bug-gnulib/2011-11/msg00226.html
65316         http://bugs.gnu.org/12820
65317         https://lists.gnu.org/r/bug-gnulib/2010-11/msg00113.html
65318         https://lists.gnu.org/r/bug-gnulib/2009-11/msg00007.html
65319         Now, nap() avoids the race alltogether by verifying on a reference
65320         file whether a timestamp difference has happened.
65321         * tests/nap.h (nap_fd): Define file descriptor variable for the
65322         witness file.
65323         (nap_works): Change return value to bool.  Change passing
65324         the old file's status by value instead of by reference as this function
65325         does no longer update that timestamp; rename the function argument from
65326         st to old_st.  Remove the local variables cdiff and mdiff because that
65327         function now returns true/false instead of the precise delay.
65328         (guess_delay): Remove function.
65329         (clear_tmp_file): Add new function to close and unlink the witness file.
65330         (nap): Instead of re-using the delay which has been calculated during
65331         the first call, avoid the race by actually verifying that a timestamp
65332         difference can be observed on the current file system.  Use an adaptive
65333         approach for the delay to minimize execution time.  Assert that the
65334         maximum delay is <= ~2 seconds, more precisely sum(2^n) from 0 to 30
65335         = 2^31 - 1 = 2.1s.
65336         Use atexit to call clear_tmp_file when the process terminates.
65338 2013-06-02  Paul Eggert  <eggert@cs.ucla.edu>
65340         sig2str: port to C++
65341         * lib/sig2str.h (sig2str, str2sig): Declare as extern "C".
65342         Reported by Daniel J Sebald in
65343         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00000.html>.
65345 2013-05-30  Eric Blake  <eblake@redhat.com>
65347         docs: mention cygwin shortcoming in <sys/un.h>
65348         * doc/posix-headers/sys_un.texi (sys/un.h): Mention problem.
65350         vasnprintf: silence mingw compiler warning
65351         * lib/vasnprintf.c (VASNPRINTF): Avoid unused variable warning.
65353 2013-05-29  Paul Eggert  <eggert@cs.ucla.edu>
65355         c-ctype, regex, verify: port to gcc -std=c90 -pedantic
65356         Avoid constructions that are rejected by gcc -std=c90 -pedantic.
65357         This fixes a porting bug I recently reintroduced in regex, and
65358         some other instances that I discovered while testing the fix.
65359         * lib/c-ctype.h [__STRICT_ANSI__]: Avoid ({ ... }).
65360         * lib/regcomp.c (utf8_sb_map) [__STRICT_ANSI__]: Avoid [0 ... N] = E.
65361         * lib/regex_internal.h [!_LIBC && GNULIB_LOCK]: Do not use a macro
65362         with an empty argument if this is a pedantic pre-C99 GCC.
65363         * lib/verify.h: Do not use _Static_assert if this is a pedantic
65364         pre-C11 GCC.
65366         regex: adapt to locking regime instead of depending on pthread
65367         Instead of depending on pthread, adapt to whatever thread
65368         modules are in use.  Problem reported by Ludovic Courtès in
65369         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00082.html>
65370         and by Mats Erik Andersson in
65371         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00100.html>.
65372         * lib/regex_internal.h (lock_define, lock_init, lock_fini):
65373         Support either the 'lock' module, or the 'pthread' module, or
65374         no module.
65375         (lock_lock, lock_unlock): New macros.
65376         * lib/regexec.c (regexec, re_search_stub): Use the new macros.
65377         * modules/lock, modules/pthread (configure.ac): Add module indicator.
65378         * modules/regex (Depends-on): Remove pthread.
65380 2013-05-22  Eric Blake  <eblake@redhat.com>
65382         getgroups: document portability issues
65383         * doc/glibc-functions/initgroups.texi (initgroups): Mention
65384         multithread safety.
65385         * doc/posix-functions/getpwuid.texi (getpwuid): Likewise.
65386         * doc/posix-functions/getpwuid_r.texi (getpwuid_r): Likewise.
65387         * doc/glibc-functions/getgrouplist.texi (getgrouplist): Mention
65388         getugroups.
65389         * doc/posix-functions/getgroups.texi (getgroups): Mention
65390         multithread safety and mgetgroups.
65392 2013-05-22  Bernhard Voelker  <mail@bernhard-voelker.de>
65394         test-lchown, test-chown: also skip test if chown fails with EPERM
65395         * tests/test-lchown.h (test_lchown): Add EPERM to the condition to
65396         skip this test, to handle FAT file systems.
65397         * tests/test-chown.h (test_chown): Likewise.
65399 2013-05-19  Paul Eggert  <eggert@cs.ucla.edu>
65401         regex: fix dfa race in multithreaded uses
65402         Problem reported by Ludovic Courtès in
65403         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00058.html>.
65404         * lib/regex_internal.h (lock_define, lock_init, lock_fini):
65405         New macros.  All uses of __libc_lock_define, __libc_lock_init
65406         changed to use the first two of these.
65407         (__libc_lock_lock, __libc_lock_unlock): New macros, for
65408         non-glibc platforms.
65409         (struct re_dfa_t): Define the lock unconditionally.
65410         * lib/regexec.c (regexec, re_search_stub): Remove some now-incorrect
65411         '#ifdef _LIBC"s.
65412         * modules/regex (Depends-on): Add pthread, if we use the
65413         included regex.
65415         * lib/regcomp.c: Do actions that are not needed for glibc,
65416         but may be needed elsewhere.
65417         (regfree, re_compile_internal): Destroy the lock.
65418         (re_compile_internal): Check for lock-initialization failure.
65420         malloca: port to compilers that reject size-zero arrays
65421         This fixes a bug introduced in my previous patch.
65422         * lib/malloca.c (struct preliminary_header): Use an int
65423         rather than a character array of size int; that's simpler.
65424         (struct header): Remove, replacing with ...
65425         (union header): New type.  This avoids the need for declaring a
65426         character array of size zero, which is not allowed on some platforms.
65427         All uses changed.
65429 2013-05-18  Paul Eggert  <eggert@cs.ucla.edu>
65431         parse-datetime, tests: don't use "string" + int
65432         Recent versions of 'clang' complain about C source code that
65433         uses expressions of the form '"string literal" + integer',
65434         I guess on the theory that it's confusing for readers who are
65435         used to C++.  On those grounds I suppose it's OK to make this
65436         minor style change.
65437         * lib/parse-datetime.y (parse_datetime):
65438         * tests/test-fchdir.c (main):
65439         * tests/test-snprintf-posix.h (test_function):
65440         * tests/test-snprintf.c (main):
65441         * tests/test-vasnprintf-posix.c (test_function):
65442         * tests/test-vasnprintf.c (test_function):
65443         * tests/test-vsnprintf.c (main):
65444         * tests/unistdio/test-ulc-asnprintf1.h (test_function):
65445         Rewrite '"str" + E' to '&"str"[E]'.
65447 2013-05-17  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
65449         argmatch: port to C++
65450         * lib/argmatch.h [__cplusplus]: Add extern "C".
65452         argp: typo fix
65453         * lib/argp-help.c: Typo in comment.
65455 2013-05-15  Paul Eggert  <eggert@cs.ucla.edu>
65457         manywarnings: update for GCC 4.8.0
65458         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
65459         Add -Waggressive-loop-optimizations, -Wreturn-local-addr, which
65460         are new to GCC 4.8.  Remove -Wformat=2, -Wmissing-format-attribute,
65461         -Wmissing-noreturn, as they are duplicates of other warnings.
65462         Remove -Wunreachable-code, as it is removed in GCC 4.8 and
65463         was documented to be flaky in earlier versions of GCC.
65465         spawn-tests, sys_socket-tests, sys_wait-tests: port to clang
65466         * tests/test-spawn.c (main):
65467         * tests/test-sys_socket.c (main):
65468         * tests/test-sys_wait.c (main):
65469         Don't have a switch value that isn't covered by a case.
65471         getaddrinfo-tests: port --enable-gcc-warnings to clang
65472         * tests/test-getaddrinfo.c (simple):
65473         Avoid casts from looser to stricter-aligned pointers.
65475         thread: port --enable-gcc-warnings to clang
65476         * lib/glthread/thread.h [__clang__ && USE_POSIX_THREADS_WEAK]:
65477         Include <signal.h>, to pacify a warning about pthread_sigmask.
65479         stdio: use __REDIRECT for fwrite, fwrite_unlocked
65480         * lib/stdio.in.h (fwrite):
65481         When working around bug 11959, use __REDIRECT rather than '#define
65482         fwrite(...) ... fwrite (...) ...'.  This is a more-targeted way to
65483         fix the -Wunused-value issue with clang, and it works with GCC too.
65484         Problem with targeting reported by Eric Blake in
65485         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00067.html>.
65486         (fwrite_unlocked): Treat like fwrite.  I ran into this issue while
65487         debugging the fwrite issue.
65489         stdio: port --enable-gcc-warnings to clang
65490         * lib/stdio.in.h (fwrite) [__clang__]: Ignore -Wunused-value entirely,
65491         since the GCC workaround for fwrite does not pacify clang.
65493         sig2str: port --enable-gcc-warnings to clang
65494         * lib/sig2str.c (sig2str): Avoid warning about unused printf argument.
65496         obstack: port --enable-gcc-warnings to clang
65497         * lib/obstack.h (obstack_ptr_grow_fast, obstack_int_grow_fast):
65498         Avoid casts from looser to stricter-aligned pointers.
65500         memchr2: port --enable-gcc-warnings to clang
65501         * lib/memchr2.c (memchr2):
65502         Avoid casts from looser to stricter-aligned pointers.
65504         mbsstr: port --enable-gcc-warnings to clang
65505         * lib/mbsstr.c (knuth_morris_pratt_multibyte):
65506         Avoid casts from looser to stricter-aligned pointers.
65508         malloca: port --enable-gcc-warnings to clang
65509         * lib/malloca.c (struct header): New member 'magic', to avoid casts.
65510         (mmalloca): Avoid casts from looser to stricter-aligned pointers.
65512         inttostr: port --enable-gcc-warnings to clang
65513         * lib/anytostr.c [__clang__]: Ignore -Wtautological-compare.
65515         warnings: port to clang
65516         Problem reported by Daniel P. Berrange via Eric Blake in
65517         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00055.html>.
65518         * m4/warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS): New macro.
65519         (gl_WARN_ADD): Use it.
65521 2013-05-11  Jim Meyering  <meyering@fb.com>
65523         quotearg: do not read beyond end of buffer
65524         * lib/quotearg.c (quotearg_buffer_restyled): Do not read beyond the
65525         end of an ARG for which no length was specified.  With an N-byte
65526         quote string, (e.g., N is 3 in the fr_FR.UTF-8 locale), this function
65527         would read N-2 bytes beyond ARG's trailing NUL.  This was triggered
65528         via coreutils' misc/sort-debug-keys.sh test and detected by running
65529         the test against a binary compiled with gcc-4.8.0's -fsanitize=address.
65530         * tests/test-quotearg-simple.c (main): Add a test to trigger the bug.
65531         * modules/quotearg-simple-tests (Files): Add tests/zerosize-ptr.h.
65532         Introduced via the 2000-01-15 commit, c4b7f3f8, "Quote multibyte
65533         characters correctly."
65535 2013-05-11  Daiki Ueno  <ueno@gnu.org>
65537         lock: work around pthread recursive mutexes bug in Mac OS X 10.6
65538         * m4/lock.m4: Don't define HAVE_PTHREAD_MUTEX_RECURSIVE if the
65539         compilation target is Mac OS X 10.6.
65540         Problem reported by parafin and Andoni Morales in
65541         <http://savannah.gnu.org/bugs/?37844> and
65542         <http://lists.gnu.org/r/bug-gettext/2013-05/msg00007.html>.
65544 2013-05-11  Paul Eggert  <eggert@cs.ucla.edu>
65546         mkdir-p: remove assumptions about umask and mode
65547         * lib/mkdir-p.c (make_dir_parents): Do not assume that the current
65548         umask is 0, or that MODE is a subset of MODE_BITS.
65550 2013-05-10  Eric Blake  <eblake@redhat.com>
65552         maint.mk: catch more abuse of HAVE_DECL in syntax-check
65553         * top/maint.mk (sc_prohibit_defined_have_decl_tests): Relax regex.
65555 2013-05-10  Stefano Lattarini  <stefano.lattarini@gmail.com>
65557         deps: require Automake >= 1.9.6 in generated Makefile fragments
65559         That is the same minimal version required in the DEPENDENCIES file.
65560         Moreover, the old code generated a requirement of Automake >= 1.5,
65561         and that is an insanely outdated version.
65563         * gnulib-tool: Bump minimal version requirement in AUTOMAKE_OPTIONS.
65564         * tests/havelib/rpathlx/Makefile.am: Likewise.
65565         * tests/havelib/rpathly/Makefile.am: Likewise.
65566         * tests/havelib/rpathlyx/Makefile.am: Likewise.
65567         * tests/havelib/rpathlz/Makefile.am: Likewise.
65568         * tests/havelib/rpathlzyx/Makefile.am: Likewise.
65569         * tests/havelib/rpathx/Makefile.am: Likewise.
65570         * tests/havelib/rpathy/Makefile.am: Likewise.
65571         * tests/havelib/rpathz/Makefile.am: Likewise.
65573 2013-05-08  Eric Blake  <eblake@redhat.com>
65575         bootstrap: AC_INIT may have more than four parameters
65576         * build-aux/bootstrap (extract_package_name): Correctly extract
65577         non-empty tarname field.  Avoid range in regex.
65578         Based on a report by Sami Kerola <kerolasa@iki.fi>.
65580 2013-05-07  Paul Eggert  <eggert@cs.ucla.edu>
65582         qacl: port to MS-Windows port of GNU Emacs
65583         * lib/acl-errno-valid.c (acl_errno_valid) [ENOTSUP == ENOSYS]:
65584         Omit the duplicate ENOTSUP case.  Needed for the MS-Windows
65585         port of GNU Emacs.  Problem reported by Eli Zaretskii in
65586         <http://bugs.gnu.org/14295#14>.
65588 2013-05-07  Mike Frysinger  <vapier@gentoo.org>
65590         acl: include quote.h
65591         * lib/copy-acl.c: Include quote.h.
65592         * lib/set-acl.c: Likewise.
65594 2013-05-06  Mike Frysinger  <vapier@gentoo.org>
65596         fchownat, renameat, unlinkat: update statat dependencies
65597         These modules use statat and lstatat, not fstatat; so depend on
65598         the statat module, which was split out recently from fstatat.
65599         * modules/fchownat, modules/unlinkat: Change fstatat to statat.
65600         * modules/renameat: Likewise.  Also delete fstat.
65601         URL: http://bugs.gentoo.org/468790
65603 2013-05-04  Stefano Lattarini  <stefano.lattarini@gmail.com>
65605         Assume gnulib is checked out from Git, not CVS
65607         In fact, access to the gnulib repository through CVS has been
65608         disabled, or more precisely, got broken and was never restored; see:
65609         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00008.html>
65611         Note that support for CVS is not removed completely and unthinkingly
65612         by this change: only support for CVS checkouts of gnulib itself is
65613         removed.  For example, the 'bootstrap' script still cater to .cvsingore
65614         files and CVS directories, for the benefit of those poor gnulib clients
65615         still stuck with CVS.  Ditto for the 'gnulib-tool' script itself.
65617         * gnulib-tool: Simplify accordingly.
65618         * posix-modules: Likewise.
65619         * MODULES.html.sh: Likewise.
65620         * doc/gnulib.texi: No longer mention the decommissioned CVS gnulib
65621         repository.
65622         * doc/gnulib-intro.texi: Likewise.
65623         * doc/gnulib-readme.texi: Likewise.
65624         * doc/gnulib-tool.texi: In the examples and explanations, refer to a
65625         sample '.gitignore' file rather than a sample '.cvsignore'.
65626         * NEWS: Update.
65627         * m4/extensions.m4: While at it, remove a comment mistakenly referring
65628         to "CVS Autoconf" rather than "git Autoconf".
65630 2013-04-30  Paul Eggert  <eggert@cs.ucla.edu>
65632         utimensat-tests, etc.: try to fix some races
65633         Problem reported by Bernhard Voelker in
65634         <http://lists.gnu.org/r/bug-gnulib/2013-04/msg00071.html>.
65635         I don't know whether this patch fixes that race condition, but it
65636         fixes *some* race conditions, so it should be a win.
65637         * modules/chown-tests (Depends-on):
65638         * modules/fchownat-tests (Depends-on):
65639         * modules/fdutimensat-tests (Depends-on):
65640         * modules/futimens-tests (Depends-on):
65641         * modules/lchown-tests (Depends-on):
65642         * modules/stat-time-tests (Depends-on):
65643         * modules/utimens-tests (Depends-on):
65644         * modules/utimensat-tests (Depends-on):
65645         Depend on nanosleep, not usleep.
65646         * modules/chown-tests (test_chown_LDADD):
65647         * modules/lchown-tests (test_lchown_LDADD):
65648         * modules/stat-time-tests (test_stat_time_LDADD):
65649         New macro.
65650         * modules/fchownat-tests (test_fchownat_LDADD):
65651         * modules/fdutimensat-tests (test_fdutimensat_LDADD):
65652         * modules/futimens-tests (test_futimens_LDADD):
65653         * modules/utimens-tests (test_utimens_LDADD):
65654         * modules/utimensat-tests (test_utimensat_LDADD):
65655         Add $(LIB_NANOSLEEP).
65656         * modules/stat-time-tests (Files): Add tests/nap.h.
65657         * tests/nap.h: Include <limits.h>, for INT_MAX.
65658         (lt_mtime): Remove.
65659         (diff_timespec): New function.
65660         (get_stat): Rename from get_mtime.  All callers changed.
65661         (nap_works): Determine the needed delay by inspecting the
65662         file system's timestamp jumps; this should be more reliable.
65663         Look at both mtime and ctime, and take the maximum of the two jumps.
65664         (nap_works, guess_delay):
65665         Return a nanosecond count, not a microsecond count.
65666         All callers changed.
65667         (nap_works, nap): Use nanosleep, not usleep.  Check for nanosleep
65668         failure.
65669         (nap): Multiply the guess by 1.125, to accommodate the case where
65670         the file system's clock is a bit slower than nanosleep's clock.
65671         * tests/test-stat-time.c (BASE): New macro.
65672         Include nap.h.
65673         (nap): Remove; nap.h now defines this.  This removes a duplicate
65674         implementation of 'nap'.
65676         utimens, utimensat: work around Solaris UTIME_OMIT bug
65677         Solaris 11.1 and Solaris 10 have the same UTIME_OMIT bug that
65678         Linux kernel 2.6.32 does.  Work around it in the same way.
65679         * doc/posix-functions/futimens.texi (futimens):
65680         * doc/posix-functions/utimensat.texi (utimensat): Document the bug.
65681         * lib/utimens.c (fdutimens, lutimens):
65682         * lib/utimensat.c (rpl_utimensat): Work around the bug.
65684         gettext: now it's your responsibility to add -I$(top_builddir)/intl
65685         Formerly, it was your responsibility to do this for all Makefile.ams
65686         other than Gnulib's.  Now it's your responsibility to do it for
65687         Gnulib's Makefile.am, too.
65688         * NEWS: Document this.
65689         * modules/gettext (AM_CPPFLAGS): Don't append -$(top_builddir)/intl.
65691         acl: include errno.h to get errno
65692         Reported by Daiki Ueno in
65693         <http://lists.gnu.org/r/bug-gnulib/2013-04/msg00073.html>.
65694         * lib/copy-acl.c, lib/set-acl.c: Include errno.h.
65696 2013-04-29  Paul Eggert  <eggert@cs.ucla.edu>
65698         tests: don't assume getdtablesize () <= 10000000
65699         * modules/cloexec-tests:
65700         * modules/dup2-tests:
65701         * modules/dup3-tests:
65702         * modules/nonblocking-tests:
65703         * modules/posix_spawn_file_actions_addclose-tests:
65704         * modules/posix_spawn_file_actions_adddup2-tests:
65705         * modules/posix_spawn_file_actions_addopen-tests:
65706         * modules/unistd-safer-tests:
65707         Depend on the getdtablesize module.
65708         * tests/test-cloexec.c:
65709         * tests/test-dup-safer.c:
65710         * tests/test-dup2.c:
65711         * tests/test-dup3.c:
65712         * tests/test-fcntl.c:
65713         * tests/test-nonblocking.c:
65714         * tests/test-posix_spawn_file_actions_addclose.c:
65715         * tests/test-posix_spawn_file_actions_adddup2.c:
65716         * tests/test-posix_spawn_file_actions_addopen.c:
65717         Don't assume getdtablesize () <= 10000000.
65719 2013-04-28  Paul Eggert  <eggert@cs.ucla.edu>
65721         extern-inline: work around bug in Sun c99
65722         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE):
65723         Work around bug in Sun C 5.12 c99's implementation of 'inline'.
65725 2013-04-27  Paul Eggert  <eggert@cs.ucla.edu>
65727         qacl: new module, broken out from the acl module
65728         This is for GNU Emacs, which wants the acl functions but does
65729         not want 'error' invoked when they fail.
65730         * lib/acl-internal.h: Do not include error.h, quote.h.
65731         (ENOSYS, ENOTSUP): Remove; no longer needed.
65732         (ACL_NOT_WELL_SUPPORTED): Remove; replaced by acl_errno_valid.
65733         * lib/acl.h: Include <stdbool.h>.
65734         (acl_errno_valid): New function.
65735         * lib/copy-acl.c, lib/set-acl.c: Include errno,h, not acl-internal.h.
65736         * lib/copy-acl.c (qcopy_acl): Move to lib/qcopy-acl.c.
65737         * lib/set-acl.c: Rename from lib/set-mode-acl.c.
65738         (chmod_or_fchmod, qset_acl): Move to lib/qset-acl.c.
65739         (ACL_INTERNAL_INLINE): Remove; no longer needed.
65740         * lib/file-has-acl.c (file_has_acl):
65741         * lib/qcopy-acl.c (qcopy_acl):
65742         * lib/qset-acl.c (qset_acl):
65743         Use acl_errno_valid instead of ACL_NOT_WELL_SUPPORTED.
65744         * modules/acl (Files): Move lib/acl.h, lib/acl-internal.h,
65745         lib/acl_entries.c, lib/set-mode-acl.c (renamed to lib/set-acl.c),
65746         lib/file-has-acl.c, m4/acl.m4 to qacl module.
65747         Add lib/set-acl.c.
65748         (Depends-on): Move extern-inline, fstat, sys_stat to qacl module.
65749         Add qacl.
65750         (configure.ac): Move gl_FUNC_ACL to qacl module.
65751         (lib_SOURCES): Remove file-has-acl.c (moved to qacl module).
65752         Rename set-mode-acl.c to set-acl.c.
65753         * lib/acl-errno-valid.c: New file.
65754         * lib/qcopy-acl.c: New file, moved from the old lib/copy-acl.c; the
65755         copy_acl function remains in copy-acl.c.
65756         * lib/qcopy-acl.c, lib/qset-acl.c: Do not include gettext.h.
65757         (_): Remove; not needed.
65758         * lib/qset-acl.c: New file, moved from the old lib/set-mode-acl.c; the
65759         set_acl function remains in set-acl.c (renamed from set-mode-acl.c).
65760         * modules/qacl: New file, moved from the old modules/acl.
65761         (Files, lib_SOURCES): Add acl-errno-valid.c, qcopy-acl.c, qset-acl.c.
65762         Remove set-mode-acl.c, copy-acl.c.
65763         (Depends-on): Remove error, gettext-h, quote.  Add stdbool.
65765         alignof, intprops, malloca: port better to IBM's C compiler
65766         * lib/alignof.h (alignof_type) [__IBM_ALIGNOF__]: Use __alignof__.
65767         * lib/intprops.h (_GL_HAVE___TYPEOF__) [__IBM_TYPEOF__]: Now 1.
65768         * lib/malloca.h (sa_alignof): [__IBM_ALIGNOF__]: Use __alignof__.
65770 2013-04-25  Daiki Ueno  <ueno@gnu.org>
65772         wctype-h: fix gettext link error on mingw
65773         Reported by Josue Andrade Gomes and Takayuki Tsunakawa in
65774         <https://lists.gnu.org/r/bug-gettext/2013-03/msg00086.html>.
65775         * lib/wctype.in.h [__MINGW32__]: Include <ctype.h> before defining
65776         rpl_towupper and rpl_towupper.
65778 2013-04-11  Dmitry V. Levin  <ldv@altlinux.org>
65780         regex-tests, regex: allow glibc re_search behavior
65781         * tests/test-regex.c (main): In test for glibc bug 15078, reformat
65782         re_search input data to make the multi-character collating element
65783         in it clearly visible, and treat re_search return code 0 as valid.
65784         * m4/regex.m4 (gl_REGEX): Likewise.
65786 2013-03-30  Paul Eggert  <eggert@cs.ucla.edu>
65788         stdalign: doc fix
65789         * doc/posix-headers/stdalign.texi (stdalign.h):
65790         Gnulib doesn't support '_Alignof expr'.
65792 2013-03-29  Paul Eggert  <eggert@cs.ucla.edu>
65794         stdalign: port to stricter ISO C11
65795         ISO C11 says that _Alignof's operand must be a parenthesized type.
65796         Problem reported by Eli Zaretskii in
65797         <http://lists.gnu.org/r/emacs-devel/2013-03/msg00960.html>.
65798         * doc/posix-headers/stdalign.texi (stdalign.h): Document this.
65799         * m4/stdalign.m4 (gl_STDALIGN_H): Don't use _Alignof (expr).
65801 2013-03-21  Paul Eggert  <eggert@cs.ucla.edu>
65803         sys_select, sys_time: port 2013-01-30 Solaris 2.6 fix to Cygwin
65804         Problem reported by Marco Atzeri in
65805         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00000.html>.
65806         * lib/sys_select.in.h [HAVE_SYS_SELECT_H && _CYGWIN_SYS_TIME_H]:
65807         Simply delegate to the system <sys/select.h> in this case too.
65808         Also, pay attention to _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H only
65809         if OSF/1, since otherwise Cygwin breaks, and it doesn't seem to
65810         be needed on Solaris either.
65811         * lib/sys_time.in.h [_CYGWIN_SYS_TIME_H]:
65812         Simply delegate to the system <sys/time.h> in this case.
65814 2013-03-19  Karl Berry  <karl@gnu.org>
65816         * build-aux/gnupload: check for erroneous (with gnupload) use of
65817         ftp-upload.gnu.org, tweak help.
65819 2013-03-19  Paul Eggert  <eggert@cs.ucla.edu>
65821         copy-file, rpmatch: fix problems found by cppcheck
65822         Reported by Arno Onken in
65823         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00069.html>.
65824         * lib/rpmatch.c (try): Fix memory leak.
65825         * lib/copy-file.c: Include "ignore-value.h".
65826         (qcopy_file_preserving): Ignore chown value.
65827         * modules/copy-file (Depends-on): Add ignore-value.
65829 2013-01-27  Jim Meyering  <jim@meyering.net>
65831         prefix-gnulib-mk: give better diagnostics
65832         * build-aux/prefix-gnulib-mk: Don't just "die".
65833         Give better diagnostics upon failure.
65835 2013-03-13  Paul Eggert  <eggert@cs.ucla.edu>
65837         putenv: port to Solaris 10
65838         * lib/putenv.c (_unsetenv, putenv): Use HAVE_DECL__PUTENV, not
65839         HAVE__PUTENV.  Solaris 10 has a _putenv that's not declared and
65840         is not what is wanted here.
65841         * m4/putenv.m4 (gl_PREREQ_PUTENV): Check for _putenv's
65842         declaration, not for its existence.
65844 2013-03-12  Paul Eggert  <eggert@cs.ucla.edu>
65846         mktime: fix configure typo
65847         * m4/mktime.m4 (gl_FUNC_MKTIME): Fix typo in previous change.
65849 2013-03-12  Eric Blake  <eblake@redhat.com>
65851         regex-tests: skip UTF-8 test on mingw
65852         * modules/regex-tests (Depends-on): Add localcharset.
65853         * tests/test-regex.c (main): Use it to skip test on mingw.
65855 2013-03-11  Eric Blake  <eblake@redhat.com>
65857         tests: make it easier to bypass alarm time in debugger
65858         * tests/test-file-has-acl.c (main): Allow gdb to override alarm.
65859         * tests/test-memmem.c (main): Likewise.
65860         * tests/test-passfd.c (main): Likewise.
65861         * tests/test-ptsname.c (main): Likewise.
65862         * tests/test-ptsname_r.c (main): Likewise.
65863         * tests/test-strcasestr.c (main): Likewise.
65864         * tests/test-strstr.c (main): Likewise.
65866         regex: port to mingw's recent addition of undeclared alarm
65867         * doc/posix-functions/alarm.texi (alarm): Document that alarm
65868         exists but still doesn't work in newer mingw.
65869         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Check for alarm declaration,
65870         not existence.  Ensure SIGALRM is not trapped.
65871         * m4/mktime.m4 (gl_FUNC_MKTIME): Likewise.
65872         * m4/regex.m4 (gl_REGEX): Likewise.
65873         * m4/remainderf.m4 (gl_FUNC_REMAINDERF_WORKS): Likewise.
65874         * tests/test-regex.c (main): Use correct probe for alarm.
65876         putenv: avoid compilation warning on mingw
65877         * lib/putenv.c (_unsetenv): Protect variable declaration.
65878         (putenv): Fix indentation.
65880 2013-03-11  Gary V. Vaughan  <gary@gnu.org>
65882         unistd: don't prevent Tru64 Unix from using gnulib strtod.
65883         * lib/unistd.in.h: be careful not to include un-needed system
65884         stdlib.h from here, because that prevents gnulib stdlib.h from
65885         defining rpl_strtod correctly.
65887 2013-03-09  Gary V. Vaughan  <gary@gnu.org>
65889         vasprintf-posix-tests: allow rounding 1.51 to 1, per the previous
65890         changesets, but for the 'precision 0' test.
65891         * tests/test-vasprintf-posix.c (test_function): Don't insist on
65892         round-to-even, since POSIX says rounding is implementation-defined
65893         and OS X 10.8.2 rounds 1.51 to 1 here.
65895         vasprintf-posix-tests: allow rounding 1.5 to 1, per the previous
65896         changeset.
65897         * tests/test-vasprintf-posix.c (test_function): Don't insist on
65898         round-to-even, since POSIX says rounding is implementation-defined
65899         and OS X 10.8.2 rounds 1.5 to 1 here.
65901 2013-03-08  Paul Eggert  <eggert@cs.ucla.edu>
65903         vasnprintf-posix-tests: allow rounding 1.5 to 1
65904         * tests/test-vasnprintf-posix.c (test_function): Don't insist on
65905         round-to-even, since POSIX says rounding is implementation-defined
65906         and OS X 10.8.2 rounds 1.5 to 1 here.  Reported by Gary V. Vaughan in
65907         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00019.html>.
65909         bootstrap: port to FreeBSD
65910         * build-aux/bootstrap (bootstrap_sync): Port sh -c usage to shells
65911         that treat '--' differently.  Reported by Mats Erik Andersson in
65912         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00012.html>.
65914 2013-03-08  Gary V. Vaughan  <gary@gnu.org>
65916         regex: rename remaining __attribute calls to __attribute__.
65917         2012-02-25 changed definition of __attribute, but left some uses
65918         unchanged, preventing compilation of regex module on most non-gcc
65919         environments.
65920         * lib/regcomp.c (re_set_fastmap, seek_collating_symbol_entry)
65921         (lookup_collation_sequence_value, build_range_exp)
65922         (build_collating_symbol): Set attributes with newly renamed
65923         __attribute__ decorator.
65924         * lib/regex_internal.c (re_string_peek_byte_case)
65925         (re_node_set_compare, re_node_set_contains): Likewise.
65926         * lib/regexec.c (acquire_init_state_context): Likewise.
65928 2013-03-06  Bruno Haible  <bruno@clisp.org>
65930         execute: Revert last change, but use a different condition.
65931         * lib/execute.c (nonintr_close, nonintr_open): Reintroduce, but only
65932         on Windows.
65934 2013-03-05  Eric Blake  <eblake@redhat.com>
65936         execute: drop dead code
65937         * lib/execute.c (nonintr_close, nonintr_open): Delete.
65939 2013-03-04  Paul Eggert  <eggert@cs.ucla.edu>
65941         non-recursive-gnulib-prefix-hack: port coreutils 8.21 to HP NonStop
65942         * m4/non-recursive-gnulib-prefix-hack.m4
65943         (gl_NON_RECURSIVE_GNULIB_PREFIX_HACK): Don't mess with ALLOCA.
65944         Problem reported for HP NonStop + coreutils 8.21 by Joachim Schmitz in
65945         <http://bugs.gnu.org/10305#237>.
65947 2013-03-04  Eric Blake  <eblake@redhat.com>
65949         test-getsockopt: avoid compiler warning
65950         * tests/test-getsockopt.c (includes): Ensure close is declared.
65952 2013-03-02  Bruno Haible  <bruno@clisp.org>
65954         sys_types: Avoid autoconf warning about gl_SYS_TYPES_H.
65955         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Define through AC_DEFUN_ONCE.
65957 2013-03-02  Bruno Haible  <bruno@clisp.org>
65959         gettext: Update to version 0.18.2.
65960         * m4/intl.m4, m4/po.m4: Update from gettext-0.18.2. In particular:
65961         2012-12-07  Stefano Lattarini  <stefano.lattarini@gmailcom>
65962                 * intl.m4, po.m4: Bump requirement in AC_PREREQ to 2.60.
65964 2013-02-25  Paul Eggert  <eggert@cs.ucla.edu>
65966         regex: merge patches from libc
65968         2013-02-26  Siddhesh Poyarekar  <siddhesh@redhat.com>
65969         * lib/regex_internal.h (__attribute__): Rename from __attribute.
65970         All uses changed.
65971         (bitset_not, bitset_merge, bitset_mask, re_string_char_size_at)
65972         (re_string_wchar_at, re_string_elem_size_at):
65973         Mark function as possibly unused.
65975         2013-02-12  Andreas Schwab  <schwab@suse.de>  [BZ #11561]
65976         * lib/regcomp.c (parse_bracket_exp) [_LIBC]: When looking up collating
65977         elements compare against the byte sequence of it, not its name.
65979 2013-02-21  Paul Eggert  <eggert@cs.ucla.edu>
65981         putenv: port better to native Windows
65982         * lib/putenv.c [(_WIN32 || __WIN32__) && ! __CYGWIN__]:
65983         Define WIN32_LEAN_AND_MEAN and include <windows.h>.
65984         (_unsetenv): Use _putenv if available.
65985         (putenv): Temporarily set NAME=' ' rather than NAME='x' as that's
65986         a bit less likely to cause damage.
65987         (putenv) [(_WIN32 || __WIN32__) && ! __CYGWIN__]:
65988         Fix the wrong value with SetEnvironmentVariable.
65989         (putenv) [!HAVE__PUTENV]: Simplify and match the HAVE__PUTENV
65990         code better.
65992 2013-02-20  Paul Eggert  <eggert@cs.ucla.edu>
65994         regex: ignore old-style-definition warnings
65995         * lib/regex.c: Add pragma to ignore these warnings.
65996         Problem reported for GNU tar by Pavel Raiskup.
65998 2013-02-19  Paul Eggert  <eggert@cs.ucla.edu>
66000         getcwd: support coreutils better
66001         Like strtod, getcwd incorrectly referred to HAVE_RAW_DECL_GETCWD,
66002         but this might not be correct in coreutils, which disables
66003         the raw decl checks.  Problem reported by Nagendra in
66004         <http://bugs.gnu.org/10305#192>.
66005         * lib/getcwd.c (__getcwd): Do not depend on HAVE_RAW_DECL_GETCWD.
66006         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
66007         Test the getcwd function, not any macro, since getcwd.c wants the
66008         function.
66009         * m4/getcwd.m4 (gl_FUNC_GETCWD):
66010         Don't define HAVE_MINIMALLY_WORKING_GETCWD if the code doesn't
66011         compile, as might happen if there's a macro but no function.
66013         strtod: support coreutils better
66014         * lib/strtod.c (underlying_strtod): Just invoke the underlying strtod.
66015         HAVE_RAW_DECL_STRTOD might not be correct in coreutils, which
66016         disables the raw decl checks.  This assumes there is an underlying
66017         strtod, but that's a safe assumption these days.
66018         (HAVE_RAW_DECL_STRTOD): Remove; no longer used.
66020         mountlist: port to HP NonStop
66021         Reported by Joachim Schmitz in
66022         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00084.html>.
66023         * lib/mountlist.c (hasmntopt) [!HAVE_HASMNTOPT]: New function.
66024         (MNT_IGNORE) [MNTOPT_IGNORE]: Use it.
66026 2013-02-18  Paul Eggert  <eggert@cs.ucla.edu>
66028         extern-inline: avoid compilation error with HP-UX cc
66029         Reported by Richard Lloyd in
66030         <http://lists.gnu.org/r/bug-texinfo/2013-02/msg00030.html>.
66031         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE):
66032         Suppress extern inline with HP-UX cc.  This should be safe,
66033         though it may hurt performance.  Perhaps someone with some HP-UX
66034         experience can come up with a higher-performance fix.
66036 2013-02-14  Paul Eggert  <eggert@cs.ucla.edu>
66038         putenv: fix heap corruption with mixed putenv/_putenv
66039         Problem reported by Michael Goffioul in
66040         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00061.html>.
66041         * lib/putenv.c (putenv) [HAVE__PUTENV]:
66042         Rely on _putenv to allocate the new environment.
66043         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
66044         * modules/putenv (configure.ac): Use it.
66046 2013-02-11  Paul Eggert  <eggert@cs.ucla.edu>
66048         unsetenv etc.: port to Solaris 11 + GNU Emacs
66049         * lib/canonicalize-lgpl.c, lib/getaddrinfo.c, lib/getdelim.c:
66050         * lib/glob.c, lib/random_r.c, lib/setenv.c, lib/tsearch.c:
66051         * lib/unsetenv.c (_GL_ARG_NONNULL): Define before including <config.h>.
66052         GNU Emacs's <config.h> includes <stdlib.h> (which is not a great
66053         idea but is too painful to fix right now), and without this gnulib
66054         change <stdlib.h> was defining _GL_ARG_NONNULL incorrectly when
66055         compiling unsetenv.c on Solaris 11.  Fix the problem for
66056         unsetenv.c, and fix other similar occurrences.
66058 2013-02-09  Paul Eggert  <eggert@cs.ucla.edu>
66060         secure_getenv: fix C++ declaration typo
66061         * lib/stdlib.in.h (secure_getenv): Fix typo with return type
66062         in _GL_CXXALIAS_SYS macro.  Reported by John W. Eaton in
66063         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00057.html>.
66065 2013-02-08  Paul Eggert  <eggert@cs.ucla.edu>
66067         careadlinkat: stop exporting careadlinkatcwd
66068         Only Emacs used it directly, and Emacs no longer needs it.
66069         * NEWS: Document this simplification.
66070         * lib/areadlink.c (careadlinkatcwd): Move here from careadlinkat.c,
66071         and make it static.  Include <stdlib.h>, for abort, and unistd.h,
66072         for readlink.
66073         * lib/careadlinkat.c (careadlinkatcwd): Move to areadlink.c.
66074         Don't include stdlib.h; no longer needed.
66075         * lib/careadlinkat.h (careadlinkatcwd): Remove decl.
66076         * lib/relocwrapper.c: Adjust comment to match new dependencies.
66077         * modules/areadlink (Depends-on): Add readlink.
66078         (Maintainer): Add self.
66079         * modules/careadlinkat (Depends-on): Remove readlink.
66081         extensions: port better to HP-UX
66082         This is merged from git Autoconf.
66083         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
66084         On hosts that need _XOPEN_SOURCE, define it when configuring, too,
66085         so that it's compatible with the value used when compiling.
66087         openpty: fix bug where HAVE_OPENPTY is mistakenly 1
66088         Problem reported by Mats Erik Andersson in
66089         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00051.html>.
66090         * m4/pty.m4 (gl_FUNC_OPENPTY): Define HAVE_OPENPTY when the
66091         openpty function exists, not merely when we intend to replace it.
66092         This corrects the 2013-01-31 patch, which mistakenly defined
66093         HAVE_OPENPTY even on hosts that lacked it.
66095 2013-02-07  Paul Eggert  <eggert@cs.ucla.edu>
66097         secure_getenv: fix include typo
66098         * lib/secure_getenv.c: Include config.h.  Somehow I forgot!
66100         secure_getenv: port better to FreeBSD and Solaris
66101         * lib/secure_getenv.c [!HAVE___SECURE_GETENV]:
66102         Include unistd.h if HAVE_ISSETUGID, otherwise define a dummy issetugid.
66103         (secure_getenv) [!HAVE___SECURE_GETENV]: Use getenv if not issetugid.
66104         This works better on BSDish platforms.
66105         * m4/secure_getenv.m4 (gl_PREREQ_SECURE_GETENV):
66106         Test for issetugid if __secure_getenv is missing.
66108 2013-02-06  Paul Eggert  <eggert@cs.ucla.edu>
66110         extensions: port better to MINIX 3, HP-UX, autoheader 2.62
66111         Some of these changes are merged in from git Autoconf.
66112         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
66113         When deciding whether to define _XOPEN_SOURCE, inspect the
66114         preprocessor macro __hpux instead of the more-heavyweight
66115         operation of requiring AC_CANONICAL_HOST.  Define _NETBSD_HOST on
66116         MINIX, for MINIX 3.  Use USE_SYSTEM_EXTENSIONS, not __EXTENSIONS__,
66117         as the key for __EXTENSIONS__.
66119         unistd: avoid namespace pollution on non-glibc systems
66120         * lib/unistd.in.h: #define __need_getopt before including <getopt.h>.
66121         This avoids namespace pollution on non-glibc systems, by causing
66122         gnulib unistd.h to behave more like glibc unistd.h.  I also hope
66123         that this fixes a bug on FreeBSD, reported by Mats Erik Andersson in
66124         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00027.html>.
66126 2013-02-04  Paul Eggert  <eggert@cs.ucla.edu>
66128         tmpdir: use secure_getenv
66129         * lib/tmpdir.c (__secure_getenv) [!LIBC]:
66130         Define to secure_getenv, not getenv.
66131         * m4/tmpdir.m4 (gt_TMPDIR): Don't check for __secure_getenv,
66132         as that's now secure_getenv's job.
66133         * modules/tmpdir (Depends-on): Add secure_getenv.
66135         tempname: use secure_getenv
66136         * lib/tempname.c (__secure_getenv) [!_LIBC]:
66137         Define to secure_getenv, not getenv.
66138         * modules/tempname (Depends-on):
66139         Add secure_getenv.
66141         secure_getenv: new module
66142         * MODULES.html.sh (Extra functions based on ANSI C 89):
66143         Add secure_getenv.
66144         * doc/glibc-functions/secure_getenv.texi: New file.
66145         * doc/gnulib.texi: Include it.
66146         * lib/secure_getenv.c, m4/secure_getenv.m4, modules/secure_getenv:
66147         New files.
66148         * lib/stdlib.in.h (secure_getenv): New decl.
66149         * m4/stdlib_h.m4 (gl_STDLIB_H, gl_STDLIB_H_DEFAULTS):
66150         * modules/stdlib (stdlib.h):
66151         Add secure_getenv checks.
66153 2013-02-03  Paul Eggert  <eggert@cs.ucla.edu>
66155         getcwd: break fdopendir + save_cwd recursive loop (Bug#13516)
66156         Reported for OS X 10.8.2 by Assaf Gordon in
66157         <http://bugs.gnu.org/13516>.
66158         * lib/getcwd.c (HAVE_OPENAT_SUPPORT): Do not define if
66159         !HAVE_OPENAT && !HAVE_FDOPENDIR.
66160         * m4/getcwd-abort-bug.m4: Reformat to match test-getcwd.c
66161         so that they can be kept in sync more easily.  Avoid PATH_MAX
66162         test on the Hurd.  Sync from test-getcwd.c for errno tests after
66163         mkdir or chdir failure.
66164         * tests/test-getcwd.c (HAVE_OPENAT_SUPPORT): New macro, from
66165         lib/getcwd.c.
66166         (test_abort_bug): Do not test for the deep directory bug unless we
66167         have openat support.  Avoid PATH_MAX test on the Hurd.
66169         regex-tests, regex: fix bug: memset undeclared
66170         * tests/test-regex.c: Don't include regex.h twice.  Include
66171         string.h, to declare memset.  Christensen's report also mentioned
66172         this issue.
66173         * m4/regex.m4 (gl_REGEX): Keep test program more in sync with
66174         test-regex.c, to avoid future problems like this.  Remove
66175         AC_INCLUDES_DEFAULT.  Include <string.h>.  Don't include <regex.h>
66176         twice.
66178         regex-tests: fix link errors on older Solaris
66179         These need to link with @LIBINTL@ to get libintl_gettext.
66180         Problem reported by Tom G. Christensen in
66181         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00003.html>.
66182         * modules/regex-tests (test_regex_LDADD): New macro.
66184 2013-01-31  Paul Eggert  <eggert@cs.ucla.edu>
66186         regex-tests: new module
66187         * modules/regex-tests, tests/test-regex.c: New files.
66189         regex: fix off-by-one error in configure test
66190         * m4/regex.m4 (gl_REGEX): Test should return 21, not 20.
66192 2013-01-31  Eric Blake  <eblake@redhat.com>
66194         regex: avoid infinite configure test
66195         * m4/regex.m4 (gl_REGEX): Add an alarm escape hatch.
66197 2013-01-31  Reuben Thomas  <rrt@sc3d.org>
66199         openpty: fix bug where HAVE_OPENPTY wasn't defined
66200         See the thread starting at:
66201         http://lists.gnu.org/r/bug-gnulib/2013-01/msg00185.html
66202         * m4/pty.m4 (gl_FUNC_OPENPTY): Define HAVE_OPENPTY when the
66203         openpty function exists, not merely when we intend to replace it.
66205 2013-01-30  Paul Eggert  <eggert@cs.ucla.edu>
66207         sys_time: port to Solaris 2.6
66208         There is a circularity problem on Solaris 2.6, where <time.h> includes
66209         <sys/time.h> for struct timespec.  The include nesting is gnulib
66210         <time.h>, system <time.h>, gnulib <sys/time.h>, system
66211         <sys/time.h>, gnulib <sys/types.h>, system <sys/types.h>, gnulib
66212         <sys/select.h>, gnulib <signal.h>, system <sys/signal.h>, system
66213         <sys/siginfo.h>; the last, innermost file needs struct
66214         timestruc_t, which is defined in <sys/time.h>, which has not been
66215         fully parsed.  Problem reported by Tom G. Christensen in
66216         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00113.html>.
66217         * lib/sys_select.in.h: Treat Solaris 2.6's problem with
66218         <sys/time.h> and <sys/types.h> like OSF/1's similar problem.
66219         * lib/sys_time.in.h: Redo to resemble sys_select.in.h, which
66220         uses split double-inclusion guards.
66222 2013-01-29  Paul Eggert  <eggert@cs.ucla.edu>
66224         regex: test for buffer overrun
66225         * m4/regex.m4 (gl_REGEX): Add test case, by Andreas Schwab,
66226         for the just-fixed regex bug.
66228 2013-01-29  Andreas Schwab  <schwab@suse.de>
66230         regex: fix buffer overrun in regexp matcher [BZ #15078]
66231         * lib/regexec.c (extend_buffers): Add parameter min_len.
66232         (check_matching): Pass minimum needed length.
66233         (clean_state_log_if_needed): Likewise.
66234         (get_subexp): Likewise.
66236 2013-01-28  Pádraig Brady  <P@draigBrady.com>
66238         mountlist: don't consider "devtmpfs" as dummy
66239         * lib/mountlist.c (ME_DUMMY_0): Remove "devtmpfs"
66240         as there is storage associcated with it.
66242 2013-01-27  Paul Eggert  <eggert@cs.ucla.edu>
66244         futimens-tests, utimens-tests: Depend on gettext.
66245         This works around a problem introduced in my 2013-01-12 patch,
66246         which added @LIBINTL@ to these modules.
66247         * modules/futimens-tests (Depends-on):
66248         * modules/utimens-tests (Depends-on): Add gettext.
66250 2013-01-26  Eric Blake  <eblake@redhat.com>
66252         test-getpeername: fix typo
66253         * tests/test-getpeername.c: Fix typo introduced in fd cleanup.
66255 2013-01-20  Bernhard Voelker  <mail@bernhard-voelker.de>
66257         bootstrap: remove the need for a sorted .gitignore file
66258         * build-aux/bootstrap (insert_sorted_if_absent): Adjust and
66259         rename to insert_if_absent(), so that we don't need or generate
66260         a sorted .gitignore file.  We do require a .gitignore with no
66261         existing duplicate entries and enforce that.
66262         (sort_patterns): Remove this function as we now use the simpler
66263         technigue of inserting blacklist entries at the top of the file,
66264         assuming gnulib won't be inserting !whitelist entries.
66266 2013-01-23  Paul Eggert  <eggert@cs.ucla.edu>
66268         readlinkat: don't depend on gl_FUNC_OPENAT
66269         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Don't require gl_FUNC_OPENAT.
66270         Perhaps a similar change needs to be made for linkat.m4, mkfifoat.m4,
66271         renameat.m4, symlinkat.m4; but one thing at a time.
66273         statat: new module, split out from fstatat
66274         GNU Emacs needs the POSIX-specified fstatat, but not the
66275         gnulib-specified statat and lstat.  Split the latter two into a
66276         new module 'statat'.
66277         * lib/openat.h: Depend on GNULIB_STATAT, not GNULIB_FSTATAT.
66278         * lib/openat.h, lib/statat.c (STATAT_INLINE):
66279         Rename from FSTATAT_INLINE. All uses changed.
66280         * modules/fstatat (Files): Remove lib/statat.c.
66281         (gl_MODULE_INDICATOR([fstatat])): Remove.
66282         (lib_SOURCES): Remove.
66283         (Maintainer): Add self.
66284         * modules/statat, modules/statat-tests, tests/test-statat.c: New files.
66285         * tests/test-fstatat.c (BASE): Don't define if already defined.
66286         (do_stat, do_lstat) [!TEST_STATAT]: Test fstatat instead.
66288 2013-01-22  Paul Eggert  <eggert@cs.ucla.edu>
66290         tests: don't assume fd 99 is closed
66291         * tests/test-accept.c, tests/test-accept4.c, tests/test-bind.c:
66292         * tests/test-close.c, tests/test-connect.c, tests/test-dprintf.c:
66293         * tests/test-dup.c, tests/test-dup2.c, tests/test-faccessat.c:
66294         * tests/test-fchdir.c, tests/test-fchmod.c, tests/test-fchmodat.c:
66295         * tests/test-fchown.c, tests/test-fchownat.c, tests/test-fclose.c:
66296         * tests/test-fdatasync.c, tests/test-fdopen.c, tests/test-fdopendir.c:
66297         * tests/test-fflush.c, tests/test-fgetc.c, tests/test-fputc.c:
66298         * tests/test-fread.c, tests/test-freopen.c, tests/test-fseeko4.c:
66299         * tests/test-fstat.c, tests/test-fstatat.c, tests/test-fsync.c:
66300         * tests/test-ftello4.c, tests/test-ftruncate.c, tests/test-futimens.h:
66301         * tests/test-fwrite.c, tests/test-getpeername.c:
66302         * tests/test-getsockname.c, tests/test-getsockopt.c:
66303         * tests/test-grantpt.c, tests/test-ioctl.c, tests/test-isatty.c:
66304         * tests/test-linkat.c, tests/test-listen.c, tests/test-lseek.c:
66305         * tests/test-mkdirat.c, tests/test-mkfifoat.c, tests/test-openat.c:
66306         * tests/test-pread.c, tests/test-pwrite.c, tests/test-read.c:
66307         * tests/test-readlinkat.c, tests/test-recv.c, tests/test-recvfrom.c:
66308         * tests/test-renameat.c, tests/test-select.h, tests/test-send.c:
66309         * tests/test-sendto.c, tests/test-setsockopt.c, tests/test-shutdown.c:
66310         * tests/test-symlinkat.c, tests/test-ttyname_r.c:
66311         * tests/test-unlinkat.c, tests/test-unlockpt.c:
66312         * tests/test-utimensat.c, tests/test-vdprintf.c, tests/test-write.c:
66313         Close file descriptor 99, instead of assuming it's already closed.
66315 2013-01-21  Paul Eggert  <eggert@cs.ucla.edu>
66317         stpncpy: port to OS X 10.8
66318         * lib/stpncpy.c (__stpncpy): Parenthesize name when defining function.
66319         Problem reported by Assaf Gordon in <http://bugs.gnu.org/13495>.
66321 2013-01-16  Paul Eggert  <eggert@cs.ucla.edu>
66323         unistd: port to recent mingw
66324         * lib/unistd.in.h: Remove special invocation convention for mingw,
66325         which breaks for the latest mingw version.  See John W. Eaton in
66326         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00100.html>.
66328         largefile: port better to Mac OS X 10.5
66329         This patch is backported from Autoconf git.
66330         * m4/largefile.m4 (AC_SYS_LARGEFILE): Use AC_DEFINE, not
66331         AH_VERBATIM, to define _DARWIN_USE_64_BIT_INODE, to avoid problems
66332         with ino_t size being different for configuration time versus
66333         build/run time.  Problem reported by PHO in
66334         <http://lists.gnu.org/r/bug-autoconf/2013-01/msg00040.html>.
66336 2013-01-15  Paul Eggert  <eggert@cs.ucla.edu>
66338         doc: clarify -Werror
66339         * doc/warnings.texi (warnings): -Werror is not always a bad idea;
66340         clarify that it's intended for developers, not for ordinary builds,
66341         and mention --enable-gcc-warnings as one possible use.
66343 2013-01-15  Andoni Morales Alastruey  <ylatuya@gmail.com>  (tiny change)
66345         stdint: fix build with Android's Bionic fox x86
66346         * lib/stdint.in.h: fix check to test if included-fixed/sys/types.h
66347         was already included as _SSIZE_T_DEFINED_ might also be defined
66348         in include/machine/_types.h, which is included by stdio.h
66350 2013-01-13  Paul Eggert  <eggert@cs.ucla.edu>
66352         net_if-tests: port to Solaris 7 + GCC 3.4.6
66353         Problem reported by Tom G. Christensen in
66354         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00091.html>.
66355         * tests/test-net_if.c (ni): Move to next the code that uses it,
66356         so that it's declared only if needed.
66358 2013-01-12  Paul Eggert  <eggert@cs.ucla.edu>
66360         net_if-tests: port to older Solaris
66361         Problem reported by Tom G. Christensen in
66362         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html>.
66363         * modules/net_if-tests (NET_IF_LIB): New substitution.
66364         (test_net_if_LDADD): New makefile macro, which uses NET_IF_LIB.
66365         (HAVE_IF_NAMEINDEX): New C macro.
66366         * tests/test-net_if.c: Bypass most of the test if !HAVE_IF_NAMEINDEX.
66368         system-quote-tests: port to older Solaris
66369         Problem reported by Tom G. Christensen in
66370         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html>.
66371         * tests/test-system-quote-child.c (fopen, fread): Undef.
66373         c-xvasprintf etc.: fix link errors on older Solaris
66374         These need to link with @LIBINTL@ to get libintl_gettext.
66375         Problem reported by Tom G. Christensen in
66376         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html>.
66377         * modules/c-xvasprintf-tests (test_c_xvasprintf_LDADD):
66378         * modules/readtokens-tests (test_readtokens_LDADD): New macros.
66379         * modules/futimens-tests (test_futimens_LDADD):
66380         * modules/utimens-tests (test_utimens_LDADD): Add @LIBINTL@.
66382 2013-01-10  Paul Eggert  <eggert@cs.ucla.edu>
66384         locale: port to Solaris 2.6 and 7 + GNU gettext
66385         * lib/locale.in.h: Just include_next <locale.h> when
66386         being invoked recursively.  This prevents problems on Solaris 2.6 and 7
66387         when combining the localename module with GNU gettext 0.18.2.
66388         Problem reported by Tom G. Christensen in
66389         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00084.html>.
66391 2013-01-09  Paul Eggert  <eggert@cs.ucla.edu>
66393         stdlib: port to Solaris 2.6
66394         Also, the code worked on Solaris 7 through 9 only by accident.
66395         Problem reported by Tom G. Christensen in
66396         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00059.html>.
66397         * lib/stdlib.in.h: If __need_system_stdlib_h is defined,
66398         simply include the system stdlib.h.
66399         * lib/getopt.in.h (__need_system_stdlib_h):
66400         * lib/pthread.in.h (__need_system_stdlib_h):
66401         * lib/unistd.in.h (__need_system_stdlib_h) [!__GLIBC__]:
66402         Define when including <stdlib.h>, to avoid problems at least for
66403         the pthread case on Solaris 2.6 and 7.  These .h files can get by
66404         with the system stdlib.h.
66406 2013-01-06  Paul Eggert  <eggert@cs.ucla.edu>
66408         doc: update main copyright year
66409         * doc/gnulib.texi: Update copyright date.
66411         doc: improve ISO 8601 discussion
66412         * doc/parse-datetime.texi (Combined date and time of day items):
66413         Specify more carefully what formats are supported and what is
66414         done with excess precision.
66416 2013-01-05  Paul Eggert  <eggert@cs.ucla.edu>
66418         doc: avoid small caps
66419         * doc/parse-datetime.texi, doc/regex.texi: Don't use small caps;
66420         they're more trouble than they're worth.  Suggested by Karl Berry
66421         in <http://bugs.gnu.org/13360>.
66423         regex: conform to strict C
66424         * lib/regcomp.c (parse_bracket_exp): Add cast to conform to strict C.
66425         From Aharon Robbins.
66427         gnulib-tool: fix incompatibility with autopoint 0.18.2
66428         * gnulib-tool: Don't indent AM_GNU_GETTEXT_VERSION line.
66429         Problem reported by Tom G. Christensen in
66430         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00053.html>.
66432 2013-01-04  Paul Eggert  <eggert@cs.ucla.edu>
66434         fprintftime: bring back and reword fwrite comment
66435         * lib/strftime.c (cpy) [FPRINTFTIME]: Re-add reworded comment.
66437         stdio: remove now-unnecessary stdio.c
66438         Since stdio.in.h no longer uses inline functions, we no longer
66439         need to compile the extern versions.
66440         * lib/stdio.c: Remove.
66441         * modules/stdio (Files): Remove lib/stdio.c.
66442         (lib_SOURCES): Remove.
66444         unicodeio: depend on stdio, not ignore-value
66445         * lib/unicodeio.c: Do not include ignore-value.h.
66446         (fwrite_success_callback): Use plain fwrite, not ignore_value + fwrite.
66447         * modules/unicodeio (Depends-on): Depend on stdio, not ignore-value.
66449         fprintftime: depend on stdio, not ignore-value
66450         * lib/strftime.c [FPRINTFTIME]: Do not include ignore-value.h.
66451         (cpy) [FPRINTFTIME]: Use plain fwrite, not ignore_value of fwrite,
66452         since the stdio module arranges to silence that warning now.
66453         * modules/fprintftime (Depends-on): Depend on stdio, not ignore-value.
66455 2012-10-04  Simon Josefsson  <simon@josefsson.org>
66457         stdint-tests: Fix expanded-before-required-warning.
66458         * modules/stdint-tests (Depends-on): Use AC_REQUIRE.
66460 2013-01-03  Paul Eggert  <eggert@cs.ucla.edu>
66462         fwrite: silence __wur only for older glibc versions
66463         * lib/stdio.in.h (fwrite): Limit workaround to glibc 2.4 through 2.15.
66464         This will help us remove this workaround some time in the far future.
66466 2013-01-03  Eric Blake  <eblake@redhat.com>
66468         fwrite: silence __wur without using inline
66469         * lib/stdio.in.h (fwrite): Limit warn_unused_result workaround to
66470         just gcc, and in a way that avoids inline issues.
66471         * modules/stdio (Depends-on): Drop extern-inline.
66473 2013-01-03  Jim Meyering  <jim@meyering.net>
66475         update-copyright: avoid copyright notice date corruption
66476         Given a sequence of copyright year numbers in which the final
66477         one was a two-digit number that happened to be a substring of
66478         a preceding four-digit year number, we would mistakenly update
66479         the substring (from two- to four-digit) rather than the two-digit
66480         number at the end, which, combined with the addition of the current
66481         4-digit year number would yield two 5-digit year numbers, e.g.,
66482         here, it would convert the first "99" to "1999, 2013" rather than
66483         the final one:
66484           1991, 99
66485           11999, 20131, 1999
66486         * build-aux/update-copyright: Tighten a regexp.
66487         * tests/test-update-copyright.sh: Add a test case to trigger the bug.
66488         Reported by Joseph Myers in
66489         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/32281
66491 2013-01-01  Paul Eggert  <eggert@cs.ucla.edu>
66493         regex: omit needless signed-pointer casts
66494         * lib/regcomp.c (build_charclass, build_charclass_op):
66495         Use char *, not unsigned char *, for class name and extra.
66496         The char values are always nonnegative so there's no need to
66497         insist on unsigned char * here, and using char * removes the need
66498         for casts.  Reported by Aharon Robbins in
66499         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66501         regex: support Gawk, which never uses alloca
66502         * lib/regex_internal.h [!_LIBC && !HAVE_ALLOCA]:
66503         Do not include in this case.  Gawk doesn't supply a substitute
66504         alloca.h and doesn't need one.
66506         regex: port __libc_lock_define usage to C89
66507         * lib/regex_internal.h (__libc_lock_define) [!_LIBC]: Remove.
66508         (struct re_dfa_t): Use #ifdef instead.  '__libc_lock_define (, lock)'
66509         does not conform to C89, as it has an empty macro argument.
66510         Reported by Aharon Robbins in
66511         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66513 2013-01-01  Eric Blake  <eblake@redhat.com>
66515         maint: update all copyright year number ranges
66516         Run "make update-copyright".
66518         version-etc: bump copyright year reported in --version
66519         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2013.
66521 2012-12-31  Eric Blake  <eblake@redhat.com>
66523         sigprocmask-tests: skip test if pid is unexpectedly large
66524         * tests/test-sigprocmask.c (main): Add range check.
66526         git-version-gen: avoid test -z portability glitch
66527         * build-aux/git-version-gen: Prefer portable test spelling, since
66528         git-version-gen is run on more than just developer machines.
66530 2012-12-31  Peter Rosin  <peda@lysator.liu.se>  (tiny change)
66532         git-version-gen: add --fallback option to use if git is not present
66533         * build-aux/git-version-gen: Add support for the new option --fallback,
66534         which comes into play when there is no $tarball_version_file and
66535         git is not working.
66536         (scriptversion): Update.
66538         maint.mk: handle missing git with more grace
66539         * top/maint.mk (no-submodule-changes, public-submodule-commit):
66540         Quietly proceed if git is not present.
66542 2012-12-31  Eric Blake  <eblake@redhat.com>
66544         dup2: work around cygwin bug
66545         * m4/dup2.m4 (gl_FUNC_DUP2): Flush out cygwin core dump.
66546         * lib/dup2.c (rpl_dup2): Work around it.
66547         * doc/posix-functions/dup2.texi (dup2): Document it.
66549 2012-12-30  Paul Eggert  <eggert@cs.ucla.edu>
66551         regex: remove unnecessary dependency on localcharset.h
66552         * lib/regex_internal.h [!_LIBC]: Don't include localcharset.h;
66553         hasn't been needed for years.
66554         * modules/regex (Depends-on): Remove localcharset.
66556         regex: revert single-byte change
66557         * lib/regexec.c (check_node_accept_bytes): Revert previous change
66558         to this function.  This was alredy fixed in a different way, at
66559         bdb56bacd57070eced9998569ffe3f3c37ef5964 in the glibc git; see
66560         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=510219> and
66561         <http://sourceware.org/bugzilla/show_bug.cgi?id=9697>.
66563         regex: simplify based on Gawk version
66564         * lib/regex_internal.c (re_dfa_add_node): Simplify.
66565         Reported by Aharon Robbins in
66566         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66568 2012-12-29  Paul Eggert  <eggert@cs.ucla.edu>
66570         regex: check that pattern char is single-byte
66571         Reported by Aharon Robbins in
66572         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66573         * lib/regexec.c (check_node_accept_bytes):
66574         Return 0 if the pattern string has a multibyte character here.
66576         regex: implement rational ranges
66577         Reported by Aharon Robbins in
66578         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66579         * lib/regcomp.c (build_range_exp) [!_LIBC]:
66580         * lib/regexec.c (check_node_accept_bytes) [!_LIBC]:
66581         Implement rational ranges.
66583         regex: avoid redefining __wctype
66584         Reported by Aharon Robbins in
66585         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66586         * lib/regex_internal.h (__wctype, __iswctype) [!_LIBC]:
66587         #undef before defining.
66589         regex: port to hosts where malloc (0) == NULL
66590         Reported by Aharon Robbins in
66591         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66592         * lib/regex_internal.c (re_node_set_alloc):
66593         Don't assume that malloc (0) yields nonnull.
66594         * lib/regex_internal.h (MALLOC_0_IS_NONNULL): New macro.
66595         * m4/regex.m4 (gl_PREREQ_REGEX): Require gl_EEMALLOC.
66596         * modules/regex (Files): Add m4/eealloc.m4.
66598         regex: port to C89
66599         Reported by Aharon Robbins in
66600         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
66601         * lib/regcomp.c (init_word_char): Declaration before statement.
66603         regex: merge glibc changes
66604         Also, copy the license wording from glibc.  This simplifies
66605         merging changes.  gnulib-tool will change the wording to GPL as
66606         appropriate, when importing it to other packages.  The only
66607         glibc change made since the last merge, which needs merging, is:
66608         2012-05-24 Andreas Schwab <schwab@linux-m68k.org>
66609         * lib/regex_internal.h (gettext): Remove use of INTUSE.
66611         * users.txt: Add Emacs.
66613         doc: omit mention of version when not needed
66614         * doc/gnulib-intro.texi (Portability and Application Code):
66615         * doc/gnulib.texi (Brief Overview, Legacy Function Substitutes):
66616         Don't mention particular dates or versions when not necessary, so
66617         that the documentation won't go out of date so quickly.
66619         * doc/intprops.texi (Integer Properties): Fix Texinfo typo.
66621 2012-12-28  Akim Demaille  <akim@lrde.epita.fr>
66623         bootstrap: pass --force to autoreconf.
66624         * build-aux/bootstrap (AUTORECONFFLAGS): New.
66625         Add "--force" so that Automake's ylwrap and other such tools
66626         be updated at each bootstrap invocation.
66627         Use it.
66629 2012-12-27  Paul Eggert  <eggert@cs.ucla.edu>
66631         argp: fix port of port new 'inline' approach to Sun C 5.12 + Solaris 10
66632         The earlier patch forgot to update one of the #if conditions, causing
66633         a problem on Debian testing i386 reported by Mats Erik Andersson
66634         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00124.html>.
66635         * lib/argp-fmtstream.h (__argp_fmtstream_putc, argp_fmtstream_putc)
66636         (__argp_fmtstream_puts, argp_fmtstream_puts)
66637         (__argp_fmtstream_write, argp_fmtstream_write)
66638         [!_LIBC && !__OPTIMIZE__]: Declare as ARGP_FS_EI, not as extern.
66640         * doc/gnulib-readme.texi: Minor fixups.
66641         (Portability guidelines): Modernize URLs.  Remove some repetition.
66642         (Indent with spaces not TABs): Reword to avoid too-long lines.
66643         Remove some '@ifset standalone' stuff that isn't used.
66645         * doc/gnulib-readme.texi (Portability guidelines):
66646         ctype.h, not ctime.h.
66648         Correct name of POSIX.1-2001.
66649         * doc/posix-functions/fgetc.texi (fgetc):
66650         * doc/posix-functions/fgets.texi (fgets):
66651         * doc/posix-functions/fread.texi (fread):
66652         * doc/posix-functions/fscanf.texi (fscanf):
66653         * doc/posix-functions/getc.texi (getc):
66654         * doc/posix-functions/getchar.texi (getchar):
66655         * doc/posix-functions/scanf.texi (scanf):
66656         POSIX.1-2001, not POSIX-2001.
66658         doc: move README into manual
66659         * README: Move contents to new file doc/gnulib-readme.texi.
66660         Replace with a one-line summary.
66661         * doc/gnulib.texi (Brief Overview): New section,
66662         with old intro preface.  Include gnulib-readme.texi for contents.
66663         (Philosophy): Rename from "Introduction", since this
66664         section no longer introduces the rest.  Write a new preface.
66665         * doc/gnulib-readme.texi: New file, with the old contents of
66666         README texinfo-ized.  This way, the README info appears
66667         in the online and printed manual.
66669 2012-12-25  Ben Pfaff  <blp@cs.stanford.edu>
66671         c-xvasprintf: Fix "implicit declaration of function" GCC warning.
66672         * lib/c-xvasprintf.c: Add missing #include "c-vasprintf.h", for
66673         c_vasprintf() prototype.
66675 2012-12-24  Ben Pfaff  <blp@cs.stanford.edu>
66677         c-vasprintf: Fix "empty declaration" warning reported by GCC.
66678         * lib/c-vasprintf.h: Remove stray semicolon.
66680 2012-12-23  Paul Eggert  <eggert@cs.ucla.edu>
66682         gettext: avoid obsolete macro AM_PROG_MKDIR_P
66683         It is obsolete and is planned to be removed from Automake 1.14; see
66684         <http://lists.gnu.org/r/automake/2012-12/msg00029.html>.
66685         * build-aux/po/Makefile.in.in (install-data, install-data-yes)
66686         (installdirs-data, installdirs-data-yes):
66687         Use $(MKDIR_P), not $(mkdir_p).
66688         * m4/intl.m4 (AM_INTL_SUBDIR):
66689         * m4/po.m4 (AM_PO_SUBDIRS):
66690         Require AC_PROG_MKDIR_P, not AM_PROG_MKDIR_P.
66692 2012-12-22  Paul Eggert  <eggert@cs.ucla.edu>
66694         argp: port new 'inline' approach to Sun C 5.12 + Solaris 10
66695         On this platform, we are not optimizing but we are using
66696         the substitute for extern inlines, so compile as if
66697         C99-style extern inline, or a substitute, is available.
66698         * lib/argp-fmtstream.h (argp_fmtstream_set_lmargin)
66699         (__argp_fmtstream_set_lmargin, argp_fmtstream_set_rmargin)
66700         (__argp_fmtstream_set_rmargin, argp_fmtstream_set_wmargin)
66701         (__argp_fmtstream_set_wmargin, argp_fmtstream_point)
66702         (__argp_fmtstream_point) [!_LIBC && !__OPTIMIZE__]:
66703         Declare as ARGP_FS_EI, not as extern.
66704         * lib/argp.h (argp_usage, __argp_usage, _option_is_short)
66705         (__option_is_short, _option_is_end, __option_is_end)
66706         [!_LIBC && __USE_EXTERN_INLINES]:
66707         Declare as ARGP_EI, not as extern.
66709 2012-12-21  Paul Eggert  <eggert@cs.ucla.edu>
66711         AC_PROG_MKDIR_P: port workaround to pre-2.62 Autoconf
66712         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P, AC_C_RESTRICT):
66713         Use m4_ifndef([AC_AUTOCONF_VERSION], ...), not
66714         m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]),[2.62]),[-1],
66715         ...), as the latter is fatal with older Autoconfs.
66716         Problem reported and fix suggested by Eric Blake in thread starting at
66717         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00097.html>.
66719 2012-12-20  Paul Eggert  <eggert@cs.ucla.edu>
66721         AC_PROG_MKDIR_P: don't workaround if not buggy
66722         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P):
66723         Define only for Autoconf versions before 2.62.
66724         (AC_C_RESTRICT): Use documented AC_AUTOCONF_VERSION, not
66725         undocumented m4_PACKAGE_VERSION, for consistency with the
66726         abovementioned change to AC_PROG_MKDIR_P.  This should suffice
66727         since we're checking for 2.62 or later, and AC_AUTOCONF_VERSION
66728         was introduced in 2.62.
66730 2012-12-15  Ben Pfaff  <blp@cs.stanford.edu>
66732         New 'c-*printf' modules for formatted output in C locale.
66734         New module 'c-vasnprintf'.
66735         * modules/c-vasnprintf: New file.
66736         * lib/c-vasnprintf.c: New file.
66737         * lib/c-vasnprintf.h: New file.
66739         New module 'c-snprintf'.
66740         * modules/c-snprintf: New file.
66741         * modules/c-snprintf-tests: New file.
66742         * lib/c-snprintf.c: New file.
66743         * lib/c-snprintf.h: New file.
66744         * tests/test-c-snprintf.c: New file.
66745         * tests/test-c-snprintf.sh: New file.
66747         New module 'c-vsnprintf'.
66748         * modules/c-vsnprintf: New file.
66749         * modules/c-vsnprintf-tests: New file.
66750         * lib/c-vsnprintf.c: New file.
66751         * lib/c-vsnprintf.h: New file.
66752         * tests/test-c-vsnprintf.c: New file.
66753         * tests/test-c-vsnprintf.sh: New file.
66755         New module 'c-vasprintf'.
66756         * modules/c-vasprintf: New file.
66757         * modules/c-vasprintf-tests: New file.
66758         * lib/c-asprintf.c: New file.
66759         * lib/c-vasprintf.c: New file.
66760         * lib/c-vasprintf.h: New file.
66761         * tests/test-c-vasprintf.c  +: New file.
66762         * tests/test-c-vasprintf.sh: New file.
66764         New module 'c-xvasprintf'.
66765         * modules/c-xvasprintf: New file.
66766         * modules/c-xvasprintf-tests: New file.
66767         * lib/c-xasprintf.c: New file.
66768         * lib/c-xvasprintf.c: New file.
66769         * lib/c-xvasprintf.h: New file.
66770         * tests/test-c-xvasprintf.c: New file.
66771         * tests/test-c-xvasprintf.sh: New file.
66773 2012-12-18  Paul Eggert  <eggert@cs.ucla.edu>
66775         argp: better 'inline'
66776         Use extern-inline module to declare extern inline functions.
66777         This avoids some bogus warning diagnostics.  Problem discovered
66778         when modifying GNU tar to use the manywarnings module.
66779         * lib/argp.h, lib/argp-xinl.c (ARGP_EI) [!_LIBC]:
66780         * lib/argp-fmtstream.h, lib/argp-fs-xinl.c (ARGP_FS_EI) [!_LIBC]:
66781         Define based on extern-inline.
66782         * modules/argp (Depends-on): Add extern-inline.
66784 2012-12-17  Paul Eggert  <eggert@cs.ucla.edu>
66786         filemode, sys_stat: Handle MPX files a la AIX.
66787         * lib/filemode.c (ftypelet): Report 'm' for MPX files.
66788         * lib/sys_stat.in.h (S_ISMPX): New macro.
66789         * tests/test-sys_stat.c: Add tests for MPX files.
66791 2012-12-16  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
66793         x-to-1: honor $PERL
66794         * build-aux/x-to-1.in: Run $HELP2MAN via $PERL so that the user gets
66795         a chance to use his preferred version of Perl.  This is typically
66796         required by Darwin users whose default /usr/bin/perl does not have all
66797         the libraries required by help2man, and who need to use their MacPorts
66798         installation of Perl instead.
66800 2012-12-16  Akim Demaille  <akim@lrde.epita.fr>
66802         gnu-web-doc-update: add all the new files, even in new directories
66803         See http://lists.gnu.org/r/bug-gnulib/2012-12/msg00057.html
66804         * build-aux/gnu-web-doc-update (--dry-run, $dryrun): New.
66805         Use it.
66806         (main): Don't use cvsutils to get the list of unknown files,
66807         just add all the existing files and directories.
66809 2012-12-16  Akim Demaille  <akim@lrde.epita.fr>
66811         gnu-web-doc-update: improve --help
66812         * build-aux/gnu-web-doc-update: Move comments into --help.
66814 2012-12-07  Eric Wong  <normalperson@yhbt.net>
66816         mountlist: recognize more "dummy" file systems
66817         * lib/mountlist.c (ME_DUMMY_0):
66818         Add these dummy FS names to the list:
66819         - "debugfs" virtual filesystem for kernel debugging
66820         - "devpts" PTY slave filesystem
66821         - "devtmpfs" device filesystem on top of tmpfs/ramfs
66822         - "fusectl" control filesystem for FUSE
66823         - "mqueue" enumerates POSIX message queues
66824         - "rpc_pipefs" kernel <-> userspace bridge for NFS
66825         - "sysfs" is for exporting kernel objects
66826         - "devfs" device filesystem for Linux 2.4 and FreeBSD
66828 2012-12-11  Paul Eggert  <eggert@cs.ucla.edu>
66830         extern-inline: avoid incompatibility with Darwin Libc
66831         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE): Do not use
66832         extern inline if __APPLE__.  Use _GL_UNUSED in the non-inline branch.
66833         Problem reported by Akim Demaille in
66834         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00023.html>.
66836 2012-12-11  Simon Josefsson  <simon@josefsson.org>
66838         gnupload: Work with GnuPG using gpg-agent (for smartcards).
66839         * build-aux/gnupload: If GnuPG is configured to use gpg-agent,
66840         let it handle password prompting.
66842 2012-12-10  Eli Zaretskii  <eliz@gnu.org>
66844         canonicalize, canonicalize-lgpl: Microsoft Windows prefix fixes
66845         * lib/canonicalize.c (canonicalize_filename_mode):
66846         * lib/canonicalize-lgpl.c (__realpath): Recompute prefix_len after
66847         fetching the current directory.  Don't overrun the beginning of
66848         rpath if there's no slashes after the MS-Windows drive letter.
66850 2012-12-08  Stefano Lattarini  <stefano.lattarini@gmail.com>
66852         maint.mk: avoid extra forks
66853         * top/maint.mk (_cfg_mk): The GNU make manual documents that
66854         "$(wildcard FILE)" expands to empty if FILE doesn't exist.
66855         So use that instead of "$(shell test -f FILE && echo FILE)".
66857 2012-12-07  Paul Eggert  <eggert@cs.ucla.edu>
66859         vasnprintf: fix ASCII_ONLY typo
66860         * lib/unistdio/u8-vasnprintf.c (FCHAR_T_ONLY_ASCII):
66861         * lib/unistdio/u16-vasnprintf.c (FCHAR_T_ONLY_ASCII):
66862         * lib/unistdio/u32-vasnprintf.c (FCHAR_T_ONLY_ASCII):
66863         New macro, replacing ASCII_ONLY.  This fixes a typo.  See thread at
66864         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00021.html>.
66866 2012-12-05  Paul Eggert  <eggert@cs.ucla.edu>
66868         list, oset, xlist, xoset: fix extern inline issue with C99
66869         This was introduced by my recent changes for 'inline'.
66870         Problem reported for gettext by Daiki Ueno in
66871         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00000.html>.
66872         * lib/gl_list.h (gl_list_nx_create_empty, gl_list_create)
66873         (gl_list_nx_create, gl_list_size, gl_list_node_value)
66874         (gl_list_node_set_value, gl_list_node_nx_set_value, gl_list_next_node)
66875         (gl_list_previous_node, gl_list_get_at)
66876         (gl_list_nx_set_at, gl_list_search, gl_list_search_from)
66877         (gl_list_search_from_to, gl_list_indexof, gl_list_indexof_from)
66878         (gl_list_indexof_from_to, gl_list_nx_add_first, gl_list_nx_add_last)
66879         (gl_list_nx_add_before, gl_list_nx_add_after, gl_list_nx_add_at)
66880         (gl_list_remove_node, gl_list_remove_at, gl_list_remove, gl_list_free)
66881         (gl_list_iterator, gl_list_iterator_from_to, gl_list_iterator_next)
66882         (gl_list_iterator_free, gl_sortedlist_search)
66883         (gl_sortedlist_search_from_to, gl_sortedlist_indexof)
66884         (gl_sortedlist_indexof_from_to, gl_sortedlist_add, gl_sortedlist_nx_add)
66885         (gl_sortedlist_remove):
66886         * lib/gl_oset.h (go_oset_nx_create_empty, gl_oset_size, gl_oset_search)
66887         (gl_oset_search_atleast, gl_oset_nx_add, gl_oset_remove, gl_oset_free)
66888         (gl_oset_iterator, gl_oset_iterator_next, gl_oset_iterator_free):
66889         * lib/gl_xlist.h (gl_list_create_empty, gl_list_create)
66890         (gl_list_node_set_value, gl_list_set_at, gl_list_add_first)
66891         (gl_list_add_last, gl_list_add_before, gl_list_add_after)
66892         (gl_list_add_at, gl_sortedlist_add):
66893         * lib/gl_xoset.h (gl_oset_create_empty, gl_oset_add):
66894         Wrap these extern decls inside "#if 0", because they are implemented
66895         as inline functions, and extern inline is not what's wanted here.
66896         It would simplify these .h files to remove the extern decls entirely,
66897         although a downside would be less-clear separation between
66898         specification and implementation.
66900 2012-11-29  Paul Eggert  <eggert@cs.ucla.edu>
66902         sys_stat: no 'static inline'
66903         * lib/sys_stat.in.h (rpl_mkdir): Now static, not static inline.
66904         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Do not require AC_C_INLINE.
66906         extern-inline: no 'static inline'
66907         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
66908         Do not require AC_C_INLINE.
66909         (_GL_INLINE, _GL_EXTERN_INLINE): Define as 'static', not as
66910         'static inline', for older compilers.
66912         snippet/warn-on-use: no 'static inline'
66913         * build-aux/snippet/warn-on-use.h:
66914         Remove unnecessary 'inline' in comment.
66916         rbtree-list, rbtreehash-list: no 'static inline'
66917         * lib/gl_anyrbtree_list2.h (rotate_left, rotate_right):
66918         * lib/gl_anytree_list2.h (node_at):
66919         * lib/gl_anytreehash_list1.h (hash_resize_after_add)
66920         (gl_oset_first, add_nodes_to_buckets):
66921         Now static, not static inline.
66923         regex: no 'static inline'
66924         * lib/regex_internal.c (calc_state_hash):
66925         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain)
66926         (bitset_empty, bitset_set_all, bitset_copy, bitset_not, bitset_merge)
66927         (bitset_mask, re_string_char_size_at, re_string_wchar_at):
66928         Now static, not static inline.
66929         (inline) [__GNUC__ < 3 && _LIBC]:
66930         Remove macro; no longer needed.
66932         xvasprintf: no 'static inline'
66933         * lib/xvasprintf.c (xstrcat):
66934         Now static, not static inline.
66935         * m4/xvasprintf.m4 (gl_XVASPRINTF):
66936         Do not require AC_C_INLINE.
66938         parse-datetime, parse-duration: no 'static inline'
66939         * lib/parse-datetime.y (to_uchar):
66940         * lib/parse-duration.c (str_const_to_ul, str_const_to_l)
66941         (scale_n_add):
66942         Now static, not static inline.
66943         * m4/parse-datetime.m4 (gl_PARSE_DATETIME):
66944         * modules/parse-duration (configure.ac):
66945         Do not require AC_C_INLINE.
66947         getaddrinfo: no 'static inline'
66948         * lib/getaddrinfo.c (validate_family):
66949         Now static, not static inline.
66950         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO):
66951         Do not require AC_C_INLINE.
66953         ftruncate, fts, lstat, openat, raise: no 'static inline'
66954         * lib/ftruncate.c (chsize_nothrow):
66955         * lib/fts.c (opendirat, diropen):
66956         * lib/lstat.c (orig_lstat):
66957         * lib/openat.c (orig_openat):
66958         * lib/raise.c (raise_nothrow):
66959         Now static, not static inline.
66960         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE):
66961         * m4/fts.m4 (gl_FUNC_FTS_CORE):
66962         * m4/lstat.m4 (gl_PREREQ_LSTAT):
66963         * m4/openat.m4 (gl_PREREQ_OPENAT):
66964         * m4/raise.m4 (gl_PREREQ_RAISE):
66965         Do not require AC_C_INLINE.
66967         fflush, stat: no 'static inline'
66968         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
66969         (clear_ungetc_buffer, disable_seek_optimization)
66970         (restore_seek_optimization, update_fpos_cache):
66971         * lib/stat.c (orig_stat):
66972         Now static, not static inline.
66973         * lib/fflush.c (disable_seek_optimization, restore_seek_optimization)
66974         (update_fpos_cache):
66975         Define only if ! (defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1).
66976         * m4/fflush.m4 (gl_PREREQ_FFLUSH):
66977         * m4/stat.m4 (gl_PREREQ_STAT):
66978         Do not require AC_C_INLINE.
66980         error, filevercmp: no 'static inline'
66981         * lib/error.c (is_open, flush_stdout):
66982         * lib/filevercmp.c (order):
66983         Now static, not static inline.
66984         * m4/error.m4 (gl_PREREQ_ERROR):
66985         * modules/filevercmp (configure.ac):
66986         Do not require AC_C_INLINE.
66988         dup, execute, fatal-signal, etc.: no 'static inline'
66989         * lib/dup.c (dup_nothrow):
66990         * lib/execute.c (nonintr_close, nonintr_open):
66991         * lib/fatal-signal.c (uninstall_handlers, install_handlers):
66992         * lib/fopen.c (orig_fopen):
66993         * lib/freadseek.c (freadptrinc):
66994         * lib/freopen.c (orig_freopen):
66995         * lib/fstat.c (orig_fstat, fstat_nothrow):
66996         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit)
66997         (get_rusage_as_via_iterator):
66998         * lib/get-rusage-data.c (get_rusage_data_via_setrlimit):
66999         * lib/getdtablesize.c (_setmaxstdio_nothrow):
67000         * lib/isatty.c (_isatty_nothrow):
67001         * lib/open.c (orig_open):
67002         * lib/read.c (read_nothrow):
67003         * lib/sigprocmask.c (signal_nothrow):
67004         * lib/spawn-pipe.c (nonintr_close, nonintr_open):
67005         * lib/vasnprintf.c (MAX_ROOM_NEEDED):
67006         * lib/wait-process.c (unregister_slave_subprocess):
67007         * lib/write.c (write_nothrow):
67008         Now static, not static inline.
67009         * lib/spawn-pipe.c (nonintr_open): Define only if
67010         (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__.
67011         * m4/dup.m4 (gl_PREREQ_DUP):
67012         * m4/execute.m4 (gl_EXECUTE):
67013         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL):
67014         * m4/fopen.m4 (gl_PREREQ_FOPEN):
67015         * m4/freadseek.m4 (gl_FUNC_FREADSEEK):
67016         * m4/freopen.m4 (gl_PREREQ_FREOPEN):
67017         * m4/fstat.m4 (gl_PREREQ_FSTAT):
67018         * m4/getdtablesize.m4 (gl_PREREQ_GETDTABLESIZE):
67019         * m4/isatty.m4 (gl_PREREQ_ISATTY):
67020         * m4/open.m4 (gl_PREREQ_OPEN):
67021         * m4/read.m4 (gl_PREREQ_READ):
67022         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK):
67023         * m4/spawn-pipe.m4 (gl_SPAWN_PIPE):
67024         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF):
67025         * m4/wait-process.m4 (gl_WAIT_PROCESS):
67026         * m4/write.m4 (gl_PREREQ_WRITE):
67027         * modules/get-rusage-as, modules/get-rusage-data (configure.ac):
67028         Do not require AC_C_INLINE.
67030         c-strtod, memcoll, readutmp: no 'static inline'
67031         * lib/c-strtod.c (c_locale):
67032         * lib/memcoll.c (strcoll_loop):
67033         * lib/readutmp.c (desirable_utmp_entry):
67034         Now static, not static inline.
67035         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOLD):
67036         * m4/memcoll.m4 (gl_MEMCOLL):
67037         * m4/readutmp.m4 (gl_READUTMP):
67038         Do not require AC_C_INLINE.
67040         arctwo, md4, md5, sha1, sha256, sha512: no 'static inline'
67041         * lib/arctwo.c (to_uchar):
67042         * lib/md4.c (set_uint32):
67043         * lib/md5.c (set_uint32):
67044         * lib/sha1.c (set_uint32):
67045         * lib/sha256.c (set_uint32):
67046         * lib/sha512.c (set_uint64):
67047         Now static, not static inline.  This is a bit simpler, and doesn't
67048         affect performance with GCC and default optimization.
67049         * m4/arctwo.m4 (gl_ARCTWO):
67050         * m4/md4.m4 (gl_MD4):
67051         * m4/md5.m4 (gl_MD5):
67052         * m4/sha1.m4 (gl_SHA1):
67053         * m4/sha256.m4 (gl_SHA256):
67054         * m4/sha512.m4 (gl_SHA512):
67055         Do not require AC_C_INLINE.
67057         cond, lock, thread: better 'inline'
67058         * lib/glthread/cond.c, lib/glthread/cond.h (_GLTHREAD_COND_INLINE):
67059         * lib/glthread/thread.c, lib/glthread/thread.h (_GLTHREAD_THREAD_INLINE):
67060         New macros.  Use them instead of static inline, for header functions.
67061         * lib/glthread/cond.c (gl_waitqueue_init, gl_waitqueue_remove)
67062         (gl_waitqueue_notify_first, gl_waitqueue_notify_all):
67063         * lib/glthread/lock.c (gl_waitqueue_init)
67064         (gl_waitqueue_notify_first, gl_waitqueue_notify_all):
67065         * lib/glthread/thread.c (get_current_thread_handle):
67066         Change 'static inline' to 'inline'.
67067         * lib/glthread/cond.h, lib/glthread/thread.h:
67068         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67069         * m4/cond.m4 (gl_COND):
67070         * m4/lock.m4 (gl_PREREQ_LOCK):
67071         * m4/thread.m4 (gl_THREAD):
67072         Do not require AC_C_INLINE.
67073         * modules/cond, modules/thread (Depends-on): Add extern-inline.
67075         chdir-long, cycle-check, savewd: better 'inline'
67076         * lib/chdir-long.c (cdb_init, cdb_fchdir, cdb_free)
67077         (find_non_slash):
67078         * lib/cycle-check.c (is_zero_or_power_of_two):
67079         * lib/savewd.c (savewd_delegating):
67080         Change 'static inline' to 'inline'.
67081         * lib/savewd.c, lib/savewd.h (SAVEWD_INLINE): New macro.
67082         Replace all remaining uses of 'static inline' with it.
67083         * lib/savewd.h:
67084         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67085         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG):
67086         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
67087         * m4/savewd.m4 (gl_SAVEWD):
67088         Do not require AC_C_INLINE.
67089         * modules/savewd (Depends-on): Add extern-inline.
67091         base32, base64: no need for 'inline'
67092         * lib/base32.c (to_uchar, get_8, decode_8):
67093         * lib/base64.c (to_uchar, get_4, decode_4):
67094         Change 'static inline' to 'inline'.
67095         * m4/base32.m4 (gl_PREREQ_BASE32):
67096         * m4/base64.m4 (gl_PREREQ_BASE64):
67097         Do not require AC_C_INLINE.
67099         array-oset, linkedhash-list, rbtree-oset: no need for 'inline'
67100         * lib/gl_array_oset.c (gl_array_nx_add_at):
67101         (gl_array_remove_at):
67102         * lib/gl_linkedhash_list.c (hash_resize_after_add)
67103         (add_to_bucket, remove_from_bucket):
67104         * lib/gl_rbtree_oset.c (rotate_left, rotate_right):
67105         Change 'static inline' to 'static', as it's simpler to omit
67106         'inline' unless there's a significant performance advantage.
67108         list, oset, xlist, xoset, xsublist: simplify via extern inline
67109         * lib/gl_list.h, lib/gl_list.c (GL_LIST_INLINE):
67110         * lib/gl_oset.c, lib/gl_oset.h (GL_OSET_INLINE):
67111         * lib/gl_xlist.c, lib/gl_xlist.h (GL_XLIST_INLINE):
67112         * lib/gl_xoset.c, lib/gl_xoset.h (GL_XOSET_INLINE):
67113         * lib/gl_xsublist.c, lib/gl_xsublist.h (GL_XSUBLIST_INLINE):
67114         New macro.  Replace all uses of 'static inline' with it.
67115         [HAVE_INLINE]: Implement functions as *_INLINE functions,
67116         instead of as macros FOO that are defined to static inline
67117         functions FOO_inline.
67118         * lib/gl_list.c, lib/gl_oset.c, lib/gl_xlist.c, lib/gl_xoset.c:
67119         * lib/gl_xsublist.c:
67120         Reimplement from scratch, by defining the corresponding *_INLINE
67121         macro and including the corresponding .h file.  This is simpler.
67122         * modules/list, modules/oset, modules/xlist, modules/xoset:
67123         (Files): Remove m4/gl_list.m4.
67124         (configure.ac): Remove gl_LIST.
67125         * m4/gl_list.m4: Remove.
67126         * modules/list, modules/oset, modules/xlist, modules/xoset:
67127         * modules/xsublist:
67128         (Depends-on): Depend on extern-inline, not inline.
67130         xalloc: better 'inline'
67131         * lib/xmalloc.c, lib/xalloc.h (XALLOC_INLINE):
67132         New macro.  Replace all uses of 'static inline' with it.
67133         (static_inline): Remove.
67134         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
67135         Let 'extern inline' do the work automatically, instead of doing
67136         it by hand.
67137         * m4/xalloc.m4 (gl_PREREQ_XALLOC, gl_PREREQ_XMALLOC):
67138         Remove.  All uses removed.
67139         * modules/xalloc (Depends-on): Remove 'inline'.  Add 'extern-inline'.
67141         gethrxtime: better 'inline'
67142         * lib/xtime.c: New file.
67143         * lib/gethrxtime.c, lib/gethrxtime.h (GETHRXTIME_INLINE):
67144         * lib/xtime.h (XTIME_INCLUDE):
67145         New macros.  Replace all uses of 'static inline' with them.
67146         * lib/gethrxtime.c (gethrxtime): Define only if
67147         ! (HAVE_ARITHMETIC_HRTIME_T && HAVE_DECL_GETHRTIME), since
67148         this source file is now always compiled, because of the extern inline.
67149         * lib/gethrxtime.h, lib/xtime.h:
67150         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67151         * m4/gethrxtime.m4 (gl_GETHRXTIME): Do not check for clock macros
67152         if gethrtime works, as they're not needed in that case.
67153         (gl_XTIME): Do not require AC_C_INLINE.
67154         (gl_PREREQ_GETHRXTIME): Remove; all uses removed, as it's always
67155         compiled now.  Move the check into gl_GETHRXTIME.
67156         * modules/gethrxtime (Files, lib_SOURCES): Add lib/xtime.c.
67157         (Depends-on): Add extern-inline.
67158         (configure.ac): gethrxtime is always compiled now.
67159         (lib_SOURCES): Add gethrxtime.c.
67161         wctype-h: better 'inline'
67162         * lib/wctype-h.c: New file.
67163         * lib/wctype.in.h (_GL_WCTYPE_INLINE):
67164         New macro.  Replace all uses of 'static inline' with it.
67165         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67166         * m4/wctype_h.m4 (gl_WCTYPE_H): Do not require AC_C_INLINE.
67167         * modules/wctype-h (Files, lib_SOURCES): Add lib/wctype-h.c.
67168         (Depends-on): Add extern-inline.
67170         unistd: better 'inline'
67171         * lib/unistd.c: New file.
67172         * lib/unistd.in.h (_GL_UNISTD_INLINE):
67173         New macro.  Replace all uses of 'static inline' with it.
67174         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67175         * m4/unistd_h.m4 (gl_UNISTD_H): Do not require AC_C_INLINE.
67176         * modules/unistd (Files, lib_SOURCES): Add lib/unistd.c.
67177         (Depends-on): Add extern-inline.
67179         sys_socket: better 'inline'
67180         * lib/sys_socket.c: New file.
67181         * lib/sys_socket.in.h (_GL_SYS_SOCKET_INLINE):
67182         New macro.  Replace all uses of 'static inline' with it.
67183         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67184         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Do not require AC_C_INLINE.
67185         * modules/sys_socket (Files, lib_SOURCES): Add lib/sys_socket.c.
67186         (Depends-on): Add extern-inline.
67188         stdio: better 'inline'
67189         * lib/stdio.c: New file.
67190         * lib/stdio.in.h (_GL_STDIO_INLINE):
67191         New macro.  Replace all uses of 'static inline' with it.
67192         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67193         * m4/stdio_h.m4 (gl_STDIO_H): Do not require AC_C_INLINE.
67194         * modules/stdio (Files, lib_SOURCES): Add lib/stdio.c.
67195         (Depends-on): Add extern-inline.
67197         sigaction: better 'inline'
67198         * lib/sig-handler.c: New file.
67199         * lib/sig-handler.h (SIG_HANDLER_INLINE):
67200         New macro.  Replace all uses of 'static inline' with it.
67201         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67202         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): Do not require AC_C_INLINE.
67203         * modules/sigaction (Files, lib_SOURCES): Add lib/sig-handler.c.
67204         (Depends-on): Add extern-inline.
67206         selinux-h: better 'inline'
67207         * lib/se-context.c, lib/se-selinux.c: New files.
67208         * lib/getfilecon.c (map_to_failure): Omit 'inline' for static function.
67209         * lib/se-context.in.h (SE_CONTEXT_INLINE):
67210         New macro.  Replace all uses of 'static inline' with it.
67211         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67212         * lib/se-selinux.in.h (SE_SELINUX_INLINE):
67213         New macro.  Replace all uses of 'static inline' with it.
67214         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67215         * modules/selinux-h (Files, lib_SOURCES):
67216         Add lib/se-context.c, lib/se-selinux.c.
67217         (Depends-on): Add extern-inline.
67218         (configure.ac): Do not require AC_C_INLINE.
67220         pthread: better 'inline'
67221         * lib/pthread.c: New file.
67222         * lib/pthread.in.h (_GL_PTHREAD_INLINE):
67223         New macro.  Replace all uses of 'static inline' with it.
67224         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67225         * m4/pthread.m4 (gl_PTHREAD_CHECK):
67226         Add AC_LIBOBJ([pthread]).  Do not require AC_C_INLINE.
67227         * modules/pthread (Files): Add lib/pthread.c.
67228         (Depends-on): Add extern-inline.
67230         math: better 'inline'
67231         * lib/math.c: New file.
67232         * lib/math.in.h (_GL_MATH_INLINE):
67233         New macro.  Replace all uses of 'static inline' with it.
67234         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67235         * m4/math_h.m4 (gl_MATH_H):
67236         Do not require AC_C_INLINE.
67237         * modules/math (Files, lib_SOURCES):
67238         Add lib/math.c.
67239         (Depends-on): Add extern-inline.
67241         count-one-bits: better 'inline'
67242         * lib/count-one-bits.c: New file.
67243         * lib/count-one-bits.h (COUNT_ONE_BITS_INLINE):
67244         New macro.  Replace all uses of 'static inline' with it.
67245         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67246         * m4/count-one-bits.m4 (gl_COUNT_ONE_BITS):
67247         Do not require AC_C_INLINE.
67248         * modules/count-one-bits (Files, lib_SOURCES):
67249         Add lib/count-one-bits.c.
67250         (Depends-on): Add extern-inline.
67252         count-leading-zeros: better 'inline'
67253         * lib/count-leading-zeros.c: New file.
67254         * lib/count-leading-zeros.h (COUNT_LEADING_ZEROS_INLINE):
67255         New macro.  Replace all uses of 'static inline' with it.
67256         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67257         * m4/count-leading-zeros.m4 (gl_COUNT_LEADING_ZEROS):
67258         Do not require AC_C_INLINE.
67259         * modules/count-leading-zeros (Files, lib_SOURCES):
67260         Add lib/count-leading-zeros.c.
67261         (Depends-on): Add extern-inline.
67263         bitrotate: better 'inline'
67264         * lib/bitrotate.c: New file.
67265         * lib/bitrotate.h (BITROTATE_INLINE):
67266         New macros.
67267         Replace all uses of 'static inline' with them.
67268         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67269         * modules/bitrotate (Files, lib_SOURCES): Add lib/bitrotate.c.
67270         (Depends-on): Add extern-inline.
67271         (configure.ac): Do not require AC_C_INLINE.
67273 2012-11-20  Theophile Ranquet  <ranquet@lrde.epita.fr>
67275         maint.mk: avoid gratuitous failure
67276         Reported by Stefano Lattarini in
67277         <http://lists.gnu.org/r/bug-bison/2012-11/msg00022.html>
67278         * top/maint.mk (public-submodule-commit): Quote more safely.
67280 2012-11-20  Eli Zaretskii  <eliz@gnu.org>
67282         canonicalize, canonicalize-lgpl: support MS-Windows file names
67283         See <http://lists.gnu.org/r/bug-gnulib/2012-11/msg00074.html>
67284         for test cases, which it'd be nice to add at some point.
67285         * lib/canonicalize.c, lib/canonicalize-lgpl.c: Include dosname.h.
67286         * lib/canonicalize.c (canonicalize_filename_mode):
67287         * lib/canonicalize-lgpl.c (__realpath):
67288         Use FILE_SYSTEM_PREFIX_LEN instead of assuming that the first
67289         slash is at the beginning of the file name.  Use ISSLASH, instead
67290         of a literal '/'.  Use IS_ABSOLUTE_FILE_NAME instead of comparing
67291         the first character with '/'.  Test for
67292         DOUBLE_SLASH_IS_DISTINCT_ROOT only if the file name does not begin
67293         with a drive letter.
67294         * lib/canonicalize.c (SLASHES): New macro.
67295         (canonicalize_filename_mode): Use SLASHES instead of a literal "/".
67297 2012-11-17  Dmitry V. Levin  <ldv@altlinux.org>
67299         fts: introduce FTS_VERBATIM
67300         * lib/fts_.h (FTS_VERBATIM): New bit flag.
67301         (FTS_OPTIONMASK, FTS_NAMEONLY, FTS_STOP): Adjust.
67302         * lib/fts.c (fts_open): Honor it.
67304 2012-11-09  Pádraig Brady  <P@draigBrady.com>
67306         getlogin-tests: allow errno == ENXIO
67307         * tests/test-getlogin.c (main): Skip tests if getlogin fails
67308         with errno == ENXIO (No controlling tty).
67309         getlogin_r-tests: Likewise. Also allow errno == ENOENT
67310         * tests/test-getlogin_r.c (main): Skip tests if getlogin_r fails
67311         with errno == ENOENT.  This was reported to happen in various
67312         situations on GNU/Linux.
67314 2012-11-09  Paul Eggert  <eggert@cs.ucla.edu>
67316         getlogin-tests: allow errno == ENOENT
67317         * tests/test-getlogin.c (main): Skip tests if getlogin fails
67318         with errno == ENOENT.  This happened to me on Ubuntu 12.04.1 x86,
67319         when running a test in an Emacs shell buffer.
67321 2012-11-08  Jim Meyering  <jim@meyering.net>
67323         tests/nap.h: avoid warning about unused variable
67324         * tests/nap.h (nap_works): Remove now-unused declaration of "result".
67326         prefix-gnulib-mk: avoid overzealous "lib/"-prefix addition
67327         * build-aux/prefix-gnulib-mk (prefix): Tighten a regexp to require
67328         white space before each of the special-cased file names, to avoid
67329         adding "lib/" after $(libdir)/.  Reported by Matias A. fonzo
67330         in http://bugs.gnu.org/12830.
67332 2012-11-08  Paul Eggert  <eggert@cs.ucla.edu>
67334         fcntl-h: default O_SEARCH, O_EXEC back to O_RDONLY
67335         O_PATH doesn't work with Linux kernel 3.6.5, as fchmod (fd, ...)
67336         fails with errno == EBADF when fd is opened with O_PATH.
67337         Reported by Jim Meyering in
67338         <http://lists.gnu.org/r/bug-gnulib/2012-11/msg00026.html>.
67339         * doc/posix-headers/fcntl.texi (fcntl.h): Document this.
67340         * lib/fcntl.in.h (O_EXEC, O_SEARCH) [O_PATH]: Default back to O_RDONLY.
67342 2012-11-07  Paul Eggert  <eggert@cs.ucla.edu>
67344         test-utimens: speed up by taking shorter naps
67345         * tests/nap.h (lt_mtime, get_mtime, nap_works, guess_delay):
67346         New functions.
67347         (nap): Use them, to do a better job of guessing the delay.
67348         On Fedora 17 with ext4 atop md atop hard disks, this made
67349         test-utimens run 10x faster, because the test napped for
67350         1 ms at a time rather than 20 ms.  Reported by Stefano Lattarini in
67351         <http://bugs.gnu.org/12820#11>.
67353 2012-11-07  Jim Meyering  <jim@meyering.net>
67355         mountlist.c: fix a compilation failure
67356         * lib/mountlist.c (read_file_system_list): Fix a compilation failure
67357         I introduced while transforming commit v0.0-7683-g613bcb6
67359 2012-11-05  Paul Eggert  <eggert@cs.ucla.edu>
67361         errno: port to LynxOS 178 2.2.2
67362         Problem reported by Joel Brobecker in
67363         <http://lists.gnu.org/r/bug-gnulib/2012-10/msg00088.html>.
67364         * doc/posix-headers/errno.texi (errno.h): Document this.
67365         * lib/errno.in.h (EILSEQ, GNULIB_defined_EILSEQ) [!EILSEQ]: New macros.
67366         * lib/strerror-override.c, lib/strerror-override.h (strerror_override):
67367         Supply a string for EILSEQ.
67368         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Check for EILSEQ.
67370 2012-11-05  Paul Eggert  <eggert@cs.ucla.edu>
67372         fcntl-h: default O_SEARCH, O_EXEC to O_PATH if available
67373         Linux kernel 2.6.39 introduced O_PATH (see
67374         <http://lwn.net/Articles/433854/>) and this is a better fallback
67375         for O_SEARCH and O_EXEC than O_RDONLY, if O_PATH is available.
67376         * doc/posix-headers/fcntl.texi (fcntl.h): Document this.
67377         * lib/fcntl.in.h (O_EXEC, O_SEARCH) [O_PATH]: Default to O_PATH.
67378         * lib/fcntl.in.h (O_ACCMODE):
67379         * tests/test-fcntl-h.c (main):
67380         Do not reject O_ACCMODE merely because it has more than the
67381         minimal number of bits, as POSIX allows extensions here.
67383 2012-11-04  Andrew Warshall  <warshall@99main.com>  (tiny change)
67385         mountlist: do not classify a bind-mounted dir entry as "dummy"
67386         * lib/mountlist.c (ME_DUMMY_0): Rename from ME_DUMMY, but omit
67387         the "none"-testing clause.
67388         (ME_DUMMY) [MOUNTED_GETMNTENT1]: New macro to encapsulate the
67389         exception for bind-mounted directories.
67391 2012-11-01  Akim Demaille  <akim@lrde.epita.fr>
67393         quote: provide a means to escape strings with nul characters
67394         * lib/quote.h, lib/quotearg.c (quote_mem, quote_n_mem): New functions.
67395         (quote, quote_n): Rename formal arguments for consistency with
67396         quotearg.
67398 2012-10-30  Paul Eggert  <eggert@cs.ucla.edu>
67400         test-raise: don't assume 199 is an invalid signal
67401         * tests/test-raise.c (main): Don't assume 199 is not a signal number.
67403         sh-quote-tests: port to Solaris 9
67404         * modules/sh-quote-tests (test_sh_quote_LDADD): Add @LIBINTL@.
67405         Problem reported by Dagobert Michelsen in
67406         <http://lists.gnu.org/r/bug-gnulib/2012-10/msg00114.html>.
67408 2012-10-28  Jim Meyering  <jim@meyering.net>
67410         maint.mk: rename a new configurable variable
67411         * top/maint.mk (_gl_translatable_string_re): Rename from
67412         translation-markers: _gl_ prefix to insulate from user Makefile code,
67413         and the _re suffix to inform that it's a regular expression.
67415 2012-10-26  Eric Blake  <eblake@redhat.com>
67417         maint.mk: let packages tweak sc_po_check pattern
67418         * top/maint.mk (sc_po_check): Add translation-markers, to allow
67419         finding files with other translation markers.
67421 2012-10-16  Paul Eggert  <eggert@cs.ucla.edu>
67423         euidaccess: speed up 'configure' on GNU hosts
67424         * m4/euidaccess.m4 (gl_FUNC_NONREENTRANT_EUIDACCESS):
67425         Check for setregid here, not in gl_PREREQ_EUIDACCESS, since
67426         it's needed only in this case.  Use AC_CHECK_DECLS, not
67427         AC_CHECK_DECLS_ONCE.
67428         (gl_PREREQ_EUIDACCESS): Do not use AC_CHECK_HEADERS_ONCE libgen.h
67429         or AC_REQUIRE for AC_FUNC_GETGROUPS.
67431         * lib/regexec.c (re_search_internal): Fix grammar in comment.
67433 2012-10-15  Paul Eggert  <eggert@cs.ucla.edu>
67435         fchmodat, fchownat, fstatat: port to non-inlining compilers
67436         Problem reported for FreeBSD 9 by Jim Meyering in
67437         <http://lists.gnu.org/r/bug-gnulib/2012-10/msg00070.html>.
67438         * lib/chmodat.c, lib/chownat.c, lib/statat.c:
67439         New files, which define FCHMODAT_INLINE etc.
67440         * lib/fchmodat.c (FCHMODAT_INLINE):
67441         * lib/fchownat.c (FCHOWNAT_INLINE):
67442         * lib/fstatat.c (FSTATAT_INLINE):
67443         Remove, as chmodat.c etc. now do this.
67444         * modules/fchmodat (Files): Add lib/chmodat.c.
67445         * modules/fchownat (Files): Add lib/chownat.c.
67446         * modules/fstatat (Files): Add lib/statat.c.
67448 2012-10-15  Jim Meyering  <jim@meyering.net>
67450         fchmodat.c, fchownat.c: compile-impeding typos
67451         * lib/fchmodat.c (FCHMODAT_INLINE): Fix typo: s/#include/#define/
67452         * lib/fchownat.c (FCHOWNAT_INLINE): Likewise.
67453         Introduced in commit v0.0-7636-gd202279.
67455 2012-10-15  Paul Eggert  <eggert@cs.ucla.edu>
67457         fcntl-h: support GNU flags like O_IGNORE_CTTY
67458         * doc/posix-headers/fcntl.texi (fcntl.h): Support O_IGNORE_CTTY,
67459         O_NOLINK, and O_NOTRANS.  These flags are nonzero on GNU/Hurd
67460         systems.  Discovered when using fcntl-h with GNU Emacs, which uses
67461         O_IGNORE_CTTY.  Fix misspelling of F_SETLKW.
67462         * lib/fcntl.in.h (O_IGNORE_CTTY, O_NOLINK, O_NOTRANS):
67463         Define to 0 if not already defined.
67464         * tests/test-fcntl-h.c: Test these new flags.
67466 2012-10-14  Paul Eggert  <eggert@cs.ucla.edu>
67468         faccessat, etc.: support AT_FDCWD-only use
67469         * lib/at-func.c: If GNULIB_SUPPORT_ONLY_AT_FDCWD, then support
67470         this function only if its first argument is AT_FDCWD.
67471         Emacs wants faccessat for AT_EACCESS but not for any first-arg
67472         values other than AT_FDCWD, so it doesn't want all the openat
67473         machinery with fchdir etc.
67474         * modules/faccessat, modules/fchmodat, modules/fchownat (Files):
67475         * modules/fstatat, modules/mkdirat, modules/openat (Files):
67476         * modules/unlinkat (Files):
67477         Remove lib/openat-priv.h, as at-internal supplies this file.
67478         Removing this file here allows us to support programs like Emacs
67479         that avoid at-internal.
67481         faccessat: speed up 'configure' on mainstream hosts
67482         * m4/faccessat.m4 (gl_PREREQ_FACCESSAT):
67483         Use AT_CHECK_FUNCS for 'access', not AC_CHECK_FUNCS_ONCE,
67484         since it's only on unusual platforms that we need to check for
67485         'access', and it's better not to slow 'configure' down on all
67486         platforms.
67488         faccessat: port to Solaris 10
67489         * lib/faccessat.c: Include <fcntl.h>, for AT_EACCESS.
67490         Needed on Solaris 10, which doesn't have AT_EACCESS,
67491         so we need the Gnulib fcntl.h, which defines it.
67493 2012-10-14  Pádraig Brady  <P@draigBrady.com>
67494         canonicalize: fix C89 compilation
67495         * lib/canonicalize.c (canonicalize_filename_mode): Swap order of
67496         declarations so C89 is supported.  Also remove the comment
67497         referencing memorty allocation as the suggested feature could
67498         not be implemented as suggested.
67499         Reported by Michael Goffioul.
67501 2012-10-12  Paul Eggert  <eggert@cs.ucla.edu>
67503         group-member: omit unnecessary dependencies
67504         This is for Emacs, which has its own allocator and where we
67505         don't want to use xalloc.
67506         * lib/group-member.c: Include xalloc-oversized.h, not xalloc.h,
67507         since we no longer use xmalloc.  Do not include stdbool.h, since
67508         the changes below happen to remove the only use of bool.
67509         (GROUPBUF_SIZE): New constant.
67510         (struct group_info): Remove n_groups member.  Add groupbuf member.
67511         This lets us get the groups without using malloc, usually.
67512         (free_group_info, get_group_info): Adjust to this.
67513         (get_group_info): Return the number of groups found, or -1 on error.
67514         Use plain malloc not xmalloc, and treat its failure as if there
67515         are no groups, as the user already loses in case of error.
67516         (group_member): Simplify, based on changes to get_group_info.
67517         * modules/group-member (Depends-on): Remove dependencies on
67518         xalloc and stdbool.  Add dependency on xalloc-oversized.
67520 2012-10-08  Alexandre Duret-Lutz  <adl@lrde.epita.fr>  (tiny change)
67522         gethrxtime: port to C++
67523         * lib/gethrxtime.h, lib/xtime.h [__cplusplus]: Add extern "C".
67525 2012-10-04  Paul Eggert  <eggert@cs.ucla.edu>
67527         ptsname: fix macro-name typo
67528         * lib/stdlib.in.h (ptsname): Fix misspelling of GNULIB_NAMESPACE.
67530 2012-10-03  Simon Josefsson  <simon@josefsson.org>
67532         inttostr: Relax license.
67533         * modules/inttostr (License): Change from LGPL to LGPLv2+.
67535 2012-10-03  Eric Blake  <eblake@redhat.com>
67537         ptsname_r: support ptys returned by FreeBSD posix_openpt
67538         * lib/ptsname_r.c (__ptsname_r): Don't munge name if it already
67539         lives in /dev/pts/.
67541 2012-10-02  Eric Blake  <eblake@redhat.com>
67543         pselect: reject invalid file descriptors
67544         * m4/pselect.m4 (gl_FUNC_PSELECT): Probe for FreeBSD bug.
67545         * lib/pselect.c (rpl_pselect) [!win32]: Work around it.
67546         * modules/pselect (Depends-on): Add dup2.
67547         * doc/posix-functions/pselect.texi (pselect): Document this.
67549         select: reject invalid file descriptors
67550         * m4/select.m4 (gl_FUNC_SELECT): Probe for FreeBSD bug.
67551         * lib/select.c (rpl_select) [!win32]: Work around it.
67552         * modules/select (Depends-on): Add dup2.
67553         * doc/posix-functions/select.texi (select): Document this.
67555         select: enhance test
67556         * tests/test-select.h (do_select_bad_nfd_nowait, test_bad_nfd):
67557         New functions.
67558         (test_function): Enhance test.
67559         (do_select_bad_fd): Avoid any stale errno values.
67561         ptsname: reject invalid file descriptors
67562         http://www.austingroupbugs.net/view.php?id=503
67563         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Probe for FreeBSD bug.
67564         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Add new witness.
67565         * modules/stdlib (Makefile.am): Replace witness.
67566         * lib/stdlib.in.h (ptsname): Allow for replacement.
67567         * modules/ptsname (configure.ac): Trigger replacement.
67568         * doc/posix-functions/ptsname.texi (ptsname): Document this.
67570 2012-10-02  Nikos Mavrogiannopoulos  <nmav@gnutls.org>  (tiny change)
67572         hash-pjw-bare: new module
67573         * lib/hash-pjw-bare.c: New file, very much like hash-pjw.c.
67574         * lib/hash-pjw-bare.h: Likewise.
67575         * modules/hash-pjw-bare: New file.
67576         * MODULES.html.sh (Misc): Add it.
67578 2012-10-02  Eric Blake  <eblake@redhat.com>
67580         manywarnings: cater to more gcc infelicities
67581         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add test for
67582         -Wuninitialized without -O.
67584 2012-10-01  Ed Maste  <emaste@freebsd.org>  (tiny change)
67586         select, poll tests: Make setsockopt invocation effective.
67587         * tests/test-poll.c (open_server_socket): Move setsockopt() call before
67588         the bind() call.
67589         * tests/test-select.h (open_server_socket): Likewise.
67591 2012-09-30  Paul Eggert  <eggert@cs.ucla.edu>
67593         sockets, sys_stat: restore AC_C_INLINE
67594         This undoes the 2012-09-22 patch.
67595         * m4/sockets.m4 (gl_SOCKETS):
67596         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H):
67597         Restore AC_C_INLINE, since MSVC requires __inline or _inline
67598         and does not support plain 'inline'.  Reported by Bruno Haible in
67599         <http://lists.gnu.org/r/bug-gnulib/2012-09/msg00183.html>.
67601 2012-09-30  Bruno Haible  <bruno@clisp.org>
67603         localeconv tests: Avoid test failure on OpenIndiana.
67604         * tests/test-localeconv.c (main): On OpenIndiana (a Solaris 11 variant)
67605         skip the 'grouping' and 'mon_grouping' tests.
67606         Reported by Jim Meyering.
67608 2012-09-30  Bruno Haible  <bruno@clisp.org>
67610         havelib: Follow libtool developments.
67611         * m4/lib-ld.m4: Rebase on libtool.m4 from libtool-2.4.
67612         Suggested by Simon Josefsson.
67614 2012-09-29  Jim Meyering  <meyering@redhat.com>
67616         fstatat.c: fix a compile-impeding typo
67617         * lib/fstatat.c (FSTATAT_INLINE): Fix typo: s/#include/#define/
67618         Introduced in commit v0.0-7636-gd202279.
67619         Mats Erik Andersson reported the resulting OpenBSD compilation failure.
67621 2012-09-28  Akim Demaille  <akim@lrde.epita.fr>
67623         extern-inline: provide a -Wundef safe config.h
67624         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Protect
67625         "#if __GNUC_STDC_INLINE__" with "defined __GNUC_STDC_INLINE__"
67626         to produce a -Wundef warning free config.h.
67628 2012-09-26  Paul Eggert  <eggert@cs.ucla.edu>
67630         hash-pjw: relax license to LGPLv2+
67631         * modules/hash-pjw (License): Relax, with consent of author.
67633 2012-09-25  Akim Demaille  <akim@lrde.epita.fr>
67635         maint.mk: fix strict vs. lazy variable issues with RELEASE
67636         * top/maint.mk (_equal): New function.
67637         (member_check): Strip the result to avoid spurious spaces.
67638         (url_dir_list): Do not use ifeq, which is strict, as it will
67639         require RELEASE_TYPE to be defined.
67640         (announcement_Cc_, announcement_mail_headers_): Likewise: instead
67641         of relying on ifeq, use $(release_type) to dispatch (lazily) onto...
67642         (announcement_Cc_alpha,announcement_mail_headers_alpha)
67643         (announcement_Cc_beta,announcement_mail_headers_beta)
67644         (announcement_Cc_stable,announcement_mail_headers_stable): these.
67645         (release): Do not depend on $(release-type), as it forces its
67646         evaluation.  Bounce to it.
67648 2012-09-25  Akim Demaille  <akim@lrde.epita.fr>
67650         maint.mk: formatting changes
67651         * top/maint.mk: Indent bodies of if's.
67653 2012-09-21  Akim Demaille  <akim@lrde.epita.fr>
67655         maint.mk: factor the validation of RELEASE_TYPE
67656         With help from Jim Meyering.
67657         http://lists.gnu.org/r/bug-gnulib/2012-09/msg00132.html
67658         * top/maint.mk (_empty, _sp): Move their definition earlier.
67659         (member-check, release-type): New.
67660         Use the latter instead of $(RELEASE_TYPE).
67661         Remove now useless local checks.
67663 2012-09-20  Akim Demaille  <akim@lrde.epita.fr>
67665         maint.mk: provide "make upload" to ease uploading
67666         See
67667         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00028.html>.
67668         Do not depend simply on the current $(VERSION), as there may have been
67669         new commits since the tarball generation.  Rather, rely on $(RELEASE),
67670         as "make release-commit" already does.
67672         For consistency, add "make release RELEASE='X.Y TYPE'" as an alias for
67673         "make TYPE".
67675         * top/maint.mk (upload_command, upload, release): New.
67676         (RELEASE_TYPE): If undefined, default to the second word of $(RELEASE).
67677         (VERSION): first word of $(RELEASE) is always right.
67678         (emit_upload_commands): Adjust.
67679         * top/README-release: Update.
67681 2012-09-20  Akim Demaille  <akim@lrde.epita.fr>
67683         maint.mk: silent rules
67684         With help from Stefano Lattarini.
67685         * top/maint.mk (writable-files): Use $(AM_V_GEN).
67686         (announcement): Use $(AM_V_at).
67688 2012-09-24  Paul Eggert  <eggert@cs.ucla.edu>
67690         localename: port gl_locale_name_thread_unsafe to FreeBSD
67691         * lib/localename.c (gl_locale_name_thread_unsafe): Port to FreeBSD,
67692         and use the simpler FreeBSD implementation on Mac OS X as well.
67693         Original idea suggested by Ed Maste in
67694         <http://lists.gnu.org/r/bug-gnulib/2012-09/msg00094.html>.
67696 2012-09-22  Paul Eggert  <eggert@cs.ucla.edu>
67698         binary-io, eealloc, mbfile, mbiter, mbutil, xsize: better 'inline'
67699         * lib/binary-io.c, lib/eealloc.c, lib/mbfile.c, lib/mbiter.c:
67700         * lib/mbuiter.c, lib/xsize.c: New files.
67701         * lib/binary-io.h (BINARY_IO_INLINE):
67702         * lib/eealloc.h (EEALLOC_INLINE):
67703         * lib/mbfile.h (MBFILE_INLINE):
67704         * lib/mbiter.h (MBITER_INLINE):
67705         * lib/mbuiter.h (MBUITER_INLINE):
67706         * lib/xsize.h (XSIZE_INLINE):
67707         New macros.
67708         Replace all uses of 'static inline' with them.
67709         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67710         * m4/eealloc.m4 (gl_EEALLOC):
67711         * m4/mbfile.m4 (gl_MBFILE):
67712         * m4/mbiter.m4 (gl_MBITER):
67713         * m4/xsize.m4 (gl_XSIZE):
67714         Do not require AC_C_INLINE.
67715         * modules/binary-io (Files, lib_SOURCES): Add lib/binary-io.c
67716         * modules/eealloc (Files, lib_SOURCES): Add lib/eealloc.c.
67717         * modules/mbfile (Files, lib_SOURCES): Add lib/mbfile.c.
67718         * modules/mbiter (Files, lib_SOURCES): Add lib/mbiter.c.
67719         * modules/mbuiter (Files, lib_SOURCES): Add lib/mbuiter.c.
67720         * modules/xsize (Files, lib_SOURCES): Add lib/xsize.c.
67721         * modules/binary-io, modules/eealloc, modules/mbfile:
67722         * modules/mbiter, modules/mbuiter:
67723         (Depends-on): Add extern-inline.
67725         pipe-filter-gi, pipe-filter-ii: better use of 'inline'
67726         * lib/pipe-filter-aux.c: New file.
67727         * lib/pipe-filter-aux.h (PIPE_FILTER_AUX_INLINE): New macro.
67728         Replace all uses of 'static inline' with it.
67729         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67730         * lib/pipe-filter-gi.c (filter_init, filter_cleanup)
67731         (filter_retcode): No real need for inline here.
67732         * modules/pipe-filter-gi, modules/pipe-filter-ii:
67733         (Files): Add lib/pipe-filter-aux.c.
67734         (Depends-on): Add extern-inline.
67735         (configure.ac): Do not require AC_C_INLINE.
67736         (lib_SOURCES): Add pipe-filter-aux.c.
67738         fdutimensat: omit unnecessary AC_C_INLINE
67739         * modules/fdutimensat (configure.ac): Remove AC_C_INLINE.
67741         fchmodat, fchownat, fstatat: use extern-inline
67742         * lib/fchmodat.c, lib/openat.h (FCHMODAT_INLINE):
67743         * lib/fchownat.c, lib/openat.h (FCHOWNAT_INLINE):
67744         * lib/fstatat.c, lib/openat.h (FSTATAT_INLINE):
67745         New macros.
67746         * lib/openat.h:
67747         Replace all uses of 'static inline' with them.
67748         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67749         * modules/fchmodat, modules/fchownat, modules/fstatat:
67750         * modules/openat-h:
67751         (Depends-on):
67752         Add extern-inline.
67753         (configure.ac): Remove AC_C_INLINE.
67755         acl, mbchar, priv-set: use extern-inline
67756         * lib/set-mode-acl.c, lib/acl-internal.h (ACL_INTERNAL_INLINE):
67757         * lib/mbchar.c, lib/mbchar.h (MBCHAR_INLINE):
67758         * lib/priv-set.c, lib/priv-set.h (PRIV_SET_INLINE):
67759         New macros.
67760         * lib/acl-internal.h, lib/mbchar.h, lib/priv-set.h:
67761         Replace all uses of 'static inline' with it.
67762         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
67763         * m4/acl.m4 (gl_FUNC_ACL):
67764         * m4/mbchar.m4 (gl_MBCHAR):
67765         * m4/priv-set.m4 (gl_PRIV_SET):
67766         Remove AC_C_INLINE, since 'inline' is no longer used directly.
67767         * modules/acl, modules/mbchar, modules/priv-set (Depends-on):
67768         Add extern-inline.
67770         sockets, sys_stat: remove AC_C_INLINE in MSVC-only cases
67771         * m4/sockets.m4 (gl_SOCKETS):
67772         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H):
67773         Remove AC_C_INLINE.  Here, 'inline' is used only in MSVC
67774         environments where it's already guaranteed to work, so we needn't
67775         check for it at 'configure'-time.
67777         tls-tests: omit unnecessary 'inline'
67778         * tests/test-tls.c (perhaps_yield): No longer inline.
67779         Simplicity and portability trump efficiency in test cases.
67781         utimens-tests: avoid unnecessary 'inline'
67782         * modules/fdutimensat-tests (configure.ac):
67783         * modules/futimens-tests (configure.ac):
67784         * modules/utimens-tests (configure.ac):
67785         * modules/utimensat-tests (configure.ac):
67786         Remove AC_C_INLINE.
67787         * tests/test-utimens-common.h (ctime_compare):
67788         No longer inline.  Simplicity and portability trump efficiency here.
67790         misc: don't limit commentary to inline functions
67791         * lib/binary-io.h, lib/malloca.h, lib/safe-alloc.c:
67792         * lib/xalloc-oversized.h, lib/xsize.h:
67793         Contrast macros to functions in general, not just to inline functions,
67794         when the commentary does not apply only to inline functions.
67796 2012-09-20  Jim Meyering  <meyering@redhat.com>
67798         non-recursive-gnulib-prefix-hack: new module
67799         * build-aux/prefix-gnulib-mk: Copied from coreutils, derived from
67800         the file that originated in Bison.
67801         * m4/non-recursive-gnulib-prefix-hack.m4: Likewise, this code is
67802         largely copied from a snippet that resided in bison's configure.ac.
67803         * modules/non-recursive-gnulib-prefix-hack: New file.
67804         * MODULES.html.sh (Support for maintaining and releasing projects):
67805         Add it.
67807 2012-09-18  Jim Meyering  <meyering@redhat.com>
67809         maint.mk: generalize _gl_tight_scope for non-recursive make
67810         * top/maint.mk (_gl_tight_scope): Remove a hard-coded assumption
67811         that *.h would describe additional .h files in the directory
67812         specified by $(_gl_TS_dir).  I.e., add this...
67813         (_gl_TS_other_headers): New variable.
67815         maint.mk: exempt trailing blanks found in "binary" files
67816         * top/maint.mk (sc_trailing_blank): Filter out any matches found in
67817         "binary" files, as reported by grep.  Suggested by Richard W.M. Jones
67818         in http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
67820 2012-09-17  Jim Meyering  <meyering@redhat.com>
67822         maint.mk: sc_prohibit_path_max_allocation: don't FP for UNIX_PATH_MAX
67823         * top/maint.mk (sc_prohibit_path_max_allocation): Avoid false-positive
67824         match for symbols like UNIX_PATH_MAX. Reported by Richard W.M. Jones
67825         in http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
67827 2012-09-17  Jim Meyering  <meyering@redhat.com>
67829         maint.mk: teach sc_prohibit_magic_number_exit to accept 77
67830         * top/maint.mk (sc_prohibit_magic_number_exit): Do not complain about
67831         uses like "exit (77)".  "77" is automake's "skip this test" exit code.
67832         It is not in the same category as "exit (0)" or "exit (1)", and
67833         besides, I know of no symbolic name for that 77.  Reported by
67834         Richard W.M. Jones in
67835         http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
67837 2012-09-17  Jim Meyering  <meyering@redhat.com>
67839         maint.mk: relax sc_prohibit_strcmp, to avoid a false positive
67840         * top/maint.mk (sc_prohibit_strcmp): Relax regexp, so as to match
67841         all uses of #define, not just those that start in column 1.
67842         Richard W.M. Jones reported a false positive in
67843         http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
67845 2012-09-16  Paul Eggert  <eggert@cs.ucla.edu>
67847         localcharset: work around Mac OS X bug with UTF-8 and MB_CUR_MAX
67848         * lib/localcharset.c (locale_charset) [DARWIN7]:
67849         Return "ASCII" if the system reports "UTF-8" and MB_CUR_MAX <= 1,
67850         as these two values are incompatible.  Problem reported by Max Horn.
67851         For more discussion, please see
67852         <http://lists.gnu.org/r/bug-gnulib/2012-09/msg00061.html>.
67854         doc: document sticky-EOF issue
67855         * doc/posix-functions/fgetc.texi (fgetc):
67856         * doc/posix-functions/fgets.texi (fgets):
67857         * doc/posix-functions/fread.texi (fread):
67858         * doc/posix-functions/fscanf.texi (fscanf):
67859         * doc/posix-functions/getc.texi (getc):
67860         * doc/posix-functions/getchar.texi (getchar):
67861         * doc/posix-functions/scanf.texi (scanf):
67862         Mention that glibc and default Solaris do not conform to
67863         C99 and POSIX-2001 or later, with respect to how getchar
67864         etc. behave when feof reports nonzero.
67866 2012-09-13  Joachim Schmitz  <jojo@schmitz-digital.de>  (tiny change)
67868         poll: fix poll(0, NULL, msec)
67869         * lib/poll.c: don't exit early if NULL is the 1st arg to poll(),
67870         but nfd is 0.  In that case poll should behave like select.
67872 2012-09-13  Joachim Schmitz  <jojo@schmitz-digital.de>  (tiny change)
67873             Paolo Bonzini  <bonzini@gnu.org>
67875         poll: fix for systems that can't recv() on a non-socket
67876         * lib/poll.c: if recv returns ENOTSOCK, assume the descriptor
67877         is readable.  In this case POLLHUP will not be supported.
67878         * doc/posix-functions/poll.texi: Document this.
67880 2012-09-13  Paolo Bonzini  <bonzini@gnu.org>
67882         poll/select: document portability problems not fixed by Gnulib.
67883         * doc/posix-functions/poll.texi: poll does not work well on
67884         pipes under Windows.  It has the same limitations as select on
67885         BeOS.
67886         * doc/posix-functions/select.texi: select does not work well
67887         on pipes under Windows.
67889 2012-09-10  Paul Eggert  <eggert@cs.ucla.edu>
67891         fcntl-h: check for AIX 7.1 bug with O_NOFOLLOW and O_CREAT
67892         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Check for AIX 7.1 bug
67893         that caused a GNU tar test failure.  Problem reported by Jez Wain; see
67894         <http://lists.gnu.org/r/bug-tar/2012-07/msg00018.html>.
67896 2012-09-06  Eric Blake  <eblake@redhat.com>
67898         net_if: give more details about the bug being fixed
67899         * doc/posix-headers/net_if.texi: Add clarification.
67901 2012-09-05  Eric Blake  <eblake@redhat.com>
67903         net_if: new module
67904         * modules/net_if: New module, borrowing ideas from netinet_in.
67905         * m4/net_if_h.m4: New file.
67906         * lib/net_if.in.h: Likewise.
67907         * doc/posix-headers/net_if.texi (net/if.h): Document it.
67908         * MODULES.html.sh (lacking POSIX:2008): Likewise.
67909         * tests/test-net_if.c: Make function checks conditional.
67910         Reported by Jasper Lievisse Adriaanse <jasper@humppa.nl>.
67912 2012-09-05  Mats Erik Andersson  <gnu@gisladisker.se>  (tiny change)
67914         readutmp: fix non-portable UT_PID use
67915         * lib/readutmp.c (desirable_utmp_entry) <READ_UTMP_CHECK_PIDS>:
67916         Use `UT_PID (u) > 0' as absolute condition.
67918 2012-09-04  Jim Meyering  <meyering@redhat.com>
67920         fts: reduce two or more trailing spaces to just one, usually
67921         * lib/fts.c (fts_open): Upon initialization, if a name ends in two
67922         or more slashes, trim all but the final one.  But if a name consists
67923         solely of two slashes, don't modify it.  If it consists solely of
67924         three or more slashes, strip all but one.
67926         This is part of the solution to a minor problem with rm:
67927         it would print a bogus ELOOP diagnostic when failing to remove
67928         the slash-decorated name of a symlink-to-directory:
67930             $ mkdir d && ln -s d s && env rm -r s/
67931             rm: cannot remove 's': Too many levels of symbolic links
67933         With the change below and a trivial don't-trim-trailing-slashes
67934         adjustment to remove.c, it does this:
67936             $ env rm -r s/
67937             rm: cannot remove 's/': Not a directory
67939         Improved by: Eric Blake
67941         fts: when there is no risk of overlap, use memcpy, not memmove
67942         * lib/fts.c (fts_alloc): Fix unjustified memcopy: s/memmove/memcpy/
67944 2012-08-29  Paul Eggert  <eggert@cs.ucla.edu>
67946         stdbool: be more compatible with mixed C/C++ compiles
67947         * lib/stdbool.in.h (_Bool, true, false) [__cplusplus]:
67948         Define to bool, true, false, respectively, as GCC's builtin
67949         stdbool.h does.  Problem reported by Michael Goffioul in
67950         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00143.html>.
67952 2012-08-28  Jim Meyering  <meyering@redhat.com>
67954         revert last change: it was not needed
67955         * tests/test-vc-list-files-git.sh: There's already a test for
67956         a working git, just below.
67958 2012-08-28  Jim Meyering  <meyering@redhat.com>
67960         tests: test-vc-list-files-git.sh: skip if git is not available
67961         * tests/test-vc-list-files-git.sh: Skip this test when git is
67962         not available.
67964 2012-08-26  Bruno Haible  <bruno@clisp.org>
67966         gnulib-tool: Remove no-op option --no-changelog.
67967         * gnulib-tool (func_usage): Don't mention --no-changelog.
67968         (do_changelog): Remove variable.
67969         Reported by Dmitriy Selyutin <ghostman.sd@gmail.com>.
67971 2012-08-24  Paul Eggert  <eggert@cs.ucla.edu>
67973         doc: remove fdl-1.2.texi
67974         It is no longer used or maintained, and its use of @acronym
67975         is problematic.  See the thread containing
67976         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00134.html>.
67977         * config/srclist.txt: Remove doc/old-licenses/fdl-1.2.texi.
67978         * doc/old-licenses/fdl-1.2.texi: Remove.
67980         execinfo: port to FreeBSD
67981         * m4/execinfo.m4 (gl_EXECINFO_H): Set LIB_EXECINFO to -lexecinfo
67982         if needed, as in FreeBSD.  Reported by Bastien Roucariès in
67983         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00113.html>.
67984         * modules/execinfo (Link): Add $(LIB_EXECINFO).
67986 2012-08-23  Jim Meyering  <meyering@redhat.com>
67988         xstrtol.h: avoid "_Noreturn is not at beginning of declaration" warning
67989         * lib/xstrtol.h: Put "_Noreturn" before "void" in declaration,
67990         to placate gcc's -Wold-style-declaration.
67992 2012-08-24  Paul Eggert  <eggert@cs.ucla.edu>
67994         doc: do not use @acronym
67995         * doc/inet_ntoa.texi (inet_ntoa):
67996         * doc/parse-datetime.texi (Seconds since the Epoch)
67997         (Specifying time zone rules):
67998         * doc/posix-functions/inet_ntoa.texi (inet_ntoa):
67999         Don't use @acronym.  Problem reported by John Darlington in
68000         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00124.html>.
68002 2012-08-23  Paul Eggert  <eggert@cs.ucla.edu>
68004         stdnoreturn: port to newer GCCs
68005         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): Avoid problems with
68006         bleeding-edge GCC that complains about 'int _Noreturn foo (void);'.
68007         Problem reported by Jim Meyering in
68008         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00121.html>.
68009         Also, rename the 'test' function to a void a clash with the
68010         already-supplied 'main' function; this fixes a bug that incorrectly
68011         rejected GCC 4.7.1's <stdnoreturn.h>.
68012         * doc/posix-headers/stdnoreturn.texi (stdnoreturn.h):
68013         Document GCC problem.
68015 2012-08-22  Reuben Thomas  <rrt@sc3d.org>
68017         pipe-filter: fix comment typo
68018         * lib/pipe-filter.h: Mention correct function.
68020 2012-08-22  Paul Eggert  <eggert@cs.ucla.edu>
68022         execinfo: new module
68023         This is for Emacs.  Currently, it provides a no-effect stub
68024         on all platforms where it does not already work.
68025         It already works on glibc-based systems, and on Solaris 11.
68026         * lib/execinfo.c, lib/execinfo.in.h, m4/execinfo.m4, modules/execinfo:
68027         New files.
68028         * doc/glibc-headers/execinfo.texi (execinfo.h):
68029         * MODULES.html.sh (Misc): Document it.
68031 2012-08-20  Paul Eggert  <eggert@cs.ucla.edu>
68033         extern-inline: support old GCC 'inline'
68034         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Use pre-C99 GCC 'inline'
68035         if available.  This applies to GCC versions 2.7 through 4.2, or
68036         when newer GCC is using -fgnu89-inline.  The goal is to address
68037         some of the performance issues mentioned by Bruno Haible in
68038         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00097.html>.
68040 2012-08-20  Eric Blake  <eblake@redhat.com>
68042         maint.mk: avoid redundant file name in message
68043         * top/maint.mk (sc_prohibit_strcmp, sc_unmarked_diagnostics)
68044         (sc_prohibit_defined_have_decl_tests, sc_const_long_option)
68045         (sc_makefile_path_separator_check): Remove bogus $(ME).
68047 2012-08-20  Mike Frysinger  <vapier@gentoo.org>
68049         timer-time: fix link order when static linking on glibc
68050         * m4/timer_time.m4 (LIB_TIMER_TIME): Add -lpthread
68051         _after_ -lrt so that it's significant.
68053 2012-08-19  Paul Eggert  <eggert@cs.ucla.edu>
68055         timespec: omit unnecessary AC_C_INLINE
68056         * m4/timespec.m4 (gl_TIMESPEC): Do not require AC_C_INLINE.
68058         stat-time: omit unnecessary AC_C_INLINE
68059         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
68060         Do not require AC_C_INLINE.
68062         ignore-value: omit unnecessary AC_C_INLINE
68063         * modules/ignore-value (configure.ac): Do not require AC_C_INLINE.
68065         sys_select: avoid 'static inline'
68066         * lib/sys_select.in.h (rpl_fd_isset): Now static, not static inline.
68068         mktime: avoid 'static inline'
68069         * lib/mktime.c (leapyear, ydhms_diff): Now static, not static inline.
68070         * m4/mktime.m4 (gl_PREREQ_MKTIME): Do not require AC_C_INLINE.
68072 2012-08-19  Bruno Haible  <bruno@clisp.org>
68074         gnulib-tool: Improve coding style.
68075         * gnulib-tool (func_emit_tests_Makefile_am): Set perhapsLT, like in
68076         func_emit_lib_Makefile_am.
68077         Reported and fix suggested by Dmitriy Selyutin <ghostman.sd@gmail.com>.
68079 2012-08-19  Bruno Haible  <bruno@clisp.org>
68081         gnulib-tool: Fix indentation.
68082         * gnulib-tool (func_import): Fix indentation.
68084 2012-08-19  Bruno Haible  <bruno@clisp.org>
68086         gnulib-tool: Remove old file names from .cvsignore, .gitignore.
68087         * gnulib-tool (func_update_ignorelist): Don't use 'join -v 1' command
68088         on the list of removed files.
68090 2012-08-17  Paul Eggert  <eggert@cs.ucla.edu>
68092         test-parse-datetime: avoid glibc leap-second glitch
68093         * tests/test-parse-datetime.c (main): Set TZ to US Eastern time
68094         with the 2012 rules.  Problem reported by Bruce Dubbs in
68095         <http://bugs.gnu.org/12206>.
68097 2012-08-14  Bruno Haible  <bruno@clisp.org>
68099         gnulib-tool: Fix indentation of generated gnulib-comp.m4 file.
68100         * gnulib-tool (func_emit_autoconf_snippet): Initialize indentation
68101         from argument.
68102         Reported and fix suggested by Dmitriy Selyutin <ghostman.sd@gmail.com>.
68104 2012-08-14  Eric Blake  <eblake@redhat.com>
68106         ldexp: relax license
68107         * modules/ldexp (License): Trivial relax, since the module only
68108         provides a permissively licensed m4 file.
68110 2012-08-13  Bruno Haible  <bruno@clisp.org>
68112         gnulib-tool: Fix persistence of --witness-c-macro option.
68113         * gnulib-tool (func_import): Fix typo in emit of gl_WITNESS_C_MACRO.
68114         Reported by Dmitriy Selyutin <ghostman.sd@gmail.com>.
68116 2012-08-11  Eric Blake  <eblake@redhat.com>
68118         count-leading-zeros: use a lookup table on non-gcc compilers
68119         * lib/count-leading-zeros.h (count_leading_zeros_32): Use an
68120         alternate implementation, suggested by Jim Meyering.
68122 2012-08-10  Eric Blake  <eblake@redhat.com>
68124         count-leading-zeros: new module
68125         * modules/count-leading-zeros: New module.
68126         * m4/count-leading-zeros.m4: New file.
68127         * lib/count-leading-zeros.h: Likewise.
68128         * modules/count-leading-zeros-tests: New test.
68129         * tests/test-count-leading-zeros.c: New file.
68130         * MODULES.html.sh (Integer arithmetic functions): Document it.
68132 2012-08-07  Simon Josefsson  <simon@josefsson.org>
68133             Jim Meyering  <meyering@redhat.com>
68135         maintainer-makefile: Fix syntax error with dash.
68136         * top/maint.mk (sc_vulnerable_makefile_CVE-2009-4029): Quote arguments.
68137         (sc_vulnerable_makefile_CVE-2012-3386): Likewise.
68139 2012-08-05  Jim Meyering  <meyering@redhat.com>
68141         extern-inline: also ignore -Wmissing-declarations
68142         * m4/extern-inline.m4: Also ignore -Wmissing-declarations,
68143         required with gcc-4.8.0-to-be.
68145         maint.mk: sc_prohibit_magic_number_exit: avoid new false positives
68146         * top/maint.mk (sc_prohibit_magic_number_exit): Also filter out matches
68147         for /error ?([^,]*)/.  This avoids false-positives for strings like
68148         "Unknown error (252)", introduced via commit v0.0-7538-g92875a6.
68150 2012-08-02  Stefano Lattarini  <stefano.lattarini@gmail.com>
68152         gnumakefile: better interaction with Automake-NG
68153         * modules/gnumakefile [Makefile.am]: The makefiles generated by
68154         Automake-NG always contain a definition of VPATH, even in non-VPATH
68155         builds (its value being simply '.' in that case).  So, in the
68156         'clean-GNUmakefile' rule, to determine whether running under a
68157         VPATH setup, compare '$(srcdir)' to '.' rather than checking whether
68158         '$(VPATH)' expands to the empty string.
68160 2012-08-02  Carlo de Falco  <carlo.defalco@polimi.it>  (tiny change)
68162         base64: Use extern C scope in header file, for C++.
68163         * lib/base64.h: Add C++ namespace protection.
68165 2012-08-02  Paul Eggert  <eggert@cs.ucla.edu>
68167         stat-time, timespec, u64: support naive out-of-dir builds
68168         * lib/stat-time.c, lib/timespec.c, lib/u64.c:
68169         Use '#include "foo.h"', not '#include <foo.h>', when including
68170         one's own interface.  This works better when configuring with
68171         out-of-directory builds, since packages need not add an
68172         otherwise-unnecessary -I$(topdir_src)/lib to DEFAULT_INCLUDES.
68174 2012-08-01  Paul Eggert  <eggert@cs.ucla.edu>
68176         utimens: use extern-inline
68177         * lib/utimens.c (_GL_UTIMENS_INLINE): Define when including utimens.h.
68178         * lib/utimens.h: Add copyright notice, since this is now large enough
68179         to copyright.  Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
68180         (_GL_UTIMENS_INLINE): New macro.  Use it instead of 'static inline'.
68181         * modules/utimens (Depends-on): Add extern-inline.
68183         u64: use extern-inline
68184         * lib/u64.c: New file.
68185         * lib/u64.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
68186         (_GL_U64_INLINE): New macro.  Use it instead of 'static inline'.
68187         * modules/u64 (Files): Add lib/u64.c.
68188         (Depends-on): Add extern-inline.
68189         (configure.ac): No need to require AC_C_INLINE, since extern-inline
68190         does that now.
68191         (lib_SOURCES): Add u64.c.
68193         timespec: use extern-inline
68194         * lib/timespec.c: New file.
68195         * lib/timespec.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
68196         (_GL_TIMESPEC_INLINE): New macro.  Use it instead of 'static inline'.
68197         * modules/timespec (Files): Add lib/timespec.c.
68198         (Depends-on): Add extern-inline.
68199         (lib_SOURCES): Add timespec.c.
68201         stat-time: use extern-inline
68202         * lib/stat-time.c: New file.
68203         * lib/stat-time.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
68204         (_GL_STAT_TIME_INLINE): New macro.  Use it instead of 'static inline'.
68205         * modules/stat-time (Files): Add lib/stat-time.c.
68206         (Depends-on): Add extern-inline.
68207         (lib_SOURCES): Add stat-time.c.
68209         extern-inline: new module
68210         * modules/extern-inline, m4/extern-inline.m4: New files.
68211         This is for better support of 'extern inline' a la ISO C99,
68212         with a portable alternative on compilers that do not support
68213         C99-style 'extern inline'.  Using 'extern inline' shrinks the size
68214         of the Emacs executable, when compiled with debugging disabled,
68215         which is a typical way that Emacs is built while developing.
68217 2012-08-01  Akim Demaille  <akim@lrde.epita.fr>
68219         maint.mk: a "release-commit" wrapper to do-release-commit-and-tag
68220         * build-aux/do-release-commit-and-tag: Move variable definitions
68221         together.
68222         ($branch): Instead of defaulting to "master", default to the current
68223         branch (as gnu-web-doc-update does).
68224         (help): Display the current values of the option arguments.
68225         * top/maint.mk (release-commit): New.
68226         * top/README-release: Simplify the corresponding step.
68228 2012-07-30  Eric Blake  <eblake@redhat.com>
68230         passfd: fix comment on recvfd
68231         * lib/passfd.c (recvfd): Fix comment.
68232         Reported by Jann Horn <jannhorn@googlemail.com>.
68234 2012-07-30  Jim Meyering  <meyering@redhat.com>
68236         maint.mk: avoid a sub-shell
68237         * top/maint.mk (release-prep): Remove unneeded sub-shell.
68239 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
68241         maint.mk: use silent-rules support from Automake
68242         * top/maint.mk (news-check, vc-diff-check, announcement)
68243         (no-submodule-changes, alpha beta stable, release-prep)
68244         (web-manual, update-copyright): Use $(AM_V_GEN) and $(AM_V_at).
68246 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
68248         maint.mk: provide a web-manual-update target
68249         * top/maint.mk: here.
68250         * top/README-release: Use it to simplify the web manual update step.
68252 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
68254         README-release: shorten the circuit to post a news
68255         * top/README-release: Point directly to the news submission form.
68257 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
68259         gnu-web-doc-update: fix --help
68260         * build-aux/gnu-web-doc-update: The information "top level" was written
68261         twice.
68263 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
68265         maint.mk: absolute VPATH issue
68266         * top/maint.mk (release-prep): Help Git find .git/.
68267         From Jim Meyering.
68269 2012-07-29  Akim Demaille  <akim@lrde.epita.fr>
68271         gitlog-to-changelog: fix previous change
68272         * build-aux/gitlog-to-changelog: Fix condition.
68273         Add missing ";".
68275 2012-07-29  Akim Demaille  <akim@lrde.epita.fr>
68277         gitlog-to-changelog: don't expect .git to be in $srcdir
68278         Reported by Bruno Haible.
68279         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00265.html>
68280         * build-aux/gitlog-to-changelog (&git_dir_option): New.
68281         Use it.
68283 2012-07-29  Akim Demaille  <akim@lrde.epita.fr>
68285         maint.mk: absolute VPATH build fix
68286         * top/maint.mk (gpg_key_ID): Help git find .git when, for instance,
68287         $(srcdir) is not a parent of $(builddir).
68289 2012-07-28  John Darrington  <john@darrington.wattle.id.au>
68291         clean-temp: Fix memory leak.
68292         * lib/clean-temp.c (cleanup_temp_dir): Free also the 'subdirs' and
68293         'files' members of tmpdir.
68295 2012-07-27  Jim Meyering  <meyering@redhat.com>
68297         maint.mk: new rule: refresh-gnulib-patches
68298         I noticed that 8 of coreutils' 9 gl/**/*.diff files were stale.
68299         Use this rule to refresh them.
68300         * top/maint.mk (refresh-gnulib-patches): New rule.
68302 2012-07-24  Bruno Haible  <bruno@clisp.org>
68304         gnulib-tool: Fix handling of inctests variable.
68305         * gnulib-tool: Canonicalize $inctests also in 'update' mode.
68306         Reported by Nick Bowler <nbowler@elliptictech.com>.
68308 2012-07-22  Bruno Haible  <bruno@clisp.org>
68310         getpass: Assume AC_CHECK_DECLS_ONCE invocation, like in getpass.m4.
68311         * lib/getpass.h: Assume HAVE_DECL_GETPASS is defined.
68312         * cfg.mk (exclude_file_name_regexp--sc_prohibit_defined_have_decl_tests):
68313         Remove exemption for getpass.h.
68314         Suggested by Eric Blake.
68316 2012-07-20  Eric Blake  <eblake@redhat.com>
68318         verify: document conflict with -Wnested-externs
68319         * lib/verify.h: Give hint about usage when gcc warnings are enabled.
68321         maint.mk: forbid exit(-1)
68322         * top/maint.mk (sc_prohibit_magic_number_exit): Detect negatives.
68324 2012-07-20  Paul Eggert  <eggert@cs.ucla.edu>
68326         fsusage: port back to Solaris
68327         * lib/fsusage.c (get_fs_usage): Fix busted logic causing compile-time
68328         error (fsd not declared) on Solaris 10.  Reported privately by
68329         Andrew Borodin.
68331 2012-07-19  Akim Demaille  <akim@lrde.epita.fr>
68333         gnu-web-doc-update: fix error messages
68334         * build-aux/gnu-web-doc-update: Don't pass $ME to die.
68336         gnu-web-doc-update: check the requirements.
68337         * build-aux/gnu-web-doc-update (find_tool): Import from bootstrap.
68338         ($CVS, $CVSU, $GIT, $RSYNC, $XARGS): New.
68339         * build-aux/bootstrap (find_tool): Comment change.
68341 2012-07-17  Akim Demaille  <akim@lrde.epita.fr>
68343         maint.mk: minor simplication.
68344         * top/maint.mk (_sc_excl): Use $(or...) instead of $(if...)
68345         for default values.
68347 2012-07-15  Akim Demaille  <akim@lrde.epita.fr>
68349         gitlog-to-changelog: VPATH build issues
68350         If builddir is not a subdirectory of srcdir, running git from it will
68351         fail.
68352         * build-aux/gitlog-to-changelog (--srcdir): New option.
68354 2012-07-15  Bruno Haible  <bruno@clisp.org>
68356         fpending: Assume AC_CHECK_DECLS_ONCE invocation, like in fpending.m4.
68357         * lib/fpending.h: Assume HAVE_DECL___FPENDING is defined.
68358         * cfg.mk (exclude_file_name_regexp--sc_prohibit_defined_have_decl_tests)
68359         Remove exemption for fpending.h.
68360         Suggested by Eric Blake.
68362 2012-07-15  Paul Eggert  <eggert@cs.ucla.edu>
68364         pthread_sigmask: fix bug on FreeBSD 9
68365         * lib/pthread_sigmask.c [PTHREAD_SIGMASK_INEFFECTIVE]:
68366         Include string.h.
68367         (pthread_sigmask) [PTHREAD_SIGMASK_INEFFECTIVE]:
68368         When calling pthread_sigmask (1729, NEW, OLD), specify non-null NEW;
68369         this avoids a bug on FreeBSD 9, where pthread_sigmask is effective
68370         but pthread_sigmask (1729, NULL, NULL) returns zero.
68371         See <http://bugs.gnu.org/11884>.
68372         Avoid the need to call pthread_sigmask (1729, ...) in most cases,
68373         by inspecting whether the main call changed the old mask.
68375 2012-07-15  Reuben Thomas  <rrt@sc3d.org>
68377         README-release: make it more legible
68378         * top/README-release: Improve typography slightly.
68380 2012-07-15  Jim Meyering  <meyering@redhat.com>
68382         maint: require that each sc_... command start with "@"
68383         * Makefile (sc_prohibit_sc_omitted_at): New rule so that
68384         "make sc_maint" helps us avoid this nit.
68386 2012-07-15  Jim Meyering  <meyering@redhat.com>
68388         maint.mk: add leading "@" to quiet new "make syntax-check" rule
68389         * top/maint.mk (sc_prohibit_defined_have_decl_tests): Add "@".
68391 2012-07-13  Eric Blake  <eblake@redhat.com>
68393         maint.mk: new syntax check for HAVE_DECL checks
68394         * top/maint.mk (sc_prohibit_defined_have_decl_tests): New rule.
68395         * cfg.mk
68396         (exclude_file_name_regexp--sc_prohibit_defined_have_decl_tests):
68397         Exempt some false positives.
68398         Based on a report by Karel Zak.
68400         argp: make HAVE_DECL usage consistent
68401         * lib/argp-parse.c (__argp_parse): Check contents of HAVE_DECL
68402         macros, not whether they are defined.
68403         * m4/argp.m4 (gl_ARGP): Always define HAVE_DECL_* macros, per
68404         convention with other declaration checks.
68405         Reported by Karel Zak, with suggestions from Paul Eggert.
68407         stat-time: relax license to LGPLv2+
68408         * modules/stat-time (License): Relax, with consent of all authors.
68410         strndup: fix m4 usage error
68411         * m4/strndup.m4 (gl_FUNC_STRNDUP): HAVE_DECL_STRNDUP is always
68412         defined, to either 0 or 1.
68413         Reported by Karel Zak.
68415 2012-07-11  Jim Meyering  <meyering@redhat.com>
68417         maint: enable the sc_avoid_if_before_free syntax-check rule
68418         * cfg.mk (local-checks-to-skip): Enable sc_avoid_if_before_free.
68419         (if_before_free_offenders_): Define.
68420         (if_before_free_basename_re_): Define.
68421         Exempt current files with useless if-before-free.
68423 2012-07-11  Paul Eggert  <eggert@cs.ucla.edu>
68425         gettext: do not assume '#define ... defined ...' behavior
68426         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS):
68427         Do not use '#define FOO ... defined BAR ...', as the C standard says
68428         it's not portable to expect that this works after macro expansion.
68429         Problem reported for gzip by Steven M. Schweda in
68430         <http://lists.gnu.org/r/bug-gzip/2012-07/msg00000.html>.
68432 2012-07-10  Paul Eggert  <eggert@cs.ucla.edu>
68434         getloadavg: clean out old Emacs and Autoconf cruft
68435         See Glenn Morris in <http://bugs.gnu.org/11905>.
68436         * lib/getloadavg.c: Include <config.h>, <stdbool.h> always.
68437         Include <sys/param.h> if HAVE_SYS_PARAM_H, not if unix or __unix.
68438         (LDAV_CVT): Remove no-longer-used LOAD_AVE_CVT hook.
68439         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Check for <sys/param.h>.
68441 2012-07-10  Akim Demaille  <akim@lrde.epita.fr>
68443         bootstrap: let warn be like tests/init.sh's warn_
68444         Reported by Jim Meyering.
68445         * build-aux/bootstrap (warn): Remove, replaced by...
68446         (warnf_, warn_): these.
68447         Adjust callers.
68448         Shorten messages that no longer fit in 80 columns.
68450 2012-07-09  Bruno Haible  <bruno@clisp.org>
68452         getopt: Simplify after Emacs changed.
68453         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX): Inline gl_GETOPT_IFELSE.
68454         (gl_GETOPT_IFELSE): Remove macro.
68456 2012-07-09  Jim Meyering  <meyering@redhat.com>
68458         maint.mk: add sc_vulnerable_makefile_CVE-2012-3386
68459         * top/maint.mk (sc_vulnerable_makefile_CVE-2012-3386): New rule.
68461         maint.mk: _sc_search_regexp, sc_vulnerable_makefile_CVE-2009-4029: fix
68462         Bugs in both of those conspired to make the
68463         sc_vulnerable_makefile_CVE-2009-4029 rule 99% useless.
68464         _sc_search_regexp's handling of non-empty $in_files would filter
68465         out any offending file names.  sc_vulnerable_makefile_CVE-2009-4029's
68466         choice of in_files value meant there would be no match in most
68467         projects, due to the presence of two or more Makefile.in files.
68468         * top/maint.mk (_sc_search_regexp) [in_vc_files,in_files]: Clarify.
68469         Fix a bug in how a non-empty $$in_files was processed:
68470         (sc_vulnerable_makefile_CVE-2009-4029): Fix erroneous use of in_files:
68471         in spite of the name, it's a regexp, not a list of file names.
68473 2012-07-09  Paul Eggert  <eggert@cs.ucla.edu>
68475         getloadavg, getopt: fix commentary re configure.in
68476         Autoconf is deprecating the name 'configure.in', so change it to
68477         to the new name 'configure.ac' in a couple of places.
68478         * lib/getloadavg.c: configure.in -> configure.ac, in comment.
68479         * m4/getopt.m4 (gl_GETOPT_IFELSE, gl_GETOPT_SUBSTITUTE_HEADER)
68480         (gl_PREREQ_GETOPT): Remove obsolete commentary re Emacs configure.in.
68481         Emacs has renamed it to configure.ac, and it no longer refers
68482         to these macros anyway.
68484         timespec: mark functions with const attributes
68485         * lib/timespec.h (timespec_add, timespec_sub, dtotimespec):
68486         Mark with _GL_ATTRIBUTE_CONST.
68488 2012-07-07  Ludovic Courtès  <ludo@gnu.org>
68490         canonicalize[-lgpl]: handle "guessing" values when cross-building
68491         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
68492         (gl_CANONICALIZE_LGPL): Check whether $gl_cv_func_realpath_works
68493         matches "*yes" instead of just "yes".  Regression introduced in commit
68494         e0bcf6626cde8dad4bfbdc4045c744f0cd8b9e24.
68496 2012-07-07  Ludovic Courtès  <ludo@gnu.org>
68497             Bruno Haible  <bruno@clisp.org>
68499         canonicalize: make the right guess when cross-compiling to GNU
68500         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Match also "gnu*" to
68501         determine whether cross-compiling to glibc systems, so as to
68502         include GNU/Hurd.
68504 2012-07-06  Paul Eggert  <eggert@cs.ucla.edu>
68506         timespec-sub: avoid duplicate include
68507         * lib/timespec-sub.c: Do not include <config.h> twice.
68508         Reported by Juanma Barranquero.
68510 2012-07-06  Akim Demaille  <akim@lrde.epita.fr>
68512         bootstrap: use a more consistent error reporting scheme
68513         * build-aux/bootstrap (warn, die): New.
68514         Use them.
68516 2012-07-05  Paul Eggert  <eggert@cs.ucla.edu>
68518         sys_time: allow too-wide tv_sec
68519         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Allow struct
68520         timeval even if tv_sec is wider than time_t.  This allows
68521         OpenBSD 5.1 amd64 and fixes an Emacs porting glitch with utimens.c,
68522         as without this patch gnulib replaces struct timeval
68523         and OpenBSD futimes therefore has a type mismatch.
68524         * doc/posix-headers/sys_time.texi: Mention this.
68526         pthread: check for both pthread_create and pthread_join
68527         * m4/pthread.m4 (gl_PTHREAD_CHECK): Revert previous change, but
68528         alter the check so that it tests for both pthread_create and
68529         pthread_join.  This should be more portable to hosts like OSF/1 5.1.
68530         Suggested by Bruno Haible and Richard Yao in
68531         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00048.html>.
68533         parse-datetime: doc tuneup
68534         * doc/parse-datetime.texi: Index "leap seconds" and fix minor
68535         spacing issues.
68537 2012-07-05  Akim Demaille  <akim@lrde.epita.fr>
68539         do-release-commit-and-tag: fix the previous commit
68540         * build-aux/do-release-commit-and-tag: Actually the test was right,
68541         but the comment and the error message were misleading.
68542         Fix comment, and improve error message.
68543         Perform check first, so that NEWS is not modified uselessly.
68545         do-release-commit-and-tag: fix typo
68546         * build-aux/do-release-commit-and-tag: Be sure that NEWS does
68547         _not_ start with a stub.
68549 2012-07-04  Paul Eggert  <eggert@cs.ucla.edu>
68551         pthread: check for pthread_create, not pthread_join
68552         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for pthread_create, not
68553         pthread_join.  On FreeBSD 9, pthread_create is in libpthread but
68554         pthread_join in libc.  I hope this removes the need for all the
68555         OSF/1 5.1 pthread_join business.  Reported by Richard Yao in
68556         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00042.html>.
68558 2012-07-04  Jim Meyering  <meyering@redhat.com>
68560         parse-datetime: fix failure to diagnose invalid input
68561         date -d "$(printf '\xb0')" would print 00:00:00 with today's date
68562         rather than diagnosing the invalid input.  Now it reports this:
68563         date: invalid date '\260'
68564         * lib/parse-datetime.y (to_uchar): Define.
68565         (yylex): Don't sign-extend "other" bytes.
68566         * m4/parse-datetime.m4: Require AC_C_INLINE for first use of "inline".
68567         Thanks to Bruno Haible for the patch to this file.
68568         * tests/test-parse-datetime.c (main): Add a test to trigger the bug.
68569         Peter Evans reported the bug in GNU date: http://bugs.gnu.org/11843
68571 2012-07-03  Jim Meyering  <meyering@redhat.com>
68573         bootstrap: do not require now-removed build-aux/missing
68574         Now that build-aux/missing is, er, missing, bootstrap would
68575         silently fail.
68576         * build-aux/bootstrap (gnulib_extra_files): Remove $build_aux/missing
68577         from the list, now that (since commit v0.0-7489-gd0f486f) the file is
68578         no longer part of gnulib.
68579         Diagnose the failure.
68581 2012-07-03  Paul Eggert  <eggert@cs.ucla.edu>
68583         alloca: add support for HP NonStop TNS/E native
68584         * lib/alloca.in.h (alloca): Support the new host.
68585         From a suggestion by Joachim Schmitz in
68586         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00355.html>.
68588 2012-07-02  Pádraig Brady  <P@draigBrady.com>
68590         fsusage: remove code not needed on non GNU/Linux systems.
68592         * lib/fsusage.c [STAT_STATVFS || STAT_STATVFS64]:
68593         Don't include headers no longer needed in this case.
68594         * lib/fsusage.c [STAT_STATVFS &&
68595         ! (__linux__ && (__GLIBC__||__UCLIBC__))]: Undefine
68596         STAT_STATFS2_FRSIZE to exclude code not used in this case.
68598 2012-07-02  Paul Eggert  <eggert@cs.ucla.edu>
68600         fsusage: include files needed for glibc 2.6 fallback
68601         * lib/fsusage.c [STAT_STATVFS || STAT_STATVFS64]:
68602         Include <sys/param.h>, <sys/mount.h>, <sys/vfs.h>
68603         as they are needed for the 2.6 < glibc/Linux < 2.6.36 fallback.
68604         Problem reported by Ludovic Courtès in
68605         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00005.html>.
68607         fsusage: avoid needless check on GNU/Linux
68608         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Omit STAT_STATFS3_OSF1 check
68609         on GNU/Linux systems, since it can't possibly work.
68611 2012-07-01  Bruno Haible  <bruno@clisp.org>
68613         log: Fix an autoconf >= 2.64 warning.
68614         * modules/log (configure.ac): Require, not invoke, gl_FUNC_LOG.
68615         Reported by Carlos O'Donell <carlos_odonell@mentor.com>.
68617 2012-06-28  Bruno Haible  <bruno@clisp.org>
68619         log10f: Fix possible configuration problem.
68620         * m4/log10f.m4 (gl_FUNC_LOG10F): Augment LIBS by $LOG10F_LIBM, not
68621         $LOGF_LIBM.
68622         Reported by Carlos O'Donell <carlos_odonell@mentor.com>.
68624 2012-06-28  Bruno Haible  <bruno@clisp.org>
68626         remove: No longer override on all platforms. Fixes bug from 2010-03-20.
68627         * m4/remove.m4 (gl_FUNC_REMOVE): Test gl_cv_func_unlink_honors_slashes,
68628         not gl_cv_func_unlink_works.
68629         Reported by Carlos O'Donell <carlos_odonell@mentor.com>.
68631 2012-06-27  Eric Blake  <eblake@redhat.com>
68633         config: drop scripts that automake says are not independent
68634         * config/srclist.txt: Drop elisp-comp, missing, and ylwrap.
68635         * build-aux/elisp-comp: Delete.
68636         * build-aux/missing: Likewise.
68637         * build-aux/ylwrap: Likewise.
68638         * modules/elisp-comp: Likewise.
68639         * MODULES.html.sh: Drop mention of elisp-comp.
68640         * NEWS: Mention this.
68642 2012-06-26  Paul Eggert  <eggert@cs.ucla.edu>
68644         root-uid: new module
68645         This is for portability to Tandem's NonStop Kernel.
68646         * lib/root-uid.h, modules/root-uid: New files.
68647         * lib/euidaccess.c, lib/pt_chown.c, lib/unlinkdir.c:
68648         * lib/write-any-file.c, tests/test-sethostname2.c:
68649         Include "root-uid.h".
68650         * lib/euidaccess.c (euidaccess):
68651         * lib/pt_chown.c (main):
68652         * lib/unlinkdir.c (cannot_unlink_dir):
68653         * lib/write-any-file.c (can_write_any_file):
68654         * m4/mknod.m4 (gl_FUNC_MKNOD):
68655         * tests/test-sethostname2.c (geteuid, main):
68656         Don't assume ROOT_UID == 0.
68657         * modules/euidaccess (Depends-on):
68658         * modules/pt_chown (Depends-on):
68659         * modules/sethostname-tests (Depends-on):
68660         * modules/unlinkdir (Depends-on):
68661         * modules/write-any-file (Depends-on):
68662         Add root-uid.
68664         regex: use locale-independent comparison for codeset name
68665         See Bruno Haible's comment in <http://bugs.gnu.org/10305#120>.
68666         * lib/regcomp.c (init_dfa): Use just ASCII case comparison
68667         for codeset name.
68668         * lib/regex_internal.h: Do not include <strings.h>, since we
68669         no longer use strcasecmp.
68670         * modules/regex (Depends-on): Remove strcase.
68672 2012-06-23  Bruno Haible  <bruno@clisp.org>
68674         getopt-posix: No longer guarantee that option processing is resettable.
68675         * doc/posix-functions/getopt.texi: Drop description of problem with
68676         internal state. Fix info about mingw and msvc9.
68677         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Don't require a resettable
68678         option processing by getopt(). Run three test programs instead of one.
68679         Simplify cross-compilation guess.
68680         * NEWS: Mention the change.
68681         Reported by Rich Felker <dalias@aerifal.cx>.
68683 2012-06-26  Bruno Haible  <bruno@clisp.org>
68685         argp, regex: Ensure strcasecmp gets declared.
68686         * lib/argp-help.c: Include <strings.h>.
68687         * lib/regex_internal.h: Likewise.
68688         Reported and suggested by Joachim Schmitz <jojo@schmitz-digital.de>.
68690 2012-06-24  Bruno Haible  <bruno@clisp.org>
68692         ptsname_r: Make it consistent with ptsname on AIX.
68693         * lib/ptsname_r.c (__ptsname_r): For AIX, use nearly the same
68694         implementation as for OSF/1.
68695         * tests/test-ptsname_r.c (main) [AIX]: Use the modern way of opening
68696         a pty master.
68698         ptsname_r: Make it consistent with ptsname on OSF/1.
68699         * lib/ptsname_r.c (__ptsname_r): Add a different implementation for
68700         OSF/1.
68702 2012-06-24  Bruno Haible  <bruno@clisp.org>
68704         ttyname_r: Fix result on OSF/1, Solaris.
68705         * lib/ttyname_r.c (ttyname_r): Produce a NUL-terminated result.
68707 2012-06-24  Bruno Haible  <bruno@clisp.org>
68709         ptsname_r: Add support for Solaris.
68710         * lib/ptsname_r.c (__ptsname_r): Add a different implementation for
68711         Solaris.
68713         ptsname_r: Fix test failure on native Windows.
68714         * modules/ptsname_r (Depends-on): Add isatty.
68716         ptsname_r: Fix test failures on IRIX, Solaris.
68717         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Test whether isatty sets
68718         errno when it fails. Define ISATTY_FAILS_WITHOUT_SETTING_ERRNO
68719         accordingly.
68720         * lib/ptsname_r.c: Include <fcntl.h>.
68721         (__ptsname_r): When isatty returned false, then on IRIX, Solaris
68722         set errno if fd is invalid.
68723         * tests/test-isatty.c (main): Update comments.
68725 2012-06-24  Bruno Haible  <bruno@clisp.org>
68727         ptsname test: Extend test.
68728         * tests/test-ptsname.c: Include <errno.h>.
68729         (main): Test behaviour with invalid file descriptor.
68731 2012-06-23  Paul Eggert  <eggert@cs.ucla.edu>
68733         time: fix obsolete comment
68734         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Remove obsolete
68735         reference to HAVE_STRUCT_TIMESPEC in comment.
68737 2012-06-23  Bruno Haible  <bruno@clisp.org>
68739         getopt-gnu: Handle suboptimal getopt_long's abbreviation handling.
68740         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): If getopt_long exists but
68741         does not handle abbreviated long options with equivalent
68742         disambiguations, set gl_replace_getopt to yes.
68743         * doc/posix-functions/getopt.texi: Mention the OpenBSD 5.0 problem.
68745 2012-06-22  Paul Eggert  <eggert@cs.ucla.edu>
68747         time_r: fix typo that always overrode localtime_r decl
68748         * m4/time_r.m4 (gl_TIME_R): Use AC_CHECK_DECLS, not
68749         AC_CHECK_DECLS_ONCE, since localtime_r is declared in <time.h>,
68750         not in a standard include.
68752 2012-06-22  Bruno Haible  <bruno@clisp.org>
68754         Write "Mac OS X" instead of "MacOS X".
68755         * README: Write "Mac OS X" instead of "MacOS X".
68756         * build-aux/bootstrap: Likewise.
68757         * build-aux/install-reloc: Likewise.
68758         * lib/acl-internal.h: Likewise.
68759         * lib/acl_entries.c: Likewise.
68760         * lib/argp-ba.c: Likewise.
68761         * lib/argp-pv.c: Likewise.
68762         * lib/config.charset: Likewise.
68763         * lib/copy-acl.c: Likewise.
68764         * lib/csharpexec.c: Likewise.
68765         * lib/euidaccess.c: Likewise.
68766         * lib/fbufmode.c: Likewise.
68767         * lib/fflush.c: Likewise.
68768         * lib/file-has-acl.c: Likewise.
68769         * lib/filemode.h: Likewise.
68770         * lib/fpurge.c: Likewise.
68771         * lib/freadable.c: Likewise.
68772         * lib/freadahead.c: Likewise.
68773         * lib/freading.c: Likewise.
68774         * lib/freadptr.c: Likewise.
68775         * lib/freadseek.c: Likewise.
68776         * lib/fseeko.c: Likewise.
68777         * lib/fseterr.c: Likewise.
68778         * lib/fsusage.c: Likewise.
68779         * lib/fwritable.c: Likewise.
68780         * lib/fwriting.c: Likewise.
68781         * lib/get-rusage-as.c: Likewise.
68782         * lib/get-rusage-data.c: Likewise.
68783         * lib/getdomainname.c: Likewise.
68784         * lib/idpriv-drop.c: Likewise.
68785         * lib/idpriv-droptemp.c: Likewise.
68786         * lib/localcharset.c: Likewise.
68787         * lib/locale.in.h: Likewise.
68788         * lib/localename.c: Likewise.
68789         * lib/mbsrtowcs-state.c: Likewise.
68790         * lib/nproc.c: Likewise.
68791         * lib/passfd.c: Likewise.
68792         * lib/posix_openpt.c: Likewise.
68793         * lib/printf-parse.c: Likewise.
68794         * lib/progreloc.c: Likewise.
68795         * lib/safe-read.h: Likewise.
68796         * lib/safe-write.h: Likewise.
68797         * lib/sched.in.h: Likewise.
68798         * lib/set-mode-acl.c: Likewise.
68799         * lib/signal.in.h: Likewise.
68800         * lib/stdint.in.h: Likewise.
68801         * lib/stdio-impl.h: Likewise.
68802         * lib/stdlib.in.h: Likewise.
68803         * lib/strtod.c: Likewise.
68804         * lib/sys_select.in.h: Likewise.
68805         * lib/tcgetsid.c: Likewise.
68806         * lib/unistd.in.h: Likewise.
68807         * lib/unlockpt.c: Likewise.
68808         * lib/vasnprintf.c: Likewise.
68809         * lib/vma-iter.c: Likewise.
68810         * lib/wcsrtombs-state.c: Likewise.
68811         * m4/acl.m4: Likewise.
68812         * m4/acosl.m4: Likewise.
68813         * m4/asinl.m4: Likewise.
68814         * m4/atanl.m4: Likewise.
68815         * m4/c-stack.m4: Likewise.
68816         * m4/cosl.m4: Likewise.
68817         * m4/expl.m4: Likewise.
68818         * m4/extensions.m4: Likewise.
68819         * m4/fdatasync.m4: Likewise.
68820         * m4/fmal.m4: Likewise.
68821         * m4/frexp.m4: Likewise.
68822         * m4/frexpf.m4: Likewise.
68823         * m4/frexpl.m4: Likewise.
68824         * m4/fsusage.m4: Likewise.
68825         * m4/getdomainname.m4: Likewise.
68826         * m4/getloadavg.m4: Likewise.
68827         * m4/getopt.m4: Likewise.
68828         * m4/gettext.m4: Likewise.
68829         * m4/gnulib-common.m4: Likewise.
68830         * m4/intdiv0.m4: Likewise.
68831         * m4/intlmacosx.m4: Likewise.
68832         * m4/largefile.m4: Likewise.
68833         * m4/ldexpl.m4: Likewise.
68834         * m4/link-follow.m4: Likewise.
68835         * m4/locale-ar.m4: Likewise.
68836         * m4/locale-fr.m4: Likewise.
68837         * m4/locale-ja.m4: Likewise.
68838         * m4/locale-tr.m4: Likewise.
68839         * m4/locale-zh.m4: Likewise.
68840         * m4/locale_h.m4: Likewise.
68841         * m4/lock.m4: Likewise.
68842         * m4/logl.m4: Likewise.
68843         * m4/mathfunc.m4: Likewise.
68844         * m4/minus-zero.m4: Likewise.
68845         * m4/mktime.m4: Likewise.
68846         * m4/mmap-anon.m4: Likewise.
68847         * m4/multiarch.m4: Likewise.
68848         * m4/nanosleep.m4: Likewise.
68849         * m4/nocrash.m4: Likewise.
68850         * m4/poll.m4: Likewise.
68851         * m4/printf-frexpl.m4: Likewise.
68852         * m4/printf.m4: Likewise.
68853         * m4/signbit.m4: Likewise.
68854         * m4/sinl.m4: Likewise.
68855         * m4/sqrtl.m4: Likewise.
68856         * m4/strerror_r.m4: Likewise.
68857         * m4/tanl.m4: Likewise.
68858         * m4/threadlib.m4: Likewise.
68859         * m4/ttyname_r.m4: Likewise.
68860         * m4/unlink.m4: Likewise.
68861         * m4/visibility.m4: Likewise.
68862         * m4/wcwidth.m4: Likewise.
68863         * tests/minus-zero.h: Likewise.
68864         * tests/test-alloca-opt.c: Likewise.
68865         * tests/test-copy-acl.sh: Likewise.
68866         * tests/test-copy-file.sh: Likewise.
68867         * tests/test-fdatasync.c: Likewise.
68868         * tests/test-file-has-acl.sh: Likewise.
68869         * tests/test-flock.c: Likewise.
68870         * tests/test-fsync.c: Likewise.
68871         * tests/test-localename.c: Likewise.
68872         * tests/test-malloca.c: Likewise.
68873         * tests/test-nonblocking-pipe.h: Likewise.
68874         * tests/test-nonblocking-socket.h: Likewise.
68875         * tests/test-openpty.c: Likewise.
68876         * tests/test-posix_openpt.c: Likewise.
68877         * tests/test-ptsname.c: Likewise.
68878         * tests/test-ptsname_r.c: Likewise.
68879         * tests/test-sameacls.c: Likewise.
68880         * tests/test-select.h: Likewise.
68881         * tests/test-set-mode-acl.sh: Likewise.
68882         * tests/test-snprintf-posix.h: Likewise.
68883         * tests/test-sprintf-posix.h: Likewise.
68884         * tests/test-strtod.c: Likewise.
68885         * tests/test-time.c: Likewise.
68886         * tests/test-vasnprintf-posix.c: Likewise.
68887         * tests/test-vasprintf-posix.c: Likewise.
68888         * doc/acl-resources.txt: Likewise.
68889         * doc/**/*.texi: Likewise.
68890         Reported by Max Horn <max@quendi.de>.
68892 2012-06-22  Bruno Haible  <bruno@clisp.org>
68894         grantpt: Relax requirement regarding invalid file descriptors.
68895         * lib/grantpt.c: Don't include <fcntl.h>.
68896         (grantpt): Don't verify the validity of the file descriptor.
68897         * modules/grantpt (Depends-on): Remove fcntl-h.
68898         * tests/test-grantpt.c (main): Allow grantpt to succeed for invalid
68899         file descriptors.
68900         * doc/posix-functions/grantpt.texi: Document more platforms on which
68901         grantpt succeeds for invalid file descriptors.
68902         Reported by Rich Felker <dalias@aerifal.cx>.
68904 2012-06-22  Bruno Haible  <bruno@clisp.org>
68906         fbufmode test: Don't test unportable behaviour.
68907         * tests/test-fbufmode.c (test_mode): New function, extracted from main.
68908         (main): Invoke it three times.
68909         Reported by Szabolcs Nagy <nsz@port70.net>
68910         and Rich Felker <dalias@aerifal.cx>.
68912 2012-06-21  Bruno Haible  <bruno@clisp.org>
68914         gnulib-tool: Refactor inctests variable.
68915         * gnulib-tool: Normalize inctests to 'true' or 'false', not ''.
68916         (func_modules_transitive_closure,
68917         func_modules_transitive_closure_separately,
68918         func_import, func_create_testdir): Update.
68920         gnulib-tool: --create-[mega]testdir, --[mega]test implies --with-tests.
68921         * gnulib-tool: Accept option --without-tests.
68922         (func_usage): Document --without-tests option. Rearrange.
68923         (inctests): Normalize according to the mode.
68924         * NEWS: Mention the change.
68925         Suggested by Simon Josefsson.
68927 2012-06-21  Bruce Korb  <bkorb@gnu.org>
68929         parse-duration test: Avoid spurious output.
68930         * tests/test-parse-duration.sh: Reindent with leading tabs.
68932 2012-06-21  Jim Meyering  <meyering@redhat.com>
68934         maint: disable the strncpy prohibition
68935         * cfg.mk: Do not prohibit strncpy here.
68937 2012-06-21  Bruno Haible  <bruno@clisp.org>
68939         nonblocking: Avoid compilation error on mingw64.
68940         * m4/stdio_h.m4 (gl_STDIO_H): Invoke gl_MODULE_INDICATOR for scanf,
68941         fscanf.
68942         * modules/vscanf (configure.ac): Invoke gl_MODULE_INDICATOR.
68943         * modules/vfscanf (configure.ac): Likewise.
68944         * lib/stdio-read.c (scanf, fscanf, vscanf, vfscanf): Enable function
68945         definition only if stdio.h has prepared it.
68946         Reported by Daniel P. Berrange <berrange@redhat.com>.
68948 2012-06-20  Bernd Jendrissek  <bernd.jendrissek@gmail.com>  (tiny change)
68950         gnulib-tool: Use readlink if it is available.
68951         * gnulib-tool (func_readlink): Choose function more appropriately.
68953 2012-06-21  Paul Eggert  <eggert@cs.ucla.edu>
68955         posixtm-tests: port to buggy compiler
68956         Problem reported by Simon Josefsson in
68957         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00246.html>.
68958         * modules/posixtm-tests (Depends-on): Add stdint.
68959         * tests/test-posixtm.c (struct posixtm_test.t_expected):
68960         Now of type int_least64_t, not int64_t, both because that's
68961         what INT64_C returns and because int_least64_t works even
68962         on 72-bit hosts.
68963         (T): Use INT64_C on constants outside the traditional int range,
68964         to work around compiler bug noted by Simon.
68966         mktime: fix integer overflow in 'configure'-time test
68967         * m4/mktime.m4 (gl_FUNC_MKTIME): Do not rely on undefined behavior
68968         after integer overflow.  Problem reported by Rich Felker in
68969         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00257.html>.
68970         Also, don't look for further instances of a bug if we've already
68971         found one instance; this helps 'configure' run faster.
68973 2012-06-20  John Darrington  <john@darrington.wattle.id.au>  (tiny change)
68975         tmpfile, clean-temp: Fix invocation of GetVersionEx.
68976         * lib/tmpfile.c (supports_delete_on_close): Initialize parameter for
68977         GetVersionEx correctly.
68978         * lib/clean-temp.c (supports_delete_on_close): Likewise.
68980 2012-06-20  Bruno Haible  <bruno@clisp.org>
68982         fdopen: Allow implementations that don't reject invalid fd arguments.
68983         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Let the test pass if fdopen(-1,...)
68984         succeeds.
68985         Reported by Rich Felker <dalias@aerifal.cx>.
68987 2012-06-20  Simon Josefsson  <simon@josefsson.org>
68989         * modules/parse-duration-tests (test_parse_duration_LDADD): Don't
68990         bring in LIBINTL.
68992 2012-06-20  Paul Eggert  <eggert@cs.ucla.edu>
68994         init.sh: do not rely on autoupated PWD
68995         This addresses symptoms of the problem reported by Nelson H.F. Beebe in
68996         <http://lists.gnu.org/r/bug-gzip/2012-06/msg00008.html>.
68997         Although Nelson's bug was not necessarily fixed by this patch,
68998         it seems wise to make the change for safety.
68999         * tests/init.sh (path_prepend_): Do not rely on PWD updating
69000         automagically after 'cd'; this is not reliable on older shells.
69001         (setup_): Fail if we cannot cd to temporary directory.
69003 2012-06-19  Bruno Haible  <bruno@clisp.org>
69005         stat, fstat: Avoid warnings on mingw64.
69006         * lib/stat.c (stat) [_GL_WINDOWS_64_BIT_ST_SIZE]: Undefine before
69007         redefining.
69008         * lib/fstat.c (stat, fstat) [_GL_WINDOWS_64_BIT_ST_SIZE]: Likewise.
69009         Reported by Daniel P. Berrange <berrange@redhat.com>.
69011 2012-06-19  Bruno Haible  <bruno@clisp.org>
69013         stdioext: Add support for musl libc.
69015         * m4/fbufmode.m4 (gl_FUNC_FBUFMODE): Test whether __fbufsize exists.
69016         * lib/fbufmode.c (fbufmode): Add conditional code for musl.
69018         * m4/fseterr.m4: New file.
69019         * lib/fseterr.h (fseterr): Define as an alias of __fseterr if that
69020         function exists.
69021         * modules/fseterr (Files): Add m4/fseterr.m4.
69022         (configure.ac): Invoke gl_FUNC_FSETERR. Compile fseterr.c if
69023         __fseterr does not exist.
69024         (Makefile.am): Remove fseterr.c from lib_SOURCES.
69026         * lib/freadable.h: Update comment.
69028         * lib/fwritable.h: Update comment.
69030         * lib/freading.h: Update comment.
69032         * lib/fwriting.h: Update comment.
69034         * m4/freadahead.m4: New file.
69035         * lib/freadahead.h (freadahead): Define as an alias of __freadahead if
69036         that function exists.
69037         * modules/freadahead (Files): Add m4/freadahead.m4.
69038         (configure.ac): Invoke gl_FUNC_FREADAHEAD. Compile freadahead.c if
69039         __freadahead does not exist.
69040         (Makefile.am): Remove freadahead.c from lib_SOURCES.
69042         * m4/freadptr.m4: New file.
69043         * lib/freadptr.h (freadptr): Define as an alias of __freadptr if that
69044         function exists.
69045         * modules/freadptr (Files): Add m4/freadptr.m4.
69046         (configure.ac): Invoke gl_FUNC_FREADPTR. Compile freadptr.c if
69047         __freadptr does not exist.
69048         (Makefile.am): Remove freadptr.c from lib_SOURCES.
69050         * m4/freadseek.m4: New file.
69051         * lib/freadseek.c (freadptrinc): Use __freadptrinc if that function
69052         exists.
69053         * modules/freadseek (Files): Add m4/freadseek.m4.
69054         (configure.ac): Invoke gl_FUNC_FREADSEEK.
69056         * lib/fpurge.c (fpurge): Update comment.
69058         Reported by and with help from Rich Felker <dalias@aerifal.cx>.
69060 2012-06-19  Bruno Haible  <bruno@clisp.org>
69062         *printf-posix: Put more info into config.log.
69063         * m4/printf.m4 (gl_PRINTF_ENOMEM): Emit conftest's error output and
69064         exit code into config.log.
69066 2012-06-19  Bruno Haible  <bruno@clisp.org>
69068         getopt-gnu: Fix exit code overflow in autoconf test.
69069         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Squash exit code values,
69070         to keep them below < 128.
69072 2012-06-17  Jim Meyering  <meyering@redhat.com>
69074         maint.mk: fix typo in code to derive GPG key at release time
69075         * top/maint.mk (gpg_key_ID): Fix typo: $3 -> $$3
69077 2012-06-17  Paul Eggert  <eggert@cs.ucla.edu>
69079         regex: avoid warning when pointers are not long
69080         * lib/regcomp.c (parse_dup_op, mark_opt_subexp): Cast between void *
69081         and uintptr_t, not long, for portability to hosts where pointers and
69082         long have different sizes.  Issue noted by Daniel P. Berrange in
69083         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00122.html>
69084         and fix suggested by Bruno Haible in
69085         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00128.html>.
69087 2012-06-17  Bruno Haible  <bruno@clisp.org>
69089         dummy: Relicense into the public domain.
69090         * modules/dummy (License): Set to "public domain".
69091         Suggested by Reuben Thomas.
69093 2012-06-12  Akim Demaille  <akim@lrde.epita.fr>
69095         announce-gen: VPATH issues
69096         * build-aux/announce-gen (--srcdir): New option, used to trim the
69097         $srcdir part of the path from $builddir to NEWS.
69098         * top/maint.mk (announcement): Adjust.
69100 2012-06-12  Akim Demaille  <akim@lrde.epita.fr>
69102         gnu-web-doc-update: VPATH builds
69103         * build-aux/gnu-web-doc-update (--builddir): New option.
69104         Revamp the handling of options.
69105         Prefer $(...) to `...`.
69106         Don't pass --tmpdir=. to mktemp, it is useless given that we specify
69107         the template, and it is GNU mktemp specific.
69108         Prefer set -e to long series of &&.
69109         Restore the initial git branch, not "master".
69110         Properly initialize submodules (don't rely only on bootstrap).
69111         Do not reconfigure blindly, use config.status.
69112         * top/README-release: Update instructions for gnu-web-doc-update.
69114 2012-06-11  Jim Meyering  <meyering@redhat.com>
69116         maint.mk: revert most of the previous change re "all these"
69117         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Remove that pair.
69118         For rationale, see the discussion at
69119         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30912
69121 2012-06-10  Karl Berry  <karl@gnu.org>
69123         * build-aux/gnupload: with --dry-run, do not ask for gpg pw.
69125         * build-aux/gnupload: implement --replace, ftp-upload protocol v1.2.
69127 2012-06-10  Bruce Korb  <bkorb@gnu.org>
69129         parse-duration: Relicense under LGPLv2+.
69130         * modules/parse-duration (License): Change to LGPLv2+.
69132 2012-06-10  Jim Meyering  <meyering@redhat.com>
69134         maint.mk: prohibit common grammar error: "all these"
69135         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Add "all these" to
69136         the list of prohibited word sequences.  It should be "all of these".
69137         * lib/tempname.c (__gen_tempname): Fix one of them.
69139 2012-06-07  Akim Demaille  <akim@lrde.epita.fr>
69141         do-release-commit-and-tag: support VPATH builds
69142         * build-aux/do-release-commit-and-tag: Prefer $(...) to `...`.
69143         (noteworthy): Defined earlier to factor its value.
69144         (noteworthy_stub): New.
69145         Use it to factor.
69146         (help_version): Split into...
69147         (help, version): these.
69148         Adjust the option processing part.
69149         Support "--option=value" in addition to "--option value".
69150         (builddir): New.
69151         (--builddir): New option.
69152         * top/README-release: Document this.
69153         Reword slightly so that the reader cannot understand that he
69154         has to do these steps before calling do-release-commit-and-tag.
69156 2012-06-07  Akim Demaille  <akim@lrde.epita.fr>
69158         readme-release: also require announce-gen and maintainer-makefile
69159         * modules/readme-release (Depends-on): here.
69160         * modules/announce-gen, modules/do-release-commit-and-tag,
69161         modules/gnu-web-doc-update, modules/maintainer-makefile
69162         (Description): Point to readme-release.
69164 2012-06-07  Akim Demaille  <akim@lrde.epita.fr>
69166         maint.mk: fix VPATH issues.
69167         * top/maint.mk (news-check): GNU Make understand $< very well.
69168         (release-prep): NEWS is in $(srcdir).
69170 2012-06-05  Akim Demaille  <akim@lrde.epita.fr>
69172         readme-release: require the promoted modules.
69173         * modules/readme-release (Depends-on): Add
69174         do-release-commit-and-tag, gnupload, and gnu-web-doc-update, used
69175         in this text.
69177 2012-05-21  Paolo Bonzini  <bonzini@gnu.org>
69178             Bruno Haible  <bruno@clisp.org>
69180         error, strerror-override: Support mingw64 from Fedora 17.
69181         * lib/errno.in.h (GNULIB_defined_ESTREAMS): Use a different indicator
69182         for ETXTBSY, ENODATA, ENOSR, ENOSTR, ETIME, EOTHER, compared to
69183         EINPROGRESS.
69184         * lib/strerror-override.h (strerror_override): Test it.
69185         * lib/strerror-override.c (strerror_override): Likewise.
69186         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Test also ETXTBSY.
69188 2012-05-21  Paolo Bonzini  <bonzini@gnu.org>
69189             Bruno Haible  <bruno@clisp.org>
69191         error, strerror-override: Support mingw64 from Fedora 17.
69192         * lib/errno.in.h (GNULIB_defined_ENOTRECOVERABLE): Use a different
69193         indicator for ENOTRECOVERABLE, compared to EOWNERDEAD.
69194         * lib/strerror-override.h (strerror_override): Test it.
69195         * lib/strerror-override.c (strerror_override): Likewise.
69197 2012-06-03  Bruno Haible  <bruno@clisp.org>
69199         error, strerror-override: Support new errno values from POSIX:2008.
69200         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Test also EOWNERDEAD and
69201         ENOTRECOVERABLE.
69202         * lib/errno.in.h (EOWNERDEAD, ENOTRECOVERABLE): Define on all
69203         platforms.
69204         * lib/strerror-override.c (strerror_override): Conditionalize the
69205         EOWNERDEAD, ENOTRECOVERABLE handling on GNULIB_defined_EOWNERDEAD.
69206         * lib/strerror-override.h (strerror_override): Declare also if
69207         GNULIB_defined_EOWNERDEAD is defined.
69208         * tests/test-errno.c (e130, e131): New variables.
69209         * doc/posix-headers/errno.texi: Mention the status for EOWNERDEAD,
69210         ENOTRECOVERABLE.
69211         Reported by Paolo Bonzini.
69213 2012-05-31  Jim Meyering  <meyering@redhat.com>
69215         savewd: add missing dependency on sys_wait module
69216         * modules/savewd (Depends-on): Add sys_wait, needed at least
69217         for MSVC.  Report and suggested change by Michael Goffioul.
69219 2012-05-29  Paul Eggert  <eggert@cs.ucla.edu>
69221         system-quote-tests: port to CentOS 5
69222         Problem reported by Tom G. Christensen in
69223         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00255.html>.
69224         * tests/test-system-quote-child.c (fclose, fprintf): Undef.
69226 2012-05-29  Jim Meyering  <meyering@redhat.com>
69228         maint: fix typos in comments and ChangeLog
69229         Culprits identified and fixed mostly automatically using these commands:
69230         git ls-files | misspellings -f - |grep -v '^ERROR:' |perl -pe \
69231         's/^(.*?)\[(\d+)\]: (\w+) -> "(.*?)"$/sed -i '\''${2}s!$3!$4!'\'' $1/'
69232         using http://github.com/lyda/misspell-check
69233         * ChangeLog: Fix typos.
69234         * doc/solaris-versions: Likewise.
69235         * lib/regexec.c (re_search_stub): Likewise.
69236         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
69238 2012-05-27  Paul Eggert  <eggert@cs.ucla.edu>
69240         manywarnings: remove duplicate -Wmultichar entry
69241         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Remove duplicate
69242         entry for -Wmultichar.  -Wno-multichar is in the GCC 4.7.0 manual,
69243         so keep the entry marked as documented.
69245 2012-05-27  Karl Berry  <karl@gnu.org>
69247         * config/srclist.txt (mktime.c): remove last libc sync,
69248         perhaps just temporarily.
69250 2012-05-26  Paul Eggert  <eggert@cs.ucla.edu>
69252         regex: don't assume uint64_t or uint32_t
69253         * lib/regcomp.c (init_word_char): Don't assume that the types
69254         uint64_t and uint32_t exist.  The C standard doesn't guarantee
69255         them, and on some 32-bit compilers there is no uint64_t.
69256         Problem reported by Gianluigi Tiesi in
69257         <http://lists.gnu.org/r/bug-gnulib/2012-03/msg00154.html>.
69259 2012-05-25  Jim Meyering  <meyering@redhat.com>
69261         maint.mk: add strncpy-prohibiting syntax-check rule
69262         * top/maint.mk (sc_prohibit_strncpy): New rule, from coreutils.
69264 2012-05-24  Jim Meyering  <meyering@redhat.com>
69266         maint.mk: compute $(gpg_key_ID) more portably
69267         * top/maint.mk (gpg_key_ID): Use awk in place of sed '{...;...;}'.
69268         That use of sed is not portable to some fringe systems.
69269         Reported by Paul Eggert in
69270         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30793/focus=30802
69272 2012-05-23  Paul Eggert  <eggert@cs.ucla.edu>
69274         mktime: sync from glibc
69275         * config/srclist.txt: Uncomment mktime.c.
69276         * lib/mktime.c: Sync from glibc master.  This incorporates 3 changes.
69277         First, indent with tabs, since glibc uses tabs and doesn't want to
69278         change and we'd rather be identical to glibc.  Also, two small
69279         coding changes:
69280         (isdst_differ): Use &&, not &, as && is the usual style.
69281         (__mktime_internal): Rename local var from abs_diff to approx_abs_diff
69282         for clarity.
69284 2012-05-23  Akim Demaille  <akim@lrde.epita.fr>
69286         announce-gen: du -h is more portable than du --human
69287         * build-aux/announce-gen (sizes): Invoke du with -h instead
69288         of --human.  Accept leading white space in its output.
69290 2012-05-23  Akim Demaille  <akim@lrde.epita.fr>
69292         announce-gen: Improve diagnostics.
69293         * build-aux/announce-gen: When parsing command line options,
69294         prefer "announce-gen: option --release-type requires an argument"
69295         to "Option release-type requires an argument".
69297 2012-05-23  Akim Demaille  <akim@lrde.epita.fr>
69299         maint.mk: gpg_key_ID: use sed more portably
69300         * top/maint.mk (gpg_key_ID): End sed block with a semicolon before
69301         the closing brace.
69302         (refresh-po): Fuse two sed invocations into one.
69304 2012-05-15  Akim Demaille  <akim@lrde.epita.fr>
69306         gitlog-to-changelog: support the log message format used in Bison.
69307         * build-aux/gitlog-to-changelog: Support --strip-tab and
69308         --strip-cherry-picked.
69310 2012-05-21  Paolo Bonzini  <bonzini@gnu.org>
69312         poll/select: prevent busy-waiting.  SwitchToThread() only gives away
69313         the rest of the current time slice to another thread in the current
69314         process. So if the thread that feeds the file decscriptor we're
69315         polling is not in the current process, we get busy-waiting.
69316         * lib/poll.c: Use SleepEx(1, TRUE) instead of SwitchToThread().
69317         Patch from Theodore Leblond.
69318         * lib/select.c: Split polling out of the loop that sets the output
69319         fd_sets.  Check for zero result and loop if the wait timeout is
69320         infinite.
69322 2012-05-21  Simon Josefsson  <simon@josefsson.org>
69324         select: Fix build error on IRIX 6.5.
69325         * lib/select.c: Include stddef.h for NULL.
69327 2012-05-21  Simon Josefsson  <simon@josefsson.org>
69329         gc: fix libgcrypt detection on older machines.
69330         * m4/gc.m4: Reject libgcrypt earlier than 1.4.4.  Collapse
69331         copyright years because the file has been distributed every year
69332         since it was created.
69334 2012-05-18  Paul Eggert  <eggert@cs.ucla.edu>
69336         crypto: fix bug in large buffer handling
69337         Problem reported by Serge Belyshev for glibc in
69338         <http://sourceware.org/bugzilla/show_bug.cgi?id=14090> and for gnulib in
69339         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00226.html>.
69340         * lib/md4.c (md4_process_block):
69341         * lib/md5.c (md5_process_block):
69342         * lib/sha1.c (sha1_process_block):
69343         * lib/sha256.c (sha256_process_block):
69344         Don't assume the buffer length is less than 2**32.
69345         * lib/sha512.c (sha512_process_block): Likewise.
69346         Here, the bug is present only in the rare case where the host does
69347         not support uint64_t or where size_t is wider than 64 bits.
69348         Use u64size to work around the problems.
69349         * lib/u64.h (u64size): New macro.
69351 2012-05-15  Pádraig Brady  <P@draigBrady.com>
69353         fsusage: fix block size returned on older Linux 2.6
69355         * lib/fsusage.c: Fall back to (struct statfs).f_frsize
69356         which is available since Linux 2.6.
69357         * m4/fsusage.m4 (STAT_STATFS2_FRSIZE): Always define
69358         when the member is available so it can be used as a fallback.
69359         * doc/posix-functions/statvfs.texi: Mention the hang issue
69360         on Linux < 2.6.36.
69362 2012-05-14  Paul Eggert  <eggert@cs.ucla.edu>
69364         bootstrap: suppress stderr chatter
69365         * build-aux/bootstrap (insert_sorted_if_absent, main program):
69366         Omit unnecessary chatter to stderr.  The main program chatter
69367         was there only inadvertantly.
69369         bootstrap: .gitignore files created by autopoint, libtool
69370         I ran into this problem when bootstrapping the latest diffutils.
69371         After './bootstrap', 'git status' reported lots of untracked files
69372         m4/codeset.m4, m4/gettext.m4, etc.  These files were created by
69373         autopoint and do not need to be version-controlled.
69374         * build-aux/bootstrap: Put into .gitignore the files that
69375         autopoint and libtool create, by keeping track of files that exist
69376         after but not before these programs are run.
69377         (version_controlled_file): Move up.  2nd arg is now full file
69378         name, not base name; this is more convenient.  Put CVS at the end,
69379         as it's now somewhat deprecated.
69381 2012-05-14  Jim Meyering  <meyering@redhat.com>
69383         ignore-value.h: remove unused _GL_ATTRIBUTE_DEPRECATED definition
69384         * lib/ignore-value.h (_GL_ATTRIBUTE_DEPRECATED): Remove now-unused
69385         definition.  Reported by Bruno Haible.
69387 2012-05-13  Bruno Haible  <bruno@clisp.org>
69388             Paul Eggert  <eggert@cs.ucla.edu>
69390         binary-io: Define set_binary_mode function.
69391         * lib/binary-io.h (set_binary_mode): New function.
69392         (SET_BINARY): Define in terms of set_binary_mode.
69393         * modules/binary-io (configure.ac): Require AC_C_INLINE.
69394         * tests/test-binary-io.c (main): Accept an argument, and test either
69395         set_binary_mode or SET_BINARY depending on the argument.
69396         * tests/test-binary-io.sh: Invoke test-binary-io twice, with an
69397         argument. Clean up also t-bin-out0.tmp.
69399 2012-05-13  Stefano Lattarini  <stefano.lattarini@gmail.com>
69401         bootstrap: take advantage of POSIX shell features
69403         The 'bootstrap' script offered by Gnulib script already uses POSIX
69404         shell features (like $((...)) arithmetic expansions) that are not
69405         supported by legacy Bourne shells like Solaris 10 /bin/sh.  This
69406         means that bootstrap must already be run using a proper POSIX shell,
69407         which will thus provide more features, like ${var#pattern} parameter
69408         expansion or inversion of a command exit status with '!'.  We can
69409         thus use these features to improve the clarity and the performances
69410         of the bootstrap script.
69412         Suggested by Eric Blake.
69414         * build-aux/bootstrap: Prefer xpg4 parameter expansions over use
69415         of sed/expr plus command substitutions, to save some forks.  While
69416         we are at it, prefer the POSIX $(...) form of command substitution,
69417         rather than the legacy form `...` (since the former is visually
69418         clearer and interacts better with quoting), and prefer the idiom:
69419           "if ! CMD; then ACTION ..."
69420         over the idiom:
69421           "if CMD; then :; else ACTION ..."
69422         which was required by legacy Bourne shells not supporting '!'.
69424 2012-05-12  Bruno Haible  <bruno@clisp.org>
69426         system-quote: Add more comments.
69427         * lib/system-quote.h: Add more comments about wilcards and limitations.
69428         Suggested by Eli Zaretskii <eliz@gnu.org>.
69430         sh-quote, system-quote: Add comments about wildcards.
69431         * lib/sh-quote.h: Clarify what happens with wildcard characters.
69432         * lib/system-quote.h: Likewise.
69433         Reported by Eli Zaretskii <eliz@gnu.org>.
69435 2012-05-11  Paul Eggert  <eggert@cs.ucla.edu>
69437         fsusage: check for GNU/Linux statvfs problem dynamically
69438         * lib/fsusage.c [STAT_STATVFS && __linux__ && (__GLIBC__||__UCLIBC__)]:
69439         Define STAT_STATFS2_BSIZE too, since in this case the code now
69440         checks dynamically whether statvfs is reliable, falling back on
69441         Linux-style statfs otherwise.
69442         (statvfs_works): New function, for dynamically testing statvfs.
69443         (get_fs_usage) [STAT_STATVFS]: Use it.
69444         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Remove static check for
69445         statvfs on GNU/Linux hosts, since it's now done dynamically.
69447 2012-05-10  Bruno Haible  <bruno@clisp.org>
69449         system-quote, execute, spawn-pipe: Escape '?' on Windows.
69450         * lib/system-quote.c (SHELL_SPECIAL_CHARS, CMD_SPECIAL_CHARS): Add the
69451         '?' character.
69452         * lib/w32spawn.h (SHELL_SPECIAL_CHARS): Likewise.
69453         * tests/test-system-quote-main.c (check_all): Check also strings like
69454         "??????????".
69455         Reported by Eli Zaretskii <eliz@gnu.org>.
69457 2012-05-10  Paul Eggert  <eggert@cs.ucla.edu>
69459         _Noreturn: port config.h to gcc -Wundef
69460         * m4/gnulib-common.m4 (gl_COMMON_BODY): Check that __STDC_VERSION__ is
69461         defined before using it, for gcc -Wundef.  Reported by Akim Demaille in
69462         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00147.html>.
69464 2012-05-10  Bruno Haible  <bruno@clisp.org>
69466         system-quote: Refactor.
69467         * lib/system-quote.h (system_quote_copy): Fix comment.
69468         * lib/system-quote.c (windows_createprocess_quote, windows_cmd_quote):
69469         New functions, extracted from system_quote_copy.
69470         (system_quote_length, system_quote_copy): Use these functions.
69471         Reported by Paul Eggert.
69473 2012-05-08  Bruno Haible  <bruno@clisp.org>
69475         execute, spawn-pipe: Escape '*' characters in arguments on Windows.
69476         * lib/w32spawn.h (SHELL_SPECIAL_CHARS): Add the '*' character.
69478 2012-05-08  Bruno Haible  <bruno@clisp.org>
69480         Tests for module 'system-quote'.
69481         * modules/system-quote-tests: New file.
69482         * tests/test-system-quote.sh: New file.
69483         * tests/test-system-quote-main.c: New file.
69484         * tests/test-system-quote-child.c: New file.
69486         New module 'system-quote'.
69487         * lib/system-quote.h: New file.
69488         * lib/system-quote.c: New file.
69489         * modules/system-quote: New file.
69491 2012-05-08  Bruno Haible  <bruno@clisp.org>
69493         sh-quote: Make C++ safe and allow multiple inclusion.
69494         * lib/sh-quote.h: Add double-inclusion guard. For C++, wrap function
69495         declarations in extern "C".
69497 2012-05-08  Bruno Haible  <bruno@clisp.org>
69499         sh-quote tests: Make tests stricter.
69500         * tests/test-sh-quote.c (check_one): Check the return value of
69501         shell_quote_copy.
69502         (main): Check a string with a CR character. Check a string that
69503         contains UCHAR_MAX.
69505 2012-05-08  Akim Demaille  <akim@lrde.epita.fr>
69507         warnings.m4: provide a means to specify the program to compile.
69508         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): New, extracted from...
69509         (gl_WARN_ADD): here.
69510         Use gl_AS_VAR_APPEND.
69511         Support an argument to specify the program to compile.
69512         (gl_WARN_ADD): Accept an argument to specify the program to compile.
69513         AC_SUBST the WARN_CFLAGS when they are used.
69514         * modules/warnings (configure.ac): Don't AC_SUBST WARN_CFLAGS,
69515         leave this to gl_WARN_ADD.
69517 2012-05-08  Eric Blake  <eblake@redhat.com>
69519         doc: recommendations on gettext version
69520         * doc/gnulib-tool.texi (gettextize and autopoint): Document the
69521         choice between versions.
69522         * DEPENDENCIES (gettext): Cover both approaches.
69524 2012-05-08  Jim Meyering  <meyering@redhat.com>
69526         init.sh: explain why EXEEXT support uses aliases rather than functions
69527         * tests/init.sh: Add a comment.
69529         init.sh: don't let bash aliases interfere with tests
69530         * tests/init.sh: Undefine any pre-defined aliases if the selected shell
69531         is bash.  This avoids problems for those who alias standard commands to
69532         non-conforming uses, like those reported in http://bugs.gnu.org/11256.
69533         Suggested by Tim Mooney <Tim.Mooney@ndsu.edu>.
69535 2012-05-07  Paul Eggert  <eggert@cs.ucla.edu>
69537         stdint: be more consistent with glibc, SunOS libc
69538         * lib/stdint.in.h (gl_int_fast8_t, gl_uint_fast8_t)
69539         (gl_int_fast16_t, gl_uint_fast16_t)
69540         (gl_int_fast32_t, gl_uint_fast32_t)
69541         (INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX)
69542         (INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX)
69543         (INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
69544         Be consistent with glibc by default, and with SunOS 5.10 and later
69545         if __sun is defined.  This lessens the likelihood of clashes if
69546         code compiled for older hosts is combined with code compiled for
69547         newer ones.  Problem reported by Niels Möller in
69548         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00074.html>.
69550 2012-05-07  Eric Blake  <eblake@redhat.com>
69552         isatty: relax license to LGPLv2+
69553         * modules/isatty (License): Relax license.
69555 2012-05-06  Paul Eggert  <eggert@cs.ucla.edu>
69557         stat-size: comment fix
69558         * lib/stat-size.h: Remove obsolete comment about indenting.
69560 2012-05-06  Bruno Haible  <bruno@clisp.org>
69562         Tests for module 'sh-quote'.
69563         * modules/sh-quote-tests: New file.
69564         * tests/test-sh-quote.c: New file.
69566 2012-05-06  Bruno Haible  <bruno@clisp.org>
69568         sh-quote: Improve shell_quote_argv's signature.
69569         * lib/sh-quote.h (shell_quote_argv): Make argument array a 'const *'.
69570         * lib/sh-quote.c (shell_quote_argv): Likewise.
69572 2012-05-06  Paul Eggert  <eggert@cs.ucla.edu>
69574         stdint: document issues with int_fast8_t etc.
69575         * doc/posix-headers/stdint.texi (stdint.h): Say that other
69576         stdint.h substitutes may define these types differently.  See
69577         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00071.html>.
69579 2012-05-05  Bruno Haible  <bruno@clisp.org>
69581         nanosleep: Avoid guessing wrong when cross-compiling to Linux.
69582         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require AC_CANONICAL_HOST. When
69583         cross-compiling, set gl_cv_func_nanosleep to either 'guessing no'
69584         or 'guessing no (mishandles large arguments)'.
69586 2012-05-05  Bruno Haible  <bruno@clisp.org>
69588         link-follow: Avoid guessing wrong when cross-compiling to glibc/Linux.
69589         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Require
69590         AC_CANONICAL_HOST. When cross-compiling to a glibc/Linux platform,
69591         set gl_cv_func_link_follows_symlink to "guessing no".
69593 2012-05-05  Bruno Haible  <bruno@clisp.org>
69595         tzset: Avoid guessing wrong when cross-compiling to glibc systems.
69596         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require AC_CANONICAL_HOST. When
69597         cross-compiling to a glibc platform, set gl_cv_func_tzset_clobber to
69598         "guessing no".
69599         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Update.
69601 2012-05-05  Bruno Haible  <bruno@clisp.org>
69603         d-ino: Avoid guessing "no" when cross-compiling to glibc/Linux systems.
69604         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Require
69605         AC_CANONICAL_HOST. When cross-compiling to a glibc/Linux platform,
69606         set gl_cv_struct_dirent_d_ino to "guessing yes".
69608 2012-05-05  Bruno Haible  <bruno@clisp.org>
69610         fseeko-tests, ftello-tests: Avoid "guessing no" when cross-compiling.
69611         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Require AC_CANONICAL_HOST. When
69612         cross-compiling to a glibc platform, set gl_cv_func_ungetc_works to
69613         "guessing yes".
69615 2012-05-05  Bruno Haible  <bruno@clisp.org>
69617         signbit: Avoid "guessing no" when cross-compiling to glibc systems.
69618         * m4/signbit.m4 (gl_SIGNBIT): Require AC_CANONICAL_HOST. When cross-
69619         compiling to a glibc system, set gl_cv_func_signbit and
69620         gl_cv_func_signbit_gcc to "guessing yes".
69622 2012-05-05  Bruno Haible  <bruno@clisp.org>
69624         strerror: Avoid "guessing no" when cross-compiling to glibc systems.
69625         * m4/strerror.m4 (gl_FUNC_STRERROR): Require AC_CANONICAL_HOST. When
69626         cross-compiling to a glibc platform, set gl_cv_func_working_strerror
69627         to "guessing yes".
69628         (gl_FUNC_STRERROR_0): Require AC_CANONICAL_HOST. When cross-compiling
69629         to a glibc platform, set gl_cv_func_strerror_0_works to "guessing yes".
69631 2012-05-05  Bruno Haible  <bruno@clisp.org>
69633         canonicalize[-lgpl]: Avoid "guessing no" when cross-compiling to glibc.
69634         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Require
69635         AC_CANONICAL_HOST. When cross-compiling to a glibc system, set
69636         gl_cv_func_realpath_works to "guessing yes".
69638 2012-05-05  Bruno Haible  <bruno@clisp.org>
69640         gettimeofday: Avoid bad guess when cross-compiling to glibc systems.
69641         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Require
69642         AC_CANONICAL_HOST. When cross-compiling, guess no on glibc platforms.
69644 2012-05-04  Bruno Haible  <bruno@clisp.org>
69646         Tweak last commit.
69647         * m4/off_t.m4 (gl_TYPE_OFF_T): Tweak comments.
69648         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
69650 2012-05-04  Paul Eggert  <eggert@cs.ucla.edu>
69652         unistd_h: make it easier to avoid sys_types_h
69653         This is useful for Emacs, which has its own method of porting to
69654         Windows, and which therefore does not need the sys_types_h module.
69655         * m4/off_t.m4: New file, defining gl_TYPE_OFF_T, which contains
69656         code moved here from gl_SYS_TYPES_H.
69657         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Require it instead of
69658         using the code directly.
69659         * m4/unistd_h.m4 (gl_UNISTD_H): Require gl_TYPE_OFF_T, not
69660         gl_SYS_TYPES_H.
69661         * modules/sys_types (Files):
69662         * modules/unistd (Files): Add m4/off_t.m4.
69664 2012-05-03  Bruno Haible  <bruno@clisp.org>
69666         lstat: Avoid "guessing no" when cross-compiling to glibc systems.
69667         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): When cross-
69668         compiling, set gl_cv_func_lstat_dereferences_slashed_symlink to
69669         "guessing yes" or "guessing no".
69670         (gl_FUNC_LSTAT): Update.
69671         * m4/fstatat.m4 (gl_FUNC_FSTATAT): Update.
69672         * m4/openat.m4 (gl_FUNC_OPENAT): Update.
69673         * m4/unlinkat.m4 (gl_FUNC_UNLINKAT): Update.
69675 2012-05-03  Bruno Haible  <bruno@clisp.org>
69677         *alloc-gnu, eealloc: Avoid "guessing no" when cross-compiling to glibc.
69678         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Override in autoconf < 2.70.
69679         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Override in autoconf < 2.70.
69680         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Require AC_CANONICAL_HOST. When
69681         cross-compiling, choose the first alternative on glibc systems.
69682         * modules/eealloc (Files): Add m4/malloc.m4, m4/realloc.m4.
69684 2012-05-03  Bruno Haible  <bruno@clisp.org>
69686         getgroups: Avoid "guessing no" when cross-compiling to glibc systems.
69687         * m4/getgroups.m4 (AC_FUNC_GETGROUPS): Override in autoconf < 2.70.
69688         (gl_FUNC_GETGROUPS): Adapt to change of ac_cv_func_getgroups_works.
69690 2012-05-03  Bruno Haible  <bruno@clisp.org>
69692         chown: Avoid "guessing no" when cross-compiling to glibc systems.
69693         * m4/chown.m4 (AC_FUNC_CHOWN): Override in autoconf < 2.70.
69695 2012-05-03  Bruno Haible  <bruno@clisp.org>
69697         Avoid "guessing no" guesses when cross-compiling to glibc systems.
69698         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Require AC_CANONICAL_HOST. When cross-
69699         compiling to glibc systems, set gl_cv_func_cbrtl_ieee to "guessing yes".
69700         * m4/ceil.m4 (gl_FUNC_CEIL): Require AC_CANONICAL_HOST. When cross-
69701         compiling to glibc systems, set gl_cv_func_ceil_ieee to "guessing yes".
69702         * m4/ceilf.m4 (gl_FUNC_CEILF): Require AC_CANONICAL_HOST. When cross-
69703         compiling to glibc systems, set gl_cv_func_ceilf_ieee to "guessing yes".
69704         * m4/ceill.m4 (gl_FUNC_CEILL): Require AC_CANONICAL_HOST. When cross-
69705         compiling to glibc systems, set gl_cv_func_ceill_ieee to "guessing yes".
69706         * m4/chown.m4 (gl_FUNC_CHOWN): Require AC_CANONICAL_HOST. When cross-
69707         compiling to glibc systems, set gl_cv_func_chown_slash_works,
69708         gl_cv_func_chown_ctime_works to "guessing yes".
69709         * m4/lchown.m4 (gl_FUNC_LCHOWN): Update.
69710         * m4/exp2l.m4 (gl_FUNC_EXP2L): Require AC_CANONICAL_HOST. When cross-
69711         compiling to glibc systems, set gl_cv_func_exp2l_ieee to "guessing yes".
69712         * m4/expm1.m4 (gl_FUNC_EXPM1): Require AC_CANONICAL_HOST. When cross-
69713         compiling to glibc systems, set gl_cv_func_expm1_ieee to "guessing yes".
69714         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require AC_CANONICAL_HOST. When cross-
69715         compiling to glibc systems, set gl_cv_func_open_directory_works to
69716         "guessing yes".
69717         * m4/fstat.m4 (gl_FUNC_FSTAT): Update.
69718         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Require AC_CANONICAL_HOST. When
69719         cross-compiling to glibc systems, set gl_cv_func_fdopendir_works to
69720         "guessing yes".
69721         * m4/floor.m4 (gl_FUNC_FLOOR): Require AC_CANONICAL_HOST. When cross-
69722         compiling to glibc systems, set gl_cv_func_floor_ieee to "guessing yes".
69723         * m4/floorf.m4 (gl_FUNC_FLOORF): Require AC_CANONICAL_HOST. When cross-
69724         compiling to glibc systems, set gl_cv_func_floorf_ieee to
69725         "guessing yes".
69726         * m4/fmod.m4 (gl_FUNC_FMOD): Require AC_CANONICAL_HOST. When cross-
69727         compiling to glibc systems, set gl_cv_func_fmod_ieee to "guessing yes".
69728         * m4/fmodf.m4 (gl_FUNC_FMODF): Require AC_CANONICAL_HOST. When cross-
69729         compiling to glibc systems, set gl_cv_func_fmodf_ieee to "guessing yes".
69730         * m4/fmodl.m4 (gl_FUNC_FMODL): Require AC_CANONICAL_HOST. When cross-
69731         compiling to glibc systems, set gl_cv_func_fmodl_ieee to "guessing yes".
69732         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Require AC_CANONICAL_HOST. When
69733         cross-compiling to glibc systems, set gl_cv_func_getgroups_works to
69734         "guessing yes".
69735         * m4/hypot.m4 (gl_FUNC_HYPOT): Require AC_CANONICAL_HOST. When cross-
69736         compiling to glibc systems, set gl_cv_func_hypot_ieee to "guessing yes".
69737         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Require AC_CANONICAL_HOST. When cross-
69738         compiling to glibc systems, set gl_cv_func_hypotf_ieee to
69739         "guessing yes".
69740         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Require AC_CANONICAL_HOST. When cross-
69741         compiling to glibc systems, set gl_cv_func_hypotl_ieee to
69742         "guessing yes".
69743         * m4/link.m4 (gl_FUNC_LINK): Require AC_CANONICAL_HOST. When cross-
69744         compiling to glibc systems, set gl_cv_func_link_works to "guessing yes".
69745         * m4/log.m4 (gl_FUNC_LOG): Require AC_CANONICAL_HOST. When cross-
69746         compiling to glibc systems, set gl_cv_func_log_ieee to "guessing yes".
69747         * m4/logf.m4 (gl_FUNC_LOGF): Require AC_CANONICAL_HOST. When cross-
69748         compiling to glibc systems, set gl_cv_func_logf_ieee to "guessing yes".
69749         * m4/log10.m4 (gl_FUNC_LOG10): Require AC_CANONICAL_HOST. When cross-
69750         compiling to glibc systems, set gl_cv_func_log10_ieee to "guessing yes".
69751         * m4/log10f.m4 (gl_FUNC_LOG10F): Require AC_CANONICAL_HOST. When cross-
69752         compiling to glibc systems, set gl_cv_func_log10f_ieee to
69753         "guessing yes".
69754         * m4/log1p.m4 (gl_FUNC_LOG1P): Require AC_CANONICAL_HOST. When cross-
69755         compiling to glibc systems, set gl_cv_func_log1p_ieee to "guessing yes".
69756         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Require AC_CANONICAL_HOST. When cross-
69757         compiling to glibc systems, set gl_cv_func_log1pf_ieee to
69758         "guessing yes".
69759         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Require AC_CANONICAL_HOST. When cross-
69760         compiling to glibc systems, set gl_cv_func_log1pl_ieee to
69761         "guessing yes".
69762         * m4/log2.m4 (gl_FUNC_LOG2): Require AC_CANONICAL_HOST. When cross-
69763         compiling to glibc systems, set gl_cv_func_log2_ieee to "guessing yes".
69764         * m4/log2f.m4 (gl_FUNC_LOG2F): Require AC_CANONICAL_HOST. When cross-
69765         compiling to glibc systems, set gl_cv_func_log2f_ieee to "guessing yes".
69766         * m4/mkdir.m4 (gl_FUNC_MKDIR): Require AC_CANONICAL_HOST. When cross-
69767         compiling to glibc systems, set gl_cv_func_mkdir_trailing_slash_works,
69768         gl_cv_func_mkdir_trailing_dot_works to "guessing yes".
69769         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Require AC_CANONICAL_HOST. When cross-
69770         compiling to glibc systems, set gl_cv_func_mkfifo_works to
69771         "guessing yes".
69772         * m4/mknod.m4 (gl_FUNC_MKNOD): Require AC_CANONICAL_HOST. When cross-
69773         compiling to glibc systems, set gl_cv_func_mknod_works to
69774         "guessing yes".
69775         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_CANONICAL_HOST. When
69776         cross-compiling to glibc systems, set gl_cv_func_working_mkstemp to
69777         "guessing yes".
69778         * m4/modf.m4 (gl_FUNC_MODF): Require AC_CANONICAL_HOST. When cross-
69779         compiling to glibc systems, set gl_cv_func_modf_ieee to "guessing yes".
69780         * m4/modff.m4 (gl_FUNC_MODFF): Require AC_CANONICAL_HOST. When cross-
69781         compiling to glibc systems, set gl_cv_func_modff_ieee to "guessing yes".
69782         * m4/modfl.m4 (gl_FUNC_MODFL): Require AC_CANONICAL_HOST. When cross-
69783         compiling to glibc systems, set gl_cv_func_modfl_ieee to "guessing yes".
69784         * m4/putenv.m4 (gl_FUNC_PUTENV): Require AC_CANONICAL_HOST. When cross-
69785         compiling to glibc systems, set gl_cv_func_svid_putenv to
69786         "guessing yes".
69787         * m4/readlink.m4 (gl_FUNC_READLINK): Require AC_CANONICAL_HOST. When
69788         cross-compiling to glibc systems, set gl_cv_func_readlink_works to
69789         "guessing yes".
69790         * m4/remainder.m4 (gl_FUNC_REMAINDER): Require AC_CANONICAL_HOST. When
69791         cross-compiling to glibc systems, set gl_cv_func_remainder_ieee to
69792         "guessing yes".
69793         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Require AC_CANONICAL_HOST.
69794         When cross-compiling to glibc systems, set gl_cv_func_remainderf_ieee
69795         to "guessing yes".
69796         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Require AC_CANONICAL_HOST.
69797         When cross-compiling to glibc systems, set gl_cv_func_remainderl_ieee
69798         to "guessing yes".
69799         * m4/rmdir.m4 (gl_FUNC_RMDIR): Require AC_CANONICAL_HOST. When cross-
69800         compiling to glibc systems, set gl_cv_func_rmdir_works to
69801         "guessing yes".
69802         * m4/unlink.m4 (gl_FUNC_UNLINK): Require AC_CANONICAL_HOST. When cross-
69803         compiling to glibc systems, set gl_cv_func_unlink_honors_slashes,
69804         gl_cv_func_unlink_parent_fails to "guessing yes".
69805         * m4/remove.m4 (gl_FUNC_REMOVE): Update.
69806         * m4/rename.m4 (gl_FUNC_RENAME): Require AC_CANONICAL_HOST. When cross-
69807         compiling to glibc systems, set gl_cv_func_rename_slash_dst_works,
69808         gl_cv_func_rename_slash_src_works, gl_cv_func_rename_link_works,
69809         gl_cv_func_rename_dest_works to "guessing yes".
69810         * m4/round.m4 (gl_FUNC_ROUND): Require AC_CANONICAL_HOST. When cross-
69811         compiling to glibc systems, set gl_cv_func_round_ieee to "guessing yes".
69812         * m4/roundf.m4 (gl_FUNC_ROUNDF): Require AC_CANONICAL_HOST. When cross-
69813         compiling to glibc systems, set gl_cv_func_roundf_ieee to
69814         "guessing yes".
69815         * m4/roundl.m4 (gl_FUNC_ROUNDL): Require AC_CANONICAL_HOST. When cross-
69816         compiling to glibc systems, set gl_cv_func_roundl_ieee to
69817         "guessing yes".
69818         * m4/setenv.m4 (gl_FUNC_SETENV): Require AC_CANONICAL_HOST. When cross-
69819         compiling to glibc systems, set gl_cv_func_setenv_works to
69820         "guessing yes".
69821         (gl_FUNC_UNSETENV): Require AC_CANONICAL_HOST. When cross-
69822         compiling to glibc systems, set gl_cv_func_unsetenv_works to
69823         "guessing yes".
69824         * m4/sleep.m4 (gl_FUNC_SLEEP): Require AC_CANONICAL_HOST. When cross-
69825         compiling to glibc systems, set gl_cv_func_sleep_works to
69826         "guessing yes".
69827         * m4/stat.m4 (gl_FUNC_STAT): Require AC_CANONICAL_HOST. When cross-
69828         compiling to glibc systems, set gl_cv_func_stat_file_slash to
69829         "guessing yes".
69830         * m4/symlink.m4 (gl_FUNC_SYMLINK): Require AC_CANONICAL_HOST. When
69831         cross-compiling to glibc systems, set gl_cv_func_symlink_works to
69832         "guessing yes".
69833         * m4/trunc.m4 (gl_FUNC_TRUNC): Require AC_CANONICAL_HOST. When cross-
69834         compiling to glibc systems, set gl_cv_func_trunc_ieee to "guessing yes".
69835         * m4/truncf.m4 (gl_FUNC_TRUNCF): Require AC_CANONICAL_HOST. When cross-
69836         compiling to glibc systems, set gl_cv_func_truncf_ieee to
69837         "guessing yes".
69838         * m4/truncl.m4 (gl_FUNC_TRUNCL): Require AC_CANONICAL_HOST. When cross-
69839         compiling to glibc systems, set gl_cv_func_truncl_ieee to
69840         "guessing yes".
69841         * m4/usleep.m4 (gl_FUNC_USLEEP): Require AC_CANONICAL_HOST. When cross-
69842         compiling to glibc systems, set gl_cv_func_usleep_works to
69843         "guessing yes".
69844         * m4/utimens.m4 (gl_UTIMENS): Require AC_CANONICAL_HOST. When cross-
69845         compiling to glibc systems, set gl_cv_func_futimesat_works to
69846         "guessing yes".
69848 2012-05-03  Bruno Haible  <bruno@clisp.org>
69850         Say "guessing yes" or "guessing no" when cross-compiling.
69851         * m4/dup2.m4 (gl_FUNC_DUP2): When cross-compiling, set
69852         gl_cv_func_dup2_works to "guessing yes" or "guessing no".
69853         * m4/getdelim.m4 (gl_FUNC_GETDELIM): When cross-compiling, set
69854         gl_cv_func_working_getdelim to "guessing yes" or "guessing no".
69855         * m4/getline.m4 (gl_FUNC_GETLINE): When cross-compiling, set
69856         am_cv_func_working_getline to "guessing yes" or "guessing no".
69857         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): When cross-compiling, set
69858         gl_cv_func_memmem_works_always to "guessing yes" or "guessing no".
69859         (gl_FUNC_MEMMEM): When cross-compiling, set
69860         gl_cv_func_memmem_works_fast to "guessing yes" or "guessing no".
69861         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): When cross-compiling, set
69862         gl_cv_func_stpncpy to "guessing yes" or "guessing no".
69863         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): When cross-compiling,
69864         set gl_cv_func_strcasestr_works_always to "guessing yes" or
69865         "guessing no".
69866         (gl_FUNC_STRCASESTR): When cross-compiling, set
69867         gl_cv_func_strcasestr_linear to "guessing yes" or "guessing no".
69868         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): When cross-compiling, set
69869         gl_cv_func_strstr_works_always to "guessing yes" or "guessing no".
69870         (gl_FUNC_STRSTR): When cross-compiling, set
69871         gl_cv_func_strstr_linear to "guessing yes" or "guessing no".
69872         * m4/strtod.m4 (gl_FUNC_STRTOD): When cross-compiling, set
69873         gl_cv_func_strtod_works to "guessing yes" or "guessing no".
69874         * m4/wctype_h.m4 (gl_WCTYPE_H): When cross-compiling, set
69875         gl_cv_func_iswcntrl_works to "guessing yes" or "guessing no".
69877 2012-05-01  Bruno Haible  <bruno@clisp.org>
69879         relocatable-prog: Enable ELF ORIGIN trick also on GNU/kFreeBSD.
69880         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Treat kFreeBSD like Linux.
69881         * build-aux/reloc-ldflags: Likewise.
69882         Suggested by Steven Chamberlain <steven@pyro.eu.org>.
69884 2012-05-01  Bruno Haible  <bruno@clisp.org>
69886         gnulib-tool: Remove transitional code.
69887         * gnulib-tool: Don't warn about --import with 0 arguments any more.
69888         Reported by Dmitriy Selyutin <ghostman.sd@gmail.com>.
69890 2012-05-01  Bruno Haible  <bruno@clisp.org>
69892         getcwd: Fix misindentation.
69893         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Fix indentation.
69895 2012-04-29  Paul Eggert  <eggert@cs.ucla.edu>
69897         exclude: process exclude and include directives in order
69898         This restores the pre-2009 behavior, and is part of a fix of a
69899         grep bug reported by Quentin Arce in
69900         <http://lists.gnu.org/r/bug-grep/2012-04/msg00056.html>.
69901         * lib/exclude.c (struct exclude): Remove 'tail' member.
69902         (new_exclude_segment): Prepend the new segment instead of appending.
69903         Return void, since that's now more convenient.
69904         (file_pattern_matches): Renamed from excluded_file_pattern_p.
69905         (file_name_matches): Renamed from excluded_file_name_p.
69906         (file_pattern_matches, file_name_matches):
69907         Return true if the pattern matches, not if it excludes.
69908         All callers changed.
69909         (excluded_file_name): Process the list in reverse order;
69910         since the list is now reversed this restores the pre-2009 behavior.
69911         (add_exclude): Adjust to new reversed-order list.  Use local var
69912         rather than macro, for clarity.
69913         * tests/test-exclude7.sh: Adjust to corrected behavior.
69915         exclude: handle wildcards with FNM_NOESCAPE and with trailing \
69916         * lib/exclude.c (unescape_pattern): Don't worry about unescaped [;
69917         it's not possible here.  Handle the case of \ at end of pattern
69918         without dumping core.
69919         (add_exclude): Do not unescape the pattern if FNM_NOESCAPE is used.
69921         _Noreturn: future-proof non-GNU and non-MSVC compilers
69922         * build-aux/snippet/_Noreturn.h (_Noreturn):
69923         * m4/gnulib-common.m4 (gl_COMMON_BODY):
69924         Do not define _Noreturn if __STDC_VERSION__ indicates this is
69925         C11 or later.  This is more likely to work with random future C
69926         compilers that are neither GNUish nor MSVCish.  See Vincent Lefevre in
69927         <http://lists.gnu.org/r/bug-gnulib/2012-04/msg00195.html>.
69929         exclude: handle wildcards with FNM_EXTMATCH
69930         * lib/exclude.c (fnmatch_pattern_has_wildcards): Also treat '+(',
69931         '+@', '!(' as wildcards, if FNM_EXTMATCH.  Make it clear in a
69932         comment that "has wildcards" really means "has or may have
69933         wildcards".  Simplify by avoiding the need to call strcspn.
69935 2012-04-29  Bruno Haible  <bruno@clisp.org>
69937         gnulib-tool: Fix list of authors.
69938         * gnulib-tool (func_version): Add Paul Eggert to list of authors.
69940 2012-04-26  Stefano Lattarini  <stefano.lattarini@gmail.com>
69942         bootstrap: support Automake-NG in $buildreq
69943         * bootstrap (check_versions): Handle automake and aclocal from
69944         Automake-NG specially.  They can be specified as respectively
69945         the "automake-ng" and "aclocal-ng" requirements.
69947 2012-04-25  Eric Blake  <eblake@redhat.com>
69949         bootstrap: only force latest Makefile.in.in for gettext module
69950         * build-aux/bootstrap (with_gettext): Only install latest
69951         Makefile.in.in for projects requesting bleeding edge gettext.
69953 2012-04-22  Bruno Haible  <bruno@clisp.org>
69955         doc: Mention reason for replacement on glibc/Linux systems.
69956         * doc/posix-functions/dprintf.texi: Mention the problem with special
69957         'long double' values.
69958         * doc/posix-functions/fprintf.texi: Likewise.
69959         * doc/posix-functions/printf.texi: Likewise.
69960         * doc/posix-functions/snprintf.texi: Likewise.
69961         * doc/posix-functions/sprintf.texi: Likewise.
69962         * doc/posix-functions/vdprintf.texi: Likewise.
69963         * doc/posix-functions/vfprintf.texi: Likewise.
69964         * doc/posix-functions/vprintf.texi: Likewise.
69965         * doc/posix-functions/vsnprintf.texi: Likewise.
69966         * doc/posix-functions/vsprintf.texi: Likewise.
69967         * doc/posix-functions/fcntl.texi: Add glibc/Linux to the list of
69968         platforms with F_DUPFD_CLOEXEC problems.
69969         * doc/posix-functions/glob.texi: Mention which platforms are affected
69970         by the problem with symbolic links.
69971         * doc/posix-functions/linkat.texi: Mention the problem with
69972         AT_SYMLINK_FOLLOW on Linux.
69974 2012-04-22  Bruno Haible  <bruno@clisp.org>
69976         pwrite: Don't replace on all platforms.
69977         * m4/pwrite.m4 (gl_FUNC_PWRITE): Fix syntax error in test program.
69979 2012-04-22  Bruno Haible  <bruno@clisp.org>
69981         rint* tests: Avoid gcc warnings.
69982         * tests/test-rint.c (INFINITY, NAN): Undefine before redefining.
69983         * tests/test-rintf.c (INFINITY, NAN): Likewise.
69984         * tests/test-rintl.c (INFINITY, NAN): Likewise.
69986 2012-04-21  Bruno Haible  <bruno@clisp.org>
69988         users.txt: Update.
69989         * users.txt: Add freedink, wdiff. Update URLs for projects that have
69990         switched from CVS to git, bzr, or svn.
69992 2012-04-21  Bruno Haible  <bruno@clisp.org>
69994         Large File Support for native Windows platforms.
69996         * m4/largefile.m4 (gl_LARGEFILE): New macro.
69997         * modules/largefile (configure.ac): Require gl_LARGEFILE.
69999         * lib/sys_types.in.h (off_t) [WINDOWS_64_BIT_OFF_T]: Define to a 64-bit
70000         type.
70001         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Set WINDOWS_64_BIT_OFF_T.
70002         * modules/sys_types (Makefile.am): Substitute WINDOWS_64_BIT_OFF_T.
70003         * doc/posix-headers/sys_types.texi: Mention the effect of the
70004         'largefile' module.
70006         * lib/fcntl.in.h: Add comments about off_t.
70007         * modules/fcntl-h (Depends-on): Add sys_types.
70009         * lib/unistd.in.h [WINDOWS_64_BIT_OFF_T]: Include <sys/types.h>.
70010         (ftruncate): Replace it if REPLACE_FTRUNCATE is 1.
70011         * m4/unistd_h.m4 (gl_UNISTD_H): Require gl_SYS_TYPES_H.
70012         (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_FTRUNCATE.
70013         * modules/unistd (Depends-on): Add sys_types.
70014         (Makefile.am): Substitute WINDOWS_64_BIT_OFF_T, REPLACE_FTRUNCATE.
70016         * lib/lseek.c (rpl_lseek) [_GL_WINDOWS_64_BIT_OFF_T]: Use _lseeki64
70017         instead of lseek.
70018         * m4/lseek.m4 (gl_FUNC_LSEEK): Require gl_SYS_TYPES_H. Set
70019         REPLACE_LSEEK if WINDOWS_64_BIT_OFF_T is 1.
70020         * modules/lseek (Depends-on): Add sys_types.
70022         * lib/ftruncate.c: Put under GPLv3+. Include <windows.h>,
70023         msvc-nothrow.h.
70024         (SetFileSize): New function.
70025         (ftruncate) [_GL_WINDOWS_64_BIT_OFF_T]: New implementation.
70026         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Set REPLACE_FTRUNCATE on Windows
70027         if Large File Support is requested.
70028         * modules/ftruncate (configure.ac): Consider REPLACE_FTRUNCATE.
70029         (Depends-on): Add sys_types, msvc-nothrow. Update conditions.
70031         * lib/stdio.in.h: Add comments about off_t.
70032         * modules/stdio (Depends-on): Add sys_types.
70034         * lib/ftello.c [_GL_WINDOWS_64_BIT_OFF_T]: Use _ftelli64 or ftello64
70035         instead of ftello.
70036         * m4/ftello.m4 (gl_FUNC_FTELLO): Require gl_SYS_TYPES_H. Set
70037         REPLACE_FTELLO if WINDOWS_64_BIT_OFF_T is 1.
70038         (gl_PREREQ_FTELLO): New macro.
70039         * modules/ftello (Depends-on): Add sys_types.
70040         (configure.ac): Incoke gl_PREREQ_FTELLO.
70042         * lib/fseeko.c [_GL_WINDOWS_64_BIT_OFF_T]: Use _fseeki64 or fseeko64
70043         instead of fseeko.
70044         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Require gl_SYS_TYPES_H. Set
70045         REPLACE_FSEEKO if WINDOWS_64_BIT_OFF_T is 1.
70046         (gl_PREREQ_FSEEKO): New macro.
70047         * modules/fseeko (Depends-on): Add sys_types.
70048         (configure.ac): Invoke gl_PREREQ_FSEEKO.
70050         * lib/sys_stat.in.h: Add comments about off_t.
70051         (stat, fstat) [WINDOWS_64_BIT_ST_SIZE]: Define to variants that use a
70052         64-bit integer for st_size in 'struct stat'.
70053         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Set WINDOWS_64_BIT_ST_SIZE.
70054         Define _GL_WINDOWS_64_BIT_ST_SIZE.
70055         * modules/sys_stat (Depends-on): Add sys_types.
70056         (Makefile.am): Substitute WINDOWS_64_BIT_ST_SIZE.
70058         * lib/stat.c (stat) [_GL_WINDOWS_64_BIT_ST_SIZE]: Define to _stati64
70059         instead of stat or _stat.
70061         * lib/fstat.c [_GL_WINDOWS_64_BIT_ST_SIZE]: Use _fstati64 and
70062         'struct _stati64' instead of fstat and 'struct stat'.
70063         * m4/fstat.m4 (gl_FUNC_FSTAT): Require gl_HEADER_SYS_STAT_H. Set
70064         REPLACE_FSTAT if WINDOWS_64_BIT_ST_SIZE is 1.
70066         Reported by Ray Satiro <raysatiro@yahoo.com>.
70068 2012-04-19  Eric Blake  <eblake@redhat.com>
70070         bootstrap: accommodate older libtool
70071         * build-aux/bootstrap (use_libtool): Cater to libtool 1.5.22.
70072         Reported by Daniel P. Berrange.
70074 2012-04-19  Jim Meyering  <meyering@redhat.com>
70076         announce-gen: avoid failure due to lack of Digest::SHA1
70077         Even with the preferred Digest::SHA available, this script
70078         would fail when the backup module, Digest::SHA1, was not installed.
70079         * build-aux/announce-gen: Quote the conditional use of "use".
70080         Reported by Reuben Thomas in:
70081         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30444
70083         bootstrap: don't let a user's CDPATH setting affect this script
70084         When CDPATH is set, cd will sometimes generate output.
70085         When "cd" is run in a subshell whose output matters, that
70086         surprising-to-some output can cause malfunction.
70087         Unsetting CDPATH turns off this shell "feature."
70088         * build-aux/bootstrap (CDPATH): Unset.
70089         Reported by Reuben Thomas in:
70090         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30435
70091         and inspired by his patch here:
70092         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30440
70094 2012-04-16  Akim Demaille  <akim@lrde.epita.fr>
70095         and Jim Meyering  <meyering@redhat.com>
70097         maint.mk: catch "see @xref{}" and similar
70098         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Also
70099         prohibit "See also @xref{", "Also see @pxref{", and similar.
70101 2012-04-16  Jim Meyering  <meyering@redhat.com>
70103         bootstrap: really use gnulib's po/Makefile.in.in
70104         * build-aux/bootstrap: Correct the source file name in previous change.
70105         Reported by Akim Demaille.
70107         configmake: correct minor inconsistency in Makefile rule
70108         * modules/configmake (Makefile.am): All other rules like this one
70109         run the final "mv -f ..." in the same backslash-continued command
70110         as the one that does everything else.  This one put the mv -f ...
70111         command on a separate, non-backslash-continued line.
70112         Make it like the others.
70114         bootstrap: use gnulib's po/Makefile.in.in, not the one from gettext
70115         * build-aux/bootstrap: Use gnulib's po/Makefile.in.in, not
70116         the one from gettext.  Reported by Akim Demaille.
70118 2012-04-16  Joel E. Denny  <joeldenny@joeldenny.org>
70120         Fix recursion of install-* into po directories.
70121         Bison's install-pdf bug reported by Hans Aberg at
70122         <http://lists.gnu.org/r/bug-bison/2011-05/msg00008.html>.
70123         * build-aux/po/Makefile.in.in (install-dvi, install-html)
70124         (install-info, install-pdf, install-ps): New targets.
70126 2012-04-16  Jim Meyering  <meyering@redhat.com>
70128         maint: avoid spurious "make sc_maint" failure
70129         * cfg.mk (exclude_file_name_regexp--sc_trailing_blank): Also
70130         exempt all *.class file names, for lib/javaversion.class.
70132 2012-04-15  Bruno Haible  <bruno@clisp.org>
70134         lseek: Make configure test independent of environment.
70135         * m4/lseek.m4 (gl_FUNC_LSEEK): Require AC_CANONICAL_HOST. On native
70136         Windows, we know that lseek() on pipes is broken; skip the runtime
70137         test.
70139 2012-04-14  Bruno Haible  <bruno@clisp.org>
70141         stat: Bypass buggy override in mingw64.
70142         * m4/stat.m4 (gl_FUNC_STAT): Update comments.
70143         * lib/stat.c (stat) [mingw64]: Define to _stat.
70144         * doc/posix-functions/stat.texi: Mention mingw64 bug.
70146 2012-04-14  Bruno Haible  <bruno@clisp.org>
70148         pathmax: Fix compilation error on MSVC 9.
70149         * modules/pathmax (Depends-on): Add unistd.
70151 2012-04-12  Paul Eggert  <eggert@cs.ucla.edu>
70153         README: document pointer comparison assumption
70154         * README (Portability guidelines): Document assumption about
70155         pointer comparisons, in response to a recent bug-gnulib comment by
70156         Jeffrey Kegler.
70158 2012-04-12  Bruno Haible  <bruno@clisp.org>
70160         Tests for module 'getrusage'.
70161         * modules/getrusage-tests: New file.
70162         * tests/test-getrusage.c: New file.
70164         New module 'getrusage'.
70165         * lib/sys_resource.in.h: Include arg-nonnull.h, c++defs.h,
70166         warn-on-use.h.
70167         (getrusage): New declaration.
70168         * lib/getrusage.c: New file.
70169         * m4/getrusage.m4: New file.
70170         * m4/sys_resource_h.m4 (gl_HEADER_SYS_RESOURCE): Test whether getrusage
70171         is declared.
70172         (gl_SYS_RESOURCE_H_DEFAULTS): Initialize GNULIB_GETRUSAGE,
70173         HAVE_GETRUSAGE.
70174         * modules/sys_resource (Depends-on): Add snippet/arg-nonnull,
70175         snippet/c++defs, snippet/warn-on-use.
70176         (Makefile.am): Update generation of sys/resource.h. Substitute
70177         GNULIB_GETRUSAGE, HAVE_GETRUSAGE.
70178         * modules/getrusage: New file.
70179         * doc/posix-functions/getrusage.texi: Mention the new module.
70181 2012-04-12  Bruno Haible  <bruno@clisp.org>
70183         Tests for module 'sys_resource'.
70184         * modules/sys_resource-tests: New file.
70185         * tests/test-sys_resource.c: New file.
70187         New module 'sys_resource'.
70188         * lib/sys_resource.in.h: New file.
70189         * m4/sys_resource_h.m4: New file.
70190         * modules/sys_resource: New file.
70191         * doc/posix-headers/sys_resource.texi: Mention the new module.
70193 2012-04-12  LRN  <lrn1986@gmail.com>  (tiny change)
70195         ioctl: Fix compilation error on mingw.
70196         * lib/ioctl.c: Include <windows.h>.
70197         Also reported by Ray Satiro <raysatiro@yahoo.com>.
70199 2012-04-04  Jim Meyering  <meyering@redhat.com>
70201         regex: correct #pragma guard expression
70202         * lib/regex.c: -Wsuggest-attribute=pure was introduced in gcc-4.6,
70203         not 4.3.  Correct its cpp guard expression.
70205 2012-04-04  Paul Eggert  <eggert@cs.ucla.edu>
70207         regex: remove unnecessary type punning
70208         Problem reported by Vladimir Serbinenko in
70209         <http://lists.gnu.org/r/bug-gnulib/2012-04/msg00006.html>.
70210         * lib/regex.h (struct re_pattern_buffer): Change the type of
70211         __REPB_PREFIX(buffer) from unsigned char * to struct re_dfa_t *.
70212         Fix comment to match code.
70213         * lib/regcomp.c (re_compile_fastmap, re_compile_fastmap_iter, regfree)
70214         (re_compile_internal, free_workarea_compile, analyze, lower_subexp)
70215         (parse, parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
70216         * lib/regexec.c (regexec, re_search_stub, re_search_internal)
70217         (set_regs):
70218         Omit no-longer-necessary casts.
70220 2012-04-03  Bruno Haible  <bruno@clisp.org>
70222         Tests for module 'ilogbl'.
70223         * modules/ilogbl-tests: New file.
70224         * tests/test-ilogbl.c: New file.
70226         New module 'ilogbl'.
70227         * lib/math.in.h (ilogbl): New declaration.
70228         * lib/ilogbl.c: New file.
70229         * m4/ilogbl.m4: New file.
70230         * m4/math_h.m4 (gl_MATH_H): Test whether ilogbl is declared.
70231         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ILOGBL, HAVE_ILOGBL.
70232         * modules/math (Makefile.am): Substitute GNULIB_ILOGBL, HAVE_ILOGBL.
70233         Split sed invocation, to avoid the limit of 100 substitutions of
70234         HP-UX 'sed'.
70235         * modules/ilogbl: New file.
70236         * tests/test-math-c++.cc: Check the declaration of ilogbl.
70237         * doc/posix-functions/ilogbl.texi: Mention the new module.
70239 2012-04-03  Bruno Haible  <bruno@clisp.org>
70241         Tests for module 'ilogbf'.
70242         * modules/ilogbf-tests: New file.
70243         * tests/test-ilogbf.c: New file.
70245         New module 'ilogbf'.
70246         * lib/math.in.h (ilogbf): New declaration.
70247         * lib/ilogbf.c: New file.
70248         * m4/ilogbf.m4: New file.
70249         * m4/math_h.m4 (gl_MATH_H): Test whether ilogbf is declared.
70250         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ILOGBF, HAVE_ILOGBF,
70251         REPLACE_ILOGBF.
70252         * modules/math (Makefile.am): Substitute GNULIB_ILOGBF, HAVE_ILOGBF,
70253         REPLACE_ILOGBF.
70254         * modules/ilogbf: New file.
70255         * tests/test-math-c++.cc: Check the declaration of ilogbf.
70256         * doc/posix-functions/ilogbf.texi: Mention the new module.
70258 2012-04-03  Bruno Haible  <bruno@clisp.org>
70260         Tests for module 'ilogb'.
70261         * modules/ilogb-tests: New file.
70262         * tests/test-ilogb.c: New file.
70263         * tests/test-ilogb.h: New file, based on tests/test-logb.h and
70264         tests/test-logb-ieee.h.
70266         New module 'ilogb'.
70267         * lib/math.in.h (ilogb): New declaration.
70268         * lib/ilogb.c: New file.
70269         * m4/ilogb.m4: New file.
70270         * m4/math_h.m4 (gl_MATH_H): Test whether ilogb is declared.
70271         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ILOGB, HAVE_ILOGB,
70272         REPLACE_ILOGB.
70273         * modules/math (Makefile.am): Substitute GNULIB_ILOGB, HAVE_ILOGB,
70274         REPLACE_ILOGB.
70275         * modules/ilogb: New file.
70276         * tests/test-math-c++.cc: Check the declaration of ilogb.
70277         * doc/posix-functions/ilogb.texi: Mention the new module.
70279 2012-04-03  Bruno Haible  <bruno@clisp.org>
70281         math: Provide FP_ILOGB0 and FP_ILOGBNAN.
70282         * lib/math.in.h (FP_ILOGB0, FP_ILOGBNAN): Define fallback.
70283         * tests/test-math.c: Check that FP_ILOGB0, FP_ILOGBNAN are defined.
70284         (main): Check their values.
70285         * doc/posix-headers/math.texi: Mention the FP_ILOGB0, FP_ILOGBNAN
70286         problem.
70288 2012-04-03  Bruno Haible  <bruno@clisp.org>
70290         Tests for module 'logbl-ieee'.
70291         * modules/logbl-ieee-tests: New file.
70292         * tests/test-logbl-ieee.c: New file.
70294         New module 'logbl-ieee'.
70295         * modules/logbl-ieee: New file.
70297         Tests for module 'logb-ieee'.
70298         * modules/logb-ieee-tests: New file.
70299         * tests/test-logb-ieee.c: New file.
70301         New module 'logb-ieee'.
70302         * modules/logb-ieee: New file.
70304         Tests for module 'logbf-ieee'.
70305         * modules/logbf-ieee-tests: New file.
70306         * tests/test-logbf-ieee.c: New file.
70307         * tests/test-logb-ieee.h: New file.
70309         New module 'logbf-ieee'.
70310         * modules/logbf-ieee: New file.
70312 2012-04-03  Bruno Haible  <bruno@clisp.org>
70314         Tests for module 'logbl'.
70315         * modules/logbl-tests: New file.
70316         * tests/test-logbl.c: New file.
70318         New module 'logbl'.
70319         * lib/math.in.h (logbl): New declaration.
70320         * lib/logbl.c: New file.
70321         * m4/logbl.m4: New file.
70322         * m4/math_h.m4 (gl_MATH_H): Test whether logbl is declared.
70323         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGBL, HAVE_LOGBL,
70324         REPLACE_LOGBL.
70325         * modules/math (Makefile.am): Substitute GNULIB_LOGBL, HAVE_LOGBL,
70326         REPLACE_LOGBL.
70327         * modules/logbl: New file.
70328         * tests/test-math-c++.cc: Check the declaration of logbl.
70329         * doc/posix-functions/logbl.texi: Mention the new module.
70331 2012-04-02  Bruno Haible  <bruno@clisp.org>
70333         Tests for module 'logbf'.
70334         * modules/logbf-tests: New file.
70335         * tests/test-logbf.c: New file.
70337         New module 'logbf'.
70338         * lib/math.in.h (logbf): New declaration.
70339         * lib/logbf.c: New file.
70340         * m4/logbf.m4: New file.
70341         * m4/math_h.m4 (gl_MATH_H): Test whether logbf is declared.
70342         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGBF, HAVE_LOGBF,
70343         REPLACE_LOGBF.
70344         * modules/math (Makefile.am): Substitute GNULIB_LOGBF, HAVE_LOGBF,
70345         REPLACE_LOGBF.
70346         * modules/logbf: New file.
70347         * tests/test-math-c++.cc: Check the declaration of logbf.
70348         * doc/posix-functions/logbf.texi: Mention the new module.
70350 2012-04-02  Bruno Haible  <bruno@clisp.org>
70352         logb tests: More tests.
70353         * tests/test-logb.h: New file, based on tests/test-logb.c and
70354         tests/test-frexp.h.
70355         * tests/test-logb.c: Include minus-zero.h, test-logb.h.
70356         (main): Just invoke test_function.
70357         * modules/logb-tests (Files): Add tests/test-logb.h,
70358         tests/minus-zero.h, tests/randomd.c.
70359         (Makefile.am): Add randomd.c to test_logb_SOURCES.
70361         logb: Provide replacement and workarounds.
70362         * lib/math.in.h (logb): Ensure declaration. Replace if REPLACE_LOGB
70363         is 1.
70364         * lib/logb.c: New file.
70365         * m4/logb.m4 (gl_FUNC_LOGB_WORKS): New macro.
70366         (gl_FUNC_LOGB): Invoke it. Set HAVE_LOGB, REPLACE_LOGB.
70367         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOGB.
70368         * modules/math (Makefile.am): Substitute REPLACE_LOGB.
70369         * modules/logb (Files): Add lib/logb.c.
70370         (Depends-on): Add isfinite, frexp, isnand.
70371         (configure.ac): Compile the replacement code logb.c if needed.
70372         * tests/test-math-c++.cc: Check the declaration of logb.
70373         * doc/posix-functions/logb.texi: Mention the replacement and the bug
70374         with subnormal numbers.
70376 2012-04-02  Bruno Haible  <bruno@clisp.org>
70378         log10* tests: Speed up.
70379         * tests/test-log10.h (test_function): Reduce amount of random numbers
70380         to test.
70382 2012-04-01  Bruno Haible  <bruno@clisp.org>
70384         logf-ieee: Fix test whether logf works.
70385         * m4/logf.m4 (gl_FUNC_LOGF): Fix typo in test program.
70387 2012-04-01  Bruno Haible  <bruno@clisp.org>
70389         log10l: Work around log10l-ieee test failure on IRIX 6.5.
70390         * lib/log10l.c: Include <float.h>
70391         (log10l): On IRIX, normalize the +Infinity value.
70392         * modules/log10l (Depends-on): Add 'float'.
70393         * doc/posix-functions/log10l.texi: Mention the IRIX problem with
70394         +Infinity.
70396         log10f-ieee: Work around test failure on NetBSD 5.1.
70397         * m4/log10f-ieee.m4: New file.
70398         * m4/log10f.m4 (gl_FUNC_LOG10F): If gl_FUNC_LOG10F_IEEE is present,
70399         test whether log10f works with a negative argument. Replace it if not.
70400         * lib/log10f.c (log10f): For negative arguments, return NaN.
70401         * modules/log10f-ieee (Files): Add m4/log10f-ieee.m4.
70402         (configure.ac): Invoke gl_FUNC_LOG10F_IEEE.
70403         * doc/posix-functions/log10f.texi: Mention the log10f-ieee module.
70405         log10f-ieee: Work around test failure on Solaris 9.
70406         * modules/log10f-ieee (Depends-on): Add log10-ieee.
70407         (configure.ac): Require gl_FUNC_LOG10F.
70409         log10-ieee: Work around test failure on NetBSD 5.1 and Solaris 11.
70410         * m4/log10-ieee.m4: New file.
70411         * m4/log10.m4 (gl_FUNC_LOG10): If gl_FUNC_LOG10_IEEE is present, test
70412         whether log10 works with a negative argument. Replace it if not.
70413         * lib/log10.c (log10): For negative arguments, return NaN.
70414         * modules/log10-ieee (Files): Add m4/log10-ieee.m4.
70415         (configure.ac): Invoke gl_FUNC_LOG10_IEEE.
70416         * doc/posix-functions/log10.texi: Mention the log10-ieee module.
70418         Tests for module 'log10l-ieee'.
70419         * modules/log10l-ieee-tests: New file.
70420         * tests/test-log10l-ieee.c: New file.
70422         New module 'log10l-ieee'.
70423         * modules/log10l-ieee: New file.
70425         Tests for module 'log10-ieee'.
70426         * modules/log10-ieee-tests: New file.
70427         * tests/test-log10-ieee.c: New file.
70429         New module 'log10-ieee'.
70430         * modules/log10-ieee: New file.
70432         Tests for module 'log10f-ieee'.
70433         * modules/log10f-ieee-tests: New file.
70434         * tests/test-log10f-ieee.c: New file.
70435         * tests/test-log10-ieee.h: New file.
70437         New module 'log10f-ieee'.
70438         * modules/log10f-ieee: New file.
70440 2012-04-01  Bruno Haible  <bruno@clisp.org>
70442         log10l: Work around AIX 5.1, IRIX 6.5, OSF/1 5.1 bug.
70443         * lib/math.in.h (log10l): Override if REPLACE_LOG10L is 1.
70444         * lib/log10l.c (log10l): If log10l exists, use it and provide just the
70445         workaround.
70446         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): New macro.
70447         (gl_FUNC_LOG10L): Invoke it. Set REPLACE_LOG10L.
70448         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG10L.
70449         * modules/math (Makefile.am): Substitute REPLACE_LOG10L.
70450         * modules/log10l (configure.ac): Consider REPLACE_LOG10L.
70451         (Depends-on): Update conditions.
70452         * doc/posix-functions/log10l.texi: Mention the MSVC9, AIX 5.1,
70453         IRIX 6.5, OSF/1 5.1 problems.
70455 2012-04-01  Bruno Haible  <bruno@clisp.org>
70457         log10f: Work around OSF/1 5.1 bug.
70458         * lib/math.in.h (log10f): Override if REPLACE_LOG10F is 1.
70459         * lib/log10f.c (log10f): If logf exists, use it and provide just the
70460         workaround.
70461         * m4/log10f.m4 (gl_FUNC_LOG10F_WORKS): New macro.
70462         (gl_FUNC_LOG10F): Invoke it. Set REPLACE_LOG10F.
70463         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG10F.
70464         * modules/math (Makefile.am): Substitute REPLACE_LOG10F.
70465         * modules/log10f (configure.ac): Consider REPLACE_LOG10F.
70466         (Depends-on): Update conditions.
70467         * doc/posix-functions/log10f.texi: Mention the OSF/1 5.1 problem.
70469 2012-04-01  Bruno Haible  <bruno@clisp.org>
70471         log10: Work around OSF/1 5.1 bug.
70472         * lib/math.in.h (log10): New declaration.
70473         * lib/log10.c: New file.
70474         * m4/log10.m4 (gl_FUNC_LOG10_WORKS): New macro.
70475         (gl_FUNC_LOG10): Invoke it. Set REPLACE_LOG10.
70476         * m4/math_h.m4 (gl_MATH_H): Test whether log10 is declared.
70477         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG10, REPLACE_LOG10.
70478         * modules/math (Makefile.am): Substitute GNULIB_LOG10, REPLACE_LOG10.
70479         * modules/log10 (Files): Add lib/log10.c.
70480         (Depends-on): Add math.
70481         (configure.ac): If REPLACE_LOG10 is 1, compile an override.
70482         * tests/test-math-c++.cc: Check the declaration of log10.
70483         * doc/posix-functions/log10.texi: Mention the OSF/1 5.1 problem.
70485 2012-03-31  Bruno Haible  <bruno@clisp.org>
70487         log10l tests: More tests.
70488         * modules/log10l-tests (Files): Add tests/test-log10l.h,
70489         tests/minus-zero.h, tests/randoml.c.
70490         (Makefile.am): Add randoml.c to test_log10l_SOURCES.
70491         * tests/test-log10l.c: Include <float.h>, minus-zero.h, test-log10l.h.
70492         (main): Invoke test_function.
70494         log10f tests: More tests.
70495         * modules/log10f-tests (Files): Add tests/test-log10.h,
70496         tests/minus-zero.h, tests/randomf.c.
70497         (Makefile.am): Add randomf.c to test_log10f_SOURCES.
70498         * tests/test-log10f.c: Include <float.h>, minus-zero.h, test-log10.h.
70499         (main): Invoke test_function.
70501         log10 tests: More tests.
70502         * tests/test-log10.h: New file.
70503         * modules/log10-tests (Files): Add tests/test-log10.h,
70504         tests/minus-zero.h, tests/randomd.c.
70505         (Makefile.am): Add randomd.c to test_log10_SOURCES.
70506         * tests/test-log10.c: Include <float.h>, minus-zero.h, test-log10.h.
70507         (main): Invoke test_function.
70509 2012-03-31  Simon Josefsson  <simon@josefsson.org>
70511         fflush: Fix syntax error.
70512         * lib/fflush.c: Include unused-parameter.h, needed for
70513         _GL_UNUSED_PARAMETER.
70514         * modules/fflush (Depends-on): Add snippet/unused-parameter.
70516 2012-03-30  Paul Eggert  <eggert@cs.ucla.edu>
70518         regex: pacify GCC when compiling GRUB
70519         * lib/regcomp.c (init_dfa): Make a pointer 'const', to avoid
70520         a diagnostic.  Reported by Vladimir Serbinenko in
70521         <http://lists.gnu.org/r/bug-gnulib/2012-03/msg00163.html>.
70523 2012-03-29  Eric Blake  <eblake@redhat.com>
70525         stdio: don't assume gets any more
70526         * m4/stdio_h.m4 (gl_STDIO_H, gl_STDIO_H_DEFAULTS): Drop gets
70527         support.
70528         * modules/stdio (Makefile.am): Likewise.
70529         * lib/stdio-read.c (gets): Likewise.
70530         * tests/test-stdio-c++.cc: Likewise.
70531         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Fix comment.
70532         * lib/stdio.in.h (gets): Make warning occur in more places.
70533         * doc/posix-functions/gets.texi (gets): Update documentation.
70534         Reported by Christer Solskogen.
70536         maint.mk: fix syntax checks without exclusions
70537         * top/maint.mk (_sc_search_regexp): Allow for empty variable.
70538         Reported by Daniel P. Berrange.
70540         strerror_r: avoid compiler warning
70541         * lib/strerror_r.c (strerror_r): Hoist extern declaration to top
70542         level.
70544         fflush: avoid compiler warning
70545         * lib/fflush.c (update_fpos_cache): Mark variables that are
70546         potentially unused.
70548 2012-03-25  Bruno Haible  <bruno@clisp.org>
70550         Tests for module 'localeconv'.
70551         * modules/localeconv-tests: New file.
70552         * tests/test-localeconv.c: New file.
70554         New module 'localeconv'.
70555         * lib/locale.in.h (localeconv): New declaration.
70556         * lib/localeconv.c: New file.
70557         * m4/localeconv.m4: New file.
70558         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize GNULIB_LOCALECONV,
70559         REPLACE_LOCALECONV.
70560         * modules/locale (Makefile.am): Substitute GNULIB_LOCALECONV,
70561         REPLACE_LOCALECONV.
70562         * modules/localeconv: New file.
70563         * modules/nl_langinfo (Depends-on): Add localeconv.
70564         * modules/human (Depends-on): Likewise.
70565         * doc/posix-functions/localeconv.texi: Mention the new module.
70567 2012-03-25  Bruno Haible  <bruno@clisp.org>
70569         locale: Provide a complete 'struct lconv'.
70570         * m4/locale_h.m4 (gl_LOCALE_H): Set REPLACE_STRUCT_LCONV to 1 if
70571         'struct lconv' does not contain int_p_cs_precedes.
70572         * tests/test-locale.c (main): Check that 'struct lconv' is complete.
70573         * doc/posix-headers/locale.texi: Update.
70575         locale: Provide a complete 'struct lconv' on Solaris 10, 11.
70576         * m4/locale_h.m4 (gl_LOCALE_H): On Solaris, define _LCONV_C99.
70577         * doc/posix-headers/locale.texi: Update.
70579         locale: Provide a working 'struct lconv'.
70580         * lib/locale.in.h (lconv): Override if REPLACE_STRUCT_LCONV is 1.
70581         * m4/locale_h.m4 (gl_LOCALE_H): Set REPLACE_STRUCT_LCONV to 1 if
70582         'struct lconv' does not even contain decimal_point.
70583         (gl_LOCALE_H_DEFAULTS): Initialize REPLACE_STRUCT_LCONV.
70584         * modules/locale (Makefile.am): Substitute REPLACE_STRUCT_LCONV.
70585         * tests/test-locale.c (main): Check that 'struct lconv' is complete.
70586         * doc/posix-headers/locale.texi: Mention the problems with
70587         'struct lconv'.
70588         Reported by Gianluigi Tiesi <sherpya@netfarm.it>.
70590 2012-03-24  Bruno Haible  <bruno@clisp.org>
70592         Enable common subexpression optimization in GCC.
70593         * lib/unitypes.in.h (_UC_ATTRIBUTE_CONST, _UC_ATTRIBUTE_PURE): New
70594         macros.
70595         * lib/unicase.in.h (uc_toupper, uc_tolower, uc_totitle): Declare with
70596         GCC attribute 'const'.
70597         (uc_locale_language): Declare with GCC attribute 'pure'.
70598         * lib/unicase/caseprop.h (uc_is_cased, uc_is_case_ignorable): Declare
70599         with GCC attribute 'const'.
70600         * lib/unictype.in.h (uc_is_general_category_withtable,
70601         uc_combining_class, uc_combining_class_name,
70602         uc_combining_class_long_name, uc_bidi_class_name,
70603         uc_bidi_category_name, uc_bidi_class_long_name, uc_bidi_class,
70604         uc_bidi_category, uc_is_bidi_class, uc_is_bidi_category,
70605         uc_decimal_value, uc_digit_value, uc_numeric_value,
70606         uc_joining_type_name, uc_joining_type_long_name, uc_joining_type,
70607         uc_joining_group_name, uc_joining_group, uc_is_property_*, uc_script,
70608         uc_block, uc_is_c_whitespace, uc_is_java_whitespace,
70609         uc_c_ident_category, uc_java_ident_category, uc_is_alnum, uc_is_alpha,
70610         uc_is_cntrl, uc_is_digit, uc_is_graph, uc_is_lower, uc_is_print,
70611         uc_is_punct, uc_is_space, uc_is_upper, uc_is_xdigit, uc_is_blank):
70612         Declare with GCC attribute 'const'.
70613         (uc_general_category_name, uc_general_category_long_name,
70614         uc_general_category_byname, uc_general_category,
70615         uc_is_general_category, uc_combining_class_byname,
70616         uc_bidi_class_byname, uc_bidi_category_byname, uc_joining_type_byname,
70617         uc_joining_group_byname, uc_script_byname, uc_is_script, uc_is_block):
70618         Declare with GCC attribute 'pure'.
70619         * lib/unigbrk.in.h (uc_graphemeclusterbreak_property,
70620         uc_is_grapheme_break, u8_grapheme_next, u16_grapheme_next,
70621         u32_grapheme_next, u8_grapheme_prev, u16_grapheme_prev,
70622         u32_grapheme_prev, lib/uniname.in.h (unicode_name_character): Declare
70623         with GCC attribute 'pure'.
70624         * lib/uninorm.in.h (uc_composition): Declare with GCC attribute
70625         'const'.
70626         (uninorm_decomposing_form): Declare with GCC attribute 'pure'.
70627         * lib/unistr.in.h (): Declare with GCC attribute 'const'.
70628         (u8_check, u16_check, u32_check, u8_mblen, u16_mblen, u32_mblen,
70629         u8_cmp, u16_cmp, u32_cmp, u8_cmp2, u16_cmp2, u32_cmp2, u8_chr, u16_chr,
70630         u32_chr, u8_mbsnlen, u16_mbsnlen, u32_mbsnlen, u8_strmblen,
70631         u16_strmblen, u32_strmblen, u8_strlen, u16_strlen, u32_strlen,
70632         u8_strnlen, u16_strnlen, u32_strnlen, u8_strcmp_gnu, u8_strcmp,
70633         u16_strcmp, u32_strcmp, u8_strncmp, u16_strncmp, u32_strncmp,
70634         u8_strchr, u16_strchr, u32_strchr, u8_strrchr, u16_strrchr,
70635         u32_strrchr, u8_strcspn, u16_strcspn, u32_strcspn, u8_strspn,
70636         u16_strspn, u32_strspn, u8_strpbrk, u16_strpbrk, u32_strpbrk,
70637         u8_strstr, u16_strstr, u32_strstr, u8_startswith, u16_startswith,
70638         u32_startswith, u8_endswith, u16_endswith, u32_endswith): Declare with
70639         GCC attribute 'pure'.
70640         * lib/uniwbrk.in.h (uc_wordbreak_property): Declare with GCC attribute
70641         'const'.
70642         * lib/uniwidth.in.h (uc_width): Simplify declaration.
70643         (u8_width, u16_width, u32_width, u8_strwidth, u16_strwidth,
70644         u32_strwidth): Declare with GCC attribute 'pure'.
70646         Enable common subexpression optimization in GCC.
70647         * lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
70648         (alphasort): Declare with GCC attribute 'pure'.
70649         * lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
70650         (atoll): Declare with GCC attribute 'pure'.
70651         * lib/string.in.h (mbslen, mbsnlen, mbschr, mbsrchr, mbsstr,
70652         mbscasecmp, mbsncasecmp, mbspcasecmp, mbscasestr, mbscspn, mbspbrk,
70653         mbsspn, strverscmp): Declare with GCC attribute 'pure'.
70654         * lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
70655         (btowc, wctob, wcwidth, wmemchr, wmemcmp, wcslen, wcsnlen, wcscmp,
70656         wcsncmp, wcscasecmp, wcsncasecmp, wcschr, wcsrchr, wcscspn, wcsspn,
70657         wcspbrk, wcsstr, wcswidth): Declare with GCC attribute 'pure'.
70659 2012-03-24  Bruno Haible  <bruno@clisp.org>
70661         gnulib-tool: Avoid unintended error output from 'cmp'.
70662         * gnulib-tool (func_add_file, func_update_file, func_import): Use
70663         "cmp -s", not "cmp > /dev/null".
70665 2012-03-23  Stefano Lattarini  <stefano.lattarini@gmail.com>
70667         gnulib-tool: fix imprecise comments w.r.t. an automake bug
70669         It's not just Automake versions < 1.9b that creates an empty
70670         pkgdatadir at installation time if pkgdata_DATA is specified
70671         to empty; modern automake versions do this as well, at least
70672         until automake 1.11.4 (not yet released at the moment of writing,
70673         but soon to appear).  That behaviour was generally considered a
70674         feature rather than a bug, at least until this discussion:
70675         <http://lists.gnu.org/r/automake/2012-03/msg00014.html>
70677         See also automake bugs #10997 and #11030.
70679         * gnulib-tool (func_emit_lib_Makefile_am): Adjust comments.  Add
70680         reference to relevant automake bug numbers.
70681         (func_emit_tests_Makefile_am): Likewise.
70683 2012-03-20  Reuben Thomas  <rrt@sc3d.org>
70685         announce-gen: use Digest::SHA when possible
70686         * build-aux/announce-gen: Use Digest::SHA when possible, falling
70687         back to Digest::SHA1 if necessary.
70689 2012-03-20  Jim Meyering  <meyering@redhat.com>
70691         tests: avoid gcc warnings about argv vs. const initializers
70692         * tests/test-posix_spawn1.c (main): Cast to "(char *)" to avoid two
70693         warnings about discarding 'const' qualifier from pointer target type.
70694         * tests/test-posix_spawn2.c (main): Likewise.
70696 2012-03-20  Reuben Thomas  <rrt@sc3d.org>
70698         README-release: simplify slightly
70699         * top/README-release: Run "git checkout master" only once.
70701 2012-03-15  Mark Wielaard  <mark@klomp.org>
70703         git-merge-changelog: add specific example on how to use with hg.
70704         * lib/git-merge-changelog.c: Add example on how to use in .hgrc.
70706 2012-03-18  Mark Wielaard  <mark@klomp.org>
70708         lib/git-merge-changelog.c (status): Report bugs to bug-gnulib@gnu.org.
70710 2012-03-18  Andreas Oberritter  <obi@opendreambox.org>
70712         git-version-gen: don't let "prefix" envvar cause trouble
70713         * build-aux/git-version-gen (prefix): Initialize properly,
70714         so as not to use a value specified via the environment.
70715         Details here: http://thread.gmane.org/gmane.comp.gnu.parted.bugs/10810
70717 2012-03-16  Paul Eggert  <eggert@cs.ucla.edu>
70719         regex: diagnose too-large repeat counts in EREs
70720         Previously, the code did not diagnose the too-large repeat count
70721         in EREs like 'b{1000000000}'; instead, it silently treated the ERE
70722         as if it were 'b\{1000000000}', which is unexpected.
70723         * lib/regcomp.c (parse_dup_op): Fail with REG_ESIZE if a repeat count
70724         is too large.  REG_ESIZE is used nowhere else, and the diagnostic
70725         is a reasonable one for this problem.  Another option would be to
70726         create a new REG_OVERFLOW error for repeat counts that are too large.
70727         (fetch_number): Return RE_DUP_MAX + 1, not REG_ERROR, if the repeat
70728         count is too large, so that the caller can distinguish the two cases.
70729         * lib/regex.h (_REG_ESIZE): Document that this is now a generic
70730         "Too large" return code, and that repeat counts are one example of this.
70732 2012-03-16  Paul Eggert  <eggert@cs.ucla.edu>
70734         doc: some glibc x32 integer width issues
70735         * doc/posix-headers/sys_types.texi (sys/types.h):
70736         * doc/posix-headers/time.texi (time.h):
70737         Mention that glibc x32 does not conform to POSIX in a couple of
70738         areas related to integer widths.
70740 2012-03-15  Bruno Haible  <bruno@clisp.org>
70742         fmal: Avoid test failure on OpenBSD 5.1/SPARC64.
70743         * lib/fma.c (VOLATILE): New macro.
70744         (FUNC): Use it to work around a GCC compiler bug.
70746 2012-03-13  Bruno Haible  <bruno@clisp.org>
70748         hypotl: Bypass broken implementation in OpenBSD 5.1/SPARC.
70749         * m4/hypotl.m4 (gl_FUNC_HYPOTL_WORKS): New macro.
70750         (gl_FUNC_HYPOTL): Invoke it. If the function does not work, set
70751         REPLACE_HYPOTL to 1.
70752         * doc/posix-functions/hypotl.texi: Mention the OpenBSD 5.1/SPARC bug.
70754 2012-03-13  Bruno Haible  <bruno@clisp.org>
70756         remainderl: Bypass broken implementation in OpenBSD 5.1/SPARC.
70757         * m4/remainderl.m4 (gl_FUNC_REMAINDERL_WORKS): New macro.
70758         (gl_FUNC_REMAINDERL): Invoke it. If the function does not work, set
70759         REPLACE_REMAINDERL to 1.
70760         * doc/posix-functions/remainderl.texi: Mention the OpenBSD 5.1/SPARC
70761         bug.
70763 2012-03-13  Bruno Haible  <bruno@clisp.org>
70765         sqrtl: Bypass broken implementation in OpenBSD 5.1/SPARC.
70766         * lib/math.in.h (sqrtl): Replace it if REPLACE_SQRTL is 1.
70767         * m4/sqrtl.m4 (gl_FUNC_SQRTL_WORKS): New macro.
70768         (gl_FUNC_SQRTL): Invoke it. Set REPLACE_SQRTL to 1 if sqrtl() produces
70769         too big rounding errors.
70770         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_SQRTL.
70771         * modules/math (Makefile.am): Substitute REPLACE_SQRTL.
70772         * modules/sqrtl (configure.ac): Consider REPLACE_SQRTL.
70773         (Depends-on): Update conditions.
70774         * tests/test-sqrtl.c (my_ldexpl): New function.
70775         (main): Add test of a particular value.
70776         * doc/posix-functions/sqrtl.texi: Mention the OpenBSD 5.1/SPARC bug.
70778 2012-03-13  Pádraig Brady  <P@draigBrady.com>
70780         doc: Update timer_* platform portability notes.
70781         * doc/posix-functions/timer_create.texi: Add platforms (OpenBSD 4.9)
70782         that always return ENOSYS.
70783         * doc/posix-functions/timer_delete.texi: Likewise.
70784         * doc/posix-functions/timer_gettime.texi: Likewise.
70785         * doc/posix-functions/timer_settime.texi: Likewise.
70787 2012-03-13  Bruno Haible  <bruno@clisp.org>
70789         cbrtl: Bypass broken implementation in OpenBSD 5.1/SPARC.
70790         * m4/cbrtl.m4 (gl_FUNC_CBRTL_WORKS): New macro.
70791         (gl_FUNC_CBRTL): Invoke it. If the function does not work, set
70792         REPLACE_CBRTL to 1.
70793         * doc/posix-functions/cbrtl.texi: Mention the OpenBSD 5.1/SPARC bug.
70795 2012-03-13  Bruno Haible  <bruno@clisp.org>
70797         remainderl: Avoid compilation error on AIX >= 5.2.
70798         * lib/math.in.h (remainderl): Undefine macro from the system header.
70800 2012-03-13  Bruno Haible  <bruno@clisp.org>
70802         Avoid compilation errors with MSVC option -fp:strict.
70803         * lib/cbrt.c: Use MSVC specific pragma fenv_access.
70804         * lib/cbrtf.c: Likewise.
70805         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
70807 2012-03-12  Bruno Haible  <bruno@clisp.org>
70809         uninorm: Don't crash in out-of-memory conditions.
70810         * lib/uninorm/u-normalize-internal.h (FUNC): Handle malloc() failure
70811         gracefully.
70812         * lib/uninorm/uninorm-filter.c (uninorm_filter_write): Likewise.
70813         Based on a report and patch by Stephen Gallagher <sgallagh@redhat.com>.
70815 2012-03-13  Akim Demaille  <akim@lrde.epita.fr>
70817         quote: fix syntax-check
70818         * top/maint.mk (sc_prohibit_quote_without_use): quote.h
70819         also exports quote_quoting_options.
70821 2012-03-12  Simon Josefsson  <simon@josefsson.org>
70823         Collapse list of copyright years to ranges.  See
70824         <https://lists.gnu.org/r/bug-gnulib/2012-03/msg00051.html>.
70825         * build-aux/bootstrap.conf, build-aux/csharpcomp.sh.in,
70826         build-aux/csharpexec.sh.in, build-aux/gnupload,
70827         build-aux/install-reloc, build-aux/javacomp.sh.in,
70828         build-aux/javaexec.sh.in, build-aux/ldd.sh.in,
70829         build-aux/move-if-change, build-aux/reloc-ldflags,
70830         build-aux/relocatable.sh.in, build-aux/x-to-1.in: Fix copyright.
70832 2012-03-11  Bruno Haible  <bruno@clisp.org>
70834         log2f-ieee: Work around test failure on NetBSD 5.1 and Solaris 10.
70835         * m4/log2f-ieee.m4: New file.
70836         * m4/log2f.m4 (gl_FUNC_LOG2F): If gl_FUNC_LOG2F_IEEE is present, test
70837         whether log2f works with a minus zero argument. Replace it if not.
70838         * modules/log2f-ieee (Files): Add m4/log2f-ieee.m4.
70839         (Depends-on): Add log2-ieee.
70840         (configure.ac): Invoke gl_FUNC_LOG2F_IEEE.
70841         * doc/posix-functions/log2f.texi: Mention the log2f-ieee module.
70843         log2-ieee: Work around test failure on NetBSD 5.1 and Solaris 10.
70844         * m4/log2-ieee.m4: New file.
70845         * m4/log2.m4 (gl_FUNC_LOG2): If gl_FUNC_LOG2_IEEE is present, test
70846         whether log2 works with a minus zero argument. Replace it if not.
70847         * modules/log2-ieee (Files): Add m4/log2-ieee.m4.
70848         (configure.ac): Invoke gl_FUNC_LOG2_IEEE.
70849         * doc/posix-functions/log2.texi: Mention the log2-ieee module.
70851         Tests for module 'log2l-ieee'.
70852         * modules/log2l-ieee-tests: New file.
70853         * tests/test-log2l-ieee.c: New file.
70855         New module 'log2l-ieee'.
70856         * modules/log2l-ieee: New file.
70858         Tests for module 'log2-ieee'.
70859         * modules/log2-ieee-tests: New file.
70860         * tests/test-log2-ieee.c: New file.
70862         New module 'log2-ieee'.
70863         * modules/log2-ieee: New file.
70865         Tests for module 'log2f-ieee'.
70866         * modules/log2f-ieee-tests: New file.
70867         * tests/test-log2f-ieee.c: New file.
70868         * tests/test-log2-ieee.h: New file.
70870         New module 'log2f-ieee'.
70871         * modules/log2f-ieee: New file.
70873 2012-03-11  Bruno Haible  <bruno@clisp.org>
70875         Tests for module 'log2l'.
70876         * modules/log2l-tests: New file.
70877         * tests/test-log2l.c: New file.
70879         New module 'log2l'.
70880         * lib/math.in.h (log2l): New declaration.
70881         * lib/log2l.c: New file.
70882         * m4/log2l.m4: New file.
70883         * m4/math_h.m4 (gl_MATH_H): Test whether log2l is declared.
70884         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG2L, HAVE_DECL_LOG2L,
70885         REPLACE_LOG2L.
70886         * modules/math (Makefile.am): Substitute GNULIB_LOG2L, HAVE_DECL_LOG2L,
70887         REPLACE_LOG2L.
70888         * modules/log2l: New file.
70889         * tests/test-math-c++.cc: Check the declaration of log2l.
70890         * doc/posix-functions/log2l.texi: Mention the new module and the IRIX
70891         and OSF/1 problems.
70893 2012-03-11  Bruno Haible  <bruno@clisp.org>
70895         Tests for module 'log2f'.
70896         * modules/log2f-tests: New file.
70897         * tests/test-log2f.c: New file.
70899         New module 'log2f'.
70900         * lib/math.in.h (log2f): New declaration.
70901         * lib/log2f.c: New file.
70902         * m4/log2f.m4: New file.
70903         * m4/math_h.m4 (gl_MATH_H): Test whether log2f is declared.
70904         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG2F, HAVE_DECL_LOG2F,
70905         REPLACE_LOG2F.
70906         * modules/math (Makefile.am): Substitute GNULIB_LOG2F, HAVE_DECL_LOG2F,
70907         REPLACE_LOG2F.
70908         * modules/log2f: New file.
70909         * tests/test-math-c++.cc: Check the declaration of log2f.
70910         * doc/posix-functions/log2f.texi: Mention the new module and the IRIX
70911         and OSF/1 and Cygwin problems.
70913 2012-03-11  Bruno Haible  <bruno@clisp.org>
70915         Tests for module 'log2'.
70916         * modules/log2-tests: New file.
70917         * tests/test-log2.c: New file.
70918         * tests/test-log2.h: New file.
70920         New module 'log2'.
70921         * lib/math.in.h (log2): New declaration.
70922         * lib/log2.c: New file.
70923         * m4/log2.m4: New file.
70924         * m4/math_h.m4 (gl_MATH_H): Test whether log2 is declared.
70925         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG2, HAVE_DECL_LOG2,
70926         REPLACE_LOG2.
70927         * modules/math (Makefile.am): Substitute GNULIB_LOG2, HAVE_DECL_LOG2,
70928         REPLACE_LOG2.
70929         * modules/log2: New file.
70930         * tests/test-math-c++.cc: Check the declaration of log2.
70931         * doc/posix-functions/log2.texi: Mention the new module and the IRIX
70932         and OSF/1 and Cygwin problems.
70934 2012-03-11  Bruno Haible  <bruno@clisp.org>
70936         exp2* tests: More tests.
70937         * tests/test-exp2.h (test_function): Test all integral arguments that
70938         don't need to overflow or denormalized numbers.
70939         * tests/test-exp2.c (MAX_EXP, MIN_EXP): New macros.
70940         * tests/test-exp2f.c (MAX_EXP, MIN_EXP): Likewise.
70941         * tests/test-exp2l.c (MAX_EXP, MIN_EXP): Likewise.
70943 2012-03-10  Bruno Haible  <bruno@clisp.org>
70945         log1pl-ieee: Work around test failure on AIX 7.1.
70946         * modules/log1pl-ieee (Depends-on): Add log1p-ieee.
70948         log1pl-ieee: Work around test failure on IRIX 6.5.
70949         * m4/log1pl-ieee.m4: New file.
70950         * m4/log1pl.m4 (gl_FUNC_LOG1PL): If gl_FUNC_LOG1PL_IEEE is present,
70951         test whether log1pl works with a minus zero argument. Replace it if
70952         not.
70953         * lib/math.in.h (log1pl): Override if REPLACE_LOG1PL is 1.
70954         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG1PL.
70955         * modules/math (Makefile.am): Substitute REPLACE_LOG1PL.
70956         * modules/log1pl (configure.ac): Consider REPLACE_LOG1PL.
70957         (Depends-on): Update conditions.
70958         * modules/log1pl-ieee (Files): Add m4/log1p-ieee.m4, m4/minus-zero.m4,
70959         m4/signbit.m4.
70960         (configure.ac): Invoke gl_FUNC_LOG1PL_IEEE.
70961         * doc/posix-functions/log1pl.texi: Mention the log1pl-ieee module.
70963         log1pf-ieee: Work around test failure on OpenBSD 4.9 and AIX 7.1.
70964         * m4/log1pf-ieee.m4: New file.
70965         * m4/log1pf.m4 (gl_FUNC_LOG1PF): If gl_FUNC_LOG1PF_IEEE is present,
70966         test whether log1pf works with a minus zero argument. Replace it if
70967         not.
70968         * modules/log1pf-ieee (Files): Add m4/log1pf-ieee.m4, m4/minus-zero.m4,
70969         m4/signbit.m4.
70970         (configure.ac): Invoke gl_FUNC_LOG1PF_IEEE.
70971         * doc/posix-functions/log1pf.texi: Mention the log1pf-ieee module.
70973         log1pf-ieee: Work around test failure on AIX 5.1 and HP-UX 11.
70974         * modules/log1pf-ieee (Depends-on): Add log1p-ieee.
70975         (configure.ac): Require gl_FUNC_LOG1PF.
70977         log1p-ieee: Work around test failure on AIX 7.1 and HP-UX 11.
70978         * m4/log1p-ieee.m4: New file.
70979         * m4/log1p.m4 (gl_FUNC_LOG1P): If gl_FUNC_LOG1P_IEEE is present, test
70980         whether log1p works with a minus zero argument. Replace it if not.
70981         * lib/math.in.h (log1p): Override if REPLACE_LOG1P is 1.
70982         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG1P.
70983         * modules/math (Makefile.am): Substitute REPLACE_LOG1P.
70984         * modules/log1p (configure.ac): Consider REPLACE_LOG1P.
70985         (Depends-on): Update conditions.
70986         * modules/log1p-ieee (Files): Add m4/log1p-ieee.m4, m4/minus-zero.m4,
70987         m4/signbit.m4.
70988         (configure.ac): Invoke gl_FUNC_LOG1P_IEEE.
70989         * doc/posix-functions/log1p.texi: Mention the log1p-ieee module.
70991         Tests for module 'log1pl-ieee'.
70992         * modules/log1pl-ieee-tests: New file.
70993         * tests/test-log1pl-ieee.c: New file.
70995         New module 'log1pl-ieee'.
70996         * modules/log1pl-ieee: New file.
70998         Tests for module 'log1p-ieee'.
70999         * modules/log1p-ieee-tests: New file.
71000         * tests/test-log1p-ieee.c: New file.
71002         New module 'log1p-ieee'.
71003         * modules/log1p-ieee: New file.
71005         Tests for module 'log1pf-ieee'.
71006         * modules/log1pf-ieee-tests: New file.
71007         * tests/test-log1pf-ieee.c: New file.
71008         * tests/test-log1p-ieee.h: New file.
71010         New module 'log1pf-ieee'.
71011         * modules/log1pf-ieee: New file.
71013 2012-03-10  Bruno Haible  <bruno@clisp.org>
71015         Tests for module 'log1pl'.
71016         * modules/log1pl-tests: New file.
71017         * tests/test-log1pl.c: New file.
71019         New module 'log1pl'.
71020         * lib/math.in.h (log1pl): New declaration.
71021         * lib/log1pl.c: New file.
71022         * m4/log1pl.m4: New file.
71023         * m4/math_h.m4 (gl_MATH_H): Test whether log1pl is declared.
71024         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG1PL, HAVE_LOG1PL.
71025         * modules/math (Makefile.am): Substitute GNULIB_LOG1PL, HAVE_LOG1PL.
71026         * modules/log1pl: New file.
71027         * tests/test-math-c++.cc: Check the declaration of log1pl.
71028         * doc/posix-functions/log1pl.texi: Mention the new module.
71030 2012-03-10  Bruno Haible  <bruno@clisp.org>
71032         Tests for module 'log1pf'.
71033         * modules/log1pf-tests: New file.
71034         * tests/test-log1pf.c: New file.
71036         New module 'log1pf'.
71037         * lib/math.in.h (log1pf): New declaration.
71038         * lib/log1pf.c: New file.
71039         * m4/log1pf.m4: New file.
71040         * m4/math_h.m4 (gl_MATH_H): Test whether log1pf is declared.
71041         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG1PF, HAVE_LOG1PF,
71042         REPLACE_LOG1PF.
71043         * modules/math (Makefile.am): Substitute GNULIB_LOG1PF, HAVE_LOG1PF,
71044         REPLACE_LOG1PF.
71045         * modules/log1pf: New file.
71046         * tests/test-math-c++.cc: Check the declaration of log1pf.
71047         * doc/posix-functions/log1pf.texi: Mention the new module.
71049 2012-03-10  Bruno Haible  <bruno@clisp.org>
71051         log1p tests: More tests.
71052         * tests/test-log1p.h: New file.
71053         * modules/log1p-tests (Files): Add tests/test-log1p.h, tests/randomd.c.
71054         (Makefile.am): Add randomd.c to test_log1p_SOURCES.
71055         * tests/test-log1p.c: Include <float.h> and test-log1p.h.
71056         (main): Invoke test_function.
71058         log1p: Provide replacement for Minix and MSVC.
71059         * lib/math.in.h (log1p): New declaration.
71060         * lib/log1p.c: New file.
71061         * m4/log1p.m4: New file.
71062         * m4/math_h.m4 (gl_MATH_H): Test whether log1p is declared.
71063         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG1P, HAVE_LOG1P.
71064         * modules/math (Makefile.am): Substitute GNULIB_LOG1P, HAVE_LOG1P.
71065         * modules/log1p (Files): Add lib/log1p.c, m4/log1p.m4.
71066         (Depends-on): Add math, isnand, log, round.
71067         (configure.ac): Invoke gl_FUNC_LOG1P. Arrange to compile replacement if
71068         HAVE_LOG1P is 0.
71069         * tests/test-math-c++.cc: Check the declaration of log1p.
71070         * doc/posix-functions/log1p.texi: Mention the replacement.
71072 2012-03-10  Bruno Haible  <bruno@clisp.org>
71074         math tests: Small simplification.
71075         * tests/test-exp.h (test_function): Use the same err_bound for
71076         'double' on platforms with sizeof (long double) == sizeof (double)
71077         than on platforms with sizeof (long double) > sizeof (double).
71078         * tests/test-exp2.h (test_function): Likewise.
71079         * tests/test-expm1.h (test_function): Likewise.
71080         * tests/test-log.h (test_function): Likewise.
71082 2012-03-10  Bruno Haible  <bruno@clisp.org>
71084         Fix some comments.
71085         * lib/expl.c: Fix an ambiguous comment.
71086         * lib/expm1.c: Likewise.
71087         * lib/expm1l.c: Likewise.
71088         * lib/exp2.c: Likewise.
71089         * lib/exp2l.c: Likewise.
71091 2012-03-10  Paul Eggert  <eggert@cs.ucla.edu>
71093         regex: allow inclusion of <regex.h> before <limits.h>
71094         Without this patch, portable programs had to include <limits.h> before
71095         <regex.h> if they wanted a consistent value for RE_DUP_MAX.
71096         I ran into this problem with a test version of GNU grep on Solaris 8.
71097         * lib/regex.h: Include <limits.h> if _REGEX_INCLUDE_LIMITS_H.
71098         This is done conditionally so that this change can be merged
71099         back to glibc.
71100         * m4/regex.m4 (gl_REGEX): Define _REGEX_INCLUDE_LIMITS_H if
71101         using the included regex.
71103         fts: depend on fdopendir
71104         * modules/fts (Depends-on): Depend on fdopendir.  This is needed
71105         on Solaris 8, at least, since it lacks fdopendir.  Evidently the
71106         problem was introduced when fdopendir was split out.
71108 2012-03-10  Bruno Haible  <bruno@clisp.org>
71110         Remove unused variables.
71111         * m4/fmodf.m4 (gl_FUNC_FMODF): Remove unused variable 'i'.
71112         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
71114 2012-03-10  Bruno Haible  <bruno@clisp.org>
71116         isnanf-nolibm: Fix last commit.
71117         * lib/isnanf-nolibm.h [IRIX]: Don't include <ieeefp.h>. Declare isnanf.
71119         isnanf-nolibm: Make it work on IRIX 6.5 with cc.
71120         * lib/isnanf-nolibm.h [IRIX]: Include <ieeefp.h>.
71122 2012-03-10  Bruno Haible  <bruno@clisp.org>
71124         logf-ieee: Work around test failure on NetBSD 5.1.
71125         * m4/logf-ieee.m4: New file.
71126         * m4/logf.m4 (gl_FUNC_LOGF): If gl_FUNC_LOGF_IEEE is present, test
71127         whether logf works with a negative argument. Replace it if not.
71128         * lib/logf.c (logf): For negative arguments, return NaN.
71129         * modules/logf-ieee (Files): Add m4/logf-ieee.m4.
71130         (configure.ac): Invoke gl_FUNC_LOGF_IEEE.
71131         * doc/posix-functions/logf.texi: Mention the logf-ieee module.
71133         logf-ieee: Work around test failure on Solaris 9.
71134         * modules/logf-ieee (Depends-on): Add log-ieee.
71135         (configure.ac): Require gl_FUNC_LOGF.
71137         log-ieee: Work around test failure on NetBSD 5.1 and Solaris 11.
71138         * m4/log-ieee.m4: New file.
71139         * m4/log.m4 (gl_FUNC_LOG): If gl_FUNC_LOG_IEEE is present, test whether
71140         log works with a negative argument. Replace it if not.
71141         * lib/log.c (log): For negative arguments, return NaN.
71142         * modules/log-ieee (Files): Add m4/log-ieee.m4.
71143         (configure.ac): Invoke gl_FUNC_LOG_IEEE.
71144         * doc/posix-functions/log.texi: Mention the log-ieee module.
71146         Tests for module 'logl-ieee'.
71147         * modules/logl-ieee-tests: New file.
71148         * tests/test-logl-ieee.c: New file.
71150         New module 'logl-ieee'.
71151         * modules/logl-ieee: New file.
71153         Tests for module 'log-ieee'.
71154         * modules/log-ieee-tests: New file.
71155         * tests/test-log-ieee.c: New file.
71157         New module 'log-ieee'.
71158         * modules/log-ieee: New file.
71160         Tests for module 'logf-ieee'.
71161         * modules/logf-ieee-tests: New file.
71162         * tests/test-logf-ieee.c: New file.
71163         * tests/test-log-ieee.h: New file.
71165         New module 'logf-ieee'.
71166         * modules/logf-ieee: New file.
71168 2012-03-10  Bruno Haible  <bruno@clisp.org>
71170         log: Fix bug introduced on 2012-03-09.
71171         * m4/log.m4 (gl_FUNC_LOG): Require gl_MATH_H_DEFAULTS.
71173 2012-03-10  Pádraig Brady  <P@draigBrady.com>
71175         timer-time: link explicitly with pthreads on glibc
71176         * m4/timer_time.m4 (LIB_TIMER_TIME): Add -lpthread
71177         to support static linking, when newer glibc is
71178         detected, as that contains pthread emulation of
71179         POSIX timer functions where required.
71180         * modules/timer-time: Depend on threadlib to
71181         pull in the appropriate library to link.
71183 2012-03-10  Bruno Haible  <bruno@clisp.org>
71185         log* tests: More tests.
71186         * tests/test-log.h: New file.
71187         * tests/test-log.c: Include <float.h>, minus-zero.h, test-log.h.
71188         (main): Invoke test_function.
71189         * tests/test-logf.c: Include <float.h>, minus-zero.h, test-log.h.
71190         (main): Invoke test_function.
71191         * tests/test-logl.c: Include <float.h>, minus-zero.h, test-log.h.
71192         (main): Invoke test_function.
71193         * modules/log-tests (Files): Add tests/test-log.h, tests/minus-zero.h,
71194         tests/randomd.c.
71195         (Makefile.am): Add randomd.c to test_log_SOURCES.
71196         * modules/logf-tests (Files): Add tests/test-log.h, tests/minus-zero.h,
71197         tests/randomf.c.
71198         (Makefile.am): Add randomf.c to test_logf_SOURCES.
71199         * modules/logl-tests (Files): Add tests/test-log.h, tests/minus-zero.h,
71200         tests/randoml.c.
71201         (Depends-on): Add 'float'.
71202         (Makefile.am): Add randoml.c to test_logl_SOURCES.
71204 2012-03-09  Bruno Haible  <bruno@clisp.org>
71206         logl: Work around OSF/1 5.1 bug.
71207         * lib/math.in.h (logl): Override if REPLACE_LOGL is 1.
71208         * lib/logl.c (logl): If logl exists, use it and provide just the
71209         workaround.
71210         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): New macro.
71211         (gl_FUNC_LOGL): Invoke it. Set REPLACE_LOGL.
71212         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOGL.
71213         * modules/math (Makefile.am): Substitute REPLACE_LOGL.
71214         * modules/logl (configure.ac): Consider REPLACE_LOGL.
71215         (Depends-on): Update conditions.
71216         * doc/posix-functions/logl.texi: Mention the OSF/1 5.1 problem.
71218 2012-03-09  Bruno Haible  <bruno@clisp.org>
71220         logf: Work around OSF/1 5.1 bug.
71221         * lib/math.in.h (logf): Override if REPLACE_LOGF is 1.
71222         * lib/logf.c (logf): If logf exists, use it and provide just the
71223         workaround.
71224         * m4/logf.m4 (gl_FUNC_LOGF_WORKS): New macro.
71225         (gl_FUNC_LOGF): Invoke it. Set REPLACE_LOGF.
71226         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOGF.
71227         * modules/math (Makefile.am): Substitute REPLACE_LOGF.
71228         * modules/logf (configure.ac): Consider REPLACE_LOGF.
71229         (Depends-on): Update conditions.
71230         * doc/posix-functions/logf.texi: Mention the OSF/1 5.1 problem.
71232 2012-03-09  Bruno Haible  <bruno@clisp.org>
71234         log: Work around OSF/1 5.1 bug.
71235         * lib/math.in.h (log): New declaration.
71236         * lib/log.c: New file.
71237         * m4/log.m4 (gl_FUNC_LOG_WORKS): New macro.
71238         (gl_FUNC_LOG): Invoke it. Set REPLACE_LOG.
71239         * m4/math_h.m4 (gl_MATH_H): Test whether log is declared.
71240         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG, REPLACE_LOG.
71241         * modules/math (Makefile.am): Substitute GNULIB_LOG, REPLACE_LOG.
71242         * modules/log (Files): Add lib/log.c.
71243         (Depends-on): Add math.
71244         (configure.ac): If REPLACE_LOG is 1, compile an override.
71245         * tests/test-math-c++.cc: Check the declaration of log.
71246         * doc/posix-functions/log.texi: Mention the OSF/1 5.1 problem.
71248 2012-03-09  Jim Meyering  <meyering@redhat.com>
71250         readtokens.c: adjust wording in a comment
71251         * lib/readtokens.c: Insert omitted "that" in a comment.
71253 2012-03-08  Paul Eggert  <eggert@cs.ucla.edu>
71255         modechange: add notations +40, 00440, etc.
71256         * lib/modechange.c (mode_compile): Support new notations
71257         +40, -40, =440, 00440.  See <http://debbugs.gnu.org/8391>.
71259 2012-03-08  Bruno Haible  <bruno@clisp.org>
71261         exp2l-ieee: Work around test failure on OpenBSD 4.9 and IRIX 6.5.
71262         * m4/exp2l-ieee.m4: New file.
71263         * m4/exp2l.m4 (gl_FUNC_EXP2L): If gl_FUNC_EXP2L_IEEE is present,
71264         test whether exp2l works with a NaN argument and with a negative
71265         infinity argument. Replace it if not.
71266         * lib/math.in.h (exp2l): Override if REPLACE_EXP2L is 1.
71267         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXP2L.
71268         * modules/math (Makefile.am): Substitute REPLACE_EXP2L.
71269         * modules/exp2l (configure.ac): Consider REPLACE_EXP2L.
71270         (Depends-on): Update conditions.
71271         * modules/exp2l-ieee (Files): Add m4/exp2l-ieee.m4.
71272         (configure.ac): Invoke gl_FUNC_EXP2L_IEEE.
71273         * doc/posix-functions/exp2l.texi: Mention the exp2l-ieee module.
71275         Tests for module 'exp2l-ieee'.
71276         * modules/exp2l-ieee-tests: New file.
71277         * tests/test-exp2l-ieee.c: New file.
71279         New module 'exp2l-ieee'.
71280         * modules/exp2l-ieee: New file.
71282         Tests for module 'exp2-ieee'.
71283         * modules/exp2-ieee-tests: New file.
71284         * tests/test-exp2-ieee.c: New file.
71286         New module 'exp2-ieee'.
71287         * modules/exp2-ieee: New file.
71289         Tests for module 'exp2f-ieee'.
71290         * modules/exp2f-ieee-tests: New file.
71291         * tests/test-exp2f-ieee.c: New file.
71292         * tests/test-exp2-ieee.h: New file.
71294         New module 'exp2f-ieee'.
71295         * modules/exp2f-ieee: New file.
71297 2012-03-08  Bruno Haible  <bruno@clisp.org>
71299         Tests for module 'exp2l'.
71300         * modules/exp2l-tests: New file.
71301         * tests/test-exp2l.c: New file.
71303         New module 'exp2l'.
71304         * lib/math.in.h (exp2l): New declaration.
71305         * lib/exp2l.c: New file.
71306         * lib/expl-table.c: New file, extracted from lib/expl.c.
71307         * lib/expl.c (gl_expl_table): New declaration.
71308         (expl): Remove expl_table. Update reference.
71309         * m4/exp2l.m4: New file.
71310         * m4/math_h.m4 (gl_MATH_H): Test whether exp2l is declared.
71311         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXP2L, HAVE_DECL_EXP2L.
71312         * modules/math (Makefile.am): Substitute GNULIB_EXP2L, HAVE_DECL_EXP2L.
71313         * modules/exp2l: New file.
71314         * modules/expl (Files): Add lib/expl-table.c.
71315         (configure.ac): Compile also expl-table.c.
71316         * tests/test-math-c++.cc: Check the declaration of exp2l.
71317         * doc/posix-functions/exp2l.texi: Mention the new module and the IRIX
71318         problem.
71320 2012-03-08  Bruno Haible  <bruno@clisp.org>
71322         Tests for module 'exp2f'.
71323         * modules/exp2f-tests: New file.
71324         * tests/test-exp2f.c: New file.
71326         New module 'exp2f'.
71327         * lib/math.in.h (exp2f): New declaration.
71328         * lib/exp2f.c: New file.
71329         * m4/exp2f.m4: New file.
71330         * m4/math_h.m4 (gl_MATH_H): Test whether exp2f is declared.
71331         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXP2F, HAVE_DECL_EXP2F.
71332         * modules/math (Makefile.am): Substitute GNULIB_EXP2F, HAVE_DECL_EXP2F.
71333         * modules/exp2f: New file.
71334         * tests/test-math-c++.cc: Check the declaration of exp2f.
71335         * doc/posix-functions/exp2f.texi: Mention the new module and the
71336         IRIX problem.
71338 2012-03-08  Bruno Haible  <bruno@clisp.org>
71340         Tests for module 'exp2'.
71341         * modules/exp2-tests: New file.
71342         * tests/test-exp2.c: New file.
71343         * tests/test-exp2.h: New file.
71345         New module 'exp2'.
71346         * lib/math.in.h (exp2): New declaration.
71347         * lib/exp2.c: New file.
71348         * m4/exp2.m4: New file.
71349         * m4/math_h.m4 (gl_MATH_H): Test whether exp2 is declared.
71350         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXP2, HAVE_DECL_EXP2,
71351         REPLACE_EXP2.
71352         * modules/math (Makefile.am): Substitute GNULIB_EXP2, HAVE_DECL_EXP2,
71353         REPLACE_EXP2.
71354         * modules/exp2: New file.
71355         * tests/test-math-c++.cc: Check the declaration of exp2.
71356         * doc/posix-functions/exp2.texi: Mention the new module and the IRIX
71357         and OpenBSD problems.
71359 2012-03-08  Paul Eggert  <eggert@cs.ucla.edu>
71361         savedir: fix comment typo
71362         * lib/savedir.c (savedirstream): Fix typo in comment.
71364 2012-03-08  Bruno Haible  <bruno@clisp.org>
71366         test-readtokens.c: use const; remove unwarranted cast
71367         * tests/test-readtokens.c: Declare delim to be const, to avoid a cast.
71369 2012-03-08  Bruno Haible  <bruno@clisp.org>
71371         fmal: Avoid compilation error on AIX.
71372         * lib/math.in.h (fmal): Undefine macro before declaration. Needed on
71373         AIX 5.2..7.1.
71375 2012-03-08  Bruno Haible  <bruno@clisp.org>
71377         fma, fmaf, fmal: Override undeclared system functions on IRIX 6.5.
71378         * m4/fma.m4 (gl_FUNC_FMA): If fma() exists but is not declared,
71379         arrange to set REPLACE_FMA=1, not HAVE_FMA=0.
71380         * m4/fmaf.m4 (gl_FUNC_FMAF): If fmaf() exists but is not declared,
71381         arrange to set REPLACE_FMAF=1, not HAVE_FMAF=0.
71382         * m4/fmal.m4 (gl_FUNC_FMAL): If fmal() exists but is not declared,
71383         arrange to set REPLACE_FMAL=1, not HAVE_FMAL=0.
71385 2012-03-08  Bruno Haible  <bruno@clisp.org>
71387         remainderf: Override buggy system function on IRIX 6.5.
71388         * m4/remainderf.m4 (gl_FUNC_REMAINDERF_WORKS): New macro.
71389         (gl_FUNC_REMAINDERF): Invoke it. Don't assume remainderf() is declared
71390         when it exists.
71391         * doc/posix-functions/remainderf.texi: Mention the IRIX problems.
71393 2012-03-08  Jim Meyering  <meyering@redhat.com>
71395         test-readtokens.c: avoid const-related compilation warnings
71396         * tests/test-readtokens.c: Avoid const-related compilation warnings.
71398 2012-03-07  Jim Meyering  <meyering@redhat.com>
71399             Bruno Haible  <bruno@clisp.org>
71401         frexp-nolibm, frexpl-nolibm tests: Fix bug introduced on 2012-03-03.
71402         * modules/frexp-nolibm-tests (Files): Add tests/test-frexp.h,
71403         tests/randomd.c.
71404         (Makefile.am): Add randomd.c to test_frexp_nolibm_SOURCES.
71405         * modules/frexpl-nolibm-tests (Files): Add tests/test-frexp.h,
71406         tests/randoml.c.
71407         (Makefile.am): Add randoml.c to test_frexpl_nolibm_SOURCES.
71409 2012-03-07  Bruno Haible  <bruno@clisp.org>
71411         expm1l: Avoid compilation error on AIX.
71412         * lib/math.in.h (expm1l): Undefine macro before declaration. Needed on
71413         AIX 5.2..7.1.
71415 2012-03-07  Bruno Haible  <bruno@clisp.org>
71417         expm1l: Don't override undeclared system function on IRIX 6.5.
71418         * lib/math.in.h (expm1l): Test HAVE_DECL_EXPM1L, not HAVE_EXPM1L.
71419         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Don't assume expm1l() is declared when
71420         it exists. Set HAVE_DECL_EXPM1L.
71421         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_EXPM1L, not
71422         HAVE_EXPM1L.
71423         * modules/math (Makefile.am): Substitute HAVE_DECL_EXPM1L, not
71424         HAVE_EXPM1L.
71425         * doc/posix-functions/expm1l.texi: Mention missing declaration problem.
71427 2012-03-07  Bruno Haible  <bruno@clisp.org>
71429         remainderl: Don't override undeclared system function on IRIX 6.5.
71430         * lib/math.in.h (remainderl): Test HAVE_DECL_REMAINDERL, not
71431         HAVE_REMAINDERL.
71432         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Don't assume remainderl() is
71433         declared when it exists. Set HAVE_DECL_REMAINDERL.
71434         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_REMAINDERL,
71435         not HAVE_REMAINDERL.
71436         * modules/math (Makefile.am): Substitute HAVE_DECL_REMAINDERL, not
71437         HAVE_REMAINDERL.
71438         * doc/posix-functions/remainderl.texi: Mention missing declaration
71439         problem.
71441 2012-03-07  Bruno Haible  <bruno@clisp.org>
71443         rintf: Don't override undeclared system function on IRIX 6.5.
71444         * lib/math.in.h (rintf): Test HAVE_DECL_RINTF, not HAVE_RINTF.
71445         * m4/rintf.m4 (gl_FUNC_RINTF): Don't assume rintf() is declared when it
71446         exists. Set HAVE_DECL_RINTF.
71447         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_RINTF, not
71448         HAVE_RINTF.
71449         * modules/math (Makefile.am): Substitute HAVE_DECL_RINTF, not
71450         HAVE_RINTF.
71451         * doc/posix-functions/rintf.texi: Mention missing declaration problem.
71453 2012-03-07  Bruno Haible  <bruno@clisp.org>
71455         roundl: Avoid compilation error on AIX.
71456         * lib/math.in.h (roundl): Undefine macro before declaration. Needed on
71457         AIX 5.2..7.1.
71459 2012-03-07  Bruno Haible  <bruno@clisp.org>
71461         roundl: Don't override undeclared system function on IRIX 6.5.
71462         * m4/roundl.m4 (gl_FUNC_ROUNDL): Search for roundl() in the libraries
71463         also when it is not declared. Set HAVE_ROUNDL. For replacement code,
71464         test HAVE_ROUNDL, not HAVE_DECL_ROUNDL.
71465         * modules/roundl (configure.ac): For replacement code, test
71466         HAVE_ROUNDL, not HAVE_DECL_ROUNDL.
71467         (Depends-on): Update conditions.
71468         * doc/posix-functions/roundl.texi: Mention the IRIX problem.
71470 2012-03-07  Bruno Haible  <bruno@clisp.org>
71472         roundf: Don't override undeclared system function on IRIX 6.5.
71473         * m4/roundf.m4 (gl_FUNC_ROUNDF): Search for roundf() in the libraries
71474         also when it is not declared. Set HAVE_ROUNDF. For replacement code,
71475         test HAVE_ROUNDF, not HAVE_DECL_ROUNDF.
71476         * modules/roundf (configure.ac): For replacement code, test
71477         HAVE_ROUNDF, not HAVE_DECL_ROUNDF.
71478         (Depends-on): Update conditions.
71479         * modules/roundf-ieee (Depends-on): Update conditions.
71480         * doc/posix-functions/roundf.texi: Mention the IRIX problem.
71482 2012-03-07  Bruno Haible  <bruno@clisp.org>
71484         round: Don't override undeclared system function on IRIX 6.5.
71485         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Accept an optional third
71486         argument.
71487         * m4/round.m4 (gl_FUNC_ROUND): Search for round() in the libraries
71488         also when it is not declared. Set HAVE_ROUND. For replacement code,
71489         test HAVE_ROUND, not HAVE_DECL_ROUND.
71490         * modules/round (configure.ac): For replacement code, test HAVE_ROUND,
71491         not HAVE_DECL_ROUND.
71492         (Depends-on): Update conditions.
71493         * modules/round-ieee (Depends-on): Update conditions.
71494         * doc/posix-functions/round.texi: Mention the IRIX problem.
71496 2012-03-07  Bruno Haible  <bruno@clisp.org>
71498         copysignf: Don't override undeclared system function on IRIX 6.5.
71499         * lib/math.in.h (copysignf): Test HAVE_DECL_COPYSIGNF, not
71500         HAVE_COPYSIGNF.
71501         * m4/copysignf.m4 (gl_FUNC_COPYSIGNF): Don't assume copysignf() is
71502         declared when it exists. Set HAVE_DECL_COPYSIGNF.
71503         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_COPYSIGNF,
71504         not HAVE_COPYSIGNF.
71505         * modules/math (Makefile.am): Substitute HAVE_DECL_COPYSIGNF, not
71506         HAVE_COPYSIGNF.
71507         * doc/posix-functions/copysignf.texi: Mention missing declaration
71508         problem.
71510 2012-03-07  Jim Meyering  <meyering@redhat.com>
71512         readtokens: add tests
71513         * modules/readtokens-tests: New file.
71514         * tests/test-readtokens.c: New file.
71516 2012-03-07  Jim Meyering  <meyering@redhat.com>
71518         quotearg: the module must now include quote.h
71519         With commit v0.0-7133-g6417476, quotearg.c includes "quote.h".
71520         So must the module.
71521         * modules/quotearg (Files): Add quote.h.
71523 2012-03-06  Paul Eggert  <eggert@cs.ucla.edu>
71525         readtokens: avoid core dumps with unusual calling patterns
71526         Reported by Xu Zhongxing in <http://debbugs.gnu.org/10953>.
71527         * lib/readtokens.c: Include limits.h.
71528         (word, bits_per_word, get_nth_bit, set_nth_bit): New.
71529         (readtoken): Don't cache the delimiters; the cache code was buggy
71530         if !delim && saved_delim, or if the new n_delim differs from the old.
71531         Also, it wasn't thread-safe.
71533 2012-03-07  Bruno Haible  <bruno@clisp.org>
71535         quote: Adhere to common module description layout.
71536         * modules/quote (Makefile.am): Add back empty section.
71538 2012-03-06  Akim Demaille  <demaille@gostai.com>
71540         quote: fuse into quotearg
71541         This patch is made for the benefit of Bison.
71542         quote does not leave the choice of the quoting style to the user.
71543         quoting_style provides poor customizability, yet quoting_options,
71544         which is very rich, is hidden inside quotearg.c.  So in order to
71545         allow quote customization, move its implementation to quotearg.c.
71546         * lib/quote.c: Remove.
71547         * modules/quote: Adjust.
71548         * lib/quotearg.c (quoting_options_from_style): Fix a compiler
71549         warning: provide all the members of literal structs.
71550         (quote_quoting_options): New.
71551         (quote, quote_n): Import implementation from quote.c.
71552         * lib/quote.h: Import the comments from quote.c.
71553         (quote_quoting_options): New.
71555 2012-03-06  Bruno Haible  <bruno@clisp.org>
71557         Tests for module 'expm1l-ieee'.
71558         * modules/expm1l-ieee-tests: New file.
71559         * tests/test-expm1l-ieee.c: New file.
71561         New module 'expm1l-ieee'.
71562         * modules/expm1l-ieee: New file.
71564         Tests for module 'expm1f-ieee'.
71565         * modules/expm1f-ieee-tests: New file.
71566         * tests/test-expm1f-ieee.c: New file.
71568         New module 'expm1f-ieee'.
71569         * modules/expm1f-ieee: New file.
71571         Tests for module 'expm1-ieee'.
71572         * modules/expm1-ieee-tests: New file.
71573         * tests/test-expm1-ieee.c: New file.
71574         * tests/test-expm1-ieee.h: New file.
71576         New module 'expm1-ieee'.
71577         * modules/expm1-ieee: New file.
71578         * m4/expm1-ieee.m4: New file.
71579         * m4/expm1.m4 (gl_FUNC_EXPM1): If gl_FUNC_EXPM1_IEEE is present, test
71580         whether expm1 works with a minus zero argument. Replace it if not.
71581         * lib/math.in.h (expm1): Override if REPLACE_EXPM1 is 1.
71582         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPM1.
71583         * modules/math (Makefile.am): Substitute REPLACE_EXPM1.
71584         * modules/expm1 (configure.ac): Consider REPLACE_EXPM1.
71585         (Depends-on): Update conditions.
71586         * doc/posix-functions/expm1.texi: Mention the expm1-ieee module and the
71587         AIX problem.
71589 2012-03-06  Bruno Haible  <bruno@clisp.org>
71591         Work around expm1f bug on IRIX 6.5.
71592         * lib/math.in.h (expm1f): Override if REPLACE_EXPM1F is 1.
71593         * m4/expm1f.m4 (gl_FUNC_EXPM1F_WORKS): New macro.
71594         (gl_FUNC_EXPM1F): Invoke it. Set REPLACE_EXPM1F to 1 if expm1f() does
71595         not work.
71596         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPM1F.
71597         * modules/math (Makefile.am): Substitute REPLACE_EXPM1F.
71598         * modules/expm1f (configure.ac): Consider REPLACE_EXPM1F.
71599         (Depends-on): Update conditions.
71600         * doc/posix-functions/expm1f.texi: Mention the IRIX 6.5 bug.
71602 2012-03-06  Bruno Haible  <bruno@clisp.org>
71604         Tests for module 'expm1l'.
71605         * modules/expm1l-tests: New file.
71606         * tests/test-expm1l.c: New file.
71608         New module 'expm1l'.
71609         * lib/math.in.h (expm1l): New declaration.
71610         * lib/expm1l.c: New file.
71611         * m4/expm1l.m4: New file.
71612         * m4/math_h.m4 (gl_MATH_H): Test whether expm1l is declared.
71613         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPM1L, HAVE_EXPM1L.
71614         * modules/math (Makefile.am): Substitute GNULIB_EXPM1L, HAVE_EXPM1L.
71615         * modules/expm1l: New file.
71616         * tests/test-math-c++.cc: Check the declaration of expm1l.
71617         * doc/posix-functions/expm1l.texi: Mention the new module.
71619 2012-03-06  Bruno Haible  <bruno@clisp.org>
71621         Tests for module 'expm1f'.
71622         * modules/expm1f-tests: New file.
71623         * tests/test-expm1f.c: New file.
71625         New module 'expm1f'.
71626         * lib/math.in.h (expm1f): New declaration.
71627         * lib/expm1f.c: New file.
71628         * m4/expm1f.m4: New file.
71629         * m4/math_h.m4 (gl_MATH_H): Test whether expm1f is declared.
71630         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPM1F, HAVE_EXPM1F.
71631         * modules/math (Makefile.am): Substitute GNULIB_EXPM1F, HAVE_EXPM1F.
71632         * modules/expm1f: New file.
71633         * tests/test-math-c++.cc: Check the declaration of expm1f.
71634         * doc/posix-functions/expm1f.texi: Mention the new module.
71636 2012-03-06  Bruno Haible  <bruno@clisp.org>
71638         Tests for module 'expm1'.
71639         * modules/expm1-tests: New file.
71640         * tests/test-expm1.c: New file.
71641         * tests/test-expm1.h: New file.
71643         New module 'expm1'.
71644         * lib/math.in.h (expm1): New declaration.
71645         * lib/expm1.c: New file.
71646         * m4/expm1.m4: New file.
71647         * m4/math_h.m4 (gl_MATH_H): Test whether expm1 is declared.
71648         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPM1, HAVE_EXPM1.
71649         * modules/math (Makefile.am): Substitute GNULIB_EXPM1, HAVE_EXPM1.
71650         * modules/expm1: New file.
71651         * tests/test-math-c++.cc: Check the declaration of expm1.
71652         * doc/posix-functions/expm1.texi: Mention the new module.
71654 2012-03-06  Bruno Haible  <bruno@clisp.org>
71656         math: Ensure declarations of math functions.
71657         * modules/acosf (Depends-on): Add 'extensions'.
71658         * modules/asinf (Depends-on): Likewise.
71659         * modules/atan2f (Depends-on): Likewise.
71660         * modules/atanf (Depends-on): Likewise.
71661         * modules/cbrt (Depends-on): Likewise.
71662         * modules/cbrtf (Depends-on): Likewise.
71663         * modules/cbrtl (Depends-on): Likewise.
71664         * modules/copysignf (Depends-on): Likewise.
71665         * modules/copysignl (Depends-on): Likewise.
71666         * modules/cosf (Depends-on): Likewise.
71667         * modules/coshf (Depends-on): Likewise.
71668         * modules/expf (Depends-on): Likewise.
71669         * modules/fabsf (Depends-on): Likewise.
71670         * modules/fabsl (Depends-on): Likewise.
71671         * modules/fmaf (Depends-on): Likewise.
71672         * modules/fmal (Depends-on): Likewise.
71673         * modules/fmodf (Depends-on): Likewise.
71674         * modules/fmodl (Depends-on): Likewise.
71675         * modules/frexpf (Depends-on): Likewise.
71676         * modules/frexpl (Depends-on): Likewise.
71677         * modules/hypot (Depends-on): Likewise.
71678         * modules/hypotf (Depends-on): Likewise.
71679         * modules/hypotl (Depends-on): Likewise.
71680         * modules/ldexpf (Depends-on): Likewise.
71681         * modules/ldexpl (Depends-on): Likewise.
71682         * modules/log10f (Depends-on): Likewise.
71683         * modules/log10l (Depends-on): Likewise.
71684         * modules/log1p (Depends-on): Likewise.
71685         * modules/logb (Depends-on): Likewise.
71686         * modules/logf (Depends-on): Likewise.
71687         * modules/modff (Depends-on): Likewise.
71688         * modules/modfl (Depends-on): Likewise.
71689         * modules/powf (Depends-on): Likewise.
71690         * modules/remainderf (Depends-on): Likewise.
71691         * modules/remainderl (Depends-on): Likewise.
71692         * modules/rintf (Depends-on): Likewise.
71693         * modules/rintl (Depends-on): Likewise.
71694         * modules/sinf (Depends-on): Likewise.
71695         * modules/sinhf (Depends-on): Likewise.
71696         * modules/sqrtf (Depends-on): Likewise.
71697         * modules/tanf (Depends-on): Likewise.
71698         * modules/tanhf (Depends-on): Likewise.
71699         * m4/acosf.m4 (gl_FUNC_ACOSF): Require gl_USE_SYSTEM_EXTENSIONS.
71700         * m4/asinf.m4 (gl_FUNC_ASINF): Likewise.
71701         * m4/atan2f.m4 (gl_FUNC_ATAN2F): Likewise.
71702         * m4/atanf.m4 (gl_FUNC_ATANF): Likewise.
71703         * m4/cbrt.m4 (gl_FUNC_CBRT): Likewise.
71704         * m4/cbrtf.m4 (gl_FUNC_CBRTF): Likewise.
71705         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Likewise.
71706         * m4/copysignf.m4 (gl_FUNC_COPYSIGNF): Likewise.
71707         * m4/copysignl.m4 (gl_FUNC_COPYSIGNL): Likewise.
71708         * m4/cosf.m4 (gl_FUNC_COSF): Likewise.
71709         * m4/coshf.m4 (gl_FUNC_COSHF): Likewise.
71710         * m4/expf.m4 (gl_FUNC_EXPF): Likewise.
71711         * m4/fabsf.m4 (gl_FUNC_FABSF): Likewise.
71712         * m4/fabsl.m4 (gl_FUNC_FABSL): Likewise.
71713         * m4/fmaf.m4 (gl_FUNC_FMAF): Likewise.
71714         * m4/fmal.m4 (gl_FUNC_FMAL): Likewise.
71715         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
71716         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
71717         * m4/frexpf.m4 (gl_FUNC_FREXPF): Likewise.
71718         * m4/frexpl.m4 (gl_FUNC_FREXPL): Likewise.
71719         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
71720         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
71721         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
71722         * m4/ldexpf.m4 (gl_FUNC_LDEXPF): Likewise.
71723         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Likewise.
71724         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
71725         * m4/log10l.m4 (gl_FUNC_LOF10L): Likewise.
71726         * m4/logb.m4 (gl_FUNC_LOGB): Likewise.
71727         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
71728         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
71729         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
71730         * m4/powf.m4 (gl_FUNC_POWF): Likewise.
71731         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
71732         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
71733         * m4/rintf.m4 (gl_FUNC_RINTF): Likewise.
71734         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
71735         * m4/sinf.m4 (gl_FUNC_SINF): Likewise.
71736         * m4/sinhf.m4 (gl_FUNC_SINHF): Likewise.
71737         * m4/sqrtf.m4 (gl_FUNC_SQRTF): Likewise.
71738         * m4/tanf.m4 (gl_FUNC_TANF): Likewise.
71739         * m4/tanhf.m4 (gl_FUNC_TANHF): Likewise.
71741 2012-03-06  Bruno Haible  <bruno@clisp.org>
71743         math: Update module names in warnings.
71744         * lib/math.in.h (acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl,
71745         tanl): Use specific module name in warn-on-use warning.
71747 2012-03-06  Bruno Haible  <bruno@clisp.org>
71749         expl: Simplify computation.
71750         * lib/expl.c (expl): Simplify computation of exp_y. Fix comment.
71752 2012-03-05  Bruno Haible  <bruno@clisp.org>
71754         exp* tests: More tests.
71755         * tests/test-exp.h: New file.
71756         * tests/test-exp.c: Include <float.h> and test-exp.h.
71757         (main): Invoke test_function.
71758         * tests/test-expf.c: Include <float.h> and test-exp.h.
71759         (main): Invoke test_function.
71760         * tests/test-expl.c: Include <float.h> and test-exp.h.
71761         (main): Invoke test_function.
71762         * modules/exp-tests (Files): Add tests/test-exp.h, tests/randomd.c.
71763         (Makefile.am): Add randomd.c to test_exp_SOURCES.
71764         * modules/expf-tests (Files): Add tests/test-exp.h, tests/randomf.c.
71765         (Makefile.am): Add randomf.c to test_expf_SOURCES.
71766         * modules/expl-tests (Files): Add tests/test-exp.h, tests/randoml.c.
71767         (Depends-on): Add 'float'.
71768         (Makefile.am): Add randoml.c to test_expl_SOURCES.
71770         expl: Fix precision of computed result.
71771         * lib/expl.c: Completely rewritten.
71772         * modules/expl (Depends-on): Add isnanl, roundl, ldexpl. Remove floorl.
71773         (Maintainer): Add me.
71774         * m4/expl.m4 (gl_FUNC_EXPL): Update computation of EXPL_LIBM.
71776 2012-03-05  Bruno Haible  <bruno@clisp.org>
71778         cbrt* tests: More tests.
71779         * tests/test-cbrt.h: New file.
71780         * tests/test-cbrt.c: Include <float.h> and test-cbrt.h.
71781         (main): Invoke test_function.
71782         * tests/test-cbrtf.c: Include <float.h> and test-cbrt.h.
71783         (main): Invoke test_function.
71784         * tests/test-cbrtl.c: Include <float.h> and test-cbrt.h.
71785         (main): Invoke test_function.
71786         * modules/cbrt-tests (Files): Add tests/test-cbrt.h, tests/randomd.c.
71787         (Makefile.am): Add randomd.c to test_cbrt_SOURCES.
71788         * modules/cbrtf-tests (Files): Add tests/test-cbrt.h, tests/randomf.c.
71789         (Makefile.am): Add randomf.c to test_cbrtf_SOURCES.
71790         * modules/cbrtl-tests (Files): Add tests/test-cbrt.h, tests/randoml.c.
71791         (Depends-on): Add 'float'.
71792         (Makefile.am): Add randoml.c to test_cbrtl_SOURCES.
71794 2012-03-05  Bruno Haible  <bruno@clisp.org>
71796         hypot* tests: More tests.
71797         * tests/test-hypot.h: New file, partially extracted from
71798         tests/test-hypotl.c.
71799         * tests/test-hypot.c: Include test-hypot.h.
71800         (main): Invoke test_function.
71801         * tests/test-hypotf.c: Include test-hypot.h.
71802         (main): Invoke test_function.
71803         * tests/test-hypotl.c: Include fpucw.h and test-hypot.h.
71804         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING and test_function.
71805         * modules/hypot-tests (Files): Add tests/test-hypot.h, tests/randomd.c.
71806         (Makefile.am): Add randomd.c to test_hypot_SOURCES.
71807         * modules/hypotf-tests (Files): Add tests/test-hypot.h,
71808         tests/randomf.c.
71809         (Makefile.am): Add randomf.c to test_hypotf_SOURCES.
71810         * modules/hypotl-tests (Files): Add tests/test-hypot.h,
71811         tests/randoml.c.
71812         (Depends-on): Add 'fpucw', 'float'.
71813         (Makefile.am): Add randoml.c to test_hypotl_SOURCES.
71815 2012-03-05  Bruno Haible  <bruno@clisp.org>
71817         fpucw: Doc about FreeBSD.
71818         * lib/fpucw.h: Mention FreeBSD in comments.
71820 2012-03-04  Bruno Haible  <bruno@clisp.org>
71822         sqrt* tests: More tests.
71823         * tests/test-sqrt.h: New file.
71824         * tests/test-sqrt.c: Include <float.h> and test-sqrt.h.
71825         (main): Invoke test_function.
71826         * tests/test-sqrtf.c: Include <float.h> and test-sqrt.h.
71827         (main): Invoke test_function.
71828         * tests/test-sqrtl.c: Include <float.h> and test-sqrt.h.
71829         (main): Invoke test_function.
71830         * modules/sqrt-tests (Files): Add tests/test-sqrt.h, tests/randomd.c.
71831         (Makefile.am): Add randomd.c to test_sqrt_SOURCES.
71832         * modules/sqrtf-tests (Files): Add tests/test-sqrt.h, tests/randomf.c.
71833         (Makefile.am): Add randomf.c to test_sqrtf_SOURCES.
71834         * modules/sqrtl-tests (Files): Add tests/test-sqrt.h, tests/randoml.c.
71835         (Depends-on): Add 'float'.
71836         (Makefile.am): Add randoml.c to test_sqrtl_SOURCES.
71838 2012-03-04  Bruno Haible  <bruno@clisp.org>
71840         remainder* tests: More tests.
71841         * tests/test-remainder.h: New file, based on tests/test-fmod.h.
71842         * tests/test-remainder.c: Include <float.h> and test-remainder.h.
71843         (main): Invoke test_function.
71844         * tests/test-remainderf.c: Include <float.h> and test-remainder.h.
71845         (main): Invoke test_function.
71846         * tests/test-remainderl.c: Include <float.h> and test-remainder.h.
71847         (main): Invoke test_function.
71848         * modules/remainder-tests (Files): Add tests/test-remainder.h,
71849         tests/randomd.c.
71850         (Makefile.am): Add randomd.c to test_remainder_SOURCES.
71851         * modules/remainderf-tests (Files): Add tests/test-remainder.h,
71852         tests/randomf.c.
71853         (Makefile.am): Add randomf.c to test_remainderf_SOURCES.
71854         * modules/remainderl-tests (Files): Add tests/test-remainder.h,
71855         tests/randoml.c.
71856         (Depends-on): Add 'float'.
71857         (Makefile.am): Add randoml.c to test_remainderl_SOURCES.
71859 2012-03-04  Bruno Haible  <bruno@clisp.org>
71861         remainder, remainderf, remainderl: Fix computation for large quotients.
71862         * lib/remainder.c: Completely rewritten.
71863         * lib/remainderf.c (remainderf): Use implementation of remainder.c with
71864         USE_FLOAT.
71865         * lib/remainderl.c (remainderl): Use implementation of remainder.c with
71866         USE_LONG_DOUBLE.
71867         * modules/remainder (Depends-on): Add isfinite, signbit, fabs, fmod,
71868         isnand, isinf. Remove round, fma.
71869         * modules/remainderf (Files): Add lib/remainder.c.
71870         (Depends-on): Add isfinite, signbit, fabsf, fmodf, isnanf, isinf.
71871         Remove roundf, fmaf.
71872         * modules/remainderl (Files): Add lib/remainder.c.
71873         (Depends-on): Add float, isfinite, signbit, fabsl, fmodl, isnanl,
71874         isinf. Remove roundl, fmal.
71875         * m4/remainder.m4 (gl_FUNC_REMAINDER): Update computation of
71876         REMAINDER_LIBM.
71877         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Update computation of
71878         REMAINDERF_LIBM.
71879         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Update computation of
71880         REMAINDERL_LIBM.
71882 2012-03-04  Bruno Haible  <bruno@clisp.org>
71884         fmod* tests: More tests.
71885         * tests/test-fmod.h (my_ldexp): New function.
71886         (test_function): Reduce amount of random numbers to test. Add tests
71887         of very large quotients x / y.
71888         * tests/test-fmod.c (MAX_EXP): New macro.
71889         * tests/test-fmodf.c (MAX_EXP): Likewise.
71890         * tests/test-fmodl.c (MAX_EXP): Likewise.
71892 2012-03-04  Bruno Haible  <bruno@clisp.org>
71894         fmod, fmodl: Fix computation for large quotients x / y.
71895         * lib/fmod.c: Completely rewritten.
71896         * lib/fmodl.c (fmodl): Use implementation of fmod.c with
71897         USE_LONG_DOUBLE.
71898         * modules/fmod (Depends-on): Add isfinite, signbit, fabs, frexp, ldexp,
71899         isnand. Remove fma.
71900         * modules/fmodl (Files): Add lib/fmod.c.
71901         (Depends-on): Add float, isfinite, signbit, fabsl,
71902         frexpl, ldexpl, isnanl. Remove fma.
71903         * m4/fmod.m4 (gl_FUNC_FMOD): Update computation of FMOD_LIBM.
71904         * m4/fmodl.m4 (gl_FUNC_FMODL): Update computation of FMODL_LIBM.
71906 2012-03-03  Bruno Haible  <bruno@clisp.org>
71908         fmod* tests: More tests.
71909         * tests/test-fmod.h: New file.
71910         * tests/test-fmod.c: Include <float.h> and test-fmod.h.
71911         (main): Invoke test_function.
71912         * tests/test-fmodf.c: Include <float.h> and test-fmod.h.
71913         (main): Invoke test_function.
71914         * tests/test-fmodl.c: Include <float.h> and test-fmod.h.
71915         (main): Invoke test_function.
71916         * modules/fmod-tests (Files): Add tests/test-fmod.h, tests/randomd.c.
71917         (Makefile.am): Add randomd.c to test_fmod_SOURCES.
71918         * modules/fmodf-tests (Files): Add tests/test-fmod.h, tests/randomf.c.
71919         (Makefile.am): Add randomf.c to test_fmodf_SOURCES.
71920         * modules/fmodl-tests (Files): Add tests/test-fmod.h, tests/randoml.c.
71921         (Depends-on): Add 'float'.
71922         (Makefile.am): Add randoml.c to test_fmodl_SOURCES.
71924 2012-03-03  Bruno Haible  <bruno@clisp.org>
71926         rint* tests: More tests.
71927         * tests/test-rint.h: New file, partially extracted from
71928         tests/test-rintl.c.
71929         * tests/test-rint.c: Include test-rint.h.
71930         (main): Invoke test_function.
71931         * tests/test-rintf.c: Include test-rint.h.
71932         (main): Invoke test_function.
71933         * tests/test-rintl.c: Include test-rint.h.
71934         (main): Invoke test_function.
71935         * modules/rint-tests (Files): Add tests/test-rint.h, tests/randomd.c.
71936         (Makefile.am): Add randomd.c to test_rint_SOURCES.
71937         * modules/rintf-tests (Files): Add tests/test-rint.h, tests/randomf.c.
71938         (Makefile.am): Add randomf.c to test_rintf_SOURCES.
71939         * modules/rintl-tests (Files): Add tests/test-rint.h, tests/randoml.c.
71940         (Makefile.am): Add randoml.c to test_rintl_SOURCES.
71942 2012-03-03  Bruno Haible  <bruno@clisp.org>
71944         modf* tests: More tests.
71945         * tests/test-modf.h: New file.
71946         * tests/test-modf.c: Include <float.h> and test-modf.h.
71947         (main): Invoke test_function.
71948         * tests/test-modff.c: Include <float.h> and test-modf.h.
71949         (main): Invoke test_function.
71950         * tests/test-modfl.c: Include <float.h> and test-modf.h.
71951         (main): Invoke test_function.
71952         * modules/modf-tests (Files): Add tests/test-modf.h, tests/randomd.c.
71953         (Makefile.am): Add randomd.c to test_modf_SOURCES.
71954         * modules/modff-tests (Files): Add tests/test-modf.h, tests/randomf.c.
71955         (Makefile.am): Add randomf.c to test_modff_SOURCES.
71956         * modules/modfl-tests (Files): Add tests/test-modf.h, tests/randoml.c.
71957         (Depends-on): Add 'float'.
71958         (Makefile.am): Add randoml.c to test_modfl_SOURCES.
71960 2012-03-03  Bruno Haible  <bruno@clisp.org>
71962         fabs* tests: More tests.
71963         * tests/test-fabs.h: New file, partially extracted from
71964         tests/test-fabsl.c.
71965         * tests/test-fabs.c (RANDOM): New macro.
71966         * tests/test-fabsf.c (RANDOM): New macro.
71967         * tests/test-fabsl.c (RANDOM): New macro.
71968         * modules/fabs-tests (Files): Add tests/randomd.c.
71969         (Makefile.am): Add randomd.c to test_fabs_SOURCES.
71970         * modules/fabsf-tests (Files): Add tests/randomf.c.
71971         (Makefile.am): Add randomf.c to test_fabsf_SOURCES.
71972         * modules/fabsl-tests (Files): Add tests/randoml.c.
71973         (Makefile.am): Add randoml.c to test_fabsl_SOURCES.
71975 2012-03-03  Bruno Haible  <bruno@clisp.org>
71977         ldexp* tests: More tests.
71978         * tests/test-ldexp.h (test_function): Add some pseudo-randomized tests.
71979         * tests/test-ldexp.c (RANDOM): New macro.
71980         * tests/test-ldexpf.c (RANDOM): New macro.
71981         * tests/test-ldexpl.c (RANDOM): New macro.
71982         * modules/ldexp-tests (Files): Add tests/randomd.c.
71983         (Makefile.am): Add randomd.c to test_ldexp_SOURCES.
71984         * modules/ldexpf-tests (Files): Add tests/randomf.c.
71985         (Makefile.am): Add randomf.c to test_ldexpf_SOURCES.
71986         * modules/ldexpl-tests (Files): Add tests/randoml.c.
71987         (Makefile.am): Add randoml.c to test_ldexpl_SOURCES.
71989 2012-03-03  Bruno Haible  <bruno@clisp.org>
71991         frexp* tests: More tests.
71992         * tests/test-frexp.h (test_function): Add some pseudo-randomized tests.
71993         * tests/test-frexp.c (RANDOM): New macro.
71994         * tests/test-frexpf.c (RANDOM): New macro.
71995         * tests/test-frexpl.c (RANDOM): New macro.
71996         * modules/frexp-tests (Files): Add tests/randomd.c.
71997         (Makefile.am): Add randomd.c to test_frexp_SOURCES.
71998         * modules/frexpf-tests (Files): Add tests/randomf.c.
71999         (Makefile.am): Add randomf.c to test_frexpf_SOURCES.
72000         * modules/frexpl-tests (Files): Add tests/randoml.c.
72001         (Makefile.am): Add randoml.c to test_frexpl_SOURCES.
72003 2012-03-03  Bruno Haible  <bruno@clisp.org>
72005         Support for pseudo-random numbers in tests.
72006         * tests/randomf.c: New file.
72007         * tests/randomd.c: New file.
72008         * tests/randoml.c: New file.
72009         * tests/macros.h (randomf, randomd, randoml): New declarations.
72011 2012-03-03  Bruno Haible  <bruno@clisp.org>
72013         frexp* tests: Refactor.
72014         * tests/test-frexp.h: New file, extracted from tests/test-frexpl.c.
72015         * tests/test-frexp.c: Include and use it.
72016         * tests/test-frexpf.c: Likewise.
72017         * tests/test-frexpl.c: Likewise.
72018         * modules/frexp-tests (Files): Add tests/test-frexp.h.
72019         * modules/frexpf-tests (Files): Likewise.
72020         * modules/frexpl-tests (Files): Likewise.
72022 2012-03-02  Jim Meyering  <meyering@redhat.com>
72024         maint: don't specify XZ_OPT=-9ev in dist-related rule
72025         Using xz's -9 option is warranted only if you have a very large
72026         tarball (see xz's documentation for the sizes vs. presets), and
72027         requires 64MiB of memory at decompression time.
72028         * top/maint.mk (alpha beta stable): Don't specify XZ_OPT=-9ev.
72029         Automake's default of just "-e" is fine.  Override on a
72030         per-package basis by setting XZ_OPT e.g., in cfg.mk.
72032 2012-03-01  Eric Blake  <eblake@redhat.com>
72034         maint.mk: allow announcement for non-gnulib project
72035         * maint.mk (announcement): Skip gnulib version if not used.
72037 2012-03-01  Jim Meyering  <meyering@redhat.com>
72039         maint.mk: avoid spurious failure of _sc_search_regexp-using tests
72040         * top/maint.mk: Initialize _sc_search_regexp parameters, so that
72041         envvar settings cannot interfere.  Otherwise, setting envvars like
72042         prohibit=foo require=bar, etc. would cause spurious test failures.
72044 2012-03-01  Eric Blake  <eblake@redhat.com>
72046         maint.mk: add per-line exclusions to prohibitions
72047         * maint.mk (_sc_search_regexp): Add $exclude parameter.
72048         (sc_prohibit_strcmp, sc_unmarked_diagnostics)
72049         (sc_const_long_option): Use it.
72051 2012-03-01  Bruno Haible  <bruno@clisp.org>
72053         Tests for module 'expl-ieee'.
72054         * modules/expl-ieee-tests: New file.
72055         * tests/test-expl-ieee.c: New file.
72057         New module 'expl-ieee'.
72058         * modules/expl-ieee: New file.
72060         Tests for module 'exp-ieee'.
72061         * modules/exp-ieee-tests: New file.
72062         * tests/test-exp-ieee.c: New file.
72064         New module 'exp-ieee'.
72065         * modules/exp-ieee: New file.
72067         Tests for module 'expf-ieee'.
72068         * modules/expf-ieee-tests: New file.
72069         * tests/test-expf-ieee.c: New file.
72070         * tests/test-exp-ieee.h: New file.
72072         New module 'expf-ieee'.
72073         * modules/expf-ieee: New file.
72075 2012-02-29  Bruno Haible  <bruno@clisp.org>
72077         cbrtl-ieee: Work around test failure on IRIX 6.5.
72078         * m4/cbrtl-ieee.m4: New file.
72079         * m4/cbrtl.m4 (gl_FUNC_CBRTL): If gl_FUNC_CBRTL_IEEE is present,
72080         test whether cbrtl works with a minus zero argument. Replace it if not.
72081         * lib/math.in.h (cbrtl): Override if REPLACE_CBRTL is 1.
72082         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_CBRTL.
72083         * modules/math (Makefile.am): Substitute REPLACE_CBRTL.
72084         * modules/cbrtl (configure.ac): Consider REPLACE_CBRTL.
72085         (Depends-on): Update conditions.
72086         * modules/cbrtl-ieee (Files): Add m4/cbrtl-ieee.m4, m4/minus-zero.m4,
72087         m4/signbit.m4.
72088         (configure.ac): Invoke gl_FUNC_CBRTL_IEEE.
72089         * lib/cbrtl.c (cbrtl) [IRIX]: Avoid an unnecessary addition.
72090         * doc/posix-functions/cbrtl.texi: Mention the cbrtl-ieee module.
72092         Tests for module 'cbrtl-ieee'.
72093         * modules/cbrtl-ieee-tests: New file.
72094         * tests/test-cbrtl-ieee.c: New file.
72096         New module 'cbrtl-ieee'.
72097         * modules/cbrtl-ieee: New file.
72099         Tests for module 'cbrt-ieee'.
72100         * modules/cbrt-ieee-tests: New file.
72101         * tests/test-cbrt-ieee.c: New file.
72103         New module 'cbrt-ieee'.
72104         * modules/cbrt-ieee: New file.
72106         Tests for module 'cbrtf-ieee'.
72107         * modules/cbrtf-ieee-tests: New file.
72108         * tests/test-cbrtf-ieee.c: New file.
72109         * tests/test-cbrt-ieee.h: New file.
72111         New module 'cbrtf-ieee'.
72112         * modules/cbrtf-ieee: New file.
72114 2012-02-29  Bruno Haible  <bruno@clisp.org>
72116         cbrtf: Work around bug in IRIX 6.5 system function.
72117         * lib/math.in.h (cbrtf): Override if REPLACE_CBRTF is 1.
72118         * m4/cbrtf.m4 (gl_FUNC_CBRTF_WORKS): New macro.
72119         (gl_FUNC_CBRTF): Invoke it. Set REPLACE_CBRTF to 1 if cbrtf() does not
72120         work.
72121         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_CBRTF.
72122         * modules/math (Makefile.am): Substitute REPLACE_CBRTF.
72123         * modules/cbrtf (configure.ac): Consider REPLACE_CBRTF.
72124         (Depends-on): Update conditions.
72125         * doc/posix-functions/cbrtf.texi: Mention the IRIX 6.5 problem.
72127 2012-02-29  Bruno Haible  <bruno@clisp.org>
72129         Tests for module 'cbrtl'.
72130         * modules/cbrtl-tests: New file.
72131         * tests/test-cbrtl.c: New file.
72133         New module 'cbrtl'.
72134         * lib/math.in.h (cbrtl): New declaration.
72135         * lib/cbrtl.c: New file.
72136         * m4/cbrtl.m4: New file.
72137         * m4/math_h.m4 (gl_MATH_H): Test whether cbrtl is declared.
72138         (gl_MATH_H_DEFAULTS): Initialize GNULIB_CBRTL, HAVE_CBRTL,
72139         HAVE_DECL_CBRTL.
72140         * modules/math (Makefile.am): Substitute GNULIB_CBRTL, HAVE_CBRTL,
72141         HAVE_DECL_CBRTL.
72142         * modules/cbrtl: New file.
72143         * tests/test-math-c++.cc: Check the declaration of cbrtl.
72144         * doc/posix-functions/cbrtl.texi: Mention the new module.
72146 2012-02-29  Bruno Haible  <bruno@clisp.org>
72148         Tests for module 'cbrtf'.
72149         * modules/cbrtf-tests: New file.
72150         * tests/test-cbrtf.c: New file.
72152         New module 'cbrtf'.
72153         * lib/math.in.h (cbrtf): New declaration.
72154         * lib/cbrtf.c: New file.
72155         * m4/cbrtf.m4: New file.
72156         * m4/math_h.m4 (gl_MATH_H): Test whether cbrtf is declared.
72157         (gl_MATH_H_DEFAULTS): Initialize GNULIB_CBRTF, HAVE_CBRTF,
72158         HAVE_DECL_CBRTF.
72159         * modules/math (Makefile.am): Substitute GNULIB_CBRTF, HAVE_CBRTF,
72160         HAVE_DECL_CBRTF.
72161         * modules/cbrtf: New file.
72162         * tests/test-math-c++.cc: Check the declaration of cbrtf.
72163         * doc/posix-functions/cbrtf.texi: Mention the new module.
72165 2012-02-29  Bruno Haible  <bruno@clisp.org>
72167         cbrt: Provide replacement on MSVC and Minix.
72168         * lib/math.in.h (cbrt): New declaration.
72169         * lib/cbrt.c: New file.
72170         * m4/cbrt.m4: New file.
72171         * m4/math_h.m4 (gl_MATH_H): Test whether cbrt is declared.
72172         (gl_MATH_H_DEFAULTS): Initialize GNULIB_CBRT, HAVE_CBRT.
72173         * modules/math (Makefile.am): Substitute GNULIB_CBRT, HAVE_CBRT.
72174         * modules/cbrt (Files): Add lib/cbrt.c, m4/cbrt.m4.
72175         (Depends-on): Add dependencies.
72176         (configure.ac): Arrange to compile replacement if HAVE_CBRT is 0.
72177         * tests/test-math-c++.cc: Check the declaration of cbrt.
72178         * doc/posix-functions/cbrt.texi: Mention that the module provides a
72179         replacement.
72181 2012-02-29  Bruno Haible  <bruno@clisp.org>
72183         hypotl-ieee: Work around test failure on OSF/1 and native Windows.
72184         * m4/hypotl-ieee.m4: New file.
72185         * m4/hypotl.m4 (gl_FUNC_HYPOTL): If gl_FUNC_HYPOTL_IEEE is present,
72186         test whether hypotl works with mixed NaN and Infinity arguments.
72187         Replace it if not.
72188         * lib/math.in.h (hypotl): Override if REPLACE_HYPOTL is 1.
72189         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_HYPOTL.
72190         * modules/math (Makefile.am): Substitute REPLACE_HYPOTL.
72191         * modules/hypotl (configure.ac): Consider REPLACE_HYPOTL.
72192         (Depends-on): Update conditions.
72193         * modules/hypotl-ieee (Files): Add m4/hypotl-ieee.m4.
72194         (Depends-on): Add hypot-ieee.
72195         (configure.ac): Invoke gl_FUNC_HYPOTL_IEEE.
72196         * doc/posix-functions/hypotl.texi: Mention the hypotl-ieee module.
72198         hypotf-ieee: Work around test failure on OSF/1 and native Windows.
72199         * m4/hypotf-ieee.m4: New file.
72200         * m4/hypotf.m4 (gl_FUNC_HYPOTF): If gl_FUNC_HYPOTF_IEEE is present,
72201         test whether hypotf works with mixed NaN and Infinity arguments.
72202         Replace it if not.
72203         * modules/hypotf-ieee (Files): Add m4/hypotf-ieee.m4.
72204         (Depends-on): Add hypot-ieee.
72205         (configure.ac): Invoke gl_FUNC_HYPOTF_IEEE.
72206         * doc/posix-functions/hypotf.texi: Mention the hypotf-ieee module.
72208         hypot-ieee: Work around test failure on OSF/1 and native Windows.
72209         * lib/math.in.h (hypot): New declaration.
72210         * lib/hypot.c: New file.
72211         * m4/hypot-ieee.m4: New file.
72212         * m4/hypot.m4 (gl_FUNC_HYPOT): If gl_FUNC_HYPOT_IEEE is present, test
72213         whether hypot works with mixed NaN and Infinity arguments. Replace it
72214         if not.
72215         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_HYPOT,
72216         REPLACE_HYPOT.
72217         * modules/math (Makefile.am): Substitute GNULIB_HYPOT, REPLACE_HYPOT.
72218         * modules/hypot (Files): Add lib/hypot.c.
72219         (Depends-on): Add dependencies.
72220         (configure.ac): Arrange to compile replacement if REPLACE_HYPOT is 1.
72221         * modules/hypot-ieee (Files): Add m4/hypot-ieee.m4.
72222         (configure.ac): Invoke gl_FUNC_HYPOT_IEEE.
72223         * tests/test-math-c++.cc: Check the declaration of hypot.
72224         * doc/posix-functions/hypot.texi: Mention the hypot-ieee module.
72226         Tests for module 'hypotl-ieee'.
72227         * modules/hypotl-ieee-tests: New file.
72228         * tests/test-hypotl-ieee.c: New file.
72230         New module 'hypotl-ieee'.
72231         * modules/hypotl-ieee: New file.
72233         Tests for module 'hypot-ieee'.
72234         * modules/hypot-ieee-tests: New file.
72235         * tests/test-hypot-ieee.c: New file.
72237         New module 'hypot-ieee'.
72238         * modules/hypot-ieee: New file.
72240         Tests for module 'hypotf-ieee'.
72241         * modules/hypotf-ieee-tests: New file.
72242         * tests/test-hypotf-ieee.c: New file.
72243         * tests/test-hypot-ieee.h: New file.
72245         New module 'hypotf-ieee'.
72246         * modules/hypotf-ieee: New file.
72248 2012-02-29  Bruno Haible  <bruno@clisp.org>
72250         Remove unused variables.
72251         * m4/fmod.m4 (gl_FUNC_FMOD): Remove unused variable 'i'.
72252         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
72253         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
72254         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
72256 2012-02-29  Eric Blake  <eblake@redhat.com>
72258         termios: fix pid_t always, not just for tcgetsid
72259         * doc/posix-headers/termios.texi (termios.h): Mention problem.
72260         * lib/termios.in.h (include): Ensure pid_t on all platforms, not
72261         just when building tcgetsid.
72263 2012-02-29  Bruno Haible  <bruno@clisp.org>
72265         Tests for module 'hypotl'.
72266         * modules/hypotl-tests: New file.
72267         * tests/test-hypotl.c: New file.
72269         New module 'hypotl'.
72270         * lib/math.in.h (hypotl): New declaration.
72271         * lib/hypotl.c: New file.
72272         * m4/hypotl.m4: New file.
72273         * m4/math_h.m4 (gl_MATH_H): Test whether hypotf is declared.
72274         (gl_MATH_H_DEFAULTS): Initialize GNULIB_HYPOTL, HAVE_HYPOTL.
72275         * modules/math (Makefile.am): Substitute GNULIB_HYPOTL, HAVE_HYPOTL.
72276         * modules/hypotl: New file.
72277         * tests/test-math-c++.cc: Check the hypotl declaration.
72278         * doc/posix-functions/hypotl.texi: Mention the new module.
72280 2012-02-29  Eric Blake  <eblake@redhat.com>
72282         tcgetsid: fix cygwin header bug
72283         * lib/termios.in.h (includes) [Cygwin]: Ensure pid_t is defined.
72285         docs: update cygwin progress
72286         * doc/posix-functions/llround.texi (llround): Added in cygwin
72287         1.7.8.
72288         * doc/posix-functions/llroundf.texi (llroundf): Likewise.
72289         * doc/glibc-functions/program_invocation_name.texi
72290         (program_invocation_name): Likewise.
72291         * doc/glibc-functions/program_invocation_short_name.texi
72292         (program_invocation_short_name): Likewise.
72293         * doc/glibc-functions/madvise.texi (madvise): Likewise.
72294         * doc/glibc-functions/pthread_yield.texi (pthread_yield):
72295         Likewise.
72296         * doc/posix-functions/pthread_spin_destroy.texi
72297         (pthread_spin_destroy): Added in cygwin 1.7.10.
72298         * doc/posix-functions/pthread_spin_init.texi (pthread_spin_init):
72299         Likewise.
72300         * doc/posix-functions/pthread_spin_lock.texi (pthread_spin_lock):
72301         Likewise.
72302         * doc/posix-functions/pthread_spin_trylock.texi
72303         (pthread_spin_trylock): Likewise.
72304         * doc/posix-functions/pthread_spin_unlock.texi
72305         (pthread_spin_unlock): Likewise.
72306         * doc/posix-functions/pthread_setschedprio.texi
72307         (pthread_setschedprio): Likewise.
72308         * doc/posix-functions/pthread_attr_getstack.texi
72309         (pthread_attr_getstack): Likewise.
72310         * doc/pastposix-functions/pthread_attr_getstackaddr.texi
72311         (pthread_attr_getstackaddr): Likewise.
72312         * doc/glibc-functions/pthread_getattr_np.texi
72313         (pthread_getattr_np): Likewise.
72314         * doc/glibc-functions/sys_siglist.texi (sys_siglist): Likewise.
72315         * doc/glibc-functions/sysinfo.texi (sysinfo): Likewise.
72316         * doc/posix-functions/clock_settime.texi (clock_settime):
72317         Likewise.
72318         * doc/posix-functions/pthread_attr_getguardsize.texi
72319         (pthread_attr_getguardsize): Likewise.
72320         * doc/posix-functions/pthread_attr_setguardsize.texi
72321         (pthread_attr_setguardsize): Likewise.
72322         * doc/posix-functions/pthread_attr_setstack.texi
72323         (pthread_attr_setstack): Likewise.
72324         * doc/pastposix-functions/pthread_attr_setstackaddr.texi
72325         (pthread_attr_setstackaddr): Likewise.
72326         * doc/posix-functions/clock_getcpuclockid.texi
72327         (clock_getcpuclockid): Likewise.
72328         * doc/posix-functions/pthread_getcpuclockid.texi
72329         (pthread_getcpuclockid): Likewise.
72330         * doc/glibc-functions/error.texi (error): Likewise.
72331         * doc/glibc-functions/error_at_line.texi (error_at_line):
72332         Likewise.
72333         * doc/glibc-functions/error_message_count.texi
72334         (error_message_count): Likewise.
72335         * doc/glibc-functions/error_one_per_line.texi
72336         (error_one_per_line): Likewise.
72337         * doc/glibc-functions/error_print_progname.texi
72338         (error_print_progname): Likewise.
72339         * doc/posix-functions/pthread_condattr_getclock.texi
72340         (pthread_condattr_getclock): Likewise.
72341         * doc/posix-functions/pthread_condattr_setclock.texi
72342         (pthread_condattr_setclock): Likewise.
72343         * doc/posix-functions/clock_nanosleep.texi (clock_nanosleep):
72344         Likewise.
72345         * doc/glibc-functions/getgrouplist.texi (getgrouplist): Likewise.
72346         * doc/glibc-functions/getpt.texi (getpt): Likewise.
72347         * doc/glibc-functions/get_current_dir_name.texi
72348         (get_current_dir_name): Likewise.
72349         * doc/glibc-functions/pthread_sigqueue.texi (pthread_sigqueue):
72350         Likewise.
72351         * doc/posix-functions/tcgetsid.texi (tcgetsid): Likewise, but with
72352         wrong return type.
72353         * doc/glibc-functions/scandirat.texi (scandirat): Added in cygwin
72354         1.7.11.
72356 2012-02-29  Bruno Haible  <bruno@clisp.org>
72358         Tests for module 'hypotf'.
72359         * modules/hypotf-tests: New file.
72360         * tests/test-hypotf.c: New file.
72362         New module 'hypotf'.
72363         * lib/math.in.h (hypotf): New declaration.
72364         * lib/hypotf.c: New file.
72365         * m4/hypotf.m4: New file.
72366         * m4/math_h.m4 (gl_MATH_H): Test whether hypotf is declared.
72367         (gl_MATH_H_DEFAULTS): Initialize GNULIB_HYPOTF, HAVE_HYPOTF,
72368         REPLACE_HYPOTF.
72369         * modules/math (Makefile.am): Substitute GNULIB_HYPOTF, HAVE_HYPOTF,
72370         REPLACE_HYPOTF.
72371         * modules/hypotf: New file.
72372         * tests/test-math-c++.cc: Check the hypotf declaration.
72373         * doc/posix-functions/hypotf.texi: Mention the new module.
72375         hypot: Prepare for hypotf module.
72376         * m4/hypot.m4: New file.
72377         * modules/hypot (Files): Add m4/hypot.m4.
72378         (configure.ac): Invoke gl_FUNC_HYPOT.
72380 2012-02-29  Bruno Haible  <bruno@clisp.org>
72382         hypot tests: More tests.
72383         * tests/test-hypot.c: Include <float.h>.
72384         (main): Add tests about overflow and underflow.
72386 2012-02-29  Bruno Haible  <bruno@clisp.org>
72388         math code: Add comments.
72389         * lib/acosl.c: Add comment about related glibc source files.
72390         * lib/asinl.c: Likewise.
72391         * lib/atanl.c: Likewise.
72392         * lib/expl.c: Likewise.
72393         * lib/logl.c: Likewise.
72394         * lib/sincosl.c: Likewise.
72395         * lib/sinl.c: Likewise.
72396         * lib/tanl.c: Likewise.
72397         * lib/trigl.c: Likewise.
72398         * lib/cosl.c: Likewise. Fix comments.
72400 2012-02-28  Bruno Haible  <bruno@clisp.org>
72402         math: Ensure HUGE_VAL, HUGE_VALF, HUGE_VALL are defined.
72403         * lib/math.in.h (HUGE_VAL, HUGE_VALF, HUGE_VALL): Define fallbacks.
72404         * tests/test-math.c: Include macros.h. Check that HUGE_VAL, HUGE_VALF,
72405         HUGE_VALL are defined.
72406         (numeric_equald): Renamed from numeric_equal.
72407         (numeric_equalf, numeric_equall): New functions.
72408         (main): Check also HUGE_VALF, HUGE_VALL.
72409         * modules/math-tests (Files): Add tests/macros.h.
72410         * doc/posix-headers/math.texi: Document the problems with HUGE_VALF and
72411         HUGE_VALL.
72413 2012-02-28  Bruno Haible  <bruno@clisp.org>
72415         doc: Move ISO C11 feature notes into POSIX chapters.
72416         * doc/posix-functions/aligned_alloc.texi: Renamed from
72417         doc/glibc-functions/aligned_alloc.texi.
72418         * doc/posix-functions/quick_exit.texi: Renamed from
72419         doc/glibc-functions/quick_exit.texi.
72420         * doc/posix-headers/uchar.texi: Renamed from
72421         doc/glibc-headers/uchar.texi.
72422         * doc/posix-functions/c16rtomb.texi: Renamed from
72423         doc/glibc-functions/c16rtomb.texi.
72424         * doc/posix-functions/c32rtomb.texi: Renamed from
72425         doc/glibc-functions/c32rtomb.texi.
72426         * doc/posix-functions/mbrtoc16.texi: Renamed from
72427         doc/glibc-functions/mbrtoc16.texi.
72428         * doc/posix-functions/mbrtoc32.texi: Renamed from
72429         doc/glibc-functions/mbrtoc32.texi.
72430         * doc/gnulib.texi: Update.
72431         (Glibc uchar.h): Remove section.
72432         Suggested by Eric Blake.
72434 2012-02-29  Paul Eggert  <eggert@cs.ucla.edu>
72436         stdnoreturn: port to MSVC better
72437         MSVC standard headers use __declspec(noreturn), so #define noreturn
72438         to empty on that platform.  Reported by Bruno Haible in
72439         <http://lists.gnu.org/r/bug-gnulib/2012-02/msg00152.html>.
72440         * lib/stdnoreturn.in.h (noreturn): Define to empty on MSVC.
72441         * doc/posix-headers/stdnoreturn.texi (stdnoreturn.h): Document this.
72443 2012-02-28  Bruno Haible  <bruno@clisp.org>
72445         doc: Mention new glibc headers and functions.
72446         * doc/glibc-headers/uchar.texi: New file.
72447         * doc/glibc-functions/aligned_alloc.texi: New file.
72448         * doc/glibc-functions/c16rtomb.texi: New file.
72449         * doc/glibc-functions/c32rtomb.texi: New file.
72450         * doc/glibc-functions/clock_adjtime.texi: New file.
72451         * doc/glibc-functions/fanotify_init.texi: New file.
72452         * doc/glibc-functions/fanotify_mark.texi: New file.
72453         * doc/glibc-functions/inet6_opt_append.texi: New file.
72454         * doc/glibc-functions/inet6_opt_find.texi: New file.
72455         * doc/glibc-functions/inet6_opt_finish.texi: New file.
72456         * doc/glibc-functions/inet6_opt_get_val.texi: New file.
72457         * doc/glibc-functions/inet6_opt_init.texi: New file.
72458         * doc/glibc-functions/inet6_opt_next.texi: New file.
72459         * doc/glibc-functions/inet6_opt_set_val.texi: New file.
72460         * doc/glibc-functions/inet6_rth_add.texi: New file.
72461         * doc/glibc-functions/inet6_rth_getaddr.texi: New file.
72462         * doc/glibc-functions/inet6_rth_init.texi: New file.
72463         * doc/glibc-functions/inet6_rth_reverse.texi: New file.
72464         * doc/glibc-functions/inet6_rth_segments.texi: New file.
72465         * doc/glibc-functions/inet6_rth_space.texi: New file.
72466         * doc/glibc-functions/login.texi: New file.
72467         * doc/glibc-functions/mbrtoc16.texi: New file.
72468         * doc/glibc-functions/mbrtoc32.texi: New file.
72469         * doc/glibc-functions/name_to_handle_at.texi: New file.
72470         * doc/glibc-functions/ntp_gettimex.texi: New file.
72471         * doc/glibc-functions/open_by_handle_at.texi: New file.
72472         * doc/glibc-functions/prlimit.texi: New file.
72473         * doc/glibc-functions/process_vm_readv.texi: New file.
72474         * doc/glibc-functions/process_vm_writev.texi: New file.
72475         * doc/glibc-functions/recvmmsg.texi: New file.
72476         * doc/glibc-functions/scandirat.texi: New file.
72477         * doc/glibc-functions/sendmmsg.texi: New file.
72478         * doc/glibc-functions/setns.texi: New file.
72479         * doc/glibc-functions/timespec_get.texi: New file.
72480         * doc/gnulib.texi: Include them.
72481         (Glibc sys/fanotify.h, Glibc sys/resource.h, Glibc uchar.h): New
72482         sections.
72483         Reported by Eric Blake.
72485 2012-02-28  Bruno Haible  <bruno@clisp.org>
72487         Avoid compilation errors with MSVC option -fp:strict.
72488         * lib/floor.c: Use MSVC specific pragma fenv_access.
72489         * lib/ceil.c: Likewise.
72490         * lib/trunc.c: Likewise.
72491         * lib/round.c: Likewise.
72492         * lib/rint.c: Likewise.
72493         * lib/fma.c: Likewise.
72494         * lib/integer_length.c: Likewise.
72495         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
72496         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
72497         * tests/test-floor2.c: Likewise.
72498         * tests/test-floorf2.c: Likewise.
72499         * tests/test-ceil2.c: Likewise.
72500         * tests/test-ceilf2.c: Likewise.
72501         * tests/test-trunc2.c: Likewise.
72502         * tests/test-truncf2.c: Likewise.
72503         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
72505 2012-02-27  Bruno Haible  <bruno@clisp.org>
72507         Tests for module 'sqrtl-ieee'.
72508         * modules/sqrtl-ieee-tests: New file.
72509         * tests/test-sqrtl-ieee.c: New file.
72511         New module 'sqrtl-ieee'.
72512         * modules/sqrtl-ieee: New file.
72514         Tests for module 'sqrt-ieee'.
72515         * modules/sqrt-ieee-tests: New file.
72516         * tests/test-sqrt-ieee.c: New file.
72518         New module 'sqrt-ieee'.
72519         * modules/sqrt-ieee: New file.
72521         Tests for module 'sqrtf-ieee'.
72522         * modules/sqrtf-ieee-tests: New file.
72523         * tests/test-sqrtf-ieee.c: New file.
72524         * tests/test-sqrt-ieee.h: New file.
72526         New module 'sqrtf-ieee'.
72527         * modules/sqrtf-ieee: New file.
72529 2012-02-27  Bruno Haible  <bruno@clisp.org>
72531         remainderl-ieee: Work around test failure on OSF/1.
72532         * m4/remainderl-ieee.m4: New file.
72533         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): If gl_FUNC_REMAINDERL_IEEE is
72534         present, test whether remainderl works with a zero second argument.
72535         Replace it if not.
72536         * lib/math.in.h (remainderl): Override if REPLACE_REMAINDERL is 1.
72537         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_REMAINDERL.
72538         * modules/math (Makefile.am): Substitute REPLACE_REMAINDERL.
72539         * modules/remainderl (configure.ac): Consider REPLACE_REMAINDERL.
72540         (Depends-on): Update conditions.
72541         * modules/remainderl-ieee (Files): Add m4/remainderl-ieee.m4.
72542         (Depends-on): Add remainder-ieee.
72543         (configure.ac): Invoke gl_FUNC_REMAINDERL_IEEE.
72544         * doc/posix-functions/remainderl.texi: Mention the remainderl-ieee
72545         module.
72547         remainderf-ieee: Work around test failure on OSF/1.
72548         * m4/remainderf-ieee.m4: New file.
72549         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): If gl_FUNC_REMAINDERF_IEEE is
72550         present, test whether remainderf works with a zero second argument.
72551         Replace it if not.
72552         * lib/math.in.h (remainderf): Override if REPLACE_REMAINDERF is 1.
72553         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_REMAINDERF.
72554         * modules/math (Makefile.am): Substitute REPLACE_REMAINDERF.
72555         * modules/remainderf (configure.ac): Consider REPLACE_REMAINDERF.
72556         (Depends-on): Update conditions.
72557         * modules/remainderf-ieee (Files): Add m4/remainderf-ieee.m4.
72558         (Depends-on): Add remainder-ieee.
72559         (configure.ac): Invoke gl_FUNC_REMAINDERF_IEEE.
72560         * doc/posix-functions/remainderf.texi: Mention the remainderf-ieee
72561         module.
72563         remainder-ieee: Work around test failure on OSF/1.
72564         * m4/remainder-ieee.m4: New file.
72565         * m4/remainder.m4 (gl_FUNC_REMAINDER): If gl_FUNC_REMAINDER_IEEE is
72566         present, test whether remainder works with a zero second argument.
72567         Replace it if not.
72568         * lib/math.in.h (remainder): Override if REPLACE_REMAINDER is 1.
72569         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_REMAINDER.
72570         * modules/math (Makefile.am): Substitute REPLACE_REMAINDER.
72571         * modules/remainder (configure.ac): Consider REPLACE_REMAINDER.
72572         (Depends-on): Update dependencies.
72573         * modules/remainder-ieee (Files): Add m4/remainder-ieee.m4.
72574         (configure.ac): Invoke gl_FUNC_REMAINDER_IEEE.
72575         * doc/posix-functions/remainder.texi: Mention the remainder-ieee module.
72577         Tests for module 'remainderl-ieee'.
72578         * modules/remainderl-ieee-tests: New file.
72579         * tests/test-remainderl-ieee.c: New file.
72581         New module 'remainderl-ieee'.
72582         * modules/remainderl-ieee: New file.
72584         Tests for module 'remainder-ieee'.
72585         * modules/remainder-ieee-tests: New file.
72586         * tests/test-remainder-ieee.c: New file.
72588         New module 'remainder-ieee'.
72589         * modules/remainder-ieee: New file.
72591         Tests for module 'remainderf-ieee'.
72592         * modules/remainderf-ieee-tests: New file.
72593         * tests/test-remainderf-ieee.c: New file.
72594         * tests/test-remainder-ieee.h: New file.
72596         New module 'remainderf-ieee'.
72597         * modules/remainderf-ieee: New file.
72599 2012-02-27  Bruno Haible  <bruno@clisp.org>
72601         modff, modfl: Fix configure syntax error.
72602         * m4/modff.m4 (gl_FUNC_MODFF): Insert ':' command in 'if'.
72603         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
72605 2012-02-27  Bruno Haible  <bruno@clisp.org>
72607         fmodl-ieee: Work around test failures on OSF/1, MSVC 9.
72608         * m4/fmodl-ieee.m4: New file.
72609         * m4/fmodl.m4 (gl_FUNC_FMODL): If gl_FUNC_FMODL_IEEE is present, test
72610         whether fmodl works with zero arguments. Replace it if not.
72611         * modules/fmodl-ieee (Files): Add m4/fmodl-ieee.m4.
72612         (Depends-on): Add fmod-ieee.
72613         (configure.ac): Invoke gl_FUNC_FMODL_IEEE.
72614         * doc/posix-functions/fmodl.texi: Mention the fmodl-ieee module.
72616         fmodf-ieee: Work around test failure on OSF/1.
72617         * m4/fmodf-ieee.m4: New file.
72618         * m4/fmodf.m4 (gl_FUNC_FMODF): If gl_FUNC_FMODF_IEEE is present, test
72619         whether fmodf works with zero arguments. Replace it if not.
72620         * lib/math.in.h (fmodf): Override if REPLACE_FMODF is 1.
72621         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FMODF.
72622         * modules/math (Makefile.am): Substitute REPLACE_FMODF.
72623         * modules/fmodf (configure.ac): Consider REPLACE_FMODF.
72624         (Depends-on): Update dependencies.
72625         * modules/fmodf-ieee (Files): Add m4/fmodf-ieee.m4.
72626         (configure.ac): Invoke gl_FUNC_FMODF_IEEE.
72627         * doc/posix-functions/fmodf.texi: Mention the problem on OSF/1.
72629         fmodf-ieee: Work around test failure on MSVC 9.
72630         * modules/fmodf-ieee (Depends-on): Add fmod-ieee.
72631         * doc/posix-functions/fmodf.texi: Mention the fmodf-ieee module.
72633         fmod-ieee: Work around test failures on OSF/1, mingw.
72634         * m4/fmod-ieee.m4: New file.
72635         * m4/fmod.m4 (gl_FUNC_FMOD): If gl_FUNC_FMOD_IEEE is present, test
72636         whether fmod works with zero arguments. Replace it if not.
72637         * lib/math.in.h (fmod): New declaration.
72638         * lib/fmod.c: New file.
72639         * m4/math_h.m4 (gl_MATH_H): Test whether fmod is declared.
72640         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMOD, REPLACE_FMOD.
72641         * modules/math (Makefile.am): Substitute GNULIB_FMOD, REPLACE_FMOD.
72642         * modules/fmod (Files): Add lib/fmod.c.
72643         (Depends-on): Add math, isinf, trunc, fma.
72644         (configure.ac): Arrange to compile lib/fmod.c if needed.
72645         * modules/fmod-ieee (Files): Add m4/fmod-ieee.m4, m4/minus-zero.m4,
72646         m4/signbit.m4.
72647         (configure.ac): Invoke gl_FUNC_FMOD_IEEE.
72648         * tests/test-math-c++.cc: Check the declaration of fmod.
72649         * doc/posix-functions/fmod.texi: Mention the fmod-ieee module.
72651         fmodl-ieee: Fix test failures.
72652         * lib/fmodl.c (fmodl): Treat Inf specially.
72653         * modules/fmodl (Depends-on): Add isinf.
72655         Tests for module 'fmodl-ieee'.
72656         * modules/fmodl-ieee-tests: New file.
72657         * tests/test-fmodl-ieee.c: New file.
72659         New module 'fmodl-ieee'.
72660         * modules/fmodl-ieee: New file.
72662         Tests for module 'fmod-ieee'.
72663         * modules/fmod-ieee-tests: New file.
72664         * tests/test-fmod-ieee.c: New file.
72666         New module 'fmod-ieee'.
72667         * modules/fmod-ieee: New file.
72669         Tests for module 'fmodf-ieee'.
72670         * modules/fmodf-ieee-tests: New file.
72671         * tests/test-fmodf-ieee.c: New file.
72672         * tests/test-fmod-ieee.h: New file.
72674         New module 'fmodf-ieee'.
72675         * modules/fmodf-ieee: New file.
72677 2012-02-27  Bruno Haible  <bruno@clisp.org>
72679         Tests for module 'rintl-ieee'.
72680         * modules/rintl-ieee-tests: New file.
72681         * tests/test-rintl-ieee.c: New file.
72683         New module 'rintl-ieee'.
72684         * modules/rintl-ieee: New file.
72686         Tests for module 'rint-ieee'.
72687         * modules/rint-ieee-tests: New file.
72688         * tests/test-rint-ieee.c: New file.
72690         New module 'rint-ieee'.
72691         * modules/rint-ieee: New file.
72693         Tests for module 'rintf-ieee'.
72694         * modules/rintf-ieee-tests: New file.
72695         * tests/test-rintf-ieee.c: New file.
72696         * tests/test-rint-ieee.h: New file.
72698         New module 'rintf-ieee'.
72699         * modules/rintf-ieee: New file.
72701 2012-02-26  Paul Eggert  <eggert@cs.ucla.edu>
72703         regex: re_search etc. should return -2 when memory exhausted
72704         This bug was uncovered when testing 'grep'.  Without the fix,
72705         re_search and friends return -1 when memory is exhausted, but -1
72706         means no match, and this causes grep to falsely report no-match
72707         instead of memory-exhaustion.  See
72708         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=13762>.
72709         * lib/regexec.c (re_search_stub): Return -2 (not -1) if there is
72710         trouble; this can occur if re_search_internal ran out of memory.
72712 2012-02-26  Bruno Haible  <bruno@clisp.org>
72714         modfl-ieee: Work around test failures on IRIX, OSF/1, mingw.
72715         * m4/modfl-ieee.m4: New file.
72716         * m4/modfl.m4 (gl_FUNC_MODFL): If gl_FUNC_MODFL_IEEE is present, test
72717         whether modfl works with Inf. Replace it if not.
72718         * lib/math.in.h (modfl): Override if REPLACE_MODFF is 1.
72719         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_MODFL.
72720         * modules/math (Makefile.am): Substitute REPLACE_MODFL.
72721         * modules/modfl (configure.ac): Consider REPLACE_MODFL.
72722         (Depends-on): Update dependencies.
72723         * modules/modfl-ieee (Files): Add m4/modfl-ieee.m4, m4/minus-zero.m4,
72724         m4/signbit.m4.
72725         (configure.ac): Invoke gl_FUNC_MODFL_IEEE.
72726         * doc/posix-functions/modfl.texi: Mention the modfl-ieee module.
72728         modfl-ieee: Fix dependencies.
72729         * modules/modfl-ieee (Depends-on): Add modf-ieee.
72731         modfl-ieee: Fix test failures.
72732         * lib/modfl.c (modfl): Treat NaN and Inf specially.
72733         * modules/modfl (Depends-on): Add isfinite, isinf.
72735         modff-ieee: Work around test failures on *BSD, IRIX, OSF/1, etc.
72736         * m4/modff-ieee.m4: New file.
72737         * m4/modff.m4 (gl_FUNC_MODFF): If gl_FUNC_MODFF_IEEE is present, test
72738         whether modff works with NaN and Inf. Replace it if not.
72739         * lib/math.in.h (modff): Override if REPLACE_MODFF is 1.
72740         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_MODFF.
72741         * modules/math (Makefile.am): Substitute REPLACE_MODFF.
72742         * modules/modff (configure.ac): Consider REPLACE_MODFF.
72743         (Depends-on): Update dependencies.
72744         * modules/modff-ieee (Files): Add m4/modff-ieee.m4, m4/minus-zero.m4,
72745         m4/signbit.m4.
72746         (Depends-on): Add modf-ieee.
72747         (configure.ac): Invoke gl_FUNC_MODFF_IEEE.
72748         * doc/posix-functions/modff.texi: Mention the modff-ieee module.
72750         modf-ieee: Work around test failures on *BSD, IRIX, OSF/1, Cygwin.
72751         * m4/modf-ieee.m4: New file.
72752         * m4/modf.m4 (gl_FUNC_MODF): If gl_FUNC_MODF_IEEE is present, test
72753         whether modf works with NaN and Inf. Replace it if not.
72754         * lib/math.in.h (modf): New declaration.
72755         * lib/modf.c: New file.
72756         * m4/math_h.m4 (gl_MATH_H): Test whether modf is declared.
72757         (gl_MATH_H_DEFAULTS): Initialize GNULIB_MODF, REPLACE_MODF.
72758         * modules/math (Makefile.am): Substitute GNULIB_MODF, REPLACE_MODF.
72759         * modules/modf (Files): Add lib/modf.c.
72760         (Depends-on): Add math, isfinite, trunc, isinf.
72761         (configure.ac): Addrange to compile lib/modf.c if needed.
72762         * modules/modf-ieee (Files): Add m4/modf-ieee.m4, m4/minus-zero.m4,
72763         m4/signbit.m4.
72764         (configure.ac): Invoke gl_FUNC_MODF_IEEE.
72765         * tests/test-math-c++.cc: Check the declaration of modf.
72766         * doc/posix-functions/modf.texi: Mention the modf-ieee module.
72768         Tests for module 'modfl-ieee'.
72769         * modules/modfl-ieee-tests: New file.
72770         * tests/test-modfl-ieee.c: New file.
72772         New module 'modfl-ieee'.
72773         * modules/modfl-ieee: New file.
72775         Tests for module 'modf-ieee'.
72776         * modules/modf-ieee-tests: New file.
72777         * tests/test-modf-ieee.c: New file.
72779         New module 'modf-ieee'.
72780         * modules/modf-ieee: New file.
72782         Tests for module 'modff-ieee'.
72783         * modules/modff-ieee-tests: New file.
72784         * tests/test-modff-ieee.c: New file.
72785         * tests/test-modf-ieee.h: New file.
72787         New module 'modff-ieee'.
72788         * modules/modff-ieee: New file.
72790 2012-02-26  Bruno Haible  <bruno@clisp.org>
72792         Tests for module 'fabsl-ieee'.
72793         * modules/fabsl-ieee-tests: New file.
72794         * tests/test-fabsl-ieee.c: New file.
72796         New module 'fabsl-ieee'.
72797         * modules/fabsl-ieee: New file.
72799         Tests for module 'fabs-ieee'.
72800         * modules/fabs-ieee-tests: New file.
72801         * tests/test-fabs-ieee.c: New file.
72803         New module 'fabs-ieee'.
72804         * modules/fabs-ieee: New file.
72806         Tests for module 'fabsf-ieee'.
72807         * modules/fabsf-ieee-tests: New file.
72808         * tests/test-fabsf-ieee.c: New file.
72809         * tests/test-fabs-ieee.h: New file.
72811         New module 'fabsf-ieee'.
72812         * modules/fabsf-ieee: New file.
72814 2012-02-26  Bruno Haible  <bruno@clisp.org>
72816         Tests for module 'fmal-ieee'.
72817         * modules/fmal-ieee-tests: New file.
72818         * tests/test-fmal-ieee.c: New file.
72820         New module 'fmal-ieee'.
72821         * modules/fmal-ieee: New file.
72823         Tests for module 'fma-ieee'.
72824         * modules/fma-ieee-tests: New file.
72825         * tests/test-fma-ieee.c: New file.
72827         New module 'fma-ieee'.
72828         * modules/fma-ieee: New file.
72830         Tests for module 'fmaf-ieee'.
72831         * modules/fmaf-ieee-tests: New file.
72832         * tests/test-fmaf-ieee.c: New file.
72833         * tests/test-fma-ieee.h: New file.
72835         New module 'fmaf-ieee'.
72836         * modules/fmaf-ieee: New file.
72838 2012-02-26  Bruno Haible  <bruno@clisp.org>
72840         Tests for module 'ldexpl-ieee'.
72841         * modules/ldexpl-ieee-tests: New file.
72842         * tests/test-ldexpl-ieee.c: New file.
72844         New module 'ldexpl-ieee'.
72845         * modules/ldexpl-ieee: New file.
72847         Tests for module 'ldexp-ieee'.
72848         * modules/ldexp-ieee-tests: New file.
72849         * tests/test-ldexp-ieee.c: New file.
72851         New module 'ldexp-ieee'.
72852         * modules/ldexp-ieee: New file.
72854         Tests for module 'ldexpf-ieee'.
72855         * modules/ldexpf-ieee-tests: New file.
72856         * tests/test-ldexpf-ieee.c: New file.
72857         * tests/test-ldexp-ieee.h: New file.
72859         New module 'ldexpf-ieee'.
72860         * modules/ldexpf-ieee: New file.
72862 2012-02-26  Bruno Haible  <bruno@clisp.org>
72864         Refactor frexp*-ieee tests.
72865         * tests/test-frexp-ieee.h: New file.
72866         * tests/test-frexpf-ieee.c: Include test-frexp-ieee.h.
72867         (main): Just call test_function.
72868         * tests/test-frexp-ieee.c: Include test-frexp-ieee.h.
72869         (main): Just call test_function.
72870         * tests/test-frexpl-ieee.c: Include test-frexp-ieee.h.
72871         (main): Just call test_function.
72872         * modules/frexpf-ieee-tests (Files): Add tests/test-frexp-ieee.h.
72873         * modules/frexp-ieee-tests (Files): Likewise.
72874         * modules/frexpl-ieee-tests (Files): Likewise.
72876         Tests for module 'frexpl-ieee'.
72877         * modules/frexpl-ieee-tests: New file.
72878         * tests/test-frexpl-ieee.c: New file.
72880         New module 'frexpl-ieee'.
72881         * modules/frexpl-ieee: New file.
72883         Tests for module 'frexp-ieee'.
72884         * modules/frexp-ieee-tests: New file.
72885         * tests/test-frexp-ieee.c: New file.
72887         New module 'frexp-ieee'.
72888         * modules/frexp-ieee: New file.
72890         Tests for module 'frexpf-ieee'.
72891         * modules/frexpf-ieee-tests: New file.
72892         * tests/test-frexpf-ieee.c: New file.
72894         New module 'frexpf-ieee'.
72895         * modules/frexpf-ieee: New file.
72897 2012-02-26  Bruno Haible  <bruno@clisp.org>
72899         roundl-ieee tests: More tests.
72900         * tests/test-roundl-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
72901         (main): Add tests for [MX] shaded specification in POSIX.
72902         * modules/roundl-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72903         (Depends-on): Add isnanl-nolibm.
72905         round-ieee tests: More tests.
72906         * tests/test-round-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
72907         (main): Add tests for [MX] shaded specification in POSIX.
72908         * modules/round-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72909         (Depends-on): Add isnand-nolibm.
72911         roundf-ieee tests: More tests.
72912         * tests/test-roundf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
72913         (main): Add tests for [MX] shaded specification in POSIX.
72914         * modules/roundf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72915         (Depends-on): Add isnanf-nolibm.
72917         truncl-ieee tests: More tests.
72918         * tests/test-truncl-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
72919         (main): Add tests for [MX] shaded specification in POSIX.
72920         * modules/truncl-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72921         (Depends-on): Add isnanl-nolibm.
72923         trunc-ieee tests: More tests.
72924         * tests/test-trunc-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
72925         (main): Add tests for [MX] shaded specification in POSIX.
72926         * modules/trunc-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72927         (Depends-on): Add isnand-nolibm.
72929         truncf-ieee tests: More tests.
72930         * tests/test-truncf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
72931         (main): Add tests for [MX] shaded specification in POSIX.
72932         * modules/truncf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72933         (Depends-on): Add isnanf-nolibm.
72935         ceill-ieee tests: More tests.
72936         * tests/test-ceill-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
72937         (main): Add tests for [MX] shaded specification in POSIX.
72938         * modules/ceill-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72939         (Depends-on): Add isnanl-nolibm.
72941         ceil-ieee tests: More tests.
72942         * tests/test-ceil-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
72943         (main): Add tests for [MX] shaded specification in POSIX.
72944         * modules/ceil-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72945         (Depends-on): Add isnand-nolibm.
72947         ceilf-ieee tests: More tests.
72948         * tests/test-ceilf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
72949         (main): Add tests for [MX] shaded specification in POSIX.
72950         * modules/ceilf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72951         (Depends-on): Add isnanf-nolibm.
72953         floorl-ieee tests: More tests.
72954         * tests/test-floorl-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
72955         (main): Add tests for [MX] shaded specification in POSIX.
72956         * modules/floorl-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72957         (Depends-on): Add isnanl-nolibm.
72959         floor-ieee tests: More tests.
72960         * tests/test-floor-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
72961         (main): Add tests for [MX] shaded specification in POSIX.
72962         * modules/floor-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72963         (Depends-on): Add isnand-nolibm.
72965         floorf-ieee tests: More tests.
72966         * tests/test-floorf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
72967         (main): Add tests for [MX] shaded specification in POSIX.
72968         * modules/floorf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
72969         (Depends-on): Add isnanf-nolibm.
72971 2012-02-26  Bruno Haible  <bruno@clisp.org>
72973         fpieee: More comments.
72974         * m4/fpieee.m4 (gl_FP_IEEE): Add more comments.
72976 2012-02-25  Bruno Haible  <bruno@clisp.org>
72978         Tests for module 'log10l'.
72979         * modules/log10l-tests: New file.
72980         * tests/test-log10l.c: New file.
72981         * tests/test-math-c++.cc: Check the declaration of log10l.
72983         New module 'log10l'.
72984         * lib/math.in.h (log10l): New declaration.
72985         * lib/log10l.c: New file.
72986         * m4/log10l.m4: New file.
72987         * modules/log10l: New file.
72988         * m4/math_h.m4 (gl_MATH_H): Test whether log10l is declared.
72989         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG10L, HAVE_LOG10L,
72990         HAVE_DECL_LOG10L.
72991         * modules/math (Makefile.am): Substitute GNULIB_LOG10L, HAVE_LOG10L,
72992         HAVE_DECL_LOG10L.
72993         * doc/posix-functions/log10l.texi: Mention the new module.
72995 2012-02-25  Bruno Haible  <bruno@clisp.org>
72997         fmodl, remainder*: Avoid wrong results due to rounding errors.
72998         * lib/fmodl.c (fmodl): Correct the result if it is not within the
72999         expected bounds.
73000         * lib/remainderf.c (remainderf): Likewise.
73001         * lib/remainder.c (remainder): Likewise.
73002         * lib/remainderl.c (remainderl): Likewise.
73004 2012-02-25  Bruno Haible  <bruno@clisp.org>
73006         Tests for module 'remainderl'.
73007         * modules/remainderl-tests: New file.
73008         * tests/test-remainderl.c: New file.
73009         * tests/test-math-c++.cc: Check the declaration of remainderl.
73011         New module 'remainderl'.
73012         * lib/math.in.h (remainderl): New declaration.
73013         * lib/remainderl.c: New file.
73014         * m4/remainderl.m4: New file.
73015         * modules/remainderl: New file.
73016         * m4/math_h.m4 (gl_MATH_H): Test whether remainderl is declared.
73017         (gl_MATH_H_DEFAULTS): Initialize GNULIB_REMAINDERL, HAVE_REMAINDERL.
73018         * modules/math (Makefile.am): Substitute GNULIB_REMAINDERL,
73019         HAVE_REMAINDERL.
73020         * doc/posix-functions/remainderl.texi: Mention the new module.
73022 2012-02-25  Bruno Haible  <bruno@clisp.org>
73024         Tests for module 'remainderf'.
73025         * modules/remainderf-tests: New file.
73026         * tests/test-remainderf.c: New file.
73027         * tests/test-math-c++.cc: Check the declaration of remainderf.
73029         New module 'remainderf'.
73030         * lib/math.in.h (remainderf): New declaration.
73031         * lib/remainderf.c: New file.
73032         * m4/remainderf.m4: New file.
73033         * modules/remainderf: New file.
73034         * m4/math_h.m4 (gl_MATH_H): Test whether remainderf is declared.
73035         (gl_MATH_H_DEFAULTS): Initialize GNULIB_REMAINDERF, HAVE_REMAINDERF.
73036         * modules/math (Makefile.am): Substitute GNULIB_REMAINDERF,
73037         HAVE_REMAINDERF.
73038         * doc/posix-functions/remainderf.texi: Mention the new module.
73040 2012-02-25  Bruno Haible  <bruno@clisp.org>
73042         remainder: Support for MSVC.
73043         * lib/math.in.h (remainder): New declaration.
73044         * lib/remainder.c: New file.
73045         * m4/remainder.m4: New file.
73046         * modules/remainder (Files): Add lib/remainder.c, m4/remainder.m4.
73047         (Depends-on): Add math, round, fma.
73048         (configure.ac): Use results of gl_FUNC_REMAINDER.
73049         * m4/math_h.m4 (gl_MATH_H): Test whether remainder is declared.
73050         (gl_MATH_H_DEFAULTS): Initialize GNULIB_REMAINDER, HAVE_REMAINDER,
73051         HAVE_DECL_REMAINDER.
73052         * modules/math (Makefile.am): Substitute GNULIB_REMAINDER,
73053         HAVE_REMAINDER, HAVE_DECL_REMAINDER.
73054         * tests/test-math-c++.cc: Check the declaration of remainder.
73055         * doc/posix-functions/remainder.texi: Mention that the MSVC and IRIX 5
73056         problems are fixed.
73058 2012-02-25  Bruno Haible  <bruno@clisp.org>
73060         Tests for module 'fmodl'.
73061         * modules/fmodl-tests: New file.
73062         * tests/test-fmodl.c: New file.
73063         * tests/test-math-c++.cc: Check the declaration of fmodl.
73065         New module 'fmodl'.
73066         * lib/math.in.h (fmodl): New declaration.
73067         * lib/fmodl.c: New file.
73068         * m4/fmodl.m4: New file.
73069         * m4/math_h.m4 (gl_MATH_H): Test whether fmodl is declared.
73070         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMODL, HAVE_FMODL,
73071         REPLACE_FMODL.
73072         * modules/math (Makefile.am): Substitute GNULIB_FMODL, HAVE_FMODL,
73073         REPLACE_FMODL.
73074         * modules/fmodl: New file.
73075         * doc/posix-functions/fmodl.texi: Mention the new module.
73077 2012-02-25  Bruno Haible  <bruno@clisp.org>
73079         Tests for module 'modfl'.
73080         * modules/modfl-tests: New file.
73081         * tests/test-modfl.c: New file.
73082         * tests/test-math-c++.cc: Check the declaration of modfl.
73084         New module 'modfl'.
73085         * lib/math.in.h (modfl): New declaration.
73086         * lib/modfl.c: New file.
73087         * m4/modfl.m4: New file.
73088         * m4/math_h.m4 (gl_MATH_H): Test whether modfl is declared.
73089         (gl_MATH_H_DEFAULTS): Initialize GNULIB_MODFL, HAVE_MODFL.
73090         * modules/math (Makefile.am): Substitute GNULIB_MODFL, HAVE_MODFL.
73091         * modules/modfl: New file.
73092         * doc/posix-functions/modfl.texi: Mention the new module.
73094 2012-02-25  Bruno Haible  <bruno@clisp.org>
73096         Tests for module 'fabsl'.
73097         * modules/fabsl-tests: New file.
73098         * tests/test-fabsl.c: New file.
73099         * tests/test-math-c++.cc: Check the declaration of fabsl.
73101         New module 'fabsl'.
73102         * lib/math.in.h (fabsl): New declaration.
73103         * lib/fabsl.c: New file.
73104         * m4/fabsl.m4: New file.
73105         * m4/math_h.m4 (gl_MATH_H): Test whether fabsl is declared.
73106         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FABSL, HAVE_FABSL,
73107         REPLACE_FABSL.
73108         * modules/math (Makefile.am): Substitute GNULIB_FABSL, HAVE_FABSL,
73109         REPLACE_FABSL.
73110         * modules/fabsl: New file.
73111         * doc/posix-functions/fabsl.texi: Mention the new module.
73113 2012-02-25  Bruno Haible  <bruno@clisp.org>
73115         fabs tests: More tests.
73116         * tests/test-fabs.c: Include <string.h>, minus-zero.h.
73117         (zero): New variable.
73118         (main): Add tests for signed zero.
73119         * modules/fabs-tests (Files): Add tests/minus-zero.h.
73121         fabsf tests: More tests.
73122         * tests/test-fabsf.c: Include <string.h>, minus-zero.h.
73123         (zero): New variable.
73124         (main): Add tests for signed zero.
73125         * modules/fabsf-tests (Files): Add tests/minus-zero.h.
73127 2012-02-24  Bruno Haible  <bruno@clisp.org>
73129         atanl: Provide function definition on MSVC.
73130         * m4/atanl.m4 (gl_FUNC_ATANL): Test also whether atanl can be used as a
73131         function pointer.
73132         * lib/math.in.h (atanl): Undefine if it does not exist as a function.
73134 2012-02-24  Bruno Haible  <bruno@clisp.org>
73136         acosl: Provide function definition on MSVC.
73137         * m4/acosl.m4 (gl_FUNC_ACOSL): Test also whether acosl can be used as a
73138         function pointer.
73139         * lib/math.in.h (acosl): Undefine if it does not exist as a function.
73141 2012-02-24  Bruno Haible  <bruno@clisp.org>
73143         asinl: Provide function definition on MSVC.
73144         * m4/asinl.m4 (gl_FUNC_ASINL): Test also whether asinl can be used as a
73145         function pointer.
73146         * lib/math.in.h (asinl): Undefine if it does not exist as a function.
73148 2012-02-24  Bruno Haible  <bruno@clisp.org>
73150         tanl: Provide function definition on MSVC.
73151         * m4/tanl.m4 (gl_FUNC_TANL): Test also whether tanl can be used as a
73152         function pointer.
73153         * lib/math.in.h (tanl): Undefine if it does not exist as a function.
73155 2012-02-24  Bruno Haible  <bruno@clisp.org>
73157         cosl: Provide function definition on MSVC.
73158         * m4/cosl.m4 (gl_FUNC_COSL): Test also whether cosl can be used as a
73159         function pointer.
73160         * lib/math.in.h (cosl): Undefine if it does not exist as a function.
73162 2012-02-24  Bruno Haible  <bruno@clisp.org>
73164         sinl: Provide function definition on MSVC.
73165         * m4/sinl.m4 (gl_FUNC_SINL): Test also whether sinl can be used as a
73166         function pointer.
73167         * lib/math.in.h (sinl): Undefine if it does not exist as a function.
73169 2012-02-24  Bruno Haible  <bruno@clisp.org>
73171         logl: Provide function definition on MSVC.
73172         * m4/logl.m4 (gl_FUNC_LOGL): Test also whether logl can be used as a
73173         function pointer.
73174         * lib/math.in.h (logl): Undefine if it does not exist as a function.
73176 2012-02-24  Bruno Haible  <bruno@clisp.org>
73178         expl: Provide function definition on MSVC.
73179         * m4/expl.m4 (gl_FUNC_EXPL): Test also whether expl can be used as a
73180         function pointer.
73181         * lib/math.in.h (expl): Undefine if it does not exist as a function.
73183 2012-02-24  Bruno Haible  <bruno@clisp.org>
73185         sqrtl: Provide function definition on MSVC.
73186         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Test also whether sqrtl can be used as
73187         a function pointer.
73188         * lib/math.in.h (sqrtl): Undefine if it does not exist as a function.
73190 2012-02-24  Bruno Haible  <bruno@clisp.org>
73192         ceill: Provide function definition on MSVC.
73193         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Test also whether ceill can be
73194         used as a function pointer.
73195         * lib/math.in.h (ceill): Undefine if it is not declared as a function.
73197 2012-02-24  Bruno Haible  <bruno@clisp.org>
73199         floorl: Provide function definition on MSVC.
73200         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Test also whether floorl can be
73201         used as a function pointer.
73202         * lib/math.in.h (floorl): Undefine if it is not declared as a function.
73204 2012-02-24  Bruno Haible  <bruno@clisp.org>
73206         ceilf: Provide function definition on MSVC.
73207         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Test also whether ceilf can be
73208         used as a function pointer.
73209         * lib/math.in.h (ceilf): Undefine if it is not declared as a function.
73211 2012-02-24  Bruno Haible  <bruno@clisp.org>
73213         floorf: Provide function definition on MSVC.
73214         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Test also whether floorf can be
73215         used as a function pointer.
73216         * lib/math.in.h (floorf): Undefine if it is not declared as a function.
73218 2012-02-24  Paul Eggert  <eggert@cs.ucla.edu>
73220         stdnoreturn: new module
73221         This implements a replacement for C11's <stdnoreturn.h>.
73222         * doc/gnulib.texi (Header File Substitutes): Add stdnoreturn.
73223         * doc/posix-headers/stdnoreturn.texi, lib/stdnoreturn.in.h:
73224         * m4/stdnoreturn.m4, modules/stdnoreturn, modules/stdnoreturn-tests:
73225         * tests/test-stdnoreturn.c: New files.
73227 2012-02-24  Stanislav Brabec  <sbrabec@suse.cz>  (tiny change)
73229         regex: fix false multibyte matches in some regular expressions
73230         See <http://sourceware.org/bugzilla/show_bug.cgi?id=13637>
73231         and <http://sourceware.org/ml/libc-alpha/2012-02/msg00521.html>.
73232         * lib/regex_internal.c (re_string_skip_chars):
73233         Fix miscomputation of remain_len that may cause incomplete
73234         multi-byte character and false match.
73236 2012-02-24  Jim Meyering  <meyering@redhat.com>
73238         maint.mk: tell sc_prohibit_strcmp to ding "0 == strcmp (...)", too
73239         * top/maint.mk (sc_prohibit_strcmp): Also prohibit uses of strcmp
73240         uses with "==" *before* the call, e.g., 0 == strcmp (...)
73241         Remove now-unnecessary str''cmp obfuscation.
73242         Suggested by Akim Demaille.
73244 2012-02-24  Bruno Haible  <bruno@clisp.org>
73246         streq: Rename macro.
73247         * lib/streq.h (STREQ_OPT): Renamed from STREQ.
73248         * NEWS: Mention the change.
73249         * lib/mbrtowc.c (mbrtowc): Update.
73250         * lib/uniwidth/cjk.h (is_cjk_encoding): Update.
73251         * lib/wcwidth.c (wcwidth): Update.
73252         Suggested by Akim Demaille and Jim Meyering.
73254 2012-02-20  Paul Eggert  <eggert@cs.ucla.edu>
73256         regex: fix typo in definition of MIN
73257         * lib/regex_internal.h (MIN): Fix typo.  Problem reported by Thomas
73258         Schwinge in <http://sourceware.org/bugzilla/show_bug.cgi?id=11638#c4>.
73260 2012-02-19  Paul Eggert  <eggert@cs.ucla.edu>
73261             Bruno Haible  <bruno@clisp.org>
73263         acl: Don't use ACL_CNT and similar ops, since they are unreliable.
73264         * lib/file-has-acl.c (file_has_acl) [HP-UX, NonStop Kernel]: Read the
73265         entries into a stack-allocated buffer directly.
73266         * lib/copy-acl.c (qcopy_acl) [HP-UX, NonStop Kernel]: Likewise.
73268 2012-02-19  Paul Eggert  <eggert@cs.ucla.edu>
73269             Bruno Haible  <bruno@clisp.org>
73271         acl: Don't use GETACLCNT and similar ops, since they are unreliable.
73273          - There were several instances of this pattern:
73275              for (;;) {
73276                n = acl (f, GETACLCNT, 0, NULL);
73277                [ allocate an array A of size N ]
73278                if (acl (f, GETACL, n, a) == n)
73279                  break;
73280              }
73282            This loop might never terminate if some other process is constantly
73283            manipulating the file's ACL.  The loop should be rewritten to
73284            terminate.
73286          - The acl (... GETACLNT ...) call is merely an optimization; its value
73287            is merely a hint as to how big to make the array.  A better
73288            optimization is to avoid the acl (... GETACLNT ...)  call entirely,
73289            and just guess a reasonably-big size, growing the size and trying
73290            again if it's not large enough.  This guarantees termination, and
73291            saves a system call.
73293         * lib/acl-internal.h: Include <limits.h>.
73294         (MIN, SIZE_MAX): New macros.
73295         * lib/file-has-acl.c (file_has_acl) [Solaris]: Read the entries into
73296         a stack-allocated buffer, and use malloc if it does not fit. Don't
73297         use GETACLCNT.
73298         * lib/set-mode-acl.c (qset_acl) [Solaris]: Likewise.
73300 2012-02-19  Bruno Haible  <bruno@clisp.org>
73302         acl: Fix endless loop on Solaris with vxfs.
73303         * lib/file-has-acl.c (file_has_acl) [Solaris]: Treat a failing
73304         acl()/facl() call for ACE_GETACL like a failing call for ACE_GETACLCNT.
73305         * lib/set-mode-acl.c (qset_acl) [Solaris]: Likewise.
73306         * lib/copy-acl.c (qcopy_acl)[Solaris]: Likewise.
73307         * tests/test-sameacls.c (main)[Solaris]: Likewise.
73308         Reported by Bill Jones in
73309         <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10639>, via Paul Eggert.
73311 2012-02-19  Bruno Haible  <bruno@clisp.org>
73313         acl: Fix copy-acl test failure on Solaris 11.0.
73314         * lib/file-has-acl.c (NEW_ACE_WRITEA_DATA): New macro.
73315         (acl_ace_nontrivial): Relax the restrictions on access_masks[] so
73316         that this function returns 0 in some more cases.
73318 2012-02-19  Bruno Haible  <bruno@clisp.org>
73320         acl: Update doc references.
73321         * doc/acl-resources.txt: Update links to Solaris documentation.
73323 2012-02-19  Bruno Haible  <bruno@clisp.org>
73325         Fix test failure in many locales on Solaris 11.
73326         * tests/test-pipe-filter-gi1.c (main): Don't use range expression in
73327         'tr' arguments.
73328         * tests/test-pipe-filter-ii1.c (main): Likewise.
73329         * build-aux/bootstrap (check_versions): Run 'tr' command with range
73330         expressions in the C locale.
73331         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
73332         * m4/host-os.m4 (gl_HOST_OS): Likewise.
73334 2012-02-19  Bruno Haible  <bruno@clisp.org>
73336         gnulib-tool: Improve usage message.
73337         * gnulib-tool (func_usage): Move doc of --help and --version to the
73338         section "Operation modes".
73340 2012-02-18  Reuben Thomas  <rrt@sc3d.org>
73342         README-release: make it easier to execute commands
73343         * top/README-release: break commands out on to separate lines.
73345 2012-02-16  Stefano Lattarini  <stefano.lattarini@gmail.com>
73347         GNUmakefile: simplify detection of unconfigured trees
73348         * top/GNUmakefile: Use $(wildcard) instead of $(shell) to determine
73349         whether the tree make is being run from is already configured or
73350         not.  Related simplifications.
73352 2012-02-13  Simon Josefsson  <simon@josefsson.org>
73354         * gnulib-tool (func_usage): Document --help and --version.
73356 2012-02-11  Jim Meyering  <meyering@redhat.com>
73358         bootstrap: don't exit 0 upon gnulib-tool failure
73359         * build-aux/bootstrap (gnulib_tool): If gnulib-tool fails, exit with
73360         its exit status, not 0.
73362 2011-12-19  Reuben Thomas  <rrt@sc3d.org>
73364         README-release: various improvements
73365         * top/README-release: Give a command to push changes for the
73366         release.  Add "distcheck" to list of other pre-release checks.
73367         Fix instance of "make stable" which should be "make TYPE".
73369 2012-02-09  Paul Eggert  <eggert@cs.ucla.edu>
73371         maint: replace FSF snail-mail addresses with URLs
73372         * config/argz.mk, lib/accept4.c, lib/alignof.h, lib/alloca.in.h:
73373         * lib/alphasort.c, lib/arcfour.c, lib/arcfour.h, lib/arctwo.c:
73374         * lib/arctwo.h, lib/argz.c, lib/arpa_inet.in.h, lib/asnprintf.c:
73375         * lib/asprintf.c, lib/assert.in.h, lib/base32.c, lib/base32.h:
73376         * lib/base64.c, lib/base64.h, lib/c-ctype.c, lib/c-ctype.h:
73377         * lib/c-strcase.h, lib/c-strcasecmp.c, lib/c-strncasecmp.c:
73378         * lib/check-version.c, lib/check-version.h, lib/config.charset:
73379         * lib/ctype.in.h, lib/des.c, lib/des.h, lib/dup3.c, lib/errno.in.h:
73380         * lib/float+.h, lib/fnmatch.c, lib/fnmatch.in.h, lib/fnmatch_loop.c:
73381         * lib/fseeko.c, lib/gai_strerror.c, lib/gc-gnulib.c:
73382         * lib/gc-libgcrypt.c, lib/gc-pbkdf2-sha1.c, lib/gc.h:
73383         * lib/getaddrinfo.c, lib/getdelim.c, lib/getfilecon.c, lib/getline.c:
73384         * lib/getlogin_r.c, lib/getpass.c, lib/getpass.h, lib/gettext.h:
73385         * lib/gettimeofday.c, lib/glob.in.h, lib/glthread/cond.c:
73386         * lib/glthread/cond.h, lib/glthread/lock.c, lib/glthread/lock.h:
73387         * lib/glthread/thread.c, lib/glthread/thread.h:
73388         * lib/glthread/threadlib.c, lib/glthread/yield.h, lib/hmac-md5.c:
73389         * lib/hmac-sha1.c, lib/hmac.h, lib/iconv.c, lib/iconv.in.h:
73390         * lib/iconv_close.c, lib/iconv_open.c, lib/inet_ntop.c, lib/isfinite.c:
73391         * lib/isinf.c, lib/iswblank.c, lib/langinfo.in.h, lib/link.c:
73392         * lib/localcharset.c, lib/localcharset.h, lib/lseek.c, lib/malloc.c:
73393         * lib/malloca.c, lib/malloca.h, lib/md2.c, lib/md2.h, lib/md4.c:
73394         * lib/md4.h, lib/md5.c, lib/md5.h, lib/memmem.c, lib/mempcpy.c:
73395         * lib/memset.c, lib/memxor.c, lib/memxor.h, lib/minmax.h, lib/mktime.c:
73396         * lib/msvc-inval.c, lib/msvc-inval.h, lib/msvc-nothrow.c:
73397         * lib/msvc-nothrow.h, lib/netdb.in.h, lib/netinet_in.in.h, lib/nproc.c:
73398         * lib/nproc.h, lib/obstack_printf.c, lib/pathmax.h, lib/pipe.c:
73399         * lib/pipe2.c, lib/poll.c, lib/poll.in.h, lib/printf-args.c:
73400         * lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h:
73401         * lib/pselect.c, lib/pthread.in.h, lib/pty-private.h, lib/pty.in.h:
73402         * lib/read-file.c, lib/read-file.h, lib/ref-add.sin, lib/ref-del.sin:
73403         * lib/regcomp.c, lib/regex.c, lib/regex.h, lib/regex_internal.c:
73404         * lib/regex_internal.h, lib/regexec.c, lib/rijndael-alg-fst.c:
73405         * lib/rijndael-alg-fst.h, lib/rijndael-api-fst.c:
73406         * lib/rijndael-api-fst.h, lib/rint.c, lib/rintf.c, lib/rintl.c:
73407         * lib/round.c, lib/roundf.c, lib/roundl.c, lib/scandir.c, lib/select.c:
73408         * lib/sha1.c, lib/sha1.h, lib/size_max.h, lib/snprintf.c:
73409         * lib/stdalign.in.h, lib/stdarg.in.h, lib/stdbool.in.h:
73410         * lib/stddef.in.h, lib/stdint.in.h, lib/stdio.in.h, lib/str-kmp.h:
73411         * lib/str-two-way.h, lib/strcasecmp.c, lib/strcasestr.c, lib/strdup.c:
73412         * lib/striconv.c, lib/striconv.h, lib/string.in.h, lib/strings.in.h:
73413         * lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c, lib/strpbrk.c:
73414         * lib/strptime.c, lib/strsep.c, lib/strstr.c, lib/strverscmp.c:
73415         * lib/sys_file.in.h, lib/sys_ioctl.in.h, lib/sys_select.in.h:
73416         * lib/sys_socket.in.h, lib/sys_stat.in.h, lib/sys_time.in.h:
73417         * lib/sys_times.in.h, lib/sys_types.in.h, lib/sys_uio.in.h:
73418         * lib/sys_utsname.in.h, lib/sys_wait.in.h, lib/tcgetsid.c:
73419         * lib/termios.in.h, lib/time.in.h, lib/time_r.c, lib/timegm.c:
73420         * lib/times.c, lib/unictype/3level.h, lib/unictype/3levelbit.h:
73421         * lib/unistd.in.h, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c:
73422         * lib/vsnprintf.c, lib/waitpid.c, lib/wchar.in.h, lib/wctype.in.h:
73423         * lib/xsize.h, tests/test-closein.c, tests/test-des.c:
73424         * tests/test-fclose.c, tests/test-fgetc.c, tests/test-filevercmp.c:
73425         * tests/test-fputc.c, tests/test-fread.c, tests/test-fwrite.c:
73426         * tests/test-gc-arcfour.c, tests/test-gc-arctwo.c, tests/test-gc-des.c:
73427         * tests/test-gc-hmac-md5.c, tests/test-gc-hmac-sha1.c:
73428         * tests/test-gc-md2.c, tests/test-gc-md4.c, tests/test-gc-md5.c:
73429         * tests/test-gc-pbkdf2-sha1.c, tests/test-gc-rijndael.c:
73430         * tests/test-gc-sha1.c, tests/test-gc.c, tests/test-getdelim.c:
73431         * tests/test-getline.c, tests/test-getndelim2.c, tests/test-md2.c:
73432         * tests/test-md4.c, tests/test-parse-datetime.c, tests/test-perror.c:
73433         * tests/test-perror2.c, tests/test-pipe.c, tests/test-pipe2.c:
73434         * tests/test-poll.c, tests/test-quotearg-simple.c:
73435         * tests/test-quotearg.c, tests/test-quotearg.h:
73436         * tests/test-round-ieee.c, tests/test-round1.c:
73437         * tests/test-roundf-ieee.c, tests/test-roundf1.c:
73438         * tests/test-roundl-ieee.c, tests/test-roundl.c:
73439         * tests/test-safe-alloc.c, tests/test-sigpipe.c:
73440         * tests/test-spawn-pipe-child.c, tests/test-spawn-pipe-main.c:
73441         * tests/test-strerror.c, tests/test-strerror_r.c:
73442         * tests/test-strsignal.c, tests/test-strverscmp.c:
73443         * tests/test-xmemdup0.c:
73444         Replace FSF snail mail addresses with URLs, as per GNU coding
73445         standards.  See glibc bug
73446         <http://sourceware.org/bugzilla/show_bug.cgi?id=13673>.
73448 2011-12-22  Reuben Thomas  <rrt@sc3d.org>
73450         README-release: capitalize a word and split a line
73451         * top/README-release: Fix punctuation and spacing.
73453 2012-02-08  Akim Demaille  <demaille@gostai.com>
73455         fatal-signal: use C prototypes (with explicit void).
73456         * lib/fatal-signal.c (uninstall_handlers, install_handlers)
73457         (init_fatal_signal_set, block_fatal_signals): Fix signatures.
73459 2012-02-07  Paul Eggert  <eggert@cs.ucla.edu>
73461         regex: spelling fix
73462         * lib/regexec.c: spelling fix
73464         regex: rely on stdint.h for SIZE_MAX
73465         * lib/regex_internal.h (SIZE_MAX): Remove; stdint.h supplies this now.
73467 2012-02-07  Paul Eggert  <eggert@cs.ucla.edu>
73469         regex: merge glibc changes
73471         * lib/regcomp.c (init_dfa): Tighten overflow checks to test
73472         for IDX_MAX too, since IDX_MAX can be much less than SIZE_MAX.
73473         (init_word_char): Work even if bitset words are not exactly 32 or
73474         64 bits wide.  Don't assume there are no padding bits.
73475         * lib/regex.c [_LIBC]: Do not include <config.h>.
73476         [!_LIBC]: Add pragmas to ignore -Wsuggest-attributes=pure
73477         and -Wtype-limits.
73478         * lib/regex.h (__USE_GNU): Renamed from __USE_GNU_REGEX, to avoid
73479         needless disagreement with glibc.  All uses changed.  Define it to
73480         1 only if _GNU_SOURCE, to match glibc.
73481         (_REG_RM_NAME): Remove; no longer needed, since the names in
73482         question are now all protected by __USE_GNU.
73483         (_REG_RE_NAME): Remove; replaced by glibc's __REPB_PREFIX.
73484         (REG_TRANSLATE_TYPE): Remove; replaced by glibc's __RE_TRANSLATE_TYPE.
73485         * lib/regex_internal.h (MIN): New macro.
73487         2012-01-03 Ulrich Drepper <drepper@gmail.com>
73488         * lib/regcomp.c (init_word_char): Optimize regex a bit.
73490         2011-12-30 Jakub Jelinek <jakub@redhat.com>
73491         * lib/regex_internal.c (re_string_fetch_byte_case):
73492         Fix up regcomp/regexec.  The problem is that parse_bracket_symbol
73493         is miscompiled, and it turns out it is because of an incorrect
73494         attribute on re_string_fetch_byte_case.  Unlike
73495         re_string_peek_byte_case, this one is really not pure, it modifies
73496         memory (increments pstr->cur_idx), and with the pure attribute GCC
73497         assumed it doesn't and it cached the presumed value of
73498         regexp->cur_idx in a variable across the
73499          for (;; ++i)
73500            {
73501              if (i >= BRACKET_NAME_BUF_SIZE)
73502                return REG_EBRACK;
73503              if (token->type == OP_OPEN_CHAR_CLASS)
73504                ch = re_string_fetch_byte_case (regexp);
73505              else
73506                ch = re_string_fetch_byte (regexp);
73507              if (re_string_eoi(regexp))
73508                return REG_EBRACK;
73509              if (ch == delim && re_string_peek_byte (regexp, 0) == ']')
73510                break;
73511              elem->opr.name[i] = ch;
73512            }
73514         2011-11-29 Andreas Schwab <schwab@redhat.com>
73515         * lib/regcomp.c (build_equiv_class):
73516         Fix access after end of search string in regex matcher.
73518         2011-11-12 Ulrich Drepper <drepper@redhat.com>
73519         * lib/regex_internal.c, lib/regex_internal.h: Fix warnings in regex.
73521         2011-10-12 Ulrich Drepper <drepper@redhat.com>
73522         * lib/regcomp.c (parse_branch): One more regex memory leak fixed.
73524         2011-10-11 Ulrich Drepper <drepper@redhat.com>
73525         * lib/regcomp.c (parse_branch, parse_sub_exp):
73526         More regex memory leak fixes and tests.
73527         (parse_sub_exp, parse_bracket_exp):
73528         Fix memory leak for some invalid regular expressions.
73530         2011-05-28 Ulrich Drepper <drepper@gmail.com>
73531         * lib/regex_internal.c, lib/regexec.c:
73532         Fix unnecessary overallocation due to incomplete character.  When
73533         incomplete characters are found at the end of a string the code
73534         ran amok and allocated lots of memory.  Stricter limits are now in
73535         place.
73537         2011-05-20 Reuben Thomas <rrt@sc3d.org>
73538         * lib/regex.h: Update documentation.
73540         2011-05-16 Aharon Robbins <arnold@skeeve.com>
73541         * lib/regex.h: Update RE_SYNTAX*_AWK constants.
73543         2010-05-05 Andreas Schwab <schwab@redhat.com>
73544         * lib/regexec.c (find_collation_sequence_value):
73545         Fix lookup of collation sequence value during regexp matching.
73547         2010-01-22 Ulrich Drepper <drepper@redhat.com>
73548         * lib/regex_internal.c (re_dfa_add_node): Extend overflow detection.
73550         2008-01-16 Ulrich Drepper <drepper@redhat.com>
73551         * lib/regex.h: Cleanup namespace.
73553         2007-11-26 Ulrich Drepper <drepper@redhat.com>
73554         * lib/regex.h (REG_ENOSYS): Define REG_ENOSYS also for __USE_XOPEN2K.
73556         2007-08-26 Ulrich Drepper <drepper@redhat.com>
73557         * lib/regex_internal.h: Prevent some declarations and definitions
73558         to be seen when used in tests.
73560         2005-05-06 Ulrich Drepper <drepper@redhat.com>
73561         * lib/regex_internal.h: Include bits/libc-lock.h or define dummy
73562         __libc_lock_* macros if not _LIBC.
73563         (struct re_dfa_t): Add lock.
73565 2012-02-07  Eric Blake  <eblake@redhat.com>
73567         maint.mk: also prohibit lower-case @var@
73568         * top/maint.mk (sc_makefile_at_at_check): Enhance check to cover
73569         lower case, like @top_srcdir@.
73571 2012-02-04  Eric Blake  <eblake@redhat.com>
73573         canonicalize: avoid uninitialized memory use
73574         * lib/canonicalize-lgpl.c (__realpath): Avoid possibility of
73575         random '/' left in dest.
73576         * lib/canonicalize.c (canonicalize_filename_mode): Likewise.
73578 2012-02-04  Bruno Haible  <bruno@clisp.org>
73580         isatty: Fix test failure of ptsname_r on native Windows.
73581         * lib/isatty.c (_isatty_nothrow): Upon exception, return 0, not -1,
73582         and don't set errno.
73583         (isatty): Test first whether fd is valid. Set errno when returning 0.
73585 2012-02-04  Bruno Haible  <bruno@clisp.org>
73587         spawn-pipe tests: Fix a NULL program name in a diagnostic.
73588         * tests/test-spawn-pipe-main.c: Include progname.h.
73589         (main): Invoke set_program_name.
73590         * modules/spawn-pipe-tests (Depends-on): Add progname.
73592         nonblocking-socket tests: Fix a NULL program name in a diagnostic.
73593         * tests/test-nonblocking-socket-main.c: Include progname.h.
73594         (main): Invoke set_program_name.
73595         * modules/nonblocking-socket-tests (Depends-on): Add progname.
73597         nonblocking-pipe tests: Fix a NULL program name in a diagnostic.
73598         * tests/test-nonblocking-pipe-main.c: Include progname.h.
73599         (main): Invoke set_program_name.
73600         * modules/nonblocking-pipe-tests (Depends-on): Add progname.
73602 2012-02-04  Eric Blake  <eblake@redhat.com>
73604         canonicalize-lgpl: fix // handling
73605         * lib/canonicalize-lgpl.c (__realpath): Don't convert /// to //.
73607         canonicalize: fix // handling
73608         * lib/canonicalize.c (canonicalize_filename_mode): Don't convert
73609         /// to //, since only // is special.
73611 2012-02-04  Bruno Haible  <bruno@clisp.org>
73613         ioctl: Fix test failure on native Windows.
73614         * lib/ioctl.c: Include msvc-nothrow.h.
73615         (primary_ioctl): If fd is not a valid handle, set errno to EBADF.
73617 2012-02-04  Bruno Haible  <bruno@clisp.org>
73619         fsync: Avoid test failure on native Windows.
73620         * lib/fsync.c (fsync) [Windows]: Don't fail if the handle is merely
73621         read-only.
73623 2012-02-04  Bruno Haible  <bruno@clisp.org>
73625         sys_select: Avoid syntax error on OpenBSD 5.0.
73626         * lib/sys_select.in.h [OpenBSD]: When /usr/include/pthread.h is
73627         currently being included, just include the system's <sys/select.h>.
73629 2012-02-04  Bruno Haible  <bruno@clisp.org>
73631         sys_select: Avoid syntax error on OpenBSD 5.0.
73632         * lib/sys_select.in.h: Include <signal.h> only after the include_next
73633         <sys/select.h>, not before.
73634         Reported by Jiri B <jirib@devio.us>.
73636 2012-02-04  Bruno Haible  <bruno@clisp.org>
73638         get-rusage-as, get-rusage-data tests: Avoid test failure with gcc-4.7.
73639         * tests/test-get-rusage-as.c (main): Assign the malloc() results to
73640         global variables.
73641         * tests/test-get-rusage-data.c (main): Likewise.
73642         Reported by Jim Meyering.
73644 2012-02-04  Bruno Haible  <bruno@clisp.org>
73646         stdioext: Fix last commit.
73647         * lib/fwritable.c [EPLAN9]: Include <fcntl.h>.
73649 2012-02-03  Bruno Haible  <bruno@clisp.org>
73651         stdioext: Add tentative support for Plan9.
73652         * lib/stdio-impl.h: Include <errno.h>.
73653         * lib/fseterr.c (fseterr) [EPLAN9]: Add conditional code.
73654         * lib/freadable.c (freadable): Likewise.
73655         * lib/fwritable.c (fwritable): Likewise.
73656         * lib/fbufmode.c (fbufmode): Likewise.
73657         * lib/freading.c (freading): Likewise.
73658         * lib/fwriting.c (fwriting): Likewise.
73659         * lib/freadptr.c (freadptr): Likewise.
73660         * lib/freadseek.c (freadptrinc): Likewise.
73661         * lib/freadahead.c (freadahead): Likewise.
73662         * lib/fpurge.c (fpurge): Likewise.
73663         * lib/fseeko.c (rpl_fseeko): Likewise.
73664         * m4/fpending.m4 (gl_PREREQ_FPENDING): Add a variant for Plan9.
73665         Reported by Jens Staal <staal1978@gmail.com>.
73667 2012-02-02  Jim Meyering  <meyering@redhat.com>
73669         file-has-acl: suppress a warning from gcc -Wsuggest-attribute=const
73670         * lib/file-has-acl.c (file_has_acl): This function (for some #ifdefs)
73671         would evoke a new gcc warning.  Given all of the #ifdefs, it is better
73672         not even to try to add the attribute.  Instead, add a pragma to suppress
73673         the suggestion/warning.
73675 2012-01-31  Karl Berry  <karl@gnu.org>
73677         setstate doc: typo.
73678         * doc/posix-functions/setstate.texi (setstate): { not (.
73680 2012-01-31  Bruno Haible  <bruno@clisp.org>
73682         popen: Make more robust on Windows.
73683         * lib/popen.c: On native Windows, use the _popen based code even if
73684         HAVE_POPEN is set.
73685         * doc/posix-functions/popen.texi: Mention necessity of COMSPEC
73686         environment variable on native Windows.
73688 2012-01-30  Bruno Haible  <bruno@clisp.org>
73690         pclose: Fix typo.
73691         * lib/stdio.in.h (pclose): Fix typo in warning message.
73693 2012-01-30  Bruno Haible  <bruno@clisp.org>
73695         doc about getlogin_r, setstate.
73696         * doc/posix-functions/getlogin_r.texi: List the incompatible
73697         declaration problem under "not fixed by gnulib".
73698         * doc/posix-functions/setstate.texi: Mention incompatible declaration
73699         problem on Solaris 11 and other platforms.
73701 2012-01-30  Chuanchang Jia  <chuanchang.jia@gmail.com>  (tiny change)
73702             Bruno Haible  <bruno@clisp.org>
73704         poll tests: Make test more robust.
73705         * tests/test-poll.c: Include macros.h.
73706         (test_accept_first, test_pair, test_socket_pair, test_pipe): Verify
73707         return value of various I/O operations.
73708         * modules/poll-tests (Files): Add tests/macros.h.
73710 2012-01-30  Bruno Haible  <bruno@clisp.org>
73712         sys_stat: Fix support for mingw64 and MSVC.
73713         * lib/sys_stat.in.h (stat) [AIX]: Don't redefine 'stat' if the system
73714         header files already do it.
73715         (stat) [mingw, msvc]: Redefine the symbol to which stat is defined, not
73716         stat itself.
73717         Reported by Marc-André Lureau <marcandre.lureau@redhat.com>.
73719 2012-01-30  Bruno Haible  <bruno@clisp.org>
73721         wcwidth: Work around bug in UTF-8 locale on OpenBSD 5.0.
73722         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test also wcwidth of U+05B0.
73723         * doc/posix-functions/wcwidth.texi: Mention the OpenBSD 5.0 bug.
73725 2012-01-29  Bruno Haible  <bruno@clisp.org>
73727         quotearg: Fix test failure on MacOS X 10.5.
73728         * tests/test-quotearg-simple.c: Include localcharset.h.
73729         (main): If the locale encoding is not ASCII, bypass the tests of
73730         locale_quoting_style and clocale_quoting_style.
73731         * modules/quotearg-tests (Depends-on): Add 'localcharset'.
73733 2012-01-29  Jim Meyering  <meyering@redhat.com>
73735         maint.mk: sc_prohibit_canonicalize_without_use: avoid false positive
73736         * top/maint.mk (sc_prohibit_canonicalize_without_use): Also
73737         detect uses of canonicalize_file_name.
73739 2012-01-28  Bruno Haible  <bruno@clisp.org>
73741         test-framework-sh: Fix test failure with AIX 7.1 diff.
73742         * tests/init.sh (compare_): Don't use 'diff -u' if it inserts a space
73743         in column 1, like 'diff -c' does.
73744         * tests/test-init.sh (test_compare): Don't repeat the test from init.sh
73745         whether 'diff -u' is used. Instead, test whether the output contains
73746         some '@' character.
73748 2012-01-28  Paul Eggert  <eggert@cs.ucla.edu>
73750         strtoimax: eliminate need for stdint.h, inttypes.h checks
73751         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Don't use
73752         gl_AC_HEADER_STDINT_H or gl_AC_HEADER_INTTYPES_H.  This reduces
73753         the prerequisites for a recently-introduced strtoimax test.
73754         I guess this might cause strtoimax to be replaced when not
73755         strictly necessary on older hosts, but this shouldn't introduce
73756         any bugs and it should make Emacs 'configure' faster on typical
73757         modern hosts.  Problem discovered when importing the latest gnulib
73758         to an Emacs test version.
73759         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4.
73761 2012-01-28  Bruno Haible  <bruno@clisp.org>
73763         sys_time: Override 'struct timeval' on some native Windows platforms.
73764         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Test whether tv_sec
73765         has the right type. Set REPLACE_STRUCT_TIMEVAL if not.
73766         (gl_HEADER_SYS_TIME_H_DEFAULTS): Initialize REPLACE_STRUCT_TIMEVAL.
73767         * lib/sys_time.in.h: Include <winsock2.h> also when 'struct timeval'
73768         needs to be overridden.
73769         (timeval): Override if REPLACE_STRUCT_TIMEVAL is set.
73770         * modules/sys_time (Makefile.am): Substitute REPLACE_STRUCT_TIMEVAL.
73771         * tests/test-sys_select.c: Check that the tv_sec member has the same
73772         size as a 'time_t'.
73773         * tests/test-sys_time.c: Likewise.
73774         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): If REPLACE_STRUCT_TIMEVAL
73775         is set, set also REPLACE_GETTIMEOFDAY.
73776         * lib/gettimeofday.c (gettimeofday): If 'struct timeval' is overridden,
73777         convert the resulting 'struct timeval' before returning.
73778         * lib/select.c: Include <sys/time.h>.
73779         (select, timeval): Undefine at the right place.
73780         * modules/select (Depends-on): Add sys_time.
73781         * doc/posix-headers/sys_time.texi: Mention the problem with tv_sec on
73782         some Windows platforms.
73783         Reported by Marc-André Lureau <marcandre.lureau@redhat.com>.
73785 2012-01-28  Marc-André Lureau  <marcandre.lureau@redhat.com>  (tiny change)
73787         accept4, fcntl, socket modules: Avoid warnings on x86_64 mingw64.
73788         * lib/accept4.c (accept4): Use intptr_t to convert handle pointer to
73789         an integer.
73790         * lib/fcntl.c (dupfd): Likewise.
73791         * lib/w32sock.h (SOCKET_TO_FD): Likewise.
73793 2012-01-28  Bruno Haible  <bruno@clisp.org>
73795         fcntl: Avoid compilation error on native Windows.
73796         * modules/fcntl (Depends-on): Add 'close'.
73798 2012-01-28  Marc-André Lureau  <marcandre.lureau@redhat.com>  (tiny change)
73800         select, poll, isatty: Avoid warnings on x86_64 mingw64.
73801         * lib/select.c (IsConsoleHandle): Use intptr_t to convert handle
73802         pointer to an integer.
73803         * lib/poll.c (IsConsoleHandle): Likewise.
73804         * lib/isatty.c (IsConsoleHandle): Likewise.
73806 2012-01-28  Jim Meyering  <meyering@redhat.com>
73808         doc: clarify README-release
73809         * top/README-release: Clarify: you should make a point to have
73810         the latest stable versions of build tools in your PATH, and the
73811         reference to buildreq is solely for its list of tool names, not
73812         for its minimal-functional version numbers.
73813         Prompted by discussion with Reuben Thomas and Gary V. Vaughan.
73815         maint.mk: use more readable (yet functionally equivalent) quoting
73816         It is common to quote a single quote in a single quoted string like
73817         this:  '...'\''...'.  Unless you know the idiom, that looks like
73818         gibberish, so prefer to double-quote the string when possible.
73819         Then you can use a more readable, lone single quote: "...'..."
73820         * top/maint.mk (sc_cast_of_argument_to_free): Quoting like this
73821         "don't" is more readable than the equivalent 'don'\''t'.
73822         (sc_cast_of_x_alloc_return_value): Likewise.
73823         (sc_cast_of_alloca_return_value): Likewise.
73824         (sc_makefile_path_separator_check): Similar: use ":" in '...',
73825         rather than '\'':'\''.
73827 2012-01-27  Paul Eggert  <eggert@cs.ucla.edu>
73829         stdalign: relax _Alignof and tighten _Alignas test
73830         * m4/stdalign.m4 (gl_STDALIGN_H): Relax the _Alignof test,
73831         as it was too strict: alignof must divide offsetof, but it need
73832         not equal offsetof.  Inspired by Joseph S. Myers's comment
73833         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023#c10>.
73834         Conversely, tighten the _Alignas test a bit, as the resulting
73835         alignment must be exactly 8.
73837 2012-01-27  Bruno Haible  <bruno@clisp.org>
73839         stdalign: Document the last change.
73840         * doc/posix-headers/stdalign.texi: Mention GCC bug 52023.
73842 2012-01-27  Paul Eggert  <eggert@cs.ucla.edu>
73844         stdalign: check that alignof and offsetof are consistent
73845         * m4/stdalign.m4 (gl_STDALIGN_H): Check for GCC bug 52023.
73846         Problem reported for gnulib by Richard W.M. Jones in
73847         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00340.html>.
73849 2012-01-27  Jim Meyering  <meyering@redhat.com>
73851         update-copyright: accept new option: UPDATE_COPYRIGHT_USE_INTERVALS=2
73852         * build-aux/update-copyright: When UPDATE_COPYRIGHT_USE_INTERVALS=2,
73853         convert a sequence with gaps to the minimal containing range.
73854         For example, convert 2000, 2004-2007, 2009 to 2000-2009.
73855         * tests/test-update-copyright.sh: Test for this.
73856         The FSF confirmed it is ok to do this, assuming there is at
73857         least one significant change per year in the affected range:
73858         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/29554/focus=29860
73860 2012-01-26  Bruno Haible  <bruno@clisp.org>
73862         pipe2: refine doc about thread-safety
73863         * doc/glibc-functions/pipe2.texi: Clarify the extent of the
73864         multithread-safety problem.
73865         * doc/glibc-functions/accept4.texi: Likewise.
73867 2012-01-26  Bruno Haible  <bruno@clisp.org>
73869         posix_spawn_file_actions_addopen: Fix 2012-01-08 commit.
73870         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN):
73871         In the test program, include <fcntl.h>, for O_RDONLY.
73873 2012-01-26  Eric Blake  <eblake@redhat.com>
73875         pipe2: document lack of thread-safety in replacement
73876         * doc/glibc-functions/pipe2.texi (pipe2): Mention thread safety
73877         issue in replacement.
73878         * doc/glibc-functions/accept4.texi (accept4): Likewise.
73879         Based on a report by Eric Wong.
73881 2012-01-24  Marc-André Lureau  <marcandre.lureau@redhat.com>  (tiny change)
73882             Bruno Haible  <bruno@clisp.org>
73884         malloca: Avoid warnings on x86_64 mingw64.
73885         * lib/malloca.c: Include <stdint.h>.
73886         (mmalloca, freea): Use uintptr_t to convert pointers to integers.
73887         * modules/malloca (Depends-on): Add stdint.
73888         * modules/relocatable-prog-wrapper (Depends-on): Likewise.
73890 2012-01-25  Paul Eggert  <eggert@cs.ucla.edu>
73892         obstack: remove __STDC__ conditionals
73893         * lib/obstack.h: Remove __STDC__ conditionals, as suggested by Joseph
73894         S. Myers in <http://cygwin.com/ml/libc-alpha/2012-01/msg00104.html>.
73895         This leaves lib/localcharset.c, m4/iconv.m4, and a confusing comment in
73896         m4/include_next.m4 as the only gnulib-maintained places that still
73897         refer to __STDC__.
73899 2012-01-24  Bruno Haible  <bruno@clisp.org>
73901         havelib: Modern quoting.
73902         * build-aux/config.rpath: Quote 'like this', not `like this', as per
73903         the recent change to the GNU coding standards.
73905 2012-01-24  Bruno Haible  <bruno@clisp.org>
73907         stdint: Improve support for Android.
73908         * lib/stdint.in.h: Test __ANDROID__, not __BIONIC__.
73909         Reported by Simon Josefsson <simon@josefsson.org>.
73911 2012-01-23  Paul Eggert  <eggert@cs.ucla.edu>
73913         doc: omit trailing empty lines from INSTALL etc.
73914         * doc/Makefile (INSTALL): Omit trailing empty lines.
73915         (INSTALL.ISO, INSTALL.UTF-8): Build from INSTALL, so that these also
73916         omit trailing empty lines.  This simplifies the build procedure.
73918 2012-01-23  Jim Meyering  <meyering@redhat.com>
73920         tests: avoid spurious warnings about gl_sockets_startup
73921         Fedora rawhide's gcc version 4.7.0 20120119 with -Wunused-value
73922         would warn about every use of "gl_sockets_startup (SOCKETS_1_1);"
73923         reporting a "statement with no effect".
73924         * tests/test-accept.c (main): Mark as "(void)".
73925         * tests/test-accept4.c (main): Likewise.
73926         * tests/test-bind.c (main): Likewise.
73927         * tests/test-connect.c (main): Likewise.
73928         * tests/test-getpeername.c (main): Likewise.
73929         * tests/test-getsockname.c (main): Likewise.
73930         * tests/test-getsockopt.c (main): Likewise.
73931         * tests/test-listen.c (main): Likewise.
73932         * tests/test-recv.c (main): Likewise.
73933         * tests/test-recvfrom.c (main): Likewise.
73934         * tests/test-send.c (main): Likewise.
73935         * tests/test-sendto.c (main): Likewise.
73936         * tests/test-setsockopt.c (main): Likewise.
73937         * tests/test-shutdown.c (main): Likewise.
73939 2012-01-21  Bruno Haible  <bruno@clisp.org>
73941         locale-fr.m4: Fix for Android.
73942         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Avoid compilation
73943         failure of the test program on Bionic libc.
73945 2012-01-21  Jim Meyering  <meyering@redhat.com>
73947         bootstrap: fail when bootstrap_post_import_hook fails
73948         Otherwise, it's far too easy to miss diagnostics emitted
73949         between gnulib-tool's output and that of running configure.
73950         * build-aux/bootstrap: Fail when bootstrap_post_import_hook fails.
73952 2012-01-17  Jim Meyering  <meyering@redhat.com>
73954         maint: enable sc_trailing_blank
73955         * build-aux/pmccabe.css: Remove trailing blanks.
73956         * doc/acl-cygwin.txt: Likewise.
73957         * doc/gnu-oids.texi: Likewise
73958         * cfg.mk: Enable sc_trailing_blank.
73959         Exempt build-aux/texinfo.tex and doc/Copyright/assign.future.manual.
73961 2012-01-17  Jim Meyering  <meyering@redhat.com>
73963         maint: enable sc_prohibit_openat_without_use
73964         * cfg.mk: Enable sc_prohibit_openat_without_use.
73965         Exempt lib/selinux-at.c.
73967 2012-01-17  Jim Meyering  <meyering@redhat.com>
73969         maint: enable sc_prohibit_cloexec_without_use
73970         * cfg.mk: Enable sc_prohibit_cloexec_without_use.
73971         * lib/dup-safer-flag.c: Don't include "cloexec.h".  Not needed.
73973 2012-01-17  Jim Meyering  <meyering@redhat.com>
73975         maint: enable sc_prohibit_intprops_without_use
73976         * cfg.mk: Enable sc_prohibit_intprops_without_use
73977         * tests/test-nanosleep.c: Don't include "intprops.h".  Not needed.
73979 2012-01-17  Jim Meyering  <meyering@redhat.com>
73981         maint: enable sc_prohibit_hash_pjw_without_use
73982         * cfg.mk: Enable sc_prohibit_hash_pjw_without_use.
73983         * top/maint.mk (sc_prohibit_hash_pjw_without_use): Adjust regexp
73984         to match any use of \<hash_pjw\>, i.e., not necessarily with a
73985         following " (".
73987 2012-01-17  Jim Meyering  <meyering@redhat.com>
73989         maint: enable double-word-prohibiting rule
73990         * cfg.mk (local-checks-to-skip): Enable sc_prohibit_doubled_word.
73991         Exempt three files.
73993 2012-01-17  Jim Meyering  <meyering@redhat.com>
73995         maint: remove empty lines at EOF, but excluding modules/*
73996         Apply syntax rules at home as well as abroad.  Most changes
73997         were induced by running this:
73998           make srcdir=. _build-aux=build-aux -f top/maint.mk \
73999             sc_prohibit_empty_lines_at_EOF | grep -v modules/ \
74000             | xargs perl -pi -0777 -e 's/\n\n+$/\n/'
74001         * cfg.mk (local-checks-to-skip): Enable sc_prohibit_empty_lines_at_EOF.
74002         Exempt modules/* and two binary files.
74003         Also exempt doc/INSTALL*, per request from Bruno Haible.
74004         * doc/regexprops-generic.texi: *Add* a newline at EOF.  There was none.
74005         * doc/Copyright/assign.translation.manual: Remove empty lines at EOF.
74006         * doc/Copyright/request-assign.future: Likewise.
74007         * doc/Copyright/request-disclaim.changes: Likewise.
74008         * doc/INSTALL: Likewise.
74009         * doc/INSTALL.ISO: Likewise.
74010         * doc/INSTALL.UTF-8: Likewise.
74011         * doc/acl-cygwin.txt: Likewise.
74012         * doc/acl-resources.txt: Likewise.
74013         * doc/fdl-1.2.texi: Likewise.
74014         * doc/fdl-1.3.texi: Likewise.
74015         * doc/fdl.texi: Likewise.
74016         * lib/argp-pin.c: Likewise.
74017         * lib/round.c: Likewise.
74018         * lib/unicase/u16-totitle.c: Likewise.
74019         * lib/unictype/block_test.c: Likewise.
74020         * lib/uninorm/canonical-decomposition.c: Likewise.
74021         * m4/README: Likewise.
74022         * m4/relocatable-lib.m4: Likewise.
74023         * tests/test-isnand-nolibm.c: Likewise.
74024         * tests/test-isnand.c: Likewise.
74025         * tests/uninorm/NormalizationTest.txt: Likewise.
74027 2012-01-17  Jim Meyering  <meyering@redhat.com>
74029         maint: add framework to run syntax-check rules against gnulib sources
74030         * cfg.mk: New file, to disable all currently-failing tests.
74031         We'll enable them one by one, as they are made to pass.
74032         * Makefile (sc_maint): New rule.
74034 2012-01-21  Bruno Haible  <bruno@clisp.org>
74036         stdint: Add support for Android.
74037         * lib/stdint.in.h: When included from Bionic <sys/types.h>, just
74038         include the system's <stdint.h>.
74039         Reported by Simon Josefsson <simon@josefsson.org>.
74041 2012-01-19  Jim Meyering  <meyering@redhat.com>
74043         bootstrap: add bootstrap_post_import_hook
74044         Bison does still need something like the gnulib_mk_hook whose
74045         invocation I had to remove along with slurp in commit 767ccd40.
74046         Technically, we could get along without it, but doing so would
74047         have required living with a warning and a mandatory post-bootstrap
74048         automake rerun.
74049         * build-aux/bootstrap (gnulib_mk_hook): Remove definition, too.
74050         (bootstrap_post_import_hook): New function.
74051         Invoke it after gnulib-tool --import and before autoreconf.
74053 2012-01-18  Jim Meyering  <meyering@redhat.com>
74055         gitlog-to-changelog: don't use "no_"-prefixed variable name
74056         * build-aux/gitlog-to-changelog (main): Use getopt's "!" attribute
74057         to enable both --cluster and --no-cluster.  Change variable name,
74058         s/\$no_cluster/$cluster/, and reverse usage to match.
74060         gitlog-to-changelog: use "||", not "or" in expressions
74061         * build-aux/gitlog-to-changelog (main): Use "||", not "or" in
74062         expressions.
74064 2012-01-17  Joel E. Denny  <joeldenny@joeldenny.org>
74066         gitlog-to-changelog: new option --no-cluster
74067         * build-aux/gitlog-to-changelog: New option --no-cluster, disables
74068         clustering of adjacent commit messages.
74070 2012-01-17  Jim Meyering  <meyering@redhat.com>
74072         maint: spell file systems with two words, not one
74073         * m4/ls-mntd-fs.m4 (MOUNTED_INTERIX_STATVFS): Spell file systems with
74074         two words, not one.
74076 2012-01-16  Jim Meyering  <meyering@redhat.com>
74078         bootstrap: add a FIXME comment to ensure we eventually remove the hack
74079         * build-aux/bootstrap (gnulib_tool_options): Add comment.
74081 2012-01-16  Eric Blake  <eblake@redhat.com>
74083         bootstrap: cater to autoconf 2.59
74084         * build-aux/bootstrap (AUTORECONF): Work even when --no-recursive
74085         is not available.
74087         bootstrap: properly check for libtool
74088         * build-aux/bootstrap (libtoolize): Also run libtool when older
74089         usage is detected.
74091 2012-01-15  Bruno Haible  <bruno@clisp.org>
74093         Improve support for MSVC 9.
74094         * lib/unistd.in.h: Include <io.h> when needed to avoid redefinition
74095         clashes on MSVC.
74096         * lib/fcntl.in.h: Likewise.
74097         * lib/stdlib.in.h: Likewise.
74098         * lib/sys_stat.in.h: Likewise.
74100 2011-01-15  Stefano Lattarini  <stefano.lattarini@gmail.com>
74102         gnupload: we hold the master copy of this script now
74103         For motivation and more information, see:
74104         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00222.html>
74105         * build-aux/gnupload: Make it clear in the heading comments that the
74106         master copy of this file is maintained by gnulib.  Since we are at
74107         it, bump its copyright year and ...
74108         ($scriptversion): ... the date in its version.
74109         ($usage): Patches and bug reports should be sent to the gnulib list,
74110         not the automake one.
74111         * config/srclist.txt: Don't try to sync 'gnupload' from automake
74112         anymore.
74114 2012-01-15  Bruno Haible  <bruno@clisp.org>
74116         Fix module 'random'.
74117         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether random, srandom,
74118         initstate, setstate are declared.
74120 2012-01-14  Bruno Haible  <bruno@clisp.org>
74122         Tests for module 'random'.
74123         * modules/random-tests: New file.
74124         * tests/test-random.c: New file, based on tests/test-random_r.c.
74126         New module 'random'.
74127         * lib/stdlib.in.h (random, srandom, initstate, setstate): New
74128         declarations.
74129         * lib/random.c: New file, based on glibc/stdlib/random.c.
74130         * m4/random.m4: New file.
74131         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_RANDOM,
74132         HAVE_RANDOM.
74133         * modules/stdlib (Makefile.am): Substitute GNULIB_RANDOM, HAVE_RANDOM.
74134         * modules/random: New file.
74135         * config/srclist.txt: Add an entry for random.c.
74136         * doc/posix-functions/random.texi: Mention the 'random' module.
74137         * doc/posix-functions/initstate.texi: Likewise.
74138         * doc/posix-functions/setstate.texi: Likewise.
74139         * doc/posix-functions/srandom.texi: Likewise.
74141 2012-01-12  Bruno Haible  <bruno@clisp.org>
74143         random_r: Use common idioms.
74144         * lib/random_r.c: Include <stdlib.h> first.
74146         random_r: Override incompatible API on AIX, OSF/1.
74147         * lib/stdlib.in.h (random_r, srandom_r, initstate_r, setstate_r):
74148         Override the system function if REPLACE_RANDOM_R is 1.
74149         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Require AC_CANONICAL_HOST. On AIX
74150         and OSF/1, set REPLACE_RANDOM_R.
74151         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_RANDOM_R.
74152         * modules/stdlib (Makefile.am): Substitute REPLACE_RANDOM_R.
74153         * modules/random_r (configure.ac): Test REPLACE_RANDOM_R.
74154         * doc/glibc-functions/initstate_r.texi: Mention the AIX, OSF/1 problem.
74155         * doc/glibc-functions/random_r.texi: Likewise.
74156         * doc/glibc-functions/setstate_r.texi: Likewise.
74158         random_r: Support for MSVC 9.
74159         * lib/random_r.c: Include stdint.h, not inttypes.h.
74161 2012-01-12  Eric Blake  <eblake@redhat.com>
74163         inet_ntop: guard extra work by IF_LINT
74164         * lib/inet_ntop.c (inet_ntop6): Mark spurious initialization, for
74165         better code generation when not checking for warnings.
74166         Suggested by Paul Eggert and Jim Meyering.
74168         strptime: fix regression on mingw
74169         * lib/strptime.c (__strptime_internal) [!_LIBC && !HAVE_TM_GMTOFF]:
74170         Fix regression.  Reported by Bruno Haible.
74172 2012-01-11  Reuben Thomas  <rrt@sc3d.org>
74173             Bruno Haible  <bruno@clisp.org>
74175         copy-file: add error-code-returning variant.
74176         * lib/copy-file.h (GL_COPY_ERR_*): New enumeration items.
74177         (qcopy_file_preserving): New declaration.
74178         * lib/copy-file.c (qcopy_file_preserving): Renamed from
74179         copy_file_preserving. Change return type to 'int'. Don't emit an error
74180         message here.
74181         (copy_file_preserving): New function.
74182         * tests/test-copy-file.c: Include <stdlib.h>.
74183         (main): Test qcopy_file_preserving if the environment variable
74184         NO_STDERR_OUTPUT is set.
74185         * tests/test-copy-file-1.sh: Invoke test-copy-file.sh a second time,
74186         with NO_STDERR_OUTPUT
74187         * tests/test-copy-file-2.sh: Likewise.
74189 2012-01-10  Bruno Haible  <bruno@clisp.org>
74191         copy-file: Use 'quote' module consistently.
74192         * lib/copy-file.c (copy_file_preserving): Use quote().
74194         copy-file: Refactor.
74195         * lib/copy-file.c: Include quote.h.
74196         (copy_file_preserving): Call qcopy_acl instead of copy_acl. Emit error
74197         message here.
74198         * modules/copy-file (Depends-on): Add quote.
74200         acl: Export qcopy_acl.
74201         * lib/acl.h (qcopy_acl): New declaration.
74202         * lib/copy-acl.c (qcopy_acl): Make non-static.
74204         acl: Rename a local variable.
74205         * lib/set-mode-acl.c (set_acl): Use same variable name as in copy_acl.
74207         acl: Align return values of copy_acl and qcopy_acl.
74208         * lib/copy-acl.c (copy_acl): Return the same value as qcopy_acl,
74209         maybe < -1.
74211 2012-01-11  Eric Blake  <eblake@redhat.com>
74213         strptime: silence gcc warnings
74214         * lib/strptime.c (__strptime_internal) [!_NL_CURRENT],
74215         [!_LIBC && !HAVE_TM_GMTOFF]: Avoid unused variables.
74216         Reported by Daniel P. Berrange.
74218         inet_ntop: silence gcc warning
74219         * lib/inet_ntop.c (inet_ntop6): Initialize best.base.
74220         Reported by Daniel P. Berrange.
74222 2012-01-11  Dmitry V. Levin  <ldv@altlinux.org>
74224         getloadavg test: skip the test on GNU/Linux without /proc mounted
74225         GNU libc implements getloadavg(3) on Linux by parsing /proc/loadavg
74226         file.  When /proc is not mounted, it always fails with ENOENT.
74227         * tests/test-getloadavg.c (main): Treat ENOENT return code from
74228         getloadavg(3) the same way as ENOSYS and ENOTSUP.
74230 2012-01-10  Bruno Haible  <bruno@clisp.org>
74232         regex: Avoid link error on MSVC 9.
74233         * modules/regex (Depends-on): Add wctype.
74235 2012-01-10  Bruno Haible  <bruno@clisp.org>
74237         doc: Mention --with-tests option.
74238         * gnulib-tool (func_usage): Suggest --with-tests for --test etc.
74239         * doc/gnulib.texi (Extra tests modules): Mention the need to pass
74240         --with-tests.
74241         Reported by Reuben Thomas.
74243 2012-01-10  Reuben Thomas  <rrt@sc3d.org>
74245         users.txt: order package names lexicographically.
74246         * users.txt: Order package names lexicographically.
74248 2012-01-10  Jim Meyering  <meyering@redhat.com>
74250         maint.mk: fix description in comment
74251         * top/maint.mk (require_exactly_one_NL_at_EOF_): Fix comment.
74253         ignore-value: remove deprecated ignore_ptr function
74254         * lib/ignore-value.h (ignore_ptr): Remove deprecated function.
74255         * NEWS: Note this.
74257 2012-01-09  Jim Meyering  <meyering@redhat.com>
74259         test-init.sh: avoid a subshell
74260         * tests/test-init.sh: Remove protective subshell.
74261         Suggested by Bernhard Voelker.  While a subshell is normally
74262         required to protect against older shells (Solaris, FreeBSD) that
74263         warn about a missing program before performing redirection, the
74264         shell-selection tests performed by init.sh probably exclude any
74265         offending shell.
74267 2012-01-08  Bruno Haible  <bruno@clisp.org>
74269         setlocale tests: Avoid test failure on Solaris 11.0.
74270         * tests/test-setlocale2.sh: Use 'env' to set the LC_ALL environment
74271         variable.
74273 2012-01-08  Bruno Haible  <bruno@clisp.org>
74275         posix_spawn_file_actions_addopen: Work around Solaris 11.0 bug.
74276         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Initialize
74277         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN.
74278         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): New
74279         macro.
74280         * lib/spawn.in.h (posix_spawn_file_actions_addopen): Test
74281         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN, not REPLACE_POSIX_SPAWN.
74282         * lib/spawn_faction_addopen.c: Add workaround implementation if
74283         HAVE_WORKING_POSIX_SPAWN.
74284         * modules/spawn (Makefile): Substitute
74285         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN.
74286         * modules/posix_spawn_file_actions_addopen (configure.ac): Invoke
74287         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN. Test
74288         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN, not REPLACE_POSIX_SPAWN.
74289         (Depends-on): Update conditions.
74290         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Mention
74291         the Solaris 11 bug.
74293 2012-01-08  Bruno Haible  <bruno@clisp.org>
74295         posix_spawn_file_actions_adddup2: Work around Solaris 11.0 bug.
74296         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Initialize
74297         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2.
74298         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2): New
74299         macro.
74300         * lib/spawn.in.h (posix_spawn_file_actions_adddup2): Test
74301         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2, not REPLACE_POSIX_SPAWN.
74302         * lib/spawn_faction_adddup2.c: Add workaround implementation if
74303         HAVE_WORKING_POSIX_SPAWN.
74304         * modules/spawn (Makefile): Substitute
74305         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2.
74306         * modules/posix_spawn_file_actions_adddup2 (configure.ac): Invoke
74307         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2. Test
74308         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2, not REPLACE_POSIX_SPAWN.
74309         (Depends-on): Update conditions.
74310         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Mention
74311         the Solaris 11 bug.
74313 2012-01-08  Bruno Haible  <bruno@clisp.org>
74315         posix_spawn_file_actions_addclose: Work around Solaris 11.0 bug.
74316         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Initialize
74317         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE.
74318         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Define
74319         HAVE_WORKING_POSIX_SPAWN.
74320         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE): New macro.
74321         * lib/spawn.in.h (posix_spawn_file_actions_addclose): Test
74322         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE, not REPLACE_POSIX_SPAWN.
74323         * lib/spawn_faction_addclose.c: Add workaround implementation if
74324         HAVE_WORKING_POSIX_SPAWN.
74325         * modules/spawn (Makefile): Substitute
74326         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE.
74327         * modules/posix_spawn_file_actions_addclose (configure.ac): Invoke
74328         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE. Test
74329         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE, not REPLACE_POSIX_SPAWN.
74330         (Depends-on): Update conditions.
74331         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
74332         the Solaris 11 bug.
74334 2012-01-08  Bruno Haible  <bruno@clisp.org>
74336         doc: Update for Solaris 11.0.
74337         * doc/*/*.texi: Mention Solaris 11.0 where appropriate.
74338         * m4/printf.m4: Update comments.
74340 2012-01-08  Bruno Haible  <bruno@clisp.org>
74342         mktime: Avoid compilation error on Solaris 11.
74343         * lib/mktime.c (WRAPV): Define to 0 on all non-glibc systems.
74345 2012-01-08  Bruno Haible  <bruno@clisp.org>
74347         doc: Small fix.
74348         * doc/posix-headers/nl_types.texi: Correct platforms list.
74350 2012-01-08  Simon Josefsson  <simon@josefsson.org>
74352         Add lgpl-3.0 module.
74353         * MODULES.html.sh (Support for building documentation): Add
74354         lgpl-3.0.
74355         * modules/lgpl-3.0: New file.
74357 2012-01-08  Jim Meyering  <meyering@redhat.com>
74359         select.c: indent with spaces, not TABs
74360         * lib/select.c (windows_poll_handle): Indent with spaces, not TABs.
74362 2012-01-07  Paolo Bonzini  <bonzini@gnu.org>
74364         quotearg: do not use grave accent for left quote
74365         * lib/quotearg.c (gettext_quote): Map "`" to "'" for
74366         locale_quoting_style.
74367         (quotearg_buffer_restyled): Fix example.
74368         * tests/test-quotearg-simple.c (results_g): Adjust test vectors.
74370 2012-01-07  Paolo Bonzini  <bonzini@gnu.org>
74372         quotearg: fall back to Unicode single quotes in UTF-8, GB-18030 locales
74373         Most programs do not have translation catalogs for English and much
74374         less separate catalogs for British and American English.  Drop the
74375         suggestion to translators about these two, and provide it
74376         automatically for Unicode locales.  Like most programs, even those
74377         using American English, we use single quotation marks.  This conflicts
74378         with the American typographic convention, but works better when you
74379         cite the entire error message within double quotes.  It also tries not
74380         to clash with established practice and with what non-gnulib programs
74381         will usually do.
74382         * lib/quotearg.c (gettext_quote): Hard-code U+2018 and U+2019 when
74383         using an UTF-8 or GB-18030 locale.  The list of other locales with
74384         quotes was provided by Bruno Haible.
74385         (quotearg_buffer_restyled): Adjust instructions to translators.
74386         * lib/quotearg.h (locale_quoting_style): Do not put an example in the
74387         text, since this would be wrong when using Unicode.
74388         * modules/quotearg: Depend on c-strcaseeq.
74390 2012-01-07  Paolo Bonzini  <bonzini@gnu.org>
74392         quotearg: fix Wikipedia link
74393         * lib/quotearg.c (quotearg_buffer_restyled): Fix link to Wikipedia.
74395 2012-01-07  Simon Josefsson  <simon@josefsson.org>
74397         Fix for mingw with MSVC9.
74398         * m4/ld-version-script.m4: Check that compiler rejects version
74399         scripts with syntax errors.  Reported by Bruno Haible
74400         <bruno@clisp.org>.
74402 2012-01-06  Bruno Haible  <bruno@clisp.org>
74404         Talk about "native Windows API", not "Woe32".
74405         * lib/accept4.c: Update comments to mention native Windows.
74406         * lib/execute.c: Likewise.
74407         * lib/fatal-signal.c: Likewise.
74408         * lib/localcharset.c: Likewise.
74409         * lib/nanosleep.c: Likewise.
74410         * lib/nl_langinfo.c: Likewise.
74411         * lib/pclose.c: Likewise.
74412         * lib/pipe-filter-gi.c: Likewise.
74413         * lib/pipe-filter-ii.c: Likewise.
74414         * lib/pipe.c: Likewise.
74415         * lib/pipe2.c: Likewise.
74416         * lib/popen.c: Likewise.
74417         * lib/progreloc.c: Likewise.
74418         * lib/relocatable.c: Likewise.
74419         * lib/sigaction.c: Likewise.
74420         * lib/sigprocmask.c: Likewise.
74421         * lib/spawn-pipe.h: Likewise.
74422         * lib/spawn-pipe.c: Likewise.
74423         * lib/spawni.c: Likewise.
74424         * lib/stat-time.h: Likewise.
74425         * lib/w32spawn.h: Likewise.
74426         * tests/test-isatty.c: Likewise.
74427         * lib/config.charset: More comments.
74428         * doc/gnulib-intro.texi: Mention native Windows.
74429         * doc/posix-functions/_Exit_C99.texi: Likewise.
74430         * doc/posix-headers/fcntl.texi: Likewise.
74432 2012-01-06  Guillem Jover  <guillem@hadrons.org>  (tiny change)
74434         argp: Avoid crash if translator uses % characters in a translation.
74435         * lib/argp-parse.c (argp_version_parser): Use a "%s" format string.
74436         Reported by Mats Erik Andersson <gnu@gisladisker.se>.
74438 2012-01-06  Paul Eggert  <eggert@cs.ucla.edu>
74440         doc: C11 and C++11 are now official
74441         * doc/posix-headers/assert.texi, doc/posix-headers/stdalign.texi:
74442         * doc/verify.texi, stdalign.in.h, verify.h, m4/gnulib-common.m4:
74443         * m4/stdalign.m4, modules/assert-h, modules/snippet/_Noreturn:
74444         * modules/stdalign:
74445         Replace references to draft C1X to C11, and to draft C++0X to C++11.
74447 2012-01-06  Bruno Haible  <bruno@clisp.org>
74449         uc-is-grapheme-break tests: Tweak.
74450         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Fix an error
74451         message.
74453 2012-01-06  Bruno Haible  <bruno@clisp.org>
74455         test-init.sh: correct the test for diff -u
74456         * tests/test-init.sh: Also redirect stdout to /dev/null.
74458 2012-01-05  Paul Eggert  <eggert@cs.ucla.edu>
74460         Use ', not `, for quoting output.
74461         * build-aux/announce-gen (usage, sizes, print_news_deltas)
74462         (print_changelog_deltas, get_tool_versions, main program):
74463         * build-aux/git-version-gen:
74464         * build-aux/gitlog-to-changelog (usage, parse_amend_file):
74465         * build-aux/move-if-change (help):
74466         * build-aux/useless-if-before-free (usage, main program):
74467         * check-module (parse_module_file, usage)
74468         (find_included_lib_files, check_module):
74469         * lib/argmatch.c (main) [TEST]:
74470         * lib/argp-help.c (_help):
74471         * lib/getopt1.c (main) [TEST]:
74472         * lib/git-merge-changelog.c (usage):
74473         * lib/xstrtol-error.c (xstrtol_error):
74474         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA):
74475         * m4/argz.m4 (gl_FUNC_ARGZ):
74476         * m4/bison.m4 (gl_BISON):
74477         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU):
74478         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
74479         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
74480         * m4/fpending.m4 (gl_PREREQ_FPENDING):
74481         * m4/gc-random.m4 (gl_GC_RANDOM):
74482         * m4/intl.m4 (gt_CHECK_DECL):
74483         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK):
74484         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT)
74485         (AC_TYPE_UNSIGNED_LONG_LONG_INT):
74486         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS):
74487         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK):
74488         * m4/onceonly.m4 (AC_CHECK_FUNCS_ONCE):
74489         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION):
74490         * tests/test-dirname.c (main):
74491         * tests/test-getpass.c (main):
74492         * tests/test-iconvme.c (main):
74493         * tests/test-parse-datetime.c (LOG):
74494         * tests/test-xstrtoimax.sh:
74495         * tests/test-xstrtol.sh:
74496         * tests/test-xstrtoll.sh:
74497         * tests/test-xstrtoumax.sh:
74498         * tests/unigbrk/test-uc-is-grapheme-break.c (main):
74499         * top/GNUmakefile (abort-due-to-no-makefile):
74500         Quote 'like this', not `like this', as per the recent change to
74501         the GNU coding standards.
74503 2012-01-05  Bruno Haible  <bruno@clisp.org>
74505         strtoimax: Don't force a replacement on systems where intmax_t is int.
74506         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Use a different test if
74507         'intmax_t' is not larger than 'int'.
74508         Reported by Pádraig Brady <P@draigBrady.com>.
74510 2012-01-05  Bruno Haible  <bruno@clisp.org>
74512         doc: Mention NetBSD bugs.
74513         * doc/posix-functions/*printf.texi: Mention a NetBSD 5.1 bug.
74514         * doc/posix-functions/nl_langinfo.texi: Mention another NetBSD 5.1 bug.
74516 2012-01-05  Bruno Haible  <bruno@clisp.org>
74518         strtoumax tests: Enhance tests.
74519         * tests/test-strtoumax.c (main): Add tests for large values.
74521 2012-01-05  Bruno Haible  <bruno@clisp.org>
74523         strtoimax: Work around AIX 5.1 bug.
74524         * lib/inttypes.in.h (strtoimax): Allow overriding the system's
74525         definition.
74526         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Check against the AIX 5.1 bug.
74527         Set HAVE_STRTOIMAX.
74528         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Initialize
74529         REPLACE_STRTOIMAX.
74530         * modules/inttypes-incomplete (Makefile.am): Substitute
74531         REPLACE_STRTOIMAX.
74532         * modules/strtoimax (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
74533         (configure.ac): Test HAVE_STRTOIMAX, REPLACE_STRTOIMAX.
74534         (Depends-on): Update conditions.
74535         * tests/test-strtoimax.c (main): Add tests for large values.
74536         * doc/posix-functions/strtoimax.texi: Mention the AIX 5.1 bug.
74538 2012-01-05  Bruno Haible  <bruno@clisp.org>
74540         inttypes: Modernize.
74541         * lib/inttypes.in.h (strtoimax, strtoumax): Use the C++ safe idioms.
74542         * modules/inttypes-incomplete (Depends-on): Add snippet/c++defs.
74543         (Makefile.am): Update inttypes.h rule.
74545 2012-01-05  Jim Meyering  <meyering@redhat.com>
74547         init.sh: don't waste a subshell just to redirect stderr
74548         * tests/init.sh: In testing for diff -u and diff -c, use a
74549         stderr-redirecting exec inside `...` rather than a subshell.
74551         test-init.sh: avoid failure on HP-UX 11.00
74552         * tests/test-init.sh: Skip "diff -u"-comparing step when compare
74553         resolves to diff -c or cmp.  Reported by Bruno Haible.
74555 2012-01-05  Bruno Haible  <bruno@clisp.org>
74557         Tests for module 'strtoull'.
74558         * modules/strtoull-tests: New file.
74559         * tests/test-strtoull.c: New file, based on tests/test-strtoumax.c.
74561 2012-01-05  Bruno Haible  <bruno@clisp.org>
74563         Tests for module 'strtoll'.
74564         * modules/strtoll-tests: New file.
74565         * tests/test-strtoll.c: New file, based on tests/test-strtoimax.c.
74567 2012-01-05  Bruno Haible  <bruno@clisp.org>
74569         Tests for module 'strtoul'.
74570         * modules/strtoul-tests: New file.
74571         * tests/test-strtoul.c: New file, based on tests/test-strtoumax.c.
74573 2012-01-05  Bruno Haible  <bruno@clisp.org>
74575         Tests for module 'strtol'.
74576         * modules/strtol-tests: New file.
74577         * tests/test-strtol.c: New file, based on tests/test-strtoimax.c.
74579 2012-01-04  Jim Meyering  <meyering@redhat.com>
74581         test-init.sh: accommodate Solaris 5.10's different diff -u output
74582         * tests/test-init.sh: Also exempt @@ lines from the comparison
74583         of diff output, since Solaris 5.10 and GNU diff formats differ.
74584         Reported by Stefano Lattarini.
74586 2012-01-04  Paul Eggert  <eggert@cs.ucla.edu>
74588         test-posixtm: don't assume signed integer wraparound
74589         * tests/test-posixtm.c (main): Don't assume wraparound semantics
74590         after signed integer overflow.  Inspired by (though it may not
74591         fix) Bruno Haible's bug report in
74592         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00066.html>.
74594         Spell out "Windows 9x" and "Windows XP".
74595         * lib/poll.c, lib/select.c: In comments, replace "Win9x" with
74596         "Windows 9x" and "WinXP" with "Windows XP".
74598 2012-01-04  Jim Meyering  <meyering@redhat.com>
74600         test-vc-list-files-cvs.sh: remove obsolete comment
74601         * tests/test-vc-list-files-cvs.sh: Remove obsolete comment about
74602         double exit.  Now that's all encapsulated via skip_ and Exit.
74604 2012-01-04  Bruno Haible  <bruno@clisp.org>
74606         Talk about "native Windows API", not "Win32".
74607         * lib/classpath.c: Update comments to mention native Windows.
74608         * lib/csharpexec.c: Likewise.
74609         * lib/dup2.c: Likewise.
74610         * lib/error.c: Likewise.
74611         * lib/fcntl.c: Likewise.
74612         * lib/filename.h: Likewise.
74613         * lib/findprog.c: Likewise.
74614         * lib/get-rusage-as.c: Likewise.
74615         * lib/get-rusage-data.c: Likewise.
74616         * lib/getpagesize.c: Likewise.
74617         * lib/javaexec.c: Likewise.
74618         * lib/msvc-inval.c: Likewise.
74619         * lib/msvc-nothrow.c: Likewise.
74620         * lib/nanosleep.c: Likewise.
74621         * lib/nonblocking.c: Likewise.
74622         * lib/printf-parse.c: Likewise.
74623         * lib/setlocale.c: Likewise.
74624         * lib/sigaction.c: Likewise.
74625         * lib/strerror_r.c: Likewise.
74626         * lib/tmpdir.c: Likewise.
74627         * lib/vasnprintf.c: Likewise.
74628         * lib/w32spawn.h: Likewise.
74629         * lib/waitpid.c: Likewise.
74630         * lib/stdio.in.h (fdopen, fopen, freopen): Likewise.
74631         * m4/locale-ar.m4: Likewise.
74632         * m4/locale-fr.m4: Likewise.
74633         * m4/locale-ja.m4: Likewise.
74634         * m4/locale-tr.m4: Likewise.
74635         * m4/locale-zh.m4: Likewise.
74636         * m4/printf.m4: Likewise.
74637         * tests/test-cloexec.c: Likewise.
74638         * tests/test-copy-acl.sh: Likewise.
74639         * tests/test-copy-file.sh: Likewise.
74640         * tests/test-file-has-acl.sh: Likewise.
74641         * tests/test-set-mode-acl.sh: Likewise.
74642         * tests/test-dup-safer.c: Likewise.
74643         * tests/test-dup2.c: Likewise.
74644         * tests/test-dup3.c: Likewise.
74645         * tests/test-fcntl.c: Likewise.
74646         * tests/test-nonblocking-pipe.h: Likewise.
74647         * tests/test-nonblocking-socket.h: Likewise.
74648         * tests/test-pipe.c: Likewise.
74649         * tests/test-pipe2.c: Likewise.
74650         * tests/test-spawn-pipe-child.c: Likewise.
74651         * doc/acl-resources.txt: Likewise.
74652         * lib/getaddrinfo.c (WINDOWS_NATIVE): Renamed from WIN32_NATIVE.
74653         * tests/test-poll.c (WINDOWS_NATIVE): Likewise.
74654         * tests/test-select.h (WINDOWS_NATIVE): Likewise.
74655         * lib/localcharset.c: Update comments to mention native Windows.
74656         (WINDOWS_NATIVE): Renamed from WIN32_NATIVE.
74657         * lib/localename.c: Likewise.
74658         * lib/progreloc.c: Likewise.
74659         * lib/relocatable.c: Likewise.
74660         * lib/poll.c (WINDOWS_NATIVE): Renamed from WIN32_NATIVE.
74661         (windows_compute_revents): Renamed from win32_compute_revents.
74662         (windows_compute_revents_socket): Renamed from
74663         win32_compute_revents_socket.
74664         * lib/select.c: Update comments to mention native Windows.
74665         (windows_poll_handle): Renamed from win32_poll_handle.
74666         * m4/threadlib.m4: Update comments to mention native Windows.
74667         (gl_THREADLIB_EARLY_BODY, gl_THREADLIB_BODY): Expect
74668         --enable-threads=windows instead of --enable-threads=win32. Set
74669         USE_WINDOWS_THREADS, not USE_WIN32_THREADS.
74670         * lib/glthread/lock.h: Update comments to mention native Windows.
74671         (USE_WINDOWS_THREADS): Renamed from USE_WIN32_THREADS.
74672         * lib/glthread/lock.c (USE_WINDOWS_THREADS): Renamed from
74673         USE_WIN32_THREADS.
74674         * lib/glthread/cond.h (USE_WINDOWS_THREADS): Likewise.
74675         * lib/glthread/cond.c (USE_WINDOWS_THREADS): Likewise.
74676         * lib/glthread/thread.h (USE_WINDOWS_THREADS): Likewise.
74677         * lib/glthread/thread.c (USE_WINDOWS_THREADS): Likewise.
74678         * lib/glthread/tls.h (USE_WINDOWS_THREADS): Likewise.
74679         * lib/glthread/tls.c (USE_WINDOWS_THREADS): Likewise.
74680         * lib/glthread/yield.h (USE_WINDOWS_THREADS): Likewise.
74681         * tests/test-cond.c (USE_WINDOWS_THREADS): Likewise.
74682         * tests/test-thread_create.c (USE_WINDOWS_THREADS): Likewise.
74683         * tests/test-lock.c (USE_WINDOWS_THREADS): Likewise.
74684         (TEST_WINDOWS_THREADS): Renamed from TEST_WIN32_THREADS.
74685         * tests/test-tls.c: Likewise.
74686         Rationale:
74687         Microsoft renamed the "Win32 API" to "Windows API", as it is available
74688         on both 32-bit and 64-bit Windows systems.
74689         But in gnulib, we treat Cygwin like a Unix platform, therefore the main
74690         line of distinction is between "native Windows" on one side and Unix/
74691         POSIX systems on the other side. More details in
74692         <https://lists.gnu.org/r/bug-gnulib/2012-01/msg00027.html>.
74693         Suggested by Paul Eggert.
74695 2012-01-03  Bruno Haible  <bruno@clisp.org>
74697         isatty: Support for MSVC 9.
74698         * doc/posix-functions/isatty.texi: Mention the MSVC problem.
74699         * lib/isatty.c: Include <errno.h>, msvc-inval.h.
74700         (_isatty_nothrow): New function.
74701         (isatty): Use it instead of _isatty.
74702         (IsConsoleHandle): Add comment, from Paolo Bonzini.
74703         * lib/poll.c (IsConsoleHandle): Likewise.
74704         * lib/select.c (IsConsoleHandle): Likewise.
74705         * m4/isatty.m4 (gl_FUNC_ISATTY): Fix comment. Reported by Eli Zaretskii.
74706         (gl_PREREQ_ISATTY): New macro.
74707         * modules/isatty (Depends-on): Add msvc-inval.
74708         (configure.ac): Invoke gl_PREREQ_ISATTY.
74710 2012-01-03  Jim Meyering  <meyering@redhat.com>
74712         maint.mk: remove temporary transition aid from over 1.5 years ago
74713         * top/maint.mk (_prohibit_regexp): Remove definition whose sole
74714         purpose was to aid in the transition (avoiding silent malfunction)
74715         from that old name to the new _sc_search_regexp.  This shim was
74716         added by commit 219c504b.
74718         init.sh: do not try to accommodate compare arguments starting with "-"
74719         * tests/init.sh (compare_dev_null_): Do not try to accommodate
74720         compare arguments that start with "-".  Besides, we do not worry
74721         about this when invoking diff or cmp; why start now with sed?
74722         Using "--" to separate options from argument would trigger sed
74723         failure in at least Solaris 7, HP-UX 11.00, IRIX 6.5, FreeBSD 6.4,
74724         OpenBSD 4.9 and NetBSD 5.1.  Reported by Bruno Haible.
74726 2012-01-02  Bruno Haible  <bruno@clisp.org>
74728         Enhance tests for module 'isatty'.
74729         * modules/isatty-tests (Depends-on): Add pipe-posix.
74730         * tests/test-isatty.c: Include <fcntl.h>.
74731         (DEV_NULL): New macro.
74732         (main): Test the resut of isatty() also on regular files, pipes, and
74733         /dev/null.
74735         New module 'isatty'.
74736         * lib/unistd.in.h (isatty): New declaration.
74737         * lib/isatty.c: New file, based on an idea of
74738         Bastien Roucariès <roucaries.bastien@gmail.com>.
74739         * m4/isatty.m4: New file.
74740         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether isatty is declared.
74741         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ISATTY, REPLACE_ISATTY.
74742         * modules/unistd (Makefile.am): Substitute GNULIB_ISATTY,
74743         REPLACE_ISATTY.
74744         * modules/isatty: New file.
74745         * doc/posix-functions/isatty.texi: Mention the new module.
74746         Suggested by Paolo Bonzini.
74748 2012-01-02  Bruno Haible  <bruno@clisp.org>
74750         canonicalize: Tweak 2011-12-29 commit.
74751         * lib/canonicalize.c (canonicalize_filename_mode): Fix typo in comment.
74752         * lib/canonicalize.h (canonicalize_filename_mode): Update specification.
74754 2012-01-02  Jim Meyering  <meyering@redhat.com>
74756         gitlog-to-changelog: describe input syntax in --help output
74757         * build-aux/gitlog-to-changelog (usage) [SPECIAL SYNTAX]: New section.
74759         gitlog-to-changelog: fix typo in --help: show backslash before email @
74760         * build-aux/gitlog-to-changelog (usage): An "@" was backslash-escaped
74761         in sources, but not in actual output.
74763 2011-12-30  Jim Meyering  <meyering@redhat.com>
74765         gitlog-to-changelog: don't malfunction when name contains %-directive
74766         * build-aux/gitlog-to-changelog (main): Don't let a %-directive
74767         in a name string cause trouble.  E.g., with a user name of "%s",
74768         gitlog-to-changelog would fail with "Missing argument in sprintf at..."
74770 2011-12-30  Gary V. Vaughan  <gary@gnu.org>
74772         gitlog-to-changelog: Copyright-paperwork-exempt: yes == (tiny change)
74773         * build-aux/gitlog-to-changelog (main): Map the string, at beginning
74774         of line in a git commit log, "Copyright-paperwork-exempt: yes", to
74775         the "  (tiny change)" notation that is appended to the standard
74776         ChangeLog "date  name  email" header line.
74778 2012-01-01  Jim Meyering  <meyering@redhat.com>
74780         test-framework-sh: init.sh: fix "make dist" failure
74781         When using gnulib-tool's --with-tests option and any module that
74782         depends on test-framework-sh, "make dist" would fail due to the
74783         lack of init.sh *in lib/*.  The EXTRA_DIST += init.sh is required
74784         in the gltests directory, and not in the gllib/ directory.
74785         One way to work around that is to move the EXTRA_DIST += init.sh
74786         from the primary module to the -tests one:
74787         * modules/test-framework-sh-tests (EXTRA_DIST): Add init.sh here, ...
74788         * modules/test-framework-sh (Makefile.am): ...not here.
74789         Reported by Tom G. Christensen in
74790         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/29519
74792         version-etc: update copyright year reported by --version
74793         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2012.
74795 2011-12-31  Pádraig Brady  <P@draigBrady.com>
74797         canonicalize: only stat() if required
74798         * lib/canonicalize.c (canonicalize_filename_mode):
74799         Avoid calling l?stat() when both CAN_MISSING,
74800         and CAN_NOLINKS are set, as we neither need
74801         to resolve symlinks or test component existence.
74803 2011-12-31  Paul Eggert  <eggert@cs.ucla.edu>
74805         doc: cover st_ino issues once; add OpenVMS etc.
74806         * doc/posix-functions/stat.texi (stat):
74807         * doc/posix-functions/lstat.texi (lstat):
74808         * doc/posix-functions/fstatat.texi (fstatat):
74809         * doc/posix-functions/fstat.texi (fstat):
74810         Move general 'struct stat' stuff to sys_stat.texi,
74811         leaving behind a pointer.
74812         * doc/posix-headers/sys_stat.texi (sys/stat.h):
74813         Merge duplicate info about 'struct stat' problems into here.
74814         Mention issues with OpenVMS, GNU/Linux NFS, NetApp, ClearCase,
74815         and suggest partial workarounds.
74817         same-inode: port to OpenVMS
74818         * lib/same-inode.h (SAME_INODE): Port to OpenVMS by checking all
74819         three st_ino values.
74821 2011-12-30  Pádraig Brady  <P@draigBrady.com>
74823         canonicalize: fix references to stat() and lstat()
74824         * lib/canonicalize.c (canonicalize_filename_mode):
74825         Ensure references always resolve to a replacement
74826         function if required (even via a macro).
74828 2011-12-30  Jim Meyering  <meyering@redhat.com>
74830         gitlog-to-changelog: remove a little duplication
74831         * build-aux/gitlog-to-changelog (main): Grep @lines once,
74832         rather than twice.
74834 2011-12-29  Pádraig Brady  <P@draigBrady.com>
74836         canonicalize: add support for not resolving symlinks
74837         * lib/canonicalize.h: Add the CAN_NOLINKS flag to
74838         indicate we don't want to follow symlinks.  Also
74839         provide CAN_MODE_MASK to aid setting these existing
74840         mutually exclusive values.
74841         * lib/canonicalize.c (canonicalize_filename_mode):
74842         Extract the flags from can_mode parameter, which
74843         are currently just used to select between stat()
74844         and lstat().  Also ensure that mutually exclusive
74845         values are flagged immediately as invalid.
74846         * tests/test-canonicalize.c: Verify symlinks are
74847         not followed, and that invalid flag combinations
74848         are diagnosed.
74850 2011-12-25  Jim Meyering  <meyering@redhat.com>
74852         gitlog-to-changelog: do not clump multi-paragraph entries
74853         Identical header lines (date,name,email+coauthors) are suppressed,
74854         thus putting all entries with those same characteristics under
74855         a single header.  However, when a log entry consists of two or
74856         more paragraphs, it may not be clear where it starts and ends.
74857         This change makes it so that such an entry is always separated
74858         from others by a header line, even when that header would
74859         otherwise be suppressed.
74860         * build-aux/gitlog-to-changelog: Implement the above.
74861         Inspired by a related request from Stefano Lattarini in
74862         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/29456
74864 2011-12-25  Paul Eggert  <eggert@cs.ucla.edu>
74866         announce-gen: fix `cmd' typo in diagnostic
74867         * build-aux/announce-gen (print_changelog_deltas): Fix typo in
74868         diagnostic: a missing '$' meant that the command was not output.
74870 2011-12-23  Jim Meyering  <meyering@redhat.com>
74872         test-framework-sh: distribute init.sh
74873         * modules/test-framework-sh (EXTRA_DIST): Append init.sh.
74874         Otherwise, "make -C gnulib-tests check" (at least in grep) would
74875         fail due to the lack of init.sh.
74877         maint: remove explicit Files: tests/init.sh; depend on test-framework-sh
74878         * modules/atexit-tests: Rather than listing tests/init.sh,
74879         now that there's a module for it, simply depend on that new module.
74880         * modules/closein-tests: Likewise.
74881         * modules/exclude-tests: Likewise.
74882         * modules/getcwd-tests: Likewise.
74883         * modules/perror-tests: Likewise.
74884         * modules/pread-tests: Likewise.
74885         * modules/pwrite-tests: Likewise.
74886         * modules/vc-list-files-tests: Likewise.
74887         * modules/verify-tests: Likewise.
74888         * modules/xalloc-die-tests: Likewise.
74889         * modules/xstrtoimax-tests: Likewise.
74890         * modules/xstrtol-tests: Likewise.
74891         * modules/xstrtoll-tests: Likewise.
74892         * modules/xstrtoumax-tests: Likewise.
74893         * modules/yesno-tests: Likewise.
74895 2011-12-22  Jim Meyering  <meyering@redhat.com>
74897         test-framework-sh: add minimal tests of init.sh's compare function
74898         * modules/test-framework-sh-tests: New file.
74899         * tests/test-init.sh: New file.
74901         test-framework-sh: new module
74902         * modules/test-framework-sh: New file.
74903         * MODULES.html.sh (Support for maintaining and releasing projects):
74904         List it.
74906         init.sh: do not emit simulated diff output to stderr
74907         * tests/init.sh (compare_dev_null_): Print to stdout, not stderr.
74909 2011-12-22  Reuben Thomas  <rrt@sc3d.org>
74911         .gitignore: ignore gnulib.dvi and regex.info
74912         * doc/.gitignore:add gnulib.dvi and regex.info
74914 2011-12-22  Jim Meyering  <meyering@redhat.com>
74916         init.sh: correct previous change
74917         * tests/init.sh (compare): My previous change was wrong.
74918         Don't clobber "$?".  Spotted by Stefano Lattarini and Pádraig Brady.
74920         init.sh: avoid unwarranted test failure when using "set -e"
74921         * tests/init.sh (compare): Ignore nonzero exit from compare_dev_null_.
74922         Otherwise, in a test script that uses "set -e" (like many in vc-dwim)
74923         a use like "compare exp out" would get evoke an unconditional failure.
74925 2011-12-21  Alfred M. Szmidt  <ams@gnu.org>
74927         bootstrap: fix it to honor $ACLOCAL_FLAGS once again
74928         The 2011-12-17 change, commit 767ccd40, replaced a manual invocation
74929         of aclocal that used explicit $ACLOCAL_FLAGS with an invocation of
74930         autoreconf that did not.
74931         * build-aux/bootstrap: Use $ACLOCAL_FLAGS when invoking autoreconf.
74932         Reported by Mats Erik Andersson <gnu@gisladisker.se>.
74934 2011-12-17  Jim Meyering  <meyering@redhat.com>
74936         bootstrap: remove some now-unneeded code
74937         This script arose back when gnulib-tool was young.
74938         Since then, it has seen improvements that render much of this
74939         script unnecessary.  In particular, it can now make symlinks
74940         to the files it uses.  Also, I no longer see as much value in
74941         marking files as read-only via comments.
74942         If you relied on the symlink-creation feature of the preceding
74943         version of this script, you can get most of that functionality
74944         by adding the --symlink option to the definition of
74945         gnulib_tool_option_extras in your bootstrap.conf file.
74946         * build-aux/bootstrap (AUTOPOINT, AUTORECONF): Factor out definitions.
74947         Run autopoint and libtoolize *before* gnulib-tool.
74948         After it, run an abbreviated autoreconf, rather than a loop around
74949         all tools.
74950         (slirp, bt_mark_as_generated): Remove functions.
74952 2011-12-18  Paul Eggert  <eggert@cs.ucla.edu>
74954         ftoastr: fix typo
74955         * lib/ftoastr.h: Fix misspelling in comment.
74957 2011-12-18  Reuben Thomas  <rrt@sc3d.org>
74959         * top/README-release: fix punctuation.
74961 2011-12-17  Jim Meyering  <meyering@redhat.com>
74963         bootstrap: correct the recent buildreq change
74964         The 2011-12-07 commit, 39f5f1e4, omitted some '*'s, and thus
74965         had no effect.
74966         * build-aux/bootstrap (buildreq): Bracket each search term with
74967         "*...*", so that the shell "case" statement works as intended.
74968         Add comments.
74970 2011-12-17  Bernhard Voelker  <mail@bernhard-voelker.de>
74972         build: let bootstrap resort to wget when downloading .po files
74973         * build-aux/bootstrap (download_po_files): Fallback to wget when
74974         downloading the .po files via rsync fails.  This is necessary to
74975         bootstrap from behind a strict firewall.
74977 2011-12-15  Paul Eggert  <eggert@cs.ucla.edu>
74979         stdint: don't assume C++11 when compiling with g++
74980         Problem reported for glibc 2.14 and g++ by Alexander V. Lukyanov in
74981         <http://lists.gnu.org/r/bug-gnulib/2011-12/msg00099.html>.
74982         * m4/stdint.m4 (gl_STDINT_H): Don't go to extra work to make it
74983         work also in C++ before C++11, as that improperly inhibits
74984         generating a substitute stdint.h for that case.
74986 2011-12-15  Paul Eggert  <eggert@cs.ucla.edu>
74988         alloca: protect comment from gnulib-tool
74989         * lib/alloca.c: Change "GCC version 2" to "GCC 2" in comment, so
74990         that gnulib-tool doesn't think it's a license, and munge it to
74991         say "GCC version 3".
74993 2011-12-15  Ludovic Courtès  <ludo@gnu.org>  (tiny change)
74995         localcharset: Use an absolute path in TESTS_ENVIRONMENT.
74996         * modules/localcharset (LOCALCHARSET_TESTS_ENVIRONMENT): Use
74997         $(abs_top_builddir) instead of $(top_builddir).
74999 2011-12-14  Alex Nelson  <ajnelson@cs.ucsc.edu>  (tiny change)
75001         strftime-tests: also test nanoseconds
75002         * tests/test-strftime.c (T): Add a test of %N.
75004 2011-12-13  Paul Eggert  <eggert@cs.ucla.edu>
75006         inttypes, stdint: add C++11 support
75007         C++11 says there's no need to define __STDC_CONSTANT_MACROS etc.
75008         when including inttypes.h and stdint.h.  Support this change to
75009         the standard.
75010         * doc/posix-headers/inttypes.texi (inttypes.h):
75011         * doc/posix-headers/stdint.texi (stdint.h): Document this.
75012         * lib/inttypes.in.h (__STDC_FORMAT_MACROS) [! __cplusplus]:
75013         Define if not defined already, for the benefit of pre-C++11 hosts.
75014         Define the standard format macros (e.g., PRId8) always.
75015         * lib/stdint.in.h (__STDC_CONSTANT_MACROS, __STDC_LIMIT_MACROS):
75016         Likewise, if __cpluspus.  Define the standard constant and limit
75017         macros (e.g., INT8_C, INT8_MAX) always.
75018         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): Do not define
75019         GL_TRIGGER_STDC_LIMIT_MACROS or __STDC_LIMIT_MACROS; no longer needed.
75020         * m4/stdint.m4 (gl_STDINT_H): Update comments about these macros.
75021         * tests/test-inttypes.c (__STDC_LIMIT_MACROS, __STDC_CONSTANT_MACROS)
75022         (__STDC_FORMAT_MACROS): Do not define, since we assume C++11 API now.
75023         * tests/test-stdint.c (__STDC_LIMIT_MACROS, __STDC_CONSTANT_MACROS):
75024         Likewise.
75026 2011-12-12  Paul Eggert  <eggert@cs.ucla.edu>
75028         nonblocking tests: Fix test failure on Linux/PPC.
75029         Suggested by Prerna Saxena in
75030         <http://lists.gnu.org/r/bug-gnulib/2011-12/msg00080.html>.
75031         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/PPC64]:
75032         Set to 1100000.
75034 2011-12-12  Jim Meyering  <meyering@redhat.com>
75036         argmatch: don't hard-code `' when listing valid option arguments
75037         * lib/argmatch.c (argmatch_valid): Don't hard-code `%s'.  Instead,
75038         use the quote function to add quotes.  Use fputs rather than
75039         fprintf for the format string with no format directive.
75041 2011-12-07  Eric Blake  <eblake@redhat.com>
75043         bootstrap: detect tools required by gnulib-tool
75044         * build-aux/bootstrap (buildreq): Provide minimum implicit
75045         dependencies.
75046         * DEPENDENCIES: Mention patch as a prereq.
75048 2011-12-04  Bruno Haible  <bruno@clisp.org>
75050         sethostname: Port to Windows platforms.
75051         * lib/sethostname.c: Provide an alternate implementation for Windows
75052         platforms.
75053         * tests/test-sethostname2.c (geteuid): Redefine on Cygwin.
75054         (main): Skip the test if sethostname() fails with EPERM. On Windows
75055         platforms, don't check the result of gethostname().
75057 2011-12-04  Bruno Haible  <bruno@clisp.org>
75058             Jim Meyering  <meyering@redhat.com>
75060         tests: Avoid spurious error message on platforms without mktemp program.
75061         * tests/init.sh (mktempd_): Run mktemp in a subcommand.
75063 2011-12-04  Bruno Haible  <bruno@clisp.org>
75065         sethostname: Fix documentation.
75066         * doc/glibc-functions/sethostname.texi: Move the Solaris problem to the
75067         "not fixed" section.
75069 2011-12-03  Bruno Haible  <bruno@clisp.org>
75071         gnulib-tool: Verify that the License field is present and non-empty.
75072         * gnulib-tool (func_get_license_raw): New function, extracted from
75073         func_get_license.
75074         (func_get_license): Use it. Warn if the module is not a test module and
75075         has no license.
75076         Suggested by Jim Meyering.
75078 2011-12-03  Bruno Haible  <bruno@clisp.org>
75080         sethostname tests: Fix link error on mingw.
75081         * tests/test-sethostname1.c: New file, extracted from
75082         tests/test-sethostname.c.
75083         * tests/test-sethostname2.c: New file, extracted from
75084         tests/test-sethostname.c.
75085         * tests/test-sethostname.c: Remove file.
75086         * modules/sethostname-tests (Files): Add tests/test-sethostname1.c,
75087         tests/test-sethostname2.c. Remove tests/test-sethostname.c.
75088         (Depends-on): Add gethostname.
75089         (Makefile.am): Compile both test-sethostname1 and test-sethostname2.
75090         Link the latter with $(GETHOSTNAME_LIB).
75092         sethostname tests: Fix compilation error on mingw.
75093         * tests/test-sethostname.c: Don't include <sys/types.h>.
75094         (geteuid): Use a dummy value without uid_t.
75095         * modules/sethostname-tests (Depends-on): Remove sys_types.
75097         sethostname tests: Avoid a gcc warning.
75098         * tests/test-sethostname.c (main): Remove an unused variable.
75100         Tweak last commit.
75101         * modules/sethostname-tests (Files): Sort by decreasing importance.
75102         (configure.ac): Check for geteuid.
75103         * tests/test-sethostname.c (main): Emit error messages to stderr. Skip
75104         the test when there's nothing to test. Drop an unnecessary cast.
75105         Improve an error message. Verify that the final sethostname() call
75106         succeeds.
75108 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
75110         Add a test suite for the sethostname module.
75111         * modules/sethostname-tests: New file.  A test program
75112         for the sethostname module.
75113         * tests/test-sethostname.c: Likewise.
75115 2011-12-03  Bruno Haible  <bruno@clisp.org>
75117         Tweak last commit.
75118         * lib/unistd.in.h (sethostname): Keep declarations in alphabetic order.
75119         Fix preprocessor directives indentation. Fix typos.
75120         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Keep alphabetic order.
75121         * modules/unistd (Makefile): Likewise.
75123 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
75125         Integrate the sethostname module into unistd.
75126         * lib/unistd.in.h: Integrate the SETHOSTNAME preprocessor handling
75127         into the unistd.h header.
75128         * m4/unistd_h.m4: Setup the autoconf handling for the SETHOSTNAME
75129         preprocessor directives.
75130         * modules/unistd: Setup the Makefile substitutions of the
75131         SETHOSTNAME preprocessor directives.
75133 2011-12-03  Bruno Haible  <bruno@clisp.org>
75135         Tweak last commit.
75136         * lib/sethostname.c: Don't include <string.h>.
75137         (sethostname): No need to copy the argument string to the stack. Don't
75138         call clearerr. Preserve errno when fprintf failed.
75139         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): Comment about HOST_NAME_MAX.
75140         Don't invoke AC_REPLACE_FUNCS.
75141         * modules/sethostname (Link): Remove empty section.
75142         * doc/glibc-functions/sethostname.texi: Gnulib does not fix the ENOSYS
75143         failure problem.
75145 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
75147         New module 'sethostname'.
75148         * lib/sethostname.c (sethostname): New file.  Provide sethostname
75149         for systems that lack it.
75150         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): New file.  Detection of
75151         sethostname declaration and function.
75152         * modules/sethostname: New file.  Define the sethostname module.
75154 2011-12-03  Bruno Haible  <bruno@clisp.org>
75156         Tweak last commit.
75157         * m4/gethostname.m4 (gl_PREREQ_HOST_NAME_MAX): Trim blank line.
75159 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
75161         Split the HOST_NAME_MAX detection into a separate m4 macro.
75162         * m4/gethostname.m4 (gl_PREREQ_HOST_NAME_MAX): Make this a separate
75163         macro so it can be used by the pending sethostname module.
75165 2011-12-03  Bruno Haible  <bruno@clisp.org>
75167         Fix module descriptions syntax.
75168         * modules/argv-iter (License): Fix syntax.
75169         * modules/di-set (License): Likewise.
75170         * modules/ino-map (License): Likewise.
75171         Reported by Stefano Lattarini <stefano.lattarini@gmail.com>.
75173 2011-12-02  Paul Eggert  <eggert@cs.ucla.edu>
75175         stdalign: port to Clang 3.0
75176         Problem reported by Simon Josefsson in
75177         <http://lists.gnu.org/r/bug-gnulib/2011-12/msg00005.html>.
75178         * doc/posix-headers/stdalign.texi (stdalign.h): Mention Clang 3.0,
75179         which has <stdalign.h> but which does not define alignof.
75180         * m4/stdalign.m4 (gl_STDALIGN_H): Check for Clang 3.0's problem.
75182 2011-12-01  Eric Blake  <eblake@redhat.com>
75184         mktempd: silence dd usage
75185         * build-aux/mktempd (rand_bytes): Silence dd.
75187 2011-11-30  Simon Josefsson  <simon@josefsson.org>
75189         manywarnings: Don't mention gcc version in docstring.
75190         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Doc fix.  Suggested by
75191         Jim Meyering <meyering@redhat.com>.
75193 2011-11-30  Jim Meyering  <meyering@redhat.com>
75195         hash: mark a few floating point constants with "f" suffix
75196         * lib/hash.c (DEFAULT_GROWTH_THRESHOLD, DEFAULT_GROWTH_FACTOR)
75197         (DEFAULT_SHRINK_THRESHOLD, DEFAULT_SHRINK_FACTOR): Mark literal
75198         floating point constants with "f", since they're destined to be
75199         saved/used as "float"s.
75201 2011-11-29  Paolo Bonzini  <bonzini@gnu.org>
75203         float tests: Correct and re-enable assertion about LDBL_MIN_EXP.
75204         * tests/test-float.c (test_long_double): Correct and re-enable the
75205         assertion about LDBL_MIN_EXP that was disabled on 2011-08-31.
75207 2011-11-29  Matthew Wala  <wala1@illinois.edu>  (tiny change)
75209         Avoid subtracting two pointers that don't point into the same block.
75210         * lib/argp-help.c (hol_append): Reorder pointer subtractions so that
75211         only pointers into the same memory block are subtracted. We cannot
75212         assume that sizeof (ptrdiff_t) == sizeof (void *).
75214 2011-11-29  Eric Blake  <eblake@redhat.com>
75216         maint.mk: add syntax check for use of compare from init.sh
75217         * top/maint.mk (sc_prohibit_reversed_compare_failure): New rule,
75218         moved here from coreutils.
75220         manywarnings: drop -Wunsuffixed-float-constants
75221         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): C99 does not allow
75222         '1.0D', which is the only way to silence this warning for 'double'.
75224 2011-11-29  Jim Meyering  <meyering@redhat.com>
75226         hash: mark compute_bucket_size with the pure attribute
75227         * lib/hash.c (compute_bucket_size): Use _GL_ATTRIBUTE_PURE.
75229         quotearg, propername: correct pragma guard expression
75230         * lib/quotearg.c: Enable pragma for gcc-4.6 and newer, not 4.3 and newer.
75231         * lib/propername.c: Likewise.  Reported by Bernhard Voelker.
75233 2011-11-28  Jim Meyering  <meyering@redhat.com>
75235         propername: do not mark proper_name with the const attribute
75236         * lib/propername.h (proper_name): Do *not* mark as _GL_ATTRIBUTE_CONST,
75237         since it examines data pointed to by its parameter.
75238         * lib/propername.c (proper_name): Instead, add a pragma to suppress
75239         the suggestion from -Wsuggest-attribute=const.
75241         propername: mark one more function as const
75242         * lib/propername.h (proper_name): Mark as _GL_ATTRIBUTE_CONST.
75244 2011-11-27  Jim Meyering  <meyering@redhat.com>
75246         mark functions with const and pure attributes
75248         Mark functions per suggestions from gcc-4.6 when using these options:
75249         -Wsuggest-attribute=pure -Wsuggest-attribute=const.
75250         Use gnulib's _GL_ATTRIBUTE_PURE and _GL_ATTRIBUTE_CONST macros.
75251         Follow these guidelines: when possible, apply the attribute to
75252         an extern declaration, not to its definition.  Apply it to the
75253         definition only when the definition is static.
75254         * lib/argmatch.h (argmatch, argmatch_to_argument): Mark.
75255         * lib/argv-iter.h (argv_iter_n_args): Likewise.
75256         * lib/base64.h (isbase64): Likewise.
75257         * lib/basename-lgpl.c (last_component, base_len): Likewise.
75258         * lib/c-ctype.h (c_isascii, c_isalnum, c_isalpha): Likewise.
75259         (c_isblank, c_iscntrl, c_isdigit, c_islower, c_isgraph): Likewise.
75260         (c_isprint, c_ispunct, c_isspace, c_isupper, c_isxdigit): Likewise.
75261         (c_tolower, c_toupper): Likewise.
75262         * lib/c-strcase.h (c_strcasecmp, c_strncasecmp): Likewise.
75263         * lib/chdir-long.c (find_non_slash): Likewise.
75264         * lib/dirname.h (base_len, dir_len, last_component): Likewise.
75265         * lib/exclude.h (fnmatch_pattern_has_wildcards): Likewise.
75266         * lib/file-type.h (file_type): Likewise.
75267         * lib/filenamecat-lgpl.c (longest_relative_suffix): Likewise.
75268         * lib/filevercmp.c (verrevcmp): Likewise.
75269         * lib/freadahead.h (freadahead): Likewise.
75270         * lib/fts.c (fts_maxarglen): Likewise.
75271         * lib/hash-pjw.h (hash_pjw): Likewise.
75272         * lib/hash-triple.h (triple_hash_no_name, triple_compare_ino_str):
75273         * lib/hash.c (is_prime, next_prime): Likewise.
75274         * lib/hash.c (hash_get_n_buckets, hash_get_n_buckets_used): Likewise.
75275         (hash_get_n_entries, hash_get_max_bucket_length): Likewise.
75276         (hash_table_ok, hash_get_first, hash_string): Likewise.
75277         (compute_bucket_size): Likewise.
75278         * lib/i-ring.h (i_ring_empty): Likewise.
75279         * lib/isnan.c (isnanl): Likewise.
75280         * lib/math.h (isnanl, rpl_isnanl): Likewise.
75281         * lib/memcasecmp.h (memcasecmp): Likewise.
75282         * lib/memchr2.h (memchr2): Likewise.
75283         * lib/memcmp2.h (memcmp2): Likewise.
75284         * lib/parse-datetime.y (lookup_zone): Likewise.
75285         * lib/sockets.h (gl_sockets_startup, gl_sockets_cleanup)
75286         [!WINDOWS_SOCKETS]: Likewise.
75287         * lib/strnlen1.h (strnlen1): Likewise.
75288         * lib/uniwidth.in.h (uc_width): Likewise.
75289         * lib/quotearg.c: Add pragma to avoid unwarranted suggestion from
75290         gcc's -Wsuggest-attribute=pure for quoting_options_from_style.
75291         (quoting_options_from_style): Add a comment.
75292         * lib/propername.h (proper_name): Add a comment.
75294 2011-11-27  Bruno Haible  <bruno@clisp.org>
75296         Remove unused macros from !_LIBC code in glibc-borrowed files.
75297         * lib/fnmatch.c (STRCOLL): Remove macro.
75298         * lib/fnmatch_loop.c (STRCOLL): Remove undef.
75299         * lib/glob.c (__stat, __readdir64): Remove macros.
75300         * lib/tempname.c (__open64, __xstat64): Remove macros.
75301         Suggested by Paul Eggert.
75303 2011-11-27  Bruno Haible  <bruno@clisp.org>
75305         getcwd: Fix link error on MSVC 9.
75306         * modules/getcwd (Depends-on): Add readdir, rewinddir.
75308 2011-11-27  Bruno Haible  <bruno@clisp.org>
75310         Don't set REPLACE_FOO to 1 if HAVE_FOO is 0.
75311         * m4/opendir.m4 (gl_FUNC_OPENDIR): Don't set REPLACE_OPENDIR to 1 if
75312         HAVE_OPENDIR is 0.
75313         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Don't set REPLACE_CLOSEDIR to 1 if
75314         HAVE_CLOSEDIR is 0.
75315         * m4/dup2.m4 (gl_FUNC_DUP2): Don't set REPLACE_DUP2 to 1 if HAVE_DUP2
75316         is 0.
75317         * m4/dup3.m4 (gl_FUNC_DUP3): Update comments.
75319 2011-11-27  Bruno Haible  <bruno@clisp.org>
75321         getcwd: Fix bug from 2011-08-17.
75322         * m4/getcwd.m4 (gl_FUNC_GETCWD): Set REPLACE_GETCWD to 1 only on
75323         platforms that need it.
75324         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Consider a return
75325         code of 4 to be a failure, not a success. This ensures that
75326         REPLACE_GETCWD becomes 1 on OpenBSD 4.9 and NetBSD 5.1.
75328 2011-11-27  Bruno Haible  <bruno@clisp.org>
75330         binary-io tests: Avoid test failure on mingw when libtool is used.
75331         * tests/test-binary-io.c (main): Don't remove t-bin-out2.tmp here.
75332         Don't verify the size of t-bin-out1.tmp here.
75333         * tests/test-binary-io.sh: Verify it here.
75334         Reported by Simon Josefsson.
75336 2011-11-26  Bruno Haible  <bruno@clisp.org>
75338         Fix conflict between two instantiations of module 'unistd'.
75339         * gnulib-tool (func_emit_autoconf_snippet): Substitute
75340         ${include_guard_prefix} also in the autoconf snippet.
75341         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX): Don't set GNULIB_UNISTD_H_GETOPT.
75342         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Don't initialize
75343         GNULIB_UNISTD_H_GETOPT.
75344         * modules/getopt-posix (configure.ac): Set the
75345         GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT variable.
75346         * modules/getopt-gnu (configure.ac): Likewise.
75347         * modules/unistd (Makefile.am): Change the substitution value of
75348         GNULIB_UNISTD_H_GETOPT to depend on the include guard prefix.
75349         Reported by Simon Josefsson.
75351 2011-11-25  Bruno Haible  <bruno@clisp.org>
75353         pagealign_alloc: Doc and comments.
75354         * doc/posix-functions/posix_memalign.texi: Refer to the pagealign_alloc
75355         module.
75356         * lib/pagealign_alloc.c (pagealign_alloc): Add comment.
75358 2011-11-25  Jim Meyering  <meyering@redhat.com>
75360         test-update-copyright.sh: avoid false-positive failure
75361         * tests/test-update-copyright.sh: Use $TMP.? (not $TMP.*), to work
75362         around false positive failure on Cygwin/Windows.  The latter was
75363         matching erroneously-created files with names like
75364         update-copyright.test-ex.4.bak.  Reported by Simon Josefsson.
75366 2011-11-25  Simon Josefsson  <simon@josefsson.org>
75368         valgrind-tests.m4: Avoid breakage if valgrind on bash fails.
75369         * m4/valgrind-tests.m4: Check that the parameters that will be
75370         used works, not just a subset of them.  Reported by Bruno Haible
75371         <bruno@clisp.org>.
75373 2011-11-24  Jim Meyering  <meyering@redhat.com>
75375         test-stdalign.c: comment out long double tests
75376         * tests/test-stdalign.c: Don't try to reduce alignment of long double
75377         variables.  That provokes errors like this from gcc-4.7.0 20111124:
75378         error: '_Alignas' specifiers cannot reduce alignment of \
75379         'static_longdouble_alignas'.
75381 2011-11-22  Jim Meyering  <meyering@redhat.com>
75383         init.sh: make "compare /dev/null FILE" output more readable
75384         * tests/init.sh (compare_): Document the preferred order of arguments.
75385         (emit_diff_u_header_): New function.
75386         (compare_dev_null_): Emit a simulated diff, rather than just the
75387         contents of the unexpected file.  Suggestion from Bruno Haible.
75389 2011-11-21  Jim Meyering  <meyering@redhat.com>
75390             Eric Blake  <eblake@redhat.com>
75392         init.sh: work around OSF/1 5.1's mishandling of /dev/null
75393         * tests/init.sh: Make our compare function slightly more portable.
75394         Reported by Bruno Haible in
75395         http://thread.gmane.org/gmane.comp.gnu.grep.bugs/4020
75397 2011-11-21  Simon Josefsson  <simon@josefsson.org>
75399         * m4/gnulib-common.m4 (_Noreturn): Check that _MSC_VER is defined
75400         before using it, in code that ends up in config.h.
75402 2011-11-20  Bruno Haible  <bruno@clisp.org>
75404         getcwd: Work around getcwd bug on AIX 5..7.
75405         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Require
75406         AC_CANONICAL_HOST. Assign exit code 31 to the bug seen on AIX 5.1..7.1.
75407         Use a different value for gl_cv_func_getcwd_path_max. Move the
75408         definition of HAVE_PARTLY_WORKING_GETCWD from here...
75409         * m4/getcwd.m4 (gl_FUNC_GETCWD): ... to here. Invoke
75410         gl_FUNC_GETCWD_PATH_MAX also when $gl_cv_func_getcwd_null is 'no'.
75411         Define HAVE_MINIMALLY_WORKING_GETCWD.
75412         * lib/getcwd.c (__getcwd): Don't use the system's getcwd on platforms
75413         where it is not even minimally working, that is, on AIX.
75414         * tests/test-getcwd.c (test_long_name): Distinguish the same cases as
75415         m4/getcwd-path-max.m4.
75416         (main): Update exit code computation.
75417         * doc/posix-functions/getcwd.texi: Mention list of platforms where
75418         getcwd does not handle long file names.
75420 2011-11-20  Bruno Haible  <bruno@clisp.org>
75422         getcwd: Fix bug from 2009-09-10.
75423         * m4/getcwd.m4 (gl_FUNC_GETCWD): Treat "guessing yes" like "yes", not
75424         like "no".
75426 2011-11-20  Simon Josefsson  <simon@josefsson.org>
75428         * m4/manywarnings.m4: Add more warnings from gcc 4.6.2.
75430 2011-11-20  Bruno Haible  <bruno@clisp.org>
75432         fma tests: Avoid shadowing local variables.
75433         * tests/test-fma2.h (test_function): Reduce scope of x, y, z, result,
75434         expected.
75436 2011-11-20  Bruno Haible  <bruno@clisp.org>
75438         copysignf tests: Fix.
75439         * tests/test-copysignf.c: Fix signature check.
75441 2011-11-20  Bruno Haible  <bruno@clisp.org>
75443         fma: Remove unused code.
75444         * lib/fma.c (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): Remove
75445         unused macros.
75447 2011-11-20  Bruno Haible  <bruno@clisp.org>
75449         sethostname: Fix doc about AIX.
75450         * doc/glibc-functions/sethostname.texi: Drop mention that AIX 5.1 lacks
75451         sethostname; it has it.
75453         sethostname: Mention more portability problems.
75454         * doc/glibc-functions/sethostname.texi: Mention the missing declaration
75455         problem.
75456         Reported by Ben Walton <bwalton@artsci.utoronto.ca>.
75458 2011-11-19  Bruno Haible  <bruno@clisp.org>
75460         Depend on module fcntl-h when AT_FDCWD is used.
75461         * modules/utimens (Depends-on): Add fcntl-h.
75462         * modules/areadlinkat (Depends-on): Likewise.
75463         * modules/areadlinkat-with-size (Depends-on): Likewise.
75464         * modules/faccessat (Depends-on): Likewise.
75465         * modules/fchmodat (Depends-on): Likewise.
75466         * modules/fchownat (Depends-on): Likewise.
75467         * modules/getcwd (Depends-on): Likewise.
75468         * modules/mkdirat (Depends-on): Likewise.
75469         * modules/mkfifoat (Depends-on): Likewise.
75470         * modules/readlinkat (Depends-on): Likewise.
75471         * modules/symlinkat (Depends-on): Likewise.
75472         * modules/dup2-tests (Depends-on): Likewise.
75473         * modules/fdutimensat-tests (Depends-on): Likewise.
75474         * modules/futimens-tests (Depends-on): Likewise.
75476 2011-11-19  Bruno Haible  <bruno@clisp.org>
75478         euidaccess: Update a comment.
75479         * lib/euidaccess.c: Update comment about platforms with faccessat.
75481 2011-11-19  Bruno Haible  <bruno@clisp.org>
75483         openat: Fix file list.
75484         * modules/openat (Files): Remove lib/at-func.c.
75486 2011-11-19  Bruno Haible  <bruno@clisp.org>
75488         fstatat: Simplify.
75489         * lib/fstatat.c (AT_FUNC_NAME): Define as fstatat. On platforms where
75490         gnulib should define rpl_fstatat, there is a
75491         "#define fstatat rpl_fstatat" in <sys/stat.h>.
75493 2011-11-19  Bruno Haible  <bruno@clisp.org>
75495         Ensure 'inline' can be used in tests/test-utimens-common.h.
75496         * modules/fdutimensat-tests (configure.ac): Require AC_C_INLINE.
75497         * modules/futimens-tests (configure.ac): Likewise.
75498         * modules/utimens-tests (configure.ac): Likewise.
75499         * modules/utimensat-tests (configure.ac): Likewise.
75501 2011-11-19  Simon Josefsson  <simon@josefsson.org>
75503         * lib/hash.c (hash_insert): Use hash_insert_if_absent,
75504         not hash_insert0.
75505         (hash_insert_if_absent): Doc fix.
75507 2011-11-19  Simon Josefsson  <simon@josefsson.org>
75509         * m4/readline.m4 (gl_FUNC_READLINE): Check for readline/history.h.
75511 2011-11-18  Paul Eggert  <eggert@cs.ucla.edu>
75513         test-getcwd: disambiguate exit status
75514         * tests/test-getcwd.c (test_long_name): Return 0..7.
75515         (main): Exit with an unambiguous exit status.  The old
75516         code yielded a mysterious mixture of two failure codes.
75518         fstatat: fix configuration bug on mingw, OpenBSD 4, Solaris 8
75519         * lib/fstatat.c (AT_FUNC_NAME): Use HAVE_FSTAT, not
75520         HAVE_WORKING_FSTATAT_ZERO_FLAG, to decide whether to define
75521         rpl_fstatat or fstatat.  This should fix the other problem
75522         reported by Kai Habel in
75523         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00237.html>.
75524         A similar problem was reported for OpenBSD 4.6 by Mats Erik Andersson
75525         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00239.html>
75526         and I reproduced it on a Solaris 8 host we still have in production.
75528 2011-11-18  Jim Meyering  <meyering@redhat.com>
75530         hash: deprecate poorly-named hash_insert0: use hash_insert_if_absent
75531         * lib/hash.c (hash_insert_if_absent): Rename from hash_insert0.
75532         Add a sentence to the comment.
75533         (hash_insert0): New function that simply calls hash_insert_if_absent.
75534         * lib/hash.h (hash_insert_if_absent): Declare it.
75535         (hash_insert0): Add deprecation attribute.
75536         (_GL_ATTRIBUTE_DEPRECATED): Define.
75537         * lib/di-set.c (di_set_insert): Use hash_insert_if_absent,
75538         not hash_insert0.
75539         * NEWS: Mention it, even though it's not really an incompatible change.
75541 2011-11-18  Dagobert Michelsen  <dam@opencsw.org>  (tiny change)
75543         openat: avoid compilation failure due to lack of <errno.h> inclusion
75544         * lib/openat.c: Include <errno.h>.
75546 2011-11-17  Paul Eggert  <eggert@cs.ucla.edu>
75548         * modules/getcwd (Depends-on): Add fdopendir.
75549         This fixes one of the two problems reported by Kai Habel in
75550         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00237.html>.
75552         modules/crypto/gc-*: simplify dependencies and fix stdalign.h bug
75553         stdalign problem reported by Ian Beckwith in
75554         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00238.html>.
75555         * modules/crypto/gc-arcfour (Depends-on):
75556         Depend conditionally on crypto/arcfour.
75557         * modules/crypto/gc-arctwo (Depends-on):
75558         Depend conditionally on crypto/arctwo.
75559         * modules/crypto/gc-des (Depends-on):
75560         Depend conditionally on crypto/des.
75561         * modules/crypto/gc-hmac-md5 (Depends-on):
75562         Depend conditionally on crypto/hmac-md5.
75563         * modules/crypto/gc-hmac-sha1 (Depends-on):
75564         Depend conditionally on crypto/hmac-sha1.
75565         * modules/crypto/gc-md2 (Depends-on): Remove stdint, minmax.
75566         * modules/crypto/gc-md4 (Depends-on):
75567         Depend conditionally on crypto/md4.
75568         * modules/crypto/gc-md5 (Depends-on):
75569         Depend conditionally on crypto/md5.
75570         * modules/crypto/gc-rijndael (Depends-on):
75571         Depend conditionally on crypto/rijndael.
75572         * modules/crypto/gc-sha1 (Depends-on):
75573         Depend conditionally on crypto/sha1.
75574         * modules/crypto/gc-arcfour:
75575         * modules/crypto/gc-arctwo:
75576         * modules/crypto/gc-des:
75577         * modules/crypto/gc-hmac-md5:
75578         * modules/crypto/gc-hmac-sha1:
75579         * modules/crypto/gc-md2:
75580         * modules/crypto/gc-md4:
75581         * modules/crypto/gc-md5:
75582         * modules/crypto/gc-rijndael:
75583         * modules/crypto/gc-sha1:
75584         (Files, Depends-on, configure.ac): Remove now-unnecessary stuff,
75585         now that the conditional dependencies do the work for us.
75587 2011-11-17  Jim Meyering  <meyering@redhat.com>
75589         tests: factor st_ctime-comparison out of two headers
75590         * tests/test-utimens-common.h (ctime_compare): Define.
75591         * tests/test-futimens.h (test_futimens): Replace open-coded equivalent.
75592         * tests/test-lutimens.h (test_lutimens): Likewise.
75593         * tests/test-utimens.h (test_utimens): Likewise.
75595         test-getcwd: don't leave behind a confdir3/ directory upon interrupt
75596         Invoke the test program via an init.sh-using wrapper.
75597         * tests/test-getcwd.sh: New file.
75598         * modules/getcwd-tests (Files): Add it.
75599         (Makefile.am) [TESTS]: Invoke the shell script wrapper.
75601 2011-11-01  Gary V. Vaughan  <gary@gnu.org>
75603         gitlog-to-changelog: support multi-author commits.
75604         The FSF cares about keeping track of all authors of patches to its
75605         projects, but Git doesn't provide obvious support for multi-author
75606         changesets. Consensus seems to be forming around the use of extra
75607         Signed-off-by inspired lines in the log message formatted as
75608         `Co-authored-by: A U Thor <email@example.com>' for round-tripping
75609         multi-author commits between version control systems.
75610         * gitlog-to-changelog: Extract `Co-authored-by:' lines from the git
75611         log message and output in standard ChangeLog multi-author format.
75612         Reported by Peter Rosin <peda@lysator.liu.se>
75614 2011-11-15  Ben Walton  <bwalton@artsci.utoronto.ca>  (tiny change)
75615             Bruno Haible  <bruno@clisp.org>
75617         Fix some modules' file list.
75618         * modules/fstatat (Files): Add m4/lstat.m4.
75619         * modules/openat (Files): Likewise.
75620         * modules/unlinkat (Files): Likewise.
75622 2011-11-15  Gary V. Vaughan  <gary@gnu.org>
75624         maint.mk: fix tight-scope.mk generation in VPATH builds.
75625         * top/maint.mk (tight-scope.mk): Make sure to prefix file
75626         reference with $(srcdir) so that the file is found correctly even
75627         when running `make syntax-check' in a VPATH build.
75629 2011-11-13  Bruno Haible  <bruno@clisp.org>
75630             Jim Meyering  <meyering@redhat.com>
75632         Silence successful tests that use 'compare' on AIX, HP-UX, Solaris.
75633         * tests/init.sh (compare): Remove "No differences encountered" or
75634         synonymous output from the 'diff' program.
75636 2011-11-13  Bruno Haible  <bruno@clisp.org>
75638         Makefile: Tweak indentation.
75639         * Makefile: Use tab as first character in every line that contains rule
75640         commands.
75642 2011-11-13  Bruno Haible  <bruno@clisp.org>
75644         Syntax check for copyright statements.
75645         * check-copyright: New file.
75646         * Makefile (sc_check_copyright): New rule.
75648 2011-11-13  Simon Josefsson  <simon@josefsson.org>
75650         * build-aux/git-version-gen: Add --prefix to configure the tag
75651         match string.
75653 2011-11-13  Simon Josefsson  <simon@josefsson.org>
75655         * build-aux/git-version-gen: Add --help and --version.
75657 2011-11-12  Jim Meyering  <meyering@redhat.com>
75659         revamp the other test-exclude?.sh scripts to use init.sh, too
75660         * tests/test-exclude1.sh: Use init.sh.
75661         * tests/test-exclude2.sh: Likewise.
75662         * tests/test-exclude3.sh: Likewise.
75663         * tests/test-exclude4.sh: Likewise.
75664         * tests/test-exclude5.sh: Likewise.
75665         * tests/test-exclude6.sh: Likewise.
75666         * tests/test-exclude7.sh: Likewise.
75667         * tests/test-exclude8.sh: Likewise.
75668         * modules/exclude-tests (Files): List init.sh.
75670         test-exclude2.sh, test-exclude5.sh: fail if test-exclude fails
75671         These shell scripts ignored failure of the binary test-exclude,
75672         so making the latter return 77 didn't cause them to be skipped.
75673         * tests/test-exclude5.sh: Exit with test-exclude's error status
75674         when that program fails.  Revamp to use init.sh.
75675         * tests/test-exclude2.sh: Likewise.
75677         test-exclude: fix a typo
75678         * tests/test-exclude.c (main): Test for "leading_dir", not "leading-dir".
75680 2011-11-11  Bruno Haible  <bruno@clisp.org>
75682         obstack: Fix compilation error on MSVC 9.
75683         * lib/obstack.c (print_and_abort): Declare with _Noreturn specifier.
75685 2011-11-11  Jim Meyering  <meyering@redhat.com>
75687         test-exclude: skip tests rather than failing on deficient systems
75688         * tests/test-exclude.c (main): Skip tests that use FNM_CASEFOLD
75689         and FNM_LEADING_DIR on systems that lack the definitions.  This affects
75690         at least Solaris 9.  Reported and diagnosed by Dagobert Michelsen in
75691         http://thread.gmane.org/gmane.comp.gnu.grep.bugs/3947/focus=3950
75693 2011-11-10  Bruno Haible  <bruno@clisp.org>
75695         ptsname_r test: Avoid gcc warning on glibc systems.
75696         * tests/test-ptsname_r.c (null_ptr): New function.
75697         (test_errors): Use it.
75699 2011-11-10  Bruno Haible  <bruno@clisp.org>
75701         ptsname_r: Avoid compilation error on OSF/1 5.1.
75702         * lib/stdlib.in.h (ptsname_r): Override if REPLACE_PTSNAME_R is 1.
75703         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_PTSNAME_R.
75704         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Set REPLACE_PTSNAME_R if the
75705         function is not declared or incompatibly declared.
75706         * modules/stdlib (Makefile.am): Substitute REPLACE_PTSNAME_R.
75707         * modules/ptsname_r (Depends-on, configure.ac): Update.
75708         * doc/glibc-functions/ptsname_r.texi: Mention the OSF/1 problems.
75710 2011-11-10  Bruno Haible  <bruno@clisp.org>
75712         fstatat: Make cross-compilation guess succeed everywhere except on AIX.
75713         * m4/fstatat.m4 (gl_FUNC_FSTATAT): Require AC_CANONICAL_HOST.
75714         When cross-compiling, guess yes on all platforms except AIX.
75715         Reported by Ludovic Courtès <ludo@gnu.org>.
75717 2011-11-09  Bruno Haible  <bruno@clisp.org>
75719         ptsname_r tests: Fix bugs.
75720         * tests/test-ptsname_r.c (test_errors): Change return type to 'void'.
75721         Fix ptsname_r calls. Reduce loop rounds to a reasonable amount.
75723 2011-11-09  Paul Eggert  <eggert@cs.ucla.edu>
75725         fstatat: work with cross-compilation
75726         Problem reported by Ludovic Courtès in
75727         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00136.html>.
75728         * m4/fstatat.m4 (gl_FUNC_FSTATAT): When cross-compiling, report
75729         "cross-compiling" and assume the bug is present.  Replace
75730         FSTATAT_ZERO_FLAG_BROKEN with HAVE_WORKING_FSTATAT_ZERO_FLAG with
75731         an inverted sense, to be more conservative about our assumptions.
75732         * lib/fstatat.c (rpl_fstatat): Adjust to renamed macro.
75734 2011-11-09  Bruno Haible  <bruno@clisp.org>
75736         Improve MODULES.html output.
75737         * modules/mkfifoat (Description): Use the word "function".
75738         * modules/readlinkat (Description): Likewise.
75739         * modules/symlinkat (Description): Likewise.
75741 2011-11-09  Eric Blake  <eblake@redhat.com>
75743         ptsname_r-tests: new test module
75744         * modules/ptsname_r-tests: New module.
75745         * tests/test-ptsname_r.c: New file.
75747         ptsname_r: new module
75748         * modules/ptsname_r: New module.
75749         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): New file.
75750         * lib/ptsname.c (__ptsname_r): Split...
75751         * lib/ptsname_r.c: ...into new file.
75752         * m4/stdlib_h.m4 (gl_STDLIB_H): Check for decl.
75753         (gl_STDLIB_H_DEFAULTS): Set witness defaults.
75754         * modules/stdlib (Makefile.am): Substitute witnesses.
75755         * lib/stdlib.in.h (ptsname_r): Declare it.
75756         * doc/glibc-functions/ptsname_r.texi (ptsname_r): Document it.
75757         * MODULES.html.sh (Misc): Likewise.
75758         * modules/ptsname (Depends-on): Alter dependency.
75759         * doc/posix-functions/ptsname.texi (ptsname): Mention new module.
75761 2011-11-09  Jim Meyering  <meyering@redhat.com>
75763         announce-gen: be more concise when there's only one URL+tarball
75764         * build-aux/announce-gen (get_tool_versions): When you distribute
75765         only one type of tarball, combine the first two "Here are..."
75766         sections and make the key-checking grammar independent of
75767         how many tarballs there are.
75769 2011-11-09  Eric Blake  <eblake@redhat.com>
75771         openpty: provide a stub on mingw
75772         * lib/pty.in.h (includes): Provide forward declarations.
75773         * lib/openpty.c (openpty) [mingw]: Provide ENOSYS stub.
75775         raise: fix mingw handling of SIGPIPE
75776         * lib/sigprocmask.c (_gl_raise_SIGPIPE): Provide a return value.
75778 2011-11-08  Bruno Haible  <bruno@clisp.org>
75780         More conditional dependencies.
75781         * modules/faccessat (Depends-on): Add conditions.
75782         * modules/fchmodat (Depends-on): Likewise.
75783         * modules/fchownat (Depends-on): Likewise.
75784         * modules/fstatat (Depends-on): Likewise.
75785         * modules/mkfifoat (Depends-on): Likewise.
75786         * modules/readlinkat (Depends-on): Likewise.
75787         * modules/symlinkat (Depends-on): Likewise.
75788         * modules/unlinkat (Depends-on): Likewise.
75789         * modules/utimensat (Depends-on): Likewise.
75790         * modules/mkdirat (Depends-on): Add sys_stat. Add conditions.
75791         * modules/linkat (Depends-on): Refine the conditions.
75792         * modules/renameat (Depends-on): Likewise.
75794 2011-11-08  Bruno Haible  <bruno@clisp.org>
75796         faccessat: Move AC_LIBOBJ invocation to module description.
75797         * m4/faccessat.m4 (gl_PREREQ_FACCESSAT): New macro.
75798         (gl_FUNC_FACESSAT): Don't test for access() here. Move AC_LIBOBJ
75799         invocation from here...
75800         * modules/faccessat (configure.ac): ... to here. Invoke
75801         gl_PREREQ_FACCESSAT.
75803 2011-11-08  Bruno Haible  <bruno@clisp.org>
75805         faccessat: Simplify autoconf macro.
75806         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Don't require gl_FUNC_OPENAT,
75807         gl_FUNC_EUIDACCESS.
75809 2011-11-08  Bruno Haible  <bruno@clisp.org>
75811         renameat: Fix dependencies.
75812         * modules/renameat (Depends-on): Add stdbool.
75814 2011-11-08  Bruno Haible  <bruno@clisp.org>
75816         mkfifoat: Fix module description.
75817         * modules/mkfifoat (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR,
75818         not gl_UNISTD_MODULE_INDICATOR.
75820 2011-11-08  Bruno Haible  <bruno@clisp.org>
75822         fstatat: Remove unused dependency.
75823         * modules/fstatat (Depends-on): Remove fstat.
75825 2011-11-08  Simon Josefsson  <simon@josefsson.org>
75827         GNUmakefile: behave when Makefile is missing.
75828         * top/GNUmakefile: Always initialize _build-aux and _autoreconf.
75830 2011-11-08  Bruno Haible  <bruno@clisp.org>
75832         openat: Conditionalize dependencies.
75833         * lib/openat.c: Reduce the scope of some #includes.
75834         * modules/openat (Depends-on): Add conditions.
75836 2011-11-07  Jim Meyering  <meyering@redhat.com>
75838         maint.mk: extract GPG key ID without using a temporary file
75839         * top/maint.mk (gpg_key_ID): Extract GPG key ID from signed tag, but
75840         without using a temporary file.  Based on a suggestion from Werner Koch
75841         in http://thread.gmane.org/gmane.comp.encryption.gpg.devel/16496
75843 2011-11-07  Eric Blake  <eblake@redhat.com>
75845         grantpt: fix typo
75846         * lib/stdlib.in.h (grantpt): Check correct function.
75848         maint.mk: silence new syntax check
75849         * top/maint.mk (sc_prohibit_dirent_without_use): Add missing @.
75851 2011-11-06  Bruno Haible  <bruno@clisp.org>
75853         Doc about floating-point and math API.
75854         * doc/posix-headers/float.texi: Mention problem with FLT_ROUNDS.
75855         * doc/posix-headers/math.texi: Mention problem with math_errhandling.
75857 2011-11-06  Bruno Haible  <bruno@clisp.org>
75859         stdalign tests: Skip the test when compiled by Sun C.
75860         * tests/test-stdalign.c (main): Skip the test on Sun C.
75862 2011-11-06  Bruno Haible  <bruno@clisp.org>
75864         ansi-c++-opt: Complete the 2011-06-05 change.
75865         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): When a C++ compiler is found but
75866         does not support namespaces, set the variable to "no", not to ":".
75868 2011-11-06  Paul Eggert  <eggert@cs.ucla.edu>
75870         * doc/posix-headers/stdalign.texi (stdalign.h): Mention Sun review ID.
75872 2011-11-06  Bruno Haible  <bruno@clisp.org>
75874         copysignl: Fix result for zero argument on HP-UX 11 with HP C.
75875         * lib/copysignl.c (compute_minus_zerol) [HP-UX]: New function.
75876         (minus_zerol) [HP-UX]: New macro.
75877         (unary_minus) [HP-UX]: New function.
75878         (copysignl) [HP-UX]: Use unary_minus function.
75880 2011-11-06  Bruno Haible  <bruno@clisp.org>
75882         ldexp, ldexpf, ldexpl: Enhance tests.
75883         * tests/test-ldexp.h: New file, combining code from tests/test-ldexp.c
75884         and tests/test-ldexpl.c.
75885         * tests/test-ldexpl.c: (DOUBLE, ISNAN, INFINITY, NAN, L_, MINUS_ZERO,
75886         LDEXP, MIN_EXP, MAX_EXP): New macros.
75887         Include test-ldexp.h.
75888         (main): Just call test_function.
75889         * tests/test-ldexp.c: Include float.h, isnand-nolibm.h, minus-zero.h,
75890         infinity.h, nan.h.
75891         (DOUBLE, ISNAN, INFINITY, NAN, L_, MINUS_ZERO, LDEXP, MIN_EXP,
75892         MAX_EXP): New macros.
75893         Include test-ldexp.h.
75894         (x, y): Remove variables.
75895         (main): Just call test_function.
75896         * tests/test-ldexpf.c: Include float.h, isnanf-nolibm.h, minus-zero.h,
75897         infinity.h, nan.h.
75898         (DOUBLE, ISNAN, INFINITY, NAN, L_, MINUS_ZERO, LDEXP, MIN_EXP,
75899         MAX_EXP): New macros.
75900         Include test-ldexp.h.
75901         (x, y): Remove variables.
75902         (main): Just call test_function.
75903         * modules/ldexpl-tests (Files): Add tests/test-ldexp.h.
75904         * modules/ldexp-tests (Files): Add tests/test-ldexp.h,
75905         tests/minus-zero.h, tests/infinity.h, tests/nan.h.
75906         (Depends-on): Add isnand-nolibm, signbit, float.
75907         * modules/ldexpf-tests (Files): Add tests/test-ldexp.h,
75908         tests/minus-zero.h, tests/infinity.h, tests/nan.h.
75909         (Depends-on): Add isnanf-nolibm, signbit, float.
75911 2011-11-06  Bruno Haible  <bruno@clisp.org>
75913         math tests: Cosmetics.
75914         * tests/test-math-c++.cc: Reorder declarations.
75916 2011-11-05  Bruno Haible  <bruno@clisp.org>
75918         fma*: Simplify test.
75919         * tests/test-fma2.h (FORGIVE_GLIBC_BUG): Remove macro.
75920         (test_function): Remove all if (FORGIVE_GLIBC_BUG) statements.
75922         Tests for module 'fmal'.
75923         * modules/fmal-tests: New file.
75924         * tests/test-fmal1.c: New file.
75925         * tests/test-fmal2.c: New file.
75927         New module 'fmal'.
75928         * lib/math.in.h (fmal): New declaration.
75929         * lib/fmal.c: New file.
75930         * m4/fmal.m4: New file.
75931         * m4/math_h.m4 (gl_MATH_H): Test whethern fmal is declared.
75932         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMAL, HAVE_FMAL, REPLACE_FMAL.
75933         * modules/math (Makefile.am): Substitute GNULIB_FMAL, HAVE_FMAL,
75934         REPLACE_FMAL.
75935         * modules/fmal: New file.
75936         * doc/posix-functions/fmal.texi: Mention the new module and the various
75937         bugs.
75939         Tests for module 'fmaf'.
75940         * modules/fmaf-tests: New file.
75941         * tests/test-fmaf1.c: New file.
75942         * tests/test-fmaf2.c: New file.
75944         New module 'fmaf'.
75945         * lib/math.in.h (fmaf): New declaration.
75946         * lib/fmaf.c: New file.
75947         * m4/fmaf.m4: New file.
75948         * m4/math_h.m4 (gl_MATH_H): Test whethern fmaf is declared.
75949         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMAF, HAVE_FMAF, REPLACE_FMAF.
75950         * modules/math (Makefile.am): Substitute GNULIB_FMAF, HAVE_FMAF,
75951         REPLACE_FMAF.
75952         * modules/fmaf: New file.
75953         * doc/posix-functions/fmaf.texi: Mention the new module and the various
75954         bugs.
75956         Tests for module 'fma'.
75957         * modules/fma-tests: New file.
75958         * tests/test-fma1.c: New file.
75959         * tests/test-fma1.h: New file.
75960         * tests/test-fma2.c: New file.
75961         * tests/test-fma2.h: New file.
75963         New module 'fma'.
75964         * lib/math.in.h (fma): New declaration.
75965         * lib/fma.c: New file.
75966         * m4/fma.m4: New file.
75967         * m4/fegetround.m4: New file.
75968         * m4/math_h.m4 (gl_MATH_H): Test whethern fma is declared.
75969         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMA, HAVE_FMA, REPLACE_FMA.
75970         * modules/math (Makefile.am): Substitute GNULIB_FMA, HAVE_FMA,
75971         REPLACE_FMA.
75972         * modules/fma: New file.
75973         * doc/posix-functions/fma.texi: Mention the new module and the various
75974         bugs.
75976         Extend gl_MATHFUNC.
75977         * m4/mathfunc.m4 (gl_MATHFUNC): Accept an 4th parameter of INCLUDES.
75978         Support 'void' as argument type.
75979         * m4/rint.m4 (gl_FUNC_RINT): Update gl_MATHFUNC invocation.
75981 2011-11-05  Jim Meyering  <meyering@redhat.com>
75983         maint.mk: also prohibit inclusion of dirent.h without use
75984         * top/maint.mk (sc_prohibit_dirent_without_use): New rule.
75986 2011-11-05  Bruno Haible  <bruno@clisp.org>
75988         ldexpl tests: Avoid test failure on MSVC 9.
75989         * tests/test-ldexpl.c (main): Use a temporary variable for the expected
75990         value. Needed in order to enforce the conversion from a value greater
75991         than LDBL_MAX to Infinity.
75993 2011-11-05  Bruno Haible  <bruno@clisp.org>
75995         New modules 'at-internal', 'openat-h', split off from module 'openat'.
75996         * modules/at-internal: New file, extracted from modules/openat.
75997         * modules/openat-h: New file.
75998         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_OPENAT. Don't
75999         invoke gl_PREREQ_OPENAT and gl_MODULE_INDICATOR.
76000         * modules/openat (Description): Add reference to POSIX function.
76001         (Files): Remove lib/openat.h, lib/openat-proc.c.
76002         (Depends-on): Add at-internal, openat-h. Remove fdopendir, gettext-h,
76003         intprops, unistd.
76004         (configure.ac): Remove AC_LIBOBJ of openat-proc. Invoke
76005         gl_PREREQ_OPENAT, gl_MODULE_INDICATOR here. Invoke
76006         gl_FCNTL_MODULE_INDICATOR.
76007         (Include): Remove unistd.h, openat.h.
76008         * modules/areadlinkat (Files): Add lib/at-func.c.
76009         (Depends-on): Add at-internal, dosname, errno, extensions, fchdir,
76010         openat-die, openat-h, save-cwd.
76011         * modules/areadlinkat-with-size (Files): Add lib/at-func.c.
76012         (Depends-on): Add at-internal, dosname, errno, extensions, fchdir,
76013         openat-die, openat-h, save-cwd, unistd.
76014         * modules/faccessat (Files): Add lib/at-func.c, lib/openat-priv.h.
76015         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
76016         openat-h, save-cwd. Remove fcntl-h, openat.
76017         * modules/fchmodat (Files): Remove lib/openat.h.
76018         (Depends-on): Add at-internal, openat-h. Remove dirent, fcntl-h,
76019         openat, stdbool, unistd.
76020         * modules/fchownat (Files): Remove lib/openat.h.
76021         (Depends-on): Add at-internal, openat-h. Remove dirent, fcntl-h,
76022         openat, stdbool, sys_stat.
76023         * modules/fdopendir (Files): Remove lib/openat-priv.h,
76024         lib/openat-proc.c.
76025         (Depends-on): Add at-internal.
76026         (condigure.ac): Remove AC_LIBOBJ of openat-proc.
76027         * modules/fstatat (Files): Remove lib/openat.h.
76028         (Depends-on): Add at-internal, openat-h. Remove dirent, openat,
76029         stdbool, unistd.
76030         * modules/fts (Depends-on): Add openat-h.
76031         * modules/linkat (Depends-on): Add at-internal, openat-h. Remove
76032         openat.
76033         * modules/mkdirat (Files): Remove lib/openat.h.
76034         (Depends-on): Add at-internal, openat-h. Remove dirent, fcntl-h,
76035         openat, stdbool, sys_stat.
76036         * modules/mkfifoat (Files): Add lib/at-func.c.
76037         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
76038         openat-h, save-cwd. Remove fcntl-h, openat.
76039         * modules/openat-die (Depends-on): Add openat-h. Remove openat.
76040         * modules/readlinkat (Files): Add lib/at-func.c.
76041         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
76042         openat-h, save-cwd. Remove fcntl-h, openat.
76043         * modules/renameat (Depends-on): Add at-internal, openat-h. Remove
76044         openat.
76045         * modules/selinux-at (Files): Add lib/at-func.c.
76046         (Depends-on): Add at-internal, dosname, errno, extensions, fchdir,
76047         fcntl-h, openat-die, openat-h, save-cwd, unistd. Remove openat.
76048         * modules/symlinkat (Files): Add lib/at-func.c.
76049         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
76050         openat-h, save-cwd. Remove fcntl-h, openat.
76051         * modules/unlinkat (Files): Remove lib/openat.h.
76052         (Depends-on): Add at-internal, openat-h. Remove dirent, openat,
76053         stdbool.
76054         * modules/utimensat (Files): Add lib/at-func.c.
76055         (Depends-on): Add at-internal, dosname, errno, fchdir, fcntl-h,
76056         openat-die, openat-h, save-cwd.
76057         * modules/fchownat-tests (Depends-on): Add openat-h. Remove openat.
76058         * modules/fdutimensat-tests (Depends-on): Add openat.
76059         * modules/fstatat-tests (Depends-on): Add openat-h.
76060         * modules/readlinkat-tests (Depends-on): Add openat.
76061         * modules/symlinkat-tests (Depends-on): Add openat.
76063 2011-11-05  Bruno Haible  <bruno@clisp.org>
76065         openat: Include <stdbool.h>.
76066         * lib/openat.c: Include <stdbool.h>.
76068 2011-11-04  Bruno Haible  <bruno@clisp.org>
76070         fchownat, renameat, unlinkat: Fix dependencies.
76071         * modules/fchownat (Depends-on): Add fstatat.
76072         * modules/renameat (Depends-on): Likewise.
76073         * modules/unlinkat (Depends-on): Likewise.
76075 2011-11-04  Paul Eggert  <eggert@cs.ucla.edu>
76077         openat: remove direct dependency on dirent
76078         * lib/openat.h: Don't include <dirent.h>; it's no longer needed,
76079         and hasn't been needed ever since fdopendir was split into its own
76080         module on 2009-08-31.
76081         * modules/openat (Depends-on): Remove dirent.
76083 2011-11-04  Bruno Haible  <bruno@clisp.org>
76085         renameat: Optimize code size.
76086         * modules/renameat (configure.ac): Don't compile at-func2.c if
76087         REPLACE_RENAMEAT is 1.
76089 2011-11-04  Bruno Haible  <bruno@clisp.org>
76091         openat tests: Fix file list.
76092         * modules/openat-tests (Files): Add tests/test-open.h.
76094 2011-11-04  Bruno Haible  <bruno@clisp.org>
76096         openat, fchmodat, fchownat, linkat, renameat: Fix dependencies.
76097         * modules/fchmodat (Depends-on): Add openat-die.
76098         * modules/fchownat (Depends-on): Likewise.
76099         * modules/linkat (Depends-on): Likewise.
76100         * modules/renameat (Depends-on): Likewise.
76101         * modules/openat (Depends-on): Add dirent.
76103 2011-11-04  Jim Meyering  <meyering@redhat.com>
76105         at-func*.c: fix comments
76106         * lib/at-func2.c: Correct/improve first-line comment.
76107         * lib/at-func.c: Correct grammar in first-line comment.
76109 2011-11-04  Bruno Haible  <bruno@clisp.org>
76111         New module 'mkdirat', split off from module 'openat'.
76112         * m4/mkdirat.m4: New file. extracted from m4/openat.m4.
76113         * m4/openat.m4 (gl_FUNC_OPENAT): Don't require gl_SYS_STAT_H_DEFAULTS.
76114         Don't test for mkdirat. Don't set GNULIB_MKDIRAT, HAVE_MKDIRAT.
76115         * modules/mkdirat: New file, extracted from modules/openat.
76116         * modules/openat (Files): Remove lib/mkdirat.c.
76117         (Depends-on): Remove mkdir.
76118         (configure.ac): Remove AC_LIBOBJ of mkdirat.
76119         (Include): Remove <sys/stat.h>.
76120         * modules/mkdirat-tests: New file, extracted from modules/openat-tests.
76121         * modules/openat-tests (Files): Remove tests/test-mkdirat.c,
76122         tests/test-mkdir.h.
76123         (Depends-on): Remove ignore-value.
76124         (Makefile.am): Remove rules for test-mkdirat.
76125         * doc/posix-functions/mkdirat.texi: Mention module 'mkdirat' instead
76126         of module 'openat'.
76127         * NEWS: Mention the change.
76129 2011-11-04  Bruno Haible  <bruno@clisp.org>
76131         closedir: Avoid warning on mingw.
76132         * lib/closedir.c: Include <unistd.h>.
76134 2011-11-04  Bruno Haible  <bruno@clisp.org>
76136         New module 'fstatat', split off from module 'openat'.
76137         * lib/openat.h (statat, lstatat): Enable only if GNULIB_FSTATAT is
76138         defined.
76139         * m4/fstatat.m4: New file. extracted from m4/openat.m4.
76140         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FSTATAT. Don't invoke
76141         gl_FUNC_FSTATAT.
76142         (gl_FUNC_FSTATAT): Moved to m4/fstatat.m4.
76143         * modules/fstatat: New file, extracted from modules/openat.
76144         * modules/openat (Files): Remove lib/fstatat.c.
76145         (Depends-on): Remove lstat.
76146         (configure.ac): Remove AC_LIBOBJ of fstatat.
76147         * modules/fstatat-tests: New file, extracted from modules/openat-tests.
76148         * modules/openat-tests (Files): Remove tests/test-fstatat.c,
76149         tests/test-lstat.h, tests/test-stat.h.
76150         (Depends-on): Remove getcwd-lgpl.
76151         (Makefile.am): Remove rules for test-fstatat.
76152         * doc/posix-functions/fstatat.texi: Mention module 'fstatat' instead
76153         of module 'openat'.
76154         * NEWS: Mention the change.
76155         * modules/getcwd (Depends-on): Add fstatat.
76156         * modules/linkat (Depends-on): Likewise.
76157         * modules/mkfifoat-tests (Depends-on): Likewise.
76158         * modules/utimensat (Depends-on): Add fstatat. Remove openat.
76160 2011-11-03  Bruno Haible  <bruno@clisp.org>
76162         New module 'unlinkat', split off from module 'openat'.
76163         * m4/unlinkat.m4: New file, extracted from m4/openat.m4.
76164         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_UNLINKAT,
76165         REPLACE_UNLINKAT, HAVE_UNLINKAT. Don't test for unlinkat.
76166         * modules/unlinkat: New file, extracted from modules/openat. Correct
76167         the dependency conditions.
76168         * modules/openat (Files): Remove lib/unlinkat.c.
76169         (Depends-on): Remove rmdir, unlink.
76170         (configure.ac): Remove AC_LIBOBJ of unlinkat.
76171         * modules/unlinkat-tests: New file, extracted from modules/openat-tests.
76172         * modules/openat-tests (Files): Remove tests/test-unlinkat.c,
76173         tests/test-rmdir.h, tests/test-unlink.h.
76174         (Depends-on): Remove unlinkdir.
76175         (Makefile.am): Remove rules for test-unlinkat.
76176         * doc/posix-functions/unlinkat.texi: Mention module 'unlinkat' instead
76177         of module 'openat'.
76178         * NEWS: Mention the change.
76179         * modules/linkat-tests (Depends-on): Add unlinkat.
76180         * modules/mkfifoat-tests (Depends-on): Likewise.
76181         * modules/readlinkat-tests (Depends-on): Likewise.
76183 2011-11-02  Bruno Haible  <bruno@clisp.org>
76185         New module 'fchmodat', split off from module 'openat'.
76186         * lib/openat.h (chmodat, lchmodat): Enable only if GNULIB_FCHMODAT is
76187         defined.
76188         * m4/fchmodat.m4: New file, extracted from m4/openat.m4.
76189         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FCHMODAT. Don't test
76190         for fchmodat, lchmod. Don't set HAVE_FCHMODAT.
76191         * modules/fchmodat: New file, extracted from modules/openat.
76192         * modules/openat (Files): Remove lib/fchmodat.c.
76193         (configure.ac): Remove AC_LIBOBJ of fchmodat.
76194         * modules/fchmodat-tests: New file, extracted from modules/openat-tests.
76195         * modules/openat-tests (Files): Remove tests/test-fchmodat.c.
76196         (Makefile.am): Remove rules for test-fchmodat.
76197         * doc/posix-functions/fchmodat.texi: Mention module 'fchmodat' instead
76198         of module 'openat'.
76199         * NEWS: Mention the change.
76201 2011-11-02  Jim Meyering  <meyering@redhat.com>
76203         putenv: indent #definition of "environ" to placate cppi
76204         * lib/putenv.c (environ): Make indentation reflect cpp nesting.
76206         gitlog-to-changelog: provide a ChangeLog-repair mechanism
76207         Git logs are often treated as immutable, because editing them
76208         changes the SHA1 checksums of all descendants.  Thus, errors in
76209         git logs tend to stay there forever.  However, when we generate
76210         a ChangeLog file -- typically for distribution -- from that git log,
76211         we can actually make corrections in the generated file.  The key
76212         lies in recording in machine-readable/applicable form the desired
76213         corrections.  See --help for description and an example.
76214         * build-aux/gitlog-to-changelog (parse_amend_file): New function.
76215         (usage): Describe it; alphabetize option descriptions.
76216         (main): Honor the new option, carefully.
76218 2011-11-01  Jim Meyering  <meyering@redhat.com>
76220         gitlog-to-changelog: avoid an infloop
76221         * build-aux/gitlog-to-changelog: Don't infloop for a commit log
76222         that ends up being empty.
76224 2011-11-01  Paul Eggert  <eggert@cs.ucla.edu>
76226         * MODULES.html.sh: Fix sed-script shell quoting and locale issues.
76227         (func_module): Replace foo=` ... sed -e COMPLICATED ... ` with
76228         bar=COMPLICATED; foo=` ... sed -e "$bar" ... ` when COMPLICATED
76229         contains (possibly-quoted) backslashes.  This should avoid
76230         all-too-common shell bugs if COMPLICATED contains backslashes in
76231         the "wrong" places.  Reported by David Evans in
76232         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00013.html>.
76233         When 'sed' uses character ranges like A-Z, invoke it in the C locale,
76234         because we want ASCII ranges.  Is there some reason we don't use
76235         the C locale everywhere in this script?
76236         (func_module, top level): Avoid unwanted pathname expansion when
76237         $repo_url_prefix or $repo_url_suffix_repl contain shell
76238         metacharacters like '?' and '*'.
76240 2011-11-01  Bruno Haible  <bruno@clisp.org>
76242         fchownat: Improve description.
76243         * modules/fchownat (Description): Add link to function.
76245 2011-11-01  Paul Eggert  <eggert@cs.ucla.edu>
76247         * tests/test-stdalign.c (TEST_ALIGNMENT): Shrink back to 8.
76248         mingw supports alignments only up to 8 (!).  Reported by Bruno Haible in
76249         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00006.html>.
76250         * doc/posix-headers/stdalign.texi (stdalign.h): Document this.
76252 2011-11-01  Bruno Haible  <bruno@clisp.org>
76254         alignof: Avoid collision with stdalign module.
76255         * lib/alignof.h (alignof): Remove macro.
76256         * NEWS: Mention the change.
76257         Reported by Paul Eggert.
76259 2011-11-01  Bruno Haible  <bruno@clisp.org>
76261         New module 'fchownat', split off from module 'openat'.
76262         * lib/openat.h (chownat, lchownat): Enable only if GNULIB_FCHOWNAT is
76263         defined.
76264         * m4/fchownat.m4: New file, extracted from m4/openat.m4.
76265         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FCHOWNAT. Don't
76266         invoke gl_FUNC_FCHOWNAT.
76267         (gl_FUNC_FCHOWNAT_DEREF_BUG, gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG,
76268         gl_FUNC_FCHOWNAT): Moved to m4/fchownat.m4.
76269         * modules/fchownat: New file, extracted from modules/openat.
76270         * modules/openat (Files): Remove lib/fchownat.c.
76271         (Depends-on): Remove lchown.
76272         (configure.ac): Remove AC_LIBOBJ of fchownat.
76273         * modules/fchownat-tests: New file, extracted from modules/openat-tests.
76274         * modules/openat-tests (Files): Remove tests/test-fchownat.c,
76275         tests/test-chown.h, tests/test-lchown.h, tests/nap.h.
76276         (Depends-on): Remove mgetgroups, usleep, stat-time.
76277         (configure.ac): Remove test for getegid.
76278         (Makefile.am): Remove rules for test-fchownat.
76279         * doc/posix-functions/fchownat.texi: Mention module 'fchownat' instead
76280         of module 'openat'.
76281         * NEWS: Mention the change.
76283 2011-10-31  Paul Eggert  <eggert@cs.ucla.edu>
76285         stdalign: port better to MSVC and to Sun C 5.11
76286         This fixes some of the problems reported by Bruno Haible in
76287         <http://lists.gnu.org/r/bug-gnulib/2011-10/msg00300.html>.
76288         * doc/posix-headers/stdalign.texi (stdalign.h): Document more
76289         shortcomings of MSVC and of Sun C 5.11.
76290         * lib/stdalign.in.h (_Alignas): Omit bogus extra parenthesis
76291         around __declspec arg.
76292         * modules/stdalign-tests (Files): Add tests/macros.h.
76293         * tests/test-stdalign.c: Do not include <stdlib.h>; no longer needed.
76294         Include macros.h, for ASSERT.
76295         (DECLARE_ALIGNED): Remove.
76296         (TEST_ALIGNMENT): Define to 16 if alignment is supported (more likely
76297         to catch bug), and to 1 if not (simplifies the rest of the code).
76298         (CHECK_STATIC): Always declare the alignment test vars; that's simpler.
76299         (CHECK_AUTO): Remove.
76300         (CHECK_ALIGNED): Check only the alignment of the static vars,
76301         since auto var alignment isn't supported by Sun C 5.11.
76302         (CHECK_TYPES): Remove.  All uses replaced by inline code, so that
76303         ASSERT failures are easier to diagnose.
76305 2011-10-31  Bruno Haible  <bruno@clisp.org>
76307         doc about some IRIX 5.3 problems.
76308         * doc/posix-functions/getpwnam_r.texi: Mention incompatible declaration
76309         on IRIX 5.3.
76310         * doc/posix-headers/poll.texi: Mention missing nfds_t on IRIX 5.3.
76311         * doc/posix-functions/ptsname.texi: Mention missing declaration on IRIX
76312         5.3.
76313         * doc/posix-functions/grantpt.texi: Likewise.
76314         * doc/posix-functions/unlockpt.texi: Likewise.
76315         * doc/posix-functions/lgamma.texi: Likewise.
76316         * doc/posix-functions/nextafter.texi: Likewise.
76317         * doc/posix-functions/remainder.texi: Likewise.
76318         * doc/posix-functions/select.texi: Mention misplaced declaration on
76319         IRIX 5.3.
76320         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
76322 2011-10-31  Dmitry V. Levin  <ldv@altlinux.org>
76324         gitlog-to-changelog: fix git-log invocation.
76325         git-log mishandles date strings before 1970-01-01 UTC, and there is
76326         no use to specify --since=1970-01-01 by default anyway.
76327         * build-aux/gitlog-to-changelog: By default, when no --since option
76328         was given, do not specify explicit --since option to git-log.
76330 2011-10-30  Dmitry V. Levin  <ldv@altlinux.org>
76332         gitlog-to-changelog: new option --append-dot.
76333         * build-aux/gitlog-to-changelog: New option --append-dot, makes the
76334         first non-blank line of each commit message terminated with a dot.
76336 2011-10-30  Bruno Haible  <bruno@clisp.org>
76338         ffsl, ffsll: Avoid compilation error due to 'restrict'.
76339         * lib/ffsl.h: Include <config.h>.
76340         Suggested by Tom G. Christensen <tgc@jupiterrise.com>.
76342 2011-10-30  Jim Meyering  <meyering@redhat.com>
76344         GNUmakefile: reenable "make syntax-check" for most projects
76345         Since Friday's commit 05e2d798, "maint.mk: don't maintain a second
76346         build-aux variable", "syntax-check" would do nothing but succeed with
76347         the "No version control files detected..." diagnostic (unless you
76348         happened to override _build-aux via cfg.mk).
76349         * top/GNUmakefile (_autoreconf, _build-aux): Move default definitions
76350         to precede inclusion of maint.mk.  Otherwise, these variables would
76351         be used undefined in any project that does not override the default.
76353 2011-10-29  Dmitry V. Levin  <ldv@altlinux.org>
76355         gitlog-to-changelog: treat a message with only blank lines as empty.
76356         * build-aux/gitlog-to-changelog: Move the code that removes leading and
76357         trailing blank lines before the code that issues a warning about an
76358         empty commit message.
76360 2011-10-30  Jim Meyering  <meyering@redhat.com>
76362         test-parse-datetime.c: avoid new DST-related false positive test failure
76363         * tests/test-parse-datetime.c (gmt_offset): Determine the "gmt_offset"
76364         based on the time/date we'll convert, not the current time.
76365         Otherwise, the moment we cross a DST boundary like today's in
76366         Europe, (CEST to CET), that offset ends up being one hour off.
76368 2011-10-27  Bruno Haible  <bruno@clisp.org>
76370         fstat: Tweak documentation.
76371         * modules/fstat (Description): More precise description.
76373 2011-10-27  Bruno Haible  <bruno@clisp.org>
76375         Update documentation regarding 'largefile' module.
76376         * doc/posix-functions/fstat.texi: Tweak wording.
76377         * doc/posix-functions/opendir.texi: Mention that the module fixes the
76378         problems with huge directories and/or small ino_t types.
76379         * doc/posix-functions/readdir.texi: Likewise.
76380         * doc/posix-functions/rewinddir.texi: Likewise.
76382 2011-10-28  Gary V. Vaughan  <gary@gnu.org>
76384         maint.mk: don't maintain a second build-aux variable.
76385         * maint.mk (build_aux): Removed.  The maintainer-makefile module
76386         depends on GNUmakefile, which already maintains a cfg.mk
76387         overridable $(_build-aux) for projects with a non-standard
76388         build-aux directory location, although without the $(srcdir)
76389         prefix.  Use that variable consistently instead of introducing a
76390         second one.  Adjust all call sites.
76392 2011-10-27  Paul Eggert  <eggert@cs.ucla.edu>
76394         Add stdalign module and use it in other modules.
76395         This is based on a previous proposal by Bruno Haible
76396         <https://lists.gnu.org/r/bug-gnulib/2011-07/msg00226.html>.
76398         stdalign: new module
76399         * doc/posix-headers/stdalign.texi, lib/stdalign.in.h, m4/stdalign.m4:
76400         * modules/stdalign: New files.
76401         * MODULES.html.sh (c1x_core_properties): Add stdalign.
76402         * doc/gnulib.texi (Header File Substitutes): Add stdalign.
76404         stdalign-tests: new module
76405         * modules/stdalign-tests, tests/test-stdalign.c: New files.
76407         argp: use stdalign
76408         * lib/argp-parse.c: Include <stdalign.h>.
76409         (alignof): Remove.
76410         * modules/argp (Depends-on): Add stdalign.
76412         crypto libraries: use stdalign
76413         * lib/md4.c, lib/md5.c, lib/sha1.c, lib/sha256.c, lib/sha512.c:
76414         Include <stdalign.h> and <stdint.h>.  Do not include <stddef.h>.
76415         Do not include <stdlib.h> twice, in md4.c.
76416         (UNALIGNED_P): Simplify by using alignof.  Use uintptr_t, not size_t,
76417         because we are accessing a pointer's bit-pattern, not a size.
76418         * modules/crypto/gc-md4 (Depends-on): Add stdalign.
76419         * modules/crypto/gc-md5, modules/crypto/gc-sha1, modules/crypto/md4:
76420         * modules/crypto/md5, modules/crypto/sha1, modules/crypto/sha256:
76421         * modules/crypto/sha512: Likewise.
76423         sys_socket: use stdalign, not alignof
76424         * lib/sys_socket.in.h: Include <stdalign.h> instead of <alignof.h>.
76425         * modules/sys_socket (Depends-on): Depend on stdalign, not alignof.
76427 2011-10-27  Bruno Haible  <bruno@clisp.org>
76429         raise test: Avoid a test failure on Linux/MIPS.
76430         * tests/test-raise.c (main): Try raising signal 199, not 99. Needed
76431         because 99 is a valid signal on Linux/MIPS.
76433 2011-10-27  Bruno Haible  <bruno@clisp.org>
76435         nonblocking tests: Fix test failure on Linux/MIPS.
76436         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/MIPS]:
76437         Set to 270000.
76439 2011-10-27  Bruno Haible  <bruno@clisp.org>
76441         utimensat: Work around problem on Linux/hppa.
76442         * lib/utimensat.c (rpl_utimensat) [Linux/hppa]: Reject invalid tv_nsec
76443         values.
76444         * doc/posix-functions/utimensat.texi: Mention the problem on Linux/hppa.
76446 2011-10-25  Jim Meyering  <meyering@redhat.com>
76448         maint.mk: fix a bug in sc_prohibit_stddef_without_use
76449         * top/maint.mk (sc_prohibit_stddef_without_use): Don't require / *\(/
76450         after symbols like NULL, size_t, etc.
76451         Reported by Alfred M. Szmidt.
76453         maint.mk: exempt ENODATA from a syntax-check rule
76454         * top/maint.mk (gl_extract_significant_defines_): Also exempt ENODATA
76455         from the sc_prohibit_always-defined_macros syntax-check rule.
76456         Add a comment.  See this for more details:
76457         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28739/focus=28795
76459 2011-10-23  Jim Meyering  <meyering@redhat.com>
76461         fts: close parent dir FD before returning from post-traversal fts_read
76462         The problem: the fts-using "mkdir -p A/B; rm -rf A" would attempt to
76463         unlink A, even though an FD open on A remained.  This is suboptimal
76464         (holding a file descriptor open longer than needed), but otherwise not
76465         a problem on Unix-like kernels.  However, on Cygwin with certain Novell
76466         file systems, (see http://cygwin.com/ml/cygwin/2011-10/msg00365.html),
76467         that represents a real problem: it causes the removal of A to fail
76468         with e.g., "rm: cannot remove `A': Device or resource busy"
76470         fts visits each directory twice and keeps a cache (fts_fd_ring) of
76471         directory file descriptors.  After completing the final, FTS_DP,
76472         visit of a directory, RESTORE_INITIAL_CWD intended to clear the FD
76473         cache, but then proceeded to add a new FD to it via the subsequent
76474         FCHDIR (which calls cwd_advance_fd and i_ring_push).  Before, the
76475         final file descriptor would be closed only via fts_close's call to
76476         fd_ring_clear.  Now, it is usually closed earlier, via the final
76477         FTS_DP-returning fts_read call.
76478         * lib/fts.c (restore_initial_cwd): New function, converted from
76479         the macro.  Call fd_ring_clear *after* FCHDIR, not before it.
76480         Update callers.
76481         Reported by Franz Sirl via the above URL, with analysis by Eric Blake
76482         in http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28739
76484 2011-10-23  Gary V. Vaughan  <gary@gnu.org>
76485             Bruno Haible  <bruno@clisp.org>
76486             Jim Meyering  <jim@meyering.net>
76488         readme-release: improve safety of release prep instructions.
76489         * README-release: Don't git pull all branches when only master
76490         is needed for the release process.
76491         Run make maintainer-clean before changing trees and merging.
76492         Don't try to run ./configure right after git pull in case files
76493         that influence the bootstrap process have changed, move the
76494         ./configure step to after running ./bootstrap.
76495         Don't bootstrap "one last time"... it's the first time!
76497 2011-10-22  Bruno Haible  <bruno@clisp.org>
76499         errno, strerror-override: Support for MSVC 10.
76500         * lib/errno.in.h (GNULIB_defined_ETXTBSY): Remove macro.
76501         (ENOMSG, EIDRM, ENOLINK, EPROTO, EBADMSG, EOVERFLOW, ENOTSUP,
76502         ENETRESET, ECONNABORTED, ECANCELED, EINPROGRESS, EALREADY, ENOTSOCK,
76503         EDESTADDRREQ, EMSGSIZE, EPROTOTYPE, ENOPROTOOPT, EPROTONOSUPPORT,
76504         EOPNOTSUPP, EAFNOSUPPORT, EADDRINUSE, EADDRNOTAVAIL, ENETDOWN,
76505         ENETUNREACH, ECONNRESET, ENOBUFS, EISCONN, ENOTCONN, ETIMEDOUT,
76506         ECONNREFUSED, ELOOP, EHOSTUNREACH, EWOULDBLOCK, ETXTBSY) [Win32]:
76507         Assign values compatible with MSVC 10.
76508         (ENODATA, ENOSR, ENOSTR, ENOTRECOVERABLE, EOWNERDEAD, ETIME, EOTHER):
76509         New macros.
76510         (GNULIB_defined_EWINSOCK): New macro.
76511         * lib/strerror-override.c (strerror_override): Update accordingly.
76512         * lib/strerror-override.h: Likewise.
76513         * lib/w32sock.h (set_winsock_errno): Map those WSA* values that are no
76514         longer equal to the corresponding errno value.
76515         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
76517 2011-10-22  Bruno Haible  <bruno@clisp.org>
76519         perror: Recognize when test program crashes.
76520         * m4/perror.m4 (gl_FUNC_PERROR): If the test program crashes due to
76521         strerror, set gl_cv_func_perror_works to no.
76522         Reported by Daniel Richard G. <skunk@iskunk.org>.
76524         perror: Fix indentation.
76525         * m4/perror.m4 (gl_FUNC_PERROR): Fix indentation.
76527 2011-10-22  Bruno Haible  <bruno@clisp.org>
76529         isfinite, isinf, isnan, signbit: Don't define as a macro in C++.
76530         * lib/math.in.h (_GL_MATH_CXX_REAL_FLOATING_DECL_1,
76531         _GL_MATH_CXX_REAL_FLOATING_DECL_2): nEW MACROS.
76532         (isfinite, isinf, isnan, signbit): In C++, define as overloaded
76533         functions, not as a macro.
76534         * tests/test-math-c++.cc (REAL_FLOATING_CHECK, OVERLOADED_CHECK): New
76535         macros.
76536         (isfinite, isinf, isnan, signbit): Check overloaded functions and
76537         absence of macro.
76538         Suggested by Eric Blake.
76539         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
76541 2011-10-21  Bruno Haible  <bruno@clisp.org>
76543         relocatable-prog-wrapper: Don't leave object files behind.
76544         * build-aux/install-reloc: Re-synchronize list of .o files to be
76545         removed with list of compilation units.
76547 2011-10-20  Bruno Haible  <bruno@clisp.org>
76549         openpty, posix_openpt: Remove code duplication.
76550         * lib/posix_openpt.c: Add comments about platforms, from lib/openpty.c.
76551         * lib/openpty.c: Include <stdlib.h>.
76552         (openpty): Use posix_openpt on all platforms except IRIX.
76553         * modules/openpty (Depends-on): Add posix_openpt. Add conditions.
76555 2011-10-20  Bruno Haible  <bruno@clisp.org>
76557         unlockpt: Detect invalid argument.
76558         * lib/unlockpt.c: Include <fcntl.h>.
76559         (unlockpt): Check whether fd is valid, using fcntl().
76560         * modules/unlockpt (Depends-on): Add fcntl-h.
76562 2011-10-20  Bruno Haible  <bruno@clisp.org>
76564         openpty: Avoid compilation error on AIX 6.1.
76565         * lib/pty.in.h [AIX]: Include <sys/ioctl.h>, for 'struct winsize'.
76567 2011-10-20  Bruno Haible  <bruno@clisp.org>
76569         posix_openpt: Support for OpenBSD.
76570         * lib/posix_openpt.c [OpenBSD]: Include <sys/ioctl.h>, <sys/tty.h>.
76571         (posix_openpt) [OpenBSD]: New code.
76572         * lib/grantpt.c: Include <fcntl.h>.
76573         (grantpt) [OpenBSD]: Only test whether fd is valid, nothing else.
76574         * modules/grantpt (Depends-on): Add fcntl-h.
76576 2011-10-20  Bruno Haible  <bruno@clisp.org>
76578         posix_openpt test: Coding style.
76579         * tests/test-posix_openpt.c: Use GNU coding style.
76581 2011-10-20  Bruno Haible  <bruno@clisp.org>
76583         grantpt: Support --avoid=pt_chown.
76584         * modules/grantpt (Files): Add lib/pty-private.h.
76586 2011-10-20  Bruno Haible  <bruno@clisp.org>
76588         posix_openpt: Fix autoconf macro.
76589         * m4/posix_openpt.m4 (gl_FUNC_POSIX_OPENPT): Fix variable name. Remove
76590         unneeded check for _getpty.
76592 2011-10-20  Bruno Haible  <bruno@clisp.org>
76594         openpty: Update comments.
76595         * lib/openpty.c: Add comments about Minix.
76597 2011-10-19  Eric Blake  <eblake@redhat.com>
76599         openpty: relax license
76600         * modules/openpty (License): Change from LGPLv3+ to LGPLv2+.
76602         pt_chown: use configmake to simplify build
76603         * modules/pt_chown (Makefile.am): Drop line guaranteed by configmake.
76605         ptsname and others: relax license
76606         * modules/grantpt (License): Change from LGPLv3+ to LGPLv2+.
76607         * modules/unlockpt (License): Likewise.
76608         * modules/pt_chown (License): Likewise.
76609         * modules/ptsname (License): Likewise.
76610         * modules/ttyname_r (License): Likewise.
76612 2011-10-19  Jim Meyering  <meyering@redhat.com>
76614         posix_openpt: remove spurious #endif
76615         * lib/posix_openpt.c (posix_openpt): Remove spurious #endif.
76617 2011-10-19  Gary V. Vaughan  <gary@gnu.org>
76619         maint.mk: Respect $(build_aux) in web-manual rule.
76620         * top/maint.mk (web-manual): Find gen-announce script in user's
76621         $(build_aux) directory instead of hard-coding 'build-aux'.
76623 2011-10-19  Bruno Haible  <bruno@clisp.org>
76625         posix_openpt: Fix compilation error.
76626         * lib/posix_openpt.c (posix_openpt): Renamed from posix_openpty.
76627         * doc/posix-functions/posix_openpt.texi: Mention ENOENT error code.
76628         Mention the openpty module as an alternative.
76630 2011-10-19  Bruno Haible  <bruno@clisp.org>
76632         Support for old NeXTstep 3.3 frexp().
76633         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Check for alarm. Limit the
76634         execution time of the test to 5 seconds.
76635         Reported by Daniel Richard G. <skunk@iskunk.org>.
76637 2011-10-19  Bruno Haible  <bruno@clisp.org>
76639         Support for old NeXTstep 3.3 sed.
76640         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): In the sed address
76641         part, use /.../, not \|...|. Escape periods in the header file name.
76642         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Likewise.
76643         Reported by Daniel Richard G. <skunk@iskunk.org>.
76645 2011-10-18  Daniel Richard G.  <skunk@iskunk.org>  (tiny change)
76647         Support for old NeXTstep 3.3 gcc.
76648         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Write
76649         'defined __STRICT_ANSI__', not '__STRICT_ANSI__'.
76650         * lib/math.in.h (_GL_NUM_UINT_WORDS etc.): Likewise.
76651         * lib/spawn.in.h (_Restrict_arr_): Likewise.
76652         * lib/regex.h (_Restrict_arr_): Likewise.
76653         * lib/regex_internal.h (re_token_t): Likewise.
76654         * lib/regexec.c (check_node_accept_bytes): Likewise.
76655         * tests/test-printf-posix.c (func1, func2, func3, func4): Likewise.
76657 2011-10-18  Eric Blake  <eblake@redhat.com>
76659         posix_openpt: new module
76660         * modules/posix_openpt: New module.
76661         * m4/posix_openpt.m4: New file.
76662         * lib/posix_openpt.c: Likewise.
76663         * m4/stdlib_h.m4 (gl_STDLIB_H): Check for decl.
76664         (gl_STDLIB_H_DEFAULTS): Set defaults.
76665         * modules/stdlib (Makefile.am): Substitute macros.
76666         * lib/stdlib.in.h (posix_openpt): Declare.
76667         * MODULES.html.sh (systems lacking POSIX:2008): Document it.
76668         * doc/posix-functions/posix_openpt.texi (posix_openpt): Likewise.
76669         * modules/posix_openpt-tests: New test module.
76670         * tests/test-posix_openpt.c: New test.
76672 2011-10-15  Bruno Haible  <bruno@clisp.org>
76674         xstrtoll: Fix compilation failure.
76675         * lib/xstrtol.c (ULLONG_MAX, LLONG_MAX, LLONG_MIN): New macros, taken
76676         from lib/strtol.c.
76677         * doc/posix-headers/limits.texi: Mention missing numerical limits on
76678         some platforms.
76679         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
76681 2011-10-15  Bruno Haible  <bruno@clisp.org>
76683         vasnprintf: Optimize bit search operation.
76684         * lib/vasnprintf.c (divide): Use optimizations from integer_length.c.
76685         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Require
76686         gl_DOUBLE_EXPONENT_LOCATION.
76687         * modules/vasnprintf (Files): Add m4/exponentd.m4.
76688         * modules/unistdio/u8-vasnprintf (Files): Likewise.
76689         * modules/unistdio/u8-u8-vasnprintf (Files): Likewise.
76690         * modules/unistdio/u16-vasnprintf (Files): Likewise.
76691         * modules/unistdio/u16-u16-vasnprintf (Files): Likewise.
76692         * modules/unistdio/u32-vasnprintf (Files): Likewise.
76693         * modules/unistdio/u32-u32-vasnprintf (Files): Likewise.
76694         * modules/unistdio/ulc-vasnprintf (Files): Likewise.
76695         * m4/isnand.m4 (gl_PREREQ_ISNAND): Use AC_REQUIRE.
76697 2011-10-15  Bruno Haible  <bruno@clisp.org>
76699         vasnprintf: Fix comments.
76700         * lib/vasnprintf.c (decode_long_double, decode_double): Fix comments.
76702 2011-10-14  Bruno Haible  <bruno@clisp.org>
76704         Tests for module 'integer_length_ll'.
76705         * modules/integer_length_ll-tests: New file.
76706         * tests/test-integer_length_ll.c: New file.
76708         New module 'integer_length_ll'.
76709         * lib/integer_length_ll.c: New file.
76710         * modules/integer_length_ll: New file.
76712 2011-10-14  Bruno Haible  <bruno@clisp.org>
76714         Tests for module 'integer_length_l'.
76715         * modules/integer_length_l-tests: New file.
76716         * tests/test-integer_length_l.c: New file.
76718         New module 'integer_length_l'.
76719         * lib/integer_length_l.c: New file.
76720         * modules/integer_length_l: New file.
76722 2011-10-14  Bruno Haible  <bruno@clisp.org>
76724         Tests for module 'integer_length'.
76725         * modules/integer_length-tests: New file.
76726         * tests/test-integer_length.c: New file.
76728         New module 'integer_length'.
76729         * lib/integer_length.h: New file.
76730         * lib/integer_length.c: New file.
76731         * modules/integer_length: New file.
76733 2011-10-14  Daniel Richard G.  <skunk@iskunk.org>  (tiny change)
76735         popen: Fix dependency conditions.
76736         * modules/popen (Depends-on, configure.ac): Fix shell syntax error.
76738 2011-10-14  Daniel Richard G.  <skunk@iskunk.org>  (tiny change)
76740         perror: Fix autoconf test.
76741         * m4/perror.m4 (gl_FUNC_PERROR): In the test program, include
76742         <stdlib.h> and <string.h>.
76744 2011-10-14  Bruno Haible  <bruno@clisp.org>
76746         ffsl: Optimize on 64-bit platforms.
76747         * lib/ffsl.h (FUNC): Omit a test from the last loop round. Do loop
76748         unrolling.
76750 2011-10-13  Bruno Haible  <bruno@clisp.org>
76752         ffsl: Optimize on 32-bit platforms.
76753         * lib/ffsl.h (FUNC): If TYPE has the same representation as 'int', just
76754         use ffs() without a loop.
76756         ffsl, ffsll: Optimize for GCC.
76757         * lib/ffsl.h (FUNC): Use GCC_BUILTIN if defined.
76758         * lib/ffsl.c (GCC_BUILTIN): New macro.
76759         * lib/ffsll.c (GCC_BUILTIN): Likewise.
76761 2011-10-13  Bruno Haible  <bruno@clisp.org>
76763         ffs, bcopy, memset: Support symbol renaming via config.h.
76764         * lib/ffs.c: Include <config.h>.
76765         * lib/bcopy.c: Likewise.
76766         * lib/memset.c: Likewise.
76768 2011-10-10  Bruno Haible  <bruno@clisp.org>
76770         atanl: Simplify for platforms where 'long double' == 'double'.
76771         * lib/atanl.c (atanl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
76772         alternative implementation.
76773         * m4/atanl.m4 (gl_FUNC_ATANL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76774         Determine ATANL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76775         * modules/atanl (Depends-on): Add atan. Update conditions.
76777 2011-10-10  Bruno Haible  <bruno@clisp.org>
76779         acosl: Simplify for platforms where 'long double' == 'double'.
76780         * lib/acosl.c (acosl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
76781         alternative implementation.
76782         * m4/acosl.m4 (gl_FUNC_ACOSL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76783         Determine ACOSL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76784         * modules/acosl (Depends-on): Add acos. Update conditions.
76786 2011-10-10  Bruno Haible  <bruno@clisp.org>
76788         asinl: Simplify for platforms where 'long double' == 'double'.
76789         * lib/asinl.c (asinl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
76790         alternative implementation.
76791         * m4/asinl.m4 (gl_FUNC_ASINL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76792         Determine ASINL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76793         * modules/asinl (Depends-on): Add asin. Update conditions.
76795 2011-10-10  Bruno Haible  <bruno@clisp.org>
76797         tanl: Simplify for platforms where 'long double' == 'double'.
76798         * lib/tanl.c (tanl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
76799         implementation.
76800         * m4/tanl.m4 (gl_FUNC_TANL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76801         Determine TANL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76802         * modules/tanl (Depends-on): Add tan. Update conditions.
76803         (configure.ac): Don't compile trigl.c if
76804         HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76806 2011-10-10  Bruno Haible  <bruno@clisp.org>
76808         cosl: Simplify for platforms where 'long double' == 'double'.
76809         * lib/cosl.c (cosl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
76810         implementation.
76811         * m4/cosl.m4 (gl_FUNC_COSL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76812         Determine COSL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76813         * modules/cosl (Depends-on): Add cos. Update conditions.
76814         (configure.ac): Don't compile sincosl.c and trigl.c if
76815         HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76817 2011-10-10  Bruno Haible  <bruno@clisp.org>
76819         sinl: Simplify for platforms where 'long double' == 'double'.
76820         * lib/sinl.c (sinl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
76821         implementation.
76822         * m4/sinl.m4 (gl_FUNC_SINL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76823         Determine SINL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76824         * modules/sinl (Depends-on): Add sin. Update conditions.
76825         (configure.ac): Don't compile sincosl.c and trigl.c if
76826         HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76828 2011-10-10  Bruno Haible  <bruno@clisp.org>
76830         logl: Simplify for platforms where 'long double' == 'double'.
76831         * lib/logl.c (logl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
76832         implementation.
76833         * m4/logl.m4 (gl_FUNC_LOGL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76834         Determine LOGL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76835         * modules/logl (Depends-on): Add log. Update conditions.
76837 2011-10-10  Bruno Haible  <bruno@clisp.org>
76839         expl: Simplify for platforms where 'long double' == 'double'.
76840         * lib/expl.c (expl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
76841         implementation.
76842         * m4/expl.m4 (gl_FUNC_EXPL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76843         Determine EXPL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76844         * modules/expl (Depends-on): Add exp. Update conditions.
76846 2011-10-10  Bruno Haible  <bruno@clisp.org>
76848         sqrtl: Simplify for platforms where 'long double' == 'double'.
76849         * lib/sqrtl.c (sqrtl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
76850         alternative implementation.
76851         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76852         Determine SQRTL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76853         * modules/sqrtl (Depends-on): Update conditions.
76855 2011-10-10  Bruno Haible  <bruno@clisp.org>
76857         ldexpl: Simplify for platforms where 'long double' == 'double'.
76858         * lib/ldexpl.c (ldexpl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
76859         alternative implementation.
76860         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76861         Determine LDEXPL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76862         * modules/ldexpl (Depends-on): Add ldexp. Update conditions.
76864 2011-10-10  Tom G. Christensen  <tgc@jupiterrise.com>  (tiny change)
76866         ffsll: set correct witness
76867         * modules/ffsll (configure.ac): Fix typo.
76869 2011-10-10  Bruno Haible  <bruno@clisp.org>
76871         printf-frexpl: Simplify for platforms where 'long double' == 'double'.
76872         * lib/printf-frexpl.c: Include <config.h>.
76873         (printf_frexpl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
76874         * lib/printf-frexp.c [!USE_LONG_DOUBLE]: Don't include <config.h> a
76875         second time.
76876         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Require
76877         gl_LONG_DOUBLE_VS_DOUBLE.
76878         * modules/printf-frexpl (Depends-on): Add printf-frexp. Update
76879         conditions.
76881 2011-10-10  Bruno Haible  <bruno@clisp.org>
76883         frexpl: Simplify for platforms where 'long double' == 'double'.
76884         * lib/frexpl.c: Include <config.h>.
76885         (frexpl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
76886         * lib/frexp.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
76887         time.
76888         * m4/frexpl.m4 (gl_FUNC_FREXPL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76889         Determine FREXPL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76890         (gl_FUNC_FREXPL_NO_LIBM): Require gl_LONG_DOUBLE_VS_DOUBLE.
76891         * modules/frexpl (Depends-on): Add frexp. Update conditions.
76892         * modules/frexpl-nolibm (Depends-on): Add frexp-nolibm. Update
76893         conditions.
76895 2011-10-10  Jim Meyering  <meyering@redhat.com>
76897         test-renameat: don't leave behind a temporary file
76898         * tests/test-renameat.c (main): Don't forget to remove a temporary file.
76899           ERROR: files left in build directory after distclean:
76900           ./gltests/test-renameat.too
76901           make[1]: *** [distcleancheck] Error 1
76902         Reported by Tom G. Christensen.
76904 2011-10-09  Bruno Haible  <bruno@clisp.org>
76906         rint: Determine RINT_LIBM correctly on AIX 7.
76907         * m4/mathfunc.m4 (gl_MATHFUNC): Try to invoke the function also
76908         directly, not only through a function pointer. Also accept an optional
76909         4th argument with extra code.
76910         * m4/rint.m4 (gl_FUNC_RINT): Pass an extra code that gets turned into a
76911         rintf() call by gcc when optimizing.
76913         mathfunc.m4: Refactor.
76914         * m4/mathfunc.m4 (gl_MATHFUNC): Assign the argument list to a temporary
76915         m4 variable.
76917 2011-10-09  Bruno Haible  <bruno@clisp.org>
76919         rintl: Simplify for platforms where 'long double' == 'double'.
76920         * lib/rintl.c: Include <config.h>.
76921         (rintl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
76922         * lib/rint.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
76923         time.
76924         * m4/rintl.m4 (gl_FUNC_RINTL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76925         Determine RINTL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76926         * modules/rintl (Depends-on): Add rint. Update conditions.
76928 2011-10-09  Bruno Haible  <bruno@clisp.org>
76930         roundl: Simplify for platforms where 'long double' == 'double'.
76931         * lib/roundl.c: Include <config.h>.
76932         (roundl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
76933         * lib/round.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
76934         time.
76935         * m4/roundl.m4 (gl_FUNC_ROUNDL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76936         Determine ROUNDL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76937         * modules/roundl (Depends-on): Add round. Update conditions.
76939 2011-10-09  Bruno Haible  <bruno@clisp.org>
76941         truncl: Simplify for platforms where 'long double' == 'double'.
76942         * lib/truncl.c: Include <config.h>.
76943         (truncl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
76944         * lib/trunc.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
76945         time.
76946         * m4/truncl.m4 (gl_FUNC_TRUNCL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76947         Determine TRUNCL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76948         * modules/truncl (Depends-on): Add trunc. Update conditions.
76950 2011-10-09  Bruno Haible  <bruno@clisp.org>
76952         ceill: Simplify for platforms where 'long double' == 'double'.
76953         * lib/ceill.c: Include <config.h>.
76954         (ceill) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
76955         * lib/ceil.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
76956         time.
76957         * m4/ceill.m4 (gl_FUNC_CEILL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76958         Determine CEILL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76959         * modules/ceill (Depends-on): Add ceil. Update conditions.
76961 2011-10-09  Bruno Haible  <bruno@clisp.org>
76963         floorl: Simplify for platforms where 'long double' == 'double'.
76964         * lib/floorl.c: Include <config.h>.
76965         (floorl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
76966         * lib/floor.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
76967         time.
76968         * m4/floorl.m4 (gl_FUNC_FLOORL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76969         Determine FLOORL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76970         * modules/floorl (Depends-on): Add floor. Update conditions.
76972 2011-10-09  Bruno Haible  <bruno@clisp.org>
76974         rint: Fix ordering constraints.
76975         * m4/rint.m4 (gl_FUNC_RINT): Require gl_MATH_H_DEFAULTS.
76976         * m4/rintf.m4 (gl_FUNC_RINTF): Likewise.
76977         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
76979 2011-10-09  Bruno Haible  <bruno@clisp.org>
76981         copysignl: Simplify for platforms where 'long double' == 'double'.
76982         * lib/copysignl.c (copysignl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
76983         alternative.
76984         * m4/copysignl.m4 (gl_FUNC_COPYSIGNL): Require gl_LONG_DOUBLE_VS_DOUBLE.
76985         Determine COPYSIGNL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
76986         * modules/copysignl (Depends-on): Add copysign. Update conditions.
76988 2011-10-09  Bruno Haible  <bruno@clisp.org>
76990         Tests for module 'rintl'.
76991         * modules/rintl-tests: New file.
76992         * tests/test-rintl.c: New file.
76994         New module 'rintl'.
76995         * lib/math.in.h (rintl): New declaration.
76996         * lib/rintl.c: New file.
76997         * m4/rintl.m4: New file.
76998         * m4/math_h.m4 (gl_MATH_H): Test whether rintl is declared.
76999         (gl_MATH_H_DEFAULTS): Initialize GNULIB_RINTL, HAVE_RINTL.
77000         * modules/math (Makefile.am): Substitute GNULIB_RINTL, HAVE_RINTL.
77001         * modules/rintl: New file.
77002         * tests/test-math-c++.cc: Check the declaration of rintl.
77003         * modules/math-c++-tests (Makefile.am): Link test-math-c++ against
77004         $(RINTL_LIBM). Needed on IRIX 6.5 with cc.
77005         * doc/posix-functions/rintl.texi: Mention the new module.
77007 2011-10-09  Bruno Haible  <bruno@clisp.org>
77009         Tests for module 'rintf'.
77010         * modules/rintf-tests: New file.
77011         * tests/test-rintf.c: New file.
77013         New module 'rintf'.
77014         * lib/math.in.h (rintf): New declaration.
77015         * lib/rintf.c: New file.
77016         * m4/rintf.m4: New file.
77017         * m4/math_h.m4 (gl_MATH_H): Test whether rintf is declared.
77018         (gl_MATH_H_DEFAULTS): Initialize GNULIB_RINTF, HAVE_RINTF.
77019         * modules/math (Makefile.am): Substitute GNULIB_RINTF, HAVE_RINTF.
77020         * modules/rintf: New file.
77021         * tests/test-math-c++.cc: Check the declaration of rintf.
77022         * doc/posix-functions/rintf.texi: Mention the new module.
77024 2011-10-09  Bruno Haible  <bruno@clisp.org>
77026         rint: Support for MSVC.
77027         * lib/math.in.h (rint): New declaration.
77028         * lib/rint.c: New file.
77029         * m4/rint.m4: New file.
77030         * m4/math_h.m4 (gl_MATH_H): Test whether rint is declared.
77031         (gl_MATH_H_DEFAULTS): Initialize GNULIB_RINT, HAVE_RINT.
77032         * modules/math (Makefile.am): Substitute GNULIB_RINT, HAVE_RINT.
77033         * modules/rint (Description): Fix.
77034         (Files): Add lib/rint.c, m4/rint.m4.
77035         (Depends-on): Add math.
77036         (configure.ac): Invoke gl_FUNC_RINT, AC_LIBOBJ,
77037         gl_MATH_MODULE_INDICATOR.
77038         * tests/test-math-c++.cc: Check the declaration of rint.
77039         * modules/math-c++-tests (Makefile.am): Link test-math-c++ against
77040         $(RINT_LIBM). Needed on IRIX 6.5 with cc.
77041         * doc/posix-functions/rint.texi: Mention the replacement provided by
77042         the module.
77044         rint tests: More tests.
77045         * tests/test-rint.c: Include <float.h>, <stdio.h>, isnand-nolibm.h,
77046         minus-zero.h, infinity.h, nan.h.
77047         (main): Skip the test if the current rounding mode is not standard. Add
77048         tests for negative numbers, minus zero, infinity, NaN.
77049         * modules/rint-tests (Files): Add tests/minus-zero.h, tests/infinity.h,
77050         tests/nan.h.
77051         (Depends-on): Add isnand-nolibm.
77053 2011-10-09  Bruno Haible  <bruno@clisp.org>
77055         Tests for module 'copysignl'.
77056         * modules/copysignl-tests: New file.
77057         * tests/test-copysignl.c: New file.
77059         New module 'copysignl'.
77060         * lib/math.in.h (copysignl): New declaration.
77061         * lib/copysignl.c: New file.
77062         * m4/copysignl.m4: New file.
77063         * m4/math_h.m4 (gl_MATH_H): Test whether copysignl is declared.
77064         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COPYSIGNL, HAVE_COPYSIGNL.
77065         * modules/math (Makefile.am): Substitute GNULIB_COPYSIGNL,
77066         HAVE_COPYSIGNL.
77067         * modules/copysignl: New file.
77068         * tests/test-math-c++.cc: Check the declaration of copysignl.
77069         * modules/math-c++-tests (Makefile.am): Link test-math-c++ against
77070         $(COPYSIGNL_LIBM). Needed on IRIX 6.5 with cc.
77071         * doc/posix-functions/copysignl.texi: Mention the new module.
77073 2011-10-09  Bruno Haible  <bruno@clisp.org>
77075         Tests for module 'copysignf'.
77076         * modules/copysignf-tests: New file.
77077         * tests/test-copysignf.c: New file.
77079         New module 'copysignf'.
77080         * lib/math.in.h (copysignf): New declaration.
77081         * lib/copysignf.c: New file.
77082         * m4/copysignf.m4: New file.
77083         * m4/math_h.m4 (gl_MATH_H): Test whether copysignf is declared.
77084         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COPYSIGNF, HAVE_COPYSIGNF.
77085         * modules/math (Makefile.am): Substitute GNULIB_COPYSIGNF,
77086         HAVE_COPYSIGNF.
77087         * modules/copysignf: New file.
77088         * tests/test-math-c++.cc: Check the declaration of copysignf.
77089         * doc/posix-functions/copysignf.texi: Mention the new module.
77091 2011-10-09  Bruno Haible  <bruno@clisp.org>
77093         Ensure that HAVE_* variables are set to 1 before they are set to 0.
77094         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Require gl_DIRENT_H_DEFAULTS.
77095         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Require gl_ARPA_INET_H_DEFAULTS.
77096         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
77097         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Require
77098         gl_SIGNAL_H_DEFAULTS.
77100 2011-10-09  Bruno Haible  <bruno@clisp.org>
77102         poll: Make macro safer.
77103         * m4/poll.m4 (gl_FUNC_POLL): Complain if, after invoking gl_POLL_H,
77104         ac_cv_header_poll_h is not set.
77106 2011-10-09  Bruno Haible  <bruno@clisp.org>
77108         copysign: Provide replacement.
77109         * lib/math.in.h (copysign): New declaration.
77110         * lib/copysign.c: New file.
77111         * m4/copysign.m4: New file.
77112         * m4/math_h.m4 (gl_MATH_H): Test whether copysign is declared.
77113         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COPYSIGN, HAVE_COPYSIGN.
77114         * modules/math (Makefile.am): Substitute GNULIB_COPYSIGN,
77115         HAVE_COPYSIGN.
77116         * modules/copysign (Description): Clarify.
77117         (Files): Add lib/copysign.c, m4/copysign.m4.
77118         (Depends-on): Add math, signbit.
77119         (configure.ac): Invoke gl_FUNC_COPYSIGN, AC_LIBOBJ,
77120         gl_MATH_MODULE_INDICATOR.
77121         * tests/test-math-c++.cc: Check the declaration of copysign.
77122         * doc/posix-functions/copysign.texi: Mention the effects of the module
77123         on Minix and MSVC.
77125 2011-10-09  Bruno Haible  <bruno@clisp.org>
77127         isinf: Ensure macro on AIX 5.1.
77128         * m4/isinf.m4 (gl_ISINF): Also test whether isinf is defined as a
77129         macro.
77130         * doc/posix-functions/isinf.texi: Mention also AIX 5.1 as deficient.
77132 2011-10-09  Bruno Haible  <bruno@clisp.org>
77134         *printf-posix tests: Fix for platforms where 'long double' == 'double'.
77135         * modules/snprintf-posix-tests (configure.ac): Require
77136         gl_LONG_DOUBLE_VS_DOUBLE.
77137         * modules/sprintf-posix-tests (configure.ac): Likewise.
77138         * modules/vasnprintf-posix-tests (configure.ac): Likewise.
77139         * modules/vasprintf-posix-tests (configure.ac): Likewise.
77140         * modules/vsnprintf-posix-tests (configure.ac): Likewise.
77141         * modules/vsprintf-posix-tests (configure.ac): Likewise.
77142         * tests/test-snprintf-posix.h (test_function): Avoid 80-bit long double
77143         tests on platforms where 'long double' is the same as 'double'.
77144         * tests/test-sprintf-posix.h (test_function): Likewise.
77145         * tests/test-vasnprintf-posix.c (test_function): Likewise.
77146         * tests/test-vasprintf-posix.c (test_function): Likewise.
77148         *printf: Fix for platforms where 'long double' == 'double'.
77149         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
77150         gl_LONG_DOUBLE_VS_DOUBLE. Don't blindly assume 80-bit 'long double'.
77151         * modules/dprintf-posix (Files): Add m4/math_h.m4.
77152         * modules/fprintf-posix (Files): Likewise.
77153         * modules/obstack-printf-posix (Files): Likewise.
77154         * modules/snprintf-posix (Files): Likewise.
77155         * modules/sprintf-posix (Files): Likewise.
77156         * modules/vasnprintf (Files): Likewise.
77157         * modules/vasnprintf-posix (Files): Likewise.
77158         * modules/vasprintf-posix (Files): Likewise.
77159         * modules/vdprintf-posix (Files): Likewise.
77160         * modules/vfprintf-posix (Files): Likewise.
77161         * modules/vsnprintf-posix (Files): Likewise.
77162         * modules/vsprintf-posix (Files): Likewise.
77163         * modules/unistdio/u8-vasnprintf (Files): Likewise.
77164         * modules/unistdio/u8-u8-vasnprintf (Files): Likewise.
77165         * modules/unistdio/u16-vasnprintf (Files): Likewise.
77166         * modules/unistdio/u16-u16-vasnprintf (Files): Likewise.
77167         * modules/unistdio/u32-vasnprintf (Files): Likewise.
77168         * modules/unistdio/u32-u32-vasnprintf (Files): Likewise.
77169         * modules/unistdio/ulc-vasnprintf (Files): Likewise.
77171         isnanl[-nolibm]: Fix for platforms where 'long double' == 'double'.
77172         * lib/isnan.c (rpl_isnanl): Don't blindly assume 80-bit 'long double'.
77173         * m4/isnanl.m4 (gl_PREREQ_ISNANL): Require gl_LONG_DOUBLE_VS_DOUBLE.
77174         (gl_FUNC_ISNANL_WORKS): Likewise. Don't blindly assume 80-bit
77175         'long double'.
77176         * modules/isnanl-nolibm (Files): Add m4/math_h.m4.
77178         isinf: Fix for platforms where 'long double' == 'double'.
77179         * m4/isinf.m4 (gl_ISINFL_WORKS): Require gl_LONG_DOUBLE_VS_DOUBLE.
77180         Don't blindly assume 80-bit 'long double'.
77182         isfinite: Fix for platforms where 'long double' == 'double'.
77183         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Require gl_LONG_DOUBLE_VS_DOUBLE.
77184         Don't blindly assume 80-bit 'long double'.
77186         isfinite, isinf, isnan tests: Avoid syntax error on MSVC 9.
77187         * m4/math_h.m4 (gl_LONG_DOUBLE_VS_DOUBLE): New macro.
77188         * modules/isfinite-tests (configure.ac): Require
77189         gl_LONG_DOUBLE_VS_DOUBLE.
77190         * modules/isinf-tests (configure.ac): Likewise.
77191         * modules/isnan-tests (configure.ac): Likewise.
77192         * modules/isnanl-tests (configure.ac): Likewise.
77193         * modules/isnanl-nolibm-tests (configure.ac): Likewise.
77194         * tests/test-isfinite.c (test_isfinitel): Avoid 80-bit long double
77195         tests on platforms where 'long double' is the same as 'double'.
77196         * tests/test-isinf.c (test_isinfl): Likewise.
77197         * tests/test-isnan.c (test_long_double): Likewise.
77198         * tests/test-isnanl.h (main): Likewise.
77200 2011-10-08  Bruno Haible  <bruno@clisp.org>
77202         Tests for module 'tanhf'.
77203         * modules/tanhf-tests: New file.
77204         * tests/test-tanhf.c: New file.
77206         New module 'tanhf'.
77207         * lib/math.in.h (tanhf): New declaration.
77208         * lib/tanhf.c: New file.
77209         * m4/tanhf.m4: New file.
77210         * m4/math_h.m4 (gl_MATH_H): Test whether tanhf is declared.
77211         (gl_MATH_H_DEFAULTS): Initialize GNULIB_TANHF, HAVE_TANHF.
77212         * modules/math (Makefile.am): Substitute GNULIB_TANHF, HAVE_TANHF.
77213         * modules/tanhf: New file.
77214         * tests/test-math-c++.cc: Check the declaration of tanhf.
77215         * doc/posix-functions/tanhf.texi: Mention the new module.
77217         tanh: Use a .m4 file.
77218         * m4/tanh.m4: New file.
77219         * modules/tanh (Files): Add it.
77220         (configure.ac): Just invoke gl_FUNC_TANH.
77222 2011-10-08  Bruno Haible  <bruno@clisp.org>
77224         Tests for module 'coshf'.
77225         * modules/coshf-tests: New file.
77226         * tests/test-coshf.c: New file.
77228         New module 'coshf'.
77229         * lib/math.in.h (coshf): New declaration.
77230         * lib/coshf.c: New file.
77231         * m4/coshf.m4: New file.
77232         * m4/math_h.m4 (gl_MATH_H): Test whether coshf is declared.
77233         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COSHF, HAVE_COSHF.
77234         * modules/math (Makefile.am): Substitute GNULIB_COSHF, HAVE_COSHF.
77235         * modules/coshf: New file.
77236         * tests/test-math-c++.cc: Check the declaration of coshf.
77237         * doc/posix-functions/coshf.texi: Mention the new module.
77239         cosh: Use a .m4 file.
77240         * m4/cosh.m4: New file.
77241         * modules/cosh (Files): Add it.
77242         (configure.ac): Just invoke gl_FUNC_COSH.
77244 2011-10-08  Bruno Haible  <bruno@clisp.org>
77246         Tests for module 'sinhf'.
77247         * modules/sinhf-tests: New file.
77248         * tests/test-sinhf.c: New file.
77250         New module 'sinhf'.
77251         * lib/math.in.h (sinhf): New declaration.
77252         * lib/sinhf.c: New file.
77253         * m4/sinhf.m4: New file.
77254         * m4/math_h.m4 (gl_MATH_H): Test whether sinhf is declared.
77255         (gl_MATH_H_DEFAULTS): Initialize GNULIB_SINHF, HAVE_SINHF.
77256         * modules/math (Makefile.am): Substitute GNULIB_SINHF, HAVE_SINHF.
77257         * modules/sinhf: New file.
77258         * tests/test-math-c++.cc: Check the declaration of sinhf.
77259         * doc/posix-functions/sinhf.texi: Mention the new module.
77261         sinh: Use a .m4 file.
77262         * m4/sinh.m4: New file.
77263         * modules/sinh (Files): Add it.
77264         (configure.ac): Just invoke gl_FUNC_SINH.
77266 2011-10-08  Bruno Haible  <bruno@clisp.org>
77268         Tests for module 'atan2f'.
77269         * modules/atan2f-tests: New file.
77270         * tests/test-atan2f.c: New file.
77272         New module 'atan2f'.
77273         * lib/math.in.h (atan2f): New declaration.
77274         * lib/atan2f.c: New file.
77275         * m4/atan2f.m4: New file.
77276         * m4/math_h.m4 (gl_MATH_H): Test whether atan2f is declared.
77277         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ATAN2F, HAVE_ATAN2F.
77278         * modules/math (Makefile.am): Substitute GNULIB_ATAN2F, HAVE_ATAN2F.
77279         * modules/atan2f: New file.
77280         * tests/test-math-c++.cc: Check the declaration of atan2f.
77281         * doc/posix-functions/atan2f.texi: Mention the new module.
77283         atan2: Use a .m4 file.
77284         * m4/atan2.m4: New file.
77285         * modules/atan2 (Files): Add it.
77286         (configure.ac): Just invoke gl_FUNC_ATAN2.
77288 2011-10-08  Bruno Haible  <bruno@clisp.org>
77290         Tests for module 'atanf'.
77291         * modules/atanf-tests: New file.
77292         * tests/test-atanf.c: New file.
77294         New module 'atanf'.
77295         * lib/math.in.h (atanf): New declaration.
77296         * lib/atanf.c: New file.
77297         * m4/atanf.m4: New file.
77298         * m4/math_h.m4 (gl_MATH_H): Test whether atanf is declared.
77299         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ATANF, HAVE_ATANF.
77300         * modules/math (Makefile.am): Substitute GNULIB_ATANF, HAVE_ATANF.
77301         * modules/atanf: New file.
77302         * tests/test-math-c++.cc: Check the declaration of atanf.
77303         * doc/posix-functions/atanf.texi: Mention the new module.
77305         atan: Use a .m4 file.
77306         * m4/atan.m4: New file.
77307         * modules/atan (Files): Add it.
77308         (configure.ac): Just invoke gl_FUNC_ATAN.
77310 2011-10-08  Bruno Haible  <bruno@clisp.org>
77312         Tests for module 'acosf'.
77313         * modules/acosf-tests: New file.
77314         * tests/test-acosf.c: New file.
77316         New module 'acosf'.
77317         * lib/math.in.h (acosf): New declaration.
77318         * lib/acosf.c: New file.
77319         * m4/acosf.m4: New file.
77320         * m4/math_h.m4 (gl_MATH_H): Test whether acosf is declared.
77321         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ACOSF, HAVE_ACOSF.
77322         * modules/math (Makefile.am): Substitute GNULIB_ACOSF, HAVE_ACOSF.
77323         * modules/acosf: New file.
77324         * tests/test-math-c++.cc: Check the declaration of acosf.
77325         * doc/posix-functions/acosf.texi: Mention the new module.
77327         acos: Use a .m4 file.
77328         * m4/acos.m4: New file.
77329         * modules/acos (Files): Add it.
77330         (configure.ac): Just invoke gl_FUNC_ACOS.
77332 2011-10-08  Bruno Haible  <bruno@clisp.org>
77334         Tests for module 'asinf'.
77335         * modules/asinf-tests: New file.
77336         * tests/test-asinf.c: New file.
77338         New module 'asinf'.
77339         * lib/math.in.h (asinf): New declaration.
77340         * lib/asinf.c: New file.
77341         * m4/asinf.m4: New file.
77342         * m4/math_h.m4 (gl_MATH_H): Test whether asinf is declared.
77343         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ASINF, HAVE_ASINF.
77344         * modules/math (Makefile.am): Substitute GNULIB_ASINF, HAVE_ASINF.
77345         * modules/asinf: New file.
77346         * tests/test-math-c++.cc: Check the declaration of asinf.
77347         * doc/posix-functions/asinf.texi: Mention the new module.
77349         asin: Use a .m4 file.
77350         * m4/asin.m4: New file.
77351         * modules/asin (Files): Add it.
77352         (configure.ac): Just invoke gl_FUNC_ASIN.
77354 2011-10-08  Bruno Haible  <bruno@clisp.org>
77356         Tests for module 'tanf'.
77357         * modules/tanf-tests: New file.
77358         * tests/test-tanf.c: New file.
77360         New module 'tanf'.
77361         * lib/math.in.h (tanf): New declaration.
77362         * lib/tanf.c: New file.
77363         * m4/tanf.m4: New file.
77364         * m4/math_h.m4 (gl_MATH_H): Test whether tanf is declared.
77365         (gl_MATH_H_DEFAULTS): Initialize GNULIB_TANF, HAVE_TANF.
77366         * modules/math (Makefile.am): Substitute GNULIB_TANF, HAVE_TANF.
77367         * modules/tanf: New file.
77368         * tests/test-math-c++.cc: Check the declaration of tanf.
77369         * doc/posix-functions/tanf.texi: Mention the new module.
77371         tan: Use a .m4 file.
77372         * m4/tan.m4: New file.
77373         * modules/tan (Files): Add it.
77374         (configure.ac): Just invoke gl_FUNC_TAN.
77376 2011-10-08  Bruno Haible  <bruno@clisp.org>
77378         Tests for module 'cosf'.
77379         * modules/cosf-tests: New file.
77380         * tests/test-cosf.c: New file.
77382         New module 'cosf'.
77383         * lib/math.in.h (cosf): New declaration.
77384         * lib/cosf.c: New file.
77385         * m4/cosf.m4: New file.
77386         * m4/math_h.m4 (gl_MATH_H): Test whether cosf is declared.
77387         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COSF, HAVE_COSF.
77388         * modules/math (Makefile.am): Substitute GNULIB_COSF, HAVE_COSF.
77389         * modules/cosf: New file.
77390         * tests/test-math-c++.cc: Check the declaration of cosf.
77391         * doc/posix-functions/cosf.texi: Mention the new module.
77393         cos: Use a .m4 file.
77394         * m4/cos.m4: New file.
77395         * modules/cos (Files): Add it.
77396         (configure.ac): Just invoke gl_FUNC_COS.
77398 2011-10-08  Bruno Haible  <bruno@clisp.org>
77400         Tests for module 'sinf'.
77401         * modules/sinf-tests: New file.
77402         * tests/test-sinf.c: New file.
77404         New module 'sinf'.
77405         * lib/math.in.h (sinf): New declaration.
77406         * lib/sinf.c: New file.
77407         * m4/sinf.m4: New file.
77408         * m4/math_h.m4 (gl_MATH_H): Test whether sinf is declared.
77409         (gl_MATH_H_DEFAULTS): Initialize GNULIB_SINF, HAVE_SINF.
77410         * modules/math (Makefile.am): Substitute GNULIB_SINF, HAVE_SINF.
77411         * modules/sinf: New file.
77412         * tests/test-math-c++.cc: Check the declaration of sinf.
77413         * doc/posix-functions/sinf.texi: Mention the new module.
77415         sin: Use a .m4 file.
77416         * m4/sin.m4: New file.
77417         * modules/sin (Files): Add it.
77418         (configure.ac): Just invoke gl_FUNC_SIN.
77420 2011-10-08  Bruno Haible  <bruno@clisp.org>
77422         Tests for module 'powf'.
77423         * modules/powf-tests: New file.
77424         * tests/test-powf.c: New file.
77426         New module 'powf'.
77427         * lib/math.in.h (powf): New declaration.
77428         * lib/powf.c: New file.
77429         * m4/powf.m4: New file.
77430         * m4/math_h.m4 (gl_MATH_H): Test whether powf is declared.
77431         (gl_MATH_H_DEFAULTS): Initialize GNULIB_POWF, HAVE_POWF.
77432         * modules/math (Makefile.am): Substitute GNULIB_POWF, HAVE_POWF.
77433         * modules/powf: New file.
77434         * tests/test-math-c++.cc: Check the declaration of powf.
77435         * doc/posix-functions/powf.texi: Mention the new module.
77437         pow: Use a .m4 file.
77438         * m4/pow.m4: New file.
77439         * modules/pow (Files): Add it.
77440         (configure.ac): Just invoke gl_FUNC_POW.
77442 2011-10-08  Bruno Haible  <bruno@clisp.org>
77444         Tests for module 'log10f'.
77445         * modules/log10f-tests: New file.
77446         * tests/test-log10f.c: New file.
77448         New module 'log10f'.
77449         * lib/math.in.h (log10f): New declaration.
77450         * lib/log10f.c: New file.
77451         * m4/log10f.m4: New file.
77452         * m4/math_h.m4 (gl_MATH_H): Test whether log10f is declared.
77453         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG10F, HAVE_LOG10F.
77454         * modules/math (Makefile.am): Substitute GNULIB_LOG10F, HAVE_LOG10F.
77455         * modules/log10f: New file.
77456         * tests/test-math-c++.cc: Check the declaration of log10f.
77457         * doc/posix-functions/log10f.texi: Mention the new module.
77459         log10: Use a .m4 file.
77460         * m4/log10.m4: New file.
77461         * modules/log10 (Files): Add it.
77462         (configure.ac): Just invoke gl_FUNC_LOG10.
77464 2011-10-08  Bruno Haible  <bruno@clisp.org>
77466         Tests for module 'logf'.
77467         * modules/logf-tests: New file.
77468         * tests/test-logf.c: New file.
77470         New module 'logf'.
77471         * lib/math.in.h (logf): New declaration.
77472         * lib/logf.c: New file.
77473         * m4/logf.m4: New file.
77474         * m4/math_h.m4 (gl_MATH_H): Test whether logf is declared.
77475         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGF, HAVE_LOGF.
77476         * modules/math (Makefile.am): Substitute GNULIB_LOGF, HAVE_LOGF.
77477         * modules/logf: New file.
77478         * tests/test-math-c++.cc: Check the declaration of logf.
77479         * doc/posix-functions/logf.texi: Mention the new module.
77481         log: Use a .m4 file.
77482         * m4/log.m4: New file.
77483         * modules/log (Files): Add it.
77484         (configure.ac): Just invoke gl_FUNC_LOG.
77486 2011-10-08  Bruno Haible  <bruno@clisp.org>
77488         Tests for module 'expf'.
77489         * modules/expf-tests: New file.
77490         * tests/test-expf.c: New file.
77492         New module 'expf'.
77493         * lib/math.in.h (expf): New declaration.
77494         * lib/expf.c: New file.
77495         * m4/expf.m4: New file.
77496         * m4/math_h.m4 (gl_MATH_H): Test whether expf is declared.
77497         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPF, HAVE_EXPF.
77498         * modules/math (Makefile.am): Substitute GNULIB_EXPF, HAVE_EXPF.
77499         * modules/expf: New file.
77500         * tests/test-math-c++.cc: Check the declaration of expf.
77501         * doc/posix-functions/expf.texi: Mention the new module.
77503         exp: Use a .m4 file.
77504         * m4/exp.m4: New file.
77505         * modules/exp (Files): Add it.
77506         (configure.ac): Just invoke gl_FUNC_EXP.
77508 2011-10-08  Bruno Haible  <bruno@clisp.org>
77510         Tests for module 'sqrtf'.
77511         * modules/sqrtf-tests: New file.
77512         * tests/test-sqrtf.c: New file.
77514         New module 'sqrtf'.
77515         * lib/math.in.h (sqrtf): New declaration.
77516         * lib/sqrtf.c: New file.
77517         * m4/sqrtf.m4: New file.
77518         * m4/math_h.m4 (gl_MATH_H): Test whether sqrtf is declared.
77519         (gl_MATH_H_DEFAULTS): Initialize GNULIB_SQRTF, HAVE_SQRTF.
77520         * modules/math (Makefile.am): Substitute GNULIB_SQRTF, HAVE_SQRTF.
77521         * modules/sqrtf: New file.
77522         * tests/test-math-c++.cc: Check the declaration of sqrtf.
77523         * doc/posix-functions/sqrtf.texi: Mention the new module.
77525 2011-10-08  Bruno Haible  <bruno@clisp.org>
77527         Tests: Avoid link failures w.r.t. libintl.
77528         * modules/faccessat-tests (Makefile.am): Link test-faccessat against
77529         $(LIBINTL).
77530         * modules/fchdir-tests (Makefile.am): Link test-fchdir against
77531         $(LIBINTL).
77532         * modules/getcwd-lgpl-tests (Makefile.am): Link test-getcwd-lgpl
77533         against $(LIBINTL).
77534         * modules/getcwd-tests (Makefile.am): Link test-getcwd against
77535         $(LIBINTL).
77536         * modules/openat-tests (Makefile.am): Link test-fchmodat against
77537         $(LIBINTL).
77538         * modules/stat-tests (Makefile.am): Link test-stat against $(LIBINTL).
77540 2011-10-08  Bruno Haible  <bruno@clisp.org>
77542         pow tests: Defeat compiler optimizations.
77543         * tests/test-pow.c (main): Assign arguments to x and y before use.
77545 2011-10-08  Bruno Haible  <bruno@clisp.org>
77547         gnulib-tool: Improve last commit.
77548         * gnulib-tool (func_modules_transitive_closure): Simplify code.
77549         (func_emit_autoconf_snippets): Instead of invoking func_acceptable,
77550         ignore dependencies that are not among the modules list.
77552 2011-10-07  Paul Eggert  <eggert@cs.ucla.edu>
77554         gnulib-tool: don't follow dependencies to avoided modules
77555         This fixes a bug that is related to the previous one.
77556         * gnulib-tool (func_modules_transitive_closure)
77557         (func_emit_autoconf_snippets):
77558         Check whether a dependency is acceptable before using it.
77559         (--extract-dependencies): Report an error if --avoid is also used,
77560         since this combination of options is not yet supported.
77562         gnulib-tool: fix typo that broke Emacs on powerpc-apple-darwin9.8.0.
77563         Problem reported by Peter Dyballa in
77564         <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9696>.
77565         * gnulib-tool (func_emit_autoconf_snippets): Quote with "", not '',
77566         when echoing "$condition".
77568 2011-10-07  Bruno Haible  <bruno@clisp.org>
77570         Fix documentation about math functions on MacOS X.
77571         * doc/posix-functions/exp2.texi: Don't say the function is missing on
77572         MacOS X 10.5.
77573         * doc/posix-functions/fdim.texi: Likewise.
77574         * doc/posix-functions/feclearexcept.texi: Likewise.
77575         * doc/posix-functions/fegetenv.texi: Likewise.
77576         * doc/posix-functions/fegetround.texi: Likewise.
77577         * doc/posix-functions/feholdexcept.texi: Likewise.
77578         * doc/posix-functions/feraiseexcept.texi: Likewise.
77579         * doc/posix-functions/fesetenv.texi: Likewise.
77580         * doc/posix-functions/fesetround.texi: Likewise.
77581         * doc/posix-functions/fetestexcept.texi: Likewise.
77582         * doc/posix-functions/feupdateenv.texi: Likewise.
77583         * doc/posix-functions/fmax.texi: Likewise.
77584         * doc/posix-functions/fmin.texi: Likewise.
77585         * doc/posix-functions/log2.texi: Likewise.
77586         * doc/posix-functions/modff.texi: Likewise.
77587         * doc/posix-functions/nan.texi: Likewise.
77588         * doc/posix-functions/nanf.texi: Likewise.
77589         * doc/posix-functions/nextafterf.texi: Likewise.
77590         * doc/posix-functions/remquo.texi: Likewise.
77592 2011-10-07  Bruno Haible  <bruno@clisp.org>
77594         modff: Drop assumption about library that defines modff.
77595         * m4/modff.m4 (gl_FUNC_MODFF): Use gl_MATHFUNC macro instead of
77596         AC_CHECK_FUNCS.
77597         * modules/modff (Files): Add m4/mathfunc.m4.
77599 2011-10-07  Bernhard Voelker  <mail@bernhard-voelker.de>
77601         raise tests: Avoid a GCC warning.
77602         * tests/test-raise.c (handler): Use _Noreturn.
77604 2011-10-07  Bruno Haible  <bruno@clisp.org>
77606         Tests for module 'ldexpf'.
77607         * modules/ldexpf-tests: New file.
77608         * tests/test-ldexpf.c: New file.
77610         New module 'ldexpf'.
77611         * lib/math.in.h (ldexpf): New declaration.
77612         * lib/ldexpf.c: New file.
77613         * m4/ldexpf.m4: New file.
77614         * m4/math_h.m4 (gl_MATH_H): Test whether ldexpf is declared.
77615         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LDEXPF, HAVE_LDEXPF.
77616         * modules/math (Makefile.am): Substitute GNULIB_LDEXPF, HAVE_LDEXPF.
77617         * modules/ldexpf: New file.
77618         * tests/test-math-c++.cc: Check the declaration of ldexpf.
77619         * doc/posix-functions/ldexpf.texi: Mention the new module.
77621 2011-10-06  Bruno Haible  <bruno@clisp.org>
77623         frexpf: Work around problems on IRIX and mingw.
77624         * lib/math.in.h (frexpf): Consider also REPLACE_FREXPF.
77625         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPF.
77626         * m4/frexpf.m4 (gl_FUNC_FREXPF_WORKS): New macro.
77627         (gl_FUNC_FREXPF): Invoke it. Set REPLACE_FREXPF.
77628         * modules/frexpf (Depends-on, configure.ac): Consider REPLACE_FREXPF.
77629         * modules/math (Makefile.am): Substitute REPLACE_FREXPF.
77630         * doc/posix-functions/frexpf.texi: Mention the IRIX and mingw problems.
77632 2011-10-06  Bruno Haible  <bruno@clisp.org>
77634         fabsf: Drop assumption about library that defines fabsf.
77635         * m4/fabsf.m4 (gl_FUNC_FABSF): Use gl_MATHFUNC macro instead of
77636         AC_CHECK_FUNCS.
77637         * modules/fabsf (Files): Add m4/mathfunc.m4.
77639 2011-10-06  Bruno Haible  <bruno@clisp.org>
77641         frexpf: Drop assumption about library that defines frexpf.
77642         * m4/mathfunc.m4 (gl_MATHFUNC): Support also the argument types
77643         'int *', 'float *', 'long double *', 'float', 'long double'.
77644         * m4/frexpf.m4 (gl_FUNC_FREXPF): Use gl_MATHFUNC macro instead of
77645         AC_CHECK_FUNCS.
77646         * modules/frexpf (Files): Add m4/mathfunc.m4.
77648         Tests for module 'frexpf'.
77649         * modules/frexpf-tests: New file.
77650         * tests/test-frexpf.c: New file.
77652         New module 'frexpf'.
77653         * lib/math.in.h (frexpf): New declaration.
77654         * lib/frexpf.c: New file.
77655         * m4/frexpf.m4: New file.
77656         * m4/math_h.m4 (gl_MATH_H): Test whether frexpf is declared.
77657         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPF, HAVE_FREXPF.
77658         * modules/math (Makefile.am): Substitute GNULIB_FREXPF, HAVE_FREXPF.
77659         * modules/frexpf: New file.
77660         * tests/test-math-c++.cc: Check the declaration of frexpf.
77661         * doc/posix-functions/frexpf.texi: Mention the new module.
77663 2011-10-06  Bruno Haible  <bruno@clisp.org>
77665         math: Sort function declarations of math.in.h.
77666         * lib/math.in.h (frexp, logb): Move declarations.
77668 2011-10-05  Bruno Haible  <bruno@clisp.org>
77670         Tests for module 'modff'.
77671         * modules/modff-tests: New file.
77672         * tests/test-modff.c: New file.
77674         New module 'modff'.
77675         * lib/math.in.h (modff): New declaration.
77676         * lib/modff.c: New file.
77677         * m4/modff.m4: New file.
77678         * m4/math_h.m4 (gl_MATH_H): Test whether modff is declared.
77679         (gl_MATH_H_DEFAULTS): Initialize GNULIB_MODFF, HAVE_MODFF.
77680         * modules/math (Makefile.am): Substitute GNULIB_MODFF, HAVE_MODFF.
77681         * modules/modff: New file.
77682         * tests/test-math-c++.cc: Check the declaration of modff.
77683         * doc/posix-functions/modff.texi: Mention the new module.
77685         modf tests: Make test sharper.
77686         * tests/test-modf.c (main): Strengthen upper bound.
77688         modf: Use a .m4 file.
77689         * m4/modf.m4: New file.
77690         * modules/modf (Files): Add it.
77691         (configure.ac): Just invoke gl_FUNC_MODF.
77693 2011-10-05  Bruno Haible  <bruno@clisp.org>
77695         Tests for module 'fmodf'.
77696         * modules/fmodf-tests: New file.
77697         * tests/test-fmodf.c: New file.
77699         New module 'fmodf'.
77700         * lib/math.in.h (fmodf): New declaration.
77701         * lib/fmodf.c: New file.
77702         * m4/fmodf.m4: New file.
77703         * m4/math_h.m4 (gl_MATH_H): Test whether fmodf is declared.
77704         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMODF, HAVE_FMODF.
77705         * modules/math (Makefile.am): Substitute GNULIB_FMODF, HAVE_FMODF.
77706         * modules/fmodf: New file.
77707         * tests/test-math-c++.cc: Check the declaration of fmodf.
77708         * doc/posix-functions/fmodf.texi: Mention the new module.
77710         fmod: Use a .m4 file.
77711         * m4/fmod.m4: New file.
77712         * modules/fmod (Files): Add it.
77713         (configure.ac): Just invoke gl_FUNC_FMOD.
77715 2011-10-05  Bruno Haible  <bruno@clisp.org>
77717         Tests for module 'fabsf'.
77718         * modules/fabsf-tests: New file.
77719         * tests/test-fabsf.c: New file.
77721         New module 'fabsf'.
77722         * lib/math.in.h (fabsf): New declaration.
77723         * lib/fabsf.c: New file.
77724         * m4/fabsf.m4: New file.
77725         * m4/math_h.m4 (gl_MATH_H): Test whether fabsf is declared.
77726         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FABSF, HAVE_FABSF.
77727         * modules/math (Makefile.am): Substitute GNULIB_FABSF, HAVE_FABSF.
77728         * modules/fabsf: New file.
77729         * tests/test-math-c++.cc: Check the declaration of fabsf.
77730         * doc/posix-functions/fabsf.texi: Mention the new module.
77732         fabs: Use a .m4 file.
77733         * m4/fabs.m4: New file.
77734         * modules/fabs (Files): Add it.
77735         (configure.ac): Just invoke gl_FUNC_FABS.
77737 2011-10-05  Jim Meyering  <meyering@redhat.com>
77739         file-has-acl: revert both recent changes, 80af92af and 95f7c57f
77740         * lib/file-has-acl.c: While the 2011-10-03 change does fix the
77741         ls -lL regression introduced in coreutils-8.12, it does so at the
77742         cost of an additional stat call in the common case.  Besides, now
77743         that the kernel change that prompted commit 95f7c57f has been reverted
77744         (see https://bugzilla.redhat.com/show_bug.cgi?id=720325#c24)
77745         we have no use for commit 95f7c57f, "file-has-acl: use
77746         acl_extended_file_nofollow if available".
77748 2011-10-03  Kamil Dudka  <kdudka@redhat.com>
77750         file-has-acl: revert unintended change in behavior of ls -L
77751         * lib/file-has-acl.c (acl_extended_file_wrap): New function,
77752         derived from...
77753         (file_has_acl): ...code here.  Call it.
77754         This problem was introduced with 2011-07-22 commit 95f7c57f,
77755         "file-has-acl: use acl_extended_file_nofollow if available".
77756         See http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28538
77758 2011-10-03  Bruno Haible  <bruno@clisp.org>
77760         poll: Avoid link errors on MSVC.
77761         * m4/poll.m4 (gl_FUNC_POLL): Determine LIB_POLL.
77762         * modules/poll (Depends-on): Add sockets.
77763         (Link): New section.
77764         * NEWS: Mention the change.
77765         * modules/poll-tests (Makefile.am): Link test-poll against $(LIB_POLL).
77766         * modules/poll-h-c++-tests (Makefile.am): Link test-poll-h-c++ against
77767         $(LIB_POLL) instead of $(LIBSOCKET).
77769 2011-10-03  Bruno Haible  <bruno@clisp.org>
77771         sys_select tests: Fix link error on MSVC 9.
77772         * modules/sys_select-c++-tests (Makefile.am): Link test-sys_select-c++
77773         with $(LIB_SELECT) instead of $(LIBSOCKET).
77775 2011-10-03  Bruno Haible  <bruno@clisp.org>
77777         sys_select: Fix compilation error on mingw.
77778         * lib/sys_select.in.h: On native Windows, include <io.h>.
77780 2011-10-03  Bruno Haible  <bruno@clisp.org>
77782         wmemset: Support for MSVC.
77783         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Use a small test program to test
77784         whether wmemset() exists.
77786 2011-10-03  Bruno Haible  <bruno@clisp.org>
77788         wmemmove: Support for MSVC.
77789         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Use a small test program to test
77790         whether wmemmove() exists.
77792 2011-10-03  Bruno Haible  <bruno@clisp.org>
77794         wmemcpy: Support for MSVC.
77795         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Use a small test program to test
77796         whether wmemcpy() exists.
77798 2011-10-03  Bruno Haible  <bruno@clisp.org>
77800         wmemcmp: Support for MSVC.
77801         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Use a small test program to test
77802         whether wmemcmp() exists.
77804 2011-10-03  Bruno Haible  <bruno@clisp.org>
77806         wmemchr: Support for MSVC.
77807         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Use a small test program to test
77808         whether wmemchr() exists.
77810 2011-10-03  Bruno Haible  <bruno@clisp.org>
77812         glthread/*, strsignal: Support for MSVC.
77813         * lib/glthread/cond.h: Define WIN32_LEAN_AND_MEAN, so as to avoid
77814         including <winsock.h> on MSVC 9.
77815         * lib/glthread/lock.h: Likewise.
77816         * lib/glthread/thread.h: Likewise.
77817         * lib/glthread/tls.h: Likewise.
77818         * lib/glthread/yield.h: Likewise.
77819         * lib/strsignal.c: Include <string.h> first. Don't include <unistd.h>
77820         if HAVE_UNISTD_H is false.
77821         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Test for <unistd.h>.
77823 2011-10-03  Bruno Haible  <bruno@clisp.org>
77825         nonblocking tests: Fix test failure on OpenBSD/SPARC64.
77826         * tests/test-nonblocking-socket.h (SOCKET_DATA_BLOCK_SIZE) [OpenBSD]:
77827         Set to 100000.
77829 2011-10-03  Bruno Haible  <bruno@clisp.org>
77831         acl: Fix specification.
77832         * lib/file-has-acl.c (file_has_acl): Fix specification.
77834 2011-10-03  Bruno Haible  <bruno@clisp.org>
77836         relocatable-lib[-lgpl]: Avoid expensive /proc access on Linux, Cygwin.
77837         * lib/relocatable.c (ENABLE_COSTLY_RELOCATABLE): New macro.
77838         (compute_curr_prefix, shared_library_fullname,
77839         find_shared_library_fullname, get_shared_library_fullname, relocate):
77840         Use it together with PIC && INSTALLDIR.
77841         Reported by <jojelino@gmail.com>
77842         via Charles Wilson <cygwin@cwilson.fastmail.fm>.
77844 2011-10-01  Jim Meyering  <meyering@redhat.com>
77846         maint.mk: adjust a release-related rule not to require use of gzip
77847         * top/maint.mk (writable-files): Don't hard-code use of .tar.gz.
77848         Instead, check each file in $(DIST_ARCHIVES).  This is better for
77849         projects that build only .tar.xz files.  Also fix an erroneous test.
77851         test-linkat: don't leave behind a temporary file
77852         * tests/test-linkat.c (main): Don't forget to remove a temporary file.
77853         Otherwise, coreutils' "make distcheck" would fail with this:
77854           Only in /c/cu/tests/torture/coreutils/test/\
77855             coreutils-8.13.22-d5caf.old/gnulib-tests: test-linkat.too
77856           make[2]: *** [my-distcheck] Error 1
77858         float, math: add omitted file
77859         * lib/itold.c: Add file, required for yesterday's float change.
77861 2011-10-01  Bruno Haible  <bruno@clisp.org>
77863         isinf: Fix for OpenBSD/x86.
77864         * m4/isinf.m4 (gl_ISINFL_WORKS): Also test the behaviour of isinf on
77865         pseudo-NaNs, pseudo-Infinities, and other non-IEEE values.
77866         * doc/posix-functions/isinf.texi: Mention the problem on OpenBSD/x86.
77868 2011-10-01  Bruno Haible  <bruno@clisp.org>
77870         isfinite: Fix syntax error in configure test.
77871         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Fix syntax error.
77873         isfinite: Fix typo.
77874         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): When cross-compiling, set
77875         gl_cv_func_isfinitel_works, not gl_cv_func_isnanl_works.
77877 2011-10-01  Bruno Haible  <bruno@clisp.org>
77879         nonblocking tests: Fix test failure on Linux/IA-64.
77880         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/IA-64]:
77881         Set to 270000.
77883 2011-10-01  Bruno Haible  <bruno@clisp.org>
77885         mkfifoat tests: Fix a test failure on mingw.
77886         * tests/test-mkfifoat.c (main): Allow mkfifoat or test_mknodat to fail
77887         with error ENOSYS.
77889 2011-09-30  Bruno Haible  <bruno@clisp.org>
77891         float, math: Fix 'int' to 'long double' conversion on Linux/SPARC64.
77892         * m4/float_h.m4 (gl_FLOAT_H): Test conversion from 'int' to
77893         'long double'. Set REPLACE_ITOLD.
77894         * lib/float.in.h (_Qp_itoq, _gl_float_fix_itold): New declarations.
77895         * lib/math.in.h (_Qp_itoq, _gl_math_fix_itold): New declarations.
77896         * lib/itold.c: New file.
77897         * modules/float (Files): Add lib/itold.c.
77898         (configure.ac): When REPLACE_ITOLD is 1, arrange to compile itold.c.
77899         (Makefile.am): Substitute REPLACE_ITOLD.
77900         * modules/math (Depends-on): Add float.
77901         (Makefile.am): Substitute REPLACE_ITOLD.
77902         * doc/posix-headers/float.texi: Mention problem on Linux/SPARC64.
77903         * doc/posix-headers/math.texi: Likewise.
77904         * doc/posix-functions/logl.texi: Likewise.
77906 2011-09-30  Bruno Haible  <bruno@clisp.org>
77908         nonblocking tests: Fix test failure on Linux/SPARC (32-bit and 64-bit).
77909         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/SPARC]:
77910         Set to 140000.
77912 2011-09-30  Bruno Haible  <bruno@clisp.org>
77914         gnulib-tool: Improve suggestion where to put gl_EARLY invocation.
77915         * gnulib-tool (func_import): If the configure.ac has an AC_PROG_CC_STDC
77916         invocation, say "right after AC_PROG_CC_STDC", not "right after
77917         AC_PROG_CC".
77918         Reported by Gary V. Vaughan <gary@gnu.org>.
77920 2011-09-30  Bruno Haible  <bruno@clisp.org>
77922         Centralize C99 requirement.
77923         * m4/gnulib-common.m4 (gl_PROG_CC_C99): New macro.
77924         * modules/stdarg (configure.ac-early): Invoke it instead of
77925         AC_PROG_CC_STDC.
77926         Reported by Gary V. Vaughan and Paul Eggert.
77928 2011-09-29  Bruno Haible  <bruno@clisp.org>
77930         float: Fix LDBL_MAX value on Linux/PowerPC.
77931         * m4/float_h.m4 (gl_FLOAT_H): Set FLOAT_H and REPLACE_FLOAT_LDBL also
77932         on Linux/PowerPC.
77933         * lib/float.in.h (LDBL_MAX): Redefine also on Linux/PowerPC.
77934         * lib/float.c (gl_LDBL_MAX): Also define on Linux/PowerPC.
77935         * doc/posix-headers/float.texi: Mention Linux/PowerPC as an affected
77936         platform.
77937         Reported by Andreas Metzler <ametzler@downhill.at.eu.org>.
77939 2011-09-29  Bruno Haible  <bruno@clisp.org>
77941         doc: Improve doc about gl_EARLY.
77942         * doc/gnulib-tool.texi (Initial import): Mention where to place an
77943         AC_PROG_CC_STDC invocation.
77944         Reported by Gary V. Vaughan <gary@gnu.org>.
77946 2011-09-28  Bruno Haible  <bruno@clisp.org>
77948         fgetc, fputc, fread, fwrite tests: Fix link error.
77949         * tests/test-fgetc.c (main): Don't invoke gl_msvc_inval_ensure_handler
77950         on non-MSVC platforms.
77951         * tests/test-fputc.c (main): Likewise.
77952         * tests/test-fread.c (main): Likewise.
77953         * tests/test-fwrite.c (main): Likewise.
77954         Reported by Jim Meyering.
77956 2011-09-27  Bruno Haible  <bruno@clisp.org>
77958         fputc, fwrite tests: Avoid test failure on MSVC.
77959         * tests/test-fgetc.c: Include msvc-inval.h.
77960         (main): Invoke gl_msvc_inval_ensure_handler.
77961         * tests/test-fputc.c: Include msvc-inval.h.
77962         (main): Invoke gl_msvc_inval_ensure_handler.
77963         * tests/test-fread.c: Include msvc-inval.h.
77964         (main): Invoke gl_msvc_inval_ensure_handler.
77965         * tests/test-fwrite.c: Include msvc-inval.h.
77966         (main): Invoke gl_msvc_inval_ensure_handler.
77967         * modules/fgetc-tests (Depends-on): Add msvc-inval.
77968         * modules/fputc-tests (Depends-on): Likewise.
77969         * modules/fread-tests (Depends-on): Likewise.
77970         * modules/fwrite-tests (Depends-on): Likewise.
77972 2011-09-27  Bruno Haible  <bruno@clisp.org>
77974         raise: Fix double declaration with modules 'sigprocmask' and 'sigpipe'.
77975         * lib/signal.in.h (GNULIB_defined_signal_blocking): New macro.
77976         (raise): Remove older, duplicated declaration.
77977         (_gl_raise_SIGPIPE): New declaration.
77978         * lib/sigprocmask.c (_gl_raise_SIGPIPE): New function.
77979         (rpl_raise): Remove function.
77980         * lib/raise.c (rpl_raise, raise): Merge into a single function. Handle
77981         a gnulib-defined SIGPIPE here.
77982         * m4/raise.m4 (gl_FUNC_RAISE): Set REPLACE_RAISE also if the module
77983         'sigprocmask' has detected missing signal-blocking and the module
77984         'sigpipe' is enabled.
77985         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>.
77987 2011-09-26  Gijs van Tulder  <gvtulder@gmail.com>
77989         base64-tests: avoid memory leak
77990         * tests/test-base64.c (main): Plug memory leak.
77992         base32: new module
77993         * modules/base32: New module.
77994         * lib/base32.c: New file.
77995         * lib/base32.h: Likewise.
77996         * m4/base32.m4: Likewise.
77997         * modules/base32-tests: New test.
77998         * tests/test-base32.c: Likewise.
77999         * MODULES.html.sh (Misc): Mention it.
78001 2011-09-26  Paul Eggert  <eggert@cs.ucla.edu>
78003         gnulib: use more-standard license notice wording
78004         * gnulib-tool (func_emit_copyright_notice): When emitting a
78005         license notice into a file, use the standard wording as suggested
78006         by the current information for GNU maintainers, except say "file"
78007         rather than "program".  The new wording gives a license version
78008         number, which addresses an issue raised by Glenn Morris in
78009         <http://lists.gnu.org/r/bug-gnulib/2011-09/msg00397.html>.
78010         * m4/onceonly.m4: Use that same wording here, too.
78012         dup2: minor simplification
78013         * m4/dup2.m4 (gl_PREREQ_DUP2): Don't require AC_C_INLINE,
78014         as lib/dup2.c no longer uses 'inline'.
78016 2011-09-25  Bruno Haible  <bruno@clisp.org>
78018         strings: Fix compilation error on MSVC.
78019         * lib/strings.in.h: Include <stddef.h> for size_t.
78021 2011-09-25  Bruno Haible  <bruno@clisp.org>
78023         fflush et al.: Document limitation on MSVC.
78024         * doc/posix-functions/fflush.texi: Document possible crash in handling
78025         mode other than DEFAULT_HANDLING.
78026         * doc/posix-functions/fgetc.texi: Likewise.
78027         * doc/posix-functions/fputc.texi: Likewise.
78028         * doc/posix-functions/fread.texi: Likewise.
78029         * doc/posix-functions/fwrite.texi: Likewise.
78031 2011-09-25  Bruno Haible  <bruno@clisp.org>
78033         msvc-inval: Allow three invalid parameter handling modes.
78034         * lib/msvc-inval.h: Don't include <stdlib.h> here.
78035         (DEFAULT_HANDLING, HAIRY_LIBRARY_HANDLING, SANE_LIBRARY_HANDLING): New
78036         macros.
78037         (gl_msvc_inval_ensure_handler, TRY_MSVC_INVAL, CATCH_MSVC_INVAL,
78038         DONE_MSVC_INVAL): Implement DEFAULT_HANDLING. Treat
78039         SANE_LIBRARY_HANDLING as a no-op.
78040         * lib/msvc-inval.c: Treat SANE_LIBRARY_HANDLING as a no-op. Include
78041         <stdlib.h>.
78042         (gl_msvc_invalid_parameter_handler): Implement DEFAULT_HANDLING.
78044 2011-09-25  Bruno Haible  <bruno@clisp.org>
78046         msvc-inval: Make handler multithread-safe.
78047         * lib/msvc-inval.h (struct gl_msvc_inval_per_thread): New type.
78048         (gl_msvc_inval_restart, gl_msvc_inval_restart_valid): Remove
78049         declarations.
78050         (gl_msvc_inval_current): New declaration.
78051         (TRY_MSVC_INVAL, CATCH_MSVC_INVAL, DONE_MSVC_INVAL) [!_MSC_VER]:
78052         Operate on the structure returned by gl_msvc_inval_current().
78053         * lib/msvc-inval.c (gl_msvc_inval_restart, gl_msvc_inval_restart_valid):
78054         Remove varaiables.
78055         (tls_index, tls_initialized): New variables.
78056         (not_per_thread): New variable.
78057         (gl_msvc_inval_current): New function.
78058         (gl_msvc_invalid_parameter_handler) [!_MSC_VER]: Use the structure
78059         returned by gl_msvc_inval_current().
78061 2011-09-25  Bruno Haible  <bruno@clisp.org>
78063         msvc-inval: Install handler globally.
78064         * lib/msvc-inval.h (STATUS_GNULIB_INVALID_PARAMETER): Define also for
78065         !_MSC_VER.
78066         (gl_msvc_invalid_parameter_handler): Remove declaration.
78067         (gl_msvc_inval_restart_valid, gl_msvc_inval_ensure_handler): New
78068         declarations.
78069         (TRY_MSVC_INVAL, CATCH_MSVC_INVAL, DONE_MSVC_INVAL) [!_MSC_VER]:
78070         Install the handler globally, don't uninstall it.
78071         * lib/msvc-inval.c (gl_msvc_inval_restart_valid): New variable.
78072         (gl_msvc_invalid_parameter_handler): Make static. If the restart is not
78073         currently valid, call RaiseException instead.
78074         (gl_msvc_inval_initialized, gl_msvc_inval_ensure_handler): Define also
78075         for !_MSC_VER.
78077 2011-09-25  Bruno Haible  <bruno@clisp.org>
78079         strerror_r-posix: Fix for MSVC 9.
78080         * lib/strerror_r.c (local_snprintf): New function.
78081         (snprintf): Define to local_snprintf, not to _snprintf.
78083 2011-09-25  Bruno Haible  <bruno@clisp.org>
78085         ftruncate: Support for MSVC 9.
78086         * lib/ftruncate.c: Include errno.h, msvc-inval.h.
78087         (chsize_nothrow): New function.
78088         (chsize): Redefine as a macro.
78089         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): Require AC_C_INLINE.
78090         * modules/ftruncate (Depends-on): Add msvc-inval.
78092 2011-09-25  Bruno Haible  <bruno@clisp.org>
78094         New module 'fstat'.
78095         * lib/sys_stat.in.h (fstat): Declare only if GNULIB_FSTAT is set.
78096         * lib/fstat.c: New file, based on a piece of lib/fchdir.c.
78097         * lib/fchdir.c (rpl_fstat): Remove function.
78098         * m4/fstat.m4: New file.
78099         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_FSTAT.
78100         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Test whether fstat is
78101         declared.
78102         (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_FSTAT.
78103         * modules/sys_stat (Makefile.am): Substitute GNULIB_FSTAT.
78104         * modules/fstat: New file.
78105         * modules/sys_stat-tests (Depends-on): Remove fstat-tests.
78106         * tests/test-sys_stat-c++.cc (fstat): Check only if GNULIB_TEST_FSTAT
78107         is set.
78108         * doc/posix-functions/fstat.texi: Mention the new module and the
78109         problem on MSVC.
78110         * NEWS: Mention the change.
78111         * modules/acl (Depends-on): Add fstat.
78112         * modules/chdir-safer (Depends-on): Likewise.
78113         * modules/chown (Depends-on): Likewise.
78114         * modules/copy-file (Depends-on): Likewise.
78115         * modules/fchdir (Depends-on): Likewise.
78116         * modules/fdopendir (Depends-on): Likewise.
78117         * modules/fopen (Depends-on): Likewise.
78118         * modules/fts (Depends-on): Likewise.
78119         * modules/getcwd (Depends-on): Likewise.
78120         * modules/isapipe (Depends-on): Likewise.
78121         * modules/linkat (Depends-on): Likewise.
78122         * modules/lseek (Depends-on): Likewise.
78123         * modules/mkdir-p (Depends-on): Likewise.
78124         * modules/open (Depends-on): Likewise.
78125         * modules/openat (Depends-on): Likewise.
78126         * modules/read-file (Depends-on): Likewise.
78127         * modules/renameat (Depends-on): Likewise.
78128         * modules/utimens (Depends-on): Likewise.
78130 2011-09-25  Bruno Haible  <bruno@clisp.org>
78132         linkat: Fix compilation on MSVC 9.
78133         * lib/linkat.c: Don't include <stdint.h>.
78135 2011-09-25  Bruno Haible  <bruno@clisp.org>
78137         fclose: Support for MSVC 9.
78138         * lib/fclose.c: Include msvc-inval.h.
78139         (fclose_nothrow): New function.
78140         (rpl_fclose): Use it.
78141         * modules/fclose (Depends-on): Add msvc-inval.
78142         * doc/posix-functions/fclose.texi: Mention the problem on MSVC.
78144 2011-09-24  Paul Eggert  <eggert@cs.ucla.edu>
78146         dup2: minor simplifications
78147         * lib/dup2.c (ms_windows_dup2): Omit 'inline' as it's not clear
78148         that it's a performance win.
78149         (rpl_dup2): Change "if !((defined _WIN32 || defined __WIN32__) &&
78150         ! defined __CYGWIN__)" to "ifdef F_GETFL".
78152 2011-09-24  Jim Meyering  <meyering@redhat.com>
78154         test-futimens: avoid a warning from gcc -Wshadow
78155         * tests/test-futimens.h (test_futimens): Rename inner local, s/fd/fd0/
78156         to avoid a shadowing warning.
78158 2011-09-24  Bruno Haible  <bruno@clisp.org>
78160         fdopen: Support for MSVC 9.
78161         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Set REPLACE_FDOPEN also if
78162         HAVE_MSVC_INVALID_PARAMETER_HANDLER is 1.
78163         * lib/fdopen.c: Include msvc-inval.h.
78164         (fdopen_nothrow): New function.
78165         (rpl_fdopen): Use it.
78166         * modules/fdopen (Depends-on): Add msvc-inval.
78167         * modules/fclose-tests (Depends-on): Add fdopen.
78168         * modules/fflush-tests (Depends-on): Likewise.
78169         * modules/fgetc-tests (Depends-on): Likewise.
78170         * modules/fputc-tests (Depends-on): Likewise.
78171         * modules/fread-tests (Depends-on): Likewise.
78172         * modules/freopen-tests (Depends-on): Likewise.
78173         * modules/fseeko-tests (Depends-on): Likewise.
78174         * modules/ftello-tests (Depends-on): Likewise.
78175         * modules/fwrite-tests  (Depends-on): Likewise.
78176         * doc/posix-functions/fdopen.texi: Mention the problem on MSVC.
78178 2011-09-24  Bruno Haible  <bruno@clisp.org>
78180         fgetc, fputc, fread, fwrite tests: Avoid compilation error on MSVC.
78181         * modules/fgetc-tests (Depends-on): Add unistd.
78182         * modules/fputc-tests (Depends-on): Likewise.
78183         * modules/fread-tests (Depends-on): Likewise.
78184         * modules/fwrite-tests (Depends-on): Likewise.
78186 2011-09-24  Bruno Haible  <bruno@clisp.org>
78188         dup: Simplify autoconf test.
78189         * m4/dup.m4 (gl_FUNC_DUP): Don't run a test program. Instead, just rely
78190         on gl_MSVC_INVAL's result.
78192 2011-09-24  Bruno Haible  <bruno@clisp.org>
78194         Tests for function fwrite().
78195         * modules/fwrite-tests: New file.
78196         * tests/test-fwrite.c: New file.
78197         * modules/stdio-tests (Depends-on): Add fwrite-tests.
78199         Tests for function fread().
78200         * modules/fread-tests: New file.
78201         * tests/test-fread.c: New file.
78202         * modules/stdio-tests (Depends-on): Add fread-tests.
78204         Activate fputc tests.
78205         * modules/stdio-tests (Depends-on): Add fputc-tests.
78207         Enhance fgetc, fputc tests.
78208         * tests/test-fgetc.c (main): Also test the stream's error indicator.
78209         * tests/test-fputc.c (main): Likewise.
78211 2011-09-24  Bruno Haible  <bruno@clisp.org>
78213         write: Support for MSVC 9.
78214         * lib/unistd.in.h (write): Replace also when GNULIB_UNISTD_H_NONBLOCKING
78215         is not 1.
78216         * lib/write.c (write_nothrow): New function.
78217         (rpl_write): Define also when GNULIB_NONBLOCKING or GNULIB_SIGPIPE is
78218         not 1. Use write_nothrow.
78219         * m4/write.m4 (gl_FUNC_WRITE): Replace read if the platform has an
78220         invalid parameter handler.
78221         (gl_PREREQ_WRITE): New macro.
78222         * modules/write (Depends-on): Add msvc-inval.
78223         (configure.ac): Invoke gl_PREREQ_WRITE.
78224         * doc/posix-functions/write.texi: Mention the problem on MSVC.
78226 2011-09-24  Bruno Haible  <bruno@clisp.org>
78228         read: Fix last commit.
78229         * lib/read.c (read_nothrow): Change return type to 'ssize_t'.
78231 2011-09-24  Bruno Haible  <bruno@clisp.org>
78233         dup2: Fix last commit.
78234         * lib/dup2.c: Restore comments. Treat Cygwin like Unix.
78235         (rpl_dup2): Disable fcntl workaround on native Windows.
78237         sigprocmask: Make code safer.
78238         * lib/sigprocmask.c: Move '#include "msvc-inval.h"' before the code
78239         section that changes macro definitions for this compilation unit.
78241 2011-09-23  Paul Eggert  <eggert@cs.ucla.edu>
78243         dup2: clarify by coalescing Windows-specific material
78244         * lib/dup2.c: Move '#include "msvc-inval.h"' and '#include
78245         "msvc-nothrow.h"' to the Windows-specific section, so that the
78246         Emacs source need not contain these include files.
78247         (ms_windows_dup2): Rename from dup2_nothrow, and move all the
78248         Windows-specific fixes into this function rather than just the
78249         nothrow fix, as this shortens and clarifies the code.  Always
78250         define as a function, as that's a bit cleaner than having it be
78251         sometimes a function and sometimes a macro.
78252         (rpl_dup2): Move the Windows-specific stuff out of here and into
78253         ms_windows_dup2.  Don't protect the Haiku-related fix with
78254         "#if !defined __linux__", as the same code also works around
78255         a Linux kernel bug, and it doesn't add any system calls on any
78256         platform.  Add comment about FreeBSD 6.1.
78258         sigprocmask: move #include directive
78259         * lib/sigprocmask.c: Move '#include "msvc-inval.h"' to the
78260         Windows-specific section, so that the Emacs source need not
78261         contain msvc-inval.h.
78263 2011-09-23  Bruno Haible  <bruno@clisp.org>
78265         read: Support for MSVC 9.
78266         * lib/unistd.in.h (read): Replace also when GNULIB_UNISTD_H_NONBLOCKING
78267         is not 1.
78268         * lib/read.c (read_nothrow): New function.
78269         (rpl_read): Define also when GNULIB_NONBLOCKING is not 1. Use
78270         read_nothrow.
78271         * m4/read.m4 (gl_FUNC_READ): Replace read if the platform has an
78272         invalid parameter handler.
78273         (gl_PREREQ_READ): New macro.
78274         * modules/read (Depends-on): Add msvc-inval.
78275         (configure.ac): Invoke gl_PREREQ_READ.
78276         * doc/posix-functions/read.texi: Mention the problem on MSVC.
78278 2011-09-23  Bruno Haible  <bruno@clisp.org>
78280         close: Support for MSVC 9.
78281         * lib/close.c: Include <errno.h>, msvc-inval.h.
78282         (close_nothrow): New function.
78283         (rpl_close): Use it.
78284         * m4/close.m4 (gl_FUNC_CLOSE): Replace close if the platform has an
78285         invalid parameter handler.
78286         * modules/close (Depends-on): Add msvc-inval.
78287         * modules/dup2-tests (Depends-on): Add close.
78288         * modules/dup3-tests (Depends-on): Likewise.
78289         * modules/fcntl-tests (Depends-on): Likewise.
78290         * modules/spawn-pipe-tests (Depends-on): Likewise.
78291         * modules/unistd-safer-tests (Depends-on): Likewise.
78292         * doc/posix-functions/close.texi: Mention the problem on MSVC.
78294 2011-09-23  Bruno Haible  <bruno@clisp.org>
78296         New module 'dup'.
78297         * lib/unistd.in.h (dup): Declare only if the 'dup' module is in use.
78298         Allow replacement.
78299         * lib/dup.c: New file.
78300         * lib/fchdir.c (rpl_dup): Remove function.
78301         * m4/dup.m4: New file.
78302         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_DUP here.
78303         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether 'dup' is declared.
78304         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_DUP.
78305         * modules/unistd (Makefile.am): Substitute GNULIB_DUP.
78306         * modules/dup: New file.
78307         * tests/test-unistd-c++.cc: Check the signature of 'dup' only if the
78308         'dup' module is in use.
78309         * modules/fdopendir (Depends-on): Add dup.
78310         * modules/fdutimensat-tests (Depends-on): Likewise.
78311         * modules/fts (Depends-on): Likewise.
78312         * modules/futimens-tests (Depends-on): Likewise.
78313         * modules/posix_spawnp-tests (Depends-on): Likewise.
78314         * modules/unistd-safer-tests (Depends-on): Likewise.
78315         * modules/utimens-tests (Depends-on): Likewise.
78316         * doc/posix-functions/dup.texi: Mention the new module and the problem
78317         on MSVC.
78319 2011-09-23  Bruno Haible  <bruno@clisp.org>
78321         getdtablesize: Support for MSVC 9.
78322         * lib/getdtablesize.c: Include msvc-inval.h.
78323         (_setmaxstdio_nothrow): New function.
78324         (_setmaxstdio): Redefine it.
78325         * m4/getdtablesize.m4 (gl_PREREQ_GETDTABLESIZE): New macro.
78326         * modules/getdtablesize (Depends-on): Add msvc-inval.
78327         (configure.ac): Invoke gl_PREREQ_GETDTABLESIZE.
78329 2011-09-23  Bruno Haible  <bruno@clisp.org>
78331         signal-h: Rename from signal.
78332         * modules/signal-h: Renamed from modules/signal.
78333         * modules/pthread_sigmask (Depends-on): Update.
78334         * modules/raise (Depends-on): Likewise.
78335         * modules/sigaction (Depends-on): Likewise.
78336         * modules/sigpipe (Depends-on): Likewise.
78337         * modules/sigprocmask (Depends-on): Likewise.
78338         * modules/sys_select (Depends-on): Likewise.
78339         * modules/signal-h-tests: Renamed from modules/signal-tests.
78340         (Files, Depends-on, Makefile.am): Update.
78341         * tests/test-signal-h.c: Renamed from tests/test-signal.c.
78342         * modules/signal-h-c++-tests: Renamed from modules/signal-c++-tests.
78343         (Files, Makefile.am): Update.
78344         * tests/test-signal-h-c++.cc: Renamed from tests/test-signal-c++.cc.
78345         * tests/test-signal-h-c++2.cc: Renamed from tests/test-signal-c++2.cc.
78346         * modules/signal: New placeholder file.
78347         * MODULES.html.sh (Support for systems lacking POSIX:2008): Update.
78348         * doc/posix-headers/signal.texi: Update.
78349         * NEWS: Mention the change.
78351 2011-09-23  Bruno Haible  <bruno@clisp.org>
78353         sigprocmask: Avoid crashes through signal() on MSVC 9.
78354         * lib/sigprocmask.c: Include msvc-inval.h.
78355         (signal_nothrow): New function.
78356         (signal): Redefine it.
78357         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Require AC_C_INLINE.
78358         * modules/sigprocmask (Depends-on): Add msvc-inval.
78359         * doc/posix-functions/signal.texi: Mention the problem on MSVC.
78361 2011-09-23  Bruno Haible  <bruno@clisp.org>
78363         Tests for module 'raise'.
78364         * modules/raise-tests: New file.
78365         * tests/test-raise.c: New file.
78367         raise: Support for MSVC.
78368         * lib/signal.in.h (raise): New declaration.
78369         * lib/raise.c (raise_nothrow, rpl_raise): New alternate implementation
78370         for native Windows platforms.
78371         * m4/raise.m4: New file.
78372         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize GNULIB_RAISE,
78373         HAVE_RAISE, REPLACE_RAISE.
78374         * modules/signal (Makefile.am): Substitute GNULIB_RAISE, HAVE_RAISE,
78375         REPLACE_RAISE.
78376         * modules/raise (Status, Notice): Remove fields.
78377         (Files): Add m4/raise.m4.
78378         (Depends-on): Add signal, msvc-inval.
78379         (configure.ac): Use the common idioms.
78380         (Maintainer): Add me.
78381         * tests/test-signal-c++.cc: Check the signature of raise.
78382         * doc/posix-functions/raise.texi: Mention the problem on MSVC.
78384 2011-09-23  Bruno Haible  <bruno@clisp.org>
78386         pipe2: Fix compilation on pre-C99 compilers.
78387         * lib/pipe2.c (pipe2): Surround verify(...) declaration with braces.
78389 2011-09-23  Bruno Haible  <bruno@clisp.org>
78391         New module 'msvc-nothrow'. Makes _get_osfhandle safe on MSVC 9.
78392         * lib/msvc-nothrow.h: New file.
78393         * lib/msvc-nothrow.c: New file.
78394         * m4/msvc-nothrow.m4: New file.
78395         * modules/msvc-nothrow: New file.
78396         * lib/dup2.c: Include msvc-nothrow.h.
78397         (rpl_dup2): No need to protect _get_osfhandle call here.
78398         * lib/accept4.c: Include msvc-nothrow.h.
78399         * lib/error.c: Likewise.
78400         * lib/fcntl.c: Likewise.
78401         * lib/lseek.c: Likewise.
78402         * lib/nonblocking.c: Likewise.
78403         * lib/poll.c: Likewise.
78404         * lib/read.c: Likewise.
78405         * lib/select.c: Likewise.
78406         * lib/sockets.h: Likewise.
78407         * lib/sockets.c: Likewise.
78408         * lib/stdio-read.c: Likewise.
78409         * lib/stdio-write.c: Likewise.
78410         * lib/write.c: Likewise.
78411         * lib/w32sock.h: Likewise.
78412         * lib/w32spawn.h: Likewise.
78413         * lib/flock.c: Include msvc-nothrow.h instead of <io.h>.
78414         * lib/fsync.c: Likewise.
78415         * lib/isapipe.c: Likewise.
78416         * modules/dup2 (Depends-on): Add msvc-nothrow.
78417         * modules/accept4 (Depends-on): Likewise.
78418         * modules/error (Depends-on): Likewise.
78419         * modules/fcntl (Depends-on): Likewise.
78420         * modules/lseek (Depends-on): Likewise.
78421         * modules/nonblocking (Depends-on): Likewise.
78422         * modules/poll (Depends-on): Likewise.
78423         * modules/read (Depends-on): Likewise.
78424         * modules/select (Depends-on): Likewise.
78425         * modules/sockets (Depends-on): Likewise.
78426         * modules/sigpipe (Depends-on): Likewise.
78427         * modules/write (Depends-on): Likewise.
78428         * modules/accept (Depends-on): Likewise.
78429         * modules/bind (Depends-on): Likewise.
78430         * modules/connect (Depends-on): Likewise.
78431         * modules/gethostname (Depends-on): Likewise.
78432         * modules/getpeername (Depends-on): Likewise.
78433         * modules/getsockname (Depends-on): Likewise.
78434         * modules/getsockopt (Depends-on): Likewise.
78435         * modules/ioctl (Depends-on): Likewise.
78436         * modules/listen (Depends-on): Likewise.
78437         * modules/recv (Depends-on): Likewise.
78438         * modules/recvfrom (Depends-on): Likewise.
78439         * modules/send (Depends-on): Likewise.
78440         * modules/sendto (Depends-on): Likewise.
78441         * modules/setsockopt (Depends-on): Likewise.
78442         * modules/shutdown (Depends-on): Likewise.
78443         * modules/socket (Depends-on): Likewise.
78444         * modules/execute (Depends-on): Likewise.
78445         * modules/spawn-pipe (Depends-on): Likewise.
78446         * modules/flock (Depends-on): Likewise.
78447         * modules/fsync (Depends-on): Likewise.
78448         * modules/isapipe (Depends-on): Likewise.
78449         * tests/test-cloexec.c: Include msvc-nothrow.h.
78450         * tests/test-dup-safer.c: Likewise.
78451         * tests/test-dup2.c: Likewise.
78452         * tests/test-dup3.c: Likewise.
78453         * tests/test-fcntl.c: Likewise.
78454         * tests/test-pipe.c: Likewise.
78455         * tests/test-pipe2.c: Likewise.
78456         * modules/cloexec-tests (Depends-on): Add msvc-nothrow.
78457         * modules/unistd-safer-tests (Depends-on): Likewise.
78458         * modules/dup2-tests (Depends-on): Likewise.
78459         * modules/dup3-tests (Depends-on): Likewise.
78460         * modules/fcntl-tests (Depends-on): Likewise.
78461         * modules/pipe-posix-tests (Depends-on): Likewise.
78462         * modules/pipe2-tests (Depends-on): Likewise.
78464 2011-09-23  Bruno Haible  <bruno@clisp.org>
78466         dup2: Make code more maintainable.
78467         * lib/dup2.c (dup2_nothrow): New function, extracted from rpl_dup2.
78468         (rpl_dup2): Use it.
78469         * m4/dup2.m4 (gl_PREREQ_DUP2): New macro.
78470         * modules/dup2 (configure.ac): Invoke it.
78471         Reported by Paul Eggert.
78473 2011-09-23  Bruno Haible  <bruno@clisp.org>
78475         msvc-inval: Fix compilation error.
78476         * lib/msvc-inval.h: Include <excpt.h>.
78478 2011-09-23  Bruno Haible  <bruno@clisp.org>
78480         mkdir: Tweak for MSVC 9.
78481         * lib/sys_stat.in.h: Update comments.
78482         * doc/posix-functions/mkdir.texi: Mention problem on MSVC 9.
78484         Tests for module 'chdir'.
78485         * modules/chdir-tests: New file.
78486         * tests/test-chdir.c: New file.
78488         New module 'chdir'.
78489         * modules/chdir: New file.
78490         * lib/unistd.in.h: Include <io.h>, <direct.h> also for chdir.
78491         (chdir): New declaration.
78492         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether chdir is declared.
78493         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_CHDIR.
78494         * modules/unistd (Makefile.am): Substitute GNULIB_CHDIR.
78495         * tests/test-unistd-c++.cc: Check signature of chdir.
78496         * doc/posix-functions/chdir.texi: Mention problem on native Windows.
78497         * modules/chdir-long (Depends-on): Add chdir.
78498         * modules/fchdir (Depends-on): Likewise.
78499         * modules/rename (Depends-on): Likewise.
78500         * modules/savewd (Depends-on): Likewise.
78502         rmdir: Support for mingw, MSVC 9.
78503         * lib/unistd.in.h: Include <io.h> and <direct.h> also for rmdir.
78504         * doc/posix-functions/getcwd.texi: Mention problem on native Windows.
78506         getcwd: Tweak for MSVC 9.
78507         * lib/unistd.in.h: Update comments.
78508         * doc/posix-functions/getcwd.texi: Mention problem on MSVC 9.
78510 2011-09-22  Bruno Haible  <bruno@clisp.org>
78512         strerror_r-posix: Avoid a link error on MSVC.
78513         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R): Check for snprintf.
78514         * lib/strerror_r.c (snprintf): Define to _snprintf if it doesn't exist.
78516 2011-09-22  Bruno Haible  <bruno@clisp.org>
78518         select: Avoid link errors on MSVC.
78519         * m4/select.m4 (gl_FUNC_SELECT): Determine LIB_SELECT.
78520         * modules/select (Link): Replace $(LIBSOCKET) with $(LIB_SELECT).
78521         * modules/pselect (Link): Likewise.
78522         * NEWS: Mention the change.
78523         * modules/select-tests (Makefile.am): Link test-select, test-select-fd,
78524         test-select-stdin against $(LIB_SELECT).
78525         * modules/pselect-tests (Makefile.am): Link test-pselect against
78526         $(LIB_SELECT).
78528 2011-09-22  Bruno Haible  <bruno@clisp.org>
78530         select: Avoid compilation error on MSVC.
78531         * lib/select.c: Don't include <stdbool.h>.
78533 2011-09-21  Bruno Haible  <bruno@clisp.org>
78535         Consolidate all uses of PATH_MAX in *.m4 files.
78536         * m4/pathmax.m4 (gl_PATHMAX_SNIPPET, gl_PATHMAX_SNIPPET_PREREQ): New
78537         macros.
78538         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Use gl_PATHMAX_SNIPPET_PREREQ
78539         and gl_PATHMAX_SNIPPET.
78540         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
78541         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
78542         * modules/chdir-long (Files): Add m4/pathmax.m4.
78543         * modules/getcwd (Files): Likewise.
78545 2011-09-21  Bruno Haible  <bruno@clisp.org>
78547         ftruncate: Un-deprecate, concentrate on Win32 support.
78548         * modules/ftruncate (Status, Notice): Remove sections.
78549         (Depends-on): Add largefile.
78550         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Drop failure message on
78551         non-mingw platforms.
78552         * lib/ftruncate.c: Remove code for the older platforms. For Win32,
78553         include <io.h>.
78554         * modules/perror-tests (Depends-on): Add ftruncate.
78555         * doc/posix-functions/ftruncate.texi: Mention the MSVC problem and the
78556         'ftruncate' module.
78558 2011-09-21  Bruno Haible  <bruno@clisp.org>
78560         Add dependencies to new dirent related modules.
78561         * modules/opendir (Depends-on): Add closedir.
78562         * modules/getcwd (Depends-on): Add opendir, closedir.
78563         * modules/dirent-safer-tests (Depends-on): Likewise.
78564         * modules/fdopendir-tests (Depends-on): Likewise.
78565         * modules/rename-tests (Depends-on): Add opendir, readdir, closedir.
78566         * modules/renameat-tests (Depends-on): Likewise.
78568 2011-09-21  Bruno Haible  <bruno@clisp.org>
78570         opendir: Avoid compilation error on mingw.
78571         * lib/opendir.c: Include <stddef.h> always. Include <unistd.h> as well.
78572         * modules/opendir (Depends-on): Add unistd.
78574 2011-09-21  Bruno Haible  <bruno@clisp.org>
78576         ftruncate tests: Avoid a test failure on mingw.
78577         * tests/test-ftruncate.c (main): Allow a failure with EACCES.
78579 2011-09-21  Bruno Haible  <bruno@clisp.org>
78581         select tests: Avoid test failures on OSF/1 5.1 and mingw.
78582         * tests/test-select.h (test_bad_fd): Disable all tests on OSF/1 and
78583         native Windows.
78585 2011-09-21  Bruno Haible  <bruno@clisp.org>
78587         New module 'fdopen'.
78588         * lib/stdio.in.h (fdopen): New declaration.
78589         * lib/fdopen.c: New file.
78590         * m4/fdopen.m4: New file.
78591         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FDOPEN,
78592         REPLACE_FDOPEN.
78593         * modules/stdio (Makefile.am): Substitute GNULIB_FDOPEN,
78594         REPLACE_FDOPEN.
78595         * modules/fdopen: New file.
78596         * modules/stdio-tests (Depends-on): Remove fdopen-tests.
78597         * tests/test-stdio-c++.cc: Check signature of fdopen.
78598         * doc/posix-functions/fdopen.texi: Mention the new module.
78600 2011-09-21  Bruno Haible  <bruno@clisp.org>
78602         unlockpt tests: Avoid test failure on NetBSD 5.1.
78603         * tests/test-unlockpt.c (main): Skip the EBADF tests on NetBSD.
78604         * doc/posix-functions/unlockpt.texi: Mention the bug on NetBSD.
78606 2011-09-21  Bruno Haible  <bruno@clisp.org>
78608         getlogin, getlogin_r tests: Avoid test failure on Linux/SPARC.
78609         * tests/test-getlogin.c (main): Allow a failure with EINVAL.
78610         * tests/test-getlogin_r.c (main): Likewise.
78612 2011-09-20  Bruno Haible  <bruno@clisp.org>
78614         time tests: Don't require pid_t.
78615         * doc/posix-headers/time.texi: Revert last change.
78616         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Revert last change.
78617         * tests/test-time.c: Comment out the check for pid_t.
78619 2011-09-20  Bruno Haible  <bruno@clisp.org>
78621         fsync tests: Avoid a test failure on mingw.
78622         * tests/test-fsync.c (main): Allow a failure with EIO.
78624 2011-09-20  Bruno Haible  <bruno@clisp.org>
78626         euidaccess: Update comments.
78627         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Update comments.
78629 2011-09-20  Bruno Haible  <bruno@clisp.org>
78631         Ensure EBADF returns for socket functions on mingw.
78632         * lib/accept.c (rpl_accept): Fail with error EBADF if the file
78633         descriptor is invalid.
78634         * lib/bind.c (rpl_bind): Likewise.
78635         * lib/connect.c (rpl_connect): Likewise.
78636         * lib/getpeername.c (rpl_getpeername): Likewise.
78637         * lib/getsockname.c (rpl_getsockname): Likewise.
78638         * lib/getsockopt.c (rpl_getsockopt): Likewise.
78639         * lib/listen.c (rpl_listen): Likewise.
78640         * lib/recv.c (rpl_recv): Likewise.
78641         * lib/recvfrom.c (rpl_recvfrom): Likewise.
78642         * lib/send.c (rpl_send): Likewise.
78643         * lib/sendto.c (rpl_sendto): Likewise.
78644         * lib/setsockopt.c (rpl_setsockopt): Likewise.
78645         * lib/shutdown.c (rpl_shutdown): Likewise.
78647 2011-09-20  Bruno Haible  <bruno@clisp.org>
78649         select tests: EBADF tests.
78650         * tests/test-select.h (do_select_bad_fd, do_select_bad_fd_nowait,
78651         test_bad_fd): New functions.
78652         (test_function): Invoke also test_bad_fd.
78654 2011-09-20  Bruno Haible  <bruno@clisp.org>
78656         Tests for module 'posix_spawn_file_actions_addopen.
78657         * modules/posix_spawn_file_actions_addopen-tests: New file.
78658         * tests/test-posix_spawn_file_actions_addopen.c: New file.
78660         Tests for module 'posix_spawn_file_actions_adddup2'.
78661         * modules/posix_spawn_file_actions_adddup2-tests: New file.
78662         * tests/test-posix_spawn_file_actions_adddup2.c: New file.
78664         Tests for module 'posix_spawn_file_actions_addclose'.
78665         * modules/posix_spawn_file_actions_addclose-tests: New file.
78666         * tests/test-posix_spawn_file_actions_addclose.c: New file.
78668 2011-09-20  Bruno Haible  <bruno@clisp.org>
78670         Tests for module 'unlockpt'.
78671         * modules/unlockpt-tests: New file.
78672         * tests/test-unlockpt.c: New file.
78673         * doc/posix-functions/unlockpt.texi: Mention the Cygwin 1.7 problem.
78675         Tests for module 'grantpt'.
78676         * modules/grantpt-tests: New file.
78677         * tests/test-grantpt.c: New file.
78678         * doc/posix-functions/grantpt.texi: Mention the Cygwin 1.7 problem.
78680 2011-09-20  Bruno Haible  <bruno@clisp.org>
78682         freopen tests: EBADF tests.
78683         * tests/test-freopen.c: Include errno.h, unistd.h.
78684         (main): Add tests for EBADF, commented out for the moment.
78686         fclose tests: EBADF tests.
78687         * tests/test-fclose.c (main): Add tests for EBADF.
78689         fflush tests: EBADF tests.
78690         * tests/test-fflush.c: Include errno.h, macros.h.
78691         (main): Add tests for EBADF.
78693         ftello tests: EBADF tests.
78694         * tests/test-ftello4.sh: New file.
78695         * tests/test-ftello4.c: New file.
78696         * modules/ftello-tests (Files): Add them.
78697         (Makefile.am): Arrange to compile test-ftello4 and run test-ftello4.sh.
78699         fseeko tests: EBADF tests.
78700         * tests/test-fseeko4.sh: New file.
78701         * tests/test-fseeko4.c: New file.
78702         * modules/fseeko-tests (Files): Add them.
78703         (Makefile.am): Arrange to compile test-fseeko4 and run test-fseeko4.sh.
78705         Tests for function fputc().
78706         * modules/fputc-tests: New file.
78707         * tests/test-fputc.c: New file.
78708         * modules/stdio-tests (Depends-on): Add fputc-tests.
78710         Tests for function fgetc().
78711         * modules/fgetc-tests: New file.
78712         * tests/test-fgetc.c: New file.
78713         * modules/stdio-tests (Depends-on): Add fgetc-tests.
78715         Tests for function fdopen().
78716         * modules/fdopen-tests: New file.
78717         * tests/test-fdopen.c: New file.
78718         * modules/stdio-tests (Depends-on): Add fdopen-tests.
78720         Tests for module 'vdprintf'.
78721         * modules/vdprintf-tests: New file.
78722         * tests/test-vdprintf.c: New file.
78724         Tests for module 'dprintf'.
78725         * modules/dprintf-tests: New file.
78726         * tests/test-dprintf.c: New file.
78728 2011-09-20  Bruno Haible  <bruno@clisp.org>
78730         Tests for module 'ioctl'.
78731         * modules/ioctl-tests: New file.
78732         * tests/test-ioctl.c: New file.
78734 2011-09-20  Bruno Haible  <bruno@clisp.org>
78736         fcntl tests: EBADF tests.
78737         * tests/test-fcntl.c (main): Add more tests for EBADF.
78739 2011-09-20  Bruno Haible  <bruno@clisp.org>
78741         utimensat tests: EBADF tests.
78742         * tests/test-utimensat.c (main): Add tests for EBADF.
78744         renameat tests: EBADF tests.
78745         * tests/test-renameat.c (main): Add tests for EBADF.
78747         mkfifoat tests: EBADF tests.
78748         * tests/test-mkfifoat.c (main): Add tests for EBADF.
78750         readlinkat tests: EBADF tests.
78751         * tests/test-readlinkat.c (main): Add tests for EBADF.
78753         symlinkat tests: EBADF tests.
78754         * tests/test-symlinkat.c (main): Add tests for EBADF.
78756         linkat tests: EBADF tests.
78757         * tests/test-linkat.c (main): Add tests for EBADF.
78759         Tests for module 'faccessat'.
78760         * modules/faccessat-tests: New file.
78761         * tests/test-faccessat.c: New file.
78763         fdopendir tests: EBADF tests.
78764         * tests/test-fdopendir.c (main): Add more tests for EBADF.
78766         openat tests: EBADF tests.
78767         * tests/test-fchownat.c (main): Add tests for EBADF.
78768         * tests/test-fstatat.c (main): Likewise.
78769         * tests/test-mkdirat.c (main): Likewise.
78770         * tests/test-openat.c (main): Likewise.
78771         * tests/test-unlinkat.c (main): Likewise.
78772         * tests/test-fchmodat.c: New file.
78773         * modules/openat-tests (Files): Add tests/test-fchmodat.c.
78774         (Makefile.am): Also run 'test-fchmodat'.
78776 2011-09-20  Bruno Haible  <bruno@clisp.org>
78778         utimens, futimens, fdutimensat tests: EBADF tests.
78779         * tests/test-futimens.h (test_futimens): Add more tests for EBADF.
78781         Tests for function fstat().
78782         * modules/fstat-tests: New file.
78783         * tests/test-fstat.c: New file.
78784         * modules/sys_stat-tests (Depends-on): Add fstat-tests.
78786 2011-09-20  Bruno Haible  <bruno@clisp.org>
78788         test-ttyname_r tests: EBADF tests.
78789         * tests/test-ttyname_r.c (main): Add tests for EBADF.
78791         Tests for module 'isatty'.
78792         * modules/isatty-tests: New file.
78793         * tests/test-isatty.c: New file.
78795         Tests for module 'write'.
78796         * modules/write-tests: New file.
78797         * tests/test-write.c: New file.
78799         Tests for module 'read'.
78800         * modules/read-tests: New file.
78801         * tests/test-read.c: New file.
78803         pwrite tests: EBADF tests.
78804         * tests/test-pwrite.c (main): Add tests for EBADF.
78806         pread tests: EBADF tests.
78807         * tests/test-pread.c (main): Add tests for EBADF.
78809         lseek tests: EBADF tests.
78810         * tests/test-lseek.c (main): Add more tests for EBADF.
78812         Tests for module 'ftruncate'.
78813         * modules/ftruncate-tests: New file.
78814         * tests/test-ftruncate.sh: New file.
78815         * tests/test-ftruncate.c: New file.
78817         fsync tests: EBADF tests.
78818         * tests/test-fsync.c (main): Add more tests for EBADF.
78820         fdatasync tests: EBADF tests.
78821         * tests/test-fdatasync.c (main): Add more tests for EBADF.
78823         Tests for module 'fchown'.
78824         * modules/fchown-tests: New file.
78825         * tests/test-fchown.c: New file.
78827         Tests for module 'fchmod'.
78828         * modules/fchmod-tests: New file.
78829         * tests/test-fchmod.c: New file.
78831         fchdir tests: EBADF tests.
78832         * tests/test-fchdir.c (main): Add more tests for EBADF.
78834         dup2 tests: EBADF tests.
78835         * tests/test-dup2.c (main): Add more tests for EBADF.
78837         Tests for module 'dup'.
78838         * modules/dup-tests: New file.
78839         * tests/test-dup.c: New file.
78841         Tests for module 'close'.
78842         * modules/close-tests: New file.
78843         * tests/test-close.c: New file.
78845 2011-09-20  Bruno Haible  <bruno@clisp.org>
78847         Tests for module 'shutdown'.
78848         * modules/shutdown-tests: New file.
78849         * tests/test-shutdown.c: New file.
78851         Tests for module 'setsockopt'.
78852         * modules/setsockopt-tests: New file.
78853         * tests/test-setsockopt.c: New file.
78855         Tests for module 'sendto'.
78856         * modules/sendto-tests: New file.
78857         * tests/test-sendto.c: New file.
78859         Tests for module 'send'.
78860         * modules/send-tests: New file.
78861         * tests/test-send.c: New file.
78863         Tests for module 'recvfrom'.
78864         * modules/recvfrom-tests: New file.
78865         * tests/test-recvfrom.c: New file.
78867         Tests for module 'recv'.
78868         * modules/recv-tests: New file.
78869         * tests/test-recv.c: New file.
78871         Tests for module 'listen'.
78872         * modules/listen-tests: New file.
78873         * tests/test-listen.c: New file.
78875         Tests for module 'getsockopt'.
78876         * modules/getsockopt-tests: New file.
78877         * tests/test-getsockopt.c: New file.
78879         Tests for module 'getsockname'.
78880         * modules/getsockname-tests: New file.
78881         * tests/test-getsockname.c: New file.
78883         Tests for module 'getpeername'.
78884         * modules/getpeername-tests: New file.
78885         * tests/test-getpeername.c: New file.
78887         Tests for module 'connect'.
78888         * modules/connect-tests: New file.
78889         * tests/test-connect.c: New file.
78891         Tests for module 'bind'.
78892         * modules/bind-tests: New file.
78893         * tests/test-bind.c: New file.
78895         accept4 tests: Fix for native Windows.
78896         * tests/test-accept4.c: Include sockets.h.
78897         (main): Invoke gl_sockets_startup.
78898         * modules/accept4-tests (Depends-on): Add sockets.
78900         accept tests: Fix for native Windows.
78901         * tests/test-accept.c: Include sockets.h.
78902         (main): Invoke gl_sockets_startup.
78903         * modules/accept-tests (Depends-on): Add sockets.
78905 2011-09-19  Bruno Haible  <bruno@clisp.org>
78907         msvc-inval: Require a semicolon after DONE_MSVC_INVAL.
78908         * lib/msvc-inval.h (TRY_MSVC_INVAL, DONE_MSVC_INVAL): Wrap in a
78909         do...while(0).
78910         * lib/dup2.c (rpl_dup2): Add a semicolon after DONE_MSVC_INVAL.
78911         Suggested by Paul Eggert.
78913 2011-09-19  Bruno Haible  <bruno@clisp.org>
78915         sched: Ensure pid_t is defined.
78916         * m4/sched_h.m4 (gl_SCHED_H): Arrange to override <sched.h> if it does
78917         not define pid_t.
78918         * lib/sched.in.h: Include <sys/types.h>.
78919         * doc/posix-headers/sched.texi: Mention the pid_t problem.
78920         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
78922 2011-09-19  Bruno Haible  <bruno@clisp.org>
78924         msvc-inval: Ensure the entire expansion is a single statement.
78925         * lib/msvc-inval.h (TRY_MSVC_INVAL, DONE_MSVC_INVAL): Add an extra pair
78926         of braces.
78928 2011-09-19  Jim Meyering  <meyering@redhat.com>
78930         tests: use printf, not echo in init.sh's warn_ function
78931         * tests/init.sh (warn_): Use printf, not echo.  The latter would
78932         misbehave when given strings containing a backslash or starting
78933         with e.g., -n.  James Youngman suggested setting IFS.
78935 2011-09-19  Eric Blake  <eblake@redhat.com>
78937         futimens: enhance test
78938         * tests/test-futimens.h (test_futimens): Also check for EBADF on
78939         closed non-negative fd.
78941         date: accept 'hence' as opposite of 'ago'
78942         * lib/parse-datetime.y (relative_time_table): Add 'hence'.
78943         * tests/test-parse-datetime.c (main): Enhance test.
78944         Suggested by Jesse Wilson.
78946 2011-09-19  Jim Meyering  <meyering@redhat.com>
78948         getcwd: don't fail in a deep directory on a system without openat
78949         Before this change, getcwd would fail when called from a directory
78950         of depth PATH_MAX / 3 or greater.  That was due to the fact that
78951         the non-openat implementation used "..", "../..", "../../..", etc.
78952         to access ancestor directories.  With too many, that string would
78953         be longer than PATH_MAX.
78954         * lib/getcwd.c (HAVE_OPENAT_SUPPORT): Define also when we are
78955         using gnulib's openat replacement.
78956         * m4/openat.m4: Set GNULIB_OPENAT, so getcwd.c knows when
78957         we're using the replacement function.
78959 2011-09-14  Martin von Gagern  <Martin.vGagern@gmx.net>
78961         maint.mk: avoid warnings from perl about missing files
78962         * top/maint.mk (def_sym_regex): Ignore files listed in
78963         $(gl_other_headers_) that do not exist, say because a project
78964         does not use a corresponding module.
78966 2011-09-18  Paul Eggert  <eggert@cs.ucla.edu>
78968         stat: use pathmax.h only if needed
78969         * lib/stat.c: Include pathmax.h only if REPLACE_FUNC_STAT_DIR.
78970         This is better for Emacs, which does not have a mingw port and
78971         therefore can avoid the pathmax module.
78973         utimens: remove dependency on dup2
78974         * lib/utimens.c (fdutimens): Don't invoke dup2; it's not needed
78975         to work around the Linux kernel bug.
78976         * modules/utimens (Depends-on): Remove dup2.
78978 2011-09-18  Bruno Haible  <bruno@clisp.org>
78980         inet_ntop, inet_pton: Look for it also in libresolv.
78981         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): If the function was not found in
78982         libnsl, search for it in libresolv.
78983         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
78984         Needed on Solaris 7.
78986 2011-09-18  Bruno Haible  <bruno@clisp.org>
78988         accept, accept4 tests: Avoid link error on Solaris.
78989         * modules/accept-tests (Makefile.am): Link test-accept against
78990         $(LIBSOCKET).
78991         * modules/accept4-tests (Makefile.am): Link test-accept4 against
78992         $(LIBSOCKET).
78994         accept4: Avoid link error on Solaris.
78995         * modules/accept4 (Link): New section.
78997         socket functions: Avoid link errors on Solaris.
78998         * modules/accept (Depends-on): Add socketlib.
78999         (Link): New section.
79000         * modules/bind (Depends-on): Add socketlib.
79001         (Link): New section.
79002         * modules/connect (Depends-on): Add socketlib.
79003         (Link): New section.
79004         * modules/getpeername (Depends-on): Add socketlib.
79005         (Link): New section.
79006         * modules/getsockname (Depends-on): Add socketlib.
79007         (Link): New section.
79008         * modules/getsockopt (Depends-on): Add socketlib.
79009         (Link): New section.
79010         * modules/listen (Depends-on): Add socketlib.
79011         (Link): New section.
79012         * modules/recv (Depends-on): Add socketlib.
79013         (Link): New section.
79014         * modules/recvfrom (Depends-on): Add socketlib.
79015         (Link): New section.
79016         * modules/send (Depends-on): Add socketlib.
79017         (Link): New section.
79018         * modules/sendto (Depends-on): Add socketlib.
79019         (Link): New section.
79020         * modules/setsockopt (Depends-on): Add socketlib.
79021         (Link): New section.
79022         * modules/shutdown (Depends-on): Add socketlib.
79023         (Link): New section.
79024         * modules/socket (Depends-on): Add socketlib.
79025         (Link): New section.
79027 2011-09-18  Bruno Haible  <bruno@clisp.org>
79029         ptsname tests: Let the test fail rather than hang (e.g. on AIX 5.1).
79030         * tests/test-ptsname.c (main): Terminate the test if it takes longer
79031         than 5 seconds.
79032         * modules/ptsname-tests (configure.ac): Test for alarm.
79034 2011-09-18  Bruno Haible  <bruno@clisp.org>
79036         posix_spawn_file_actions_add*: Fix module dependencies.
79037         * modules/posix_spawn_file_actions_addclose (Dependencies): Add
79038         posix_spawn_file_actions_init.
79039         * modules/posix_spawn_file_actions_adddup2 (Dependencies): Likewise.
79040         * modules/posix_spawn_file_actions_addopen (Dependencies): Likewise.
79042 2011-09-18  Bruno Haible  <bruno@clisp.org>
79044         rename, renameat tests: Avoid test failures on FreeBSD 6.4.
79045         * tests/test-rename.h (test_rename): Allow error code EEXIST.
79046         * tests/test-renameat.c (main): Likewise.
79048 2011-09-18  Bruno Haible  <bruno@clisp.org>
79050         Tests for module 'accept4'.
79051         * modules/accept4-tests: New file.
79052         * tests/test-accept4.c: New file.
79054 2011-09-18  Bruno Haible  <bruno@clisp.org>
79056         Tests for module 'accept'.
79057         * modules/accept-tests: New file.
79058         * tests/test-accept.c: New file.
79060 2011-09-18  Bruno Haible  <bruno@clisp.org>
79062         dup2: Support for MSVC.
79063         * lib/dup2.c: Include msvc-inval.h.
79064         (rpl_dup2): Handle invalid parameter notifications during dup2 and
79065         _get_osfhandle calls.
79066         * modules/dup2 (Depends-on): Add msvc-inval.
79067         * doc/posix-functions/dup2.texi: Mention problem on MSVC.
79069         New module 'msvc-inval'.
79070         * lib/msvc-inval.h: New file.
79071         * lib/msvc-inval.c: New file.
79072         * m4/msvc-inval.m4: New file.
79073         * modules/msvc-inval: New file.
79075 2011-09-17  Bruno Haible  <bruno@clisp.org>
79077         Tests for module 'pclose'.
79078         * modules/pclose-tests: New file.
79080         New module 'pclose'.
79081         * lib/stdio.in.h (pclose): New declaration.
79082         * lib/pclose.c: New file.
79083         * m4/pclose.m4: New file.
79084         * m4/stdio_h.m4 (gl_STDIO_H): Test whether pclose is declared.
79085         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_PCLOSE, HAVE_PCLOSE.
79086         * modules/stdio (Makefile.am): Substitute GNULIB_PCLOSE, HAVE_PCLOSE.
79087         * modules/pclose: New file.
79088         * modules/popen-tests (Depends-on): Add pclose.
79089         * modules/popen-safer-tests (Depends-on): Likewise.
79090         * doc/posix-functions/pclose.texi: Mention the new module.
79092 2011-09-17  Bruno Haible  <bruno@clisp.org>
79094         popen: Support for MSVC.
79095         * lib/stdio.in.h (popen): Declare it if the system lacks this function.
79096         * lib/popen.c (popen): Provide alternate definition for native Windows.
79097         * m4/popen.m4 (gl_FUNC_POPEN): Test if popen exists. Set HAVE_POPEN.
79098         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_POPEN.
79099         * modules/popen (Depends-on, configure.ac): Update condition.
79100         * modules/stdio (Makefile.am): Substitute HAVE_POPEN.
79101         * doc/posix-functions/popen.texi: Mention that the MSVC problem is
79102         fixed.
79104 2011-09-17  Bruno Haible  <bruno@clisp.org>
79106         isnanl, isnand, isnanf: Work around MSVC bug.
79107         * lib/isnan.c (FUNC): Use alternate ways of computing NaN and Infinity.
79109 2011-09-17  Bruno Haible  <bruno@clisp.org>
79111         sys_socket tests: Fix recent mistake.
79112         * tests/test-sys_socket.c (t1): Avoid collision of identifiers.
79114 2011-09-17  Bruno Haible  <bruno@clisp.org>
79116         putenv: Support for MSVC.
79117         * modules/putenv (Depends-on): Add environ.
79118         * lib/putenv.c (environ): Disable declaration.
79119         * lib/unistd.in.h: Update comment.
79121 2011-09-17  Bruno Haible  <bruno@clisp.org>
79123         math: Avoid macro redefinition warnings on MSVC.
79124         * lib/math.in.h (ceilf, ceill, floorf, floorl, frexpl, ldexpl):
79125         Undefine before redefining.
79127 2011-09-17  Bruno Haible  <bruno@clisp.org>
79129         doc: Mention functions which are declared as macros.
79130         * doc/posix-functions/*[fl].texi: Mention that some functions are
79131         defined as macros with arguments only.
79133 2011-09-17  Bruno Haible  <bruno@clisp.org>
79135         Add dependencies to new dirent related modules.
79136         * modules/backupfile (Depends-on): Add opendir, readdir, closedir.
79137         * modules/fts (Depends-on): Likewise.
79138         * modules/glob (Depends-on): Likewise.
79139         * modules/savedir (Depends-on): Likewise.
79140         * modules/scandir (Depends-on): Likewise.
79141         * modules/dirent-safer (Depends-on): Add opendir, closedir.
79142         * modules/fdopendir (Depends-on): Add opendir.
79144 2011-09-17  Bruno Haible  <bruno@clisp.org>
79146         inet_pton: Support for MSVC on Windows Vista or newer.
79147         * lib/arpa_inet.in.h (inet_pton): Also consider REPLACE_INET_PTON.
79148         * lib/inet_pton.c (rpl_inet_pton): Use a simple wrapper if
79149         HAVE_DECL_INET_PTON is defined.
79150         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Invoke gl_PREREQ_SYS_H_WINSOCK2.
79151         On platforms with <winsock2.h>, test whether inet_pton is declared in
79152         <ws2tcpip.h>. If so, arrange to replace it.
79153         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Initialize
79154         REPLACE_INET_PTON.
79155         * modules/arpa_inet (Makefile.am): Substitute REPLACE_INET_PTON.
79156         * modules/inet_pton (Files): Add m4/sys_socket_h.m4.
79157         (Depends-on, configure.ac): Update condition.
79158         * doc/posix-functions/inet_pton.texi: Mention the MSVC problem.
79160 2011-09-17  Bruno Haible  <bruno@clisp.org>
79162         inet_ntop: Support for MSVC on Windows Vista or newer.
79163         * lib/arpa_inet.in.h (inet_ntop): Also consider REPLACE_INET_NTOP.
79164         * lib/inet_ntop.c (rpl_inet_ntop): Use a simple wrapper if
79165         HAVE_DECL_INET_NTOP is defined.
79166         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Invoke gl_PREREQ_SYS_H_WINSOCK2.
79167         On platforms with <winsock2.h>, test whether inet_ntop is declared in
79168         <ws2tcpip.h>. If so, arrange to replace it.
79169         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Initialize
79170         REPLACE_INET_NTOP.
79171         * modules/arpa_inet (Makefile.am): Substitute REPLACE_INET_NTOP.
79172         * modules/inet_ntop (Files): Add m4/sys_socket_h.m4.
79173         (Depends-on, configure.ac): Update condition.
79174         * doc/posix-functions/inet_ntop.texi: Mention the MSVC problem.
79176 2011-09-16  Eric Blake  <eblake@redhat.com>
79178         test-fsync: yet another enhancement
79179         * tests/test-fsync.c (main): Also test behavior on read-only text
79180         file.
79182 2011-09-16  Bruno Haible  <bruno@clisp.org>
79184         Enhance fsync, fdatasync tests.
79185         * tests/test-fsync.c (main): Test both STDIN_FILENO and STDOUT_FILENO.
79186         * tests/test-fdatasync.c (main): Likewise.
79188 2011-09-16  Bruno Haible  <bruno@clisp.org>
79190         Support for MSVC compiler: Ensure mode_t gets defined.
79191         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_TYPE_MODE_T.
79192         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
79193         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
79194         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Likewise.
79195         * tests/test-fcntl-h.c: Check that mode_t is defined.
79196         * tests/test-sys_stat.c: Likewise.
79197         * tests/test-sys_types.c: Likewise.
79198         * doc/posix-headers/fcntl.texi: Mention the missing mode_t problem.
79199         * doc/posix-headers/sys_stat.texi: Likewise.
79200         * doc/posix-headers/sys_types.texi: Likewise.
79202 2011-09-16  Bruno Haible  <bruno@clisp.org>
79204         sys_stat: Support for MSVC.
79205         * lib/sys_stat.in.h (S_IFIFO): Define to _S_IFIFO if that exists.
79206         * tests/test-sys_stat.c: Don't assume that S_IFBLK exists.
79207         * doc/posix-headers/sys_stat.texi: Mention missing S_IFIFO, S_IFBLK on
79208         MSVC.
79210 2011-09-16  Bruno Haible  <bruno@clisp.org>
79212         Support for MSVC compiler: Ensure off_t gets defined.
79213         * lib/unistd.in.h: Include <sys/types.h>.
79214         * tests/test-fcntl-h.c: Check that off_t is defined.
79215         * tests/test-sys_stat.c: Likewise.
79216         * tests/test-sys_types.c: Likewise.
79218 2011-09-16  Eric Blake  <eblake@redhat.com>
79220         fdatasync: port to Solaris
79221         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Set LIB_FDATASYNC.
79222         * modules/fdatasync (Link): Document it.
79223         * modules/fdatasync-tests (test_fdatasync_LDADD): Link with it.
79225         fdatasync: port to MacOS X 10.7
79226         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Check for present but not
79227         declared.
79228         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Another default.
79229         * modules/unistd (Makefile.am): Substitute it.
79230         * lib/unistd.in.h (fdatasync): Declare on MacOS.
79231         * doc/posix-functions/fdatasync.texi (fdatasync): Document it.
79233         fdatasync: minor improvements
79234         * modules/fdatasync (Depends-on): Add condition for fsync.
79235         * lib/fdatasync.c (fdatasync): Add comment.
79236         * tests/test-unistd-c++.cc: Test fdatasync.
79238         unistd: update refs to newer POSIX
79239         * lib/unistd.in.h: Prefer POSIX 2008 over 2001.
79240         Suggested by Bruno Haible.
79242         fdatasync: new module
79243         * modules/fsync (Description): Document difference to fdatasync.
79244         * modules/fdatasync: New module.
79245         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): New file.
79246         * lib/fdatasync.c (fdatasync): Likewise.
79247         * m4/unistd_h.m4 (gl_UNISTD_H, gl_UNISTD_H_DEFAULTS): Set up
79248         defaults.
79249         * modules/unistd (Makefile.am): Set witnesses.
79250         * lib/unistd.in.h (fdatasync): Declare.
79251         * MODULES.html.sh: Document it.
79252         * doc/posix-functions/fdatasync.texi (fdatasync): Likewise.
79253         * modules/fdatasync-tests: New test.
79254         * tests/test-fdatasync.c: Likewise.
79256 2011-09-16  Eric Blake  <eblake@redhat.com>
79258         test-fsync: enhance tests
79259         * modules/fsync-tests (Depends-on): Add errno, for mingw.
79260         * tests/test-fsync.c (main): Enhance test.
79262 2011-09-15  Bruno Haible  <bruno@clisp.org>
79264         Support for MSVC compiler: Ensure ssize_t gets defined.
79265         * doc/posix-headers/sys_types.texi: Mention the missing ssize_t problem.
79266         * doc/posix-headers/stdio.texi: Likewise.
79267         * modules/stdio (Depends-on): Add ssize_t.
79268         * modules/sys_socket (Depends-on): Likewise.
79269         * modules/sys_types (Depends-on): Likewise.
79270         * modules/sys_uio (Depends-on): Likewise.
79271         * modules/unistd (Depends-on): Likewise.
79272         * tests/test-sys_socket.c: Check that size_t and ssize_t are defined.
79273         * tests/test-sys_types.c: Check that ssize_t is defined.
79275 2011-09-14  Bruno Haible  <bruno@clisp.org>
79277         Avoid using #, the m4 comment starter character, near brackets.
79278         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): Use |, not #, as
79279         delimiter character in sed expressions.
79280         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Likewise.
79281         Suggested by Eric Blake.
79283         Properly quote AC_CHECK_DECLS' 4th argument.
79284         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Double-quote AC_CHECK_DECLS' 4th
79285         argument.
79286         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
79287         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
79288         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
79289         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
79290         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
79291         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): Likewise.
79292         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Likewise.
79293         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Likewise.
79294         * m4/gethrxtime.m4 (gl_GETHRXTIME): Likewise.
79295         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
79296         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Likewise.
79297         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
79298         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
79299         * m4/isinf.m4 (gl_ISINF): Likewise.
79300         * m4/logb.m4 (gl_FUNC_LOGB): Likewise.
79301         * m4/readutmp.m4 (gl_READUTMP): Likewise.
79302         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
79303         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
79304         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
79305         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
79306         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
79307         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
79308         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Likewise.
79309         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
79310         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
79311         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
79312         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Likewise.
79313         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
79314         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
79315         Reported by Eric Blake.
79317         Properly quote AC_CHECK_DECL's 4th argument.
79318         * m4/acosl.m4 (gl_FUNC_ACOSL): Double-quote AC_CHECK_DECL's 4th
79319         argument.
79320         * m4/argp.m4 (gl_ARGP): Likewise.
79321         * m4/asinl.m4 (gl_FUNC_ASINL): Likewise.
79322         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
79323         * m4/cosl.m4 (gl_FUNC_COSL): Likewise.
79324         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
79325         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): Likewise.
79326         * m4/getloadavg.m4 (gl_GETLOADAVG): Likewise.
79327         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Likewise.
79328         * m4/logl.m4 (gl_FUNC_LOGL): Likewise.
79329         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
79330         * m4/sinl.m4 (gl_FUNC_SINL): Likewise.
79331         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Likewise.
79332         * m4/tanl.m4 (gl_FUNC_TANL): Likewise.
79333         Reported by Eric Blake.
79335 2011-09-14  Eric Blake  <eblake@redhat.com>
79337         opendir: avoid compile warning
79338         * lib/opendir.c (includes): Always include errno.h.
79339         Reported by Tatsuro MATSUOKA.
79341 2011-09-14  Jim Meyering  <meyering@redhat.com>
79343         maint.mk: sc_tight_scope: propagate failure from sub-make
79344         * top/maint.mk (sc_tight_scope): Actually initialize and use $fail.
79345         Reported by Martin von Gagern.
79347 2011-09-13  Bruno Haible  <bruno@clisp.org>
79349         tempname: Support for MSVC.
79350         * doc/posix-headers/fcntl.texi: Document the problem with O_ACCMODE on
79351         MSVC.
79352         * modules/tempname (Depends-on): Add fcntl-h.
79354 2011-09-13  Bruno Haible  <bruno@clisp.org>
79356         sys_time: Support for MSVC.
79357         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Invoke
79358         gl_PREREQ_SYS_H_WINSOCK2. When testing for 'struct timeval', also
79359         include <winsock2.h>.
79360         * lib/sys_time.in.h: On MSVC, include <winsock2.h> and hide its
79361         function declarations that collide with POSIX.
79362         * modules/sys_time (Files): Add m4/sys_socket_h.m4.
79363         (Makefile.am): Substitute HAVE_WINSOCK2_H.
79365 2011-09-13  Bruno Haible  <bruno@clisp.org>
79367         stat: Support for MSVC.
79368         * lib/stat.c: Include pathmax.h.
79369         * modules/stat (Depends-on): Add pathmax.
79371         pathmax: Support for native Windows.
79372         * lib/pathmax.h (PATH_MAX): Define to 260 on native Windows.
79374 2011-09-12  Bruno Haible  <bruno@clisp.org>
79376         New modules 'opendir', 'readdir', 'rewinddir', 'closedir'.
79377         * lib/dirent.in.h (struct dirent): New type.
79378         (DT_UNKNOWN, DT_FIFO, DT_CHR, DT_DIR, DT_BLK, DT_REG, DT_LNK, DT_SOCK,
79379         DT_WHT): New macros.
79380         (DIR): New type.
79381         (opendir, closedir): Declare only if the module 'opendir' is enabled.
79382         (readdir, rewinddir): New declarations.
79383         * lib/dirent-private.h: New file.
79384         * lib/opendir.c: New file.
79385         * lib/readdir.c: New file.
79386         * lib/rewinddir.c: New file.
79387         * lib/closedir.c: New file.
79388         * lib/fchdir.c (rpl_closedir, rpl_opendir): Remove functions.
79389         * m4/opendir.m4: New file.
79390         * m4/readdir.m4: New file.
79391         * m4/rewinddir.m4: New file.
79392         * m4/closedir.m4: New file.
79393         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_OPENDIR,
79394         REPLACE_CLOSEDIR here.
79395         * m4/dirent_h.m4 (gl_DIRENT_H): Also check whether closedir, opendir,
79396         readdir, rewinddir are declared.
79397         (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_OPENDIR, GNULIB_READDIR,
79398         GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR, HAVE_READDIR,
79399         HAVE_REWINDDIR, HAVE_CLOSEDIR.
79400         * modules/dirent (Makefile.am): Substitute GNULIB_OPENDIR,
79401         GNULIB_READDIR, GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR,
79402         HAVE_READDIR, HAVE_REWINDDIR, HAVE_CLOSEDIR.
79403         * modules/opendir: New file.
79404         * modules/readdir: New file.
79405         * modules/rewinddir: New file.
79406         * modules/closedir: New file.
79407         * doc/posix-functions/opendir.texi: Mention the 'opendir' module.
79408         * doc/posix-functions/readdir.texi: Mention the 'readdir' module.
79409         * doc/posix-functions/rewinddir.texi: Mention the 'rewinddir' module.
79410         * doc/posix-functions/closedir.texi: Mention the 'closedir' module.
79411         * NEWS: Mention the 'fchdir' change.
79413 2011-09-11  Bruno Haible  <bruno@clisp.org>
79415         asm-underscore.m4: Support for MSVC.
79416         * m4/asm-underscore.m4 (gl_C_ASM): New macro.
79417         (gl_ASM_SYMBOL_PREFIX): Require it. Use its results.
79419 2011-09-11  Reuben Thomas  <rrt@sc3d.org>
79421         Doc about crypt functions.
79422         * doc/posix-functions/crypt.texi: Expand range of glibc versions
79423         needing for _GNU_SOURCE to get crypt.
79424         * doc/posix-functions/encrypt.texi: Likewise.
79425         * doc/posix-functions/setkey.texi: Likewise.
79427 2011-09-11  Bruno Haible  <bruno@clisp.org>
79429         doc: Update regarding MSVC 9.
79430         * doc/gnulib-intro.texi (Target Platforms): Classify MSVC as "rarely
79431         tested".
79432         * doc/posix-functions/*.texi: Update with info about MSVC 9.
79433         * doc/posix-headers/*.texi: Likewise.
79434         * doc/pastposix-functions/*.texi: Likewise.
79435         * doc/glibc-functions/*.texi: Likewise.
79436         * doc/glibc-headers/*.texi: Likewise.
79438 2011-09-11  Bruno Haible  <bruno@clisp.org>
79440         unistd et al.: Don't assume <unistd.h> exists.
79441         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Don't include <unistd.h> if it
79442         does not exist.
79443         * m4/environ.m4 (gl_ENVIRON): Don't include <unistd.h> if it does not
79444         exist. But include <stdlib.h>.
79445         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): If <unistd.h> does not exist,
79446         include <io.h> and <stdlib.h> instead. Don't test symbolink links if
79447         symlink() does not exist.
79448         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): If <unistd.h> does not exist,
79449         include <io.h> instead.
79450         * m4/free.m4 (gl_FUNC_FREE): Assume free(NULL) works on native Windows.
79451         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): If <unistd.h> does not exist,
79452         include <direct.h> instead.
79453         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
79454         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
79455         * m4/lseek.m4 (gl_FUNC_LSEEK): If <unistd.h> does not exist, include
79456         <io.h> instead.
79457         * m4/rename.m4 (gl_FUNC_RENAME): Assume rename() manages hard links
79458         correctly if the system does not have hard links.
79459         * m4/rmdir.m4 (gl_FUNC_RMDIR): If <unistd.h> does not exist, include
79460         <direct.h> instead.
79461         * m4/unistd_h.m4 (gl_UNISTD_H): If <unistd.h> does not exist, bypass
79462         it when looking for function declarations.
79463         * m4/unlink.m4 (gl_FUNC_UNLINK): If <unistd.h> does not exist, include
79464         <direct.h> and <io.h> instead.
79465         * doc/posix-headers/unistd.texi: More details about MSVC problem.
79467 2011-09-11  Bruno Haible  <bruno@clisp.org>
79469         strcase: Support for MSVC.
79470         * modules/strcase (Status, Notice): Remove obsoletion mark.
79471         * doc/posix-functions/strcasecmp.texi: Mention MSVC problem.
79472         * doc/posix-functions/strncasecmp.texi: Likewise.
79474         strings: Don't assume <strings.h> exists.
79475         * lib/strings.in.h: Include <strings.h> only if HAVE_STRINGS_H is 1.
79476         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Set HAVE_STRINGS_H.
79477         * modules/strings (Makefile.am): Substitute HAVE_STRINGS_H.
79478         * doc/posix-headers/strings.texi: Mention the MSVC problem.
79480 2011-09-11  Bruno Haible  <bruno@clisp.org>
79482         dirent: Don't assume <dirent.h> exists.
79483         * lib/dirent.in.h: Include <dirent.h> only if HAVE_DIRENT_H is 1.
79484         * m4/dirent_h.m4 (gl_DIRENT_H): Set HAVE_DIRENT_H.
79485         * modules/dirent (Makefile.am): Substitute HAVE_DIRENT_H.
79486         * doc/posix-headers/dirent.texi: Mention the MSVC problem.
79488 2011-09-11  Bruno Haible  <bruno@clisp.org>
79490         Fix wint_t on MSVC.
79491         * lib/wchar.in.h (wint_t): On MSVC, override it.
79492         * lib/wctype.in.h (wint_t): Likewise.
79493         * m4/stdint.m4 (gl_STDINT_TYPE_PROPERTIES): Override BITSIZEOF_WINT_T on
79494         MSVC.
79495         * doc/posix-headers/wchar.texi: Mention the problem with wint_t on MSVC.
79496         * doc/posix-headers/wctype.texi: Likewise.
79498 2011-09-11  Bruno Haible  <bruno@clisp.org>
79500         sys_types: Fix typo.
79501         * lib/sys_types.in.h: Fix typo in comment.
79502         Reported by Paul Eggert.
79504         Support for MSVC compiler: Ensure size_t gets defined.
79505         * modules/strings (Depends-on): Add 'sys_types'.
79506         * modules/sys_uio (Depends-on): Likewise.
79507         * lib/sys_uio.in.h: Update comment.
79509         C++ tests for module 'sys_types'.
79510         * modules/sys_types-c++-tests: New file.
79511         * tests/test-sys_types-c++.cc: New file.
79513         Tests for module 'sys_types'.
79514         * modules/sys_types-tests: New file.
79515         * tests/test-sys_types.c: New file.
79517         New module 'sys_types'.
79518         * lib/sys_types.in.h: New file.
79519         * m4/sys_types_h.m4: New file.
79520         * modules/sys_types: New file.
79521         * doc/posix-headers/sys_types.texi: Mention the new module and the
79522         size_t problem on MSVC 9.
79524 2011-09-11  Bruno Haible  <bruno@clisp.org>
79526         Support for MSVC compiler: Avoid division by a literal 0.
79527         * lib/math.in.h (NAN): Define through a function call also on MSVC.
79528         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Divide by 'zero' instead of 0.0.
79529         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_DIRECTIVE_A,
79530         gl_PRINTF_DIRECTIVE_F, gl_PRINTF_FLAG_ZERO): Likewise.
79531         (gl_PRINTF_INFINITE_LONG_DOUBLE): Divide by 'zeroL' instead of 0.0L.
79532         * tests/infinity.h: New file.
79533         * tests/nan.h (NaNf, NaNd, NaNl): Define through a function call also
79534         on MSVC.
79535         * tests/test-ceilf1.c: Include infinity.h.
79536         (main): Use Infinityf.
79537         * tests/test-ceil1.c: Include infinity.h.
79538         (main): Use Infinityd.
79539         * tests/test-ceill.c: Include infinity.h.
79540         (main): Use Infinityl.
79541         * tests/test-dprintf-posix.c: Include infinity.h.
79542         (test_function): Use Infinityd.
79543         * tests/test-floorf1.c: Include infinity.h.
79544         (main): Use Infinityf.
79545         * tests/test-floor1.c: Include infinity.h.
79546         (main): Use Infinityd.
79547         * tests/test-floorl.c: Include infinity.h.
79548         (main): Use Infinityl.
79549         * tests/test-fprintf-posix.c: Include infinity.h.
79550         (test_function): Use Infinityd.
79551         * tests/test-frexp.c: Include infinity.h.
79552         (main): Use Infinityd.
79553         * tests/test-frexpl.c: Include infinity.h.
79554         (main): Use Infinityl.
79555         * tests/test-isfinite.c: Include infinity.h.
79556         (test_isfinitef): Use Infinityf.
79557         (test_isfinited): Use Infinityd.
79558         (test_isfinitel): Use Infinityl.
79559         * tests/test-isinf.c: Include infinity.h.
79560         (test_isinff): Use Infinityf.
79561         (test_isinfd): Use Infinityd.
79562         (test_isinfl): Use Infinityl.
79563         * tests/test-isnan.c: Include infinity.h.
79564         (test_float): Use Infinityf.
79565         (test_double): Use Infinityd.
79566         (test_long_double): Use Infinityl.
79567         * tests/test-isnanf.h: Include infinity.h.
79568         (main): Use Infinityf.
79569         * tests/test-isnand.h: Include infinity.h.
79570         (main): Use Infinityd.
79571         * tests/test-isnanl.h: Include infinity.h.
79572         (main): Use Infinityl.
79573         * tests/test-ldexpl.c: Include infinity.h.
79574         (main): Use Infinityl.
79575         * tests/test-printf-posix.h: Include infinity.h.
79576         (test_function): Use Infinityd.
79577         * tests/test-roundf1.c: Include infinity.h.
79578         (main): Use Infinityf.
79579         * tests/test-round1.c: Include infinity.h.
79580         (main): Use Infinityd.
79581         * tests/test-roundl.c: Include infinity.h.
79582         (main): Use Infinityl.
79583         * tests/test-signbit.c: Include infinity.h.
79584         (test_signbitf): Use Infinityf.
79585         (test_signbitd): Use Infinityd.
79586         (test_signbitl): Use Infinityl.
79587         * tests/test-snprintf-posix.h: Include infinity.h.
79588         (test_function): Use Infinityd, Infinityl.
79589         * tests/test-sprintf-posix.h: Include infinity.h.
79590         (test_function): Use Infinityd, Infinityl.
79591         * tests/test-truncf1.c: Include infinity.h.
79592         (main): Use Infinityf.
79593         * tests/test-trunc1.c: Include infinity.h.
79594         (main): Use Infinityd.
79595         * tests/test-truncl.c: Include infinity.h.
79596         (main): Use Infinityl.
79597         * tests/test-vasnprintf-posix.c: Include infinity.h.
79598         (test_function): Use Infinityd, Infinityl.
79599         * tests/test-vasprintf-posix.c: Include infinity.h.
79600         (test_function): Use Infinityd, Infinityl.
79601         * modules/ceilf-tests (Files): Add tests/infinity.h.
79602         * modules/ceil-tests (Files): Likewise.
79603         * modules/ceill-tests (Files): Likewise.
79604         * modules/dprintf-posix-tests (Files): Likewise.
79605         * modules/floorf-tests (Files): Likewise.
79606         * modules/floor-tests (Files): Likewise.
79607         * modules/floorl-tests (Files): Likewise.
79608         * modules/fprintf-posix-tests (Files): Likewise.
79609         * modules/frexp-tests (Files): Likewise.
79610         * modules/frexp-nolibm-tests (Files): Likewise.
79611         * modules/frexpl-tests (Files): Likewise.
79612         * modules/frexpl-nolibm-tests (Files): Likewise.
79613         * modules/isfinite-tests (Files): Likewise.
79614         * modules/isinf-tests (Files): Likewise.
79615         * modules/isnan-tests (Files): Likewise.
79616         * modules/isnanf-tests (Files): Likewise.
79617         * modules/isnanf-nolibm-tests (Files): Likewise.
79618         * modules/isnand-tests (Files): Likewise.
79619         * modules/isnand-nolibm-tests (Files): Likewise.
79620         * modules/isnanl-tests (Files): Likewise.
79621         * modules/isnanl-nolibm-tests (Files): Likewise.
79622         * modules/ldexpl-tests (Files): Likewise.
79623         * modules/printf-posix-tests (Files): Likewise.
79624         * modules/roundf-tests (Files): Likewise.
79625         * modules/round-tests (Files): Likewise.
79626         * modules/roundl-tests (Files): Likewise.
79627         * modules/signbit-tests (Files): Likewise.
79628         * modules/snprintf-posix-tests (Files): Likewise.
79629         * modules/sprintf-posix-tests (Files): Likewise.
79630         * modules/truncf-tests (Files): Likewise.
79631         * modules/trunc-tests (Files): Likewise.
79632         * modules/truncl-tests (Files): Likewise.
79633         * modules/vasnprintf-posix-tests (Files): Likewise.
79634         * modules/vasprintf-posix-tests (Files): Likewise.
79635         * modules/vdprintf-posix-tests (Files): Likewise.
79636         * modules/vfprintf-posix-tests (Files): Likewise.
79637         * modules/vprintf-posix-tests (Files): Likewise.
79638         * modules/vsnprintf-posix-tests (Files): Likewise.
79639         * modules/vsprintf-posix-tests (Files): Likewise.
79640         * modules/xprintf-posix-tests (Files): Likewise.
79642 2011-09-11  Bruno Haible  <bruno@clisp.org>
79644         Ensure pid_t gets defined.
79645         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_TYPE_PID_T.
79646         * m4/sched_h.m4 (gl_SCHED_H): Likewise.
79647         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
79648         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
79649         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H): Likewise.
79650         * m4/termios_h.m4 (gl_TERMIOS_H): Likewise.
79651         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
79652         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
79653         * tests/test-fcntl-h.c: Check that pid_t is defined.
79654         * tests/test-sched.c: Likewise.
79655         * tests/test-termios.c: Likewise.
79656         * tests/test-time.c: Likewise.
79657         * doc/posix-headers/fcntl.texi: Mention lack of pid_t on MSVC platform.
79658         * doc/posix-headers/signal.texi: Likewise.
79659         * doc/posix-headers/sys_types.texi: Likewise.
79660         * doc/posix-headers/time.texi: Likewise.
79662 2011-09-11  Bruno Haible  <bruno@clisp.org>
79664         acl: Fix compilation on Solaris 10 (older version).
79665         * lib/file-has-acl.c (acl_ace_nontrivial): Use NEW_ACE_EVERYONE instead
79666         of ACE_EVERYONE.
79667         * lib/set-mode-acl.c (qset_acl): Likewise.
79668         Reported by Christian Jullien <eligis@orange.fr>.
79670 2011-09-10  Bruno Haible  <bruno@clisp.org>
79672         iconv, unsetenv: Add support for MSVC compiler.
79673         * m4/iconv.m4 (AM_ICONV): Use ISO C declaration syntax on MSVC.
79674         * m4/setenv.m4 (gl_FUNC_UNSETENV): Drop support for K&R C compilers.
79676 2011-09-10  Bruno Haible  <bruno@clisp.org>
79678         *printf: Add support for MSVC compiler.
79679         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): On MSVC, install a handler that
79680         handles the exception caused by the %n directive. When cross-compiling,
79681         guess no on native Windows.
79682         (gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
79683         gl_SNPRINTF_DIRECTIVE_N, gl_SNPRINTF_SIZE1): When snprintf is missing,
79684         emulate it through vsnprintf.
79685         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Update comment.
79686         * doc/posix-functions/dprintf.texi: Update documentation regarding
79687         MSVC 9.
79688         * doc/posix-functions/fprintf.texi: Likewise.
79689         * doc/posix-functions/printf.texi: Likewise.
79690         * doc/posix-functions/snprintf.texi: Likewise.
79691         * doc/posix-functions/sprintf.texi: Likewise.
79692         * doc/posix-functions/swprintf.texi: Likewise.
79693         * doc/posix-functions/vdprintf.texi: Likewise.
79694         * doc/posix-functions/vfprintf.texi: Likewise.
79695         * doc/posix-functions/vprintf.texi: Likewise.
79696         * doc/posix-functions/vsnprintf.texi: Likewise.
79697         * doc/posix-functions/vsprintf.texi: Likewise.
79698         * doc/glibc-functions/asprintf.texi: Likewise.
79699         * doc/glibc-functions/obstack_printf.texi: Likewise.
79700         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
79701         * doc/glibc-functions/vasprintf.texi: Likewise.
79703 2011-09-10  Bruno Haible  <bruno@clisp.org>
79705         nocrash: Add support for native Windows.
79706         * m4/nocrash.m4 (GL_NOCRASH): Avoid a crash also on native Windows.
79708 2011-09-10  Michael Goffioul  <michael.goffioul@gmail.com>  (tiny change)
79709             Bruno Haible  <bruno@clisp.org>
79711         absolute-header, include-next: Add support for MSVC compiler.
79712         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): Require
79713         AC_CANONICAL_HOST. On native Windows, recognize also backslash as
79714         directory separator in #line directives.
79715         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): On native Windows,
79716         recognize also backslash as directory separator in #line directives.
79718 2011-09-08  Jim Meyering  <meyering@redhat.com>
79720         maint.mk: mark the post-release commit log with "maint: " prefix
79721         * top/maint.mk (emit-commit-log): Add "maint: " prefix to the
79722         one-line commit-log summary.
79724 2011-09-08  Reuben Thomas  <rrt@sc3d.org>
79725             Bruno Haible  <bruno@clisp.org>
79727         Doc about crypt functions.
79728         * doc/posix-functions/crypt.texi: Mention need for _GNU_SOURCE on glibc
79729         systems.
79730         * doc/posix-functions/encrypt.texi: Likewise.
79731         * doc/posix-functions/setkey.texi: Likewise.
79733 2011-09-08  Simon Josefsson  <simon@josefsson.org>
79735         * lib/gc.h: Fix copyright header.
79737 2011-09-07  Bruno Haible  <bruno@clisp.org>
79739         pthread: Determine $(LIB_PTHREAD) correctly on OSF/1 5.1.
79740         * m4/pthread.m4 (gl_PTHREAD_CHECK): Use AC_CACHE_CHECK and
79741         AC_LINK_IFELSE instead of AC_SEARCH_LIBS.
79743 2011-09-07  Bruno Haible  <bruno@clisp.org>
79745         openat: Work around compilation error with OSF/1 5.1 DTK cc.
79746         * lib/fopen.c: Use different syntax for include of <stdio.h>.
79747         * lib/freopen.c: Likewise.
79748         * lib/fstatat.c: Use different syntax for include of <sys/stat.h>.
79749         * lib/lstat.c: Likewise.
79750         * lib/stat.c: Likewise.
79751         * lib/open.c: Use different syntax for include of <fcntl.h>.
79752         * lib/openat.c: Include fcntl.h again, explicitly.
79754 2011-09-04  J.T. Conklin  <jtc@acorntoolworks.com>
79756         parse-datetime: document the newly accepted format
79757         * doc/parse-datetime.texi (Combined date and time of day items):
79758         New section.
79760 2011-09-06  Bruno Haible  <bruno@clisp.org>
79762         acl: Fix a test failure on newer Solaris 10 with ZFS.
79763         * tests/test-sameacls.c (main): Interpret acl GETACLCNT failure with
79764         ENOSYS as no ACL.
79765         Reported by Jim Meyering.
79767 2011-09-06  Bruno Haible  <bruno@clisp.org>
79769         acl: Update for AIX >= 5.3 with NFS.
79770         * lib/file-has-acl.c (file_has_acl): Interpret aclx_get failure with
79771         ENOSYS as no ACL.
79773         acl: Fix a test failure on AIX >= 5.3 with NFS.
79774         * tests/test-sameacls.c (main): Interpret aclx_get failure with ENOSYS
79775         as no ACL.
79777 2011-09-06  Bruno Haible  <bruno@clisp.org>
79779         acl: Fix a test failure on IRIX 6.5 with NFS.
79780         * lib/acl-internal.h (MODE_INSIDE_ACL): Define to 0 on IRIX.
79781         * lib/set-mode-acl.c (qset_acl): Test !HAVE_ACL_TYPE_EXTENDED instead
79782         of MODE_INSIDE_ACL. If !MODE_INSIDE_ACL, do a chmod_or_fchmod always.
79783         * lib/copy-acl.c (qcopy_acl): Likewise.
79785 2011-09-05  Paul Eggert  <eggert@cs.ucla.edu>
79787         openat: port to AIX 7.1 with large files
79788         AIX 7.1 does a "#define openat open64at" if large files are in use,
79789         so we can't simply #undef openat.  Use the orig_openat trick (similar
79790         to orig_open in lib/open.c) to work around the problem.  Problem
79791         reported by Kevin Brott for GNU tar, in the thread containing
79792         <http://lists.gnu.org/r/bug-tar/2011-09/msg00032.html>.
79793         * lib/openat.c (__need_system_fcntl_h): Define first.
79794         Include <fcntl.h> and <sys/types.h> before undefining.
79795         (orig_openat) [HAVE_OPENAT]: New inline function.
79796         (openat) [HAVE_OPENAT]: Do not undef.
79797         (rpl_openat): Use orig_openat, not openat.
79799 2011-09-05  Joachim Schmitz  <schmitz@hp.com>  (tiny change)
79800             Bruno Haible  <bruno@clisp.org>
79802         acl: Avoid errors on NonStop Kernel.
79803         * lib/file-has-acl.c (file_has_acl) [NonStop Kernel]: Ignore ENOSYS and
79804         ENOTSUP errors.
79806 2011-09-05  Bruno Haible  <bruno@clisp.org>
79808         acl: Clean up Solaris code.
79809         * lib/acl-internal.h: Remove no-op #if.
79810         * lib/file-has-acl.c: Likewise.
79811         * lib/set-mode-acl.c (qset_acl): Remove unused Solaris code.
79812         * lib/copy-acl.c (qcopy_acl): Likewise.
79814 2011-09-05  Bruno Haible  <bruno@clisp.org>
79816         acl: Fix a bug with NFSv4 ACLs on Solaris 10 (newer version) in
79817         binaries built on the original Solaris 10.
79818         * lib/file-has-acl.c (file_has_acl): ACLs with 4..6 ACEs can be
79819         trivial.
79821 2011-09-05  Bruno Haible  <bruno@clisp.org>
79823         acl: Improve support of NFSv4 ACLs on Solaris 10 (newer version).
79824         * lib/acl-internal.h (acl_nontrivial): Declare also on newer Solaris
79825         10.
79826         * lib/file-has-acl.c (acl_nontrivial): Define also on newer Solaris 10.
79827         (acl_ace_nontrivial): Likewise. Recognize the trivial ACLs with 6 ACEs.
79828         * lib/copy-acl.c (qcopy_acl): On newer Solaris 10, use acl or facl
79829         instead of acl_get, facl_get, acl_set, facl_set.
79831 2011-09-05  Bruno Haible  <bruno@clisp.org>
79833         copy-file: Try unit tests on more file systems.
79834         * tests/test-copy-file-1.sh: New file.
79835         * tests/test-copy-file-2.sh: New file.
79836         * modules/copy-file-tests (Files): Add them.
79837         (Makefile.am): Add them to TESTS.
79839         acl: Try unit tests on more file systems.
79840         * tests/test-file-has-acl-1.sh: New file.
79841         * tests/test-file-has-acl-2.sh: New file.
79842         * tests/test-set-mode-acl-1.sh: New file.
79843         * tests/test-set-mode-acl-2.sh: New file.
79844         * tests/test-copy-acl-1.sh: New file.
79845         * tests/test-copy-acl-2.sh: New file.
79846         * modules/acl-tests (Files): Add them.
79847         (Makefile.am): Add them to TESTS.
79849 2011-09-04  Bruno Haible  <bruno@clisp.org>
79851         acl: Improve support of NFSv4 ACLs on Solaris 10 (newer version).
79852         * lib/acl-internal.h (ACE_*, NEW_ACE_*): Define also on newer Solaris
79853         10.
79854         (OLD_ALLOW, OLD_DENY): New macros.
79855         (NEW_ACE_ACCESS_ALLOWED_ACE_TYPE): Renamed from
79856         ACE_ACCESS_ALLOWED_ACE_TYPE.
79857         (NEW_ACE_ACCESS_DENIED_ACE_TYPE): Renamed from
79858         ACE_ACCESS_DENIED_ACE_TYPE.
79859         (OLD_ACE_OWNER, OLD_ACE_GROUP, OLD_ACE_OTHER): New macros.
79860         (NEW_ACE_EXECUTE): Fix value.
79861         (NEW_ACE_APPEND_DATA, NEW_ACE_READ_NAMED_ATTRS,
79862         NEW_ACE_WRITE_NAMED_ATTRS, NEW_ACE_DELETE_CHILD,
79863         NEW_ACE_READ_ATTRIBUTES, NEW_ACE_WRITE_ATTRIBUTES, NEW_ACE_DELETE,
79864         NEW_ACE_READ_ACL, NEW_ACE_WRITE_ACL, NEW_ACE_WRITE_OWNER,
79865         NEW_ACE_SYNCHRONIZE): New macros.
79866         * lib/set-mode-acl.c (qset_acl): On newer Solaris 10, use acl or facl
79867         instead of acl_fromtext, acl_set, facl_set.
79868         Fixes a coreutils/tests/cp/perm failure.
79870 2011-09-03  Paul Eggert  <eggert@cs.ucla.edu>
79872         openat: test for fstatat (..., 0) bug
79873         Further testing with tar suggests that fstatat (..., 0)
79874         does not work in general, on AIX 7.1; see
79875         <http://lists.gnu.org/r/bug-tar/2011-09/msg00023.html>.
79876         So, give up entirely on AIX 7.1's fstatat, and fall back on our
79877         replacement fstatat (which is what older AIX releases were using
79878         anyway).
79879         * lib/fstatat.c (fstatat) [HAVE_FSTATAT]: Do not undef.  The only
79880         use is now changed to orig_fstatat.  This was probably the right
79881         thing to do anyway.
79882         (FSTATAT_AT_FDCWD_0_BROKEN): Remove; no longer used.
79883         (rpl_fstatat) [FSTATAT_ZERO_FLAG_BROKEN]: Remove.
79884         (rpl_fstatat): Simplify, assuming !FSTATAT_ZERO_FLAG_BROKEN.
79885         (AT_FUNC_NAME) [FSTATAT_ZERO_FLAG_BROKEN]: Now rpl_fstatat.
79886         * m4/openat.m4 (gl_FUNC_FSTATAT): Test for the more-general bug
79887         and define FSTATAT_ZERO_FLAG_BROKEN, not FSTATAT_AT_FDCWD_0_BROKEN,
79888         if the bug is found.
79890         openat: test for fstatat (AT_FDCWD, ..., 0) bug
79891         This tests for another fstatat bug on AIX 7.1:
79892         fstatat (AT_FDCWD, ..., 0) does not work.  See
79893         <http://lists.gnu.org/r/bug-tar/2011-09/msg00015.html>.
79894         * lib/fstatat.c (FSTATAT_AT_FDCWD_0_BROKEN)
79895         (LSTAT_FOLLOWS_SLASHED_SYMLINK): Default to 0.
79896         (rpl_fstatat): Adjust so that it works around either (or both)
79897         bugs if present.
79898         * m4/openat.m4 (gl_FUNC_FSTATAT): Test for this fstatat bug.
79900 2011-09-03  Karl Berry  <karl@gnu.org>
79902         * doc/regex.texi (Character Class Operators): Avoid literal ":"
79903         in index entries.
79905 2011-09-02  Bruno Haible  <bruno@clisp.org>
79907         Allow the user to override the choice of AR, ARFLAGS, RANLIB.
79908         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): Don't override the given
79909         values of AR, ARFLAGS, RANLIB.
79910         Reported by John W. Eaton <jwe@gnu.org> for Octave.
79912 2011-09-02  Bruno Haible  <bruno@clisp.org>
79914         Find 'ar' program that fits with --host argument.
79915         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): Use AC_CHECK_TOOL.
79917 2011-09-02  Bruno Haible  <bruno@clisp.org>
79919         tests: init.sh: Support any non-GNU diff.
79920         * tests/init.sh (compare): If "diff -c" is supported but "diff -u" is
79921         not, use "diff -c". Useful on AIX 6.1, HP-UX 11.31, OSF/1 5.1,
79922         Solaris 8.
79924 2011-09-02  Bruno Haible  <bruno@clisp.org>
79926         tests: init.sh: work also with any non-GNU diff that supports -u
79927         * tests/init.sh: Relax check for diff -u support.
79928         Rather than checking for GNU diff via --version, simply check
79929         for support for -u itself.  Useful at least on OpenBSD 4.9,
79930         AIX 7.1, IRIX 6.5, and Solaris 10.
79932 2011-09-01  Bruno Haible  <bruno@clisp.org>
79934         strtoimax, strtoumax: Document problem on HP-UX 11.
79935         * doc/posix-functions/strtoimax.texi: Mention HP-UX 11.11 problem.
79936         * doc/posix-functions/strtoumax.texi: Likewise.
79938 2011-09-01  Bruno Haible  <bruno@clisp.org>
79940         strtoumax: Avoid link error on OSF/1 with DTK cc.
79941         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Always test whether strtoumax is
79942         defined as a function.
79943         * modules/strtoumax (Depends-on, configure.ac): Test only whether
79944         strtoumax is defined, not whether it is declared.
79946 2011-09-01  Bruno Haible  <bruno@clisp.org>
79948         strtoimax: Avoid link error on OSF/1 with DTK cc.
79949         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Always test whether strtoimax is
79950         defined as a function.
79951         * modules/strtoimax (Depends-on, configure.ac): Test only whether
79952         strtoimax is defined, not whether it is declared.
79954 2011-09-01  Bruno Haible  <bruno@clisp.org>
79956         imaxdiv: Avoid link error on OSF/1 with DTK cc.
79957         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Also test whether imaxdiv is defined
79958         as a function.
79959         * modules/imaxdiv (configure.ac): Test whether imaxdiv is defined, not
79960         whether it is declared.
79962 2011-09-01  Bruno Haible  <bruno@clisp.org>
79964         imaxabs: Avoid link error on OSF/1 with DTK cc.
79965         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Also test whether imaxabs is defined
79966         as a function.
79967         * modules/imaxabs (configure.ac): Test whether imaxabs is defined, not
79968         whether it is declared.
79970 2011-09-01  Bruno Haible  <bruno@clisp.org>
79972         Tests for module 'strtoumax'.
79973         * modules/strtoumax-tests: New file.
79974         * tests/test-strtoumax.c: New file.
79976         Tests for module 'strtoimax'.
79977         * modules/strtoimax-tests: New file.
79978         * tests/test-strtoimax.c: New file.
79980         Tests for module 'imaxdiv'.
79981         * modules/imaxdiv-tests: New file.
79982         * tests/test-imaxdiv.c: New file.
79984         Tests for module 'imaxabs'.
79985         * modules/imaxabs-tests: New file.
79986         * tests/test-imaxabs.c: New file.
79988 2011-09-01  Bruno Haible  <bruno@clisp.org>
79990         pthread: Determine $(LIB_PTHREAD) correctly on IRIX 6.5.
79991         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for pthread_join, not
79992         pthread_create.
79994 2011-09-01  Paul Eggert  <eggert@cs.ucla.edu>
79996         openat: work around AIX 7.1 fstatat issue
79997         This should fix the problem that was not properly fixed
79998         in the previous change, dated 2011-08-30.
79999         * lib/fstatat.c: Include <sys/stat.h> twice, the first with
80000         __need_system_stat_h defined.
80001         (orig_fstatat) [HAVE_FSTATAT]: New function.
80002         (rpl_fstatat): Go back to the old way of doing things,
80003         except call orig_fstatat instead of fstatat.
80004         * m4/openat.m4 (gl_FUNC_FSTATAT): Remove unnecessary check for openat.
80005         Remove unnecessary check whether fstatat fills in st_size etc.
80007 2011-09-01  Bruno Haible  <bruno@clisp.org>
80009         sys_select: Avoid a syntax error regarding timespec_t on IRIX 6.5.
80010         * lib/sys_select.in.h [__sgi]: When included from <sys/bsd_types.h>,
80011         just include the system's header.
80013 2011-08-31  Jim Meyering  <meyering@redhat.com>
80015         tests: avoid spurious assertion failure in test-float.c on ppc64
80016         * tests/test-float.c (test_long_double): Comment out an assertion,
80017         LDBL_MIN_EXP <= DBL_MIN_EXP, that is failing at least on PowerPC-64
80018         with gcc-4.4.4.
80020         maint: indent with spaces, not TABs
80021         I need to get in the habit of running gnulib's "make check".
80022         Both of these would have been caught.
80023         * m4/largefile.m4: Indent with spaces, not TABs.
80024         * lib/parse-datetime.y (iso_8601_time): Likewise.
80025         Spotted by Pádraig Brady.
80027         test-parse-datetime.c: accommodate a relatively strict gcc warning
80028         * tests/test-parse-datetime.c (gmt_offset): Declare function "static",
80029         to avoid a warning from gcc's -Werror=missing-declarations.
80030         Insert a few spaces-before-funcall-parenthesis.
80032 2011-08-17  J.T. Conklin  <jtc@acorntoolworks.com>
80034         parse-datetime: accept ISO 8601 date and time rep with "T" separator
80035         The parser now accepts ISO 8601 date-time strings with "T" as the
80036         separator.  It has long parsed dates like "2004-02-29 16:21:42"
80037         with a space between the date and time strings.  Now it also parses
80038         "2004-02-29T16:21:42" and fractional-second and time-zone-annotated
80039         variants like "2004-02-29T16:21:42.333-07:00"
80040         * lib/parse-datetime.y: Parse ISO 8601 extended date and time
80041         of day representation using the 'T' separator character.
80042         * doc/parse-datetime.texi (General date syntax): replace use of
80043         deprecated --iso-8601 option with --rfc-3339 in example of date
80044         command output formats that can be parsed.
80045         * tests/test-parse-datetime.c (tm_diff): New function, taken from
80046         lib/parse-datetime.y.
80047         (gmt_offset): New function.
80048         (main): Add additional test cases to validate ISO8601 extended
80049         date and time of day parsing.
80051 2011-08-31  Bruno Haible  <bruno@clisp.org>
80053         freopen: Documentation.
80054         * doc/posix-functions/freopen.texi: Document the bug with the NULL file
80055         name.
80056         Reported by Claudio Bley <claudio.bley@gmail.com>.
80058 2011-08-31  Claudio Bley  <claudio.bley@gmail.com>  (tiny change)
80060         freopen: Don't crash if the filename argument is NULL.
80061         * lib/freopen.c (rpl_freopen): Don't compare the filename if it is
80062         NULL.
80064 2011-08-30  Paul Eggert  <eggert@cs.ucla.edu>
80066         openat: work around AIX 7.1 fstatat bug
80067         Problem reported by Kevin Brott for GNU tar, in the thread containing
80068         <http://lists.gnu.org/r/bug-tar/2011-08/msg00015.html>.
80069         * lib/fstatat.c (rpl_fstatat): Do not invoke underlying fstatat if
80070         FSTATAT_ST_SIZE_ETC_BROKEN.
80071         (fstatat) [FSTATAT_ST_SIZE_ETC_BROKEN && HAVE_FSTATAT]: #define to
80072         rpl_fstatat.
80073         * m4/openat.m4 (gl_FUNC_FSTATAT): New macro, with the fstatat-relevant
80074         part of gl_FUNC_OPENAT.  Also, check for the AIX 7.1 bug, and use
80075         AC_CHECK_FUNCS_ONCE for fstatat.
80076         (gl_FUNC_OPENAT): Use it.  Use AC_CHECK_FUNCS_ONCE for
80077         fchmodat, mkdirat, openat and unlinkat.
80079 2011-08-30  Bruno Haible  <bruno@clisp.org>
80081         Avoid endless recursions if config.h includes some header files.
80082         * lib/fopen.c (__need_FILE): Define already before including config.h.
80083         * lib/freopen.c (__need_FILE): Likewise.
80084         * lib/open.c (__need_system_fcntl_h): Likewise.
80085         * lib/stat.c (__need_system_sys_stat_h): Likewise.
80086         * lib/lstat.c (__need_system_sys_stat_h): Likewise.
80087         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
80089 2011-08-25  Karl Berry  <karl@gnu.org>
80091         * config/srclist.txt (ylwrap): new try.
80092         * build-aux/ylwrap: new file.
80094 2011-08-23  Bruno Haible  <bruno@clisp.org>
80096         tmpdir: Use a good default directory on native Windows.
80097         * lib/tmpdir.c: Include <windows.h>, pathmax.h.
80098         (P_tmpdir): Default to _P_tmpdir on native Windows.
80099         (path_search): On native Windows, try the value returned by GetTempPath
80100         before trying P_tmpdir.
80101         * modules/tmpdir (Depends-on): Add pathmax.
80102         Suggested by John Darrington <john@darrington.wattle.id.au>.
80104 2011-08-20  Reuben Thomas  <rrt@sc3d.org>
80106         doc: fix typo in README-release
80107         * top/README-release: Capitalize first word of a sentence.
80109 2011-08-19  Jim Meyering  <meyering@redhat.com>
80111         fts: do not exhaust memory when processing million-entry directories
80112         Before this change, traversing (via rm -rf, find, du, etc.) an N-entry
80113         directory would require about 256*N bytes of memory.  Thus, it was
80114         easy to construct a directory too large to be processed by any of
80115         those tools.  With this change, fts' maximum memory utilization is
80116         now limited to around 30MB.
80117         * lib/fts.c (FTS_MAX_READDIR_ENTRIES): Define.
80118         (fts_read): When we've processed the final entry (i.e., when
80119         ->fts_link is NULL) and fts_dirp is non-NULL, call fts_build
80120         using the parent entry to read any remaining entries.  Dispatch
80121         depending on what fts_build returns:
80122         - NULL+stop, aka failure: stop
80123         - NULL otherwise: move up in the dir hierarchy
80124         - non-NULL: handle this new entry
80125         (fts_build): Declare and use new local, continue_readdir.
80126         Prepare to be called from fts_read, when the entries
80127         from a partially-read directory have just been exhausted.
80128         In that case, we'll skip the opendir and instead use the parent's
80129         fts_dirp and derive dir_fd from that.
80130         Finally, in the readdir loop, if we read max_entries entries,
80131         exit the loop ensuring *not* to call closedir.  This is required
80132         so that fts_dirp can be reused on a subsequent call.
80133         Prompted by Ben England's report of memory exhaustion in find
80134         and rm -rf vs. NFS: https://bugzilla.redhat.com/719749.
80136         maint: fts: move decl of `dp' down into while loop; split a long line
80137         * lib/fts.c (fts_build): No semantic change.
80139         fts: add/use new struct member, fts_dirp
80140         We are about to use this to manage any directory with
80141         too many entries to read all of them into memory at once.
80142         To do that, we'll need to save the DIR* pointer in each
80143         affected FTSENT struct.
80144         * lib/fts_.h: Include <dirent.h>.
80145         (struct FTSENT) [fts_dirp]: New member.
80146         * lib/fts.c (closedir_and_clear): Define.
80147         Use it in place of closedir so that we are sure to
80148         clear the new fts_dirp member when done with it.
80149         (fts_alloc): Initialize the new member.
80150         (fts_lfree): Free, if needed.
80152         maint: fts: give __opendir2 a new parameter and rename
80153         * lib/fts.c (__opendir2): Give it a new parameter, Pdir_fd, rather
80154         than surreptitiously using sole caller's "dir_fd".
80155         (fts_opendir): Rename from __opendir2.
80157         maint: fts.c: remove __opendir2's now-unused parameter, oflag
80158         * lib/fts.c (__opendir2): Remove unused parameter, oflag.
80160         maint: fts.c: correct off-by-one indentation
80161         * lib/fts.c (fts_build): Correct indentation, change style
80162         of a couple of block comments, and bracing style.
80164         maint: fts.c: move __opendir2 #define "up" out of function body
80165         * lib/fts.c (__opendir2): Move "up".  No semantic change.
80167         maint: fts.c: remove #if-0'd FTS_WHITEOUT code
80168         * lib/fts.c: Remove #if-0'd FTS_WHITEOUT code.  It's been #if-0'd
80169         out for a long time and besides was useful only on BSD systems.
80171 2011-08-18  Paul Eggert  <eggert@cs.ucla.edu>
80173         regex: port to Stratus OpenVOS
80174         * lib/regex_internal.h (internal_function) [!_LIBC]: Simply
80175         define to empty, rather than attempting nonportable optimizations.
80176         Problem reported by Paul Green in:
80177         http://lists.gnu.org/r/bug-diffutils/2011-08/msg00047.html
80178         and fix suggested by Eric Blake in:
80179         http://lists.gnu.org/r/bug-gnulib/2011-08/msg00143.html
80181 2011-08-17  Eric Blake  <eblake@redhat.com>
80183         getcwd: fix test failures on mingw
80184         * lib/getcwd.c (__getcwd): Early exit for ERANGE.
80185         * tests/test-getcwd.c (test_abort_bug, test_long_name): Don't fail
80186         test if long directory cannot be created, and allow mingw errno.
80188         getcwd-lgpl: fix m4 to match relaxed test for BSD
80189         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Relax probe.
80190         (gl_FUNC_GETCWD_SIGNATURE): New macro.
80191         (gl_FUNC_GETCWD_LGPL, gl_FUNC_GETCWD): Use it.
80192         * doc/posix-functions/getcwd.texi (getcwd): Tweak mentions of
80193         signature problem.
80195         getcwd: fix compilation on mingw64
80196         * lib/unistd.in.h (includes) [mingw]: Include <direct.h> for
80197         getcwd.
80198         Reported by Marc-André Lureau.
80200         pipe2: silence compiler warning
80201         * lib/pipe2.c (pipe2): Hide label if it is not used.
80203 2011-08-15  Ben Pfaff  <blp@cs.stanford.edu>
80205         relocatable-prog: fix link error
80206         * modules/relocatable-prog (configure.ac) [RELOCATABLE]: Also
80207         invoke AC_LIBOBJ([relocatable]).  This invocation was previously
80208         in the gl_RELOCATABLE_LIBRARY macro.  That invocation was moved
80209         into modules/relocatable-lib without noticing that
80210         modules/relocatable-prog also invokes gl_RELOCATABLE_LIBRARY and
80211         also needs to build relocatable.c.
80213 2011-08-12  Paul Eggert  <eggert@cs.ucla.edu>
80215         getaddrinfo: fix sh typo in gai_strerrorA decl checking
80216         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix typo in the generated
80217         shell code: it contained a 'break' that was not in a loop.
80218         Apparently the macro assumed that AC_CHECK_DECLS is implemenented
80219         via a shell-language loop; this may have been true in old Autoconf
80220         versions, but it's not true in Autoconf 2.68.  I found this bug
80221         when testing coreutils git on Solaris 8, whose shell complains
80222         about the syntax error.
80224 2011-08-12  Simon Josefsson  <simon@josefsson.org>
80226         * lib/base64.c: Fix comment to reference RFC 4648.
80227         Suggested by Bruno Haible <bruno@clisp.org> and Gijs van Tulder
80228         <gvtulder@gmail.com>.
80230 2011-08-11  Paul Eggert  <eggert@cs.ucla.edu>
80232         * build-aux/bootstrap (slurp): Remove obsolescent gettext.m4 patch.
80234         po/Makefile.in.in: fix make -q problem
80235         * build-aux/po/Makefile.in.in (check-macro-version): Remove this
80236         rule, since there's no file named 'check-macro-version' and its
80237         use as a file breaks make -q.
80238         (all): Don't depend on check-macro-version.
80239         (CHECK_MACRO_VERSION): New macro.
80240         (stamp-po): Use it.
80242         configmake: fix make -q problem
80243         * modules/configmake (configmake.h): Update configmake.h's time stamp
80244         even if the file does not change.  Otherwise, 'make -q' fails.
80245         Problem reported by Simon Josefsson in
80246         <http://lists.gnu.org/r/bug-gnulib/2011-08/msg00088.html>.
80248 2011-08-11  Jim Meyering  <meyering@redhat.com>
80250         git-version-gen: correct the advice in a comment
80251         * build-aux/git-version-gen: Correct comment.
80252         Don't recommend to list .tarball-version in .gitignore.
80254 2011-08-10  Paul Eggert  <eggert@cs.ucla.edu>
80256         base64: fix off-by-one buffer size bug
80257         Problem and (trivial) fix reported by Gijs van Tulder in
80258         <http://lists.gnu.org/r/bug-gnulib/2011-08/msg00083.html>.
80259         * lib/base64.c (base64_decode_alloc_ctx): Allocate one more byte.
80260         * tests/test-base64.c (main): Catch the bug.
80262 2011-08-10  Eric Blake  <eblake@redhat.com>
80264         closein: correct comments
80265         * lib/closein.c (close_stdin): Improve comments.
80267 2011-08-09  Bruno Haible  <bruno@clisp.org>
80269         More tests for 'fseeko'.
80270         * tests/test-fseeko3.c: New file, from Eric Blake.
80271         * tests/test-fseeko3.sh: New file.
80272         * modules/fseeko-tests (Files): Add them.
80273         (TESTS): Add test-fseeko3.sh.
80274         (check_PROGRAMS): Add test-fseeko3.
80276 2011-08-09  Eric Blake  <eblake@redhat.com>
80278         fseeko: remove unneeded hack
80279         * lib/fseeko.c (fseeko): Don't special-case SEEK_END.
80281         fseeko: fix bug on glibc
80282         * lib/fseeko.c (fseeko): Set stream offset to match fd offset.
80283         Reported by John W. Eaton.
80285 2011-08-08  Bruno Haible  <bruno@clisp.org>
80287         unictype/base: Fix interoperability with preinstalled libunistring.
80288         * modules/unictype/base (configure.ac): Bump minimum version to 0.9.4.
80289         Reported by Simon Josefsson.
80291 2011-08-08  Bruno Haible  <bruno@clisp.org>
80293         iswblank: Detect declaration correctly.
80294         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Use correct headers in
80295         AC_CHECK_DECLS invocation.
80297 2011-08-08  Bruno Haible  <bruno@clisp.org>
80299         tcgetsid: Detect declaration correctly.
80300         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Use correct headers in
80301         AC_CHECK_DECLS invocation.
80302         Reported by Simon Josefsson.
80304 2011-08-08  Eric Blake  <eblake@redhat.com>
80306         largefile: fix typo that regressed large file support
80307         * modules/largefile (configure.ac-early): Fix section name.
80309 2011-08-06  Karl Berry  <karl@gnu.org>
80311         * MODULES.html.sh (func_all_files): _Noreturn is no longer
80312         a separate module.
80314 2011-08-05  Simon Josefsson  <simon@josefsson.org>
80316         openat: Fix warnings and commens when building unlinkat.c on Hurd.
80317         * lib/unlinkat.c: Mention Hurd in comments.  Include stdlib.h to
80318         get prototype for free.
80320 2011-08-04  Bruno Haible  <bruno@clisp.org>
80322         Tests for module 'pathmax'.
80323         * modules/pathmax-tests: New file.
80324         * tests/test-pathmax.c: New file.
80326         canonicalize-lgpl: Support larger filenames on the Hurd.
80327         * lib/canonicalize-lgpl.c (__realpath): Bump path_max fallback to 8192.
80328         Reported by Paul Eggert.
80330         pathmax: Leave PATH_MAX undefined on the Hurd, and a constant otherwise.
80331         * lib/pathmax.h (PATH_MAX): Leave it undefined on GNU/Hurd.
80332         * lib/chdir-long.h: Include pathmax.h.
80333         * lib/clean-temp.c (PATH_MAX): Remove code that is done by pathmax.h.
80334         * lib/getcwd.c: Include pathmax.h instead of <limits.h>.
80335         (PATH_MAX): Remove code that is done by pathmax.h.
80336         * lib/canonicalize.c (PATH_MAX): Provide a fallback value.
80337         * lib/tmpfile.c: Add a comment.
80338         * m4/pathmax.m4 (gl_PATHMAX): Don't test for pathconf.
80339         * modules/chdir-long (Depends-on): Add pathmax.
80340         * modules/getcwd (Depends-on): Add pathmax.
80341         * tests/test-getcwd.c (test_abort_bug): Avoid syntax error when PATH_MAX
80342         is not defined.
80343         * doc/posix-headers/limits.texi: Mention the pathmax module.
80344         * NEWS: Mention the change.
80346 2011-08-02  Bruno Haible  <bruno@clisp.org>
80348         pthread_sigmask: Actually use results of gl_THREADLIB.
80349         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test and require
80350         gl_THREADLIB, not gl_[]THREADLIB.
80351         Reported by Eric Blake.
80353 2011-08-02  Jim Meyering  <meyering@redhat.com>
80355         maint.mk: relax the default _gl_TS_function_match regexp
80356         * top/maint.mk (_gl_TS_function_match): Don't require at least one
80357         space between function name and "(" in an "extern" declaration.
80358         That would fail to match a decl with no space there: extern void foo();
80360 2011-07-31  Iain Nicol  <iain@thenicols.net>
80362         git-version-gen: document that EXTRA_DIST must include .version
80363         * build-aux/git-version-gen: In the how-to-use comment, document
80364         that EXTRA_DIST must include .version.  Otherwise, "make distcheck"
80365         will fail when run from an unpacked distribution tarball.
80367 2011-08-01  Bruno Haible  <bruno@clisp.org>
80369         wctype-h: Fix last change.
80370         * m4/wctype_h.m4 (gl_WCTYPE_H): If towlower is defined, set
80371         REPLACE_TOWLOWER to 0.
80372         Reported by Sam Steingold <sds@gnu.org>.
80374 2011-07-31  Bruno Haible  <bruno@clisp.org>
80376         frexpl: Update autoconf test.
80377         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Update overrides of <float.h>,
80378         according to changes of 2011-06-20.
80380 2011-07-31  Bruno Haible  <bruno@clisp.org>
80382         sys_utsname: Add support for Minix.
80383         * lib/sys_utsname.in.h [Minix]: Include <stddef.h> before
80384         <sys/utsname.h>.
80385         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
80386         * doc/posix-headers/sys_utsname.texi: Document the Minix problem.
80388 2011-07-31  Bruno Haible  <bruno@clisp.org>
80390         strings: Add support for Minix.
80391         * lib/strings.in.h [Minix]: Include <sys/types.h> before <strings.h>.
80392         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Likewise.
80393         * doc/posix-headers/strings.texi: Document the Minix problem.
80395 2011-07-31  Bruno Haible  <bruno@clisp.org>
80397         wctype-h: Add support for Minix.
80398         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether towlower is declared. Set
80399         REPLACE_TOWLOWER.
80400         * modules/wctype-h (Makefile.am): Substitute REPLACE_TOWLOWER.
80401         * lib/wctype.in.h (towlower, towupper): Test REPLACE_TOWLOWER, not
80402         REPLACE_ISWCNTRL.
80404 2011-07-31  Paul Eggert  <eggert@cs.ucla.edu>
80406         * lib/xalloc.h (DEFAULT_MXFAST): Track 64-bit glibc.
80407         This is a performance improvement for 64-bit hosts: it causes the
80408         value of DEFAULT_MXFAST to track what's in glibc on such hosts.
80410 2011-07-31  Bruno Haible  <bruno@clisp.org>
80412         stdioext: Add support for Minix.
80413         * lib/fbufmode.c (fbufmode) [__minix]: Add conditional code.
80414         * lib/fpurge.c (fpurge): Likewise.
80415         * lib/freadahead.c (freadahead): Likewise.
80416         * lib/freadable.c (freadable): Likewise.
80417         * lib/freading.c (freading): Likewise.
80418         * lib/freadptr.c (freadptr): Likewise.
80419         * lib/freadseek.c (freadptrinc): Likewise.
80420         * lib/fseeko.c (rpl_fseeko): Likewise.
80421         * lib/fseterr.c (fseterr): Likewise.
80422         * lib/fwritable.c (fwritable): Likewise.
80423         * lib/fwriting.c (fwriting): Likewise.
80424         * lib/fflush.c (clear_ungetc_buffer): Update comment.
80425         * m4/fpending.m4 (gl_PREREQ_FPENDING): Add a variant for Minix.
80427 2011-07-31  Bruno Haible  <bruno@clisp.org>
80429         errno: Port to Minix.
80430         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Test also whether ENETRESET and
80431         ECONNABORTED are defined.
80432         * lib/errno.in.h (ENETRESET, GNULIB_defined_ENETRESET, ECONNABORTED,
80433         GNULIB_defined_ECONNABORTED): New macros.
80434         * lib/strerror-override.h (strerror_override): Test also
80435         GNULIB_defined_ENETRESET, GNULIB_defined_ECONNABORTED.
80436         * lib/strerror-override.c (strerror_override): Handle also ENETRESET,
80437         ECONNABORTED.
80438         * doc/posix-headers/errno.texi: Mention the Minix problem.
80440 2011-07-31  Bruno Haible  <bruno@clisp.org>
80442         Work around declaration collisions on Minix.
80443         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): If mbsinit is declared but not
80444         defined, set REPLACE_MBSINIT.
80445         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): If mbrtowc is declared but not
80446         defined, set REPLACE_MBRTOWC.
80447         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): If mbrlen is declared but not defined,
80448         set REPLACE_MBRLEN.
80449         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): If mbsrtowcs is declared but not
80450         defined, set REPLACE_MBSRTOWCS.
80451         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): If wcrtomb is declared but not
80452         defined, set REPLACE_WCRTOMB.
80453         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): If wcsrtombs is declared but not
80454         defined, set REPLACE_WCSRTOMBS.
80456 2011-07-31  Bruno Haible  <bruno@clisp.org>
80458         Add support for Minix with ACK compiler.
80459         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): New macro.
80460         * gnulib-tool (func_import, func_create_testdir): Emit invocation of
80461         gl_PROG_AR_RANLIB instead of AC_PROG_RANLIB.
80463 2011-07-31  Bruno Haible  <bruno@clisp.org>
80465         Documentation about Minix.
80466         * doc/posix-headers/*.texi: Add info about Minix 3.1.8.
80467         * doc/glibc-headers/*.texi: Likewise.
80468         * doc/posix-functions/*.texi: Likewise.
80469         * doc/glibc-functions/*.texi: Likewise.
80471 2011-07-31  Bruno Haible  <bruno@clisp.org>
80473         snippet/warn-on-use: Fix indentation.
80474         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Fix indentation.
80476 2011-07-25  Jim Meyering  <meyering@redhat.com>
80478         tests: test-update-copyright.sh: remove unnecessary "rm" commands
80479         * tests/test-update-copyright.sh: Remove unused rm -f $TMP.*.bak
80480         commands.
80482 2011-07-27  Jim Meyering  <meyering@redhat.com>
80484         maint.mk: avoid sc_prohibit_always-defined_macros failure in coreutils
80485         * top/maint.mk (gl_extract_significant_defines_): Now that
80486         SA_RESETHAND and SA_RESTART are #defined (albeit conditionally) in
80487         gnulib/lib/signal.in.h, and now that we recommend to
80488         define-if-undefined those two symbols in application code,
80489         we must filter them out of the "significant" list.
80490         This avoids a "make syntax-check" failure in coreutils.
80492 2011-07-26  Eric Blake  <eblake@redhat.com>
80494         warnings: add comments about previous patch
80495         * m4/absolute-header.m4: Document AS_VAR_PUSHDEF limitation.
80496         * m4/include_next.m4: Likewise.
80497         * m4/warn-on-use.m4: Likewise.
80498         * m4/warnings.m4: Likewise, and simplify use.
80499         Suggested by Stefano Lattarini.
80501         include-next, warnings: support older autoconf
80502         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Use
80503         AS_VAR_PUSHDEF in a way that works with older autoconf.
80504         * m4/warnings.m4 (gl_WARN_ADD): Likewise.
80505         Reported by Daniel P. Berrange.
80507 2011-07-25  Bruno Haible  <bruno@clisp.org>
80509         fseek, ftell: Fix doc.
80510         * doc/posix-functions/fseek.texi: Reword statement about
80511         AC_SYS_LARGEFILE.
80512         * doc/posix-functions/ftell.texi: Likewise.
80514 2011-07-25  Paul Eggert  <eggert@cs.ucla.edu>
80515             Bruno Haible  <bruno@clisp.org>
80517         Add dependencies to the 'largefile' module.
80518         * modules/fopen (Depends-on): Add 'largefile'.
80519         * modules/freopen (Depends-on): Likewise.
80520         * modules/fseeko (Depends-on): Likewise.
80521         * modules/ftello (Depends-on): Likewise.
80522         * modules/glob (Depends-on): Likewise.
80523         * modules/lseek (Depends-on): Likewise.
80524         * modules/lstat (Depends-on): Likewise.
80525         * modules/mkostemp (Depends-on): Likewise.
80526         * modules/mkostemps (Depends-on): Likewise.
80527         * modules/mkstemp (Depends-on): Likewise.
80528         * modules/mkstemps (Depends-on): Likewise.
80529         * modules/open (Depends-on): Likewise.
80530         * modules/openat (Depends-on): Likewise.
80531         * modules/pread (Depends-on): Likewise.
80532         * modules/pwrite (Depends-on): Likewise.
80533         * modules/scandir (Depends-on): Likewise.
80534         * modules/stat (Depends-on): Likewise.
80535         * modules/tmpfile (Depends-on): Likewise.
80536         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Do not require AC_SYS_LARGEFILE,
80537         since the containing module now depends on the largefile module.
80538         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Likewise.
80539         * doc/posix-functions/fopen.texi: Mention that the problem of 32-bit
80540         off_t is fixed by gnulib.
80541         * doc/posix-functions/freopen.texi: Likewise.
80542         * doc/posix-functions/fseeko.texi: Likewise.
80543         * doc/posix-functions/fstatat.texi: Likewise.
80544         * doc/posix-functions/ftello.texi: Likewise.
80545         * doc/posix-functions/glob.texi: Likewise.
80546         * doc/posix-functions/lseek.texi: Likewise.
80547         * doc/posix-functions/lstat.texi: Likewise.
80548         * doc/posix-functions/mkstemp.texi: Likewise.
80549         * doc/posix-functions/open.texi: Likewise.
80550         * doc/posix-functions/openat.texi: Likewise.
80551         * doc/posix-functions/pread.texi: Likewise.
80552         * doc/posix-functions/pwrite.texi: Likewise.
80553         * doc/posix-functions/scandir.texi: Likewise.
80554         * doc/posix-functions/stat.texi: Likewise.
80555         * doc/posix-functions/tmpfile.texi: Likewise.
80556         * doc/glibc-functions/mkostemp.texi: Likewise.
80557         * doc/glibc-functions/mkostemps.texi: Likewise.
80558         * doc/glibc-functions/mkstemps.texi: Likewise.
80560 2011-07-25  Bruno Haible  <bruno@clisp.org>
80562         fcntl: Move AC_LIBOBJ invocation to module description.
80563         * m4/fcntl.m4 (gl_REPLACE_FCNTL): Don't invoke AC_LIBOBJ.
80564         * modules/fcntl (configure.ac): Invoke AC_LIBOBJ.
80566         fcntl: Remove call-in from fchdir.m4.
80567         * m4/fcntl.m4 (gl_FUNC_FCNTL): Conditionally invoke gl_TEST_FCHDIR.
80568         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_FCNTL.
80570         dup3: Remove potential call-in from fchdir.m4.
80571         * m4/dup3.m4 (gl_FUNC_DUP3): Add comment about fchdir.
80572         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Remove comment about dup3.
80574         dup2: Move AC_LIBOBJ invocation to module description.
80575         * m4/dup2.m4 (gl_REPLACE_DUP2): Remove macro.
80576         (gl_FUNC_DUP2): Instead of gl_REPLACE_DUP2, just set REPLACE_DUP2 to 1.
80577         Don't invoke AC_LIBOBJ.
80578         * modules/dup2 (configure.ac): Invoke AC_LIBOBJ.
80580         dup2: Remove call-in from fchdir.m4.
80581         * m4/dup2.m4 (gl_FUNC_DUP2): Conditionally invoke gl_TEST_FCHDIR.
80582         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_DUP2.
80584         fclose: Move AC_LIBOBJ invocation to module description.
80585         * m4/fclose.m4 (gl_REPLACE_FCLOSE): Remove macro.
80586         (gl_FUNC_FCLOSE): Instead of gl_REPLACE_FCLOSE, just set REPLACE_FCLOSE
80587         to 1.
80588         * modules/fclose (configure.ac): Invoke AC_LIBOBJ.
80590         fclose: Remove call-in from close.m4.
80591         * m4/fclose.m4 (gl_FUNC_FCLOSE): Invoke gl_FUNC_CLOSE.
80592         * m4/close.m4 (gl_FUNC_CLOSE): Don't invoke gl_REPLACE_FCLOSE.
80594         close: Move AC_LIBOBJ invocation to module description.
80595         * m4/close.m4 (gl_REPLACE_CLOSE): Remove macro.
80596         (gl_FUNC_CLOSE): Instead of gl_REPLACE_CLOSE, just set REPLACE_CLOSE to
80597         1.
80598         * modules/close (configure.ac): Invoke AC_LIBOBJ.
80600         close: Remove call-in from fchdir.m4.
80601         * m4/close.m4 (gl_FUNC_CLOSE): Conditionally invoke gl_TEST_FCHDIR.
80602         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_CLOSE.
80604         open: Move AC_LIBOBJ invocation to module description.
80605         * m4/open.m4 (gl_REPLACE_OPEN): Remove macro.
80606         (gl_FUNC_OPEN): Instead of gl_REPLACE_OPEN, just set REPLACE_OPEN to 1.
80607         * modules/open (configure.ac): Invoke AC_LIBOBJ and gl_PREREQ_OPEN.
80609         open: Remove call-in from fchdir.m4.
80610         * m4/open.m4 (gl_FUNC_OPEN): Conditionally invoke gl_TEST_FCHDIR.
80611         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_OPEN.
80613         fchdir: Start to remove gl_REPLACE_* idiom.
80614         * m4/fchdir.m4 (gl_TEST_FCHDIR): New macro.
80615         (gl_FUNC_FCHDIR): Invoke it.
80617 2011-07-25  Paul Eggert  <eggert@cs.ucla.edu>
80619         * lib/ftell.c (ftell): Comment out cast.
80621         close: use gl_REPLACE_FCLOSE only if defined
80622         * m4/close.m4 (gl_REPLACE_CLOSE): Use gl_REPLACE_FCLOSE only if it
80623         is defined.  The close module doesn't depend on the fclose module
80624         any more, so gl_REPLACE_CLOSE's existence cannot be assumed.  See
80625         <http://lists.gnu.org/r/bug-gnulib/2011-07/msg00392.html>.
80626         I reproduced the problem with "./gnulib-tool --test close sys_socket".
80628 2011-07-24  Jim Meyering  <meyering@redhat.com>
80630         test-select.h: avoid warning when using gcc's -Wmissing-declarations
80631         * tests/test-select.h (test_function): Declare as "static".
80633 2011-07-24  Bruno Haible  <bruno@clisp.org>
80635         doc: Mention the effects of AC_SYS_LARGEFILE.
80636         * doc/posix-functions/aio_cancel.texi: Mention the effects of AC_SYS_LARGEFILE
80637         on this function.
80638         * doc/posix-functions/aio_error.texi: Likewise.
80639         * doc/posix-functions/aio_fsync.texi: Likewise.
80640         * doc/posix-functions/aio_read.texi: Likewise.
80641         * doc/posix-functions/aio_return.texi: Likewise.
80642         * doc/posix-functions/aio_suspend.texi: Likewise.
80643         * doc/posix-functions/aio_write.texi: Likewise.
80644         * doc/posix-functions/fgetpos.texi: Likewise.
80645         * doc/posix-functions/fopen.texi: Likewise.
80646         * doc/posix-functions/freopen.texi: Likewise.
80647         * doc/posix-functions/fsetpos.texi: Likewise.
80648         * doc/posix-functions/fstatvfs.texi: Likewise.
80649         * doc/posix-functions/ftruncate.texi: Likewise.
80650         * doc/posix-functions/ftw.texi: Likewise.
80651         * doc/posix-functions/getrlimit.texi: Likewise.
80652         * doc/posix-functions/glob.texi: Likewise.
80653         * doc/posix-functions/lio_listio.texi: Likewise.
80654         * doc/posix-functions/lockf.texi: Likewise.
80655         * doc/posix-functions/mkstemp.texi: Likewise.
80656         * doc/posix-functions/mmap.texi: Likewise.
80657         * doc/posix-functions/nftw.texi: Likewise.
80658         * doc/posix-functions/openat.texi: Likewise.
80659         * doc/posix-functions/opendir.texi: Likewise.
80660         * doc/posix-functions/posix_fadvise.texi: Likewise.
80661         * doc/posix-functions/posix_fallocate.texi: Likewise.
80662         * doc/posix-functions/pread.texi: Likewise.
80663         * doc/posix-functions/pwrite.texi: Likewise.
80664         * doc/posix-functions/readdir.texi: Likewise.
80665         * doc/posix-functions/readdir_r.texi: Likewise.
80666         * doc/posix-functions/rewinddir.texi: Likewise.
80667         * doc/posix-functions/scandir.texi: Likewise.
80668         * doc/posix-functions/seekdir.texi: Likewise.
80669         * doc/posix-functions/setrlimit.texi: Likewise.
80670         * doc/posix-functions/statvfs.texi: Likewise.
80671         * doc/posix-functions/telldir.texi: Likewise.
80672         * doc/posix-functions/tmpfile.texi: Likewise.
80673         * doc/posix-functions/truncate.texi: Likewise.
80674         * doc/glibc-functions/fallocate.texi: Likewise.
80675         * doc/glibc-functions/fstatfs.texi: Likewise.
80676         * doc/glibc-functions/fts_children.texi: Likewise.
80677         * doc/glibc-functions/fts_read.texi: Likewise.
80678         * doc/glibc-functions/getdirentries.texi: Likewise.
80679         * doc/glibc-functions/mkostemp.texi: Likewise.
80680         * doc/glibc-functions/mkostemps.texi: Likewise.
80681         * doc/glibc-functions/mkstemps.texi: Likewise.
80682         * doc/glibc-functions/preadv.texi: Likewise.
80683         * doc/glibc-functions/pwritev.texi: Likewise.
80684         * doc/glibc-functions/sendfile.texi: Likewise.
80685         * doc/glibc-functions/statfs.texi: Likewise.
80687 2011-07-24  Bruno Haible  <bruno@clisp.org>
80689         doc: Fix typo.
80690         * doc/posix-functions/fstat.texi: Talk about fstat, not stat.
80692 2011-07-24  Bruno Haible  <bruno@clisp.org>
80694         doc: Mention fsusage.
80695         * doc/posix-functions/statvfs.texi: Mention the fsusage module.
80697 2011-07-24  Bruno Haible  <bruno@clisp.org>
80699         doc: Mention new glibc headers and functions.
80700         * doc/glibc-headers/gshadow.texi: New file.
80701         * doc/glibc-functions/endsgent.texi: New file.
80702         * doc/glibc-functions/fgetsgent.texi: New file.
80703         * doc/glibc-functions/fgetsgent_r.texi: New file.
80704         * doc/glibc-functions/getsgent.texi: New file.
80705         * doc/glibc-functions/getsgent_r.texi: New file.
80706         * doc/glibc-functions/getsgnam.texi: New file.
80707         * doc/glibc-functions/getsgnam_r.texi: New file.
80708         * doc/glibc-functions/putsgent.texi: New file.
80709         * doc/glibc-functions/setsgent.texi: New file.
80710         * doc/glibc-functions/sgetsgent.texi: New file.
80711         * doc/glibc-functions/sgetsgent_r.texi: New file.
80712         * doc/glibc-functions/malloc_info.texi: New file.
80713         * doc/glibc-functions/preadv.texi: New file.
80714         * doc/glibc-functions/pwritev.texi: New file.
80715         * doc/glibc-functions/register_printf_modifier.texi: New file.
80716         * doc/glibc-functions/register_printf_specifier.texi: New file.
80717         * doc/glibc-functions/register_printf_type.texi: New file.
80718         * doc/glibc-functions/pthread_attr_getaffinity_np.texi: New file.
80719         * doc/glibc-functions/pthread_attr_setaffinity_np.texi: New file.
80720         * doc/glibc-functions/pthread_getaffinity_np.texi: New file.
80721         * doc/glibc-functions/pthread_getname_np.texi: New file.
80722         * doc/glibc-functions/pthread_mutex_consistent_np.texi: New file.
80723         * doc/glibc-functions/pthread_mutexattr_getrobust_np.texi: New file.
80724         * doc/glibc-functions/pthread_mutexattr_setrobust_np.texi: New file.
80725         * doc/glibc-functions/pthread_setaffinity_np.texi: New file.
80726         * doc/glibc-functions/pthread_setname_np.texi: New file.
80727         * doc/glibc-functions/pthread_sigqueue.texi: New file.
80728         * doc/glibc-functions/pthread_timedjoin_np.texi: New file.
80729         * doc/glibc-functions/pthread_tryjoin_np.texi: New file.
80730         * doc/glibc-functions/qsort_r.texi: New file.
80731         * doc/glibc-functions/quick_exit.texi: New file.
80732         * doc/glibc-functions/syncfs.texi: New file.
80733         * doc/gnulib.texi: Include them.
80734         (Glibc gshadow.h, Glibc sys/uio.h): New sections.
80735         * doc/posix-functions/psiginfo.texi: Fix info about glibc version.
80736         * doc/posix-functions/pthread_mutex_consistent.texi: Likewise.
80737         * doc/posix-functions/pthread_mutexattr_getrobust.texi: Likewise.
80738         * doc/posix-functions/pthread_mutexattr_setrobust.texi: Likewise.
80739         * doc/glibc-functions/execvpe.texi: Likewise.
80741 2011-07-24  Paul Eggert  <eggert@cs.ucla.edu>
80743         ftell: don't include <unistd.h>
80744         * lib/ftell.c: Don't include <unistd.h>.  <stdio.h> is now
80745         guaranteed to define off_t, and the ftell module depends on the
80746         stdio module.
80748         ftell: do not assume wraparound signed arithmetic
80749         * lib/ftell.c: Include <limits.h>.
80750         (ftell): Don't assume wraparound signed arithmetic.
80752 2011-07-24  Bruno Haible  <bruno@clisp.org>
80754         close: No longer depend on module 'fclose'.
80755         * modules/close (Depends-on): Remove fclose.
80756         * NEWS: Mention the change.
80757         Suggested by Sam Steingold <sds@gnu.org>.
80759 2011-07-24  Bruno Haible  <bruno@clisp.org>
80761         fsusage: Enable large volume support on AIX >= 5.2.
80762         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): If 'struct statvfs64' has a
80763         larger f_blocks field than 'struct statvfs', define STAT_STATVFS64
80764         instead of STAT_STATVFS.
80765         * lib/fsusage.c (get_fs_usage) [STAT_STATVFS64]: Use statvfs64.
80767         fsusage: Restore previous behaviour on AIX, Cygwin, Interix.
80768         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Enforce a 64-bit struct statvfs
80769         f_blocks field only on MacOS X.
80771         fsusage: Support large volumes on glibc/Hurd, HP-UX, Solaris, MacOS X.
80772         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Require AC_SYS_LARGEFILE.
80773         * modules/fsusage (Depends-on): Add largefile.
80775 2011-07-24  Paul Eggert  <eggert@cs.ucla.edu>
80777         * README: Modernize discussion of signed integers.
80778         Assuming overflow wraparound is no longer safe.
80779         Mention ones' complement and signed magnitude.
80781 2011-07-22  Bruno Haible  <bruno@clisp.org>
80783         select tests, pselect tests: Refactor.
80784         * tests/test-select.h: New file, extracted from tests/test-select.c.
80785         (select_fn): New type.
80786         (test, do_select, do_select_nowait, do_select_wait, test_tty,
80787         test_connect_first, test_accept_first, test_pair, test_socket_pair,
80788         test_pipe): Add my_select argument.
80789         (test_function): Renamed from main. Add my_select argument.
80790         * tests/test-select.c: Move most code to tests/test-select.h. Include
80791         test-select.h.
80792         * modules/select-tests (Files): Add tests/test-select.h.
80793         * tests/test-pselect.c: Include test-select.h instead of test-select.c.
80794         (my_select, main): New functions.
80795         * modules/pselect-tests (Files): Add tests/test-select.h,
80796         tests/macros.h, tests/signature.h.
80797         (Depends-on): Remove select-tests. Add dependencies of test-select.h.
80798         (configure.ac): Check for <sys/wait.h>.
80800 2011-07-22  Bruno Haible  <bruno@clisp.org>
80802         sys_select tests: Check the signature of FD_*.
80803         * tests/test-select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): Move
80804         signature tests from here...
80805         * tests/test-sys_select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): ... to
80806         here.
80807         * modules/sys_select-tests (Files): Add tests/signature.h.
80809 2011-07-22  Paul Eggert  <eggert@cs.ucla.edu>
80811         largefile: new module, replacing large-inode
80812         Pádraig Brady suggested this in <http://debbugs.gnu.org/9140#20>.
80813         * MODULES.html.sh: Add largefile, remove large-inode.
80814         * modules/largefile, m4/largefile.m4: New files.
80815         * modules/large-inode, m4/large-inode.m4: Remove.
80817         fsusage: port to MacOS X 10.7 with 4 TiB file systems
80818         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Reject statvfs
80819         implementations that use only 32 bits to count blocks.
80820         On typical hosts with 1024-byte blocks, this fails with file
80821         systems as small as 4 TiB.  Problem reported by Herb Wartens
80822         <http://debbugs.gnu.org/9140> and this should also fix a similar
80823         problem reported by Tim Spriggs <http://debbugs.gnu.org/7355>.
80825         large-inode: New module
80826         * MODULES.html.sh: Add it.
80827         * modules/large-inode, m4/large-inode.m4: New files.
80829         extensions: Enable extensions on MacOS X 10.5 and later.
80830         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define _DARWIN_C_SOURCE.
80832 2011-07-22  Kamil Dudka  <kdudka@redhat.com>
80834         file-has-acl: use acl_extended_file_nofollow if available
80835         * lib/acl-internal.h (HAVE_ACL_EXTENDED_FILE): New macro.
80836         (acl_extended_file): New macro.
80837         * lib/file-has-acl.c (file_has_acl): Use acl_extended_file_nofollow.
80838         * m4/acl.m4 (gl_FUNC_ACL): Check for acl_extended_file_nofollow.
80840 2011-07-21  Bruno Haible  <bruno@clisp.org>
80842         Declare system functions in a way that works with C++.
80843         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR) [C++]: In the test program,
80844         declare fdopendir as extern "C".
80845         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS) [C++]: In the test program,
80846         declare frexpl as extern "C".
80847         * m4/getaddrinfo.m4 (gl_GETADDRINFO) [C++]: In the test program,
80848         declare gai_strerror as extern "C".
80849         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME) [C++]: In the test
80850         programs, declare gai_strerror as extern "C".
80851         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R) [C++]: In the test program,
80852         declare getlogin_r as extern "C".
80853         * m4/ioctl.m4 (gl_FUNC_IOCTL) [C++]: In the test program, declare ioctl
80854         as extern "C".
80855         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS) [C++]: In the test program,
80856         declare ldexpl as extern "C".
80857         * m4/logb.m4 (gl_FUNC_LOGB) [C++]: In the test programs, declare logb
80858         as extern "C".
80859         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS) [C++]: In the test
80860         program, declare getmntinfo as extern "C".
80861         * m4/stpncpy.m4 (gl_FUNC_STPNCPY) [C++]: In the test program, declare
80862         stpncpy as extern "C".
80863         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS) [C++]: In the test
80864         program, declare __xpg_strerror_r as extern "C".
80865         * m4/strndup.m4 (gl_FUNC_STRNDUP) [C++]: In the test program, declare
80866         strndup as extern "C".
80867         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT) [C++]: In the test program,
80868         declare memset and bzero as extern "C".
80869         Reported by Sam Steingold <sds@gnu.org>.
80871 2011-07-12  Jim Meyering  <meyering@redhat.com>
80873         maint.mk: prohibit inclusion of "verify.h" without use
80874         * top/maint.mk (sc_prohibit_verify_without_use): New rule.
80876 2011-07-19  Pádraig Brady  <P@draigBrady.com>
80878         timer-time: A new module to check for timer_settime()
80879         * m4/timer_time.m4: Check for the posix function.
80880         * modules/timer-time: Add the new module.
80881         * MODULES.html.sh (Compat checks for POSIX:2008 functions):
80882         Mention it.
80884 2011-07-19  Paul Eggert  <eggert@cs.ucla.edu>
80885             Bruno Haible  <bruno@clisp.org>
80887         pthread_sigmask: assume POSIX threads if --avoid=threadlib
80888         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): If gl_THREADLIB is
80889         not defined, assume POSIX threads and look for pthread_sigmask in
80890         $LIBS, without changing $CPPFLAGS.
80892 2011-07-19  Bruno Haible  <bruno@clisp.org>
80894         strstr: Update cross-compilation guess.
80895         * m4/strstr.m4 (gl_FUNC_STRSTR): On glibc > 2.12 with x86 or x86_64
80896         CPUs, guess no, in view of glibc
80897         BZ #12100 <http://sourceware.org/bugzilla/show_bug.cgi?id=12100>.
80898         Suggested by Eric Blake. Reported by Reuben Thomas.
80900 2011-07-19  Pádraig Brady  <P@draigBrady.com>
80902         getopt-gnu: suppress core dumps from detection code
80903         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Use the nocrash module
80904         to suppress core dumps that may well occur on glibc systems.
80905         * modules/getopt-gnu: Depend on nocrash.
80907 2011-07-16  Paul Eggert  <eggert@cs.ucla.edu>
80909         pthread_sigmask: ensure usleep is declared
80910         * lib/pthread_sigmask.c [PTHREAD_SIGMASK_UNBLOCK_BUG]:
80911         Include <unistd.h>, to declare usleep.  Needed on Solaris 8,
80913 2011-07-15  Paul Eggert  <eggert@cs.ucla.edu>
80915         doc: Document NonStop portability issues.
80916         * doc/posix-functions/sigaction.texi (sigaction):
80917         * doc/posix-headers/signal.texi (signal.h):
80918         Document NonStop.  See Joachim Schmitz in
80919         http://lists.gnu.org/r/bug-coreutils/2011-07/msg00062.html
80921 2011-07-15  Bruno Haible  <bruno@clisp.org>
80923         ffsl, ffsll: Avoid unportable behaviour.
80924         * lib/ffsl.h (FUNC): Use 'unsigned int' instead of 'int'.
80926 2011-07-15  Bruno Haible  <bruno@clisp.org>
80928         ffs: More tests.
80929         * tests/test-ffs.c (NBITS): New macro.
80930         (main): Add more tests.
80931         * tests/test-ffsl.c (NBITS): New macro.
80932         (main): Add more tests.
80933         * tests/test-ffsll.c (NBITS): New macro.
80934         (main): Add more tests.
80936 2011-07-15  Eric Blake  <eblake@redhat.com>
80938         ffsl, ffsll: new modules
80939         * modules/ffsl: New file.
80940         * modules/ffsll: Likewise.
80941         * m4/ffsl.m4: Likewise.
80942         * m4/ffsll.m4: Likewise.
80943         * lib/ffsl.c: Likewise.
80944         * lib/ffsl.h: Likewise.
80945         * lib/ffsll.c: Likewise.
80946         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY)
80947         (gl_HEADER_STRING_H_DEFAULTS): Add defaults.
80948         * modules/string (Makefile.am): Substitute witnesses.
80949         * lib/strings.in.h (ffsl, ffsll): Declare.
80950         * modules/ffsl-tests: New test file.
80951         * modules/ffsll-tests: Likewise.
80952         * tests/test-ffsl.c: Likewise.
80953         * tests/test-ffsll.c: Likewise.
80954         * MODULES.html.sh (Integer arithmetic functions): Mention it.
80955         * doc/glibc-functions/ffsl.texi (ffsl): Likewise.
80956         * doc/glibc-functions/ffsll.texi (ffsll): Likewise.
80958         ffs: fix m4 prerequisite
80959         * m4/ffs.m4 (gl_FUNC_FFS): Require strings.h defaults.
80961         ffs: avoid undefined behavior
80962         * lib/ffs.c (ffs): Provide fallback for non-32-bit int.
80963         * tests/test-ffs.c (naive, main): Avoid signed shifts.
80964         Reported by Bruno Haible.
80966 2011-07-12  Bruno Haible  <bruno@clisp.org>
80968         pthread_sigmask: Rely on module 'threadlib'.
80969         * modules/pthread_sigmask (Depends-on): Add threadlib.
80970         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Assume gl_THREADLIB
80971         is defined.
80973 2011-07-12  Bruno Haible  <bruno@clisp.org>
80975         regex: Depend on module 'strcase'.
80976         * modules/regex (Depends-on): Add strcase, for strcasecmp().
80978 2011-07-12  Jim Meyering  <meyering@redhat.com>
80980         warn-on-use: fix typo in file name
80981         * modules/snippet/warn-on-use (Files): Correct file name:
80982         include /snippet/ component in "build-aux/snippet/warn-on-use.h".
80984 2011-07-12  Bruno Haible  <bruno@clisp.org>
80986         strings: Document module.
80987         * doc/posix-headers/strings.texi: Mention module 'strings'.
80989 2011-07-12  Bruno Haible  <bruno@clisp.org>
80991         Rename module '_Noreturn' to 'snippet/_Noreturn'.
80992         * modules/snippet/_Noreturn: Renamed from modules/_Noreturn.
80993         (Files, Makefile.am): Update.
80994         * build-aux/snippet/_Noreturn.h: Renamed from build-aux/_Noreturn.h.
80995         * modules/stdlib (Depends-on): Update.
80997 2011-07-12  Bruno Haible  <bruno@clisp.org>
80999         * NEWS: Mention the changes.
81001         Rename module 'warn-on-use' to 'snippet/warn-on-use'.
81002         * modules/snippet/warn-on-use: Renamed from modules/warn-on-use.
81003         (Files, Makefile.am): Update.
81004         * build-aux/snippet/warn-on-use.h: Renamed from build-aux/warn-on-use.h.
81005         * modules/arpa_inet (Depends-on): Update.
81006         * modules/ctype (Depends-on): Update.
81007         * modules/dirent (Depends-on): Update.
81008         * modules/fcntl-h (Depends-on): Update.
81009         * modules/glob (Depends-on): Update.
81010         * modules/iconv-h (Depends-on): Update.
81011         * modules/inttypes-incomplete (Depends-on): Update.
81012         * modules/langinfo (Depends-on): Update.
81013         * modules/locale (Depends-on): Update.
81014         * modules/math (Depends-on): Update.
81015         * modules/netdb (Depends-on): Update.
81016         * modules/poll-h (Depends-on): Update.
81017         * modules/pty (Depends-on): Update.
81018         * modules/search (Depends-on): Update.
81019         * modules/signal (Depends-on): Update.
81020         * modules/spawn (Depends-on): Update.
81021         * modules/stdio (Depends-on): Update.
81022         * modules/stdlib (Depends-on): Update.
81023         * modules/string (Depends-on): Update.
81024         * modules/strings (Depends-on): Update.
81025         * modules/sys_file (Depends-on): Update.
81026         * modules/sys_ioctl (Depends-on): Update.
81027         * modules/sys_select (Depends-on): Update.
81028         * modules/sys_socket (Depends-on): Update.
81029         * modules/sys_stat (Depends-on): Update.
81030         * modules/sys_time (Depends-on): Update.
81031         * modules/sys_times (Depends-on): Update.
81032         * modules/sys_utsname (Depends-on): Update.
81033         * modules/sys_wait (Depends-on): Update.
81034         * modules/termios (Depends-on): Update.
81035         * modules/time (Depends-on): Update.
81036         * modules/unistd (Depends-on): Update.
81037         * modules/wchar (Depends-on): Update.
81038         * modules/wctype-h (Depends-on): Update.
81039         * MODULES.html.sh (Support for building libraries and executables):
81040         Update.
81042         Rename module 'unused-parameter' to 'snippet/unused-parameter'.
81043         * modules/snippet/unused-parameter: Renamed from
81044         modules/unused-parameter.
81045         (Files, Makefile.am): Update.
81046         * build-aux/snippet/unused-parameter.h: Renamed from
81047         build-aux/unused-parameter.h.
81048         * modules/selinux-h (Depends-on): Update.
81049         * modules/unistr/base (Depends-on): Update.
81050         * MODULES.html.sh (Core language properties): Update.
81052         Rename module 'link-warning' to 'snippet/link-warning'.
81053         * modules/snippet/link-warning: Renamed from modules/link-warning.
81054         (Files, Makefile.am): Update.
81055         * build-aux/snippet/link-warning.h: Renamed from
81056         build-aux/link-warning.h.
81057         * MODULES.html.sh (Support for building libraries and executables):
81058         Update.
81060         Rename module 'c++defs' to 'snippet/c++defs'.
81061         * modules/snippet/c++defs: Renamed from modules/c++defs.
81062         (Files, Makefile.am): Update.
81063         * build-aux/snippet/c++defs.h: Renamed from build-aux/c++defs.h.
81064         * modules/arpa_inet (Depends-on): Update.
81065         * modules/ctype (Depends-on): Update.
81066         * modules/dirent (Depends-on): Update.
81067         * modules/fcntl-h (Depends-on): Update.
81068         * modules/glob (Depends-on): Update.
81069         * modules/iconv-h (Depends-on): Update.
81070         * modules/langinfo (Depends-on): Update.
81071         * modules/locale (Depends-on): Update.
81072         * modules/math (Depends-on): Update.
81073         * modules/netdb (Depends-on): Update.
81074         * modules/poll-h (Depends-on): Update.
81075         * modules/pty (Depends-on): Update.
81076         * modules/search (Depends-on): Update.
81077         * modules/signal (Depends-on): Update.
81078         * modules/spawn (Depends-on): Update.
81079         * modules/stdio (Depends-on): Update.
81080         * modules/stdlib (Depends-on): Update.
81081         * modules/string (Depends-on): Update.
81082         * modules/strings (Depends-on): Update.
81083         * modules/sys_ioctl (Depends-on): Update.
81084         * modules/sys_select (Depends-on): Update.
81085         * modules/sys_socket (Depends-on): Update.
81086         * modules/sys_stat (Depends-on): Update.
81087         * modules/sys_time (Depends-on): Update.
81088         * modules/sys_wait (Depends-on): Update.
81089         * modules/termios (Depends-on): Update.
81090         * modules/time (Depends-on): Update.
81091         * modules/unistd (Depends-on): Update.
81092         * modules/wchar (Depends-on): Update.
81093         * modules/wctype-h (Depends-on): Update.
81095         Rename module 'arg-nonnull' to 'snippet/arg-nonnull'.
81096         * modules/snippet/arg-nonnull: Renamed from modules/arg-nonnull.
81097         (Files, Makefile.am): Update.
81098         * build-aux/snippet/arg-nonnull.h: Renamed from build-aux/arg-nonnull.h.
81099         * modules/argv-iter (Depends-on): Update.
81100         * modules/arpa_inet (Depends-on): Update.
81101         * modules/dirent (Depends-on): Update.
81102         * modules/fcntl-h (Depends-on): Update.
81103         * modules/fnmatch (Depends-on): Update.
81104         * modules/getopt-posix (Depends-on): Update.
81105         * modules/glob (Depends-on): Update.
81106         * modules/iconv-h (Depends-on): Update.
81107         * modules/inttypes-incomplete (Depends-on): Update.
81108         * modules/locale (Depends-on): Update.
81109         * modules/math (Depends-on): Update.
81110         * modules/netdb (Depends-on): Update.
81111         * modules/search (Depends-on): Update.
81112         * modules/signal (Depends-on): Update.
81113         * modules/spawn (Depends-on): Update.
81114         * modules/stdio (Depends-on): Update.
81115         * modules/stdlib (Depends-on): Update.
81116         * modules/string (Depends-on): Update.
81117         * modules/strings (Depends-on): Update.
81118         * modules/sys_socket (Depends-on): Update.
81119         * modules/sys_stat (Depends-on): Update.
81120         * modules/sys_time (Depends-on): Update.
81121         * modules/sys_times (Depends-on): Update.
81122         * modules/sys_utsname (Depends-on): Update.
81123         * modules/time (Depends-on): Update.
81124         * modules/unistd (Depends-on): Update.
81125         * modules/wchar (Depends-on): Update.
81126         * MODULES.html.sh (Support for building libraries and executables):
81127         Update.
81129 2011-07-12  Paul Eggert  <eggert@cs.ucla.edu>
81131         Improvements on _Noreturn and related modules.
81133         modules/_Exit-tests: test _Noreturn too
81134         * tests/test-_Exit.c (MTA, Charlie): New functions, taken from the
81135         old tests/test-stdnoreturn.c.  This tests the _Noreturn keyword a bit.
81136         (main): Use them.
81138         stdnoreturn, stdnoreturn-tests: remove modules
81139         They're not needed here and a bit premature for use elsewhere.  See
81140         <http://lists.gnu.org/r/bug-gnulib/2011-07/msg00209.html>.
81141         * m4/stdnoreturn.m4, modules/stdnoreturn, modules/stdnoreturn-tests:
81142         * tests/test-stdnoreturn.c: Remove files.
81143         * MODULES.html.sh (_Noreturn <stdnoreturn.h>): Remove section.
81144         * lib/openat.h, lib/sigpipe-die.h, lib/xalloc.h, lib/xmemdup0.h:
81145         * lib/xstrtol.h: Use _Noreturn rather than including <stdnoreturn.h>
81146         and using noreturn.
81147         * modules/openat, modules/sigpipe-die, modules/xalloc:
81148         * modules/xmemdup0, modules/xstrtol:
81149         Remove dependency on stdnoreturn.
81151         _Noreturn: Ignore __STDC_VERSION__; observe _MSC_VER.
81152         * build-aux/_Noreturn.h (_Noreturn): Ignore __STDC_VERSION__.
81153         Reparenthesize to avoid GCC warning.
81154         Support Microsoft's syntax.
81155         * m4/gnulib-common.m4 (gl_COMMON_BODY): Likewise.
81157         _Noreturn-tests: remove module
81158         * modules/_Noreturn-tests: Remove.
81159         * modules/stdnoreturn-tests (Files): Remove tests/test-_Noreturn.c.
81160         * tests/test-_Noreturn.c: Remove.
81161         * tests/test-stdnoreturn.c: Merge from the old
81162         tests/test-_Noreturn.c, testing both noreturn and _Noreturn.
81164 2011-07-12  Paul Eggert  <eggert@cs.ucla.edu>
81166         _Noreturn, stdnoreturn, and related modules.
81168         * top/maint.mk: Adjust to new noreturn support.
81169         (gl_extract_significant_defines_): Omit pattern ATTRIBUTE_NORETURN.
81170         (def_sym_regex): Do not remove ATTRIBUTE_NORETURN.
81172         xalloc: use stdnoreturn.h
81173         * lib/xalloc.h: Include <stdnoreturn.h>.
81174         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
81175         * modules/xalloc (Depends-on): Add stdnoreturn.
81177         xstrtol: use stdnoreturn.h
81178         * lib/xstrtol.h: Include <stdnoreturn.h>.
81179         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
81180         * modules/xstrtol (Depends-on): Add stdnoreturn.
81182         xmemdup0: use stdnoreturn.h
81183         * lib/xmemdup0.h: Include <stdnoreturn.h>.
81184         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
81185         * modules/xmemdup0 (Depends-on): Add stdnoreturn.
81187         sigpipe-die: use stdnoreturn.h
81188         * lib/sigpipe-die.h: Include <stdnoreturn.h>.
81189         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
81190         * modules/sigpipe-die (Depends-on): Add stdnoreturn.
81192         openat: use stdnoreturn.h
81193         * lib/openat.h: Include <stdnoreturn.h>.
81194         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
81195         * modules/openat (Depends-on): Add stdnoreturn.
81197         * lib/openat-die.c (openat_save_fail): Modernize comment.
81199         * lib/xalloc-die.c (xalloc_die): Modernize comment.
81201         * lib/glthread/thread.h: Modernize comment.
81203         obstack: use _Noreturn
81204         * lib/obstack.c (__attribute__): Remove macro.
81205         (print_and_abort): Use _Noreturn.
81207         c-stack: use _Noreturn
81208         * lib/c-stack.c (die, overflow_handler, segv_handler):
81209         Use _Noreturn rather than __attribute__((noreturn)).
81211         argmatch-tests, exclude_tests: use _Noreturn
81212         * tests/test-argmatch.c, tests/test-exclude.c (_GL_ATTRIBUTE_NORETURN):
81213         Remove.
81214         (ARGMATCH_DIE_DECL): Use _Noreturn instead.
81216         stdlib: use _Noreturn
81217         * lib/stdlib.in.h (_GL_ATTRIBUTE_NORETURN): Remove.
81218         (_Exit): Use _Noreturn rather than _GL_ATTRIBUTE_NORETURN.
81219         * modules/stdlib (Depends-on): Add _Noreturn.
81220         (stdlib.h): Depend on $(_NORETURN_H), and copy it in.
81222         stdnoreturn-tests: new module
81223         * modules/stdnoreturn-tests, tests/test-stdnoreturn.c: New files.
81225         stdnoreturn: new module
81226         * MODULES.html.sh (Noreturn <stdnoreturn.h>): New section.
81227         * m4/stdnoreturn.m4, modules/stdnoreturn: New files.
81229         _Noreturn-tests: new module
81230         * modules/_Noreturn-tests, tests/test-_Noreturn.c: New files.
81232         _Noreturn: new module
81233         * MODULES.html.sh (Support for systems lacking draft ISO C 1X):
81234         New section, mentioning it.
81235         * build-aux/_Noreturn.h, modules/_Noreturn: New files.
81237         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add _Noreturn.
81239 2011-07-11  Eric Blake  <eblake@redhat.com>
81241         ffs: new module
81242         * modules/ffs: New file.
81243         * m4/ffs.m4: Likewise.
81244         * lib/ffs.c: Likewise.
81245         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_DEFAULTS): Add default.
81246         * modules/strings (Makefile.am): Substitute witness.
81247         (Depends-on): Add c++defs.
81248         * lib/strings.in.h (ffs): Declare.
81249         * modules/ffs-tests: New test file.
81250         * tests/test-ffs.c: Test new module.
81251         * MODULES.html.sh (Integer arithmetic functions): Mention it.
81252         * doc/posix-functions/ffs.texi (ffs): Likewise.
81254         regex: avoid compiler warning
81255         * lib/regex.c (includes): Include <strings.h>, for use of
81256         strcasecmp in regcomp.c.
81257         Reported by Joachim Schmitz.
81259 2011-07-09  Paul Eggert  <eggert@cs.ucla.edu>
81261         stdint: respect system's intmax_t if INTMAX_MAX
81262         * lib/stdint.in.h (intmax_t, uintmax_t): If the system defines
81263         INTMAX_MAX, assume its intmax_t is OK.  Similarly for and
81264         uintmax_t.  This is for some Mac OS X builds, where intmax_t is
81265         long but int64_t is long long, and where we will clash with the
81266         system intmax_t if we override it.  See
81267         <http://lists.gnu.org/r/bug-gnulib/2011-07/msg00160.html>.
81268         (INTMAX_C, UINTMAX_C): For consistency, respect the system's
81269         INTMAX_C if INTMAX_MAX and INTMAX_C are both defined, and
81270         similarly for UINTMAX_C.
81272 2011-07-08  Bruno Haible  <bruno@clisp.org>
81274         pthread_sigmask tests: Avoid a compiler warning.
81275         * tests/test-pthread_sigmask1.c (main): Complain if system() returns
81276         non-zero.
81278         sigprocmask tests: A better way to avoid a compiler warning.
81279         * tests/test-sigprocmask.c: Don't include "ignore-value.h".
81280         (main): Complain if system() returns non-zero.
81281         * modules/sigprocmask-tests (Depends-on): Remove ignore-value.
81283 2011-07-08  Bruno Haible  <bruno@clisp.org>
81285         pthread_sigmask: Work around IRIX bug.
81286         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test for the IRIX
81287         bug.
81288         * lib/pthread_sigmask.c (pthread_sigmask): usleep for some time when
81289         there may be unblocked pending signals.
81290         * doc/posix-functions/pthread_sigmask.texi: Mention the IRIX bug.
81292 2011-07-08  Bruno Haible  <bruno@clisp.org>
81294         pthread_sigmask: Work around Cygwin bug.
81295         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test for the Cygwin
81296         bug.
81297         * lib/pthread_sigmask.c (pthread_sigmask): Fix the return value from
81298         the system's pthread_sigmask function.
81299         * doc/posix-functions/pthread_sigmask.texi: Mention the Cygwin bug.
81301 2011-07-08  Bruno Haible  <bruno@clisp.org>
81303         pthread_sigmask: Work around bug in single-threaded implementation.
81304         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test for the
81305         FreeBSD, HP-UX, Solaris bug.
81306         (gl_PREREQ_PTHREAD_SIGMASK): New macro.
81307         * lib/pthread_sigmask.c: Include <stddef.h>.
81308         (pthread_sigmask): If HAVE_PTHREAD_SIGMASK, define as a wrapper around
81309         the system's pthread_sigmask function.
81310         * modules/pthread_sigmask (configure.ac): Invoke
81311         gl_PREREQ_PTHREAD_SIGMASK.
81312         * doc/posix-functions/pthread_sigmask.texi: Mention bug on FreeBSD,
81313         HP-UX, Solaris.
81315 2011-07-08  Eric Blake  <eblake@redhat.com>
81317         test-sigprocmask: avoid compiler warning
81318         * modules/sigprocmask-tests (Depends-on): Add ignore-value.
81319         * tests/test-sigprocmask.c (main): Use it to silence warning.
81320         Reported by Jim Meyering.
81322         test-snprintf: avoid compiler warning
81323         * tests/test-snprintf.c (main): Avoid shadowed declaration.
81324         * tests/test-vsnprintf.c (main): Likewise.
81325         Reported by Jim Meyering.
81327 2011-07-08  Bruno Haible  <bruno@clisp.org>
81329         Tests for module 'pthread_sigmask'.
81330         * modules/pthread_sigmask-tests: New file.
81331         * tests/test-pthread_sigmask1.c: New file, based on
81332         tests/test-sigprocmask.c.
81333         * tests/test-pthread_sigmask2.c: New file.
81335 2011-07-08  Jim Meyering  <meyering@redhat.com>
81337         test-getopt.h: avoid warning about an unused variable
81338         * tests/test-getopt.h (test_getopt): Remove unused variable, "c".
81340 2011-07-07  Jim Meyering  <meyering@redhat.com>
81342         maint: reduce list of files exempt from sc_prohibit_leading_TABs
81343         * Makefile (sc_prohibit_leading_TABs): Don't exempt m4/po.m4,
81344         now that it no longer contains leading TABs.
81345         Remove unused "url=FIXME" statement.
81347 2011-07-08  Paul Eggert  <eggert@cs.ucla.edu>
81349         pthread_sigmask: Assume POSIX when not gl_THREADLIB.
81350         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
81351         When gl_THREADLIB is not in use, assume that the POSIX sematics
81352         are desired.  This is better for Emacs, which uses POSIX semantics
81353         on GNUish and/or POSIXish platforms, and does not use threads at
81354         all otherwise.
81356         pthread_sigmask: fix typo when testing for libraries
81357         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
81358         AC_LINK_IFELSE, not AC_COMPILE_IFELSE.
81360 2011-07-08  Eric Blake  <eblake@redhat.com>
81362         fts: introduce FTS_NOATIME
81363         * lib/fts_.h (FTS_NOATIME): New bit flag.
81364         (FTS_OPTIONMASK): Adjust.
81365         * lib/fts.c (diropen, fts_open, fts_build): Honor it.
81366         (fd_ring_check): Debug code unconditionally uses O_NOATIME.
81368 2011-07-08  Bruno Haible  <bruno@clisp.org>
81370         Tests for module 'thread'.
81371         * modules/thread-tests: New file.
81372         * tests/test-thread_self.c: New file.
81373         * tests/test-thread_create.cc: New file.
81375 2011-07-08  Bruno Haible  <bruno@clisp.org>
81377         thread: Avoid gcc warnings when using gl_thread_self().
81378         * lib/glthread/thread.h (gl_thread_self): Return a pthread_t, not a
81379         'void *'.
81380         (gl_thread_self_pointer): Update.
81382 2011-07-07  Bruno Haible  <bruno@clisp.org>
81384         signal-c++-tests: Check declaration of pthread_sigmask.
81385         * tests/test-signal-c++.cc: Check declaration of pthread_sigmask.
81386         * modules/signal-c++-tests (Makefile.am): Link test-signal-c++ against
81387         $(LIB_PTHREAD_SIGMASK).
81389 2011-07-07  Bruno Haible  <bruno@clisp.org>
81391         pthread_sigmask: Fix link requirements on OSF/1 5.1 and with pth.
81392         * lib/signal.in.h (pthread_sigmask): Override if
81393         REPLACE_PTHREAD_SIGMASK is 1.
81394         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
81395         REPLACE_PTHREAD_SIGMASK.
81396         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Set also
81397         REPLACE_PTHREAD_SIGMASK. Set and substitute LIB_PTHREAD_SIGMASK.
81398         * modules/signal (Makefile.am): Substitute REPLACE_PTHREAD_SIGMASK.
81399         * modules/pthread_sigmask (Depends-on, configure.ac): Update condition.
81400         (Link): Set to $(LIB_PTHREAD_SIGMASK), not $(LIBMULTITHREAD).
81402 2011-07-07  Bruno Haible  <bruno@clisp.org>
81404         pthread_sigmask: Ensure declaration in <signal.h>.
81405         * lib/signal.in.h: On MacOS X, FreeBSD, OpenBSD, OSF/1, Solaris 2.6,
81406         include <pthread.h>.
81407         * doc/posix-functions/pthread_sigmask.texi: Mention the header file
81408         problem.
81410 2011-07-07  Bruno Haible  <bruno@clisp.org>
81412         pthread_sigmask: Document the module.
81413         * doc/posix-functions/pthread_sigmask.texi: Mention the new module.
81415 2011-07-07  Bruno Haible  <bruno@clisp.org>
81417         pthread_sigmask: Follow gnulib conventions.
81418         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Renamed from
81419         gl_PTHREAD_SIGMASK.
81420         * modules/pthread_sigmask (configure.ac): Update.
81422 2011-07-07  Bruno Haible  <bruno@clisp.org>
81424         pthread_sigmask: Make declaration C++ safe.
81425         * lib/signal.in.h: In two special conditions, just do an #include_next.
81426         (pthread_sigmask): Test HAVE_PTHREAD_SIGMASK, not REPLACE_PTHREAD_MASK.
81427         Invoke _GL_CXXALIAS_SYS and _GL_CXXALIASWARN.
81428         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
81429         HAVE_PTHREAD_SIGMASK, not REPLACE_PTHREAD_MASK.
81430         * m4/pthread_sigmask.m4 (gl_PTHREAD_SIGMASK): Set HAVE_PTHREAD_SIGMASK,
81431         not REPLACE_PTHREAD_MASK.
81432         * modules/signal (Makefile.am): Substitute HAVE_PTHREAD_SIGMASK,
81433         not REPLACE_PTHREAD_MASK.
81434         * modules/pthread_sigmask (Depends-on, configure.ac): Update condition.
81436 2011-07-07  Bruno Haible  <bruno@clisp.org>
81438         pthread_sigmask: Fix return value.
81439         * lib/signal.in.h (pthread_sigmask): Declare. Don't define as a macro.
81440         * lib/pthread_sigmask.c: New file.
81441         * modules/pthread_sigmask (Files): Add it.
81442         (configure.ac): Invoke AC_LIBOBJ.
81444 2011-07-07  Eric Blake  <eblake@redhat.com>
81446         getopt: more portable argv creation
81447         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADRS): Rather than casting away
81448         const, use char arrays rather than strings.
81449         Suggested by Paul Eggert.
81451 2011-07-07  Bruno Haible  <bruno@clisp.org>
81453         Tests for module 'sigprocmask'.
81454         * modules/sigprocmask-tests: New file.
81455         * tests/test-sigprocmask.c: New file.
81457 2011-07-07  Bruno Haible  <bruno@clisp.org>
81459         float tests: Tweak.
81460         * tests/test-float.c (main): Tweak skip message.
81462 2011-07-07  Eric Blake  <eblake@redhat.com>
81464         getopt: avoid compiler warning during configure
81465         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADRS): Avoid problems with
81466         assigning string literals to non-const pointer.
81468         getopt-gnu: avoid crash in glibc getopt
81469         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADRS): Detect the problem.
81470         * tests/test-getopt.h (test_getopt): Enhance test.
81471         * tests/test-getopt_long.h (test_getopt_long): Likewise.
81472         * doc/posix-functions/getopt.texi (getopt): Document it.
81473         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
81474         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
81475         Likewise.
81477 2011-07-07  Ulrich Drepper  <drepper@gmail.com>
81479         getopt: handle W; without long options in getopt [BZ #12922]
81480         * lib/getopt.c (_getopt_internal_r): When "W;" is in short options
81481         but no long options are defined, just return 'W'.
81483 2011-07-07  Bruno Haible  <bruno@clisp.org>
81485         Avoid literal tabs.
81486         * m4/po,m4 (AM_PO_SUBDIRS, AM_POSTPROCESS_PO_MAKEFILE): Use a shell
81487         variable containing a tab instead of a literal tab.
81488         Reported by Jim Meyering.
81490 2011-07-07  Bruno Haible  <bruno@clisp.org>
81492         Comments.
81493         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Update comments about mingw.
81495 2011-07-06  Bruno Haible  <bruno@clisp.org>
81497         sys_select: Fix compilation error on mingw, introduced on 2011-06-30.
81498         * lib/sys_select.in.h: Don't include <sys/socket.h>. Instead, include
81499         <winsock2.h>.
81500         (rpl_fd_isset, FD_ISSET): New definitions, copied from
81501         lib/sys_socket.in.h.
81502         (close, gethostname): Hide declarations from <winsock2.h>.
81503         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
81504         listen, recv, send, recvfrom, sendto, setsockopt, shutdown): Likewise.
81505         * lib/sys_socket.in.h (close, gethostname): Tweak indentation.
81506         (select): Don't override if gnulib's <sys/select.h> was already
81507         included.
81508         * lib/unistd.in.h (socket, connect, accept, bind, getpeername,
81509         getsockname, getsockopt, listen, recv, send, recvfrom, sendto,
81510         setsockopt, shutdown, select): Tweak indentation.
81512 2011-07-06  Paul Eggert  <eggert@cs.ucla.edu>
81514         * modules/pthread_sigmask (configure.ac): gl_SIGNAL_MODULE_INDICATOR
81515         and not gl_SYS_SELECT_MODULE_INDICATOR, fixing a typo exposed
81516         in an application that does not use the sys_select module.
81518 2011-07-06  Erik Faye-Lund  <kusmabite@gmail.com>
81520         poll: do not return 0 on timeout=-1
81521         * lib/poll.c: Loop with yield if no events occurred.
81523 2011-07-06  Eric Blake  <eblake@redhat.com>
81525         pthread_sigmask: always replace when not using pthread
81526         * m4/pthread_sigmask.m4 (gl_PTHREAD_SIGMASK): Force sigprocmask
81527         replacement when using some threading other than pthread.  Fix
81528         logic bug.
81530 2011-07-06  Bruno Haible  <bruno@clisp.org>
81532         Comments.
81533         * m4/printf.m4: Update comments about mingw.
81535 2011-07-06  Paul Eggert  <eggert@cs.ucla.edu>
81537         sys_select: define sigset_t more portably
81538         * lib/sys_select.in.h: Always include <sys/types.h>, since
81539         we now need sigset_t and mingw defines it there.
81540         Include <signal.h> before split inclusion guard, to avoid
81541         mishaps on Solaris, whose <signal.h> eventually includes us.
81542         * m4/signal_h.m4 (gl_SIGNAL_H): Require gl_CHECK_TYPE_SIGSET_T.
81543         (gl_CHECK_TYPE_SIGSET_T): New macro, most of the contents of
81544         which come from ...
81545         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
81546         gl_CHECK_TYPE_SIGSET_T.
81547         (gl_PREREQ_SIGPROCMASK): Now a no-op, since gl_CHECK_TYPE_SIGSET_T
81548         does the real work.
81549         * modules/sys_select (Depends-on): Add 'signal'.
81551         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Poison pselect.
81552         Suggested by Bruno Haible.
81554         pselect: Use pthread_sigmask, not sigprocmask.
81555         * lib/pselect.c (pselect): Use pthread_sigmask, as it supports
81556         multithreaded apps better than sigprocmask does.
81557         * modules/pselect (Depends-on): Depend on pthread_sigmask, not
81558         sigprocmask directly.
81560 2011-07-05  Paul Eggert  <eggert@cs.ucla.edu>
81562         * lib/pselect.c (pselect): Use plain name, without "rpl_".
81563         Don't #undef,  since we don't need any underlying pselect.
81564         * modules/pselect (configure.ac): Use our pselect.o if !HAVE_PSELECT.
81565         (Depends-on): Add select.
81566         (Link): Add $(LIBSOCKET).
81567         These changes suggested by Bruno Haible.
81569         pselect: document better
81570         * MODULES.html.sh (Support for systems lacking POSIX:2008): Add it.
81571         * doc/posix-functions/pselect.texi (pselect): Document new module.
81573         pthread_sigmask: new module
81574         * MODULES.html.sh (Support for systems lacking POSIX:2008): Add it.
81575         * doc/posix-functions/pthread_sigmask.texi: Document new module.
81576         * lib/signal.in.h (pthread_sigmask): Arrange for replacement.
81577         This is done only as a macro; I don't know how well that'll
81578         work for C++.  Move <sys/types.h> include before the include_next,
81579         to avoid mishap on Solaris.
81580         * m4/signal_h.m4 (gl_SIGNAL_H, gl_SIGNAL_H_DEFAULTS): Check for it.
81581         * modules/signal (Makefile.am): Substitute the check's results.
81582         * modules/pthread_sigmask, m4/pthread_sigmask.m4: New files.
81584         test-pselect: new module
81585         * modules/pselect-tests, tests/test-pselect.c: New files.
81586         * tests/test-select.c, tests/test-sys_select-c++.cc:
81587         If TEST_PSELECT is defined, test pselect instead of testing select.
81589         * tests/test-sys_select.c (sigset_t): Test for it, too.
81590         Suggested by Bruno Haible.
81592 2011-07-05  Eric Blake  <eblake@redhat.com>
81594         snprintf: guarantee %1$d, for libintl
81595         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require %1$d support.
81596         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Likewise.
81597         * doc/posix-functions/snprintf.texi (snprintf): Update.
81598         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
81599         * tests/test-snprintf.c (main): Enhance test.
81600         * tests/test-vsnprintf.c (main): Likewise.
81602 2011-07-05  Jim Meyering  <meyering@redhat.com>
81604         maint: exempt stdio-read.c and stdio-write.c from the cppi check
81605         * Makefile (sc_cpp_indent_check): Exempt stdio-read.c and stdio-write.c
81606         per Bruno's request, to accommodate this idiom (no space after "#")
81607         even when the function is inside an #if block:
81608         char *
81609         gets (char *s)
81610         #undef gets
81611         {
81612           ...
81613         }
81615 2011-07-04  Jim Meyering  <meyering@redhat.com>
81617         maint: indent with spaces, not TABs, and add a rule to check this
81618         * tests/test-userspec.c: Indent with spaces, not TABs.
81619         * tests/test-argp.c: Likewise.
81620         * tests/test-c-stack2.sh: Likewise.
81621         * tests/test-parse-duration.sh: Likewise
81622         * m4/strtod.m4: Likewise.
81623         * m4/alloca.m4: Likewise.
81624         * m4/pselect.m4: Likewise.
81625         * Makefile (sc_prohibit_leading_TABs): Prohibit leading TABs.
81627 2011-07-03  Jim Meyering  <meyering@redhat.com>
81629         maint.mk: correct omissions in prohibit_argmatch_without_use check
81630         This rule would mistakenly report that argmatch.h is included without
81631         use even when both the argmatch and invalid_arg macro were used.
81632         * top/maint.mk (sc_prohibit_argmatch_without_use): Also detect uses
81633         of argmatch and invalid_arg.
81635 2011-07-03  Bruno Haible  <bruno@clisp.org>
81637         Comments about EINTR.
81638         * lib/safe-read.h: Explain the purpose of this module.
81639         * lib/safe-write.h: Likewise.
81640         * doc/posix-functions/read.texi: Mention EINTR and the 'safe-read'
81641         module.
81642         * doc/posix-functions/write.texi: Mention EINTR and the 'safe-write'
81643         module.
81644         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
81646 2011-06-30  Paul Eggert  <eggert@cs.ucla.edu>
81648         xnanosleep: Rewrite to use new dtotimespec module.
81649         It has the conversion code that used to be in xnanosleep.
81650         * lib/xnanosleep.c: Do not include limits.h, stdbool.h, stdio.h,
81651         assert.h, sys/types.h, or intprops.h.  Include timespec.h instead.
81652         (TIME_T_MAX): Remove.
81653         (xnanosleep): Rewrite in terms of dtotimespec.
81654         * modules/xnanosleep (Depends-on): Add dtotimespec.
81655         Remove intprops, stdbool.
81657         timespec-add, timespec-sub: new modules
81658         * lib/timespec.h (timespec_add, timespec_sub): New decls.
81659         * lib/timespec-add.c, lib/timespec-sub.c:
81660         * modules/timespec-add, modules/timespec-sub: New files.
81662         dtotimespec: new module
81663         * lib/timespec.h (dtotimespec): New decl.
81664         * lib/dtotimespec.c, modules/dtotimespec: New files.
81666         * lib/timespec.h (timespec_sign, timespectod): New inline functions.
81668         pselect: new module
81669         * lib/sys_select.in.h: Include <signal.h>, for 'sigset_t'.
81670         (pselect): New decls.
81671         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Require AC_C_RESTRICT,
81672         since the standard pselect decl uses 'restrict'.
81673         (gl_SYS_SELECT_H_DEFAULTS): Add defaults for GNULIB_PSELECT,
81674         HAVE_PSELECT, REPLACE_PSELECT.
81675         * modules/sys_select (sys/select.h): Substitute GNULIB_PSELECT,
81676         HAVE_PSELECT, REPLACE_PSELECT.
81677         * lib/pselect.c, m4/pselect.m4, modules/pselect: New files.
81679         sys_select: don't depend on sys_socket
81680         This is so that Emacs doesn't have to drag in m4/sockpfaf.m4 etc; see
81681         <http://lists.gnu.org/r/bug-gnulib/2011-06/msg00358.html>.
81682         This fix works on GNU and GNU-like platforms, but has not been tested
81683         on native Windows.
81684         * lib/sys_select.in.h: Include <sys/socket.h> only if native Windows.
81685         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Do not require
81686         gl_HEADER_SYS_SOCKET.
81687         * modules/sys_select (Files): Add m4/sys_socket_h.m4, for
81688         gl_PREREQ_SYS_H_WINSOCK2.
81690 2011-06-29  Eric Blake  <eblake@redhat.com>
81692         pipe2: fix C89 compile problem
81693         * lib/pipe2.c (pipe2): Avoid C99 array initialization.
81694         Reported by Bruno Haible.
81696         pipe, pipe2: don't corrupt fd on error
81697         * lib/pipe.c (pipe): Leave fd unchanged on error.
81698         * lib/pipe2.c (pipe2): Likewise.
81699         * doc/posix-functions/pipe.texi (pipe): Document cygwin issue.
81700         * doc/glibc-functions/pipe2.texi (pipe2): Likewise.
81702 2011-06-27  Paolo Bonzini  <bonzini@gnu.org>
81704         mmap-anon: do not use regular expressions inadvertently
81705         * m4/mmap-anon.m4: Remove trailing period from strings sought
81706         in the output.
81708 2011-06-25  Paul Eggert  <eggert@cs.ucla.edu>
81710         nanosleep: fix integer overflow problem
81711         * lib/nanosleep.c (my_usleep): Don't assume signed integer
81712         arithmetic wraps around on overflow.
81714         nanosleep: simplify carrying
81715         * lib/nanosleep.c (nanosleep): Use the requested tv_nsec for the
81716         first call to the underyling nanosleep, not for the last one.
81717         This doesn't fix any bugs, but it simplifies the computation of
81718         the remaining delay.  Found while auditing integer overflow issues.
81720         dup2: remove test for existence of fcntl
81721         * m4/dup2.m4 (gl_FUNC_DUP2): Use "#ifdef FD_CLOEXEC", not
81722         "#if HAVE_FCNTL", in the configure-time test program.
81723         This removes the need for the AC_CHECK_FUNCS_ONCE([fcntl]),
81724         and therefore speeds up "configure" a bit.  Found while
81725         adding the dup2 module to Emacs.
81727 2011-06-24  Eric Blake  <eblake@redhat.com>
81729         maint.mk: enhance useless header checks
81730         * top/maint.mk (_sc_header_without_use): Check both include
81731         styles.
81732         (sc_prohibit_assert_without_use)
81733         (sc_prohibit_close_stream_without_use)
81734         (sc_prohibit_getopt_without_use)
81735         (sc_prohibit_quotearg_without_use)
81736         (sc_prohibit_quote_without_use)
81737         (sc_prohibit_long_options_without_use)
81738         (sc_prohibit_inttostr_without_use)
81739         (sc_prohibit_ignore_value_without_use)
81740         (sc_prohibit_error_without_use, sc_prohibit_xalloc_without_use)
81741         (sc_prohibit_hash_without_use, sc_prohibit_cloexec_without_use)
81742         (sc_prohibit_posixver_without_use, sc_prohibit_same_without_use)
81743         (sc_prohibit_hash_pjw_without_use)
81744         (sc_prohibit_safe_read_without_use)
81745         (sc_prohibit_argmatch_without_use)
81746         (sc_prohibit_canonicalize_without_use)
81747         (sc_prohibit_root_dev_ino_without_use)
81748         (sc_prohibit_openat_without_use)
81749         (sc_prohibit_c_ctype_without_use)
81750         (sc_prohibit_signal_without_use)
81751         (sc_prohibit_stdio--_without_use)
81752         (sc_prohibit_stdio-safer_without_use)
81753         (sc_prohibit_strings_without_use)
81754         (sc_prohibit_intprops_without_use)
81755         (sc_prohibit_stddef_without_use)
81756         (sc_prohibit_xfreopen_without_use): Update clients.
81758 2011-06-24  Jim Meyering  <meyering@redhat.com>
81760         syntax-check: keep one maint.mk rule in sync with its header
81761         * Makefile (sc_check_sym_list): Add a rule to prevent a repeat
81762         of the bug Eric has just fixed, with today's commit 25e4c2ec.
81763         I prefer to avoid temporary files here, so use <(...), but that
81764         is not supported by /bin/sh, so...
81765         (SHELL): Define to /bin/bash.
81767 2011-06-24  Eric Blake  <eblake@redhat.com>
81769         maint.mk: update sc_prohibit_intprops_without_use
81770         * top/maint.mk (_intprops_names): Match recent changes.
81772 2011-06-24  Bruno Haible  <bruno@clisp.org>
81774         strerror-override: No-op tweak.
81775         * lib/strerror-override.h (strerror_override): Reorder conditions,
81776         for consistency with lib/strerror-override.c.
81778 2011-06-23  Eric Blake  <eblake@redhat.com>
81780         maint.mk: test further PATH_MAX issues
81781         * top/maint.mk (sc_prohibit_path_max_array): Rename...
81782         (sc_prohibit_path_max_allocation): ...and also test alloca.
81783         Suggested by Jim Meyering.
81785 2011-06-22  Eric Blake  <eblake@redhat.com>
81787         maint.mk: add syntax-check to avoid char[PATH_MAX]
81788         * top/maint.mk (sc_prohibit_path_max_array): New rule.
81790         stat: be robust to PATH_MAX definition
81791         * lib/stat.c (rpl_stat): Require reasonable PATH_MAX.
81792         * modules/stat (Depends-on): Add verify.
81794         link: work around IRIX bug
81795         * m4/link.m4 (gl_FUNC_LINK): Expose the bug.
81796         * lib/link.c (rpl_link): Work around it.
81797         * tests/test-link.h (test_link): Enhance test.
81798         * doc/posix-functions/link.texi (link): Document the bug.
81800         getopt: silence clang warning
81801         * lib/getopt.c (_getopt_internal_r): Avoid unlikely NULL
81802         dereference.
81803         Reported by Gustavo Martin Domato.
81805 2011-06-22  Jim Meyering  <meyering@redhat.com>
81807         bootstrap: do not insert a blank line into each .gitignore file
81808         * build-aux/bootstrap (sort_patterns): Filter out blank lines.
81810 2011-06-21  Eric Blake  <eblake@redhat.com>
81812         perror: test for output mismatch
81813         * m4/perror.m4 (gl_FUNC_PERROR): Add test, in order to replace
81814         perror on IRIX.
81816         strerror_r: fix OpenBSD behavior on out-of-range
81817         * lib/strerror_r.c (strerror_r): Always use maximal string.
81818         * doc/posix-functions/strerror_r.texi (strerror_r): Document it.
81820         strerror_r: fix OpenBSD behavior on 0
81821         * lib/strerror-override.c (strerror_override): Also override 0
81822         when needed.
81823         * lib/strerror-override.h (strerror_override): Likewise.
81824         * lib/strerror.c (strerror): Simplify, now that 0 override is done
81825         earlier.
81826         * lib/strerror_r.c (strerror_r): Likewise.
81827         * m4/strerror.m4 (gl_FUNC_STRERROR): Split detection of 0
81828         behavior...
81829         (gl_FUNC_STRERROR_0): ...into new macro.
81830         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Replace strerror_r if 0
81831         is overridden.
81832         (gl_FUNC_STRERROR_R_WORKS): Avoid extra tests if 0 is broken.
81833         * modules/strerror-override (Files): Add strerror.m4.
81834         (configure.ac): Also provide override for 0 when needed.
81835         * doc/posix-functions/strerror.texi (strerror): Document this.
81836         * doc/posix-functions/perror.texi (perror): Likewise.
81838         perror: adjust array size
81839         * modules/perror (Depends-on): Add strerror-override.
81840         * lib/perror.c (perror): Use it to avoid magic number.
81842         strerror-override: reduce size
81843         * lib/strerror-override.c (strerror_override): Use fewer lines.
81845 2011-06-20  Bruno Haible  <bruno@clisp.org>
81847         pathmax: Ensure correct value for PATH_MAX on HP-UX.
81848         * lib/pathmax.h (PATH_MAX) [HP-UX]: Define to 1024.
81850 2011-06-20  Paul Eggert  <eggert@cs.ucla.edu>
81852         alloca: port to compilers that can optimize like GCC 4.6.0
81853         * lib/alloca.c (find_stack_direction): New signature, taken from
81854         Autoconf git.  This works with GCC 4.6.0.  This code should never
81855         be used with GCC 4.6.0 itself, as GCC has alloca, but it might
81856         be used with other compilers that optimize as well as GCC 4.6.0 does.
81857         (alloca): Adjust to new signature.
81858         * m4/alloca.m4 (__AC_LIBOBJ_ALLOCA) [Autoconf version < 2.69]:
81859         New macro, which patches Autoconf in a similar way.
81861         c-stack: stop worrying about stack direction
81862         * lib/c-stack.c (find_stack_direction): Remove.
81863         (segv_handler): Don't worry about stack direction growth, as it's
81864         too much of a pain to configure this correctly, given how compilers
81865         are optimizing-away our stack-growth detection code.  Instead, assume
81866         that any access to just before or just after the stack is OK.
81867         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
81868         Don't require AC_FUNC_ALLOCA; no longer needed.
81870 2011-06-20  Eric Blake  <eblake@redhat.com>
81872         test-stat: don't allocate PATH_MAX bytes
81873         * tests/test-stat.h (test_stat_func): Don't stack-allocate a
81874         PATH_MAX-sized buffer.
81875         * modules/openat-tests (Depends-on): Add getcwd-lgpl, drop pathmax.
81876         * modules/stat-tests (Depends-on): Likewise.
81877         * tests/test-fstatat.c (includes): Drop pathmax.h.
81878         * tests/test-stat.c (includes): Likewise.
81879         Reported by Bruno Haible.
81881 2011-06-20  Bruno Haible  <bruno@clisp.org>
81883         float: Work around <float.h> bugs on FreeBSD/x86, AIX with GCC, IRIX.
81884         * lib/float.in.h: Add workarounds for FreeBSD/x86, AIX with GCC, IRIX.
81885         * lib/float.c: New file.
81886         * m4/float_h.m4 (gl_FLOAT_H): Also handle FreeBSD, AIX, IRIX. Set
81887         REPLACE_FLOAT_LDBL.
81888         * modules/float (Files): Add lib/float.c.
81889         (configure.ac): Invoke AC_LIBOBJ.
81890         * doc/posix-headers/float.texi: Mention problems on FreeBSD, AIX, IRIX.
81892 2011-06-20  Bruno Haible  <bruno@clisp.org>
81894         Tests for module 'float'.
81895         * modules/float-tests: New file.
81896         * tests/test-float.c: New file.
81898 2011-06-19  Bruno Haible  <bruno@clisp.org>
81900         isinf: Coding style.
81901         * lib/isinf.c: Use GNU coding style.
81903 2011-06-19  Bruno Haible  <bruno@clisp.org>
81905         linkat test: Avoid test failure on AIX 7.1.
81906         * tests/test-linkat.c (main): Allow EINVAL as alternate error value.
81907         * tests/test-link.h (test_link): Likewise.
81909 2011-06-19  Bruno Haible  <bruno@clisp.org>
81911         pread test: Avoid test failure on OpenBSD 4.9.
81912         * tests/test-pread.c (main): Allow EFBIG instead of EINBAL.
81914 2011-06-19  Bruno Haible  <bruno@clisp.org>
81916         sprintf-posix: Fix test failure on AIX 7.1.
81917         * m4/printf.m4 (gl_PRINTF_PRECISION): Test against AIX bug.
81918         * doc/posix-functions/dprintf.texi: Mention limited precision problem
81919         on AIX.
81920         * doc/posix-functions/fprintf.texi: Likewise.
81921         * doc/posix-functions/printf.texi: Likewise.
81922         * doc/posix-functions/snprintf.texi: Likewise.
81923         * doc/posix-functions/sprintf.texi: Likewise.
81924         * doc/posix-functions/vdprintf.texi: Likewise.
81925         * doc/posix-functions/vfprintf.texi: Likewise.
81926         * doc/posix-functions/vprintf.texi: Likewise.
81927         * doc/posix-functions/vsnprintf.texi: Likewise.
81928         * doc/posix-functions/vsprintf.texi: Likewise.
81930 2011-06-19  Bruno Haible  <bruno@clisp.org>
81932         roundl-ieee: Fix test failure on AIX 7.1.
81933         * m4/roundl.m4 (gl_FUNC_ROUNDL): Test also the sign of roundl (-0.3L).
81934         * doc/posix-functions/roundl.texi: Mention problem with negative
81935         arguments.
81937 2011-06-19  Bruno Haible  <bruno@clisp.org>
81939         round-ieee: Fix test failures on AIX 7.1 and OSF/1 5.1.
81940         * modules/round-ieee (Depends-on): Add floor-ieee, ceil-ieee.
81941         * doc/posix-functions/round.texi: Mention problem with negative
81942         arguments.
81943         * doc/posix-functions/ceil.texi: Mention problem on OSF/1 5.1.
81945 2011-06-19  Bruno Haible  <bruno@clisp.org>
81947         roundf-ieee: Fix test failures on AIX 7.1 and OSF/1 5.1.
81948         * m4/roundf.m4 (gl_FUNC_ROUNDF): Test also the sign of roundf (-0.3f).
81949         * modules/roundf-ieee (Depends-on): Add floorf-ieee, ceilf-ieee.
81950         * doc/posix-functions/roundf.texi: Mention problem with negative
81951         arguments.
81952         * doc/posix-functions/ceilf.texi: Mention problem on OSF/1 5.1.
81954 2011-06-19  Bruno Haible  <bruno@clisp.org>
81956         ceilf-ieee: Work around bug on MacOS X 10.5.
81957         * doc/posix-functions/ceilf.texi: Mention the MacOS X 10.5 problem.
81959         floor*-ieee, ceil*-ieee, trunc*-ieee, round*-ieee: More robust checks.
81960         * m4/floorf.m4 (gl_FUNC_FLOORF): In the test whether the function is
81961         IEEE compliant, avoid compiler optimizations.
81962         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
81963         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
81964         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
81965         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
81966         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
81967         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
81968         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
81969         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
81970         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
81971         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
81973 2011-06-19  Bruno Haible  <bruno@clisp.org>
81975         ceilf-ieee: Work around bug on AIX 7.1.
81976         * m4/ceilf.m4 (gl_FUNC_CEILF): Test also the sign of ceilf (-0.3f).
81977         * doc/posix-functions/ceilf.texi: Mention the AIX 7.1 problem.
81979 2011-06-19  Bruno Haible  <bruno@clisp.org>
81981         ceil-ieee: Work around bug on AIX 7.1.
81982         * m4/ceil.m4 (gl_FUNC_CEIL): Test also the sign of ceil (-0.3).
81983         * doc/posix-functions/ceil.texi: Mention the AIX 7.1 problem.
81985 2011-06-18  Bruno Haible  <bruno@clisp.org>
81987         fsync test: Avoid test failure on MacOS X and AIX.
81988         * tests/test-fsync.c (fsync): Allow ENOTSUP and EBADF instead of
81989         EINVAL.
81991 2011-06-18  Bruno Haible  <bruno@clisp.org>
81993         openat, fdopendir tests: Fix link errors.
81994         * modules/openat-tests (Depends-on): Add progname.
81995         * modules/fdopendir-tests (Depends-on): Likewise.
81996         * tests/test-fchownat.c: Include progname.h.
81997         (main): Call set_program_name.
81998         * tests/test-fstatat.c: Include progname.h.
81999         (main): Call set_program_name.
82000         * tests/test-mkdirat.c: Include progname.h.
82001         (main): Call set_program_name.
82002         * tests/test-openat.c: Include progname.h.
82003         (main): Call set_program_name.
82004         * tests/test-unlinkat.c: Include progname.h.
82005         (main): Call set_program_name.
82006         * tests/test-fdopendir.c: Include progname.h.
82007         (main): Call set_program_name.
82009 2011-06-18  Bruno Haible  <bruno@clisp.org>
82011         Doc update.
82012         * doc/posix-functions/pthread_attr_getstack.texi: Update info regarding
82013         HP-UX.
82014         * doc/posix-functions/pthread_attr_setstack.texi: Likewise.
82016 2011-06-18  Bruno Haible  <bruno@clisp.org>
82018         getcwd tests: Avoid compilation error on HP-UX 11.31.
82019         * modules/getcwd-tests (Depends-on): Add pathmax.
82020         * tests/test-getcwd.c: Include pathmax.h.
82022 2011-06-18  Bruno Haible  <bruno@clisp.org>
82024         isfinite, isinf: Fix link error on AIX 6 and 7.
82025         * m4/isfinite.m4 (gl_ISFINITE): When determining whether libm is
82026         needed, also test the macro with a 'float' argument.
82027         * m4/isinf.m4 (gl_ISINF): Likewise.
82029 2011-06-18  Bruno Haible  <bruno@clisp.org>
82031         getloadavg: Don't clobber LIBS. Regression from previous commit.
82032         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Move tests that use
82033         AC_CHECK_LIB from here...
82034         (gl_GETLOADAVG): ... to here, inside the experiment with LIBS.
82035         (gl_GETLOADAVG, gl_PREREQ_GETLOADAVG): Rename gl_have_func to
82036         gl_func_getloadavg_done.
82037         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
82039 2011-06-18  Bruno Haible  <bruno@clisp.org>
82041         clean-temp: Improve documentation.
82042         * lib/clean-temp.h: Explain better how to use this module.
82043         Reported by John Darrington <john@darrington.wattle.id.au>.
82045 2011-06-17  Bruno Haible  <bruno@clisp.org>
82047         pread, pwrite: Avoid cc warning on AIX.
82048         * lib/unistd.in.h (pread): Undefine before defining as a macro.
82049         (pwrite): Likewise.
82051 2011-06-17  Bruno Haible  <bruno@clisp.org>
82053         spawn-pipe tests: Fix link error.
82054         * tests/test-spawn-pipe-child.c: Undefine fprintf.
82055         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
82057 2011-06-17  Bruno Haible  <bruno@clisp.org>
82059         Tests: Remove unnecessary dependency.
82060         * modules/canonicalize-tests (Depends-on): Remove progname.
82061         * modules/chown-tests (Depends-on): Likewise.
82062         * modules/dirname-tests (Depends-on): Likewise.
82063         * modules/fdopendir-tests (Depends-on): Likewise.
82064         * modules/fdutimensat-tests (Depends-on): Likewise.
82065         * modules/hash-tests (Depends-on): Likewise.
82066         * modules/lchown-tests (Depends-on): Likewise.
82067         * modules/linkat-tests (Depends-on): Likewise.
82068         * modules/renameat-tests (Depends-on): Likewise.
82069         * modules/spawn-pipe-tests (Depends-on): Likewise.
82070         * modules/utimensat-tests (Depends-on): Likewise.
82072 2011-06-17  Bruno Haible  <bruno@clisp.org>
82074         spawn-pipe tests: Fix link error.
82075         * tests/test-spawn-pipe-child.c: Undefine fflush.
82077 2011-06-17  Bruno Haible  <bruno@clisp.org>
82079         Fix tests link errors.
82080         * modules/ceil-ieee-tests (Makefile.am): Use CEIL_LIBM, not FLOOR_LIBM.
82081         * modules/chown-tests (Makefile.am): Don't link test-chown with
82082         LIBINTL.
82083         * modules/lchown-tests (Makefile.am): Don't link test-lchown with
82084         LIBINTL.
82085         * modules/utimens-tests (Makefile.am): Don't link test-utimens with
82086         LIBINTL.
82087         * modules/futimens-tests (Makefile.am): Don't link test-futimens with
82088         LIBINTL.
82090 2011-06-16  Bruno Haible  <bruno@clisp.org>
82092         crypto/gc-sha1: Fix recent regression.
82093         * modules/crypto/gc-sha1 (configure.ac): Invoke AC_LIBOBJ here.
82094         * m4/gc-sha1.m4 (gl_GC_SHA1): Don't invoke gl_SHA1.
82096         crypto/gc-md5: Fix recent regression.
82097         * modules/crypto/gc-md5 (configure.ac): Invoke AC_LIBOBJ here.
82099         crypto/gc-md4: Fix recent regression.
82100         * modules/crypto/gc-md4 (configure.ac): Invoke AC_LIBOBJ here.
82101         * m4/md4.m4 (gl_MD4): Ensure the expansion is non-empty.
82103         crypto/gc-arctwo: Fix recent regression.
82104         * modules/crypto/gc-arctwo (configure.ac): Invoke AC_LIBOBJ here.
82105         * m4/arctwo.m4 (gl_ARCTWO): Ensure the expansion is non-empty.
82107         crypto/gc-rijndael: Fix recent regression.
82108         * modules/crypto/gc-rijndael (Files): Remove m4/rijndael.m4.
82109         (configure.ac): Invoke AC_LIBOBJ here.
82110         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Don't invoke gl_RIJNDAEL.
82111         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
82113         crypto/gc-hmac-sha1: Fix recent regression.
82114         * modules/crypto/gc-hmac-sha1 (Files): Remove m4/hmac-sha1.m4.
82115         (configure.ac): Invoke AC_LIBOBJ here.
82116         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Don't invoke gl_HMAC_SHA1.
82117         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
82119         crypto/gc-hmac-md5: Fix recent regression.
82120         * modules/crypto/gc-hmac-md5 (Files): Remove m4/hmac-md5.m4.
82121         (configure.ac): Invoke AC_LIBOBJ here.
82122         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Don't invoke gl_HMAC_MD5.
82123         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
82125         crypto/gc-des: Fix recent regression.
82126         * modules/crypto/gc-des (Files): Remove m4/des.m4.
82127         (configure.ac): Invoke AC_LIBOBJ here.
82128         * m4/gc-des.m4 (gl_GC_DES): Don't invoke gl_DES.
82129         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
82131         crypto/gc-arcfour: Fix recent regression.
82132         * modules/crypto/gc-arcfour (Files): Remove m4/arcfour.m4.
82133         (configure.ac): Invoke AC_LIBOBJ here.
82134         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Don't invoke gl_ARCFOUR.
82135         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
82137 2011-06-16  Paul Eggert  <eggert@cs.ucla.edu>
82139         * m4/lstat.m4 (gl_FUNC_LSTAT): Fix typo in prerequisite.
82140         After the 2011-05-21 change, this macro requires
82141         gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, not
82142         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
82144 2011-06-16  Bruno Haible  <bruno@clisp.org>
82146         fprintftime: Move AC_LIBOBJ invocations to module description.
82147         * m4/fprintftime.m4: Remove file.
82148         * modules/fprintftime (Files): Remove m4/fprintftime.m4.
82149         (configure.ac): Remove gl_FPRINTFTIME call.
82150         (Makefile.am): Augment lib_SOURCES.
82151         Reported by Jim Meyering.
82153 2011-06-16  Bruno Haible  <bruno@clisp.org>
82155         tmpfile-safer: Finish 2011-05-23 commit.
82156         * m4/stdio-safer.m4: Really remove file.
82157         Reported by Jim Meyering.
82159 2011-06-16  Bruno Haible  <bruno@clisp.org>
82161         syntax-check: Fix typo.
82162         * Makefile (allow_AC_LIBOBJ): Mention printf-posix-rpl.m4, not
82163         printf-posix.m4.
82164         Reported by Jim Meyering.
82166 2011-06-13  Jim Meyering  <meyering@redhat.com>
82168         syntax-check: add a rule to help enforce the no-AC_LIBOBJ-in-m4/ policy
82169         * Makefile (sc_prohibit_AC_LIBOBJ_in_m4): New rule.
82171 2011-05-23  Bruno Haible  <bruno@clisp.org>
82173         yesno: Move AC_LIBOBJ invocations to module description.
82174         * m4/yesno.m4 (gl_YESNO): Remove AC_LIBOBJ invocation.
82175         * modules/yesno (Makefile.am): Augment lib_SOURCES.
82177 2011-05-23  Bruno Haible  <bruno@clisp.org>
82179         xstrtol: Move AC_LIBOBJ invocations to module description.
82180         * m4/xstrtol.m4 (gl_XSTRTOL): Remove AC_LIBOBJ invocations.
82181         * modules/xstrtol (Makefile.am): Augment lib_SOURCES.
82183 2011-05-23  Bruno Haible  <bruno@clisp.org>
82185         xstrtold: Move AC_LIBOBJ invocations to module description.
82186         * m4/xstrtod.m4 (gl_XSTRTOLD): Remove AC_LIBOBJ invocation.
82187         * modules/xstrtold (Makefile.am): Augment lib_SOURCES.
82189 2011-05-23  Bruno Haible  <bruno@clisp.org>
82191         xstrtod: Move AC_LIBOBJ invocations to module description.
82192         * m4/xstrtod.m4 (gl_XSTRTOD): Remove AC_LIBOBJ invocation.
82193         * modules/xstrtod (Makefile.am): Augment lib_SOURCES.
82195 2011-05-23  Bruno Haible  <bruno@clisp.org>
82197         xnanosleep: Move AC_LIBOBJ invocations to module description.
82198         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove AC_LIBOBJ invocation.
82199         * modules/xnanosleep (Makefile.am): Augment lib_SOURCES.
82201 2011-05-23  Bruno Haible  <bruno@clisp.org>
82203         xgetcwd: Move AC_LIBOBJ invocations to module description.
82204         * m4/xgetcwd.m4 (gl_XGETCWD): Remove AC_LIBOBJ invocation.
82205         * modules/xgetcwd (Makefile.am): Augment lib_SOURCES.
82207 2011-05-23  Bruno Haible  <bruno@clisp.org>
82209         xalloc: Move AC_LIBOBJ invocations to module description.
82210         * m4/xalloc.m4 (gl_XALLOC): Remove AC_LIBOBJ invocation.
82211         * modules/xalloc (Makefile.am): Augment lib_SOURCES.
82213 2011-05-23  Bruno Haible  <bruno@clisp.org>
82215         write-any-file: Move AC_LIBOBJ invocations to module description.
82216         * m4/write-any-file.m4 (gl_WRITE_ANY_FILE): Remove AC_LIBOBJ
82217         invocation.
82218         * modules/write-any-file (Makefile.am): Augment lib_SOURCES.
82220 2011-05-23  Bruno Haible  <bruno@clisp.org>
82222         utimens: Move AC_LIBOBJ invocations to module description.
82223         * m4/utimens.m4 (gl_UTIMENS): Remove AC_LIBOBJ invocation.
82224         * modules/utimens (Makefile.am): Augment lib_SOURCES.
82226 2011-05-23  Bruno Haible  <bruno@clisp.org>
82228         utimecmp: Move AC_LIBOBJ invocations to module description.
82229         * m4/utimecmp.m4 (gl_UTIMECMP): Remove AC_LIBOBJ invocation.
82230         * modules/utimecmp (Makefile.am): Augment lib_SOURCES.
82232 2011-05-23  Bruno Haible  <bruno@clisp.org>
82234         userspec: Move AC_LIBOBJ invocations to module description.
82235         * m4/userspec.m4 (gl_USERSPEC): Remove AC_LIBOBJ invocation.
82236         * modules/userspec (Makefile.am): Augment lib_SOURCES.
82238 2011-05-23  Bruno Haible  <bruno@clisp.org>
82240         unlinkdir: Move AC_LIBOBJ invocations to module description.
82241         * m4/unlinkdir.m4 (gl_UNLINKDIR): Remove AC_LIBOBJ invocation.
82242         * modules/unlinkdir (Makefile.am): Augment lib_SOURCES.
82244 2011-05-23  Bruno Haible  <bruno@clisp.org>
82246         unistd-safer: Move AC_LIBOBJ invocations to module description.
82247         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Remove AC_LIBOBJ invocations.
82248         * modules/unistd-safer (Makefile.am): Augment lib_SOURCES.
82250 2011-05-23  Bruno Haible  <bruno@clisp.org>
82252         tempname: Move AC_LIBOBJ invocations to module description.
82253         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Remove AC_LIBOBJ invocation.
82254         * modules/tempname (Makefile.am): Augment lib_SOURCES.
82256 2011-05-23  Bruno Haible  <bruno@clisp.org>
82258         strftime: Move AC_LIBOBJ invocations to module description.
82259         * m4/strftime.m4 (gl_FUNC_STRFTIME): Remove AC_LIBOBJ invocation.
82260         * modules/strftime (Makefile.am): Augment lib_SOURCES.
82262 2011-05-23  Bruno Haible  <bruno@clisp.org>
82264         stdlib-safer: Move AC_LIBOBJ invocations to module description.
82265         * m4/stdlib-safer.m4: Remove file.
82266         * modules/stdlib-safer (Files): Remove m4/stdlib-safer.m4.
82267         (configure.ac): Remove gl_STDLIB_SAFER call.
82268         (Makefile.am): Augment lib_SOURCES.
82270 2011-05-23  Bruno Haible  <bruno@clisp.org>
82272         tmpfile-safer: Move AC_LIBOBJ invocations to module description.
82273         * m4/stdio-safer.m4: Remove file.
82274         * modules/tmpfile-safer (Files): Remove m4/stdio-safer.m4.
82275         (configure.ac): Remove gl_TMPFILE_SAFER call.
82276         (Makefile.am): Augment lib_SOURCES.
82278 2011-05-23  Bruno Haible  <bruno@clisp.org>
82280         popen-safer: Move AC_LIBOBJ invocations to module description.
82281         * m4/stdio-safer.m4 (gl_POPEN_SAFER): Remove macro.
82282         * modules/popen-safer (Files): Remove m4/stdio-safer.m4.
82283         (configure.ac): Remove gl_POPEN_SAFER call.
82284         (Makefile.am): Augment lib_SOURCES.
82286 2011-05-23  Bruno Haible  <bruno@clisp.org>
82288         freopen-safer: Move AC_LIBOBJ invocations to module description.
82289         * m4/stdio-safer.m4 (gl_FREOPEN_SAFER): Remove macro.
82290         * modules/freopen-safer (Files): Remove m4/stdio-safer.m4.
82291         (configure.ac): Remove gl_FREOPEN_SAFER call.
82292         (Makefile.am): Augment lib_SOURCES.
82294 2011-05-23  Bruno Haible  <bruno@clisp.org>
82296         fopen-safer: Move AC_LIBOBJ invocations to module description.
82297         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove macro.
82298         * modules/fopen-safer (Files): Remove m4/stdio-safer.m4.
82299         (configure.ac): Remove gl_FOPEN_SAFER call.
82300         (Makefile.am): Augment lib_SOURCES.
82302 2011-05-23  Bruno Haible  <bruno@clisp.org>
82304         crypto/sha512: Move AC_LIBOBJ invocations to module description.
82305         * m4/sha512.m4 (gl_SHA512): Remove AC_LIBOBJ invocation.
82306         * modules/crypto/sha512 (Makefile.am): Augment lib_SOURCES.
82308 2011-05-23  Bruno Haible  <bruno@clisp.org>
82310         crypto/sha256: Move AC_LIBOBJ invocations to module description.
82311         * m4/sha256.m4 (gl_SHA256): Remove AC_LIBOBJ invocation.
82312         * modules/crypto/sha256 (Makefile.am): Augment lib_SOURCES.
82314 2011-05-23  Bruno Haible  <bruno@clisp.org>
82316         crypto/sha1: Move AC_LIBOBJ invocations to module description.
82317         * m4/sha1.m4 (gl_SHA1): Remove AC_LIBOBJ invocation.
82318         * modules/crypto/sha1 (Makefile.am): Augment lib_SOURCES.
82320 2011-05-23  Bruno Haible  <bruno@clisp.org>
82322         settime: Move AC_LIBOBJ invocations to module description.
82323         * m4/settime.m4 (gl_SETTIME): Remove AC_LIBOBJ invocation.
82324         * modules/settime (Makefile.am): Augment lib_SOURCES.
82326 2011-05-23  Bruno Haible  <bruno@clisp.org>
82328         savedir: Move AC_LIBOBJ invocations to module description.
82329         * m4/savedir.m4 (gl_SAVEDIR): Remove AC_LIBOBJ invocation.
82330         * modules/savedir (Makefile.am): Augment lib_SOURCES.
82332 2011-05-23  Bruno Haible  <bruno@clisp.org>
82334         save-cwd: Move AC_LIBOBJ invocations to module description.
82335         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove AC_LIBOBJ invocation.
82336         * modules/save-cwd (Makefile.am): Augment lib_SOURCES.
82338 2011-05-23  Bruno Haible  <bruno@clisp.org>
82340         same: Move AC_LIBOBJ invocations to module description.
82341         * m4/same.m4 (gl_SAME): Remove AC_LIBOBJ invocation.
82342         * modules/same (Makefile.am): Augment lib_SOURCES.
82344 2011-05-23  Bruno Haible  <bruno@clisp.org>
82346         safe-write: Move AC_LIBOBJ invocations to module description.
82347         * m4/safe-write.m4 (gl_SAFE_WRITE): Remove macro.
82348         * modules/safe-write (configure.ac): Invoke gl_PREREQ_SAFE_WRITE
82349         instead of gl_SAFE_WRITE.
82350         (Makefile.am): Augment lib_SOURCES.
82352 2011-05-23  Bruno Haible  <bruno@clisp.org>
82354         safe-read: Move AC_LIBOBJ invocations to module description.
82355         * m4/safe-read.m4 (gl_SAFE_READ): Remove macro.
82356         * modules/safe-read (configure.ac): Invoke gl_PREREQ_SAFE_READ instead
82357         of gl_SAFE_READ.
82358         (Makefile.am): Augment lib_SOURCES.
82360 2011-05-23  Bruno Haible  <bruno@clisp.org>
82362         safe-alloc: Move AC_LIBOBJ invocations to module description.
82363         * m4/safe-alloc.m4 (gl_SAFE_ALLOC): Remove AC_LIBOBJ invocation.
82364         * modules/safe-alloc (Makefile.am): Augment lib_SOURCES.
82366 2011-05-23  Bruno Haible  <bruno@clisp.org>
82368         crypto/rijndael: Move AC_LIBOBJ invocations to module description.
82369         * m4/rijndael.m4: Remove file.
82370         * modules/crypto/rijndael (Files): Remove it.
82371         (configure.ac): Remove gl_RIJNDAEL call.
82372         (Makefile.am): Augment lib_SOURCES.
82374 2011-05-23  Bruno Haible  <bruno@clisp.org>
82376         readtokens: Move AC_LIBOBJ invocations to module description.
82377         * m4/readtokens.m4 (gl_READTOKENS): Remove AC_LIBOBJ invocation.
82378         * modules/readtokens (Makefile.am): Augment lib_SOURCES.
82380 2011-05-23  Bruno Haible  <bruno@clisp.org>
82382         read-file: Move AC_LIBOBJ invocations to module description.
82383         * m4/read-file.m4 (gl_FUNC_READ_FILE): Remove macro.
82384         * modules/read-file (configure.ac): Invoke gl_PREREQ_READ_FILE instead
82385         of gl_FUNC_READ_FILE.
82386         (Makefile.am): Augment lib_SOURCES.
82388 2011-05-23  Bruno Haible  <bruno@clisp.org>
82390         quotearg: Move AC_LIBOBJ invocations to module description.
82391         * m4/quotearg.m4 (gl_QUOTEARG): Remove AC_LIBOBJ invocation.
82392         * modules/quotearg (Makefile.am): Augment lib_SOURCES.
82394 2011-05-23  Bruno Haible  <bruno@clisp.org>
82396         quote: Move AC_LIBOBJ invocations to module description.
82397         * m4/quote.m4 (gl_QUOTE): Remove AC_LIBOBJ invocation.
82398         * modules/quote (Makefile.am): Augment lib_SOURCES.
82400 2011-05-23  Bruno Haible  <bruno@clisp.org>
82402         posixver: Move AC_LIBOBJ invocations to module description.
82403         * m4/posixver.m4 (gl_POSIXVER): Remove AC_LIBOBJ invocation.
82404         * modules/posixver (Makefile.am): Augment lib_SOURCES.
82406 2011-05-23  Bruno Haible  <bruno@clisp.org>
82408         posixtm: Move AC_LIBOBJ invocations to module description.
82409         * m4/posixtm.m4 (gl_POSIXTM): Remove AC_LIBOBJ invocation.
82410         * modules/posixtm (Makefile.am): Augment lib_SOURCES.
82412 2011-05-23  Bruno Haible  <bruno@clisp.org>
82414         physmem: Move AC_LIBOBJ invocations to module description.
82415         * m4/physmem.m4 (gl_PHYSMEM): Remove AC_LIBOBJ invocation.
82416         * modules/physmem (Makefile.am): Augment lib_SOURCES.
82418 2011-05-23  Bruno Haible  <bruno@clisp.org>
82420         pagealign_alloc: Move AC_LIBOBJ invocations to module description.
82421         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC): Remove AC_LIBOBJ
82422         invocation.
82423         * modules/pagealign_alloc (Makefile.am): Augment lib_SOURCES.
82425 2011-05-23  Bruno Haible  <bruno@clisp.org>
82427         mpsort: Move AC_LIBOBJ invocations to module description.
82428         * m4/mpsort.m4 (gl_MPSORT): Remove AC_LIBOBJ invocation.
82429         * modules/mpsort (Makefile.am): Augment lib_SOURCES.
82431 2011-05-23  Bruno Haible  <bruno@clisp.org>
82433         modechange: Move AC_LIBOBJ invocations to module description.
82434         * m4/modechange.m4 (gl_MODECHANGE): Remove AC_LIBOBJ invocation.
82435         * modules/modechange (Makefile.am): Augment lib_SOURCES.
82437 2011-05-23  Bruno Haible  <bruno@clisp.org>
82439         mkdir-p: Move AC_LIBOBJ invocations to module description.
82440         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Remove AC_LIBOBJ invocations.
82441         * modules/mkdir-p (Makefile.am): Augment lib_SOURCES.
82443 2011-05-23  Bruno Haible  <bruno@clisp.org>
82445         mkancesdirs: Move AC_LIBOBJ invocations to module description.
82446         * m4/mkancesdirs.m4 (gl_MKANCESDIRS): Remove AC_LIBOBJ invocation.
82447         * modules/mkancesdirs (Makefile.am): Augment lib_SOURCES.
82449 2011-05-23  Bruno Haible  <bruno@clisp.org>
82451         mgetgroups: Move AC_LIBOBJ invocations to module description.
82452         * m4/mgetgroups.m4 (gl_MGETGROUPS): Remove AC_LIBOBJ invocation.
82453         * modules/mgetgroups (Makefile.am): Augment lib_SOURCES.
82455 2011-05-23  Bruno Haible  <bruno@clisp.org>
82457         memxor: Move AC_LIBOBJ invocations to module description.
82458         * m4/memxor.m4 (gl_MEMXOR): Remove AC_LIBOBJ invocation.
82459         * modules/memxor (Makefile.am): Augment lib_SOURCES.
82461 2011-05-23  Bruno Haible  <bruno@clisp.org>
82463         memcoll: Move AC_LIBOBJ invocations to module description.
82464         * m4/memcoll.m4 (gl_MEMCOLL): Remove AC_LIBOBJ invocation.
82465         * modules/memcoll (Makefile.am): Augment lib_SOURCES.
82467 2011-05-23  Bruno Haible  <bruno@clisp.org>
82469         memcasecmp: Move AC_LIBOBJ invocations to module description.
82470         * m4/memcasecmp.m4 (gl_MEMCASECMP): Remove AC_LIBOBJ invocation.
82471         * modules/memcasecmp (Makefile.am): Augment lib_SOURCES.
82473 2011-05-23  Bruno Haible  <bruno@clisp.org>
82475         crypto/md5: Move AC_LIBOBJ invocations to module description.
82476         * m4/md5.m4 (gl_MD5): Remove AC_LIBOBJ invocation.
82477         * modules/crypto/md5 (Makefile.am): Augment lib_SOURCES.
82479 2011-05-23  Bruno Haible  <bruno@clisp.org>
82481         crypto/md4: Move AC_LIBOBJ invocations to module description.
82482         * m4/md4.m4 (gl_MD4): Remove AC_LIBOBJ invocation.
82483         * modules/crypto/md4 (Makefile.am): Augment lib_SOURCES.
82485 2011-05-23  Bruno Haible  <bruno@clisp.org>
82487         crypto/md2: Move AC_LIBOBJ invocations to module description.
82488         * m4/md2.m4: Remove file.
82489         * modules/crypto/md2 (Files): Remove it.
82490         (configure.ac): Remove gl_MD2 call.
82491         (Makefile.am): Augment lib_SOURCES.
82493 2011-05-23  Bruno Haible  <bruno@clisp.org>
82495         long-options: Move AC_LIBOBJ invocations to module description.
82496         * m4/long-options.m4: Remove file.
82497         * modules/long-options (Files): Remove it.
82498         (configure.ac): Remove gl_LONG_OPTIONS call.
82499         (Makefile.am): Augment lib_SOURCES.
82501 2011-05-23  Bruno Haible  <bruno@clisp.org>
82503         i-ring: Move AC_LIBOBJ invocations to module description.
82504         * m4/i-ring.m4 (gl_I_RING): Remove AC_LIBOBJ invocation.
82505         * modules/i-ring (Makefile.am): Augment lib_SOURCES.
82507 2011-05-23  Bruno Haible  <bruno@clisp.org>
82509         idcache: Move AC_LIBOBJ invocations to module description.
82510         * m4/idcache.m4 (gl_IDCACHE): Remove AC_LIBOBJ invocation.
82511         * modules/idcache (Makefile.am): Augment lib_SOURCES.
82513 2011-05-23  Bruno Haible  <bruno@clisp.org>
82515         human: Move AC_LIBOBJ invocations to module description.
82516         * m4/human.m4 (gl_HUMAN): Remove AC_LIBOBJ invocation.
82517         * modules/human (Makefile.am): Augment lib_SOURCES.
82519 2011-05-23  Bruno Haible  <bruno@clisp.org>
82521         crypto/hmac-sha1: Move AC_LIBOBJ invocations to module description.
82522         * m4/hmac-sha1.m4: Remove file.
82523         * modules/crypto/hmac-sha1 (Files): Remove it.
82524         (configure.ac): Remove gl_HMAC_SHA1 call.
82525         (Makefile.am): Augment lib_SOURCES.
82527 2011-05-23  Bruno Haible  <bruno@clisp.org>
82529         crypto/hmac-md5: Move AC_LIBOBJ invocations to module description.
82530         * m4/hmac-md5.m4: Remove file.
82531         * modules/crypto/hmac-md5 (Files): Remove it.
82532         (configure.ac): Remove gl_HMAC_MD5 call.
82533         (Makefile.am): Augment lib_SOURCES.
82535 2011-05-23  Bruno Haible  <bruno@clisp.org>
82537         hash: Move AC_LIBOBJ invocations to module description.
82538         * m4/hash.m4: Remove file.
82539         * modules/hash (Files): Remove it.
82540         (configure.ac): Remove gl_HASH call.
82541         (Makefile.am): Augment lib_SOURCES.
82543 2011-05-23  Bruno Haible  <bruno@clisp.org>
82545         hard-locale: Move AC_LIBOBJ invocations to module description.
82546         * m4/hard-locale.m4 (gl_HARD_LOCALE): Remove AC_LIBOBJ invocation.
82547         * modules/hard-locale (Makefile.am): Augment lib_SOURCES.
82549 2011-05-23  Bruno Haible  <bruno@clisp.org>
82551         getugroups: Move AC_LIBOBJ invocations to module description.
82552         * m4/getugroups.m4 (gl_GETUGROUPS): Remove AC_LIBOBJ invocation.
82553         * modules/getugroups (Makefile.am): Augment lib_SOURCES.
82555 2011-05-23  Bruno Haible  <bruno@clisp.org>
82557         gettime: Move AC_LIBOBJ invocations to module description.
82558         * m4/gettime.m4 (gl_GETTIME): Remove AC_LIBOBJ invocation.
82559         * modules/gettime (Makefile.am): Augment lib_SOURCES.
82561 2011-05-23  Bruno Haible  <bruno@clisp.org>
82563         getndelim2: Move AC_LIBOBJ invocations to module description.
82564         * m4/getndelim2.m4 (gl_GETNDELIM2): Remove AC_LIBOBJ invocation.
82565         * modules/getndelim2 (Makefile.am): Augment lib_SOURCES.
82567 2011-05-23  Bruno Haible  <bruno@clisp.org>
82569         crypto/gc-pbkdf2-sha1: Move AC_LIBOBJ invocations to module description.
82570         * m4/gc-pbkdf2-sha1.m4: Remove file.
82571         * modules/crypto/gc-pbkdf2-sha1 (Files): Remove it.
82572         (configure.ac): Remove gl_GC_PBKDF2_SHA1 call.
82573         (Makefile.am): Augment lib_SOURCES.
82575 2011-05-23  Bruno Haible  <bruno@clisp.org>
82577         fts: Move AC_LIBOBJ invocations to module description.
82578         * m4/fts.m4 (gl_FUNC_FTS_CORE): Move AC_LIBOBJ invocation from here...
82579         * modules/fts (configure.ac): ... to here.
82581 2011-05-23  Bruno Haible  <bruno@clisp.org>
82583         file-type: Move AC_LIBOBJ invocations to module description.
82584         * m4/file-type.m4: Remove file.
82585         * modules/file-type (Files): Remove it.
82586         (configure.ac): Remove gl_FILE_TYPE call.
82587         (Makefile.am): Augment lib_SOURCES.
82589 2011-05-23  Bruno Haible  <bruno@clisp.org>
82591         filenamecat*: Respect rules for use of AC_LIBOBJ.
82592         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT, gl_FILE_NAME_CONCAT_LGPL):
82593         Remove AC_LIBOBJ invocation.
82594         * modules/filenamecat (Makefile.am): Augment lib_SOURCES.
82595         * modules/filenamecat-lgpl (Makefile.am): Augment lib_SOURCES.
82597 2011-05-23  Bruno Haible  <bruno@clisp.org>
82599         filemode: Move AC_LIBOBJ invocations to module description.
82600         * m4/filemode.m4 (gl_FILEMODE): Remove AC_LIBOBJ invocation.
82601         * modules/filemode (Makefile.am): Augment lib_SOURCES.
82603 2011-05-23  Bruno Haible  <bruno@clisp.org>
82605         openat-safer: Move AC_LIBOBJ invocations to module description.
82606         * m4/fcntl-safer.m4 (gl_OPENAT_SAFER): Remove AC_LIBOBJ invocation.
82607         * modules/openat-safer (Makefile.am): Augment lib_SOURCES.
82609 2011-05-23  Bruno Haible  <bruno@clisp.org>
82611         fcntl-safer: Move AC_LIBOBJ invocations to module description.
82612         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove AC_LIBOBJ invocations.
82613         * modules/fcntl-safer (Makefile.am): Augment lib_SOURCES.
82615 2011-05-23  Bruno Haible  <bruno@clisp.org>
82617         exclude: Move AC_LIBOBJ invocations to module description.
82618         * m4/exclude.m4: Remove file.
82619         * modules/exclude (Files): Remove it.
82620         (configure.ac): Remove gl_EXCLUDE call.
82621         (Makefile.am): Augment lib_SOURCES.
82623 2011-05-23  Bruno Haible  <bruno@clisp.org>
82625         dirname*: Respect rules for use of AC_LIBOBJ.
82626         * m4/dirname.m4 (gl_DIRNAME, gl_DIRNAME_LGPL): Remove AC_LIBOBJ
82627         invocations.
82628         * modules/dirname (Makefile.am): Augment lib_SOURCES.
82629         * modules/dirname-lgpl (Makefile.am): Augment lib_SOURCES.
82631 2011-05-23  Bruno Haible  <bruno@clisp.org>
82633         dirent-safer: Move AC_LIBOBJ invocations to module description.
82634         * m4/dirent-safer.m4 (gl_DIRENT_SAFER): Remove AC_LIBOBJ invocation.
82635         * modules/dirent-safer (Makefile.am): Augment lib_SOURCES.
82637 2011-05-23  Bruno Haible  <bruno@clisp.org>
82639         crypto/des: Move AC_LIBOBJ invocations to module description.
82640         * m4/des.m4: Remove file.
82641         * modules/crypto/des (Files): Remove it.
82642         (configure.ac): Remove gl_DES call.
82643         (Makefile.am): Augment lib_SOURCES.
82645 2011-05-23  Bruno Haible  <bruno@clisp.org>
82647         cycle-check: Move AC_LIBOBJ invocations to module description.
82648         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Remove AC_LIBOBJ invocation.
82649         * modules/cycle-check (Makefile.am): Augment lib_SOURCES.
82651 2011-05-23  Bruno Haible  <bruno@clisp.org>
82653         c-strtold: Move AC_LIBOBJ invocations to module description.
82654         * m4/c-strtod.m4 (gl_C_STRTOLD): Remove AC_LIBOBJ invocation.
82655         * modules/c-strtold (Makefile.am): Augment lib_SOURCES.
82657 2011-05-23  Bruno Haible  <bruno@clisp.org>
82659         c-strtod: Move AC_LIBOBJ invocations to module description.
82660         * m4/c-strtod.m4 (gl_C_STRTOD): Remove AC_LIBOBJ invocation.
82661         * modules/c-strtod (Makefile.am): Augment lib_SOURCES.
82663 2011-05-23  Bruno Haible  <bruno@clisp.org>
82665         crc: Move AC_LIBOBJ invocations to module description.
82666         * m4/crc.m4: Remove file.
82667         * modules/crc (Files): Remove it.
82668         (configure.ac): Remove gl_CRC call.
82669         (Makefile.am): Augment lib_SOURCES.
82671 2011-05-23  Bruno Haible  <bruno@clisp.org>
82673         close-stream: Move AC_LIBOBJ invocations to module description.
82674         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove AC_LIBOBJ invocation.
82675         * modules/close-stream (Makefile.am): Augment lib_SOURCES.
82677 2011-05-23  Bruno Haible  <bruno@clisp.org>
82679         closeout: Move AC_LIBOBJ invocations to module description.
82680         * m4/closeout.m4 (gl_CLOSEOUT): Remove AC_LIBOBJ invocation.
82681         * modules/closeout (Makefile.am): Augment lib_SOURCES.
82683 2011-05-23  Bruno Haible  <bruno@clisp.org>
82685         closein: Move AC_LIBOBJ invocations to module description.
82686         * m4/closein.m4 (gl_CLOSEIN): Remove AC_LIBOBJ invocation.
82687         * modules/closein (Makefile.am): Augment lib_SOURCES.
82689 2011-05-23  Bruno Haible  <bruno@clisp.org>
82691         cloexec: Move AC_LIBOBJ invocations to module description.
82692         * m4/cloexec.m4: Remove file.
82693         * modules/cloexec (Files): Remove it.
82694         (configure.ac): Remove gl_CLOEXEC call.
82695         (Makefile.am): Augment lib_SOURCES.
82697 2011-05-23  Bruno Haible  <bruno@clisp.org>
82699         check-version: Move AC_LIBOBJ invocations to module description.
82700         * m4/check-version.m4: Remove file.
82701         * modules/check-version (Files): Remove it.
82702         (configure.ac): Remove gl_CHECK_VERSION call.
82703         (Makefile.am): Augment lib_SOURCES.
82705 2011-05-23  Bruno Haible  <bruno@clisp.org>
82707         chdir-safer: Move AC_LIBOBJ invocations to module description.
82708         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Remove AC_LIBOBJ invocation.
82709         * modules/chdir-safer (Makefile.am): Augment lib_SOURCES.
82711 2011-05-23  Bruno Haible  <bruno@clisp.org>
82713         canonicalize: Move AC_LIBOBJ invocations to module description.
82714         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Remove
82715         AC_LIBOBJ invocation.
82716         * modules/canonicalize (Makefile.am): Augment lib_SOURCES.
82718 2011-05-23  Bruno Haible  <bruno@clisp.org>
82720         canon-host: Move AC_LIBOBJ invocations to module description.
82721         * m4/canon-host.m4 (gl_CANON_HOST): Remove macro.
82722         * modules/canon-host (configure.ac): Invoke gl_PREREQ_CANON_HOST
82723         instead of gl_CANON_HOST.
82724         (Makefile.am): Augment lib_SOURCES.
82726 2011-05-23  Bruno Haible  <bruno@clisp.org>
82728         backupfile: Move AC_LIBOBJ invocations to module description.
82729         * m4/backupfile.m4 (gl_BACKUPFILE): Remove AC_LIBOBJ invocation.
82730         * modules/backupfile (Makefile.am): Augment lib_SOURCES.
82732 2011-05-23  Bruno Haible  <bruno@clisp.org>
82734         argmatch: Move AC_LIBOBJ invocations to module description.
82735         * m4/argmatch.m4: Remove file.
82736         * modules/argmatch (Files): Remove it.
82737         (configure.ac): Remove gl_ARGMATCH call.
82738         (Makefile.am): Augment lib_SOURCES.
82740 2011-05-23  Bruno Haible  <bruno@clisp.org>
82742         crypto/arctwo: Move AC_LIBOBJ invocations to module description.
82743         * m4/arctwo.m4 (gl_ARCTWO): Remove AC_LIBOBJ invocation.
82744         * modules/crypto/arctwo (Makefile.am): Augment lib_SOURCES.
82746 2011-05-23  Bruno Haible  <bruno@clisp.org>
82748         crypto/arcfour: Move AC_LIBOBJ invocations to module description.
82749         * m4/arcfour.m4: Remove file.
82750         * modules/crypto/arcfour (Files): Remove it.
82751         (configure.ac): Remove gl_ARCFOUR call.
82752         (Makefile.am): Augment lib_SOURCES.
82754 2011-05-22  Bruno Haible  <bruno@clisp.org>
82756         write: Move AC_LIBOBJ invocations to module description.
82757         * m4/write.m4 (gl_FUNC_WRITE): Move AC_LIBOBJ invocation from here...
82758         * modules/write (configure.ac): ... to here.
82760 2011-05-22  Bruno Haible  <bruno@clisp.org>
82762         wmemset: Move AC_LIBOBJ invocations to module description.
82763         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Move AC_LIBOBJ invocation from
82764         here...
82765         * modules/wmemset (configure.ac): ... to here.
82767 2011-05-22  Bruno Haible  <bruno@clisp.org>
82769         wmemmove: Move AC_LIBOBJ invocations to module description.
82770         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Move AC_LIBOBJ invocation from
82771         here...
82772         * modules/wmemmove (configure.ac): ... to here.
82774 2011-05-22  Bruno Haible  <bruno@clisp.org>
82776         wmemcpy: Move AC_LIBOBJ invocations to module description.
82777         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Move AC_LIBOBJ invocation from
82778         here...
82779         * modules/wmemcpy (configure.ac): ... to here.
82781 2011-05-22  Bruno Haible  <bruno@clisp.org>
82783         wmemcmp: Move AC_LIBOBJ invocations to module description.
82784         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Move AC_LIBOBJ invocation from
82785         here...
82786         * modules/wmemcmp (configure.ac): ... to here.
82788 2011-05-22  Bruno Haible  <bruno@clisp.org>
82790         wmemchr: Move AC_LIBOBJ invocations to module description.
82791         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Move AC_LIBOBJ invocation from
82792         here...
82793         * modules/wmemchr (configure.ac): ... to here.
82795 2011-05-22  Bruno Haible  <bruno@clisp.org>
82797         wcswidth: Move AC_LIBOBJ invocations to module description.
82798         * m4/wcswidth.m4 (gl_FUNC_WCSWIDTH): Move AC_LIBOBJ invocation from
82799         here...
82800         * modules/wcswidth (configure.ac): ... to here.
82802 2011-05-22  Bruno Haible  <bruno@clisp.org>
82804         wcwidth: Respect rules for use of AC_LIBOBJ.
82805         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Set HAVE_WCWIDTH. Move AC_LIBOBJ
82806         invocation from here...
82807         * modules/wcwidth (configure.ac): ... to here.
82808         (Depends-on): Update conditions.
82810 2011-05-22  Bruno Haible  <bruno@clisp.org>
82812         wctype: Move AC_LIBOBJ invocations to module description.
82813         * m4/wctype.m4 (gl_FUNC_WCTYPE): Set HAVE_WCTYPE. Move AC_LIBOBJ
82814         invocation from here...
82815         * modules/wctype (configure.ac): ... to here.
82816         (Depends-on): Update conditions.
82818 2011-05-22  Bruno Haible  <bruno@clisp.org>
82820         wctrans: Move AC_LIBOBJ invocations to module description.
82821         * m4/wctrans.m4 (gl_FUNC_WCTRANS): Set HAVE_WCTRANS. Move AC_LIBOBJ
82822         invocation from here...
82823         * modules/wctrans (configure.ac): ... to here.
82825 2011-05-22  Bruno Haible  <bruno@clisp.org>
82827         wctomb: Move AC_LIBOBJ invocations to module description.
82828         * m4/wctomb.m4 (gl_FUNC_WCTOMB): Move AC_LIBOBJ and gl_PREREQ_WCTOMB
82829         invocations from here...
82830         * modules/wctomb (configure.ac): ... to here.
82832 2011-05-22  Bruno Haible  <bruno@clisp.org>
82834         wctob: Move AC_LIBOBJ invocations to module description.
82835         * m4/wctob.m4 (gl_FUNC_WCTOB): Set HAVE_WCTOB. Move AC_LIBOBJ and
82836         gl_PREREQ_WCTOB invocations from here...
82837         * modules/wctob (configure.ac): ... to here.
82838         (Depends-on): Update conditions.
82840 2011-05-22  Bruno Haible  <bruno@clisp.org>
82842         wcsxfrm: Move AC_LIBOBJ invocations to module description.
82843         * m4/wcsxfrm.m4 (gl_FUNC_WCSXFRM): Move AC_LIBOBJ invocation from
82844         here...
82845         * modules/wcsxfrm (configure.ac): ... to here.
82847 2011-05-22  Bruno Haible  <bruno@clisp.org>
82849         wcstok: Move AC_LIBOBJ invocations to module description.
82850         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Move AC_LIBOBJ invocation from here...
82851         * modules/wcstok (configure.ac): ... to here.
82853 2011-05-22  Bruno Haible  <bruno@clisp.org>
82855         wcsstr: Move AC_LIBOBJ invocations to module description.
82856         * m4/wcsstr.m4 (gl_FUNC_WCSSTR): Move AC_LIBOBJ invocation from here...
82857         * modules/wcsstr (configure.ac): ... to here.
82859 2011-05-22  Bruno Haible  <bruno@clisp.org>
82861         wcsspn: Move AC_LIBOBJ invocations to module description.
82862         * m4/wcsspn.m4 (gl_FUNC_WCSSPN): Move AC_LIBOBJ invocation from here...
82863         * modules/wcsspn (configure.ac): ... to here.
82865 2011-05-22  Bruno Haible  <bruno@clisp.org>
82867         wcsrtombs: Move AC_LIBOBJ invocations to module description.
82868         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): Move AC_LIBOBJ and
82869         gl_PREREQ_WCSRTOMBS invocations from here...
82870         * modules/wcsrtombs (configure.ac): ... to here.
82872 2011-05-22  Bruno Haible  <bruno@clisp.org>
82874         wcsrchr: Move AC_LIBOBJ invocations to module description.
82875         * m4/wcsrchr.m4 (gl_FUNC_WCSRCHR): Move AC_LIBOBJ invocation from
82876         here...
82877         * modules/wcsrchr (configure.ac): ... to here.
82879 2011-05-22  Bruno Haible  <bruno@clisp.org>
82881         wcspbrk: Move AC_LIBOBJ invocations to module description.
82882         * m4/wcspbrk.m4 (gl_FUNC_WCSPBRK): Move AC_LIBOBJ invocation from
82883         here...
82884         * modules/wcspbrk (configure.ac): ... to here.
82886 2011-05-22  Bruno Haible  <bruno@clisp.org>
82888         wcsnrtombs: Move AC_LIBOBJ invocations to module description.
82889         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): Move AC_LIBOBJ and
82890         gl_PREREQ_WCSNRTOMBS invocations from here...
82891         * modules/wcsnrtombs (configure.ac): ... to here.
82893 2011-05-22  Bruno Haible  <bruno@clisp.org>
82895         wcsnlen: Move AC_LIBOBJ invocations to module description.
82896         * m4/wcsnlen.m4 (gl_FUNC_WCSNLEN): Move AC_LIBOBJ invocation from
82897         here...
82898         * modules/wcsnlen (configure.ac): ... to here.
82900 2011-05-22  Bruno Haible  <bruno@clisp.org>
82902         wcsncpy: Move AC_LIBOBJ invocations to module description.
82903         * m4/wcsncpy.m4 (gl_FUNC_WCSNCPY): Move AC_LIBOBJ invocation from
82904         here...
82905         * modules/wcsncpy (configure.ac): ... to here.
82907 2011-05-22  Bruno Haible  <bruno@clisp.org>
82909         wcsncmp: Move AC_LIBOBJ invocations to module description.
82910         * m4/wcsncmp.m4 (gl_FUNC_WCSNCMP): Move AC_LIBOBJ invocation from
82911         here...
82912         * modules/wcsncmp (configure.ac): ... to here.
82914 2011-05-22  Bruno Haible  <bruno@clisp.org>
82916         wcsncat: Move AC_LIBOBJ invocations to module description.
82917         * m4/wcsncat.m4 (gl_FUNC_WCSNCAT): Move AC_LIBOBJ invocation from
82918         here...
82919         * modules/wcsncat (configure.ac): ... to here.
82921 2011-05-22  Bruno Haible  <bruno@clisp.org>
82923         wcsncasecmp: Move AC_LIBOBJ invocations to module description.
82924         * m4/wcsncasecmp.m4 (gl_FUNC_WCSNCASECMP): Move AC_LIBOBJ invocation
82925         from here...
82926         * modules/wcsncasecmp (configure.ac): ... to here.
82928 2011-05-22  Bruno Haible  <bruno@clisp.org>
82930         wcslen: Move AC_LIBOBJ invocations to module description.
82931         * m4/wcslen.m4 (gl_FUNC_WCSLEN): Move AC_LIBOBJ invocation from here...
82932         * modules/wcslen (configure.ac): ... to here.
82934 2011-05-22  Bruno Haible  <bruno@clisp.org>
82936         wcsdup: Move AC_LIBOBJ invocations to module description.
82937         * m4/wcsdup.m4 (gl_FUNC_WCSDUP): Move AC_LIBOBJ invocation from here...
82938         * modules/wcsdup (configure.ac): ... to here.
82940 2011-05-22  Bruno Haible  <bruno@clisp.org>
82942         wcscspn: Move AC_LIBOBJ invocations to module description.
82943         * m4/wcscspn.m4 (gl_FUNC_WCSCSPN): Move AC_LIBOBJ invocation from
82944         here...
82945         * modules/wcscspn (configure.ac): ... to here.
82947 2011-05-22  Bruno Haible  <bruno@clisp.org>
82949         wcscpy: Move AC_LIBOBJ invocations to module description.
82950         * m4/wcscpy.m4 (gl_FUNC_WCSCPY): Move AC_LIBOBJ invocation from here...
82951         * modules/wcscpy (configure.ac): ... to here.
82953 2011-05-22  Bruno Haible  <bruno@clisp.org>
82955         wcscoll: Move AC_LIBOBJ invocations to module description.
82956         * m4/wcscoll.m4 (gl_FUNC_WCSCOLL): Move AC_LIBOBJ invocation from
82957         here...
82958         * modules/wcscoll (configure.ac): ... to here.
82960 2011-05-22  Bruno Haible  <bruno@clisp.org>
82962         wcscmp: Move AC_LIBOBJ invocations to module description.
82963         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Move AC_LIBOBJ invocation from here...
82964         * modules/wcscmp (configure.ac): ... to here.
82966 2011-05-22  Bruno Haible  <bruno@clisp.org>
82968         wcschr: Move AC_LIBOBJ invocations to module description.
82969         * m4/wcschr.m4 (gl_FUNC_WCSCHR): Move AC_LIBOBJ invocation from here...
82970         * modules/wcschr (configure.ac): ... to here.
82972 2011-05-22  Bruno Haible  <bruno@clisp.org>
82974         wcscat: Move AC_LIBOBJ invocations to module description.
82975         * m4/wcscat.m4 (gl_FUNC_WCSCAT): Move AC_LIBOBJ invocation from here...
82976         * modules/wcscat (configure.ac): ... to here.
82978 2011-05-22  Bruno Haible  <bruno@clisp.org>
82980         wcscasecmp: Move AC_LIBOBJ invocations to module description.
82981         * m4/wcscasecmp.m4 (gl_FUNC_WCSCASECMP): Move AC_LIBOBJ invocation from
82982         here...
82983         * modules/wcscasecmp (configure.ac): ... to here.
82985 2011-05-22  Bruno Haible  <bruno@clisp.org>
82987         wcrtomb: Move AC_LIBOBJ invocations to module description.
82988         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Move AC_LIBOBJ and gl_PREREQ_WCRTOMB
82989         invocations from here...
82990         * modules/wcrtomb (configure.ac): ... to here.
82992 2011-05-22  Bruno Haible  <bruno@clisp.org>
82994         wcpncpy: Move AC_LIBOBJ invocations to module description.
82995         * m4/wcpncpy.m4 (gl_FUNC_WCPNCPY): Move AC_LIBOBJ invocation from
82996         here...
82997         * modules/wcpncpy (configure.ac): ... to here.
82999 2011-05-22  Bruno Haible  <bruno@clisp.org>
83001         wcpcpy: Move AC_LIBOBJ invocations to module description.
83002         * m4/wcpcpy.m4 (gl_FUNC_WCPCPY): Move AC_LIBOBJ invocation from here...
83003         * modules/wcpcpy (configure.ac): ... to here.
83005 2011-05-22  Bruno Haible  <bruno@clisp.org>
83007         waitpid: Move AC_LIBOBJ invocations to module description.
83008         * m4/waitpid.m4 (gl_FUNC_WAITPID): Set HAVE_WAITPID. Move AC_LIBOBJ
83009         invocation from here...
83010         * modules/waitpid (configure.ac): ... to here.
83012 2011-05-22  Bruno Haible  <bruno@clisp.org>
83014         utimensat: Move AC_LIBOBJ invocations to module description.
83015         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Move AC_LIBOBJ invocations from
83016         here...
83017         * modules/utimensat (configure.ac): ... to here.
83019 2011-05-22  Bruno Haible  <bruno@clisp.org>
83021         usleep: Move AC_LIBOBJ invocations to module description.
83022         * m4/usleep.m4 (gl_FUNC_USLEEP): Move AC_LIBOBJ invocations from
83023         here...
83024         * modules/usleep (configure.ac): ... to here.
83026 2011-05-22  Bruno Haible  <bruno@clisp.org>
83028         unlockpt: Move AC_LIBOBJ invocations to module description.
83029         * m4/unlockpt.m4 (gl_FUNC_UNLOCKPT): Move AC_LIBOBJ and
83030         gl_PREREQ_UNLOCKPT invocations from here...
83031         * modules/unlockpt (configure.ac): ... to here.
83033 2011-05-22  Bruno Haible  <bruno@clisp.org>
83035         unlink: Respect rules for use of AC_LIBOBJ.
83036         * m4/unlink.m4 (gl_FUNC_UNLINK): Move AC_LIBOBJ invocation from here...
83037         * modules/unlink (configure.ac): ... to here.
83039 2011-05-22  Bruno Haible  <bruno@clisp.org>
83041         uname: Move AC_LIBOBJ invocations to module description.
83042         * m4/uname.m4 (gl_FUNC_UNAME): Call AC_CHECK_FUNCS instead of
83043         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_UNAME invocations from
83044         here...
83045         * modules/uname (configure.ac): ... to here.
83047 2011-05-22  Bruno Haible  <bruno@clisp.org>
83049         ttyname_r: Move AC_LIBOBJ invocations to module description.
83050         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Move AC_LIBOBJ and
83051         gl_PREREQ_TTYNAME_R invocations from here...
83052         * modules/ttyname_r (configure.ac): ... to here.
83054 2011-05-22  Bruno Haible  <bruno@clisp.org>
83056         tsearch: Move AC_LIBOBJ invocations to module description.
83057         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Move AC_LIBOBJ and gl_PREREQ_TSEARCH
83058         invocations from here...
83059         * modules/tsearch (configure.ac): ... to here.
83061 2011-05-22  Bruno Haible  <bruno@clisp.org>
83063         towctrans: Move AC_LIBOBJ invocations to module description.
83064         * m4/towctrans.m4 (gl_FUNC_TOWCTRANS): Set HAVE_TOWCTRANS. Move
83065         AC_LIBOBJ invocation from here...
83066         * modules/towctrans (configure.ac): ... to here.
83068 2011-05-22  Bruno Haible  <bruno@clisp.org>
83070         tmpfile: Move AC_LIBOBJ invocations to module description.
83071         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Move AC_LIBOBJ and gl_PREREQ_TMPFILE
83072         invocations from here...
83073         * modules/tmpfile (configure.ac): ... to here.
83075 2011-05-22  Bruno Haible  <bruno@clisp.org>
83077         times: Move AC_LIBOBJ invocations to module description.
83078         * m4/times.m4 (gl_FUNC_TIMES): Move AC_LIBOBJ invocation from here...
83079         * modules/times (configure.ac): ... to here.
83081 2011-05-22  Bruno Haible  <bruno@clisp.org>
83083         time_r: Move AC_LIBOBJ invocations to module description.
83084         * m4/time_r.m4 (gl_TIME_R): Move AC_LIBOBJ and gl_PREREQ_TIME_R
83085         invocations from here...
83086         * modules/time_r (configure.ac): ... to here.
83088 2011-05-22  Bruno Haible  <bruno@clisp.org>
83090         timegm: Move AC_LIBOBJ invocations to module description.
83091         * m4/timegm.m4 (gl_FUNC_TIMEGM): Move AC_LIBOBJ and gl_PREREQ_TIMEGM
83092         invocations from here...
83093         * modules/timegm (configure.ac): ... to here.
83095 2011-05-22  Bruno Haible  <bruno@clisp.org>
83097         tcgetsid: Move AC_LIBOBJ invocations to module description.
83098         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Set HAVE_TCGETSID. Move AC_LIBOBJ
83099         and gl_PREREQ_TCGETSID invocations from here...
83100         * modules/tcgetsid (configure.ac): ... to here.
83101         (Depends-on): Update conditions.
83103 2011-05-22  Bruno Haible  <bruno@clisp.org>
83105         symlinkat: Move AC_LIBOBJ invocations to module description.
83106         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Move AC_LIBOBJ invocation from
83107         here...
83108         * modules/symlinkat (configure.ac): ... to here.
83110 2011-05-22  Bruno Haible  <bruno@clisp.org>
83112         symlink: Move AC_LIBOBJ invocations to module description.
83113         * m4/symlink.m4 (gl_FUNC_SYMLINK): Move AC_LIBOBJ invocations from
83114         here...
83115         * modules/symlink (configure.ac): ... to here.
83117 2011-05-22  Bruno Haible  <bruno@clisp.org>
83119         strverscmp: Move AC_LIBOBJ invocations to module description.
83120         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Call AC_CHECK_FUNCS instead of
83121         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRVERSCMP invocations
83122         from here...
83123         * modules/strverscmp (configure.ac): ... to here.
83125 2011-05-22  Bruno Haible  <bruno@clisp.org>
83127         strtok_r: Move AC_LIBOBJ invocations to module description.
83128         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_STRTOK_R. Move AC_LIBOBJ
83129         and gl_PREREQ_STRTOK_R invocations from here...
83130         * modules/strtok_r (configure.ac): ... to here.
83131         (Depends-on): Update conditions.
83133 2011-05-22  Bruno Haible  <bruno@clisp.org>
83135         strtoumax: Move AC_LIBOBJ invocations to module description.
83136         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Call AC_CHECK_FUNCS instead of
83137         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOUMAX invocations
83138         from here...
83139         * modules/strtoumax (configure.ac): ... to here.
83141 2011-05-22  Bruno Haible  <bruno@clisp.org>
83143         strtoimax: Move AC_LIBOBJ invocations to module description.
83144         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Call AC_CHECK_FUNCS instead of
83145         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOIMAX invocations
83146         from here...
83147         * modules/strtoimax (configure.ac): ... to here.
83149 2011-05-22  Bruno Haible  <bruno@clisp.org>
83151         strtoull: Move AC_LIBOBJ invocations to module description.
83152         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Call AC_CHECK_FUNCS instead of
83153         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOULL invocations
83154         from here...
83155         * modules/strtoull (configure.ac): ... to here.
83157 2011-05-22  Bruno Haible  <bruno@clisp.org>
83159         strtoll: Move AC_LIBOBJ invocations to module description.
83160         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Call AC_CHECK_FUNCS instead of
83161         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOLL invocations from
83162         here...
83163         * modules/strtoll (configure.ac): ... to here.
83165 2011-05-22  Bruno Haible  <bruno@clisp.org>
83167         strtoul: Move AC_LIBOBJ invocations to module description.
83168         * m4/strtoul.m4 (gl_FUNC_STRTOUL): Call AC_CHECK_FUNCS instead of
83169         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocation from here...
83170         * modules/strtoul (configure.ac): ... to here.
83172 2011-05-22  Bruno Haible  <bruno@clisp.org>
83174         strtol: Move AC_LIBOBJ invocations to module description.
83175         * m4/strtol.m4 (gl_FUNC_STRTOL): Call AC_CHECK_FUNCS instead of
83176         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocation from here...
83177         * modules/strtol (configure.ac): ... to here.
83179 2011-05-22  Bruno Haible  <bruno@clisp.org>
83181         strtod: Move AC_LIBOBJ invocations to module description.
83182         * m4/strtod.m4 (gl_FUNC_STRTOD): Move AC_LIBOBJ and gl_PREREQ_STRTOD
83183         invocations from here...
83184         * modules/strtod (configure.ac): ... to here.
83186 2011-05-22  Bruno Haible  <bruno@clisp.org>
83188         strstr*: Move AC_LIBOBJ invocations to module description.
83189         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Move AC_LIBOBJ
83190         invocations from here...
83191         * modules/strstr-simple (configure.ac): ... to here.
83192         * modules/strstr (configure.ac): ... and here.
83194 2011-05-22  Bruno Haible  <bruno@clisp.org>
83196         strsignal: Move AC_LIBOBJ invocations to module description.
83197         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Set HAVE_STRSIGNAL. Move
83198         AC_LIBOBJ and gl_PREREQ_STRSIGNAL invocations from here...
83199         * modules/strsignal (configure.ac): ... to here.
83200         (Depends-on): Update conditions.
83202 2011-05-22  Bruno Haible  <bruno@clisp.org>
83204         strsep: Move AC_LIBOBJ invocations to module description.
83205         * m4/strsep.m4 (gl_FUNC_STRSEP): Call AC_CHECK_FUNCS instead of
83206         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRSEP invocations from
83207         here...
83208         * modules/strsep (configure.ac): ... to here.
83210 2011-05-22  Bruno Haible  <bruno@clisp.org>
83212         strptime: Move AC_LIBOBJ invocations to module description.
83213         * m4/strptime.m4 (gl_FUNC_STRPTIME): Move AC_LIBOBJ and
83214         gl_PREREQ_STRPTIME invocations from here...
83215         * modules/strptime (configure.ac): ... to here.
83217 2011-05-22  Bruno Haible  <bruno@clisp.org>
83219         strpbrk: Move AC_LIBOBJ invocations to module description.
83220         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Call AC_CHECK_FUNCS instead of
83221         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRPBRK invocations from
83222         here...
83223         * modules/strpbrk (configure.ac): ... to here.
83225 2011-05-22  Bruno Haible  <bruno@clisp.org>
83227         strnlen: Move AC_LIBOBJ invocations to module description.
83228         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Move AC_LIBOBJ and gl_PREREQ_STRNLEN
83229         invocations from here...
83230         * modules/strnlen (configure.ac): ... to here.
83232 2011-05-22  Bruno Haible  <bruno@clisp.org>
83234         strndup: Move AC_LIBOBJ invocations to module description.
83235         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_STRNDUP. Move AC_LIBOBJ
83236         invocations from here...
83237         * modules/strndup (configure.ac): ... to here.
83238         (Depends-on): Update conditions.
83240 2011-05-22  Bruno Haible  <bruno@clisp.org>
83242         strncat: Move AC_LIBOBJ invocations to module description.
83243         * m4/strncat.m4 (gl_FUNC_STRNCAT): Move AC_LIBOBJ and gl_PREREQ_STRNCAT
83244         invocations from here...
83245         * modules/strncat (configure.ac): ... to here.
83247 2011-05-22  Bruno Haible  <bruno@clisp.org>
83249         strdup, strdup-posix: Move AC_LIBOBJ invocations to module description.
83250         * m4/strdup.m4 (gl_FUNC_STRDUP): Move AC_LIBOBJ and gl_PREREQ_STRDUP
83251         invocations from here...
83252         * modules/strdup (configure.ac): ... to here.
83253         * modules/strdup-posix (configure.ac): ... and here.
83255 2011-05-22  Bruno Haible  <bruno@clisp.org>
83257         strcspn: Move AC_LIBOBJ invocations to module description.
83258         * m4/strcspn.m4 (gl_FUNC_STRCSPN): Call AC_CHECK_FUNCS instead of
83259         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRCSPN invocations from
83260         here...
83261         * modules/strcspn (configure.ac): ... to here.
83263 2011-05-22  Bruno Haible  <bruno@clisp.org>
83265         strchrnul: Move AC_LIBOBJ invocations to module description.
83266         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Move AC_LIBOBJ and
83267         gl_PREREQ_STRCHRNUL invocations from here...
83268         * modules/strchrnul (configure.ac): ... to here.
83270 2011-05-22  Bruno Haible  <bruno@clisp.org>
83272         strcasestr*: Move AC_LIBOBJ invocations to module description.
83273         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE, gl_FUNC_STRCASESTR):
83274         Move AC_LIBOBJ and gl_PREREQ_STRCASESTR invocations from here...
83275         * modules/strcasestr-simple (configure.ac): ... to here.
83276         * modules/strcasestr (configure.ac): ... and here.
83278 2011-05-22  Bruno Haible  <bruno@clisp.org>
83280         strcase: Move AC_LIBOBJ invocations to module description.
83281         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Set HAVE_STRNCASECMP.
83282         (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Call AC_CHECK_FUNCS instead
83283         of AC_REPLACE_FUNCS. Move AC_LIBOBJ, gl_PREREQ_STRCASECMP,
83284         gl_PREREQ_STRNCASECMP invocations from here...
83285         * modules/strcase (configure.ac): ... to here.
83287 2011-05-22  Bruno Haible  <bruno@clisp.org>
83289         stpncpy: Move AC_LIBOBJ invocations to module description.
83290         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Move AC_LIBOBJ invocations from
83291         here...
83292         * modules/stpncpy (configure.ac): ... to here.
83294 2011-05-22  Bruno Haible  <bruno@clisp.org>
83296         stpcpy: Move AC_LIBOBJ invocations to module description.
83297         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Call AC_CHECK_FUNCS instead of
83298         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STPCPY invocations from
83299         here...
83300         * modules/stpcpy (configure.ac): ... to here.
83302 2011-05-21  Bruno Haible  <bruno@clisp.org>
83304         stat: Move AC_LIBOBJ invocations to module description.
83305         * m4/stat.m4 (gl_PREREQ_STAT): New macro, extracted from gl_FUNC_STAT.
83306         (gl_FUNC_STAT): Move AC_LIBOBJ and gl_PREREQ_STAT invocations from
83307         here...
83308         * modules/stat (configure.ac): ... to here.
83310 2011-05-21  Bruno Haible  <bruno@clisp.org>
83312         sleep: Move AC_LIBOBJ invocations to module description.
83313         * m4/sleep.m4 (gl_FUNC_SLEEP): Move AC_LIBOBJ invocations from here...
83314         * modules/sleep (configure.ac): ... to here.
83316 2011-05-21  Bruno Haible  <bruno@clisp.org>
83318         signbit: Move AC_LIBOBJ invocations to module description.
83319         * m4/signbit.m4 (gl_SIGNBIT): Move AC_LIBOBJ invocations from here...
83320         * modules/signbit (configure.ac): ... to here.
83322 2011-05-21  Bruno Haible  <bruno@clisp.org>
83324         sigprocmask: Move AC_LIBOBJ invocations to module description.
83325         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Move AC_LIBOBJ and
83326         gl_PREREQ_SIGPROMASK invocations from here...
83327         * modules/sigprocmask (configure.ac): ... to here.
83329 2011-05-21  Bruno Haible  <bruno@clisp.org>
83331         sigaction: Move AC_LIBOBJ invocations to module description.
83332         * m4/sigaction.m4 (gl_SIGACTION): Move AC_LIBOBJ and
83333         gl_PREREQ_SIGACTION invocations from here...
83334         * modules/sigaction (configure.ac): ... to here.
83336 2011-05-21  Bruno Haible  <bruno@clisp.org>
83338         sig2str: Move AC_LIBOBJ invocations to module description.
83339         * m4/sig2str.m4 (gl_FUNC_SIG2STR): Call AC_CHECK_FUNCS instead of
83340         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_SIG2STR invocations from
83341         here...
83342         * modules/sig2str (configure.ac): ... to here.
83344 2011-05-21  Bruno Haible  <bruno@clisp.org>
83346         setlocale: Move AC_LIBOBJ invocations to module description.
83347         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Move AC_LIBOBJ and
83348         gl_PREREQ_SETLOCALE invocations from here...
83349         * modules/setlocale (configure.ac): ... to here.
83351 2011-05-21  Bruno Haible  <bruno@clisp.org>
83353         unsetenv: Move AC_LIBOBJ invocations to module description.
83354         * m4/setenv.m4 (gl_FUNC_UNSETENV): Set HAVE_UNSETENV. Move AC_LIBOBJ
83355         and gl_PREREQ_UNSETENV invocations from here...
83356         * modules/unsetenv (configure.ac): ... to here.
83357         (Depends-on): Update.
83359 2011-05-21  Bruno Haible  <bruno@clisp.org>
83361         setenv: Move AC_LIBOBJ invocations to module description.
83362         * m4/setenv.m4 (gl_FUNC_SETENV): Move AC_LIBOBJ invocations from
83363         here...
83364         * modules/setenv (configure.ac): ... to here.
83366 2011-05-21  Bruno Haible  <bruno@clisp.org>
83368         selinux-h: Move AC_LIBOBJ invocations to module description.
83369         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Move
83370         AC_LIBOBJ invocation from here...
83371         * modules/selinux-h (configure.ac): ... to here.
83373 2011-05-21  Bruno Haible  <bruno@clisp.org>
83375         select: Respect rules for use of AC_LIBOBJ.
83376         * m4/select.m4 (gl_FUNC_SELECT): Move AC_LIBOBJ invocations from
83377         here...
83378         * modules/select (configure.ac): ... to here.
83380 2011-05-21  Bruno Haible  <bruno@clisp.org>
83382         scandir: Move AC_LIBOBJ invocations to module description.
83383         * m4/scandir.m4 (gl_FUNC_SCANDIR): Move AC_LIBOBJ and gl_PREREQ_SCANDIR
83384         invocations from here...
83385         * modules/scandir (configure.ac): ... to here.
83387 2011-05-21  Bruno Haible  <bruno@clisp.org>
83389         rpmatch: Move AC_LIBOBJ invocations to module description.
83390         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Call AC_CHECK_FUNCS instead of
83391         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_RPMATCH invocations from
83392         here...
83393         * modules/rpmatch (configure.ac): ... to here.
83395 2011-05-21  Bruno Haible  <bruno@clisp.org>
83397         rmdir: Respect rules for use of AC_LIBOBJ.
83398         * m4/rmdir.m4 (gl_FUNC_RMDIR): Move AC_LIBOBJ invocation from here...
83399         * modules/rmdir (configure.ac): ... to here.
83401 2011-05-21  Bruno Haible  <bruno@clisp.org>
83403         renameat: Move AC_LIBOBJ invocations to module description.
83404         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Move AC_LIBOBJ invocations from
83405         here...
83406         * modules/renameat (configure.ac): ... to here.
83408 2011-05-21  Bruno Haible  <bruno@clisp.org>
83410         rename: Respect rules for use of AC_LIBOBJ.
83411         * m4/rename.m4 (gl_FUNC_RENAME): Move AC_LIBOBJ invocations from
83412         here...
83413         * modules/rename (configure.ac): ... to here.
83415 2011-05-21  Bruno Haible  <bruno@clisp.org>
83417         remove: Move AC_LIBOBJ invocations to module description.
83418         * m4/remove.m4 (gl_FUNC_REMOVE): Move AC_LIBOBJ invocations from
83419         here...
83420         * modules/remove (configure.ac): ... to here.
83422 2011-05-21  Bruno Haible  <bruno@clisp.org>
83424         relocatable-lib: Move AC_LIBOBJ invocations to module description.
83425         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_SEPARATE): Remove
83426         macro.
83427         (gl_RELOCATABLE_LIBRARY): Move AC_LIBOBJ invocation from here...
83428         * modules/relocatable-lib (configure.ac): ... to here.
83429         * modules/relocatable-prog-wrapper (configure.ac): Invoke
83430         gl_RELOCATABLE_LIBRARY instead of gl_RELOCATABLE_LIBRARY_SEPARATE.
83432 2011-05-21  Bruno Haible  <bruno@clisp.org>
83434         relocatable-prog: Move AC_LIBOBJ invocations to module description.
83435         * m4/relocatable.m4 (gl_RELOCATABLE): Move AC_LIBOBJ invocation from
83436         here...
83437         * modules/relocatable-prog (configure.ac): ... to here.
83439 2011-05-21  Bruno Haible  <bruno@clisp.org>
83441         regex: Move AC_LIBOBJ invocations to module description.
83442         * m4/regex.m4 (gl_REGEX): Move AC_LIBOBJ and gl_PREREQ_REGEX
83443         invocations from here...
83444         * modules/regex (configure.ac): ... to here.
83446 2011-05-21  Bruno Haible  <bruno@clisp.org>
83448         realloc-*: Move AC_LIBOBJ invocations to module description.
83449         * m4/realloc.m4 (gl_REPLACE_REALLOC): Remove macro.
83450         (gl_FUNC_REALLOC_GNU, gl_FUNC_REALLOC_POSIX): Inline it here. Move
83451         AC_LIBOBJ invocations from here...
83452         * modules/realloc-gnu (configure.ac): ... to here.
83453         * modules/realloc-posix (configure.ac): ... and here.
83455 2011-05-21  Bruno Haible  <bruno@clisp.org>
83457         readutmp: Move AC_LIBOBJ invocations to module description.
83458         * m4/readutmp.m4 (gl_READUTMP): Move AC_LIBOBJ invocation from here...
83459         * modules/readutmp (configure.ac): ... to here.
83461 2011-05-21  Bruno Haible  <bruno@clisp.org>
83463         readlinkat: Move AC_LIBOBJ invocations to module description.
83464         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Move AC_LIBOBJ invocation from
83465         here...
83466         * modules/readlinkat (configure.ac): ... to here.
83468 2011-05-21  Bruno Haible  <bruno@clisp.org>
83470         readlink: Move AC_LIBOBJ invocations to module description.
83471         * m4/readlink.m4 (gl_FUNC_READLINK): Move AC_LIBOBJ and
83472         gl_PREREQ_READLINK invocations from here...
83473         * modules/readlink (configure.ac): ... to here.
83475 2011-05-21  Bruno Haible  <bruno@clisp.org>
83477         readline: Move AC_LIBOBJ invocations to module description.
83478         * m4/readline.m4 (gl_FUNC_READLINE): Move AC_LIBOBJ and
83479         gl_PREREQ_READLINE invocations from here...
83480         * modules/readline (configure.ac): ... to here.
83482 2011-05-21  Bruno Haible  <bruno@clisp.org>
83484         read: Move AC_LIBOBJ invocations to module description.
83485         * m4/read.m4 (gl_FUNC_READ): Move AC_LIBOBJ invocation from here...
83486         * modules/read (configure.ac): ... to here.
83488 2011-05-21  Bruno Haible  <bruno@clisp.org>
83490         rawmemchr: Move AC_LIBOBJ invocations to module description.
83491         * m4/rawmemchr.m4 (gl_FUNC_RAWMEMCHR): Call AC_CHECK_FUNCS instead of
83492         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_RAWMEMCHR invocations
83493         from here...
83494         * modules/rawmemchr (configure.ac): ... to here.
83496 2011-05-21  Bruno Haible  <bruno@clisp.org>
83498         random_r: Move AC_LIBOBJ invocations to module description.
83499         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Move AC_LIBOBJ and
83500         gl_PREREQ_RANDOM_R invocations from here...
83501         * modules/random_r (configure.ac): ... to here.
83503 2011-05-21  Bruno Haible  <bruno@clisp.org>
83505         pwrite: Move AC_LIBOBJ invocations to module description.
83506         * m4/pwrite.m4 (gl_FUNC_PWRITE): Move AC_LIBOBJ invocation from here...
83507         * modules/pwrite (configure.ac): ... to here.
83509 2011-05-21  Bruno Haible  <bruno@clisp.org>
83511         putenv: Move AC_LIBOBJ invocations to module description.
83512         * m4/putenv.m4 (gl_FUNC_PUTENV): Move AC_LIBOBJ invocation from here...
83513         * modules/putenv (configure.ac): ... to here.
83515 2011-05-21  Bruno Haible  <bruno@clisp.org>
83517         login_tty: Move AC_LIBOBJ invocations to module description.
83518         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Move AC_LIBOBJ invocation from here...
83519         * modules/login_tty (configure.ac): ... to here.
83521 2011-05-21  Bruno Haible  <bruno@clisp.org>
83523         openpty: Move AC_LIBOBJ invocations to module description.
83524         * m4/pty.m4 (gl_FUNC_OPENPTY): Move AC_LIBOBJ invocations from here...
83525         * modules/openpty (configure.ac): ... to here.
83527 2011-05-21  Bruno Haible  <bruno@clisp.org>
83529         forkpty: Move AC_LIBOBJ invocations to module description.
83530         * m4/pty.m4 (gl_FUNC_FORKPTY): Move AC_LIBOBJ invocations from here...
83531         * modules/forkpty (configure.ac): ... to here.
83533 2011-05-21  Bruno Haible  <bruno@clisp.org>
83535         ptsname: Move AC_LIBOBJ invocations to module description.
83536         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Move AC_LIBOBJ and gl_PREREQ_PTSNAME
83537         invocations from here...
83538         * modules/ptsname (configure.ac): ... to here.
83540 2011-05-21  Bruno Haible  <bruno@clisp.org>
83542         pread: Move AC_LIBOBJ invocations to module description.
83543         * m4/pread.m4 (gl_FUNC_PREAD): Move AC_LIBOBJ invocation from here...
83544         * modules/pread (configure.ac): ... to here.
83546 2011-05-21  Bruno Haible  <bruno@clisp.org>
83548         posix_spawn*: Move AC_LIBOBJ invocations to module description.
83549         * m4/posix_spawn.m4 (gl_PREREQ_POSIX_SPAWN_INTERNAL): Renamed from
83550         gl_POSIX_SPAWN_INTERNAL. Move AC_LIBOBJ invocation from here...
83551         * modules/posix_spawn (configure.ac): ... to here.
83552         * modules/posix_spawnp (configure.ac): ... and here.
83554 2011-05-21  Bruno Haible  <bruno@clisp.org>
83556         popen: Move AC_LIBOBJ invocations to module description.
83557         * m4/popen.m4 (gl_FUNC_POPEN): Move AC_LIBOBJ and gl_PREREQ_POPEN
83558         invocations from here...
83559         * modules/popen (configure.ac): ... to here.
83561 2011-05-21  Bruno Haible  <bruno@clisp.org>
83563         poll: Move AC_LIBOBJ invocations to module description.
83564         * m4/poll.m4 (gl_FUNC_POLL): Move AC_LIBOBJ and gl_PREREQ_POLL
83565         invocations from here...
83566         * modules/poll (configure.ac): ... to here.
83568 2011-05-21  Bruno Haible  <bruno@clisp.org>
83570         pipe-posix: Move AC_LIBOBJ invocations to module description.
83571         * m4/pipe.m4 (gl_FUNC_PIPE): Move AC_LIBOBJ invocation from here...
83572         * modules/pipe-posix (configure.ac): ... to here.
83574 2011-05-21  Bruno Haible  <bruno@clisp.org>
83576         openat: Respect rules for use of AC_LIBOBJ.
83577         * m4/openat.m4 (gl_FUNC_OPENAT): Call AC_CHECK_FUNCS instead of
83578         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocations from here...
83579         * modules/openat (configure.ac): ... to here.
83581 2011-05-21  Bruno Haible  <bruno@clisp.org>
83583         obstack-printf*: Move AC_LIBOBJ invocations to module description.
83584         * m4/obstack-printf.m4 (gl_REPLACE_OBSTACK_PRINTF): Move AC_LIBOBJ
83585         invocation from here...
83586         * modules/obstack-printf (configure.ac): ... to here.
83587         * modules/obstack-printf-posix (configure.ac): ... and here.
83589 2011-05-21  Bruno Haible  <bruno@clisp.org>
83591         nl_langinfo: Move AC_LIBOBJ invocations to module description.
83592         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Move AC_LIBOBJ invocations
83593         from here...
83594         * modules/nl_langinfo (configure.ac): ... to here.
83596 2011-05-21  Bruno Haible  <bruno@clisp.org>
83598         nanosleep: Move AC_LIBOBJ invocations to module description.
83599         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Move AC_LIBOBJ and
83600         gl_PREREQ_NANOSLEEP invocations from here...
83601         * modules/nanosleep (configure.ac): ... to here.
83603 2011-05-21  Bruno Haible  <bruno@clisp.org>
83605         mountlist: Move AC_LIBOBJ invocations to module description.
83606         * m4/mountlist.m4 (gl_MOUNTLIST): Move AC_LIBOBJ and
83607         gl_PREREQ_MOUNTLIST_EXTRA invocations from here...
83608         * modules/mountlist (configure.ac): ... to here.
83610 2011-05-21  Bruno Haible  <bruno@clisp.org>
83612         mktime: Respect rules for use of AC_LIBOBJ.
83613         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove macro.
83614         (gl_FUNC_MKTIME): Inline it here. Set gl_cv_func_working_mktime. Move
83615         AC_LIBOBJ and gl_PREREQ_MKTIME invocations from here...
83616         (gl_FUNC_MKTIME_INTERNAL): ... and here...
83617         * modules/mktime (configure.ac): ... to here.
83618         * modules/mktime-internal (configure.ac): ... and here.
83619         * m4/timegm.m4 (gl_FUNC_TIMEGM): Update.
83621 2011-05-21  Bruno Haible  <bruno@clisp.org>
83623         mkstemps: Move AC_LIBOBJ invocations to module description.
83624         * m4/mkstemps.m4 (gl_FUNC_MKSTEMPS): Move AC_LIBOBJ invocation from
83625         here...
83626         * modules/mkstemps (configure.ac): ... to here.
83628 2011-05-21  Bruno Haible  <bruno@clisp.org>
83630         mkstemp: Move AC_LIBOBJ invocations to module description.
83631         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Move AC_LIBOBJ and
83632         gl_PREREQ_MKSTEMP invocations from here...
83633         * modules/mkstemp (configure.ac): ... to here.
83635 2011-05-21  Bruno Haible  <bruno@clisp.org>
83637         mkostemps: Move AC_LIBOBJ invocations to module description.
83638         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Move AC_LIBOBJ invocation from
83639         here...
83640         * modules/mkostemps (configure.ac): ... to here.
83642 2011-05-21  Bruno Haible  <bruno@clisp.org>
83644         mkostemp: Move AC_LIBOBJ invocations to module description.
83645         * m4/mkostemp.m4 (gl_FUNC_MKOSTEMP): Move AC_LIBOBJ and
83646         gl_PREREQ_MKOSTEMP invocations from here...
83647         * modules/mkostemp (configure.ac): ... to here.
83649 2011-05-21  Bruno Haible  <bruno@clisp.org>
83651         mknod: Move AC_LIBOBJ invocations to module description.
83652         * m4/mknod.m4 (gl_FUNC_MKNOD): Move AC_LIBOBJ invocations from here...
83653         * modules/mknod (configure.ac): ... to here.
83655 2011-05-21  Bruno Haible  <bruno@clisp.org>
83657         mkfifoat: Move AC_LIBOBJ invocations to module description.
83658         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Move AC_LIBOBJ invocations from
83659         here...
83660         * modules/mkfifoat (configure.ac): ... to here.
83662 2011-05-21  Bruno Haible  <bruno@clisp.org>
83664         mkfifo: Respect rules for use of AC_LIBOBJ.
83665         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Move AC_LIBOBJ invocations from
83666         here...
83667         * modules/mkfifo (configure.ac): ... to here.
83669 2011-05-21  Bruno Haible  <bruno@clisp.org>
83671         mkdtemp: Move AC_LIBOBJ invocations to module description.
83672         * m4/mkdtemp.m4 (gl_FUNC_MKDTEMP): Move AC_LIBOBJ and gl_PREREQ_MKDTEMP
83673         invocations from here...
83674         * modules/mkdtemp (configure.ac): ... to here.
83676 2011-05-21  Bruno Haible  <bruno@clisp.org>
83678         mkdir: Move AC_LIBOBJ invocations to module description.
83679         * m4/mkdir.m4 (gl_FUNC_MKDIR): Move AC_LIBOBJ invocations from here...
83680         * modules/mkdir (configure.ac): ... to here.
83682 2011-05-21  Bruno Haible  <bruno@clisp.org>
83684         memset: Move AC_LIBOBJ invocations to module description.
83685         * m4/memset.m4 (gl_FUNC_MEMSET): Call AC_CHECK_FUNCS instead of
83686         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMSET invocations from
83687         here...
83688         * modules/memset (configure.ac): ... to here.
83690 2011-05-21  Bruno Haible  <bruno@clisp.org>
83692         memrchr: Move AC_LIBOBJ invocations to module description.
83693         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Call AC_CHECK_FUNCS instead of
83694         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMRCHR invocations from
83695         here...
83696         * modules/memrchr (configure.ac): ... to here.
83698 2011-05-21  Bruno Haible  <bruno@clisp.org>
83700         mempcpy: Move AC_LIBOBJ invocations to module description.
83701         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Call AC_CHECK_FUNCS instead of
83702         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMPCPY invocations from
83703         here...
83704         * modules/mempcpy (configure.ac): ... to here.
83706 2011-05-21  Bruno Haible  <bruno@clisp.org>
83708         memmove: Move AC_LIBOBJ invocations to module description.
83709         * m4/memmove.m4 (gl_FUNC_MEMMOVE): Call AC_CHECK_FUNCS instead of
83710         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMMOVE invocations from
83711         here...
83712         * modules/memmove (configure.ac): ... to here.
83714 2011-05-21  Bruno Haible  <bruno@clisp.org>
83716         memmem*: Move AC_LIBOBJ invocations to module description.
83717         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Call AC_CHECK_FUNCS instead of
83718         AC_REPLACE_FUNCS. Set HAVE_MEMMEM. Move AC_LIBOBJ invocations from
83719         here...
83720         (gl_FUNC_MEMMEM): ... and here...
83721         * modules/memmem-simple (configure.ac): ... to here.
83722         * modules/memmem (configure.ac): ... and here.
83724 2011-05-21  Bruno Haible  <bruno@clisp.org>
83726         memcpy: Move AC_LIBOBJ invocations to module description.
83727         * m4/memcpy.m4 (gl_FUNC_MEMCPY): Call AC_CHECK_FUNCS instead of
83728         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMCPY invocations from
83729         here...
83730         * modules/memcpy (configure.ac): ... to here.
83732 2011-05-21  Bruno Haible  <bruno@clisp.org>
83734         memcmp: Simplify autoconf macro.
83735         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Merge the cross-compilation code into
83736         the AC_RUN_IFELSE invocation. Set gl_func_memcmp.
83737         * modules/memcmp (Depends-on, configure.ac): Test gl_func_memcmp.
83739 2011-05-21  Bruno Haible  <bruno@clisp.org>
83741         memcmp: Move AC_LIBOBJ invocations to module description.
83742         * m4/memcmp.m4 (AC_FUNC_MEMCMP): Remove macro.
83743         (gl_FUNC_MEMCMP): Inline it here. Set gl_cv_func_memcmp_working. Move
83744         AC_LIBOBJ and gl_PREREQ_MEMCMP invocations from here...
83745         * modules/memcmp (configure.ac): ... to here.
83746         (Depends-on): Update conditions.
83748 2011-05-21  Bruno Haible  <bruno@clisp.org>
83750         memchr: Respect rules for use of AC_LIBOBJ.
83751         * m4/memchr.m4 (gl_FUNC_MEMCHR): Move AC_LIBOBJ and gl_PREREQ_MEMCHR
83752         invocations from here...
83753         * modules/memchr (configure.ac): ... to here.
83755 2011-05-21  Bruno Haible  <bruno@clisp.org>
83757         mbtowc: Move AC_LIBOBJ invocations to module description.
83758         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Move AC_LIBOBJ and gl_PREREQ_MBTOWC
83759         invocations from here...
83760         * modules/mbtowc (configure.ac): ... to here.
83762 2011-05-21  Bruno Haible  <bruno@clisp.org>
83764         mbsrtowcs: Move AC_LIBOBJ invocations to module description.
83765         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Move AC_LIBOBJ and
83766         gl_PREREQ_MBSRTOWCS invocations from here...
83767         * modules/mbsrtowcs (configure.ac): ... to here.
83769 2011-05-21  Bruno Haible  <bruno@clisp.org>
83771         mbsnrtowcs: Move AC_LIBOBJ invocations to module description.
83772         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Move AC_LIBOBJ and
83773         gl_PREREQ_MBSNRTOWCS invocations from here...
83774         * modules/mbsnrtowcs (configure.ac): ... to here.
83776 2011-05-21  Bruno Haible  <bruno@clisp.org>
83778         mbsinit: Move AC_LIBOBJ invocations to module description.
83779         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Move AC_LIBOBJ and gl_PREREQ_MBSINIT
83780         invocations from here...
83781         * modules/mbsinit (configure.ac): ... to here.
83783 2011-05-21  Bruno Haible  <bruno@clisp.org>
83785         mbrlen: Move AC_LIBOBJ invocations to module description.
83786         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): Move AC_LIBOBJ and gl_PREREQ_MBRLEN
83787         invocations from here...
83788         * modules/mbrlen (configure.ac): ... to here.
83790 2011-05-21  Bruno Haible  <bruno@clisp.org>
83792         mbrtowc: Respect rules for use of AC_LIBOBJ.
83793         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Move AC_LIBOBJ and gl_PREREQ_MBRTOWC
83794         invocations from here...
83795         * modules/mbrtowc (configure.ac): ... to here.
83797 2011-05-21  Bruno Haible  <bruno@clisp.org>
83799         malloc-*: Move AC_LIBOBJ invocations to module description.
83800         * m4/malloc.m4 (gl_REPLACE_MALLOC): Remove macro.
83801         (gl_FUNC_MALLOC_GNU, gl_FUNC_MALLOC_POSIX): Inline it here. Move
83802         AC_LIBOBJ invocations from here...
83803         * modules/malloc-gnu (configure.ac): ... to here.
83804         * modules/malloc-posix (configure.ac): ... and here.
83806 2011-05-21  Bruno Haible  <bruno@clisp.org>
83808         lstat, openat: Respect rules for use of AC_LIBOBJ.
83809         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Renamed from
83810         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK. Set variable
83811         gl_cv_func_lstat_dereferences_slashed_symlink. Don't invoke AC_LIBOBJ.
83812         (gl_PREREQ_LSTAT): New macro, extracted from gl_FUNC_LSTAT.
83813         (gl_FUNC_LSTAT): Update. Remove gl_PREREQ_LSTAT code.
83814         * modules/lstat (configure.ac): Invoke AC_LIBOBJ and gl_PREREQ_LSTAT
83815         here.
83816         * m4/openat.m4 (gl_FUNC_OPENAT): Update.
83818 2011-05-21  Bruno Haible  <bruno@clisp.org>
83820         lseek: Move AC_LIBOBJ invocations to module description.
83821         * m4/lseek.m4 (gl_REPLACE_LSEEK): Remove macro.
83822         (gl_FUNC_LSEEK): Inline it here. Move AC_LIBOBJ invocation from here...
83823         * modules/lseek (configure.ac): ... to here.
83825 2011-05-21  Bruno Haible  <bruno@clisp.org>
83827         linkat: Move AC_LIBOBJ invocations to module description.
83828         * m4/linkat.m4 (gl_FUNC_LINKAT): Move AC_LIBOBJ invocations from
83829         here...
83830         * modules/linkat (configure.ac): ... to here.
83832 2011-05-21  Bruno Haible  <bruno@clisp.org>
83834         link: Respect rules for use of AC_LIBOBJ.
83835         * m4/link.m4 (gl_FUNC_LINK): Move AC_LIBOBJ invocations from here...
83836         * modules/link (configure.ac): ... to here.
83838 2011-05-21  Bruno Haible  <bruno@clisp.org>
83840         lchown: Move AC_LIBOBJ invocations to module description.
83841         * m4/lchown.m4 (gl_FUNC_EUIDACCESS): Call AC_CHECK_FUNCS instead of
83842         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocations from here...
83843         * modules/lchown (configure.ac): ... to here.
83845 2011-05-21  Bruno Haible  <bruno@clisp.org>
83847         iswctype: Move AC_LIBOBJ invocations to module description.
83848         * m4/iswctype.m4 (gl_FUNC_ISWCTYPE): Move AC_LIBOBJ invocation from
83849         here...
83850         * modules/iswctype (configure.ac): ... to here.
83852 2011-05-21  Bruno Haible  <bruno@clisp.org>
83854         iswblank: Move AC_LIBOBJ invocations to module description.
83855         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Move AC_LIBOBJ invocation from
83856         here...
83857         * modules/iswblank (configure.ac): ... to here.
83859 2011-05-21  Bruno Haible  <bruno@clisp.org>
83861         atanl: Move AC_LIBOBJ invocations to module description.
83862         * m4/atanl.m4 (gl_FUNC_ATANL): Move AC_LIBOBJ invocation from here...
83863         * modules/atanl (configure.ac): ... to here.
83865 2011-05-21  Bruno Haible  <bruno@clisp.org>
83867         acosl: Move AC_LIBOBJ invocations to module description.
83868         * m4/acosl.m4 (gl_FUNC_ACOSL): Move AC_LIBOBJ invocation from here...
83869         * modules/acosl (configure.ac): ... to here.
83871 2011-05-21  Bruno Haible  <bruno@clisp.org>
83873         asinl: Respect rules for use of AC_LIBOBJ.
83874         * m4/asinl.m4 (gl_FUNC_ASINL): Move AC_LIBOBJ invocation from here...
83875         * modules/asinl (configure.ac): ... to here.
83877 2011-05-21  Bruno Haible  <bruno@clisp.org>
83879         tanl: Move AC_LIBOBJ invocations to module description.
83880         * m4/tanl.m4 (gl_FUNC_TANL): Move AC_LIBOBJ invocations from here...
83881         * modules/tanl (configure.ac): ... to here.
83883 2011-05-21  Bruno Haible  <bruno@clisp.org>
83885         cosl: Move AC_LIBOBJ invocations to module description.
83886         * m4/cosl.m4 (gl_FUNC_COSL): Move AC_LIBOBJ invocations from here...
83887         * modules/cosl (configure.ac): ... to here.
83889 2011-05-21  Bruno Haible  <bruno@clisp.org>
83891         sinl: Move AC_LIBOBJ invocations to module description.
83892         * m4/sinl.m4 (gl_FUNC_SINL): Move AC_LIBOBJ invocations from here...
83893         * modules/sinl (configure.ac): ... to here.
83895 2011-05-21  Bruno Haible  <bruno@clisp.org>
83897         logl: Move AC_LIBOBJ invocations to module description.
83898         * m4/logl.m4 (gl_FUNC_LOGL): Move AC_LIBOBJ invocation from here...
83899         * modules/logl (configure.ac): ... to here.
83901 2011-05-21  Bruno Haible  <bruno@clisp.org>
83903         expl: Move AC_LIBOBJ invocations to module description.
83904         * m4/expl.m4 (gl_FUNC_EXPL): Move AC_LIBOBJ invocation from here...
83905         * modules/expl (configure.ac): ... to here.
83907 2011-05-21  Bruno Haible  <bruno@clisp.org>
83909         roundl: Move AC_LIBOBJ invocations to module description.
83910         * m4/roundl.m4 (gl_FUNC_ROUNDL): Move AC_LIBOBJ invocation from here...
83911         * modules/roundl (configure.ac): ... to here.
83913 2011-05-21  Bruno Haible  <bruno@clisp.org>
83915         round: Move AC_LIBOBJ invocations to module description.
83916         * m4/round.m4 (gl_FUNC_ROUND): Move AC_LIBOBJ invocation from here...
83917         * modules/round (configure.ac): ... to here.
83919 2011-05-21  Bruno Haible  <bruno@clisp.org>
83921         roundf: Move AC_LIBOBJ invocations to module description.
83922         * m4/roundf.m4 (gl_FUNC_ROUNDF): Move AC_LIBOBJ invocation from here...
83923         * modules/roundf (configure.ac): ... to here.
83925 2011-05-21  Bruno Haible  <bruno@clisp.org>
83927         truncl: Move AC_LIBOBJ invocations to module description.
83928         * m4/truncl.m4 (gl_FUNC_TRUNCL): Move AC_LIBOBJ invocation from here...
83929         * modules/truncl (configure.ac): ... to here.
83931 2011-05-21  Bruno Haible  <bruno@clisp.org>
83933         trunc: Move AC_LIBOBJ invocations to module description.
83934         * m4/trunc.m4 (gl_FUNC_TRUNC): Move AC_LIBOBJ invocation from here...
83935         * modules/trunc (configure.ac): ... to here.
83937 2011-05-21  Bruno Haible  <bruno@clisp.org>
83939         truncf: Move AC_LIBOBJ invocations to module description.
83940         * m4/truncf.m4 (gl_FUNC_TRUNCF): Move AC_LIBOBJ invocation from here...
83941         * modules/truncf (configure.ac): ... to here.
83943 2011-05-21  Bruno Haible  <bruno@clisp.org>
83945         ceill: Move AC_LIBOBJ invocations to module description.
83946         * m4/ceill.m4 (gl_FUNC_CEILL): Move AC_LIBOBJ invocation from here...
83947         * modules/ceill (configure.ac): ... to here.
83949 2011-05-21  Bruno Haible  <bruno@clisp.org>
83951         ceil: Move AC_LIBOBJ invocations to module description.
83952         * m4/ceil.m4 (gl_FUNC_CEIL): Move AC_LIBOBJ invocation from here...
83953         * modules/ceil (configure.ac): ... to here.
83955 2011-05-21  Bruno Haible  <bruno@clisp.org>
83957         ceilf: Move AC_LIBOBJ invocations to module description.
83958         * m4/ceilf.m4 (gl_FUNC_CEILF): Move AC_LIBOBJ invocation from here...
83959         * modules/ceilf (configure.ac): ... to here.
83961 2011-05-21  Bruno Haible  <bruno@clisp.org>
83963         floorl: Respect rules for use of AC_LIBOBJ.
83964         * m4/floorl.m4 (gl_FUNC_FLOORL): Move AC_LIBOBJ invocation from here...
83965         * modules/floorl (configure.ac): ... to here.
83967 2011-05-21  Bruno Haible  <bruno@clisp.org>
83969         floor: Respect rules for use of AC_LIBOBJ.
83970         * m4/floor.m4 (gl_FUNC_FLOOR): Move AC_LIBOBJ invocation from here...
83971         * modules/floor (configure.ac): ... to here.
83973 2011-05-21  Bruno Haible  <bruno@clisp.org>
83975         floorf: Move AC_LIBOBJ invocations to module description.
83976         * m4/floorf.m4 (gl_FUNC_FLOORF): Move AC_LIBOBJ invocation from here...
83977         * modules/floorf (configure.ac): ... to here.
83979 2011-05-20  Bruno Haible  <bruno@clisp.org>
83981         sqrtl: Respect rules for use of AC_LIBOBJ.
83982         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Move AC_LIBOBJ invocation from here...
83983         * modules/sqrtl (configure.ac): ... to here.
83985 2011-05-20  Bruno Haible  <bruno@clisp.org>
83987         ldexpl: Respect rules for use of AC_LIBOBJ.
83988         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Move AC_LIBOBJ invocation from here...
83989         * modules/ldexpl (configure.ac): ... to here.
83991 2011-05-20  Bruno Haible  <bruno@clisp.org>
83993         frexpl*: Respect rules for use of AC_LIBOBJ.
83994         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): Move AC_LIBOBJ
83995         invocation from here...
83996         * modules/frexpl (configure.ac): ... to here.
83997         * modules/frexpl-nolibm (configure.ac): ... and here.
83999 2011-05-20  Bruno Haible  <bruno@clisp.org>
84001         frexp, frexp-nolibm: Move AC_LIBOBJ invocations to module description.
84002         * m4/frexp.m4 (gl_FUNC_FREXP, gl_FUNC_FREXP_NO_LIBM): Move AC_LIBOBJ
84003         invocation from here...
84004         * modules/frexp (configure.ac): ... to here.
84005         * modules/frexp-nolibm (configure.ac): ... and here.
84007 2011-05-20  Bruno Haible  <bruno@clisp.org>
84009         isnan: Respect rules for use of AC_LIBOBJ.
84010         * m4/isnan.m4 (gl_ISNAN): Don't do the AC_LIBOBJ and gl_PREREQ_ISNAN*
84011         invocations here.
84012         * modules/isnanf (configure.ac): Require gl_ISNAN if it exists. Test
84013         REPLACE_ISNAN.
84014         * modules/isnand (configure.ac): Likewise.
84015         * modules/isnanl (configure.ac): Likewise.
84017 2011-05-20  Bruno Haible  <bruno@clisp.org>
84019         isnanl*: Respect rules for use of AC_LIBOBJ.
84020         * m4/isnanl.m4 (gl_FUNC_ISNANL, gl_FUNC_ISNANL_NO_LIBM): Move AC_LIBOBJ
84021         invocation from here...
84022         * modules/isnanl (configure.ac): ... to here.
84023         * modules/isnanl-nolibm (configure.ac): ... and here.
84025 2011-05-20  Bruno Haible  <bruno@clisp.org>
84027         isnand*: Move AC_LIBOBJ invocations to module description.
84028         * m4/isnand.m4 (gl_FUNC_ISNAND, gl_FUNC_ISNAND_NO_LIBM): Move AC_LIBOBJ
84029         invocation from here...
84030         * modules/isnand (configure.ac): ... to here.
84031         * modules/isnand-nolibm (configure.ac): ... and here.
84033 2011-05-20  Bruno Haible  <bruno@clisp.org>
84035         isnanf*: Move AC_LIBOBJ invocations to module description.
84036         * m4/isnanf.m4 (gl_FUNC_ISNANF, gl_FUNC_ISNANF_NO_LIBM): Move AC_LIBOBJ
84037         invocation from here...
84038         * modules/isnanf (configure.ac): ... to here.
84039         * modules/isnanf-nolibm (configure.ac): ... and here.
84041 2011-05-20  Bruno Haible  <bruno@clisp.org>
84043         isnan*: Separate the AC_LIBOBJ invocations.
84044         * m4/isnanf.m4 (gl_PREREQ_ISNANF): Renamed from gl_BUILD_ISNANF. Remove
84045         AC_LIBOBJ invocation.
84046         (gl_FUNC_ISNANF, gl_FUNC_ISNANF_NO_LIBM): Update. Invoke AC_LIBOBJ
84047         here.
84048         * m4/isnand.m4 (gl_PREREQ_ISNAND): Renamed from gl_BUILD_ISNAND. Remove
84049         AC_LIBOBJ invocation.
84050         (gl_FUNC_ISNAND, gl_FUNC_ISNAND_NO_LIBM): Update. Invoke AC_LIBOBJ
84051         here.
84052         * m4/isnanl.m4 (gl_PREREQ_ISNANL): Renamed from gl_BUILD_ISNANL. Remove
84053         AC_LIBOBJ invocation.
84054         (gl_FUNC_ISNANL, gl_FUNC_ISNANL_NO_LIBM): Update. Invoke AC_LIBOBJ
84055         here.
84056         * m4/isnan.m4 (gl_ISNAN): Update. Invoke AC_LIBOBJ here.
84058 2011-05-08  Bruno Haible  <bruno@clisp.org>
84060         isinf: Move AC_LIBOBJ invocations to module description.
84061         * m4/isinf.m4 (gl_ISINF): Move AC_LIBOBJ invocation from here...
84062         * modules/isinf (configure.ac): ... to here.
84064 2011-05-08  Bruno Haible  <bruno@clisp.org>
84066         isfinite: Move AC_LIBOBJ invocations to module description.
84067         * m4/isfinite.m4 (gl_ISFINITE): Move AC_LIBOBJ invocation from here...
84068         * modules/isfinite (configure.ac): ... to here.
84070 2011-05-08  Bruno Haible  <bruno@clisp.org>
84072         isblank: Move AC_LIBOBJ invocations to module description.
84073         * m4/isblank.m4 (gl_FUNC_ISBLANK): Move AC_LIBOBJ invocation from
84074         here...
84075         * modules/isblank (configure.ac): ... to here.
84077 2011-05-08  Bruno Haible  <bruno@clisp.org>
84079         isapipe: Move AC_LIBOBJ invocations to module description.
84080         * m4/isapipe.m4 (gl_ISAPIPE): Set HAVE_ISAPIPE. Move AC_LIBOBJ and
84081         gl_PREREQ_ISAPIPE invocations from here...
84082         * modules/isapipe (configure.ac): ... to here.
84083         (Depends-on): Update condition.
84085 2011-05-08  Bruno Haible  <bruno@clisp.org>
84087         ioctl: Move AC_LIBOBJ invocations to module description.
84088         * m4/ioctl.m4 (gl_FUNC_IOCTL): Set HAVE_IOCTL. Move AC_LIBOBJ
84089         invocations from here...
84090         * modules/ioctl (configure.ac): ... to here.
84091         (Depends-on): Update condition.
84093 2011-05-08  Bruno Haible  <bruno@clisp.org>
84095         imaxdiv: Move AC_LIBOBJ invocations to module description.
84096         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Move AC_LIBOBJ and gl_PREREQ_IMAXDIV
84097         invocations from here...
84098         * modules/imaxdiv (configure.ac): ... to here.
84100 2011-05-08  Bruno Haible  <bruno@clisp.org>
84102         imaxabs: Move AC_LIBOBJ invocations to module description.
84103         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Move AC_LIBOBJ and gl_PREREQ_IMAXABS
84104         invocations from here...
84105         * modules/imaxabs (configure.ac): ... to here.
84107 2011-05-08  Bruno Haible  <bruno@clisp.org>
84109         getaddrinfo: Move AC_LIBOBJ invocations to module description.
84110         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Set HAVE_GETADDRINFO, Move
84111         AC_LIBOBJ invocations from here...
84112         * modules/getaddrinfo (configure.ac): ... to here.
84113         (Depends-on): Add conditions.
84115 2011-05-08  Bruno Haible  <bruno@clisp.org>
84117         inet_pton. getaddrinfo: Respect rules for use of AC_LIBOBJ.
84118         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Set HAVE_INET_PTON. Call
84119         AC_CHECK_FUNCS instead of AC_REPLACE_FUNCS. Don't invoke
84120         gl_PREREQ_INET_PTON. Move tests for declaration of inet_pton here...
84121         (gl_PREREQ_INET_PTON): ... from here.
84122         * modules/inet_pton (configure.ac): Invoke AC_LIBOBJ and
84123         gl_PREREQ_INET_PTON here.
84124         (Depends-on): Update condition.
84126 2011-05-08  Bruno Haible  <bruno@clisp.org>
84128         inet_ntop. getaddrinfo: Respect rules for use of AC_LIBOBJ.
84129         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Set HAVE_INET_NTOP. Call
84130         AC_CHECK_FUNCS instead of AC_REPLACE_FUNCS. Don't invoke
84131         gl_PREREQ_INET_NTOP. Move tests for declaration of inet_ntop here...
84132         (gl_PREREQ_INET_NTOP): ... from here.
84133         * modules/inet_ntop (configure.ac): Invoke AC_LIBOBJ and
84134         gl_PREREQ_INET_NTOP here.
84135         (Depends-on): Update condition.
84137 2011-05-08  Bruno Haible  <bruno@clisp.org>
84139         iconv_open: Move AC_LIBOBJ invocations to module description.
84140         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN, gl_REPLACE_ICONV_OPEN): Move
84141         AC_LIBOBJ invocations from here...
84142         * modules/iconv_open (configure.ac): ... to here.
84144 2011-05-08  Bruno Haible  <bruno@clisp.org>
84146         iconv_open, iconv_open-utf: Respect rules for use of AC_LIBOBJ.
84147         If module 'iconv_open' is among the main modules and module
84148         'iconv_open-utf' is among the tests dependencies, then
84149         REPLACE_ICONV_UTF will be defined to 1, hence iconv_open() in lib may
84150         return the special iconv_t values. Therefore iconv() and iconv_close()
84151         must support these special iconv_t values, already in lib, not only in
84152         tests.
84153         * m4/iconv_open-utf.m4: New file, extracted from m4/iconv_open.m4.
84154         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Invoke
84155         gl_FUNC_ICONV_OPEN_UTF_SUPPORT if present.
84156         (gl_FUNC_ICONV_OPEN_UTF): Remove macro.
84157         * modules/iconv_open (Files): Add lib/iconv.c, lib/iconv_close.c.
84158         (Depends-on): Add the dependencies of iconv_open-utf.
84159         * modules/iconv_open-utf (Files): Add m4/iconv_open-utf.m4. Remove
84160         m4/iconv_open.m4, lib/iconv.c, lib/iconv_close.c.
84161         (Depends-on): Remove modules needed by lib/iconv.c, lib/iconv_close.c.
84163 2011-05-08  Bruno Haible  <bruno@clisp.org>
84165         group-member: Move AC_LIBOBJ invocations to module description.
84166         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Move AC_LIBOBJ and
84167         gl_PREREQ_GROUP_MEMBER invocations from here...
84168         * modules/group-member (configure.ac): ... to here.
84170 2011-05-08  Bruno Haible  <bruno@clisp.org>
84172         grantpt: Move AC_LIBOBJ invocations to module description.
84173         * m4/grantpt.m4 (gl_FUNC_GRANTPT): Move AC_LIBOBJ and gl_PREREQ_GRANTPT
84174         invocations from here...
84175         * modules/grantpt (configure.ac): ... to here.
84177 2011-05-08  Bruno Haible  <bruno@clisp.org>
84179         glob: Move AC_LIBOBJ invocations to module description.
84180         * m4/glob.m4 (gl_GLOB): Move AC_LIBOBJ and gl_PREREQ_GLOB invocations
84181         from here...
84182         * modules/glob (configure.ac): ... to here.
84184 2011-05-08  Bruno Haible  <bruno@clisp.org>
84186         getusershell: Move AC_LIBOBJ invocations to module description.
84187         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): Set HAVE_GETUSERSHELL.
84188         Move AC_LIBOBJ invocation from here...
84189         * modules/getusershell (configure.ac): ... to here.
84190         (Depends-on): Update condition.
84192 2011-05-08  Bruno Haible  <bruno@clisp.org>
84194         gettimeofday: Move AC_LIBOBJ invocations to module description.
84195         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
84196         gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Move AC_LIBOBJ and
84197         gl_PREREQ_GETTIMEOFDAY invocations from here...
84198         * modules/gettimeofday (configure.ac): ... to here.
84200 2011-05-08  Bruno Haible  <bruno@clisp.org>
84202         gettimeofday, tzset: Respect rules for use of AC_LIBOBJ.
84203         * modules/tzset (configure.ac): Don't invoke gl_FUNC_TZSET_CLOBBER,
84204         just gl_FUNC_TZSET.
84205         * m4/tzset.m4 (gl_FUNC_TZSET): New macro.
84206         (gl_FUNC_TZSET_CLOBBER): Remove actions.
84207         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Invoke
84208         gl_FUNC_TZSET_CLOBBER and its actions here, if present.
84210 2011-05-08  Bruno Haible  <bruno@clisp.org>
84212         getsubopt: Move AC_LIBOBJ invocations to module description.
84213         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Move AC_LIBOBJ and
84214         gl_PREREQ_GETSUBOPT invocations from here...
84215         * modules/getsubopt (configure.ac): ... to here.
84217 2011-05-08  Bruno Haible  <bruno@clisp.org>
84219         getpass-gnu: Move AC_LIBOBJ invocations to module description.
84220         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): Set REPLACE_GETPASS. Move
84221         AC_LIBOBJ and gl_PREREQ_GETPASS invocations from here...
84222         * modules/getpass-gnu (configure.ac): ... to here.
84224 2011-05-08  Bruno Haible  <bruno@clisp.org>
84226         getpass: Move AC_LIBOBJ invocations to module description.
84227         * m4/getpass.m4 (gl_FUNC_GETPASS): Set HAVE_GETPASS. Move AC_LIBOBJ and
84228         gl_PREREQ_GETPASS invocations from here...
84229         * modules/getpass (configure.ac): ... to here.
84231 2011-05-08  Bruno Haible  <bruno@clisp.org>
84233         getpagesize: Move AC_LIBOBJ invocations to module description.
84234         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Move AC_LIBOBJ invocation
84235         from here...
84236         * modules/getpagesize (configure.ac): ... to here.
84238 2011-05-08  Bruno Haible  <bruno@clisp.org>
84240         getopt: Move AC_LIBOBJ invocations to module description.
84241         * m4/getopt.m4 (gl_REPLACE_GETOPT): Remove macro.
84242         (gl_FUNC_GETOPT): Inline it here. Move AC_LIBOBJ and gl_PREREQ_GETOPT
84243         invocations from here...
84244         * modules/getopt-gnu (configure.ac): ... to here.
84245         * modules/getopt-posix (configure.ac): ... and here.
84246         (Depends-on): Update condition.
84248 2011-05-08  Bruno Haible  <bruno@clisp.org>
84250         getopt, argp: Respect rules for use of AC_LIBOBJ.
84251         * m4/argp.m4 (gl_ARGP): Don't invoke gl_REPLACE_GETOPT.
84252         (gl_REPLACE_GETOPT_ALWAYS): New macro.
84253         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX): Test whether
84254         gl_REPLACE_GETOPT_ALWAYS is defined. Set REPLACE_GETOPT.
84256 2011-05-08  Bruno Haible  <bruno@clisp.org>
84258         getlogin_r: Move AC_LIBOBJ invocations to module description.
84259         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Move AC_LIBOBJ and
84260         gl_PREREQ_GETLOGIN_R invocations from here...
84261         * modules/getlogin_r (configure.ac): ... to here.
84263 2011-05-08  Bruno Haible  <bruno@clisp.org>
84265         getlogin: Move AC_LIBOBJ invocations to module description.
84266         * m4/getlogin.m4 (gl_FUNC_GETLOGIN): Move AC_LIBOBJ invocation from
84267         here...
84268         * modules/getlogin (configure.ac): ... to here.
84270 2011-05-08  Bruno Haible  <bruno@clisp.org>
84272         getloadavg: Move AC_LIBOBJ invocations to module description.
84273         * m4/getloadavg.m4 (gl_FUNC_GETDELIM): Set HAVE_GETLOADAVG. Move
84274         AC_LIBOBJ and gl_PREREQ_GETLOADAVG invocations from here...
84275         * modules/getloadavg (configure.ac): ... to here.
84277 2011-05-08  Bruno Haible  <bruno@clisp.org>
84279         gethrxtime: Move AC_LIBOBJ invocations to module description.
84280         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Move code that determines
84281         LIB_GETHRXTIME from here...
84282         (gl_GETHRXTIME): ... to here. Move AC_LIBOBJ and gl_PREREQ_GETHRXTIME
84283         invocations from here...
84284         * modules/gethrxtime (configure.ac): ... to here.
84286 2011-05-08  Bruno Haible  <bruno@clisp.org>
84288         gethostname: Move AC_LIBOBJ invocations to module description.
84289         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Move AC_LIBOBJ and
84290         gl_PREREQ_GETHOSTNAME invocations from here...
84291         * modules/gethostname (configure.ac): ... to here.
84293 2011-05-08  Bruno Haible  <bruno@clisp.org>
84295         getgroups: Move AC_LIBOBJ invocations to module description.
84296         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Move AC_LIBOBJ invocations from
84297         here...
84298         * modules/getgroups (configure.ac): ... to here.
84300 2011-05-08  Bruno Haible  <bruno@clisp.org>
84302         getdtablesize: Move AC_LIBOBJ invocations to module description.
84303         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Move AC_LIBOBJ
84304         invocation from here...
84305         * modules/getdtablesize (configure.ac): ... to here.
84307 2011-05-08  Bruno Haible  <bruno@clisp.org>
84309         getdomainname: Move AC_LIBOBJ invocations to module description.
84310         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Move AC_LIBOBJ and
84311         gl_PREREQ_GETDOMAINNAME invocations from here...
84312         * modules/getdomainname (configure.ac): ... to here.
84314 2011-05-08  Bruno Haible  <bruno@clisp.org>
84316         getline: Move AC_LIBOBJ invocations to module description.
84317         * m4/getline.m4 (gl_FUNC_GETLINE): Move AC_LIBOBJ and gl_PREREQ_GETLINE
84318         invocations from here...
84319         * modules/getline (configure.ac): ... to here.
84321 2011-05-08  Bruno Haible  <bruno@clisp.org>
84323         getline: Simplify.
84324         * m4/getline.m4 (gl_PREREQ_GETLINE): Don't invoke gl_FUNC_GETDELIM.
84325         It's already handled through the module dependency.
84327 2011-05-08  Bruno Haible  <bruno@clisp.org>
84329         getdelim: Move AC_LIBOBJ invocations to module description.
84330         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Set HAVE_GETDELIM. Move AC_LIBOBJ
84331         and gl_PREREQ_GETDELIM invocations from here...
84332         * modules/getdelim (configure.ac): ... to here.
84333         (Depends-on): Fix condition.
84335 2011-05-08  Bruno Haible  <bruno@clisp.org>
84337         getcwd: Move AC_LIBOBJ invocations to module description.
84338         * m4/getcwd.m4 (gl_FUNC_GETCWD): Move AC_LIBOBJ and gl_PREREQ_GETCWD
84339         invocations from here...
84340         * modules/getcwd (configure.ac): ... to here.
84342 2011-05-08  Bruno Haible  <bruno@clisp.org>
84344         getcwd-lgpl: Move AC_LIBOBJ invocations to module description.
84345         * m4/getcwd.m4 (gl_FUNC_GETCWD_LGPL): Move AC_LIBOBJ invocation from
84346         here...
84347         * modules/getcwd-lgpl (configure.ac): ... to here.
84349 2011-05-07  Bruno Haible  <bruno@clisp.org>
84351         crypto/gc: Move AC_LIBOBJ invocations to module description.
84352         * m4/gc.m4 (gl_GC): Move AC_LIBOBJ invocations from here...
84353         * modules/crypto/gc (configure.ac): ... to here.
84355 2011-05-07  Bruno Haible  <bruno@clisp.org>
84357         fwriting: Move AC_LIBOBJ invocations to module description.
84358         * m4/fwriting.m4 (gl_FUNC_FWRITINT): Move AC_LIBOBJ invocation from
84359         here...
84360         * modules/fwriting (configure.ac): ... to here.
84362 2011-05-07  Bruno Haible  <bruno@clisp.org>
84364         fwritable: Move AC_LIBOBJ invocations to module description.
84365         * m4/fwritable.m4 (gl_FUNC_FWRITABLE): Move AC_LIBOBJ invocation from
84366         here...
84367         * modules/fwritable (configure.ac): ... to here.
84369 2011-05-07  Bruno Haible  <bruno@clisp.org>
84371         futimens: Move AC_LIBOBJ invocations to module description.
84372         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Move AC_LIBOBJ invocations from
84373         here...
84374         * modules/futimens (configure.ac): ... to here.
84376 2011-05-07  Bruno Haible  <bruno@clisp.org>
84378         ftruncate: Move AC_LIBOBJ invocations to module description.
84379         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Move AC_LIBOBJ and
84380         gl_PREREQ_FTRUNCATE invocations from here...
84381         * modules/ftruncate (configure.ac): ... to here.
84383 2011-05-07  Bruno Haible  <bruno@clisp.org>
84385         fsync: Move AC_LIBOBJ invocations to module description.
84386         * m4/fsync.m4 (gl_FUNC_FSYNC): Move AC_LIBOBJ and gl_PREREQ_FSYNC
84387         invocations from here...
84388         * modules/fsync (configure.ac): ... to here.
84390 2011-05-07  Bruno Haible  <bruno@clisp.org>
84392         fsusage: Move AC_LIBOBJ invocations to module description.
84393         * m4/fsusage.m4 (gl_FUNC_FREOPEN): Move AC_LIBOBJ and
84394         gl_PREREQ_FSUSAGE_EXTRA invocations from here...
84395         * modules/fsusage (configure.ac): ... to here.
84397 2011-05-07  Bruno Haible  <bruno@clisp.org>
84399         freopen: Move AC_LIBOBJ invocations to module description.
84400         * m4/freopen.m4 (gl_FUNC_FREOPEN): Move AC_LIBOBJ and gl_PREREQ_FREOPEN
84401         invocations from here...
84402         * modules/freopen (configure.ac): ... to here.
84404 2011-05-07  Bruno Haible  <bruno@clisp.org>
84406         free: Move AC_LIBOBJ invocations to module description.
84407         * m4/free.m4 (gl_FUNC_FREE): Move AC_LIBOBJ and missing gl_PREREQ_FREE
84408         invocations from here...
84409         * modules/free (configure.ac): ... to here.
84411 2011-05-07  Bruno Haible  <bruno@clisp.org>
84413         freadable: Move AC_LIBOBJ invocations to module description.
84414         * m4/freadable.m4 (gl_FUNC_FREADABLE): Move AC_LIBOBJ invocation from
84415         here...
84416         * modules/freadable (configure.ac): ... to here.
84418 2011-05-07  Bruno Haible  <bruno@clisp.org>
84420         fpurge: Move AC_LIBOBJ invocations to module description.
84421         * m4/fpurge.m4 (gl_FUNC_FPURGE): Set HAVE_FPURGE. Move AC_LIBOBJ
84422         invocations from here...
84423         * modules/fpurge (configure.ac): ... to here.
84425 2011-05-07  Bruno Haible  <bruno@clisp.org>
84427         fpending: Move AC_LIBOBJ invocations to module description.
84428         * m4/fpending.m4 (gl_PREREQ_FPENDING): New macro, extracted from
84429         gl_FUNC_FPENDING.
84430         (gl_FUNC_FPENDING): Move AC_LIBOBJ and gl_PREREQ_FPENDING
84431         invocations from here...
84432         * modules/fpending (configure.ac): ... to here.
84434 2011-05-07  Bruno Haible  <bruno@clisp.org>
84436         fopen: Move AC_LIBOBJ invocations to module description.
84437         * m4/fopen.m4 (gl_FUNC_FOPEN): Move AC_LIBOBJ and gl_PREREQ_FOPEN
84438         invocations from here...
84439         * modules/fopen (configure.ac): ... to here.
84441 2011-05-07  Bruno Haible  <bruno@clisp.org>
84443         fnmatch, fnmatch-gnu: Move AC_LIBOBJ invocations to module description.
84444         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): New macro, extracted from
84445         gl_FUNC_FNMATCH_POSIX.
84446         (gl_FUNC_FNMATCH_POSIX): Move AC_LIBOBJ and gl_PREREQ_FNMATCH
84447         invocations from here...
84448         * modules/fnmatch (configure.ac): ... to here.
84449         * modules/fnmatch-gnu (configure.ac): ... and here.
84451 2011-05-07  Bruno Haible  <bruno@clisp.org>
84453         flock: Move AC_LIBOBJ invocations to module description.
84454         * m4/flock.m4 (gl_FUNC_FLOCK): Move AC_LIBOBJ and gl_PREREQ_FLOCK
84455         invocations from here...
84456         * modules/flock (configure.ac): ... to here.
84458 2011-05-07  Bruno Haible  <bruno@clisp.org>
84460         fileblocks: Move AC_LIBOBJ invocations to module description.
84461         * m4/fileblocks.m4 (gl_FILEBLOCKS): Move AC_LIBOBJ and
84462         gl_PREREQ_FILEBLOCKS invocations from here...
84463         * modules/fileblocks (configure.ac): ... to here.
84465 2011-05-06  Bruno Haible  <bruno@clisp.org>
84467         fflush: Move AC_LIBOBJ invocations to module description.
84468         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Remove macro.
84469         (gl_FUNC_FFLUSH): Inline it here. Move AC_LIBOBJ and gl_PREREQ_FFLUSH
84470         invocations from here...
84471         * modules/fflush (configure.ac): ... to here.
84473 2011-05-06  Bruno Haible  <bruno@clisp.org>
84475         fdopendir: Move AC_LIBOBJ invocations to module description.
84476         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Move AC_LIBOBJ invocations from
84477         here...
84478         * modules/fdopendir (configure.ac): ... to here.
84479         (Depends-on): Improve conditions.
84481 2011-05-06  Bruno Haible  <bruno@clisp.org>
84483         _Exit: Move AC_LIBOBJ invocations to module description.
84484         * m4/_Exit.m4 (gl_FUNC__EXIT): Move AC_LIBOBJ and gl_PREREQ__EXIT
84485         invocations from here...
84486         * modules/_Exit (configure.ac): ... to here.
84488 2011-05-21  Bruno Haible  <bruno@clisp.org>
84490         euidaccess: Respect rules for use of AC_LIBOBJ.
84491         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Call AC_CHECK_FUNCS instead of
84492         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_EUIDACCESS invocations
84493         from here...
84494         * modules/euidaccess (configure.ac): ... to here.
84496 2011-05-06  Bruno Haible  <bruno@clisp.org>
84498         error: Move AC_LIBOBJ invocations to module description.
84499         * m4/error.m4 (gl_ERROR): Inline AC_FUNC_ERROR_AT_LINE. Remove
84500         AC_LIBSOURCES invocation. Move AC_LIBOBJ and gl_PREREQ_ERROR
84501         invocations from here...
84502         * modules/error (configure.ac): ... to here.
84504 2011-05-06  Bruno Haible  <bruno@clisp.org>
84506         duplocale: Move AC_LIBOBJ invocations to module description.
84507         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Move AC_LIBOBJ and
84508         gl_PREREQ_DUPLOCALE invocations from here...
84509         * modules/duplocale (configure.ac): ... to here.
84511 2011-05-05  Bruno Haible  <bruno@clisp.org>
84513         dirfd: Move AC_LIBOBJ invocations to module description.
84514         * m4/dirfd.m4 (gl_PREREQ_DIRFD): New macro, extracted from
84515         gl_FUNC_DIRFD.
84516         (gl_FUNC_DIRFD): Move AC_LIBOBJ and gl_PREREQ_DIRFD invocations from
84517         here...
84518         * modules/dirfd (configure.ac): ... to here.
84519         (Depends-on): Fix condition.
84521 2011-05-05  Bruno Haible  <bruno@clisp.org>
84523         chown: Respect rules for use of AC_LIBOBJ.
84524         * m4/chown.m4 (gl_FUNC_CHOWN): Move AC_LIBOBJ invocations from here...
84525         * modules/chown (configure.ac): ... to here.
84527 2011-05-05  Bruno Haible  <bruno@clisp.org>
84529         chdir-long: Move AC_LIBOBJ invocations to module description.
84530         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Move AC_LIBOBJ and
84531         gl_PREREQ_CHDIR_LONG invocations from here...
84532         * modules/chdir-long (configure.ac): ... to here.
84534 2011-05-05  Bruno Haible  <bruno@clisp.org>
84536         canonicalize-lgpl: Move AC_LIBOBJ invocations to module description.
84537         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL): Move AC_LIBOBJ invocation
84538         from here...
84539         * modules/canonicalize-lgpl (configure.ac): ... to here.
84541 2011-05-05  Bruno Haible  <bruno@clisp.org>
84543         calloc-posix, calloc-gnu: Move AC_LIBOBJs to module description.
84544         * m4/calloc.m4 (gl_REPLACE_CALLOC): Remove macro.
84545         (gl_FUNC_CALLOC_GNU, gl_FUNC_CALLOC_POSIX): Instead, just set
84546         REPLACE_CALLOC.
84547         * modules/calloc-posix (configure.ac): Invoke AC_LIBOBJ here.
84548         * modules/calloc-gnu (configure.ac): Likewise.
84550 2011-05-05  Bruno Haible  <bruno@clisp.org>
84552         btowc: Move AC_LIBOBJ invocations to module description.
84553         * m4/btowc.m4 (gl_FUNC_BTOWC): Move AC_LIBOBJ and gl_PREREQ_BTOWC
84554         invocations from here...
84555         * modules/btowc (configure.ac): ... to here.
84557 2011-05-21  Bruno Haible  <bruno@clisp.org>
84559         atexit: Move AC_LIBOBJ invocations to module description.
84560         * m4/atexit.m4 (gl_FUNC_ATEXIT): Call AC_CHECK_FUNCS instead of
84561         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_ATEXIT invocations from
84562         here...
84563         * modules/atexit (configure.ac): ... to here.
84565 2011-05-05  Bruno Haible  <bruno@clisp.org>
84567         atoll: Move AC_LIBOBJ invocations to module description.
84568         * m4/atoll.m4 (gl_FUNC_ATOLL): Move AC_LIBOBJ and gl_PREREQ_ATOLL
84569         invocations from here...
84570         * modules/atoll (configure.ac): ... to here.
84572 2011-05-05  Bruno Haible  <bruno@clisp.org>
84574         argz: Move AC_LIBOBJ invocations to module description.
84575         * m4/argz.m4 (gl_FUNC_ARGZ): Move AC_LIBOBJ invocation from here...
84576         * modules/argz (configure.ac): ... to here.
84578 2011-05-05  Bruno Haible  <bruno@clisp.org>
84580         alphasort: Move AC_LIBOBJ invocations to module description.
84581         * m4/alphasort.m4 (gl_FUNC_ALPHASORT): Move AC_LIBOBJ and
84582         gl_PREREQ_ALPHASORT invocations from here...
84583         * modules/alphasort (configure.ac): ... to here.
84585 2011-06-15  Paul Eggert  <eggert@cs.ucla.edu>
84587         verify: new macro verify_expr; verify_true deprecated
84588         * NEWS: Mention this.
84589         * doc/verify.texi (Compile-time Assertions): Document this.
84590         * lib/verify.h (verify_true): Deprecate.
84591         (verify_expr): New macro.
84592         * tests/test-verify.c (function): Test verify_expr.
84594 2011-06-14  Jim Meyering  <meyering@redhat.com>
84596         init.sh: give more portable redirection-related advice in a comment
84597         * tests/init.sh (stderr_fileno_): Update the advice in comments.
84598         See http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/22488
84599         for lots of discussion.  Stefano Lattarini suggested the solution
84600         of putting "9>&2" after the command.  Reported by Bruno Haible.
84602 2011-06-13  Bruno Haible  <bruno@clisp.org>
84604         locale-zh: Reject zh_CN.GB18030 locale on Solaris 8.
84605         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): On Solaris 8, set LOCALE_ZH_CN to
84606         'none'.
84608 2011-06-13  Paul Eggert  <eggert@cs.ucla.edu>
84610         ftoastr: use strtof only if HAVE_STRTOF
84611         This is needed on HP-UX 11.11 with GCC 4.2.4; see Bruno Haible's report
84612         <http://lists.gnu.org/r/bug-gnulib/2011-06/msg00154.html>.
84613         * lib/ftoastr.c (STRTOF) [LENGTH == 1]: Use strtof only if HAVE_STRTOF.
84614         * modules/ftoastr (configure.ac): Check for strtof.
84616 2011-06-13  Bruno Haible  <bruno@clisp.org>
84618         gnulib-tool: Addendum to 2011-06-08 commit.
84619         * gnulib-tool (func_emit_lib_Makefile_am): If options --makefile-name
84620         and --witness-c-macro have been given, augment AM_CPPFLAGS.
84622 2011-06-13  Bruno Haible  <bruno@clisp.org>
84624         fseeko: Provide a non-inline replacement of fseek().
84625         * lib/stdio.in.h (fseek): Don't provide if module 'fseek' is not used.
84626         * modules/fseeko (Depends-on): Add fseek.
84627         * modules/fseek (License): Change to LGPLv2+.
84629 2011-06-13  Bruno Haible  <bruno@clisp.org>
84631         ftello: Provide a non-inline replacement of ftell().
84632         * lib/stdio.in.h (ftell): Don't provide if module 'ftell' is not used.
84633         * m4/ftell.m4 (gl_FUNC_FTELL): Replace ftell also if the system does
84634         not have ftello() (such as on mingw).
84635         * modules/ftello (Depends-on): Add ftell.
84636         * modules/ftell (License): Change to LGPLv2+.
84638 2011-05-07  Bruno Haible  <bruno@clisp.org>
84640         ftell: Move AC_LIBOBJ invocations to module description.
84641         * m4/ftell.m4 (gl_FUNC_FTELL): Move AC_LIBOBJ invocation from here...
84642         * modules/ftell (configure.ac): ... to here.
84644 2011-05-07  Bruno Haible  <bruno@clisp.org>
84646         ftello: Respect rules for use of AC_LIBOBJ.
84647         * m4/ftello.m4 (gl_REPLACE_FTELLO): Remove macro.
84648         (gl_FUNC_FTELLO): Inline it here. Move AC_LIBOBJ invocation from
84649         here...
84650         * modules/ftello (configure.ac): ... to here.
84652 2011-05-07  Bruno Haible  <bruno@clisp.org>
84654         fseeko: Simplify.
84655         * m4/fseeko.m4 (gl_HAVE_FSEEKO): Remove macro.
84656         (gl_FUNC_FSEEKO): Inline it here.
84658 2011-05-07  Bruno Haible  <bruno@clisp.org>
84660         fseek: Move AC_LIBOBJ invocations to module description.
84661         * m4/fseek.m4 (gl_REPLACE_FSEEK): Remove macro.
84662         (gl_FUNC_FSEEK): Inline it here. Move AC_LIBOBJ invocation from here...
84663         * modules/fseek (configure.ac): ... to here.
84665 2011-05-07  Bruno Haible  <bruno@clisp.org>
84667         fseek: Respect rules for use of AC_LIBOBJ.
84668         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Move gl_REPLACE_FSEEK invocation from
84669         here...
84670         * m4/fseek.m4 (gl_FUNC_FSEEK): ... to here.
84672 2011-05-07  Bruno Haible  <bruno@clisp.org>
84674         fseeko: Respect rules for use of AC_LIBOBJ.
84675         * m4/fseeko.m4 (gl_REPLACE_FSEEKO): Remove macro.
84676         (gl_FUNC_FSEEKO): Inline it here. Move AC_LIBOBJ invocation from
84677         here...
84678         * modules/fseeko (configure.ac): ... to here.
84680 2011-06-13  Bruno Haible  <bruno@clisp.org>
84682         gnulib-tool: Allow comments in the 'Depends-on' section.
84683         * doc/gnulib.texi (Module description): Mention comment syntax in the
84684         Depends-on section.
84685         * gnulib-tool (func_get_dependencies): Filter out comment lines.
84687 2011-06-13  Bruno Haible  <bruno@clisp.org>
84689         file-set.h: guard __attibute__ use, now that it's not always defined
84690         * lib/file-set.h (record_file): Use __attribute__ only with compiler
84691         versions that support it.  This fixes a coreutils build failure with
84692         the vendor cc on HP-UX 11.31.
84694 2011-06-12  Bruno Haible  <bruno@clisp.org>
84696         acl: Add support for HP-UX >= 11.11 JFS ACLs.
84697         * doc/acl-resources.txt: Add info about the ACL APIs on HP-UX.
84698         * m4/acl.m4 (gl_FUNC_ACL): Also test for HP-UX 11.11 API.
84699         * lib/acl-internal.h [HP-UX 11.11]: Include <aclv.h>.
84700         (acl, aclsort): New declarations.
84701         (aclv_nontrivial): New declaration.
84702         * lib/file-has-acl.c (aclv_nontrivial) [HP-UX 11.11]: New function.
84703         (file_has_acl): Read also the second kind of HP-UX ACLs.
84704         * lib/set-mode-acl.c (qset_acl) [HP-UX 11.11]: Try to set the second
84705         kind of HP-UX ACLs if the first kind fails.
84706         * lib/copy-acl.c (qcopy_acl) [HP-UX 11.11]: Read and set also the
84707         second kind of HP-UX ACLs.
84708         * tests/test-sameacls.c [HP-UX 11.11]: Include <aclv.h>.
84709         (main) [HP-UX 11.11]: Test also whether the second kind of HP-UX ACLs
84710         agree.
84711         * tests/test-file-has-acl.sh (acl_flavor) [HP-UX 11.11]: Set to
84712         hpuxjfs.
84713         Handle hpuxjfs.
84714         * tests/test-set-mode-acl.sh (acl_flavor) [HP-UX 11.11]: Set to
84715         hpuxjfs.
84716         Handle hpuxjfs.
84717         * tests/test-copy-acl.sh (acl_flavor) [HP-UX 11.11]: Set to hpuxjfs.
84718         (func_test_same_acls): Use both lsacl and getacl.
84719         Handle hpuxjfs.
84720         * tests/test-copy-file.sh (acl_flavor) [HP-UX 11.11]: Set to hpuxjfs.
84721         (func_test_same_acls): Use both lsacl and getacl.
84722         Handle hpuxjfs.
84724 2011-06-12  Bruno Haible  <bruno@clisp.org>
84726         acl: Complete the 2010-08-10 fix.
84727         * lib/file-has-acl.c (file_has_acl) [HP-UX]: Also test against ENOTSUP.
84728         * lib/set-mode-acl.c (qset_acl) [HP-UX]: Likewise.
84729         * lib/copy-acl.c (qcopy_acl) [HP-UX]: Test for the errno values
84730         explicitly.
84731         * tests/test-sameacls.c (main) [HP-UX]: Also test against ENOTSUP.
84732         Reported in <http://debbugs.gnu.org/db/60/6053.html>.
84734 2011-06-12  Bruno Haible  <bruno@clisp.org>
84736         spawn-pipe tests: Comments.
84737         * tests/test-spawn-pipe-child.c (main): Update comment.
84738         Reported by James Youngman <jay@gnu.org>.
84740 2011-06-11  James Youngman  <jay@gnu.org>
84742         New module 'stat-size'.
84743         * modules/stat-size: New module.  Provides macros for accessing
84744         file size information in instances of struct stat.  Depends on the
84745         fileblocks module because it calls st_blocks.
84746         * lib/stat-size.h: New file, adapted from coreutils' system.h.
84747         * doc/gnulib.texi: Include stat-size.texi.
84748         * doc/stat-size.texi: Documentation for this module.
84749         * m4/stat-size.m4: New file; defines gl_STAT_SIZE.
84750         * m4/fileblocks.m4: Mention that stat-size depends on the call to
84751         AC_STRUCT_ST_BLOCKS.
84753 2011-06-09  Bruno Haible  <bruno@clisp.org>
84755         thread: Support pthreads-win32.
84756         * lib/glthread/thread.h (gl_thread_self): Define differently on
84757         pthreads-win32.
84758         (gl_null_thread): New declaration.
84759         (gl_thread_self_pointer): New macro.
84760         * lib/glthread/thread.c (gl_null_thread): New constant.
84761         * tests/test-lock.c: Use gl_thread_self_pointer instead of
84762         gl_thread_self.
84763         * tests/test-tls.c: Likewise.
84764         Suggested by Paul Eggert. Reported by Eric Blake.
84766 2011-06-09  Bruno Haible  <bruno@clisp.org>
84768         thread: Fix confusion between NULL and 0.
84769         * lib/glthread/thread.h (gl_thread_self): Use NULL and 0 appropriately.
84770         Reported by Paul Eggert.
84772 2011-06-09  Bruno Haible  <bruno@clisp.org>
84774         spawn-pipe tests: Avoid test failure on HP-UX 11.
84775         * tests/test-spawn-pipe-child.c (main) [HP-UX]: Don't assert that fd 2
84776         is closed.
84778 2011-06-09  Bruno Haible  <bruno@clisp.org>
84780         acl tests: Fix compilation error on HP-UX 11.
84781         * tests/test-sameacls.c: Include <sys/acl.h> also on HP-UX.
84783 2011-06-09  Bruno Haible  <bruno@clisp.org>
84785         rmdir: Avoid test failure on HP-UX 10.20.
84786         * tests/test-rmdir.h (test_rmdir_func): Accept ENOTEMPTY error, like
84787         EEXIST.
84789 2011-06-08  Eric Blake  <eblake@redhat.com>
84791         perror: fix test on mingw
84792         * modules/perror-tests (Depends-on): Add dup2.
84794         strerror_r-posix: fix on MacOS
84795         * m4/strerror.m4 (gl_FUNC_STRERROR): Flush out MacOS bug.
84796         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Likewise, and fix
84797         logic bug.
84798         * lib/strerror_r.c (strerror_r): Fix the bug.
84799         * lib/strerror.c (strerror): Likewise.
84800         * doc/posix-functions/strerror_r.texi (strerror_r): Document the
84801         problem.
84802         * doc/posix-functions/strerror.texi (strerror): Likewise.
84803         * doc/posix-functions/perror.texi (perror): Likewise.
84804         * tests/test-strerror.c (main): Enhance test.
84805         * tests/test-strerror_r.c (main): Likewise.
84807 2011-06-08  Bruno Haible  <bruno@clisp.org>
84809         gnulib-tool: Better isolation between different gnulib-tool invocations.
84810         * gnulib-tool: New option --witness-c-macro.
84811         (witness_c_macro): New variable.
84812         (func_emit_lib_Makefile_am): If --witness-c-macro was specified, let
84813         AM_CPPFLAGS define it as a C macro.
84814         (func_emit_tests_Makefile_am): Likewise.
84815         (func_import): Store witness_c_macro setting in gnulib-cache.m4 and
84816         read it from there.
84817         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_CONDITION): Define through
84818         m4_define, not AC_DEFUN.
84819         (gl_MODULE_INDICATOR_SET_VARIABLE_AUX,
84820         gl_MODULE_INDICATOR_SET_VARIABLE_AUX_OR): New macros.
84821         (gl_MODULE_INDICATOR_SET_VARIABLE): Use them.
84822         * modules/arpa_inet (Makefile.am): Use sed expression s/.../.../, not
84823         s|...|...|, to substitute the values of the GNULIB_* module indicator
84824         variables.
84825         * modules/dirent (Makefile.am): Likewise.
84826         * modules/fcntl-h (Makefile.am): Likewise.
84827         * modules/iconv-h (Makefile.am): Likewise.
84828         * modules/langinfo (Makefile.am): Likewise.
84829         * modules/locale (Makefile.am): Likewise.
84830         * modules/math (Makefile.am): Likewise.
84831         * modules/netdb (Makefile.am): Likewise.
84832         * modules/poll-h (Makefile.am): Likewise.
84833         * modules/pty (Makefile.am): Likewise.
84834         * modules/search (Makefile.am): Likewise.
84835         * modules/signal (Makefile.am): Likewise.
84836         * modules/spawn (Makefile.am): Likewise.
84837         * modules/stdio (Makefile.am): Likewise.
84838         * modules/stdlib (Makefile.am): Likewise.
84839         * modules/string (Makefile.am): Likewise.
84840         * modules/sys_ioctl (Makefile.am): Likewise.
84841         * modules/sys_select (Makefile.am): Likewise.
84842         * modules/sys_socket (Makefile.am): Likewise.
84843         * modules/sys_stat (Makefile.am): Likewise.
84844         * modules/sys_times (Makefile.am): Likewise.
84845         * modules/sys_utsname (Makefile.am): Likewise.
84846         * modules/sys_wait (Makefile.am): Likewise.
84847         * modules/termios (Makefile.am): Likewise.
84848         * modules/time (Makefile.am): Likewise.
84849         * modules/unistd (Makefile.am): Likewise.
84850         * modules/wchar (Makefile.am): Likewise.
84852 2011-06-08  Eric Blake  <eblake@redhat.com>
84854         strerror: simplify replacement
84855         * m4/strerror.m4 (gl_PREREQ_STRERROR): Delete.
84856         * modules/strerror (configure.ac): No prereqs needed here...
84857         * modules/strerror-override (configure.ac): ...but this needs it.
84858         (Files): Add file for needed prereq macro.
84860 2011-06-08  Bruno Haible  <bruno@clisp.org>
84862         strerror_r-posix: Tweaks.
84863         * m4/strerror.m4 (gl_FUNC_STRERROR): Omit the code that tests
84864         gl_cv_func_strerror_r_works if gl_FUNC_STRERROR_R_WORKS is not present.
84865         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Fix AC_CACHE_CHECK
84866         message. Move gl_HEADER_STRING_H_DEFAULTS invocation from here...
84867         (gl_FUNC_STRERROR_R): ... to here.
84868         (gl_PREREQ_STRERROR_R): Test for __xpg_strerror_r.
84870 2011-06-07  Eric Blake  <eblake@redhat.com>
84872         perror: document fixed bugs
84873         * doc/posix-functions/perror.texi (perror): Document recent
84874         patches.
84876 2011-06-07  Paul Eggert  <eggert@cs.ucla.edu>
84878         stat-time: get_stat_birthtime failure is better-defined
84879         * lib/stat-time.h (get_stat_birthtime): If the time is not available,
84880         return a timestamp whose tv_sec and tv_nsec values are both -1.
84881         Previously, the spec said only that the tv_nsec value was negative.
84882         This upward-compatible change simplifies GNU tar a bit.
84884 2011-06-07  Eric Blake  <eblake@redhat.com>
84886         strerror_r-posix: work around cygwin 1.7.9
84887         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Split...
84888         (gl_FUNC_STRERROR_R_WORKS): ...into new macro, to detect Cygwin
84889         bug without replacing strerror_r.
84890         * m4/strerror.m4 (gl_FUNC_STRERROR): Replace strerror if
84891         strerror_r is buggy, but without requiring strerror_r compilation.
84892         * doc/posix-functions/strerror_r.texi (strerror_r): Fix docs.
84894         test-perror: relax test to ignore cygwin bug
84895         * tests/test-perror2.c (main): Relax test on requiring detection
84896         of stream errors, and use unbuffered stream.
84897         * doc/posix-functions/dprintf.texi (dprintf): Document bug.
84898         * doc/posix-functions/fprintf.texi (fprintf): Likewise.
84899         * doc/posix-functions/fputc.texi (fputc): Likewise.
84900         * doc/posix-functions/fputs.texi (fputs): Likewise.
84901         * doc/posix-functions/fputws.texi (fputws): Likewise.
84902         * doc/posix-functions/fwprintf.texi (fwprintf): Likewise.
84903         * doc/posix-functions/fwrite.texi (fwrite): Likewise.
84904         * doc/posix-functions/getopt.texi (getopt): Likewise.
84905         * doc/posix-functions/perror.texi (perror): Likewise.
84906         * doc/posix-functions/printf.texi (printf): Likewise.
84907         * doc/posix-functions/psiginfo.texi (psiginfo): Likewise.
84908         * doc/posix-functions/psignal.texi (psignal): Likewise.
84909         * doc/posix-functions/putc.texi (putc): Likewise.
84910         * doc/posix-functions/putc_unlocked.texi (putc_unlocked):
84911         Likewise.
84912         * doc/posix-functions/putchar.texi (putchar): Likewise.
84913         * doc/posix-functions/putchar_unlocked.texi (putchar_unlocked):
84914         Likewise.
84915         * doc/posix-functions/puts.texi (puts): Likewise.
84916         * doc/posix-functions/putwc.texi (putwc): Likewise.
84917         * doc/posix-functions/putwchar.texi (putwchar): Likewise.
84918         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
84919         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
84920         * doc/posix-functions/vfwprintf.texi (vfwprintf): Likewise.
84921         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
84922         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
84923         * doc/posix-functions/wordexp.texi (wordexp): Likewise.
84924         * doc/posix-functions/wprintf.texi (wprintf): Likewise.
84926 2011-05-22  Bruno Haible  <bruno@clisp.org>
84928         strerror: Move AC_LIBOBJ invocations to module description.
84929         * m4/strerror.m4 (gl_FUNC_STRERROR): Move AC_LIBOBJ and
84930         gl_PREREQ_STRERROR invocations from here...
84931         * modules/strerror (configure.ac): ... to here.
84933 2011-05-21  Bruno Haible  <bruno@clisp.org>
84935         perror: Use common idiom.
84936         * modules/perror (configure.ac): Reorder statements.
84938 2011-06-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
84940         tests: fix usage message in 'mktempd_'
84941         * tests/init.sh (mktempd_): In the usage message, use literal
84942         'mktempd_', not '$ME' (which is even undefined), as the name of
84943         the subroutine.
84945 2011-06-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
84947         tests init: new function 'fatal_', for hard errors
84948         Before this patch, the only way offered by tests/init.sh to
84949         properly signal a hard error was the `framework_failure_'
84950         function.  But the error message issued by that function,
84951         as its name would suggest, refers to a set-up failure in the
84952         testsuite, while hard errors can obviously also be due to
84953         other reasons.  The best way to fix this inconsistency is to
84954         introduce a new function with a more general error message.
84955         * tests/init.sh (fatal_): New function.
84957 2011-06-06  Eric Blake  <eblake@redhat.com>
84959         canonicalize-lgpl: use common idiom
84960         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Prefer older rm -rf
84961         over newer POSIX -Rf.
84962         Reported by Bruno Haible.
84964         canonicalize-lgpl: work around AIX realpath bug
84965         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Expose AIX bug.
84966         * doc/posix-functions/realpath.texi (realpath): Document it.
84967         Reported by Bruno Haible.
84969         strerror: work around FreeBSD bug
84970         * lib/strerror.c (strerror): Special case 0.
84971         Reported by Bruno Haible.
84973         strerror-override: avoid bloating errno module
84974         * modules/errno (Files, configure.ac): Move replacement strings...
84975         * modules/strerror-override: ...to new module.
84976         * modules/strerror (Depends-on): Add strerror-override.
84977         * modules/strerror_r-posix (Depends-on): Likewise.
84978         * MODULES.html.sh: Document new module.
84979         Reported by Bruno Haible.
84981 2011-06-06  Bruno Haible  <bruno@clisp.org>
84983         spawn-pipe tests: Rename program.
84984         * tests/test-spawn-pipe-main.c: Renamed from tests/test-spawn-pipe.c.
84985         * tests/test-spawn-pipe-child.c: Update comment.
84986         * tests/test-spawn-pipe.sh: Update.
84987         * modules/spawn-pipe-tests (Files, Makefile.am): Update.
84989         spawn-pipe tests: Link the child program only against libc.
84990         * tests/test-spawn-pipe-child.c: New file, extracted from
84991         tests/test-spawn-pipe.c.
84992         (main): Expect only one argument.
84993         (is_open): New function, copied from tests/test-pipe.c.
84994         * tests/test-spawn-pipe.c: Don't include <errno.h>.
84995         (child_main): Remove function.
84996         (test_pipe): Pass only one argument to the child program.
84997         (main): Remove child process code. Expect the child program's name as
84998         first argument.
84999         * tests/test-spawn-pipe.sh: Pass the child program's name as first
85000         argument.
85001         * modules/spawn-pipe-tests (Files): Add tests/test-spawn-pipe-child.c.
85002         (Makefile.am): Add test-spawn-pipe-child to check_PROGRAMS. Link
85003         test-spawn-pipe-child against no libraries.
85005 2011-06-06  Bruno Haible  <bruno@clisp.org>
85007         careadlinkat: Avoid mismatch between ssize_t and int.
85008         * lib/careadlinkat.h (careadlinkatcwd): Declare as a function always.
85009         * lib/careadlinkat.c (careadlinkatcwd): Define always.
85011 2011-06-06  Jim Meyering  <meyering@redhat.com>
85013         gnulib-common.m4: add _GL_ATTRIBUTE_CONST and _GL_ATTRIBUTE_PURE
85014         * m4/gnulib-common.m4 (gl_COMMON): Emit definitions of
85015         _GL_ATTRIBUTE_CONST and _GL_ATTRIBUTE_PURE.
85017 2011-06-05  Bruno Haible  <bruno@clisp.org>
85019         ansi-c++-opt: Interoperability with libtool.
85020         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): When a C++ compiler is not found,
85021         set the variable to "no", not to ":".
85022         * NEWS: Mention the change.
85024 2011-06-05  Bruno Haible  <bruno@clisp.org>
85026         acl: Fix test failure on AIX 7.
85027         * tests/test-sameacls.c (main) [AIX]: Fix aclx_printStr invocation.
85028         Based on a patch by Jørn Amundsen <Jorn.Amundsen@ntnu.no>.
85030 2011-06-05  Bruno Haible  <bruno@clisp.org>
85032         pipe-filter-ii: Fix test failure on AIX and IRIX.
85033         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): When write() fails
85034         with EAGAIN, retry with a smaller buffer size.
85036 2011-06-05  Bruno Haible  <bruno@clisp.org>
85038         localename: Fix link dependencies.
85039         * modules/localename (Link): Mention $(LIBTHREAD) or $(LTLIBTHREAD).
85040         * modules/localename-tests (Makefile.am): Link test-localename with
85041         $(LIBTHREAD).
85043 2011-06-05  Bruno Haible  <bruno@clisp.org>
85045         error: Avoid gcc warning.
85046         * lib/error.c (strerror_r): Declare also when its return type is 'int'.
85048 2011-06-05  Bruno Haible  <bruno@clisp.org>
85050         unsetenv: Avoid gcc warning.
85051         * lib/unsetenv.c (unsetenv): Provide declaration if system lacks it.
85053 2011-06-05  Bruno Haible  <bruno@clisp.org>
85055         setenv: Avoid gcc warning.
85056         * lib/setenv.c (setenv): Provide declaration if system lacks it.
85058 2011-06-05  Bruno Haible  <bruno@clisp.org>
85060         sys_select: Ensure memset is declared also on AIX 7.
85061         * lib/sys_select.in.h: Include <string.h> also on AIX.
85062         * doc/posix-headers/sys_select.texi: Mention that <sys/select.h> is not
85063         self-contained also on AIX 7.1.
85065 2011-06-04  Jim Meyering  <meyering@redhat.com>
85067         maint.mk: sc_unmarked_diagnostics: don't hard-code "error"
85068         * top/maint.mk (sc_unmarked_diagnostics): Don't hard-code the
85069         function name, "error".
85070         (_gl_translatable_diag_func_re): New configurable variable.
85072 2011-06-04  Bruno Haible  <bruno@clisp.org>
85074         getopt: Avoid gcc warning.
85075         * lib/getopt.c (_getopt_internal_r): Remove unused variable 'ambig'.
85077 2011-06-04  Bruno Haible  <bruno@clisp.org>
85079         strerror_r: Fix comments.
85080         * lib/strerror_r.c (strerror_r): Update comments after 2011-06-01
85081         commit.
85083 2011-06-04  Bruno Haible  <bruno@clisp.org>
85085         perror: Fix compilation error.
85086         * lib/perror.c: Don't include intprops.h, verify.h, strerror-impl.h.
85087         Undefine fprintf, not sprintf.
85088         * modules/perror (Depends-on): Remove intprops, verify.
85090 2011-06-04  Bruno Haible  <bruno@clisp.org>
85092         setlocale: Enable replacement on Cygwin 1.5.
85093         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Set REPLACE_SETLOCALE also on
85094         Cygwin 1.5.x.
85095         * doc/posix-functions/setlocale.texi: Mention that the problem with the
85096         LC_CTYPE category also exists on Cygwin 1.5.x.
85098 2011-06-04  Bruno Haible  <bruno@clisp.org>
85100         strerror-override: Don't disable symbol renamings.
85101         * lib/strerror-override.h: Include errno.h and stddef.h, not string.h.
85102         * lib/strerror-override.c: Include config.h.
85103         (strerror_override): Don't undefine.
85105 2011-06-03  Bruno Haible  <bruno@clisp.org>
85107         Copyright: Use LGPL 2.1 instead of LGPL 2.0.
85108         * lib/localename.h: Update copyright header.
85109         * lib/localename.c: Likewise.
85110         * lib/relocatable.h: Likewise.
85111         * lib/relocatable.c: Likewise.
85113 2011-06-02  Bruno Haible  <bruno@clisp.org>
85115         doc: Fix a module name.
85116         * doc/posix-functions/open.texi: Fix module name 'nonblocking'.
85118 2011-06-02  Bruno Haible  <bruno@clisp.org>
85120         pipe2: Remove dependency on 'nonblocking' module.
85121         * lib/pipe2.c: Include verify.h. Include nonblocking.h only if
85122         O_NONBLOCK is defined by gnulib.
85123         (pipe2) [WIN32]: If O_NONBLOCK is not defined by gnulib, verify that it
85124         is zero.
85125         * modules/pipe2 (Depends-on): Add verify. Remove nonblocking.
85126         * tests/test-pipe2.c: Include nonblocking.h only if O_NONBLOCK is
85127         defined by gnulib.
85128         (get_nonblocking_flag): New function.
85129         (main): Test O_NONBLOCK flag only if it is nonzero.
85130         * doc/glibc-functions/pipe2.texi: Mention the 'nonblocking' module.
85132 2011-06-03  Jim Meyering  <meyering@redhat.com>
85134         maint: three new prohibit-header-without-use rules
85135         Prohibit use of cloexec.h, posixver.h, same.h without use.
85136         * top/maint.mk (sc_prohibit_cloexec_without_use): New rule.
85137         (sc_prohibit_posixver_without_use): Likewise.
85138         (sc_prohibit_same_without_use): Likewise.
85140 2011-06-02  Paul Eggert  <eggert@cs.ucla.edu>
85142         allocator: 'die' routine is now given requested size
85143         * lib/allocator.h (struct allocator.die): New size arg.
85144         * lib/careadlinkat.c (careadlinkat): Pass size to 'die' function.
85145         If the actual problem is an ssize_t limitation, not a size_t or
85146         malloc failure, fail with errno==ENAMETOOLONG instead of calling 'die'.
85148 2011-06-01  Eric Blake  <eblake@redhat.com>
85150         strerror: drop strerror_r dependency
85151         * lib/strerror_r.c (strerror_r): Move gnulib replacement strings...
85152         * lib/strerror-override.c (strerror_override): ...to new file.
85153         * lib/strerror-override.h: Add prototype.
85154         * lib/strerror-impl.h: Delete.
85155         * lib/strerror.c (strerror): New implementation.
85156         * modules/errno (Files): Add new files.
85157         (configure.ac): Compile new file as appropriate.
85158         * modules/strerror (Files): Drop unused file.
85159         (Depends-on): Drop strerror_r-posix.
85160         * MODULES.html.sh: Document strerror_r-posix.
85161         Requested by Sam Steingold.
85163         perror: call strerror_r directly
85164         * modules/perror (Files): Drop strerror-impl.h.
85165         * lib/perror.c (perror): Use our own stack buffer, rather than
85166         calling a wrapper that uses static storage.
85167         * doc/posix-functions/perror.texi (perror): Document a limitation
85168         of our replacement.
85170         strerror_r: fix includes for FreeBSD
85171         * lib/strerror_r.c (includes): Use <stdlib.h> unconditionally,
85172         since we use abort on some platforms.
85173         Reported by Matthias Bolte.
85175 2011-05-31  Bruno Haible  <bruno@clisp.org>
85177         Fix link errors in tests: openat-die uses gettext-h.
85178         * modules/areadlinkat-tests (Makefile.am): Link test-areadlinkat
85179         against $(LIBINTL).
85180         * modules/dirent-safer-tests (Makefile.am): Link test-dirent-safer
85181         against $(LIBINTL).
85182         * modules/fdopendir-tests (Makefile.am): Link test-fdopendir against
85183         $(LIBINTL).
85184         * modules/fdutimensat-tests (Makefile.am): Link test-fdutimensat
85185         against $(LIBINTL).
85186         * modules/linkat-tests (Makefile.am): Link test-linkat against
85187         $(LIBINTL).
85188         * modules/mkfifoat-tests (Makefile.am): Link test-mkfifoat against
85189         $(LIBINTL).
85190         * modules/openat-safer-tests (Makefile.am): Link test-openat-safer
85191         against $(LIBINTL).
85192         * modules/openat-tests (Makefile.am): Link test-fchownat, test-fstatat,
85193         test-mkdirat, test-openat, test-unlinkat against $(LIBINTL).
85194         * modules/readlinkat-tests (Makefile.am): Link test-readlinkat against
85195         $(LIBINTL).
85196         * modules/symlinkat-tests (Makefile.am): Link test-symlinkat against
85197         $(LIBINTL).
85198         * modules/utimensat-tests (Makefile.am): Link test-utimensat against
85199         $(LIBINTL).
85200         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
85202 2011-05-31  Bruno Haible  <bruno@clisp.org>
85204         Fix link errors in tests: wait-process uses gettext-h.
85205         * modules/nonblocking-pipe-tests (Makefile.am): Set
85206         test_nonblocking_pipe_main_LDADD.
85207         * modules/nonblocking-socket-tests (Makefile.am): Link
85208         test-nonblocking-socket-main against $(LIBINTL).
85209         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
85211 2011-05-29  Paul Eggert  <eggert@cs.ucla.edu>
85213         assert-h: work around 'verify' incompatibility
85214         * lib/verify.h: Use @...@ directives, not ifdef.
85215         * modules/assert-h (assert.h): Implement the directives.
85216         (assert.h): Substitute the symbol-prefix more consistently.
85218 2011-05-29  Jim Meyering  <meyering@redhat.com>
85220         trim: remove three superfluous assignments
85221         * lib/trim.c (trim2): Remove three superfluous assignments
85222         and correct brace positioning.
85224 2011-05-29  Bruno Haible  <bruno@clisp.org>
85226         wctype-h: Avoid namespace pollution on Solaris 2.6.
85227         * lib/wctype.in.h: On Solaris, undefine 'multibyte' and a few other
85228         identifiers.
85229         * doc/posix-headers/wctype.texi: Mention the problem.
85230         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
85232 2011-05-28  Jim Meyering  <meyering@redhat.com>
85234         parse-datetime.y: accommodate -Wstrict-overflow
85235         * lib/parse-datetime.y (yylex): Rearrange pointer arithmetic to
85236         placate -Wstrict-overflow.
85238         trim: avoid a warning from -O2 -Wstrict-overflow
85239         * lib/trim.c (trim2): Declare local to be "unsigned int", not "int".
85241 2011-05-29  Bruno Haible  <bruno@clisp.org>
85243         gnulib-tool: Fix bug in yesterday's commit.
85244         * gnulib-tool (func_create_testdir): Don't add gltests to $subdirs
85245         twice.
85247 2011-05-29  Bruno Haible  <bruno@clisp.org>
85249         Allow multiple gnulib generated include files to be combined.
85250         * gnulib-tool (func_compute_include_guard_prefix): New function.
85251         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Resolve also
85252         ${gl_include_guard_prefix} references.
85253         (func_import, func_create_testdir): Invoke
85254         func_compute_include_guard_prefix.
85255         * lib/arpa_inet.in.h: Use the @GUARD_PREFIX@ placeholder.
85256         * lib/ctype.in.h: Likewise.
85257         * lib/dirent.in.h: Likewise.
85258         * lib/errno.in.h: Likewise.
85259         * lib/fcntl.in.h: Likewise.
85260         * lib/float.in.h: Likewise.
85261         * lib/getopt.in.h: Likewise.
85262         * lib/iconv.in.h: Likewise.
85263         * lib/langinfo.in.h: Likewise.
85264         * lib/locale.in.h: Likewise.
85265         * lib/math.in.h: Likewise.
85266         * lib/netdb.in.h: Likewise.
85267         * lib/netinet_in.in.h: Likewise.
85268         * lib/poll.in.h: Likewise.
85269         * lib/pthread.in.h: Likewise.
85270         * lib/pty.in.h: Likewise.
85271         * lib/sched.in.h: Likewise.
85272         * lib/se-selinux.in.h: Likewise.
85273         * lib/search.in.h: Likewise.
85274         * lib/signal.in.h: Likewise.
85275         * lib/spawn.in.h: Likewise.
85276         * lib/stdarg.in.h: Likewise.
85277         * lib/stddef.in.h: Likewise.
85278         * lib/stdint.in.h: Likewise.
85279         * lib/stdio.in.h: Likewise.
85280         * lib/stdlib.in.h: Likewise.
85281         * lib/string.in.h: Likewise.
85282         * lib/strings.in.h: Likewise.
85283         * lib/sys_file.in.h: Likewise.
85284         * lib/sys_ioctl.in.h: Likewise.
85285         * lib/sys_select.in.h: Likewise.
85286         * lib/sys_socket.in.h: Likewise.
85287         * lib/sys_stat.in.h: Likewise.
85288         * lib/sys_time.in.h: Likewise.
85289         * lib/sys_times.in.h: Likewise.
85290         * lib/sys_uio.in.h: Likewise.
85291         * lib/sys_utsname.in.h: Likewise.
85292         * lib/sys_wait.in.h: Likewise.
85293         * lib/sysexits.in.h: Likewise.
85294         * lib/termios.in.h: Likewise.
85295         * lib/time.in.h: Likewise.
85296         * lib/unistd.in.h: Likewise.
85297         * lib/wchar.in.h: Likewise.
85298         * lib/wctype.in.h: Likewise.
85299         * modules/arpa_inet (Makefile.am): Substitute @GUARD_PREFIX@.
85300         * modules/ctype (Makefile.am): Likewise.
85301         * modules/dirent (Makefile.am): Likewise.
85302         * modules/errno (Makefile.am): Likewise.
85303         * modules/fcntl-h (Makefile.am): Likewise.
85304         * modules/float (Makefile.am): Likewise.
85305         * modules/getopt-posix (Makefile.am): Likewise.
85306         * modules/iconv-h (Makefile.am): Likewise.
85307         * modules/langinfo (Makefile.am): Likewise.
85308         * modules/locale (Makefile.am): Likewise.
85309         * modules/math (Makefile.am): Likewise.
85310         * modules/netdb (Makefile.am): Likewise.
85311         * modules/netinet_in (Makefile.am): Likewise.
85312         * modules/poll-h (Makefile.am): Likewise.
85313         * modules/pthread (Makefile.am): Likewise.
85314         * modules/pty (Makefile.am): Likewise.
85315         * modules/sched (Makefile.am): Likewise.
85316         * modules/search (Makefile.am): Likewise.
85317         * modules/selinux-h (Makefile.am): Likewise.
85318         * modules/signal (Makefile.am): Likewise.
85319         * modules/spawn (Makefile.am): Likewise.
85320         * modules/stdarg (Makefile.am): Likewise.
85321         * modules/stddef (Makefile.am): Likewise.
85322         * modules/stdint (Makefile.am): Likewise.
85323         * modules/stdio (Makefile.am): Likewise.
85324         * modules/stdlib (Makefile.am): Likewise.
85325         * modules/string (Makefile.am): Likewise.
85326         * modules/strings (Makefile.am): Likewise.
85327         * modules/sys_file (Makefile.am): Likewise.
85328         * modules/sys_ioctl (Makefile.am): Likewise.
85329         * modules/sys_select (Makefile.am): Likewise.
85330         * modules/sys_socket (Makefile.am): Likewise.
85331         * modules/sys_stat (Makefile.am): Likewise.
85332         * modules/sys_time (Makefile.am): Likewise.
85333         * modules/sys_times (Makefile.am): Likewise.
85334         * modules/sys_uio (Makefile.am): Likewise.
85335         * modules/sys_utsname (Makefile.am): Likewise.
85336         * modules/sys_wait (Makefile.am): Likewise.
85337         * modules/sysexits (Makefile.am): Likewise.
85338         * modules/termios (Makefile.am): Likewise.
85339         * modules/time (Makefile.am): Likewise.
85340         * modules/unistd (Makefile.am): Likewise.
85341         * modules/wchar (Makefile.am): Likewise.
85342         * modules/wctype-h (Makefile.am): Likewise.
85343         * modules/assert-h (Makefile.am): Replace _GL_VERIFY_H specially.
85345 2011-05-29  Bruno Haible  <bruno@clisp.org>
85347         assert-h: Allow multiple gnulib generated replacements to coexist.
85348         * lib/verify.h (struct _gl_verify_type): Avoid identical redefinition.
85350 2011-05-29  Bruno Haible  <bruno@clisp.org>
85352         argp: Allow coexistence with strerror_r-posix module.
85353         * lib/argp-help.c (__argp_failure): If strerror_r is defined as a macro
85354         (either to __xpg_strerror_r by glibc's <string.h> or to rpl_strerror_r
85355         by gnulib's <string.h> replacement), assume it has the POSIX signature,
85356         not the glibc signature.
85358 2011-05-28  Bruno Haible  <bruno@clisp.org>
85360         gnulib-tool: Alternative structure of testdirs, similar to --import.
85361         * gnulib-tool: New option --single-configure.
85362         (func_usage): Document it.
85363         (single_configure): New variable.
85364         (func_modules_transitive_closure_separately,
85365         func_modules_transitive_closure_separately,
85366         func_determine_use_libtests, func_modules_add_dummy_separately,
85367         func_modules_to_filelist_separately): New functions, extracted from
85368         func_import.
85369         (func_emit_tests_Makefile_am): Handle $single_configure = true case.
85370         (func_import): Use the new functions.
85371         (func_create_testdir): Set final_modules. Handle $single_configure =
85372         true case.
85374 2011-05-28  Bruno Haible  <bruno@clisp.org>
85376         getloadavg: Remove an unreliable safety check.
85377         * m4/getloadavg.m4 (gl_GETLOADAVG): Drop argument. Remove test whether
85378         getloadavg.c is in place.
85379         * modules/getloadavg (configure.ac): Drop argument of gl_GETLOADAVG.
85380         Reported by Sam Steingold <sds@gnu.org>.
85382 2011-05-28  Bruno Haible  <bruno@clisp.org>
85384         doc: Cleanup yet another file produced by texinfo.tex.
85385         * doc/Makefile (mostlyclean): Remove also gnulib.cn.
85387 2011-05-28  Bruno Haible  <bruno@clisp.org>
85389         Finish the conditional dependencies mechanism.
85390         * gnulib-tool: New option --no-conditional-dependencies.
85391         (func_usage): Document it. Don't mark --conditional-dependencies as
85392         experimental.
85393         (cond_dependencies): The possible values can now be true, false, empty.
85394         (func_modules_transitive_closure, func_emit_autoconf_snippets): Update.
85395         (func_import): Store setting in gnulib-cache.m4 and read it from there.
85396         * doc/gnulib-tool.texi (Conditional dependencies): New section.
85398 2011-05-28  Bruno Haible  <bruno@clisp.org>
85400         doc: Use a recent texinfo.tex.
85401         * doc/Makefile (tex_opts): New variable.
85402         (%.dvi, %.pdf): Pass it to texi2dvi and texi2pdf.
85404 2011-05-28  Jim Meyering  <meyering@redhat.com>
85406         intprops.h: adjust comment to match code change
85407         * lib/intprops.h (_GL_INT_CONVERT): Adjust comment: now that E is used
85408         only once, it *may* have side effects.  Also fix an unrelated typo.
85409         (_GL_INT_SIGNED): Likewise.
85411 2011-05-26  Simon Josefsson  <simon@josefsson.org>
85413         * lib/gen-uni-tables.c: Say "gen-uni-tables.c" consistently.
85415 2011-05-26  Bruno Haible  <bruno@clisp.org>
85417         mbsrchr: Avoid collision with system function on Interix.
85418         * lib/string.in.h (mbsrchr): Define as rpl_mbsrchr also on Interix.
85419         Reported by Markus Duft <mduft@gentoo.org>.
85421 2011-05-15  James Youngman  <jay@gnu.org>
85423         getopt: for ambiguous options, enumerate the possibilities.
85424         * lib/getopt.c (_getopt_internal_r): Merge glibc change printing
85425         the ambiguous options when an ambiguous prefix is given. This was
85426         http://sourceware.org/bugzilla/show_bug.cgi?id=7101.  The merged
85427         glibc change was
85428         http://sourceware.org/git/?p=glibc.git;a=commit;h=bd25564e1e98910ed69043ed6a6f884ce60e5780.
85430 2011-05-25  Eric Blake  <eblake@redhat.com>
85432         getcwd: work around mingw bug
85433         * lib/getcwd-lgpl.c (rpl_getcwd): Guarantee correct error.
85434         * doc/posix-functions/getcwd.texi (getcwd): Document it.
85435         Reported by Matthias Bolte.
85437 2011-05-24  Paul Eggert  <eggert@cs.ucla.edu>
85439         test-intprops: disable -Wtype-limits diagnostics
85440         * tests/test-intprops.c: Use a pragma to ignore -Wtype-limits
85441         diagnostics.  Otherwise, the integer overflow macros generate many
85442         diagnostics.  Reported by Jim Meyering in
85443         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00528.html>.
85445         intprops: shorten, to pacify gcc -Woverlength-strings
85446         * lib/intprops.h (_GL_INT_CONVERT, _GL_INT_NEGATE_CONVERT):
85447         (_GL_BINARY_OP_OVERFLOW): Say "0 * (x)" rather than "(x) - (x)",
85448         so that, for example, verify (INT_MULTIPLY_OVERFLOW (...)) is less
85449         likely to run afoul of C compiler limits for string constant lengths.
85450         See <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00528.html>.
85452 2011-05-24  Eric Blake  <eblake@redhat.com>
85454         docs: document recently fixed glibc printf bug
85455         * doc/posix-functions/fprintf.texi (fprintf): Document it.
85456         * doc/posix-functions/printf.texi (printf): Likewise.
85457         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
85458         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
85460         closein-tests: convert to init.sh
85461         * modules/closein-tests (Files): Add init.sh
85462         * tests/test-closein.sh Use it.
85464         yesno-tests: convert to init.sh
85465         * modules/yesno-tests (Files): Add init.sh.
85466         * tests/test-yesno.sh: Use it.
85468         atexit-tests: ensure reliable exit status
85469         * tests/test-atexit.sh: Prefer 'Exit' over 'exit'.
85470         Reported by Bruno Haible.
85472 2011-05-24  Bruno Haible  <bruno@clisp.org>
85474         strerror_r-posix: Respect rules for use of AC_LIBOBJ.
85475         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Move AC_LIBOBJ and
85476         gl_PREREQ_STRERROR_R invocations from here...
85477         * modules/strerror_r-posix (configure.ac): ... to here.
85479 2011-05-24  Eric Blake  <eblake@redhat.com>
85481         strerror_r: fix missing header
85482         * lib/strerror_r.c: Avoid compiler warning about snprintf.
85484         strerror_r: fix AIX test failures
85485         * lib/strerror_r.c (strerror_r): Convert silent truncation to
85486         ERANGE failure.
85488         strerror_r: fix Solaris test failures
85489         * lib/strerror_r.c (strerror_r): Partially populate buf on ERANGE
85490         failures.
85491         * doc/posix-functions/strerror_r.texi (strerror_r): Document this.
85493         strerror_r: enforce POSIX recommendations
85494         * lib/strerror_r.c (safe_copy): New helper method.
85495         (strerror_r): Guarantee a non-empty string.
85496         * tests/test-strerror_r.c (main): Enhance tests to incorporate
85497         recent POSIX rulings and to match our strerror guarantees.
85498         * doc/posix-functions/strerror_r.texi (strerror_r): Document this.
85500 2011-05-24  Jim Meyering  <meyering@redhat.com>
85502         test-perror2.c: avoid warning about unused variable
85503         * tests/test-perror2.c (main): Remove declaration of unused "fp".
85505 2011-05-24  Eric Blake  <eblake@redhat.com>
85507         perror: avoid spurious test failure on HP-UX
85508         * tests/test-perror.sh: Use Exit to avoid wrong exit status.
85510         tests: fix logic bug in init.sh
85511         * tests/init.sh: (gl_set_x_corrupts_stderr_): Clear for successful
85512         shell.
85514 2011-05-24  Jim Meyering  <meyering@redhat.com>
85516         utimensat: do not reference an out-of-scope buffer
85517         Otherwise, with __linux__ defined, "times" would point to a buffer, "ts"
85518         declared in an inner scope, yet "times" would be dereferenced outside
85519         the scope in which "ts" was valid.
85520         * lib/utimensat.c (rpl_utimensat) [__linux__]: Move the declaration
85521         of ts[2] "out/up", so that the use of aliased "times" (via
85522         "times = ts;") does not end up referencing an out-of-scope "ts"
85524         opendir-safer.c: don't clobber errno; don't close negative FD
85525         * lib/opendir-safer.c (opendir_safer):
85526         [HAVE_FDOPENDIR || GNULIB_FDOPENDIR]: Don't close a negative
85527         file descriptor, and more importantly, don't clobber the
85528         offending errno value with EINVAL.  Before, upon failure
85529         of dup_safer, we would pass the negative file descriptor to
85530         fdopendir, which would clobber errno.
85532 2011-05-23  Bruno Haible  <bruno@clisp.org>
85534         idcache: Fix module description.
85535         * modules/idcache (Include): Set to "idcache.h".
85537 2011-05-23  Paul Eggert  <eggert@cs.ucla.edu>
85539         gnulib-tool: fix portability problem with MacOS sed
85540         A sed command like "/x/{s/a/b/}" is not portable; a newline is needed
85541         before the "}".  Problem reported by Leo in
85542         <http://lists.gnu.org/r/emacs-devel/2011-05/msg00717.html>.
85543         * gnulib-tool (func_modules_transitive_closure): Insert newlines in
85544         sed_extract_condition1, sed_extract_condition2.
85546 2011-05-23  Bruno Haible  <bruno@clisp.org>
85548         hash: Simplify autoconf macro.
85549         * m4/hash.m4 (gl_HASH): Don't require AM_STDBOOL_H.
85551 2011-05-23  Bruno Haible  <bruno@clisp.org>
85553         getugroups: Fix module description.
85554         * modules/getugroups (Include): Set to "getugroups.h".
85556 2011-05-23  Bruno Haible  <bruno@clisp.org>
85558         linkat: Simplify autoconf macro.
85559         * m4/linkat.m4 (gl_FUNC_LINKAT): Don't require gl_FUNC_LINK.
85561 2011-05-23  Bruno Haible  <bruno@clisp.org>
85562             Eric Blake  <eblake@redhat.com>
85564         linkat, renameat: Update dependencies.
85565         * modules/renameat (Depends-on): Add dosname, save-cwd. Remove stpcpy.
85566         * modules/linkat (Depends-on): Likewise. Remove also readlink,
85567         symlinkat.
85569 2011-05-23  Jim Meyering  <meyering@redhat.com>
85571         maint.mk: more tight_scope improvements
85572         * top/maint.mk: (_gl_TS_var_match): Use $(_gl_TS_extern) here, too.
85573         (_gl_TS_headers): Define only in if-0'd block.
85574         (_gl_TS_dir): Omit the $(srcdir)/ prefix.  Sometimes we need it,
85575         sometimes we must *not* use it.  Adjust uses accordingly.
85576         (sc_tight_scope): Use much simpler grep-based test to determine
85577         whether we skip this rule.
85579         maint.mk: generalize/improve the tight-scope rule
85580         * top/maint.mk: Emit a warning when the test is skipped.
85581         (_gl_TS_dir): Add $(srcdir)/ prefix.
85582         (_gl_TS_function_match): Simplify, rather than trying
85583         to enumerate common types.  Otherwise, it would fail to match an
85584         "extern unsigned char const *" declaration in idutils.
85585         (_gl_TS_extern): Do not endorse use of "XTERN", but do provide
85586         a way to support use of that type of macro.
85587         (_gl_TS_var_match): Simplify regexp.
85588         (_gl_TS_obj_files): New configurable variable.
85589         (_gl_TS_headers): Likewise.
85591 2011-05-22  Paul Eggert  <eggert@cs.ucla.edu>
85593         verify: fix bug when gnulib <assert.h> is also included
85594         * lib/verify.h (verify, verify_true): Define if _GL_VERIFY_H
85595         is defined, not if _GL_STATIC_ASSERT_H is not defined.
85596         Perhaps there's a better way, but this fixes the immediate problem.
85597         Problem reported by Bruno Haible in
85598         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00478.html>.
85600 2011-05-22  Bruno Haible  <bruno@clisp.org>
85602         xgetcwd: Simplify autoconf macro.
85603         * m4/xgetcwd.m4 (gl_XGETCWD): Don't require gl_FUNC_GETCWD.
85605 2011-05-22  Bruno Haible  <bruno@clisp.org>
85607         New module 'mktime-internal'.
85608         * modules/mktime-internal: New file.
85609         * m4/timegm.m4 (gl_PREREQ_TIMEGM): Move contents to ...
85610         * m4/mktime.m4 (gl_FUNC_MKTIME_INTERNAL): New macro. Define
85611         mktime_internal as a C macro if libc has __mktime_internal.
85612         * modules/timegm (Depends-on): Add mktime-internal. Remove mktime. Add
85613         conditions.
85614         * MODULES.html.sh (Date and time <time.h>): Add mktime-internal.
85616 2011-05-22  Bruno Haible  <bruno@clisp.org>
85618         timegm: Correct mktime replacement statements.
85619         * m4/timegm.m4 (gl_PREREQ_TIMEGM): Set REPLACE_MKTIME, instead of
85620         defining mktime as a C macro. This completes a 2009-07-28 commit.
85622 2011-05-22  Bruno Haible  <bruno@clisp.org>
85624         timegm: Simplify autoconf macro.
85625         * m4/timegm.m4 (gl_PREREQ_TIMEGM): Don't require gl_TIME_R.
85627 2011-05-21  Paul Eggert  <eggert@cs.ucla.edu>
85629         clock-time: change to LGPLv2+.
85630         * modules/clock-time: Change from GPL to LGPLv2+.  Actually, it's
85631         BSD-like but we have no mark for that; this is good enough for now.
85633 2011-05-21  Bruno Haible  <bruno@clisp.org>
85635         strerror_r: Fix comments.
85636         * lib/strerror_r.c (strerror_r): Fix comment about Cygwin and sys_nerr.
85638 2011-05-21  Bruno Haible  <bruno@clisp.org>
85640         relocatable-prog-wrapper: Fix possible link error.
85641         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Move determination of
85642         HAVE_SETENV and REPLACE_SETENV and AC_LIBOBJ invocation from here...
85643         (gl_FUNC_SETENV): ... to here.
85644         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL_SEPARATE): Update comment.
85645         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): Likewise.
85647 2011-05-21  Bruno Haible  <bruno@clisp.org>
85649         relocatable-prog-wrapper: Assume strerror() exists.
85650         * modules/relocatable-prog-wrapper (Files): Remove lib/strerror.c,
85651         m4/strerror.m4.
85652         (configure.ac): Don't invoke gl_FUNC_STRERROR_SEPARATE.
85653         * lib/relocwrapper.c: Remove mention of strerror module.
85654         * lib/strerror.c: Assume REPLACE_STRERROR is 1.
85655         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Remove macro.
85656         (gl_FUNC_STRERROR): Inline it here. Don't define REPLACE_STRERROR as a
85657         C macro.
85659 2011-05-21  Bruno Haible  <bruno@clisp.org>
85661         select: Simplify replacement idiom.
85662         * m4/select.m4 (gl_FUNC_SELECT): Set REPLACE_SELECT also on native
85663         Win32 platforms.
85664         * lib/sys_select.in.h (select): Simplify accordingly.
85665         * modules/select (Depends-on): Likewise.
85667 2011-05-21  Bruno Haible  <bruno@clisp.org>
85669         mkdir-p: Simplify autoconf macro.
85670         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't require gl_FUNC_LCHMOD,
85671         gl_FUNC_LCHOWN.
85673 2011-05-21  Eric Blake  <eblake@redhat.com>
85675         strerror_r: avoid clobbering strerror on cygwin
85676         * lib/strerror_r.c (strerror_r): Don't use cygwin's strerror_r;
85677         fall back instead to sys_errlist.
85678         * modules/strerror (configure.ac): Add witness.
85679         * tests/test-strerror_r.c (main): Enhance test.
85680         * doc/posix-functions/strerror_r.texi (strerror_r): Document it.
85681         * tests/test-perror2.c (main): Free memory before exit.
85683 2011-05-21  Bruno Haible  <bruno@clisp.org>
85685         mkdtemp: Use gnulib naming conventions.
85686         * m4/mkdtemp.m4 (gl_FUNC_MKDTEMP): Renamed from gt_FUNC_MKDTEMP.
85687         * modules/mkdtemp (configure.ac): Update.
85689 2011-05-20  Eric Blake  <eblake@redhat.com>
85691         strerror_r: avoid corrupting errno on Solaris
85692         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Check for Solaris behavior.
85693         * doc/posix-functions/strerror_r.texi (strerror_r): Document it.
85695         strerror_r: avoid compiler warning
85696         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Don't return a char*.
85698         strerror_r: simplify AIX code
85699         * lib/strerror_r.c (strerror_r): Filter out buflen of 1 up front.
85701         test-perror: avoid spurious failure on FreeBSD
85702         * modules/perror-tests (Depends-on): Add strerror, now that
85703         strerror_r no longer pulls it in.
85705 2011-05-20  Bruno Haible  <bruno@clisp.org>
85707         strerror_r-posix: Remove unused dependencies.
85708         * modules/strerror_r-posix (Depends-on): Remove strerror.
85709         Reported by Eric Blake.
85711 2011-05-20  Paul Eggert  <eggert@cs.ucla.edu>
85713         intprops: remove assumption about A|B representation
85714         * lib/intprops.h (_GL_BINARY_OP_OVERFLOW): Do not assume that A|B
85715         is a valid integer if both A and B are.  Although this is true for
85716         all known practical hosts, the C standard doesn't guarantee it,
85717         and the code need not assume it.  Also, this change may work around
85718         HP-UX 11.23 and IRIX 6.5 cc bugs reported by Bruno Haible in
85719         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00426.html>.
85721 2011-05-20  Eric Blake  <eblake@redhat.com>
85723         perror: work around FreeBSD bug
85724         * m4/perror.m4 (gl_FUNC_PERROR): Also replace perror if strerror_r
85725         is broken.  Move AC_LIBOBJ...
85726         * modules/perror (configure.ac): Here.
85727         * doc/posix-functions/perror.texi (perror): Document this.
85728         * tests/test-perror2.c (main): Enhance test.
85730         test-perror: check for strerror interactions
85731         * tests/macros.h (STREQ): Add macro.
85732         * modules/perror-tests (Files): Add second test.
85733         * tests/test-perror2.c (main): New file.
85734         * doc/posix-functions/perror.texi (perror): Document glibc bug.
85736         test-perror: rewrite to use init script
85737         * modules/perror-tests (Files): Add init.sh.
85738         * tests/test-perror.sh: Use temporary directory.
85740 2011-05-20  Jim Meyering  <meyering@redhat.com>
85742         maint: replace misused "a" with "an"
85743         * doc/intprops.texi: "a integer"
85744         * doc/regex.texi: "a explanation"
85745         * lib/alignof.h: "a object"
85746         * lib/argmatch.h: "a explanation"
85747         * lib/argp-help.c: "a option" and "a OPTION_DOC"
85748         * lib/stdint.in.h: "a integer"
85749         * lib/userspec.c: "a owner"
85750         * doc/gnulib.texi: Fix "a idea", and reword.
85752 2011-05-19  Jim Meyering  <meyering@redhat.com>
85754         maint: correct misuse of "a" and "an"
85755         * doc/regex.texi (Collating Symbol Operators): s/an close.../a close/
85756         * lib/argp-help.c: "an docum...": s/an/a/
85757         * lib/argp-parse.c: "An vector": s/An/A/
85758         * lib/execute.c: "an native": s/an/a/
85759         * lib/spawn-pipe.c: Likewise.
85760         * lib/gc.h: "an Gc_rc": s/an/a/
85761         * lib/unigbrk.in.h: "an grapheme": s/an/a/
85762         * lib/fts.c: "an stat.st_dev": s/an/a/
85764 2011-05-19  Paul Eggert  <eggert@cs.ucla.edu>
85766         intprops-tests: work around HP-UX 11.23 cc bug with constants
85767         * tests/test-intprops.c (VERIFY): New macro.
85768         (main): Use it, instead of verify, to work around the compiler bug; see
85769         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00401.html>.
85771         intprops: work around IRIX 6.5 cc bug with 0u - 0u + -1
85772         See http://lists.gnu.org/r/bug-gnulib/2011-05/msg00406.html
85773         * lib/intprops.h (_GL_INT_NEGATE_CONVERT): New macro.
85774         (_GL_INT_SIGNED, _GL_INT_MAXIMUM, _GL_DIVIDE_OVERFLOW):
85775         (_GL_REMAINDER_OVERFLOW): Use it.
85777         intprops-tests: revert unsigned part of previous change
85778         * tests/test-intprops.c (UINT_MAX, ULONG_MAX, UINTMAX_MAX, U0, U1):
85779         Remove; they weren't actually needed.  All uses of U0 and U1 removed,
85780         and other casts to 'unsigned int' reverted to 'u' suffixes.  See
85781         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00406.html>.
85783 2011-05-19  Bruno Haible  <bruno@clisp.org>
85785         strerror_r: Work around strerror_r() change in Cygwin 1.7.8.
85786         * lib/strerror_r.c (strerror_r) [CYGWIN]: Recognize when the system's
85787         strerror_r() returned without filling the buffer.
85788         Reported by Eric Blake.
85790 2011-05-19  Eric Blake  <eblake@redhat.com>
85792         strerror_r: guarantee unchanged errno
85793         * lib/strerror_r.c (strerror_r): Guarantee unchanged errno.
85794         * lib/strerror-impl.h (strerror): Set errno to match strerror_r
85795         failure.
85796         * tests/test-strerror_r.c (main): Enhance test.
85798 2011-05-19  Bruno Haible  <bruno@clisp.org>
85800         strerror_r: Reorder #if blocks.
85801         * lib/strerror_r.c (strerror_r): Reorder conditionals in the function
85802         for consistency with the previous commit.
85804 2011-05-19  Bruno Haible  <bruno@clisp.org>
85806         perror: Avoid clobbering the strerror buffer when possible.
85807         * lib/strerror-impl.h: New file, extracted from lib/strerror.c.
85808         * lib/strerror.c: Include it.
85809         * modules/strerror (Files): Add lib/strerror-impl.h.
85810         * lib/perror.c: Include <stdlib.h>, intprops.h, verify.h.
85811         (my_strerror): New function, defined through lib/strerror-impl.h.
85812         (perror): Use it instead of strerror.
85813         * modules/perror (Files): Add lib/strerror-impl.h.
85814         (Depends-on): Remove strerror. Add intprops, verify, strerror_r-posix.
85816 2011-05-19  Eric Blake  <eblake@redhat.com>
85818         strerror_r: fix on newer cygwin
85819         * lib/strerror_r.c (strerror_r): Cygwin now has
85820         __xpg_strerror_r, use it.
85822 2011-05-19  Bruno Haible  <bruno@clisp.org>
85824         strerror_r: Avoid clobbering the strerror buffer when possible.
85825         * lib/strerror.c: Define _NETBSD_SOURCE. Include <nl_types.h>.
85826         (sys_nerr, sys_errlist): New declarations.
85827         (strerror_r): Be careful not to clobber the strerror buffer on NetBSD,
85828         HP-UX, native Win32, IRIX, and 32-bit Solaris.
85829         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R): Test whether catgets exists.
85831 2011-05-19  Bruno Haible  <bruno@clisp.org>
85833         strerror_r: Fix test failure on mingw.
85834         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Don't define
85835         EXTEND_STRERROR_R.
85836         * lib/strerror_r.c (strerror_r): Test the various GNULIB_defined_*
85837         macros from errno.in.h instead.
85839 2011-05-19  Eric Blake  <eblake@redhat.com>
85841         strerror: relax test for Solaris
85842         * tests/test-strerror.c (main): Permit Solaris behavior.
85843         * tests/test-strerror_r.c (main): Likewise.
85845         strerror: enforce POSIX ruling on strerror(0)
85846         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Expose BSD bug.
85847         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Likewise.
85848         * lib/strerror_r.c (rpl_strerror_r): Work around it.
85849         * doc/posix-functions/strerror.texi (strerror): Document it.
85850         * doc/posix-functions/strerror_r.texi (strerror_r): Likewise.
85851         * tests/test-strerror.c (main): Strengthen test.
85852         * tests/test-strerror_r.c (main): Likewise.
85854 2011-05-19  Paul Eggert  <eggert@cs.ucla.edu>
85856         intprop-tests: port to older and more-pedantic compilers
85857         * modules/intprops-tests (Files): Add tests/macros.h.
85858         * tests/test-intprops.c: Include macros.h.
85859         (TYPE_IS_INTEGER): Use ASSERT, not verify, to test this macro, as
85860         it's no longer documented to expand to an integer constant expression.
85861         (TYPE_SIGNED): Use ASSERT, not verify, to test this macro when the
85862         argument is floating point, as it's no longer documented to expand
85863         to an integer constant expression in that case.
85864         (UINT_MAX, ULONG_MAX, UINTMAX_MAX): Redefine to work around
85865         compiler bugs reported by Bruno Haible.  See
85866         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00401.html>.
85867         (U0, U1): New constants, to work around the same bugs.  Also,
85868         in tests, use e.g., "(unsigned int) 39" rather than "39u".
85870         intprops: work around C compiler bugs
85871         * lib/intprops.h (INT_MULTIPLY_RANGE_OVERFLOW): Work around compiler
85872         bug in Sun C 5.11 2010/08/13 and other compilers; see
85873         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00401.html>.
85875         intprops: TYPE_IS_INTEGER, TYPE_SIGNED not integer constant exprs
85876         * doc/intprops.texi (Integer Type Determination): Fix
85877         documentation for TYPE_IS_INTEGER: it returns an constant
85878         expression, not an integer constant expression.  Fix doc for
85879         TYPE_SIGNED: it returns an integer constant expression only if its
85880         argument is an integer type.  (TYPE_IS_INTEGER is the same, but is
85881         hardly worth documented that way....)
85883 2011-05-18  Bruno Haible  <bruno@clisp.org>
85885         strerror_r: Avoid clobbering the strerror buffer when possible.
85886         * lib/strerror_r.c (strerror_r): Merge the three implementations.
85887         Handle gnulib defined errno values here. When strerror() returns NULL
85888         or an empty string, return EINVAL.
85889         * lib/strerror.c (strerror): Always call strerror_r. Don't handle
85890         gnulib defined errno values here.
85891         * modules/strerror (Depends-on): Add verify, strerror_r-posix.
85893 2011-05-18  Eric Blake  <eblake@redhat.com>
85895         fnmatch: avoid compiler warning
85896         * lib/fnmatch_loop.c (FCT): Use correct type.
85897         Reported by Matthias Bolte.
85899 2011-05-13  Jim Meyering  <meyering@redhat.com>
85901         maint.mk: three new prohibit_<HDR>_without_use rules
85902         * top/maint.mk (sc_prohibit_stdio--_without_use): New rule.
85903         (sc_prohibit_stdio-safer_without_use): Likewise.
85904         (sc_prohibit_xfreopen_without_use): Likewise.
85906 2011-05-17  Jim Meyering  <meyering@redhat.com>
85908         announce-gen: fail if the NEWS delta is empty
85909         If there's nothing noteworthy in NEWS, then either you forgot
85910         or you shouldn't be releasing.
85911         * build-aux/announce-gen: Die if the NEWS delta is effectively empty.
85913 2011-05-17  Pádraig Brady  <P@draigBrady.com>
85915         * top/maint.mk (_gl_tight_scope:): Automatically exclude compiler
85916         reserved symbols starting with double underscore from the check.
85918 2011-05-17  Paul Eggert  <eggert@cs.ucla.edu>
85920         intprops: add doc
85921         * doc/intprops.texi: New file, documenting intprops.
85922         * doc/gnulib.texi (Particular Modules): Include it.
85924         verify: add doc to gnulib manual and fix example
85925         * doc/gnulib.texi (Compile-time Assertions): New node, for 'verify'.
85926         * doc/verify.texi (Compile-time Assertions): Update 'assert' doc.
85927         (Compile-time Assertions): Fix example so it can't overflow.
85929 2011-05-17  Jim Meyering  <meyering@redhat.com>
85931         warnings.m4: don't usurp save_CPPFLAGS variable name
85932         * m4/warnings.m4: Prefix local temporary variable name with gl_.
85934         doc: fix typo
85935         * doc/gnulib-intro.texi (Target Platforms): s/is/are/
85937 2011-05-16  Paul Eggert  <eggert@cs.ucla.edu>
85938             Bruno Haible  <bruno@clisp.org>
85940         doc: Tweak recent change.
85941         * README (Portability guidelines): Tweak new text.
85942         * doc/gnulib-intro.texi (Target Platforms): Likewise. Mention
85943         Interix 6.1.
85945 2011-05-16  Eric Blake  <eblake@redhat.com>
85947         inttypes: avoid autoconf warning
85948         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): Only expand once.
85949         * m4/stdint.m4 (gl_STDINT_H): Likewise.
85951 2011-05-16  Sam Steingold  <sds@gnu.org>
85952         and Eric Blake  <eblake@redhat.com>
85954         vc-list-files: accept multiple directory operands
85955         * build-aux/vc-list-files: Iterate over all remaining operands.
85957 2011-05-16  Bruno Haible  <bruno@clisp.org>
85959         Fix confusion regarding deprecated modules.
85960         * modules/calloc (Status, Notice): Mark module as deprecated, not
85961         obsolete.
85962         * modules/fnmatch-posix (Status, Notice): Likewise.
85963         * modules/getdate (Status, Notice): Likewise.
85964         * modules/getopt (Status, Notice): Likewise.
85965         * modules/malloc (Status, Notice): Likewise.
85966         * modules/pipe (Status, Notice): Likewise.
85967         * modules/realloc (Status, Notice): Likewise.
85968         * modules/rename-dest-slash (Status, Notice): Likewise.
85969         * modules/unictype/bidicategory-all (Status, Notice): Likewise.
85970         * modules/unictype/bidicategory-byname (Status, Notice): Likewise.
85971         * modules/unictype/bidicategory-name (Status, Notice): Likewise.
85972         * modules/unictype/bidicategory-of (Status, Notice): Likewise.
85973         * modules/unictype/bidicategory-test (Status, Notice): Likewise.
85975 2011-05-16  Bruno Haible  <bruno@clisp.org>
85977         doc: List the target platforms.
85978         * doc/gnulib-intro.texi (Target Platforms): New section.
85979         * doc/gnulib.texi (Introduction): Update menu.
85980         * README (Portability guidelines): Refer to the new section. Update
85981         statement about oldest supported environment. Remove rationale why
85982         <errno.h>, <string.h>, <stdlib.h> are assumed. Update example of an
85983         unportable C89 function.
85984         Reported by Bastien Roucariès <roucaries.bastien@gmail.com> and
85985         Charles Wilson <cygwin@cwilson.fastmail.fm>. Feedback from Paul Eggert.
85987 2011-05-16  Paul Eggert  <eggert@cs.ucla.edu>
85989         * build-aux/bootstrap (gnulib_tool): Handle symlink timestamps better.
85991 2011-05-13  Paul Eggert  <eggert@cs.ucla.edu>
85993         intprops-tests: new module
85994         * modules/intprops-tests, tests/test-intprops.c: New files.
85996         intprops: add safe, portable integer overflow checking
85997         * lib/intprops.h (_GL_INT_CONVERT, _GL_INT_TWOS_COMPLEMENT):
85998         (_GL_INT_SIGNED, _GL_INT_MINIMUM, _GL_INT_MAXIMUM):
85999         (_GL_SIGNED_INT_MINIMUM, INT_ADD_RANGE_OVERFLOW):
86000         (INT__SUBTRACT__RANGE_OVERFLOW, INT_NEGATE_RANGE_OVERFLOW):
86001         (INT_MULTIPLY_RANGE_OVERFLOW, INT_REMAINDER_RANGE_OVERFLOW):
86002         (INT_LEFT_SHIFT_RANGE_OVERFLOW, _GL_ADD_OVERFLOW):
86003         (_GL__SUBTRACT__OVERFLOW, _GL_MULTIPLY_OVERFLOW, _GL_DIVIDE_OVERFLOW):
86004         (_GL_REMAINDER_OVERFLOW, _GL_UNSIGNED_NEG_MULTIPLE, INT_ADD_OVERFLOW):
86005         (INT__SUBTRACT__OVERFLOW, INT_NEGATE_OVERFLOW, INT_MULTIPLY_OVERFLOW):
86006         (INT_DIVIDE_OVERFLOW, INT_REMAINDER_OVERFLOW):
86007         (INT_LEFT_SHIFT_OVERFLOW, _GL_BINARY_OP_OVERFLOW): New macros.
86009 2011-05-12  James Youngman  <jay@gnu.org>
86011         Add a test for glibc's Bugzilla bug #12378.
86012         * m4/fnmatch.m4: Use gnulib's fnmatch if the system fnmatch
86013         doesn't allow the literal matching of a lone "[" (which is
86014         required by POSIX).
86015         * tests/test-fnmatch.c (main): Check that "[/b" matches itself.
86017 2011-05-11  Ulrich Drepper  <drepper@gmail.com>
86019         Sync glibc change fixing Bugzilla bug #12378.
86020         * lib/fnmatch_loop.c (FCT): When matching '[' keep track of
86021         beginning and fall back to matching as normal character if the
86022         string ends before the matching ']' is found.  This is what POSIX
86023         requires.
86025 2011-05-13  Eric Blake  <eblake@redhat.com>
86027         getcwd-lgpl: relax test for FreeBSD
86028         * doc/posix-functions/getcwd.texi (getcwd): Document portability
86029         issue.
86030         * tests/test-getcwd-lgpl.c (main): Relax test.
86031         Reported by Matthias Bolte.
86033 2011-05-11  Eric Blake  <eblake@redhat.com>
86035         test-fflush: silence compiler warning
86036         * tests/test-fflush.c (main): Don't fclose a NULL pointer.
86038 2011-05-11  Bruno Haible  <bruno@clisp.org>
86040         canonicalize, canonicalize-lgpl: Avoid crash dialog on MacOS X.
86041         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Add GL_NOCRASH code.
86042         * modules/canonicalize (Depends-on): Add 'nocrash'.
86043         * modules/canonicalize-lgpl (Depends-on): Likewise.
86044         * doc/posix-functions/realpath.texi: Update platforms list.
86045         Reported by Ryan Schmidt <ryandesign@macports.org>.
86047 2011-05-11  Bruno Haible  <bruno@clisp.org>
86049         group-member: Declare function in <unistd.h>.
86050         * lib/unistd.in.h (group_member): New declaration.
86051         * lib/group-member.h: Remove file.
86052         * lib/group-member.c: Include <unistd.h> instead of group-member.h.
86053         * tests/test-unistd-c++.cc: Check signature of group_member.
86054         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Require
86055         gl_UNISTD_H_DEFAULTS. Set HAVE_GROUP_MEMBER.
86056         * m4/unistd_h.m4 (gl_UNISTD_H): Check whether group_member is declared.
86057         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GROUP_MEMBER,
86058         HAVE_GROUP_MEMBER.
86059         * modules/group-member (Files): Remove lib/group-member.h.
86060         (Depends-on): Add unistd. Specify conditions.
86061         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
86062         (Include): Change to <unistd.h>.
86063         * modules/unistd (Makefile.am): Substitute GNULIB_GROUP_MEMBER,
86064         HAVE_GROUP_MEMBER.
86065         * NEWS: Mention the change.
86066         * lib/euidaccess.c: Don't include group-member.h.
86068 2011-05-11  Bruno Haible  <bruno@clisp.org>
86070         group-member: Document module.
86071         * doc/glibc-functions/group_member.texi: Mention the 'group-member'
86072         module.
86074 2011-05-11  Bruno Haible  <bruno@clisp.org>
86076         fclose: Fix mistake earlier today.
86077         * lib/fclose.c (rpl_fclose): Don't assume that EOF < 0.
86079 2011-05-11  Eric Blake  <eblake@redhat.com>
86081         fclose: preserve fflush errors
86082         * lib/fclose.c (rpl_fclose): Don't lose fflush errors.
86083         Reported by Jim Meyering.
86085         bootstrap: support a prereq of 'rpcgen -' on RHEL5
86086         * build-aux/bootstrap (check_versions): When no specific version
86087         is required, merely check that the app produces an exit status
86088         that indicates its existence.
86090         maint.mk: drop redundant check
86091         * top/maint.mk (sc_the_the): Delete; sc_prohibit_doubled_word does
86092         the same but better.
86094 2011-05-11  Bruno Haible  <bruno@clisp.org>
86096         fclose: Fix possible link error.
86097         * lib/fclose.c (rpl_fclose): Invoke _gl_unregister_fd, not
86098         unregister_shadow_fd. Improve comments.
86099         * lib/sockets.c (close_fd_maybe_socket): Add comments. Reported by
86100         Eric Blake.
86102 2011-05-11  Jim Meyering  <meyering@redhat.com>
86104         maint.mk: improve "can not" detection and generalize rule name
86105         * top/maint.mk (sc_prohibit_undesirable_word_seq): Renamed from
86106         sc_prohibit_can_not, since we'll probably add a few more word pairs here.
86107         Use the same technique as in sc_prohibit_doubled_word, so that
86108         we recognize "can not" also when the words are separated by a newline.
86109         Suggested by Eric Blake.
86110         (perl_filename_lineno_text_): Define.  Factored out of...
86111         (prohibit_doubled_word_): ...here.  Use the new definition.
86112         (prohibit_undesirable_word_seq_): New var.  Use it here, too.
86113         (prohibit_undesirable_word_seq_RE_): New overridable variable.
86114         (ignore_undesirable_word_sequence_RE_): New overridable variable.
86116 2011-05-10  Eric Blake  <eblake@redhat.com>
86118         fclose: avoid double close race when possible
86119         * lib/fclose.c (rpl_fclose): Rewrite to avoid double-close race on
86120         all but WINDOWS_SOCKETS.
86122 2011-05-10  Bastien Roucariès  <roucaries.bastien@gmail.com>
86124         openat: correct new comment
86125         * lib/openat-proc.c (openat_proc_name): Correct the comment.
86127 2011-05-10  Jim Meyering  <meyering@redhat.com>
86129         openat: add comments
86130         * lib/openat-proc.c (openat_proc_name): Add comments,
86131         mostly from Eric Blake.
86133 2011-05-09  Eric Blake  <eblake@redhat.com>
86135         openat: reduce syscalls in first probe of /proc
86136         * lib/openat-proc.c (openat_proc_name): Require that /proc/self/fd
86137         be a directory.  Simplify the probe for .. bugs.
86138         * modules/openat (Depends-on): Drop same-inode.
86139         Reported by Bastien ROUCARIES.
86141 2011-05-09  Jim Meyering  <meyering@redhat.com>
86143         maint.mk: change semantics/name of tight_scope variables
86144         * top/maint.mk (_gl_TS_var_match, _gl_TS_function_match):
86145         Rename variables to align with semantics that make them more useful.
86147         maint.mk: tweak new rule's name not to impinge
86148         * top/maint.mk (_gl_tight_scope): Rename from sc_tight_scope-0.
86149         (sc_tight_scope): Use new rule name rather than $@-0.
86151         maint.mk: add a syntax-check rule to ensure tightly-scoped symbols
86152         * top/maint.mk (sc_tight_scope): New rule.
86153         (sc_tight_scope-0): New rule, ifdef'd out.
86154         (_gl_TS_dir): Default.
86155         (_gl_TS_unmarked_extern_functions, _gl_TS_function_regex): Define.
86156         (_gl_TS_unmarked_extern_vars, _gl_TS_var_regex): Define.
86158 2011-05-09  Simon Josefsson  <simon@josefsson.org>
86160         * m4/gc.m4: Remove gl_PREREQ_GC (not used).  Reported by Bruno
86161         Haible <bruno@clisp.org>.
86163 2011-05-08  Bruno Haible  <bruno@clisp.org>
86165         Comments.
86166         * m4/isnanf.m4: Add comment.
86167         * m4/isnanl.m4: Likewise.
86169 2011-05-08  Bruno Haible  <bruno@clisp.org>
86171         glob: Remove obsolete macro.
86172         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): Remove macro.
86174 2011-05-08  Paul Eggert  <eggert@cs.ucla.edu>
86176         intprops: Sun C 5.11 supports __typeof__
86177         * lib/intprops.h (_GL_HAVE___TYPEOF__): New macro, which is set
86178         for either GCC 2 or later, as before, or for Sun C 5.11 or later,
86179         which is new.
86180         (_GL_SIGNED_TYPE_OR_EXPR): Use it.
86182         intprops: switch to usual gnulib indenting and naming
86183         * lib/intprops.h (_GL_INTPROPS_H): Rename from GL_INTPROPS_H.
86184         (_GL_SIGNED_TYPE_OR_EXPR): Rename from signed_type_or_expr__.
86186         * tests/test-inttostr.c (IS_TIGHT): Adjust to above renaming.
86188 2011-05-08  Jim Meyering  <meyering@redhat.com>
86190         maint.mk: suppress "Entering/Leaving directory" diag in announcement
86191         * top/maint.mk (release-prep): Use make's --no-print-directory
86192         option when generating the announcement.  This eliminates the
86193         pesky "make[2]: Entering/Leaving directory" diagnostics in the
86194         generated announcement template.
86196 2011-05-08  Bruno Haible  <bruno@clisp.org>
86198         tzset: Fix gettimeofday wrapper on Solaris 2.6.
86199         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): When invoking
86200         gl_GETTIMEOFDAY_REPLACE_LOCALTIME, also set REPLACE_GETTIMEOFDAY.
86202 2011-05-07  Paul Eggert  <eggert@cs.ucla.edu>
86204         ignore-value, verify: Omit include files from lib_SOURCES.
86205         * modules/ignore-value, modules/verify (Makefile.am):
86206         Don't put ignore-value.h, or verify.h, into lib_SOURCES, as
86207         that leads Automake to duplicate use of am__objects_... variables
86208         in Makefile.in.  See
86209         <http://lists.gnu.org/r/emacs-devel/2011-05/msg00257.html>.
86211 2011-05-07  Bruno Haible  <bruno@clisp.org>
86213         fclose: Simplify autoconf macro.
86214         * m4/fclose.m4 (gl_FUNC_FCLOSE): Assume gl_FUNC_FFLUSH_STDIN is
86215         defined.
86217 2011-05-07  Bruno Haible  <bruno@clisp.org>
86219         canonicalize-lgpl: Fix autoconf macro ordering bug.
86220         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL): Require
86221         gl_STDLIB_H_DEFAULTS.
86223 2011-05-06  Eric Blake  <eblake@redhat.com>
86225         maintainer-makefile: make sc_po_check easier to tune
86226         * top/maint.mk (sc_po_check): Allow overriding which non-VC files
86227         to probe for strings, such as an alternate location for gnulib.
86229         fclose: guarantee behavior on seekable stdin
86230         * modules/fclose (Depends-on): Add fflush.
86231         * doc/posix-functions/fclose.texi (fclose): Document this.
86232         * tests/test-fclose.c (main): Make test for this unconditional.
86234 2011-05-06  Bruno Haible  <bruno@clisp.org>
86236         fflush, fpurge: Relicense under LGPLv2+.
86237         * modules/fflush (License): Change from LGPLv3+ to LGPLv2+.
86238         * modules/fpurge (License): Likewise.
86239         With permission from Eric Blake and Jim Meyering.
86240         Suggested by Eric Blake.
86242 2011-05-06  Karl Berry  <karl@gnu.org>
86244         * MODULES.html.sh (func_all_modules): remove exit.
86246 2011-05-06  Jim Meyering  <meyering@redhat.com>
86248         maint.mk: use info-gnu@ as the default only for a stable release
86249         * top/maint.mk: Don't default to info-gnu for alpha or beta releases.
86250         For those, just use $(PACKAGE_BUGREPORT), in which case we don't have
86251         to set the Mail-Followup-To header.  Prompted by Reuben Thomas in
86252         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/26488
86254 2011-05-05  Paul Eggert  <eggert@cs.ucla.edu>
86256         assert-h: new module, which supports C1X-style static_assert
86257         * lib/assert.in.h, m4/assert_h.m4, modules/assert-h: New files.
86258         * lib/verify.h: Revamp so that this can be copied into assert.h,
86259         while retaining the ability to use it standalone as before.
86260         Rename private identifiers so as not to encroach on the
86261         standard C namespace, since this is now used by assert.h.
86262         (_GL_VERIFY_TYPE): New macro, factoring out differing parts of
86263         the old verify_true.
86264         (_GL_VERIFY_TRUE): New macro, with much of the contents of
86265         the old verify_true.  Use _GL_VERIFY_TYPE.
86266         (_GL_VERIFY): New macro, with much of the contents of the old verify.
86267         (static_assert): New macro, if _GL_STATIC_ASSERT_H
86268         is defined and static_assert is not; _GL_STATIC_ASSERT_H is
86269         defined when this file is copied into the replacement assert.h.
86270         (_Static_assert): New macro, if _GL_STATIC_ASSERT_H is defined
86271         and _Static_assert is not built in.
86272         (verify_true, verify): Define only if _GL_STATIC_ASSERT_H is not
86273         defined, and use the new macros mentioned above.
86274         * doc/posix-headers/assert.texi: Document this.
86276 2011-05-05  Bruno Haible  <bruno@clisp.org>
86278         fclose, fflush: Respect rules for use of AC_LIBOBJ.
86279         * m4/fflush.m4 (gl_FUNC_FFLUSH): Don't invoke gl_REPLACE_FCLOSE.
86280         * m4/fclose.m4 (gl_FUNC_FCLOSE): Invoke gl_FUNC_FFLUSH_STDIN and
86281         gl_REPLACE_FCLOSE here.
86282         * modules/fflush (Depends-on): Remove fclose.
86283         * doc/posix-functions/fclose.texi: Mention module 'fflush' only in
86284         combination with module 'fclose'.
86286 2011-05-05  Bruno Haible  <bruno@clisp.org>
86288         fflush, fseeko: Respect rules for use of AC_LIBOBJ.
86289         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): New macro, extracted from
86290         gl_FUNC_FFLUSH.
86291         (gl_FUNC_FFLUSH): Use it.
86292         (gl_REPLACE_FFLUSH): Don't invoke gl_REPLACE_FSEEKO.
86293         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Invoke gl_FUNC_FFLUSH_STDIN and
86294         gl_REPLACE_FSEEKO here.
86296 2011-05-05  Bruno Haible  <bruno@clisp.org>
86298         tzset: Relicense under LGPL.
86299         * modules/tzset (License): Change to LGPL.
86300         No agreement needed; it's a no-op.
86302         strtoimax, strtoumax: Relicense under LGPL.
86303         * modules/strtoimax (License): Change to LGPL.
86304         * modules/strtoumax (License): Likewise.
86305         With permission from Jim Meyering, Paul Eggert:
86306         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00124.html>
86307         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00109.html>
86309         getgroups: Relicense under LGPL.
86310         * modules/getgroups (License): Change to LGPL.
86311         With permission from Jim Meyering, Paul Eggert, Eric Blake:
86312         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00111.html>
86313         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00148.html>
86314         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
86316         nanosleep: Relicense under LGPL.
86317         * modules/nanosleep (License): Change to LGPL.
86318         With permission from Jim Meyering, Paul Eggert, Eric Blake, Bruno
86319         Haible:
86320         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00111.html>
86321         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00148.html>
86322         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
86323         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00131.html>
86325         futimens: Relicense under LGPL.
86326         * modules/futimens (License): Change to LGPL.
86327         With permission from Eric Blake:
86328         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
86330         fflush: Relicense under LGPL.
86331         * modules/fflush (License): Change to LGPL.
86332         With permission from Eric Blake, Bruno Haible, Jim Meyering:
86333         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
86334         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00131.html>
86335         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00133.html>
86337         tmpfile: Relicense under LGPL.
86338         * modules/tmpfile (License): Change to LGPL.
86339         With permission from Ben Pfaff:
86340         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00185.html>
86342         isfinite: Relicense under LGPL.
86343         * modules/isfinite (License): Change to LGPL.
86344         With permission from Ben Pfaff, Bruno Haible:
86345         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00185.html>
86346         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00130.html>
86348         acosl..tanl: Relicense under LGPL.
86349         * modules/acosl (License): Change to LGPL.
86350         * modules/asinl (License): Likewise.
86351         * modules/atanl (License): Likewise.
86352         * modules/cosl (License): Likewise.
86353         * modules/expl (License): Likewise.
86354         * modules/logl (License): Likewise.
86355         * modules/sinl (License): Likewise.
86356         * modules/sqrtl (License): Likewise.
86357         * modules/tanl (License): Likewise.
86358         Source code originally from glibc and Paolo Bonzini. Agreements:
86359         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00137.html>
86360         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00128.html>
86362 2011-05-05  Bruno Haible  <bruno@clisp.org>
86364         signal: Define sighandler_t.
86365         * lib/signal.in.h (sighandler_t): New type.
86366         * m4/signal_h.m4 (gl_SIGNAL_H): Require AC_USE_SYSTEM_EXTENSIONS. Test
86367         whether sighandler_t is defined.
86368         (gl_SIGNAL_H_DEFAULTS): Initialize HAVE_SIGHANDLER_T.
86369         * modules/signal (Depends-on): Add extensions.
86370         (Makefile.am): Substitute HAVE_SIGHANDLER_T.
86371         * doc/posix-headers/signal.texi: Mention the problem with sighandler_t.
86372         Suggested by Markus Steinborn <gnugv_maintainer@yahoo.de>.
86374 2011-05-05  Eric Blake  <eblake@redhat.com>
86376         maint: remove useless REPLACE_*_H macros
86377         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Delete.
86378         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H): Likewise.
86379         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H): Likewise.
86380         * m4/poll_h.m4 (gl_REPLACE_POLL_H): Likewise.
86381         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H): Likewise.
86382         * m4/sys_ioctl_h.m4 (gl_REPLACE_SYS_IOCTL_H): Likewise.
86383         * m4/wchar_h.m4 (gl_REPLACE_WCHAR_H): Likewise.
86384         * m4/btowc.m4: Update callers.
86385         * m4/dirfd.m4: Likewise.
86386         * m4/duplocale.m4: Likewise.
86387         * m4/fchdir.m4: Likewise.
86388         * m4/fdopendir.m4: Likewise.
86389         * m4/inet_ntop.m4: Likewise.
86390         * m4/inet_pton.m4: Likewise.
86391         * m4/ioctl.m4: Likewise.
86392         * m4/mbrlen.m4: Likewise.
86393         * m4/mbrtowc.m4: Likewise.
86394         * m4/mbsinit.m4: Likewise.
86395         * m4/mbsnrtowcs.m4: Likewise.
86396         * m4/mbsrtowcs.m4: Likewise.
86397         * m4/poll.m4: Likewise.
86398         * m4/setlocale.m4: Likewise.
86399         * m4/wcrtomb.m4: Likewise.
86400         * m4/wcsnrtombs.m4: Likewise.
86401         * m4/wcsrtombs.m4: Likewise.
86402         * m4/wctob.m4: Likewise.
86403         * m4/wcwidth.m4: Likewise.
86404         * modules/posix_spawn: Likewise.
86405         * modules/posix_spawn_file_actions_addclose: Likewise.
86406         * modules/posix_spawn_file_actions_adddup2: Likewise.
86407         * modules/posix_spawn_file_actions_addopen: Likewise.
86408         * modules/posix_spawn_file_actions_destroy: Likewise.
86409         * modules/posix_spawn_file_actions_init: Likewise.
86410         * modules/posix_spawnattr_destroy: Likewise.
86411         * modules/posix_spawnattr_getflags: Likewise.
86412         * modules/posix_spawnattr_getpgroup: Likewise.
86413         * modules/posix_spawnattr_getschedparam: Likewise.
86414         * modules/posix_spawnattr_getschedpolicy: Likewise.
86415         * modules/posix_spawnattr_getsigdefault: Likewise.
86416         * modules/posix_spawnattr_getsigmask: Likewise.
86417         * modules/posix_spawnattr_init: Likewise.
86418         * modules/posix_spawnattr_setflags: Likewise.
86419         * modules/posix_spawnattr_setpgroup: Likewise.
86420         * modules/posix_spawnattr_setschedparam: Likewise.
86421         * modules/posix_spawnattr_setschedpolicy: Likewise.
86422         * modules/posix_spawnattr_setsigdefault: Likewise.
86423         * modules/posix_spawnattr_setsigmask: Likewise.
86424         * modules/posix_spawnp: Likewise.
86426 2011-05-04  Reuben Thomas  <rrt@sc3d.org>
86428         Add option to do-release-commit-and-tag to specify branch.
86429         * build-aux/do-release-commit-and-tag: Add --branch.
86431 2011-05-03  Bruno Haible  <bruno@clisp.org>
86433         Avoid unnecessary compilation units, through conditional dependencies.
86434         * modules/accept (Depends-on): Add conditions to the dependencies.
86435         * modules/acosl (Depends-on): Likewise.
86436         * modules/argz (Depends-on): Likewise.
86437         * modules/asinl (Depends-on): Likewise.
86438         * modules/atanl (Depends-on): Likewise.
86439         * modules/atoll (Depends-on): Likewise.
86440         * modules/bind (Depends-on): Likewise.
86441         * modules/btowc (Depends-on): Likewise.
86442         * modules/canonicalize-lgpl (Depends-on): Likewise.
86443         * modules/ceil (Depends-on): Likewise.
86444         * modules/ceilf (Depends-on): Likewise.
86445         * modules/ceill (Depends-on): Likewise.
86446         * modules/chdir-long (Depends-on): Likewise.
86447         * modules/chown (Depends-on): Likewise.
86448         * modules/close (Depends-on): Likewise.
86449         * modules/connect (Depends-on): Likewise.
86450         * modules/cosl (Depends-on): Likewise.
86451         * modules/dirfd (Depends-on): Likewise.
86452         * modules/dprintf (Depends-on): Likewise.
86453         * modules/dprintf-posix (Depends-on): Likewise.
86454         * modules/error (Depends-on): Likewise.
86455         * modules/euidaccess (Depends-on): Likewise.
86456         * modules/expl (Depends-on): Likewise.
86457         * modules/faccessat (Depends-on): Likewise.
86458         * modules/fchdir (Depends-on): Likewise.
86459         * modules/fclose (Depends-on): Likewise.
86460         * modules/fcntl (Depends-on): Likewise.
86461         * modules/fdopendir (Depends-on): Likewise.
86462         * modules/fflush (Depends-on): Likewise.
86463         * modules/floor (Depends-on): Likewise.
86464         * modules/floorf (Depends-on): Likewise.
86465         * modules/floorl (Depends-on): Likewise.
86466         * modules/fnmatch (Depends-on): Likewise.
86467         * modules/fopen (Depends-on): Likewise.
86468         * modules/fprintf-posix (Depends-on): Likewise.
86469         * modules/frexp (Depends-on): Likewise.
86470         * modules/frexp-nolibm (Depends-on): Likewise.
86471         * modules/frexpl (Depends-on): Likewise.
86472         * modules/frexpl-nolibm (Depends-on): Likewise.
86473         * modules/fseek (Depends-on): Likewise.
86474         * modules/fsusage (Depends-on): Likewise.
86475         * modules/ftell (Depends-on): Likewise.
86476         * modules/ftello (Depends-on): Likewise.
86477         * modules/futimens (Depends-on): Likewise.
86478         * modules/getcwd (Depends-on): Likewise.
86479         * modules/getcwd-lgpl (Depends-on): Likewise.
86480         * modules/getdelim (Depends-on): Likewise.
86481         * modules/getdomainname (Depends-on): Likewise.
86482         * modules/getgroups (Depends-on): Likewise.
86483         * modules/gethostname (Depends-on): Likewise.
86484         * modules/getline (Depends-on): Likewise.
86485         * modules/getlogin_r (Depends-on): Likewise.
86486         * modules/getopt-posix (Depends-on): Likewise.
86487         * modules/getpeername (Depends-on): Likewise.
86488         * modules/getsockname (Depends-on): Likewise.
86489         * modules/getsockopt (Depends-on): Likewise.
86490         * modules/getsubopt (Depends-on): Likewise.
86491         * modules/getusershell (Depends-on): Likewise.
86492         * modules/glob (Depends-on): Likewise.
86493         * modules/grantpt (Depends-on): Likewise.
86494         * modules/iconv_open (Depends-on): Likewise.
86495         * modules/iconv_open-utf (Depends-on): Likewise.
86496         * modules/inet_ntop (Depends-on): Likewise.
86497         * modules/inet_pton (Depends-on): Likewise.
86498         * modules/ioctl (Depends-on): Likewise.
86499         * modules/isapipe (Depends-on): Likewise.
86500         * modules/isfinite (Depends-on): Likewise.
86501         * modules/isinf (Depends-on): Likewise.
86502         * modules/lchown (Depends-on): Likewise.
86503         * modules/ldexpl (Depends-on): Likewise.
86504         * modules/link (Depends-on): Likewise.
86505         * modules/linkat (Depends-on): Likewise.
86506         * modules/listen (Depends-on): Likewise.
86507         * modules/logl (Depends-on): Likewise.
86508         * modules/lstat (Depends-on): Likewise.
86509         * modules/mbrlen (Depends-on): Likewise.
86510         * modules/mbrtowc (Depends-on): Likewise.
86511         * modules/mbsinit (Depends-on): Likewise.
86512         * modules/mbsnrtowcs (Depends-on): Likewise.
86513         * modules/mbsrtowcs (Depends-on): Likewise.
86514         * modules/mbtowc (Depends-on): Likewise.
86515         * modules/memcmp (Depends-on): Likewise.
86516         * modules/mkdir (Depends-on): Likewise.
86517         * modules/mkdtemp (Depends-on): Likewise.
86518         * modules/mkfifo (Depends-on): Likewise.
86519         * modules/mkfifoat (Depends-on): Likewise.
86520         * modules/mknod (Depends-on): Likewise.
86521         * modules/mkostemp (Depends-on): Likewise.
86522         * modules/mkostemps (Depends-on): Likewise.
86523         * modules/mkstemp (Depends-on): Likewise.
86524         * modules/mkstemps (Depends-on): Likewise.
86525         * modules/mktime (Depends-on): Likewise.
86526         * modules/nanosleep (Depends-on): Likewise.
86527         * modules/open (Depends-on): Likewise.
86528         * modules/openat (Depends-on): Likewise.
86529         * modules/perror (Depends-on): Likewise.
86530         * modules/poll (Depends-on): Likewise.
86531         * modules/popen (Depends-on): Likewise.
86532         * modules/posix_spawn (Depends-on): Likewise.
86533         * modules/posix_spawn_file_actions_addclose (Depends-on): Likewise.
86534         * modules/posix_spawn_file_actions_adddup2 (Depends-on): Likewise.
86535         * modules/posix_spawn_file_actions_addopen (Depends-on): Likewise.
86536         * modules/posix_spawnp (Depends-on): Likewise.
86537         * modules/pread (Depends-on): Likewise.
86538         * modules/printf-posix (Depends-on): Likewise.
86539         * modules/ptsname (Depends-on): Likewise.
86540         * modules/putenv (Depends-on): Likewise.
86541         * modules/pwrite (Depends-on): Likewise.
86542         * modules/readline (Depends-on): Likewise.
86543         * modules/readlink (Depends-on): Likewise.
86544         * modules/readlinkat (Depends-on): Likewise.
86545         * modules/recv (Depends-on): Likewise.
86546         * modules/recvfrom (Depends-on): Likewise.
86547         * modules/regex (Depends-on): Likewise.
86548         * modules/remove (Depends-on): Likewise.
86549         * modules/rename (Depends-on): Likewise.
86550         * modules/renameat (Depends-on): Likewise.
86551         * modules/rmdir (Depends-on): Likewise.
86552         * modules/round (Depends-on): Likewise.
86553         * modules/roundf (Depends-on): Likewise.
86554         * modules/roundl (Depends-on): Likewise.
86555         * modules/rpmatch (Depends-on): Likewise.
86556         * modules/select (Depends-on): Likewise.
86557         * modules/send (Depends-on): Likewise.
86558         * modules/sendto (Depends-on): Likewise.
86559         * modules/setenv (Depends-on): Likewise.
86560         * modules/setlocale (Depends-on): Likewise.
86561         * modules/setsockopt (Depends-on): Likewise.
86562         * modules/shutdown (Depends-on): Likewise.
86563         * modules/sigaction (Depends-on): Likewise.
86564         * modules/signbit (Depends-on): Likewise.
86565         * modules/sigprocmask (Depends-on): Likewise.
86566         * modules/sinl (Depends-on): Likewise.
86567         * modules/sleep (Depends-on): Likewise.
86568         * modules/snprintf (Depends-on): Likewise.
86569         * modules/snprintf-posix (Depends-on): Likewise.
86570         * modules/socket (Depends-on): Likewise.
86571         * modules/sprintf-posix (Depends-on): Likewise.
86572         * modules/sqrtl (Depends-on): Likewise.
86573         * modules/stat (Depends-on): Likewise.
86574         * modules/strchrnul (Depends-on): Likewise.
86575         * modules/strdup-posix (Depends-on): Likewise.
86576         * modules/strerror (Depends-on): Likewise.
86577         * modules/strerror_r-posix (Depends-on): Likewise.
86578         * modules/strndup (Depends-on): Likewise.
86579         * modules/strnlen (Depends-on): Likewise.
86580         * modules/strptime (Depends-on): Likewise.
86581         * modules/strsep (Depends-on): Likewise.
86582         * modules/strsignal (Depends-on): Likewise.
86583         * modules/strstr-simple (Depends-on): Likewise.
86584         * modules/strtod (Depends-on): Likewise.
86585         * modules/strtoimax (Depends-on): Likewise.
86586         * modules/strtok_r (Depends-on): Likewise.
86587         * modules/strtoumax (Depends-on): Likewise.
86588         * modules/symlink (Depends-on): Likewise.
86589         * modules/symlinkat (Depends-on): Likewise.
86590         * modules/tanl (Depends-on): Likewise.
86591         * modules/tcgetsid (Depends-on): Likewise.
86592         * modules/tmpfile (Depends-on): Likewise.
86593         * modules/trunc (Depends-on): Likewise.
86594         * modules/truncf (Depends-on): Likewise.
86595         * modules/truncl (Depends-on): Likewise.
86596         * modules/uname (Depends-on): Likewise.
86597         * modules/unlink (Depends-on): Likewise.
86598         * modules/unlockpt (Depends-on): Likewise.
86599         * modules/unsetenv (Depends-on): Likewise.
86600         * modules/usleep (Depends-on): Likewise.
86601         * modules/utimensat (Depends-on): Likewise.
86602         * modules/vasprintf (Depends-on): Likewise.
86603         * modules/vdprintf (Depends-on): Likewise.
86604         * modules/vdprintf-posix (Depends-on): Likewise.
86605         * modules/vfprintf-posix (Depends-on): Likewise.
86606         * modules/vprintf-posix (Depends-on): Likewise.
86607         * modules/vsnprintf (Depends-on): Likewise.
86608         * modules/vsnprintf-posix (Depends-on): Likewise.
86609         * modules/vsprintf-posix (Depends-on): Likewise.
86610         * modules/wcrtomb (Depends-on): Likewise.
86611         * modules/wcscasecmp (Depends-on): Likewise.
86612         * modules/wcscspn (Depends-on): Likewise.
86613         * modules/wcsdup (Depends-on): Likewise.
86614         * modules/wcsncasecmp (Depends-on): Likewise.
86615         * modules/wcsnrtombs (Depends-on): Likewise.
86616         * modules/wcspbrk (Depends-on): Likewise.
86617         * modules/wcsrtombs (Depends-on): Likewise.
86618         * modules/wcsspn (Depends-on): Likewise.
86619         * modules/wcsstr (Depends-on): Likewise.
86620         * modules/wcstok (Depends-on): Likewise.
86621         * modules/wcswidth (Depends-on): Likewise.
86622         * modules/wctob (Depends-on): Likewise.
86623         * modules/wctomb (Depends-on): Likewise.
86624         * modules/wctype (Depends-on): Likewise.
86625         * modules/wcwidth (Depends-on): Likewise.
86626         * modules/write (Depends-on): Likewise.
86628 2011-05-03  Bruno Haible  <bruno@clisp.org>
86630         Support for conditional dependencies.
86631         * doc/gnulib.texi (Module description): Document the syntax of
86632         conditional dependencies.
86633         * gnulib-tool: New option --conditional-dependencies.
86634         (func_usage): Document it.
86635         (cond_dependencies): New variable.
86636         (func_get_automake_snippet_conditional,
86637         func_get_automake_snippet_unconditional): New functions, extracted from
86638         func_get_automake_snippet.
86639         (func_get_automake_snippet): Use them.
86640         (sed_first_32_chars): New variable.
86641         (func_module_shellfunc_name): New function.
86642         (func_module_shellvar_name): New function.
86643         (func_module_conditional_name): New function.
86644         (func_uncond_add_module, func_conddep_add_module, func_cond_module_p,
86645         func_cond_module_condition): New functions.
86646         (func_modules_transitive_closure): Add support for conditional
86647         dependencies.
86648         (func_emit_lib_Makefile_am): For a conditional module, enclose the
86649         conditional automake snippet in an automake conditional.
86650         (func_emit_autoconf_snippets): Emit shell functions that contain the
86651         code for conditional modules.
86652         (func_import, func_create_testdir): Update specification.
86654 2011-05-03  Eric Blake  <eblake@redhat.com>
86656         test-getaddrinfo: report error information
86657         * tests/test-getaddrinfo.c (simple): Use err outside of dbprintf.
86659 2011-05-03  Jim Meyering  <meyering@redhat.com>
86661         bootstrap: avoid build failure when $GZIP is set
86662         * build-aux/bootstrap (check_versions): Do not treat $GZIP as a
86663         program name.  If defined at all, it is supposed to list gzip options.
86664         Reported by Alan Curry in http://debbugs.gnu.org/8609
86666 2011-05-03  Reuben Thomas  <rrt@sc3d.org>
86668         readme-release: new module with release instructions
86669         * modules/readme-release: New module.
86670         * top/README-release: New file, from coreutils, grep, diffutils.
86671         * MODULES.html.sh (Support for maintaining and releasing): Add it.
86673 2011-05-02  Eric Blake  <eblake@redhat.com>
86675         fflush: also replace fclose when fixing fflush
86676         * modules/fflush (Depends-on): Add fclose.
86677         * m4/fflush.m4 (gl_FUNC_FFLUSH): Also replace fclose.
86678         * lib/fclose.c (rpl_fclose): Don't cause spurious failures on
86679         memstreams with no backing fd.
86680         * doc/posix-functions/fclose.texi (fclose): Document the use of
86681         fflush module to fix the bug.
86682         * tests/test-fclose.c (main): Relax test when fclose is used in
86683         isolation.
86685         fclose: add some tests
86686         * modules/fclose-tests: New test module.
86687         * tests/test-fclose.c: New file.
86688         * doc/posix-functions/fclose.texi (fclose): Document the bug.
86690         fclose: reduced dependencies
86691         * modules/fclose (Depends-on): Switch from fflush/fseeko to
86692         simpler lseek.
86693         * lib/fclose.c (rpl_fclose): Likewise.
86694         Reported by Simon Josefsson.
86696         exit: drop remaining clients
86697         * modules/argmatch (Depends-on): Replace exit with stdlib.
86698         * modules/copy-file (Depends-on): Likewise.
86699         * modules/execute (Depends-on): Likewise.
86700         * modules/exitfail (Depends-on): Likewise.
86701         * modules/obstack (Depends-on): Likewise.
86702         * modules/pagealign_alloc (Depends-on): Likewise.
86703         * modules/pipe-filter-gi (Depends-on): Likewise.
86704         * modules/pipe-filter-ii (Depends-on): Likewise.
86705         * modules/savewd (Depends-on): Likewise.
86706         * modules/spawn-pipe (Depends-on): Likewise.
86707         * modules/wait-process (Depends-on): Likewise.
86708         * modules/xsetenv (Depends-on): Likewise.
86709         * modules/chdir-long (Depends-on): Add stdlib, for EXIT_FAILURE.
86710         * modules/git-merge-changelog (Depends-on): Likewise.
86711         * modules/long-options (Depends-on): Likewise.
86712         * modules/pt_chown (Depends-on): Likewise.
86713         * modules/sysexits (Depends-on): Likewise.
86715         freading: relax license from LGPLv3+ to LGPLv2+
86716         * modules/freading (License): Relax LGPL version.
86718 2011-05-02  Bruno Haible  <bruno@clisp.org>
86720         fchdir: Remove unused dependencies.
86721         * modules/fchdir (Depends-on): Remove include_next.
86723 2011-05-02  Bruno Haible  <bruno@clisp.org>
86725         gnulib-tool: Refactor.
86726         * gnulib-tool (func_emit_autoconf_snippet): New function, extracted
86727         from func_emit_autoconf_snippets.
86728         (func_emit_autoconf_snippets): Use it.
86730 2011-05-02  Simon Josefsson  <simon@josefsson.org>
86732         * NEWS: Document removal of 'exit'.
86733         * modules/exit: Remove file.
86735 2011-05-01  Bruno Haible  <bruno@clisp.org>
86737         Update DEPENDENCIES.
86738         * DEPENDENCIES (gettext): Recommend the newest release.
86739         Reported by Simon Josefsson.
86741 2011-05-01  Bruno Haible  <bruno@clisp.org>
86743         gnulib-tool: Reduce code duplication.
86744         * gnulib-tool (func_emit_autoconf_snippets): New function.
86745         (func_import, func_create_testdir): Use it.
86747 2011-04-30  Eric Blake  <eblake@redhat.com>
86749         fclose: don't fail on non-seekable input stream
86750         * modules/fclose (Depends-on): Add freading, fflush, fseeko.
86751         * lib/fclose.c (rpl_fclose): Skip fflush for non-seekable input,
86752         since fflush is allowed to fail in that case.
86754 2011-04-30  Bruno Haible  <bruno@clisp.org>
86756         dup3: cleanup
86757         * lib/dup3.c: Remove old code, leftover from 2009-12-16.
86759 2011-04-30  Bruno Haible  <bruno@clisp.org>
86761         netdb: Make it work in C++ mode.
86762         * lib/netdb.in.h (struct addrinfo): In C++, define as a C struct.
86763         (getaddrinfo, freeaddrinfo, getnameinfo): Use macros from c++defs
86764         module.
86765         * m4/netdb_h.m4 (gl_NETDB_MODULE_INDICATOR): Invoke
86766         gl_MODULE_INDICATOR_FOR_TESTS.
86767         * modules/netdb-tests (Depends-on): Add netdb-c++-tests.
86768         * modules/netdb-c++-tests: New file.
86769         * tests/test-netdb-c++.cc: New file.
86771 2011-04-30  Bruno Haible  <bruno@clisp.org>
86773         New modules 'vfscanf', 'vscanf'.
86774         * modules/vfscanf: New file.
86775         * modules/vscanf: New file.
86776         * m4/stdio_h.m4 (gl_STDIO_H): Don't set GNULIB_VFSCANF, GNULIB_VSCANF
86777         here.
86778         * doc/posix-functions/vfscanf.texi: Mention module 'vfscanf'.
86779         * doc/posix-functions/vscanf.texi: Mention module 'vscanf'.
86781 2011-04-30  Bruno Haible  <bruno@clisp.org>
86783         passfd: Add comments.
86784         * lib/passfd.c: Add comments about platforms.
86786 2011-04-30  Bruno Haible  <bruno@clisp.org>
86788         sys_uio: Make <sys/uio.h> self-contained.
86789         * lib/sys_uio.in.h: Include <sys/types.h> before <sys/uio.h>.
86790         * doc/posix-headers/sys_uio.texi: Mention the OpenBSD problem.
86792 2011-04-30  Bruno Haible  <bruno@clisp.org>
86794         sys_socket: Ensure 'struct iovec' definition.
86795         * lib/sys_socket.in.h: Include <sys/uio.h> also on platforms that have
86796         <sys/socket.h>.
86797         * doc/posix-headers/sys_socket.texi: Mention the OpenBSD problem.
86799 2011-04-30  Bruno Haible  <bruno@clisp.org>
86801         sys_uio: Protect definition of 'struct iovec'.
86802         * lib/sys_uio.in.h (struct iovec): Avoid redefinition. In C++, define
86803         it as a C struct.
86805 2011-04-30  Bruno Haible  <bruno@clisp.org>
86807         manywarnings: fix indentation
86808         * m4/manywarnings.m4: Indent by 2 spaces consistently.
86810 2011-04-30  Pádraig Brady  <P@draigBrady.com>
86812         manywarnings: add -Wno-missing-field-initializers if needed.
86813         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add the above
86814         option if it's needed to allow initialization with { 0, }
86816 2011-04-29  Reuben Thomas  <rrt@sc3d.org>
86818         announce-gen: cosmetic improvement
86819         * build-aux/announce-gen: Strip any leading ./ from the NEWS file name.
86821 2011-04-29  Jim Meyering  <meyering@redhat.com>
86823         vc-list-files: indent with spaces, not TABs
86824         * build-aux/vc-list-files: Convert leading TABs to spaces,
86825         to match the style of most other files in gnulib.
86827         announce-gen: indent with spaces, not TABs
86828         * build-aux/announce-gen: Convert all TABs to spaces, to match
86829         the style of most other files in gnulib.
86831 2011-04-29  Eric Blake  <eblake@redhat.com>
86833         quotearg: avoid uninitialized variable use
86834         * lib/quotearg.c (quoting_options_from_style): Initialize
86835         remaining fields, and ensure that custom styles are only used via
86836         quoting_options rather than quoting_style.
86838 2011-04-29  Jim Meyering  <meyering@redhat.com>
86840         maint.mk: remove unused VC-tag variable
86841         * top/maint.mk (VC-tag): Remove unused variable.
86843 2011-04-29  Bruno Haible  <bruno@clisp.org>
86845         netdb: fix gai_strerror replacements
86846         * lib/netdb.in.h: Add _GL_FUNCDECL_RPL definitions.
86847         * modules/netdb: Substitute it.
86849 2011-04-29  Jim Meyering  <meyering@redhat.com>
86851         test-getcwd.c: avoid new set-but-not-used warning
86852         * tests/test-getcwd.c (test_abort_bug): Exit nonzero for any problem,
86853         not just the glibc/abort one that getcwd-abort-bug.m4 detects.
86854         * m4/getcwd-abort-bug.m4: Update this now-duplicated code to match,
86855         and adjust the code that sets gl_cv_func_getcwd_abort_bug accordingly.
86857         test-hash.c: avoid a new shadowing warning
86858         * tests/test-hash.c (main): Don't shadow "dup".
86860 2011-04-28  Eric Blake  <eblake@redhat.com>
86862         getaddrinfo: fix gai_strerror signature
86863         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Detect broken signatures,
86864         and work around mingw with UNICODE defined.
86865         (gl_PREREQ_GETADDRINFO): Drop redundant decl check.
86866         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Add witness.
86867         * modules/netdb (Makefile.am): Substitute it.
86868         * lib/netdb.in.h (gai_strerror): Declare replacement.
86869         * lib/gai_strerror.c (rpl_gai_strerror): Fix signature.
86870         * doc/posix-functions/gai_strerror.texi (gai_strerror): Document
86871         the fix.
86873         getsockopt: avoid compiler warning
86874         * lib/getsockopt.c (rpl_getsockopt): Add a cast for mingw.
86875         Reported by Matthias Bolte.
86877         tests: drop unused link dependency
86878         * modules/areadlinkat-tests (Makefile.am): Drop stale LDADD.
86879         * modules/dirent-safer-tests (Makefile.am): Likewise.
86880         * modules/fdopendir-tests (Makefile.am): Likewise.
86881         * modules/mkfifoat-tests (Makefile.am): Likewise.
86882         * modules/openat-safer-tests (Makefile.am): Likewise.
86883         * modules/openat-tests (Makefile.am): Likewise.
86884         * modules/readlinkat-tests (Makefile.am): Likewise.
86885         * modules/symlinkat-tests (Makefile.am): Likewise.
86886         * modules/linkat-tests (Makefile.am): Likewise.
86887         (Depends-on): Switch to filenamecat-lgpl.
86888         * modules/fdutimensat-tests (test_fdutimensat_LDADD): Drop unused
86889         LIBINTL.
86890         * modules/utimensat-tests (test_utimensat_LDADD): Likewise.
86891         * tests/test-linkat.c (main): Don't require xalloc.
86893         hash, mgetgroups: drop xalloc dependency
86894         * lib/hash.c (includes): Adjust includes.
86895         * lib/mgetgroups.c (includes): Likewise.
86896         (xgetgroups): Move...
86897         * lib/xgetgroups.c: ...to new file.
86898         * lib/mgetgroups.h (xgetgroups): Make declaration conditional.
86899         * modules/xgetgroups: New file, split from...
86900         * modules/mgetgroups: ...here.
86901         (Depends-on): Add xalloc-oversized.
86902         * modules/hash (Depends-on): Likewise.
86903         * modules/hash-tests (Depends-on): Drop xalloc.
86904         (test_hash_LDADD): Drop unused library.
86905         * tests/test-hash.c (main): Break xalloc dependency.
86906         (includes): Drop unused include.
86908         xalloc-oversized: new module
86909         * modules/xalloc-oversized: New module.
86910         * modules/xalloc (Depends-on): Add it.
86911         * lib/xalloc.h (xalloc_oversized): Move...
86912         * lib/xalloc-oversized.h: ...into new file.
86914         utimecmp: drop dependency on xmalloc
86915         * lib/utimecmp.c (utimecmp): Work even if hash table cache fails
86916         due to memory pressure.
86917         * modules/utimecmp (Depends-on): Drop xalloc.
86919 2011-04-27  Eric Blake  <eblake@redhat.com>
86921         getcwd: fix mingw bugs
86922         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Detect one mingw bug.
86923         * doc/posix-functions/getcwd.texi (getcwd): Document the problems.
86924         * lib/getcwd-lgpl.c (rpl_getcwd): Fix return type.
86926 2011-04-27  Bruno Haible  <bruno@clisp.org>
86928         mkstemps: Ensure declaration on MacOS X 10.5.
86929         * lib/stdlib.in.h: Include <unistd.h> when mkstemps is requested.
86930         * doc/glibc-functions/mkstemps.texi: Document header file problem on
86931         MacOS X.
86933 2011-04-27  Bruno Haible  <bruno@clisp.org>
86935         mkstemp: More documentation.
86936         * doc/posix-functions/mkstemp.texi: Document header file problem on
86937         MacOS X.
86939 2011-04-27  Bruno Haible  <bruno@clisp.org>
86941         mkstemp: Tweak configure message when cross-compiling.
86942         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): When cross-compiling, qualify the
86943         result as a guess.
86945 2011-04-27  Bruno Haible  <bruno@clisp.org>
86947         clean-temp: Clarify what it does.
86948         * lib/clean-temp.h: Add more comments.
86949         * doc/posix-functions/mkstemp.texi: Tweak reference to 'clean-temp'
86950         module.
86951         * doc/glibc-functions/mkostemp.texi: Mention 'clean-temp' here too.
86952         * doc/glibc-functions/mkstemps.texi: Likewise.
86953         * doc/glibc-functions/mkostemps.texi: Likewise.
86955 2011-04-27  Eric Blake  <eblake@redhat.com>
86957         fchdir: avoid extra chdir and fix test
86958         * modules/fchdir (Depends-on): Add dosname, filenamecat-lgpl,
86959         getcwd-lgpl.
86960         * lib/fchdir.c (get_name): Any absolute name will do; it does not
86961         have to be canonical.
86962         (canonicalize_file_name): Drop unused macro.
86963         * m4/dup2.m4 (gl_REPLACE_DUP2): Ensure dup2 is replaced.
86965         filenamecat-lgpl: fix licence
86966         * modules/filenamecat-lgpl (License): Mark as LGPLv2+, as intended
86967         when it was first created.
86969         linkat, renameat: add missing dependency
86970         * modules/linkat (Depends-on): Require getcwd-lgpl.
86971         * modules/renameat (Depends-on): Likewise.
86973         tests: reduce dependencies
86974         * tests/test-linkat.c (main): Use lighter-weight getcwd.
86975         * tests/test-renameat.c (main): Likewise.
86976         * modules/linkat-tests (Depends-on): Relax dependency.
86977         * modules/renameat-tests (Depends-on): Likewise.
86978         * modules/fchdir-tests (Depends-on): Likewise.  Also make cloexec
86979         dependency explicit.
86981         save-cwd: reduce default dependency
86982         * modules/save-cwd (Depends-on): Use getcwd-lgpl.
86983         * lib/save-cwd.c: Update comments.
86984         * NEWS: Document the semantic change.
86986         getcwd: enhance tests
86987         * tests/test-getcwd-lgpl.c: New file, taken from...
86988         * tests/test-getcwd.c: ...old contents.  Rewrite this file to
86989         repeat long path stress tests from m4 probe.
86990         * modules/getcwd-lgpl-tests: New module.
86991         * modules/getcwd-tests (Depends-on): Depend on lgpl tests.
86992         * m4/getcwd-abort-bug.m4: Update comment.
86993         * m4/getcwd-path-max.m4: Likewise.
86995         getcwd-lgpl: new module
86996         * modules/getcwd-lgpl: New module.
86997         * lib/getcwd-lgpl.c: New file.
86998         * doc/posix-functions/getcwd.texi (getcwd): Document it.
86999         * MODULES.html.sh (lacking POSIX:2008): Likewise.
87000         * modules/getcwd (configure.ac): Set C witness.
87001         * m4/getcwd.m4 (gl_FUNC_GETCWD_LGPL): New macro.
87003         getcwd: tweak comments
87004         * m4/getcwd-abort-bug.m4: Fix comments.
87005         * m4/getcwd-path-max.m4: Likewise.
87006         * m4/getcwd.m4: Likewise.
87008 2011-04-27  Reuben Thomas  <rrt@sc3d.org>
87009         and Eric Blake  <eblake@redhat.com>
87011         mkstemp: replace if system version uses wrong permissions
87012         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Add test for non-owner
87013         read/write mode bits set in file created by mkstemp.
87014         * doc/posix-functions/mkstemp.texi (mkstemp): Document the fix.
87016 2011-04-27  Eric Blake  <eblake@redhat.com>
87018         passfd: avoid compiler warning
87019         * lib/passfd.c (sendfd, recvfd): Avoid shadowing names.
87020         Reported by Laine Stump.
87022 2011-04-27  J.T. Conklin  <jtc@acorntoolworks.com>  (tiny change)
87024         * gnulib-tool: change "join -a 2" to "join -a2", the latter is
87025         required by the NetBSD (and perhaps other 4.4BSD derived) join.
87027 2011-04-27  Reuben Thomas  <rrt@sc3d.org>
87028         and Eric Blake  <eblake@redhat.com>
87030         mkstemp: mention clean-temp module
87031         * lib/mkstemp.c: Add comment.
87032         * doc/posix-functions/mkstemp.texi (mkstemp): Likewise.
87034 2011-04-26  Paul Eggert  <eggert@cs.ucla.edu>
87036         inttypes: also provide default values for 32-bit tests
87037         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Also provide default values
87038         for INT32_MAX_LT_INTMAX_MAX and for UINT32_MAX_LT_UINTMAX_MAX.
87040 2011-04-25  Paul Eggert  <eggert@cs.ucla.edu>
87042         strtoumax: remove dependency on strtoimax
87043         This is like the strtoull change of yesterday.
87044         * modules/strtoumax (Files): Add lib/strtoimax.c.
87045         (Depends-on): Remove strtoimax and add verify.
87047         inttypes-incomplete: new module
87048         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): New macro, containing
87049         all but the PRI* and SCN* parts of gl_INTTYPES_H.
87050         (gl_INTTYPES_PRI_SCN): New macro, containing the PRI* and SCN* parts
87051         of gl_INTTYPES_H.
87052         (gl_INTTYPES_H): Rewrite in terms of these new macros.
87053         (gl_INTTYPES_H_DEFAULTS): Provide defaults for the PRI* and SCN*
87054         parts, in case gl_INTTYPE_PRI_SCN is not invoked.
87055         * modules/imaxabs, modules/imaxdiv, modules/strtoimax (Depends-on):
87056         * modules/strtoumax, modules/xstrtol (Depends-on):
87057         Depend on inttypes-incomplete, not inttypes.
87058         * modules/inttypes-incomplete: New module, containing the contents
87059         of the old modules/inttypes module, except that the Files: section
87060         omits m4/inttypes-pri.m4, and the configure.ac section invokes
87061         gl_INTTYPES_INCOMPLETE rather than gl_INTTYPES_H.
87062         * modules/inttypes (Files): Remove lib/inttypes.in.h, m4/inttypes.m4.
87063         (Depends-on): Depend only on inttypes-incomplete.
87064         (Makefile.am): Remove everything; this is now in inttypes-incomplete.
87066         inttypes: omit now-redundant strtoimax and strtoumax work
87067         * m4/inttypes.m4 (gl_INTTYPES_H): Do not check for strtoimax and
87068         strtoumax decls; gl_FUNC_STRTOIMAX and gl_FUNC_STRTOUMAX now do this.
87070         strtoimax, strtoumax: simplify, port to HP-UX 11.00 64-bit
87071         This supports apps that need pointers to strtoimax and strtoumax,
87072         and ports to HP-UX 11.00 64.bit, which has macros that expand to
87073         nonexistent functions.  See
87074         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00241.html>
87075         et seq.
87076         * lib/inttypes.in.h (strtoimax, strtoumax): #undef before declaring.
87077         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Don't check whether it's
87078         a macro.
87079         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
87081 2011-04-25  Simon Josefsson  <simon@josefsson.org>
87083         * modules/gnumakefile (configure.ac): Replace TAB with SPCs.
87085 2011-04-25  Bruno Haible  <bruno@clisp.org>
87087         strtol, strtoul: Mark modules as obsolete.
87088         * modules/strtol (Status, Notice): New sections.
87089         * modules/strtoul (Status, Notice): New sections.
87091 2011-04-25  Bruno Haible  <bruno@clisp.org>
87093         strtod: Remove check for strtod, unless supporting old platforms.
87094         * modules/strtod-obsolete: New file.
87095         * m4/strtod-obsolete.m4: New file.
87096         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't check whether strtod is declared
87097         if gl_FUNC_STRTOD_OBSOLETE is not also defined.
87098         * modules/strtod (Depends-on): Add strtod-obsolete.
87099         * doc/posix-functions/strtod.texi: Mention module strtod-obsolete.
87101 2011-04-25  Bruno Haible  <bruno@clisp.org>
87103         strcase: Make module obsolete.
87104         * modules/strcase (Status, Notice): New sections.
87106 2011-04-25  Bruno Haible  <bruno@clisp.org>
87108         dup2: Remove check for dup2, unless supporting old obsolete platforms.
87109         * modules/dup2-obsolete: New file.
87110         * m4/dup2-obsolete.m4: New file.
87111         * m4/dup2.m4 (gl_FUNC_DUP2): Don't check whether dup2 exists if
87112         gl_FUNC_DUP2_OBSOLETE is not also defined.
87113         * modules/dup2 (Depends-on): Add dup2-obsolete.
87114         * doc/posix-functions/dup2.texi: Mention module dup2-obsolete.
87116 2011-04-25  Bruno Haible  <bruno@clisp.org>
87118         strnlen: Avoid memchr related link error on old obsolete platforms.
87119         * modules/memchr-obsolete: New file.
87120         * m4/memchr-obsolete.m4: New file.
87121         * m4/memchr.m4 (gl_FUNC_MEMCHR): Don't check whether memchr exists if
87122         gl_FUNC_MEMCHR_OBSOLETE is not also defined.
87123         * modules/memchr (Depends-on): Add memchr-obsolete.
87124         * modules/strnlen (Depends-on): Likewise.
87125         * doc/posix-functions/memchr.texi: Mention module memchr-obsolete.
87127 2011-04-25  Jim Meyering  <meyering@redhat.com>
87129         maint.mk: makefile_at_at_check extend and clean up
87130         * top/maint.mk (sc_makefile_at_at_check): Check *.mk files
87131         in addition to */Makefile.am.
87132         Exempt legitimate uses of @VAR@ notation, e.g.,
87133         MAKEINFO = env LANG= LC_MESSAGES= LC_ALL= LANGUAGE= @MAKEINFO@
87134         Remove obsolete coreutils-specific comment.
87135         Prompted by discussion here:
87136         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/26074
87138 2011-04-24  Paul Eggert  <eggert@cs.ucla.edu>
87140         strtoul: remove dependency on strtol
87141         This is so that 'configure' need not check for strtol merely because
87142         the application needs strtoul.
87143         * modules/strtoul (Files): Add lib/strtol.c.
87144         (Depends-on): Remove strtol.
87146         strtoull: remove dependency on strtoul
87147         This is like the strtoll change.
87148         * modules/strtoull (Files): Add lib/strtol.c, lib/strtoul.c.
87149         (Depends-on): Remove strtoul.
87151         strtoll: remove dependency on strtol
87152         This is so that 'configure' need not check for strtol merely because
87153         the application needs strtoll.
87154         * modules/strtoll (Files): Add lib/strtol.c.
87155         (Depends-on): Remove strtol.
87157 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
87159         inttypes: Move some configure check to module 'imaxdiv'.
87160         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Require gl_INTTYPES_H_DEFAULTS
87161         instead of gl_INTTYPES_H.  Check for imaxdiv decl here.
87162         * m4/inttypes.m4 (gl_INTTYPES_H): Don't check for imaxdiv decl here.
87164 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
87166         inttypes: Move some configure check to module 'imaxabs'.
87167         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Require gl_INTTYPES_H_DEFAULTS
87168         instead of gl_INTTYPES_H.  Check for imaxabs decl here.
87169         * m4/inttypes.m4 (gl_INTTYPES_H): Don't check for imaxabs decl here.
87171 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
87173         inttypes: Remove configure tests that are not needed since 2009-12-31.
87174         * m4/inttypes.m4 (gl_INTTYPES_H): Remove determination of
87175         gl_cv_header_working_inttypes_h.
87177 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
87179         * modules/strnlen (Depends-on): Remove memchr.
87180         The strnlen implementation doesn't need the memchr module's fixes; see
87181         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00237.html>.
87183         strtol: remove dependency on wchar
87184         * lib/strtol.c: Include <wchar.h> only if USE_WIDE_CHAR is defined.
87185         * modules/strtol (Depends-on): Remove wchar.
87187 2011-04-21  Eric Blake  <eblake@redhat.com>
87189         passfd: fix test regression on Linux
87190         * modules/passfd-tests (configure.ac): Correct socketpair check.
87192         passfd: speed up configure and drop unused code
87193         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Rename...
87194         * m4/passfd.m4 (gl_PASSFD): ...to something more fitting of
87195         its use.  Drop test for setting unused HAVE_UNIXSOCKET_SCM_RIGHTS.
87196         Instead of probing at configure for unix_scm_rights_bsd44_way,
87197         instead probe for CMSG_FIRSTHDR at compile time.  Simplify BSD 4.3
87198         check to a struct member probe.
87199         * lib/passfd.c (includes): Nothing here requires <sys/un.h>.
87200         (sendfd, recvfd): Update preprocessor checks.
87201         * modules/passfd (Files): Reflect rename, and drop unused file.
87202         (Depends-on): Drop unused dependency.
87204         passfd: allow compilation on mingw
87205         * modules/sys_socket (Depends-on): Add sys_uio.
87206         * lib/sys_socket.in.h [!@HAVE_SYS_SOCKET_H@]: Use it for struct
87207         iovec and a minimal struct msghdr.
87208         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Detect recvmsg/sendmsg.
87209         * tests/test-sys_socket.c (main): Enhance test.
87210         * lib/passfd.c (include): Drop <sys/uio.h>; <sys/sockets.h> is
87211         guaranteed to provide what we need.
87212         (sendmsg, recvmsg): Declare fallbacks if we lack sendmsg.
87213         * modules/passfd-tests (Depends-on): Add sys_wait.
87214         * tests/test-passfd.c (main): Skip test on mingw, for now.
87215         * doc/posix-headers/sys_socket.texi (sys/socket.h): Document the
87216         partial 'struct msghdr' implementation.
87218         sys_uio: new module
87219         * modules/sys_uio: New module.
87220         * modules/sys_uio-tests: Likewise.
87221         * lib/sys_uio.in.h: New file.
87222         * m4/sys_uio_h.m4: Likewise.
87223         * tests/test-sys_uio.c: Likewise.
87224         * doc/posix-headers/sys_uio.texi (sys/uio.h): Document it.
87225         * MODULES.html.sh (systems lacking POSIX:2008): Likewise.
87227 2011-04-20  Jim Meyering  <meyering@redhat.com>
87229         useless-if-before-free: avoid false-positive
87230         * build-aux/useless-if-before-free: Adjust regexp for the non-brace
87231         disjunct so that it too requires a terminating ";".  Without that,
87232         this script would identify as useless one statement from gcc that
87233         was not:
87234           if (aligned_ptr)
87235             free (((void **) aligned_ptr) [-1]);
87237 2011-04-20  Giuseppe Scrivano  <gscrivano@gnu.org>
87239         doc: update users.txt.
87240         * users.txt: Add barcode.
87242 2011-04-19  Bruno Haible  <bruno@clisp.org>
87244         ioctl: Remove link dependency on native Windows.
87245         * lib/fd-hook.h: Renamed from lib/close-hook.h.
87246         (gl_close_fn, gl_ioctl_fn): New types.
87247         (struct fd_hook): Renamed from struct close_hook. Change type of
87248         private_close_fn field. Add private_ioctl_fn field.
87249         (close_hook_fn): Add parameter for primary close method.
87250         (execute_close_hooks, execute_all_close_hooks): Likewise.
87251         (ioctl_hook_fn): New type.
87252         (execute_ioctl_hooks, execute_all_ioctl_hooks): New declarations.
87253         (register_fd_hook): Renamed from register_close_hook. Add ioctl_hook
87254         argument.
87255         (unregister_fd_hook): Renamed from unregister_close_hook.
87256         * lib/fd-hook.c: Renamed from lib/close-hook.c.
87257         Don't include <unistd.h>.
87258         (close): Remove undef.
87259         (anchor): Update.
87260         (execute_close_hooks): Add argument for primary close method.
87261         (execute_all_close_hooks): Likewise.
87262         (execute_ioctl_hooks, execute_all_ioctl_hooks): New functions.
87263         (register_fd_hook): Renamed from register_close_hook. Add ioctl_hook
87264         argument. Allow each argument to be NULL.
87265         (unregister_fd_hook): Renamed from unregister_close_hook.
87266         * lib/close.c (rpl_close): Pass 'close' function pointer to
87267         execute_all_close_hooks.
87268         * lib/ioctl.c: Include <errno.h>, fd-hook.h.
87269         (primary_ioctl): New function.
87270         (ioctl): Don't call ioctlsocket here. Instead, call
87271         execute_all_ioctl_hooks.
87272         * lib/sockets.c (close_fd_maybe_socket): Add argument for primary
87273         close method.
87274         (ioctl_fd_maybe_socket): New function, with code from lib/ioctl.c.
87275         (fd_sockets_hook): Renamed from close_sockets_hook.
87276         (gl_sockets_startup, gl_sockets_cleanup): Update.
87277         * modules/fd-hook: Renamed from modules/close-hook. Update.
87278         * modules/close (Depends-on): Add fd-hook, remove close-hook.
87279         * modules/sockets (Depends-on): Likewise.
87280         * modules/ioctl (Depends-on): Add fd-hook.
87281         * tests/test-nonblocking.c (main): Use GNULIB_TEST_SOCKET, not
87282         GNULIB_SOCKET.
87284 2011-04-19  Bruno Haible  <bruno@clisp.org>
87286         Move the support of O_NONBLOCK in open() to the 'open' module.
87287         * modules/nonblocking (Depends-on): Remove 'open'.
87288         * m4/nonblocking.m4 (gl_NONBLOCKING_IO_BODY): Set
87289         gl_cv_have_open_O_NONBLOCK.
87290         * m4/open.m4 (gl_FUNC_OPEN): Replace open() also when required for
87291         O_NONBLOCK support.
87292         * doc/posix-functions/open.texi: Document support for O_NONBLOCK.
87294 2011-04-17  Bruno Haible  <bruno@clisp.org>
87296         pipe2: Simplify code.
87297         * lib/pipe2.c (pipe2): Reduce code duplication.
87299 2011-04-17  Bruno Haible  <bruno@clisp.org>
87301         nonblocking: Add comment.
87302         * lib/fcntl.in.h (O_NONBLOCK): Add comment.
87304 2011-04-17  Bruno Haible  <bruno@clisp.org>
87306         nonblocking: Add tests for sockets.
87307         * tests/test-nonblocking-socket.sh: New file.
87308         * tests/test-nonblocking-socket-main.c: New file.
87309         * tests/test-nonblocking-socket-child.c: New file.
87310         * tests/test-nonblocking-socket.h: New file.
87311         * tests/socket-server.h: New file.
87312         * tests/socket-client.h: New file.
87313         * modules/nonblocking-socket-tests: New file.
87314         * modules/nonblocking-tests (Depends-on): Add nonblocking-socket-tests.
87316 2011-04-17  Bruno Haible  <bruno@clisp.org>
87318         nonblocking: Add tests for pipes.
87319         * tests/test-nonblocking-pipe.sh: New file.
87320         * tests/test-nonblocking-pipe-main.c: New file.
87321         * tests/test-nonblocking-pipe-child.c: New file.
87322         * tests/test-nonblocking-pipe.h: New file.
87323         * tests/test-nonblocking-writer.h: New file.
87324         * tests/test-nonblocking-reader.h: New file.
87325         * tests/test-nonblocking-misc.h: New file.
87326         * modules/nonblocking-pipe-tests: New file.
87327         * modules/nonblocking-tests (Depends-on): Add nonblocking-pipe-tests.
87329 2011-04-16  Bruno Haible  <bruno@clisp.org>
87331         gettext: Clarify the needed programmer actions.
87332         * modules/gettext (Notice): New field.
87333         Suggested by Ben Pfaff <blp@cs.stanford.edu>.
87335 2011-04-16  Bruno Haible  <bruno@clisp.org>
87337         strchrnul: Tweak last commit.
87338         * doc/glibc-functions/strchrnul.texi: Add more details about Cygwin
87339         bug.
87340         * lib/string.in.h (strchrnul): Use same arguments in _GL_FUNCDECL_RPL
87341         as in _GL_FUNCDECL_SYS.
87342         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Invoke gl_PREREQ_STRCHRNUL after
87343         AC_LIBOBJ. When cross-compiling, say "guessing yes" not "yes".
87345 2011-04-15  Eric Blake  <eblake@redhat.com>
87347         strchrnul: work around cygwin bug
87348         * doc/glibc-functions/strchrnul.texi (strchrnul): Document bug.
87349         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Detect it.
87350         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New witness.
87351         * modules/string (Makefile.am): Substitute it.
87352         * lib/string.in.h (strchrnul): Use it.
87354 2011-04-15  Bruno Haible  <bruno@clisp.org>
87356         Don't require lib/stdio-write.c when only module 'stdio' is used.
87357         * m4/stdio_h.m4 (gl_STDIO_H): Move the AC_LIBOBJ back into the m4_ifdef
87358         invocation.
87359         Reported by Rob Vermaas <rob.vermaas@gmail.com>.
87361 2011-04-14  Bruno Haible  <bruno@clisp.org>
87363         Support non-blocking pipe I/O in read() on native Windows.
87364         * lib/unistd.in.h: Include <sys/types.h> also for 'read'.
87365         (read): New declaration.
87366         * lib/read.c: New file.
87367         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT_SCANF,
87368         _GL_ATTRIBUTE_FORMAT_SCANF_SYSTEM): New macros.
87369         (fgetc, fgets, fread, fscanf, getc, getchar, gets, scanf, vfscanf,
87370         vscanf): New declarations.
87371         * lib/stdio-read.c: New file.
87372         * m4/read.m4: New file.
87373         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_READ,
87374         REPLACE_READ.
87375         * m4/stdio_h.m4 (gl_STDIO_H): Set GNULIB_FGETC, GNULIB_FGETS,
87376         GNULIB_FREAD, GNULIB_FSCANF, GNULIB_GETC, GNULIB_GETCHAR, GNULIB_GETS,
87377         GNULIB_SCANF, GNULIB_VFSCANF, GNULIB_VSCANF. In non-blocking I/O is
87378         desired and needs workarounds, set REPLACE_STDIO_READ_FUNCS.
87379         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FGETC, GNULIB_FGETS,
87380         GNULIB_FREAD, GNULIB_FSCANF, GNULIB_GETC, GNULIB_GETCHAR, GNULIB_GETS,
87381         GNULIB_SCANF, GNULIB_VFSCANF, GNULIB_VSCANF, REPLACE_STDIO_READ_FUNCS.
87382         * modules/read: New file.
87383         * modules/nonblocking (Files): Add lib/stdio-read.c.
87384         * modules/unistd (Makefile.am): Substitute GNULIB_READ, REPLACE_READ.
87385         * modules/stdio (Makefile.am): Substitute GNULIB_FGETC, GNULIB_FGETS,
87386         GNULIB_FREAD, GNULIB_FSCANF, GNULIB_GETC, GNULIB_GETCHAR, GNULIB_GETS,
87387         GNULIB_SCANF, GNULIB_VFSCANF, GNULIB_VSCANF, REPLACE_STDIO_READ_FUNCS.
87388         * modules/pread (Depends-on): Add read.
87389         * modules/safe-read (Depends-on): Likewise.
87390         * tests/test-stdio-c++.cc (fgetc, fgets, fread, fscanf, getc, getchar,
87391         gets, scanf, vfscanf, vscanf): Verify signatures.
87392         * doc/posix-functions/read.texi: Mention 'nonblocking' module and
87393         problem with non-blocking pipes.
87394         * doc/posix-functions/fgetc.texi: Likewise.
87395         * doc/posix-functions/fgets.texi: Likewise.
87396         * doc/posix-functions/fread.texi: Likewise.
87397         * doc/posix-functions/fscanf.texi: Likewise.
87398         * doc/posix-functions/getc.texi: Likewise.
87399         * doc/posix-functions/getchar.texi: Likewise.
87400         * doc/posix-functions/gets.texi: Likewise.
87401         * doc/posix-functions/scanf.texi: Likewise.
87402         * doc/posix-functions/vfscanf.texi: Likewise.
87403         * doc/posix-functions/vscanf.texi: Likewise.
87405 2011-04-14  Bruno Haible  <bruno@clisp.org>
87407         Support non-blocking pipe I/O in write() on native Windows.
87408         * lib/write.c (rpl_write): Split a write request that failed merely
87409         because the byte count was larger than the pipe buffer's size.
87410         * doc/posix-functions/write.texi: Mention the problem with large byte
87411         counts.
87413 2011-04-14  Bruno Haible  <bruno@clisp.org>
87415         wchar: Ensure that wchar_t gets defined on uClibc.
87416         * lib/wchar.in.h: On uClibc, include <stddef.h>.
87417         Reported by Giuseppe Scrivano <gscrivano@gnu.org>.
87419 2011-04-13  Bruno Haible  <bruno@clisp.org>
87421         safe-write, full-read: Avoid unnecessary compilation units.
87422         * modules/safe-write (Files): Add lib/safe-read.c, m4/safe-read.m4.
87423         (Depends-on): Remove safe-read. Add ssize_t.
87424         * modules/full-read (Files): Add lib/full-write.c.
87425         (Depends-on): Add full-write.
87427 2011-04-13  Bruno Haible  <bruno@clisp.org>
87429         Support non-blocking pipe I/O and SIGPIPE in pwrite().
87430         * modules/pwrite (Depends-on): Add 'write'.
87432 2011-04-13  Bruno Haible  <bruno@clisp.org>
87434         Support non-blocking pipe I/O in write() on native Windows.
87435         * lib/unistd.in.h (write): Enable replacement also if
87436         GNULIB_UNISTD_H_NONBLOCKING is 1.
87437         * lib/write.c: Enable replacement also if GNULIB_NONBLOCKING.
87438         (rpl_write): When failing to write on a non-blocking pipe, change
87439         errno from ENOSPC to EAGAIN.
87440         * lib/stdio.in.h (fprintf, fputc, fputs, fwrite, printf, putc,
87441         putchar, puts, vfprintf, vprintf): Enable replacement also if
87442         GNULIB_STDIO_H_NONBLOCKING is 1.
87443         * lib/stdio-write.c: Enable replacements also if GNULIB_NONBLOCKING.
87444         (CLEAR_ERRNO, HANDLE_ENOSPC): New macros.
87445         (CLEAR_LastError, HANDLE_ERROR_NO_DATA): New macros, extracted from
87446         CALL_WITH_SIGPIPE_EMULATION.
87447         (CALL_WITH_SIGPIPE_EMULATION): Use them.
87448         * m4/nonblocking.m4: New file.
87449         * m4/write.m4 (gl_FUNC_WRITE): Enable REPLACE_WRITE also if required
87450         for non-blocking I/O support.
87451         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
87452         GNULIB_UNISTD_H_NONBLOCKING.
87453         * m4/stdio_h.m4 (gl_STDIO_H): Enable REPLACE_STDIO_WRITE_FUNCS also if
87454         required for non-blocking I/O support.
87455         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_STDIO_H_NONBLOCKING.
87456         * modules/nonblocking (Files): Add m4/nonblocking.m4,
87457         lib/stdio-write.c, m4/asm-underscore.m4.
87458         (Depends-on): Add stdio, unistd.
87459         (configure.ac): Invoke gl_NONBLOCKING_IO. Define GNULIB_NONBLOCKING.
87460         Set GNULIB_STDIO_H_NONBLOCKING, GNULIB_UNISTD_H_NONBLOCKING.
87461         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_NONBLOCKING.
87462         * modules/stdio (Makefile.am): Substitute GNULIB_STDIO_H_NONBLOCKING.
87463         * doc/posix-functions/fprintf.texi: Mention 'nonblocking' module and
87464         problem with non-blocking pipes.
87465         * doc/posix-functions/fputc.texi: Likewise.
87466         * doc/posix-functions/fputs.texi: Likewise.
87467         * doc/posix-functions/fwrite.texi: Likewise.
87468         * doc/posix-functions/printf.texi: Likewise.
87469         * doc/posix-functions/putc.texi: Likewise.
87470         * doc/posix-functions/putchar.texi: Likewise.
87471         * doc/posix-functions/puts.texi: Likewise.
87472         * doc/posix-functions/vfprintf.texi: Likewise.
87473         * doc/posix-functions/vprintf.texi: Likewise.
87474         * doc/posix-functions/write.texi: Likewise.
87476 2011-04-10  Jim Meyering  <meyering@redhat.com>
87478         maint.mk: prohibit doubled words
87479         Detect them also when they're separated by a newline.
87480         There are 3 ways to customize it:
87481           - disable the test on a per file basis, as usual with rules using
87482             $(VC_LIST_EXCEPT)
87483           - replace the default doubled-word-selecting regexp (affects all files)
87484           - ignore a particular file-vs-doubled-word match
87485         I nearly used that last one to ignore the "is is" match in
87486         coreutils' NEWS file, since the text was "ls -is is ..."
87487         To do that, I would have added this line to cfg.mk:
87488           ignore_doubled_word_match_RE_ = ^NEWS:[0-9]+:is[ ]is$
87489         but it would have ignored any "is is" match in NEWS.
87490         Low probability, but still...
87491         Instead, I changed the text, slightly:
87492           -  ls -is is now consistent with ls -lis in ignoring values returned
87493           +  "ls -is" is now consistent with ls -lis in ignoring values returned
87494         * top/maint.mk (prohibit_double_word_RE_): Provide default.
87495         (prohibit_doubled_word_): Define.
87496         (sc_prohibit_doubled_word): New rule.
87497         (sc_prohibit_the_the): Remove.  Subsumed by the above.
87499 2011-04-10  Jim Meyering  <meyering@redhat.com>
87501         maint: fix doubled-word typo in comment
87502         * m4/gethostname.m4: s/is is/it is/
87503         * m4/getdomainname.m4: Likewise.
87505 2011-04-10  Jim Meyering  <meyering@redhat.com>
87507         maint: remove doubled word: s/it it/it/
87508         * lib/stat-time.h (get_stat_birthtime): s/it it/it/
87510 2011-04-10  Jim Meyering  <meyering@redhat.com>
87512         maint.mk: remove useless semicolon and backslash
87513         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Remove stray
87514         semicolon and backslash.
87516 2011-04-10  Bruno Haible  <bruno@clisp.org>
87518         stdint test: Fix compilation failure on OSF/1 with DTK compiler.
87519         * modules/stdint-tests (Depends-on): Add wchar.
87521 2011-04-10  Jim Meyering  <meyering@redhat.com>
87523         maint: remove doubled words in comments, e.g., s/a a/a/
87524         * lib/strptime.c (day_of_the_week): s/the the/the/
87525         * tests/test-chown.h (test_chown): s/a a/a/
87527         test-chown.h: correct a cast
87528         * tests/test-chown.h (test_chown): Cast -1 to gid_t (not uid_t)
87529         when the destination is a stat.st_gid.
87531 2011-04-09  Mats Erik Andersson  <mats.andersson@gisladisker.se>  (tiny change)
87533         getaddrinfo: Fix test for sa_len member.
87534         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): When testing for sa_len,
87535         include <sys/types.h> before <sys/socket.h>.
87537 2011-04-09  Paul Eggert  <eggert@cs.ucla.edu>
87539         maint: change "can not" to "cannot"
87540         * doc/posix-functions/iconv.texi (iconv): This one crossed line
87541         boundaries.
87543 2011-04-09  Jim Meyering  <meyering@redhat.com>
87545         maint: change "a a" to "a"
87546         * tests/test-lchown.h (test_lchown): s/a a/a/
87548         maint.mk: prohibit \<the the\>
87549         * top/maint.mk (sc_prohibit_the_the): New rule.
87551         maint: fix "the the" in comment
87552         * lib/count-one-bits.h: s/the the/the/
87554         maint: change "can not" to "cannot"
87555         But do not change the occurrences in maintain.texi or in
87556         build-aux/po/Makefile.in.in, which I presume comes from gettext.
87557         * doc/gnulib-tool.texi: s/can not/cannot/
87558         * doc/posix-functions/accept.texi (accept): Likewise.
87559         * doc/posix-functions/socket.texi (socket): Likewise.
87560         * lib/mbrtowc.c: Likewise.
87562         maint.mk: prohibit use of "can not"
87563         * top/maint.mk (sc_prohibit_can_not): New rule.
87564         Writing "can not" (rather than "cannot") is too common.  Prohibit it.
87566 2011-04-09  Bruno Haible  <bruno@clisp.org>
87568         careadlinkat: Guard against misuse of careadlinkatcwd.
87569         * lib/careadlinkat.c: Include <stdlib.h>.
87570         (careadlinkatcwd): Check that the fd argument is as expected.
87572 2011-04-09  Bruno Haible  <bruno@clisp.org>
87574         careadlinkat: Use common coding style.
87575         * lib/careadlinkat.c: Move gnulib includes after system includes.
87577 2011-04-09  Bruno Haible  <bruno@clisp.org>
87579         careadlinkat: Clarify specification.
87580         * lib/careadlinkat.h (careadlinkat): Clarify preadlinkat argument.
87581         (careadlinkatcwd): Add comment.
87582         * lib/careadlinkat.c (careadlinkat): Clarify preadlinkat argument.
87584 2011-04-09  Bruno Haible  <bruno@clisp.org>
87586         areadlinkat: Avoid link error on many platforms.
87587         * modules/areadlinkat (Depends-on): Add areadlink.
87589 2011-04-09  Bruno Haible  <bruno@clisp.org>
87591         allocator, careadlinkat: Fix double-inclusion guard.
87592         * lib/allocator.h: Fix double-inclusion guard.
87593         * lib/careadlinkat.h: Likewise.
87595 2011-04-09  Bruno Haible  <bruno@clisp.org>
87597         relocatable-prog-wrapper: Update after module 'areadlink' changed.
87598         * lib/relocwrapper.c: Update dependencies hierarchy.
87599         * build-aux/install-reloc: Update list of files to be compiled.
87600         * modules/relocatable-prog-wrapper (Files): Add lib/careadlinkat.[hc],
87601         lib/allocator.[hc].
87603 2011-04-08  Eric Blake  <eblake@redhat.com>
87605         strftime: silence gnulib-tool warning
87606         * modules/strftime-tests (Depends-on): Drop automatic dependency.
87608 2011-04-08  Bruno Haible  <bruno@clisp.org>
87610         verify: Fix syntax error with GCC 4.6 in C++ mode.
87611         * lib/verify.h (HAVE__STATIC_ASSERT): Don't define in C++ mode.
87612         (HAVE_STATIC_ASSERT): New macro.
87613         (verify_true, verify): Use 'static_assert' if it is supported and
87614         '_Static_assert' is not supported.
87616 2011-04-08  Paul Eggert  <eggert@cs.ucla.edu>
87618         allocator: New module.
87619         * modules/allocator, lib/allocator.c: New files.
87620         * lib/allocator.h (stdlib_allocator): New decl.
87621         * lib/careadlinkat.c (_GL_USE_STDLIB_ALLOC, standard_allocator):
87622         Remove.  Do not include <stdlib.h>.
87623         (careadlinkat): Use stdlib_allocator instead of rolling our own.
87624         * modules/careadlinkat (Files): Remove lib/allocator.h.
87625         (Depends-on): Add allocator.
87627         stdlib: let modules use system malloc, realloc
87628         * lib/stdlib.in.h (malloc, realloc): Don't #define or add warnings
87629         if !_GL_USE_STDLIB_ALLOC.
87630         (malloc, realloc): Limit this change to a smaller scope.
87632         * lib/careadlinkat.c (_GL_USE_STDLIB_ALLOC): Define.
87633         (malloc, realloc): Don't #undef; no longer needed.
87634         * lib/malloca.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
87635         * lib/progreloc.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
87636         * lib/setenv.c (_GL_USE_STDLIB_ALLOC, malloc, realloc): Likewise.
87637         * lib/canonicalize-lgpl.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
87638         * lib/relocatable.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
87639         * lib/relocwrapper.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
87640         * lib/malloc.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
87641         * lib/realloc.c (_GL_USE_STDLIB_ALLOC, malloc, realloc): Likewise.
87643         careadlinkat: rename members to avoid problem
87644         * lib/allocator.h (struct allocator): Rename members from
87645         malloc/realloc to allocate/reallocate, to avoid problems if malloc
87646         and realloc are #define'd.  Reported by Eric Blake in
87647         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00091.html>.
87648         * lib/careadlinkat.c (careadlinkat): Adjust to renaming.
87650 2011-04-08  Eric Blake  <eblake@redhat.com>
87652         nonblocking: reduce dependency
87653         * tests/test-nonblocking.c: Only test sockets when in use.
87654         * modules/nonblocking-tests (Depends-on): Drop socket.
87655         (Makefile.am): Link even if sockets are not present.
87656         * modules/pipe2-tests (Makefile.am): Likewise.
87657         * lib/ioctl.c (ioctl) [WIN32]: Fail if sockets are not also in use.
87659         pipe2: fix O_NONBLOCK support on mingw
87660         * modules/pipe2 (Depends-on): Add nonblocking.
87661         * lib/pipe2.c (pipe2) [WIN32]: Add O_NONBLOCK support.
87662         * tests/test-pipe2.c (is_nonblocking): Adjust test accordingly.
87663         * tests/test-nonblocking.c (main): Likewise.
87664         * modules/pipe2-tests (Makefile.am): Avoid link failure.
87666         fcntl-h: fix O_ACCMODE on cygwin
87667         * doc/posix-headers/fcntl.texi (fcntl.h): Document the bug.
87668         * lib/fcntl.in.h (O_ACCMODE): Fix it.
87670         pipe-filter: drop O_NONBLOCK workarounds
87671         * modules/pipe-filter-gi (Depends-on): Add fcntl-h.
87672         * modules/pipe-filter-ii (Depends-on): Likewise.
87673         * lib/pipe-filter-aux.h (O_NONBLOCK): Delete workaround.
87675         nonblocking: provide O_NONBLOCK for mingw
87676         * modules/nonblocking (Depends-on): Add open.
87677         (configure.ac): Set new witness macro.
87678         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Provide default for it.
87679         * modules/fcntl-h (Makefile.am): Substitute it.
87680         * lib/fcntl.in.h (O_NONBLOCK): Guarantee non-zero definition when
87681         nonblocking module is in use.
87682         * lib/nonblocking.c: Adjust portability test.
87683         * lib/open.c (open): Don't let native open see gnulib flag.
87684         * tests/test-fcntl-h.c (main): Enhance test.
87685         * tests/test-open.h (test_open): Likewise.
87686         * doc/posix-headers/fcntl.texi (fcntl.h): Document the replacement.
87688         careadlinkat: fix compilation error on mingw
87689         * lib/careadlinkat.c (standard_allocator): Avoid renaming fields
87690         within struct allocator.
87692 2011-04-06  Eric Blake  <eblake@redhat.com>
87694         binary-io: relicense under LGPLv2+
87695         * modules/binary-io (License): Relax to LGPLv2+.
87696         Requested for libvirt, and required by pipe2.
87698 2011-04-06  Paul Eggert  <eggert@cs.ucla.edu>
87700         verify: use _Static_assert if available
87701         * lib/verify.h (HAVE__STATIC_ASSERT): New macro.
87702         (verify_true, verify): Use it if available.  This generates better
87703         diagnostics with GCC 4.6.0 and later.
87705 2011-04-05  Bruno Haible  <bruno@clisp.org>
87707         Remove leftover generated .h files after config.status changed.
87709         * m4/alloca.m4 (gl_FUNC_ALLOCA): New automake conditional
87710         GL_GENERATE_ALLOCA_H.
87711         * modules/alloca-opt (Makefile.am): Remove alloca.h if
87712         GL_GENERATE_ALLOCA_H evaluates to false.
87714         * m4/argz.m4 (gl_FUNC_ARGZ): New automake conditional
87715         GL_GENERATE_ARGZ_H.
87716         * modules/argz (Makefile.am): Remove argz.h if GL_GENERATE_ARGZ_H
87717         evaluates to false.
87719         * m4/byteswap.m4 (gl_BYTESWAP): New automake conditional
87720         GL_GENERATE_BYTESWAP_H.
87721         * modules/byteswap (Makefile.am): Remove byteswap.h if
87722         GL_GENERATE_BYTESWAP_H evaluates to false.
87724         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): New automake conditional
87725         GL_GENERATE_ERRNO_H.
87726         * modules/errno (Makefile.am): Remove errno.h if GL_GENERATE_ERRNO_H
87727         evaluates to false.
87729         * m4/float_h.m4 (gl_FLOAT_H): New automake conditional
87730         GL_GENERATE_FLOAT_H.
87731         * modules/float (Makefile.am): Remove float.h if GL_GENERATE_FLOAT_H
87732         evaluates to false.
87734         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): New automake conditional
87735         GL_GENERATE_FNMATCH_H.
87736         * modules/fnmatch (Makefile.am): Remove fnmatch.h if
87737         GL_GENERATE_FNMATCH_H evaluates to false.
87739         * m4/glob.m4 (gl_GLOB_SUBSTITUTE, gl_GLOB): New automake conditional
87740         GL_GENERATE_GLOB_H.
87741         * modules/glob (Makefile.am): Remove glob.h if GL_GENERATE_GLOB_H
87742         evaluates to false.
87744         * m4/iconv_h.m4 (gl_REPLACE_ICONV_H, gl_ICONV_H_DEFAULTS): New
87745         automake conditional GL_GENERATE_ICONV_H.
87746         * modules/iconv-h (Makefile.am): Remove iconv.h if GL_GENERATE_ICONV_H
87747         evaluates to false.
87749         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): New automake conditional
87750         GL_GENERATE_NETINET_IN_H.
87751         * modules/netinet_in (Makefile.am): Remove netinet/in.h if
87752         GL_GENERATE_NETINET_IN_H evaluates to false.
87754         * m4/pthread.m4 (gl_PTHREAD_CHECK): Set PTHREAD_H here. New automake
87755         conditional GL_GENERATE_PTHREAD_H.
87756         (gl_PTHREAD_DEFAULTS): Don't set PTHREAD_H here.
87757         * modules/pthread (Makefile.am): Remove pthread.h if
87758         GL_GENERATE_PTHREAD_H evaluates to false.
87760         * m4/sched_h.m4 (gl_SCHED_H): New automake conditional
87761         GL_GENERATE_SCHED_H.
87762         * modules/sched (Makefile.am): Remove sched.h if GL_GENERATE_SCHED_H
87763         evaluates to false.
87765         * m4/selinux-context-h.m4 (gl_HEADERS_SELINUX_CONTEXT_H): New automake
87766         conditional GL_GENERATE_SELINUX_CONTEXT_H.
87767         * modules/selinux-h (Makefile.am): Remove selinux/context.h if
87768         GL_GENERATE_SELINUX_CONTEXT_H evaluates to false.
87770         * m4/stdarg.m4 (gl_STDARG_H): New automake conditional
87771         GL_GENERATE_STDARG_H.
87772         * modules/stdarg (Makefile.am): Remove stdarg.h if
87773         GL_GENERATE_STDARG_H evaluates to false.
87775         * m4/stdbool.m4 (AM_STDBOOL_H): New automake conditional
87776         GL_GENERATE_STDBOOL_H.
87777         * modules/stdbool (Makefile.am): Remove stdbool.h if
87778         GL_GENERATE_STDBOOL_H evaluates to false.
87780         * m4/stddef_h.m4 (gl_STDDEF_H): Set STDDEF_H here. New automake
87781         conditional GL_GENERATE_STDDEF_H.
87782         (gl_STDDEF_H_DEFAULTS): Don't set STDDEF_H here.
87783         * modules/stddef (Makefile.am): Remove stddef.h if
87784         GL_GENERATE_STDDEF_H evaluates to false.
87786         * m4/stdint.m4 (gl_STDINT_H): New automake conditional
87787         GL_GENERATE_STDINT_H.
87788         * modules/stdint (Makefile.am): Remove stdint.h if
87789         GL_GENERATE_STDINT_H evaluates to false.
87791         * m4/sysexits.m4 (gl_SYSEXITS): New automake conditional
87792         GL_GENERATE_SYSEXITS_H.
87793         * modules/sysexits (Makefile.am): Remove sysexits.h if
87794         GL_GENERATE_SYSEXITS_H evaluates to false.
87796         Reported by Karl Berry and Ralf Wildenhues.
87798 2011-04-05  Bruno Haible  <bruno@clisp.org>
87800         Ensure to rebuild generated .h files when config.status has changed.
87801         * modules/arpa_inet (Makefile.am): Add dependency from .h file to
87802         config.status.
87803         * modules/ctype (Makefile.am): Likewise.
87804         * modules/dirent (Makefile.am): Likewise.
87805         * modules/errno (Makefile.am): Likewise.
87806         * modules/fcntl-h (Makefile.am): Likewise.
87807         * modules/float (Makefile.am): Likewise.
87808         * modules/getopt-posix (Makefile.am): Likewise.
87809         * modules/glob (Makefile.am): Likewise.
87810         * modules/iconv-h (Makefile.am): Likewise.
87811         * modules/inttypes (Makefile.am): Likewise.
87812         * modules/langinfo (Makefile.am): Likewise.
87813         * modules/locale (Makefile.am): Likewise.
87814         * modules/math (Makefile.am): Likewise.
87815         * modules/netdb (Makefile.am): Likewise.
87816         * modules/netinet_in (Makefile.am): Likewise.
87817         * modules/poll-h (Makefile.am): Likewise.
87818         * modules/pthread (Makefile.am): Likewise.
87819         * modules/pty (Makefile.am): Likewise.
87820         * modules/sched (Makefile.am): Likewise.
87821         * modules/search (Makefile.am): Likewise.
87822         * modules/selinux-h (Makefile.am): Likewise.
87823         * modules/signal (Makefile.am): Likewise.
87824         * modules/spawn (Makefile.am): Likewise.
87825         * modules/stdarg (Makefile.am): Likewise.
87826         * modules/stdbool (Makefile.am): Likewise.
87827         * modules/stddef (Makefile.am): Likewise.
87828         * modules/stdint (Makefile.am): Likewise.
87829         * modules/stdio (Makefile.am): Likewise.
87830         * modules/stdlib (Makefile.am): Likewise.
87831         * modules/string (Makefile.am): Likewise.
87832         * modules/strings (Makefile.am): Likewise.
87833         * modules/sys_file (Makefile.am): Likewise.
87834         * modules/sys_ioctl (Makefile.am): Likewise.
87835         * modules/sys_select (Makefile.am): Likewise.
87836         * modules/sys_socket (Makefile.am): Likewise.
87837         * modules/sys_stat (Makefile.am): Likewise.
87838         * modules/sys_time (Makefile.am): Likewise.
87839         * modules/sys_times (Makefile.am): Likewise.
87840         * modules/sys_utsname (Makefile.am): Likewise.
87841         * modules/sys_wait (Makefile.am): Likewise.
87842         * modules/sysexits (Makefile.am): Likewise.
87843         * modules/termios (Makefile.am): Likewise.
87844         * modules/time (Makefile.am): Likewise.
87845         * modules/unistd (Makefile.am): Likewise.
87846         * modules/wchar (Makefile.am): Likewise.
87847         * modules/wctype-h (Makefile.am): Likewise.
87848         Reported by Karl Berry, Eric Blake, and Ralf Wildenhues.
87850 2011-04-05  Bruno Haible  <bruno@clisp.org>
87852         pipe2: Relicense under LGPLv2+.
87853         * modules/pipe2 (License): Change to LGPLv2+.
87854         Requested by Eric Blake, for libvirt.
87856 2011-04-05  Bruce Korb  <bkorb@gnu.org>
87858         bootstrap: compute gnulib_extra_files after updating build_aux
87859         * build-aux/bootstrap (gnulib_extra_files): bootstrap.conf may
87860         change build_aux or also supply gnulib_extra_files.  Handle correctly.
87862 2011-04-05  Eric Blake  <eblake@redhat.com>
87864         bootstrap: preserve git whitelist item sorting
87865         * build-aux/bootstrap (sort_patterns): New function.
87866         (insert_sorted_if_absent): Use it to sink ! lines to the bottom.
87868 2011-04-05  Simon Josefsson  <simon@josefsson.org>
87870         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Don't trigger
87871         sc_space_tab check.
87873 2011-04-05  Paul Eggert  <eggert@cs.ucla.edu>
87875         areadlink, areadlinkat: rewrite in terms of careadlinkat
87876         * lib/areadlink.c, lib/areadlinkat.c: Include careadlinkat.h
87877         instead of errno.h, limits.h, stdint.h, stdlib.h, string.h, unistd.h.
87878         (SSIZE_MAX, INITIAL_BUF_SIZE): Remove.
87879         (malloc, realloc): Remove #undefs.
87880         (areadlink, areadlinkat): Rewrite in terms of careadlinkat.
87881         * modules/areadlink (Depends-on): Add careadlinkat.  Remove
87882         readlink, ssize_t, stdint, unistd.
87883         * modules/areadlinkat (Depends-on): Add careadlinkat.  Remove
87884         areadlink, stdint.
87886         careadlinkat: new module
87887         * lib/allocator.h, lib/careadlinkat.h, lib/careadlinkat.c:
87888         * modules/careadlinkat: New files, written by me with
87889         a review and feedback from Ben Pfaff in
87890         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00008.html>.
87892 2011-04-01  Bruno Haible  <bruno@clisp.org>
87894         wmemchr, wcschr, wcsrchr, wcspbrk, wcsstr: Avoid errors in C++ mode.
87895         * lib/wchar.in.h (wmemchr, wcschr, wcsrchr, wcspbrk, wcsstr): Use
87896         _GL_CXXALIAS_SYS_CAST2 instead of _GL_CXXALIAS_SYS. On glibc >= 2.10
87897         systems, use _GL_CXXALIASWARN1 instead of _GL_CXXALIASWARN.
87898         Reported by Bruce Korb <bruce.korb@gmail.com>.
87900 2011-04-01  Bruno Haible  <bruno@clisp.org>
87902         wcpcpy, wcpncpy: Ensure declaration on glibc >= 2.13 systems.
87903         * m4/wcpcpy.m4 (gl_FUNC_WCPCPY): Require AC_USE_SYSTEM_EXTENSIONS.
87904         * m4/wcpncpy.m4 (gl_FUNC_WCPNCPY): Likewise.
87905         * modules/wcpcpy (Depends-on): Add extensions.
87906         * modules/wcpncpy (Depends-on): Likewise.
87907         * doc/posix-functions/wcpcpy.texi: Mention missing declaration on glibc
87908         systems.
87909         * doc/posix-functions/wcpncpy.texi: Likewise.
87910         * doc/posix-functions/wcwidth.texi: Likewise.
87912 2011-03-31  Eric Blake  <eblake@redhat.com>
87914         nonblocking: fix mingw test failures
87915         * lib/nonblocking.c (set_nonblocking_flag): Succeed when clearing
87916         non-blocking flag on regular file.
87917         (get_nonblocking_flag): Set errno on invalid fd.
87918         * tests/test-nonblocking.c (main): Avoid test failure on
87919         directories if fchdir is not active.
87920         * modules/nonblocking-tests (Depends-on): Drop unused dependency.
87922 2011-03-31  Bruno Haible  <bruno@clisp.org>
87924         Fix bug with gl_WARN_ON_USE_PREPARE, introduced on 2011-01-23.
87925         * m4/gnulib-common.m4 (gl_ASSERT_NO_GNULIB_POSIXCHECK): Hide the
87926         gl_WARN_ON_USE_PREPARE definition from 'aclocal'.
87927         Reported by Simon Josefsson <simon@josefsson.org>.
87929 2011-03-31  Bruno Haible  <bruno@clisp.org>
87930         and Eric Blake  <eblake@redhat.com>
87932         nonblocking: new module
87933         * modules/nonblocking: New module.
87934         * modules/nonblocking-tests: Likewise.
87935         * lib/nonblocking.h: New file.
87936         * lib/nonblocking.c: Likewise.
87937         * tests/test-nonblocking.c: New test.
87938         * lib/ioctl.c (ioctl) [mingw]: Update comment.
87940 2011-03-30  Bruno Haible  <bruno@clisp.org>
87942         stdio: Avoid GCC >= 4.4 warnings when using %lld and similar on mingw.
87943         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT_PRINTF): Use 'gnu_printf' format
87944         instead of 'printf' format for GCC >= 4.4.
87945         (_GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM): New macro.
87946         (fprintf, printf, vfprintf, vprintf): Declare with
87947         _GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM when the function ends up calling
87948         the system's vfprintf() function.
87949         Reported by Daniel P. Berrange <berrange@redhat.com> via Eric Blake.
87951 2011-03-30  Eric Blake  <eblake@redhat.com>
87953         passfd: fix scoping bug
87954         * lib/passfd.c (sendfd, recvfd): Don't let buf go out of scope
87955         before sendmsg/recvmsg.
87957         passfd: standardize coding conventions
87958         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Drop check for something that
87959         can be learned at compile time.
87960         * lib/passfd.c (MSG_CMSG_CLOEXEC): Reduce number of in-function
87961         ifdefs.
87962         (sendfd, recvfd): Follow gnulib code conventions.
87964         passfd: fix incorrect sendmsg arguments
87965         * lib/passfd.c (sendfd): Avoid uninitialized msg_flags field, and
87966         incorrect msg_controllen value.
87967         * modules/passfd-tests (Depends-on): Check for alarm.
87968         * tests/test-passfd.c (main) [HAVE_DECL_ALARM]: Avoid hanging test.
87969         Reported by Bastien ROUCARIES.
87971 2011-03-30  Bruno Haible  <bruno@clisp.org>
87973         c-strcasestr: Relicense under LGPLv2+.
87974         * modules/c-strcasestr (License): Change to LGPLv2+.
87975         Requested by Eric Blake, for libvirt.
87977 2011-03-30  Simon Josefsson  <simon@josefsson.org>
87979         * users.txt: Add libidn2.  Fix libtasn1 link.
87981 2011-03-30  Jim Meyering  <meyering@redhat.com>
87983         tests: readlink* ("",... fails with EINVAL on newer kernels
87984         readlink and readlinkat have typically failed with ENOENT for
87985         the invalid, empty file name,  "".  However, with the advent
87986         of linux-2.6.39, they fail with EINVAL.
87987         * tests/test-areadlink.h (test_areadlink): Also accept EINVAL
87988         when operating on the empty file name.
87989         * tests/test-readlink.h (test_readlink): Likewise.
87991 2011-03-29  Bruno Haible  <bruno@clisp.org>
87993         Relicense some modules under LGPLv2+, for libidn2.
87994         * modules/array-mergesort (License): Change to LGPLv2+.
87995         * modules/c-strcaseeq (License): Likewise.
87996         * modules/striconveh (License): Likewise.
87997         * modules/striconveha (License): Likewise.
87998         * modules/uniconv/base (License): Likewise.
87999         * modules/uniconv/u8-conv-from-enc (License): Likewise.
88000         * modules/uniconv/u8-strconv-from-enc (License): Likewise.
88001         * modules/uniconv/u8-strconv-from-locale (License): Likewise.
88002         * modules/unictype/base (License): Likewise.
88003         * modules/unictype/bidiclass-of (License): Likewise.
88004         * modules/unictype/category-M (License): Likewise.
88005         * modules/unictype/category-none (License): Likewise.
88006         * modules/unictype/category-of (License): Likewise.
88007         * modules/unictype/category-test (License): Likewise.
88008         * modules/unictype/category-test-withtable (License): Likewise.
88009         * modules/unictype/combining-class (License): Likewise.
88010         * modules/unictype/joiningtype-of (License): Likewise.
88011         * modules/unictype/scripts (License): Likewise.
88012         * modules/uninorm/base (License): Likewise.
88013         * modules/uninorm/canonical-decomposition (License): Likewise.
88014         * modules/uninorm/composition (License): Likewise.
88015         * modules/uninorm/decompose-internal (License): Likewise.
88016         * modules/uninorm/decomposition-table (License): Likewise.
88017         * modules/uninorm/nfc (License): Likewise.
88018         * modules/uninorm/nfd (License): Likewise.
88019         * modules/uninorm/u32-normalize (License): Likewise.
88020         * modules/unistr/base (License): Likewise.
88021         * modules/unistr/u32-cpy (License): Likewise.
88022         * modules/unistr/u32-mbtouc-unsafe (License): Likewise.
88023         * modules/unistr/u32-to-u8 (License): Likewise.
88024         * modules/unistr/u32-uctomb (License): Likewise.
88025         * modules/unistr/u8-check (License): Likewise.
88026         * modules/unistr/u8-mblen (License): Likewise.
88027         * modules/unistr/u8-mbtouc (License): Likewise.
88028         * modules/unistr/u8-mbtouc-unsafe (License): Likewise.
88029         * modules/unistr/u8-mbtoucr (License): Likewise.
88030         * modules/unistr/u8-prev (License): Likewise.
88031         * modules/unistr/u8-strlen (License): Likewise.
88032         * modules/unistr/u8-to-u32 (License): Likewise.
88033         * modules/unistr/u8-uctomb (License): Likewise.
88034         * modules/unitypes (License): Likewise.
88035         Requested by Simon Josefsson.
88037 2011-03-29  Simon Josefsson  <simon@josefsson.org>
88039         lib-symbol-visibility: Add a notice.
88040         * modules/lib-symbol-visibility (Notice): New field.
88042 2011-03-29  Bruno Haible  <bruno@clisp.org>
88044         getaddrinfo: Doc fix.
88045         * doc/posix-functions/getaddrinfo.texi: Mention Windows problem in the
88046         section "fixed in Gnulib".
88048 2011-03-28  Simon Josefsson  <simon@josefsson.org>
88050         * doc/posix-functions/getaddrinfo.texi: Drop netdb.h discussion.
88051         Reported by Bastien ROUCARIES <roucaries.bastien@gmail.com>.
88053 2011-03-26  Bruno Haible  <bruno@clisp.org>
88055         unictype/property-byname: Reduce the number of load-time relocations.
88056         * lib/unictype/pr_byname.c: Include <stdlib.h>.
88057         (UC_PROPERTY_INDEX_*): New enumeration values.
88058         (uc_property_byname): Convert an index from the lookup table to an
88059         uc_property_t.
88060         * lib/unictype/pr_byname.gperf: Store indices instead of uc_property_t
88061         values.
88063 2011-03-26  Bruno Haible  <bruno@clisp.org>
88065         unictype/property-byname: Allow omitted word separators and aliases.
88066         * lib/unictype/pr_byname.gperf: Add property names without word
88067         separators. Add aliases from Unicode 6.0 PropertyAliases.txt, except
88068         for 'space'.
88070 2011-03-26  Bruno Haible  <bruno@clisp.org>
88072         unictype/joininggroup-byname: Allow hyphens, omitted word separators.
88073         * lib/unictype/joininggroup_byname.c (uc_joining_group_byname): Convert
88074         also hyphens to space.
88075         * lib/unictype/joininggroup_byname.gperf: Recognize the names also
88076         without spaces.
88077         * tests/unictype/test-joininggroup_byname.c (main): Add more tests.
88079 2011-03-26  Bruno Haible  <bruno@clisp.org>
88081         unictype/joiningtype-byname: Recognize long names as well.
88082         * lib/unictype.in.h (uc_joiningtype_class_byname): Allow argument to be
88083         a long name.
88084         * lib/unictype/joiningtype_byname.c: Include <string.h>,
88085         unictype/joiningtype_byname.h.
88086         (uc_joiningtype_class_byname): Use uc_joining_type_lookup.
88087         * lib/unictype/joiningtype_byname.gperf: New file.
88088         * modules/unictype/joiningtype-byname (Files): Add
88089         lib/unictype/joiningtype_byname.gperf.
88090         (Depends-on): Add gperf.
88091         (Makefile.am): Add rule for generating unictype/joiningtype_byname.h.
88092         * tests/unictype/test-joiningtype_byname.c (main): Test the recognition of
88093         long names.
88095         Tests for module 'unictype/joiningtype-longname'.
88096         * modules/unictype/joiningtype-longname-tests: New file.
88097         * tests/unictype/test-joiningtype_longname.c: New file.
88099         New module 'unictype/joiningtype-longname'.
88100         * lib/unictype.in.h (uc_joiningtype_class_long_name): New declaration.
88101         * lib/unictype/joiningtype_longname.c: New file.
88102         * modules/unictype/joiningtype-longname: New file.
88103         * modules/unictype/joiningtype-all (Depends-on): Add
88104         unictype/joiningtype-longname.
88106 2011-03-26  Bruno Haible  <bruno@clisp.org>
88108         unictype/bidiclass-byname: Recognize long names as well.
88109         * lib/unictype.in.h (uc_bidi_class_byname): Allow argument to be a long
88110         name.
88111         * lib/unictype/bidi_byname.c: Include <string.h>,
88112         unictype/bidi_byname.h.
88113         (uc_bidi_class_byname): Use uc_bidi_class_lookup.
88114         * lib/unictype/bidi_byname.gperf: New file.
88115         * modules/unictype/bidiclass-byname (Files): Add
88116         lib/unictype/bidi_byname.gperf.
88117         (Depends-on): Add gperf.
88118         (Makefile.am): Add rule for generating unictype/bidi_byname.h.
88119         * tests/unictype/test-bidi_byname.c (main): Test the recognition of
88120         long names.
88122         Tests for module 'unictype/bidiclass-longname'.
88123         * modules/unictype/bidiclass-longname-tests: New file.
88124         * tests/unictype/test-bidi_longname.c: New file.
88126         New module 'unictype/bidiclass-longname'.
88127         * lib/unictype.in.h (uc_bidi_class_long_name): New declaration.
88128         * lib/unictype/bidi_longname.c: New file.
88129         * modules/unictype/bidiclass-longname: New file.
88130         * modules/unictype/bidiclass-all (Depends-on): Add
88131         unictype/bidiclass-longname.
88133 2011-03-26  Bruno Haible  <bruno@clisp.org>
88135         unictype/bidi*: Rename modules.
88136         * modules/unictype/bidiclass-all: Renamed from
88137         modules/unictype/bidicategory-all.
88138         * modules/unictype/bidiclass-name: Renamed from
88139         modules/unictype/bidiclass-name.
88140         (Description): Update.
88141         * modules/unictype/bidiclass-name-tests: Renamed from
88142         modules/unictype/bidicategory-name-tests.
88143         * modules/unictype/bidiclass-byname: Renamed from
88144         modules/unictype/bidicategory-byname.
88145         (Description): Update.
88146         * modules/unictype/bidiclass-byname-tests: Renamed from
88147         modules/unictype/bidicategory-byname-tests.
88148         * modules/unictype/bidiclass-of: Renamed from
88149         modules/unictype/bidicategory-of.
88150         (Description): Update.
88151         * modules/unictype/bidiclass-of-tests: Renamed from
88152         modules/unictype/bidicategory-of-tests.
88153         * modules/unictype/bidiclass-test: Renamed from
88154         modules/unictype/bidicategory-test.
88155         (Description): Update.
88156         * modules/unictype/bidiclass-test-tests: Renamed from
88157         modules/unictype/bidicategory-test-tests.
88158         * modules/unictype/bidicategory-all: New file, a simple redirection.
88159         * modules/unictype/bidicategory-name: Likewise.
88160         * modules/unictype/bidicategory-byname: Likewise.
88161         * modules/unictype/bidicategory-of: Likewise.
88162         * modules/unictype/bidicategory-test: Likewise.
88163         * modules/unictype/property-bidi-* (Dependencies): Update.
88164         * lib/unictype/bidi_*.c: Update comment.
88166 2011-03-26  Bruno Haible  <bruno@clisp.org>
88168         unictype/bidi*: Rename functions, part 2.
88169         * modules/unictype/bidicategory-name (configure.ac): Update required
88170         libunistring version.
88171         * modules/unictype/bidicategory-byname (configure.ac): Likewise.
88173 2011-03-25  Bruno Haible  <bruno@clisp.org>
88175         New module 'unictype/combining-class-all'.
88176         * modules/unictype/combining-class-all: New file.
88178         Tests for module 'unictype/combining-class-byname'.
88179         * modules/unictype/combining-class-byname-tests: New file.
88180         * tests/unictype/test-combiningclass_byname.c: New file.
88182         New module 'unictype/combining-class-byname'.
88183         * lib/unictype.in.h (uc_combining_class_byname): New declaration.
88184         * lib/unictype/combiningclass_byname.c: New file.
88185         * lib/unictype/combiningclass_byname.gperf: New file.
88186         * modules/unictype/combining-class-byname: New file.
88188         Tests for module 'unictype/combining-class-longname'.
88189         * modules/unictype/combining-class-longname-tests: New file.
88190         * tests/unictype/test-combiningclass_longname.c: New file.
88192         New module 'unictype/combining-class-longname'.
88193         * lib/unictype.in.h (uc_combining_class_long_name): New declaration.
88194         * lib/unictype/combiningclass_longname.c: New file.
88195         * modules/unictype/combining-class-longname: New file.
88197         Tests for module 'unictype/combining-class-name'.
88198         * modules/unictype/combining-class-name-tests: New file.
88199         * tests/unictype/test-combiningclass_name.c: New file.
88201         New module 'unictype/combining-class-name'.
88202         * lib/unictype.in.h (uc_combining_class_name): New declaration.
88203         * lib/unictype/combiningclass_name.c: New file.
88204         * modules/unictype/combining-class-name: New file.
88206 2011-03-25  Bruno Haible  <bruno@clisp.org>
88208         unictype/combining-class: Rename source files.
88209         * lib/gen-uni-tables.c (main): Emit unictype/combiningclass.h instead
88210         of unictype/combining.h.
88211         * lib/unictype/combiningclass.c: Renamed from lib/unictype/combining.c.
88212         Update.
88213         * lib/unictype/combiningclass.h: Renamed from lib/unictype/combining.h.
88214         * modules/unictype/combining-class (Description): Fix.
88215         (Files, Makefile.am): Update.
88216         * tests/unictype/test-combiningclass.c: Renamed from
88217         tests/unictype/test-combining.c.
88218         * modules/unictype/combining-class-tests (Files, Makefile.am): Update.
88220 2011-03-25  Bruno Haible  <bruno@clisp.org>
88222         unictype: Update list of canonical combining classes.
88223         * lib/unictype.in.h (UC_CCC_ATA): New enumeration value.
88225 2011-03-25  Bruno Haible  <bruno@clisp.org>
88227         unictype/category-byname: Recognize long names as well.
88228         * lib/unictype.in.h (uc_general_category_byname): Allow argument to be
88229         a long name.
88230         * lib/unictype/categ_byname.c: Include <stdlib.h>, <string.h>,
88231         unictype/categ_byname.h.
88232         (UC_CATEGORY_INDEX_*): New enumeration values.
88233         (uc_general_category_byname): Use uc_general_category_lookup and
88234         convert from index to value.
88235         * lib/unictype/categ_byname.gperf: New file.
88236         * modules/unictype/category-byname (Files): Add
88237         lib/unictype/categ_byname.gperf.
88238         (Depends-on): Add gperf.
88239         (Makefile.am): Add rule for generating unictype/categ_byname.h.
88240         * tests/unictype/test-categ_byname.c (main): Test the recognition of
88241         long names.
88243         Tests for module 'unictype/category-longname'.
88244         * modules/unictype/category-longname-tests: New file.
88245         * tests/unictype/test-categ_longname.c: New file.
88247         New module 'unictype/category-longname'.
88248         * lib/unictype.in.h (uc_general_category_long_name): New declaration.
88249         * lib/unictype/categ_longname.c: New file.
88250         * modules/unictype/category-longname: New file.
88251         * modules/unictype/category-all (Depends-on): Add it.
88253 2011-03-25  Bruno Haible  <bruno@clisp.org>
88255         Tests for module 'unictype/category-LC'.
88256         * modules/unictype/category-LC-tests: New file.
88257         * tests/unictype/test-categ_LC.c: New file, automatically generated.
88259         New module 'unictype/category-LC'.
88260         * lib/unictype.in.h (UC_CATEGORY_MASK_LC): New enumeration value.
88261         (UC_CATEGORY_LC): New declaration.
88262         (UC_CASED_LETTER): New macro.
88263         * lib/gen-uni-tables.c (is_category_LC): New function.
88264         (output_categories): Also handle category LC.
88265         (UC_CATEGORY_MASK_LC): New enumeration value.
88266         (general_category_byname): Also handle category LC.
88267         * lib/unictype/categ_LC.c: New file.
88268         * lib/unictype/categ_LC.h: New file, automatically generated.
88269         * lib/unictype/categ_name.c (uc_general_category_name): Also handle
88270         category LC.
88271         * lib/unictype/categ_byname.c (uc_general_category_byname): Likewise.
88272         * modules/unictype/category-LC: New file.
88273         * modules/unictype/category-byname (Depends-on): Add
88274         unictype/category-LC.
88275         * modules/unictype/category-all (Depends-on): Likewise.
88277 2011-03-25  Eric Blake  <eblake@redhat.com>
88279         xmalloc: revert yesterday's regression
88280         * lib/xmalloc.c (xrealloc): Once again forward xrealloc(NULL,0) to
88281         realloc's underlying behavior (allowing allocation of zero-size
88282         objects, especially if malloc-gnu is also in use).
88284 2011-03-25  Reuben Thomas  <rrt@sc3d.org>
88286         maint.mk: add missing version to VC-tag
88287         * top/maint.mk: git tag was missing actual tag name; add it.
88289         valgrind: do leak checking, and exit with code 1 on error (not 0)
88290         * m4/valgrind-tests.m4: Add `--error-exitcode=1 --leak-check=full'
88291         to VALGRIND.
88293 2010-11-30  Reuben Thomas  <rrt@sc3d.org>
88295         posix-modules: say what it does.
88296         * posix-modules: Add a line to the --help output saying what it does.
88298 2011-03-24  Paul Eggert  <eggert@cs.ucla.edu>
88300         xmalloc: Do not leak if underlying realloc is C99 compatible.
88301         * lib/xmalloc.c (xrealloc): If N is zero, call 'free' directly.
88302         This avoids a leak on C99-based systems.  See
88303         <http://lists.gnu.org/r/bug-gnulib/2011-03/msg00243.html>.
88305 2011-03-24  Eric Blake  <eblake@redhat.com>
88307         realloc: document portability problem
88308         * doc/posix-functions/realloc.texi (realloc): Mention pitfalls of
88309         passing 0 size to realloc.
88311 2011-03-23  Ben Walton  <bwalton@artsci.utoronto.ca>
88313         doc: update users.txt
88314         * users.txt: Add cvsps, tmpwatch
88316 2011-03-23  Matt Rice  <ratmice@gmail.com>
88318         doc: update users.txt
88319         * users.txt: Add gdb.
88321 2011-03-23  Jim Meyering  <meyering@redhat.com>
88323         doc: update users.txt
88324         Looking through matches up to the following URL (there are still
88325         several more pages), I found several projects that use gnulib:
88326         http://codesearch.google.com/codesearch?start=50&q=gnulib-cache\.m4
88327         * users.txt: Add nagios plugins (nagiosplug), acct, gengetopt,
88328         gmediaserver, gtkreindeer, jugtail, libunistring, mini-httpd, reindeer.
88330 2011-03-22  Bruno Haible  <bruno@clisp.org>
88332         unictype/bidi*: Rename functions.
88333         * lib/unictype.in.h (uc_bidi_class_name, uc_bidi_class_byname,
88334         uc_bidi_class, uc_is_bidi_class): New declarations.
88335         * lib/unictype/bidi_byname.c (uc_bidi_class_byname): Renamed from
88336         uc_bidi_category_byname.
88337         (uc_bidi_category_byname): New function.
88338         * lib/unictype/bidi_name.c (u_bidi_class_name): Renamed from
88339         u_bidi_category_name.
88340         (uc_bidi_class_name): Renamed from uc_bidi_category_name.
88341         (uc_bidi_category_name): New function.
88342         * lib/unictype/bidi_of.c (uc_bidi_class): Renamed from
88343         uc_bidi_category.
88344         (uc_bidi_category): New function.
88345         * lib/unictype/bidi_test.c (uc_is_bidi_class): Renamed from
88346         uc_is_bidi_category. Invoke uc_bidi_class.
88347         (uc_is_bidi_category): New function.
88348         * tests/unictype/test-bidi_byname.c (main): Test uc_bidi_class_byname
88349         instead of uc_bidi_category_byname.
88350         * tests/unictype/test-bidi_name.c (main): Test uc_bidi_class_name
88351         instead of uc_bidi_category_name.
88352         * tests/unictype/test-bidi_of.c (main): Test uc_bidi_class instead of
88353         uc_bidi_category.
88354         * tests/unictype/test-bidi_test.c (main): Test uc_is_bidi_class
88355         instead of uc_is_bidi_category.
88357 2011-03-21  Bruno Haible  <bruno@clisp.org>
88359         New module 'unictype/joininggroup-all'.
88360         * modules/unictype/joininggroup-all: New file.
88362         Tests for module 'unictype/joininggroup-of'.
88363         * modules/unictype/joininggroup-of-tests: New file.
88364         * tests/unictype/test-joininggroup_of.c: New file.
88365         * tests/unictype/test-joininggroup_of.h: New file, automatically
88366         generated by gen-uni-tables.
88368         New module 'unictype/joininggroup-of'.
88369         * modules/unictype/joininggroup-of: New file.
88370         * lib/unictype/joininggroup_of.c: New file.
88371         * lib/unictype/joininggroup_of.h: New file, automatically generated by
88372         gen-uni-tables.
88374         Tests for module 'unictype/joininggroup-byname'.
88375         * modules/unictype/joininggroup-byname-tests: New file.
88376         * tests/unictype/test-joininggroup_byname.c: New file.
88378         New module 'unictype/joininggroup-byname'.
88379         * modules/unictype/joininggroup-byname: New file.
88380         * lib/unictype/joininggroup_byname.c: New file.
88381         * lib/unictype/joininggroup_byname.gperf: New file.
88383         Tests for module 'unictype/joininggroup-name'.
88384         * modules/unictype/joininggroup-name-tests: New file.
88385         * tests/unictype/test-joininggroup_name.c: New file.
88387         New module 'unictype/joininggroup-name'.
88388         * modules/unictype/joininggroup-name: New file.
88389         * lib/unictype/joininggroup_name.c: New file.
88390         * lib/unictype/joininggroup_name.h: New file.
88392         New module 'unictype/joiningtype-all'.
88393         * modules/unictype/joiningtype-all: New file.
88395         Tests for module 'unictype/joiningtype-of'.
88396         * modules/unictype/joiningtype-of-tests: New file.
88397         * tests/unictype/test-joiningtype_of.c: New file.
88398         * tests/unictype/test-joiningtype_of.h: New file, automatically
88399         generated by gen-uni-tables.
88401         New module 'unictype/joiningtype-of'.
88402         * modules/unictype/joiningtype-of: New file.
88403         * lib/unictype/joiningtype_of.c: New file.
88404         * lib/unictype/joiningtype_of.h: New file, automatically generated by
88405         gen-uni-tables.
88407         Tests for module 'unictype/joiningtype-byname'.
88408         * modules/unictype/joiningtype-byname-tests: New file.
88409         * tests/unictype/test-joiningtype_byname.c: New file.
88411         New module 'unictype/joiningtype-byname'.
88412         * modules/unictype/joiningtype-byname: New file.
88413         * lib/unictype/joiningtype_byname.c: New file.
88415         Tests for module 'unictype/joiningtype-name'.
88416         * modules/unictype/joiningtype-name-tests: New file.
88417         * tests/unictype/test-joiningtype_name.c: New file.
88419         New module 'unictype/joiningtype-name'.
88420         * modules/unictype/joiningtype-name: New file.
88421         * lib/unictype/joiningtype_name.c: New file.
88423         unictype: Add support for Arabic shaping properties.
88424         * lib/unictype.in.h (UC_JOINING_TYPE_*): New enumeration values.
88425         (uc_joining_type_name, uc_joining_type_byname, uc_joining_type): New
88426         declarations.
88427         (UC_JOINING_GROUP_*): New enumeration values.
88428         (uc_joining_group_name, uc_joining_group_byname, uc_joining_group): New
88429         declarations.
88430         * lib/gen-uni-tables.c (UC_JOINING_TYPE_*): New enumeration values.
88431         (unicode_joining_type): New variable.
88432         (UC_JOINING_GROUP_*): New enumeration values.
88433         (unicode_joining_group): New variable.
88434         (fill_arabicshaping, joining_type_as_c_identifier,
88435         output_joining_type_test, output_joining_type,
88436         joining_group_as_c_identifier, output_joining_group_test,
88437         output_joining_group): New functions.
88438         (main); Add an argument denoting the ArabicShaping.txt file. Invoke
88439         fill_arabicshaping and output_joining_type_test, output_joining_type,
88440         output_joining_group_test, output_joining_group.
88441         Reported by Simon Josefsson.
88443 2011-03-21  Jim Meyering  <meyering@redhat.com>
88445         strftime: fix a bug in yesterday's change
88446         * lib/strftime.c (add): Accommodate width's initial value of -1.
88447         Otherwise, nstrftime would copy uninitialized data into
88448         the result buffer.
88450 2011-03-21  Jim Meyering  <meyering@redhat.com>
88452         tests: add strftime-tests module
88453         * tests/test-strftime.c: New file.
88454         * modules/strftime-tests: New module.
88456 2011-03-20  Paul Eggert  <eggert@cs.ucla.edu>
88458         strftime: don't assume a byte count fits in 'int'
88459         * lib/strftime.c (add): Don't assume first arg fits in 'int'.  I
88460         found this problem by static analysis, using gcc -Wstrict-overflow
88461         (GCC 4.5.2, x86-64).  This reported an optimization that depended
88462         on an integer overflow having undefined behavior, but it turns out
88463         that the argument is a size, which might not fit in 'int' anyway,
88465 2011-03-20  Paul Eggert  <eggert@cs.ucla.edu>
88467         stdio: don't require ignore_value around fwrite
88469         This patch works around libc bug 11959
88470         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=11959>.
88471         Without this patch, applications must often write
88472         ignore_value (fwrite (...)) even though the ignore_value is
88473         not helpful here.  It's common to write many objects, using
88474         fwrite/printf/etc., and then use ferror to detect output error.
88476         I considered making this patch optional, but decided against it,
88477         because libc is obviously being inconsistent here: there is no
88478         reason libc should insist that user code must inspect fwrite
88479         return's value without also insisting that it inspect printf's,
88480         putchar's, etc.  If user code wants to have a strict style where
88481         all these functions' values are checked (so that ferror need not
88482         be checked), we could add support for that style in a new gnulib
88483         module, but in the meantime it's better to be consistent and to
88484         support common usage.
88486         * lib/stdio.in.h (rpl_fwrite): Define this wrapper around fwrite,
88487         to work around libc bug 11959, if __USE_FORTIFY_LEVEL indicates
88488         that we are compiling in checking mode, and if not C++, and
88489         if not already wrapping fwrite for some other reason.
88490         (fwrite): #define to rpl_fwrite if the latter is defined.
88492 2011-03-20  Bruno Haible  <bruno@clisp.org>
88494         verror: Fix compilation error introduced on 2011-02-13.
88495         * lib/verror.h (verror, verror_at_line): Use _GL_ATTRIBUTE_FORMAT macro
88496         instead of __attribute__.
88497         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
88499 2011-03-20  Paul Eggert  <eggert@cs.ucla.edu>
88500             Bruno Haible  <bruno@clisp.org>
88502         socklen: do not depend on sys_socket
88503         While trying to modify Emacs to use gnulib's socklen module,
88504         I discovered a circular dependency: socklen depends on sys_socket
88505         and vice versa.  Emacs can use socklen, but it does not need
88506         sys_socket because it has its own substitute for sys/socket.h.
88507         * m4/socklen.m4 (gl_SOCKET_HEADERS): New macro, extracted from
88508         gl_TYPE_SOCKLEN_T.
88509         (gl_CHECK_SOCKET_HEADERS): New macro, taken from parts of
88510         gl_PREREQ_SYS_H_SOCKET.
88511         (gl_TYPE_SOCKLEN_T): Require it instead of requiring
88512         gl_PREREQ_SYS_H_SOCKET.
88513         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_SOCKET): Require
88514         gl_CHECK_SOCKET_HEADERS instead of doing its work ourselves.
88515         * modules/socklen (Depends-on): Do not depend on sys_socket.
88516         (Include): Adjust to match the code used in gl_SOCKET_HEADERS.
88518 2011-03-20  Jim Meyering  <meyering@redhat.com>
88520         maint.mk: sort file names *after* new transformation
88521         * top/maint.mk (sc_po_check): Sorting before removing the $(srcdir)/
88522         prefix would have led to an unwarranted failure in GNU parted.
88523         Sort after that transformation.
88525 2011-03-19  Jim Meyering  <meyering@redhat.com>
88527         maint.mk: fix po-file syntax-check rule
88528         * top/maint.mk (sc_po_check): Fix fatal typo in yesterday's change.
88529         Patch by Bruno Haible.
88531 2011-03-19  Bruno Haible  <bruno@clisp.org>
88533         socklen: Update comment.
88534         * m4/socklen.m4: Update comment about platforms.
88536 2011-03-19  Paul Eggert  <eggert@cs.ucla.edu>
88537             Bruno Haible  <bruno@clisp.org>
88539         inet_ntop, inet_pton: Simplify.
88540         * modules/inet_ntop (Depends-on): Remove socklen, since sys_socket is
88541         documented to provide socklen_t and we already depend on sys_socket.
88542         * modules/inet_pton (Depends-on): Likewise.
88543         * lib/arpa_inet.in.h: Adjust comment.
88545 2011-03-19  Paul Eggert  <eggert@cs.ucla.edu>
88546             Bruno Haible  <bruno@clisp.org>
88548         netdb: Simplify.
88549         * modules/netdb (Depends-on): Remove socklen, since sys_socket is
88550         documented to provide socklen_t and we already depend on sys_socket.
88551         * lib/netdb.in.h: Adjust comment.
88553 2011-03-19  Bruno Haible  <bruno@clisp.org>
88555         sys_socket, netdb: Document problem with socklen_t.
88556         * doc/posix-headers/sys_socket.texi: Mention lack of socklen_t on some
88557         platforms.
88558         * doc/posix-headers/netdb.texi: Likewise.
88560 2011-03-18  Eric Blake  <eblake@redhat.com>
88562         maint.mk: let po check work in VPATH build
88563         * top/maint.mk (po_file): Allow cfg.mk override.
88564         (sc_po_check): Allow VPATH use.
88565         Reported by Jiri Denemark.
88567 2011-03-16  Jim Meyering  <meyering@redhat.com>
88569         maint.mk: allow fine-grained syntax-check exclusion via Make variables
88570         Before, you would have had to create one .x-sc_ file per rule in order
88571         to exempt offending files.  Now, you may instead use a Make variable --
88572         usually defined in cfg.mk -- whose name identifies the affected rule.
88573         * top/maint.mk (_sc_excl): Define.
88574         (VC_LIST_EXCEPT): Use it to exclude names on a per-rule basis.
88575         (_sc_search_regexp): When not using VC_LIST_EXCEPT, exclude here, too.
88577 2011-03-13  Bruno Haible  <bruno@clisp.org>
88579         ignore-value tests: Avoid warnings.
88580         * tests/test-ignore-value.c (_GL_ATTRIBUTE_RETURN_CHECK): Define to
88581         empty for gcc < 3.4.
88583 2011-03-13  Bruno Haible  <bruno@clisp.org>
88585         passfd: Fix link error on Solaris.
88586         * modules/passfd (Description): Correct.
88587         (Depends-on): Add socketlib.
88588         (Link): New section.
88589         * modules/passfd-tests (Makefile.am): Link test-passfd with LIBSOCKET.
88591 2011-03-13  Bruno Haible  <bruno@clisp.org>
88593         passfd: Fix link error on AIX 5.2.
88594         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Define _LINUX_SOURCE_COMPAT.
88596 2011-03-13  Bruno Haible  <bruno@clisp.org>
88598         passfd: Work around bug with CMSG_FIRSTHDR on FreeBSD 6.4.
88599         * lib/sys_socket.in.h: Include <stddef.h>.
88600         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Include <stddef.h> before using
88601         CMSG_FIRSTHDR. Remove unused variable.
88603 2011-03-13  Bruno Haible  <bruno@clisp.org>
88605         passfd: Fix compilation error on OpenBSD.
88606         * lib/passfd.c: Include <sys/uio.h>.
88608 2011-03-13  Bruno Haible  <bruno@clisp.org>
88610         passfd test: Fix warnings.
88611         * tests/test-passfd.c: Include <sys/wait.h>.
88612         (main): Fix typo.
88614 2011-03-13  Bruno Haible  <bruno@clisp.org>
88616         passfd module, part 4, tweaks.
88617         * tests/test-passfd.c: Reorder includes.
88618         (main): Fix perror and printf calls.
88620 2011-03-07  Bastien Roucariès  <roucaries.bastien@gmail.com>
88622         passfd module, part 4.
88623         * modules/passfd-tests: New file.
88624         * tests/test-passfd.c: New file.
88626 2011-03-13  Jim Meyering  <meyering@redhat.com>
88628         Makefile: rely on GNU make; derive syntax-check rule names
88629         Rather than requiring that each sc_ rule be listed as a dependent
88630         of "check", use features of GNU make to derive the list.
88631         * Makefile (syntax-check-rules): Define.
88632         (check): Depend on the new variable, not the hard-coded list.
88634 2011-03-13  Bastien Roucariès  <roucaries.bastien@gmail.com>
88635             Bruno Haible  <bruno@clisp.org>
88637         passfd module, part 3.
88638         * lib/passfd.h (recvfd): Add a flags argument.
88639         * lib/passfd.c: Include <fcntl.h>, cloexec.h.
88640         (recvfd): Add a flags argument.
88641         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Test whether MSG_CMSG_CLOEXEC
88642         exists.
88643         * modules/passfd (Depends-on): Add cloexec.
88644         Suggested by Eric Blake.
88646 2011-03-13  Bruno Haible  <bruno@clisp.org>
88648         passfd module, part 2, tweaks.
88649         * modules/passfd (Files): Reorder.
88650         (Depends-on): Remove errno.
88651         (Include): Remove <sys/socket.h>, <sys/un.h>.
88652         * lib/passfd.h: Use a GPLv3+ header. Make C++ safe.
88653         * lib/passfd.c: Untabify. Use a GPLv3+ header. Really include the
88654         specification header. Include <sys/socket.h> always. Don't include
88655         <winsock2.h>. Use "#if HAVE_..." instead of "#ifdef HAVE_...".
88656         (sendfd): Clarify that it sets errno when it fails.
88657         (recvfd): Fix specification.
88659 2011-03-07  Bastien Roucariès  <roucaries.bastien@gmail.com>
88661         passfd module, part 2.
88662         * modules/passfd: New file.
88663         * lib/passfd.h: New file.
88664         * lib/passfd.c: New file.
88666 2011-03-12  Bruno Haible  <bruno@clisp.org>
88668         wcswidth, mbswidth: Avoid integer overflow.
88669         * lib/wcswidth.c: Include <limits.h>.
88670         * lib/wcswidth-impl.h (wcswidth): Avoid 'int' overflow.
88671         * lib/mbswidth.c: Include <limits.h>.
88672         (mbsnwidth): Avoid 'int' overflow.
88673         Reported by Jim Meyering.
88675 2011-03-12  Bruno Haible  <bruno@clisp.org>
88677         futimens, utimensat: Avoid endless recursion on Solaris 10.
88678         * lib/sys_stat.in.h (futimens, utimensat): Define with rpl_ prefix on
88679         Solaris.
88680         Reported by Ben Walton <bwalton@artsci.utoronto.ca> via Eric Blake
88681         in <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=8230>.
88683 2011-03-11  Jim Meyering  <meyering@redhat.com>
88685         maint.mk: relax a regexp to accommodate other formatting styles
88686         * top/maint.mk (sc_unmarked_diagnostics): Allow 0 or 1 space
88687         between "ngettext" and the following "(".
88689 2011-03-11  Pádraig Brady  <P@draigBrady.com>
88691         maint.mk: suppress a false positive warning
88692         * top/maint.mk ((sc_unmarked_diagnostics): Don't warn when
88693         diagnostics are marked with ngettext.
88695 2011-03-10  Eric Blake  <eblake@redhat.com>
88697         wchar: add explicit dependencies, for Tru64
88698         * modules/mbmemcasecoll (Depends-on): Add wchar.
88699         * modules/mbtowc (Depends-on): Likewise.
88700         * modules/vasnprintf (Depends-on): Likewise.
88701         * modules/unistdio/u-printf-args (Depends-on): Likewise.
88702         * modules/wctomb (Depends-on): Likewise.
88703         Reported by Peter O'Gorman.
88705 2011-03-08  Bruno Haible  <bruno@clisp.org>
88707         passfd module, part 1, tweaks.
88708         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Update AC_REQUIRE invocation.
88709         Improve indentation. Improve AC_MSG_CHECKING messages.
88710         * m4/sockpfaf.m4 (gl_SOCKET_FAMILY_UNIX): New macro, extracted from
88711         gl_SOCKET_FAMILIES.
88713 2011-03-07  Bastien Roucariès  <roucaries.bastien@gmail.com>
88715         passfd module, part 1.
88716         * m4/afunix.m4: New file.
88717         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Also test for UNIX domain
88718         sockets.
88720 2011-03-08  Bruno Haible  <bruno@clisp.org>
88722         regex-quote: New API.
88723         * lib/regex-quote.h: Include <stdbool.h>.
88724         (struct regex_quote_spec): New type.
88725         (regex_quote_spec_posix, regex_quote_spec_gnu, regex_quote_spec_pcre):
88726         New declarations.
88727         (regex_quote_length, regex_quote_copy, regex_quote): Take a
88728         'const struct regex_quote_spec *' argument.
88729         * lib/regex-quote.c (RE_*, PCRE_*): New macros.
88730         (pcre_special): New constant.
88731         (regex_quote_spec_posix, regex_quote_spec_gnu, regex_quote_spec_pcre):
88732         New functions.
88733         (regex_quote_length, regex_quote_copy, regex_quote): Take a
88734         'const struct regex_quote_spec *' argument.
88735         * modules/regex-quote (Depends-on): Add stdbool.
88736         * tests/test-regex-quote.c (check): Update for new API. Add test for
88737         anchored results.
88738         * NEWS: Mention the API change.
88739         Reported by Reuben Thomas and Eric Blake.
88741 2011-03-06  Bruno Haible  <bruno@clisp.org>
88743         regex-quote: Fix creation of POSIX extended regular expressions.
88744         * lib/regex-quote.c (ere_special): Add grouping and alternation
88745         operators.
88747 2011-03-05  Bruno Haible  <bruno@clisp.org>
88749         doc: Improve doc regarding autopoint vs. gnulib.
88750         * doc/gnulib-tool.texi (gettextize and autopoint): Recommend to
88751         disable autopoint while running autoreconf.
88752         Suggested by Ralf Wildenhues.
88754 2011-03-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
88756         Update AC_OPENMP macro for Lahey compiler on GNU/Linux.
88757         * m4/openmp.m4 (AC_OPENMP): Sync from Autoconf.
88759 2011-03-03  Bruce Korb  <bkorb@gnu.org>
88761         parse-duration: remove xalloc.h dependency
88762         * lib/parse-duration.c (parse_period): handle NULL return from
88763         strdup instead of calling xstrdup().
88764         * modules/parse-duration: remove "xalloc" dependency
88766 2011-03-03  Matthew Booth  <mbooth@redhat.com>
88768         bootstrap: honor m4_base when running aclocal
88769         * build-aux/bootstrap: Fix hard-coded use of m4 directory name.
88771 2011-03-02  Jim Meyering  <meyering@redhat.com>
88773         getopt-gnu: relax license from LGPLv3+ to LGPLv2+
88774         * modules/getopt-gnu (License): Relax to LGPLv2+, for augeas,
88775         on request from Matt Booth.
88777 2011-03-01  Eric Blake  <eblake@redhat.com>
88779         test-link: work on Hurd
88780         * tests/test-link.h (test_link): Hurd rejects linking directories
88781         with EISDIR instead of the POSIX-mandated EPERM.
88783 2011-02-28  Paul Eggert  <eggert@cs.ucla.edu>
88785         stdio: simplify by moving files to printf-posix, sigpipe
88786         * m4/stdio_h.m4 (gl_STDIO_H): Do not require gl_ASM_SYMBOL_PREFIX,
88787         since this symbol is needed only if printf is replaced.
88788         * m4/printf-posix-rpl.m4 (gl_REPLACE_PRINTF):
88789         Require gl_ASM_SYMBOL_PREFIX.
88790         * modules/printf-posix (Files): Add m4/asm-underscore.m4.
88791         * modules/sigpipe (Files): Likewise.  Also, add m4/stdio-write.c.
88792         (Depends-on): Add 'raise'.
88793         (configure.ac): Require gl_ASM_SYMBOL_PREFIX.
88794         * modules/stdio (Files): Remove lib/stdio-write.c,
88795         m4/asm-underscore.m4.
88796         (Depends-on): Remove 'raise'.
88798         stdio: simplify by moving gl_STDIN_LARGE_OFFSET to fseeko, ftello
88799         * m4/fseeko.m4 (gl_STDIN_LARGE_OFFSET): Moved here, from ...
88800         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET): ... here, because
88801         * modules/ftello (Files): Add m4/fseeko.m4, for gl_STDIN_LARGE_OFFSET.
88803 2011-02-28  Bruno Haible  <bruno@clisp.org>
88805         localcharset: Assume ANSI C behaviour of free().
88806         * lib/localcharset.c (get_charset_aliases): Remove NULL test before
88807         calling free().
88808         Suggested by Simon Josefsson <simon@josefsson.org>.
88810 2011-02-28  Corinna Vinschen  <vinschen@redhat.com>  (tiny change)
88811             Charles Wilson  <cygwin@cwilson.fastmail.fm>  (tiny change)
88812             Bruno Haible  <bruno@clisp.org>  (tiny change)
88814         On Cygwin, use /proc file system instead of win32 API.
88815         * lib/relocatable.c: On Cygwin, use file names from /proc, rather than
88816         Win32 file names.
88817         (DllMain): Simplify by removing Cygwin specific code.
88818         (find_shared_library_fullname): Use Linux specific implementation also
88819         for Cygwin.
88820         (get_shared_library_fullname): Update accordingly.
88821         * lib/progreloc.c: On Cygwin, use file names from /proc, rather than
88822         Win32 file names.
88823         (find_executable): On Cygwin, use /proc, like on Linux. Remove previous
88824         Cygwin specific code.
88826 2011-02-28  Christian Rössel  <christian.roessel@gmx.de>  (tiny change)
88827             Markus Geimer  <m.geimer@fz-juelich.de>  (tiny change)
88829         Fix OpenMP flag detection for various Fortran compilers.
88830         * m4/openmp.m4 (_AC_LANG_OPENMP(Fortran 77)): Use '!$'
88831         OpenMP-conditional compilation construct, to force compile
88832         failure with missing OpenMP flag.
88833         (AC_OPENMP): Add flags for Cray CCE and NEC SX compilers.
88835 2011-02-25  Eric Blake  <eblake@redhat.com>
88837         strstr: expand test coverage
88838         * tests/test-strstr.c (main): Add much shorter trigger.  Fix C89
88839         compilation.
88840         * tests/test-memmem.c (main): Duplicate tests.
88841         * tests/test-strcasestr.c (main): Likewise.
88842         * tests/test-c-strcasestr.c (main): Likewise.
88844 2011-02-25  Jim Meyering  <meyering@redhat.com>
88846         maint.mk: detect missing-NL-at-EOF, too
88847         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Adjust so that
88848         it also detects when a file lacks a newline at EOF.
88849         (require_exactly_one_NL_at_EOF_): Renamed from
88850         detect_empty_lines_at_EOF_.  I opted not to rename the rule,
88851         since people may well have .x-sc_... file names tied to the
88852         existing name.  Suggested by Eric Blake.
88854 2011-02-25  Paul Eggert  <eggert@cs.ucla.edu>
88856         dirname: move m4/dos.m4 functionality into lib/dosname.h
88858         m4/dos.m4 needs to go.  It laboriously invokes the C compiler, and
88859         extracts symbols from it, puts them into config.h; but it's much
88860         easier to use the symbols directly.  filename.h already does this,
88861         but it disagrees with dos.m4 in some respects.  This patch
88862         introduces a different include file dosname.h that packages up
88863         dos.m4, and then later we can work on merging filename.h and
88864         dosname.h.  Applications that need only the easy-to-configure
88865         symbols should consider including dosname.h rather than dirname.h.
88866         * NEWS: Mention incompatible changes.
88867         * m4/dos.m4: Remove.
88868         * lib/dosname.h, modules/dosname: New files.
88869         * lib/dirname.h (ISSLASH, FILE_SYSTEM_PREFIX_LEN):
88870         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE):
88871         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): Move to lib/dosname.h.
88872         * lib/at-func.c, lib/at-func2.c, lib/openat.c, lib/savewd.c:
88873         Include dosname.h, not dirname.h.
88874         * lib/rmdir.c, lib/stat.c, lib/unlink.c, lib/unlinkat.c:
88875         Include dosname.h, for definitions of symbols like ISSLASH
88876         that used to be in config.h.
88877         * m4/dirname.m4 (gl_DIRNAME_LGPL): Do not require gl_AC_DOS.
88878         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
88879         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
88880         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
88881         * modules/dirname-lgpl (Files): Omit m4/dos.m4.
88882         * modules/rmdir (Files): Likewise.
88883         * modules/stat (Files): Likewise.
88884         * modules/unlink (Files): Likewise.
88885         * modules/dirname-lgpl (Depends-on): Add dosname.
88886         * modules/lstat (Depends-on): Likewise.
88887         * modules/openat (Depends-on): Likewise.
88888         * modules/rmdir (Depends-on): Likewise.
88889         * modules/savewd (Depends-on): Likewise.
88890         * modules/stat (Depends-on): Likewise.
88891         * modules/unlink (Depends-on): Likewise.
88892         * modules/openat (Depends-on): Remove dirname-lgpl.
88893         * modules/savewd (Depends-on): Likewise.
88894         * tests/test-dirname.c: Do not use removed symbols like
88895         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.  Instead, use
88896         the remaining symbols, e.g., ISSLASH ('\\').
88898 2011-02-25  Eric Blake  <eblake@redhat.com>
88900         strstr: revert patches that introduced bug and pessimization
88901         * lib/str-two-way.h: Add another reference.
88902         (two_way_short_needle, two_way_long_needle): Revert changes from
88903         2011-02-24; they pessimize search speed.
88904         (critical_factorization): Partially revert changes from
88905         2010-06-22; they violate the requirement that the left half of the
88906         needle be smaller than the period of the needle.
88908 2011-02-24  Paul Eggert  <eggert@cs.ucla.edu>
88910         filenamecat: remove unnecessary dependency on dirname-lgpl
88911         * modules/filenamecat (Depends-on): Remove dirname-lgpl, as there
88912         is no direct dependency, just an indirect one via filenamecat-lgpl.
88914         remove: remove unnecessary use of m4/dos.m4
88915         * m4/remove.m4 (gl_FUNC_REMOVE): Don't require gl_AC_DOS; not needed.
88916         * modules/remove (FILES): Remove m4/dos.m4.
88918         * lib/openat-proc.c: Don't include dirname.h; not needed.
88920         backupfile: remove unnecessary use of m4/dos.m4
88921         * m4/backupfile.m4 (gl_BACKUPFILE): Don't require gl_AC_DOS; none
88922         of its symbols are used by the backupfile code.  backupfile.c does
88923         use a symbol HAVE_DOS_FILE_NAMES, but that symbol is meant only
88924         for the rare case of programs that want all their backup file
88925         names to live within 8+3 limits, and dos.m4 doesn't address that.
88926         * modules/backupfile (Files): Remove m4/dos.m4.
88928 2011-02-24  Jim Meyering  <meyering@redhat.com>
88930         strstr: fix a bug whereby strstr would mistakenly return NULL
88931         * lib/str-two-way.h (two_way_short_needle): Correct off-by-one error
88932         in period calculation.
88933         (two_way_long_needle): Likewise.
88934         The original problem was reported by Mike Stump in
88935         http://thread.gmane.org/gmane.comp.sysutils.autoconf.bugs/7834
88936         Ralf Wildenhues provided the short needle and haystack.
88937         * tests/test-strstr.c: Add Ralf's test case to trigger the bug.
88938         Add a more involved test to trigger the bug in two_way_long_needle.
88940 2011-02-24  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
88942         gnulib-tool: remove use of bold display in help screen
88943         * gnulib-tool (func_usage): Do not use bold display anymore in the
88944         help screen.  That was just meant to be a temporary emphasis for a
88945         backward-incompatible change.
88947 2011-02-23  Bruno Haible  <bruno@clisp.org>
88949         Fix misindentation of preprocessor directives.
88950         * lib/argp-namefrob.h: Reindent preprocessor directives.
88951         * lib/getopt_int.h (struct _getopt_data): Likewise.
88952         * lib/progreloc.c (maybe_executable, find_executable): Likewise.
88953         * lib/vasnprintf.c (decode_long_double): Likewise.
88954         * tests/test-argmatch.c: Insert blank lines, for clarity.
88955         * tests/test-exclude.c: Likewise.
88957 2011-02-22  Bruno Haible  <bruno@clisp.org>
88959         ioctl: Fix for MacOS X in 64-bit mode.
88960         * lib/ioctl.c (rpl_ioctl): Zero-extend, not sign-extend, the request
88961         value.
88962         Suggested by Eric Blake.
88963         Reported by Markus Gothe <nietzsche@lysator.liu.se>.
88965 2011-02-22  Jim Meyering  <meyering@redhat.com>
88967         maint: sc_cpp_indent_check: remove the "only in lib/" restriction
88968         * Makefile (sc_cpp_indent_check): Don't limit the check to files
88969         in lib/.
88971 2011-02-22  Eric Blake  <eblake@redhat.com>
88973         maint: avoid any CDPATH issue
88974         * Makefile (sc_cpp_indent_check): Anchor cd argument.
88976         maint: adjust cpp indentation for my modules, as well
88977         * Makefile (sc_cpp_indent_check): Add my name.
88978         * lib/fbufmode.c: Filter through cppi.
88979         * lib/fpurge.c: Likewise.
88980         * lib/freadable.c: Likewise.
88981         * lib/freading.c: Likewise.
88982         * lib/fwritable.c: Likewise.
88983         * lib/fwriting.c: Likewise.
88984         * lib/sigaction.c: Likewise.
88986 2011-02-22  Jim Meyering  <meyering@redhat.com>
88988         maint: adjust cpp indentation to reflect nesting depth
88989         I.e., in a block of code that begins with an unnested "#if",
88990         put one space between the "#" in column 1 and following token.
88991         For example,
88992         -#include <sys/vfs.h>
88993         +# include <sys/vfs.h>
88994         Do this only in .c files that are part of a module I maintain.
88995         * lib/linkat.c: Filter through cppi.
88996         * lib/nanosleep.c: Likewise.
88997         * lib/openat.c: Likewise.
88998         * lib/openat-die.c: Likewise.
88999         * lib/dup3.c: Likewise.
89000         * lib/fchownat.c: Likewise.
89001         * lib/flock.c: Likewise.
89002         * lib/fsync.c: Likewise.
89003         * lib/fts.c: Likewise.
89004         * lib/getpass.c: Likewise.
89005         * lib/gettimeofday.c: Likewise.
89006         * lib/userspec.c: Likewise.
89007         * Makefile (sc_cpp_indent_check): New rule, to check this.
89009 2011-02-22  Bruno Haible  <bruno@clisp.org>
89011         New module 'wctomb'.
89012         * lib/stdlib.in.h (wctomb): New declaration.
89013         * lib/wctomb.c: New file.
89014         * lib/wctomb-impl.h: New file.
89015         * m4/wctomb.m4: New file.
89016         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_WCTOMB,
89017         REPLACE_WCTOMB.
89018         * modules/stdlib (Makefile.am): Substitute GNULIB_WCTOMB,
89019         REPLACE_WCTOMB.
89020         * modules/wctomb: New file.
89021         * tests/test-stdlib-c++.cc: Test signature of wctomb.
89022         * doc/posix-functions/wctomb.texi: Mention the new module.
89023         * modules/wctob (Depends-on): Add wctomb.
89025 2011-02-22  Bruno Haible  <bruno@clisp.org>
89027         New module 'mbtowc'.
89028         * lib/stdlib.in.h (mbtowc): New declaration.
89029         * lib/mbtowc.c: New file.
89030         * lib/mbtowc-impl.h: New file, from libutf8 with modifications.
89031         * m4/mbtowc.m4: New file.
89032         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_MBTOWC,
89033         REPLACE_MBTOWC.
89034         * modules/stdlib (Makefile.am): Substitute GNULIB_MBTOWC,
89035         REPLACE_MBTOWC.
89036         * modules/mbtowc: New file.
89037         * tests/test-stdlib-c++.cc: Test signature of mbtowc.
89038         * doc/posix-functions/mbtowc.texi: Mention the new module.
89039         * modules/btowc (Depends-on): Add mbtowc.
89041 2011-02-22  Bruno Haible  <bruno@clisp.org>
89043         wcrtomb: Add more tests for native Windows platforms.
89044         * tests/test-wcrtomb-w32-1.sh: New file.
89045         * tests/test-wcrtomb-w32-2.sh: New file.
89046         * tests/test-wcrtomb-w32-3.sh: New file.
89047         * tests/test-wcrtomb-w32-4.sh: New file.
89048         * tests/test-wcrtomb-w32-5.sh: New file.
89049         * tests/test-wcrtomb-w32.c: New file.
89050         * modules/wcrtomb-tests (Files): Add them.
89051         (Makefile.am): Arrange to run these tests.
89052         * tests/test-wcrtomb-w32-6.sh: New file, currently unused.
89053         * tests/test-wcrtomb-w32-7.sh: New file, currently unused.
89055 2011-02-20  Bruno Haible  <bruno@clisp.org>
89057         wcrtomb: Enhance test.
89058         * tests/test-wcrtomb.c (main): Add test against bug with NULL argument.
89060 2011-02-20  Bruno Haible  <bruno@clisp.org>
89062         mbrtowc: Tiny optimization.
89063         * lib/mbrtowc.c (mbrtowc): Delay pstate assignment until it is needed.
89065 2011-02-20  Jim Meyering  <meyering@redhat.com>
89067         test-exclude.c: remove unmatched #endif
89068         * tests/test-exclude.c: Remove stray #endif, left over from
89069         the change of a week ago.
89071 2011-02-19  Jim Meyering  <meyering@redhat.com>
89073         git-version-gen: skip "-dirty" check when appropriate
89074         * build-aux/git-version-gen: Don't run any git commands when the
89075         version string comes from .tarball-version.  Prior to this, we
89076         would run git update-index --refresh even from a just-unpacked
89077         tarball directory, and that could affect a .git/ directory in a
89078         parent of the build directory.  Reported by Mike Frysinger.
89080 2011-02-19  Bruno Haible  <bruno@clisp.org>
89082         unictype/property-byname: Reduce the size of the 'data' segment.
89083         * lib/unictype/pr_byname.gperf: Add gperf option '%pic'.
89085 2011-02-19  Bruno Haible  <bruno@clisp.org>
89087         unictype/scripts: Reduce the size of the 'data' segment.
89088         * lib/gen-uni-tables.c (output_scripts_byname): Emit gperf option
89089         '%pic'.
89090         * lib/unictype/scripts_byname.gperf: Regenerated.
89092 2011-02-19  Bruno Haible  <bruno@clisp.org>
89094         stdint: Update documentation.
89095         * doc/posix-headers/stdint.texi: Mention WCHAR_MIN, WCHAR_MAX problem.
89097 2011-02-18  Paul Eggert  <eggert@cs.ucla.edu>
89099         stdint: omit redundant check for wchar.h
89100         * m4/stdint.m4 (gl_STDINT_H): The earlier part of this macro now
89101         always tests whether wchar.h exists, so remove the now-redundant test.
89103 2011-02-18  Bruno Haible  <bruno@clisp.org>
89105         stdint: Cut dependency to module 'wchar'.
89106         * lib/stdint.in.h: Include wchar.h only when HAVE_WCHAR_H is 1. Also
89107         include the necessary prerequisites.
89108         * m4/stdint.m4 (gl_STDINT_H): Test whether wchar.h exists.
89109         * modules/stdint (Depends-on): Remove wchar.
89110         (Makefile.am): Substitute HAVE_WCHAR_H.
89111         This reverts part of a 2007-01-06 commit. Reported by Paul Eggert.
89113 2011-02-18  Eric Blake  <eblake@redhat.com>
89115         longlong: skip, rather than fail, on cross-compilation
89116         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Avoid aborting configure
89117         when cross-compiling; regression from 2011-02-16.
89119 2011-02-17  Paul Eggert  <eggert@cs.ucla.edu>
89121         * NEWS: Mention 2011-02-08 change to stdlib.
89123 2011-02-17  Bruno Haible  <bruno@clisp.org>
89125         getloadavg: Add comments about platforms.
89126         * m4/getloadavg.m4: Add comment.
89127         * lib/getloadavg.c: Likewise.
89129 2011-02-17  Bruno Haible  <bruno@clisp.org>
89131         getloadavg: Fix link error on Solaris 2.6.
89132         * modules/getloadavg (Link): New section.
89133         * modules/getloadavg-tests (Makefile.am): Use GETLOADAVG_LIBS for
89134         linking test-getloadavg.
89135         * doc/glibc-functions/getloadavg.texi: Mention that Solaris 2.6 lacks
89136         getloadavg.
89138 2011-02-17  Paul Eggert  <eggert@cs.ucla.edu>
89140         * lib/getloadavg.c (getloadavg) [sgi]: Make ldav_off of type ptrdiff_t.
89141         It was 'int', but this doesn't match the IRIX 6.5 manual.
89142         Suggested by Bruno Haible in
89143         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00207.html>.
89145 2011-02-17  Bruno Haible  <bruno@clisp.org>
89147         havelib: Fix comments.
89148         * m4/lib-link.m4 (AC_LIB_RPATH): Update comments after 2007-01-02
89149         change.
89151 2011-02-17  Bruno Haible  <bruno@clisp.org>
89153         havelib: Update config.rpath.
89154         * build-aux/config.rpath: Update to match libtool.m4 from libtool-2.4.
89156 2011-02-17  Bruno Haible  <bruno@clisp.org>
89158         getloadavg test: Add some plausibility checks.
89159         * tests/test-getloadavg.c (check_avg): Print a warning when the value
89160         is improbable.
89162 2011-02-16  Eric Blake  <eblake@redhat.com>
89164         maintainer-makefile: make syntax-check a no-op from tarballs
89165         * top/maint.mk (no-vc-detected): New rule.
89166         (local-checks-available): Use it to avoid hanging if someone tries
89167         'make syntax-check' from a tarball.  Also append to any non-syntax
89168         checks already defined in cfg.mk.
89170 2011-02-16  Paul Eggert  <eggert@cs.ucla.edu>
89172         longlong: tune, particularly for common case of c99
89174         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Don't bother compiling
89175         or running anything if c99, or if unsigned long long int does not
89176         work.  In either case, we know the answer without further tests.
89177         Do not compile _AC_TYPE_LONG_LONG_SNIPPET twice.  Instead, compile
89178         it at most once, and use its results for both long long int and
89179         unsigned long long int.  This is more likely to be efficient in
89180         the common case where the program wants to check for both long
89181         long int and unsigned long long int.
89182         (AC_TYPE_UNSIGNED_LONG_LONG_INT): Don't bother compiling if c99,
89183         since the answer is already known.
89185 2011-02-15  Paul Eggert  <eggert@cs.ucla.edu>
89187         getloadavg: set errno
89188         * lib/getloadavg.c: Set errno when returning -1.  If no other
89189         error number looks appropriate, set it to ENOSYS if the getloadavg
89190         looks like it can't possibly ever work, ENOTSUP otherwise.
89191         Suggested by Bruno Haible in
89192         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00187.html>.
89194         getloadavg: trim unused parts and speed up 'configure'
89195         * NEWS: Document this.
89196         * lib/getloadavg.c: Ignore HAVE_GETLOADAVG; this file is now
89197         always compiled if getloadavg is absent.
89198         Move test code to ...
89199         * tests/test-getloadavg.c: New file, containing previous
89200         contents of test from lib/getloadavg.c.  It also contains
89201         suggestions by Bruno Haible in
89202         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00186.html>.
89203         * modules/getloadavg-tests: New file.
89204         * m4/getloadavg.m4 (gl_GETLOADAVG): Do not check for getloadavg twice.
89205         Do tests in the same order as they're needed for getloadavg.c.
89206         Omit setgid-related tests that generate symbols KMEM_GROUP,
89207         NEET_SETGID, GETLOADAVG_PRIVILEGED; nobody seems to use those any more.
89208         Do only the tests that are needed to see whether the system has
89209         getloadavg, moving the other tests into ...
89210         (gl_PREREQ_GETLOADAVG): ... here.  Do not define obsolete symbol
89211         NLIST_NAME_UNION; nobody should be using it.  Do not define
89212         symbols C_GETLOADAVG and HAVE_GETLOADAVG; they're no longer
89213         relevant, as the user of this module shouldn't care how getloadavg
89214         is implemented.
89216         getloadavg: omit unused var
89217         * lib/getloadavg.c (getloadavg): Omit unused local variable.
89219 2011-02-15  Jim Meyering  <meyering@redhat.com>
89221         doc: update users.txt
89222         * users.txt: Update iwhd's URL.
89224 2011-02-13  Bruno Haible  <bruno@clisp.org>
89226         Consistent macro naming for macros that use GCC __attribute__.
89227         * lib/di-set.h (_GL_ATTRIBUTE_NONNULL): Renamed from
89228         _ATTRIBUTE_NONNULL_.
89229         * lib/ino-map.h (_GL_ATTRIBUTE_NONNULL): Likewise.
89230         * lib/hash.h (_GL_ATTRIBUTE_WUR): Renamed from ATTRIBUTE_WUR.
89231         * lib/ignore-value.h (_GL_ATTRIBUTE_DEPRECATED): Renamed from
89232         ATTRIBUTE_DEPRECATED.
89233         * lib/openat.h (_GL_ATTRIBUTE_NORETURN): Renamed from
89234         ATTRIBUTE_NORETURN.
89235         * lib/sigpipe-die.h (_GL_ATTRIBUTE_NORETURN): Likewise.
89236         * lib/xmemdup0.h (_GL_ATTRIBUTE_NORETURN): Likewise.
89237         * lib/xstrtol.h (_GL_ATTRIBUTE_NORETURN): Likewise.
89238         * lib/xalloc.h (_GL_ATTRIBUTE_NORETURN): Likewise.
89239         (_GL_ATTRIBUTE_MALLOC): Renamed from ATTRIBUTE_MALLOC.
89240         (_GL_ATTRIBUTE_ALLOC_SIZE): Renamed from ATTRIBUTE_ALLOC_SIZE.
89241         * lib/version-etc.h (_GL_ATTRIBUTE_SENTINEL): Renamed from
89242         ATTRIBUTE_SENTINEL.
89243         * lib/safe-alloc.h (_GL_ATTRIBUTE_RETURN_CHECK): Renamed from
89244         ATTRIBUTE_RETURN_CHECK.
89245         * tests/test-ignore-value.c (_GL_ATTRIBUTE_RETURN_CHECK): Likewise.
89246         * tests/test-argmatch.c (_GL_ATTRIBUTE_NORETURN): Renamed from
89247         ATTRIBUTE_NORETURN.
89248         * tests/test-exclude.c (_GL_ATTRIBUTE_NORETURN): Likewise.
89249         Reported by Paul Eggert.
89251 2011-02-13  Bruno Haible  <bruno@clisp.org>
89253         Don't interfere with a program's definition of __attribute__.
89254         * lib/argp.h (__attribute__): Remove definition.
89255         (_GL_ATTRIBUTE_FORMAT): New macro.
89256         (argp_error, __argp_error, argp_failure, __argp_failure): Use it.
89257         * lib/argp-fmtstream.h (__attribute__): Remove definition.
89258         (_GL_ATTRIBUTE_FORMAT): New macro.
89259         (__argp_fmtstream_printf, argp_fmtstream_printf): Use it.
89260         * lib/argp-help.c (hol_entry_long_iterate): Use __attribute__ only for
89261         GCC 3 or newer.
89262         * lib/error.h (__attribute__): Remove definition.
89263         (_GL_ATTRIBUTE_FORMAT): New macro.
89264         (error, error_at_line): Use it.
89265         * lib/hash.h (__attribute__): Remove definition.
89266         (ATTRIBUTE_WUR): Update definition. Define always.
89267         * lib/openat.h (__attribute__): Remove definition.
89268         (ATTRIBUTE_NORETURN): Update definition. Define always.
89269         * lib/sigpipe-die.h (__attribute__): Remove definition.
89270         (ATTRIBUTE_NORETURN): Update definition. Define always.
89271         * lib/vasnprintf.h (__attribute__): Remove definition.
89272         (_GL_ATTRIBUTE_FORMAT): New macro.
89273         (asnprintf, vasnprintf): Use it.
89274         * lib/xalloc.h (__attribute__): Remove definition.
89275         (ATTRIBUTE_NORETURN): Update definition. Define always.
89276         (ATTRIBUTE_MALLOC, ATTRIBUTE_ALLOC_SIZE): Define always.
89277         * lib/xmemdup0.h (__attribute__): Remove definition.
89278         (ATTRIBUTE_NORETURN): Update definition. Define always.
89279         * lib/xprintf.h (__attribute__): Remove definition.
89280         (_GL_ATTRIBUTE_FORMAT): New macro.
89281         (xprintf, xvprintf, xfprintf, xvfprintf): Use it.
89282         * lib/xstrtol.h (__attribute__): Remove definition.
89283         (ATTRIBUTE_NORETURN): Update definition. Define always.
89284         * lib/xvasprintf.h (__attribute__): Remove definition.
89285         (_GL_ATTRIBUTE_FORMAT): New macro.
89286         (xasprintf, xvasprintf): Use it.
89287         * tests/test-argmatch.c (__attribute__): Remove definition.
89288         (ATTRIBUTE_NORETURN): Update definition. Define always.
89289         * tests/test-exclude.c (__attribute__): Remove definition.
89290         (ATTRIBUTE_NORETURN): Update definition. Define always.
89291         Reported by Paul Eggert.
89293 2011-02-13  Bruno Haible  <bruno@clisp.org>
89295         mbrtowc: Add more tests for native Windows platforms.
89296         * tests/test-mbrtowc-w32-1.sh: New file.
89297         * tests/test-mbrtowc-w32-2.sh: New file.
89298         * tests/test-mbrtowc-w32-3.sh: New file.
89299         * tests/test-mbrtowc-w32-4.sh: New file.
89300         * tests/test-mbrtowc-w32-5.sh: New file.
89301         * tests/test-mbrtowc-w32.c: New file.
89302         * modules/mbrtowc-tests (Files): Add them.
89303         (Makefile.am): Arrange to run these tests.
89304         * tests/test-mbrtowc-w32-6.sh: New file, currently unused.
89305         * tests/test-mbrtowc-w32-7.sh: New file, currently unused.
89307 2011-02-13  Bruno Haible  <bruno@clisp.org>
89309         mbrtowc: Work around native Windows bug.
89310         * m4/mbrtowc.m4 (gl_MBRTOWC_RETVAL): Detect native Windows bug. Use the
89311         guess when no suitable locale for testing was found.
89312         * doc/posix-functions/mbrtowc.texi: Mention the native Windows bug.
89314 2011-02-13  Bruno Haible  <bruno@clisp.org>
89316         mbsinit: Work around mingw bug.
89317         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Replace mbsinit also on mingw.
89318         * lib/mbsinit.c (mbsinit): Provide an alternate definition for native
89319         Windows.
89320         * doc/posix-functions/mbsinit.texi: Mention the mingw bug.
89322 2011-02-13  Bruno Haible  <bruno@clisp.org>
89324         mbsinit: Don't crash for a NULL argument.
89325         * lib/mbsinit.c (mbsinit): When the argument is NULL, return 1.
89326         * tests/test-mbsinit.c (mbsinit): Check this behaviour.
89328 2011-02-13  Bruno Haible  <bruno@clisp.org>
89330         Don't interfere with a program's definition of __attribute__.
89331         * lib/stdio.in.h (__attribute__): Remove definition.
89332         (_GL_ATTRIBUTE_FORMAT, _GL_ATTRIBUTE_FORMAT_PRINTF): New macros.
89333         (dprintf, fprintf, obstack_printf, obstack_printf, obstack_vprintf,
89334         printf, snprintf, sprintf, asprintf, vasprintf, vdprintf, vfprintf,
89335         vsnprintf, vsprintf): Use _GL_ATTRIBUTE_FORMAT_PRINTF.
89336         * lib/string.in.h (__attribute__): Remove definition.
89337         Reported by Paul Eggert.
89339 2011-02-12  Paul Eggert  <eggert@cs.ucla.edu>
89341         stdlib: don't get in the way of non-GCC __attribute__
89342         See thread starting at
89343         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00161.html>.
89344         Revert previous stdlib change, installing the following instead:
89345         * lib/stdlib.in.h (__attribute__): Remove.  We do not want
89346         to get in the way of a non-GCC compiler that supports __attribute__.
89347         (_GL_ATTRIBUTE_RETURN): New macro.
89348         (_Exit): Use it instead of __attribute__.
89350 2011-02-12  Bruno Haible  <bruno@clisp.org>
89352         quotearg test: Avoid test failure on mingw.
89353         * tests/test-quotearg.sh: Convert the locale identifier from native
89354         Windows syntax to Unix syntax.
89356 2011-02-12  Bruno Haible  <bruno@clisp.org>
89358         setlocale: Prefer gnulib's override over libintl's override.
89359         * lib/locale.in.h (GNULIB_defined_setlocale): New macro.
89360         * lib/gettext.h (setlocale): Redefine to rpl_setlocale if
89361         GNULIB_defined_setlocale is set.
89363 2011-02-12  Paul Eggert  <eggert@cs.ucla.edu>
89365         stdlib: support non-GCC __attribute__
89367         Fix a serious and tricky problem encountered when attempting to
89368         add the getloadavg module to Emacs.  Emacs worked fine on RHEL
89369         5.5, but it crashed due to memory corruption on Solaris 10 with
89370         Sun C 5.11.  Emacs normally ORs 3-bit tags into their low-order
89371         bits that are otherwise zero.  This tagging is optional inside
89372         Emacs but is preferred and is used when __attribute__ ((__aligned
89373         (8))) works, as it does with both recent-enough GCC and with Sun C
89374         5.11.  However, Sun C 5.11 is not GCC and does not #define
89375         __GNUC__ and __GNUC_MINOR__.
89377         When I added the getloadavg module to Emacs, it brought in
89378         stdlib.in.h, which contained this fragment:
89380            #ifndef __attribute__
89381            # if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 8)
89382            #  define __attribute__(Spec)   /* empty */
89383            # endif
89384            #endif
89386         When files that include <stdlib.h> were compiled with Sun C 5.11,
89387         the above code disabled __attribute__ ((__aligned (8))), which
89388         caused variables to not be properly aligned, which eventually led
89389         to the pointer corruption mentioned above.  (This was a bit hard
89390         to diagnose, unfortunately.)
89392         Several "#define __attribute__(X) /* empty */" code snippets need
89393         to be eradicated from Gnulib to work with non-GCC compilers that
89394         support __attribute__.  The Autoconf way to do this is to test for
89395         each kind of attribute that we want support for, and selectively
89396         enable that in source code.
89398         Fix this problem just for stdlib.h, by adding a test for the
89399         __noreturn__ attribute, and change stdlib.in.h to use that test
89400         when needed.  This technique can be easily generalized to the
89401         other *.in.h files and attributes, and a similar technique can be
89402         used for *.h and *.c files.  This patch is enough to solve the
89403         problem for Emacs + getloadavg, and I thought I'd publish it for
89404         feedback before undertaking further, similar fixes in other
89405         modules.
89407         This patch does not arrange to #define HAVE_ATTRIBUTE_NORETURN
89408         because it's not needed for stdlib.h.  It merely substitutes the
89409         value directly into stdlib.h.  We may well need to #define it, or
89410         similar symbols, for other modules, but it's nice to also have an
89411         option to not #define it for applications like Emacs that do not
89412         need it.
89414         * lib/stdlib.in.h (__attribute__): Do not #define.
89415         (_GL_ATTRIBUTE_NORETURN): New macro, which in stdlib.h needs to
89416         be defined only if the _Exit module is also used.
89417         * m4/_Exit.m4 (gl_FUNC__EXIT): Require gl_ATTRIBUTE_NORETURN.
89418         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Subst
89419         HAVE_ATTRIBUTE_NORETURN and default it to 1, its value on GNU
89420         platforms.
89421         * modules/_Exit (Files): Add m4/attribute.m4.
89422         * modules/stdlib (Makefile.am): Substitute HAVE_ATTRIBUTE_NORETURN.
89423         * m4/attribute.m4: New file.
89425 2011-02-12  Bruno Haible  <bruno@clisp.org>
89427         wcsrtombs: Work around bug on native Windows.
89428         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_NULL): Test against mingw bug.
89429         * lib/wcsrtombs.c (rpl_wcsrtombs): When dest is NULL, pass SIZE_MAX
89430         instead of len.
89431         * doc/posix-functions/wcsrtombs.texi: Document mingw bug.
89433 2011-02-12  Bruno Haible  <bruno@clisp.org>
89435         mbsrtowcs: Work around bug on native Windows.
89436         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Require gt_LOCALE_FR. Test
89437         against mingw bug.
89438         * doc/posix-functions/mbsrtowcs.texi: Document mingw bug.
89440 2011-02-12  Bruno Haible  <bruno@clisp.org>
89442         Avoid setlocale bugs in tests.
89443         * modules/btowc (Dependencies): Add setlocale.
89444         * modules/c-strcase (Dependencies): Likewise.
89445         * modules/mbmemcasecmp (Dependencies): Likewise.
89446         * modules/mbmemcasecoll (Dependencies): Likewise.
89447         * modules/mbrtowc (Dependencies): Likewise.
89448         * modules/mbscasecmp (Dependencies): Likewise.
89449         * modules/mbscasestr (Dependencies): Likewise.
89450         * modules/mbschr (Dependencies): Likewise.
89451         * modules/mbscspn (Dependencies): Likewise.
89452         * modules/mbsinit (Dependencies): Likewise.
89453         * modules/mbsncasecmp (Dependencies): Likewise.
89454         * modules/mbsnrtowcs (Dependencies): Likewise.
89455         * modules/mbspbrk (Dependencies): Likewise.
89456         * modules/mbspcasecmp (Dependencies): Likewise.
89457         * modules/mbsrchr (Dependencies): Likewise.
89458         * modules/mbsrtowcs (Dependencies): Likewise.
89459         * modules/mbsspn (Dependencies): Likewise.
89460         * modules/mbsstr (Dependencies): Likewise.
89461         * modules/nl_langinfo (Dependencies): Likewise.
89462         * modules/quotearg (Dependencies): Likewise.
89463         * modules/unicase/locale-language (Dependencies): Likewise.
89464         * modules/unicase/ulc-casecmp (Dependencies): Likewise.
89465         * modules/unicase/ulc-casecoll (Dependencies): Likewise.
89466         * modules/unigbrk/ulc-grapheme-breaks (Dependencies): Likewise.
89467         * modules/unistdio/u8-vasnprintf (Dependencies): Likewise.
89468         * modules/unistdio/u16-vasnprintf (Dependencies): Likewise.
89469         * modules/unistdio/u32-vasnprintf (Dependencies): Likewise.
89470         * modules/unistdio/ulc-vasnprintf (Dependencies): Likewise.
89471         * modules/uniwbrk/ulc-wordbreaks (Dependencies): Likewise.
89472         * modules/vasnprintf-posix (Dependencies): Likewise.
89473         * modules/wcrtomb (Dependencies): Likewise.
89474         * modules/wcsnrtombs (Dependencies): Likewise.
89475         * modules/wcsrtombs (Dependencies): Likewise.
89477 2011-02-12  Bruno Haible  <bruno@clisp.org>
89479         setlocale: Workaround native Windows bug.
89480         * lib/setlocale.c (rpl_setlocale): On native Windows, when setlocale
89481         succeeds but sets LC_CTYPE to "C", report a failure.
89482         * tests/test-setlocale2.sh: New file.
89483         * tests/test-setlocale2.c: New file.
89484         * modules/setlocale-tests (Files): Add the new files.
89485         (Makefile.am): Enable test-setlocale2.sh test.
89486         * doc/posix-functions/setlocale.texi: Mention workaround.
89488 2011-02-11  Bruno Haible  <bruno@clisp.org>
89490         Tests for module 'setlocale'.
89491         * modules/setlocale-tests: New file.
89492         * tests/test-setlocale1.sh: New file.
89493         * tests/test-setlocale1.c: New file.
89495         New module 'setlocale'.
89496         * lib/locale.in.h (setlocale): New declaration.
89497         * lib/setlocale.c: New file, based on
89498         gettext/gettext-runtime/intl/setlocale.c.
89499         * m4/setlocale.m4: New file.
89500         * m4/locale_h.m4 (gl_LOCALE_H): Test whether setlocale is declared.
89501         (gl_LOCALE_H_DEFAULTS): Initialize GNULIB_SETLOCALE, REPLACE_SETLOCALE.
89502         * modules/locale (Makefile.am): Substitute GNULIB_SETLOCALE,
89503         REPLACE_SETLOCALE.
89504         * modules/setlocale: New file.
89505         * tests/test-locale-c++.cc: Test the declaration of setlocale.
89506         * doc/posix-functions/setlocale.texi: Mention the new module.
89508 2011-02-11  Bruno Haible  <bruno@clisp.org>
89510         Prepare for locale dependent tests on mingw.
89511         * m4/locale-ar.m4 (gt_LOCALE_AR): On native Windows, don't try "ar"
89512         because it has the wrong locale encoding.
89513         * m4/locale-fr.m4 (gt_LOCALE_FR): On native Windows, try
89514         French_France.1252 instead of "fr".
89515         (gt_LOCALE_FR_UTF8): On native Windows, try French_France.65001.
89516         * m4/locale-ja.m4 (gt_LOCALE_JA): On native Windows, don't try "ja"
89517         because it has the wrong locale encoding.
89518         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Require AC_CANONICAL_HOST. On
89519         native Windows, try Turkish_Turkey.65001.
89520         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): On native Windows, try
89521         Chinese_China.54936.
89523         Prepare for locale dependent tests on mingw.
89524         * m4/locale-ar.m4 (gt_LOCALE_AR): On native Windows, call setlocale
89525         differently.
89526         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
89527         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
89528         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
89529         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
89531 2011-02-11  Eric Blake  <eblake@redhat.com>
89533         strptime: avoid compiler warnings
89534         * lib/strptime.c (__strptime_internal) [!_NL_CURRENT]: Avoid
89535         compiler warnings about dead code.
89536         Reported by Daniel P. Berrange.
89538 2011-02-11  Thien-Thi Nguyen  <ttn@gnuvola.org>
89540         doc: update users.txt
89541         * users.txt: Add rcs.
89543 2011-02-10  John W. Eaton  <jwe@gnu.org>
89545         doc: update users.txt
89546         * users.txt: Add octave.
89548 2011-02-10  Jim Meyering  <meyering@redhat.com>
89550         doc: update users.txt
89551         * users.txt: Add iwhd.
89553 2011-02-09  Bruno Haible  <bruno@clisp.org>
89555         gnulib-tool: Make copyright notice adjustment more robust.
89556         * gnulib-tool (func_import): In sed_transform_main_lib_file,
89557         sed_transform_build_aux_file, sed_transform_testsrelated_lib_file,
89558         allow a line break to occur after "GNU" in "GNU [Lesser] General Public
89559         License".
89560         Reported by Glenn Morris <rgm@gnu.org> via Paul Eggert.
89562 2011-02-06  Bruno Haible  <bruno@clisp.org>
89564         New module 'towctrans'.
89565         * modules/towctrans: New file.
89566         * lib/wctype.in.h (towctrans): New declaration.
89567         * lib/towctrans.c: New file.
89568         * lib/towctrans-impl.h: New file.
89569         * m4/towctrans.m4: New file.
89570         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether towctrans is declared.
89571         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_TOWCTRANS.
89572         * modules/wctype-h (Makefile.am): Substitute GNULIB_TOWCTRANS.
89573         * tests/test-wctype-h-c++.cc: Test the declaration of towctrans.
89574         * doc/posix-functions/towctrans.texi: Mention the new module.
89576 2011-02-06  Bruno Haible  <bruno@clisp.org>
89578         New module 'wctrans'.
89579         * modules/wctrans: New file.
89580         * lib/wctype.in.h (wctrans): New declaration.
89581         * lib/wctrans.c: New file.
89582         * lib/wctrans-impl.h: New file.
89583         * m4/wctrans.m4: New file.
89584         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether wctrans is declared.
89585         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_WCTRANS.
89586         * modules/wctype-h (Makefile.am): Substitute GNULIB_WCTRANS.
89587         * tests/test-wctype-h-c++.cc: Test the declaration of wctrans.
89588         * doc/posix-functions/wctrans.texi: Mention the new module.
89590 2011-02-06  Bruno Haible  <bruno@clisp.org>
89592         New module 'iswctype'.
89593         * modules/iswctype: New file.
89594         * lib/wctype.in.h (iswctype): New declaration.
89595         * lib/iswctype.c: New file.
89596         * lib/iswctype-impl.h: New file.
89597         * m4/iswctype.m4: New file.
89598         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether iswctype is declared.
89599         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_ISWCTYPE.
89600         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWCTYPE.
89601         * tests/test-wctype-h-c++.cc: Test the declaration of iswctype.
89602         * doc/posix-functions/iswctype.texi: Mention the new module and the
89603         HP-UX 11.00 problem.
89605 2011-02-06  Bruno Haible  <bruno@clisp.org>
89607         New module 'wctype'.
89608         * modules/wctype: Change to represent the wctype() substitute.
89609         * lib/wctype.in.h (wctype): New declaration.
89610         * lib/wctype.c: New file.
89611         * lib/wctype-impl.h: New file.
89612         * m4/wctype.m4: New file.
89613         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether wctype is declared.
89614         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_WCTYPE.
89615         * modules/wctype-h (Makefile.am): Substitute GNULIB_WCTYPE.
89616         * tests/test-wctype-h-c++.cc: Test the declaration of wctype.
89617         * doc/posix-functions/wctype.texi: Mention the new module and the
89618         HP-UX 11.00 problem.
89620 2011-02-06  Bruno Haible  <bruno@clisp.org>
89622         wctype-h: Ensure wctype_t and wctrans_t are defined.
89623         * lib/wctype.in.h (wctype_t, wctrans_t): New type declarations.
89624         * m4/wctype_h.m4 (gl_WCTYPE_H): Determine HAVE_WCTYPE_T, HAVE_WCTRANS_T.
89625         (gl_WCTYPE_H_DEFAULTS): Initialize HAVE_WCTYPE_T, HAVE_WCTRANS_T.
89626         * modules/wctype-h (Makefile.am): Substitute HAVE_WCTYPE_T,
89627         HAVE_WCTRANS_T.
89628         * tests/test-wctype-h.c: Check that wctype_t and wctrans_t are defined.
89630 2011-02-09  Paul Eggert  <eggert@cs.ucla.edu>
89632         flock: fix license typo
89634         * lib/flock.c: Fix typo in license.  One of the "Lesser"s was
89635         omitted.
89637 2011-02-08  Bruno Haible  <bruno@clisp.org>
89639         Split large sed scripts, for HP-UX sed.
89640         * modules/math (Makefile.am): Split sed scripts around 50 sed commands,
89641         to avoid HP-UX limit of 99 commands, in the near future.
89642         * modules/stdlib (Makefile.am): Likewise.
89643         * modules/unistd (Makefile.am): Likewise.
89644         * modules/wchar (Makefile.am): Likewise.
89645         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
89646         Suggestion by Ralf Wildenhues <Ralf.Wildenhues@gmx.de> in
89647         <http://lists.gnu.org/r/bug-gnulib/2010-01/msg00216.html>.
89649 2011-02-08  Paul Eggert  <eggert@cs.ucla.edu>
89650             Bruno Haible  <bruno@clisp.org>
89652         stdlib: improve random_r modularization
89653         * lib/stdlib.in.h: Encapsulate all the stuff having to do with
89654         random_r inside "#if @GNULIB_RANDOM_R@", so that it's clearer that
89655         you also need the random_r module to get this material right.
89656         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Move check for random.h here ...
89657         * m4/stdlib_h.m4 (gl_STDLIB_H): ... from here.
89658         (gl_STDLIB_H_DEFAULTS): Default HAVE_RANDOM_H to 1, and AC_SUBST it.
89660 2011-02-08  Paul Eggert  <eggert@cs.ucla.edu>
89662         stdlib: don't depend on stdint
89663         * lib/stdlib.in.h: Don't include <stdint.h> merely because
89664         GNULIB_POSIXCHECK is defined.  GNULIB_POSIXCHECK seems to
89665         be independent of whether stdint.h is needed.
89666         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Check for struct random_data
89667         here, instead of ...
89668         * m4/stdlib_h.m4 (gl_STDLIB_H): ... here.  Applications that need
89669         struct random_data should be using the random_r module, not just
89670         the stdlib module (which wouldn't make sense: what package needs
89671         just struct random_data without also needing random_r?).
89672         * modules/stdlib (Depends-on): Remove stdint.
89674         getloadavg: don't depend on c-strtod, cloexec, fcntl-safer
89675         See the thread rooted at
89676         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00090.html>.
89677         * lib/getloadavg.c: Do not include c-strtod.h, cloexec.h, or fcntl--.h.
89678         Include <fcntl.h> only if (defined __linux__ || defined __CYGWIN__
89679         || defined SUNOS_5 || (defined LOAD_AVE_TYPE && !  defined
89680         __VMS)); previously it was always included (via fcntl--.h).
89681         (getloadavg): Do not use c_strtod.  Instead, approximate it by
89682         hand; this is good enough for load averages.  Also, do not use
89683         set_cloexec_flag; instead, use the O_CLOEXEC and F_DUPFD_CLOEXEC
89684         flags directly if available and don't bother otherwise.  (Packages
89685         that need the extra reliability should use the modules that define
89686         these flags on older platforms that lack them.)
89687         * modules/getloadavg (Depends-on): Remove c-strtod, cloexec,
89688         fcntl-safer.
89690 2011-02-08  Jim Meyering  <meyering@redhat.com>
89692         di-set.h, ino-map.h: add multiple-inclusion guard
89693         Technically, the guard is required only for ino-map.h, due to its
89694         INO_MAP_INSERT_FAILURE definition, but do both for consistency.
89695         * lib/di-set.h: Add file-spanning #ifndef _GL_DI_SET_H.
89696         * lib/ino-map.h: Likewise.
89698 2011-02-06  Bruno Haible  <bruno@clisp.org>
89700         iswblank: Ensure declaration on glibc systems.
89701         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Require gl_USE_SYSTEM_EXTENSIONS.
89702         * modules/iswblank (Dependencies): Add 'extensions'.
89703         * doc/posix-functions/iswblank.texi: Document the glibc problem.
89705 2011-02-06  Bruno Haible  <bruno@clisp.org>
89707         New module 'iswblank'.
89708         * lib/wctype.in.h (iswblank): Don't declare if GNULIB_ISWBLANK is 0.
89709         * modules/iswblank: New file.
89710         * modules/wctype-h (Files): Remove lib/iswblank.c.
89711         (Makefile.am): Substitute GNULIB_ISWBLANK.
89712         * m4/iswblank.m4: New file, partially extracted from m4/wctype_h.m4.
89713         * m4/wctype_h.m4 (gl_WCTYPE_MODULE_INDICATOR): New macro.
89714         (gl_WCTYPE_H_DEFAULTS): New macro.
89715         (gl_WCTYPE_H): Require it. Remove iswblank related code.
89716         * modules/iswblank-tests: New file.
89717         * tests/test-iswblank.c: New file, extraced from tests/test-wctype-h.c.
89718         * tests/test-wctype-h.c (main): Remove iswblank tests.
89719         * tests/test-wctype-h-c++.cc: Guard the signature test of iswblank.
89720         * doc/posix-functions/iswblank.texi: Mention module 'iswblank' instead
89721         of 'wctype-h'.
89722         * NEWS: Mention the change.
89723         * modules/mbchar (Depends-on): Add iswblank.
89725 2011-02-08  Bruno Haible  <bruno@clisp.org>
89727         di-set tests: Refactor.
89728         * tests/test-di-set.c: Include di-set.h early. Include macros.h. Drop
89729         unnecessary includes.
89730         (ASSERT): Remove macro.
89731         (main): Make C90 compliant by avoiding variable declaration after
89732         statement.
89733         * modules/di-set-tests (Files): Add tests/macros.h.
89735 2011-02-08  Bruno Haible  <bruno@clisp.org>
89737         ino-map tests: Refactor.
89738         * tests/test-ino-map.c: Include ino-map.h early. Include macros.h. Drop
89739         unnecessary includes.
89740         (ASSERT): Remove macro.
89741         (main): Make C90 compliant by avoiding variable declaration after
89742         statement.
89743         * modules/ino-map-tests (Files): Add tests/macros.h.
89745 2011-02-08  Jim Meyering  <meyering@redhat.com>
89747         di-set: add "const" to a cast
89748         * lib/di-set.c (di_set_insert): Cast hash_insert0 argument to
89749         "(void const *)", not "(void *)".  Spotted by Bruno Haible.
89751 2011-02-06  Bruno Haible  <bruno@clisp.org>
89753         Rename module 'wctype' to 'wctype-h'.
89754         * modules/wctype-h: Renamed from modules/wctype.
89755         * modules/wctype: Simplyfy to a redirection to 'wctype-h'.
89756         * modules/wctype-h-tests: Renamed from modules/wctype-tests.
89757         (Files, Depends-on, Makefile.am): Update.
89758         * modules/wctype-h-c++-tests: Renamed from modules/wctype-c++-tests.
89759         (Files, Makefile.am): Update.
89760         * tests/test-wctype-h.c: Renamed from tests/test-wctype.c.
89761         * tests/test-wctype-h-c++.cc: Renamed from tests/test-wctype-c++.cc.
89762         * doc/posix-headers/wctype.texi: Update.
89763         * doc/posix-functions/iswalnum.texi: Update.
89764         * doc/posix-functions/iswalpha.texi: Update.
89765         * doc/posix-functions/iswblank.texi: Update.
89766         * doc/posix-functions/iswcntrl.texi: Update.
89767         * doc/posix-functions/iswdigit.texi: Update.
89768         * doc/posix-functions/iswgraph.texi: Update.
89769         * doc/posix-functions/iswlower.texi: Update.
89770         * doc/posix-functions/iswprint.texi: Update.
89771         * doc/posix-functions/iswpunct.texi: Update.
89772         * doc/posix-functions/iswspace.texi: Update.
89773         * doc/posix-functions/iswupper.texi: Update.
89774         * doc/posix-functions/iswxdigit.texi: Update.
89775         * doc/posix-functions/towlower.texi: Update.
89776         * doc/posix-functions/towupper.texi: Update.
89777         * NEWS: Mention the change.
89778         * modules/fnmatch (Dependencies): Add wctype-h, remove wctype.
89779         * modules/mbchar (Dependencies): Likewise.
89780         * modules/mbswidth (Dependencies): Likewise.
89781         * modules/quotearg (Dependencies): Likewise.
89782         * modules/regex (Dependencies): Likewise.
89783         * modules/wcscasecmp (Dependencies): Likewise.
89784         * modules/wcsncasecmp (Dependencies): Likewise.
89785         * modules/wcwidth (Dependencies): Likewise.
89787 2011-02-06  Bruno Haible  <bruno@clisp.org>
89789         New module 'wcswidth'.
89790         * modules/wcswidth: New file.
89791         * lib/wchar.in.h (wcswidth): New declaration.
89792         * lib/wcswidth.c: New file.
89793         * lib/wcswidth-impl.h: New file, from libutf8 with modifications.
89794         * m4/wcswidth.m4: New file.
89795         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcswidth is declared.
89796         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSWIDTH, HAVE_WCSWIDTH,
89797         REPLACE_WCSWIDTH.
89798         * modules/wchar (Makefile.am): Substitute GNULIB_WCSWIDTH,
89799         HAVE_WCSWIDTH, REPLACE_WCSWIDTH.
89800         * tests/test-wchar-c++.cc: Test the declaration of wcswidth.
89801         * doc/posix-functions/wcswidth.texi: Mention the new module.
89803 2011-02-06  Bruno Haible  <bruno@clisp.org>
89805         New module 'wcstok'.
89806         * modules/wcstok: New file.
89807         * lib/wchar.in.h (wcstok): New declaration.
89808         * lib/wcstok.c: New file.
89809         * lib/wcstok-impl.h: New file, from libutf8 with modifications.
89810         * m4/wcstok.m4: New file.
89811         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcstok is declared.
89812         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSTOK, HAVE_WCSTOK.
89813         * modules/wchar (Makefile.am): Substitute GNULIB_WCSTOK, HAVE_WCSTOK.
89814         * tests/test-wchar-c++.cc: Test the declaration of wcstok.
89815         * doc/posix-functions/wcstok.texi: Mention the new module.
89817 2011-02-06  Bruno Haible  <bruno@clisp.org>
89819         New module 'wcsstr'.
89820         * modules/wcsstr: New file.
89821         * lib/wchar.in.h (wcsstr): New declaration.
89822         * lib/wcsstr.c: New file.
89823         * lib/wcsstr-impl.h: New file, from libutf8 with modifications.
89824         * m4/wcsstr.m4: New file.
89825         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsstr is declared.
89826         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSSTR, HAVE_WCSSTR.
89827         * modules/wchar (Makefile.am): Substitute GNULIB_WCSSTR, HAVE_WCSSTR.
89828         * tests/test-wchar-c++.cc: Test the declaration of wcsstr.
89829         * doc/posix-functions/wcsstr.texi: Mention the new module.
89831 2011-02-06  Bruno Haible  <bruno@clisp.org>
89833         New module 'wcspbrk'.
89834         * modules/wcspbrk: New file.
89835         * lib/wchar.in.h (wcspbrk): New declaration.
89836         * lib/wcspbrk.c: New file.
89837         * lib/wcspbrk-impl.h: New file, from libutf8 with modifications.
89838         * m4/wcspbrk.m4: New file.
89839         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcspbrk is declared.
89840         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSPBRK, HAVE_WCSPBRK.
89841         * modules/wchar (Makefile.am): Substitute GNULIB_WCSPBRK, HAVE_WCSPBRK.
89842         * tests/test-wchar-c++.cc: Test the declaration of wcspbrk.
89843         * doc/posix-functions/wcspbrk.texi: Mention the new module.
89845 2011-02-06  Bruno Haible  <bruno@clisp.org>
89847         New module 'wcsspn'.
89848         * modules/wcsspn: New file.
89849         * lib/wchar.in.h (wcsspn): New declaration.
89850         * lib/wcsspn.c: New file.
89851         * lib/wcsspn-impl.h: New file, from libutf8 with modifications.
89852         * m4/wcsspn.m4: New file.
89853         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsspn is declared.
89854         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSSPN, HAVE_WCSSPN.
89855         * modules/wchar (Makefile.am): Substitute GNULIB_WCSSPN, HAVE_WCSSPN.
89856         * tests/test-wchar-c++.cc: Test the declaration of wcsspn.
89857         * doc/posix-functions/wcsspn.texi: Mention the new module.
89859 2011-02-06  Bruno Haible  <bruno@clisp.org>
89861         New module 'wcscspn'.
89862         * modules/wcscspn: New file.
89863         * lib/wchar.in.h (wcscspn): New declaration.
89864         * lib/wcscspn.c: New file.
89865         * lib/wcscspn-impl.h: New file, from libutf8 with modifications.
89866         * m4/wcscspn.m4: New file.
89867         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscspn is declared.
89868         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCSPN, HAVE_WCSCSPN.
89869         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCSPN, HAVE_WCSCSPN.
89870         * tests/test-wchar-c++.cc: Test the declaration of wcscspn.
89871         * doc/posix-functions/wcscspn.texi: Mention the new module.
89873 2011-02-06  Bruno Haible  <bruno@clisp.org>
89875         New module 'wcsrchr'.
89876         * modules/wcsrchr: New file.
89877         * lib/wchar.in.h (wcsrchr): New declaration.
89878         * lib/wcsrchr.c: New file.
89879         * lib/wcsrchr-impl.h: New file, from libutf8 with modifications.
89880         * m4/wcsrchr.m4: New file.
89881         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsrchr is declared.
89882         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSRCHR, HAVE_WCSRCHR.
89883         * modules/wchar (Makefile.am): Substitute GNULIB_WCSRCHR, HAVE_WCSRCHR.
89884         * tests/test-wchar-c++.cc: Test the declaration of wcsrchr.
89885         * doc/posix-functions/wcsrchr.texi: Mention the new module.
89887 2011-02-06  Bruno Haible  <bruno@clisp.org>
89889         New module 'wcschr'.
89890         * modules/wcschr: New file.
89891         * lib/wchar.in.h (wcschr): New declaration.
89892         * lib/wcschr.c: New file.
89893         * lib/wcschr-impl.h: New file, from libutf8 with modifications.
89894         * m4/wcschr.m4: New file.
89895         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcschr is declared.
89896         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCHR, HAVE_WCSCHR.
89897         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCHR, HAVE_WCSCHR.
89898         * tests/test-wchar-c++.cc: Test the declaration of wcschr.
89899         * doc/posix-functions/wcschr.texi: Mention the new module.
89901 2011-02-06  Bruno Haible  <bruno@clisp.org>
89903         New module 'wcsdup'.
89904         * modules/wcsdup: New file.
89905         * lib/wchar.in.h (wcsdup): New declaration.
89906         * lib/wcsdup.c: New file.
89907         * lib/wcsdup-impl.h: New file, from libutf8 with modifications.
89908         * m4/wcsdup.m4: New file.
89909         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsdup is declared.
89910         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSDUP, HAVE_WCSDUP.
89911         * modules/wchar (Makefile.am): Substitute GNULIB_WCSDUP, HAVE_WCSDUP.
89912         * tests/test-wchar-c++.cc: Test the declaration of wcsdup.
89913         * doc/posix-functions/wcsdup.texi: Mention the new module.
89915 2011-02-06  Bruno Haible  <bruno@clisp.org>
89917         New module 'wcsxfrm'.
89918         * modules/wcsxfrm: New file.
89919         * lib/wchar.in.h (wcsxfrm): New declaration.
89920         * lib/wcsxfrm.c: New file.
89921         * lib/wcsxfrm-impl.h: New file.
89922         * m4/wcsxfrm.m4: New file.
89923         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsxfrm is declared.
89924         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSXFRM, HAVE_WCSXFRM.
89925         * modules/wchar (Makefile.am): Substitute GNULIB_WCSXFRM, HAVE_WCSXFRM.
89926         * tests/test-wchar-c++.cc: Test the declaration of wcsxfrm.
89927         * doc/posix-functions/wcsxfrm.texi: Mention the new module.
89929 2011-02-06  Bruno Haible  <bruno@clisp.org>
89931         New module 'wcscoll'.
89932         * modules/wcscoll: New file.
89933         * lib/wchar.in.h (wcscoll): New declaration.
89934         * lib/wcscoll.c: New file.
89935         * lib/wcscoll-impl.h: New file.
89936         * m4/wcscoll.m4: New file.
89937         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscoll is declared.
89938         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCOLL, HAVE_WCSCOLL.
89939         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCOLL, HAVE_WCSCOLL.
89940         * tests/test-wchar-c++.cc: Test the declaration of wcscoll.
89941         * doc/posix-functions/wcscoll.texi: Mention the new module.
89943 2011-02-06  Bruno Haible  <bruno@clisp.org>
89945         New module 'wcsncasecmp'.
89946         * modules/wcsncasecmp: New file.
89947         * lib/wchar.in.h (wcsncasecmp): New declaration.
89948         * lib/wcsncasecmp.c: New file.
89949         * lib/wcsncasecmp-impl.h: New file, from libutf8 with modifications.
89950         * m4/wcsncasecmp.m4: New file.
89951         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncasecmp is declared.
89952         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCASECMP, HAVE_WCSNCASECMP.
89953         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCASECMP,
89954         HAVE_WCSNCASECMP.
89955         * tests/test-wchar-c++.cc: Test the declaration of wcsncasecmp.
89956         * doc/posix-functions/wcsncasecmp.texi: Mention the new module.
89958 2011-02-06  Bruno Haible  <bruno@clisp.org>
89960         New module 'wcscasecmp'.
89961         * modules/wcscasecmp: New file.
89962         * lib/wchar.in.h (wcscasecmp): New declaration.
89963         * lib/wcscasecmp.c: New file.
89964         * lib/wcscasecmp-impl.h: New file, from libutf8 with modifications.
89965         * m4/wcscasecmp.m4: New file.
89966         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscasecmp is declared.
89967         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCASECMP, HAVE_WCSCASECMP.
89968         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCASECMP,
89969         HAVE_WCSCASECMP.
89970         * tests/test-wchar-c++.cc: Test the declaration of wcscasecmp.
89971         * doc/posix-functions/wcscasecmp.texi: Mention the new module.
89973 2011-02-05  Bruno Haible  <bruno@clisp.org>
89975         New module 'wcsncmp'.
89976         * modules/wcsncmp: New file.
89977         * lib/wchar.in.h (wcsncmp): New declaration.
89978         * lib/wcsncmp.c: New file.
89979         * lib/wcsncmp-impl.h: New file, from libutf8 with modifications.
89980         * m4/wcsncmp.m4: New file.
89981         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncmp is declared.
89982         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCMP, HAVE_WCSNCMP.
89983         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCMP, HAVE_WCSNCMP.
89984         * tests/test-wchar-c++.cc: Test the declaration of wcsncmp.
89985         * doc/posix-functions/wcsncmp.texi: Mention the new module.
89987 2011-02-05  Bruno Haible  <bruno@clisp.org>
89989         New module 'wcscmp'.
89990         * modules/wcscmp: New file.
89991         * lib/wchar.in.h (wcscmp): New declaration.
89992         * lib/wcscmp.c: New file.
89993         * lib/wcscmp-impl.h: New file, from libutf8 with modifications.
89994         * m4/wcscmp.m4: New file.
89995         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscmp is declared.
89996         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCMP, HAVE_WCSCMP.
89997         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCMP, HAVE_WCSCMP.
89998         * tests/test-wchar-c++.cc: Test the declaration of wcscmp.
89999         * doc/posix-functions/wcscmp.texi: Mention the new module.
90001 2011-02-05  Bruno Haible  <bruno@clisp.org>
90003         New module 'wcsncat'.
90004         * modules/wcsncat: New file.
90005         * lib/wchar.in.h (wcsncat): New declaration.
90006         * lib/wcsncat.c: New file.
90007         * lib/wcsncat-impl.h: New file, from libutf8 with modifications.
90008         * m4/wcsncat.m4: New file.
90009         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncat is declared.
90010         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCAT, HAVE_WCSNCAT.
90011         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCAT, HAVE_WCSNCAT.
90012         * tests/test-wchar-c++.cc: Test the declaration of wcsncat.
90013         * doc/posix-functions/wcsncat.texi: Mention the new module.
90015 2011-02-05  Bruno Haible  <bruno@clisp.org>
90017         New module 'wcscat'.
90018         * modules/wcscat: New file.
90019         * lib/wchar.in.h (wcscat): New declaration.
90020         * lib/wcscat.c: New file.
90021         * lib/wcscat-impl.h: New file, from libutf8 with modifications.
90022         * m4/wcscat.m4: New file.
90023         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscat is declared.
90024         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCAT, HAVE_WCSCAT.
90025         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCAT, HAVE_WCSCAT.
90026         * tests/test-wchar-c++.cc: Test the declaration of wcscat.
90027         * doc/posix-functions/wcscat.texi: Mention the new module.
90029 2011-02-05  Bruno Haible  <bruno@clisp.org>
90031         New module 'wcpncpy'.
90032         * modules/wcpncpy: New file.
90033         * lib/wchar.in.h (wcpncpy): New declaration.
90034         * lib/wcpncpy.c: New file.
90035         * lib/wcpncpy-impl.h: New file, from libutf8 with modifications.
90036         * m4/wcpncpy.m4: New file.
90037         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcpncpy is declared.
90038         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCPNCPY, HAVE_WCPNCPY.
90039         * modules/wchar (Makefile.am): Substitute GNULIB_WCPNCPY, HAVE_WCPNCPY.
90040         * tests/test-wchar-c++.cc: Test the declaration of wcpncpy.
90041         * doc/posix-functions/wcpncpy.texi: Mention the new module.
90043 2011-02-05  Bruno Haible  <bruno@clisp.org>
90045         New module 'wcsncpy'.
90046         * modules/wcsncpy: New file.
90047         * lib/wchar.in.h (wcsncpy): New declaration.
90048         * lib/wcsncpy.c: New file.
90049         * lib/wcsncpy-impl.h: New file, from libutf8 with modifications.
90050         * m4/wcsncpy.m4: New file.
90051         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncpy is declared.
90052         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCPY, HAVE_WCSNCPY.
90053         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCPY, HAVE_WCSNCPY.
90054         * tests/test-wchar-c++.cc: Test the declaration of wcsncpy.
90055         * doc/posix-functions/wcsncpy.texi: Mention the new module.
90057 2011-02-05  Bruno Haible  <bruno@clisp.org>
90059         New module 'wcpcpy'.
90060         * modules/wcpcpy: New file.
90061         * lib/wchar.in.h (wcpcpy): New declaration.
90062         * lib/wcpcpy.c: New file.
90063         * lib/wcpcpy-impl.h: New file, from libutf8 with modifications.
90064         * m4/wcpcpy.m4: New file.
90065         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcpcpy is declared.
90066         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCPCPY, HAVE_WCPCPY.
90067         * modules/wchar (Makefile.am): Substitute GNULIB_WCPCPY, HAVE_WCPCPY.
90068         * tests/test-wchar-c++.cc: Test the declaration of wcpcpy.
90069         * doc/posix-functions/wcpcpy.texi: Mention the new module.
90071 2011-02-05  Bruno Haible  <bruno@clisp.org>
90073         New module 'wcscpy'.
90074         * modules/wcscpy: New file.
90075         * lib/wchar.in.h (wcscpy): New declaration.
90076         * lib/wcscpy.c: New file.
90077         * lib/wcscpy-impl.h: New file, from libutf8 with modifications.
90078         * m4/wcscpy.m4: New file.
90079         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscpy is declared.
90080         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCPY, HAVE_WCSCPY.
90081         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCPY, HAVE_WCSCPY.
90082         * tests/test-wchar-c++.cc: Test the declaration of wcscpy.
90083         * doc/posix-functions/wcscpy.texi: Mention the new module.
90085 2011-02-05  Bruno Haible  <bruno@clisp.org>
90087         New module 'wcsnlen'.
90088         * modules/wcsnlen: New file.
90089         * lib/wchar.in.h (wcsnlen): New declaration.
90090         * lib/wcsnlen.c: New file.
90091         * lib/wcsnlen-impl.h: New file, from libutf8 with modifications.
90092         * m4/wcsnlen.m4: New file.
90093         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsnlen is declared.
90094         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNLEN, HAVE_WCSNLEN.
90095         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNLEN, HAVE_WCSNLEN.
90096         * tests/test-wchar-c++.cc: Test the declaration of wcsnlen.
90097         * doc/posix-functions/wcsnlen.texi: Mention the new module.
90099 2011-02-05  Bruno Haible  <bruno@clisp.org>
90101         New module 'wcslen'.
90102         * modules/wcslen: New file.
90103         * lib/wchar.in.h (wcslen): New declaration.
90104         * lib/wcslen.c: New file.
90105         * lib/wcslen-impl.h: New file, from libutf8 with modifications.
90106         * m4/wcslen.m4: New file.
90107         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcslen is declared.
90108         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSLEN, HAVE_WCSLEN.
90109         * modules/wchar (Makefile.am): Substitute GNULIB_WCSLEN, HAVE_WCSLEN.
90110         * tests/test-wchar-c++.cc: Test the declaration of wcslen.
90111         * doc/posix-functions/wcslen.texi: Mention the new module.
90113 2011-02-05  Bruno Haible  <bruno@clisp.org>
90115         New module 'wmemset'.
90116         * modules/wmemset: New file.
90117         * lib/wchar.in.h (wmemset): New declaration.
90118         * lib/wmemset.c: New file.
90119         * lib/wmemset-impl.h: New file, from libutf8 with modifications.
90120         * m4/wmemset.m4: New file.
90121         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemset is declared.
90122         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMSET, HAVE_WMEMSET.
90123         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMSET, HAVE_WMEMSET.
90124         * tests/test-wchar-c++.cc: Test the declaration of wmemset.
90125         * doc/posix-functions/wmemset.texi: Mention the new module.
90127 2011-02-05  Bruno Haible  <bruno@clisp.org>
90129         New module 'wmemmove'.
90130         * modules/wmemmove: New file.
90131         * lib/wchar.in.h (wmemmove): New declaration.
90132         * lib/wmemmove.c: New file.
90133         * lib/wmemmove-impl.h: New file, from libutf8 with modifications.
90134         * m4/wmemmove.m4: New file.
90135         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemmove is declared.
90136         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMMOVE, HAVE_WMEMMOVE.
90137         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMMOVE,
90138         HAVE_WMEMMOVE.
90139         * tests/test-wchar-c++.cc: Test the declaration of wmemmove.
90140         * doc/posix-functions/wmemmove.texi: Mention the new module.
90142 2011-02-05  Bruno Haible  <bruno@clisp.org>
90144         New module 'wmemcpy'.
90145         * modules/wmemcpy: New file.
90146         * lib/wchar.in.h (wmemcpy): New declaration.
90147         * lib/wmemcpy.c: New file.
90148         * lib/wmemcpy-impl.h: New file, from libutf8 with modifications.
90149         * m4/wmemcpy.m4: New file.
90150         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemcpy is declared.
90151         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMCPY, HAVE_WMEMCPY.
90152         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMCPY, HAVE_WMEMCPY.
90153         * tests/test-wchar-c++.cc: Test the declaration of wmemcpy.
90154         * doc/posix-functions/wmemcpy.texi: Mention the new module.
90156 2011-02-05  Bruno Haible  <bruno@clisp.org>
90158         New module 'wmemcmp'.
90159         * modules/wmemcmp: New file.
90160         * lib/wchar.in.h (wmemcmp): New declaration.
90161         * lib/wmemcmp.c: New file.
90162         * lib/wmemcmp-impl.h: New file, from libutf8 with modifications.
90163         * m4/wmemcmp.m4: New file.
90164         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemcmp is declared.
90165         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMCMP, HAVE_WMEMCMP.
90166         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMCMP, HAVE_WMEMCMP.
90167         * tests/test-wchar-c++.cc: Test the declaration of wmemcmp.
90168         * doc/posix-functions/wmemcmp.texi: Mention the new module.
90170 2011-02-07  Jim Meyering  <meyering@redhat.com>
90172         di-set, ino-map: new modules, from coreutils
90173         * lib/di-set.c: New file.
90174         * lib/di-set.h: Likewise.
90175         * lib/ino-map.c: Likewise.
90176         * lib/ino-map.h: Likewise.
90177         * modules/di-set: Likewise.
90178         * modules/di-set-tests: Likewise.
90179         * modules/ino-map: Likewise.
90180         * modules/ino-map-tests: Likewise.
90181         * tests/test-di-set.c: Likewise.
90182         * tests/test-ino-map.c: Likewise.
90184 2011-02-06  Paul Eggert  <eggert@cs.ucla.edu>
90186         getloadavg: merge minor changes from Emacs
90188         * lib/getloadavg.c (getloadavg_initialized): More-accurate comment.
90189         (getloadavg): Use memset, not bzero.
90191         2008-07-25  Chong Yidong  <cyd@stupidchicken.com>
90192         * lib/getloadavg.c (nl): Rename to name_list to avoid ncurses.h
90193         clash (bug#86).
90195 2010-11-14  Bruno Haible  <bruno@clisp.org>
90197         Allow multiple gnulib generated replacements to coexist.
90198         * lib/getopt.in.h (struct option): Avoid identical redefinition.
90199         * lib/inttypes.in.h (imaxdiv_t): Likewise.
90200         * lib/langinfo.in.h (nl_item): Likewise.
90201         * lib/math.in.h (_NaN, NAN): Likewise.
90202         * lib/netdb.in.h (struct addrinfo): Likewise.
90203         * lib/poll.in.h (struct pollfd, nfds_t): Likewise.
90204         * lib/pthread.in.h (pthread_t, pthread_attr_t, pthread_barrier_t,
90205         pthread_barrierattr_t, pthread_cond_t, pthread_condattr_t,
90206         pthread_key_t, pthread_mutex_t, pthread_mutexattr_t, pthread_once_t,
90207         pthread_rwlock_t, pthread_rwlockattr_t, pthread_cond_destroy,
90208         pthread_cond_init, pthread_cond_signal, pthread_cond_wait,
90209         pthread_create, pthread_exit, pthread_join, pthread_mutexattr_destroy,
90210         pthread_mutexattr_init, pthread_mutexattr_settype,
90211         pthread_mutex_destroy, pthread_mutex_init, pthread_mutex_lock,
90212         pthread_mutex_trylock, pthread_mutex_unlock, pthread_spinlock_t,
90213         pthread_spin_init, pthread_spin_destroy, pthread_spin_lock,
90214         pthread_spin_trylock, pthread_spin_unlock): Likewise.
90215         * lib/sched.in.h (struct sched_param): Likewise.
90216         * lib/se-selinux.in.h (security_class_t, security_context_t,
90217         is_selinux_enabled, getcon, freecon, getfscreatecon, setfscreatecon,
90218         matchpathcon, getfilecon, lgetfilecon, fgetfilecon, setfilecon,
90219         lsetfilecon, fsetfilecon, security_check_context,
90220         security_check_context_raw, setexeccon, matchpathcon_init_prefix):
90221         Likewise.
90222         * lib/search.in.h (VISIT, _gl_search_compar_fn, _gl_search_action_fn):
90223         Likewise.
90224         * lib/signal.in.h (sig_atomic_t, sigset_t, verify_NSIG_constraint,
90225         _gl_function_taking_int_returning_void_t, union sigval,
90226         struct siginfo_t, siginfo_t, struct sigaction): Likewise.
90227         * lib/spawn.in.h (posix_spawnattr_t, posix_spawn_file_actions_t,
90228         verify_POSIX_SPAWN_USEVFORK_no_overlap): Likewise.
90229         * lib/stdint.in.h (gl_int8_t, gl_uint8_t, gl_int16_t, gl_uint16_t,
90230         gl_int32_t, gl_uint32_t, gl_int64_t, gl_uint64_t, int_least8_t,
90231         uint_least8_t, int_least16_t, uint_least16_t, int_least32_t,
90232         uint_least32_t, int_least64_t, uint_least64_t, gl_int_fast8_t,
90233         gl_uint_fast8_t, gl_int_fast16_t, gl_uint_fast16_t, gl_int_fast32_t,
90234         gl_uint_fast32_t, int_fast64_t, uint_fast64_t, gl_intptr_t,
90235         gl_uintptr_t, intmax_t, uintmax_t, _verify_intmax_size): Likewise.
90236         * lib/stdio.in.h (rpl_fseek, rpl_ftell): Likewise.
90237         * lib/sys_socket.in.h (sa_family_t, struct sockaddr_storage,
90238         socklen_t, rpl_fd_isset): Likewise.
90239         * lib/sys_stat.in.h (rpl_mkdir): Likewise.
90240         * lib/sys_time.in.h (struct timeval): Likewise.
90241         * lib/sys_times.in.h (struct tms): Likewise.
90242         * lib/sys_utsname.in.h (struct utsname):
90243         * lib/time.in.h (struct timespec, __time_t_must_be_integral): Likewise.
90244         * lib/unistd.in.h (getpagesize): Likewise.
90245         * lib/wchar.in.h (mbstate_t): Likewise.
90246         * lib/wctype.in.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
90247         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit,
90248         towlower, towupper): Likewise.
90249         Reported by Sam Steingold <sds@gnu.org>.
90251 2011-02-05  Eric Blake  <eblake@redhat.com>
90253         unsetenv: work around Haiku issues
90254         * m4/setenv.m4 (gl_FUNC_UNSETENV): Also detect Haiku issue.
90255         * doc/posix-functions/unsetenv.texi (unsetenv): Document it.
90257 2010-12-30  Bruce Korb  <bkorb@gnu.org>
90259         libposix: avoid calling error() within libposix
90260         * lib/openat-die.c: remove error module stuff when GNULIB_LIBPOSIX
90261         is defined.
90263 2011-02-05  Eric Blake  <eblake@redhat.com>
90265         strerror_r-posix: port to cygwin
90266         * lib/strerror_r.c (strerror_r) [__CYGWIN__]: Add cygwin
90267         implementation.
90268         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Adjust comment.
90269         * tests/test-strerror_r.c (main): Fix test.
90270         * doc/posix-functions/strerror_r.texi (strerror_r): Document the
90271         issue.
90273 2011-02-05  Bruno Haible  <bruno@clisp.org>
90275         New module 'wmemchr'.
90276         * modules/wmemchr: New file.
90277         * lib/wchar.in.h (wmemchr): New declaration.
90278         * lib/wmemchr.c: New file.
90279         * lib/wmemchr-impl.h: New file, from libutf8 with modifications.
90280         * m4/wmemchr.m4: New file.
90281         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemchr is declared.
90282         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMCHR, HAVE_WMEMCHR.
90283         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMCHR, HAVE_WMEMCHR.
90284         * tests/test-wchar-c++.cc: Test the declaration of wmemchr.
90285         * doc/posix-functions/wmemchr.texi: Mention the new module.
90287 2011-02-04  Eric Blake  <eblake@redhat.com>
90289         fdopendir: detect FreeBSD bug
90290         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Detect bug.
90291         * doc/posix-functions/fdopendir.texi (fdopendir): Document it.
90293 2011-02-04  Paul Eggert  <eggert@cs.ucla.edu>
90295         stdbool: do not define HAVE_STDBOOL_H
90296         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Renamed from
90297         AC_HEADER_STDBOOL.  All uses changed.  Do not define
90298         HAVE_STDBOOL_H, as gnulib does not need this.  This change is
90299         imported from the latest Autoconf git.  It was motivated by Emacs,
90300         which uses gnulib but does not need HAVE_STDBOOL_H.
90302 2011-02-04  Bruno Haible  <bruno@clisp.org>
90304         wcsnrtombs: Prepare for new module wwcsnrtombs.
90305         * lib/wcsnrtombs-impl.h: New file, extracted from lib/wcsnrtombs.c.
90306         * lib/wcsnrtombs.c: Include it.
90307         * modules/wcsnrtombs (Files): Add lib/wcsnrtombs-impl.h.
90309         wcsrtombs: Prepare for new module wwcsrtombs.
90310         * lib/wcsrtombs-impl.h: New file, extracted from lib/wcsrtombs.c.
90311         * lib/wcsrtombs.c: Include it.
90312         * modules/wcsrtombs (Files): Add lib/wcsrtombs-impl.h.
90314         mbsnrtowcs: Prepare for new module mbsnrtowwcs.
90315         * lib/mbsnrtowcs-impl.h: New file, extracted from lib/mbsnrtowcs.c.
90316         * lib/mbsnrtowcs.c: Include it.
90317         * modules/mbsnrtowcs (Files): Add lib/mbsnrtowcs-impl.h.
90319         mbsrtowcs: Prepare for new module mbsrtowwcs.
90320         * lib/mbsrtowcs-impl.h: New file, extracted from lib/mbsrtowcs.c.
90321         * lib/mbsrtowcs.c: Include it.
90322         * modules/mbsrtowcs (Files): Add lib/mbsrtowcs-impl.h.
90324 2011-02-04  Bruno Haible  <bruno@clisp.org>
90326         vasnprintf: Reduce use of malloc for small format strings.
90327         * lib/printf-args.h (N_DIRECT_ALLOC_ARGUMENTS): New macro.
90328         (arguments): Add room for the first 7 arguments.
90329         * lib/printf-parse.h (N_DIRECT_ALLOC_DIRECTIVES): New macro.
90330         (char_directives, u8_directives, u16_directives, u32_directives): Add
90331         room for the first 7 directives.
90332         * lib/printf-parse.c: Include <string.h>.
90333         (PRINTF_PARSE): Change memory handling code so that it uses the first
90334         7 preallocated elements in an 'arguments' or 'DIRECTIVES' struct.
90335         * lib/vasnprintf.c (VASNPRINTF): Update memory handling code.
90336         Reported by Pádraig Brady <P@draigbrady.com>.
90338 2011-01-31  Eric Blake  <eblake@redhat.com>
90340         dup2: work around Haiku bug
90341         * m4/dup2.m4 (gl_FUNC_DUP2): Test for bug.
90342         * lib/dup2.c (rpl_dup2) [!WIN32]: Add workaround.
90343         * doc/posix-functions/dup2.texi (dup2): Document the bug.
90344         * tests/test-dup2.c (main): Enhance test.
90346 2011-01-31  Simon Josefsson  <simon@josefsson.org>
90348         doc: off_t is not available in eglibc 2.11.2 stdio.h.
90349         * doc/posix-headers/stdio.texi (stdio.h): Mention that off_t isn't
90350         declared by eglibc 2.11.2.
90351         * lib/stdio.in.h: Likewise.
90353 2011-01-31  Eric Blake  <eblake@redhat.com>
90355         ignore-value: add missing test dependency
90356         * tests/test-ignore-value.c: Revert previous change; stdio.h
90357         provides off_t.
90358         * modules/ignore-value-tests (Depends-on): Add missing dependency.
90360 2011-01-30  Paul Eggert  <eggert@cs.ucla.edu>
90362         mktime: clarify long_int width checking
90363         * lib/mktime.c (long_int_is_wide_enough): Move this assertion to
90364         the top level, to make it clearer that the assumption about
90365         long_int width is being checked.  See
90366         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00554.html>.
90368 2011-01-30  Simon Josefsson  <simon@josefsson.org>
90370         ignore-value: Fix self-test.
90371         * tests/test-ignore-value.c: Include sys/types.h for off_t.
90373 2011-01-29  Paul Eggert  <eggert@cs.ucla.edu>
90375         TYPE_MAXIMUM: avoid theoretically undefined behavior
90376         * lib/intprops.h (TYPE_MINIMUM, TYPE_MAXIMUM): Do not shift a
90377         negative number, which the C Standard says has undefined behavior.
90378         In practice this is not a problem, but might as well do it by the book.
90379         Reported by Rich Felker and Eric Blake; see
90380         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00493.html>.
90381         * lib/strtol.c (TYPE_MINIMUM, TYPE_MAXIMUM): Likewise.
90382         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
90383         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
90384         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Likewise.
90385         * m4/stdint.m4 (gl_STDINT_H): Likewise.
90386         * lib/mktime.c (TYPE_MAXIMUM): Redo slightly to match the others.
90388         mktime: #undef mktime before #defining it
90389         * lib/mktime.c (mktime) [DEBUG]: #undef mktime before #defining it.
90391         mktime: systematically normalize tm_isdst comparisons
90392         * lib/mktime.c (isdst_differ): New function.
90393         (__mktime_internal): Use it systematically for all isdst comparisons.
90394         This completes the fix for libc BZ #6723, and removes the need for
90395         normalizing tm_isdst.  See
90396         <http://sourceware.org/bugzilla/show_bug.cgi?id=6723>
90397         (not_equal_tm) [DEBUG]: Use isdst_differ here, too.
90399         mktime: fix some integer overflow issues and sidestep the rest
90401         This was prompted by a bug report by Benjamin Lindner for MinGW
90402         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00472.html>.
90403         His bug is due to signed integer overflow (0 - INT_MIN), and I
90404         I scanned through mktime.c looking for other integer overflow
90405         problems, fixing all the bugs I found.
90407         Although the C Standard says the resulting code is still not safe
90408         in the presence of integer overflow, in practice it should be good
90409         enough for all real-world two's-complement implementations, except
90410         for debugging environments that deliberately trap on integer
90411         overflow (e.g., gcc -ftrapv).
90413         * lib/mktime.c (WRAPV): New macro.
90414         (SHR): Also check that long_int and time_t shift right in the
90415         usual way, before using the fast-but-unportable method.
90416         (TYPE_ONES_COMPLEMENT, TYPE_SIGNED_MAGNITUDE): Remove, no longer
90417         used.  The code already assumed two's complement, so there's
90418         no need to test for alternatives.  All uses removed.
90419         (TYPE_MAXIMUM): Don't rely here on overflow behavior not defined by
90420         the C standard.  Problem reported by Rich Felker in
90421         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00488.html>.
90422         (twos_complement_arithmetic): Also check long_int and time_t.
90423         (time_t_avg, time_t_add_ok, time_t_int_add_ok): New functions.
90424         (guess_time_tm, ranged_convert, __mktime_internal): Use them.
90425         (__mktime_internal): Avoid integer overflow with unary subtraction
90426         in two instances where -1 - X is an adequate replacement for -X,
90427         since the calculations are approximate.
90429 2011-01-29  Eric Blake  <eblake@redhat.com>
90431         mktime: avoid infinite loop
90432         * m4/mktime.m4 (AC_FUNC_MKTIME): Avoid overflow on possibly-signed
90433         type; behavior is still undefined but portable to all known targets.
90434         Reported by Rich Felker.
90436 2011-01-29  Simon Josefsson  <simon@josefsson.org>
90438         rename, unlink, same-inode: Relicense.
90439         * modules/rename (License): Relax from LGPLv3+ to LGPLv2+.
90440         * modules/unlink (License): Likewise.
90441         * modules/same-inode (License): Likewise.
90443 2011-01-28  Paul Eggert  <eggert@cs.ucla.edu>
90445         mktime: avoid problems on NetBSD 5 / i386
90446         * lib/mktime.c (long_int): New type.  This works around a problem
90447         on NetBSD 5 / i386, where 'long int' and 'int' are both 32 bits
90448         but time_t is 64 bits, and where I expect the existing code is
90449         wrong in some cases.
90450         (leapyear, ydhms_diff, guess_time_tm, __mktime_internal): Use it.
90451         (ydhms_diff): Bring back the compile-time check for wide-enough
90452         year and yday.
90454         mktime: fix misspelling in comment
90455         * lib/mktime.c (__mktime_internal): Fix misspelling in comment.
90456         This merges all recent glibc changes of importance.
90458 2011-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
90460         move-if-change: cope with concurrent mv of identical file.
90461         * build-aux/move-if-change (CMPPROG): Accept environment
90462         variable as an override for `cmp'.
90463         (usage): Document CMPPROG.
90464         Adjust comparison to drop stdout.  Cope with failure of mv if
90465         the target file exists and is identical to the source, for
90466         parallel builds.
90467         Report from H.J. Lu against binutils in PR binutils/12283.
90469 2011-01-28  Bruce Korb  <bkorb@gnu.org>
90471         * users.txt: Mention sharutils.
90473 2011-01-28  Simon Josefsson  <simon@josefsson.org>
90475         * users.txt: Mention OATH Toolkit.
90477 2011-01-27  Bruno Haible  <bruno@clisp.org>
90479         Prepare for supporting FreeBSD 10.
90480         * build-aux/config.libpath: Remove handling of freebsd1*.
90482 2011-01-27  Gerald Pfeifer  <gerald@pfeifer.com>  (tiny change)
90484         Prepare for supporting FreeBSD 10.
90485         * build-aux/config.rpath: Remove handling of freebsd1* which soon would
90486         match FreeBSD 10.0.
90488 2011-01-27  Bruno Haible  <bruno@clisp.org>
90490         vma-iter, get-rusage-as: Add OpenBSD support.
90491         * modules/vma-iter (configure.ac): Test for mquery.
90492         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on OpenBSD.
90493         * lib/vma-iter.c: Include <sys/mman.h>.
90494         (vma_iterate): Add an implementation based on mquery().
90495         * lib/resource-ext.h (get_rusage_as): Update comments.
90496         * lib/get-rusage-as.c: Likewise.
90497         * lib/get-rusage-data.c: Likewise.
90499 2011-01-26  Karl Berry  <karl@gnu.org>
90501         * doc/Makefile (lang_env, makeinfo_prog, manual_opts): new
90502         variables to make it easier to override the makeinfo program used.
90504 2011-01-26  Eric Blake  <eblake@redhat.com>
90506         fcntl: work around Haiku F_DUPFD bugs
90507         * m4/fcntl.m4 (gl_FUNC_FCNTL): Also catch Haiku errno bug.
90508         * lib/fcntl.c (rpl_fcntl) [F_DUPFD]: Work around Haiku losing
90509         cloexec bit on duplication.
90510         * doc/posix-functions/fcntl.texi (fcntl): Document the bug.
90512 2011-01-26  Bruno Haible  <bruno@clisp.org>
90514         Enable memory leak tests on AIX.
90515         * tests/test-dprintf-posix2.c (main): Don't skip the test on AIX.
90516         * tests/test-fprintf-posix3.c (main): Likewise.
90518 2011-01-26  Bruno Haible  <bruno@clisp.org>
90520         Tests for module 'get-rusage-data'.
90521         * modules/get-rusage-data-tests: New file.
90522         * tests/test-get-rusage-data.c: New file.
90524         New module 'get-rusage-data'.
90525         * lib/resource-ext.h (get_rusage_data): New declaration.
90526         * lib/get-rusage-data.c: New file.
90527         * modules/get-rusage-data: New file.
90529 2011-01-25  Bruno Haible  <bruno@clisp.org>
90531         get-rusage-as: Allow for easier testing.
90532         * lib/resource-ext.h (get_rusage_as): Add comment.
90533         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit): Define always.
90534         (main): New function for interactive testing.
90536 2011-01-25  Bruno Haible  <bruno@clisp.org>
90538         vma-iter: Treat Haiku like BeOS.
90539         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define on Haiku as well.
90540         * lib/vma-iter.c (vma_iterate) [Haiku]: Use the BeOS API.
90542 2011-01-25  Eric Blake  <eblake@redhat.com>
90544         c-stack: fix regression on cygwin when libsigsegv is present
90545         * lib/c-stack.c (die): Don't flatten error if sigsegv is present.
90547 2011-01-24  Bruno Haible  <bruno@clisp.org>
90549         vma-iter: Avoid empty intervals.
90550         * lib/vma-iter.c (vma_iterate) [IRIX, OSF/1]: Don't call the callback
90551         on an empty interval.
90553 2011-01-24  Jim Meyering  <meyering@redhat.com>
90555         u64: remove unnecessary #include
90556         * lib/u64.h: Don't include <stddef.h>.  It was not used.
90558 2011-01-23  Paul Eggert  <eggert@cs.ucla.edu>
90560         Allow the user to avoid the HAVE_RAW_DECL_* macros.
90561         * m4/gnulib-common.m4 (gl_ASSERT_NO_GNULIB_POSIXCHECK): New macro.
90563 2011-01-23  Bruno Haible  <bruno@clisp.org>
90565         New module 'vma-iter'.
90566         * lib/vma-iter.h: New file.
90567         * lib/vma-iter.c: New file, based on lib/get-rusage-as.c.
90568         * modules/vma-iter: New file.
90569         * lib/get-rusage-as.c: Include vma-iter.h. Don't include system headers
90570         for get_rusage_as_via_iterator.
90571         (vma_iterate_callback): New function.
90572         (get_rusage_as_via_iterator): Rewritten to use vma_iterate.
90573         * modules/get-rusage-as (Depends-on): Add vma-iter.
90575 2011-01-23  Bruno Haible  <bruno@clisp.org>
90577         uninorm: Tweak includes.
90578         * lib/uninorm/normalize-internal.h: Don't include <stddef.h>.
90579         Reported by Jim Meyering.
90581 2011-01-23  Bruno Haible  <bruno@clisp.org>
90583         get-rusage-as: Improve on NetBSD.
90584         * lib/get-rusage-as.c (get_rusage_as_via_iterator): On NetBSD, use
90585         /proc, like on FreeBSD.
90587 2011-01-23  Jim Meyering  <meyering@redhat.com>
90589         xreadlink.h: remove unnecessary #include
90590         * lib/xreadlink.h: Don't include <stddef.h>.  It was not used.
90592         maint.mk: add syntax-check rule: detect unnecessary #include <stddef.h>
90593         * top/maint.mk (sc_prohibit_stddef_without_use): New rule.
90595 2011-01-23  Bruno Haible  <bruno@clisp.org>
90597         get-rusage-as: Fix bug.
90598         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit): Restore the
90599         original limit when aborting the first loop.
90601 2011-01-23  Bruno Haible  <bruno@clisp.org>
90603         wctype: Ensure valid C syntax.
90604         * m4/wctype_h.m4 (gl_WCTYPE_H): Invoke gl_CHECK_NEXT_HEADERS
90605         unconditionally, instead of gl_NEXT_HEADERS conditionally.
90607 2011-01-21  Paul Eggert  <eggert@cs.ucla.edu>
90609         getopt: omit HAVE_OPTRESET, HAVE_GETOPT_CLIP from config.h
90610         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not put the
90611         symbols HAVE_OPTRESET and HAVE_GETOPT_CLIP into config.h,
90612         as they are needed only for configure's test case.
90613         This removes two unnecessary symbols from config.h.
90615         gl_CHECK_NEXT_HEADERS implies AC_CHECK_HEADERS_ONCE
90616         * m4/include_next.m4 (gl_CHECK_HEXT_HEADERS): Document this.
90617         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Don't bother to invoke
90618         AC_CHECK_HEADERS_ONCE on a header that we also invoke
90619         gl_CHECK_NEXT_HEADERS on, since the latter invokes the former.
90620         * m4/netdb_h.m4 (gl_HEADER_NETDB): Likewise.
90621         * m4/pthread.m4 (gl_PTHREAD_CHECK): Likewise.
90622         * m4/sched_h.m4 (gl_SCHED_H): Likewise.
90623         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
90624         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
90625         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Likewise.
90626         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
90627         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
90628         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
90629         * m4/termios_h.m4 (gl_TERMIOS_H): Likewise.
90630         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
90631         * m4/wchar_h.m4 (gl_WCHAR_H): Likewise.
90632         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
90634 2011-01-21  Eric Blake  <eblake@redhat.com>
90636         maintainer-makefile: work with older git for submodule check
90637         * top/maint.mk (public-submodule-commit): Rewrite to avoid
90638         merge-base --independent, which Ubuntu 10.04 git 1.7.0.4 lacks.
90639         Reported by Matthias Bolte.
90641         bootstrap: minor portability fixes
90642         * build-aux/bootstrap (me): Use $me instead of $0 in functions.
90643         (usage): Omit leading capital and trailing . on help phrases, per
90644         GNU Coding Standards.
90645         (check_versions, top level): Prefix messages with script name.
90647 2011-01-21  Benjamin Lindner  <bjmldn@gmail.com>  (tiny change)
90649         bootstrap: support --no-git option
90650         * build-aux/bootstrap: Add --no-git option, to be used when
90651         --gnulib-srcdir points to the exact desired checkout.
90653 2011-01-21  Eric Blake  <eblake@redhat.com>
90655         strerror_r-posix: work with glibc 2.13
90656         * lib/strerror_r.c (strerror_r): Fix return type.
90658 2011-01-21  Pádraig Brady  <P@draigBrady.com>
90659             Bruno Haible  <bruno@clisp.org>
90661         uN_strstr: New unit tests.
90662         * modules/unistr/u8-strstr-tests: New file.
90663         * modules/unistr/u16-strstr-tests: New file.
90664         * modules/unistr/u32-strstr-tests: New file.
90665         * tests/unistr/test-u-strstr.h: New file, based on tests/test-strstr.c.
90666         * tests/unistr/test-u8-strstr.c: New file.
90667         * tests/unistr/test-u16-strstr.c: New file.
90668         * tests/unistr/test-u32-strstr.c: New file.
90670 2011-01-21  Pádraig Brady  <P@draigBrady.com>
90671             Bruno Haible  <bruno@clisp.org>
90673         Make uN_strstr functions O(n) worst-case.
90674         * lib/unistr/u-strstr.h (FUNC): In the 8-bit case, use strstr. In the
90675         16-bit and 32-bit unit cases, use the unibyte algorithm from
90676         lib/mbsstr.c.
90677         * lib/unistr/u8-strstr.c: Include <string.h>.
90678         (UNIT_IS_UINT8_T): New macro.
90679         * lib/unistr/u16-strstr.c: Include malloca.h and str-kmp.h.
90680         (U_STRLEN, U_STRNLEN): New macros.
90681         * lib/unistr/u32-strstr.c: Include malloca.h and str-kmp.h.
90682         (U_STRLEN, U_STRNLEN): New macros.
90683         * modules/unistr/u8-strstr (Depends-on): Add strstr.
90684         (configure.ac): Update required libunistring version.
90685         * modules/unistr/u16-strstr (Files): Add lib/str-kmp.h.
90686         (Depends-on): Add unistr/u16-strlen, unistr/u16-strnlen, stdbool,
90687         malloca.
90688         (configure.ac): Update required libunistring version.
90689         * modules/unistr/u32-strstr (Files): Add lib/str-kmp.h.
90690         (Depends-on): Add unistr/u32-strlen, unistr/u32-strnlen, stdbool,
90691         malloca.
90692         (configure.ac): Update required libunistring version.
90694 2011-01-21  Pádraig Brady  <P@draigBrady.com>
90695             Bruno Haible  <bruno@clisp.org>
90697         Prepare for faster uN_strstr functions.
90698         * lib/str-kmp.h: Support definable UNITs.
90699         (knuth_morris_pratt): Renamed from knuth_morris_pratt_unibyte. Add
90700         needle_len argument.
90701         * lib/mbsstr.c (mbsstr): Adjust for the changed str-kmp.h.
90702         * lib/mbscasestr.c (mbscasestr): Likewise.
90704 2011-01-21  Pádraig Brady  <P@draigBrady.com>
90706         malloca-tests: make faster by unsetting MALLOC_PERTURB_
90707         * tests/test-malloca.c (main): Unset the environment variable
90708         to greatly speed up the test.
90709         * tests/init.sh: Don't say that MALLOC_PERTURB_ is cheap.
90710         * modules/malloca-tests: Depend on unsetenv.
90712 2011-01-21  Pádraig Brady  <P@draigBrady.com>
90714         ignore-value: remove stdint dependency
90715         * lib/ignore-value.h: Remove <stdint.h>
90716         * modules/ignore-value: Remove stdint dependency.
90718 2011-01-21  Jim Meyering  <meyering@redhat.com>
90720         maint.mk: adjust variable name to be consistent with other gl_ vars
90721         * top/maint.mk (gl_public_submodule_commit): Rename the variable
90722         to be lower case.
90724 2011-01-20  Jim Meyering  <meyering@redhat.com>
90726         maint.mk: make "check" depend on public-submodule-commit by default
90727         * top/maint.mk (GL_PUBLIC_SUBMODULE_COMMIT): New overridable variable.
90729 2011-01-20  Bruno Haible  <bruno@clisp.org>
90731         mbfile, mbiter: Complete change from 2008-12-21.
90732         * m4/mbfile.m4 (gl_MBFILE): Don't require AC_FUNC_MBRTOWC.
90733         * m4/mbiter.m4 (gl_MBITER): Likewise.
90735 2011-01-20  Jim Meyering  <meyering@redhat.com>
90737         init.sh: insert space between each function name and "()"
90738         * tests/init.sh: Make it a little easier to see that a function's
90739         name is "warn_", and not "warn" when looking at the first part of
90740         its definition: "warn_ ()".  Suggested by Ralf Wildenhues.
90742 2011-01-20  Jim Meyering  <meyering@redhat.com>
90744         mountlist: clean up code formatting
90745         * lib/mountlist.c (read_file_system_list): Split a long line,
90746         correct bracing style, use NULL in place of "(struct statfs *)0",
90747         don't parenthesize return value, add spaces around "=" and after
90748         ";-in-for-stmt".
90750 2011-01-14  Markus Duft  <mduft@gentoo.org>
90752         mountlist: add support for Interix
90753         * lib/mountlist.c (read_file_system_list) [MOUNTED_INTERIX_STATVFS]:
90754         Apply statvfs to all entries of /dev/fs.
90755         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for statvfs,
90756         and if found, AC_DEFINE MOUNTED_INTERIX_STATVFS.
90758 2011-01-20  Jim Meyering  <meyering@redhat.com>
90760         maint.mk: improve the public-submodule-commit rule
90761         * top/maint.mk (public-submodule-commit): Prefix with $(AM_V_GEN),
90762         to suppress printing of its commands... unless V=1.
90763         Add git submodule's --quiet option to suppress printing of e.g.,
90764         "Entering gnulib" output.
90765         "cd" into $(srcdir) before running git submodule.
90767 2011-01-20  Bruno Haible  <bruno@clisp.org>
90769         include_next: Fix bug introduced on 2011-01-18.
90770         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): New macro, extracted
90771         from gl_CHECK_NEXT_HEADERS and gl_NEXT_HEADERS. Omit test of
90772         ac_cv_header_... variable if the second argument is not 'check'.
90773         (gl_CHECK_NEXT_HEADERS, gl_NEXT_HEADERS): Invoke
90774         gl_NEXT_HEADERS_INTERNAL.
90776 2011-01-20  Bruno Haible  <bruno@clisp.org>
90778         Allow the user to avoid the GNULIB_TEST_* macros.
90779         * m4/gnulib-common.m4 (gl_ASSERT_NO_GNULIB_TESTS): New macro.
90780         Suggested by Paul Eggert.
90782 2011-01-14  Jim Meyering  <meyering@redhat.com>
90784         bootstrap: avoid failure when there is no .gitmodules file
90785         ": ${gnulib_path=gnulib}" fails to set $gnulib_path when that variable
90786         has been assigned to, even when its value is the empty string.
90787         * build-aux/bootstrap (gnulib_path): Test explicitly for an empty
90788         "$gnulib_path", rather than using ${gnulib_path=gnulib}.
90789         Reported by John W. Eaton <jwe@gnu.org>.
90791 2011-01-19  Paul Eggert  <eggert@cs.ucla.edu>
90793         assume <ctype.h>, ..., <time.h> exist
90794         For years gnulib has been assuming the existence of the headers
90795         <ctype.h>, <errno.h>, <fcntl.h>, <locale.h>, <signal.h>,
90796         <stdio.h>, <stdlib.h>, <string.h>, and <time.h>.  Omit checks for
90797         them, since they don't appear to be needed.
90798         * README (Portability guidelines): Document this.
90799         * lib/flock.c: Assume <fcntl.h> exists.
90800         * lib/regex_internal.h: Assume <locale.h> exists.
90801         * m4/ctype.m4 (gl_CTYPE_H): Assume <ctype.h> exists.
90802         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Assume <errno.h> exists.
90803         * m4/fcntl_h.m4 (gl_FCNTL_H): Assume <fcntl.h> exists.
90804         * m4/flock.m4 (gl_PREREQ_FLOCK): Likewise.
90805         * m4/locale_h.m4 (gl_LOCALE_H): Assume <locale.h> exists.
90806         * m4/regex.m4 (gl_REGEX): Likewise.
90807         * m4/signal_h.m4 (gl_SIGNAL_H): Assume <signal.h> exists.
90808         * m4/stdio_h.m4 (gl_STDIO_H): Assume <stdio.h> exists.
90809         * m4/stdlib_h.m4 (gl_STDLIB_H): Assume <stdlib.h> exists.
90810         * m4/string_h.m4 (gl_STRING_H): Assume <string.h> exists.
90811         * tests/test-argp.c: Likewise.
90812         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Assume <time.h> exists.
90814         multiarch: remove AA_APPLE_UNIVERSAL_BUILD
90815         * m4/multiarch.m4 (gl_MULTIARCH): Don't AC_DEFINE
90816         AA_APPLE_UNIVERSAL_BUILD.  See
90817         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00247.html>.
90818         * NEWS: Document this.
90820 2011-01-19  Eric Blake  <eblake@redhat.com>
90822         c-stack: assume stack overflow if SA_SIGINFO unsupported
90823         * lib/c-stack.c (SIGACTION_WORKS): Rename...
90824         (SIGINFO_WORKS): ...since gnulib module guarantees that (most) of
90825         sigaction will work.
90826         (die): Assume stack overflow if siginfo doesn't work, to let Haiku
90827         behavior match Linux.
90828         * tests/test-c-stack.c (main): Prefer NULL for pointers.
90830         stdbool-tests: accommodate Haiku
90831         * tests/test-stdbool.c: Haiku's gcc 2.95 lacks native _Bool.
90833         binary-io: fix O_TEXT on Haiku
90834         * modules/binary-io (Depends-on): Add fcntl-h.
90835         * lib/binary-io.h (O_TEXT): Rely on replacement <fcntl.h> rather
90836         than blindly undefining O_TEXT.
90837         Reported by Scott McCreary.
90839 2011-01-18  Paul Eggert  <eggert@cs.ucla.edu>
90841         include_next: do not check for standard headers like stddef.h
90843         I found this problem when modifying Emacs to use gnulib.
90844         I noticed that it added HAVE_STDDEF_H to config.h, even though
90845         gnulib always assumes <stddef.h> exists as per README and this
90846         symbol is unnecessary.
90847         * m4/include_next.m4 (gl_NEXT_HEADERS): New macro, which does not
90848         use AC_CHECK_HEADERS_ONCE, but which otherwise contains what
90849         gl_CHECK_NEXT_HEADERS used to contain.  This makes 'configure' run
90850         faster for headers like stddef.h that are known to exist.
90851         (gl_CHECK_NEXT_HEADERS): Use it.
90852         * m4/float_h.m4 (gl_FLOAT_H): For float.h, use gl_NEXT_HEADERS
90853         rather than gl_CHECK_NEXT_HEADERS.
90854         * m4/stdarg.m4 (gl_STDARG_H): Likewise, for stdarg.h.
90855         * m4/stddef_h.m4 (gl_STDDEF_H): Likewise, for stddef.h.
90857 2011-01-18  Eric Blake  <eblake@redhat.com>
90859         ansi-c++-opt: skip C++ dependency style if C++ is unused
90860         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): Avoid full-blown dependency
90861         tests when we know C++ compilation is not desired.
90862         Reported by Scott McCreary.
90864 2011-01-18  Bruno Haible  <bruno@clisp.org>
90866         *printf-posix: Avoid test failures. Make tests work on MacOS X, Cygwin.
90867         * tests/test-fprintf-posix3.c: Include "resource-ext.h".
90868         (main): Perform test also when getrlimit and setrlimit don't exist or
90869         when setrlimit of RLIMIT_DATA fails (like on Cygwin). Instead of
90870         limiting the address space size using setrlimit, compare the address
90871         space size before and after the test.
90872         * tests/test-dprintf-posix2.c: Likewise.
90873         * tests/test-fprintf-posix3.sh: Update skip messages.
90874         * tests/test-dprintf-posix2.sh: Likewise.
90875         * modules/fprintf-posix-tests (Depends-on): Add get-rusage-as.
90876         * modules/dprintf-posix-tests (Depends-on): Likewise.
90877         Reported by Bruce Korb <bkorb@gnu.org> and
90878         Gary V. Vaughan <gary@gnu.org>.
90880 2011-01-18  Bruno Haible  <bruno@clisp.org>
90882         get-rusage-as: Improvement for Cygwin.
90883         * lib/get-rusage-as.c (get_rusage_as_via_iterator): On Windows, ignore
90884         areas that are merely reserved.
90886 2011-01-18  Paul Eggert  <eggert@cs.ucla.edu>
90888         strftime: remove dependencies on multibyte modules
90890         strftime depended on mbrlen, mbsinit, and wchar, but these modules
90891         are needed only if ! MULTIBYTE_IS_FORMAT_SAFE, and that is true
90892         only if __osf__ is defined, and I suspect OSF doesn't need these
90893         other modules.  If my guess is wrong, we'll need to come up with a
90894         variant of strftime that doesn't need the multibyte modules.
90896         I discovered this problem when attempting modify Emacs to use the
90897         strftime module.  With the previous gnulib, this caused Emacs to
90898         need 31 new files, ranging from lib/config.charset to
90899         m4/wint_t.m4.  This was overkill and I expect would be offputting
90900         to the Emacs maintainers.  After this change, only 6 new files are
90901         needed, namely strftime.[ch], srtftime.m4, stdbool.in.h,
90902         stdbool.m4, and tm_gmtoff.m4.
90904         * lib/strftime.c (MULTIBYTE_IS_FORMAT_SAFE): Define to 1 always.
90905         Suggested by Bruno Haible in
90906         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00238.html>.
90907         * m4/strftime.m4 (gl_FUNC_STRFTIME): Do not require AC_TYPE_MBSTATE_T,
90908         and do not check for wchar.h.
90909         * modules/strftime (Files): Remove m4/mbstate_t.m4.
90910         (Depends-on): Remove mbrlen, mbsinit, wchar.
90912 2011-01-18  Bruno Haible  <bruno@clisp.org>
90914         Tests for module 'get-rusage-as'.
90915         * modules/get-rusage-as-tests: New file.
90916         * tests/test-get-rusage-as.c: New file.
90918         New module 'get-rusage-as'.
90919         * modules/get-rusage-as: New file.
90920         * lib/resource-ext.h: New file.
90921         * lib/get-rusage-as.c: New file.
90923 2011-01-17  Eric Blake  <eblake@redhat.com>
90925         sigaction: relax license from LGPLv3+ to LGPLv2+
90926         * modules/sigaction (License): Relax to LGPLv2+.
90928 2011-01-14  Bruno Haible  <bruno@clisp.org>
90930         filemode: Make function declarations usable in C++ mode.
90931         * lib/filemode.h: Enclose function declarations in extern "C" block.
90932         Reported by John W. Eaton <jwe@gnu.org>.
90934 2011-01-12  Rob Vermaas  <rob.vermaas@gmail.com>
90936         save-cwd: no longer include "xgetcwd.h"
90937         * lib/save-cwd.c: Don't include "xgetcwd.h"; it's no longer used.
90938         This avoids a compilation failure in projects that use save-cwd
90939         without also using the xgetcwd module.
90941 2011-01-11  Paul Eggert  <eggert@cs.ucla.edu>
90943         ftoastr: split into 3 modules ftoastr, dtoastr, ldtoastr
90944         This is so that a program like Emacs, which needs only dtoastr,
90945         does not have to bother with distributing and compiling ftoastr
90946         and ldtoastr.
90947         * MODULES.html.sh: Document these modules (ftoastr wasn't documented).
90948         * modules/dtoastr, modules/ldtoastr: New files.
90949         * modules/ftoastr: Now works just for 'float'.
90950         (Files): Remove lib/dtoastr.c, lib/ldtoastr.c.
90951         (Makefile.am): Remove ftoastr.h (not needed and no effect),
90952         dtoastr.c, ldtoastr.c.
90954 2011-01-11  Jim Meyering  <meyering@redhat.com>
90956         save-cwd: remove #if-!HAVE_FCHDIR'd code; use the fchdir module
90957         There is no need to work around the lack of the fchdir function,
90958         since gnulib can now provide a replacement when required.
90959         * lib/save-cwd.c: Remove #if !HAVE_FCHDIR...#endif code.
90960         * modules/save-cwd (Depends-on): Add fchdir.
90962 2011-01-11  Paul Eggert  <eggert@cs.ucla.edu>
90964         openat, save-cwd: avoid xmalloc
90966         This removes a direct (but undocumented) dependency of openat on
90967         xalloc, along with an indirect dependency via save-cwd.  It also
90968         removes a dependency of save-cwd on xgetcwd, and thereby
90969         indirectly on xalloc.  This change causes the openat substitute
90970         to fall back on save_cwd when memory is tight, and for save_cwd to
90971         fail instead of dying when memory is tight, but that's good enough.
90972         Problem and initial idea for fix reported by Bastien Roucaries in
90973         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00170.html>.
90975         * lib/openat-proc.c: Include stdlib.h (for malloc), not
90976         xalloc.h (for xmalloc).
90977         (openat_proc_name): Use malloc, not xmalloc.
90978         * lib/save-cwd.c (save_cwd): Use getcwd, not xgetcwd.
90979         * modules/save-cwd (Files): Depend on getcwd, not xgetcwd.
90981         openat: Increase OPENAT_BUFFER_SIZE from 512 to at least 1024
90982         This avoids heap allocation for file names whose lengths are in
90983         the range 512..1023, with the upper bound increasing to at most
90984         4031 depending on the platform's PATH_MAX.  (We do not want
90985         pathmax.h here as it might supply a non-constant PATH_MAX.)
90986         * lib/openat-priv.h (SAFER_ALLOCA_MAX, SAFER_ALLOCA): New macros.
90987         Perhaps they should be moved to malloca.h?
90988         (OPENAT_BUFFER_SIZE): Use them.
90990 2011-01-10  Bruno Haible  <bruno@clisp.org>
90992         doc: Update users.txt.
90993         * users.txt: Add recutils.
90995 2011-01-09  Karl Berry  <karl@gnu.org>
90997         * doc/posix-functions/gai_strerror.texi: Insert missing @item.
90999         * doc/configmake.texi: New file.
91000         * doc/gnulib.texi: Include it.
91001         * modules/configmake: Move documentation from here.
91003 2011-01-09  Bruno Haible  <bruno@clisp.org>
91005         Update to Unicode 6.0.0.
91006         * lib/gen-uni-tables.c (symbolic_width): Fix bounds of planes.
91007         (get_lbp): Update for Unicode 6.0.0.
91008         * lib/uniwidth/width.c (nonspacing_table_data): Add U+065F,
91009         U+0859..U+085B, U+093A, U+0956..U+0957, U+0F8D..U+0F8F, U+135D..U+135E,
91010         U+1BE6, U+1BE8..U+1BE9, U+1BED, U+1BEF..U+1BF1, U+1DFC, U+2D7F,
91011         U+11001, U+11038..U+11046. Remove U+06DE.
91012         (uc_width): Fix bounds of planes.
91013         * tests/uniwidth/test-uc_width2.sh: Same updates as in
91014         lib/uniwidth/width.c.
91015         * tests/unigbrk/GraphemeBreakTest.txt: Copied from Unicode 6.0.0, with
91016         trailing whitespace removed.
91017         * tests/uninorm/NormalizationTest.txt: Update from Unicode 6.0.0,
91018         without comments, but with the original copyright notice.
91019         * lib/unicase/cased.h: Regenerated for Unicode 6.0.0.
91020         * lib/unicase/ignorable.h: Likewise.
91021         * lib/unicase/tocasefold.h: Likewise.
91022         * lib/unicase/tolower.h: Likewise.
91023         * lib/unicase/totitle.h: Likewise.
91024         * lib/unicase/toupper.h: Likewise.
91025         * lib/unictype/bidi_of.h: Likewise.
91026         * lib/unictype/blocks.h: Likewise.
91027         * lib/unictype/categ_C.h: Likewise.
91028         * lib/unictype/categ_Cn.h: Likewise.
91029         * lib/unictype/categ_L.h: Likewise.
91030         * lib/unictype/categ_Ll.h: Likewise.
91031         * lib/unictype/categ_Lm.h: Likewise.
91032         * lib/unictype/categ_Lo.h: Likewise.
91033         * lib/unictype/categ_Lu.h: Likewise.
91034         * lib/unictype/categ_M.h: Likewise.
91035         * lib/unictype/categ_Mc.h: Likewise.
91036         * lib/unictype/categ_Me.h: Likewise.
91037         * lib/unictype/categ_Mn.h: Likewise.
91038         * lib/unictype/categ_N.h: Likewise.
91039         * lib/unictype/categ_Nd.h: Likewise.
91040         * lib/unictype/categ_No.h: Likewise.
91041         * lib/unictype/categ_P.h: Likewise.
91042         * lib/unictype/categ_Po.h: Likewise.
91043         * lib/unictype/categ_S.h: Likewise.
91044         * lib/unictype/categ_Sc.h: Likewise.
91045         * lib/unictype/categ_Sk.h: Likewise.
91046         * lib/unictype/categ_Sm.h: Likewise.
91047         * lib/unictype/categ_So.h: Likewise.
91048         * lib/unictype/categ_of.h: Likewise.
91049         * lib/unictype/combining.h: Likewise.
91050         * lib/unictype/ctype_alnum.h: Likewise.
91051         * lib/unictype/ctype_alpha.h: Likewise.
91052         * lib/unictype/ctype_graph.h: Likewise.
91053         * lib/unictype/ctype_lower.h: Likewise.
91054         * lib/unictype/ctype_print.h: Likewise.
91055         * lib/unictype/ctype_punct.h: Likewise.
91056         * lib/unictype/ctype_upper.h: Likewise.
91057         * lib/unictype/decdigit.h: Likewise.
91058         * lib/unictype/digit.h: Likewise.
91059         * lib/unictype/numeric.h: Likewise.
91060         * lib/unictype/pr_alphabetic.h: Likewise.
91061         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
91062         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
91063         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
91064         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
91065         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
91066         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
91067         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
91068         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
91069         * lib/unictype/pr_case_ignorable.h: Likewise.
91070         * lib/unictype/pr_cased.h: Likewise.
91071         * lib/unictype/pr_changes_when_casefolded.h: Likewise.
91072         * lib/unictype/pr_changes_when_casemapped.h: Likewise.
91073         * lib/unictype/pr_changes_when_lowercased.h: Likewise.
91074         * lib/unictype/pr_changes_when_titlecased.h: Likewise.
91075         * lib/unictype/pr_changes_when_uppercased.h: Likewise.
91076         * lib/unictype/pr_combining.h: Likewise.
91077         * lib/unictype/pr_composite.h: Likewise.
91078         * lib/unictype/pr_currency_symbol.h: Likewise.
91079         * lib/unictype/pr_decimal_digit.h: Likewise.
91080         * lib/unictype/pr_deprecated.h: Likewise.
91081         * lib/unictype/pr_format_control.h: Likewise.
91082         * lib/unictype/pr_grapheme_base.h: Likewise.
91083         * lib/unictype/pr_grapheme_extend.h: Likewise.
91084         * lib/unictype/pr_grapheme_link.h: Likewise.
91085         * lib/unictype/pr_id_continue.h: Likewise.
91086         * lib/unictype/pr_id_start.h: Likewise.
91087         * lib/unictype/pr_ideographic.h: Likewise.
91088         * lib/unictype/pr_lowercase.h: Likewise.
91089         * lib/unictype/pr_math.h: Likewise.
91090         * lib/unictype/pr_numeric.h: Likewise.
91091         * lib/unictype/pr_other_alphabetic.h: Likewise.
91092         * lib/unictype/pr_other_id_continue.h: Likewise.
91093         * lib/unictype/pr_other_math.h: Likewise.
91094         * lib/unictype/pr_punctuation.h: Likewise.
91095         * lib/unictype/pr_sentence_terminal.h: Likewise.
91096         * lib/unictype/pr_terminal_punctuation.h: Likewise.
91097         * lib/unictype/pr_unassigned_code_value.h: Likewise.
91098         * lib/unictype/pr_unified_ideograph.h: Likewise.
91099         * lib/unictype/pr_uppercase.h: Likewise.
91100         * lib/unictype/pr_xid_continue.h: Likewise.
91101         * lib/unictype/pr_xid_start.h: Likewise.
91102         * lib/unictype/scripts.h: Likewise.
91103         * lib/unictype/scripts_byname.gperf: Likewise.
91104         * lib/unictype/sy_java_ident.h: Likewise.
91105         * lib/unigbrk/gbrkprop.h: Likewise.
91106         * lib/unilbrk/lbrkprop1.h: Likewise.
91107         * lib/unilbrk/lbrkprop2.h: Likewise.
91108         * lib/uninorm/decomposition-table2.h: Likewise.
91109         * lib/uniwbrk/wbrkprop.h: Likewise.
91110         * tests/unicase/test-cased.c: Likewise.
91111         * tests/unicase/test-ignorable.c: Likewise.
91112         * tests/unicase/test-uc_tolower.c: Likewise.
91113         * tests/unicase/test-uc_totitle.c: Likewise.
91114         * tests/unicase/test-uc_toupper.c: Likewise.
91115         * tests/unictype/test-categ_C.c: Likewise.
91116         * tests/unictype/test-categ_Cn.c: Likewise.
91117         * tests/unictype/test-categ_L.c: Likewise.
91118         * tests/unictype/test-categ_Ll.c: Likewise.
91119         * tests/unictype/test-categ_Lm.c: Likewise.
91120         * tests/unictype/test-categ_Lo.c: Likewise.
91121         * tests/unictype/test-categ_Lu.c: Likewise.
91122         * tests/unictype/test-categ_M.c: Likewise.
91123         * tests/unictype/test-categ_Mc.c: Likewise.
91124         * tests/unictype/test-categ_Me.c: Likewise.
91125         * tests/unictype/test-categ_Mn.c: Likewise.
91126         * tests/unictype/test-categ_N.c: Likewise.
91127         * tests/unictype/test-categ_Nd.c: Likewise.
91128         * tests/unictype/test-categ_No.c: Likewise.
91129         * tests/unictype/test-categ_P.c: Likewise.
91130         * tests/unictype/test-categ_Po.c: Likewise.
91131         * tests/unictype/test-categ_S.c: Likewise.
91132         * tests/unictype/test-categ_Sc.c: Likewise.
91133         * tests/unictype/test-categ_Sk.c: Likewise.
91134         * tests/unictype/test-categ_Sm.c: Likewise.
91135         * tests/unictype/test-categ_So.c: Likewise.
91136         * tests/unictype/test-ctype_alnum.c: Likewise.
91137         * tests/unictype/test-ctype_alpha.c: Likewise.
91138         * tests/unictype/test-ctype_graph.c: Likewise.
91139         * tests/unictype/test-ctype_lower.c: Likewise.
91140         * tests/unictype/test-ctype_print.c: Likewise.
91141         * tests/unictype/test-ctype_punct.c: Likewise.
91142         * tests/unictype/test-ctype_upper.c: Likewise.
91143         * tests/unictype/test-decdigit.h: Likewise.
91144         * tests/unictype/test-digit.h: Likewise.
91145         * tests/unictype/test-numeric.h: Likewise.
91146         * tests/unictype/test-pr_alphabetic.c: Likewise.
91147         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
91148         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Likewise.
91149         * tests/unictype/test-pr_bidi_boundary_neutral.c: Likewise.
91150         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
91151         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
91152         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
91153         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
91154         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
91155         * tests/unictype/test-pr_case_ignorable.c: Likewise.
91156         * tests/unictype/test-pr_cased.c: Likewise.
91157         * tests/unictype/test-pr_changes_when_casefolded.c: Likewise.
91158         * tests/unictype/test-pr_changes_when_casemapped.c: Likewise.
91159         * tests/unictype/test-pr_changes_when_lowercased.c: Likewise.
91160         * tests/unictype/test-pr_changes_when_titlecased.c: Likewise.
91161         * tests/unictype/test-pr_changes_when_uppercased.c: Likewise.
91162         * tests/unictype/test-pr_combining.c: Likewise.
91163         * tests/unictype/test-pr_composite.c: Likewise.
91164         * tests/unictype/test-pr_currency_symbol.c: Likewise.
91165         * tests/unictype/test-pr_decimal_digit.c: Likewise.
91166         * tests/unictype/test-pr_deprecated.c: Likewise.
91167         * tests/unictype/test-pr_format_control.c: Likewise.
91168         * tests/unictype/test-pr_grapheme_base.c: Likewise.
91169         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
91170         * tests/unictype/test-pr_grapheme_link.c: Likewise.
91171         * tests/unictype/test-pr_id_continue.c: Likewise.
91172         * tests/unictype/test-pr_id_start.c: Likewise.
91173         * tests/unictype/test-pr_ideographic.c: Likewise.
91174         * tests/unictype/test-pr_lowercase.c: Likewise.
91175         * tests/unictype/test-pr_math.c: Likewise.
91176         * tests/unictype/test-pr_numeric.c: Likewise.
91177         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
91178         * tests/unictype/test-pr_other_id_continue.c: Likewise.
91179         * tests/unictype/test-pr_other_math.c: Likewise.
91180         * tests/unictype/test-pr_punctuation.c: Likewise.
91181         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
91182         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
91183         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
91184         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
91185         * tests/unictype/test-pr_uppercase.c: Likewise.
91186         * tests/unictype/test-pr_xid_continue.c: Likewise.
91187         * tests/unictype/test-pr_xid_start.c: Likewise.
91188         * tests/unigbrk/test-uc-gbrk-prop.h: Likewise.
91189         * lib/unicase/special-casing-table.gperf: Regenerated; only comment
91190         changes.
91191         * lib/unictype/categ_Cc.h: Likewise.
91192         * lib/unictype/categ_Cf.h: Likewise.
91193         * lib/unictype/categ_Co.h: Likewise.
91194         * lib/unictype/categ_Cs.h: Likewise.
91195         * lib/unictype/categ_Lt.h: Likewise.
91196         * lib/unictype/categ_Nl.h: Likewise.
91197         * lib/unictype/categ_Pc.h: Likewise.
91198         * lib/unictype/categ_Pd.h: Likewise.
91199         * lib/unictype/categ_Pe.h: Likewise.
91200         * lib/unictype/categ_Pf.h: Likewise.
91201         * lib/unictype/categ_Pi.h: Likewise.
91202         * lib/unictype/categ_Ps.h: Likewise.
91203         * lib/unictype/categ_Z.h: Likewise.
91204         * lib/unictype/categ_Zl.h: Likewise.
91205         * lib/unictype/categ_Zp.h: Likewise.
91206         * lib/unictype/categ_Zs.h: Likewise.
91207         * lib/unictype/ctype_blank.h: Likewise.
91208         * lib/unictype/ctype_cntrl.h: Likewise.
91209         * lib/unictype/ctype_digit.h: Likewise.
91210         * lib/unictype/ctype_space.h: Likewise.
91211         * lib/unictype/ctype_xdigit.h: Likewise.
91212         * lib/unictype/mirror.h: Likewise.
91213         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
91214         * lib/unictype/pr_bidi_block_separator.h: Likewise.
91215         * lib/unictype/pr_bidi_common_separator.h: Likewise.
91216         * lib/unictype/pr_bidi_control.h: Likewise.
91217         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
91218         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
91219         * lib/unictype/pr_bidi_european_digit.h: Likewise.
91220         * lib/unictype/pr_bidi_pdf.h: Likewise.
91221         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
91222         * lib/unictype/pr_bidi_whitespace.h: Likewise.
91223         * lib/unictype/pr_dash.h: Likewise.
91224         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
91225         * lib/unictype/pr_diacritic.h: Likewise.
91226         * lib/unictype/pr_extender.h: Likewise.
91227         * lib/unictype/pr_hex_digit.h: Likewise.
91228         * lib/unictype/pr_hyphen.h: Likewise.
91229         * lib/unictype/pr_ids_binary_operator.h: Likewise.
91230         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
91231         * lib/unictype/pr_ignorable_control.h: Likewise.
91232         * lib/unictype/pr_iso_control.h: Likewise.
91233         * lib/unictype/pr_join_control.h: Likewise.
91234         * lib/unictype/pr_left_of_pair.h: Likewise.
91235         * lib/unictype/pr_line_separator.h: Likewise.
91236         * lib/unictype/pr_logical_order_exception.h: Likewise.
91237         * lib/unictype/pr_non_break.h: Likewise.
91238         * lib/unictype/pr_not_a_character.h: Likewise.
91239         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
91240         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
91241         * lib/unictype/pr_other_id_start.h: Likewise.
91242         * lib/unictype/pr_other_lowercase.h: Likewise.
91243         * lib/unictype/pr_other_uppercase.h: Likewise.
91244         * lib/unictype/pr_paired_punctuation.h: Likewise.
91245         * lib/unictype/pr_paragraph_separator.h: Likewise.
91246         * lib/unictype/pr_pattern_syntax.h: Likewise.
91247         * lib/unictype/pr_pattern_white_space.h: Likewise.
91248         * lib/unictype/pr_private_use.h: Likewise.
91249         * lib/unictype/pr_quotation_mark.h: Likewise.
91250         * lib/unictype/pr_radical.h: Likewise.
91251         * lib/unictype/pr_soft_dotted.h: Likewise.
91252         * lib/unictype/pr_space.h: Likewise.
91253         * lib/unictype/pr_titlecase.h: Likewise.
91254         * lib/unictype/pr_variation_selector.h: Likewise.
91255         * lib/unictype/pr_white_space.h: Likewise.
91256         * lib/unictype/pr_zero_width.h: Likewise.
91257         * lib/unictype/sy_c_ident.h: Likewise.
91258         * lib/unictype/sy_c_whitespace.h: Likewise.
91259         * lib/unictype/sy_java_whitespace.h: Likewise.
91260         * lib/uninorm/composition-table.gperf: Likewise.
91261         * lib/uninorm/decomposition-table1.h: Likewise.
91262         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add test for rule
91263         LB8.
91264         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
91265         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
91266         * modules/unictype/*: Bump version number of expected libunistring
91267         version.
91269 2011-01-09  Bruno Haible  <bruno@clisp.org>
91271         Update to Unicode 5.2.0.
91272         * tests/unigbrk/GraphemeBreakTest.txt: Copied from Unicode 5.2.0, with
91273         trailing whitespace removed.
91275 2011-01-09  Bruno Haible  <bruno@clisp.org>
91277         New Unicode character properties, from Unicode 5.2.0.
91278         * lib/unictype.in.h (UC_PROPERTY_CASED, UC_PROPERTY_CASE_IGNORABLE,
91279         UC_PROPERTY_CHANGES_WHEN_LOWERCASED,
91280         UC_PROPERTY_CHANGES_WHEN_UPPERCASED,
91281         UC_PROPERTY_CHANGES_WHEN_TITLECASED,
91282         UC_PROPERTY_CHANGES_WHEN_CASEFOLDED,
91283         UC_PROPERTY_CHANGES_WHEN_CASEMAPPED,
91284         uc_is_property_cased, uc_is_property_case_ignorable,
91285         uc_is_property_changes_when_lowercased,
91286         uc_is_property_changes_when_uppercased,
91287         uc_is_property_changes_when_titlecased,
91288         uc_is_property_changes_when_casefolded,
91289         uc_is_property_changes_when_casemapped): New declarations.
91290         * lib/unictype/pr_byname.gperf: Add the new properties.
91291         * modules/unictype/property-byname (Depends-on): Depend on the new
91292         properties modules.
91293         * modules/unictype/property-all (Depends-on): Likewise.
91294         * MODULES.html.sh (Unicode string functions): Add
91295         unictype/property-case-ignorable, unictype/property-cased,
91296         unictype/property-changes-when-casefolded,
91297         unictype/property-changes-when-casemapped,
91298         unictype/property-changes-when-lowercased,
91299         unictype/property-changes-when-titlecased,
91300         unictype/property-changes-when-uppercased.
91302         New module 'unictype/property-changes-when-casemapped'.
91303         * modules/unictype/property-changes-when-casemapped: New file.
91304         * lib/unictype/pr_changes_when_casemapped.c: New file.
91305         * lib/unictype/pr_changes_when_casemapped.h: New file, automatically
91306         generated by gen-uni-tables.
91307         * modules/unictype/property-changes-when-casemapped-tests: New file.
91308         * tests/unictype/test-pr_changes_when_casemapped.c: New file,
91309         automatically generated by gen-uni-tables.
91311         New module 'unictype/property-changes-when-casefolded'.
91312         * modules/unictype/property-changes-when-casefolded: New file.
91313         * lib/unictype/pr_changes_when_casefolded.c: New file.
91314         * lib/unictype/pr_changes_when_casefolded.h: New file, automatically
91315         generated by gen-uni-tables.
91316         * modules/unictype/property-changes-when-casefolded-tests: New file.
91317         * tests/unictype/test-pr_changes_when_casefolded.c: New file,
91318         automatically generated by gen-uni-tables.
91320         New module 'unictype/property-changes-when-titlecased'.
91321         * modules/unictype/property-changes-when-titlecased: New file.
91322         * lib/unictype/pr_changes_when_titlecased.c: New file.
91323         * lib/unictype/pr_changes_when_titlecased.h: New file, automatically
91324         generated by gen-uni-tables.
91325         * modules/unictype/property-changes-when-titlecased-tests: New file.
91326         * tests/unictype/test-pr_changes_when_titlecased.c: New file,
91327         automatically generated by gen-uni-tables.
91329         New module 'unictype/property-changes-when-uppercased'.
91330         * modules/unictype/property-changes-when-uppercased: New file.
91331         * lib/unictype/pr_changes_when_uppercased.c: New file.
91332         * lib/unictype/pr_changes_when_uppercased.h: New file, automatically
91333         generated by gen-uni-tables.
91334         * modules/unictype/property-changes-when-uppercased-tests: New file.
91335         * tests/unictype/test-pr_changes_when_uppercased.c: New file,
91336         automatically generated by gen-uni-tables.
91338         New module 'unictype/property-changes-when-lowercased'.
91339         * modules/unictype/property-changes-when-lowercased: New file.
91340         * lib/unictype/pr_changes_when_lowercased.c: New file.
91341         * lib/unictype/pr_changes_when_lowercased.h: New file, automatically
91342         generated by gen-uni-tables.
91343         * modules/unictype/property-changes-when-lowercased-tests: New file.
91344         * tests/unictype/test-pr_changes_when_lowercased.c: New file,
91345         automatically generated by gen-uni-tables.
91347         New module 'unictype/property-case-ignorable'.
91348         * modules/unictype/property-case-ignorable: New file.
91349         * lib/unictype/pr_case_ignorable.c: New file.
91350         * lib/unictype/pr_case_ignorable.h: New file, automatically generated
91351         by gen-uni-tables.
91352         * modules/unictype/property-case-ignorable-tests: New file.
91353         * tests/unictype/test-pr_case_ignorable.c: New file, automatically
91354         generated by gen-uni-tables.
91356         New module 'unictype/property-cased'.
91357         * modules/unictype/property-cased: New file.
91358         * lib/unictype/pr_cased.c: New file.
91359         * lib/unictype/pr_cased.h: New file, automatically generated by
91360         gen-uni-tables.
91361         * modules/unictype/property-cased-tests: New file.
91362         * tests/unictype/test-pr_cased.c: New file, automatically generated by
91363         gen-uni-tables.
91365 2011-01-09  Bruno Haible  <bruno@clisp.org>
91367         Update to Unicode 5.2.0.
91368         * lib/gen-uni-tables.c (output_predicate, output_category,
91369         output_combclass, output_bidi_category, output_decimal_digit_test,
91370         output_decimal_digit, output_digit_test, output_digit,
91371         output_numeric_test, output_numeric, output_mirror, output_scripts,
91372         output_scripts_byname, output_blocks, output_ident_category): Fix
91373         comment header.
91374         (is_WBP_MIDNUMLET, is_WBP_MIDLETTER): New functions, extracted from
91375         get_wbp.
91376         (PROP_CASED, PROP_CASE_IGNORABLE, PROP_CHANGES_WHEN_*): New enumeration
91377         items.
91378         (fill_properties): Also fill the peoperties Cased, Case_Ignorable,
91379         Changes_When_Lowercased, Changes_When_Uppercased,
91380         Changes_When_Titlecased, Changes_When_Casefolded,
91381         Changes_When_Casemapped.
91382         (is_property_alphabetic, is_property_default_ignorable_code_point):
91383         Update for Unicode 5.2.0.
91384         (is_property_cased, is_property_case_ignorable,
91385         is_property_changes_when_lowercased,
91386         is_property_changes_when_uppercased,
91387         is_property_changes_when_titlecased,
91388         is_property_changes_when_casefolded,
91389         is_property_changes_when_casemapped): New functions.
91390         (output_properties): Output also the properties cased, case_ignorable,
91391         changes_when_lowercased, changes_when_uppercased,
91392         changes_when_titlecased, changes_when_casefolded,
91393         changes_when_casemapped.
91394         (symbolic_width): Update for Unicode 5.2.0, incorporating changes from
91395         Unicode TR#11 revision 17 -> 19.
91396         (LBP_CP): New enumeration value.
91397         (LBP_*): Adjust values accordingly.
91398         (get_lbp): Update for Unicode 5.2.0, incorporating changes from Unicode
91399         TR#14 revision 22 -> 24.
91400         (debug_output_lbp): Allow for LBP_* bits >= 32. Support LBP_CP.
91401         (fill_org_lbp, debug_output_org_lbp, output_lbp): Support LBP_CP.
91402         (get_wbp): Update for Unicode 5.2.0, incorporating changes from Unicode
91403         TR#29 revision 13 -> 15. Use functions is_WBP_MIDNUMLET,
91404         is_WBP_MIDLETTER.
91405         (output_composition_tables): Allow for 24 bits instead of 16 bits in
91406         the code1 and code2 of each composition rule.
91407         * lib/unicase/cased.h: Regenerated for Unicode 5.2.0.
91408         * lib/unicase/ignorable.h: Likewise.
91409         * lib/unicase/tocasefold.h: Likewise.
91410         * lib/unicase/tolower.h: Likewise.
91411         * lib/unicase/totitle.h: Likewise.
91412         * lib/unicase/toupper.h: Likewise.
91413         * lib/unictype/bidi_of.h: Likewise.
91414         * lib/unictype/blocks.h: Likewise.
91415         * lib/unictype/categ_C.h: Likewise.
91416         * lib/unictype/categ_Cf.h: Likewise.
91417         * lib/unictype/categ_Cn.h: Likewise.
91418         * lib/unictype/categ_L.h: Likewise.
91419         * lib/unictype/categ_Ll.h: Likewise.
91420         * lib/unictype/categ_Lm.h: Likewise.
91421         * lib/unictype/categ_Lo.h: Likewise.
91422         * lib/unictype/categ_Lu.h: Likewise.
91423         * lib/unictype/categ_M.h: Likewise.
91424         * lib/unictype/categ_Mc.h: Likewise.
91425         * lib/unictype/categ_Mn.h: Likewise.
91426         * lib/unictype/categ_N.h: Likewise.
91427         * lib/unictype/categ_Nd.h: Likewise.
91428         * lib/unictype/categ_Nl.h: Likewise.
91429         * lib/unictype/categ_No.h: Likewise.
91430         * lib/unictype/categ_P.h: Likewise.
91431         * lib/unictype/categ_Pd.h: Likewise.
91432         * lib/unictype/categ_Po.h: Likewise.
91433         * lib/unictype/categ_S.h: Likewise.
91434         * lib/unictype/categ_Sc.h: Likewise.
91435         * lib/unictype/categ_So.h: Likewise.
91436         * lib/unictype/categ_of.h: Likewise.
91437         * lib/unictype/combining.h: Likewise.
91438         * lib/unictype/ctype_alnum.h: Likewise.
91439         * lib/unictype/ctype_alpha.h: Likewise.
91440         * lib/unictype/ctype_graph.h: Likewise.
91441         * lib/unictype/ctype_lower.h: Likewise.
91442         * lib/unictype/ctype_print.h: Likewise.
91443         * lib/unictype/ctype_punct.h: Likewise.
91444         * lib/unictype/ctype_upper.h: Likewise.
91445         * lib/unictype/decdigit.h: Likewise.
91446         * lib/unictype/digit.h: Likewise.
91447         * lib/unictype/numeric.h: Likewise.
91448         * lib/unictype/pr_alphabetic.h: Likewise.
91449         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
91450         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
91451         * lib/unictype/pr_bidi_european_digit.h: Likewise.
91452         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
91453         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
91454         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
91455         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
91456         * lib/unictype/pr_combining.h: Likewise.
91457         * lib/unictype/pr_composite.h: Likewise.
91458         * lib/unictype/pr_currency_symbol.h: Likewise.
91459         * lib/unictype/pr_dash.h: Likewise.
91460         * lib/unictype/pr_decimal_digit.h: Likewise.
91461         * lib/unictype/pr_deprecated.h: Likewise.
91462         * lib/unictype/pr_diacritic.h: Likewise.
91463         * lib/unictype/pr_extender.h: Likewise.
91464         * lib/unictype/pr_grapheme_base.h: Likewise.
91465         * lib/unictype/pr_grapheme_extend.h: Likewise.
91466         * lib/unictype/pr_grapheme_link.h: Likewise.
91467         * lib/unictype/pr_id_continue.h: Likewise.
91468         * lib/unictype/pr_id_start.h: Likewise.
91469         * lib/unictype/pr_ideographic.h: Likewise.
91470         * lib/unictype/pr_ignorable_control.h: Likewise.
91471         * lib/unictype/pr_logical_order_exception.h: Likewise.
91472         * lib/unictype/pr_lowercase.h: Likewise.
91473         * lib/unictype/pr_numeric.h: Likewise.
91474         * lib/unictype/pr_other_alphabetic.h: Likewise.
91475         * lib/unictype/pr_punctuation.h: Likewise.
91476         * lib/unictype/pr_sentence_terminal.h: Likewise.
91477         * lib/unictype/pr_terminal_punctuation.h: Likewise.
91478         * lib/unictype/pr_unassigned_code_value.h: Likewise.
91479         * lib/unictype/pr_unified_ideograph.h: Likewise.
91480         * lib/unictype/pr_uppercase.h: Likewise.
91481         * lib/unictype/pr_xid_continue.h: Likewise.
91482         * lib/unictype/pr_xid_start.h: Likewise.
91483         * lib/unictype/pr_zero_width.h: Likewise.
91484         * lib/unictype/scripts.h: Likewise.
91485         * lib/unictype/scripts_byname.gperf: Likewise.
91486         * lib/unictype/sy_java_ident.h: Likewise.
91487         * lib/unigbrk/gbrkprop.h: Likewise.
91488         * lib/unilbrk/lbrkprop1.h: Likewise.
91489         * lib/unilbrk/lbrkprop2.h: Likewise.
91490         * lib/unilbrk/lbrktables.h: Likewise.
91491         * lib/unilbrk/lbrktables.c (unilbrk_table): Add a row and column for
91492         LBP_CP. Implement rule LB30.
91493         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0816..U+0819,
91494         U+081B..U+0823, U+0825..U+0827, U+0829..U+082D, U+0900, U+0955, U+109D,
91495         U+1A56, U+1A58..U+1A5E, U+1A60, U+1A62, U+1A65..U+1A6C, U+1A73..U+1A7C,
91496         U+1A7F, U+1CD0..U+1CD2, U+1CD4..U+1CE0, U+1CE2..U+1CE8, U+1CED, U+1DFD,
91497         U+2CEF..U+2CF1, U+A6F0..U+A6F1, U+A8E0..U+A8F1, U+A980..U+A982, U+A9B3,
91498         U+A9B6..U+A9B9, U+A9BC, U+AAB0, U+AAB2..U+AAB4, U+AAB7..U+AAB8,
91499         U+AABE..U+AABF, U+AAC1, U+ABE5, U+ABE8, U+ABED, U+11080..U+11081,
91500         U+110B3..U+110B6, U+110B9..U+110BA, U+110BD.
91501         (uc_width): Return 2 also for unassigned code points of planes 2 and 3.
91502         * lib/uninorm/composition-table.gperf: Regenerated for Unicode 5.2.0.
91503         * lib/uninorm/composition.c (struct composition_rule): Allow for 24
91504         bits instead of 16 bits in the code1 and code2 of each composition
91505         rule.
91506         (uc_composition): Update for Unicode 5.2.0.
91507         * lib/uninorm/decomposition-table1.h: Regenerated for Unicode 5.2.0.
91508         * lib/uninorm/decomposition-table2.h: Likewise.
91509         * lib/uniwbrk/wbrkprop.h: Likewise.
91510         * tests/unicase/test-cased.c: Likewise.
91511         * tests/unicase/test-ignorable.c: Likewise.
91512         * tests/unicase/test-uc_tolower.c: Likewise.
91513         * tests/unicase/test-uc_totitle.c: Likewise.
91514         * tests/unicase/test-uc_toupper.c: Likewise.
91515         * tests/unictype/test-categ_C.c: Likewise.
91516         * tests/unictype/test-categ_Cf.c: Likewise.
91517         * tests/unictype/test-categ_Cn.c: Likewise.
91518         * tests/unictype/test-categ_L.c: Likewise.
91519         * tests/unictype/test-categ_Ll.c: Likewise.
91520         * tests/unictype/test-categ_Lm.c: Likewise.
91521         * tests/unictype/test-categ_Lo.c: Likewise.
91522         * tests/unictype/test-categ_Lu.c: Likewise.
91523         * tests/unictype/test-categ_M.c: Likewise.
91524         * tests/unictype/test-categ_Mc.c: Likewise.
91525         * tests/unictype/test-categ_Mn.c: Likewise.
91526         * tests/unictype/test-categ_N.c: Likewise.
91527         * tests/unictype/test-categ_Nd.c: Likewise.
91528         * tests/unictype/test-categ_Nl.c: Likewise.
91529         * tests/unictype/test-categ_No.c: Likewise.
91530         * tests/unictype/test-categ_P.c: Likewise.
91531         * tests/unictype/test-categ_Pd.c: Likewise.
91532         * tests/unictype/test-categ_Po.c: Likewise.
91533         * tests/unictype/test-categ_S.c: Likewise.
91534         * tests/unictype/test-categ_Sc.c: Likewise.
91535         * tests/unictype/test-categ_So.c: Likewise.
91536         * tests/unictype/test-ctype_alnum.c: Likewise.
91537         * tests/unictype/test-ctype_alpha.c: Likewise.
91538         * tests/unictype/test-ctype_graph.c: Likewise.
91539         * tests/unictype/test-ctype_lower.c: Likewise.
91540         * tests/unictype/test-ctype_print.c: Likewise.
91541         * tests/unictype/test-ctype_punct.c: Likewise.
91542         * tests/unictype/test-ctype_upper.c: Likewise.
91543         * tests/unictype/test-decdigit.h: Likewise.
91544         * tests/unictype/test-digit.h: Likewise.
91545         * tests/unictype/test-numeric.h: Likewise.
91546         * tests/unictype/test-pr_alphabetic.c: Likewise.
91547         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
91548         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
91549         * tests/unictype/test-pr_bidi_european_digit.c: Likewise.
91550         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
91551         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
91552         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
91553         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
91554         * tests/unictype/test-pr_combining.c: Likewise.
91555         * tests/unictype/test-pr_composite.c: Likewise.
91556         * tests/unictype/test-pr_currency_symbol.c: Likewise.
91557         * tests/unictype/test-pr_dash.c: Likewise.
91558         * tests/unictype/test-pr_decimal_digit.c: Likewise.
91559         * tests/unictype/test-pr_deprecated.c: Likewise.
91560         * tests/unictype/test-pr_diacritic.c: Likewise.
91561         * tests/unictype/test-pr_extender.c: Likewise.
91562         * tests/unictype/test-pr_grapheme_base.c: Likewise.
91563         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
91564         * tests/unictype/test-pr_grapheme_link.c: Likewise.
91565         * tests/unictype/test-pr_id_continue.c: Likewise.
91566         * tests/unictype/test-pr_id_start.c: Likewise.
91567         * tests/unictype/test-pr_ideographic.c: Likewise.
91568         * tests/unictype/test-pr_ignorable_control.c: Likewise.
91569         * tests/unictype/test-pr_logical_order_exception.c: Likewise.
91570         * tests/unictype/test-pr_lowercase.c: Likewise.
91571         * tests/unictype/test-pr_numeric.c: Likewise.
91572         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
91573         * tests/unictype/test-pr_punctuation.c: Likewise.
91574         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
91575         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
91576         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
91577         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
91578         * tests/unictype/test-pr_uppercase.c: Likewise.
91579         * tests/unictype/test-pr_xid_continue.c: Likewise.
91580         * tests/unictype/test-pr_xid_start.c: Likewise.
91581         * tests/unictype/test-pr_zero_width.c: Likewise.
91582         * tests/unigbrk/test-uc-gbrk-prop.h: Likewise.
91583         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update for
91584         changed behaviour: line breaking is now disallowed between a letter
91585         or '=' and '('.
91586         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
91587         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
91588         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
91589         * tests/unilbrk/test-ulc-width-linebreaks.c (main): Likewise.
91590         * tests/uniwidth/test-uc_width2.sh: Same updates as in
91591         lib/uniwidth/width.c.
91592         * tests/uninorm/NormalizationTest.txt: Update from Unicode 5.2.0,
91593         without comments, but with the original copyright notice.
91594         * lib/unicase/special-casing-table.gperf: Regenerated; only comment
91595         changes.
91596         * lib/unictype/categ_Cc.h: Likewise.
91597         * lib/unictype/categ_Co.h: Likewise.
91598         * lib/unictype/categ_Cs.h: Likewise.
91599         * lib/unictype/categ_Lt.h: Likewise.
91600         * lib/unictype/categ_Me.h: Likewise.
91601         * lib/unictype/categ_Pc.h: Likewise.
91602         * lib/unictype/categ_Pe.h: Likewise.
91603         * lib/unictype/categ_Pf.h: Likewise.
91604         * lib/unictype/categ_Pi.h: Likewise.
91605         * lib/unictype/categ_Ps.h: Likewise.
91606         * lib/unictype/categ_Sk.h: Likewise.
91607         * lib/unictype/categ_Sm.h: Likewise.
91608         * lib/unictype/categ_Z.h: Likewise.
91609         * lib/unictype/categ_Zl.h: Likewise.
91610         * lib/unictype/categ_Zp.h: Likewise.
91611         * lib/unictype/categ_Zs.h: Likewise.
91612         * lib/unictype/ctype_blank.h: Likewise.
91613         * lib/unictype/ctype_cntrl.h: Likewise.
91614         * lib/unictype/ctype_digit.h: Likewise.
91615         * lib/unictype/ctype_space.h: Likewise.
91616         * lib/unictype/ctype_xdigit.h: Likewise.
91617         * lib/unictype/mirror.h: Likewise.
91618         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
91619         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
91620         * lib/unictype/pr_bidi_block_separator.h: Likewise.
91621         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
91622         * lib/unictype/pr_bidi_common_separator.h: Likewise.
91623         * lib/unictype/pr_bidi_control.h: Likewise.
91624         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
91625         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
91626         * lib/unictype/pr_bidi_pdf.h: Likewise.
91627         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
91628         * lib/unictype/pr_bidi_whitespace.h: Likewise.
91629         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
91630         * lib/unictype/pr_format_control.h: Likewise.
91631         * lib/unictype/pr_hex_digit.h: Likewise.
91632         * lib/unictype/pr_hyphen.h: Likewise.
91633         * lib/unictype/pr_ids_binary_operator.h: Likewise.
91634         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
91635         * lib/unictype/pr_iso_control.h: Likewise.
91636         * lib/unictype/pr_join_control.h: Likewise.
91637         * lib/unictype/pr_left_of_pair.h: Likewise.
91638         * lib/unictype/pr_line_separator.h: Likewise.
91639         * lib/unictype/pr_math.h: Likewise.
91640         * lib/unictype/pr_non_break.h: Likewise.
91641         * lib/unictype/pr_not_a_character.h: Likewise.
91642         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
91643         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
91644         * lib/unictype/pr_other_id_continue.h: Likewise.
91645         * lib/unictype/pr_other_id_start.h: Likewise.
91646         * lib/unictype/pr_other_lowercase.h: Likewise.
91647         * lib/unictype/pr_other_math.h: Likewise.
91648         * lib/unictype/pr_other_uppercase.h: Likewise.
91649         * lib/unictype/pr_paired_punctuation.h: Likewise.
91650         * lib/unictype/pr_paragraph_separator.h: Likewise.
91651         * lib/unictype/pr_pattern_syntax.h: Likewise.
91652         * lib/unictype/pr_pattern_white_space.h: Likewise.
91653         * lib/unictype/pr_private_use.h: Likewise.
91654         * lib/unictype/pr_quotation_mark.h: Likewise.
91655         * lib/unictype/pr_radical.h: Likewise.
91656         * lib/unictype/pr_soft_dotted.h: Likewise.
91657         * lib/unictype/pr_space.h: Likewise.
91658         * lib/unictype/pr_titlecase.h: Likewise.
91659         * lib/unictype/pr_variation_selector.h: Likewise.
91660         * lib/unictype/pr_white_space.h: Likewise.
91661         * lib/unictype/sy_c_ident.h: Likewise.
91662         * lib/unictype/sy_c_whitespace.h: Likewise.
91663         * lib/unictype/sy_java_whitespace.h: Likewise.
91664         * modules/uni*/*: Bump version number of expected libunistring version.
91665         Reported by Simon Josefsson.
91667 2011-01-09  Karl Heuer  <kwzh@gnu.org>
91669         useless-if-before-free: fix typo in --help and make the internal,
91670         automatic version date update process work once again.
91671         --help output contained a NUL character instead of the
91672         backslash-zero that was intended.  Also, the "must lie within
91673         the first 8 lines" line is on line 9, and hence not getting
91674         automatically updated.
91675         * build-aux/useless-if-before-free: Fix the former by adding a
91676         backslash, and the latter by condensing the three lines of what-it-does
91677         to a single line, leaving one line of slack for the future.
91679 2011-01-09  Bruno Haible  <bruno@clisp.org>
91681         uniwidth/width: Fix width of U+1D173..U+1D17A.
91682         * lib/gen-uni-tables.c (is_nonspacing, output_nonspacing_property,
91683         symbolic_width, output_width_property_test): New functions.
91684         (main): Invoke output_nonspacing_property, output_width_property_test.
91685         * lib/uniwidth/width.c (nonspacing_table_data): Set bits for
91686         U+1D173..U+1D17A.
91687         * tests/uniwidth/test-uc_width2.sh: For U+1D173..U+1D17A, expect 0, not
91688         1.
91689         * modules/uniwidth/*: Bump version number of expected libunistring
91690         version.
91691         * modules/unilbrk/*: Likewise.
91693 2011-01-08  Bruno Haible  <bruno@clisp.org>
91695         uninorm tests: Preserve copyright of Unicode data file.
91696         * tests/uninorm/NormalizationTest.txt: Re-add original copyright.
91697         Mention modifications.
91699 2011-01-08  Bruno Haible  <bruno@clisp.org>
91701         gen-uni-tables: Prepare for Unicode 5.2.0.
91702         * lib/gen-uni-tables.c (get_lbp): Allow for more than 32 LBP_* values.
91703         (debug_output_lbp, output_lbp): Update.
91705 2011-01-08  Bruno Haible  <bruno@clisp.org>
91707         unilbrk: Clarify gen-uni-tables.c code.
91708         * lib/gen-uni-tables.c (get_lbp): Assume REVISION_22 to be false. These
91709         were mistakes in UAX #14 revision 22 that are corrected in revision 24.
91710         Clarify what to do with unilbrk/lbrkprop.txt and uniwbrk/wbrkprop.txt.
91712 2011-01-07  Bruno Haible  <bruno@clisp.org>
91714         strtod: Restore errno when successfully parsing Infinity or NaN.
91715         * lib/strtod.c (strtod): After successfully parsing an Infinity or NaN,
91716         restore the original errno.
91718 2011-01-07  Bruno Haible  <bruno@clisp.org>
91720         remove test: Avoid failure on HP-UX 11.
91721         * tests/test-remove.c (main): Allow EEXIST as alternative error code.
91723 2011-01-07  Bruno Haible  <bruno@clisp.org>
91725         mkdir, mkdirat tests: Avoid failure on HP-UX 11.11.
91726         * tests/test-mkdir.h (test_mkdir): Allow EOPNOTSUPP as alternative
91727         error code.
91729 2011-01-07  Pádraig Brady  <P@draigBrady.com>
91731         ignore-value: fixup comments, and add Eric Blake
91732         as an author since he rewrote the macros.
91733         * lib/ignore-value.h (ignore_value):  State that
91734         we now support aggregates.  Also specify exactly
91735         when the GCC warn_unused_result feature was added.
91737 2011-01-06  Eric Blake  <eblake@redhat.com>
91739         ignore-value: support aggregate types
91740         * lib/ignore-value.h (ignore_value): Provide separate gcc
91741         definition.
91742         * modules/ignore-value-tests: New test module.
91743         * tests/test-ignore-value.c: New test.
91745         maint.mk: improve sc_prohibit_strcmp regex
91746         * top/maint.mk (sc_prohibit_strcmp): Detect strcmp()!=0, as
91747         documented.  Also, detect strcmp((expr),expr) == 0.  Exempt the
91748         definition of STRNEQ.
91750         signal: work around Haiku issue with SIGBUS
91751         * lib/siglist.h: Add comment.
91752         * lib/sig2str.c (numname_table): Swap SIGBUS order, to match
91753         strsignal's favoring of SIGSEGV.
91754         * tests/test-signal.c (main): Avoid test failure.
91755         * doc/posix-headers/signal.texi (signal.h): Document the issue.
91756         Reported by Scott McCreary.
91758         maint.mk: add pre-release check to ensure submodule commits are public
91759         * top/maint.mk (public-submodule-commit): New rule.
91760         (submodule-checks): New variable.
91761         (alpha beta stable): Depend on the variable.
91763 2011-01-05  Pádraig Brady  <P@draigBrady.com>
91764         and Jim Meyering  <meyering@redhat.com>
91766         ignore-value: make ignore_value more generic; deprecate ignore_ptr
91767         * lib/ignore-value.h: Include <stdint.h>, for decl of intptr_t.
91768         (ATTRIBUTE_DEPRECATED): Define.
91769         (_ignore_case): New function.
91770         (ignore_value): New macro, to replace the old function.
91771         (ignore_ptr): Arrange for any use to evoke a deprecation warning.
91772         * modules/ignore-value (Depends-on): Add stdint.
91774 2011-01-04  Eric Blake  <eblake@redhat.com>
91776         doc: regenerate INSTALL
91777         * doc/Makefile (INSTALL, INSTALL.ISO, INSTALL.UTF-8): Re-add
91778         @firstparagraphindent support, now that autoconf dropped it.
91779         (INSTALL_PRELUDE): Reinstate old macro.
91780         * doc/install.texi: Resync from autoconf.
91781         * doc/INSTALL: Reflect recent autoconf update.
91782         * doc/INSTALL.ISO: Likewise.
91783         * doc/INSTALL.UTF-8: Likewise.
91784         Reported by Karl Berry.
91786 2011-01-04  Bruce Korb  <address@hidden>
91788         git-version-gen: avoid a sub-shell
91789         * build-aux/git-version-gen: Redirect stderr in `...` via
91790         "exec 2>...", rather than via an added sub-shell.
91792 2011-01-03  Ben Pfaff  <blp@cs.stanford.edu>
91794         git-version-gen: use (...) rather than sh -c '...'
91795         * build-aux/git-version-gen: Rather than hard-coding a shell's name
91796         with "sh -c '...'", just use "(...)".  Less syntax is better, too.
91798 2011-01-03  Jim Meyering  <meyering@redhat.com>
91800         git-version-gen: convert leading TABs to spaces
91801         * build-aux/git-version-gen: Expand leading TABs.
91803         git-version-gen: handle failed "git rev-list"
91804         * build-aux/git-version-gen: Rather than leaking a "fatal" error
91805         from git and proceeding as if it had succeeded but printed no SHA1
91806         checksums, suppress the diagnostic and handle the failure.
91807         Reported by Bruce Korb in http://marc.info/?l=git&m=129399145930450&w=2
91809         git-version-gen: include command name in one more diagnostic
91810         * build-aux/git-version-gen: When the required .tarball-version file
91811         was missing or unreadable, you might see the diagnostic from "cat",
91812         but no trace of the name of the invoking script.  Now, you still see
91813         the diagnostic from cat, but also get one from "git-version-gen: ".
91814         Inspired by a patch from Bruce Korb.
91816         update-copyright: adjust test to match changed code
91817         * tests/test-update-copyright.sh: Change test's expected output
91818         to match new actual output.
91820 2011-01-02  Bruno Haible  <bruno@clisp.org>
91822         getlogin_r: Avoid test failure on HP-UX 11.
91823         * tests/test-getlogin_r.c (main): Allow an error code EINVAL instead of
91824         ERANGE when the second argument is zero.
91825         * doc/posix-functions/getlogin_r.texi: Document the HP-UX 11
91826         portability problem.
91828 2011-01-02  Bruce Korb  <bkorb@gnu.org>
91830         * build-aux/update-copyright: doc Simon's changes
91832 2011-01-02  Simon Josefsson  <simon@josefsson.org>
91834         * build-aux/update-copyright: Support UPDATE_COPYRIGHT_HOLDER
91835         environment variable.
91837 2011-01-02  Bruno Haible  <bruno@clisp.org>
91839         unigbrk: Avoid gcc warnings.
91840         * lib/unigbrk/u16-grapheme-breaks.c (u16_grapheme_breaks): Remove
91841         unused variable.
91842         * lib/unigbrk/u16-grapheme-prev.c (u16_grapheme_prev): Likewise.
91843         * lib/unigbrk/u8-grapheme-prev.c (u8_grapheme_prev): Likewise.
91844         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
91845         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
91846         * tests/unigbrk/test-u8-grapheme-breaks.c (test_u8_grapheme_breaks):
91847         Change type of first argument to 'const char *'.
91848         (main): Remove unused variable.
91849         * tests/unigbrk/test-u8-grapheme-next.c (test_u8_grapheme_next): Change
91850         type of first argument to 'const char *'.
91851         * tests/unigbrk/test-u8-grapheme-prev.c (test_u8_grapheme_prev):
91852         Likewise.
91853         (main): Change type of variable 's'.
91854         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Cast column number
91855         to 'int'.
91857 2011-01-02  Bruno Haible  <bruno@clisp.org>
91859         pwrite: Fix test whether it works and make it work on HP-UX 11.11.
91860         * m4/pwrite.m4 (gl_FUNC_PWRITE): Use AC_LANG_PROGRAM, not
91861         AC_LANG_SOURCE. Extend the test program to catch another HP-UX 11.11
91862         bug.
91863         * lib/pwrite.c: Undo 2010-12-31 patch.
91864         * doc/posix-functions/pwrite.texi: Document another HP-UX 11.11 bug.
91866 2011-01-02  Bruno Haible  <bruno@clisp.org>
91868         pread: Fix test whether it works.
91869         * m4/pread.m4 (gl_FUNC_PREAD): Use AC_LANG_PROGRAM, not AC_LANG_SOURCE.
91871 2011-01-02  Bruno Haible  <bruno@clisp.org>
91873         Fix detection of traditional Arabic locale on HP-UX, Solaris, Cygwin.
91874         * m4/locale-ar.m4 (gt_LOCALE_AR): Require that the locale encoding name
91875         ends in "6". Don't require a specific month name. Try also the locale
91876         names found on HP-UX 11 and Solaris 7.
91878 2011-01-02  Bruno Haible  <bruno@clisp.org>
91880         tcgetsid: Correct linkage in C++ mode on HP-UX 11.00.
91881         * lib/termios.in.h: In C++ mode, on HP-UX, include <sys/termios.h> with
91882         C linkage.
91883         * doc/posix-functions/tcgetsid.texi: Mention the HP-UX 11.00 bug.
91885 2011-01-01  Ben Pfaff  <blp@cs.stanford.edu>
91887         Rename uc_is_grapheme_cluster_break() to uc_is_grapheme_break()
91888         for consistency, since the "cluster" term is not used elsewhere.
91889         * lib/unigbrk.in.h: Update name.
91890         * lib/unigbrk/u16-grapheme-breaks.c: Update name.
91891         * lib/unigbrk/u16-grapheme-next.c: Update name.
91892         * lib/unigbrk/u16-grapheme-prev.c: Update name.
91893         * lib/unigbrk/u32-grapheme-breaks.c: Update name.
91894         * lib/unigbrk/u32-grapheme-next.c: Update name.
91895         * lib/unigbrk/u32-grapheme-prev.c: Update name.
91896         * lib/unigbrk/u8-grapheme-breaks.c: Update name.
91897         * lib/unigbrk/u8-grapheme-next.c: Update name.
91898         * lib/unigbrk/u8-grapheme-prev.c: Update name.
91899         * lib/unigbrk/uc-is-grapheme-break.c: Update name.
91900         * tests/unigbrk/test-uc-is-grapheme-break.c: Update name.
91901         Suggested by Bruno Haible.
91903 2011-01-01  Ben Pfaff  <blp@cs.stanford.edu>
91905         Remove module 'u8-grapheme-len' as too redundant with
91906         'u8-grapheme-next'.
91907         * modules/unigbrk/u8-grapheme-len: Delete file.
91908         * modules/unigbrk/u8-grapheme-len-tests: Delete file.
91909         * lib/unigbrk.in.h: Remove prototype for deleted function.
91910         * lib/unigbrk/u8-grapheme-len.c: Delete file.
91911         * tests/unigbrk/test-u8-grapheme-len.c: Delete file.
91913         Remove module 'u16-grapheme-len' as too redundant with
91914         'u16-grapheme-next'.
91915         * modules/unigbrk/u16-grapheme-len: Delete file.
91916         * modules/unigbrk/u16-grapheme-len-tests: Delete file.
91917         * lib/unigbrk.in.h: Remove prototype for deleted function.
91918         * lib/unigbrk/u16-grapheme-len.c: Delete file.
91919         * tests/unigbrk/test-u16-grapheme-len.c: Delete file.
91921         Remove module 'u32-grapheme-len' as too redundant with
91922         'u32-grapheme-next'.
91923         * modules/unigbrk/u32-grapheme-len: Delete file.
91924         * modules/unigbrk/u32-grapheme-len-tests: Delete file.
91925         * lib/unigbrk.in.h: Remove prototype for deleted function.
91926         * lib/unigbrk/u32-grapheme-len.c: Delete file.
91927         * tests/unigbrk/test-u32-grapheme-len.c: Delete file.
91929         Suggested by Bruno Haible.
91931 2011-01-01  Ben Pfaff  <blp@cs.stanford.edu>
91933         * unigbrk.in.h: Fix typo: "ben" => "been".
91934         Reported by Bruno Haible.
91936 2011-01-01  Jim Meyering  <meyering@redhat.com>
91938         maint: update almost all copyright ranges to include 2011
91939         Run the new "make update-copyright" rule.
91941 2011-01-01  Jim Meyering  <meyering@redhat.com>
91943         maint: update-copyright: exempt doc/INSTALL*
91944         * Makefile (update-copyright): Also exclude doc/INSTALL*,
91945         since they are generated.  Suggested by Bruno Haible.
91947 2011-01-01  Jim Meyering  <meyering@redhat.com>
91949         maint: refine the update-copyright rule
91950         * Makefile (update-copyright): Also exclude any file that includes
91951         the "GENERATED AUTOMATICALLY" comment, being careful not to exclude
91952         code that merely generates the comment.
91954 2010-12-31  Ben Pfaff  <blp@cs.stanford.edu>
91956         New module 'u8-grapheme-len'.
91957         * modules/unigbrk/u8-grapheme-len: New file.
91958         * modules/unigbrk/u8-grapheme-len-tests: New file.
91959         * lib/unigbrk.in.h: Add prototype for new function.
91960         * lib/unigbrk/u8-grapheme-len.c: New file.
91961         * tests/unigbrk/test-u8-grapheme-len.c: New file.
91963         New module 'u16-grapheme-len'.
91964         * modules/unigbrk/u16-grapheme-len: New file.
91965         * modules/unigbrk/u16-grapheme-len-tests: New file.
91966         * lib/unigbrk.in.h: Add prototype for new function.
91967         * lib/unigbrk/u16-grapheme-len.c: New file.
91968         * tests/unigbrk/test-u16-grapheme-len.c: New file.
91970         New module 'u32-grapheme-len'.
91971         * modules/unigbrk/u32-grapheme-len: New file.
91972         * modules/unigbrk/u32-grapheme-len-tests: New file.
91973         * lib/unigbrk.in.h: Add prototype for new function.
91974         * lib/unigbrk/u32-grapheme-len.c: New file.
91975         * tests/unigbrk/test-u32-grapheme-len.c: New file.
91977         New module 'u8-grapheme-next'.
91978         * modules/unigbrk/u8-grapheme-next: New file.
91979         * modules/unigbrk/u8-grapheme-next-tests: New file.
91980         * lib/unigbrk.in.h: Add prototype for new function.
91981         * lib/unigbrk/u8-grapheme-next.c: New file.
91982         * tests/unigbrk/test-u8-grapheme-next.c: New file.
91984         New module 'u16-grapheme-next'.
91985         * modules/unigbrk/u16-grapheme-next: New file.
91986         * modules/unigbrk/u16-grapheme-next-tests: New file.
91987         * lib/unigbrk.in.h: Add prototype for new function.
91988         * lib/unigbrk/u16-grapheme-next.c: New file.
91989         * tests/unigbrk/test-u16-grapheme-next.c: New file.
91991         New module 'u32-grapheme-next'.
91992         * modules/unigbrk/u32-grapheme-next: New file.
91993         * modules/unigbrk/u32-grapheme-next-tests: New file.
91994         * lib/unigbrk.in.h: Add prototype for new function.
91995         * lib/unigbrk/u32-grapheme-next.c: New file.
91996         * tests/unigbrk/test-u32-grapheme-next.c: New file.
91998         New module 'u8-grapheme-prev'.
91999         * modules/unigbrk/u8-grapheme-prev: New file.
92000         * modules/unigbrk/u8-grapheme-prev-tests: New file.
92001         * lib/unigbrk.in.h: Add prototype for new function.
92002         * lib/unigbrk/u8-grapheme-prev.c: New file.
92003         * tests/unigbrk/test-u8-grapheme-prev.c: New file.
92005         New module 'u16-grapheme-prev'.
92006         * modules/unigbrk/u16-grapheme-prev: New file.
92007         * modules/unigbrk/u16-grapheme-prev-tests: New file.
92008         * lib/unigbrk.in.h: Add prototype for new function.
92009         * lib/unigbrk/u16-grapheme-prev.c: New file.
92010         * tests/unigbrk/test-u16-grapheme-prev.c: New file.
92012         New module 'u32-grapheme-prev'.
92013         * modules/unigbrk/u32-grapheme-prev: New file.
92014         * modules/unigbrk/u32-grapheme-prev-tests: New file.
92015         * lib/unigbrk.in.h: Add prototype for new function.
92016         * lib/unigbrk/u32-grapheme-prev.c: New file.
92017         * tests/unigbrk/test-u32-grapheme-prev.c: New file.
92019         New module 'u8-grapheme-breaks'.
92020         * modules/unigbrk/u8-grapheme-breaks: New file.
92021         * modules/unigbrk/u8-grapheme-breaks-tests: New file.
92022         * lib/unigbrk.in.h: Add prototype for new function.
92023         * lib/unigbrk/u8-grapheme-breaks.c: New file.
92024         * tests/unigbrk/test-u8-grapheme-breaks.c: New file.
92026         New module 'u16-grapheme-breaks'.
92027         * modules/unigbrk/u16-grapheme-breaks: New file.
92028         * modules/unigbrk/u16-grapheme-breaks-tests: New file.
92029         * lib/unigbrk.in.h: Add prototype for new function.
92030         * lib/unigbrk/u16-grapheme-breaks.c: New file.
92031         * tests/unigbrk/test-u16-grapheme-breaks.c: New file.
92033         New module 'u32-grapheme-breaks'.
92034         * modules/unigbrk/u32-grapheme-breaks: New file.
92035         * modules/unigbrk/u32-grapheme-breaks-tests: New file.
92036         * lib/unigbrk.in.h: Add prototype for new function.
92037         * lib/unigbrk/u32-grapheme-breaks.c: New file.
92038         * tests/unigbrk/test-u32-grapheme-breaks.c: New file.
92040         New module 'ulc-grapheme-breaks'.
92041         * modules/unigbrk/ulc-grapheme-breaks: New file.
92042         * modules/unigbrk/ulc-grapheme-breaks-tests: New file.
92043         * m4/locale-ar.m4: New file.
92044         * lib/unigbrk/ulc-grapheme-breaks.c: New file.
92045         * tests/unigbrk/test-ulc-grapheme-breaks.c: New file.
92046         * tests/unigbrk/test-ulc-grapheme-breaks.sh: New file.
92048 2010-12-31  Ben Pfaff  <blp@cs.stanford.edu>
92050         gbrkprop: Fix implementation of uc_graphemeclusterbreak_property.
92051         * lib/unigbrk/gbrkprop.h: Regenerate with gen-uni-tables.c.  I had
92052         modified how this file was generated before I initially submitted
92053         the module, but failed to regenerate it.  This meant that several
92054         of the level2 entries were wrong.
92055         * lib/unigbrk/uc-gbrk-prop.h (uc_graphemeclusterbreak_property):
92056         Remove the division-by-2 that is folded into the table now that
92057         gbrkprop.h has been regenerated properly.  Now -1 entries are
92058         handled correctly.
92060         New module 'unigbrk/uc-gbrk-prop-tests'.
92061         * modules/unigbrk/uc-gbrk-prop-tests: New file.
92062         * lib/gen-uni-tables.c: Generate tests/test-uc-gbrk-prop.h.
92063         * tests/unigbrk/test-uc-gbrk-prop.c: New file.
92064         * tests/unigbrk/test-uc-gbrk-prop.h: New file.
92066 2011-01-01  Bruno Haible  <bruno@clisp.org>
92068         Avoid use of hexadecimal escapes.
92069         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Use octal escapes
92070         instead of hexadecimal escapes.
92072 2011-01-01  Jim Meyering  <meyering@redhat.com>
92074         maint: new rule to update copyright year ranges
92075         * Makefile (update-copyright): New rule.
92077         maint: indent with TABs in Makefile
92078         * Makefile: Expand leading sequences of spaces to TABs
92080         version-etc: update the copyright year it reports
92081         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2011.
92083 2010-12-31  Bruno Haible  <bruno@clisp.org>
92085         isfinite: Avoid compiler bug of "cc -O" on HP-UX 11.11.
92086         * lib/isfinite.c (zerof, zerod, zerol): New variables.
92087         (gl_isfinitef, gl_isfinited, gl_isfinitel): Use them instead of literal
92088         zero.
92090 2010-12-31  Bruno Haible  <bruno@clisp.org>
92092         pwrite: Work around HP-UX 11.11 bug.
92093         * m4/pwrite.m4 (gl_FUNC_PWRITE): When pwrite exists, test whether it
92094         works and set REPLACE_PWRITE if not.
92095         * lib/pwrite.c (pwrite): Add an implementation that uses the system
92096         function.
92097         * doc/posix-functions/pwrite.texi: Document the HP-UX 11 bug.
92099 2010-12-31  Bruno Haible  <bruno@clisp.org>
92101         pread: Work around HP-UX 11 bugs.
92102         * m4/pread.m4 (gl_FUNC_PREAD): When pread exists, test whether it works
92103         and set REPLACE_PREAD if not.
92104         * doc/posix-functions/pread.texi: Document the HP-UX 11 bugs.
92106 2010-12-31  Eric Blake  <eblake@redhat.com>
92108         nl_langinfo: fix YESEXPR on Irix 6.5
92109         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Test for Irix bug.
92110         * lib/nl_langinfo.c (rpl_nl_langinfo): Work around it.
92111         * doc/posix-functions/nl_langinfo.texi (nl_langinfo): Document
92112         it.
92114 2010-12-31  Bruno Haible  <bruno@clisp.org>
92116         iconv: Document HP-UX 11 bug.
92117         * doc/posix-functions/iconv.texi: Document HP-UX 11 return value bug.
92119 2010-12-31  Bruno Haible  <bruno@clisp.org>
92121         ldexpl: Fix link error on HP-UX 11.
92122         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): When replacing ldexpl, set
92123         LDEXPL_LIBM, using $ISNANL_LIBM.
92125 2010-12-31  Eric Blake  <eblake@redhat.com>
92127         ftello: avoid compilation failure with SunStudio c89
92128         * lib/ftello.c (ftello): Use lseek, not llseek.
92130         tests: avoid failing coreutils tests on cygwin
92131         * tests/init.sh (find_exe_basenames_): Exempt [.exe.
92132         (create_exe_shims_): Return 0 when skipping.
92134 2010-12-31  Bruno Haible  <bruno@clisp.org>
92136         sys_select: Avoid warning about missing memset declaration on HP-UX 11.
92137         * lib/sys_select.in.h: On HP-UX, include also <string.h>.
92139 2010-12-31  Bruno Haible  <bruno@clisp.org>
92141         waitpid: Fix link error in C++ mode.
92142         * lib/sys_wait.in.h: Remove extern "C" { ... } group.
92144 2010-12-31  Bruno Haible  <bruno@clisp.org>
92146         isnan: Use GCC built-ins when possible.
92147         * lib/math.in.h (gl_isnan_f): Use __builtin_isnanf instead of
92148         __builtin_isnan.
92149         (gl_isnan_l): Use __builtin_isnanl instead of __builtin_isnan.
92150         (isnan): Define using GCC built-ins for GCC >= 4.0.
92152 2010-12-31  Bruno Haible  <bruno@clisp.org>
92154         isnand: Fix mistake.
92155         * m4/isnand.m4 (gl_HAVE_ISNAND_IN_LIBM): Use __builtin_isnan, not
92156         __builtin_isnand.
92158 2010-12-31  Bruno Haible  <bruno@clisp.org>
92160         open: Avoid C++ error on HP-UX 11.
92161         * lib/fcntl.in.h (open): Disable _GL_CXXALIASWARN invocation on HP-UX.
92163 2010-12-31  Bruno Haible  <bruno@clisp.org>
92165         time_r: Add missing declarations on HP-UX 11.
92166         * lib/time.in.h (localtime_r, gmtime_r): Test HAVE_DECL_LOCALTIME_R
92167         instead of HAVE_LOCALTIME_R.
92168         * m4/time_r.m4 (gl_TIME_R): Test whether localtime_r is declared. Set
92169         HAVE_LOCALTIME_R always.
92170         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize
92171         HAVE_DECL_LOCALTIME_R, not HAVE_LOCALTIME_R.
92172         * modules/time (Makefile.am): Substitute HAVE_DECL_LOCALTIME_R, not
92173         HAVE_LOCALTIME_R.
92174         * doc/posix-functions/gmtime_r.texi: Document the HP-UX 11 problem.
92175         * doc/posix-functions/localtime_r.texi: Likewise.
92177 2010-12-29  Eric Blake  <eblake@redhat.com>
92179         mountlist: tweak previous commit
92180         * lib/mountlist.c (me_remote): Guarantee trailing backslash.
92181         Reported by Paul Eggert.
92183         mountlist: fix local drive detection on cygwin
92184         * lib/mountlist.c (ME_REMOTE) [__CYGWIN__]: Provide implementation
92185         that works for cygwin.
92187 2010-12-29  Paul Eggert  <eggert@cs.ucla.edu>
92189         ftoastr, snprintf: ftoastr + snprintf module
92190         * lib/ftoastr.c: Use GNULIB_SNPRINTF, not GNULIB_SNPRINTF_POSIX,
92191         since the snprintf module now should be good enough here.
92192         * modules/snprintf (configure.ac): Add gl_MODULE_INDICATOR([snprintf]).
92193         It seems odd to have both gl_STDIO_MODULE_INDICATOR([snprintf])
92194         and gl_MODULE_INDICATOR([snprintf]), but the former enables
92195         GNULIB_SNPRINTF only for the test directory, and the latter
92196         doesn't arrange for gl_STDIO_H_DEFAULTS to be called, so neither
92197         seems to suffice by itself.
92199 2010-12-28  Paul Eggert  <eggert@cs.ucla.edu>
92201         alloca: one step towards thread-safety
92202         * lib/alloca.c (find_stack_direction): New arg PTR, to avoid the
92203         need for a static variable.  All callers changed.  This does not
92204         make the alloca replacement thread-safe, but it's one step.
92206         tests: minor indenting change
92207         * tests/init.sh: Sync from coreutils housekeeping patch
92208         <http://lists.gnu.org/r/coreutils/2010-12/msg00116.html>
92209         to keep lines within 80 columns.
92211 2010-12-28  Jim Meyering  <meyering@redhat.com>
92213         regex: don't infloop on persistent failing calloc
92214         * lib/regexec.c (build_trtable): Return failure indication upon
92215         calloc failure.  Otherwise, re_search_internal could infloop on OOM.
92216         In glibc, this was fixed for version 2.13:
92217         http://sourceware.org/bugzilla/show_bug.cgi?id=12348
92219 2010-12-28  Bruno Haible  <bruno@clisp.org>
92220             Paul Eggert <eggert@cs.ucla.edu>
92222         linkat: Make implementation robust against system behaviour variations.
92223         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Define
92224         LINK_FOLLOWS_SYMLINKS to -1 if it needs a runtime test in the Solaris
92225         way, and to -2 if it needs a generic runtime test.
92226         * lib/linkat.c (solaris_optimized_link_immediate,
92227         solaris_optimized_link_follow): New functions.
92228         * tests/test-linkat.c (EXPECT_LINK_HARDLINKS_SYMLINKS): New macro.
92229         (check_same_link): Use it.
92231 2010-12-26  Ben Pfaff  <blp@cs.stanford.edu>
92233         New module 'unigbrk/base'.
92234         * modules/unigbrk/base: New file.
92235         * lib/unigbrk.in.h: New file.
92237         New module 'unigbrk/uc-gbrk-prop'.
92238         * lib/gen-uni-tables.c: Generate lib/unigbrk/gbrkprop.h.
92239         * modules/unigbrk/uc-gbrk-prop: New file.
92240         * lib/unigbrk/gbrkprop.h: New file.
92241         * lib/unigbrk/uc-gbrk-prop.c: New file.
92243         New module 'unigbrk/uc-is-grapheme-break'.
92244         * modules/unigbrk/uc-is-grapheme-break: New file.
92245         * modules/unigbrk/uc-is-grapheme-break-tests: New file.
92246         * lib/unigbrk/uc-is-grapheme-break.c: New file.
92247         * tests/unigbrk/test-uc-is-grapheme-break.c: New file.
92248         * tests/unigbrk/test-uc-is-grapheme-break.sh: New file.
92249         * tests/unigbrk/GraphemeBreakTest.txt: New file.
92251         With corrections and tweaks by Bruno Haible <bruno@clisp.org>.
92253 2010-12-27  Bruno Haible  <bruno@clisp.org>
92255         linkat test: Avoid failure on Solaris 11 2010-11.
92256         * tests/test-linkat.c (main): Allow ENOTDIR as alternative error code.
92258 2010-12-27  Paul Eggert  <eggert@cs.ucla.edu>
92260         utimens: work around glibc rounding bug on more platforms
92261         * lib/utimens.c (fdutimens): Work around rounding bug even if
92262         HAVE_WORKING_UTIMES.  Reported for Linux 2.4.21 by Bruno Haible in
92263         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00298.html>.
92265 2010-12-27  Bruno Haible  <bruno@clisp.org>
92267         select tests: Improve comments.
92268         * tests/test-select.c (do_select): Add comments.
92270 2010-12-27  Bruno Haible  <bruno@clisp.org>
92272         select tests: Safer way of handling timeout.
92273         * tests/test-select.c (do_select_nowait): Zero-initialize the timeout
92274         at every invocation.
92276 2010-12-27  Bruno Haible  <bruno@clisp.org>
92278         select tests: Use 'bool' where appropriate.
92279         * tests/test-select.c (connect_to_socket): Change argument type to
92280         'bool'.
92282 2010-12-27  Bruno Haible  <bruno@clisp.org>
92284         select tests: Use existing modules.
92285         * modules/select-tests (Depends-on): Add pipe-posix, unistd.
92286         (configure.ac): Don't test for unistd.h.
92287         * tests/test-select.c: Include <unistd.h> always. Use pipe() as
92288         declared in <unistd.h>.
92290 2010-12-27  Bruno Haible  <bruno@clisp.org>
92292         mbrtowc: Work around a Solaris 7 bug.
92293         * m4/mbrtowc.m4 (gl_MBRTOWC_NULL_ARG1): New macro.
92294         (gl_MBRTOWC_NULL_ARG2): Renamed from gl_MBRTOWC_NULL_ARG.
92295         (gl_FUNC_MBRTOWC): Update. Define MBRTOWC_NULL_ARG2_BUG instead of
92296         MBRTOWC_NULL_ARG_BUG. Invoke gl_MBRTOWC_NULL_ARG1 and define
92297         MBRTOWC_NULL_ARG1_BUG.
92298         * lib/mbrtowc.c (rpl_mbrtowc): Use MBRTOWC_NULL_ARG2_BUG instead of
92299         MBRTOWC_NULL_ARG_BUG. Handle MBRTOWC_NULL_ARG1_BUG.
92300         * tests/test-mbrtowc.c (main): Test support of a NULL first argument.
92301         * doc/posix-functions/mbrtowc.texi: Mention the Solaris 7 bug.
92303 2010-12-27  Jim Meyering  <meyering@redhat.com>
92305         read-file.c: tweak syntax
92306         * lib/read-file.c (fread_file): Remove space after "*" in function
92307         definitions.
92309 2010-12-27  Bruno Haible  <bruno@clisp.org>
92311         times test: Avoid gcc warnings on OSF/1.
92312         * tests/test-times.c (main): Cast printf arguments from clock_t to
92313         'long int'.
92315 2010-12-27  Paul Eggert  <eggert@cs.ucla.edu>
92317         utimens: work around glibc rounding bug on older Linux kernels
92318         * lib/utimens.c (fdutimens): If invoking futimesat or futimes
92319         on Linux with a glibc whose utimes might not work, then work
92320         around a longstanding glibc bug involving rounding rather than
92321         truncated time stamps.  Reported for Linux 2.4.21 by Bruno Haible in
92322         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00113.html>.
92324 2010-12-26  Bruno Haible  <bruno@clisp.org>
92326         inet_ntop: Hide mismatch of declaration on NonStop Kernel.
92327         * lib/arpa_inet.in.h (inet_ntop): Use _GL_CXXALIAS_SYS_CAST instead of
92328         _GL_CXXALIAS_SYS.
92329         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92331 2010-12-26  Bruno Haible  <bruno@clisp.org>
92333         inet_ntop, inet_pton: Ensure declaration on NonStop Kernel.
92334         * lib/arpa_inet.in.h: On NonStop Kernel, include also <netdb.h>.
92335         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Likewise.
92336         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Include also <netdb.h> when
92337         looking for the declaration.
92338         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
92339         * doc/posix-functions/inet_ntop.texi: Document the NonStop Kernel
92340         problem.
92341         * doc/posix-functions/inet_pton.texi: Likewise.
92343 2010-12-26  Bruno Haible  <bruno@clisp.org>
92345         arpa_inet: Use the common idioms with C++ support.
92346         * lib/arpa_inet.in.h: Include c++defs.h.
92347         (inet_ntop, inet_pton): Declare using the macros with C++ namespace
92348         support.
92349         * modules/arpa_inet (Depends-on): Add c++defs.
92350         (Makefile.am): Substitute the contents of c++defs.h.
92351         * modules/arpa_inet-tests (Depends-on): Add arpa_inet-c++-tests.
92352         * modules/arpa_inet-c++-tests: New file.
92353         * tests/test-arpa_inet-c++.cc: New file.
92355 2010-12-25  Bruno Haible  <bruno@clisp.org>
92357         Fix more C++ link errors on Solaris 8.
92358         * modules/fcntl-h-c++-tests (test_fcntl_h_c___LDADD): Add
92359         $(LIB_EACCESS).
92360         * modules/stdio-c++-tests (test_stdio_c___LDADD): Likewise.
92361         * modules/stdlib-c++-tests (test_stdlib_c___LDADD): Likewise.
92362         * modules/sys_ioctl-c++-tests (test_sys_ioctl_c___LDADD): Likewise.
92363         * modules/wchar-c++-tests (test_wchar_c___LDADD): Likewise.
92364         * modules/wctype-c++-tests (test_wctype_c___LDADD): Likewise.
92366 2010-12-25  Bruno Haible  <bruno@clisp.org>
92368         printf-posix: Fix link error when a non-GCC compiler is used.
92369         * lib/stdio.in.h (printf): When not using GCC, override printf
92370         correctly.
92371         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92373 2010-12-25  Bruno Haible  <bruno@clisp.org>
92375         strerror_r-posix: Update doc.
92376         * doc/posix-functions/strerror_r.texi: Update doc about the return
92377         value. See <http://sources.redhat.com/bugzilla/show_bug.cgi?id=12204>.
92379 2010-12-25  Paul Eggert  <eggert@cs.ucla.edu>
92381         utimens: simplify the logic of the previous change
92382         * m4/utimes.m4 (gl_FUNC_UTIMES): Simplify the logic a bit.
92383         This should not affect whether the test succeeds or fails.
92385         utimens: configure better on hosts with NFS clock skew
92386         * m4/utimes.m4 (gl_FUNC_UTIMES): Don't assume that utimes (f, NULL)
92387         uses the clock of the local host.  It might use the clock of the
92388         NFS server.  Reported for Linux 2.4.21 client by Bruno Haible in
92389         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00113.html>.
92391 2010-12-25  Bruno Haible  <bruno@clisp.org>
92393         ptsname test: Avoid failure on Solaris.
92394         * tests/test-ptsname.c (main): For Solaris, use the recommended way to
92395         open a pseudo-terminal; don't use BSD-style ptys.
92396         * doc/posix-functions/ptsname.texi: Document the limitation on Solaris.
92398 2010-12-25  Bruno Haible  <bruno@clisp.org>
92400         ptsname: Avoid ERANGE failure on some systems.
92401         * lib/ptsname.c (buffer): Increase size.
92403 2010-12-25  Bruno Haible  <bruno@clisp.org>
92405         rename, renameat: Avoid test failures at NFS mounted locations.
92406         * tests/test-rename.h (assert_nonexistent): Remove the old directory,
92407         so that subsequent mkdir calls succeed.
92409 2010-12-25  Bruno Haible  <bruno@clisp.org>
92411         iswblank: Fix C++ link error on Solaris 8.
92412         * lib/wctype.in.h (iswblank): Declare using _GL_FUNCDECL_RPL or
92413         _GL_FUNCDECL_SYS.
92415 2010-12-25  Bruno Haible  <bruno@clisp.org>
92417         unistd: Fix C++ link error on Solaris 8.
92418         * modules/unistd-c++-tests (test_unistd_c___LDADD): Add $(LIB_EACCESS).
92420 2010-12-25  Bruno Haible  <bruno@clisp.org>
92422         readlink doc: Mention an old glibc bug.
92423         * doc/posix-functions/readlink.texi: Mention glibc 2.4 bug (BZ #2450).
92425 2010-12-25  Bruno Haible  <bruno@clisp.org>
92427         fcntl-h: Fix for use of C++ on glibc systems.
92428         * lib/fcntl.in.h: Include <sys/stat.h> before include_next <fcntl.h>
92429         also on glibc systems in C++ mode.
92430         Reported by Gary V. Vaughan <gary@gnu.org>.
92432 2010-12-25  Bruno Haible  <bruno@clisp.org>
92434         roundl-ieee: Make it work on OSF/1 5.1 with cc.
92435         * modules/roundl-ieee (Depends-on): Add floorl-ieee, ceill-ieee.
92437 2010-12-25  Bruno Haible  <bruno@clisp.org>
92439         truncl-ieee: Make it work on OSF/1 5.1 with cc.
92440         * doc/posix-functions/truncl.texi: Mention the OSF/1 5.1 bug.
92441         * m4/truncl.m4 (gl_FUNC_TRUNCL): If gl_FUNC_TRUNCL_IEEE is also used,
92442         test whether truncl works according to ISO C 99 with IEC 60559.
92443         * m4/truncl-ieee.m4: New file.
92444         * modules/truncl-ieee (Files): Add it and m4/minus-zero.m4,
92445         m4/signbit.m4.
92446         (configure.ac): Invoke gl_FUNC_TRUNCL_IEEE.
92448 2010-12-25  Bruno Haible  <bruno@clisp.org>
92450         ceill-ieee: Make it work on OSF/1 5.1 with cc.
92451         * doc/posix-functions/ceill.texi: Mention the OSF/1 5.1 bug.
92452         * m4/ceill.m4 (gl_FUNC_CEILL): If gl_FUNC_CEILL_IEEE is also used,
92453         test whether ceill works according to ISO C 99 with IEC 60559.
92454         * m4/ceill-ieee.m4: New file.
92455         * modules/ceill-ieee (Files): Add it and m4/minus-zero.m4,
92456         m4/signbit.m4.
92457         (configure.ac): Invoke gl_FUNC_CEILL_IEEE.
92459 2010-12-25  Bruno Haible  <bruno@clisp.org>
92461         Ensure all prerequisites of <wchar.h> are included.
92462         * m4/btowc.m4 (gl_FUNC_BTOWC): Include <stddef.h>, <stdio.h>, <time.h>
92463         before <wchar.h>.
92464         * m4/mbrlen.m4 (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL,
92465         gl_MBRLEN_NUL_RETVAL): Likewise.
92466         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
92467         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL,
92468         AC_FUNC_MBRTOWC): Likewise.
92469         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
92470         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
92471         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
92472         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
92473         Likewise.
92474         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
92475         * m4/wchar_h.m4 (gl_WCHAR_H_INLINE_OK): Likewise.
92476         (gl_WCHAR_H): Improve comments.
92477         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
92479 2010-12-25  Bruno Haible  <bruno@clisp.org>
92481         strtok_r: Fix C syntax error in autoconf macro.
92482         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Don't use UTF-8 encoded U+00A0
92483         characters in test program.
92485 2010-12-24  Bruno Haible  <bruno@clisp.org>
92487         ceil, trunc, round: Fix gcc warnings.
92488         * lib/ceil.c (MIN): Undefine before redefining.
92489         * lib/trunc.c (MIN): Likewise.
92490         * lib/round.c (MIN): Likewise.
92491         Include <math.h> first.
92493 2010-12-24  Bruno Haible  <bruno@clisp.org>
92495         select tests: Avoid failures on OSF/1 5.1.
92496         * tests/test-select.c (test_accept_first, test_socket_pair): Ignore
92497         failure of closing the last socket; it may fail with ECONNRESET.
92499 2010-12-24  Eric Blake  <eblake@redhat.com>
92501         stdint: avoid HP-UX 10.20 preprocessor bug
92502         * lib/stdint.in.h (INT64_MAX, UINT64_MAX): Check via #ifdef rather
92503         than #if.
92504         * tests/test-floor2.c (main): Likewise.
92505         Reported by Peter O'Gorman.
92507         pipe: make obsoletion transition easier
92508         * lib/pipe.h: Restore file as thin shim around "spawn-pipe.h".
92509         * modules/pipe (Files): Include revived file.
92510         (Include): Drop reference, to mirror getdate's behavior.
92512 2010-12-24  Bruno Haible  <bruno@clisp.org>
92514         sys_socket: Hide mismatch of declarations on NonStop Kernel.
92515         * lib/sys_socket.in.h (connect, bind, sendto, setsockopt): Use
92516         _GL_CXXALIAS_SYS_CAST instead of _GL_CXXALIAS_SYS.
92517         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92519 2010-12-24  Bruno Haible  <bruno@clisp.org>
92521         gethostname: Ensure declaration on NonStop Kernel.
92522         * lib/unistd.in.h: Include <netdb.h> also on NonStop Kernel systems.
92523         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92525 2010-12-24  Bruno Haible  <bruno@clisp.org>
92527         sys_select: Ensure all necessary types on NonStop Kernel.
92528         * lib/sys_select.in.h: If the system does not have <sys/select.h>,
92529         include <sys/time.h>.
92530         * doc/posix-headers/sys_select.texi: Mention that it's missing on
92531         NonStop Kernel.
92532         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92534 2010-12-24  Bruno Haible  <bruno@clisp.org>
92536         sys_select: Remove unneeded include.
92537         * lib/sys_select.in.h: Don't include <sys/socket.h> on platforms that
92538         have <sys/select.h>.
92540 2010-12-24  Bruno Haible  <bruno@clisp.org>
92542         gethostname: Provide a fallback for HOST_NAME_MAX.
92543         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): When neither HOST_NAME_MAX
92544         nor MAXHOSTNAMELEN is found in the usual system headers, use 256
92545         instead.
92546         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92548 2010-12-24  Bruno Haible  <bruno@clisp.org>
92550         sigaction tests: Allow missing SA_RESETHAND and SA_RESTART.
92551         * tests/test-sigaction.c (SA_RESETHAND): Fall back to 0.
92552         (SA_RESTART): Likewise.
92553         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92555 2010-12-24  Bruno Haible  <bruno@clisp.org>
92557         signal: Define NSIG.
92558         * lib/signal.in.h (NSIG): Define to 32 on NonStop Kernel.
92559         * tests/test-signal.c (nsig): New variable.
92560         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92562 2010-12-24  Bruno Haible  <bruno@clisp.org>
92564         rename, renameat: Avoid test failures on OSF/1 5.1.
92565         * tests/test-rename.h (test_rename): Allow EEXIST and ENOTDIR as
92566         alternative error codes.
92567         * tests/test-renameat.c (main): Likewise.
92569 2010-12-24  Bruno Haible  <bruno@clisp.org>
92571         *printf: Detect large precisions bug on Solaris 10/SPARC.
92572         * m4/printf.m4 (gl_PRINTF_PRECISION): Add one more test code, provided
92573         by Paul Eggert.
92574         * tests/test-snprintf-posix.h (test_function): Add this test code here
92575         too.
92576         * tests/test-sprintf-posix.h (test_function): Likewise.
92577         * tests/test-vasnprintf-posix.c (test_function): Likewise.
92578         * tests/test-vasprintf-posix.c (test_function): Likewise.
92579         * doc/posix-functions/fprintf.texi: Mention Solaris 10 bug as worked
92580         around by gnulib.
92581         * doc/posix-functions/printf.texi: Likewise.
92582         * doc/posix-functions/snprintf.texi: Likewise.
92583         * doc/posix-functions/sprintf.texi: Likewise.
92584         * doc/posix-functions/vfprintf.texi: Likewise.
92585         * doc/posix-functions/vprintf.texi: Likewise.
92586         * doc/posix-functions/vsnprintf.texi: Likewise.
92587         * doc/posix-functions/vsprintf.texi: Likewise.
92588         * doc/posix-functions/dprintf.texi: Undo last commit.
92589         * doc/posix-functions/vdprintf.texi: Likewise.
92591 2010-12-23  Paul Eggert  <eggert@cs.ucla.edu>
92593         tests: port test-fdutimensat.c to Solaris 8
92594         * tests/test-fdutimensat.c (do_fdutimens): Don't assume
92595         fdutimensat works with a nonnegative fd and AT_SYMLINK_NOFOLLOW.
92596         On Solaris 8, it fails with errno == ENOSYS, because there is no
92597         futimens (so it can't use the fd), and there is no lutimens (so it
92598         can't implement AT_SYMLINK_NOFOLLOW on symlinks).
92600         vsnprintf: make more consistent with snprintf; doc fixes
92602         * doc/posix-functions/snprintf.texi (snprintf): The workaround for
92603         the byte count return problem was promoted from the snprintf-posix
92604         to the snprintf module.
92605         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
92606         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Also check
92607         gl_SNPRINTF_RETVAL_C99, for consistency with gl_FUNC_SNPRINTF.
92608         * tests/test-snprintf.c (main): Check the byte count returned.
92609         * tests/test-vsnprintf.c (main): Likewise.
92611 2010-12-23  Eric Blake  <eblake@redhat.com>
92613         sigpipe: relax to LGPLv2+, since it did not have any LGPLv3+ parts
92614         * modules/sigpipe (License): Relax license.
92616 2010-12-22  Paul Eggert  <eggert@cs.ucla.edu>
92618         doc: document Solaris printf bug with large float precisions
92619         * doc/posix-functions/dprintf.texi (dprintf):
92620         * doc/posix-functions/fprintf.texi (fprintf):
92621         * doc/posix-functions/printf.texi (printf):
92622         * doc/posix-functions/snprintf.texi (snprintf):
92623         * doc/posix-functions/sprintf.texi (sprintf):
92624         * doc/posix-functions/vdprintf.texi (vdprintf):
92625         * doc/posix-functions/vfprintf.texi (vfprintf):
92626         * doc/posix-functions/vprintf.texi (vprintf):
92627         * doc/posix-functions/vsnprintf.texi (vsnprintf):
92628         * doc/posix-functions/vsprintf.texi (vsprintf):
92629         Mention that these functions mishandle large floating point
92630         precisions on Solaris 10.  The same bug is also present in Solaris
92631         8, and I assume earlier.  This causes "cd gnulib-tests; make
92632         check" to fail on Solaris 8 (and I assume, later) when building
92633         the latest coreutils, in test-vasprintf-posix's call to
92634         my_asprintf (&result, "%.4000f %d", 1.0, 99).  I have not checked
92635         the wide flavors (e.g., wprintf) so this patch just updates the
92636         documentation for the narrow ones.
92638         test-posixtm.c: add two tests
92639         * tests/test-posixtm.c: Add two tests, to highlight the
92640         bug in Solaris 10 (and earlier) localtime.  Gnulib doesn't work
92641         around this bug; this is merely to document it.
92643 2010-12-22  Bruno Haible  <bruno@clisp.org>
92645         getlogin_r: Work around portability problem on OSF/1.
92646         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Detect the OSF/1 problem.
92647         * lib/unistd.in.h (getlogin_r): Replace if REPLACE_GETLOGIN_R is set.
92648         * lib/getlogin_r.c (getlogin_r): When getlogin_r exists, invoke it and
92649         test for a truncated result.
92650         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_GETLOGIN_R.
92651         * modules/unistd (Makefile.am): Substitute REPLACE_GETLOGIN_R.
92652         * modules/getlogin_r (Depends-on): Add memchr.
92653         * doc/posix-functions/getlogin_r.texi: Mention the OSF/1 problem.
92655 2010-12-22  Bruno Haible  <bruno@clisp.org>
92657         ptsname: Avoid test failure on OSF/1 5.1.
92658         * modules/ptsname-tests (Depends-on): Add 'same-inode'.
92659         * tests/test-ptsname.c: Include <sys/stat.h>, same-inode.h.
92660         (same_slave): New function.
92661         (main): Use it to compare ptsname's result with the expected file name.
92663 2010-12-22  Bruno Haible  <bruno@clisp.org>
92665         Port extended stdio modules to HP NonStop Kernel.
92666         * lib/stdio-impl.h (_IOERR, _IOREAD, _IOWRT, _IORW) [__TANDEM]: New
92667         macros.
92668         * lib/fbufmode.c: Update comments.
92669         * lib/fflush.c: Likewise.
92670         * lib/fpurge.c: Likewise.
92671         * lib/freadable.c: Likewise.
92672         * lib/freadahead.c: Likewise.
92673         * lib/freading.c: Likewise.
92674         * lib/freadptr.c: Likewise.
92675         * lib/freadseek.c: Likewise.
92676         * lib/fseeko.c: Likewise.
92677         * lib/fseterr.c: Likewise.
92678         * lib/fwritable.c: Likewise.
92679         * lib/fwriting.c: Likewise.
92680         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
92682 2010-12-22  Bruno Haible  <bruno@clisp.org>
92684         ttyname_r: Work around bug on OSF/1 5.1.
92685         * doc/posix-functions/ttyname_r.texi: Mention the OSF/1 bug.
92686         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Detect the OSF/1 bug. Say "no"
92687         instead of "guessing no" when the OSF/1 bug or the Solaris bug is
92688         present.
92689         * lib/ttyname_r.c (ttyname_r): Update comments.
92691 2010-12-22  Bruno Haible  <bruno@clisp.org>
92693         round: Implement result sign according to IEEE 754.
92694         * lib/round.c (MIN, MINUS_ZERO): New macros.
92695         (FLOOR_FREE_ROUND): Return -0.0 for -0.5 < x < 0.
92696         * tests/test-roundf-ieee.c (main): Test also values between -1 and 1.
92697         * tests/test-round-ieee.c (main): Likewise.
92698         * tests/test-roundl-ieee.c (main): Likewise.
92700         trunc: Implement result sign according to IEEE 754.
92701         * lib/trunc.c (MIN, MINUS_ZERO): New macros.
92702         (FUNC): Return +0.0 for 0 < x < 1 and -0.0 for -1 < x < 0.
92703         * tests/test-trunc2.c: Include minus-zero.h.
92704         (MINUS_ZERO): New macro.
92705         (trunc_reference): Keep in sync with lib/trunc.c.
92706         * tests/test-truncf2.c: Include minus-zero.h.
92707         (MINUS_ZERO): New macro.
92708         (truncf_reference): Keep in sync with lib/trunc.c.
92709         * tests/test-truncf-ieee.c (main): Test also values between -1 and 1.
92710         * tests/test-trunc-ieee.c (main): Likewise.
92711         * tests/test-truncl-ieee.c (main): Likewise.
92713         ceil: Implement result sign according to IEEE 754.
92714         * lib/ceil.c (MIN, MINUS_ZERO): New macros.
92715         (FUNC): Return -0.0 for -1 < x < 0.
92716         * tests/test-ceil2.c: Include minus-zero.h.
92717         (MINUS_ZERO): New macro.
92718         (ceil_reference): Keep in sync with lib/ceil.c.
92719         * tests/test-ceilf2.c: Include minus-zero.h.
92720         (MINUS_ZERO): New macro.
92721         (ceilf_reference): Keep in sync with lib/ceil.c.
92722         * tests/test-ceilf-ieee.c (main): Test also values between -1 and 1.
92723         * tests/test-ceil-ieee.c (main): Likewise.
92724         * tests/test-ceill-ieee.c (main): Likewise.
92726         floor: Implement result sign according to IEEE 754.
92727         * lib/floor.c (FUNC): Return +0.0 for 0 < x < 1.
92728         * tests/test-floor2.c (floor_reference): Keep in sync with lib/floor.c.
92729         * tests/test-floorf2.c (floorf_reference): Likewise.
92730         * tests/test-floorf-ieee.c (main): Test also values between -1 and 1.
92731         * tests/test-floor-ieee.c (main): Likewise.
92732         * tests/test-floorl-ieee.c (main): Likewise.
92734 2010-12-22  Bruno Haible  <bruno@clisp.org>
92736         getaddrinfo: Update doc.
92737         * doc/posix-functions/gai_strerror.texi: Return type is also different
92738         on AIX and HP-UX.
92740 2010-12-22  Paul Eggert  <eggert@cs.ucla.edu>
92742         getaddrinfo, inet_ntop: Update doc for Solaris.
92743         * doc/posix-functions/gai_strerror.texi: Return type is also an
92744         issue on Solaris 9 and earlier.
92745         * doc/posix-functions/inet_ntop.texi: 4th arg type is also an issue
92746         on Solaris 10 and earlier.
92748 2010-12-21  Bruno Haible  <bruno@clisp.org>
92750         New module 'roundl-ieee'.
92751         * modules/roundl-ieee: New file.
92752         * m4/roundl.m4 (gl_FUNC_ROUNDL): If gl_FUNC_ROUNDL_IEEE is also used,
92753         test whether roundl works according to ISO C 99 with IEC 60559.
92754         * m4/roundl-ieee.m4: New file.
92755         * modules/roundl-ieee-tests: New file.
92756         * tests/test-roundl-ieee.c: New file, based on tests/test-roundl.c.
92757         * tests/test-roundl.c (main): Remove signbit tests.
92758         * modules/roundl-tests (Depends-on): Remove signbit.
92759         * doc/posix-functions/roundl.texi: Mention the new module.
92761 2010-12-21  Bruno Haible  <bruno@clisp.org>
92763         New module 'truncl-ieee'.
92764         * modules/truncl-ieee: New file.
92765         * modules/truncl-ieee-tests: New file.
92766         * tests/test-truncl-ieee.c: New file, based on tests/test-truncl.c.
92767         * tests/test-truncl.c (main): Remove signbit tests.
92768         * modules/truncl-tests (Depends-on): Remove signbit.
92769         * doc/posix-functions/truncl.texi: Mention the new module.
92771 2010-12-21  Bruno Haible  <bruno@clisp.org>
92773         New module 'ceill-ieee'.
92774         * modules/ceill-ieee: New file.
92775         * modules/ceill-ieee-tests: New file.
92776         * tests/test-ceill-ieee.c: New file, based on tests/test-ceill.c.
92777         * tests/test-ceill.c (main): Remove signbit tests.
92778         * modules/ceill-tests (Depends-on): Remove signbit.
92779         * doc/posix-functions/ceill.texi: Mention the new module.
92781 2010-12-21  Bruno Haible  <bruno@clisp.org>
92783         New module 'floorl-ieee'.
92784         * modules/floorl-ieee: New file.
92785         * modules/floorl-ieee-tests: New file.
92786         * tests/test-floorl-ieee.c: New file, based on tests/test-floorl.c.
92787         * tests/test-floorl.c (main): Remove signbit tests.
92788         * modules/floorl-tests (Depends-on): Remove signbit.
92789         * doc/posix-functions/floorl.texi: Mention the new module.
92791 2010-12-21  Bruno Haible  <bruno@clisp.org>
92793         New module 'round-ieee'.
92794         * modules/round-ieee: New file.
92795         * m4/round.m4 (gl_FUNC_ROUND): If gl_FUNC_ROUND_IEEE is also used, test
92796         whether round works according to ISO C 99 with IEC 60559.
92797         * m4/round-ieee.m4: New file.
92798         * modules/round-ieee-tests: New file.
92799         * tests/test-round-ieee.c: New file, based on tests/test-roundf-ieee.c.
92800         * tests/test-round1.c (main): Remove signbit tests.
92801         * modules/round-tests (Depends-on): Remove 'signbit'.
92802         * doc/posix-functions/round.texi: Mention the new module.
92804 2010-12-21  Bruno Haible  <bruno@clisp.org>
92806         New module 'trunc-ieee'.
92807         * modules/trunc-ieee: New file.
92808         * m4/trunc.m4 (gl_FUNC_TRUNC): If gl_FUNC_TRUNC_IEEE is also used, test
92809         whether trunc works according to ISO C 99 with IEC 60559.
92810         * m4/trunc-ieee.m4: New file.
92811         * lib/math.in.h (trunc): Replace if REPLACE_TRUNC is set.
92812         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNC.
92813         * modules/math (Makefile.am): Substitute REPLACE_TRUNC.
92814         * modules/trunc-ieee-tests: New file.
92815         * tests/test-trunc-ieee.c: New file, based on tests/test-truncf-ieee.c.
92816         * tests/test-trunc1.c (main): Remove signbit tests.
92817         * modules/trunc-tests (Depends-on): Remove 'signbit'.
92818         * doc/posix-functions/trunc.texi: Mention the new module.
92820 2010-12-21  Bruno Haible  <bruno@clisp.org>
92822         New module 'ceil-ieee'.
92823         * modules/ceil-ieee: New file.
92824         * m4/ceil.m4 (gl_FUNC_CEIL): Require gl_MATH_H_DEFAULTS. If
92825         gl_FUNC_CEIL_IEEE is also used, test whether ceil works according to
92826         ISO C 99 with IEC 60559.
92827         * m4/ceil-ieee.m4: New file.
92828         * modules/ceil (Files): Add lib/ceil.c.
92829         (Depends-on): Add 'float'.
92830         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
92831         * lib/math.in.h (ceil): New declaration.
92832         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEIL,
92833         REPLACE_CEIL.
92834         * modules/math (Makefile.am): Substitute GNULIB_CEIL, REPLACE_CEIL.
92835         * modules/ceil-ieee-tests: New file.
92836         * tests/test-ceil-ieee.c: New file, based on tests/test-ceilf-ieee.c.
92837         * tests/test-math-c++.cc: Check the signature of 'ceil'.
92838         * doc/posix-functions/ceil.texi: Mention the new module.
92840 2010-12-21  Bruno Haible  <bruno@clisp.org>
92842         New module 'floor-ieee'.
92843         * modules/floor-ieee: New file.
92844         * m4/floor.m4 (gl_FUNC_FLOOR): Require gl_MATH_H_DEFAULTS. If
92845         gl_FUNC_FLOOR_IEEE is also used, test whether floor works according to
92846         ISO C 99 with IEC 60559.
92847         * m4/floor-ieee.m4: New file.
92848         * modules/floor (Files): Add lib/floor.c.
92849         (Depends-on): Add 'float'.
92850         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
92851         * lib/math.in.h (floor): New declaration.
92852         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOOR,
92853         REPLACE_FLOOR.
92854         * modules/math (Makefile.am): Substitute GNULIB_FLOOR, REPLACE_FLOOR.
92855         * modules/floor-ieee-tests: New file.
92856         * tests/test-floor-ieee.c: New file, based on tests/test-floorf-ieee.c.
92857         * tests/test-math-c++.cc: Check the signature of 'floor'.
92858         * doc/posix-functions/floor.texi: Mention the new module.
92860 2010-12-21  Bruno Haible  <bruno@clisp.org>
92862         New module 'roundf-ieee'.
92863         * modules/roundf-ieee: New file.
92864         * m4/roundf.m4 (gl_FUNC_ROUNDF): If gl_FUNC_ROUNDF_IEEE is also used,
92865         test whether roundf works according to ISO C 99 with IEC 60559.
92866         * m4/roundf-ieee.m4: New file.
92867         * modules/roundf-ieee-tests: New file.
92868         * tests/test-roundf-ieee.c: New file, based on tests/test-roundf1.c.
92869         * tests/test-roundf1.c (main): Remove signbit tests.
92870         * modules/roundf-tests (Depends-on): Remove 'signbit'.
92871         * doc/posix-functions/roundf.texi: Mention the new module.
92873 2010-12-21  Bruno Haible  <bruno@clisp.org>
92875         New module 'truncf-ieee'.
92876         * modules/truncf-ieee: New file.
92877         * m4/truncf.m4 (gl_FUNC_TRUNCF): If gl_FUNC_TRUNCF_IEEE is also used,
92878         test whether truncf works according to ISO C 99 with IEC 60559.
92879         * m4/truncf-ieee.m4: New file.
92880         * lib/math.in.h (truncf): Replace if REPLACE_TRUNCF is set.
92881         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNCF.
92882         * modules/math (Makefile.am): Substitute REPLACE_TRUNCF.
92883         * modules/truncf-ieee-tests: New file.
92884         * tests/test-truncf-ieee.c: New file, based on tests/test-truncf1.c.
92885         * tests/test-truncf1.c (main): Remove signbit tests.
92886         * modules/truncf-tests (Depends-on): Remove 'signbit'.
92887         * doc/posix-functions/truncf.texi: Mention the new module.
92889 2010-12-21  Bruno Haible  <bruno@clisp.org>
92891         New module 'ceilf-ieee'.
92892         * modules/ceilf-ieee: New file.
92893         * m4/ceilf.m4 (gl_FUNC_FLOORF): If gl_FUNC_CEILF_IEEE is also used,
92894         test whether ceilf works according to ISO C 99 with IEC 60559.
92895         * m4/ceilf-ieee.m4: New file.
92896         * modules/ceilf-ieee-tests: New file.
92897         * tests/test-ceilf-ieee.c: New file, based on tests/test-ceilf1.c.
92898         * tests/test-ceilf1.c (main): Remove signbit tests.
92899         * modules/ceilf-tests (Depends-on): Remove 'signbit'.
92900         * doc/posix-functions/ceilf.texi: Mention the new module.
92902 2010-12-21  Bruno Haible  <bruno@clisp.org>
92904         New module 'floorf-ieee'.
92905         * modules/floorf-ieee: New file.
92906         * m4/floorf.m4 (gl_FUNC_FLOORF): If gl_FUNC_FLOORF_IEEE is also used,
92907         test whether floorf works according to ISO C 99 with IEC 60559.
92908         * m4/floorf-ieee.m4: New file.
92909         * modules/floorf-ieee-tests: New file.
92910         * tests/test-floorf-ieee.c: New file, based on tests/test-floorf1.c.
92911         * tests/test-floorf1.c (main): Remove signbit tests.
92912         * modules/floorf-tests (Depends-on): Remove 'signbit'.
92913         * doc/posix-functions/floorf.texi: Mention the new module.
92915 2010-12-21  Bruno Haible  <bruno@clisp.org>
92917         Support for minus zero in autoconf macros.
92918         * m4/minus-zero.m4: New file, based on tests/minus-zero.h.
92919         * m4/signbit.m4 (gl_FLOAT_SIGNBIT_CODE, gl_DOUBLE_SIGNBIT_CODE,
92920         gl_LONG_DOUBLE_SIGNBIT_CODE, gl_FLOATTYPE_SIGNBIT_CODE): New macros.
92921         * tests/minus-zero.h: Update comments.
92923 2010-12-21  Bruno Haible  <bruno@clisp.org>
92925         Tests for module 'ceil'.
92926         * modules/ceil-tests: New file.
92927         * tests/test-ceil1.c: New file, based on tests/test-ceill.c.
92928         * tests/test-ceil2.c: New file, based on tests/test-ceilf2.c.
92930 2010-12-21  Bruno Haible  <bruno@clisp.org>
92932         Tests for module 'floor'.
92933         * modules/floor-tests: New file.
92934         * tests/test-floor1.c: New file, based on tests/test-floorl.c.
92935         * tests/test-floor2.c: New file, based on tests/test-floorf2.c.
92937 2010-12-21  Bruno Haible  <bruno@clisp.org>
92939         math: Fix indentation.
92940         * lib/math.in.h (floorf): Fix indentation.
92942 2010-12-21  Bruno Haible  <bruno@clisp.org>
92944         Fix cross-compilation guesses on Solaris.
92945         * m4/fopen.m4 (gl_FUNC_FOPEN): Correct shell pattern so that it does
92946         not match "solaris2.10".
92947         * m4/open.m4 (gl_FUNC_OPEN): Likewise.
92948         * m4/printf.m4 (gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_DIRECTIVE_N,
92949         gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
92951 2010-12-21  Paul Eggert  <eggert@cs.ucla.edu>
92953         snprintf: port snprintf (NULL, 0, ...) to Solaris 8 and 9
92954         This fixes a problem observed with the latest coreutils snapshot
92955         that caused a test to fail on Solaris 8.  src/csplit.c's call
92956         snprintf (NULL, 0, format, UINT_MAX) returns -1 on Solaris 9 and
92957         earlier, instead of returning the number of bytes that would have
92958         been generated; this causes csplit to incorrectly report memory
92959         exhaustion.
92960         * m4/printf.m4 (gl_SNPRINTF_RETVAL_C99): Also check for
92961         snprintf (NULL, 0, ...) and (for good measure) snprintf (buf, 0, ...).
92962         Guess that it doesn't work on Solaris 2.6 through 9.  Adjust
92963         comments to match.
92964         (gl_PRINTF_SIZES_C99, gl_PRINTF_DIRECTIVE_F, gl_SNPRINTF_RETVAL_C99):
92965         Fix typo in matching older versions of Solaris: "solaris2.10"
92966         is matched by the shell pattern "solaris2.[0-9]*".  This matters
92967         only for guessing while cross-compiling.
92968         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Also check gl_SNPRINTF_RETVAL_C99.
92970 2010-12-20  Paul Eggert  <eggert@cs.ucla.edu>
92972         ftoastr: fix comment again
92973         * lib/ftoastr.h: Fix typo in comment.  Noted by Ben Pfaff in
92974         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00149.html>.
92975         Also, simplify example a bit by using flags = 0.
92977 2010-12-20  Bruno Haible  <bruno@clisp.org>
92979         round*, trunc*: Update documentation regarding glibc.
92980         * doc/posix-functions/roundf.texi: Mention missing declaration problem.
92981         * doc/posix-functions/round.texi: Likewise.
92982         * doc/posix-functions/roundl.texi: Likewise.
92983         * doc/posix-functions/truncf.texi: Likewise.
92984         * doc/posix-functions/trunc.texi: Likewise.
92985         * doc/posix-functions/truncl.texi: Likewise.
92987 2010-12-20  Bruno Haible  <bruno@clisp.org>
92989         roundf, round, roundl: Update documentation regarding OSF/1 5.1.
92990         * doc/posix-functions/roundf.texi: Mention OSF/1 5.1 problem.
92991         * doc/posix-functions/round.texi: Likewise.
92992         * doc/posix-functions/roundl.texi: Likewise.
92994 2010-12-20  Bruno Haible  <bruno@clisp.org>
92996         ttyname_r: Add missing declaration on HP-UX 11.
92997         * lib/unistd.in.h (ttyname_r): Test HAVE_DECL_TTYNAME_R instead of
92998         HAVE_TTYNAME_R.
92999         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test whether ttyname_r is
93000         declared. Set HAVE_TTYNAME_R always.
93001         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
93002         HAVE_DECL_TTYNAME_R, not HAVE_TTYNAME_R.
93003         * modules/unistd (Makefile.am): Substitute HAVE_DECL_TTYNAME_R, not
93004         HAVE_TTYNAME_R.
93005         * doc/posix-functions/ttyname_r.texi: Document the HP-UX 11 problem.
93007 2010-12-20  Bruno Haible  <bruno@clisp.org>
93009         getlogin, getlogin_r: Document HP-UX 11.11 bugs.
93010         * doc/posix-functions/getlogin.texi: Document HP-UX 11.11 bug.
93011         * doc/posix-functions/getlogin_r.texi: Likewise.
93012         * tests/test-getlogin.c: Include <errno.h>.
93013         (main): Avoid test failure on HP-UX 11.11.
93014         * tests/test-getlogin_r.c (main): Likewise.
93016 2010-12-20  Bruno Haible  <bruno@clisp.org>
93018         getlogin_r: Add missing declaration on HP-UX 11.
93019         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Test whether getlogin_r is
93020         declared also when it exists as a function.
93021         * doc/posix-functions/getlogin_r.texi: Document this workaround.
93023 2010-12-20  Bruno Haible  <bruno@clisp.org>
93025         wcsrtombs: Don't confuse mbstate_t with rpl_mbstate_t.
93026         * lib/wcsrtombs.c: If gnulib overrides mbstate_t, define wcsrtombs
93027         through wcrtomb.
93029 2010-12-19  Paul Eggert  <eggert@cs.ucla.edu>
93031         ftoastr: fix comment
93032         * lib/ftoastr.h: Fix typo in comment.  Noted by Ben Pfaff in
93033         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00130.html>.
93035 2010-12-19  Bruno Haible  <bruno@clisp.org>
93037         isnan: Ensure it is a macro.
93038         * lib/math.in.h (isnan): Define as a macro if not already a macro.
93039         * doc/posix-functions/isnan.texi: Mention problem on IRIX, OSF/1,
93040         Solaris.
93042 2010-12-19  Bruno Haible  <bruno@clisp.org>
93044         ldexpl test: Fix link error on OSF/1 5.1.
93045         * modules/ldexpl-tests (Makefile.am): Define test_ldexpl_LDADD.
93047 2010-12-19  Bruno Haible  <bruno@clisp.org>
93049         wctype: Make it work in C++ mode on OSF/1 5.1.
93050         * lib/wctype.in.h (iswblank): Declare but not define here.
93051         * lib/iswblank.c: New file, extracted from lib/wctype.in.h.
93052         * m4/wctype_h.m4 (gl_WCTYPE_H): Arrange to compile it if needed.
93053         * modules/wctype (Files): Add lib/iswblank.c.
93055 2010-12-19  Bruno Haible  <bruno@clisp.org>
93057         signal: Document problem with type of SIGRTMIN, SIGRTMAX on OSF/1 5.1.
93058         * doc/posix-headers/signal.texi: Document OSF/1 5.1 problem.
93059         * lib/strsignal.c (strsignal): Cast SIGRTMIN to 'int'.
93061 2010-12-19  Bruno Haible  <bruno@clisp.org>
93063         sys_socket: Use POSIX compatible declarations on OSF/1 5.1.
93064         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): On OSF/1, define
93065         _POSIX_PII_SOCKET.
93066         * doc/posix-functions/recv.texi: Document the OSF/1 problem.
93067         * doc/posix-functions/recvfrom.texi: Likewise.
93068         * doc/posix-functions/send.texi: Likewise.
93069         * doc/posix-functions/sendto.texi: Likewise.
93071 2010-12-19  Bruno Haible  <bruno@clisp.org>
93073         tcgetsid: Add missing declaration on OSF/1 5.1.
93074         * lib/termios.in.h (tcgetsid): Test HAVE_DECL_TCGETSID instead of
93075         HAVE_TCGETSID.
93076         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Test whether tcgetsid is declared.
93077         Don't set HAVE_TCGETSID.
93078         * m4/termios_h.m4 (gl_TERMIOS_H_DEFAULTS): Initialize
93079         HAVE_DECL_TCGETSID, not HAVE_TCGETSID.
93080         * modules/termios (Makefile.am): Substitute HAVE_DECL_TCGETSID, not
93081         HAVE_TCGETSID.
93082         * doc/posix-functions/tcgetsid.texi: Mention the OSF/1 5.1 problem.
93084 2010-12-19  Bruno Haible  <bruno@clisp.org>
93086         stdio: Fix problem with popen() declaration on OSF/1 5.1.
93087         * lib/stdio.in.h: During the include_next statement, let recursive
93088         includes of this file include only the system header file.
93090 2010-12-19  Bruno Haible  <bruno@clisp.org>
93092         iconv_open: Fix regression from 2010-12-04.
93093         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Fix typo.
93094         Reported by Noah Lavine <noah.b.lavine@gmail.com>.
93096 2010-12-19  Bruno Haible  <bruno@clisp.org>
93098         stdbool test: Avoid a gcc warning.
93099         * tests/test-stdbool.c (main): Fail if e1 is false.
93100         Reported by Jim Meyering.
93102 2010-12-19  Jim Meyering  <meyering@redhat.com>
93104         setenv: restore to working order
93105         $HAVE_SETENV is used in gl_FUNC_SETENV, yet its definitions were
93106         mistakenly removed.
93107         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Restore code to set
93108         HAVE_SETENV.
93109         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Restore code to initialize
93110         HAVE_SETENV.
93112 2010-12-19  Bruno Haible  <bruno@clisp.org>
93114         Document some different function declarations on OSF/1 5.1.
93115         * doc/posix-functions/gai_strerror.texi: Mention different declaration.
93116         * doc/posix-functions/inet_ntop.texi: Likewise.
93117         * doc/posix-functions/gethostname.texi: Likewise.
93118         * lib/unistd.in.h (gethostname): Update comment.
93120 2010-12-19  Bruno Haible  <bruno@clisp.org>
93122         doc: Mention vasprintf-posix module.
93123         * doc/glibc-functions/asprintf.texi: Mention the workarounds present in
93124         the 'vasprintf-posix' module.
93125         * doc/glibc-functions/vasprintf.texi: Likewise.
93127 2010-12-19  Bruno Haible  <bruno@clisp.org>
93129         unsetenv: Add missing declaration on OSF/1 5.1.
93130         * lib/stdlib.in.h (setenv): Test HAVE_DECL_UNSETENV, not HAVE_UNSETENV.
93131         * m4/setenv.m4 (gl_FUNC_UNSETENV): Test whether unsetenv is declared.
93132         Don't set HAVE_UNSETENV. In the test program, set _BSD.
93133         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_UNSETENV,
93134         not HAVE_UNSETENV.
93135         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_UNSETENV, not
93136         HAVE_UNSETENV.
93137         * doc/posix-functions/unsetenv.texi: Mention the OSF/1 5.1 problem.
93139 2010-12-19  Bruno Haible  <bruno@clisp.org>
93141         setenv: Add missing declaration on OSF/1 5.1.
93142         * lib/stdlib.in.h (setenv): Test HAVE_DECL_SETENV, not HAVE_SETENV.
93143         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Test whether setenv is
93144         declared. Don't set HAVE_SETENV.
93145         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_SETENV,
93146         not HAVE_SETENV.
93147         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_SETENV, not
93148         HAVE_SETENV.
93149         * doc/posix-functions/setenv.texi: Mention the OSF/1 5.1 problem.
93151 2010-12-19  Bruno Haible  <bruno@clisp.org>
93153         nl_langinfo tests: Avoid gcc warning.
93154         * tests/test-nl_langinfo.c: Don't enable the GCC pragma for GCC 4.2.
93156 2010-12-19  Bruno Haible  <bruno@clisp.org>
93158         mknod: Avoid error in C++ mode on OSF/1 with GCC.
93159         * lib/sys_stat.in.h (mknod): Use _GL_CXXALIAS_SYS_CAST instead of
93160         _GL_CXXALIAS_SYS.
93162 2010-12-19  Bruno Haible  <bruno@clisp.org>
93164         stdbool: Relax test.
93165         * tests/test-stdbool.c (e): Don't require that casts from a variable's
93166         address to 'bool' work in static initializer, for compilers other than
93167         GCC.
93169 2010-12-19  Bruno Haible  <bruno@clisp.org>
93171         ftello: Add missing declaration on OSF/1 5.1.
93172         * lib/stdio.in.h (ftello): Test HAVE_DECL_FTELLO, not HAVE_FTELLO.
93173         * m4/ftello.m4 (gl_FUNC_FTELLO): Test whether ftello is declared.
93174         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_FTELLO.
93175         * modules/stdio (Makefile.am): Substitute HAVE_DECL_FTELLO.
93176         * doc/posix-functions/ftello.texi: Mention the OSF/1 5.1 problem.
93178 2010-12-19  Bruno Haible  <bruno@clisp.org>
93180         fseeko: Add missing declaration on OSF/1 5.1.
93181         * lib/stdio.in.h (fseeko): Test HAVE_DECL_FSEEKO, not HAVE_FSEEKO.
93182         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Test whether fseeko is declared.
93183         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_FSEEKO.
93184         * modules/stdio (Makefile.am): Substitute HAVE_DECL_FSEEKO.
93185         * doc/posix-functions/fseeko.texi: Mention the OSF/1 5.1 problem.
93187 2010-12-19  Bruno Haible  <bruno@clisp.org>
93189         fchdir: Add missing declaration on OSF/1 5.1.
93190         * lib/unistd.in.h (fchdir): Provide declaration if systems lacks it.
93191         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Check whether fchdir is declared.
93192         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_FCHDIR.
93193         * modules/unistd (Makefile.am): Substitute HAVE_DECL_FCHDIR.
93194         * doc/posix-functions/fchdir.texi: Mention the OSF/1 5.1 problem.
93196 2010-12-19  Bruno Haible  <bruno@clisp.org>
93198         relocatable-prog-wrapper: Separate from relocatable-prog.
93199         * modules/relocatable-prog (Makefile.am): Define uninstall-hook and
93200         uninstall-relocwrapper rule here.
93201         * modules/relocatable-prog-wrapper (Makefile.am): ... not here.
93202         Reported by Ian Beckwith <ianb@erislabs.net>.
93204 2010-12-19  Bruno Haible  <bruno@clisp.org>
93206         unistr/u8-mbsnlen: Add missing dependency.
93207         * modules/unistr/u8-mbsnlen (Depends-on): Add unistr/u8-mbtouc.
93208         Reported by Ian Beckwith <ianb@erislabs.net>.
93210 2010-12-19  Bruno Haible  <bruno@clisp.org>
93212         iconv: Make it possible again to use this module without 'iconv-h'.
93213         * modules/iconv (configure.ac): Don't invoke gl_ICONV_MODULE_INDICATOR
93214         if it is not defined.
93215         Reported by Ian Beckwith <ianb@erislabs.net>.
93217 2010-12-18  Paul Eggert  <eggert@cs.ucla.edu>
93219         acl: port to Solaris 8 when copying from tmpfs to ufs
93220         * lib/copy-acl.c (qcopy_acl): Also allow EINVAL as an ignorable
93221         error number.  Problem observed on Solaris 8 with latest
93222         coreutils, with "mv A B", where A is on a tmpfs file system and B
93223         is on a ufs file system.  This caused coreutils' mv/part-symlink
93224         test to fail.
93226         tests: set fail=0 at start
93227         * tests/init.sh (setup_): Move fail=0 initialization here ...
93228         (mktempd_): ... from here, so that tests can rely on fail being
93229         set to 0 initially.  This fixes a problem in coreutils; see:
93230         http://lists.gnu.org/r/coreutils/2010-12/msg00083.html
93232 2010-12-18  Bruno Haible  <bruno@clisp.org>
93234         memmem-simple: Stylistic changes.
93235         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Avoid possible gcc warning.
93236         Fix preprocessor directive indentation.
93238 2010-12-15  Pádraig Brady  <P@draigBrady.com>
93240         memmem, memmem-simple: reorganize and expand empty needle check
93241         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE, gl_FUNC_MEMMEM): Move all
93242         functional checks to memmem-simple so that one has a fully functional
93243         memmem by using just this module.
93244         Restrict the performance only check to the memmem module.
93245         Also expand the empty needle check to ensure the correct
93246         pointer is returned, not just a non NULL pointer.
93247         * doc/glibc-functions/memmem.texi: Rearrange the portability
93248         documentation to correlate with the rearranged checks.
93249         Clarify exactly how the memmem and memmem-simple modules
93250         relate to each other.
93252 2010-12-15  Pádraig Brady  <P@draigBrady.com>
93253             Bruno Haible  <bruno@clisp.org>
93255         Improve cross-compilation guesses for uClibc.
93256         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): When cross-compiling, assume
93257         that uClibc does not have the glibc bug.
93258         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Likewise.
93259         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Likewise.
93261 2010-12-14  Eric Blake  <eblake@redhat.com>
93263         configmake: provide fallbacks for oldest supported autotools
93264         * m4/configmake.m4: New file.
93265         * modules/configmake (Files): Ship it.
93266         (configure.ac): Use it to guarantee fallbacks.
93268 2010-12-13  Pádraig Brady  <P@draigBrady.com>
93270         read-file: Improve handling of large files
93271         * lib/read-file.c (fread_file): Minimize realloc()s
93272         for regular files, and better manage sizes around SIZE_MAX.
93274 2010-12-13  Eric Blake  <eblake@redhat.com>
93276         cloexec, fcntl: relax license
93277         * modules/cloexec (License): Change from LGPLv3+ to LGPLv2+, with
93278         consent from all contributors.
93279         * modules/fcntl (License): Likewise.
93281 2010-12-10  Bruno Haible  <bruno@clisp.org>
93283         Tests for module 'pipe-posix'.
93284         * modules/pipe-posix-tests: New file.
93285         * tests/test-pipe.c: New file, based on tests/test-pipe2.c.
93287 2010-12-10  Bruno Haible  <bruno@clisp.org>
93289         pipe-posix: Make it work in C++ mode.
93290         * lib/unistd.in.h: Don't include <io.h>, <fcntl.h> for pipe.
93291         (pipe): Use common idiom, not a macro definition.
93292         * lib/pipe.c: New file.
93293         * m4/pipe.m4: New file.
93294         * modules/pipe-posix (Description): Enhance.
93295         (Files): Add lib/pipe.c, m4/pipe.m4.
93296         (configure.ac): Invoke gl_FUNC_PIPE.
93297         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_PIPE.
93298         * modules/unistd (Makefile.am): Substitute HAVE_PIPE.
93299         * tests/test-unistd-c++.cc: Check the signature of pipe.
93301 2010-12-10  Bruno Haible  <bruno@clisp.org>
93303         Rename module 'pipe' to 'spawn-pipe'.
93304         * modules/spawn-pipe: New file, renamed from modules/pipe.
93305         (Files, configure.ac, Makefile.am): Update.
93306         (Include): Mention "spawn-pipe.h" instead of "pipe.h".
93307         * modules/pipe: Reduce to an obsolete indirection to 'spawn-pipe'.
93308         * lib/spawn-pipe.h: New file, renamed from lib/pipe.h.
93309         * lib/spawn-pipe.c: New file, renamed from lib/pipe.c. Include
93310         "spawn-pipe.h" instead of "pipe.h".
93311         * m4/spawn-pipe.m4: New file, renamed from m4/pipe.m4. Rename gl_PIPE
93312         to gl_SPAWN_PIPE.
93313         * modules/spawn-pipe-tests: New file, renamed from modules/pipe-tests.
93314         (Files, Makefile.am): Update.
93315         * tests/test-spawn-pipe.sh: New file, renamed from tests/test-pipe.sh.
93316         Update.
93317         * tests/test-spawn-pipe.c: New file, renamed from tests/test-pipe.c.
93318         Include "spawn-pipe.h" instead of "pipe.h".
93319         * lib/csharpcomp.c: Include "spawn-pipe.h" instead of "pipe.h".
93320         * lib/javacomp.c: Likewise.
93321         * lib/javaversion.c: Likewise.
93322         * lib/pipe-filter-gi.c: Likewise.
93323         * lib/pipe-filter-ii.c: Likewise.
93324         * modules/csharpcomp (Depends-on): Add 'spawn-pipe', remove 'pipe'.
93325         * modules/javacomp (Depends-on): Likewise.
93326         * modules/javaversion (Depends-on): Likewise.
93327         * modules/pipe-filter-gi (Depends-on): Likewise.
93328         * modules/pipe-filter-ii (Depends-on): Likewise.
93329         * MODULES.html.sh (Executing programs): Update.
93330         * NEWS: Mention the change.
93332 2010-12-10  Eric Blake  <eblake@redhat.com>
93334         pipe-posix: new module
93335         * modules/pipe-posix: New file.
93336         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set default.
93337         (gl_UNISTD_H): Check for declaration.
93338         * modules/unistd (Makefile.am): Substitute it.
93339         * lib/unistd.in.h (pipe): Provide it for mingw.
93340         * doc/posix-functions/pipe.texi (pipe): Update documentation.
93341         * MODULES.html.sh (File descriptor based Input/Output): Likewise.
93343 2010-12-07  Bruno Haible  <bruno@clisp.org>
93345         unistr/u8-strcmp: Avoid collision with libc function on Solaris 11.
93346         * lib/unistr.in.h (u8_strcmp) [__sun]: Declare with real name
93347         u8_strcmp_gnu.
93348         * modules/unistr/u8-strcmp (configure.ac): Bump version number.
93350 2010-12-06  Bruno Haible  <bruno@clisp.org>
93352         Update internal documentation.
93353         * m4/README: Document new idioms for AC_RUN_IFELSE invocations.
93355 2010-12-04  Bruno Haible  <bruno@clisp.org>
93357         Put more information about failed tests into the test return codes.
93358         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Change test
93359         program so that it returns an enumerated value (0, 1, 2, 3, 4, ...).
93360         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
93361         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
93362         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
93363         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
93364         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
93365         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
93366         * m4/isapipe.m4 (gl_PREREQ_ISAPIPE): Likewise.
93367         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
93368         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Likewise.
93369         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
93370         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
93371         * m4/stdint.m4 (gl_STDINT_H): Likewise.
93372         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Change test program so that it
93373         returns a bit mask.
93374         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Likewise.
93375         * m4/chown.m4 (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Likewise.
93376         * m4/dup2.m4 (gl_FUNC_DUP2): Likewise.
93377         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Likewise.
93378         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
93379         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Likewise.
93380         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
93381         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
93382         * m4/iconv.m4 (AM_ICONV_LINK): Likewise.
93383         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Likewise.
93384         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
93385         * m4/isnanf.m4 (gl_ISNANF_WORKS): Likewise.
93386         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
93387         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Likewise.
93388         * m4/link.m4 (gl_FUNC_LINK): Likewise.
93389         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
93390         * m4/mbrlen.m4 (gl_MBRLEN_RETVAL): Likewise.
93391         * m4/mbrtowc.m4 (gl_MBRTOWC_RETVAL): Likewise.
93392         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
93393         * m4/memchr.m4 (gl_FUNC_MEMCHR): Likewise.
93394         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
93395         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
93396         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
93397         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
93398         * m4/open.m4 (gl_FUNC_OPEN): Likewise.
93399         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
93400         * m4/popen.m4 (gl_FUNC_POPEN): Likewise.
93401         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE,
93402         gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE,
93403         gl_PRINTF_DIRECTIVE_A, gl_PRINTF_DIRECTIVE_F, gl_PRINTF_DIRECTIVE_LS,
93404         gl_PRINTF_PRECISION): Likewise.
93405         * m4/regex.m4 (gl_REGEX): Likewise.
93406         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
93407         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
93408         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Likewise.
93409         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
93410         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
93411         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
93412         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Likewise.
93413         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Likewise.
93414         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
93415         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
93416         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
93417         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
93418         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Likewise.
93419         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
93420         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
93421         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
93422         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
93423         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
93424         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
93425         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Likewise.
93426         (gl_FLOATTYPE_SIGN_LOCATION): Change test program so that it returns an
93427         enumerated value.
93428         * m4/acl.m4 (gl_ACL_GET_FILE): Use "if ... return 1; return 0;" style.
93430 2010-12-04  Bruno Haible  <bruno@clisp.org>
93432         Update for Solaris 11 2010-11.
93433         * doc/{glibc,posix}-{functions,headers}: Add info about Solaris 11
93434         Express, released in November 2010.
93436 2010-12-04  Bruno Haible  <bruno@clisp.org>
93438         nproc: Relax license.
93439         * modules/nproc (License): Change to LGPL, with consent by Glen Lenker
93440         and Paul Eggert.
93441         Requested by Ludovic Courtès <ludo@gnu.org>.
93443 2010-12-01  Paul Eggert  <eggert@cs.ucla.edu>
93445         utimecmp: fine-grained src to nearby coarse-grained dest
93447         * lib/utimecmp.c (utimecmp): When UTIMECMP_TRUNCATE_SOURCE is set,
93448         and the source is on a file system with higher-resolution time
93449         stamps, than the destination, and _PC_TIMESTAMP_RESOLUTION does
93450         not work, and the time stamps are close together, the algorithm to
93451         determine the exact resolution from the read-back mtime was buggy:
93452         it had a "!=" where it should have had an "==".  This bug has been
93453         in the code ever since it was introduced to gnulib.
93454         Problem reported by Dan Jacobson in
93455         <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=7529>.
93457 2010-11-30  Bruno Haible  <bruno@clisp.org>
93459         strerror_r-posix: Fix autoconf test.
93460         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Fix typo.
93462 2010-11-28  Bruno Haible  <bruno@clisp.org>
93463             Paul Eggert  <eggert@cs.ucla.edu>
93465         Tests for module 'getdomainname'.
93466         * modules/getdomainname-tests: New file.
93467         * tests/test-getdomainname.c: New file, based on
93468         tests/test-gethostname.c.
93470 2010-11-28  Bruno Haible  <bruno@clisp.org>
93471             Paul Eggert  <eggert@cs.ucla.edu>
93473         getdomainname: Use the system function when possible.
93474         * lib/unistd.in.h: Include <netdb.h>, for getdomainname's declaration.
93475         (getdomainname): Replace if needed. Provide the declaration if it is
93476         missing. Don't use _GL_CXXALIAS_SYS_CAST.
93477         * lib/getdomainname.c: Include <limits.h> and <sys/systeminfo.h>.
93478         (getdomainname): When the system has getdomainname, call the system
93479         function. When sysinfo (SI_SRPC_DOMAIN, ...) is possible, use that.
93480         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Require
93481         gl_HEADER_SYS_SOCKET and gl_HEADER_NETDB. Test whether the function is
93482         found in libnsl. Look for the declaration also in <netdb.h>. Replace
93483         the function if its second argument is of type 'int' or if it is found
93484         in libnsl.
93485         (gl_PREREQ_GETDOMAINNAME): Define HAVE_GETDOMAINNAME. Check for
93486         <sys/systeminfo.h> and sysinfo().
93487         * modules/getdomainname (Depends-on): Add netdb, sys_socket.
93488         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
93489         HAVE_DECL_GETDOMAINNAME and REPLACE_GETDOMAINNAME instead of
93490         HAVE_GETDOMAINNAME.
93491         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETDOMAINNAME and
93492         REPLACE_GETDOMAINNAME instead of HAVE_GETDOMAINNAME.
93493         * doc/glibc-functions/getdomainname.texi: Document the problems with
93494         the getdomainname declaration.
93496 2010-11-28  Bruno Haible  <bruno@clisp.org>
93498         sys_socket: Ensure ss_family field on AIX.
93499         * lib/sys_socket.in.h (ss_family): New macro definition.
93500         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Set
93501         HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY. Set SYS_SOCKET_H if necessary.
93502         (gl_SYS_SOCKET_H_DEFAULTS): Initialize
93503         HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY.
93504         * modules/sys_socket (Makefile.am): Substitute
93505         HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY.
93506         * doc/posix-headers/sys_socket.texi: Mention the AIX bug.
93508 2010-11-27  Bruno Haible  <bruno@clisp.org>
93510         readline: Improve configure output.
93511         * m4/readline.m4 (gl_FUNC_READLINE): Make the
93512         "checking for readline..." result understandable.
93514 2010-11-27  Bruno Haible  <bruno@clisp.org>
93516         *printf-posix: Detect a bug on Solaris 10/x86.
93517         * m4/printf.m4 (gl_PRINTF_PRECISION): Detect crash with large precision
93518         for floating-point output.
93519         * tests/test-vasnprintf-posix.c (test_function): Test precision with %f
93520         directive.
93521         * tests/test-snprintf-posix.h (test_function): Likewise.
93522         * tests/test-sprintf-posix.h (test_function): Likewise.
93523         * tests/test-vasprintf-posix.c (test_function): Likewise.
93524         * doc/posix-functions/fprintf.texi: Mention Solaris/x86 bug.
93525         * doc/posix-functions/printf.texi: Likewise.
93526         * doc/posix-functions/snprintf.texi: Likewise.
93527         * doc/posix-functions/sprintf.texi: Likewise.
93528         * doc/posix-functions/vfprintf.texi: Likewise.
93529         * doc/posix-functions/vprintf.texi: Likewise.
93530         * doc/posix-functions/vsnprintf.texi: Likewise.
93531         * doc/posix-functions/vsprintf.texi: Likewise.
93532         * doc/glibc-functions/obstack_printf.texi: Likewise.
93533         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
93535 2010-11-27  Bruno Haible  <bruno@clisp.org>
93537         Fix link error when module libunistring-optional is in use.
93538         * modules/striconveh-tests (Makefile.am): Link with $(LIBUNISTRING).
93539         * modules/striconveha-tests (Makefile.am): Likewise.
93541 2010-11-27  Bruno Haible  <bruno@clisp.org>
93543         regex: Mention link dependencies.
93544         * modules/regex (Link): New section.
93545         * modules/rpmatch (Link): Likewise.
93546         * modules/regex-quote-tests (Makefile.am): Link with $(LIBINTL).
93548 2010-11-27  Bruno Haible  <bruno@clisp.org>
93550         ftoastr: Fix compilation error on Solaris.
93551         * lib/ftoastr.c: Include <config.h>.
93553 2010-11-27  Bruno Haible  <bruno@clisp.org>
93555         getloadavg: Update documentation.
93556         * doc/glibc-functions/getloadavg.texi: Mention the Solaris problem.
93558 2010-11-27  Bruno Haible  <bruno@clisp.org>
93560         sys_socket: Fix test whether the functions are declared.
93561         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Include <sys/socket.h>,
93562         not <sys/select.h>.
93564 2010-11-27  Bruno Haible  <bruno@clisp.org>
93566         getpass: Make sure to get system declaration on some platforms.
93567         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU): Require
93568         gl_USE_SYSTEM_EXTENSIONS.
93569         * modules/getpass (Depends-on): Add extensions.
93571 2010-11-26  Bruno Haible  <bruno@clisp.org>
93573         iconv-h: Fix test-iconv-h-c++ failure on Solaris 11 2010-11.
93574         * lib/iconv.in.h (iconv_open, iconv, iconv_close): Define only if the
93575         'iconv' module is present.
93576         (ICONV_CONST): New macro.
93577         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Initialize GNULIB_ICONV and
93578         ICONV_CONST.
93579         * m4/iconv.m4 (AM_ICONV): If the gnulib module 'iconv-h' is present,
93580         set ICONV_CONST.
93581         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Don't set ICONV_CONST
93582         here.
93583         * modules/iconv (configure.ac): Invoke gl_ICONV_MODULE_INDICATOR.
93584         * modules/iconv-h (Makefile.am): Substitute GNULIB_ICONV.
93585         * tests/test-iconv-h.c (ICONV_CONST): Don't define here.
93586         * tests/test-iconv-h-c++.cc (ICONV_CONST): Don't define here.
93587         (iconv_open, iconv, iconv_close): Test only if the 'iconv' module is
93588         present.
93590 2010-11-25  Paul Eggert  <eggert@cs.ucla.edu>
93592         ftoastr: comment fix
93593         * lib/ftoastr.c: "little" -> "little or no" in comment
93595 2010-11-24  Paul Eggert  <eggert@cs.ucla.edu>
93597         stdint: port to GCC 4.3 + OSX + Octave
93598         On this platform, stdint.h is buggy and defines int64_t to long
93599         long int.  The replacement defined it to long int, causing
93600         problems with C++ style name mangling.  Instead, trust the system
93601         definition if INT64_MAX is defined, and likewise for the unsigned
93602         variant.   Problem reported by Jarno Rajahalme in
93603         <http://lists.gnu.org/r/bug-gnulib/2010-04/msg00143.html>.
93604         * lib/stdint.in.h (GL_INT64_T): Define if INT64_MAX is defined,
93605         and don't mess with int64_t and INT64_MAX in this case.
93606         (GL_UINT64_T): Likewise for UINT64_MAX and uint64_t.
93608 2010-11-24  Bruno Haible  <bruno@clisp.org>
93610         doc: Corrections regarding MacOS X 10.4 and 10.5.
93611         * doc/{glibc,posix,pastposix}-functions/*.texi: Update info about
93612         MacOS X.
93613         Reported by Simon Josefsson.
93615 2010-11-22  Ben Pfaff  <blp@cs.stanford.edu>
93617         Uninstall ".bin" files installed by relocwrapper.
93618         * modules/relocatable-prog-wrapper (uninstall-relocwrapper):
93619         Recursively run "make uninstall" with ".bin" prefixed to EXEEXT,
93620         unless it is already there.
93622 2010-11-21  Bruno Haible  <bruno@clisp.org>
93624         Update for NetBSD 5.0.
93625         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Don't guess yes on
93626         NetBSD; the test fails on NetBSD 5.0.
93627         * doc/{glibc,posix,pastposix}-{headers,functions}/*.texi: Update info
93628         about NetBSD.
93630 2010-11-21  Bruno Haible  <bruno@clisp.org>
93632         Update for HP-UX 11.23 and HP-UX 11.31.
93633         * doc/{glibc,posix}-{headers,functions}/*.texi: Update info about
93634         HP-UX.
93636 2010-11-21  Bruno Haible  <bruno@clisp.org>
93638         Update for MacOS X 10.5.
93639         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Don't guess yes on
93640         MacOS X; the test fails on MacOS X 10.5.8.
93641         * doc/{glibc,posix,pastposix}-{headers,functions}/*.texi: Update info
93642         about MacOS X.
93644 2010-11-20  Joel E. Denny  <joeldenny@joeldenny.org>
93646         bootstrap: add bootstrap_sync option.
93647         See discussion at
93648         <http://lists.gnu.org/r/bug-gnulib/2010-10/msg00369.html>,
93649         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00200.html>.
93650         * build-aux/bootstrap: Accept --bootstrap-sync to update
93651         bootstrap if it is not identical to the local gnulib's
93652         bootstrap.  Accept bootstrap_sync=true in bootstrap.conf to
93653         enable this by default.  Accept --no-bootstrap-sync to disable
93654         it.
93656 2010-11-20  Bruno Haible  <bruno@clisp.org>
93658         Ensure that <features.h> is included before __GLIBC__ is tested.
93659         * lib/printf-parse.h: Include <features.h>.
93660         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gl_FEATURES_H.
93661         Reported by Mike Frysinger <vapier@gentoo.org>.
93663         Ensure that <features.h> is included before __GLIBC__ is tested.
93664         * lib/wchar.in.h: Include <features.h>.
93665         * m4/wchar_h.m4 (gl_WCHAR_H): Require gl_FEATURES_H.
93666         * modules/wchar (Makefile.am): Substitute HAVE_FEATURES_H.
93667         Reported by Mike Frysinger <vapier@gentoo.org>.
93669         Ensure that <features.h> is included before __GLIBC__ is tested.
93670         * lib/arpa_inet.in.h: Include <features.h>.
93671         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Require gl_FEATURES_H.
93672         * modules/arpa_inet (Makefile.am): Substitute HAVE_FEATURES_H.
93673         Reported by Mike Frysinger <vapier@gentoo.org>.
93675         Ensure that <features.h> is included before __GLIBC__ is tested.
93676         * build-aux/link-warning.h: Include <features.h>.
93677         * modules/link-warning (configure.ac): Require gl_FEATURES_H.
93678         (Makefile.am): Substitute HAVE_FEATURES_H into link-warning.h.
93679         Reported by Mike Frysinger <vapier@gentoo.org>.
93681         Ensure that <features.h> is included before __GLIBC__ is tested.
93682         * m4/gnulib-common.m4 (gl_FEATURES_H): New macro.
93683         Reported by Mike Frysinger <vapier@gentoo.org>.
93685 2010-11-20  Bruno Haible  <bruno@clisp.org>
93687         memmem: Fix autoconf test.
93688         * m4/memmem.m4 (gl_FUNC_MEMMEM): Test HAVE_DECL_MEMMEM, not HAVE_MEMMEM.
93690 2010-11-20  Bruno Haible  <bruno@clisp.org>
93692         Port to uClibc.
93693         * build-aux/link-warning.h (GL_LINK_WARNING): Treat uClibc like glibc.
93694         * lib/fcntl.in.h: Likewise.
93695         * lib/hard-locale.c (GLIBC_VERSION): Likewise.
93696         * lib/mbrtowc.c (mbrtowc): Likewise.
93697         * lib/relocatable.c (find_shared_library_fullname): Likewise.
93698         * lib/strerror_r.c: Likewise.
93699         * lib/unistr/u8-strnlen.c: Likewise.
93700         * lib/vasnprintf.c (decimal_point_char): Likewise.
93701         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Likewise.
93702         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Likewise.
93703         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Likewise.
93704         * m4/glibc21.m4 (gl_GLIBC21): Likewise.
93705         * tests/test-sigaction.c (handler, main): Likewise.
93706         * lib/freading.h: Treat uClibc like a non-glibc platform.
93707         * lib/freading.c: Likewise.
93708         * lib/gettext.h: Likewise.
93709         * lib/localename.c (gl_locale_name_thread_unsafe, HAVE_LOCALE_NULL):
93710         Likewise.
93711         * lib/printf-parse.h (FLAG_LOCALIZED): Likewise.
93712         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
93713         * lib/propername.c (proper_name_utf8): Likewise.
93714         * lib/spawn.in.h: Likewise.
93715         * lib/striconv.c (mem_cd_iconv, str_cd_iconv, str_iconv): Likewise.
93716         * lib/striconveh.c (iconveh_open, iconv_carefully, iconv_carefully_1,
93717         mem_cd_iconveh_internal): Likewise.
93718         * lib/striconveha.c (mem_iconveha, str_iconveha): Likewise.
93719         * lib/string.in.h (memchr, memrchr, rawmemchr, strchrnul, strpbrk,
93720         strstr, strcasestr): Likewise.
93721         * lib/unicodeio.c (unicode_to_mb): Likewise.
93722         * lib/uniconv/u16-conv-from-enc.c (UTF16_NAME): Likewise.
93723         * lib/uniconv/u16-conv-to-enc.c (UTF16_NAME): Likewise.
93724         * lib/uniconv/u16-strconv-to-enc.c (UTF16_NAME): Likewise.
93725         * lib/uniconv/u32-conv-from-enc.c (UTF32_NAME): Likewise.
93726         * lib/uniconv/u32-conv-to-enc.c (UTF32_NAME): Likewise.
93727         * lib/uniconv/u32-strconv-to-enc.c (UTF32_NAME): Likewise.
93728         * lib/unistr/u8-stpncpy.c: Likewise.
93729         * lib/vasnprintf.c (VASNPRINTF): Likewise.
93730         * lib/xmalloc.c (HAVE_GNU_CALLOC): Likewise.
93731         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
93732         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
93733         * m4/glibc2.m4 (gt_GLIBC2): Likewise.
93734         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Likewise.
93735         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE, gl_FUNC_MEMMEM): Likewise.
93736         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Likewise.
93737         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE, gl_FUNC_STRCASESTR):
93738         Likewise.
93739         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Likewise.
93740         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
93741         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
93742         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
93743         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
93744         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
93745         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
93746         * m4/wchar_h.m4 (gl_WCHAR_H): Likewise.
93747         * tests/test-getopt.h (OPTIND_MIN): Likewise.
93748         * tests/test-striconveha.c (main): Likewise.
93749         * tests/test-vasnprintf-posix.c (test_function): Likewise.
93750         * tests/test-vasnprintf-posix3.c (test_function, main): Likewise.
93751         * doc/posix-functions/getdelim.texi: Mention an uClibc bug.
93752         * doc/posix-functions/getline.texi: Likewise.
93753         Reported by Mike Frysinger <vapier@gentoo.org>.
93755 2010-11-20  Bruno Haible  <bruno@clisp.org>
93757         nproc: Fix condition.
93758         * lib/nproc.c: Test HAVE_PTHREAD_GETAFFINITY_NP, not
93759         HAVE_PTHREAD_AFFINITY_NP.
93761 2010-11-20  Bruno Haible  <bruno@clisp.org>
93763         Fix a comment.
93764         * lib/vasnprintf.c (VASNPRINTF): Fix comment.
93766 2010-11-19  Paul Eggert  <eggert@cs.ucla.edu>
93768         ftoastr: don't assume snprintf
93769         * lib/ftoastr.c (snprintf) [! GNULIB_SNPRINTF_POSIX]:
93770         Implement a subset of snprintf here, by using sprintf safely.
93771         * modules/ftoastr (Depends-on): Remove snprintf.
93773 2010-11-19  Jim Meyering  <meyering@redhat.com>
93775         test-rename.h: fix compilation failure
93776         * tests/test-rename.h (test_rename): Add omitted "}".
93778 2010-11-17  Jim Meyering  <meyering@redhat.com>
93780         maint.mk: add a URL discussing the no-@acronym policy
93781         * top/maint.mk (sc_texinfo_acronym): Add a URL in a comment.
93783 2010-11-18  Paul Eggert  <eggert@cs.ucla.edu>
93785         ftoastr: depend on snprintf, improve comments
93786         * lib/ftoastr.c: Also mention Loitsch's draft.
93787         * lib/ftoastr.h: Require WIDTH to be nonnegative.  This isn't
93788         needed in the current implementation, but it might simplify
93789         speeding up the code later.
93790         * modules/ftoastr: Depend on snprintf; this improves portability.
93791         Suggested by Bruno Haible in the same email.
93793         ftoastr: port to hosts lacking strtof and strtold
93794         Problem reported by Bruno Haible in
93795         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00242.html>.
93796         * lib/ftoastr.c (STRTOF): Define to strtod if in a pre-C99
93797         environment and strtold (and presumably strtof) are not available.
93798         * modules/ftoastr (Files): Add m4/c-strtod.m4.
93799         (configure.ac): Require gl_C99_STRTOLD.
93801 2010-11-18  Bruno Haible  <bruno@clisp.org>
93803         c-strtold: Avoid link error on AIX 7.
93804         * lib/c-strtod.c: Test also HAVE_STRTOD_L or HAVE_STRTOLD_L.
93805         * m4/c-strtod.m4 (gl_C_STRTOD): Test whether strtod_l exists.
93806         (gl_C_STRTOLD): Test whether strtold_l exists.
93807         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
93809 2010-11-17  Paul Eggert  <eggert@cs.ucla.edu>
93811         intprops: new macro INT_BITS_STRLEN_BOUND
93812         * lib/intprops.h (INT_BITS_STRLEN_BOUND): New macro, needed by
93813         ftoastr.h.  This exposes an internal of intprops.h that was formerly
93814         not exposed.  Also, it uses a slightly tighter bound than before;
93815         though this makes no practical difference, we might as well be as
93816         tight as we easily can.
93818         ftoastr: new module, for lossless conversion of floats to short strings
93819         * lib/ftoastr.h, lib/ftoastr.c, lib/dtoastr.c, lib/ldtoastr.c:
93820         * modules/ftoastr: New files.
93822 2010-11-15  Paul Eggert  <eggert@cs.ucla.edu>
93824         bootstrap: port to Solaris sed
93825         * build-aux/bootstrap (get_version): Port to Solaris sed.
93826         See Ralf Wildenhues's note in
93827         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00156.html>.
93829 2010-11-14  Jim Meyering  <meyering@redhat.com>
93831         maint.mk: rename variable: s/noteworthy/gl_noteworthy_news_/
93832         * top/maint.mk (gl_noteworthy_news_): Rename from "noteworthy"
93833         and move definition closer to sole use.
93835 2010-11-13  Jim Meyering  <meyering@redhat.com>
93837         remove autoconf-2.57 work-around requiring AC_PROG_EGREP and AC_PROG_CPP
93838         Now we require at least autoconf-2.59, which means the work-around
93839         is no longer needed.
93840         * m4/alloca.m4 (gl_FUNC_ALLOCA): Remove work-around.
93841         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
93842         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
93843         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
93844         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
93846 2010-11-13  Bruno Haible  <bruno@clisp.org>
93848         rename, renameat: Avoid test failures at NFS mounted locations.
93849         * tests/test-rename.h (dentry_exists, assert_nonexistent): New
93850         functions.
93851         (test_rename): Use assert_nonexistent.
93852         * tests/test-rename.c: Include <dirent.h>.
93853         * tests/test-renameat.c: Likewise.
93854         Reported by Gary V. Vaughan <gary@gnu.org>.
93856         rename, renameat: Document Linux bug with NFS
93857         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00154.html>.
93858         * doc/posix-functions/rename.texi: Mention the NFS bug on Linux.
93859         * doc/posix-functions/renameat.texi: Likewise.
93860         Suggested by Eric Blake.
93862 2010-11-13  Bruno Haible  <bruno@clisp.org>
93864         rename test: Add comments.
93865         * tests/test-rename.h (test_rename): Add structure and comments.
93867 2010-11-13  Eric Blake  <eblake@redhat.com>
93869         maintainer-makefile: cover a few more files
93870         * top/maint.mk (sc_prohibit_test_double_equal): Also cover shell
93871         scripts generated within C files, for libvirt.
93873 2010-11-13  Bruno Haible  <bruno@clisp.org>
93875         unistr/u8-mbtouc: Improve handling of ill-formed UTF-8 input.
93876         * lib/unistr/u8-mbtouc.c (u8_mbtouc): For an invalid multibyte
93877         character, return the number of bytes that belong together, not always
93878         1.
93879         * lib/unistr/u8-mbtouc-unsafe.c (u8_mbtouc_unsafe): Likewise.
93880         * lib/unistr/u8-mbtouc-aux.c (u8_mbtouc_aux): Likewise.
93881         * lib/unistr/u8-mbtouc-unsafe-aux.c (u8_mbtouc_unsafe_aux): Likewise.
93882         * lib/unistr/u8-mbsnlen.c (u8_mbsnlen): Use u8_mbtouc to determine the
93883         number of bytes of an invalid character.
93884         * tests/unistr/test-u8-mbtouc.c (test_safe_function): New function.
93885         (main): Invoke it.
93886         * tests/unistr/test-u8-mbtouc.h (test_function): Update two test
93887         results.
93888         * tests/unistr/test-u8-mbsnlen.c (main): Test various kinds of
93889         malformed byte sequences.
93890         * modules/unistr/u8-mbtouc (configure.ac): Bump version number.
93891         * modules/unistr/u8-mbtouc-unsafe (configure.ac): Likewise.
93892         * modules/unistr/u8-mbsnlen (configure.ac): Likewise.
93893         Reported by Ben Pfaff and Paolo Bonzini.
93895 2010-11-13  Bruno Haible  <bruno@clisp.org>
93897         openat: Work around glibc bug with fchownat() and empty file names.
93898         * m4/openat.m4 (gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): New macro.
93899         (gl_FUNC_FCHOWNAT): Invoke it.
93900         * lib/fchownat.c (rpl_fchownat): Handle the empty file name specially.
93901         * doc/posix-functions/fchownat.texi: Document the glibc bug.
93902         Reported by Gary V. Vaughan <gary@gnu.org>.
93904 2010-11-13  Bruno Haible  <bruno@clisp.org>
93906         openat: Ensure autoconf macro ordering.
93907         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Require
93908         gl_USE_SYSTEM_EXTENSIONS.
93909         (gl_FUNC_FCHOWNAT): Require gl_UNISTD_H_DEFAULTS.
93911 2010-11-13  Bruno Haible  <bruno@clisp.org>
93913         Update comments.
93914         * lib/unistr/u8-check.c: Update file name in comments.
93915         * lib/unistr/u8-mblen.c: Likewise.
93916         * lib/unistr/u8-prev.c: Likewise.
93917         * lib/unistr/u8-strmblen.c: Likewise.
93918         * lib/unistr/u8-strmbtouc.c: Likewise.
93920 2010-11-13  Jim Meyering  <meyering@redhat.com>
93922         tests: avoid test failure on Solaris 10 due to lack of PATH export
93923         * tests/test-update-copyright.sh: Don't forget to export PATH.
93925         init.sh: ensure that IFS is defined, just in case...
93926         * tests/init.sh (setup_): Ensure that IFS is defined,
93927         so that saving and restoring it works as expected.  This
93928         appears to be useful at least for an old version of dash
93929         from a long time ago (RH 6).  See here for details:
93930         http://thread.gmane.org/gmane.comp.gnu.coreutils.general/436/focus=455
93932         maint.mk: tighten "test a == b" check
93933         * top/maint.mk (sc_prohibit_test_double_equal): Restrict this
93934         test to files that contain something like #!/bin/sh.
93935         Without this, coreutils would get two false positives in
93936         the comments of C source files.
93938 2010-11-12  Eric Blake  <eblake@redhat.com>
93940         bootstrap: fix typo in previous attempt
93941         * build-aux/bootstrap (buildreq): Correct the grouping.
93942         Reported by Paul Eggert.
93944         maintainer-makefile: prohibit test x == x
93945         * top/maint.mk (sc_prohibit_test_double_equal): New rule.
93946         Based on a report by Matthias Bolte.
93948         bootstrap: allow FreeBSD gzip
93949         * build-aux/bootstrap (get_version): Parse FreeBSD gzip version,
93950         which has no '.' and goes to stderr.
93951         * build-aux/bootstrap.conf (buildreq): Improve the sample file.
93952         Reported by Matthias Bolte.
93954         maintainer-makefile: check for i18n setup
93955         * top/maint.mk (sc_bindtextdomain): Check for evidence that _()
93956         will likely work.
93958 2010-11-12  Bruno Haible  <bruno@clisp.org>
93960         sleep, nanosleep: Work around Linux 2.6.9 nanosleep bug.
93961         * lib/sleep.c (rpl_sleep): Split in chunks no larger than 24 days.
93962         * lib/nanosleep.c (nanosleep): Likewise.
93964 2010-11-11  Bruno Haible  <bruno@clisp.org>
93966         fcntl-h: Fix for use of C++ on glibc systems.
93967         * lib/fcntl.in.h: Include <sys/stat.h> before include_next <fcntl.h>
93968         also on glibc systems in C++ mode.
93969         Reported by Gary V. Vaughan <gary@gnu.org>.
93971 2010-11-11  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
93973         mknod: avoid false failure with dash
93974         * m4/mknod.m4 (gl_FUNC_MKNOD): Use portable shell syntax.
93976 2010-11-11  Paul Eggert  <eggert@cs.ucla.edu>
93978         unlink: Fix "is it should" typo in diagnostic.
93979         * m4/unlink.m4 (gl_FUNC_UNLINK): Fix typo, as per Reuben Thomas in
93980         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00106.html>.
93982 2010-11-11  Bruno Haible  <bruno@clisp.org>
93984         Tests for module 'strerror_r-posix'.
93985         * modules/strerror_r-posix-tests: New file.
93986         * tests/test-strerror_r.c: New file.
93987         * tests/test-string-c++.cc: Check the signature of strerror_r.
93989         New module 'strerror_r-posix'.
93990         * lib/string.in.h (strerror_r): New declaration.
93991         * lib/strerror_r.c: New file.
93992         * m4/strerror_r.m4: New file.
93993         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Check for the declaration
93994         of strerror_r.
93995         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_STRERROR_R,
93996         HAVE_DECL_STRERROR_R, REPLACE_STRERROR_R.
93997         * modules/strerror_r-posix: New file.
93998         * modules/string (Makefile.am): Substitute GNULIB_STRERROR_R,
93999         HAVE_DECL_STRERROR_R, REPLACE_STRERROR_R.
94000         * doc/posix-functions/strerror_r.texi: Mention the new module and the
94001         portability problems.
94003 2010-11-11  Torsten Scheck  <Torsten.Scheck@Leica-Microsystems.com> (tiny change)
94005         * build-aux/pmccabe2html: Fixed a off-by-one error, so last input
94006         line is also considered for output. Quoted function name in shell
94007         command, so temporary files for functions like MyClass::operator()
94008         are removed correctly without errors.
94010 2010-11-09  Bruno Haible  <bruno@clisp.org>
94012         * doc/posix-functions/strerror.texi: List more failing platforms.
94014         * doc/posix-functions/strerror.texi: Add a comment.
94016 2010-11-07  Paul Eggert  <eggert@cs.ucla.edu>
94018         fdopendir: fix bug on MacOS X when low on file descriptors
94020         * lib/fdopendir.c (REPLACE_FCHDIR): #define to 0 if not defined.
94021         (fdopendir_with_dup, fd_clone_opendir): Now have extra CWD arg.
94022         All callers changed.
94023         (fdopendir): Invoke save_cwd at the top level, not after using
94024         multiple dup() calls to use up file descriptors.  Then retry
94025         fdopendir_with_dup.  This avoids failure with EMFILE if FD is 1
94026         less than the maximum number of open file descriptors, because
94027         save_cwd fails with errno == EMFILE.  Problem reported by tsteven4
94028         on Mac OS X 10.6.4 for tar 1.24
94029         <http://lists.gnu.org/r/bug-tar/2010-10/msg00084.html>
94030         <http://lists.gnu.org/r/bug-tar/2010-11/msg00000.html>
94031         and for tar 1.25
94032         <http://lists.gnu.org/r/bug-tar/2010-11/msg00038.html>.
94034 2010-11-07  Bruno Haible  <bruno@clisp.org>
94036         vasnprintf: Support I flag on glibc systems.
94037         * lib/printf-parse.h (FLAG_LOCALIZED): New macro.
94038         * lib/printf-parse.c (PRINTF_PARSE): Handle the 'I' flag.
94039         * lib/vasnprintf.c (VASNPRINTF): Pass the 'I' flag on to the system's
94040         snprintf function.
94041         * tests/test-vasnprintf-posix.c (test_function): Test the 'I' flag on
94042         glibc systems.
94043         * tests/test-vasnprintf-posix3.c: New file.
94044         * modules/vasnprintf-posix-tests (Files): Add it.
94045         (TESTS, check_PROGRAMS): Add test-vasnprintf-posix3.
94047 2010-11-05  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
94049         [html] Fix copy/paste bug: Use unique name for compiler warnings.
94050         * MODULES.html.sh: For compiler warnings, use name
94051         `ansic_ext_compwarn' since `ansic_ext_misc' is already taken.
94053 2010-11-05  Eric Blake  <eblake@redhat.com>
94055         ceil, floor: avoid spurious failure with icc
94056         * tests/test-ceilf2.c (ceilf_reference): Avoid icc's use of DAZ
94057         [denormals-as-zero] when optimizing without -mieee-fp option.
94058         * tests/test-floorf2.c (floorf_reference): Likewise.
94059         * tests/test-ceilf1.c (dummy): New function.
94060         (main): Use it to outsmart icc's optimization.
94061         * tests/test-floorf1.c (dummy, main): Likewise.
94063         tests: require working signbit
94064         * modules/ceilf-tests (Depends-on): Add signbit.
94065         * modules/ceill-tests (Depends-on): Likewise.
94066         * modules/floorf-tests (Depends-on): Likewise.
94067         * modules/floorl-tests (Depends-on): Likewise.
94068         * modules/round-tests (Depends-on): Likewise.
94069         * modules/roundf-tests (Depends-on): Likewise.
94070         * modules/roundl-tests (Depends-on): Likewise.
94071         * modules/trunc-tests (Depends-on): Likewise.
94072         * modules/truncf-tests (Depends-on): Likewise.
94073         * modules/truncl-tests (Depends-on): Likewise.
94075         strtod: work around icc bug
94076         * lib/strtod.c (minus_zero): Define to working value.
94077         (strtod): Use it to avoid icc bug.
94079         copysign: enhance tests
94080         * modules/copysign-tests (Files): Add minus-zero.h.
94081         * tests/test-copysign.c (main): Also test zeros.
94083 2010-11-04  Eric Blake  <eblake@redhat.com>
94085         ceil, floor, round, trunc: enhance tests of -0
94086         * tests/test-ceilf1.c (main): Ensure correct sign of result.
94087         * tests/test-ceill.c (main): Likewise.
94088         * tests/test-floorf1.c (main): Likewise.
94089         * tests/test-floorl.c (main): Likewise.
94090         * tests/test-round1.c (main): Likewise.
94091         * tests/test-roundf1.c (main): Likewise.
94092         * tests/test-roundl.c (main): Likewise.
94093         * tests/test-trunc1.c (main): Likewise.
94094         * tests/test-truncf1.c (main): Likewise.
94095         * tests/test-truncl.c (main): Likewise.
94097 2010-11-04  Eric Blake  <eblake@redhat.com>
94099         frexp, tests: work around ICC bug with -zero
94100         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Compute -0.0 in a way that
94101         works with more compilers.
94102         * tests/minus-zero.h: New file.
94103         * modules/ceilf-tests (Files): Include it.
94104         * modules/ceill-tests (Files): Likewise.
94105         * modules/floorf-tests (Files): Likewise.
94106         * modules/floorl-tests (Files): Likewise.
94107         * modules/frexp-nolibm-tests (Files): Likewise.
94108         * modules/frexp-tests (Files): Likewise.
94109         * modules/frexpl-nolibm-tests (Files): Likewise.
94110         * modules/frexpl-tests (Files): Likewise.
94111         * modules/isnan-tests (Files): Likewise.
94112         * modules/isnand-nolibm-tests (Files): Likewise.
94113         * modules/isnand-tests (Files): Likewise.
94114         * modules/isnanf-nolibm-tests (Files): Likewise.
94115         * modules/isnanf-tests (Files): Likewise.
94116         * modules/isnanl-nolibm-tests (Files): Likewise.
94117         * modules/isnanl-tests (Files): Likewise.
94118         * modules/round-tests (Files): Likewise.
94119         * modules/roundf-tests (Files): Likewise.
94120         * modules/roundl-tests (Files): Likewise.
94121         * modules/ldexpl-tests (Files): Likewise.
94122         * modules/signbit-tests (Files): Likewise.
94123         * modules/snprintf-posix-tests (Files): Likewise.
94124         * modules/sprintf-posix-tests (Files): Likewise.
94125         * modules/strtod-tests (Files): Likewise.
94126         * modules/trunc-tests (Files): Likewise.
94127         * modules/truncf-tests (Files): Likewise.
94128         * modules/truncl-tests (Files): Likewise.
94129         * modules/vsnprintf-posix-tests (Files): Likewise.
94130         * modules/vsprintf-posix-tests (Files): Likewise.
94131         * modules/vasnprintf-posix-tests (Files): Likewise.
94132         * modules/vasprintf-posix-tests (Files): Likewise.
94133         * tests/test-ceilf1.c (main): Use it.
94134         * tests/test-ceill.c (main): Likewise.
94135         * tests/test-floorf1.c (main): Likewise.
94136         * tests/test-floorl.c (main): Likewise.
94137         * tests/test-frexp.c (main): Likewise.
94138         * tests/test-frexpl.c (main): Likewise.
94139         * tests/test-isnan.c (main): Likewise.
94140         * tests/test-isnand.h (main): Likewise.
94141         * tests/test-isnanf.h (main): Likewise.
94142         * tests/test-isnanl.h (main): Likewise.
94143         * tests/test-ldexpl.c (main): Likewise.
94144         * tests/test-round.c (main): Likewise.
94145         * tests/test-roundf.c (main): Likewise.
94146         * tests/test-roundl.c (main): Likewise.
94147         * tests/test-signbit.c (test_signbitf, test_signbitd)
94148         (test_signbitl): Likewise.
94149         * tests/test-snprintf-posix.h (test_function): Likewise.
94150         * tests/test-sprintf-posix.h (test_function): Likewise.
94151         * tests/test-strtod.c (main): Likewise.
94152         * tests/test-trunc1.c (main): Likewise.
94153         * tests/test-truncf1.c (main): Likewise.
94154         * tests/test-truncl.c (main): Likewise.
94156         isnanl: work around icc bug
94157         * lib/isnan.c (FUNC): Compute run-time NaN under ICC as well.
94159 2010-11-03  Eric Blake  <eblake@redhat.com>
94161         tests: fix compiler warnings
94162         * tests/test-getopt.h (test_getopt): Fix condition.
94163         * tests/test-getopt_long.h (test_getopt_long): Likewise.
94164         * tests/test-pipe2.c (main): Likewise.
94165         * tests/test-quotearg-simple.c (main): Avoid icc warning.
94167         utimens: fix broken m4 test
94168         * m4/utimens.m4 (gl_UTIMENS): Include correct headers.
94170 2010-10-28  Bruno Haible  <bruno@clisp.org>
94172         posix_spawn*, getdtablesize: Relax license.
94173         * modules/posix_spawn (License): Change to LGPLv2+.
94174         * modules/posix_spawnp (License): Likewise.
94175         * modules/posix_spawn-internal (License): Likewise.
94176         * modules/posix_spawnattr_init (License): Likewise.
94177         * modules/posix_spawnattr_getflags (License): Likewise.
94178         * modules/posix_spawnattr_setflags (License): Likewise.
94179         * modules/posix_spawnattr_getpgroup (License): Likewise.
94180         * modules/posix_spawnattr_setpgroup (License): Likewise.
94181         * modules/posix_spawnattr_getschedparam (License): Likewise.
94182         * modules/posix_spawnattr_setschedparam (License): Likewise.
94183         * modules/posix_spawnattr_getschedpolicy (License): Likewise.
94184         * modules/posix_spawnattr_setschedpolicy (License): Likewise.
94185         * modules/posix_spawnattr_getsigdefault (License): Likewise.
94186         * modules/posix_spawnattr_setsigdefault (License): Likewise.
94187         * modules/posix_spawnattr_getsigmask (License): Likewise.
94188         * modules/posix_spawnattr_setsigmask (License): Likewise.
94189         * modules/posix_spawnattr_destroy (License): Likewise.
94190         * modules/posix_spawn_file_actions_init (License): Likewise.
94191         * modules/posix_spawn_file_actions_addclose (License): Likewise.
94192         * modules/posix_spawn_file_actions_adddup2 (License): Likewise.
94193         * modules/posix_spawn_file_actions_addopen (License): Likewise.
94194         * modules/posix_spawn_file_actions_destroy (License): Likewise.
94195         * modules/getdtablesize (License): Likewise.
94196         Requested by Adam Stokes <ajs@redhat.com> for use in netcf.
94198 2010-10-26  Bruno Haible  <bruno@clisp.org>
94200         unistd: Refine workaround from 2009-12-23 against Cygwin bug.
94201         * lib/unistd.in.h: Don't include <stdio.h> and <fcntl.h>, except on
94202         Cygwin and mingw.
94203         Suggested by Eric Blake.
94205 2010-10-26  Bruno Haible  <bruno@clisp.org>
94207         stdio: Work around compilation error due to renameat() on Solaris 10.
94208         * lib/stdio.in.h: Include <unistd.h> on Solaris.
94209         * lib/renameat.c: Don't include <unistd.h> here.
94210         * doc/posix-functions/renameat.texi: Mention the Solaris problem.
94211         Reported by Paul Eggert and Eric Blake.
94213 2010-10-26  Paul Eggert  <eggert@cs.ucla.edu>
94215         renameat: port to Solaris 10, which declares renameat in unistd.h
94217         * lib/renameat.c: Include unistd.h before stdio.h, because
94218         Solaris 10 declares renameat in unistd.h.  Problem encountered
94219         when building GNU tar 1.24 on Solaris 10.
94221 2010-10-26  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
94223         fdopendir: fix C89 compilation
94224         * lib/fdopendir.c (fd_clone_opendir): Move declaration for older
94225         compilers.
94227 2010-10-23  Paul Eggert  <eggert@cs.ucla.edu>
94229         inttostr: simplify by removing unnecessary redundancy
94230         * lib/anytostr.c: Don't include verify.h.
94231         (anytostr): Don't verify that TYPE_SIGNED (inttype) equals
94232         inttype_is_signed.  Instead, disable the bogus GCC warnings, so that
94233         there's no need for inttype_is_signed and for calling TYPE_SIGNED.
94234         * lib/imaxtostr.c (inttype_is_signed): Remove; no longer needed.
94235         * lib/inttostr.c, lib/offtostr.c, lib/uinttostr.c, lib/umaxtostr.c:
94236         Likewise.
94237         * modules/inttostr (Depends-on): Remove 'verify'.
94239 2010-10-23  Bruno Haible  <bruno@clisp.org>
94241         nl_langinfo: Mention problem with CRNCYSTR on NetBSD 5.0.
94242         * doc/posix-functions/nl_langinfo.texi: Mention problem with CRNCYSTR.
94243         Reported by Eric Blake.
94245 2010-10-23  Bruno Haible  <bruno@clisp.org>
94247         Tests: Fix LOCALE_JA on MirBSD 10.
94248         * m4/locale-ja.m4 (gt_LOCALE_JA): Reject a locale identifier that leads
94249         to an UTF-8 locale.
94250         * m4/locale-fr.m4 (gt_LOCALE_FR): Likewise.
94251         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
94252         Reported by Eric Blake.
94254 2010-10-21  Bruno Haible  <bruno@clisp.org>
94256         nl_langinfo test: Avoid test failure on NetBSD 5.
94257         * tests/test-nl_langinfo.c (main): Relax test of nl_langinfo(CRNCYSTR).
94258         Reported by Eric Blake.
94260 2010-10-21  Eric Blake  <eblake@redhat.com>
94262         c-stack: work around libsigsegv 2.8 bug
94263         * lib/c-stack.c (SIGSTKSZ): Increase size to avoid alternate stack
94264         overflow on at least PowerPC64.
94266 2010-10-17  Bruno Haible  <bruno@clisp.org>
94268         userspec: Drop redundant file.
94269         * modules/userspec (Files): Remove lib/inttostr.h.
94271 2010-10-17  Bruno Haible  <bruno@clisp.org>
94273         nl_langinfo tests: Silence some warnings.
94274         * tests/test-nl_langinfo.c: Silence -Wtype-limits warnings.
94275         Reported by Jim Meyering.
94277 2010-10-17  Bruno Haible  <bruno@clisp.org>
94279         Make use of GCC's attribute __alloc_size__.
94280         * lib/xalloc.h (ATTRIBUTE_ALLOC_SIZE): New macro.
94281         (xmalloc, xzalloc, xcalloc, xrealloc, xmemdup, xnmalloc, xnrealloc,
94282         xcharalloc): Declare with ATTRIBUTE_ALLOC_SIZE.
94283         * lib/eealloc.h (eemalloc, eerealloc): Declare with attribute
94284         __alloc_size__.
94285         * lib/pagealign_alloc.h (pagealign_alloc, pagealign_xalloc): Likewise.
94286         Suggested by Jim Meyering.
94288 2010-10-16  Joel E. Denny  <joeldenny@joeldenny.org>
94290         bootstrap: anchor .gitignore entries.
94291         * build-aux/bootstrap (insert_sorted_if_absent): Replace all uses
94292         with...
94293         (insert_vc_ignore): ... this new function, which prepends `/' to
94294         all .gitignore entries before passing them to
94295         insert_sorted_if_absent.
94297 2010-10-16  Bruno Haible  <bruno@clisp.org>
94299         nextafter: Fix configure check.
94300         * modules/nextafter (configure.ac): Correct expected prototype.
94302 2010-10-16  Bruno Haible  <bruno@clisp.org>
94304         termios: Update documentation.
94305         * doc/posix-headers/termios.texi: Mention remaining mingw problems.
94307 2010-10-16  Bruno Haible  <bruno@clisp.org>
94309         tests: Make them compile with TinyCC.
94310         * tests/test-strstr.c (main): Remove parentheses around array
94311         initializer.
94313 2010-10-15  Eric Blake  <eblake@redhat.com>
94315         ignore-value: make header idempotent
94316         * lib/ignore-value.h: Add double-inclusion guards.
94317         Reported by Stefan Berger.
94319 2010-10-15  Jim Meyering  <meyering@redhat.com>
94321         GNUmakefile: handle "stable" target, not "major"
94322         * top/GNUmakefile (_is-dist-target): s/major/stable/ to match the
94323         lists in maint.mk and announce-gen.  Without this, "make stable"
94324         would fail to ensure that $(VERSION) is up to date.
94326 2010-10-15  Ludovic Courtès  <ludo@gnu.org>
94328         * lib/isnan.c (FUNC): Treat TinyCC (`__TINYC__') like `__SUNPRO_C'
94329         & co.
94331 2010-10-14  Bruno Haible  <bruno@clisp.org>
94333         vasnprintf: Don't set errno to 0.
94334         * lib/vasnprintf.c (VASNPRINTF): Save and restore errno around the
94335         block that sets it to 0.
94336         Reported by Gianluigi Tiesi <sherpya@netfarm.it>.
94338 2010-10-14  Bruno Haible  <bruno@clisp.org>
94340         socketlib: Fix.
94341         * modules/socketlib (Files): Add m4/sys_socket_h.m4. Needed for
94342         gl_PREREQ_SYS_H_WINSOCK2.
94343         Reported by Ian Beckwith <ianb@erislabs.net>.
94345 2010-10-13  Jim Meyering  <meyering@redhat.com>
94347         test-select-stdin.c: avoid warn_unused_result warnings
94348         * tests/test-select-stdin.c: Include "macros.h".
94349         ASSERT that read and fflush succeed.
94351 2010-10-13  Jim Meyering  <meyering@redhat.com>
94353         git-version-gen: do require git-VC'd files in cwd
94354         * build-aux/git-version-gen: Reject a git version string
94355         if there are no commits associated with the current directory.
94356         This avoids an unlikely false-positive (unrelated dir whose parent
94357         repository also contains a tag matching v*), as pointed out
94358         by Giuseppe Scrivano in
94359         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/21843/focus=23664
94361 2010-10-13  Paul Eggert  <eggert@cs.ucla.edu>
94363         argv-iter: omit nonconforming declaration
94364         * lib/argv-iter.h (enum argv_iter_err): Omit the useless
94365         enum arg_iter_err declaration, which doesn't conform to C99.
94366         Solaris 10 cc warns about this.
94368 2010-10-13  Eric Blake  <eblake@redhat.com>
94370         termios: fix compilation on mingw
94371         * m4/termios_h.m4 (gl_TERMIOS_H_DEFAULTS): Set default.
94372         (gl_TERMIOS_H): Adjust it on mingw.
94373         * modules/termios (Makefile.am): Substitute new key.
94374         * lib/termios.in.h (includes): Make include_next conditional.
94375         * doc/posix-headers/termios.texi (termios.h): Update
94376         documentation.
94377         Reported by Daniel P. Berrange.
94379 2010-10-13  Jim Meyering  <meyering@redhat.com>
94381         git-version-gen: don't require that .git/ be in the current dir
94382         * build-aux/git-version-gen: Adjust this script so that it works
94383         when run from any working directory beneath the top-level .git/-
94384         containing directory.  Inspired by a patch from Giuseppe Scrivano,
94385         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/21843/focus=21847
94387         test-select: avoid warn_unused_result warnings
94388         * tests/test-select.c: Include "macros.h".
94389         ASSERT that each call to read, write, and pipe succeeds.
94390         While not technically required, also check each "close".
94391         * modules/select-tests (Files): Add tests/macros.h.
94393         test-symlinkat: remove declaration of unused local
94394         * tests/test-symlinkat.c (main): Remove unused local, "buf".
94396         test-inttostr: avoid shadowing warnings
94397         * tests/test-inttostr.c (main): Rename local, "buf" to "b",
94398         and use malloc rather than the stack for the same reason as
94399         mentioned in the comment justifying the other allocation.
94401 2010-10-11  Bruno Haible  <bruno@clisp.org>
94403         stdlib: Allow multiple gnulib generated replacements to coexist.
94404         * lib/stdlib.in.h (struct random_data): Avoid identical redefinition.
94405         Reported by Sam Steingold <sds@gnu.org>.
94407 2010-10-11  Jim Meyering  <meyering@redhat.com>
94409         fix a documentation typo
94410         * doc/posix-functions/futimens.texi (futimens): Fix typo: s/itme/item/
94412 2010-10-11  Eric Blake  <eblake@redhat.com>
94414         futimens: work around Solaris 11 bug
94415         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Detect the bug.
94416         * tests/test-futimens.h (test_futimens): Enhance, rather than
94417         weaken test.
94418         * doc/posix-functions/futimens.texi (futimens): Document the bug.
94420 2010-10-11  Paul Eggert  <eggert@cs.ucla.edu>
94422         Indentation.
94423         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Indent
94424         higher-level operators more to the left.
94426 2010-10-11  Jim Meyering  <meyering@redhat.com>
94428         test-futimens: avoid unwarranted test failure on Solaris 5.11
94429         * tests/test-futimens.h (test_futimens): When provoking EBADF, use an
94430         invalid file descriptor, so we don't provoke EFAULT from Solaris 5.11,
94431         because it tries to dereference the NULL name argument.
94433 2010-10-11  Bruno Haible  <bruno@clisp.org>
94435         Indentation.
94436         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Improve
94437         indentation.
94439 2010-10-11  Jim Meyering  <meyering@redhat.com>
94441         spawn.in.h: make indentation consistent with parentheses
94442         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap):
94443         Make indentation consistent with parentheses.
94445 2010-10-11  Gary V. Vaughan  <gary@gnu.org>
94447         Fix mismatched parens in previous commit
94448         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Fix mismatched
94449         parens.
94451 2010-10-10  Paul Eggert  <eggert@cs.ucla.edu>
94453         rewrite int foo[2*X-1] to verify(X) or to int foo[X?1:-1]
94455         * lib/float+.h (verify_sizeof_flt, verify_sizeof_dbl):
94456         (verify_sizeof_ldbl): Rewrite 2*X-1 to X?1:-1.
94457         * lib/malloca.c: Include "verify.h".
94458         (verify1): Remove, replacing with a verify call.
94459         * lib/relocwrapper.c (verify1): Likewise.
94460         * lib/vasnprintf.c (mp_limb_verify, mp_twolimb_verify, TCHAR_T_verify):
94461         Likewise.
94462         * modules/malloca (Depends-on): Add 'verify'.
94463         * modules/relocatable-prog-wrapper (Depends-on): Add 'verify'.
94464         * modules/vasnprintf (Depends-on): Add 'verify'.
94465         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
94466         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
94467         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
94468         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
94469         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
94470         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
94471         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
94473         prefer (X ? 1 : -1) when converting from boolean (1,0) to int (1,-1)
94475         Formerly the style was sometimes 2*X - 1, because the C standard
94476         was wrongly thought to disallow ?: in integral constant expressions.
94477         * lib/inet_ntop.c (verify_int_size): Rewrite 2*X-7 (!) to 4<=X?1:-1.
94478         * lib/signal.in.h (verify_NSIG_constraint): Rewrite 2*X-1 to X?1:-1.
94479         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Likewise.
94480         * lib/stdint.in.h (_verify_intmax_size): Likewise.
94481         * lib/time.in.h (struct __time_t_must_be_integral): Rewrite
94482         2 * ((time_t) 1 / 2 == 0) - 1 to (time_t) 1; this suffices to
94483         verify that time_t cannot be floating.
94485 2010-10-08  Eric Blake  <eblake@redhat.com>
94487         time: enforce recent POSIX ruling that time_t is integral
94488         * lib/time.in.h (__time_t_must_be_integral): Detect any
94489         problematic systems, allowing the rest of gnulib to assume POSIX.
94491 2010-10-08  Jim Meyering  <meyering@redhat.com>
94493         fdopendir: fix a bug on systems lacking openat and /proc support
94494         OpenBSD 4.7 is one such system.  The most noticeable effect was
94495         failure of any application making nontrivial use of fts: rm, du,
94496         chown, chmod etc.  E.g., "mkdir -p a/b; ./rm -rf a" would fail with
94497           ./rm: traversal failed: `a': Bad file descriptor
94498         Debugging that, you see that even though FD 6 was closed just
94499         prior to the opendir call in fd_clone_opendir, its resulting
94500         dir->dd_fd was 8, rather than the expected value of 6:
94502         Breakpoint 3, fdopendir_with_dup (fd=6, older_dupfd=-1) at fdopendir.c:93
94503         93                close (fd);
94504         (gdb) n
94505         94                dir = fd_clone_opendir (dupfd);
94506         (gdb) n
94507         95                saved_errno = errno;
94508         (gdb) p dir->dd_fd
94509         $11 = 8
94511         Notice how it closes FD 6, then gets a DIR* pointer using FD 8.
94512         The problem is that on OpenBSD, fd_clone_opendir has to resort
94513         to using the old-style save/restore CWD mechanism, due to its
94514         lack of openat/proc support, and *that* would steal the FD (6)
94515         that opendir was supposed to use.
94517         The fix is to squirrel away the desired FD so that save_cwd uses a
94518         different one, and then free the dest FD right before calling opendir.
94519         That guarantees opendir will use the required file descriptor.
94521         * lib/fdopendir.c (fd_clone_opendir): Handle the above.
94523 2010-10-08  Bruno Haible  <bruno@clisp.org>
94525         sys_select: Avoid warning due to undeclared memset() on OpenBSD 4.5.
94526         * lib/sys_select.in.h: Include <string.h> also on OpenBSD.
94528 2010-10-08  Bruno Haible  <bruno@clisp.org>
94530         nanosleep: Make replacement POSIX compliant.
94531         * lib/nanosleep.c (nanosleep): Return -1/EINVAL if the delay's tv_nsec
94532         is out of range.
94533         Reported by Jim Meyering.
94535 2010-10-08  Paul Eggert  <eggert@cs.ucla.edu>
94537         bootstrap: add hook for altering gnulib.mk, for Bison
94538         * build-aux/bootstrap (gnulib_mk_hook): New function, so that
94539         the Bison bootstrapping process can rewrite file names and variables
94540         in this file before later parts of 'bootstrap' use the file.
94541         Bison wants to include lib/gnulib.mk from the top-level makefile,
94542         so it needs the file names in this file to be relative to the top
94543         level, not relative to lib; plus it needs variable names to be
94544         rewritten.
94545         (slurp): Use the new function.
94547         bootstrap: reformat for readability
94548         * build-aux/bootstrap: Rewrite to avoid lines longer than 80 columns.
94550 2010-10-08  Eric Blake  <eblake@redhat.com>
94552         docs: update cygwin progress
94553         * doc/posix-functions/cacos.texi (cacos): Added after cygwin
94554         1.7.7.
94555         * doc/posix-functions/cacosf.texi (cacosf): Likewise.
94556         * doc/posix-functions/cacosh.texi (cacosh): Likewise.
94557         * doc/posix-functions/cacoshf.texi (cacoshf): Likewise.
94558         * doc/posix-functions/carg.texi (carg): Likewise.
94559         * doc/posix-functions/cargf.texi (cargf): Likewise.
94560         * doc/posix-functions/casin.texi (casin): Likewise.
94561         * doc/posix-functions/casinf.texi (casinf): Likewise.
94562         * doc/posix-functions/casinh.texi (casinh): Likewise.
94563         * doc/posix-functions/casinhf.texi (casinhf): Likewise.
94564         * doc/posix-functions/catan.texi (catan): Likewise.
94565         * doc/posix-functions/catanf.texi (catanf): Likewise.
94566         * doc/posix-functions/catanh.texi (catanh): Likewise.
94567         * doc/posix-functions/catanhf.texi (catanhf): Likewise.
94568         * doc/posix-functions/ccos.texi (ccos): Likewise.
94569         * doc/posix-functions/ccosf.texi (ccosf): Likewise.
94570         * doc/posix-functions/ccosh.texi (ccosh): Likewise.
94571         * doc/posix-functions/ccoshf.texi (ccoshf): Likewise.
94572         * doc/posix-functions/cexp.texi (cexp): Likewise.
94573         * doc/posix-functions/cexpf.texi (cexpf): Likewise.
94574         * doc/posix-functions/cimag.texi (cimag): Likewise.
94575         * doc/posix-functions/cimagf.texi (cimagf): Likewise.
94576         * doc/posix-functions/clog.texi (clog): Likewise.
94577         * doc/posix-functions/clogf.texi (clogf): Likewise.
94578         * doc/posix-functions/conj.texi (conj): Likewise.
94579         * doc/posix-functions/conjf.texi (conjf): Likewise.
94580         * doc/posix-functions/cpow.texi (cpow): Likewise.
94581         * doc/posix-functions/cpowf.texi (cpowf): Likewise.
94582         * doc/posix-functions/cproj.texi (cproj): Likewise.
94583         * doc/posix-functions/cprojf.texi (cprojf): Likewise.
94584         * doc/posix-functions/creal.texi (creal): Likewise.
94585         * doc/posix-functions/crealf.texi (crealf): Likewise.
94586         * doc/posix-functions/csin.texi (csin): Likewise.
94587         * doc/posix-functions/csinf.texi (csinf): Likewise.
94588         * doc/posix-functions/csinh.texi (csinh): Likewise.
94589         * doc/posix-functions/csinhf.texi (csinhf): Likewise.
94590         * doc/posix-functions/csqrt.texi (csqrt): Likewise.
94591         * doc/posix-functions/csqrtf.texi (csqrtf): Likewise.
94592         * doc/posix-functions/ctan.texi (ctan): Likewise.
94593         * doc/posix-functions/ctanf.texi (ctanf): Likewise.
94594         * doc/posix-functions/ctanh.texi (ctanh): Likewise.
94595         * doc/posix-functions/ctanhf.texi (ctanhf): Likewise.
94596         * doc/posix-headers/complex.texi (complex.h): Likewise.
94598 2010-10-07  Jim Meyering  <meyering@redhat.com>
94600         parse-datetime: avoid compilation failure on OpenBSD 4.7
94601         * lib/parse-datetime.y (_STDLIB_H) [_STDLIB_H_]: Define.
94602         This works around a compilation failure on OpenBSD 4.7:
94603         http://thread.gmane.org/gmane.comp.parsers.bison.bugs/3418
94605 2010-10-07  Eric Blake  <eblake@redhat.com>
94607         docs: update cygwin progress
94608         * doc/glibc-functions/mkostemp.texi (mkostemp): Added in cygwin
94609         1.7.6.
94610         * doc/glibc-functions/mkostemps.texi (mkostemps): Likewise.
94611         * doc/posix-headers/fenv.texi (fenv.h): Added after cygwin 1.7.7.
94612         * doc/posix-functions/feclearexcept.texi (feclearexcept): Likewise.
94613         * doc/posix-functions/fegetenv.texi (fegetenv): Likewise.
94614         * doc/posix-functions/fegetexceptflag.texi (fegetexceptflag):
94615         Likewise.
94616         * doc/posix-functions/fegetround.texi (fegetround): Likewise.
94617         * doc/posix-functions/feholdexcept.texi (feholdexcept): Likewise.
94618         * doc/posix-functions/feraiseexcept.texi (feraiseexcept):
94619         Likewise.
94620         * doc/posix-functions/fesetenv.texi (fesetenv): Likewise.
94621         * doc/posix-functions/fesetexceptflag.texi (fesetexceptflag):
94622         Likewise.
94623         * doc/posix-functions/fesetround.texi (fesetround): Likewise.
94624         * doc/posix-functions/fetestexcept.texi (fetestexcept): Likewise.
94625         * doc/posix-functions/feupdateenv.texi (feupdateenv): Likewise.
94626         * doc/glibc-functions/feenableexcept.texi (feenableexcept):
94627         Likewise.
94628         * doc/glibc-functions/fedisableexcept.texi (fedisableexcept):
94629         Likewise.
94630         * doc/glibc-functions/fegetexcept.texi (fegetexcept): Likewise.
94632         docs: update parse-datetime history
94633         * doc/parse-datetime.texi (Authors of parse_datetime): Better
94634         documentation of this function's history and alternatives.
94636         cygwin: use more robust version check
94637         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE, gl_FUNC_MEMMEM): Don't
94638         exclude an eventual cygwin 1.9.1.
94639         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Likewise.
94640         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE)
94641         (gl_FUNC_STRCASESTR): Likewise.
94642         Reported by Bruno Haible.
94644 2010-10-06  Bruno Haible  <bruno@clisp.org>
94646         string, sys_select: Avoid #including large headers unless necessary.
94647         * lib/string.in.h: Don't include <unistd.h> except on NetBSD.
94648         * lib/sys_select.in.h: Don't include <string.h> except on Solaris,
94649         OSF/1, BeOS, Haiku.
94650         Reported by Jim Meyering.
94652 2010-10-05  Eric Blake  <eblake@redhat.com>
94654         memmem, strstr, strcasestr: fix bug with long periodic needle
94655         * lib/str-two-way.h (two_way_long_needle): Avoid bug with long
94656         periodic needle having false positive.
94657         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Detect bug in glibc 2.12
94658         and cygwin 1.7.7.
94659         (gl_FUNC_MEMMEM): Be more pessimistic when cross-compiling.
94660         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE)
94661         (gl_FUNC_STRCASESTR): Likewise.
94662         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Likewise.
94663         * tests/test-memmem.c (main): Expose the bug.
94664         * tests/test-strcasestr.c (main): Likewise.
94665         * tests/test-strstr.c (main): Likewise.
94666         * tests/test-c-strcasestr.c (main): Likewise.
94667         * doc/glibc-functions/memmem.texi (memmem): Document the bug.
94668         * doc/posix-functions/strstr.texi (strstr): Likewise.
94669         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
94670         Reported via http://sourceware.org/bugzilla/show_bug.cgi?id=12092
94672 2010-10-05  Paul Eggert  <eggert@cs.ucla.edu>
94674         parse-datetime: do some more renaming
94675         * doc/parse-datetime.texi (Authors of parse_datetime): Call it
94676         parse_datetime, not get_date.  Mention the renaming.
94677         * lib/parse-datetime.y:  Call it parse_datetime, not getdate,
94678         in comments.
94679         * m4/bison.m4: Likewise.
94681 2010-10-05  Eric Blake  <eblake@redhat.com>
94683         parse-datetime: better name than get_date
94684         * NEWS: Reword the deprecation notice.
94685         * modules/get_date: Rename to modules/parse-datetime.
94686         * modules/get_date-tests: Rename to modules/parse-datetime-tests.
94687         * m4/get_date.m4: Rename to m4/parse-datetime.m4.
94688         * lib/get_date.y: Rename to lib/parse-datetime.y.
94689         * tests/test-get_date.c: Rename to tests/test-parse-datetime.c.
94690         * doc/get_date.texi: Rename to doc/parse-datetime.texi.
94691         * doc/getdate.texi: Provide fallback wrapper.
94692         * lib/getdate.h: Move guts, and wrap...
94693         * lib/parse-datetime.h: ...new file.
94694         * lib/parse-datetime.y (get_date): Rename...
94695         (parse_datetime): ...to this.
94696         * m4/parse-datetime.m4 (gl_GET_DATE): Rename...
94697         (gl_PARSE_DATETIME): ...to this.
94698         * doc/posix-functions/getdate.texi (get_date): Provide fallback
94699         documentation.
94700         * modules/getdate (Files): Provide fallback docs and header.
94701         (Notice, Depends-on): Update references.
94702         * tests/test-parse-datetime.c: Likewise.
94703         * DEPENDENCIES: Likewise.
94704         * MODULES.html.sh (Date and time <time.h>): Likewise.
94705         * doc/parse-datetime.texi (Date input formats)
94706         (Authors of parse_datetime): Likewise.
94707         * modules/parse-datetime (Files, configure.ac, Makefile.am)
94708         (Include): Likewise.
94709         * modules/parse-datetime-tests (Files, Makefile.am): Likewise.
94710         * gnulib-tool: Likewise.
94711         * m4/bison.m4 (gl_BISON): Likewise.
94712         Suggested by Bruno Haible.
94714 2010-10-05  Paul Eggert  <eggert@cs.ucla.edu>
94716         more ports to Solaris tr, which needs [] around ranges
94717         * gnulib-tool: Solaris tr needs [] around ranges.
94718         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
94719         * tests/test-pipe-filter-gi1.c (main): Likewise.
94720         * tests/test-pipe-filter-ii1.c (main): Likewise.
94722 2010-10-05  Eric Blake  <eblake@redhat.com>
94724         bootstrap: fix Solaris regression
94725         * build-aux/bootstrap (check_versions): Solaris tr still needs []
94726         around ranges.
94727         Reported by Pádraig Brady.
94729         bootstrap: work with pkg-config
94730         * build-aux/bootstrap (check_versions): Also transliterate - in
94731         prerequisite name.
94732         (print_versions): Be robust to any \ in $buildreq.  Avoid listing
94733         prerequisites that were already found, to avoid confusion.
94734         Reported by Justin Clift.
94736         faccessat: remove unused wrappers
94737         * lib/openat.h (accessat, euidaccesat): Delete, since the mere
94738         presence of these wrappers dragged in -lgen on Solaris.
94739         Reported by Clemens Brogi; fix suggested by Paul Eggert.
94741 2010-10-05  Jim Meyering  <meyering@redhat.com>
94743         tests: require @PRAGMA_COLUMNS@ with each @PRAGMA_SYSTEM_HEADER@
94744         * Makefile (sc_pragma_columns): New syntax-check rule.
94746 2010-10-04  Bruno Haible  <bruno@clisp.org>
94748         gnulib-tool: Synthesize appropriate _LDFLAGS for a libtool library.
94749         * gnulib-tool (func_emit_lib_Makefile_am): When preparing for a libtool
94750         library, put '-no-undefined' and the link dependencies into _LDFLAGS.
94751         Reported by Bruce Korb and Eric Blake.
94753 2010-10-04  Bruno Haible  <bruno@clisp.org>
94755         threadlib: Make option --with-libpth-prefix work.
94756         * m4/threadlib.m4 (gl_THREADLIB_BODY): When testing whether pth works,
94757         use $LIBPTH, not just -lpth.
94759 2010-10-04  Bruno Haible  <bruno@clisp.org>
94761         Avoid line length limitation from HP NonStop system header files.
94762         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define also PRAGMA_COLUMNS.
94763         * lib/arpa_inet.in.h: Use PRAGMA_COLUMNS.
94764         * lib/ctype.in.h: Likewise.
94765         * lib/dirent.in.h: Likewise.
94766         * lib/errno.in.h: Likewise.
94767         * lib/fcntl.in.h: Likewise.
94768         * lib/float.in.h: Likewise.
94769         * lib/getopt.in.h: Likewise.
94770         * lib/iconv.in.h: Likewise.
94771         * lib/inttypes.in.h: Likewise.
94772         * lib/langinfo.in.h: Likewise.
94773         * lib/locale.in.h: Likewise.
94774         * lib/math.in.h: Likewise.
94775         * lib/netdb.in.h: Likewise.
94776         * lib/netinet_in.in.h: Likewise.
94777         * lib/poll.in.h: Likewise.
94778         * lib/pthread.in.h: Likewise.
94779         * lib/pty.in.h: Likewise.
94780         * lib/sched.in.h: Likewise.
94781         * lib/se-selinux.in.h: Likewise.
94782         * lib/search.in.h: Likewise.
94783         * lib/signal.in.h: Likewise.
94784         * lib/spawn.in.h: Likewise.
94785         * lib/stdarg.in.h: Likewise.
94786         * lib/stddef.in.h: Likewise.
94787         * lib/stdint.in.h: Likewise.
94788         * lib/stdio.in.h: Likewise.
94789         * lib/stdlib.in.h: Likewise.
94790         * lib/string.in.h: Likewise.
94791         * lib/strings.in.h: Likewise.
94792         * lib/sys_file.in.h: Likewise.
94793         * lib/sys_ioctl.in.h: Likewise.
94794         * lib/sys_select.in.h: Likewise.
94795         * lib/sys_socket.in.h: Likewise.
94796         * lib/sys_stat.in.h: Likewise.
94797         * lib/sys_time.in.h: Likewise.
94798         * lib/sys_times.in.h: Likewise.
94799         * lib/sys_utsname.in.h: Likewise.
94800         * lib/sys_wait.in.h: Likewise.
94801         * lib/sysexits.in.h: Likewise.
94802         * lib/termios.in.h: Likewise.
94803         * lib/time.in.h: Likewise.
94804         * lib/unistd.in.h: Likewise.
94805         * lib/wchar.in.h: Likewise.
94806         * lib/wctype.in.h: Likewise.
94807         * modules/arpa_inet (Makefile.am): Substitute PRAGMA_COLUMNS.
94808         * modules/ctype (Makefile.am): Likewise.
94809         * modules/dirent (Makefile.am): Likewise.
94810         * modules/errno (Makefile.am): Likewise.
94811         * modules/fcntl-h (Makefile.am): Likewise.
94812         * modules/float (Makefile.am): Likewise.
94813         * modules/getopt-posix (Makefile.am): Likewise.
94814         * modules/iconv-h (Makefile.am): Likewise.
94815         * modules/inttypes (Makefile.am): Likewise.
94816         * modules/langinfo (Makefile.am): Likewise.
94817         * modules/locale (Makefile.am): Likewise.
94818         * modules/math (Makefile.am): Likewise.
94819         * modules/netdb (Makefile.am): Likewise.
94820         * modules/netinet_in (Makefile.am): Likewise.
94821         * modules/poll-h (Makefile.am): Likewise.
94822         * modules/pthread (Makefile.am): Likewise.
94823         * modules/pty (Makefile.am): Likewise.
94824         * modules/sched (Makefile.am): Likewise.
94825         * modules/search (Makefile.am): Likewise.
94826         * modules/selinux-h (Makefile.am): Likewise.
94827         * modules/signal (Makefile.am): Likewise.
94828         * modules/spawn (Makefile.am): Likewise.
94829         * modules/stdarg (Makefile.am): Likewise.
94830         * modules/stddef (Makefile.am): Likewise.
94831         * modules/stdint (Makefile.am): Likewise.
94832         * modules/stdio (Makefile.am): Likewise.
94833         * modules/stdlib (Makefile.am): Likewise.
94834         * modules/string (Makefile.am): Likewise.
94835         * modules/strings (Makefile.am): Likewise.
94836         * modules/sys_file (Makefile.am): Likewise.
94837         * modules/sys_ioctl (Makefile.am): Likewise.
94838         * modules/sys_select (Makefile.am): Likewise.
94839         * modules/sys_socket (Makefile.am): Likewise.
94840         * modules/sys_stat (Makefile.am): Likewise.
94841         * modules/sys_time (Makefile.am): Likewise.
94842         * modules/sys_times (Makefile.am): Likewise.
94843         * modules/sys_utsname (Makefile.am): Likewise.
94844         * modules/sys_wait (Makefile.am): Likewise.
94845         * modules/sysexits (Makefile.am): Likewise.
94846         * modules/termios (Makefile.am): Likewise.
94847         * modules/time (Makefile.am): Likewise.
94848         * modules/unistd (Makefile.am): Likewise.
94849         * modules/wchar (Makefile.am): Likewise.
94850         * modules/wctype (Makefile.am): Likewise.
94852 2010-10-04  Bruno Haible  <bruno@clisp.org>
94854         read-file tests: Avoid a test failure on NonStop Kernel.
94855         * tests/test-read-file.c (main): Don't assume that /etc/resolv.conf is
94856         a regular file.
94857         Reported by Joachim Schmitz <schmitz@hp.com>.
94859 2010-10-03  Bruno Haible  <bruno@clisp.org>
94861         gnulib-tool: Fixes for --create-testdir with --libtool.
94862         * gnulib-tool (func_get_automake_snippet): Don't augment
94863         EXTRA_lib_SOURCES for the pt_chown module, since pt_chown.o goes into
94864         an executable.
94865         (func_create_testdir): Handle module 'alloca' like func_import.
94866         Reported by Bruce Korb <bruce.korb@gmail.com>.
94868 2010-10-03  Paul Eggert  <eggert@cs.ucla.edu>
94870         Avoid some lines longer than 80 characters.
94871         * lib/stdint.in.h: Break long comment lines.
94872         * lib/math.in.h: Likewise.
94873         (_GL_NUM_UINT_WORDS): New macro, for readability.
94874         (gl_signbitf, gl_signbitd, gl_signbitl): Use it.
94875         * lib/stdio.in.h: Break lines in _GL_WARN_ON_USE calls.
94876         * lib/stdlib.in.h: Likewise.
94877         * lib/spawn.in.h: Likewise.
94878         * lib/sys_socket.in.h: Update an URL.
94879         * lib/sys_stat.in.h: Break long line.
94881 2010-10-03  Reuben Thomas  <rrt@sc3d.org>
94883         Improve pmccabe2html.
94884         * build-aux/pmccabe2html: Add CYCLO_SRCS variable, and make
94885         cyclo-$(PACKAGE).html depend on it, so the HTML file is remade
94886         when the sources change. Remove the line in the HTML about "Used
94887         ranges" (which implied that there might be other unused ranges),
94888         rename "Resume" to "Summary" (easier to understand for more users).
94889         * build-aux/pmccabe.css: Removing the dashed dividers, some unused
94890         styles, and some unnecessary blank lines.
94892 2010-10-03  Bruno Haible  <bruno@clisp.org>
94893             Joachim Schmitz  <schmitz@hp.com>  (tiny change)
94895         acl: Add support for ACLs on NonStop Kernel.
94896         * m4/acl.m4 (gl_FUNC_ACL): For Solaris, test for facl(), not for acl().
94897         Check whether the function aclsort() exists.
94898         * lib/acl-internal.h: For Solaris, test HAVE_FACL, not HAVE_ACL.
94899         (acl_nontrivial) [HAVE_ACLSORT]: New declaration.
94900         * lib/file-has-acl.c: For Solaris, test HAVE_FACL, not HAVE_ACL.
94901         (acl_nontrivial [HAVE_ACLSORT]: New function.
94902         (file_has_acl): Implement for NonStop Kernel.
94903         * lib/set-mode-acl.c: For Solaris, test HAVE_FACL, not HAVE_ACL.
94904         (qset_acl): Implement for NonStop Kernel.
94905         * lib/copy-acl.c (qcopy_acl): Implement for NonStop Kernel.
94906         * tests/test-sameacls.c: For Solaris, test HAVE_FACL, not HAVE_ACL.
94907         (main): Implement for NonStop Kernel.
94908         * tests/test-file-has-acl.sh (acl_flavor): Set to 'nsk' on NonStop
94909         Kernel. Handle this flavor.
94910         * tests/test-set-mode-acl.sh: Likewise.
94911         * tests/test-copy-acl.sh: Likewise.
94912         * tests/test-copy-file.sh: Likewise.
94914 2010-10-03  Bruno Haible  <bruno@clisp.org>
94916         Info about ACLs on NonStop Kernel.
94917         * doc/acl-resources.txt: Add info about NonStop Kernel.
94918         References by Joachim Schmitz <schmitz@hp.com>.
94920 2010-10-02  Bruno Haible  <bruno@clisp.org>
94922         Define missing EDQUOT on NonStop Kernel.
94923         * lib/errno.in.h (EDQUOT): Assign a value if missing.
94924         * lib/strerror.c (rpl_strerror): Handle missing EDQUOT.
94925         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Also test whether EDQUOT is
94926         missing.
94927         * doc/posix-headers/errno.texi: Mention the NSK bug.
94928         * doc/posix-functions/strerror.texi: Mention the workaround on NSK.
94929         Reported by Joachim Schmitz <schmitz@hp.com>.
94931 2010-10-02  Bruno Haible  <bruno@clisp.org>
94933         Update doc for POSIX:2008.
94934         * doc/posix-headers/*.texi [except ucontext.texi, sys_timeb.texi]:
94935         Update URL of POSIX specification.
94937 2010-10-02  Bruno Haible  <bruno@clisp.org>
94939         gnulib-tool: In testdirs, use the newest available config.{guess.sub}.
94940         * gnulib-tool (func_create_testdir): Use config.guess and config.sub
94941         from gnulib, not from Automake.
94943 2010-10-02  Bruno Haible  <bruno@clisp.org>
94945         New module 'system-posix'.
94946         * modules/system-posix: New file.
94947         * lib/stdlib.in.h: Include <sys/wait.h> only when the 'system-posix'
94948         module is present.
94949         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
94950         GNULIB_SYSTEM_POSIX.
94951         * modules/stdlib (Depends-on): Remove sys_wait.
94952         (Makefile.am): Substitute GNULIB_SYSTEM_POSIX.
94953         * doc/posix-functions/system.texi: Mention the new module.
94954         * doc/posix-headers/stdlib.texi: Likewise.
94955         * tests/test-stdlib.c: If GNULIB_TEST_SYSTEM_POSIX is not defined,
94956         define test_sys_wait_macros to a no-op.
94957         Reported by Sam Steingold <sds@gnu.org>.
94959 2010-09-30  Bruno Haible  <bruno@clisp.org>
94961         More renaming from 'getdate' to 'get_date'.
94962         * doc/get_date.texi: Renamed from doc/getdate.texi.
94963         * modules/get_date (Files): Update.
94964         * MODULES.html.sh (Date and time <time.h>): Update.
94965         * DEPENDENCIES: Update.
94966         * gnulib-tool: Update comment.
94967         * m4/bison.m4 (gl_BISON): Likewise.
94968         * m4/get_date.m4 (gl_GET_DATE): Likewise.
94970 2010-09-30  Justin Clift  <jclift@redhat.com>  (tiny change)
94972         bootstrap: support ACLOCAL_FLAGS during aclocal
94973         * build-aux/bootstrap (aclocal): Honor ACLOCAL_FLAGS, so the user
94974         can add additional -I dir for third-party .m4 files.
94976 2010-09-30  Eric Blake  <eblake@redhat.com>
94978         bootstrap: use glibtoolize on MacOS
94979         * build-aux/bootstrap (check_versions): Convert libtool into
94980         libtoolize.
94981         (tool search): Move libtool check earlier, and look for
94982         glibtoolize for MacOS.
94983         (gnulib_tool_options): Auto-add --libtool when appropriate.
94984         Reported by Justin Clift.
94986         poll: fix typo that broke test on MacOS
94987         * m4/poll.m4 (gl_FUNC_POLL): Add missing test.
94988         Reported by Justin Clift.
94990         getdate: rename to get_date
94991         Note: getdate.h is not renamed, to minimize client impact.
94992         * modules/getdate: Mark obsolete.  Move old contents...
94993         * modules/get_date: ...to new module name.
94994         * modules/getdate-tests: Move...
94995         * modules/get_date-tests: ...here.
94996         * m4/getdate.m4: Move...
94997         * m4/get_date.m4: ...here, and rename gl_GETDATE to gl_GET_DATE.
94998         * lib/getdate.y: Move...
94999         * lib/get_date.y: ...here.
95000         * tests/test-getdate.c: Move...
95001         * tests/test-get_date.c: ...here.
95002         * doc/posix-functions/getdate.texi (getdate): Update name.
95003         * NEWS: Mention the change.
95005 2010-09-29  Bruno Haible  <bruno@clisp.org>
95007         Separate the module 'waitpid' from the module 'sys_wait'.
95008         * lib/sys_wait.in.h (waitpid): Declare only if the 'waitpid' module is
95009         present.
95010         * m4/sys_wait_h.m4 (gl_SYS_WAIT_MODULE_INDICATOR): Invoke
95011         gl_MODULE_INDICATOR_FOR_TESTS.
95012         (gl_SYS_WAIT_H_DEFAULTS): Initialize GNULIB_WAITPID.
95013         * modules/sys_wait (Depends-on): Remove waitpid.
95014         (Makefile.am): Substitute GNULIB_WAITPID.
95015         * modules/waitpid (configure.ac): Invoke gl_SYS_WAIT_MODULE_INDICATOR.
95016         * tests/test-sys_wait-c++.cc (GNULIB_NAMESPACE::waitpid): Check the
95017         signature only if the 'waitpid' module is present.
95018         * doc/posix-functions/waitpid.texi: Mention the 'waitpid' module.
95019         * NEWS: Mention the change.
95020         * modules/grantpt (Depends-on): Add waitpid.
95021         * modules/wait-process (Depends-on): Likewise.
95023 2010-09-29  Bruno Haible  <bruno@clisp.org>
95025         More tests for module 'sys_wait'.
95026         * modules/sys_wait-c++-tests: New file.
95027         * tests/test-sys_wait-c++.cc: New file.
95028         * modules/sys_wait-tests (Depends-on): Add sys_wait-c++-tests.
95029         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>.
95031 2010-09-29  Bruno Haible  <bruno@clisp.org>
95033         New module 'waitpid'.
95034         * lib/waitpid.c: New file, extracted from lib/sys_wait.in.h.
95035         * lib/sys_wait.in.h: Include <sys/types.h>, c++defs.h, warn-on-use.h.
95036         Don't include <process.h>.
95037         (waitpid): Declare only, using modern idiom.
95038         * m4/waitpid.m4: New file.
95039         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H): Check whether waitpid is declared.
95040         * modules/waitpid: New file.
95041         * modules/sys_wait (Depends-on): Add c++defs, warn-on-use, waitpid.
95042         (Makefile.am): Update.
95043         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>.
95045 2010-09-28  Bruno Haible  <bruno@clisp.org>
95047         poll: Assume ANSI C.
95048         * lib/poll.c (poll): Use an ANSI C declaration.
95050 2010-09-28  Bruno Haible  <bruno@clisp.org>
95052         poll-h: Create poll.h on all platforms.
95053         * lib/poll.in.h: Use double-inclusion guard. Don't define POLL*,
95054         struct pollfd, nfds_t, INFTIM when the system has <poll.h>.
95055         * m4/poll_h.m4 (gl_POLL_H): Set HAVE_POLL_H. Invoke
95056         gl_CHECK_NEXT_HEADERS. Don't set POLL_H.
95057         (gl_REPLACE_POLL_H): Don't set POLL_H.
95058         (gl_POLL_H_DEFAULTS): Don't initialize POLL_H.
95059         * modules/poll-h (Depends-on): Add include_next.
95060         (Makefile.am): Create poll.h unconditionally. Substitute also
95061         HAVE_POLL_H, INCLUDE_NEXT, PRAGMA_SYSTEM_HEADER, NEXT_POLL_H.
95063 2010-09-28  Bruno Haible  <bruno@clisp.org>
95065         Tests for module 'poll-h'.
95066         * modules/poll-h-c++-tests: New file.
95067         * tests/test-poll-h-c++.cc: New file.
95069         Tests for module 'poll-h'.
95070         * modules/poll-h-tests: New file.
95071         * tests/test-poll-h.c: New file.
95073 2010-09-28  Bruno Haible  <bruno@clisp.org>
95075         poll-h: Ensure POLL{RD,WR}{NORM,BAND} are defined on glibc platforms.
95076         * modules/poll-h (Depends-on): Add 'extensions'.
95078 2010-09-28  Bruno Haible  <bruno@clisp.org>
95080         New module 'poll-h'.
95081         * lib/poll.in.h: Include c++defs.h and warn-on-use.h.
95082         (poll): Use modern idiom.
95083         * modules/poll-h: New file.
95084         * modules/poll (Files): Remove lib/poll.in.h.
95085         (Depends-on): Add poll-h.
95086         (configure.ac): Invoke gl_POLL_MODULE_INDICATOR.
95087         (Makefile.am): Move code for generation of poll.h to modules/poll-h.
95088         * m4/poll_h.m4: New file.
95089         * m4/poll.m4 (gl_FUNC_POLL): Require gl_POLL_H. Don't check for poll.h
95090         here. Don't set POLL_H here. Instead, set HAVE_POLL and REPLACE_POLL
95091         and invoke gl_REPLACE_POLL_H.
95092         * lib/poll.c: Use common idiom.
95093         * tests/test-poll.c: Likewise.
95094         * doc/posix-headers/poll.texi: Mention the poll-h module.
95095         Suggested by Eric Blake.
95097 2010-09-26  Bruno Haible  <bruno@clisp.org>
95099         sys_wait: Implement WSTOPSIG.
95100         * lib/sys_wait.in.h (WSTOPSIG): New macro.
95101         Reported by Simon Josefsson.
95103 2010-09-26  Simon Josefsson  <simon@josefsson.org>
95105         stdlib, sys_wait: Avoid compilation error on mingw.
95106         * lib/sys_wait.in.h: Include <signal.h>, for SIGTERM.
95108 2010-09-26  Bruno Haible  <bruno@clisp.org>
95110         stdlib tests: Avoid code duplication.
95111         * modules/stdlib-tests (Files): Add tests/test-sys_wait.h.
95112         * modules/sys_wait-tests (Files): Likewise.
95113         * tests/test-sys_wait.h: New file, extracted from tests/test-stdlib.c.
95114         * tests/test-stdlib.c: Include test-sys_wait.h.
95115         (main): Invoke test_sys_wait_macros.
95116         * tests/test-sys_wait.c: Include test-sys_wait.h.
95117         (main): Invoke test_sys_wait_macros.
95119 2010-09-25  Simon Josefsson  <simon@josefsson.org>
95121         * modules/getaddrinfo (Depends-on): Depend on the sockets module.
95122         * lib/getaddrinfo.c (use_win32_p): Call gl_sockets_startup to make
95123         sure Windows sockets are working before calling getaddrinfo.
95124         * tests/test-getaddrinfo.c (main): Don't call WSAStartup here.
95125         * doc/gnulib.texi (Windows sockets): Fix typo.
95127 2010-09-25  Bruno Haible  <bruno@clisp.org>
95129         Tests for module 'regex-quote'.
95130         * modules/regex-quote-tests: New file.
95131         * tests/test-regex-quote.c: New file.
95133         New module 'regex-quote'.
95134         * lib/regex-quote.h: New file.
95135         * lib/regex-quote.c: New file.
95136         * modules/regex-quote: New file.
95137         Suggested by Reuben Thomas <rrt@sc3d.org>.
95139 2010-09-24  Bruno Haible  <bruno@clisp.org>
95141         unistr/u8-strchr: Fix a test failure on i586 glibc systems.
95142         * tests/unistr/test-strchr.h (test_strchr): Disable an invalid check.
95144 2010-09-23  Bruno Haible  <bruno@clisp.org>
95146         setenv: Relax license.
95147         * modules/setenv (License): Change to LGPLv2+, with consent by Eric
95148         Blake.
95149         Requested by Eric Blake.
95151 2010-09-22  Bruno Haible  <bruno@clisp.org>
95153         termios: Relax license.
95154         * modules/termios (License): Change to LGPLv2+.
95155         Requested by Eric Blake.
95157 2010-09-22  Bruno Haible  <bruno@clisp.org>
95159         threadlib: Allow the package to change the default to 'no'.
95160         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): When
95161         gl_THREADLIB_DEFAULT_NO is defined, change the default to 'no'.
95162         Reported by Paul Eggert.
95164 2010-09-22  Pádraig Brady  <P@draigbrady.com>
95165             Bruno Haible  <bruno@clisp.org>
95167         Fix endless loop in mbmemcasecoll.
95168         * lib/mbmemcasecoll.c (apply_towlower): When mbrtowc returns 0, copy 1
95169         byte.
95170         * tests/test-mbmemcasecmp.h (test_ascii): Test embedded NULs.
95172 2010-09-22  Bruno Haible  <bruno@clisp.org>
95174         Tests for module 'memcoll'.
95175         * modules/memcoll-tests: New file.
95176         * tests/test-memcoll.c: New file, based on tests/test-memcmp.c.
95178         memcoll, xmemcoll: Clarify size vs. length.
95179         * modules/memcoll.c (memcoll0): Clarify specification.
95180         * modules/xmemcoll.c (xmemcoll0): Likewise. Reduce by 1 the lengths
95181         passed to collate_error.
95183 2010-09-22  Bruno Haible  <bruno@clisp.org>
95185         Tests for module 'memcasecmp'.
95186         * modules/memcasecmp-tests: New file.
95187         * tests/test-memcasecmp.c: New file, based on tests/test-memcmp.c.
95189 2010-09-22  Paul Eggert  <eggert@cs.ucla.edu>
95191         * lib/pthread.in.h: Add split double-inclusion guard, and include
95192         system <pthread.h> if there is one.  Use @@-style as in other
95193         .in.h files.  Define PTHREAD_COND_INITIALIZER etc. only if system
95194         pthread.h doesn't.
95195         (pthread_mutexattr_destroy, pthread_mutexattr_init):
95196         (pthread_mutexattr_settype, pthread_mutex_trylock):
95197         New static inline functions, if there's no system <pthread.h>.
95198         (pthread_spinlock_t, pthread_spin_init, pthread_spin_destroy):
95199         (pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock):
95200         Approximate with mutexes if the system lacks spinlocks, as in
95201         MacOS.
95202         * m4/pthread.m4 (gl_PTHREAD_CHECK): Require gl_PTHREAD_DEFAULTS.
95203         Add gl_CHECK_NEXT_HEADERS for pthread.h, and support the usual
95204         @@-style.  Check for spinlocks separately.
95205         (gl_PTHREAD_DEFAULTS): New macro.
95206         * modules/pthread: Redo to use a more typical style for in.h files.
95208 2010-09-21  Eric Blake  <eblake@redhat.com>
95210         net_if: enhance tests
95211         * tests/test-net_if.c (main): Move signature checks earlier.
95212         Print failures to stderr.
95213         * doc/posix-functions/if_freenameindex.texi (if_freenameindex):
95214         Document the bug that we do not yet fix.
95216 2010-09-21  Reuben Thomas  <rrt@sc3d.org>
95218         * doc/gnulib.texi (Out of memory handling): Rewrite section to be
95219         about gnulib, not GSS.
95221 2010-09-21  Reuben Thomas  <rrt@sc3d.org>
95223         * build-aux/pmccabe2html: Look for sources in src/ instead of lib/.
95224         * build-aux/pmccabe2html: Set cut_dir properly, and add mode line
95225         for Emacs.
95226         * build-aux/pmccabe2html: Make Makefile.am example code more
95227         cut-and-paste friendly.
95229 2010-09-21  Simon Josefsson  <simon@josefsson.org>
95231         * tests/test-net_if.c: New file.
95232         * modules/net_if-tests: New file.
95234 2010-09-20  Paul Eggert  <eggert@cs.ucla.edu>
95236         pthread: add pthread_spin_destroy
95237         * lib/pthread.in.h (pthread_spin_destroy): New function.
95239 2010-09-19  Bruno Haible  <bruno@clisp.org>
95241         gnulib-tool: Fix --help output.
95242         * gnulib-tool (func_usage): Fix help message.
95243         Reported by Reuben Thomas <rrt@sc3d.org>.
95245 2010-09-18  Jim Meyering  <meyering@redhat.com>
95247         maint.mk: avoid unexpanded \n in two diagnostics
95248         * top/maint.mk (sc_prohibit_always_true_header_tests):
95249         Don't use a literal \n in a halt=... assignment.  It would not be
95250         expanded, and the two \n bytes would appear in the diagnostic output
95251         rather than the desired newline.  Use halt=$$(printf ... instead.
95252         (sc_vulnerable_makefile_CVE-2009-4029): Likewise.
95254 2010-09-18  Bruno Haible  <bruno@clisp.org>
95256         netinet_in: Doc tweak.
95257         * doc/posix-headers/netinet_in.texi: Mention an affected platform.
95258         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
95260 2010-09-18  Jim Meyering  <meyering@redhat.com>
95262         init.sh: correct an outdated comment
95263         * tests/init.sh (create_exe_shims_):  s/function/alias/
95265         init.sh: don't let an ephemeral "*.exe" make us skip all dir entries
95266         * tests/init.sh (find_exe_basenames_): Don't give up on a directory if
95267         a file named "*.exe" is removed between the glob expansion and the
95268         processing of that oddly named file.
95270 2010-09-17  Eric Blake  <eblake@redhat.com>
95272         mirbsd: add some more support
95273         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): MirBSD is
95274         in BSD family.
95275         * m4/gc-random.m4 (gl_GC_RANDOM): MirBSD supports same random
95276         devices as OpenBSD.
95277         * m4/host-os.m4 (mirbsd): Add MirBSD.
95279         tests: fix unportable assumption on sys/wait.h
95280         * tests/test-sys_wait.c (main): Relax test.
95281         * tests/test-stdlib.c (main): Likewise.
95283         init.sh: accommodate directory with no .exes
95284         * tests/init.sh: Accomodate directory containing only scripts.
95286         tests: avoid compiler warning
95287         * tests/test-stdlib.c (main): Use the variable.
95289         fdutimens, fdutimensat: update signature, again
95290         * lib/utimens.h (gl_futimens): Delete, and move signature...
95291         (fdutimens): ...here.
95292         (fdutimensat): Rearrange signature.
95293         (lutimensat): Rename variable for clarity.
95294         * lib/fdutimensat.c (fdutimensat): Update signature.
95295         * lib/utimens.c (fdutimens): Likewise.
95296         (gl_futimens): Delete.
95297         (utimens, lutimens): Update callers.
95298         * lib/futimens.c (futimens): Likewise.
95299         * tests/test-fdutimensat.c: Likewise.
95300         * tests/test-utimens.c: Likewise.
95301         * tests/test-futimens.h: Update comment.
95302         * NEWS: Mention this.
95303         Suggested by Paul Eggert.
95305 2010-09-17  Bruno Haible  <bruno@clisp.org>
95307         Take over the maintenance of some older macros from Autoconf.
95308         * m4/error.m4 (AC_FUNC_ERROR_AT_LINE): New macro, from GNU Autoconf.
95309         * m4/lstat.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): New macro, from
95310         GNU Autoconf.
95311         * m4/memcmp.m4 (AC_FUNC_MEMCMP): New macro, from GNU Autoconf.
95312         * m4/mktime.m4 (AC_FUNC_MKTIME): Change comment.
95314 2010-09-17  Eric Blake  <eblake@redhat.com>
95316         fdutimensat: drop atflag validation
95317         * lib/fdutimensat.c (fdutimensat): Allow AT_SYMLINK_NOFOLLOW even
95318         with valid fd, to close a race scenario where futimens is
95319         unsupported and FILE was replaced by a symlink.
95320         * tests/test-fdutimensat.c (do_fdutimens, main): Adjust test
95321         accordingly.
95322         Suggested by Paul Eggert.
95324 2010-09-16  Bruno Haible  <bruno@clisp.org>
95326         unlockpt: Fix declaration within GNULIB_POSIXCHECK.
95327         * lib/stdlib.in.h (unlockpt): Fix warning declaration.
95329 2010-09-16  Bruno Haible  <bruno@clisp.org>
95331         login_tty: Fix detection of function on FreeBSD, OpenBSD, NetBSD.
95332         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Augment LIBS while checking whether
95333         login_tty exists.
95334         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
95336 2010-09-16  Bruno Haible  <bruno@clisp.org>
95338         login_tty: Make the replacement code work on BSD systems.
95339         * lib/login_tty.c: Include <sys/ioctl.h>.
95340         (login_tty): Use ioctl TIOCSCTTY when available.
95341         * modules/login_tty (Depends-on): Add sys_ioctl.
95342         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
95344 2010-09-16  Bruno Haible  <bruno@clisp.org>
95346         login_tty: Stricter unit test.
95347         * modules/login_tty-tests (Depends-on): Add tcgetsid.
95348         * tests/test-login_tty.c (main): Also check the results of tcgetpgrp()
95349         and tcgetsid() after login_tty.
95350         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
95352 2010-09-16  Bruno Haible  <bruno@clisp.org>
95354         New module 'tcgetsid'.
95355         * lib/tcgetsid.c: New file.
95356         * m4/tcgetsid.m4: New file.
95357         * modules/tcgetsid: New file.
95358         * modules/termios (Depends-on): Add c++defs, warn-on-use.
95359         (Makefile.am): Ensure c++defs.h, warn-on-use.h get included. Substitute
95360         GNULIB_TCGETSID, HAVE_TCGETSID.
95361         * lib/termios.in.h: Include <sys/types.h>.
95362         (tcgetsid): New declaration.
95363         * m4/termios_h.m4 (gl_TERMIOS_H): Check whether tcgetsid is declared.
95364         (gl_TERMIOS_H_DEFAULTS): Initialize GNULIB_TCGETSID, HAVE_TCGETSID.
95365         * doc/posix-functions/tcgetsid.texi: Mention the new module.
95366         * tests/test-termios-c++.cc: Check GNULIB_NAMESPACE::tcgetsid.
95368 2010-09-16  Bruno Haible  <bruno@clisp.org>
95370         Tests for module 'termios'.
95371         * modules/termios-c++-tests: New file.
95372         * modules/termios-tests: New file.
95373         * tests/test-termios-c++.cc: New file.
95374         * tests/test-termios.c: New file.
95376         New module 'termios'.
95377         * modules/termios: New file.
95378         * lib/termios.in.h: New file.
95379         * m4/termios_h.m4: New file.
95380         * doc/posix-headers/termios.texi: Mention the new module.
95382 2010-09-16  Eric Blake  <eblake@redhat.com>
95384         fdutimensat: add an atflag parameter
95385         * lib/fdutimensat.c (fdutimensat): Add new parameter.
95386         * lib/utimens.h (fdutimensat): Update prototype.
95387         * tests/test-fdutimensat.c: Adjust test to match.
95388         * NEWS: Document the change.
95389         Suggested by Paul Eggert.
95391 2010-09-16  Bruno Haible  <bruno@clisp.org>
95393         Fix typos in comments.
95394         * lib/striconveh.h: Fix typo in comment.
95395         * lib/login_tty.c (login_tty): Likewise.
95397 2010-09-15  Bruno Haible  <bruno@clisp.org>
95399         stdlib: clarify MirBSD WEXITSTATUS bug
95400         * lib/stdlib.in.h: Clarify the MirBSD bug regarding WEXITSTATUS.
95401         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
95403 2010-09-15  Eric Blake  <eblake@redhat.com>
95405         stdlib: work around MirBSD WEXITSTATUS bug
95406         * lib/stdlib.in.h (includes): Guarantee WEXITSTATUS.
95407         * modules/stdlib (Depends-on): Add sys_wait.
95408         * tests/test-sys_wait.c (main): Enhance test.
95409         * tests/test-stdlib.c (main): Likewise.
95410         * doc/posix-headers/stdlib.texi (stdlib.h): Document the bug.
95412         docs: mention MacOS issue with WEXITSTATUS(constant)
95413         * doc/posix-headers/sys_wait.texi (sys/wait.h): Document the
95414         issue.
95415         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
95417         strnlen: add tests
95418         * modules/strnlen-tests: New file.
95419         * tests/test-strnlen.c: Likewise.
95421 2010-09-14  Bruno Haible  <bruno@clisp.org>
95423         unistr/base: Avoid link errors when module 'libunistring' is also used.
95424         * lib/unistr.in.h (u8_mbtouc_unsafe, u16_mbtouc_unsafe,
95425         u32_mbtouc_unsafe, u8_mbtouc, u16_mbtouc, u32_mbtouc, u8_mbtoucr,
95426         u16_mbtoucr, u32_mbtoucr, u8_uctomb_aux, u16_uctomb_aux, u32_uctomb):
95427         Declare also when HAVE_LIBUNISTRING is set.
95428         Reported by Pádraig Brady <P@draigbrady.com>.
95430 2010-09-14  Eric Blake  <eblake@redhat.com>
95432         test-rawmemchr: make more robust
95433         * modules/rawmemchr-tests (Files): Add zerosize-ptr.h, mmap-anon.m4.
95434         (Depends-on, configure.ac): Add needed prerequisites to use it.
95435         * modules/memchr-tests (Files, Depends-on, configure.ac):
95436         Likewise, to avoid implicit reliance on memchr module prereqs.
95437         * tests/test-memchr.c (main): Ensure proper masking.
95438         * tests/test-rawmemchr.c (main): Likewise.  Detect oversized
95439         reads.
95441         memchr: detect glibc Alpha bug
95442         Avoids http://sourceware.org/bugzilla/show_bug.cgi?id=12019.
95443         * m4/memchr.m4 (gl_FUNC_MEMCHR): Detect glibc 2.11.2 failure on
95444         Alpha.
95445         * doc/posix-functions/memchr.texi (memchr): Tweak wording.
95446         * tests/test-memchr.c (main): Enhance test.
95447         Reported by Nelson H. F. Beebe.
95449 2010-09-13  Paul Eggert  <eggert@cs.ucla.edu>
95451         fts, getcwd, glob: audit for dirfd returning -1
95452         * lib/fts.c (opendir): Remove #define; no longer used.
95453         (opendirat): New arg PDIR_FD.  All callers changed.
95454         (fts_build, _opendir2): Use new opendirat to avoid the need for
95455         dirfd, or for checking whether dirfd returns a negative value.
95456         Don't use opendir; always use openat followed by fdopendir.
95457         * lib/getcwd.c (__getcwd): Don't reset fd; fdopendir no longer clobbers
95458         it.
95459         * lib/glob.c (link_exists_p): Add comment explaining why dirfd never
95460         returns -1 here.
95461         * modules/fts (Depends-on): Remove dirfd.
95462         * modules/getcwd (Depends-on): Likewise.
95464 2010-09-13  Eric Blake  <eblake@redhat.com>
95466         float: fix broken MirBSD header
95467         * m4/float_h.m4 (gl_FLOAT_H): MirBSD copied OpenBSD's bug.
95468         * doc/posix-headers/float.texi (float.h): Document it.
95470 2010-09-13  Paul Eggert  <eggert@cs.ucla.edu>
95472         fts: use O_NOFOLLOW to avoid race condition when opening a directory
95473         * lib/fts.c (opendirat): New arg extra_flags.
95474         (__opendir2): Use it to avoid following symlinks when opening
95475         a directory, if symlinks are not supposed to be followed.  See
95476         <http://lists.gnu.org/r/bug-gnulib/2010-09/msg00213.html>.
95478         fdopendir: preserve argument fd before returning
95479         * lib/fdopendir.c: Adjust comments to say POSIX, not Solaris.
95480         (fdopendir_with_dup, fd_clone_opendir): New static functions.
95481         (fdopendir): Use them, arranging for FD to be open to the same
95482         directory that it was when it started.  (It might be temporarily
95483         closed while fdopendir is running, so this not thread- or
95484         signal-safe.)  Be careful to do the right thing even when file
95485         descriptors are scarce and dup fails with errno == EMFILE.  See
95486         <http://lists.gnu.org/r/bug-gnulib/2010-09/msg00208.html>.
95488 2010-09-10  Paolo Bonzini  <bonzini@gnu.org>
95490         regex: Pass the system regex if its only problem is 32-bit regoff_t.
95491         * NEWS: Document change.
95492         * m4/regex.m4: Disable test for regoff_t size.
95494 2010-09-13  Jim Meyering  <meyering@redhat.com>
95496         fts: don't operate on an invalid file descriptor after failed dup
95497         * lib/fts.c (fts_build): Don't call set_cloexec_flag on a
95498         negative file descriptor.
95500 2010-09-12  Paul Eggert  <eggert@cs.ucla.edu>
95502         savedir: add streamsavedir, deprecate fdsavedir
95503         * NEWS: Mention deprecation of fdsavedir.
95504         * lib/savedir.c (streamsavedir): New extern function, whose name
95505         ends in "savedir" to be consistent with the others.  This differs
95506         from savedirstream in that it doesn't close its argument.  The
95507         next version of GNU tar will use this instead of fdsavedir, to
95508         avoid some race conditions and conserve file descriptors.
95509         (savedirstream): Reimplement as a wrapper around streamsavedir.
95510         (fdsavedir): Add a comment deprecating this function.  As far as
95511         I know, only GNU tar used it, and GNU tar doesn't need it any more.
95512         * lib/savedir.h (streamsavedir): New decl.
95513         (fdsavedir): Add a comment deprecating this.
95515 2010-09-10  Bruno Haible  <bruno@clisp.org>
95517         langinfo: Fix last commit.
95518         * m4/langinfo_h.m4 (gl_LANGINFO_H): Initialize
95519         HAVE_LANGINFO_T_FMT_AMPM, HAVE_LANGINFO_YESEXPR.
95520         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
95522 2010-09-10  Bruno Haible  <bruno@clisp.org>
95524         relocatable-prog-wrapper: Fix compilation failure due to O_EXEC.
95525         * lib/progreloc.c (O_EXEC): Define fallback.
95527 2010-09-10  Paul Eggert  <eggert@cs.ucla.edu>
95529         fcntl-h: define O_CLOEXEC and O_EXEC if not defined; use new defines
95530         * NEWS: Document recent changes to fcntl-h.
95531         * doc/posix-headers/fcntl.texi (fcntl.h): Document that
95532         O_CLOEXEC is now defined to 0 if it is not defined, like other flags.
95533         Also, O_EXEC is now defined to be O_RDONLY if O_EXEC is not defined.
95534         Similarly for O_SEARCH; this last was already true, but not documented.
95535         * lib/fcntl.in.h (O_CLOEXEC): Define to 0 if not defined.
95536         * lib/dup-safer-flag.c (O_CLOEXEC): Remove now-useless #define.
95537         * lib/dup3.c, lib/pipe2.c, tests/test-dup-safer.c, tests/test-fcntl.c:
95538         Likewise.
95539         * lib/popen-safer.c (open_noinherit): Check whether O_CLOEXEC
95540         is zero, not whether it is defined.
95541         * tests/test-dup3.c, tests/test-pipe2.c (main): Likewise.
95542         * lib/progreloc.c (find_executable): Use O_EXEC rather than O_RDONLY.
95543         * lib/open.c (open): Check for O_SEARCH as well as for O_RDONLY.
95545 2010-09-10  Bruno Haible  <bruno@clisp.org>
95547         langinfo, nl_langinfo: Fix for IRIX 5.3.
95548         * m4/langinfo_h.m4 (gl_LANGINFO_H): Test whether langinfo.h defines
95549         T_FMT_AMPM, YESEXPR. Set HAVE_LANGINFO_T_FMT_AMPM,
95550         HAVE_LANGINFO_YESEXPR.
95551         * modules/langinfo (Makefile.am): Substitute HAVE_LANGINFO_T_FMT_AMPM,
95552         HAVE_LANGINFO_YESEXPR.
95553         * lib/langinfo.in.h (T_FMT_AMPM, GNULIB_defined_T_FMT_AMPM): Define if
95554         HAVE_LANGINFO_T_FMT_AMPM is 0.
95555         (YESEXPR, NOEXPR, GNULIB_defined_YESEXPR): Define if
95556         HAVE_LANGINFO_YESEXPR is 0.
95557         * lib/nl_langinfo.c (rpl_nl_langinfo): Handle also T_FMT_AMPM, YESEXPR,
95558         NOEXPR.
95559         * doc/posix-headers/langinfo.texi: Mention the IRIX 5.3 problem.
95560         * doc/posix-functions/nl_langinfo.texi: Likewise.
95561         Reported by Eric Blake.
95563 2010-09-10  Bruno Haible  <bruno@clisp.org>
95565         pty, readutmp: Fix for FreeBSD 8.0 and OpenBSD 4.6.
95566         * doc/glibc-functions/login_tty.texi: Mention the include file problem
95567         on FreeBSD 8.0 and OpenBSD 4.6.
95568         * lib/pty.in.h: Include <sys/types.h> before <libutil.h>.
95569         * m4/pty_h.m4 (gl_PTY_H): Likewise.
95570         * m4/pty.m4 (gl_FUNC_FORKPTY, gl_FUNC_OPENPTY): Likewise.
95571         * m4/readutmp.m4 (gl_READUTMP): Include <sys/types.h> before <utmp.h>.
95572         Invoke AC_INCLUDES_DEFAULT instead of using the undocumented variable
95573         ac_includes_default.
95574         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
95576 2010-09-09  Eric Blake  <eblake@redhat.com>
95578         strsignal: work around NetBSD bug
95579         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Also check in <unistd.h>.
95580         * lib/string.in.h (includes): Likewise.
95581         * doc/posix-functions/strsignal.texi (strsignal): Document the
95582         bug.
95583         Reported by Nelson H. F. Beebe.
95585         gnulib-tool: work with NetBSD /bin/sh
95586         * gnulib-tool (func_cache_var, func_cache_lookup_module)
95587         (func_get_description, func_get_comment, func_get_status)
95588         (func_get_notice, func_get_applicability, func_get_filelist)
95589         (func_get_dependencies, func_get_autoconf_early_snippet)
95590         (func_get_autoconf_snippet, func_get_automake_snippet)
95591         (func_get_include_directive, func_get_link_directive)
95592         (func_get_license, func_get_maintainer, func_import): Avoid
95593         shell syntax errors from parsing syntax extensions.
95595 2010-09-09  Bruno Haible  <bruno@clisp.org>
95597         gnulib-tool: Avoid stderr output on IRIX related to 'alias', 'unalias'.
95598         * gnulib-tool: Don't fiddle with file descriptors 0, 1, 2. Instead, use
95599         a reliable way to determine whether the 'alias' command works.
95601 2010-09-08  Jim Meyering  <meyering@redhat.com>
95603         init.sh: penalize a set-x-impaired shell; don't disqualify it
95604         * tests/init.sh: Too many shells corrupt application stderr when
95605         you set -x, so we can't afford to disqualify them, since at least
95606         on Irix-6.5, that would disqualify all bourne shells.
95607         Instead, use a two-pass approach.
95608         On the first pass, try to find a shell that meets the stricter
95609         condition that set -x does not corrupt stderr.
95610         If no shell meets the stricter condition, retest each candidate
95611         shell, but without that extra condition.  Finally, when
95612         VERBOSE=yes is requested and set -x might cause trouble, simply
95613         issue a warning and refrain from enabling debug output.
95615 2010-09-08  Eric Blake  <eblake@redhat.com>
95617         unsetenv: fix OpenBSD bug
95618         * m4/setenv.m4 (gl_FUNC_UNSETENV): Check for OpenBSD bug.
95619         * doc/posix-functions/unsetenv.texi (unsetenv): Update
95620         documentation.
95621         Reported by Jim Meyering.
95623         strtod: work around IRIX 6.5 bug
95624         * lib/strtod.c (strtod): Reparse number on shorter string if
95625         exponent parse was invalid.
95626         * tests/test-strtod.c (main): Add check for "0x1p 2".
95627         Reported by Tom G. Christensen.
95629         getopt: optimize previous patch
95630         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Correctly check for
95631         empty variable.  Speed up awk script.
95632         Reported by Paolo Bonzini.
95634 2010-09-08  Jim Meyering  <meyering@redhat.com>
95636         test.sh: disqualify shells for which set -x corrupts stderr
95637         * tests/init.sh: Add a test to disqualify /bin/sh from SunOS 5.11
95638         and OpenBSD 4.7.  They make it so with "set -x", environment settings
95639         appear in stderr output.  For example, this command:
95640             /bin/sh -c 'set -x; P=1 true 2> err' 2>/dev/null; cat err
95641         prints "P=1" on those two systems:
95643 2010-09-08  Bruno Haible  <bruno@clisp.org>
95645         gnulib-tool: Avoid stderr output on IRIX related to 'alias', 'unalias'.
95646         * gnulib-tool: Use stderr redirection around the 'alias' and 'unalias'
95647         commands, because some shells ignore redirections when there is an
95648         error in the command lookup.
95649         Reported by Eric Blake.
95651 2010-09-07  Reuben Thomas  <rrt@sc3d.org>
95653         * lib/regex.h: Fix a mention of `regex_compile' (should be
95654         `re_compile_pattern').
95655         Correct and clarify documentation for RE_CONTEXT_INVALID_DUP.
95656         (re_set_registers): Correct name of parameter in comment.
95658         * doc/regex.texi: Add documentation for missing syntax flags.
95659         Remove commented-out documentation of defunct syntax option
95660         RE_NO_EMPTY_ALTS.
95661         Correct name of RE_CHAR_CLASSES in one incorrect occurrence.
95662         Add documentation of re_set_registers.
95663         Document trick to re-use a pattern buffer by setting fastmap manually.
95664         Update documentation of struct re_pattern_buffer per public members.
95665         Uncomment documentation of equivalence class operators and
95666         collating symbol operators, since they are now implemented,
95667         Explain leftmost-longest matching in relation to alternatives.
95668         Tidy documentation of substring matching.
95669         Remove POSIX documentation, which is done better in
95670         glibc, and refer the reader there. Keep BSD API documentation, as
95671         that is not readily available elsewhere.
95673 2010-09-07  Eric Blake  <eblake@redhat.com>
95675         getopt: handle POSIXLY_CORRECT set but not exported
95676         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Restore pre-existing
95677         export state of POSIXLY_CORRECT, due to bash set -o posix.
95678         Reported by Dustin J. Mitchell.
95680 2010-09-05  Bruno Haible  <bruno@clisp.org>
95682         gnulib-tool: Highlight the changed options.
95683         * gnulib-tool (func_usage): Display the --import, --add-import,
95684         --remove-import explanations in bold font.
95686 2010-09-06  Karl Berry  <karl@gnu.org>
95688         * doc/gnulib-tool.texi (Modified imports): doc tweaks.
95690 2010-09-05  Bruno Haible  <bruno@clisp.org>
95692         uniwidth/width: Update comment.
95693         * lib/uniwidth/width.c (uc_width): Update comment for Unicode >= 3.1.
95694         Reported by Emanuele Giaquinta <emanuele.giaquinta@gmail.com>.
95696 2010-09-05  Bruno Haible  <bruno@clisp.org>
95698         isinf, isnan: Relax license.
95699         * modules/isinf (License): Change from GPL to LGPL, with consent from
95700         Ben Pfaff.
95701         * modules/isnan (License): Likewise.
95702         Requested by Ludovic Courtès.
95704 2010-09-04  Bruno Haible  <bruno@clisp.org>
95706         gnulib-tool: Help migration from --import to --add-import or --update.
95707         * gnulib-tool: Emit a verbose error message when --import is used
95708         without any module name.
95710 2010-09-04  Bruno Haible  <bruno@clisp.org>
95712         Update doc about gnulib-tool.
95713         * doc/gnulib-tool.texi (VCS Issues): Explain 'gnulib-tool --import' vs.
95714         'gnulib-tool --update' in more detail.
95715         Reported by Eric Blake.
95717 2010-09-04  Bruno Haible  <bruno@clisp.org>
95719         gnulib-tool: Change --import. New options --add/remove-import.
95720         * gnulib-tool: New options --add-import, --remove-import.
95721         (func_usage): Document them.
95722         (have_associative): Define always.
95723         (func_import): In import mode, don't merge the specified settings with
95724         the cached settings. Implement remove-import mode.
95725         * doc/gnulib-tool.texi (Modified imports): Mention the new options.
95726         Explain when to use them versus --import.
95727         (Simple update): Use --add-import instead of --import.
95728         * NEWS: Mention the change.
95730 2010-09-04  Bruno Haible  <bruno@clisp.org>
95732         * doc/gnulib-tool.texi (Initial import): Update paragraph about
95733         separate gnulib.mk.
95735 2010-09-04  Bruno Haible  <bruno@clisp.org>
95737         gnulib-tool: Don't talk about CVS any more.
95738         * gnulib-tool (func_usage, func_import): Write "version control"
95739         instead of CVS.
95741 2010-09-04  Jim Meyering  <meyering@redhat.com>
95743         maint.mk: avoid obscure sc_copyright_check failure in coreutils
95744         * top/maint.mk (v_etc_file): Prepend $(gnulib_dir)/, to avoid
95745         false positives (whose names may be ill-chosen) when searching
95746         non-VC'd files.  Otherwise, a file named "a b/lib/version-etc.c"
95747         would cause a false-positive.
95749         avoid coreutils "make distcheck" failure
95750         Coreutils tests with an absolute build directory name that contains
95751         a space.  Not quoting this directory name caused a failure.
95752         * tests/test-vc-list-files-git.sh: Quote PATH dir name.
95753         * tests/test-vc-list-files-cvs.sh: Likewise.
95755 2010-09-04  Bruno Haible  <bruno@clisp.org>
95757         gnulib-tool: Avoid error when run in a package without Makefile.am.
95758         * gnulib-tool: When collecting the m4dirs in a package that does not
95759         have a Makefile.am, eliminate those directories that contain no
95760         gnulib-cache.m4. Fix expression that counts these directories.
95762 2010-09-04  Bruno Haible  <bruno@clisp.org>
95764         update-copyright test: Improve output when perl is missing or too old.
95765         * tests/test-update-copyright.sh: Move test of Perl version down after
95766         the test whether Perl exists. Provide an explanation relating Perl's
95767         error message to Automake's SKIP: message.
95769 2010-09-04  Bruno Haible  <bruno@clisp.org>
95771         Don't augment PATH in TESTS_ENVIRONMENT.
95772         * modules/update-copyright-tests (Makefile.am): In TESTS_ENVIRONMENT,
95773         set abs_aux_dir instead of augmenting PATH.
95774         * modules/vc-list-files-tests (Makefile.am): Likewise.
95775         * tests/test-update-copyright.sh: Augment PATH here.
95776         * tests/test-vc-list-files-cvs.sh: Augment PATH here, through
95777         path_prepend_.
95778         * tests/test-vc-list-files-git.sh: Likewise.
95780 2010-09-04  Jim Meyering  <meyering@redhat.com>
95782         tests: prohibit augmenting PATH via TESTS_ENVIRONMENT
95783         * Makefile (sc_prohibit_augmenting_PATH_via_TESTS_ENVIRONMENT): New rule.
95785 2010-09-04  Bruno Haible  <bruno@clisp.org>
95787         strdup: Fix compilation error in C++ mode.
95788         * lib/string.in.h (strdup): In C++ mode with GNULIB_NAMESPACE, undefine
95789         the macro.
95791 2010-09-04  Bruno Haible  <bruno@clisp.org>
95793         dirfd: Fix compilation error in C++ mode on MacOS X, *BSD, IRIX.
95794         * lib/dirent.in.h (dirfd): In C++ mode with GNULIB_NAMESPACE, turn the
95795         macro into a function.
95796         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
95798 2010-09-04  Bruno Haible  <bruno@clisp.org>
95800         Set PATH_SEPARATOR the same way autoconf does.
95801         * build-aux/relocatable.sh.in (func_find_curr_installdir): Determine
95802         the value of PATH_SEPARATOR the same way autoconf-generated configure
95803         scripts do.
95804         * m4/lib-ld.m4 (AC_LIB_PROG_LD): Likewise.
95805         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
95807 2010-09-04  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
95809         Set PATH_SEPARATOR the same way autoconf does.
95810         * gnulib-tool (func_gnulib_dir): Determine the value of PATH_SEPARATOR
95811         the same way autoconf-generated configure scripts do.
95812         * posix-modules: Likewise.
95814 2010-09-02  Paul Eggert  <eggert@cs.ucla.edu>
95816         hash: fix safe_hasher const typo
95817         * lib/hash.c (safe_hasher): Result is pointer, not pointer to
95818         const; otherwise, there is a type error later.
95820 2010-09-02  Jim Meyering  <meyering@redhat.com>
95822         test-update-copyright.sh: require perl 5.8.0
95823         * tests/test-update-copyright.sh: Require 5.8.0,
95824         which Tom G. Christensen has confirmed is adequate,
95825         while 5.6.1 is not.
95827 2010-09-02  Eric Blake  <eblake@redhat.com>
95829         tests: init.sh improvements for re-exec'ing with zsh
95830         * tests/init.sh: Borrow autoconf POSIX-mode sanitization.  Pass
95831         -vx through shell re-exec.
95832         Reported by Tom G. Christensen.
95834         wctype: fix typo in previous commit
95835         * m4/wctype_h.m4 (gl_WCTYPE_H): Fix spelling.
95836         Reported by Ludovic Courtès.
95838 2010-09-02  Jim Meyering  <meyering@redhat.com>
95840         test-update-copyright.sh: skip test if Perl is too old
95841         * tests/test-update-copyright.sh: Exit 77 if Perl is too old.
95842         Reported by Tom G. Christensen.
95844 2010-09-02  Bruno Haible  <bruno@clisp.org>
95846         wctype: Avoid compilation error on IRIX 6.5.30.
95847         * lib/wctype.in.h (iswblank): Declare with a replacement if
95848         REPLACE_ISWBLANK is set.
95849         * m4/wctype_h.m4 (gl_WCTYPE_H): Check also whether iswblank is
95850         declared. Set REPLACE_ISWBLANK.
95851         * modules/wctype (Makefile.am): Substitute REPLACE_ISWBLANK.
95852         * doc/posix-functions/iswblank.texi: Mention the IRIX 6.5.30 problem.
95853         * doc/posix-headers/wctype.texi: Likewise.
95854         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
95856 2010-09-01  Bruno Haible  <bruno@clisp.org>
95858         New module 'socketlib'.
95859         * modules/socketlib: New file.
95860         * m4/socketlib.m4: New file, extracted from m4/sockets.m4.
95861         * m4/sockets.m4 (gl_SOCKETS): Require gl_SOCKETLIB.
95862         * modules/sockets (Depends-on): Add socketlib.
95863         Suggested by Sam Steingold <sds@gnu.org>.
95865 2010-09-01  Paul Eggert  <eggert@cs.ucla.edu>
95867         fcntl-h, etc.: prefer O_SEARCH to O_RDONLY when applicable
95869         POSIX 2008 specifies a new 'open' flag O_SEARCH, which can be used
95870         when one needs search access to a directory but not read access.
95871         On systems where it is available, it works in some cases where
95872         O_RDONLY does not, namely on directories that are searchable but
95873         not readable, and which need only to be searchable.  If O_SEARCH
95874         is not available, fall back to the traditional method of using
95875         O_RDONLY.
95877         * lib/fcntl.in.h (O_SEARCH): #define to O_RDONLY if not defined.
95878         * lib/chdir-long.c (cdb_advance_fd): Use O_SEARCH, not O_RDONLY,
95879         when opening a directory that needs only to be searchable.
95880         * lib/chdir-safer.c (chdir_no_follow): Likewise.
95881         * lib/fts.c (diropen, fts_open, fd_ring_check): Likewise.
95882         * lib/openat-proc.c (openat_proc_name): Likewise.
95883         * lib/openat.c (openat_needs_fchdir): Likewise.
95884         * lib/save-cwd.c (save_cwd): Likewise.
95885         * lib/savewd.c (savewd_save, savewd_chdir): Likewise.
95887 2010-08-28  Bruno Haible  <bruno@clisp.org>
95889         New module 'host-cpu-c-abi'.
95890         * modules/host-cpu-c-abi: New file.
95891         * m4/host-cpu-c-abi.m4: New file, based on part of
95892         clisp/src/m4/general.m4.
95893         Requested by Sam Steingold <sds@gnu.org>.
95895 2010-08-31  Eric Blake  <eblake@redhat.com>
95896         and Jim Meyering  <meyering@redhat.com>
95898         hash: factor, and guard against misbehaving hasher function
95899         * lib/hash.c (safe_hasher): New function, to encapsulate the checking
95900         of table->hasher's return value.  Also protect against a hash value
95901         so large that adding it to table->bucket results in a NULL pointer.
95902         (hash_lookup, hash_get_next, hash_find_entry, transfer_entries):
95903         Use it in place of open-coded check-and-abort.
95905 2010-08-30  Bruno Haible  <bruno@clisp.org>
95907         hash: silence spurious clang warning
95908         * lib/hash.c (hash_get_next): Remove unnecessary test against NULL.
95909         Reported by Eric Blake.
95911 2010-08-30  Eric Blake  <eblake@redhat.com>
95913         strstr, memmem, strcasestr: avoid leaked shell message
95914         * m4/strstr.m4 (gl_FUNC_STRSTR): Avoid "Alarm clock" message from
95915         FreeBSD.
95916         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
95917         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
95919         tests: silence clang warning
95920         * tests/test-malloca.c (do_allocation): Avoid dead store.
95922 2010-08-29  Bruno Haible  <bruno@clisp.org>
95924         gettext: Fix recent mistake.
95925         * m4/intl.m4 (gt_CHECK_DECL): Fix typo introduced on 2010-08-26.
95927 2010-08-29  Bruno Haible  <bruno@clisp.org>
95929         selinux-h: Offer a --without-selinux option.
95930         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): If
95931         --without-selinux was specified, skip all tests and define
95932         HAVE_SELINUX_SELINUX_H to 0.
95933         (gl_LIBSELINUX): Offer --without-selinux option. If it is specified,
95934         set LIB_SELINUX to empty.
95935         * m4/selinux-context-h.m4 (gl_HEADERS_SELINUX_CONTEXT_H): Require
95936         gl_LIBSELINUX. If --without-selinux was specified, replace
95937         selinux/context.h.
95938         Reported by Johan Hattne <johan.hattne@utsouthwestern.edu>.
95940 2010-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
95941             Bruno Haible  <bruno@clisp.org>
95943         Make the module 'realloc-gnu' work again on AIX and OSF/1.
95944         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): Define HAVE_REALLOC_GNU instead
95945         of HAVE_REALLOC.
95946         * lib/realloc.c (NEED_REALLOC_GNU): Enable behaviour also when
95947         GNULIB_REALLOC_GNU && !HAVE_REALLOC_GNU.
95948         (SYSTEM_MALLOC_GLIBC_COMPATIBLE): Adjust definition.
95949         * modules/realloc-gnu (configure.ac): Use gl_MODULE_INDICATOR.
95951 2010-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
95952             Bruno Haible  <bruno@clisp.org>
95954         Make the module 'calloc-gnu' work again on AIX and OSF/1.
95955         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Define HAVE_CALLOC_GNU instead of
95956         HAVE_CALLOC.
95957         * lib/xmalloc.c: Update accordingly.
95958         * lib/calloc.c (NEED_CALLOC_GNU): Enable also when
95959         GNULIB_CALLOC_GNU && !HAVE_CALLOC_GNU.
95960         * modules/calloc-gnu (configure.ac): Invoke gl_MODULE_INDICATOR.
95962 2010-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
95963             Bruno Haible  <bruno@clisp.org>
95965         Make the module 'malloc-gnu' work again on AIX and OSF/1.
95966         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): Define HAVE_MALLOC_GNU instead of
95967         HAVE_MALLOC.
95968         * lib/malloc.c (NEED_MALLOC_GNU): Enable behaviour also when
95969         GNULIB_MALLOC_GNU && !HAVE_MALLOC_GNU.
95970         * modules/malloc-gnu (configure.ac): Use gl_MODULE_INDICATOR.
95972 2010-08-29  Bruno Haible  <bruno@clisp.org>
95974         Update modules list.
95975         * MODULES.html.sh (Memory management functions <stdlib.h>): Add
95976         malloc-gnu, calloc-gnu, realloc-gnu. Remove malloc, calloc, realloc.
95977         (String handling <string.h>): Add astrxfrm.
95978         (File system functions): Add readlinkat.
95980 2010-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
95982         Tests for module 'realloc-gnu'.
95983         * modules/realloc-gnu-tests: New file.
95984         * tests/test-realloc-gnu.c: New file.
95986         Tests for module 'calloc-gnu'.
95987         * modules/calloc-gnu-tests: New file.
95988         * tests/test-calloc-gnu.c: New file.
95990         Tests for module 'malloc-gnu'.
95991         * modules/malloc-gnu-tests: New file.
95992         * tests/test-malloc-gnu.c: New file.
95994 2010-08-28  Bruno Haible  <bruno@clisp.org>
95996         Rename module 'realloc' -> 'realloc-gnu'.
95997         * modules/realloc-gnu: New file, copied from modules/realloc.
95998         * modules/realloc: Convert to a redirection to 'realloc-gnu'. Mark as
95999         obsolete.
96000         * modules/mgetgroups (Depends-on): Update.
96001         * doc/posix-functions/realloc.texi: Update.
96002         * NEWS: Mention the change.
96004         Rename module 'calloc' -> 'calloc-gnu'.
96005         * modules/calloc-gnu: New file, copied from modules/calloc.
96006         * modules/calloc: Convert to a redirection to 'calloc-gnu'. Mark as
96007         obsolete.
96008         * doc/posix-functions/calloc.texi: Update.
96009         * NEWS: Mention the change.
96011         Rename module 'malloc' -> 'malloc-gnu'.
96012         * modules/malloc-gnu: New file, copied from modules/malloc.
96013         * modules/malloc: Convert to a redirection to 'malloc-gnu'. Mark as
96014         obsolete.
96015         * modules/argp (Depends-on): Update.
96016         * modules/regex (Depends-on): Update.
96017         * doc/posix-functions/malloc.texi: Update.
96018         * NEWS: Mention the change.
96020 2010-08-28  Eric Blake  <eblake@redhat.com>
96022         pread, pwrite: add missing dependency
96023         * modules/pread (Depends-on): Add extensions.
96024         * modules/pwrite (Depends-on): Likewise.
96026 2010-08-28  Bruno Haible  <bruno@clisp.org>
96028         unistr/u*-strchr: Fix tests dependencies.
96029         * modules/unistr/u8-strchr-tests (Depends-on): Add unistr/u32-to-u8.
96030         * modules/unistr/u16-strchr-tests (Depends-on): Add unistr/u32-to-u16.
96031         Reported by Ian Beckwith <ianb@erislabs.net>.
96033 2010-08-28  Bruno Haible  <bruno@clisp.org>
96035         read-file: Don't occupy too much unused memory.
96036         * lib/read-file.c (fread_file): Shrink the buffer at the end.
96038 2010-08-28  Giuseppe Scrivano  <gscrivano@gnu.org>
96039             Eric Blake  <eblake@redhat.com>
96040             Bruno Haible  <bruno@clisp.org>
96042         read-file: Avoid memory reallocations with regular files.
96043         * lib/read-file.c: Include <sys/stat.h>, <stdio.h>, <stdint.h>.
96044         (fread_file): With regular files, use the remaining length as the
96045         initial buffer size.  Check against overflow.
96046         * modules/read-file (Depends-on): Add ftello, malloc-posix, stdint,
96047         sys_stat.
96049 2010-08-28  Bruno Haible  <bruno@clisp.org>
96051         ftello: Relax license.
96052         * modules/ftello (License): Relax to LGPLv2+.
96053         Reported by Eric Blake.
96055 2010-08-28  Bruno Haible  <bruno@clisp.org>
96057         Avoid relocwrapper link errors due to gnulib replacement functions.
96058         * lib/canonicalize-lgpl.c [IN_RELOCWRAPPER]: Use the system's getcwd
96059         function.
96060         Reported by Ben Pfaff <blp@cs.stanford.edu>.
96062 2010-08-28  Bruno Haible  <bruno@clisp.org>
96064         Prefer using AC_DEFUN_ONCE over AC_DEFUN in projects with gnulib.
96065         * m4/iconv.m4 (gl_iconv_AC_DEFUN): Use AC_DEFUN_ONCE if gl_00GNULIB is
96066         defined.
96067         * m4/libunistring.m4 (gl_libunistring_AC_DEFUN): Likewise.
96068         Suggested by Eric Blake.
96070 2010-08-28  Bruno Haible  <bruno@clisp.org>
96072         sys_socket, netdb: Ensure socklen_t gets defined.
96073         * modules/sys_socket (Depends-on): Add socklen.
96074         * modules/netdb (Depends-on): Likewise.
96075         * modules/getaddrinfo (Depends-on): Remove socklen.
96076         * modules/getsockopt (Depends-on): Likewise.
96077         * modules/setsockopt (Depends-on): Likewise.
96078         * tests/test-sys_socket.c: Check that socklen_t is defined.
96079         * tests/test-netdb.c: Likewise.
96080         * m4/socklen.m4: Update comments.
96081         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
96083 2010-08-27  Eric Blake  <eblake@redhat.com>
96085         login_tty: add missing dependency
96086         * modules/login_tty (Depends-on): Add pty.
96088 2010-08-26  Eric Blake  <eblake@redhat.com>
96090         lib-symbol-versions: fix m4 quoting
96091         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT): Use correct
96092         format for AC_LINK_IFELSE.
96094         glob: fix compile test
96095         * m4/glob.m4 (gl_GLOB): Use correct format for AC_COMPILE_IFELSE.
96097         btowc: fix missing file
96098         * modules/btowc (Files): Also ship locale-fr.m4.
96100         lseek: fix link test
96101         * m4/lseek.m4 (gl_FUNC_LSEEK): Use correct format for
96102         AC_LINK_IFELSE.
96104         include_next: silence autoconf 2.68 warning
96105         * m4/include_next.m4 (gl_INCLUDE_NEXT): Mark this use of
96106         AC_COMPILE_IFELSE as special.
96107         (AC_LANG_DEFINES_PROVIDED): Provide dummy implementation for
96108         autoconf < 2.68.
96110         acl: fix compilation test
96111         * m4/acl.m4 (gl_FUNC_ALL): Use correct format for
96112         AC_COMPILE_IFELSE.
96114 2010-08-26  Bruno Haible  <bruno@clisp.org>
96116         Modernize AC_TRY_RUN invocations.
96117         * m4/btowc.m4 (gl_FUNC_BTOWC): Use AC_RUN_IFELSE instead of AC_TRY_RUN.
96118         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Likewise.
96119         * m4/exponentd.m4 (gl_DOUBLE_EXPONENT_LOCATION): Likewise.
96120         * m4/exponentf.m4 (gl_FLOAT_EXPONENT_LOCATION): Likewise.
96121         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Likewise.
96122         * m4/fopen.m4 (gl_FUNC_FOPEN): Likewise.
96123         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Likewise.
96124         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
96125         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
96126         * m4/iconv.m4 (AM_ICONV_LINK): Likewise.
96127         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Likewise.
96128         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
96129         * m4/isnanf.m4 (gl_ISNANF_WORKS): Likewise.
96130         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
96131         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Likewise.
96132         * m4/mbrlen.m4 (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL,
96133         gl_MBRLEN_NUL_RETVAL): Likewise.
96134         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
96135         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL):
96136         Likewise.
96137         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
96138         * m4/open.m4 (gl_FUNC_OPEN): Likewise.
96139         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE,
96140         gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE,
96141         gl_PRINTF_DIRECTIVE_A, gl_PRINTF_DIRECTIVE_F, gl_PRINTF_DIRECTIVE_N,
96142         gl_PRINTF_DIRECTIVE_LS, gl_PRINTF_POSITIONS, gl_PRINTF_FLAG_GROUPING,
96143         gl_PRINTF_FLAG_LEFTADJUST, gl_PRINTF_FLAG_ZERO, gl_PRINTF_PRECISION,
96144         gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
96145         gl_SNPRINTF_DIRECTIVE_N, gl_SNPRINTF_SIZE1, gl_VSNPRINTF_ZEROSIZE_C99):
96146         Likewise.
96147         * m4/printf-posix.m4 (gt_PRINTF_POSIX): Likewise.
96148         * m4/signbit.m4 (gl_SIGNBIT, gl_FLOATTYPE_SIGN_LOCATION): Likewise.
96149         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
96150         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
96151         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
96152         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Likewise.
96153         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
96154         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION): Likewise.
96155         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
96156         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
96158 2010-08-26  Bruno Haible  <bruno@clisp.org>
96160         Modernize AC_TRY_LINK invocations.
96161         * m4/acosl.m4 (gl_FUNC_ACOSL): Use AC_LINK_IFELSE instead of
96162         AC_TRY_LINK.
96163         * m4/argp.m4 (gl_ARGP): Likewise.
96164         * m4/asinl.m4 (gl_FUNC_ASINL): Likewise.
96165         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
96166         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Likewise.
96167         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
96168         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
96169         * m4/codeset.m4 (AM_LANGINFO_CODESET): Likewise.
96170         * m4/cosl.m4 (gl_FUNC_COSL): Likewise.
96171         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
96172         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
96173         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Likewise.
96174         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
96175         * m4/frexp.m4 (gl_FUNC_FREXP, gl_CHECK_FREXP_NO_LIBM): Likewise.
96176         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_CHECK_FREXPL_NO_LIBM): Likewise.
96177         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
96178         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
96179         * m4/hostent.m4 (gl_HOSTENT): Likewise.
96180         * m4/iconv.m4 (AM_ICONV_LINK): Likewise.
96181         * m4/intl.m4 (gt_INTL_SUBDIR_CORE): Likewise.
96182         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Likewise.
96183         * m4/isnand.m4 (gl_HAVE_ISNAND_IN_LIBM, gl_HAVE_ISNAND_NO_LIBM):
96184         Likewise.
96185         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_HAVE_ISNANF_IN_LIBM):
96186         Likewise.
96187         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM):
96188         Likewise.
96189         * m4/lcmessage.m4 (gt_LC_MESSAGES): Likewise.
96190         * m4/ldexpl.m4 (gl_FUNC_LDEXPL, gl_CHECK_LDEXPL_NO_LIBM): Likewise.
96191         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Likewise.
96192         * m4/logb.m4 (gl_FUNC_LOGB): Likewise.
96193         * m4/logl.m4 (gl_FUNC_LOGL): Likewise.
96194         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Likewise.
96195         * m4/servent.m4 (gl_SERVENT): Likewise.
96196         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
96197         * m4/sinl.m4 (gl_FUNC_SINL): Likewise.
96198         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Likewise.
96199         * m4/tanl.m4 (gl_FUNC_TANL): Likewise.
96200         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
96201         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
96202         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
96203         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
96204         * modules/tsearch-tests (configure.ac): Likewise.
96206 2010-08-26  Bruno Haible  <bruno@clisp.org>
96208         Modernize AC_TRY_COMPILE invocations.
96209         * m4/environ.m4 (gt_CHECK_VAR_DECL): Use AC_COMPILE_IFELSE instead of
96210         AC_TRY_COMPILE.
96211         * m4/iconv.m4 (gl_iconv_AC_DEFUN): Likewise.
96212         * m4/intl.m4 (gt_CHECK_DECL): Likewise.
96213         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Likewise.
96214         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
96215         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Likewise.
96216         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
96217         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
96218         * m4/lock.m4 (gl_LOCK): Likewise.
96219         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Likewise.
96220         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
96221         * m4/minmax.m4 (gl_MINMAX_IN_HEADER): Likewise.
96222         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
96223         * m4/size_max.m4 (gl_SIZE_MAX): Likewise.
96224         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Likewise.
96225         * m4/stdarg.m4 (gl_STDARG_H): Likewise.
96226         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Likewise.
96227         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Likewise.
96228         * m4/visibility.m4 (gl_VISIBILITY): Likewise.
96229         * m4/wchar_t.m4 (gt_TYPE_WCHAR_T): Likewise.
96230         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
96231         * m4/libunistring.m4 (gl_LIBUNISTRING_CORE): Likewise. Remove
96232         extraneous semicolon.
96234 2010-08-26  Jim Meyering  <meyering@redhat.com>
96236         stat-time: relax license LGPL
96237         * modules/stat-time (License): Change from GPL to LGPL,
96238         with consent from all contributors, for use in libguile.
96239         Requested by Ludovic Courtès.
96241 2010-08-26  Erik Faye-Lund  <kusmabite@gmail.com>
96243         poll: return immediately on POLLHUP.
96244         * lib/poll.c (poll): Always set timeout before wait_timeout is
96245         computed.
96247 2010-08-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
96249         Fix test-unlinkat, test-rmdir failure on AIX 5.3.
96250         * tests/test-rmdir.h (test_rmdir_func): Also accept EEXIST for
96251         rmdir ("dir/.//"), unlinkat.
96253 2010-08-24  Paul Eggert  <eggert@cs.ucla.edu>
96255         stdbool: avoid spurious failure with modern xlc
96256         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Resync with autoconf.
96258 2010-08-24  Bruno Haible  <bruno@clisp.org>
96260         getloadavg: simplify code
96261         * m4/getloadavg.m4 (gl_GETLOADAVG): Remove useless test of
96262         gl_have_func. Update comments.
96264 2010-08-24  Eric Blake  <eblake@redhat.com>
96266         getloadavg: don't define SVR4 on cygwin
96267         * m4/getloadavg.m4 (gl_GETLOADAVG): Sync with autoconf fix, to
96268         only define SVR4 when -lkvm is required.
96269         Reported by Yaakov Selkowitz.
96271 2010-08-24  Bruno Haible  <bruno@clisp.org>
96273         priv-set: fix comment
96274         * lib/priv-set.c (priv_set_restore): Fix typo in comment.
96276 2010-08-23  Paul Eggert  <eggert@cs.ucla.edu>
96278         priv-set: fix comments
96279         * lib/priv-set.c (priv_set_remove, priv_set_restore): Fix comments
96280         to match code, as suggested by David Bartley in:
96281         http://lists.gnu.org/r/bug-tar/2010-08/msg00018.html
96283 2010-08-23  Eric Blake  <eblake@redhat.com>
96285         stdbool: avoid rejecting clang
96286         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Resync with autoconf.
96287         * tests/test-stdbool.c: Enable more tests if using the system
96288         <stdbool.h> instead of the gnulib replacement.
96289         (main): Move xlc bug test to a runtime test for all compilers.
96290         Reported by Anders Kaseorg.
96292         argz: fix shell quoting issue
96293         * m4/argz.m4 (gl_FUNC_ARGZ): Allow for spaces in argument.
96294         Reported by Charles Wilson.
96296 2010-08-22  Paolo Bonzini  <bonzini@gnu.org>
96297             Erik Faye-Lund <kusmabite@gmail.com>
96299         poll, select: handle ERROR_BROKEN_PIPE.
96300         * lib/poll.c (win32_compute_revents): Return POLLHUP when
96301         PeekNamedPipe fails with ERROR_BROKEN_PIPE.
96302         * lib/select.c (win32_compute_revents): Do not mark a pipe
96303         as writeable if PeekNamedPipe fails with ERROR_BROKEN_PIPE.
96305 2010-08-22  Giuseppe Scrivano  <gscrivano@gnu.org>
96307         fts: allow compilation with C++
96308         * lib/fts_.h: Specify extern "C" linkage with C++.
96310 2010-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
96312         Fix gnulib-tool sed script de-commentation for AIX sed.
96313         * gnulib-tool (sed_comments): Try indented comments, for AIX 5.3
96314         sed.
96316 2010-08-17  Eric Blake  <eblake@redhat.com>
96318         test-stddef: test for (some) offsetof bugs
96319         * tests/test-stddef.c: Enhance test to ensure correct type of
96320         offsetof.
96321         * doc/posix-headers/stddef.texi (stddef.h): Document a Solaris bug
96322         that we are not fixing at this time.
96324 2010-08-15  Bruno Haible  <bruno@clisp.org>
96326         stpncpy: Allow stpncpy to be defined as a macro.
96327         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Don't attempt to redeclare stpncpy
96328         if it's already correctly declared.
96329         * lib/string.in.h (stpncpy): Undefine before redefining.
96330         Reported by Jeremy Huddleston <jeremyhu@macports.org>.
96332 2010-08-14  Bruno Haible  <bruno@clisp.org>
96334         Rename module 'memxfrm' to 'amemxfrm'.
96335         * lib/amemxfrm.h: Renamed from lib/memxfrm.h.
96336         (amemxfrm): Renamed from memxfrm.
96337         * lib/amemxfrm.c: Renamed from lib/memxfrm.h. Include amemxfrm.h.
96338         (amemxfrm): Renamed from memxfrm.
96339         * modules/amemxfrm: Renamed from modules/memxfrm. Update.
96340         * NEWS: Mention the change.
96341         * MODULES.html.sh (String handling <string.h>): Update.
96342         * lib/unicase/u-casexfrm.h: Invoke amemxfrm instead of memxfrm.
96343         * lib/unicase/u8-casexfrm.c: Include amemxfrm.h instead of memxfrm.h.
96344         * lib/unicase/u16-casexfrm.c: Likewise.
96345         * lib/unicase/u32-casexfrm.c: Likewise.
96346         * lib/uninorm/u-normxfrm.h: Invoke amemxfrm instead of memxfrm.
96347         * lib/uninorm/u8-normxfrm.c: Include amemxfrm.h instead of memxfrm.h.
96348         * lib/uninorm/u16-normxfrm.c: Likewise.
96349         * lib/uninorm/u32-normxfrm.c: Likewise.
96350         * modules/unicase/u8-casexfrm (Depends-on): Add amemxfrm, remove
96351         memxfrm.
96352         * modules/unicase/u16-casexfrm (Depends-on): Likewise.
96353         * modules/unicase/u32-casexfrm (Depends-on): Likewise.
96354         * modules/uninorm/u8-normxfrm (Depends-on): Likewise.
96355         * modules/uninorm/u16-normxfrm (Depends-on): Likewise.
96356         * modules/uninorm/u32-normxfrm (Depends-on): Likewise.
96357         Suggested by Paul Eggert.
96359 2010-08-14  Bruno Haible  <bruno@clisp.org>
96361         Tests for module 'astrxfrm'.
96362         * modules/astrxfrm-tests: New file.
96363         * tests/test-astrxfrm.c: New file.
96365         New module 'astrxfrm'.
96366         * lib/astrxfrm.h: New file.
96367         * lib/astrxfrm.c: New file, based on lib/memxfrm.c.
96368         * modules/astrxfrm: New file.
96370 2010-08-14  Reuben Thomas  <rrt@sc3d.org>
96372         regex: Tweak doc.
96373         * doc/regex.texi (Overview): Don't mention regex.c.
96374         (GNU Regular Expression Compiling): Likewise.
96375         (Match-end-of-line Operator): Mention 'not_eol'.
96377 2010-08-14  Brian Gough  <bjg@gnu.org>
96378             Bruno Haible  <bruno@clisp.org>
96380         git-merge-changelog: add doc relating to use with bzr and hg.
96381         * lib/git-merge-changelog.c: Add comments regarding bzr, hg, diff3.
96383 2010-08-14  Matthias Bolte  <matthias.bolte@googlemail.com>
96385         pthread: fix pthread.h creation for srcdir != builddir
96386         * modules/pthread (Makefile.am): Fix the rule to work also in a
96387         non-srcdir build.
96389 2010-08-13  Karl Berry  <karl@gnu.org>
96391         * doc/regex.texi (Predefined Syntaxes): @smallexample.
96392         * doc/posix-*/*: force line break before @url of POSIX
96393         specifications.
96394         Suggested by Werner Lemberg.
96396 2010-08-10  Paul Eggert  <eggert@cs.ucla.edu>
96398         strtod: fix const diagnostic
96399         * lib/strtod.c (strtod): Don't assign const char * to char *,
96400         as this elicits a warning from GCC when warnings are enabled.
96402 2010-08-10  Pádraig Brady  <P@draigbrady.com>
96403         and Eric Blake  <eblake@redhat.com>
96405         copy-acl: ignore ENOTSUP on HP-UX
96406         * lib/acl-internal.h (ACL_NOT_WELL_SUPPORTED): Move definition up,
96407         so that it is available for HP-UX.
96408         * lib/copy-acl.c (qcopy_acl): Use it.
96409         Reported by Patrick M. Callahan.
96411 2010-08-10  Eric Blake  <eblake@redhat.com>
96413         open, chown: relax license
96414         * modules/open (License): Change to LGPLv2+, with consent by all
96415         authors, for use in augeas.
96416         * modules/chown (License): Likewise.
96417         * modules/lchown (Likewise): Likewise.
96418         Requested by Adam Stokes.
96420 2010-08-09  Karl Berry  <karl@gnu.org>
96422         * build-aux/ar-lib: new file, import from Automake.
96423         * config/srclist.txt: autocheck for updates.
96425 2010-08-09  Eric Blake  <eblake@redhat.com>
96427         readlinkat: adjust client modules
96428         * modules/areadlinkat (Depends-on): Use readlinkat, not
96429         symlinkat.
96430         * modules/areadlinkat-with-size (Depends-on): Likewise.
96432         mknod: be more vocal about danger of running tests as root
96433         * m4/mknod.m4 (gl_FUNC_MKNOD): Make it harder to run configure as
96434         root, since that is just asking for problems.
96435         Suggested by Bruno Haible, based on a report by Rainer Tammer.
96437         readlinkat: split into its own module
96438         * modules/symlinkat: Split readlinkat...
96439         * modules/readlinkat: ...into separate module.
96440         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Move readlinkat check...
96441         * m4/readlinkat.m4 (gl_FUNC_READLINAT): ...to new file.
96442         * lib/symlinkat.c (readlinkat): Move...
96443         * lib/readlinkat.c: ...into new file.
96444         * modules/symlinkat-tests: Split readlinkat test...
96445         * modules/readlinkat-tests: ...into separate module.
96446         * tests/test-symlinkat.c: Split...
96447         * tests/test-readlinkat.c: ...into new file.
96448         * NEWS: Document the split.
96449         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
96450         * lib/unistd.in.h (readlinkat): Likewise.
96451         Suggested by Bruno Haible.
96453 2010-08-08  Bruno Haible  <bruno@clisp.org>
96455         memxfrm: Speed up.
96456         * lib/memxfrm.c (memxfrm): Allocate enough memory ahead of time, so
96457         that usually only one call to strxfrm is necessary for each string
96458         part.
96459         Reported by Paul Eggert <eggert@cs.ucla.edu>.
96461 2010-08-07  Karl Berry  <karl@gnu.org>
96463         * doc/posix-headers/limits.texi,
96464         * doc/posix-functions/malloc.texi,
96465         * doc/posix-functions/strsignal.texi: missing @item.
96466         * doc/ld-version-script.texi: spurious leading i.
96467         * doc/regex.texi (Interval Operators): no commas inside @var.
96469 2010-08-01  Bruno Haible  <bruno@clisp.org>
96471         Integrate the regex documentation.
96472         * doc/gnulib.texi: Define 'cn' index.
96473         (Regular expressions): New a chapter that includes regex.texi and
96474         regexprops-generic.texi.
96475         * doc/regex.texi: Remove boilerplate stuff. Use simplified @node
96476         syntax.
96478         Whitespace cleanup.
96479         * doc/regex.texi: Remove trailing spaces.
96481         Add regex documentation.
96482         * doc/regex.texi: New file. Taken from regex-0.12/doc/regex.texi in
96483         http://ftp.gnu.org/old-gnu/regex/regex-0.12.tar.gz.
96484         Written by Kathy A. Hargreaves and Karl Berry.
96486 2010-08-01  Bruno Haible  <bruno@clisp.org>
96488         link: Update documentation.
96489         * doc/posix-functions/link.texi: Update regarding Solaris.
96491 2010-07-31  Bruno Haible  <bruno@clisp.org>
96493         Update modules list.
96494         * MODULES.html.sh (Sorting functions <stdlib.h>): Add array-mergesort.
96495         (String handling <string.h>): Add memcmp2, memxfrm.
96496         (Container data structures): Add xlist, xsublist, xoset.
96497         (Core language properties): Add alignof, unused-parameter.
96498         (Process control, Numeric conversion functions <stdlib.h>): Renamed
96499         from Numeric conversion functions <stdlib.h>. Add _Exit, atoll.
96500         (Unibyte characters <ctype.h>): New section.
96501         (String handling <string.h>): New section.
96502         (Mathematics <math.h>): Add acos, acosl, asin, asinl, atan, atan2,
96503         atanl, cbrt, copysign, cos, cosh, cosl, erf, erfc, exp, expl, fabs,
96504         fmod, hypot, j0, j1, jn, ldexp, lgamma, log, log10, log1p, logb, logl,
96505         modf, nextafter, pow, remainder, rint, sin, sinh, sinl, sqrt, sqrtl,
96506         tan, tanh, tanl, y0, y1, yn.
96507         (Support for systems lacking POSIX:2008): Add alphasort, dirent,
96508         dprintf, dprintf-posix, duplocale, fcntl, getlogin, getopt-posix,
96509         grantpt, iconv-h, ioctl, isblank, langinfo, nl_langinfo, pread,
96510         ptsname, pwrite, scandir, servent, sys_utsname, ttyname_r, uname,
96511         unlockpt, vdprintf, vdprintf-posix.
96512         (Enhancements for POSIX:2008 functions): Add getopt-gnu. Remove getopt.
96513         (File system functions): Add concat-filename, sys_file, sys_ioctl,
96514         xconcat-filename.
96515         (File descriptor based Input/Output): Add dup3, fd-safer-flag,
96516         getdtablesize, pipe2, pipe2-safer.
96517         (Security): New section.
96518         (Networking functions): Add accept4.
96519         (Signal handling): Add sigpipe.
96520         (Internationalization functions): Add xstriconveh, mbmemcasecmp,
96521         mbmemcasecoll.
96522         (Unicode string functions): Add libunistring-optional, unistr/u*-cmp2,
96523         unistr/u*-strcoll, uniwbrk/*, uninorm/*, unicase/*.
96524         (Executing programs): Add findprog-lgpl, pipe-filter-gi,
96525         pipe-filter-ii.
96526         (Misc): Add argp-version-etc, login_tty, parse-duration.
96528 2010-07-31  Bruno Haible  <bruno@clisp.org>
96530         Improve doc in MODULES.html.
96531         * modules/linkat (Description): Add the word "function".
96532         * modules/mkfifo (Description): Likewise.
96533         * modules/mknod (Description): Likewise.
96534         * modules/remove (Description): Likewise.
96535         * modules/renameat (Description): Likewise.
96536         * modules/stat (Description): Likewise.
96537         * modules/symlink (Description): Likewise.
96538         * modules/unlink (Description): Likewise.
96540 2010-07-31  Bruno Haible  <bruno@clisp.org>
96542         ansi-c++-opt: Provide option --enable-c++/--disable-c++ when possible.
96543         * m4/ansi-c++.m4 (gl_CXX_CHOICE): In Autoconf 2.66 or newer, provide
96544         option --enable/disable-c++ instead of --enable/disable-cxx.
96545         * NEWS: Mention the change.
96547 2010-07-31  Bruno Haible  <bruno@clisp.org>
96549         readlink, areadlink: Relax test a bit.
96550         * tests/test-readlink.h (test_readlink): Accept EINVAL as an
96551         alternative to ENOTDIR.
96552         * tests/test-areadlink.h (test_areadlink): Likewise.
96553         Reported by Rainer Tammer.
96555 2010-07-31  Bruno Haible  <bruno@clisp.org>
96557         unistr/u8-strstr, unistr/u16-strstr: Optimize the one-character case.
96558         * lib/unistr/u-strstr.h (FUNC): When the needle contains only one
96559         character, perform the search using U_STRCHR.
96560         * lib/unistr/u8-strstr.c (U_STRMBTOUC): New macro.
96561         * lib/unistr/u16-strstr.c (U_STRMBTOUC): Likewise.
96562         * modules/unistr/u8-strstr (Depends-on): Add unistr/u8-strmbtouc.
96563         * modules/unistr/u16-strstr (Depends-on): Add unistr/u16-strmbtouc.
96564         Suggested by Paolo Bonzini.
96566 2010-07-31  Bruno Haible  <bruno@clisp.org>
96568         unistr/u*-strstr: Fix dependencies.
96569         * modules/unistr/u8-strstr (Depends-on): Add unistr/u8-strchr.
96570         * modules/unistr/u16-strstr (Depends-on): Add unistr/u16-strchr.
96571         * modules/unistr/u32-strstr (Depends-on): Add unistr/u32-strchr.
96573 2010-07-31  Bruno Haible  <bruno@clisp.org>
96575         unistr/u8-chr, unistr/u8-strchr: Optimize and add comments.
96576         * lib/unistr/u8-chr.c (u8_chr): Add comments. Remove a useless test at
96577         the beginning of the loop.
96578         * lib/unistr/u8-strchr.c (u8_strchr): Add comments. Don't fall through
96579         cases in 'switch' statement.
96581         unistr/u8-strchr: Fix several bugs.
96582         * lib/unistr/u8-strchr.c (u8_strchr): Don't search beyond the end of
96583         the string. When not found, return NULL, not a pointer near the end.
96585         More tests for unistr/u8-strchr.
96586         * tests/unistr/test-strchr.h (test_strchr): Renamed from main. Check
96587         that the function does not read past the first occurrence of the byte
96588         being searched.
96589         * tests/unistr/test-u8-strchr.c (main): New function, with more tests.
96590         * tests/unistr/test-u16-strchr.c (main): New function.
96591         * tests/unistr/test-u32-strchr.c (main): New function.
96593 2010-07-31  Bruno Haible  <bruno@clisp.org>
96595         posix-modules: Ignore backup files of documentation files.
96596         * posix-modules: grep only through files named *.texi.
96598 2010-07-31  Bruno Haible  <bruno@clisp.org>
96600         symlinkat: Fix documentation.
96601         * doc/posix-functions/readlinkat.texi: Fix module name.
96603 2010-07-31  Bruno Haible  <bruno@clisp.org>
96605         fchownat: Replace also when chown has the trailing slash bug.
96606         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Move the test of REPLACE_CHOWN
96607         outside the gl_FUNC_FCHOWNAT_DEREF_BUG invocation. Fixes regression
96608         introduced on 2010-04-10.
96609         Reported by Rainer Tammer.
96611 2010-07-31  Bruno Haible  <bruno@clisp.org>
96613         linkat: Work around AIX 7.1 bug.
96614         * m4/linkat.m4 (gl_FUNC_LINKAT): Require AC_CANONICAL_HOST. Test
96615         whether linkat handles trailing slash correctly. If not, replace linkat
96616         and define LINKAT_TRAILING_SLASH_BUG.
96617         * lib/linkat.c (rpl_linkat): If LINKAT_TRAILING_SLASH_BUG is defined,
96618         check whether (fd1,file1) points to a directory if file1 or file2 ends
96619         in a slash. Code taken from lib/link.c.
96620         * doc/posix-functions/linkat.texi: Mention trailing slash bug.
96621         Reported by Rainer Tammer.
96623 2010-07-31  Bruno Haible  <bruno@clisp.org>
96625         Correctly determine whether pow is available in libc on AIX 7 with xlc.
96626         * m4/mathfunc.m4 (gl_MATHFUNC): Actually use the 'funcptr' variable.
96627         This disables an xlc optimization that was causing wrong test results.
96628         Reported by Rainer Tammer.
96630 2010-07-31  Bruno Haible  <bruno@clisp.org>
96632         iconv: Work around AIX 6.1..7.1 bug.
96633         * doc/posix-functions/iconv.texi: Mention AIX 6.1, 7.1 bug.
96634         * m4/iconv.m4 (AM_ICONV_LINK): Test against AIX 6.1, 7.1 bug. When
96635         cross-compiling, guess no on all versions of AIX.
96636         Reported by Rainer Tammer.
96638 2010-07-31  Bruno Haible  <bruno@clisp.org>
96640         readlink: Relax test a bit.
96641         * tests/test-readlink.h (test_readlink): Allow different errno value
96642         when readlink is called with a file name that ends in / and refers to
96643         a file.
96644         Suggested by Eric Blake.
96645         Reported by Rainer Tammer.
96647 2010-07-31  Bruno Haible  <bruno@clisp.org>
96649         copysign: Does not require -lm on glibc systems.
96650         * modules/copysign (configure.ac): Use gl_MATHFUNC, not
96651         gl_COMMON_DOUBLE_MATHFUNC.
96652         * m4/mathfunc.m4 (gl_COMMON_DOUBLE_MATHFUNC): Update comments.
96654 2010-07-31  Bruno Haible  <bruno@clisp.org>
96656         duplocale: Work around AIX 7.1 bug.
96657         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Let the test fail also when
96658         duplocale(LC_GLOBAL_LOCALE) returns (locale_t)0.
96659         * lib/duplocale.c (rpl_duplocale): Update comment.
96660         * doc/posix-functions/duplocale.texi: Mention the AIX 7.1 bug.
96661         Reported by Rainer Tammer.
96663 2010-07-30  Bruno Haible  <bruno@clisp.org>
96665         dirfd: Avoid link error on AIX 7.1.
96666         * lib/dirent.in.h (dirfd): Use modern idiom with REPLACE_DIRFD.
96667         * m4/dirfd.m4 (gl_FUNC_DIRFD): If the function is declared but does not
96668         exist, set REPLACE_DIRFD.
96669         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize REPLACE_DIRFD.
96670         * modules/dirent (Makefile.am): Substitute REPLACE_DIRFD.
96671         * doc/posix-functions/dirfd.texi: Update.
96672         Reported by Rainer Tammer.
96674 2010-07-30  Eric Blake  <eblake@redhat.com>
96676         strtod: next round of AIX fixes
96677         * lib/strtod.c (strtod): Work around AIX bug of parsing p with no
96678         exponent.
96679         * tests/test-strtod.c (main): Enhance tests.
96680         * doc/posix-functions/strtod.texi (strtod): Document next bug.
96681         Reported by Rainer Tammer.
96683         futimens: fix configure check
96684         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Use correct logic.
96685         Reported by Bruno Haible.
96687 2010-07-30  Bruno Haible  <bruno@clisp.org>
96689         getline: Update regarding AIX.
96690         * doc/posix-functions/getline.texi: Mention bug on AIX 7.1.
96691         Reported by Rainer Tammer.
96693 2010-07-30  Bruno Haible  <bruno@clisp.org>
96695         wcwidth: Drop replacement on AIX 7.
96696         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): When cross-compiling, guess yes on
96697         AIX 7.
96698         Reported by Rainer Tammer.
96700 2010-07-30  Bruno Haible  <bruno@clisp.org>
96702         strtok_r: Avoid triggering bug in AIX 7.1 xlc compiler.
96703         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Don't cast an invalid address to
96704         a 'char *'.
96705         Reported by Rainer Tammer.
96707 2010-07-30  Bruno Haible  <bruno@clisp.org>
96709         unlink: Update regarding AIX.
96710         * doc/posix-functions/unlink.texi: Mention bug on AIX 7.1.
96711         * m4/unlink.m4 (gl_FUNC_UNLINK): Update comment.
96712         Reported by Rainer Tammer.
96714 2010-07-30  Bruno Haible  <bruno@clisp.org>
96716         symlink: Update regarding AIX.
96717         * doc/posix-functions/symlink.texi: Mention bug on AIX 7.1.
96718         * m4/symlink.m4 (gl_FUNC_SYMLINK): Update comment.
96719         Reported by Rainer Tammer.
96721 2010-07-30  Bruno Haible  <bruno@clisp.org>
96723         strndup: Update regarding AIX.
96724         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, guess yes on
96725         AIX 7.
96726         Reported by Rainer Tammer.
96728 2010-07-30  Bruno Haible  <bruno@clisp.org>
96730         stat: Update regarding AIX.
96731         * doc/posix-functions/stat.texi: Mention bug on AIX 7.1.
96732         * m4/stat.m4 (gl_FUNC_STAT): Update comment.
96733         Reported by Rainer Tammer.
96735 2010-07-30  Bruno Haible  <bruno@clisp.org>
96737         truncl: Fix autoconf test.
96738         * m4/truncl.m4 (gl_FUNC_TRUNCL): Add TRUNCL_LIBM to LIBS while testing
96739         whether truncl works.
96740         Reported by Rainer Tammer.
96742 2010-07-30  Bruno Haible  <bruno@clisp.org>
96744         round: Update regarding AIX.
96745         * m4/round.m4 (gl_FUNC_ROUND): When cross-compiling, guess no on AIX 7.
96746         * doc/posix-functions/round.texi: Mention bug on AIX 7.1.
96747         Reported by Rainer Tammer.
96749 2010-07-30  Bruno Haible  <bruno@clisp.org>
96751         rename: Update regarding AIX.
96752         * doc/posix-functions/rename.texi: Mention bug on AIX 7.1.
96753         * m4/rename.m4 (gl_FUNC_RENAME): Update comment.
96754         Reported by Rainer Tammer.
96756 2010-07-30  Bruno Haible  <bruno@clisp.org>
96758         printf.m4: Update regarding AIX.
96759         * m4/printf.m4: Update comments regarding AIX.
96760         Reported by Rainer Tammer.
96762 2010-07-30  Bruno Haible  <bruno@clisp.org>
96764         iconv: Update regarding AIX.
96765         * m4/iconv.m4 (AM_ICONV_LINK): When cross-compiling, guess yes on
96766         AIX 7.
96767         Reported by Rainer Tammer.
96769 2010-07-30  Bruno Haible  <bruno@clisp.org>
96771         getopt: Update regarding AIX.
96772         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): When cross-compiling, guess
96773         no on AIX.
96774         * doc/posix-functions/getopt.texi: Mention that AIX has the optind bug.
96775         Reported by Rainer Tammer.
96777 2010-07-30  Bruno Haible  <bruno@clisp.org>
96779         ldexpl; Update regarding AIX.
96780         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): When cross-compiling, guess yes
96781         on AIX 7.
96782         Reported by Rainer Tammer.
96784 2010-07-30  Bruno Haible  <bruno@clisp.org>
96786         frexpl: Update regarding AIX.
96787         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): When cross-compiling, guess yes
96788         on AIX 7.
96789         Reported by Rainer Tammer.
96791 2010-07-30  Bruno Haible  <bruno@clisp.org>
96793         open, fopen: Update regarding AIX.
96794         * m4/open.m4 (gl_FUNC_OPEN): Adjust cross-compiling guess for AIX.
96795         * m4/fopen.m4 (gl_FUNC_FOPEN): Likewise.
96796         * doc/posix-functions/open.texi: Mention the trailing-slash bug on AIX.
96797         * doc/posix-functions/fopen.texi: Likewise.
96798         Reported by Rainer Tammer.
96800 2010-07-30  Bruno Haible  <bruno@clisp.org>
96802         chown: Update doc regarding AIX.
96803         * doc/posix-functions/chown.texi: Mention bug on AIX 7.1.
96804         * m4/chown.m4 (gl_FUNC_CHOWN): Update comment.
96805         Reported by Rainer Tammer.
96807 2010-07-30  Eric Blake  <eblake@redhat.com>
96809         strtod: fix bug in replacement function on AIX
96810         * lib/strtod.c (strtod): Special case broken "0x" parse in
96811         underlying strtod.
96812         * tests/test-strtod.c (main): Document AIX 7.1 bugs.
96813         * doc/posix-functions/strtod.texi (strtod): Likewise.
96814         Reported by Rainer Tammer.
96816 2010-07-30  Bruno Haible  <bruno@clisp.org>
96818         mbrlen: Fix cross-compilation guess for AIX.
96819         * m4/mbrlen.m4 (gl_MBRLEN_INCOMPLETE_STATE): Fix cross-compilation
96820         guess. Leftover from 2008-12-22.
96822 2010-07-30  Bruno Haible  <bruno@clisp.org>
96824         mbrtowc: Fix cross-compilation guess for AIX.
96825         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Fix cross-compilation
96826         guess. Leftover from 2008-12-21.
96828 2010-07-29  Peter O'Gorman  <pogma@thewrittenword.com>  (tiny change)
96830         init.sh: work around trap limitation of some shells
96831         * tests/init.sh (setup_): Move exit trap outside of shell function.
96833 2010-07-29  Eric Blake  <eblake@redhat.com>
96835         strtod: aid debugging
96836         * m4/strtod.m4(gl_FUNC_STRTOD): Use distinct exit status to aid
96837         understanding why strtod is rejected.
96839 2010-07-28  Bruno Haible  <bruno@clisp.org>
96841         unistr/u*-chr, unistr/u*-strchr: Fix link errors and warnings.
96842         * lib/unistr/u8-chr.c: Include <string.h>.
96843         * tests/unistr/test-u8-chr.c: Likewise.
96844         * tests/unistr/test-u16-chr.c: Likewise.
96845         * tests/unistr/test-u32-chr.c: Likewise.
96846         * tests/unistr/test-u8-strchr.c: Likewise.
96847         * tests/unistr/test-u16-strchr.c: Likewise.
96848         * tests/unistr/test-u32-strchr.c: Likewise.
96849         * modules/unistr/u8-chr-tests (Depends-on): Add unistr/u32-set.
96850         * modules/unistr/u16-chr-tests (Depends-on): Likewise.
96851         * modules/unistr/u8-strchr-tests (Depends-on): Likewise.
96852         * modules/unistr/u16-strchr-tests (Depends-on): Likewise.
96854 2010-07-28  Bruno Haible  <bruno@clisp.org>
96856         Use spaces for indentation, not tabs.
96857         * lib/**/*.[hcy] except lib/reg*.[hc]: Untabify.
96859 2010-07-27  Bruno Haible  <bruno@clisp.org>
96861         mbspcasecmp: Fix function specification.
96862         * lib/string.in.h (mbspcasecmp): Fix specification comment.
96863         * lib/mbspcasecmp.c (mbspcasecmp): Likewise.
96864         Reported by Eric Blake <eblake@redhat.com>.
96866 2010-07-26  Paul R. Eggert  <eggert@cs.ucla.edu>
96868         timespec: use cast and not conditional, as truncation isn't possible
96869         * lib/timespec.h (timespec_cmp): Use cast to pacify gcc -Wconversion
96870         instead of a conditional.  Comment about the situation in more detail.
96871         This undoes most of the 2009-10-29 patch.
96873 2010-07-23  Paolo Bonzini  <pbonzini@redhat.com>
96875         unistr/u8-chr, unistr/u8-strchr: use Boyer-Moore like algorithm.
96876         * lib/unistr/u8-chr.c: Add Boyer-Moore like operation.
96877         * lib/unistr/u8-strchr.c: Likewise.
96878         * modules/unistr/u8-chr: Depend on memchr.
96880         unistr/u*-strchr: add tests
96881         * modules/unistr/u8-strchr-tests: New file.
96882         * modules/unistr/u16-strchr-tests: New file.
96883         * modules/unistr/u32-strchr-tests: New file.
96884         * tests/unistr/test-strchr.h: New file.
96885         * tests/unistr/test-u8-strchr.c: New file.
96886         * tests/unistr/test-u16-strchr.c: New file.
96887         * tests/unistr/test-u32-strchr.c: New file.
96889         unistr/u*-chr: test multibyte sequences more
96890         * tests/unistr/test-chr.h: Do complete testing of the characters in the
96891         test vector.
96892         * tests/unistr/test-u8-chr.c (U_UCTOMB): Define.
96893         * tests/unistr/test-u16-chr.c (U_UCTOMB): Likewise.
96894         * tests/unistr/test-u32-chr.c (U_UCTOMB): Likewise.
96896         unistr/u*-chr: test multibyte sequences
96897         * tests/unistr/test-chr.h: Put characters above 0-127 in the test input.
96899         unistr/u*-chr: prepare for multibyte tests
96900         * modules/unistr/u8-chr-tests: Depend on u32-to-u8.
96901         * modules/unistr/u16-chr-tests: Depend on u32-to-u16.
96902         * tests/unistr/test-chr.h: Build initial version as UCS-4 then convert.
96903         * tests/unistr/test-u8-chr.c (U32_TO_U): Define.
96904         * tests/unistr/test-u16-chr.c (U32_TO_U): Likewise.
96905         * tests/unistr/test-u32-chr.c (U32_TO_U): Likewise.
96907 2010-07-18  Bruno Haible  <bruno@clisp.org>
96909         unistr/u8-strchr: Optimize non-ASCII argument case.
96910         * lib/unistr/u8-strchr.c (u8_strchr): Compare the last byte first,
96911         because the first byte often matches anyway.
96912         Reported by Pádraig Brady <P@draigbrady.com>.
96914 2010-07-15  Karl Berry  <karl@gnu.org>
96916         * config/srclist.txt (fdl.texi): only one copy, from gnustandards.
96918 2010-07-14  Paul R. Eggert  <eggert@cs.ucla.edu>
96920         getcwd: on Solaris, work better if ancestors are inaccessible
96921         * lib/getcwd.c (__getcwd): If getcwd returns EINVAL for zero
96922         buffer and size, try again with a large buffer.  This works better
96923         on Solaris, since its getcwd succeeds even if the path to the root
96924         is inaccessible, and this is helpful in common cases such as .zfs
96925         hidden directories.  Problem reported by J Chapman Flack in
96926         http://lists.gnu.org/r/bug-tar/2010-06/msg00000.html
96927         Use system getcwd if it's declared, not merely if it's partly
96928         working; use the partly-working test only to avoid needless effort
96929         if the system getcwd fails.
96930         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Omit
96931         comment that was already obsolete and is now even more obsolete.
96932         * modules/getcwd (Depends-on): Depend on strdup, since __getcwd
96933         now might call strdup.
96935 2010-07-13  Paul R. Eggert  <eggert@cs.ucla.edu>
96937         pthread: Add enough so that coreutils/src/sort.c compiles.
96938         * lib/pthread.in.h: Add self to author comment.  Conditionalize on
96939         _GL_PTHREAD_H, not PTHREAD_H_, for consistency with the rest of
96940         gnulib. Include <sched.h> and <time.h>, as per POSIX.
96941         Include <sys/types.h>, in case it defines pthread_t.
96942         (pthread_t, pthread_attr_t, pthread_barrier_t, pthread_barrierattr_t):
96943         (pthread_cond_t, pthread_condattr_t, pthread_key_t, pthread_mutex_t):
96944         (pthread_mutexattr_t, pthread_once_t, pthread_rwlock_t):
96945         (pthread_rwlockattr_t, pthread_spinlock_t):
96946         New typedefs, if HAVE_PTHREAD_T is not defined.
96947         (PTHREAD_COND_INITIALIZER, PTHREAD_MUTEX_INITIALIZER):
96948         (PTHREAD_ONCE_INIT, PTHREAD_RWLOCK_INITIALIZER):
96949         (PTHREAD_BARRIER_SERIAL_THREAD, PTHREAD_CANCEL_DEFERRED):
96950         (PTHREAD_CANCEL_ASYNCHRONOUS, PTHREAD_CANCEL_ENABLE):
96951         (PTHREAD_CANCEL_DISABLE, PTHREAD_CANCELED, PTHREAD_CREATE_JOINABLE):
96952         (PTHREAD_CREATE_DETACHED, PTHREAD_INHERIT_SCHED):
96953         (PTHREAD_EXPLICIT_SCHED, PTHREAD_MUTEX_DEFAULT, PTHREAD_MUTEX_NORMAL):
96954         (PTHREAD_MUTEX_ERRORCHECK, PTHREAD_MUTEX_RECURSIVE):
96955         (PTHREAD_MUTEX_STALLED, PTHREAD_MUTEX_ROBUST, PTHREAD_PRIO_NONE):
96956         (PTHREAD_PRIO_INHERIT, PTHREAD_PRIO_PROTECT, PTHREAD_PROCESS_PRIVATE):
96957         (PTHREAD_PROCESS_SHARED, PTHREAD_SCOPE_SYSTEM, PTHREAD_SCOPE_PROCESS):
96958         New macros.
96959         (pthread_cond_destroy, pthread_cond_init, pthread_cond_signal):
96960         (pthread_cond_wait, pthread_exit, pthread_mutex_destroy):
96961         (pthread_mutex_init, pthread_mutex_lock, pthread_mutex_unlock):
96962         (pthread_spin_init, pthread_spin_lock, pthread_spin_trylock);
96963         (pthread_spin_unlock): New dummy functions.
96964         (pthread_create): Return EAGAIN; don't set errno.
96965         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for pthread_t, and
96966         require AC_C_INLINE.
96967         * modules/pthread (Depends-on): Add sched, time.
96968         (pthread.h): Use AM_V_GEN.
96970 2010-07-13  Bruno Haible  <bruno@clisp.org>
96972         striconveh: Don't malloc memory if the result buffer is sufficient.
96973         * lib/striconveh.c (mem_cd_iconveh_internal): Use the provided result
96974         buffer if its size is sufficient.
96975         Reported by Ludovic Courtès <ludo@gnu.org>.
96977 2010-07-13  Bruno Haible  <bruno@clisp.org>
96979         strtod: Add safety check.
96980         * lib/strtod.c (ldexp): Abort if this dummy replacement gets called.
96982 2010-07-12  Bruno Haible  <bruno@clisp.org>
96984         Unify tests that set gl_cv_func_ldexpl_no_libm.
96985         * m4/ldexpl.m4 (gl_CHECK_LDEXPL_NO_LIBM): New macro, extracted from
96986         gl_FUNC_LDEXPL.
96987         (gl_FUNC_LDEXPL): Invoke it.
96988         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
96990 2010-07-12  Bruno Haible  <bruno@clisp.org>
96992         Unify tests that set gl_cv_func_ldexp_no_libm.
96993         * m4/ldexp.m4: New file, based on m4/mathfunc.m4.
96994         * m4/strtod.m4 (gl_PREREQ_STRTOD): Require gl_CHECK_LDEXP_NO_LIBM.
96995         * modules/ldexp (Files): Remove m4/mathfunc.m4. Add m4/ldexp.m4.
96996         (configure.ac): Simply invoke gl_FUNC_LDEXP.
96997         * modules/strtod (Files): Add m4/ldexp.m4.
96999 2010-07-12  Bruno Haible  <bruno@clisp.org>
97001         Unify tests that set gl_cv_func_frexpl_no_libm.
97002         * m4/frexpl.m4 (gl_CHECK_FREXPL_NO_LIBM): New macro, extracted from
97003         gl_FUNC_FREXPL_NO_LIBM.
97004         (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): Invoke it.
97005         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
97007 2010-07-12  Bruno Haible  <bruno@clisp.org>
97009         Unify tests that set gl_cv_func_frexp_no_libm.
97010         * m4/frexp.m4 (gl_CHECK_FREXP_NO_LIBM): New macro, extracted from
97011         gl_FUNC_FREXP_NO_LIBM.
97012         (gl_FUNC_FREXP, gl_FUNC_FREXP_NO_LIBM): Require it.
97013         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Likewise.
97015 2010-07-12  Paul R. Eggert  <eggert@cs.ucla.edu>
97017         memcoll: clarify sizes versus lengths, document better, and tweak perf
97018         * lib/memcoll.c (strcoll_loop, memcoll0):
97019         Improve quality of descriptive comments.  Name variables
97020         consistently as to whether they are lengths (which do not include
97021         terminating null) versus sizes (which do).
97022         * lib/xmemcoll.c (xmemcoll0): Likewise.
97023         * lib/memcoll.c (strcoll_loop): Tweak the way that the diff is
97024         returned when s1size == 0; this is easier to compile and saves
97025         about 17% of memcoll's code space on x86-64 with GCC 4.1.2.
97027 2010-07-12  Bruno Haible  <bruno@clisp.org>
97029         Tests for module '_Exit'.
97030         * modules/_Exit-tests: New file.
97031         * tests/test-_Exit.sh: New file.
97032         * tests/test-_Exit.c: New file.
97034         New module '_Exit'.
97035         * lib/stdlib.in.h (__attribute__): New macro.
97036         (_Exit): New declaration.
97037         * lib/_Exit.c: New file.
97038         * m4/_Exit.m4: New file.
97039         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether _Exit is declared.
97040         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB__EXIT and HAVE__EXIT.
97041         * modules/stdlib (Makefile.am): Substitute GNULIB__EXIT and HAVE__EXIT.
97042         * modules/_Exit: New file.
97043         * tests/test-stdlib-c++.cc (_Exit): Check signature.
97044         * doc/posix-functions/_Exit_C99.texi: Mention the new module.
97046 2010-07-12  Paul R. Eggert  <eggert@cs.ucla.edu>
97048         strtod: make it more-accurate typically, and don't require libm
97049         * lib/strtod.c (_GL_ARG_NONNULL): Remove; no longer needed.
97050         Include limits.h.  Don't include string.h.
97051         (HAVE_LDEXP_IN_LIBC, HAVE_RAW_DECL_STRTOD): Define to 0 if not defined.
97052         (locale_isspace): New function, so that no casts are needed to
97053         check whether *s is a space.
97054         (ldexp): Provide an unused dummy if not available.
97055         (scale_radix_exp, parse_number, underlying_strtod): New functions.
97056         (strtod): Use them.  This implementation prefers to use the
97057         underlying strtod if available, falling back on our own code
97058         only to fix known bugs.  This is more likely to produce an
97059         accurate result.  Also, it avoids the use of libm functions.
97060         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't invoke _AC_LIBOBJ_STRTOD;
97061         no longer needed.  Invoke AC_LIBOBJ([strtod]); don't know why this
97062         was absent, but it caused a test failure with coreutils.
97063         (gl_PREREQ_STRTOD): Check wither ldexp can be used without linking
97064         with libm.
97065         * modules/strtod (Makefile.am, Link): libm is no longer needed.
97066         * modules/strtod-tests (Makefile.am): Likewise.
97068 2010-07-11  Pádraig Brady  <P@draigBrady.com>
97069             Bruno Haible  <bruno@clisp.org>
97071         unistr/u8-strchr: Optimize ASCII argument case.
97072         * lib/unistr/u8-strchr.c (u8_strchr): For ASCII arguments, use strchr.
97074 2010-07-08  Paul Eggert  <eggert@cs.ucla.edu>
97076         (x)memcoll: minor tweaks
97077         * lib/memcoll.c (strcoll_loop): Prefer the style where 'const'
97078         is after the type that it qualifies.
97079         (memcoll0): Likewise.
97080         * lib/memcoll.h (memcoll0): Likewise.
97081         * lib/xmemcoll.c (collate_error, xmemcoll0): Likewise.
97082         * lib/xmemcoll.h (xmemcoll0): Likewise.
97083         * lib/memcoll.c (memcoll0): Correct the comment.  This function
97084         differs from memcoll in that the NUL byte is part of the argument.
97085         Omit the abort-checks, as performance is a real issue here.  Plus,
97086         the checks were wrong anyway (an off-by-one error).  Omit local
97087         variable 'diff', as it's a bit clearer that way.
97088         * m4/memcoll.m4 (gl_MEMCOLL): Omit AC_FUNC_STRCOLL, as it's
97089         no longer needed.
97091 2010-07-08  Chen Guo  <chenguo4@yahoo.com>
97093         (x)memcoll: speedup when input is known to be NUL delimited
97094         * lib/memcoll.c: Include stdlib.
97095         (memcoll0): New function.
97096         (strcoll_loop): New function, refactored for use in both memcoll
97097         and memcoll0.
97098         * lib/memcoll.h (memcoll0): Add prototype.
97099         * lib/xmemcoll.c (xmemcoll0): New function.
97100         (collate_error): New function, refactored for use in both xmemcoll
97101         and xmemcoll0.
97102         * lib/xmemcoll.h (xmemcoll0): Add prototype.
97103         * m4/memcoll.m4: add inline invocation.
97105 2010-07-06  Pádraig Brady  <P@draigBrady.com>
97107         * build-aux/bootstrap: Remove any local translations
97108         from the translation project synchronization directory,
97109         so that local only translations are not distributed.
97111 2010-07-04  Bruno Haible  <bruno@clisp.org>
97113         fsusage: Clarify which code applies to which platforms.
97114         * m4/fsusage.m4 (gl_FSUSAGE): Clarify which test succeeds on which
97115         platform.
97116         * lib/fsusage.c (get_fs_usage): Likewise.
97118 2010-07-04  Bruno Haible  <bruno@clisp.org>
97120         havelib: Fix bug when AC_LIB_FROMPACKAGE is used more than twice.
97121         * m4/lib-link.m4 (AC_LIB_FROMPACKAGE): Use m4_defn.
97122         Reported by Martin Lambers <marlam@marlam.de>.
97124 2010-07-04  Jim Meyering  <meyering@redhat.com>
97126         hash: once again explicitly disallow insertion of NULL
97127         * lib/hash.c (hash_insert0): Reinstate just-removed test:
97128         inserting a NULL pointer cannot work with these functions.
97129         Add a comment with details.
97130         This reverts part of the 2010-07-01 commit, 5bef1a35
97131         "hash: extend module to deal with non-pointer keys".
97133 2010-07-01  Bruno Haible  <bruno@clisp.org>
97135         stdbool: Update doc.
97136         * doc/posix-headers/stdbool.texi: Mention OpenBSD bug.
97137         Info from Christian Weisgerber <naddy@mips.inka.de>.
97139 2010-07-01  Jim Meyering  <meyering@redhat.com>
97141         hash: extend module to deal with non-pointer keys
97142         * lib/hash.c (hash_insert0): New interface, much like hash_insert
97143         but that allows insertion of non-pointer entries.
97144         Do not disallow an ENTRY value of NULL.
97145         (hash_insert): This is now just a thin wrapper.  Call hash_insert0.
97146         * lib/hash.h (hash_insert0): Declare.
97148 2010-07-01  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
97150         gettext: Use AC_GNU_SOURCE as a fallback for AC_USE_SYSTEM_EXTENSIONS.
97151         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): When AC_USE_SYSTEM_EXTENSIONS is
97152         not present (i.e. with autoconf 2.59 and when using gettextize, not
97153         gnulib), require AC_GNU_SOURCE instead.
97155 2010-07-01  Ian Beckwith  <ianb@erislabs.net>
97157         idpriv-drop: Fix tests.
97158         * tests/test-idpriv-drop.su.sh: Refer to the test-idpriv-drop program,
97159         not to the test-idpriv-droptemp program.
97161 2010-06-29  Bruno Haible  <bruno@clisp.org>
97163         string: Fix syntax error with g++ 2.96.
97164         * lib/string.in.h (__pure__): Remove definition.
97165         (_GL_ATTRIBUTE_PURE): New macro.
97166         (memchr, memmem, memrchr, rawmemchr, strchrnul, strnlen, strpbrk,
97167         strstr, strcasestr): Use it instead of __attribute__ ((__pure__)).
97168         Reported by Christian Weisgerber <naddy@mips.inka.de>.
97170 2010-06-28  Ian Beckwith  <ianb@erislabs.net>
97172         unitypes: Fix bug introduced on 2010-05-18.
97173         * modules/unitypes (Files): Really add m4/libunistring-base.m4.
97175 2010-06-22  Eric Blake  <eblake@redhat.com>
97177         memmem: slight optimization
97178         * lib/str-two-way.h (critical_factorization): Update comments.
97179         Reduce work during factorization phase.
97180         Reported by Carlos Bueno <carlos@bueno.org>.
97182 2010-06-21  Bruno Haible  <bruno@clisp.org>
97184         Fix HAVE_CALLOC_POSIX misnomer.
97185         * lib/stdlib.in.h (calloc): Use REPLACE_CALLOC instead of
97186         !HAVE_CALLOC_POSIX.
97187         * m4/calloc.m4 (gl_REPLACE_CALLOC): Set REPLACE_CALLOC instead of
97188         HAVE_CALLOC_POSIX.
97189         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_CALLOC
97190         instead of HAVE_CALLOC_POSIX.
97191         * modules/stdlib (Makefile.am): Substitute REPLACE_CALLOC instead of
97192         HAVE_CALLOC_POSIX.
97194         Use modern idiom for calloc() replacement.
97195         * modules/calloc (configure.ac): Invoke gl_FUNC_CALLOC_GNU instead of
97196         AC_FUNC_CALLOC.
97197         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Renamed from AC_FUNC_CALLOC.
97198         Require gl_STDLIB_H_DEFAULTS. Invoke gl_REPLACE_CALLOC.
97199         (gl_FUNC_CALLOC_POSIX): Rely on gl_STDLIB_H_DEFAULTS to initialize
97200         HAVE_CALLOC_POSIX. Invoke gl_REPLACE_CALLOC.
97201         (gl_REPLACE_CALLOC): New macro.
97203 2010-06-21  Bruno Haible  <bruno@clisp.org>
97205         Fix HAVE_REALLOC_POSIX misnomer.
97206         * lib/stdlib.in.h (realloc): Use REPLACE_REALLOC instead of
97207         !HAVE_REALLOC_POSIX.
97208         * m4/realloc.m4 (gl_REPLACE_REALLOC): Set REPLACE_REALLOC instead of
97209         HAVE_REALLOC_POSIX.
97210         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_REALLOC
97211         instead of HAVE_REALLOC_POSIX.
97212         * modules/stdlib (Makefile.am): Substitute REPLACE_REALLOC instead of
97213         HAVE_REALLOC_POSIX.
97215         Use modern idiom for realloc() replacement.
97216         * modules/realloc (configure.ac): Invoke gl_FUNC_REALLOC_GNU instead of
97217         AC_FUNC_REALLOC.
97218         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): New macro, mostly copied from
97219         Autoconf's AC_FUNC_REALLOC.
97220         (gl_FUNC_REALLOC_POSIX): Rely on gl_STDLIB_H_DEFAULTS to initialize
97221         HAVE_REALLOC_POSIX. Invoke gl_REPLACE_REALLOC.
97222         (gl_REPLACE_REALLOC): New macro.
97223         Reported by Richard Lloyd <richard.lloyd@connectinternetsolutions.com>.
97225 2010-06-21  Bruno Haible  <bruno@clisp.org>
97227         Fix HAVE_MALLOC_POSIX misnomer.
97228         * lib/stdlib.in.h (malloc): Use REPLACE_MALLOC instead of
97229         !HAVE_MALLOC_POSIX.
97230         * m4/malloc.m4 (gl_REPLACE_MALLOC): Set REPLACE_MALLOC instead of
97231         HAVE_MALLOC_POSIX.
97232         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MALLOC
97233         instead of HAVE_MALLOC_POSIX.
97234         * modules/stdlib (Makefile.am): Substitute REPLACE_MALLOC instead of
97235         HAVE_MALLOC_POSIX.
97237         Use modern idiom for malloc() replacement.
97238         * modules/malloc (configure.ac): Invoke gl_FUNC_MALLOC_GNU instead of
97239         AC_FUNC_MALLOC.
97240         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): New macro, mostly copied from
97241         Autoconf's AC_FUNC_MALLOC.
97242         (gl_FUNC_MALLOC_POSIX): Rely on gl_STDLIB_H_DEFAULTS to initialize
97243         HAVE_MALLOC_POSIX. Invoke gl_REPLACE_MALLOC.
97244         (gl_REPLACE_MALLOC): New macro.
97245         Reported by Richard Lloyd <richard.lloyd@connectinternetsolutions.com>.
97247 2010-06-20  Richard Lloyd  <richard.lloyd@connectinternetsolutions.com>
97249         stdio.in.h: fix compilation failure when using HP-UX 11's C compiler
97250         * lib/stdio.in.h: Remove excess _GL_CXXALIAS_RPL macro argument.
97251         This macro takes 3 arguments, not 4.
97253 2010-06-15  Giuseppe Scrivano  <gscrivano@gnu.org>
97255         ipv6: fix detection under mingw
97256         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Include <ws2tcpip.h> for struct
97257         in6_addr.
97259 2010-06-14  Ben Pfaff  <blp@cs.stanford.edu>
97261         * m4/strtod.m4 (gl_FUNC_STRTOD): Factor out common code.  Assume
97262         that strtod() works when cross-compiling to a glibc version known
97263         to work.
97265 2010-06-15  Bruno Haible  <bruno@clisp.org>
97267         * m4/strtod.m4 (gl_FUNC_STRTOD): Stop using AC_FUNC_STRTOD.
97269 2010-06-15  René Berber  <r.berber@computer.org>  (tiny change)
97271         select: Correct timeout.
97272         * lib/select.c (rpl_select): Compute wait_timeout correctly.
97274 2010-06-14  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
97276         git-version-gen: init shell var to avoid env var influence
97277         * build-aux/git-version-gen (v): Init shell var to empty.
97279 2010-06-14  Paul Eggert  <eggert@cs.ucla.edu>
97281         priv-set: Don't assume that priv.h exists merely because getppriv does.
97282         See Jan Andersen's bug report about AIX 5L in
97283         http://lists.gnu.org/r/bug-tar/2010-06/msg00019.html
97284         * m4/priv-set.m4 (gl_PRIV_SET): Check for priv.h.
97285         * lib/priv-set.c: Do nothing unless HAVE_PRIV_H.
97286         * lib/priv-set.h: Likewise.
97287         * tests/test-priv-set.c: Likewise.
97289 2010-06-13  Bruno Haible  <bruno@clisp.org>
97291         relocatable: Make it easier to test whether to install wrappers.
97292         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): New automake conditional
97293         RELOCATABLE_VIA_WRAPPER.
97295 2010-06-13  Bruno Haible  <bruno@clisp.org>
97297         gnulib-tool: Display specified modules and dependencies differently.
97298         * gnulib-tool (func_show_module_list): New function.
97299         (func_import, func_create_testdir): Invoke it.
97300         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
97302 2010-06-13  Bruno Haible  <bruno@clisp.org>
97304         gnulib-tool: Align code of func_import and func_create_testdir.
97305         * gnulib-tool (func_create_testdir): Rename variable saved_modules to
97306         specified_modules.
97308 2010-06-12  Jim Meyering  <meyering@redhat.com>
97310         test-inttostr: avoid spurious failure on Solaris 9
97311         * tests/test-inttostr.c (main): Skip the test when snprintf fails
97312         to accept "%ju".  Reported by Bruno Haible.
97314 2010-06-11  Jim Meyering  <meyering@redhat.com>
97316         test-sys_socket: mark variables as used more readably
97317         * tests/test-sys_socket.c (main): Mark otherwise unused variables
97318         as "used" explicitly via (void) statement casts.  This is more
97319         readable than using them in an artificial return expression.
97320         Suggestion from Bruno Haible.
97322 2010-06-11  Bruno Haible  <bruno@clisp.org>
97324         Avoid some more warnings from "gcc -Wwrite-strings".
97325         * tests/test-argp.c (test_optional): Change 5th and 6th argument type
97326         to 'const char *'.
97327         * tests/test-c-strstr.c (main): Add 'const' to variable declaration.
97328         * tests/test-c-strcasestr.c (main): Likewise.
97329         * tests/test-mbscasestr1.c (main): Likewise.
97330         * tests/test-mbscasestr2.c (main): Likewise.
97331         * tests/test-memmem.c (main): Likewise.
97332         * tests/test-strstr.c (main): Likewise.
97333         * tests/test-strcasestr.c (main): Likewise.
97335 2010-06-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
97337         init.sh: change framework_failure_ to fail with status 99, not 1
97338         * tests/init.sh (framework_failure_): Exit 99, not 1.  This informs
97339         automake's parallel-tests rule that this is an unexpected failure,
97340         even if the test is listed in XFAIL_TESTS.
97342 2010-06-11  Jim Meyering  <meyering@redhat.com>
97344         test-inttostr: avoid warnings about 4-6KB literal strings
97345         * tests/test-inttostr.c: Don't use <assert.h>.  Instead, ...
97346         Include "macros.h", for its definition of ASSERT.
97347         (CK): s/assert/ASSERT/
97348         * modules/inttostr-tests (Files): Add macros.h.
97350         init.sh: don't use $ME_ or skip_ before they are defined
97351         * tests/init.sh: Hoist definitions of $ME_ and skip_ to precede
97352         their first uses.  Also hoist their companions: warn_, fail_,
97353         framework_failure_, $stderr_fileno.  Prompted by a patch from
97354         Stefano Lattarini.
97356         test-sys_socket: avoid set-but-not-used warnings from gcc
97357         * tests/test-sys_socket.c (main): Use "i" and "x", in order to
97358         avoid warning about set-but-not-used variables.
97360         test-xvasprintf: avoid 'const' discard warnings
97361         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Use
97362         "const" when assigning from literal strings.
97363         (test_xasprintf): Add "void" in function argument list to placate
97364         -Wstrict-prototypes and to be consistent with test_xvasprintf above.
97366         tests: avoid compilation warnings in argmatch and exclude tests...
97367         in packages that define ARGMATCH_DIE_DECL, like coreutils.
97368         * tests/test-exclude.c [ARGMATCH_DIE_DECL]: Also declare the function.
97369         Since it always exits, declare with the "noreturn" attribute.
97370         * tests/test-argmatch.c: Likewise.
97372         tests: avoid 'const' discard warnings in mbsstr tests
97373         * tests/test-mbsstr1.c (main): Add "const" to avoid trivial warning.
97374         * tests/test-mbsstr2.c (main): Likewise.
97376         test-verify: avoid warning from gcc's -Wmissing-declarations
97377         * tests/test-verify.c (function): Declare to be static.
97379         test-inttostr.c: include <string.h> for use of strcmp
97380         * tests/test-inttostr.c: Include <string.h> for strcmp declaration.
97382         test-linkat: avoid failed assertion on "other" architectures
97383         * tests/test-linkat.c: Include <sys/stat.h>, for declarations of stat,
97384         lstat, mkdir.  Patch by John Rigby, to fix FTBFS on armel, powerpc,
97385         sparc: https://bugs.launchpad.net/bugs/591968
97387 2010-06-11  Jim Meyering  <meyering@redhat.com>
97389         printf.m4: avoid autoconf's "Expanded Before Required" warning
97390         * m4/printf.m4 (gl_SNPRINTF_RETVAL_C99): Define using AC_DEFUN_ONCE,
97391         rather than AC_DEFUN, to avoid the classic "Expanded Before Required"
97392         autoconf warning.
97394 2010-06-10  Ben Pfaff  <blp@cs.stanford.edu>
97396         Replacement header templates are now named with ".in", not "_".
97397         * doc/gnulib-intro.texi: Correct.
97399 2010-06-10  Jim Meyering  <meyering@redhat.com>
97401         inttostr-tests: depend on snprintf, not snprintf-posix
97402         * modules/inttostr-tests (Depends-on): Depend on snprintf, not
97403         snprintf-posix, to avoid this aclocal failure:
97404           missing file gnulib-tests/vasnprintf.c
97405           configure.ac:45: error: expected source file, required through \
97406           AC_LIBSOURCES, not found
97408 2010-06-10  Jim Meyering  <meyering@redhat.com>
97410         inttostr: add a new function, inttostr, and tests
97411         The namesake function was not available.  The existence of the
97412         template file, inttostr.c makes its addition nontrivial.
97413         * lib/anytostr.c: Rename from inttostr.c.
97414         (anytostr): Rename from inttostr.
97415         * lib/inttostr.c: New file.
97416         * modules/inttostr (Files): Add anytostr.c.
97417         (Makefile.am): Set lib_SOURCES instead of ...
97418         * m4/inttostr.m4: Remove uses of AC_LIBOBJ.
97419         * lib/imaxtostr.c: Update use.  s/inttostr/anytostr/
97420         * lib/offtostr.c: Likewise.
97421         * lib/uinttostr.c: Likewise.
97422         * lib/umaxtostr.c: Likewise.
97423         * modules/inttostr-tests: New file.
97424         * tests/test-inttostr.c: New file.  Test these functions.
97426 2010-06-09  Ben Pfaff  <blp@cs.stanford.edu>
97427             Bruno Haible  <bruno@clisp.org>
97429         Add "Extending Gnulib" chapter to manual.
97430         * doc/gnulib.texi (Writing Modules): Add cross-reference to new
97431         chapter.
97432         (Extending Gnulib): New chapter.
97433         * doc/gnulib-intro.texi (Openness): Add cross-reference to new
97434         chapter.
97436 2010-06-09  Bruno Haible  <bruno@clisp.org>
97438         Avoid relocwrapper link errors due to gnulib replacement functions.
97439         * lib/areadlink.c: Use the system's malloc, realloc functions.
97440         (areadlink): Set errno to ENOMEM explicitly.
97441         * modules/areadlink (Depends-on): Remove malloc-posix.
97442         Reported by Ben Pfaff <blp@cs.stanford.edu>.
97444 2010-06-09  Bruno Haible  <bruno@clisp.org>
97446         Avoid relocwrapper link errors due to gnulib replacement functions.
97447         * lib/canonicalize-lgpl.c: Use the system's malloc function.
97448         * lib/malloca.c: Likewise.
97449         * lib/relocatable.c: Likewise.
97450         * lib/progreloc.c: Use the system's malloc, sprintf functions.
97451         * lib/relocwrapper.c: Use the system's fprintf, malloc functions.
97452         * lib/setenv.c: Use the system's malloc, realloc functions.
97453         * lib/strerror.c: Use the system's sprintf function.
97454         Reported by Ben Pfaff <blp@cs.stanford.edu>.
97456 2010-06-04  Bruno Haible  <bruno@clisp.org>
97458         Prefer documented low-level autoconf macro names.
97459         * m4/lib-link.m4: Use m4_translit instead of translit.
97460         * m4/environ.m4: Likewise.
97461         * m4/mathfunc.m4: Likewise.
97462         * m4/onceonly.m4: Likewise.
97463         * m4/stdint.m4: Likewise.
97464         Suggested by Eric Blake.
97466 2010-06-04  Martin Lambers  <marlam@marlam.de>
97467             Bruno Haible  <bruno@clisp.org>
97469         havelib: Allow library names with '+' characters.
97470         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
97471         AC_LIB_FROMPACKAGE, AC_LIB_LINKFLAGS_BODY): Convert '+' in name to '_'.
97473 2010-06-09  Bruno Haible  <bruno@clisp.org>
97475         Module setenv does not depend on 'malloc-posix', 'realloc-posix'.
97476         * lib/setenv.c (__add_to_environ): Set errno to ENOMEM when malloc or
97477         realloc failed.
97479 2010-06-08  Peter Simons  <simons@cryp.to>
97481         maint.mk: make the news-check rule more configurable
97482         * top/maint.mk (news-check-lines-spec): New variable.
97483         (news-check): Use "sed -n 1,10p" in place of "head".
97485 2010-06-07  Jim Meyering  <meyering@redhat.com>
97487         do-release-commit-and-tag: fix typo in --help
97488         * build-aux/do-release-commit-and-tag (Usage): Fix typo in --help.
97490         regex: avoid new dead-code warning with gcc-4.6.0
97491         * lib/regex_internal.c (re_string_reconstruct): #if-0-out a dead
97492         if-block containing a while-loop.  It's been unused for at least
97493         5 years.
97495 2010-06-05  Bruno Haible  <bruno@clisp.org>
97497         * doc/posix-functions/strcoll.texi: Mention Solaris limitation.
97498         Reported by River Tarnell <river.tarnell@wikimedia.de> via Eric Blake.
97500 2010-06-04  Bruno Haible  <bruno@clisp.org>
97502         Update to GNU gettext 0.18.1.
97503         * modules/gettext (configure.ac): Require gettext infrastructure from
97504         version 0.18.1.
97506 2010-06-03  Bruno Haible  <bruno@clisp.org>
97508         Don't use AC_LIBOBJ with file names in subdirectories.
97509         * m4/libunistring-base.m4 (gl_LIBUNISTRING_MODULE): Renamed from
97510         gl_LIBUNISTRING_LIBSOURCE. Take a module name as argument, not a file
97511         name. Define an automake conditional. Don't invoke AC_LIBOBJ.
97512         * m4/libunistring.m4 (gl_LIBUNISTRING): Update AC_BEFORE invocation.
97513         * modules/uni*/* (configure.ac): Use gl_LIBUNISTRING_MODULE instead of
97514         gl_LIBUNISTRING_LIBSOURCE.
97515         (Makefile.am): Augment lib_SOURCES here, conditionally.
97516         * NEWS: Drop requirement for Automake option 'subdir-objects'.
97518 2010-06-03  Bruno Haible  <bruno@clisp.org>
97520         Simplify gl_LIBUNISTRING_VERSION_CMP expansion.
97521         * m4/libunistring-base.m4 (gl_LIBUNISTRING_VERSION_CMP): Ensure
97522         expansion does not end with a newline.
97523         (gl_LIBUNISTRING_LIBSOURCE, gl_LIBUNISTRING_LIBHEADER): Avoid
97524         unnecessary newline.
97526 2010-06-03  Bruno Haible  <bruno@clisp.org>
97528         Reduce dependencies.
97529         * tests/test-quotearg.h: New file, extracted from
97530         tests/test-quotearg.c.
97531         * tests/test-quotearg-simple.c: New file, extracted from
97532         tests/test-quotearg.c.
97533         * tests/test-quotearg.c: Don't include <ctype.h>.
97534         (struct result_strings, struct result_groups, LQ, RQ, LQ_ENC, RQ_ENC,
97535         RQ_ESC, inputs, compare, use_quotearg_buffer, use_quotearg,
97536         use_quote_double_quotes, use_quotearg_colon): Moved to
97537         tests/test-quotearg.h.
97538         (results_g, flag_results, custom_quotes, custom_results): Moved
97539         to tests/test-quotearg-simple.c.
97540         (main): Moved the part that does not depend on gettext to
97541         tests/test-quotearg-simple.c. Return 77 if the test cannot be
97542         performed.
97543         * modules/quotearg-simple: New file.
97544         * modules/quotearg-simple-tests: New file.
97545         * modules/quotearg (Depends-on): Add quotearg-simple.
97546         * modules/quotearg-tests (Status): Mark as gettext-dependent-test.
97547         (Files): Add tests/test-quotearg.h.
97548         Reported by Paolo Bonzini.
97550 2010-06-03  Bruno Haible  <bruno@clisp.org>
97552         Reduce dependencies.
97553         * modules/acl (Depends-on): Add gettext-h. Remove gettext.
97555 2010-06-03  Bruno Haible  <bruno@clisp.org>
97557         time: Undefine more broken macros.
97558         * lib/time.in.h: Undefine broken localtime_r and gmtime_r macros only
97559         for pthread-win32. Undefine also asctime_r, ctime_r, rand_r, strtok_r.
97560         Reported by Eric Blake.
97562 2010-06-03  Bruno Haible  <bruno@clisp.org>
97564         Choose among AC_DEFUN_ONCE, AC_DEFUN in a way that aclocal understands.
97565         * m4/iconv.m4 (gl_iconv_AC_DEFUN): New macro.
97566         (AM_ICONV): Define it through gl_iconv_AC_DEFUN.
97567         * m4/libunistring.m4 (gl_libunistring_AC_DEFUN): New macro.
97568         (gl_LIBUNISTRING): Define it through gl_libunistring_AC_DEFUN.
97569         Reported by Ludovic Courtès <ludo@gnu.org>.
97571 2010-06-02  Eric Blake  <eblake@redhat.com>
97573         time: work with mingw + pthreads-win32 library
97574         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Set new variable
97575         if timespec is defined only in pthread.h.
97576         * modules/time (Makefile.am): Substitute it.
97577         * lib/time.in.h (!TIME_H_DEFINES_STRUCT_TIMESPEC): Include
97578         <pthread.h>, when needed.
97579         (GNULIB_TIME_R): Undefine broken localtime_r and gmtime_r macros
97580         from the library.
97582 2010-05-31  Bruno Haible  <bruno@clisp.org>
97584         Avoid expanding two macros in the wrong order.
97585         * m4/libunistring-base.m4 (gl_LIBUNISTRING_LIB_PREPARE): Require
97586         gl_LIBUNISTRING if it is defined.
97587         * m4/libunistring.m4 (gl_LIBUNISTRING): Define using AC_DEFUN_ONCE for
97588         autoconf >= 2.64.
97589         Reported by Ludovic Courtès <ludo@gnu.org>.
97591 2010-05-27  Jim Meyering  <meyering@redhat.com>
97593         maint.mk: also prohibit "#undef" of always-defined symbols
97594         * top/maint.mk (def_sym_regex): Handle #undef as well as #define.
97595         Allow more than one space before the symbol name.
97596         (sc_prohibit_always-defined_macros): Use grep's -E, now that
97597         the regexp uses alternation.
97599 2010-05-26  Eric Blake  <eblake@redhat.com>
97601         maint.mk: avoid echo -e
97602         * top/maint.mk (gzip_rsyncable, _ignore_case, _sc_say_and_exit):
97603         Convert all uses of echo -* to printf.
97604         Reported by Matthias Bolte.
97606 2010-05-25  Bruno Haible  <bruno@clisp.org>
97608         Update to GNU gettext 0.18, part 2.
97609         * build-aux/po/Makefile.in.in: Update to GNU gettext 0.18.
97610         Reported by Martin von Gagern <Martin.vGagern@gmx.net>.
97612 2010-05-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
97614         Add missing include in test-pwrite.c.
97615         * tests/test-pwrite.c: Include string.h, for strcmp.
97617 2010-05-24  Bruno Haible  <bruno@clisp.org>
97619         * NEWS: Mention requirement for Automake option 'subdir-objects'.
97621 2010-05-24  Bruno Haible  <bruno@clisp.org>
97623         Don't use conversion with transliteration in u{8,16,32}_strcoll.
97624         * lib/unistr/u-strcoll.h (FUNC): Use U_STRCONV_TO_ENCODING with
97625         iconveh_error argument.
97626         * lib/unistr/u8-strcoll.c: Define U_STRCONV_TO_ENCODING instead of
97627         U_STRCONV_TO_LOCALE.
97628         * lib/unistr/u16-strcoll.c: Likewise.
97629         * lib/unistr/u32-strcoll.c: Likewise.
97630         * modules/unistr/u8-strcoll (Depends-on): Add
97631         uniconv/u8-strconv-to-enc, localcharset. Remove
97632         uniconv/u8-strconv-to-locale.
97633         (configure.ac): Bump version number.
97634         * modules/unistr/u16-strcoll (Depends-on): Add
97635         uniconv/u16-strconv-to-enc, localcharset. Remove
97636         uniconv/u16-strconv-to-locale.
97637         (configure.ac): Bump version number.
97638         * modules/unistr/u32-strcoll (Depends-on): Add
97639         uniconv/u32-strconv-to-enc, localcharset. Remove
97640         uniconv/u32-strconv-to-locale.
97641         (configure.ac): Bump version number.
97643 2010-05-24  Bruno Haible  <bruno@clisp.org>
97645         Avoid a test failure on NetBSD 5.0.
97646         * tests/test-striconveh.c (main): On NetBSD, skip a test that triggers
97647         an iconv() bug.
97649 2010-05-24  Bruno Haible  <bruno@clisp.org>
97651         Adjust #include directive style.
97652         * modules/regex (Includes): Recommend to write <regex.h>.
97654 2010-05-24  Bruno Haible  <bruno@clisp.org>
97656         regex: Don't require alloca.
97657         * modules/regex (Depends-on): Remove alloca. Add alloca-opt.
97658         * lib/regex_internal.h (alloca): Ensure it's defined even if we call it
97659         only inside if (0).
97661 2010-05-23  Jim Meyering  <meyering@redhat.com>
97663         test-renameat.c: include <sys/stat.h>
97664         * tests/test-renameat.c: Include <sys/stat.h>; required for
97665         definition of S_IS* macros.
97667 2010-05-23  Ben Pfaff  <blp@cs.stanford.edu>
97669         Update maintainer documentation for 'relocatable-prog' module.
97670         * doc/relocatable-maint.texi: Update.
97671         Comments by Bruno Haible.
97673 2010-05-23  Bruno Haible  <bruno@clisp.org>
97675         git-merge-changelog: Enable --split-merged-entry by default.
97676         * lib/git-merge-changelog.c (main): Set split_merged_entry to true.
97677         (usage): Don't mention this option any more.
97678         Reported by Ralf Wildenhues.
97680 2010-05-23  Jim Meyering  <meyering@redhat.com>
97682         test-pwrite: do not leave behind a test file named "out"
97683         Revert commit d8fa18472a54c1cb2674c296b3d82443f234d5f7.
97684         The trivial-looking use of init.sh is really necessary.
97685         It ensures that the temporary file, "out", is created in
97686         a temporary directory, and removed upon termination.
97687         * tests/test-pwrite.sh: Re-add file.
97688         * modules/pwrite-tests: Reference it.
97690 2010-05-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
97692         Fix output redirection buglet in init.sh.
97693         * tests/init.sh: Fix redirection of stderr.
97695 2010-05-20  Simon Josefsson  <simon@josefsson.org>
97697         * modules/valgrind-tests (configure.ac): Invoke gl_VALGRIND_TESTS.
97699 2010-05-17  Simon Josefsson  <simon@josefsson.org>
97701         * modules/valgrind-tests: New file.
97702         * m4/valgrind-tests.m4: New file.
97703         * doc/valgrind-tests.texi: New file.
97704         * doc/gnulib.texi (Running self-tests under valgrind): New
97705         section.
97707 2010-05-19  Bruno Haible  <bruno@clisp.org>
97709         Clean up dead code in recent commit.
97710         * m4/libunistring-base.m4 (gl_LIBUNISTRING_VERSION_CMP): Include the
97711         body of gl_LIBUNISTRING_VERSION_CMP_ORIG as fallback.
97712         (gl_LIBUNISTRING_VERSION_CMP_ORIG): Remove macro.
97713         Suggested by Paolo Bonzini.
97715 2010-05-19  Bruno Haible  <bruno@clisp.org>
97717         Avoid valgrind error reports from libunistring.
97718         * lib/libunistring.valgrind: New file, based on lib/malloca.valgrind.
97719         * modules/libunistring (Files): Add it.
97720         * modules/libunistring-optional (Files): Likewise.
97722 2010-05-18  Paolo Bonzini  <bonzini@gnu.org>
97723             Bruno Haible  <bruno@clisp.org>
97725         New module 'libunistring-optional'.
97726         * modules/libunistring-optional: New file.
97727         * m4/libunistring-base.m4: New file.
97728         * m4/libunistring-optional.m4: New file.
97729         * lib/unicase.in.h: Renamed from lib/unicase.h.
97730         * lib/uniconv.in.h: Renamed from lib/uniconv.h.
97731         * lib/unictype.in.h: Renamed from lib/unictype.h.
97732         * lib/unilbrk.in.h: Renamed from lib/unilbrk.h.
97733         * lib/uniname.in.h: Renamed from lib/uniname.h.
97734         * lib/uninorm.in.h: Renamed from lib/uninorm.h.
97735         * lib/unistdio.in.h: Renamed from lib/unistdio.h.
97736         * lib/unistr.in.h: Renamed from lib/unistr.h.
97737         * lib/unitypes.in.h: Renamed from lib/unitypes.h.
97738         * lib/uniwbrk.in.h: Renamed from lib/uniwbrk.h.
97739         * lib/uniwidth.in.h: Renamed from lib/uniwidth.h.
97740         * m4/libunistring.m4 (gl_LIBUNISTRING_CORE): Renamed from
97741         gl_LIBUNISTRING. If the library was found, determine the installed
97742         version and set LIBUNISTRING_VERSION.
97743         (gl_LIBUNISTRING): New macro, as a wrapper arount it. Document that it
97744         sets LIBUNISTRING_VERSION. If the module libunistring-optional is used,
97745         handle a configuration option --with-included-libunistring.
97746         * modules/libunistring (Files): Add m4/absolute-header.m4.
97747         * modules/unicase/base (Files): Use unicase.in.h instead of unicase.h.
97748         Add m4/libunistring-base.m4.
97749         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97750         (Makefile.am): Build unicase.h from unicase.in.h.
97751         * modules/uniconv/base (Files): Use uniconv.in.h instead of uniconv.h.
97752         Add m4/libunistring-base.m4.
97753         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97754         (Makefile.am): Build uniconv.h from uniconv.in.h.
97755         * modules/unictype/base (Files): Use unictype.in.h instead of
97756         unictype.h. Add m4/libunistring-base.m4.
97757         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97758         (Makefile.am): Build unictype.h from unictype.in.h.
97759         * modules/unilbrk/base (Files): Use unilbrk.in.h instead of unilbrk.h.
97760         Add m4/libunistring-base.m4.
97761         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97762         (Makefile.am): Build unilbrk.h from unilbrk.in.h.
97763         * modules/uniname/base (Files): Use uniname.in.h instead of uniname.h.
97764         Add m4/libunistring-base.m4.
97765         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97766         (Makefile.am): Build uniname.h from uniname.in.h.
97767         * modules/uninorm/base (Files): Use uninorm.in.h instead of uninorm.h.
97768         Add m4/libunistring-base.m4.
97769         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97770         (Makefile.am): Build uninorm.h from uninorm.in.h.
97771         * modules/unistdio/base (Files): Use unistdio.in.h instead of
97772         unistdio.h. Add m4/libunistring-base.m4.
97773         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97774         (Makefile.am): Build unistdio.h from unistdio.in.h.
97775         * modules/unistr/base (Files): Use unistr.in.h instead of unistr.h.
97776         Add m4/libunistring-base.m4.
97777         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97778         (Makefile.am): Build unistr.h from unistr.in.h.
97779         * modules/unitypes (Files): Use unitypes.in.h instead of unitypes.h.
97780         Add m4/libunistring-base.m4.
97781         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97782         (Makefile.am): Build unitypes.h from unitypes.in.h.
97783         * modules/uniwbrk/base (Files): Use uniwbrk.in.h instead of uniwbrk.h.
97784         Add m4/libunistring-base.m4.
97785         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97786         (Makefile.am): Build uniwbrk.h from uniwbrk.in.h.
97787         * modules/uniwidth/base (Files): Use uniwidth.in.h instead of
97788         uniwidth.h. Add m4/libunistring-base.m4.
97789         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
97790         (Makefile.am): Build uniwidth.h from uniwidth.in.h.
97791         * modules/unicase/empty-prefix-context: Use gl_LIBUNISTRING_LIBSOURCE
97792         instead of augmenting lib_SOURCES.
97793         * modules/unicase/empty-suffix-context: Likewise.
97794         * modules/unicase/locale-language: Likewise.
97795         * modules/unicase/tolower: Likewise.
97796         * modules/unicase/totitle: Likewise.
97797         * modules/unicase/toupper: Likewise.
97798         * modules/unicase/u8-casecmp: Likewise.
97799         * modules/unicase/u8-casecoll: Likewise.
97800         * modules/unicase/u8-casefold: Likewise.
97801         * modules/unicase/u8-casexfrm: Likewise.
97802         * modules/unicase/u8-ct-casefold: Likewise.
97803         * modules/unicase/u8-ct-tolower: Likewise.
97804         * modules/unicase/u8-ct-totitle: Likewise.
97805         * modules/unicase/u8-ct-toupper: Likewise.
97806         * modules/unicase/u8-is-cased: Likewise.
97807         * modules/unicase/u8-is-casefolded: Likewise.
97808         * modules/unicase/u8-is-lowercase: Likewise.
97809         * modules/unicase/u8-is-titlecase: Likewise.
97810         * modules/unicase/u8-is-uppercase: Likewise.
97811         * modules/unicase/u8-prefix-context: Likewise.
97812         * modules/unicase/u8-suffix-context: Likewise.
97813         * modules/unicase/u8-tolower: Likewise.
97814         * modules/unicase/u8-totitle: Likewise.
97815         * modules/unicase/u8-toupper: Likewise.
97816         * modules/unicase/u16-casecmp: Likewise.
97817         * modules/unicase/u16-casecoll: Likewise.
97818         * modules/unicase/u16-casefold: Likewise.
97819         * modules/unicase/u16-casexfrm: Likewise.
97820         * modules/unicase/u16-ct-casefold: Likewise.
97821         * modules/unicase/u16-ct-tolower: Likewise.
97822         * modules/unicase/u16-ct-totitle: Likewise.
97823         * modules/unicase/u16-ct-toupper: Likewise.
97824         * modules/unicase/u16-is-cased: Likewise.
97825         * modules/unicase/u16-is-casefolded: Likewise.
97826         * modules/unicase/u16-is-lowercase: Likewise.
97827         * modules/unicase/u16-is-titlecase: Likewise.
97828         * modules/unicase/u16-is-uppercase: Likewise.
97829         * modules/unicase/u16-prefix-context: Likewise.
97830         * modules/unicase/u16-suffix-context: Likewise.
97831         * modules/unicase/u16-tolower: Likewise.
97832         * modules/unicase/u16-totitle: Likewise.
97833         * modules/unicase/u16-toupper: Likewise.
97834         * modules/unicase/u32-casecmp: Likewise.
97835         * modules/unicase/u32-casecoll: Likewise.
97836         * modules/unicase/u32-casefold: Likewise.
97837         * modules/unicase/u32-casexfrm: Likewise.
97838         * modules/unicase/u32-ct-casefold: Likewise.
97839         * modules/unicase/u32-ct-tolower: Likewise.
97840         * modules/unicase/u32-ct-totitle: Likewise.
97841         * modules/unicase/u32-ct-toupper: Likewise.
97842         * modules/unicase/u32-is-cased: Likewise.
97843         * modules/unicase/u32-is-casefolded: Likewise.
97844         * modules/unicase/u32-is-lowercase: Likewise.
97845         * modules/unicase/u32-is-titlecase: Likewise.
97846         * modules/unicase/u32-is-uppercase: Likewise.
97847         * modules/unicase/u32-prefix-context: Likewise.
97848         * modules/unicase/u32-suffix-context: Likewise.
97849         * modules/unicase/u32-tolower: Likewise.
97850         * modules/unicase/u32-totitle: Likewise.
97851         * modules/unicase/u32-toupper: Likewise.
97852         * modules/unicase/ulc-casecmp: Likewise.
97853         * modules/unicase/ulc-casecoll: Likewise.
97854         * modules/unicase/ulc-casexfrm: Likewise.
97855         * modules/uniconv/u8-conv-from-enc: Likewise.
97856         * modules/uniconv/u8-conv-to-enc: Likewise.
97857         * modules/uniconv/u8-strconv-from-enc: Likewise.
97858         * modules/uniconv/u8-strconv-from-locale: Likewise.
97859         * modules/uniconv/u8-strconv-to-enc: Likewise.
97860         * modules/uniconv/u8-strconv-to-locale: Likewise.
97861         * modules/uniconv/u16-conv-from-enc: Likewise.
97862         * modules/uniconv/u16-conv-to-enc: Likewise.
97863         * modules/uniconv/u16-strconv-from-enc: Likewise.
97864         * modules/uniconv/u16-strconv-from-locale: Likewise.
97865         * modules/uniconv/u16-strconv-to-enc: Likewise.
97866         * modules/uniconv/u16-strconv-to-locale: Likewise.
97867         * modules/uniconv/u32-conv-from-enc: Likewise.
97868         * modules/uniconv/u32-conv-to-enc: Likewise.
97869         * modules/uniconv/u32-strconv-from-enc: Likewise.
97870         * modules/uniconv/u32-strconv-from-locale: Likewise.
97871         * modules/uniconv/u32-strconv-to-enc: Likewise.
97872         * modules/uniconv/u32-strconv-to-locale: Likewise.
97873         * modules/unictype/bidicategory-byname: Likewise.
97874         * modules/unictype/bidicategory-name: Likewise.
97875         * modules/unictype/bidicategory-of: Likewise.
97876         * modules/unictype/bidicategory-test: Likewise.
97877         * modules/unictype/block-list: Likewise.
97878         * modules/unictype/block-test: Likewise.
97879         * modules/unictype/category-C: Likewise.
97880         * modules/unictype/category-Cc: Likewise.
97881         * modules/unictype/category-Cf: Likewise.
97882         * modules/unictype/category-Cn: Likewise.
97883         * modules/unictype/category-Co: Likewise.
97884         * modules/unictype/category-Cs: Likewise.
97885         * modules/unictype/category-L: Likewise.
97886         * modules/unictype/category-Ll: Likewise.
97887         * modules/unictype/category-Lm: Likewise.
97888         * modules/unictype/category-Lo: Likewise.
97889         * modules/unictype/category-Lt: Likewise.
97890         * modules/unictype/category-Lu: Likewise.
97891         * modules/unictype/category-M: Likewise.
97892         * modules/unictype/category-Mc: Likewise.
97893         * modules/unictype/category-Me: Likewise.
97894         * modules/unictype/category-Mn: Likewise.
97895         * modules/unictype/category-N: Likewise.
97896         * modules/unictype/category-Nd: Likewise.
97897         * modules/unictype/category-Nl: Likewise.
97898         * modules/unictype/category-No: Likewise.
97899         * modules/unictype/category-P: Likewise.
97900         * modules/unictype/category-Pc: Likewise.
97901         * modules/unictype/category-Pd: Likewise.
97902         * modules/unictype/category-Pe: Likewise.
97903         * modules/unictype/category-Pf: Likewise.
97904         * modules/unictype/category-Pi: Likewise.
97905         * modules/unictype/category-Po: Likewise.
97906         * modules/unictype/category-Ps: Likewise.
97907         * modules/unictype/category-S: Likewise.
97908         * modules/unictype/category-Sc: Likewise.
97909         * modules/unictype/category-Sk: Likewise.
97910         * modules/unictype/category-Sm: Likewise.
97911         * modules/unictype/category-So: Likewise.
97912         * modules/unictype/category-Z: Likewise.
97913         * modules/unictype/category-Zl: Likewise.
97914         * modules/unictype/category-Zp: Likewise.
97915         * modules/unictype/category-Zs: Likewise.
97916         * modules/unictype/category-and: Likewise.
97917         * modules/unictype/category-and-not: Likewise.
97918         * modules/unictype/category-byname: Likewise.
97919         * modules/unictype/category-name: Likewise.
97920         * modules/unictype/category-none: Likewise.
97921         * modules/unictype/category-of: Likewise.
97922         * modules/unictype/category-or: Likewise.
97923         * modules/unictype/category-test: Likewise.
97924         * modules/unictype/combining-class: Likewise.
97925         * modules/unictype/ctype-alnum: Likewise.
97926         * modules/unictype/ctype-alpha: Likewise.
97927         * modules/unictype/ctype-blank: Likewise.
97928         * modules/unictype/ctype-cntrl: Likewise.
97929         * modules/unictype/ctype-digit: Likewise.
97930         * modules/unictype/ctype-graph: Likewise.
97931         * modules/unictype/ctype-lower: Likewise.
97932         * modules/unictype/ctype-print: Likewise.
97933         * modules/unictype/ctype-punct: Likewise.
97934         * modules/unictype/ctype-space: Likewise.
97935         * modules/unictype/ctype-upper: Likewise.
97936         * modules/unictype/ctype-xdigit: Likewise.
97937         * modules/unictype/decimal-digit: Likewise.
97938         * modules/unictype/digit: Likewise.
97939         * modules/unictype/mirror: Likewise.
97940         * modules/unictype/numeric: Likewise.
97941         * modules/unictype/property-alphabetic: Likewise.
97942         * modules/unictype/property-ascii-hex-digit: Likewise.
97943         * modules/unictype/property-bidi-arabic-digit: Likewise.
97944         * modules/unictype/property-bidi-arabic-right-to-left: Likewise.
97945         * modules/unictype/property-bidi-block-separator: Likewise.
97946         * modules/unictype/property-bidi-boundary-neutral: Likewise.
97947         * modules/unictype/property-bidi-common-separator: Likewise.
97948         * modules/unictype/property-bidi-control: Likewise.
97949         * modules/unictype/property-bidi-embedding-or-override: Likewise.
97950         * modules/unictype/property-bidi-eur-num-separator: Likewise.
97951         * modules/unictype/property-bidi-eur-num-terminator: Likewise.
97952         * modules/unictype/property-bidi-european-digit: Likewise.
97953         * modules/unictype/property-bidi-hebrew-right-to-left: Likewise.
97954         * modules/unictype/property-bidi-left-to-right: Likewise.
97955         * modules/unictype/property-bidi-non-spacing-mark: Likewise.
97956         * modules/unictype/property-bidi-other-neutral: Likewise.
97957         * modules/unictype/property-bidi-pdf: Likewise.
97958         * modules/unictype/property-bidi-segment-separator: Likewise.
97959         * modules/unictype/property-bidi-whitespace: Likewise.
97960         * modules/unictype/property-byname: Likewise.
97961         * modules/unictype/property-combining: Likewise.
97962         * modules/unictype/property-composite: Likewise.
97963         * modules/unictype/property-currency-symbol: Likewise.
97964         * modules/unictype/property-dash: Likewise.
97965         * modules/unictype/property-decimal-digit: Likewise.
97966         * modules/unictype/property-default-ignorable-code-point: Likewise.
97967         * modules/unictype/property-deprecated: Likewise.
97968         * modules/unictype/property-diacritic: Likewise.
97969         * modules/unictype/property-extender: Likewise.
97970         * modules/unictype/property-format-control: Likewise.
97971         * modules/unictype/property-grapheme-base: Likewise.
97972         * modules/unictype/property-grapheme-extend: Likewise.
97973         * modules/unictype/property-grapheme-link: Likewise.
97974         * modules/unictype/property-hex-digit: Likewise.
97975         * modules/unictype/property-hyphen: Likewise.
97976         * modules/unictype/property-id-continue: Likewise.
97977         * modules/unictype/property-id-start: Likewise.
97978         * modules/unictype/property-ideographic: Likewise.
97979         * modules/unictype/property-ids-binary-operator: Likewise.
97980         * modules/unictype/property-ids-trinary-operator: Likewise.
97981         * modules/unictype/property-ignorable-control: Likewise.
97982         * modules/unictype/property-iso-control: Likewise.
97983         * modules/unictype/property-join-control: Likewise.
97984         * modules/unictype/property-left-of-pair: Likewise.
97985         * modules/unictype/property-line-separator: Likewise.
97986         * modules/unictype/property-logical-order-exception: Likewise.
97987         * modules/unictype/property-lowercase: Likewise.
97988         * modules/unictype/property-math: Likewise.
97989         * modules/unictype/property-non-break: Likewise.
97990         * modules/unictype/property-not-a-character: Likewise.
97991         * modules/unictype/property-numeric: Likewise.
97992         * modules/unictype/property-other-alphabetic: Likewise.
97993         * modules/unictype/property-other-default-ignorable-code-point: Likewise.
97994         * modules/unictype/property-other-grapheme-extend: Likewise.
97995         * modules/unictype/property-other-id-continue: Likewise.
97996         * modules/unictype/property-other-id-start: Likewise.
97997         * modules/unictype/property-other-lowercase: Likewise.
97998         * modules/unictype/property-other-math: Likewise.
97999         * modules/unictype/property-other-uppercase: Likewise.
98000         * modules/unictype/property-paired-punctuation: Likewise.
98001         * modules/unictype/property-paragraph-separator: Likewise.
98002         * modules/unictype/property-pattern-syntax: Likewise.
98003         * modules/unictype/property-pattern-white-space: Likewise.
98004         * modules/unictype/property-private-use: Likewise.
98005         * modules/unictype/property-punctuation: Likewise.
98006         * modules/unictype/property-quotation-mark: Likewise.
98007         * modules/unictype/property-radical: Likewise.
98008         * modules/unictype/property-sentence-terminal: Likewise.
98009         * modules/unictype/property-soft-dotted: Likewise.
98010         * modules/unictype/property-space: Likewise.
98011         * modules/unictype/property-terminal-punctuation: Likewise.
98012         * modules/unictype/property-test: Likewise.
98013         * modules/unictype/property-titlecase: Likewise.
98014         * modules/unictype/property-unassigned-code-value: Likewise.
98015         * modules/unictype/property-unified-ideograph: Likewise.
98016         * modules/unictype/property-uppercase: Likewise.
98017         * modules/unictype/property-variation-selector: Likewise.
98018         * modules/unictype/property-white-space: Likewise.
98019         * modules/unictype/property-xid-continue: Likewise.
98020         * modules/unictype/property-xid-start: Likewise.
98021         * modules/unictype/property-zero-width: Likewise.
98022         * modules/unictype/scripts: Likewise.
98023         * modules/unictype/syntax-c-ident: Likewise.
98024         * modules/unictype/syntax-c-whitespace: Likewise.
98025         * modules/unictype/syntax-java-ident: Likewise.
98026         * modules/unictype/syntax-java-whitespace: Likewise.
98027         * modules/unilbrk/u8-possible-linebreaks: Likewise.
98028         * modules/unilbrk/u8-width-linebreaks: Likewise.
98029         * modules/unilbrk/u16-possible-linebreaks: Likewise.
98030         * modules/unilbrk/u16-width-linebreaks: Likewise.
98031         * modules/unilbrk/u32-possible-linebreaks: Likewise.
98032         * modules/unilbrk/u32-width-linebreaks: Likewise.
98033         * modules/unilbrk/ulc-possible-linebreaks: Likewise.
98034         * modules/unilbrk/ulc-width-linebreaks: Likewise.
98035         * modules/uniname/uniname: Likewise.
98036         * modules/uninorm/canonical-decomposition: Likewise.
98037         * modules/uninorm/composition: Likewise.
98038         * modules/uninorm/decomposing-form: Likewise.
98039         * modules/uninorm/decomposition: Likewise.
98040         * modules/uninorm/filter: Likewise.
98041         * modules/uninorm/nfc: Likewise.
98042         * modules/uninorm/nfd: Likewise.
98043         * modules/uninorm/nfkc: Likewise.
98044         * modules/uninorm/nfkd: Likewise.
98045         * modules/uninorm/u8-normalize: Likewise.
98046         * modules/uninorm/u8-normcmp: Likewise.
98047         * modules/uninorm/u8-normcoll: Likewise.
98048         * modules/uninorm/u8-normxfrm: Likewise.
98049         * modules/uninorm/u16-normalize: Likewise.
98050         * modules/uninorm/u16-normcmp: Likewise.
98051         * modules/uninorm/u16-normcoll: Likewise.
98052         * modules/uninorm/u16-normxfrm: Likewise.
98053         * modules/uninorm/u32-normalize: Likewise.
98054         * modules/uninorm/u32-normcmp: Likewise.
98055         * modules/uninorm/u32-normcoll: Likewise.
98056         * modules/uninorm/u32-normxfrm: Likewise.
98057         * modules/unistdio/u8-asnprintf: Likewise.
98058         * modules/unistdio/u8-asprintf: Likewise.
98059         * modules/unistdio/u8-snprintf: Likewise.
98060         * modules/unistdio/u8-sprintf: Likewise.
98061         * modules/unistdio/u8-u8-asnprintf: Likewise.
98062         * modules/unistdio/u8-u8-asprintf: Likewise.
98063         * modules/unistdio/u8-u8-snprintf: Likewise.
98064         * modules/unistdio/u8-u8-sprintf: Likewise.
98065         * modules/unistdio/u8-u8-vasnprintf: Likewise.
98066         * modules/unistdio/u8-u8-vasprintf: Likewise.
98067         * modules/unistdio/u8-u8-vsnprintf: Likewise.
98068         * modules/unistdio/u8-u8-vsprintf: Likewise.
98069         * modules/unistdio/u8-vasnprintf: Likewise.
98070         * modules/unistdio/u8-vasprintf: Likewise.
98071         * modules/unistdio/u8-vsnprintf: Likewise.
98072         * modules/unistdio/u8-vsprintf: Likewise.
98073         * modules/unistdio/u16-asnprintf: Likewise.
98074         * modules/unistdio/u16-asprintf: Likewise.
98075         * modules/unistdio/u16-snprintf: Likewise.
98076         * modules/unistdio/u16-sprintf: Likewise.
98077         * modules/unistdio/u16-u16-asnprintf: Likewise.
98078         * modules/unistdio/u16-u16-asprintf: Likewise.
98079         * modules/unistdio/u16-u16-snprintf: Likewise.
98080         * modules/unistdio/u16-u16-sprintf: Likewise.
98081         * modules/unistdio/u16-u16-vasnprintf: Likewise.
98082         * modules/unistdio/u16-u16-vasprintf: Likewise.
98083         * modules/unistdio/u16-u16-vsnprintf: Likewise.
98084         * modules/unistdio/u16-u16-vsprintf: Likewise.
98085         * modules/unistdio/u16-vasnprintf: Likewise.
98086         * modules/unistdio/u16-vasprintf: Likewise.
98087         * modules/unistdio/u16-vsnprintf: Likewise.
98088         * modules/unistdio/u16-vsprintf: Likewise.
98089         * modules/unistdio/u32-asnprintf: Likewise.
98090         * modules/unistdio/u32-asprintf: Likewise.
98091         * modules/unistdio/u32-snprintf: Likewise.
98092         * modules/unistdio/u32-sprintf: Likewise.
98093         * modules/unistdio/u32-u32-asnprintf: Likewise.
98094         * modules/unistdio/u32-u32-asprintf: Likewise.
98095         * modules/unistdio/u32-u32-snprintf: Likewise.
98096         * modules/unistdio/u32-u32-sprintf: Likewise.
98097         * modules/unistdio/u32-u32-vasnprintf: Likewise.
98098         * modules/unistdio/u32-u32-vasprintf: Likewise.
98099         * modules/unistdio/u32-u32-vsnprintf: Likewise.
98100         * modules/unistdio/u32-u32-vsprintf: Likewise.
98101         * modules/unistdio/u32-vasnprintf: Likewise.
98102         * modules/unistdio/u32-vasprintf: Likewise.
98103         * modules/unistdio/u32-vsnprintf: Likewise.
98104         * modules/unistdio/u32-vsprintf: Likewise.
98105         * modules/unistdio/ulc-asnprintf: Likewise.
98106         * modules/unistdio/ulc-asprintf: Likewise.
98107         * modules/unistdio/ulc-fprintf: Likewise.
98108         * modules/unistdio/ulc-snprintf: Likewise.
98109         * modules/unistdio/ulc-sprintf: Likewise.
98110         * modules/unistdio/ulc-vasnprintf: Likewise.
98111         * modules/unistdio/ulc-vasprintf: Likewise.
98112         * modules/unistdio/ulc-vfprintf: Likewise.
98113         * modules/unistdio/ulc-vsnprintf: Likewise.
98114         * modules/unistdio/ulc-vsprintf: Likewise.
98115         * modules/unistr/u8-check: Likewise.
98116         * modules/unistr/u8-chr: Likewise.
98117         * modules/unistr/u8-cmp: Likewise.
98118         * modules/unistr/u8-cmp2: Likewise.
98119         * modules/unistr/u8-cpy: Likewise.
98120         * modules/unistr/u8-cpy-alloc: Likewise.
98121         * modules/unistr/u8-endswith: Likewise.
98122         * modules/unistr/u8-mblen: Likewise.
98123         * modules/unistr/u8-mbsnlen: Likewise.
98124         * modules/unistr/u8-mbtouc: Likewise.
98125         * modules/unistr/u8-mbtouc-unsafe: Likewise.
98126         * modules/unistr/u8-mbtoucr: Likewise.
98127         * modules/unistr/u8-move: Likewise.
98128         * modules/unistr/u8-next: Likewise.
98129         * modules/unistr/u8-prev: Likewise.
98130         * modules/unistr/u8-set: Likewise.
98131         * modules/unistr/u8-startswith: Likewise.
98132         * modules/unistr/u8-stpcpy: Likewise.
98133         * modules/unistr/u8-stpncpy: Likewise.
98134         * modules/unistr/u8-strcat: Likewise.
98135         * modules/unistr/u8-strchr: Likewise.
98136         * modules/unistr/u8-strcmp: Likewise.
98137         * modules/unistr/u8-strcoll: Likewise.
98138         * modules/unistr/u8-strcpy: Likewise.
98139         * modules/unistr/u8-strcspn: Likewise.
98140         * modules/unistr/u8-strdup: Likewise.
98141         * modules/unistr/u8-strlen: Likewise.
98142         * modules/unistr/u8-strmblen: Likewise.
98143         * modules/unistr/u8-strmbtouc: Likewise.
98144         * modules/unistr/u8-strncat: Likewise.
98145         * modules/unistr/u8-strncmp: Likewise.
98146         * modules/unistr/u8-strncpy: Likewise.
98147         * modules/unistr/u8-strnlen: Likewise.
98148         * modules/unistr/u8-strpbrk: Likewise.
98149         * modules/unistr/u8-strrchr: Likewise.
98150         * modules/unistr/u8-strspn: Likewise.
98151         * modules/unistr/u8-strstr: Likewise.
98152         * modules/unistr/u8-strtok: Likewise.
98153         * modules/unistr/u8-to-u16: Likewise.
98154         * modules/unistr/u8-to-u32: Likewise.
98155         * modules/unistr/u8-uctomb: Likewise.
98156         * modules/unistr/u16-check: Likewise.
98157         * modules/unistr/u16-chr: Likewise.
98158         * modules/unistr/u16-cmp: Likewise.
98159         * modules/unistr/u16-cmp2: Likewise.
98160         * modules/unistr/u16-cpy: Likewise.
98161         * modules/unistr/u16-cpy-alloc: Likewise.
98162         * modules/unistr/u16-endswith: Likewise.
98163         * modules/unistr/u16-mblen: Likewise.
98164         * modules/unistr/u16-mbsnlen: Likewise.
98165         * modules/unistr/u16-mbtouc: Likewise.
98166         * modules/unistr/u16-mbtouc-unsafe: Likewise.
98167         * modules/unistr/u16-mbtoucr: Likewise.
98168         * modules/unistr/u16-move: Likewise.
98169         * modules/unistr/u16-next: Likewise.
98170         * modules/unistr/u16-prev: Likewise.
98171         * modules/unistr/u16-set: Likewise.
98172         * modules/unistr/u16-startswith: Likewise.
98173         * modules/unistr/u16-stpcpy: Likewise.
98174         * modules/unistr/u16-stpncpy: Likewise.
98175         * modules/unistr/u16-strcat: Likewise.
98176         * modules/unistr/u16-strchr: Likewise.
98177         * modules/unistr/u16-strcmp: Likewise.
98178         * modules/unistr/u16-strcoll: Likewise.
98179         * modules/unistr/u16-strcpy: Likewise.
98180         * modules/unistr/u16-strcspn: Likewise.
98181         * modules/unistr/u16-strdup: Likewise.
98182         * modules/unistr/u16-strlen: Likewise.
98183         * modules/unistr/u16-strmblen: Likewise.
98184         * modules/unistr/u16-strmbtouc: Likewise.
98185         * modules/unistr/u16-strncat: Likewise.
98186         * modules/unistr/u16-strncmp: Likewise.
98187         * modules/unistr/u16-strncpy: Likewise.
98188         * modules/unistr/u16-strnlen: Likewise.
98189         * modules/unistr/u16-strpbrk: Likewise.
98190         * modules/unistr/u16-strrchr: Likewise.
98191         * modules/unistr/u16-strspn: Likewise.
98192         * modules/unistr/u16-strstr: Likewise.
98193         * modules/unistr/u16-strtok: Likewise.
98194         * modules/unistr/u16-to-u32: Likewise.
98195         * modules/unistr/u16-to-u8: Likewise.
98196         * modules/unistr/u16-uctomb: Likewise.
98197         * modules/unistr/u32-check: Likewise.
98198         * modules/unistr/u32-chr: Likewise.
98199         * modules/unistr/u32-cmp: Likewise.
98200         * modules/unistr/u32-cmp2: Likewise.
98201         * modules/unistr/u32-cpy: Likewise.
98202         * modules/unistr/u32-cpy-alloc: Likewise.
98203         * modules/unistr/u32-endswith: Likewise.
98204         * modules/unistr/u32-mblen: Likewise.
98205         * modules/unistr/u32-mbsnlen: Likewise.
98206         * modules/unistr/u32-mbtouc: Likewise.
98207         * modules/unistr/u32-mbtouc-unsafe: Likewise.
98208         * modules/unistr/u32-mbtoucr: Likewise.
98209         * modules/unistr/u32-move: Likewise.
98210         * modules/unistr/u32-next: Likewise.
98211         * modules/unistr/u32-prev: Likewise.
98212         * modules/unistr/u32-set: Likewise.
98213         * modules/unistr/u32-startswith: Likewise.
98214         * modules/unistr/u32-stpcpy: Likewise.
98215         * modules/unistr/u32-stpncpy: Likewise.
98216         * modules/unistr/u32-strcat: Likewise.
98217         * modules/unistr/u32-strchr: Likewise.
98218         * modules/unistr/u32-strcmp: Likewise.
98219         * modules/unistr/u32-strcoll: Likewise.
98220         * modules/unistr/u32-strcpy: Likewise.
98221         * modules/unistr/u32-strcspn: Likewise.
98222         * modules/unistr/u32-strdup: Likewise.
98223         * modules/unistr/u32-strlen: Likewise.
98224         * modules/unistr/u32-strmblen: Likewise.
98225         * modules/unistr/u32-strmbtouc: Likewise.
98226         * modules/unistr/u32-strncat: Likewise.
98227         * modules/unistr/u32-strncmp: Likewise.
98228         * modules/unistr/u32-strncpy: Likewise.
98229         * modules/unistr/u32-strnlen: Likewise.
98230         * modules/unistr/u32-strpbrk: Likewise.
98231         * modules/unistr/u32-strrchr: Likewise.
98232         * modules/unistr/u32-strspn: Likewise.
98233         * modules/unistr/u32-strstr: Likewise.
98234         * modules/unistr/u32-strtok: Likewise.
98235         * modules/unistr/u32-to-u16: Likewise.
98236         * modules/unistr/u32-to-u8: Likewise.
98237         * modules/unistr/u32-uctomb: Likewise.
98238         * modules/uniwbrk/u8-wordbreaks: Likewise.
98239         * modules/uniwbrk/u16-wordbreaks: Likewise.
98240         * modules/uniwbrk/u32-wordbreaks: Likewise.
98241         * modules/uniwbrk/ulc-wordbreaks: Likewise.
98242         * modules/uniwbrk/wordbreak-property: Likewise.
98243         * modules/uniwidth/u8-strwidth: Likewise.
98244         * modules/uniwidth/u8-width: Likewise.
98245         * modules/uniwidth/u16-strwidth: Likewise.
98246         * modules/uniwidth/u16-width: Likewise.
98247         * modules/uniwidth/u32-strwidth: Likewise.
98248         * modules/uniwidth/u32-width: Likewise.
98249         * modules/uniwidth/width: Likewise.
98250         * modules/unicase/cased-tests (Makefile.am): Link all test programs
98251         with $(LIBUNISTRING).
98252         * modules/unicase/ignorable-tests: Likewise.
98253         * modules/unicase/locale-language-tests: Likewise.
98254         * modules/unicase/tolower-tests: Likewise.
98255         * modules/unicase/totitle-tests: Likewise.
98256         * modules/unicase/toupper-tests: Likewise.
98257         * modules/unicase/u8-casecmp-tests: Likewise.
98258         * modules/unicase/u8-casecoll-tests: Likewise.
98259         * modules/unicase/u8-casefold-tests: Likewise.
98260         * modules/unicase/u8-is-cased-tests: Likewise.
98261         * modules/unicase/u8-is-casefolded-tests: Likewise.
98262         * modules/unicase/u8-is-lowercase-tests: Likewise.
98263         * modules/unicase/u8-is-titlecase-tests: Likewise.
98264         * modules/unicase/u8-is-uppercase-tests: Likewise.
98265         * modules/unicase/u8-tolower-tests: Likewise.
98266         * modules/unicase/u8-totitle-tests: Likewise.
98267         * modules/unicase/u8-toupper-tests: Likewise.
98268         * modules/unicase/u16-casecmp-tests: Likewise.
98269         * modules/unicase/u16-casecoll-tests: Likewise.
98270         * modules/unicase/u16-casefold-tests: Likewise.
98271         * modules/unicase/u16-is-cased-tests: Likewise.
98272         * modules/unicase/u16-is-casefolded-tests: Likewise.
98273         * modules/unicase/u16-is-lowercase-tests: Likewise.
98274         * modules/unicase/u16-is-titlecase-tests: Likewise.
98275         * modules/unicase/u16-is-uppercase-tests: Likewise.
98276         * modules/unicase/u16-tolower-tests: Likewise.
98277         * modules/unicase/u16-totitle-tests: Likewise.
98278         * modules/unicase/u16-toupper-tests: Likewise.
98279         * modules/unicase/u32-casecmp-tests: Likewise.
98280         * modules/unicase/u32-casecoll-tests: Likewise.
98281         * modules/unicase/u32-casefold-tests: Likewise.
98282         * modules/unicase/u32-is-cased-tests: Likewise.
98283         * modules/unicase/u32-is-casefolded-tests: Likewise.
98284         * modules/unicase/u32-is-lowercase-tests: Likewise.
98285         * modules/unicase/u32-is-titlecase-tests: Likewise.
98286         * modules/unicase/u32-is-uppercase-tests: Likewise.
98287         * modules/unicase/u32-tolower-tests: Likewise.
98288         * modules/unicase/u32-totitle-tests: Likewise.
98289         * modules/unicase/u32-toupper-tests: Likewise.
98290         * modules/unicase/ulc-casecmp-tests: Likewise.
98291         * modules/unicase/ulc-casecoll-tests: Likewise.
98292         * modules/uniconv/u8-conv-from-enc-tests: Likewise.
98293         * modules/uniconv/u8-conv-to-enc-tests: Likewise.
98294         * modules/uniconv/u8-strconv-from-enc-tests: Likewise.
98295         * modules/uniconv/u8-strconv-to-enc-tests: Likewise.
98296         * modules/uniconv/u16-conv-from-enc-tests: Likewise.
98297         * modules/uniconv/u16-conv-to-enc-tests: Likewise.
98298         * modules/uniconv/u16-strconv-from-enc-tests: Likewise.
98299         * modules/uniconv/u16-strconv-to-enc-tests: Likewise.
98300         * modules/uniconv/u32-conv-from-enc-tests: Likewise.
98301         * modules/uniconv/u32-conv-to-enc-tests: Likewise.
98302         * modules/uniconv/u32-strconv-from-enc-tests: Likewise.
98303         * modules/uniconv/u32-strconv-to-enc-tests: Likewise.
98304         * modules/unictype/bidicategory-byname-tests: Likewise.
98305         * modules/unictype/bidicategory-name-tests: Likewise.
98306         * modules/unictype/bidicategory-of-tests: Likewise.
98307         * modules/unictype/bidicategory-test-tests: Likewise.
98308         * modules/unictype/block-list-tests: Likewise.
98309         * modules/unictype/block-of-tests: Likewise.
98310         * modules/unictype/block-test-tests: Likewise.
98311         * modules/unictype/category-C-tests: Likewise.
98312         * modules/unictype/category-Cc-tests: Likewise.
98313         * modules/unictype/category-Cf-tests: Likewise.
98314         * modules/unictype/category-Cn-tests: Likewise.
98315         * modules/unictype/category-Co-tests: Likewise.
98316         * modules/unictype/category-Cs-tests: Likewise.
98317         * modules/unictype/category-L-tests: Likewise.
98318         * modules/unictype/category-Ll-tests: Likewise.
98319         * modules/unictype/category-Lm-tests: Likewise.
98320         * modules/unictype/category-Lo-tests: Likewise.
98321         * modules/unictype/category-Lt-tests: Likewise.
98322         * modules/unictype/category-Lu-tests: Likewise.
98323         * modules/unictype/category-M-tests: Likewise.
98324         * modules/unictype/category-Mc-tests: Likewise.
98325         * modules/unictype/category-Me-tests: Likewise.
98326         * modules/unictype/category-Mn-tests: Likewise.
98327         * modules/unictype/category-N-tests: Likewise.
98328         * modules/unictype/category-Nd-tests: Likewise.
98329         * modules/unictype/category-Nl-tests: Likewise.
98330         * modules/unictype/category-No-tests: Likewise.
98331         * modules/unictype/category-P-tests: Likewise.
98332         * modules/unictype/category-Pc-tests: Likewise.
98333         * modules/unictype/category-Pd-tests: Likewise.
98334         * modules/unictype/category-Pe-tests: Likewise.
98335         * modules/unictype/category-Pf-tests: Likewise.
98336         * modules/unictype/category-Pi-tests: Likewise.
98337         * modules/unictype/category-Po-tests: Likewise.
98338         * modules/unictype/category-Ps-tests: Likewise.
98339         * modules/unictype/category-S-tests: Likewise.
98340         * modules/unictype/category-Sc-tests: Likewise.
98341         * modules/unictype/category-Sk-tests: Likewise.
98342         * modules/unictype/category-Sm-tests: Likewise.
98343         * modules/unictype/category-So-tests: Likewise.
98344         * modules/unictype/category-Z-tests: Likewise.
98345         * modules/unictype/category-Zl-tests: Likewise.
98346         * modules/unictype/category-Zp-tests: Likewise.
98347         * modules/unictype/category-Zs-tests: Likewise.
98348         * modules/unictype/category-and-not-tests: Likewise.
98349         * modules/unictype/category-and-tests: Likewise.
98350         * modules/unictype/category-byname-tests: Likewise.
98351         * modules/unictype/category-name-tests: Likewise.
98352         * modules/unictype/category-none-tests: Likewise.
98353         * modules/unictype/category-of-tests: Likewise.
98354         * modules/unictype/category-or-tests: Likewise.
98355         * modules/unictype/category-test-withtable-tests: Likewise.
98356         * modules/unictype/combining-class-tests: Likewise.
98357         * modules/unictype/ctype-alnum-tests: Likewise.
98358         * modules/unictype/ctype-alpha-tests: Likewise.
98359         * modules/unictype/ctype-blank-tests: Likewise.
98360         * modules/unictype/ctype-cntrl-tests: Likewise.
98361         * modules/unictype/ctype-digit-tests: Likewise.
98362         * modules/unictype/ctype-graph-tests: Likewise.
98363         * modules/unictype/ctype-lower-tests: Likewise.
98364         * modules/unictype/ctype-print-tests: Likewise.
98365         * modules/unictype/ctype-punct-tests: Likewise.
98366         * modules/unictype/ctype-space-tests: Likewise.
98367         * modules/unictype/ctype-upper-tests: Likewise.
98368         * modules/unictype/ctype-xdigit-tests: Likewise.
98369         * modules/unictype/decimal-digit-tests: Likewise.
98370         * modules/unictype/digit-tests: Likewise.
98371         * modules/unictype/mirror-tests: Likewise.
98372         * modules/unictype/numeric-tests: Likewise.
98373         * modules/unictype/property-alphabetic-tests: Likewise.
98374         * modules/unictype/property-ascii-hex-digit-tests: Likewise.
98375         * modules/unictype/property-bidi-arabic-digit-tests: Likewise.
98376         * modules/unictype/property-bidi-arabic-right-to-left-tests: Likewise.
98377         * modules/unictype/property-bidi-block-separator-tests: Likewise.
98378         * modules/unictype/property-bidi-boundary-neutral-tests: Likewise.
98379         * modules/unictype/property-bidi-common-separator-tests: Likewise.
98380         * modules/unictype/property-bidi-control-tests: Likewise.
98381         * modules/unictype/property-bidi-embedding-or-override-tests: Likewise.
98382         * modules/unictype/property-bidi-eur-num-separator-tests: Likewise.
98383         * modules/unictype/property-bidi-eur-num-terminator-tests: Likewise.
98384         * modules/unictype/property-bidi-european-digit-tests: Likewise.
98385         * modules/unictype/property-bidi-hebrew-right-to-left-tests: Likewise.
98386         * modules/unictype/property-bidi-left-to-right-tests: Likewise.
98387         * modules/unictype/property-bidi-non-spacing-mark-tests: Likewise.
98388         * modules/unictype/property-bidi-other-neutral-tests: Likewise.
98389         * modules/unictype/property-bidi-pdf-tests: Likewise.
98390         * modules/unictype/property-bidi-segment-separator-tests: Likewise.
98391         * modules/unictype/property-bidi-whitespace-tests: Likewise.
98392         * modules/unictype/property-byname-tests: Likewise.
98393         * modules/unictype/property-combining-tests: Likewise.
98394         * modules/unictype/property-composite-tests: Likewise.
98395         * modules/unictype/property-currency-symbol-tests: Likewise.
98396         * modules/unictype/property-dash-tests: Likewise.
98397         * modules/unictype/property-decimal-digit-tests: Likewise.
98398         * modules/unictype/property-default-ignorable-code-point-tests: Likewise.
98399         * modules/unictype/property-deprecated-tests: Likewise.
98400         * modules/unictype/property-diacritic-tests: Likewise.
98401         * modules/unictype/property-extender-tests: Likewise.
98402         * modules/unictype/property-format-control-tests: Likewise.
98403         * modules/unictype/property-grapheme-base-tests: Likewise.
98404         * modules/unictype/property-grapheme-extend-tests: Likewise.
98405         * modules/unictype/property-grapheme-link-tests: Likewise.
98406         * modules/unictype/property-hex-digit-tests: Likewise.
98407         * modules/unictype/property-hyphen-tests: Likewise.
98408         * modules/unictype/property-id-continue-tests: Likewise.
98409         * modules/unictype/property-id-start-tests: Likewise.
98410         * modules/unictype/property-ideographic-tests: Likewise.
98411         * modules/unictype/property-ids-binary-operator-tests: Likewise.
98412         * modules/unictype/property-ids-trinary-operator-tests: Likewise.
98413         * modules/unictype/property-ignorable-control-tests: Likewise.
98414         * modules/unictype/property-iso-control-tests: Likewise.
98415         * modules/unictype/property-join-control-tests: Likewise.
98416         * modules/unictype/property-left-of-pair-tests: Likewise.
98417         * modules/unictype/property-line-separator-tests: Likewise.
98418         * modules/unictype/property-logical-order-exception-tests: Likewise.
98419         * modules/unictype/property-lowercase-tests: Likewise.
98420         * modules/unictype/property-math-tests: Likewise.
98421         * modules/unictype/property-non-break-tests: Likewise.
98422         * modules/unictype/property-not-a-character-tests: Likewise.
98423         * modules/unictype/property-numeric-tests: Likewise.
98424         * modules/unictype/property-other-alphabetic-tests: Likewise.
98425         * modules/unictype/property-other-default-ignorable-code-point-tests:
98426         Likewise.
98427         * modules/unictype/property-other-grapheme-extend-tests: Likewise.
98428         * modules/unictype/property-other-id-continue-tests: Likewise.
98429         * modules/unictype/property-other-id-start-tests: Likewise.
98430         * modules/unictype/property-other-lowercase-tests: Likewise.
98431         * modules/unictype/property-other-math-tests: Likewise.
98432         * modules/unictype/property-other-uppercase-tests: Likewise.
98433         * modules/unictype/property-paired-punctuation-tests: Likewise.
98434         * modules/unictype/property-paragraph-separator-tests: Likewise.
98435         * modules/unictype/property-pattern-syntax-tests: Likewise.
98436         * modules/unictype/property-pattern-white-space-tests: Likewise.
98437         * modules/unictype/property-private-use-tests: Likewise.
98438         * modules/unictype/property-punctuation-tests: Likewise.
98439         * modules/unictype/property-quotation-mark-tests: Likewise.
98440         * modules/unictype/property-radical-tests: Likewise.
98441         * modules/unictype/property-sentence-terminal-tests: Likewise.
98442         * modules/unictype/property-soft-dotted-tests: Likewise.
98443         * modules/unictype/property-space-tests: Likewise.
98444         * modules/unictype/property-terminal-punctuation-tests: Likewise.
98445         * modules/unictype/property-test-tests: Likewise.
98446         * modules/unictype/property-titlecase-tests: Likewise.
98447         * modules/unictype/property-unassigned-code-value-tests: Likewise.
98448         * modules/unictype/property-unified-ideograph-tests: Likewise.
98449         * modules/unictype/property-uppercase-tests: Likewise.
98450         * modules/unictype/property-variation-selector-tests: Likewise.
98451         * modules/unictype/property-white-space-tests: Likewise.
98452         * modules/unictype/property-xid-continue-tests: Likewise.
98453         * modules/unictype/property-xid-start-tests: Likewise.
98454         * modules/unictype/property-zero-width-tests: Likewise.
98455         * modules/unictype/scripts-tests: Likewise.
98456         * modules/unictype/syntax-c-ident-tests: Likewise.
98457         * modules/unictype/syntax-c-whitespace-tests: Likewise.
98458         * modules/unictype/syntax-java-ident-tests: Likewise.
98459         * modules/unictype/syntax-java-whitespace-tests: Likewise.
98460         * modules/unilbrk/u8-possible-linebreaks-tests: Likewise.
98461         * modules/unilbrk/u8-width-linebreaks-tests: Likewise.
98462         * modules/unilbrk/u16-possible-linebreaks-tests: Likewise.
98463         * modules/unilbrk/u16-width-linebreaks-tests: Likewise.
98464         * modules/unilbrk/u32-possible-linebreaks-tests: Likewise.
98465         * modules/unilbrk/u32-width-linebreaks-tests: Likewise.
98466         * modules/unilbrk/ulc-possible-linebreaks-tests: Likewise.
98467         * modules/unilbrk/ulc-width-linebreaks-tests: Likewise.
98468         * modules/uniname/uniname-tests: Likewise.
98469         * modules/uninorm/canonical-decomposition-tests: Likewise.
98470         * modules/uninorm/compat-decomposition-tests: Likewise.
98471         * modules/uninorm/composition-tests: Likewise.
98472         * modules/uninorm/decomposing-form-tests: Likewise.
98473         * modules/uninorm/decomposition-tests: Likewise.
98474         * modules/uninorm/filter-tests: Likewise.
98475         * modules/uninorm/nfc-tests: Likewise.
98476         * modules/uninorm/nfd-tests: Likewise.
98477         * modules/uninorm/nfkc-tests: Likewise.
98478         * modules/uninorm/nfkd-tests: Likewise.
98479         * modules/uninorm/u8-normcmp-tests: Likewise.
98480         * modules/uninorm/u8-normcoll-tests: Likewise.
98481         * modules/uninorm/u16-normcmp-tests: Likewise.
98482         * modules/uninorm/u16-normcoll-tests: Likewise.
98483         * modules/uninorm/u32-normcmp-tests: Likewise.
98484         * modules/uninorm/u32-normcoll-tests: Likewise.
98485         * modules/unistdio/u8-asnprintf-tests: Likewise.
98486         * modules/unistdio/u8-vasnprintf-tests: Likewise.
98487         * modules/unistdio/u8-vasprintf-tests: Likewise.
98488         * modules/unistdio/u8-vsnprintf-tests: Likewise.
98489         * modules/unistdio/u8-vsprintf-tests: Likewise.
98490         * modules/unistdio/u16-asnprintf-tests: Likewise.
98491         * modules/unistdio/u16-vasnprintf-tests: Likewise.
98492         * modules/unistdio/u16-vasprintf-tests: Likewise.
98493         * modules/unistdio/u16-vsnprintf-tests: Likewise.
98494         * modules/unistdio/u16-vsprintf-tests: Likewise.
98495         * modules/unistdio/u32-asnprintf-tests: Likewise.
98496         * modules/unistdio/u32-vasnprintf-tests: Likewise.
98497         * modules/unistdio/u32-vasprintf-tests: Likewise.
98498         * modules/unistdio/u32-vsnprintf-tests: Likewise.
98499         * modules/unistdio/u32-vsprintf-tests: Likewise.
98500         * modules/unistdio/ulc-asnprintf-tests: Likewise.
98501         * modules/unistdio/ulc-vasnprintf-tests: Likewise.
98502         * modules/unistdio/ulc-vasprintf-tests: Likewise.
98503         * modules/unistdio/ulc-vsnprintf-tests: Likewise.
98504         * modules/unistdio/ulc-vsprintf-tests: Likewise.
98505         * modules/unistr/u8-check-tests: Likewise.
98506         * modules/unistr/u8-chr-tests: Likewise.
98507         * modules/unistr/u8-cmp-tests: Likewise.
98508         * modules/unistr/u8-cmp2-tests: Likewise.
98509         * modules/unistr/u8-cpy-alloc-tests: Likewise.
98510         * modules/unistr/u8-cpy-tests: Likewise.
98511         * modules/unistr/u8-mblen-tests: Likewise.
98512         * modules/unistr/u8-mbsnlen-tests: Likewise.
98513         * modules/unistr/u8-mbtouc-tests: Likewise.
98514         * modules/unistr/u8-mbtouc-unsafe-tests: Likewise.
98515         * modules/unistr/u8-mbtoucr-tests: Likewise.
98516         * modules/unistr/u8-move-tests: Likewise.
98517         * modules/unistr/u8-next-tests: Likewise.
98518         * modules/unistr/u8-prev-tests: Likewise.
98519         * modules/unistr/u8-set-tests: Likewise.
98520         * modules/unistr/u8-stpcpy-tests: Likewise.
98521         * modules/unistr/u8-stpncpy-tests: Likewise.
98522         * modules/unistr/u8-strcat-tests: Likewise.
98523         * modules/unistr/u8-strcmp-tests: Likewise.
98524         * modules/unistr/u8-strcoll-tests: Likewise.
98525         * modules/unistr/u8-strcpy-tests: Likewise.
98526         * modules/unistr/u8-strdup-tests: Likewise.
98527         * modules/unistr/u8-strlen-tests: Likewise.
98528         * modules/unistr/u8-strmblen-tests: Likewise.
98529         * modules/unistr/u8-strmbtouc-tests: Likewise.
98530         * modules/unistr/u8-strncat-tests: Likewise.
98531         * modules/unistr/u8-strncmp-tests: Likewise.
98532         * modules/unistr/u8-strncpy-tests: Likewise.
98533         * modules/unistr/u8-strnlen-tests: Likewise.
98534         * modules/unistr/u8-to-u16-tests: Likewise.
98535         * modules/unistr/u8-to-u32-tests: Likewise.
98536         * modules/unistr/u8-uctomb-tests: Likewise.
98537         * modules/unistr/u16-check-tests: Likewise.
98538         * modules/unistr/u16-chr-tests: Likewise.
98539         * modules/unistr/u16-cmp-tests: Likewise.
98540         * modules/unistr/u16-cmp2-tests: Likewise.
98541         * modules/unistr/u16-cpy-alloc-tests: Likewise.
98542         * modules/unistr/u16-cpy-tests: Likewise.
98543         * modules/unistr/u16-mblen-tests: Likewise.
98544         * modules/unistr/u16-mbsnlen-tests: Likewise.
98545         * modules/unistr/u16-mbtouc-tests: Likewise.
98546         * modules/unistr/u16-mbtouc-unsafe-tests: Likewise.
98547         * modules/unistr/u16-mbtoucr-tests: Likewise.
98548         * modules/unistr/u16-move-tests: Likewise.
98549         * modules/unistr/u16-next-tests: Likewise.
98550         * modules/unistr/u16-prev-tests: Likewise.
98551         * modules/unistr/u16-set-tests: Likewise.
98552         * modules/unistr/u16-stpcpy-tests: Likewise.
98553         * modules/unistr/u16-stpncpy-tests: Likewise.
98554         * modules/unistr/u16-strcat-tests: Likewise.
98555         * modules/unistr/u16-strcmp-tests: Likewise.
98556         * modules/unistr/u16-strcoll-tests: Likewise.
98557         * modules/unistr/u16-strcpy-tests: Likewise.
98558         * modules/unistr/u16-strdup-tests: Likewise.
98559         * modules/unistr/u16-strlen-tests: Likewise.
98560         * modules/unistr/u16-strmblen-tests: Likewise.
98561         * modules/unistr/u16-strmbtouc-tests: Likewise.
98562         * modules/unistr/u16-strncat-tests: Likewise.
98563         * modules/unistr/u16-strncmp-tests: Likewise.
98564         * modules/unistr/u16-strncpy-tests: Likewise.
98565         * modules/unistr/u16-strnlen-tests: Likewise.
98566         * modules/unistr/u16-to-u32-tests: Likewise.
98567         * modules/unistr/u16-to-u8-tests: Likewise.
98568         * modules/unistr/u16-uctomb-tests: Likewise.
98569         * modules/unistr/u32-check-tests: Likewise.
98570         * modules/unistr/u32-chr-tests: Likewise.
98571         * modules/unistr/u32-cmp-tests: Likewise.
98572         * modules/unistr/u32-cmp2-tests: Likewise.
98573         * modules/unistr/u32-cpy-alloc-tests: Likewise.
98574         * modules/unistr/u32-cpy-tests: Likewise.
98575         * modules/unistr/u32-mblen-tests: Likewise.
98576         * modules/unistr/u32-mbsnlen-tests: Likewise.
98577         * modules/unistr/u32-mbtouc-tests: Likewise.
98578         * modules/unistr/u32-mbtouc-unsafe-tests: Likewise.
98579         * modules/unistr/u32-mbtoucr-tests: Likewise.
98580         * modules/unistr/u32-move-tests: Likewise.
98581         * modules/unistr/u32-next-tests: Likewise.
98582         * modules/unistr/u32-prev-tests: Likewise.
98583         * modules/unistr/u32-set-tests: Likewise.
98584         * modules/unistr/u32-stpcpy-tests: Likewise.
98585         * modules/unistr/u32-stpncpy-tests: Likewise.
98586         * modules/unistr/u32-strcat-tests: Likewise.
98587         * modules/unistr/u32-strcmp-tests: Likewise.
98588         * modules/unistr/u32-strcoll-tests: Likewise.
98589         * modules/unistr/u32-strcpy-tests: Likewise.
98590         * modules/unistr/u32-strdup-tests: Likewise.
98591         * modules/unistr/u32-strlen-tests: Likewise.
98592         * modules/unistr/u32-strmblen-tests: Likewise.
98593         * modules/unistr/u32-strmbtouc-tests: Likewise.
98594         * modules/unistr/u32-strncat-tests: Likewise.
98595         * modules/unistr/u32-strncmp-tests: Likewise.
98596         * modules/unistr/u32-strncpy-tests: Likewise.
98597         * modules/unistr/u32-strnlen-tests: Likewise.
98598         * modules/unistr/u32-to-u16-tests: Likewise.
98599         * modules/unistr/u32-to-u8-tests: Likewise.
98600         * modules/unistr/u32-uctomb-tests: Likewise.
98601         * modules/uniwbrk/u8-wordbreaks-tests: Likewise.
98602         * modules/uniwbrk/u16-wordbreaks-tests: Likewise.
98603         * modules/uniwbrk/u32-wordbreaks-tests: Likewise.
98604         * modules/uniwbrk/ulc-wordbreaks-tests: Likewise.
98605         * modules/uniwidth/u8-strwidth-tests: Likewise.
98606         * modules/uniwidth/u8-width-tests: Likewise.
98607         * modules/uniwidth/u16-strwidth-tests: Likewise.
98608         * modules/uniwidth/u16-width-tests: Likewise.
98609         * modules/uniwidth/u32-strwidth-tests: Likewise.
98610         * modules/uniwidth/u32-width-tests: Likewise.
98611         * modules/uniwidth/width-tests: Likewise.
98613 2010-05-18  Richard Jones  <rjones@redhat.com>
98615         doc: users.txt: list hivex
98616         * users.txt: Add hivex.
98618 2010-05-18  Richard Jones  <rjones@redhat.com>
98620         doc: users.txt: list febootstrap
98621         * users.txt: Add febootstrap.
98623 2010-05-17  Giuseppe Scrivano  <gscrivano@gnu.org>
98625         bootstrap: fix an error when gnulib is not used as a git submodule
98626         * build-aux/bootstrap (gnulib_path): If its length is zero then
98627         assign "gnulib" to it.
98628         * build-aux/bootstrap: Redirect "git clone -h" stderr to stdout.
98630 2010-05-16  Bruno Haible  <bruno@clisp.org>
98632         Avoid autoconf warnings about AM_ICONV.
98633         * m4/iconv.m4 (AM_ICONV): Define using AC_DEFUN_ONCE for autoconf >=
98634         2.64.
98636 2010-05-16  Bruno Haible  <bruno@clisp.org>
98638         absolute-header: Make the macro usable in more situations.
98639         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): New macro, extracted
98640         from gl_ABSOLUTE_HEADER.
98641         (gl_ABSOLUTE_HEADER): Use it. Fix comment.
98643 2010-05-16  James Youngman  <jay@gnu.org>
98645         doc: update users.txt
98646         * users.txt: Add CSSC.
98648 2010-05-16  Jim Meyering  <meyering@redhat.com>
98650         init.sh: fix an error in the previous change; add more comments
98651         * tests/init.sh: Compare exit code in loop against 9, not 2.
98652         Patch by Bruno Haible.
98653         Make the two tests more similar by adding an empty "then" clause.
98654         Add comments.
98656         init.sh: avoid unnecessary shell re-exec
98657         * tests/init.sh: Improve the re-exec-required check to first test the
98658         current shell.  If it passes the test, do not search for a shell that
98659         does pass, and do not re-exec.  This test is particularly contorted to
98660         avoid triggering misbehavior in Solaris 10's /bin/sh whereby any use
98661         of $(...) evokes a syntax error and causes immediate shell exit with
98662         status 2.  Bruno Haible reported that the re-exec made it impossible
98663         to single-step through any init.sh-using script.
98665 2010-05-16  Bruno Haible  <bruno@clisp.org>
98667         Fix collision between gnulib's and libintl's printf replacements.
98668         * lib/stdio.in.h (_GL_STDIO_STRINGIZE,
98669         _GL_STDIO_MACROEXPAND_AND_STRINGIZE): New macros.
98670         (printf): When using GNU C, map the __printf__ function to rpl_printf
98671         via __asm__. When not using GNU C, define rpl_printf instead of
98672         __printf__.
98673         * lib/printf.c: Ignore DEPENDS_ON_LIBINTL. Undoes the 2010-03-25
98674         commit.
98675         * lib/stdio-write.c: Ignore DEPENDS_ON_LIBINTL. Undoes the 2009-08-10
98676         commit.
98677         * m4/asm-underscore.m4: New file.
98678         * m4/stdio_h.m4 (gl_STDIO_H): Require gl_ASM_SYMBOL_PREFIX.
98679         * modules/stdio (Files): Add m4/asm-underscore.m4.
98680         (Makefile.am): Substitute ASM_SYMBOL_PREFIX.
98681         Reported by Ben Pfaff.
98683 2010-05-16  Bruno Haible  <bruno@clisp.org>
98685         verify: Avoid skipping the test on openSUSE 11.0.
98686         * tests/test-verify.sh: Unset MALLOC_PERTURB_.
98688 2010-05-13  Bruno Haible  <bruno@clisp.org>
98690         Avoid useless warnings from G++.
98691         * build-aux/c++defs.h (_GL_CXXALIASWARN_2, _GL_CXXALIASWARN1_2): Don't
98692         use _GL_WARN_ON_USE or _GL_WARN_ON_USE_CXX when optimizing.
98693         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
98695 2010-05-11  Jim Meyering  <meyering@redhat.com>
98697         maint.mk: tweak preceding change
98698         * top/maint.mk (gl_extract_significant_defines_): Make exclusion
98699         regexps tighter by anchoring at EOL, and make the new group "shy"
98700         for slightly decreased overhead.
98702 2010-05-11  Eric Blake  <eblake@redhat.com>
98704         maint.mk: gnulib doesn't guarantee NSIG
98705         * top/maint.mk (gl_extract_significant_defines_): Exclude NSIG.
98707 2010-05-10  Peter O'Gorman  <pogma@thewrittenword.com>
98709         test-pwrite.c: Remove unused variable declaration.
98710         * tests/test-pwrite.c (main): Remove read_buf declaration.
98712         Remove useless test-pwrite.sh file.
98713         * tests/test-pwrite.sh: Delete file.
98714         * modules/pwrite-tests: Remove references.
98715         Reported by Bruno Haible.
98717 2010-05-10  Peter O'Gorman  <pogma@thewrittenword.com>
98719         init.sh: fix a typo
98720         * tests/init.sh: Correct typo in MALLOC_PERTURB_ initialization.
98722 2010-05-10  Jim Meyering  <meyering@redhat.com>
98724         maint.mk: avoid using a temporary file in the always-defined-macros check
98725         * top/maint.mk (.re-defmac): Remove rule.
98726         (gl_trap_): Remove definition.
98727         (sc_prohibit_always-defined_macros): Rewrite not to create and
98728         depend on a temporary file.  Instead, depend on GNU grep's ability
98729         to read a list of regular expressions from stdin when given "-f -".
98731 2010-05-09  Bruno Haible  <bruno@clisp.org>
98733         Update to GNU gettext 0.18, part 1.
98734         * m4/gettext.m4: Update to GNU gettext 0.18.
98735         * m4/intl.m4: Likewise.
98736         * m4/po.m4: Likewise.
98737         * modules/gettext (Files): Add m4/fcntl-o.m4.
98738         (configure.ac): Require gettext infrastructure from version 0.18.
98740 2010-05-09  Jim Meyering  <meyering@redhat.com>
98742         init.sh: enable MALLOC_PERTURB_
98743         * tests/init.sh: Enable glibc's malloc-perturbing option.
98745         maint.mk: improve sc_cross_check_PATH_usage_in_tests
98746         With my recent change in init.sh from the two-line form:
98747             -#   : ${srcdir=.}
98748             -#   . "$srcdir/init.sh"; path_prepend_ .
98749             +#   . "${srcdir=.}/init.sh"; path_prepend_ .
98750         I noticed that using the one-line form would cause this test
98751         to fail with a false-positive, or to stop working altogether,
98752         depending on whether help-version changed or all the tests did.
98753         * top/maint.mk (_hv_regex): Remove this definition.
98754         (_hv_regex_weak): Use a weak regex to select all init.sh-sourcing files.
98755         (_hv_regex_strong): Use a stronger regex to check for conformance.
98756         (sc_cross_check_PATH_usage_in_tests): Rewrite to use the above.
98757         Give a separate diagnostic for lack of conforming use.
98759         maint.mk: prohibit definition of symbols defined by gnulib
98760         * top/maint.mk (sc_prohibit_always-defined_macros): Reject the
98761         definition of symbols defined by gnulib.
98763 2010-05-09  Bruno Haible  <bruno@clisp.org>
98765         acl: Avoid test failure on Cygwin-hosted mingw.
98766         * tests/test-set-mode-acl.sh: Skip test if USE_ACL is 0.
98768 2010-05-09  Bruno Haible  <bruno@clisp.org>
98770         error: Use system's fcntl function.
98771         * lib/error.c (fcntl): Undefine.
98773 2010-05-09  Jim Meyering  <meyering@redhat.com>
98775         verify: adjust formatting to be more consistent
98776         * lib/verify.h (_GL_GENSYM): Add a space before each of a few
98777         argument-list '('s, and after one comma.
98779 2010-05-09  Bruno Haible  <bruno@clisp.org>
98781         error: More reliable output on mingw.
98782         * lib/error.c: Include <windows.h>.
98783         (is_open): New function.
98784         (flush_stdout): Call it instead of fcntl, also if F_GETFL is not
98785         defined.
98787 2010-05-09  Bruno Haible  <bruno@clisp.org>
98789         vasnprintf: Fix syntax errors in libintl build on mingw.
98790         * lib/vasnprintf.c (VASNPRINTF): Move a closing brace. Undefine
98791         pad_ourselves and prec_ourselves after use.
98793 2010-05-08  Bruno Haible  <bruno@clisp.org>
98795         * lib/config.charset: Update comments for Cygwin 1.7.
98796         * lib/localcharset.c: Likewise.
98798 2010-05-07  Jim Meyering  <meyering@redhat.com>
98800         init.sh: improve comments
98801         * tests/init.sh: Recommend the one-line init.sh-sourcing idiom:
98802         . "${srcdir=.}/init.sh"; path_prepend_ .
98803         Add a note about path_prepend_ and the alternative of using
98804         TESTS_ENVIRONMENT.
98806 2010-05-06  Sergey Poznyakoff  <gray@gnu.org.ua>
98808         exclude: Unescape hashed patterns in wildcard mode.
98809         * lib/exclude.c (add_exclude): Unescape the pattern before adding it
98810         to the hash list.
98811         * tests/test-exclude8.sh: New test case.
98812         * modules/exclude-tests: Add new test.
98814 2010-05-05  Eric Blake  <eblake@redhat.com>
98816         verify: automate tests
98817         * modules/verify-tests: New module.
98818         * tests/test-verify.sh: New file.
98819         * tests/test-verify.c: Guard each negative test with a unique id.
98820         Also avoid warning about unused left hand of comma expressions.
98822 2010-05-05  Paul Eggert  <eggert@cs.ucla.edu>
98824         Further improvements to verify.h, suggested by Eric Blake.
98825         * lib/verify.h (_GL_CONCAT, _GL_CONCAT0, _GL_GENSYM): Renamed from
98826         the GL_* versions, to avoid collision with OpenGL.
98827         (_GL_COUNTER): New macro, so that we can fall back on __LINE__ if
98828         __COUNTER__ doesn't work.  Test that __COUNTER__ increments rather
98829         than testing merely whether it's defined.
98831         Modify verify.h to pacify gcc -Wredundant_decls.
98832         * lib/verify.h (GL_CONCAT, GL_CONCAT0, GL_GENSYM): New macros.
98833         These use the prefix "GL_" since they're likely to be useful elsewhere.
98834         We may need to break them out into a different .h file.
98835         (__COUNTER__): Define to 0 if the compiler doesn't support it.
98836         (verify) [!defined __cplusplus]: Use them to avoid duplicate decls
98837         of verify_function__.
98839 2010-05-05  Peter O'Gorman  <pogma@thewrittenword.com>
98841         Tests for module pwrite.
98842         * modules/pwrite-tests: New file.
98843         * tests/test-pwrite.sh: New file.
98844         * tests/test-pwrite.c: New file.
98846         New module pwrite.
98847         * lib/unistd.in.h (pwrite): New declaration.
98848         * lib/pwrite.c: New file, from glibc with modifications.
98849         * m4/pwrite.m4: New file.
98850         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether pwrite is declared.
98851         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_PWRITE, HAVE_PWRITE,
98852         REPLACE_PWRITE.
98853         * modules/pwrite: New file.
98854         * modules/unistd (Makefile.am): Substitute GNULIB_PWRITE, HAVE_PWRITE,
98855         REPLACE_PWRITE.
98856         * tests/test-unistd-c++.cc: Check GNULIB_NAMESPACE::pwrite.
98857         * doc/posix-functions/pwrite.texi: Mention the new module.
98859 2010-05-05  Peter O'Gorman  <pogma@thewrittenword.com>
98861         pread: Update documentation.
98862         * doc/posix-functions/pread.texi: Mention the 'pread' module.
98864 2010-05-04  Eric Blake  <eblake@redhat.com>
98866         docs: update cygwin progress
98867         * doc/posix-functions/wctob.texi (wctob): Cygwin 1.7.6 will fix
98868         this bug.
98869         * doc/glibc-functions/get_nprocs_conf.texi (get_nprocs_conf):
98870         Added in cygwin 1.7.2.
98871         * doc/glibc-functions/get_phys_pages.texi (get_phys_pages):
98872         Likewise.
98873         * doc/glibc-functions/get_avphys_pages.texi (get_avphys_pages):
98874         Likewise.
98875         * doc/glibc-functions/dup3.texi (dup3): Likewise.
98876         * doc/glibc-functions/pipe2.texi (pipe2): Likewise.
98877         * doc/glibc-functions/accept4.texi (accept4): Likewise.
98878         * doc/posix-functions/strfmon.texi (strfmon): Likewise.
98879         * doc/glibc-functions/get_nprocs.texi (get_nprocs): Likewise.
98880         Mention nproc module.
98881         * doc/glibc-functions/xdr_uint16_t.texi (xdr_uint16_t): Mention
98882         bug in cygwin 1.7.5 addition.
98883         * doc/glibc-functions/xdr_uint32_t.texi (xdr_uint32_t): Likewise.
98884         * doc/glibc-functions/xdr_uint64_t.texi (xdr_uint64_t): Likewise.
98885         * doc/glibc-functions/xdr_uint8_t.texi (xdr_uint8_t): Likewise.
98886         * doc/glibc-functions/xdr_array.texi (xdr_array): Added in cygwin
98887         1.7.5.
98888         * doc/glibc-functions/xdr_bool.texi (xdr_bool): Likewise.
98889         * doc/glibc-functions/xdr_bytes.texi (xdr_bytes): Likewise.
98890         * doc/glibc-functions/xdr_char.texi (xdr_char): Likewise.
98891         * doc/glibc-functions/xdr_double.texi (xdr_double): Likewise.
98892         * doc/glibc-functions/xdr_enum.texi (xdr_enum): Likewise.
98893         * doc/glibc-functions/xdr_float.texi (xdr_float): Likewise.
98894         * doc/glibc-functions/xdr_free.texi (xdr_free): Likewise.
98895         * doc/glibc-functions/xdr_hyper.texi (xdr_hyper): Likewise.
98896         * doc/glibc-functions/xdr_int.texi (xdr_int): Likewise.
98897         * doc/glibc-functions/xdr_int16_t.texi (xdr_int16_t): Likewise.
98898         * doc/glibc-functions/xdr_int32_t.texi (xdr_int32_t): Likewise.
98899         * doc/glibc-functions/xdr_int64_t.texi (xdr_int64_t): Likewise.
98900         * doc/glibc-functions/xdr_int8_t.texi (xdr_int8_t): Likewise.
98901         * doc/glibc-functions/xdr_long.texi (xdr_long): Likewise.
98902         * doc/glibc-functions/xdr_longlong_t.texi (xdr_longlong_t):
98903         Likewise.
98904         * doc/glibc-functions/xdr_netobj.texi (xdr_netobj): Likewise.
98905         * doc/glibc-functions/xdr_opaque.texi (xdr_opaque): Likewise.
98906         * doc/glibc-functions/xdr_pointer.texi (xdr_pointer): Likewise.
98907         * doc/glibc-functions/xdr_reference.texi (xdr_reference):
98908         Likewise.
98909         * doc/glibc-functions/xdr_short.texi (xdr_short): Likewise.
98910         * doc/glibc-functions/xdr_sizeof.texi (xdr_sizeof): Likewise.
98911         * doc/glibc-functions/xdr_string.texi (xdr_string): Likewise.
98912         * doc/glibc-functions/xdr_u_char.texi (xdr_u_char): Likewise.
98913         * doc/glibc-functions/xdr_u_hyper.texi (xdr_u_hyper): Likewise.
98914         * doc/glibc-functions/xdr_u_int.texi (xdr_u_int): Likewise.
98915         * doc/glibc-functions/xdr_u_long.texi (xdr_u_long): Likewise.
98916         * doc/glibc-functions/xdr_u_longlong_t.texi (xdr_u_longlong_t):
98917         Likewise.
98918         * doc/glibc-functions/xdr_u_short.texi (xdr_u_short): Likewise.
98919         * doc/glibc-functions/xdr_union.texi (xdr_union): Likewise.
98920         * doc/glibc-functions/xdr_vector.texi (xdr_vector): Likewise.
98921         * doc/glibc-functions/xdr_void.texi (xdr_void): Likewise.
98922         * doc/glibc-functions/xdr_wrapstring.texi (xdr_wrapstring):
98923         Likewise.
98924         * doc/glibc-functions/xdrmem_create.texi (xdrmem_create):
98925         Likewise.
98926         * doc/glibc-functions/xdrrec_create.texi (xdrrec_create):
98927         Likewise.
98928         * doc/glibc-functions/xdrrec_endofrecord.texi
98929         (xdrrec_endofrecord): Likewise.
98930         * doc/glibc-functions/xdrrec_eof.texi (xdrrec_eof): Likewise.
98931         * doc/glibc-functions/xdrrec_skiprecord.texi (xdrrec_skiprecord):
98932         Likewise.
98933         * doc/glibc-functions/xdrstdio_create.texi (xdrstdio_create):
98934         Likewise.
98936 2010-05-04  Jim Meyering  <meyering@redhat.com>
98938         gendocs.sh: make its "-s FILE" option more useful
98939         * build-aux/gendocs.sh: When honoring the -s FILE option, update
98940         $PACKAGE to reflect the probably-different basename of "FILE".
98942 2010-05-03  Giuseppe Scrivano  <gscrivano@gnu.org>
98944         bootstrap: don't ignore download_po_files failure
98945         * build-aux/bootstrap (update_po_files): Don't ignore download_po_files
98946         failure.
98948 2010-05-03  Jim Meyering  <meyering@redhat.com>
98950         maint.mk: allow to pass options to gendocs.sh
98951         * top/maint.mk (web-manual): Pass gendocs_options_ to gendocs.sh.
98952         (gendocs_options_): New overridable variable.
98954         gnu-web-doc-update: don't ignore configure or build failure
98955         * build-aux/gnu-web-doc-update: Exit nonzero upon internal failure.
98957         announce-gen: backslash-escape '@'s in --help output
98958         * build-aux/announce-gen: Fix syntax errors.
98960         maint.mk, announce-gen: allow project-specific announcement mail headers
98961         * top/maint.mk (translation_project_): Define default.
98962         (announcement_Cc_, announcement_mail_headers_): Likewise.
98963         (announcement): Invoke announce-gen with new --mail-headers option.
98964         * build-aux/announce-gen: New option: --mail-headers=HEADERS.
98966         test-xalloc-die: avoid unwarranted test failure on OpenSolaris 5.11
98967         * tests/test-xalloc-die.sh: Redirect stdout before stderr, (i.e.,
98968         "> out 2> err", rather than "2> err > out").  Otherwise, with /bin/sh
98969         on OpenSolaris 5.11 snv_134, we would end up with a stray "1> out"
98970         line in the "err2" output file when running "make check" in verbose
98971         mode (i.e., with set -x enabled).
98973 2010-05-03  Bruno Haible  <bruno@clisp.org>
98975         wctob: Fix for weird platforms.
98976         * lib/wctob.c (wctob): When wint_t is larger than wchar_t, check the
98977         argument value.
98979 2010-05-03  Jim Meyering  <meyering@redhat.com>
98981         maint.mk: prohibit unwarranted use of <strings.h>
98982         * top/maint.mk (sc_prohibit_strings_without_use): Reject inclusion of
98983         strings.h in a file that does not also use strcasecmp, strncasecmp,
98984         ffs or ffsll.
98986         maint.mk: remove obsolete comments
98987         * top/maint.mk: Remove stale, commented-out rules.
98989 2010-05-02  Bruno Haible  <bruno@clisp.org>
98991         wcwidth: Declare also when it's aliased.
98992         * lib/wchar.in.h (wcwidth): Don't test whether wcwidth is defined as a
98993         macro.
98995 2010-05-02  Bruno Haible  <bruno@clisp.org>
98997         Fix regression from 2010-04-25.
98998         * gnulib-tool (func_modules_transitive_closure): Check the status of
98999         all modules, not only of the tests that are of the form foo-tests where
99000         foo is a module.
99002 2010-05-02  Bruno Haible  <bruno@clisp.org>
99004         wctob: Work around nasty Cygwin 1.7.2 bug.
99005         * m4/wctob.m4 (gl_FUNC_WCTOB): Detect the Cygwin bug.
99006         * doc/posix-functions/wctob.texi: Mention the Cygwin bug.
99008 2010-05-01  Bruno Haible  <bruno@clisp.org>
99010         fpurge: Sharper test.
99011         * tests/test-fpurge.c (main): Add one more ftell check.
99012         * modules/fpurge-tests (Depends-on): Add ftell.
99013         Suggested by Eric Blake.
99015 2010-05-01  Bruno Haible  <bruno@clisp.org>
99017         ftello: Another test.
99018         * tests/test-ftello3.c: New file.
99019         * modules/ftello-tests (Files): Add it.
99020         (Makefile.am): Add it to TESTS and check_PROGRAMS. Augment
99021         MOSTLYCLEANFILES.
99023         ftell: Another test.
99024         * tests/test-ftell3.c: New file.
99025         * modules/ftell-tests (Files): Add it.
99026         (Makefile.am): Add it to TESTS and check_PROGRAMS. Augment
99027         MOSTLYCLEANFILES.
99029 2010-05-01  Bruno Haible  <bruno@clisp.org>
99031         ftell, ftello: Work around Solaris bug.
99032         * m4/ftello.m4 (gl_FUNC_FTELLO): Detect Solaris bug.
99033         * lib/ftello.c: Include stdio-impl.h.
99034         (ftello): On Solaris, when _IOWRT is set, compute the result without
99035         looking at _IOREAD.
99036         * modules/ftello (Files): Add lib/stdio-impl.h.
99037         * doc/posix-functions/ftell.texi: Mention Solaris bug.
99038         * doc/posix-functions/ftello.texi: Likewise.
99039         Reported by Eric Blake.
99041 2010-05-01  Bruno Haible  <bruno@clisp.org>
99043         freading: Adapt to special meaning of _IOREAD flag on Solaris.
99044         * lib/freading.c (freading): On Solaris, ignore the _IOREAD flag if
99045         the _IOWRT flag is also set.
99047 2010-05-01  Bruno Haible  <bruno@clisp.org>
99049         Fix doc about a HP-UX stdio bug.
99050         * doc/posix-functions/ftell.texi: Mark HP-UX bug as unfixed.
99051         * doc/posix-functions/ftello.texi: Likewise.
99053 2010-05-01  Bruno Haible  <bruno@clisp.org>
99055         lseek test: Fix failure on Solaris.
99056         * tests/test-lseek.sh: Partially revert 2010-04-20 commit. Consume all
99057         output.
99059 2010-04-30  Jim Meyering  <meyering@redhat.com>
99061         bootstrap: don't ignore failure to generate po*/Makevars
99062         * build-aux/bootstrap (with_gettext): Don't ignore failure
99063         to create po/Makevars or runtime-po/Makevars.
99065 2010-04-29  Eric Blake  <eblake@redhat.com>
99067         headers: relax license to LGPLv2+
99068         * modules/fcntl-h (License): Relax license.
99069         * modules/getopt-posix (License): Likewise.
99070         * modules/locale (License): Likewise.
99071         * modules/math (License): Likewise.
99072         * modules/pty (License): Likewise.
99073         * modules/sched (License): Likewise.
99074         * modules/search (License): Likewise.
99075         * modules/spawn (License): Likewise.
99076         * modules/stdarg (License): Likewise.
99077         * modules/sysexits (License): Likewise.
99079 2010-04-29  Jim Meyering  <meyering@redhat.com>
99081         inttypes: relax license to LGPLv2+
99082         * modules/inttypes (License): Relax license.
99084 2010-04-29  Simon Josefsson  <simon@josefsson.org>
99086         * top/maint.mk (indent): Run twice to produce idempotent results.
99088 2010-04-28  Bruno Haible  <bruno@clisp.org>
99090         getdate: Generate getdate.c in the source directory.
99091         * modules/getdate (Makefile.am): Add rule for getdate.c. Augment
99092         MOSTLYCLEANFILES.
99093         Suggested by Daniel Richard G. <skunk@iskunk.org> and Ralf Wildenhues.
99095 2010-04-27  Andreas Gruenbacher  <agruen@suse.de>  (tiny change)
99097         * lib/utimens.c: On Tru64, the timestamp parameter of utimens(2)
99098         is not declared as a const *; avoid warnings in that case.
99100 2010-04-28  Eric Blake  <eblake@redhat.com>
99102         canonicalize-lgpl: avoid compiler warning
99103         * lib/canonicalize-lgpl.c (versioned_symbol): Avoid an 'empty
99104         declaration' / 'extraneous semicolon' warning with some compilers.
99105         Reported by Andreas Gruenbacher.
99107 2010-04-28  Jim Meyering  <meyering@redhat.com>
99109         init.sh: ensure a more reliable exit status when exiting via trap
99110         * tests/init.sh (setup_): Don't rely on $? in signal handler.
99111         Inspired by patches from Dmitry V. Levin.
99112         Also trap on signal 3 (SIGQUIT).
99114 2010-04-27  Bruno Haible  <bruno@clisp.org>
99116         Update doc about utimes().
99117         * doc/posix-functions/utimes.texi: Mention the OSF/1 problem and the
99118         'utimens' module.
99119         Reported by Andreas Gruenbacher <agruen@suse.de>.
99121 2010-04-27  Eric Blake  <eblake@redhat.com>
99123         full-read, full-write: relax license
99124         * modules/full-read (License): Drop to LGPLv2+.
99125         * modules/full-write (License): Likewise.
99126         * modules/safe-read (License): Likewise.
99127         * modules/safe-write (License): Likewise.
99129         pthread: mention library for linking
99130         * modules/pthread (Link): Mention $(LIB_PTHREAD).
99132 2010-04-27  Jim Meyering  <meyering@redhat.com>
99134         maint.mk: fix a bug introduced in last change
99135         * top/maint.mk (gl_assured_headers_): Now that all names are on
99136         one line, use sed's "g" modifier.  Note that while the \.in\.h LHS
99137         is not anchored to end of word, it should be adequate.
99139         maint.mk: avoid side-effect in latest syntax-check
99140         * top/maint.mk (sc_prohibit_always_true_header_tests): Rework not
99141         to run commands via $(shell...), and hence to incur cost only when
99142         the new rule is actually run.
99144         maint.mk: syntax-check: prohibit HAVE_<header>_H that are always true
99145         Derive the list of guaranteed header names from gnulib/lib/*.in.h,
99146         and use that to create a regexp used to detect all #if HAVE_..._H uses.
99147         * top/maint.mk (sc_prohibit_always_true_header_tests): New rule.
99148         (gl_assured_headers_, az_, AZ_): Define.
99149         (gl_header_upper_case_or_, gl_have_header_regex_): Define.
99151 2010-04-26  Jim Meyering  <jim@meyering.net>
99152             Bruno Haible  <bruno@clisp.org>
99154         gnulib-common.m4: make glibc write diagnostics to stderr, not /dev/tty
99155         * m4/gnulib-common.m4 (gl_COMMON_BODY): Set LIBC_FATAL_STDERR_.
99156         Prompted by an exchange with Gilles Espinasse.
99158 2010-04-26  Jim Meyering  <meyering@redhat.com>
99160         git-version-gen: aesthetic tweak
99161         * build-aux/git-version-gen: Use "$nl" rather than a literal,
99162         so that the command remains on a single line.
99164 2010-04-26  Eric Blake  <eblake@redhat.com>
99166         git-version-gen: allow use on EBCDIC hosts
99167         * build-aux/git-version-gen (dirty): Use literal rather than tying
99168         ourselves to ascii.
99169         Reported by Steve Goetze.
99171 2010-04-25  Bruno Haible  <bruno@clisp.org>
99173         netdb: Add support for GNULIB_POSIXCHECK.
99174         * lib/netdb.in.h: Include warn-on-use.h.
99175         (getaddrinfo, freeaddrinfo, gai_strerror, getnameinfo): Warn if these
99176         functions are used when GNULIB_POSIXCHECK is defined and the
99177         getaddrinfo module is not in use.
99178         * m4/netdb_h.m4 (gl_HEADER_NETDB): Test whether getaddrinfo,
99179         freeaddrinfo, gai_strerror, getnameinfo are declared.
99180         * modules/netdb (Depends-on): Add warn-on-use.
99181         (Makefile.am): Include warn-on-use.h in netdb.h.
99183 2010-04-24  Ian Beckwith  <ianb@erislabs.net>
99185         build: avoid "make check" failure without .git/ directory
99186         * Makefile (sc_prefer_ac_check_funcs_once): Skip this test when
99187         there is no .git/ directory.
99189 2010-04-25  Bruno Haible  <bruno@clisp.org>
99191         ptsname: Fix misuse of ttyname_r.
99192         * lib/ptsname.c (__ptsname_r): Use __ttyname_r's return value instead
99193         of errno.
99195 2010-04-25  Bruno Haible  <bruno@clisp.org>
99197         ttyname_r: Make it work on Solaris 10.
99198         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Define HAVE_POSIXDECL_TTYNAME_R
99199         if the system function has the POSIX declaration. Test whether the
99200         function fails if the buffer is less than 128 bytes large.
99201         * lib/ttyname_r.c (ttyname_r): Handle both possible declarations of the
99202         system's ttyname_r function. Provide a reasonably large buffer.
99203         * modules/ttyname_r (Depends-on): Add extensions.
99204         * doc/posix-functions/ttyname_r.texi: Mention the Solaris problem.
99206 2010-04-25  Bruno Haible  <bruno@clisp.org>
99208         Use the 'extensions' module for some more functions on Solaris.
99209         * doc/posix-functions/asctime_r.texi: Recommend to use the 'extensions'
99210         module.
99211         * doc/posix-functions/ctime_r.texi: Likewise.
99212         * doc/posix-functions/getgrgid_r.texi: Likewise.
99213         * doc/posix-functions/getgrnam_r.texi: Likewise.
99214         * doc/posix-functions/getpwnam_r.texi: Likewise.
99215         * doc/posix-functions/getpwuid_r.texi: Likewise.
99216         * doc/posix-functions/readdir_r.texi: Likewise.
99217         * doc/posix-functions/sigwait.texi: Likewise.
99218         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Add comment.
99219         * doc/posix-functions/getlogin_r.texi: Mark Solaris problem as fixed.
99221 2010-04-25  Bruno Haible  <bruno@clisp.org>
99223         ttyname_r: Make it work on MacOS X 10.4 and Solaris 10.
99224         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test whether the system function
99225         has the POSIX declaration. Set REPLACE_TTYNAME_R if not.
99226         * lib/ttyname_r.c: Include <limits.h>.
99227         (ttyname_r): Define using the system's ttyname_r function, if it exists
99228         and not on Solaris.
99229         * lib/unistd.in.h (ttyname_r): Replace function if REPLACE_TTYNAME_R is
99230         set.
99231         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_TTYNAME_R.
99232         * modules/unistd (Makefile.am): Substitute REPLACE_TTYNAME_R.
99233         * doc/posix-functions/ttyname_r.texi: Mark the problem as fixed.
99234         Reported by Simon Josefsson.
99236 2010-04-25  Bruno Haible  <bruno@clisp.org>
99238         Mention effects of _POSIX_PTHREAD_SEMANTICS on Solaris.
99239         * doc/posix-functions/asctime_r.texi: Mention the Solaris problem.
99240         * doc/posix-functions/ctime_r.texi: Likewise.
99241         * doc/posix-functions/getgrgid_r.texi: Likewise.
99242         * doc/posix-functions/getgrnam_r.texi: Likewise.
99243         * doc/posix-functions/getlogin_r.texi: Likewise.
99244         * doc/posix-functions/getpwnam_r.texi: Likewise.
99245         * doc/posix-functions/getpwuid_r.texi: Likewise.
99246         * doc/posix-functions/readdir_r.texi: Likewise.
99247         * doc/posix-functions/sigwait.texi: Likewise.
99248         * doc/posix-functions/ttyname_r.texi: Likewise.
99249         Reported by Simon Josefsson.
99251 2010-04-25  Bruno Haible  <bruno@clisp.org>
99253         gnulib-tool: Don't include hairy tests of dependencies in testdirs.
99254         * gnulib-tool (func_usage): Document that --with-*-tests options apply
99255         also to --create-testdir.
99256         (func_acceptable): Don't consider the status of *-tests modules here.
99257         (func_modules_transitive_closure): Consider it here, before including a
99258         test module.
99259         (func_import, func_create_testdir): Set inc_all_direct_tests,
99260         inc_all_indirect_tests.
99261         * doc/gnulib.texi (Extra tests modules): Document new behaviour of
99262         --create-testdir and --create-megatestdir.
99264 2010-04-25  Bruno Haible  <bruno@clisp.org>
99266         gnulib-tool: Add --without-*-tests options.
99267         * gnulib-tool (func_usage): Document the --without-*-tests options.
99268         (excl_cxx_tests, excl_longrunning_tests, excl_privileged_tests,
99269         excl_unportable_tests): New variables.
99270         Fail if they are specified with --import or --update.
99271         (func_acceptable): Respect the excl_*_tests variables.
99272         (func_import): Set the excl_*_tests variables to empty.
99274 2010-04-25  Simon Josefsson  <simon@josefsson.org>
99275             Bruno Haible  <bruno@clisp.org>
99277         Work around a MacOS X 10.4 bug with openpty.
99278         * doc/glibc-functions/openpty.texi: Mention the MacOS X 10.4 bug.
99279         * tests/test-openpty.c (main): Close the master side explicitly.
99281 2010-04-25  Bruno Haible  <bruno@clisp.org>
99283         strnlen: Fix a C++ test error on MacOS X and Solaris.
99284         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Don't set REPLACE_STRNLEN to 1 if
99285         the function is not declared.
99286         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com> and
99287         Simon Josefsson.
99289 2010-04-24  Bruno Haible  <bruno@clisp.org>
99291         Avoid a gcc warning.
99292         * tests/test-vasprintf.c (test_vasprintf, test_asprintf): Pass argument
99293         of correct type for %08lx directive.
99294         Reported by Eric Blake.
99296 2010-04-24  Bruno Haible  <bruno@clisp.org>
99298         vasnprintf: Correct errno value in case of out-of-memory.
99299         * lib/vasnprintf.c (VASNPRINTF): Set errno to 0 before calling SNPRINTF
99300         or sprintf. Use the errno value from SNPRINTF or sprintf.
99301         Reported by Ian Beckwith <ianb@erislabs.net>.
99303 2010-04-24  Bruno Haible  <bruno@clisp.org>
99305         ansi-c++-opt: Find correct compiler when cross-compiling.
99306         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): Use AC_CHECK_TOOLS instead of
99307         AC_CHECK_PROGS.
99308         Reported by Simon Josefsson.
99310 2010-04-24  Giuseppe Scrivano  <gscrivano@gnu.org>
99312         vc-list-files: Add support for subversion
99313         * build-aux/vc-list-files: Use "svn list" to generate the list of
99314         files controlled by subversion.
99316 2010-04-23  Jim Meyering  <meyering@redhat.com>
99318         vc-list-files tests: convert to use init.sh
99319         * tests/test-vc-list-files-cvs.sh: Invoke "$srcdir/init.sh" and
99320         path_prepend_.
99321         Use Exit, not exit.
99322         Use skip_ rather than open coding it.
99323         Remove trap set-up and compare definitions.
99324         * tests/test-vc-list-files-git.sh: Likewise.
99325         * modules/vc-list-files-tests (Files): Add tests/init.sh.
99327 2010-04-22  Simon Josefsson  <simon@josefsson.org>
99329         * top/maint.mk (sc_prohibit_backup_files): Prohibit checked in
99330         backup files.
99332 2010-04-21  Simon Josefsson  <simon@josefsson.org>
99334         * tests/test-vasprintf.c (test_vasprintf, test_asprintf): Test %08lx.
99336 2010-04-20  Eric Blake  <eblake@redhat.com>
99338         tests: be robust to ignored SIGPIPE
99339         * tests/test-select-in.sh: Consume all output.
99340         * tests/test-lseek.sh: Check correct exit status, while avoiding
99341         EPIPE.
99343 2010-04-20  Simon Josefsson  <simon@josefsson.org>
99344             Bruno Haible  <bruno@clisp.org>
99346         visibility: Don't use -fvisibility if it leads to a warning.
99347         * m4/visibility.m4 (gl_VISIBILITY): Check whether -Werror is usable. If
99348         yes, don't pretend that visibility works if it leads to a warning.
99349         Reported by Mike Gran <spk121@yahoo.com>.
99351 2010-04-20  Andreas Gruenbacher  <agruen@suse.de>
99353         * build-aux/bootstrap: Use "git -h" for testing for supported options
99354         instead of "git --help".  The short-form option only shows a summary,
99355         and doesn't layout the full man page.  Grep for the full option name
99356         in the summary, too.
99358 2010-04-19  Bruno Haible  <bruno@clisp.org>
99360         relocatable: Drop the need to define RELOCATABLE_STRIP in Makefile.am.
99361         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Set RELOCATABLE_STRIP.
99362         * doc/relocatable-maint.texi (Supporting Relocation): Remove the
99363         mention of RELOCATABLE_STRIP.
99364         Reported by Sylvain Beucler <beuc@beuc.net>.
99366 2010-04-19  Bruno Haible  <bruno@clisp.org>
99368         * lib/diffseq.h: Fix typo in comment.
99369         Reported by Eric Blake.
99371 2010-04-19  Bruno Haible  <bruno@clisp.org>
99373         ioctl: Move autoconf macro to a .m4 file.
99374         * m4/ioctl.m4: New file, extracted from modules/ioctl.
99375         * modules/ioctl (Files): Add it.
99376         (configure.ac): Simply invoke gl_FUNC_IOCTL.
99377         Reported by Ian Beckwith <ianb@erislabs.net>.
99379 2010-04-18  Andreas Gruenbacher  <agruen@suse.de>
99380             Bruno Haible  <bruno@clisp.org>
99382         diffseq: Accommodate use-case with abstract arrays.
99383         * lib/diffseq.h (struct context): Remove xvec, yvec fields if ELEMENT
99384         is not defined.
99385         (diag, compareseq): Remove local variables xv, yv if ELEMENT is not
99386         defined. Use local macro XREF_YREF_EQUAL instead of EQUAL.
99388 2010-04-18  Bruno Haible  <bruno@clisp.org>
99390         * doc/posix-headers/stdbool.texi: More precise wording.
99392 2010-04-17  Jim Meyering  <meyering@redhat.com>
99394         maint.mk: use gnu-style indentation in an embedded perl script
99395         * top/maint.mk (detect_empty_lines_at_EOF_): Clean up formatting.
99396         Rename variable: s/two/last_two_bytes/
99398 2010-04-16  Eric Blake  <eblake@redhat.com>
99400         test-stdbool: skip test that fails with Solaris CC
99401         * tests/test-stdbool.c (f): Skip test that causes compilation
99402         error under buggy C++ compiler.
99403         * lib/stdbool.in.h: Document the limitation.
99404         * doc/posix-headers/stdbool.texi (stdbool.h): Likewise.
99406         setenv: allow compilation with C++
99407         * lib/setenv.c (__add_to_environ): Add a cast.  Also, drop use of
99408         register keyword.
99410         stdint: allow test to pass with C++
99411         * tests/test-stdint.c: Define __STDC_CONSTANT_MACROS, for glibc.
99413         getopt: allow compilation with C++
99414         * lib/getopt_int.h (__ordering): Hoist enum declaration outside
99415         struct.
99416         * lib/getopt.c (_getopt_internal_r): Use correct type.
99417         Reported by Dagobert Michelson, via Joel E. Denny.
99419 2010-04-16  Bruno Haible  <bruno@clisp.org>
99421         Override netdb.h always.
99422         * modules/netdb (Makefile.am): Augment BUILT_SOURCES always.
99423         * m4/netdb_h.m4 (gl_HEADER_NETDB): Don't set NETDB_H.
99424         Reported by Ludovic Courtès <ludo@gnu.org>.
99426 2010-04-15  Bruno Haible  <bruno@clisp.org>
99428         openpty: Fix mistake from 2010-03-21.
99429         * m4/pty.m4 (gl_FUNC_OPENPTY): Define HAVE_OPENPTY when openpty exists.
99430         Reported by Simon Josefsson.
99432 2010-04-15  Eric Blake  <eblake@redhat.com>
99434         test-forkpty: fix expected signature
99435         * tests/test-forkpty.c (SIGNATURE_CHECK): Add appropriate const.
99436         Reported by Simon Josefsson.
99438 2010-04-15  Jim Meyering  <meyering@redhat.com>
99440         maint.mk: texinfo_suffix_re_: correct the default regexp
99441         * top/maint.mk (texinfo_suffix_re_): Fix default regexp.
99443         * top/maint.mk (sc_texinfo_acronym): Improve filename regexp, and
99444         make it configurable via texinfo_suffix_re_.
99446 2010-04-14  Eric Blake  <eblake@redhat.com>
99448         strtok_r: relax license to LGPLv2+
99449         * modules/strtok_r (License): Relax license.
99450         Reported by Matthias Bolte.
99452 2010-04-14  Simon Josefsson  <simon@josefsson.org>
99454         * lib/gc-libgcrypt.c (gc_init): Use MIN_GCRYPT_VERSION set to
99455         version 1.4.4 by default instead of requiring the libgcrypt
99456         version used during build.  This makes it possible to use the
99457         application with older but still binary compatible libgcrypt
99458         versions.
99460 2010-04-13  Eric Blake  <eblake@redhat.com>
99462         getopt-gnu: match recent glibc fixes and posix ruling
99463         * tests/test-getopt.h (test_getopt): Strengthen tests of leading
99464         '+' handling, when requesting extensions.
99465         * tests/test-getopt_long.h (test_getopt_long): Strengthen test of
99466         'W;' handling.
99467         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Detect glibc 2.11 bug.
99468         * doc/posix-functions/getopt.texi (getopt): Document this.
99469         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
99470         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
99471         Likewise.
99473         getopt: merge bug fixes from glibc
99474         * lib/getopt.c (_getopt_internal_r): Use correct message for 'W;'
99475         diagnostics.  Honor '+:' correctly.  Reject ';'.
99477         getopt-posix: detect MacOS bug
99478         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Reject MacOS botch of
99479         optind when missing a required argument.
99480         * doc/posix-functions/getopt.texi (getopt): Document the bug.
99481         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
99482         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
99483         Likewise.
99485         getopt-posix: avoid spurious failure on Solaris
99486         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Check for getopt_clip as
99487         an indicator that setting optind=1 is sufficient for reset.
99489         getopt-posix: avoid spurious failure on FreeBSD
99490         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Check for optreset even
99491         in POSIX mode, since the m4 test uses it.
99493         gnulib-tool: silence warning on BSD sh
99494         * gnulib-tool: Avoid leaking warning about unknown 'declare'.
99496 2010-04-13  Jim Meyering  <meyering@redhat.com>
99498         doc: users.txt: GNU patch now uses gnulib
99499         * users.txt: Add patch.
99501 2010-04-12  Jim Meyering  <meyering@redhat.com>
99503         maint.mk: generate more concise timing data for syntax-check rules
99504         * top/maint.mk ($(sc_z_rules_)): Remove the ":", "sc_" prefix and
99505         " done" from each line that reports a syntax-check test duration.
99507 2010-04-12  Andreas Gruenbacher  <agruen@suse.de>
99509         git-version-gen: use "git update-index..." rather than "git status"
99510         * build-aux/git-version-gen: Use git update-index --refresh, not
99511         "git status".  With some versions of git, "git status" would fail
99512         to update the index and result in an unwarranted "-dirty" suffix.
99514 2010-04-11  Jim Meyering  <meyering@redhat.com>
99516         openat: correct formatting (no semantic change)
99517         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Correct formatting in AC_DEFINE.
99518         Suggested by Bruno Haible.
99520 2010-04-11  Bruno Haible  <bruno@clisp.org>
99522         Stricter declaration checking in testdirs.
99523         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
99524         If for_tests is true, augment AM_CPPFLAGS to define
99525         GNULIB_STRICT_CHECKING.
99526         * build-aux/warn-on-use.h (_GL_WARN_ON_USE, _GL_WARN_ON_USE_CXX): When
99527         GNULIB_STRICT_CHECKING is defined, verify that the function is
99528         declared.
99530 2010-04-11  Paolo Bonzini  <bonzini@gnu.org>
99531             Bruno Haible  <bruno@clisp.org>
99533         libunistring: Improve configure output.
99534         * m4/libunistring.m4 (gl_LIBUNISTRING): Check for libiconv first.
99535         Don't say "consider installing GNU libunistring" when checking again
99536         with libiconv.
99538 2010-04-11  Bruno Haible  <bruno@clisp.org>
99540         libunistring: Correct value of $LTLIBUNISTRING.
99541         * m4/libunistring.m4 (gl_LIBUNISTRING): When it depends on libiconv,
99542         correct the value of $LTLIBUNISTRING.
99544 2010-04-11  Bruno Haible  <bruno@clisp.org>
99546         havelib: Add static libraries to LIBS in the right order.
99547         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): When $LIB[]NAME contains no
99548         -l options, prepend it to $LIBS, instead of appending it to $LIBS.
99550 2010-04-11  Bruno Haible  <bruno@clisp.org>
99552         libunistring: Detect libunistring also when it depends on libiconv.
99553         * m4/libunistring.m4 (gl_LIBUNISTRING): Unset the cached result before
99554         the second AC_LIB_HAVE_LINKFLAGS invocation.
99556 2010-04-11  James Youngman  <jay@gnu.org>
99558         close-stream: declare local scalars to be "const"
99559         * lib/close-stream.c (close_stream): Make boolean variables const
99560         to document the fact that we set but do not change them.
99562 2010-04-11  Bruno Haible  <bruno@clisp.org>
99564         * m4/libunistring.m4 (gl_LIBUNISTRING): Fix typo in comment.
99566 2010-04-11  Jim Meyering  <meyering@redhat.com>
99568         maint.mk: don't include dist-check.mk
99569         * top/maint.mk: Remove bogus include directive.
99571         maint.mk: improve empty-line-at-EOF check
99572         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Use Perl-based
99573         solution, rather than tail+Perl-based one.  The latter would read
99574         a few kilobytes from the end of each file, and did not handle empty
99575         files properly.
99577         maint.mk: print the elapsed time for each syntax-check rule
99578         * top/maint.mk (sc_m_rules_): Save start time in a file.
99579         (sc_z_rules_): New rules: remove temp file and print elapsed time.
99580         (local-check): Interpose the .z rules
99582 2010-04-11  Jim Meyering  <meyering@redhat.com>
99584         maint.mk: detect_empty_lines_at_EOF_: avoid FP for an empty file
99585         * top/maint.mk (detect_empty_lines_at_EOF_): Don't confuse an
99586         empty file with one that ends in an empty line.
99588 2010-04-10  Bruno Haible  <bruno@clisp.org>
99590         mkdir: Make it work on mingw64.
99591         * lib/sys_stat.in.h: Include <direct.h> together with <io.h>.
99592         * lib/mkdir.c: Update comment.
99593         Reported by Roman Donchenko (Роман Донченко) <dxdragon@yandex.ru>.
99595 2010-04-10  Bruno Haible  <bruno@clisp.org>
99597         Don't override improved macro from newer autoconf.
99598         * m4/gnulib-common.m4 (AC_C_RESTRICT): Don't define for
99599         autoconf >= 2.62.
99600         Reported by Joel E. Denny <jdenny@clemson.edu>.
99602 2010-04-10  Jim Meyering  <meyering@redhat.com>
99604         maint.mk: new syntax-check rule: prohibit empty lines at end of file
99605         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): New rule.
99607         maint.mk: correct a diagnostic
99608         * top/maint.mk (sc_prohibit_HAVE_MBRTOWC): Fix obsolete use of $re
99609         in diagnostic; now use $prohibit.
99611 2010-04-10  Bruno Haible  <address@hidden>
99613         fchownat: Fix a C++ test error on Solaris 8.
99614         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Don't set REPLACE_FCHOWNAT to 1 if
99615         the function does not exist.
99617 2010-04-10  Bruno Haible  <bruno@clisp.org>
99619         vasnprintf: Add more tests.
99620         * tests/test-vasnprintf-posix.c: Include <errno.h>.
99621         (test_function): Test converting an invalid wide string.
99623         vasnprintf: Correct handling of unconvertible wide string arguments.
99624         * lib/vasnprintf.c (MAX_ROOM_NEEDED): New function, extracted from
99625         VASNPRINTF.
99626         (VASNPRINTF): Use it. After snprintf failed, allocate more memory only
99627         if HAVE_SNPRINTF_RETVAL_C99 is false and the allocated memory is
99628         smaller than the expected maximum need for the directive. Set errno to
99629         EILSEQ, not EINVAL, when the directive is 'c' or 's'.
99630         (local_strnlen, local_wcslen, local_wcsnlen): Update conditions.
99631         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Require AC_C_INLINE and
99632         gl_SNPRINTF_RETVAL_C99. Define HAVE_SNPRINTF_RETVAL_C99.
99633         * modules/vasnprintf (Files): Add m4/printf.m4.
99634         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
99636 2010-04-10  Bruno Haible  <bruno@clisp.org>
99638         vasnprintf: Fix crash in %ls directive.
99639         * lib/vasnprintf.c (VASNPRINTF): Don't abort when a unconvertible wide
99640         string is passed as argument to %ls, with no precision and no width.
99641         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
99643 2010-04-10  Bruno Haible  <bruno@clisp.org>
99645         vasnprintf: Fix multiple test failures on mingw.
99646         * lib/vasnprintf.c (SNPRINTF) [mingw]: Define to snprintf, not
99647         _snprintf, or snwprintf, not _snwprintf.
99649 2010-04-10  Bruno Haible  <bruno@clisp.org>
99651         write: Fix a C++ test error on mingw.
99652         * lib/unistd.in.h (write): Use _GL_CXXALIAS_SYS_CAST.
99654 2010-04-10  Bruno Haible  <bruno@clisp.org>
99656         vasnprintf test: Reduce code duplication.
99657         * tests/test-vasnprintf.c (test_function): New function, extracted from
99658         test_vasnprintf.
99659         (test_vasnprintf, test_asnprintf): Invoke it.
99661 2010-04-10  Bruno Haible  <bruno@clisp.org>
99663         strnlen: Fix warning in C++ mode on MacOS X.
99664         * lib/string.in.h (strnlen): Use the modern idiom.
99665         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set REPLACE_STRNLEN to 1, instead of
99666         defining strnlen as a macro already in <config.h>.
99667         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
99668         REPLACE_STRNLEN.
99669         * modules/string (Makefile.am): Substitute REPLACE_STRNLEN.
99670         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
99672 2010-04-08  James Youngman  <jay@gnu.org>
99674         * doc/manywarnings.texi (manywarnings): Add missing parenthesis in
99675         the example.
99677 2010-04-09  Jim Meyering  <meyering@redhat.com>
99679         maint.mk: print better diagnostic when there is no $(_hv_file)
99680         * top/maint.mk (sc_cross_check_PATH_usage_in_tests): Skip test and
99681         announce that when $(_hv_file) (aka help-version) does not exist.
99683         init.sh: run tr in the "C" locale to avoid multibyte interpretation
99684         * tests/init.sh (rand_bytes_): Run tr in the "C" locale so it does
99685         not try to interpret its random input bytes.  Jarno Rajahalme reported
99686         that ./test-xalloc-die.sh would fail with "tr: Illegal byte sequence".
99687         on Darwin 10.3.0 with LC_CTYPE=UTF-8.
99688         (mktempd_): Likewise, just in case.
99690         ftruncate: add two years to projected module removal date: 2012
99691         * m4/ftruncate.m4: Adjust comments.
99693         ftruncate: mark module as obsolete; even MinGW provides it, now
99694         * modules/ftruncate (Status): Obsolete.
99695         (Notice): Say that.
99696         * doc/posix-functions/ftruncate.texi: Don't say MinGW lacks it.
99697         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/9203
99699 2010-04-08  Bruno Haible  <bruno@clisp.org>
99701         Fix side effects from tests-related modules.
99702         * modules/dprintf-posix (Comment): New section.
99703         * modules/fprintf-posix (Comment): Likewise.
99704         * modules/obstack-printf-posix (Comment): Likewise.
99705         * modules/printf-posix (Comment): Likewise.
99706         * modules/snprintf-posix (Comment): Likewise.
99707         * modules/sprintf-posix (Comment): Likewise.
99708         * modules/vasnprintf-posix (Comment): Likewise.
99709         * modules/vasprintf-posix (Comment): Likewise.
99710         * modules/vdprintf-posix (Comment): Likewise.
99711         * modules/vfprintf-posix (Comment): Likewise.
99712         * modules/vprintf-posix (Comment): Likewise.
99713         * modules/vsnprintf-posix (Comment): Likewise.
99714         * modules/vsprintf-posix (Comment): Likewise.
99715         * modules/xprintf-posix (Comment): Likewise.
99716         * modules/xvasprintf-posix (Comment): Likewise.
99717         * modules/ceilf-tests (Depends-on): Remove fprintf-posix.
99718         * modules/floorf-tests (Depends-on): Likewise.
99719         * modules/round-tests (Depends-on): Likewise.
99720         * modules/roundf-tests (Depends-on): Likewise.
99721         * modules/trunc-tests (Depends-on): Likewise.
99722         * modules/truncf-tests (Depends-on): Likewise.
99723         * tests/test-ceilf2.c (check): Don't invoke fprintf if the
99724         'fprintf-posix' module is not present.
99725         * tests/test-floorf2.c (check): Likewise.
99726         * tests/test-trunc2.c (check): Likewise.
99727         * tests/test-truncf2.c (check): Likewise.
99728         * tests/test-round2.c (equal): Likewise.
99729         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
99731 2010-04-07  Karl Berry  <karl@gnu.org>
99733         * config/srclist.txt,
99734         * config/srclistvars.sh,
99735         * config/srclist-update: doc fixes.
99737 2010-04-07  Jim Meyering  <meyering@redhat.com>
99739         maint.mk: add a PATH crosschecking syntax-check rule
99740         * top/maint.mk (sc_cross_check_PATH_usage_in_tests): New rule.
99741         Useful if you use a test like the one in help-version (coreutils,
99742         diffutils, grep, gzip) that ensures $(VERSION) matches what is
99743         printed by prog --version.
99745 2010-04-06  Bruno Haible  <bruno@clisp.org>
99747         Fix link error on mingw.
99748         * modules/unistd-c++-tests (test_unistd_c___LDADD): Add LIBSOCKET.
99749         * modules/fcntl-h-c++-tests (test_fcntl_h_c___LDADD): Likewise.
99751 2010-04-06  Bruno Haible  <bruno@clisp.org>
99753         Assume rmdir exists.
99754         * lib/rmdir.c (rpl_rmdir): Remove code that invokes the rmdir program.
99756 2010-04-06  Giuseppe Scrivano  <gscrivano@gnu.org>
99758         doc: update users.txt
99759         * users.txt: Add gcal.
99761 2010-04-06  Jim Meyering  <meyering@redhat.com>
99763         init.sh: simply unset TMPDIR rather than risking env -i
99764         * tests/init.sh (mktempd_): Using env -i is rather harsh, and
99765         although it probably works fine on all Unix-based systems, some
99766         systems (Cygwin?) cannot tolerate a totally cleared environment.
99767         Suggestion from Eric Blake.
99769 2010-04-06  Jim Meyering  <meyering@redhat.com>
99771         init.sh: portability fix: use env's POSIX-specified -i option not -u
99772         * tests/init.sh (mktempd_): Use env -i and set PATH explicitly rather
99773         than unportable env -u.  Solaris 5.11's env lacks support for -u.
99775 2010-04-05  Bruno Haible  <bruno@clisp.org>
99777         btowc: Work around Cygwin 1.7.2 bug.
99778         * m4/btowc.m4 (gl_FUNC_BTOWC): Set REPLACE_BTOWC to 1 if the function
99779         does not map NUL to 0.
99780         * doc/posix-functions/btowc.texi: Mention the Cygwin bug.
99782 2010-04-05  Bruno Haible  <bruno@clisp.org>
99784         Make the multithread modules work on Cygwin 1.7.2.
99785         * m4/threadlib.m4 (gl_THREADLIB_BODY): Improve the test whether
99786         imported symbols can be declared weak, so that it returns "no" on
99787         Cygwin 1.7.2.
99789 2010-04-05  Bruno Haible  <bruno@clisp.org>
99791         Use the module 'strncat'.
99792         * modules/unistr/u8-strncat (Depends-on): Add strncat.
99794         Tests for module 'strncat'.
99795         * modules/strncat-tests: New file.
99796         * tests/test-strncat.c: New file.
99798         New module 'strncat'.
99799         * lib/string.in.h (strncat): New declaration.
99800         * lib/strncat.c: New file, based on lib/unistr/u-strncat.h.
99801         * m4/strncat.m4: New file, based on m4/memchr.m4.
99802         * modules/strncat: New file.
99803         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Also check whether strncat
99804         is declared.
99805         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_STRNCAT,
99806         REPLACE_STRNCAT.
99807         * modules/string (Makefile.am): Substitute GNULIB_STRNCAT,
99808         REPLACE_STRNCAT.
99809         * doc/posix-functions/strncat.texi: Mention the Solaris bug and the new
99810         module.
99811         * tests/test-string-c++.cc: Check signature of strncat.
99813 2010-04-05  Jim Meyering  <meyering@redhat.com>
99815         xstrtoumax-tests: convert to use init.sh
99816         * modules/xstrtoumax-tests (Files): Add tests/init.sh.
99817         * tests/test-xstrtoumax.sh: Invoke "$srcdir/init.sh" and path_prepend_.
99818         Use Exit, not exit.
99819         Remove uses of $EXEEXT and "./" to run a program in the current dir.
99821         xstrtoimax-tests: convert to use init.sh
99822         * modules/xstrtoimax-tests (Files): Add tests/init.sh.
99823         * tests/test-xstrtoimax.sh: Invoke "$srcdir/init.sh" and path_prepend_.
99824         Use Exit, not exit.
99825         Remove uses of $EXEEXT and "./" to run a program in the current dir.
99827 2010-04-05  Bruno Haible  <bruno@clisp.org>
99829         sys_socket: Avoid #define replacements in C++ mode.
99830         * lib/sys_socket.in.h (close, gethostname, select): In C++, attach a
99831         warning to the function if possible, rather than #defining the symbol
99832         to a dysfunctional alias.
99834 2010-04-05  Bruno Haible  <bruno@clisp.org>
99836         fseeko: Fix C++ test error on mingw.
99837         * m4/fseeko.m4 (gl_HAVE_FSEEKO): New macro, extracted from
99838         gl_FUNC_FSEEKO.
99839         (gl_REPLACE_FSEEKO): Also set REPLACE_FSEEKO if appropriate.
99840         (gl_FUNC_FSEEKO): Require gl_HAVE_FSEEKO. Update.
99841         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't fiddle with internals of the
99842         fseeko module. Instead, invoke gl_REPLACE_FSEEKO.
99844 2010-04-05  Bruno Haible  <bruno@clisp.org>
99846         duplocale: Improve test output.
99847         * tests/test-duplocale.c (main): Print reason for skipped test.
99849 2010-04-05  Bruno Haible  <bruno@clisp.org>
99851         Assume rmdir exists.
99852         * m4/rmdir.m4 (gl_FUNC_RMDIR): Remove test whether rmdir exists.
99853         * doc/posix-functions/rmdir.texi: Remove mention of "old platforms".
99855 2010-04-05  Bruno Haible  <bruno@clisp.org>
99857         Fix link error on Solaris 8 with cc.
99858         * modules/pty-c++-tests (test_pty_c___LDADD): Add LIBINTL.
99860 2010-04-05  Bruno Haible  <bruno@clisp.org>
99862         frexpl: Fix a C++ test error on Solaris 8 and Cygwin.
99863         * lib/math.in.h (frexpl): Fix condition on _GL_CXXALIASWARN invocation.
99865 2010-04-05  Bruno Haible  <bruno@clisp.org>
99867         vasprintf: Update documentation.
99868         * doc/glibc-functions/asprintf.texi: Mention the 'vasprintf' module.
99870 2010-04-05  Bruno Haible  <bruno@clisp.org>
99872         ptsname: Improve test.
99873         * tests/test-ptsname.c (main): Also try the various master names of BSD
99874         systems.
99876 2010-04-05  Bruno Haible  <bruno@clisp.org>
99878         memchr: Avoid a possible C++ test error.
99879         * lib/string.in.h (memchr): Provide declaration if function is missing.
99880         * m4/memchr.m4 (gl_FUNC_MEMCHR): If the function is missing, set
99881         HAVE_MEMCHR to 0, not REPLACE_MEMCHR to 1.
99882         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize HAVE_MEMCHR.
99883         * modules/string (Makefile.am): Substitute HAVE_MEMCHR.
99885 2010-04-05  Bruno Haible  <bruno@clisp.org>
99887         strtok_r: Improve idiom.
99888         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Invoke gl_PREREQ_STRDUP only when
99889         AC_LIBOBJ is used.
99891 2010-04-05  Bruno Haible  <bruno@clisp.org>
99893         strdup: Improve idiom.
99894         * m4/strdup.m4 (gl_FUNC_STRDUP): Invoke gl_PREREQ_STRDUP only when
99895         AC_LIBOBJ is used.
99896         (gl_FUNC_STRDUP_POSIX): When strdup is missing and malloc is not POSIX
99897         compliant, don't set REPLACE_STRDUP to 1. Invoke gl_PREREQ_STRDUP only
99898         when AC_LIBOBJ is used.
99900 2010-04-05  Bruno Haible  <bruno@clisp.org>
99902         mbsinit, mbrtowc, wcrtomb: Improve idioms.
99903         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): When the function does not exist,
99904         don't set REPLACE_MBSINIT to 1.
99905         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): When the function does not exist,
99906         don't set REPLACE_MBRTOWC to 1.
99907         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): When the function does not
99908         exist, don't set REPLACE_MBSRTOWCS to 1.
99909         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): When the function does not
99910         exist, don't set REPLACE_MBSNRTOWCS to 1.
99911         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): When the function does not exist,
99912         don't set REPLACE_WCRTOMB to 1.
99913         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): When the function does not
99914         exist, don't set REPLACE_WCSRTOMBS to 1.
99915         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): When the function does not
99916         exist, don't set REPLACE_WCSNRTOMBS to 1.
99918 2010-04-05  Bruno Haible  <bruno@clisp.org>
99920         ldexpl: Improve idiom.
99921         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): When the function is not declared,
99922         make sure to set HAVE_DECL_LDEXPL to 0.
99924 2010-04-05  Jim Meyering  <meyering@redhat.com>
99926         xstrtol-tests: convert to use init.sh
99927         * modules/xstrtol-tests (Files): Add tests/init.sh.
99928         * tests/test-xstrtol.sh: Invoke "$srcdir/init.sh" and path_prepend_.
99929         Use Exit, not exit.
99930         Remove uses of $EXEEXT and "./" to run a program in the current dir.
99932         atexit-tests: convert to use init.sh
99933         * modules/atexit-tests (Files): Add tests/init.sh.
99934         * tests/test-atexit.sh: Invoke "$srcdir/init.sh" and path_prepend_.
99935         Use Exit, not exit.
99936         Remove uses of $EXEEXT and "./" to run a program in the current dir.
99938         init.sh: fix typo
99939         * tests/init.sh: Restore omitted ":" before stderr_fileno_ initialization.
99941         init.sh: make it easier for a test script to write to the tty, ...
99942         when using automake's parallel-tests mode.
99943         * tests/init.sh (stderr_fileno_): Define overridable variable.
99944         (warn_): New function, to use it.
99945         (fail_, skip_, framework_failure_): Use warn_.
99947 2010-04-04  Bruno Haible  <bruno@clisp.org>
99949         btowc: Avoid warning.
99950         * lib/btowc.c: Include <stdlib.h>.
99951         Reported by Hauke Fath <hauke@espresso.rhein-neckar.de>.
99953 2010-04-04  Hauke Fath  <hauke@espresso.rhein-neckar.de>  (tiny change)
99954             Bruno Haible  <bruno@clisp.org>
99956         wchar: Port to NetBSD 1.5.
99957         * lib/wchar.in.h (WEOF): Provide fallback also when wint_t exists.
99958         * lib/wctype.in.h (WEOF): Likewise.
99960 2010-04-04  Hauke Fath  <hauke@espresso.rhein-neckar.de>  (tiny change)
99961             Bruno Haible  <bruno@clisp.org>
99963         Port extended stdio to NetBSD 1.5.
99964         * lib/stdio-impl.h [NetBSD]: Include <sys/param.h>.
99965         (struct __sfileext, fp_ub): Define the "old way" for NetBSD 1.5Z and
99966         older.
99968 2010-04-04  Bruno Haible  <bruno@clisp.org>
99970         string: Remove unused substitution.
99971         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
99972         HAVE_DECL_STRERROR.
99973         * modules/string (Makefile.am): Don't substitute HAVE_DECL_STRERROR.
99975 2010-04-04  Bruno Haible  <bruno@clisp.org>
99977         strtod: Avoid a possible C++ test error.
99978         * m4/strtod.m4 (gl_FUNC_STRTOD): When setting HAVE_STRTOD to 0, don't
99979         set REPLACE_STRTOD.
99981 2010-04-04  Bruno Haible  <bruno@clisp.org>
99983         strerror: Update documentation.
99984         * doc/posix-functions/strerror.texi: Remove mention of old platforms.
99986 2010-04-04  Bruno Haible  <bruno@clisp.org>
99988         stdio: Fix some C++ test errors on Solaris 8 with GCC.
99989         * lib/stdio.in.h (vdprintf, vfprintf, vprintf, vsprintf): Use
99990         _GL_CXXALIAS_SYS_CAST.
99992 2010-04-04  Bruno Haible  <bruno@clisp.org>
99994         frexpl: Fix a C++ test error on Solaris 8 and Cygwin.
99995         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): When the
99996         function is not declared, set HAVE_DECL_FREXPL to 0, instead of setting
99997         REPLACE_FREXPL to 1.
99998         * doc/posix-functions/frexpl.texi: Update documentation.
100000 2010-04-04  Bruno Haible  <bruno@clisp.org>
100002         math: Fix some C++ test errors on Solaris 8 and Cygwin.
100003         * lib/math.in.h (cosl, logl, sinl): Use simpler idiom.
100005 2010-04-04  Bruno Haible  <bruno@clisp.org>
100007         Implement nanosleep for native Windows.
100008         * lib/nanosleep.c (nanosleep): New implementation for native Windows.
100010 2010-04-04  Bruno Haible  <bruno@clisp.org>
100012         math: Fix some C++ test errors on Solaris 8.
100013         * lib/math.in.h (truncf, trunc): Use simpler idiom.
100015 2010-04-04  Bruno Haible  <bruno@clisp.org>
100017         math: Fix some C++ test errors on Cygwin.
100018         * lib/math.in.h (ceilf, ceill, floorf, floorl, roundf, round, roundl,
100019         truncl): Provide declaration if the system does not have it.
100020         * m4/ceilf.m4 (gl_FUNC_CEILF): If the function is not declared, set
100021         HAVE_DECL_CEILF to 0, not REPLACE_CEILF to 1.
100022         * m4/ceill.m4 (gl_FUNC_CEILL): If the function is not declared, set
100023         HAVE_DECL_CEILL to 0, not REPLACE_CEILL to 1.
100024         * m4/floorf.m4 (gl_FUNC_FLOORF): If the function is not declared, set
100025         HAVE_DECL_FLOORF to 0, not REPLACE_FLOORF to 1.
100026         * m4/floorl.m4 (gl_FUNC_FLOORL): If the function is not declared, set
100027         HAVE_DECL_FLOORL to 0, not REPLACE_FLOORL to 1.
100028         * m4/round.m4 (gl_FUNC_ROUND): If the function is not declared, set
100029         HAVE_DECL_ROUND to 0, not REPLACE_ROUND to 1.
100030         * m4/roundf.m4 (gl_FUNC_ROUNDF): If the function is not declared, set
100031         HAVE_DECL_ROUNDF to 0, not REPLACE_ROUNDF to 1.
100032         * m4/roundl.m4 (gl_FUNC_ROUNDL): If the function is not declared, set
100033         HAVE_DECL_ROUNDL to 0, not REPLACE_ROUNDL to 1.
100034         * m4/truncl.m4 (gl_FUNC_TRUNCL): If the function is not declared, set
100035         HAVE_DECL_TRUNCL to 0, not REPLACE_TRUNCL to 1.
100036         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_CEILF,
100037         HAVE_DECL_CEILL, HAVE_DECL_FLOORF, HAVE_DECL_FLOORL, HAVE_DECL_ROUND,
100038         HAVE_DECL_ROUNDF, HAVE_DECL_ROUNDL, HAVE_DECL_TRUNCL.
100039         * modules/math (Makefile.am): Substitute HAVE_DECL_CEILF,
100040         HAVE_DECL_CEILL, HAVE_DECL_FLOORF, HAVE_DECL_FLOORL, HAVE_DECL_ROUND,
100041         HAVE_DECL_ROUNDF, HAVE_DECL_ROUNDL, HAVE_DECL_TRUNCL.
100043 2010-04-04  Bruno Haible  <bruno@clisp.org>
100045         * m4/ceilf.m4 (gl_FUNC_CEILF): Remove redundant AC_SUBST invocation.
100046         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
100047         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
100048         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
100049         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
100050         * m4/isinf.m4 (gl_ISINF): Likewise.
100051         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
100053 2010-04-04  Bruno Haible  <bruno@clisp.org>
100055         * m4/trunc.m4 (gl_FUNC_TRUNC): Remove redundant AC_SUBST invocation.
100056         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
100058 2010-04-04  Bruno Haible  <bruno@clisp.org>
100060         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Renamed from gl_TMPFILE.
100061         * modules/tmpfile (configure.ac): Update.
100063         tmpfile: Fix C++ test error on mingw.
100064         * lib/stdio.in.h (tmpfile): New declaration.
100065         * m4/tmpfile.m4 (gl_TMPFILE): Require gl_STDIO_H_DEFAULTS. Set
100066         REPLACE_TMPFILE instead of defining tmpfile as a macro in config.h.
100067         * modules/tmpfile (Depends-on): Add stdio.
100068         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
100069         * m4/stdio_h.m4 (gl_STDIO_H): Also check whether tmpfile is declared.
100070         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_TMPFILE and REPLACE_TMPFILE.
100071         * modules/stdio (Makefile.am): Substitute GNULIB_TMPFILE and
100072         REPLACE_TMPFILE.
100073         * tests/test-stdio-c++.cc (tmpfile): Verify signature.
100075 2010-04-04  Bruno Haible  <bruno@clisp.org>
100077         ioctl: Fix C++ test error on mingw.
100078         * lib/ioctl.c (ioctl): Renamed from rpl_ioctl.
100079         * lib/sys_ioctl.in.h (ioctl): When SYS_IOCTL_H_HAVE_WINSOCK2_H is 1,
100080         use _GL_FUNCDECL_SYS, not _GL_FUNCDECL_RPL.
100082 2010-04-03  Bruno Haible  <bruno@clisp.org>
100084         wcwidth: Fix C++ test error on mingw.
100085         * lib/wcwidth.c (wcwidth): Renamed from rpl_wcwidth.
100086         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): If the wcwidth function does not
100087         exist, don't set REPLACE_WCWIDTH. Instead, rely on HAVE_DECL_WCWIDTH.
100089 2010-04-03  Bruno Haible  <bruno@clisp.org>
100091         nanosleep: Fix C++ test error on mingw.
100092         * lib/nanosleep.c (nanosleep): Renamed from rpl_nanosleep.
100093         * lib/time.in.h (nanosleep): Use modern idiom.
100094         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): When the system does not have a
100095         nanosleep function, set HAVE_NANOSLEEP to 0, instead of setting
100096         REPLACE_NANOSLEEP to 1.
100097         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_NANOSLEEP.
100098         * modules/time (Makefile.am): Substitute HAVE_NANOSLEEP.
100100 2010-04-03  Bruno Haible  <bruno@clisp.org>
100102         strptime: Fix C++ test error on mingw.
100103         * lib/time.in.h (strptime): Use HAVE_STRPTIME, not REPLACE_STRPTIME.
100104         * m4/strptime.m4 (gl_FUNC_STRPTIME): Set HAVE_STRPTIME, not
100105         REPLACE_STRPTIME. Invoke gl_PREREQ_STRPTIME.
100106         (gl_PREREQ_STRPTIME): New macro, extracted from gl_FUNC_STRPTIME.
100107         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_STRPTIME,
100108         not REPLACE_STRPTIME.
100109         * modules/time (Makefile.am): Substitute HAVE_STRPTIME, not
100110         REPLACE_STRPTIME.
100112 2010-04-03  Bruno Haible  <bruno@clisp.org>
100114         timegm: Fix C++ test error on mingw.
100115         * lib/time.in.h (timegm): Use modern idiom.
100116         * m4/timegm.m4 (gl_FUNC_TIMEGM): When timegm does not exist, set
100117         HAVE_TIMEGM to 0, not REPLACE_TIMEGM to 1.
100118         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_TIMEGM.
100119         * modules/time (Makefile.am): Substitute HAVE_TIMEGM.
100121 2010-04-03  Bruno Haible  <bruno@clisp.org>
100123         timegm: Assume declaration if function exists.
100124         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume timegm is declared if and only
100125         if it exists. Don't clobber ac_cv_func_timegm.
100127 2010-04-03  Bruno Haible  <bruno@clisp.org>
100129         time_r: Fix C++ test error on mingw.
100130         * lib/time.in.h (localtime_r, gmtime_r): Use modern idiom.
100131         * m4/time_r.m4 (gl_TIME_R): When localtime_r does not exist, set
100132         HAVE_LOCALTIME_R to 0, not REPLACE_LOCALTIME_R to 1.
100133         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_LOCALTIME_R.
100134         * modules/time (Makefile.am): Substitute HAVE_LOCALTIME_R.
100136 2010-04-03  Bruno Haible  <bruno@clisp.org>
100138         time_r: Minor updates.
100139         * modules/time_r (Description): Mention the provided functions.
100140         * lib/time_r.c: Don't include <string.h>.
100141         * doc/posix-functions/gmtime_r.texi: Mention the 'time_r' module.
100142         * doc/posix-functions/localtime_r.texi: Likewise.
100144 2010-04-03  Bruno Haible  <bruno@clisp.org>
100146         time: Fix regression introduced on 2010-03-08.
100147         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Require
100148         gl_HEADER_TIME_H_DEFAULTS, not gl_HEADER_STRING_H_DEFAULTS.
100150 2010-04-03  Jim Meyering  <meyering@redhat.com>
100152         maint.mk: don't silently disable project-specific syntax-check rules
100153         * top/maint.mk (_prohibit_regexp): Define, to help people realize
100154         that they need to convert their project-specific syntax-check rules
100155         to use the new _sc_search_regexp.
100157 2010-04-03  Bruno Haible  <bruno@clisp.org>
100159         fchdir: Fix regression introduced on 2010-03-08.
100160         * lib/unistd.in.h (fchdir): Fix declaration.
100161         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set HAVE_FCHDIR, not REPLACE_FCHDIR.
100162         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_FCHDIR, not
100163         REPLACE_FCHDIR.
100164         * modules/unistd (Makefile.am): Substitute HAVE_FCHDIR, not
100165         REPLACE_FCHDIR.
100167 2010-04-03  Bruno Haible  <bruno@clisp.org>
100169         getpagesize: Fix C++ test error on mingw.
100170         * lib/unistd.in.h (getpagesize): Don't use _GL_CXXALIASWARN if the
100171         system does not declare the function.
100172         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Also check whether it's
100173         declared.
100174         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
100175         HAVE_DECL_GETPAGESIZE.
100176         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETPAGESIZE.
100178 2010-04-03  Bruno Haible  <bruno@clisp.org>
100180         stdio: Make C++ tests work on mingw.
100181         * lib/stdio.in.h (getline): Don't use _GL_CXXALIASWARN if the system
100182         does not declare the function.
100184 2010-04-03  Bruno Haible  <bruno@clisp.org>
100186         ftello: Fix C++ test error on mingw.
100187         * lib/stdio.in.h (ftello): Use modern idiom.
100188         * lib/ftello.c (ftello): Renamed from rpl_ftello.
100189         * m4/ftello.m4 (gl_FUNC_FTELLO): Distinguish the case that the function
100190         is missing and that it needs to be replaced.
100191         (gl_REPLACE_FTELLO): Don't set REPLACE_FTELLO here.
100192         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_FTELLO.
100193         * modules/stdio (Makefile.am): Substitute HAVE_FTELLO.
100195 2010-04-03  Bruno Haible  <bruno@clisp.org>
100197         fseeko: Fix C++ test error on mingw.
100198         * lib/stdio.in.h (fseeko): Use modern idiom.
100199         * lib/fseeko.c (fseeko): Renamed from rpl_fseeko.
100200         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Distinguish the case that the function
100201         is missing and that it needs to be replaced.
100202         (gl_REPLACE_FSEEKO): Don't set REPLACE_FSEEKO here.
100203         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_FSEEKO.
100204         * modules/stdio (Makefile.am): Substitute HAVE_FSEEKO.
100206 2010-04-03  Bruno Haible  <bruno@clisp.org>
100208         mkstemp: Fix C++ test error on mingw.
100209         * lib/stdlib.in.h (mkstemp): Use modern idiom.
100210         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Distinguish the case that the
100211         function is missing and that it needs to be replaced.
100212         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_MKSTEMP.
100213         * modules/stdlib (Makefile.am): Substitute HAVE_MKSTEMP.
100215 2010-04-03  Bruno Haible  <bruno@clisp.org>
100217         stpncpy: Fix C++ test error on mingw.
100218         * lib/string.in.h (stpncpy): Use modern idiom.
100219         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Distinguish the case that the
100220         function is missing and that it needs to be replaced.
100221         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
100222         REPLACE_STPNCPY.
100223         * modules/string (Makefile.am): Substitute REPLACE_STPNCPY.
100225 2010-04-03  Bruno Haible  <bruno@clisp.org>
100227         sys_stat: Fix C++ test error on mingw.
100228         * build-aux/c++defs.h (_GL_CXXALIAS_RPL_CAST_1): New macro.
100229         * lib/sys_stat.in.h (lchmod): Use it instead of _GL_CXXALIAS_RPL_1.
100231 2010-04-03  Bruno Haible  <bruno@clisp.org>
100233         pty: Update doc.
100234         * doc/glibc-headers/pty.texi: Mention changes done since 2010-03-18.
100236 2010-04-03  Bruno Haible  <bruno@clisp.org>
100238         unistd: Fix C++ test error on mingw.
100239         * lib/unistd.in.h (getcwd): Use _GL_CXXALIAS_SYS_CAST.
100241 2010-04-03  Bruno Haible  <bruno@clisp.org>
100243         Update doc regarding mingw.
100244         * doc/glibc-functions/openpty.texi: Update regarding mingw.
100245         * doc/glibc-functions/login_tty.texi: Likewise.
100246         * doc/glibc-functions/forkpty.texi: Likewise.
100248 2010-04-03  Bruno Haible  <bruno@clisp.org>
100250         stdlib: Avoid compilation failure of c-strtold on mingw.
100251         * lib/stdlib.in.h: Don't include <unistd.h> on native Windows systems.
100253 2010-04-03  Bruno Haible  <bruno@clisp.org>
100255         locale: Make C++ tests work on Cygwin and mingw.
100256         * lib/locale.in.h (duplocale): Don't use _GL_CXXALIASWARN if gnulib
100257         cannot provide the function.
100258         Reported by Simon Josefsson.
100260 2010-04-03  Bruno Haible  <bruno@clisp.org>
100262         localename: Port to MacOS X 10.6.
100263         * lib/localename.c (gl_locale_name_thread_unsafe): On MacOS X, try the
100264         memory layout of the locales in MacOS X 10.6 as well.
100265         Reported by Panu Kekäläinen <panu@kekalainen.eu>.
100267 2010-04-02  Bruno Haible  <bruno@clisp.org>
100269         gnulib-tool: Ensure that long-running tests are executed last.
100270         * gnulib-tool (func_emit_tests_Makefile_am): Emit the code for long-
100271         running tests after the one for the other tests.
100273 2010-04-02  Bruno Haible  <bruno@clisp.org>
100275         gnulib-tool: Ensure the tests in the main directory are executed first.
100276         * gnulib-tool (func_emit_tests_Makefile_am): Initialize SUBDIRS to
100277         start with the current directory.
100279 2010-04-02  Bruno Haible  <bruno@clisp.org>
100281         Tests for module 'havelib', moved here from GNU gettext.
100282         * modules/havelib-tests: New file, from gettext/autoconf-lib-link with
100283         modifications.
100284         * tests/havelib/README: New file, from gettext/autoconf-lib-link.
100285         * tests/havelib/Makefile.am: New file, from gettext/autoconf-lib-link
100286         with modifications.
100287         * tests/havelib/rpath-1: New file, from gettext/autoconf-lib-link with
100288         modifications.
100289         * tests/havelib/rpath-1a: New file, from gettext/autoconf-lib-link.
100290         * tests/havelib/rpath-1b: New file, from gettext/autoconf-lib-link.
100291         * tests/havelib/rpath-2_a: New file, from gettext/autoconf-lib-link
100292         with modifications.
100293         * tests/havelib/rpath-2_b: New file, from gettext/autoconf-lib-link
100294         with modifications.
100295         * tests/havelib/rpath-2aaa: New file, from gettext/autoconf-lib-link.
100296         * tests/havelib/rpath-2aab: New file, from gettext/autoconf-lib-link.
100297         * tests/havelib/rpath-2aac: New file, from gettext/autoconf-lib-link.
100298         * tests/havelib/rpath-2aad: New file, from gettext/autoconf-lib-link.
100299         * tests/havelib/rpath-2aba: New file, from gettext/autoconf-lib-link.
100300         * tests/havelib/rpath-2abb: New file, from gettext/autoconf-lib-link.
100301         * tests/havelib/rpath-2abc: New file, from gettext/autoconf-lib-link.
100302         * tests/havelib/rpath-2abd: New file, from gettext/autoconf-lib-link.
100303         * tests/havelib/rpath-2baa: New file, from gettext/autoconf-lib-link.
100304         * tests/havelib/rpath-2bab: New file, from gettext/autoconf-lib-link.
100305         * tests/havelib/rpath-2bac: New file, from gettext/autoconf-lib-link.
100306         * tests/havelib/rpath-2bad: New file, from gettext/autoconf-lib-link.
100307         * tests/havelib/rpath-2bba: New file, from gettext/autoconf-lib-link.
100308         * tests/havelib/rpath-2bbb: New file, from gettext/autoconf-lib-link.
100309         * tests/havelib/rpath-2bbc: New file, from gettext/autoconf-lib-link.
100310         * tests/havelib/rpath-2bbd: New file, from gettext/autoconf-lib-link.
100311         * tests/havelib/rpath-3_a: New file, from gettext/autoconf-lib-link
100312         with modifications.
100313         * tests/havelib/rpath-3_b: New file, from gettext/autoconf-lib-link
100314         with modifications.
100315         * tests/havelib/rpath-3aaa: New file, from gettext/autoconf-lib-link.
100316         * tests/havelib/rpath-3aab: New file, from gettext/autoconf-lib-link.
100317         * tests/havelib/rpath-3aac: New file, from gettext/autoconf-lib-link.
100318         * tests/havelib/rpath-3aad: New file, from gettext/autoconf-lib-link.
100319         * tests/havelib/rpath-3aae: New file, from gettext/autoconf-lib-link.
100320         * tests/havelib/rpath-3aaf: New file, from gettext/autoconf-lib-link.
100321         * tests/havelib/rpath-3aag: New file, from gettext/autoconf-lib-link.
100322         * tests/havelib/rpath-3aah: New file, from gettext/autoconf-lib-link.
100323         * tests/havelib/rpath-3aba: New file, from gettext/autoconf-lib-link.
100324         * tests/havelib/rpath-3abb: New file, from gettext/autoconf-lib-link.
100325         * tests/havelib/rpath-3abc: New file, from gettext/autoconf-lib-link.
100326         * tests/havelib/rpath-3abd: New file, from gettext/autoconf-lib-link.
100327         * tests/havelib/rpath-3abe: New file, from gettext/autoconf-lib-link.
100328         * tests/havelib/rpath-3abf: New file, from gettext/autoconf-lib-link.
100329         * tests/havelib/rpath-3abg: New file, from gettext/autoconf-lib-link.
100330         * tests/havelib/rpath-3abh: New file, from gettext/autoconf-lib-link.
100331         * tests/havelib/rpath-3baa: New file, from gettext/autoconf-lib-link.
100332         * tests/havelib/rpath-3bab: New file, from gettext/autoconf-lib-link.
100333         * tests/havelib/rpath-3bac: New file, from gettext/autoconf-lib-link.
100334         * tests/havelib/rpath-3bad: New file, from gettext/autoconf-lib-link.
100335         * tests/havelib/rpath-3bae: New file, from gettext/autoconf-lib-link.
100336         * tests/havelib/rpath-3baf: New file, from gettext/autoconf-lib-link.
100337         * tests/havelib/rpath-3bag: New file, from gettext/autoconf-lib-link.
100338         * tests/havelib/rpath-3bah: New file, from gettext/autoconf-lib-link.
100339         * tests/havelib/rpath-3bba: New file, from gettext/autoconf-lib-link.
100340         * tests/havelib/rpath-3bbb: New file, from gettext/autoconf-lib-link.
100341         * tests/havelib/rpath-3bbc: New file, from gettext/autoconf-lib-link.
100342         * tests/havelib/rpath-3bbd: New file, from gettext/autoconf-lib-link.
100343         * tests/havelib/rpath-3bbe: New file, from gettext/autoconf-lib-link.
100344         * tests/havelib/rpath-3bbf: New file, from gettext/autoconf-lib-link.
100345         * tests/havelib/rpath-3bbg: New file, from gettext/autoconf-lib-link.
100346         * tests/havelib/rpath-3bbh: New file, from gettext/autoconf-lib-link.
100347         * tests/havelib/rpathx/rpathx.c: New file, from
100348         gettext/autoconf-lib-link.
100349         * tests/havelib/rpathx/Makefile.am: New file, from
100350         gettext/autoconf-lib-link.
100351         * tests/havelib/rpathx/configure.ac: New file, from
100352         gettext/autoconf-lib-link with modifications.
100353         * tests/havelib/rpathy/rpathy.c: New file, from
100354         gettext/autoconf-lib-link.
100355         * tests/havelib/rpathy/Makefile.am: New file, from
100356         gettext/autoconf-lib-link.
100357         * tests/havelib/rpathy/configure.ac: New file, from
100358         gettext/autoconf-lib-link with modifications.
100359         * tests/havelib/rpathz/rpathz.c: New file, from
100360         gettext/autoconf-lib-link.
100361         * tests/havelib/rpathz/Makefile.am: New file, from
100362         gettext/autoconf-lib-link.
100363         * tests/havelib/rpathz/configure.ac: New file, from
100364         gettext/autoconf-lib-link with modifications.
100365         * tests/havelib/rpathlx/usex.c: New file, from
100366         gettext/autoconf-lib-link.
100367         * tests/havelib/rpathlx/Makefile.am: New file, from
100368         gettext/autoconf-lib-link.
100369         * tests/havelib/rpathlx/configure.ac: New file, from
100370         gettext/autoconf-lib-link with modifications.
100371         * tests/havelib/rpathly/usey.c: New file, from
100372         gettext/autoconf-lib-link.
100373         * tests/havelib/rpathly/Makefile.am: New file, from
100374         gettext/autoconf-lib-link.
100375         * tests/havelib/rpathly/configure.ac: New file, from
100376         gettext/autoconf-lib-link with modifications.
100377         * tests/havelib/rpathlz/usez.c: New file, from
100378         gettext/autoconf-lib-link.
100379         * tests/havelib/rpathlz/Makefile.am: New file, from
100380         gettext/autoconf-lib-link.
100381         * tests/havelib/rpathlz/configure.ac: New file, from
100382         gettext/autoconf-lib-link with modifications.
100383         * tests/havelib/rpathlyx/usey.c: New file, from
100384         gettext/autoconf-lib-link.
100385         * tests/havelib/rpathlyx/Makefile.am: New file, from
100386         gettext/autoconf-lib-link.
100387         * tests/havelib/rpathlyx/configure.ac: New file, from
100388         gettext/autoconf-lib-link with modifications.
100389         * tests/havelib/rpathlzyx/usez.c: New file, from
100390         gettext/autoconf-lib-link.
100391         * tests/havelib/rpathlzyx/Makefile.am: New file, from
100392         gettext/autoconf-lib-link.
100393         * tests/havelib/rpathlzyx/configure.ac: New file, from
100394         gettext/autoconf-lib-link with modifications.
100395         * tests/havelib/rpathcfg.sh: New file, from gettext/autoconf-lib-link
100396         with modifications.
100398 2010-04-02  Bruno Haible  <bruno@clisp.org>
100400         gnulib-tool: Create distributed built sources also for the tests.
100401         * gnulib-tool (func_create_testdir): Also generate distributed built
100402         sources in the tests directory.
100404 2010-04-02  Bruno Haible  <bruno@clisp.org>
100406         gnulib-tool: Obey user's environment variables.
100407         * gnulib-tool (func_create_testdir): When creating built sources,
100408         respect the environment variables for autoconf, automake, etc. given by
100409         the user.
100411 2010-04-02  Bruno Haible  <bruno@clisp.org>
100413         gnulib-tool: Provide the value of --m4-base to modules.
100414         * gnulib-tool (func_import, func_create_testdir): Emit a definition
100415         of gl_m4_base.
100417 2010-04-02  Eric Blake  <eblake@redhat.com>
100419         maint.mk: fix some fallout
100420         * NEWS: Document the incompatible change, and its effect on cfg.mk.
100421         * top/maint.mk (sc_prohibit_test_minus_ao): Update.
100423 2010-03-28  Jose E. Marchesi  <jemarch@gnu.org>
100425         maint.mk: _sc_search_regexp: generalize and rename from _prohibit_regexp
100426         * top/maint.mk (_sc_search_regexp): Rename from _prohibit_regexp.
100427         (sc_cast_of_argument_to_free): Adapt to use _sc_search_regexp.
100428         (sc_cast_of_x_alloc_return_value): Likewise.
100429         (sc_cast_of_alloca_return_value): Likewise.
100430         (sc_space_tab): Likewise.
100431         (sc_prohibit_atoi_atof): Likewise.
100432         (sc_prohibit_magic_number_exit): Likewise.
100433         (sc_error_exit_success): Likewise.
100434         (sc_file_system): Likewise.
100435         (sc_prohibit_have_config_h): Likewise.
100436         (sc_require_config_h): Likewise.
100437         (sc_prohibit_HAVE_MBRTOWC): Likewise.
100438         (sc_obsolete_symbols): Likewise.
100439         (sc_changelog): Likewise.
100440         (sc_program_name): Likewise.
100441         (sc_the_the): Likewise.
100442         (sc_trailing_blank): Likewise.
100443         (sc_two_space_separator_in_usage): Likewise.
100444         (sc_useless_cpp_parens): Likewise.
100445         (sc_GPL_version): Likewise.
100446         (sc_GFDL_version): Likewise.
100447         (sc_texinfo_acronym): Likewise.
100448         (sc_prohibit_cvs_keyword): Likewise.
100449         (sc_prohibit_stat_st_blocks): Likewise.
100450         (sc_prohibit_S_IS_definition): Likewise.
100451         (sc_redundant_const): Likewise.
100452         (sc_makefile_TAB_only_indentation): Likewise.
100453         (sc_m4_quote_check): Likewise.
100454         (sc_makefile_path_separator_check): Likewise.
100455         (sc_copyright_check): Likewise.
100456         (sc_Wundef_boolean): Likewise.
100457         (sc_vulnerable_makefile_CVE-2009-4029): Likewise.
100459         maint.mk: match 0 or more whitespace-before-function-call '('
100460         * top/maint.mk (sc_error_exit_success): Relax regexp to match uses
100461         that have zero or two-and-more spaces between the function name
100462         and the open parenthesis.
100463         (sc_error_message_warn_fatal): Likewise.
100464         (sc_error_message_uppercase): Likewise.
100465         (sc_error_message_period): Likewise.
100467 2010-03-31  Eric Blake  <eblake@redhat.com>
100469         maint.mk: check for [ as well as test
100470         * top/maint.mk (sc_prohibit_test_minus_ao): Extend test.
100471         Based on a libvirt report by Matthias Bolte.
100473         gnumakefile: don't squelch _version output
100474         * top/GNUmakefile (_version): Create one-shot dependency rather
100475         than using $(shell) when version must be regenerated.
100476         (_autoreconf): Run verbosely, by default.
100478         sys_time: avoid compiler warnings
100479         * lib/sys_time.in.h (includes): Ensure gcc pragma is
100480         unconditional, fixing regression from 2010-03-29.
100481         Reported by Simon Josefsson.
100483 2010-03-28  Jose E. Marchesi  <jemarch@gnu.org>
100485         maint.mk: s/_header_without_use/_sc_header_without_use/
100486         * top/maint.mk (_sc_header_without_use): Rename from _header_without_use.
100487         (sc_prohibit_assert_without_use): Use the new name.
100488         (sc_prohibit_close_stream_without_use): Likewise.
100489         (sc_prohibit_getopt_without_use): Likewise.
100490         (sc_prohibit_quotearg_without_use): Likewise.
100491         (sc_prohibit_quote_without_use): Likewise.
100492         (sc_prohibit_long_options_without_use): Likewise.
100493         (sc_prohibit_inttostr_without_use): Likewise.
100494         (sc_prohibit_ignore_value_without_use): Likewise.
100495         (sc_prohibit_error_without_use): Likewise.
100496         (sc_prohibit_xalloc_without_use): Likewise.
100497         (sc_prohibit_hash_without_use): Likewise.
100498         (sc_prohibit_hash_pjw_without_use): Likewise.
100499         (sc_prohibit_safe_read_without_use): Likewise.
100500         (sc_prohibit_argmatch_without_use): Likewise.
100501         (sc_prohibit_canonicalize_without_use): Likewise.
100502         (sc_prohibit_root_dev_ino_without_use): Likewise.
100503         (sc_prohibit_openat_without_use): Likewise.
100504         (sc_prohibit_c_ctype_without_use): Likewise.
100505         (sc_prohibit_signal_without_use): Likewise.
100506         (sc_prohibit_intprops_without_use): Likewise.
100508 2010-03-30  Eric Blake  <eblake@redhat.com>
100510         maint: improve module indicators
100511         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_SET_VARIABLE)
100512         (gl_MODULE_INDICATOR, gl_MODULE_INDICATOR_FOR_TESTS): Fit in 80
100513         columns, and avoid extra macro expansion.
100515         fdopendir: work around FreeBSD bug
100516         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
100517         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Set it.
100518         * modules/dirent (Makefile.am): Substitute it.
100519         * lib/dirent.in.h (fdopendir): Supply missing FreeBSD
100520         declaration.
100521         * doc/posix-functions/fdopendir.texi (fdopendir): Document the
100522         fix.
100523         Reported by Christian Weisgerber <naddy@mips.inka.de>.
100525 2010-03-29  Bruno Haible  <bruno@clisp.org>
100527         Emit #pragma system_header after the inclusion guard, not before.
100528         * lib/arpa_inet.in.h: Emit #pragma system_header after the inclusion
100529         guard that spans the entire file, not before. This enables an
100530         optimization in GCC's preprocessor.
100531         * lib/ctype.in.h: Likewise.
100532         * lib/dirent.in.h: Likewise.
100533         * lib/errno.in.h: Likewise.
100534         * lib/float.in.h: Likewise.
100535         * lib/getopt.in.h: Likewise.
100536         * lib/iconv.in.h: Likewise.
100537         * lib/langinfo.in.h: Likewise.
100538         * lib/locale.in.h: Likewise.
100539         * lib/math.in.h: Likewise.
100540         * lib/netdb.in.h: Likewise.
100541         * lib/netinet_in.in.h: Likewise.
100542         * lib/pty.in.h: Likewise.
100543         * lib/sched.in.h: Likewise.
100544         * lib/se-selinux.in.h: Likewise.
100545         * lib/search.in.h: Likewise.
100546         * lib/spawn.in.h: Likewise.
100547         * lib/stdarg.in.h: Likewise.
100548         * lib/stdint.in.h: Likewise.
100549         * lib/string.in.h: Likewise.
100550         * lib/strings.in.h: Likewise.
100551         * lib/sys_file.in.h: Likewise.
100552         * lib/sys_ioctl.in.h: Likewise.
100553         * lib/sys_time.in.h: Likewise.
100554         * lib/sys_times.in.h: Likewise.
100555         * lib/sys_utsname.in.h: Likewise.
100556         * lib/sys_wait.in.h: Likewise.
100557         * lib/sysexits.in.h: Likewise.
100558         * lib/wctype.in.h: Likewise.
100560 2010-03-28  James Youngman  <jay@gnu.org>
100562         save-cwd: don't leak a file descriptor when the caller execs.
100563         * lib/save-cwd.c (save_cwd): set the close-on-exec flag for the
100564         saved file descriptor.
100565         * modules/save-cwd (Depends-on): Depend on cloexec.
100567 2010-03-29  Bruno Haible  <bruno@clisp.org>
100569         Remove vestiges of fts-lgpl module.
100570         * lib/fts_.h: Assume GNULIB_FTS is 1.
100571         * lib/fts.c: Likewise.
100572         * modules/fts (configure.ac): Remove gl_MODULE_INDICATOR invocation.
100574 2010-03-28  Bruno Haible  <bruno@clisp.org>
100576         Fix definition of tests witness macro.
100577         * gnulib-tool (func_import): Fix definition of witness macro.
100579 2010-03-28  Bruno Haible  <bruno@clisp.org>
100581         Fix ioctl's protoype on glibc systems.
100582         * lib/sys_ioctl.in.h (ioctl): If REPLACE_IOCTL is 1, use a wrapper. Use
100583         _GL_CXXALIAS_SYS, not _GL_CXXALIAS_SYS_CAST.
100584         * lib/ioctl.c (rpl_ioctl) [HAVE_IOCTL]: New wrapper.
100585         * modules/ioctl (configure.ac): Test whether ioctl has the POSIX
100586         signature. If not, arrange to replace the ioctl function.
100587         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Initialize
100588         REPLACE_IOCTL.
100589         * modules/sys_ioctl (Makefile.am): Substitute REPLACE_IOCTL.
100590         * doc/posix-functions/ioctl.texi: Mention the glibc problem.
100591         Reported by Ludovic Courtès <ludo@gnu.org>.
100593 2010-03-28  Javier Villavicencio  <the_paya@gentoo.org>
100595         exclude: fix the case of globs vs. EXCLUDE_INCLUDE
100596         * lib/exclude.c (excluded_file_pattern_p): Fix logic error that
100597         made it so grep -r --include=GLOB* ... did not work.
100599 2010-03-26  Jim Meyering  <meyering@redhat.com>
100600             Eric Blake  <eblake@redhat.com>
100602         maint.mk: prohibit use of test's -o and -a operators
100603         * top/maint.mk (sc_prohibit_test_minus_ao): New rule.
100605 2010-03-28  Bruno Haible  <bruno@clisp.org>
100607         Remove unused GNULIB_XYZ macro definitions.
100608         * modules/crypto/gc-camellia (configure.ac): Remove gl_MODULE_INDICATOR
100609         invocation.
100611 2010-03-28  Bruno Haible  <bruno@clisp.org>
100613         Mark privileged tests modules.
100614         * modules/idpriv-drop-tests (Status): New section.
100615         * modules/idpriv-droptemp-tests (Status): New section.
100617 2010-03-28  Bruno Haible  <bruno@clisp.org>
100619         Split C++ tests into separate tests modules.
100620         * modules/dirent-c++-tests: New file, extracted from
100621         modules/dirent-tests.
100622         * modules/dirent-tests: Depend on it.
100623         * modules/fcntl-h-c++-tests: New file, extracted from
100624         modules/fcntl-h-tests.
100625         * modules/fcntl-h-tests: Depend on it.
100626         * modules/glob-c++-tests: New file, extracted from modules/glob-tests.
100627         * modules/glob-tests: Depend on it.
100628         * modules/iconv-h-c++-tests: New file, extracted from
100629         modules/iconv-h-tests.
100630         * modules/iconv-h-tests: Depend on it.
100631         * modules/langinfo-c++-tests: New file, extracted from
100632         modules/langinfo-tests.
100633         * modules/langinfo-tests: Depend on it.
100634         * modules/locale-c++-tests: New file, extracted from
100635         modules/locale-tests.
100636         * modules/locale-tests: Depend on it.
100637         * modules/math-c++-tests: New file, extracted from modules/math-tests.
100638         * modules/math-tests: Depend on it.
100639         * modules/pty-c++-tests: New file, extracted from modules/pty-tests.
100640         * modules/pty-tests: Depend on it.
100641         * modules/search-c++-tests: New file, extracted from
100642         modules/search-tests.
100643         * modules/search-tests: Depend on it.
100644         * modules/signal-c++-tests: New file, extracted from
100645         modules/signal-tests.
100646         * modules/signal-tests: Depend on it.
100647         * modules/spawn-c++-tests: New file, extracted from
100648         modules/spawn-tests.
100649         * modules/spawn-tests: Depend on it.
100650         * modules/stdio-c++-tests: New file, extracted from
100651         modules/stdio-tests.
100652         * modules/stdio-tests: Depend on it.
100653         * modules/stdlib-c++-tests: New file, extracted from
100654         modules/stdlib-tests.
100655         * modules/stdlib-tests: Depend on it.
100656         * modules/string-c++-tests: New file, extracted from
100657         modules/string-tests.
100658         * modules/string-tests: Depend on it.
100659         * modules/sys_ioctl-c++-tests: New file, extracted from
100660         modules/sys_ioctl-tests.
100661         * modules/sys_ioctl-tests: Depend on it.
100662         * modules/sys_select-c++-tests: New file, extracted from
100663         modules/sys_select-tests.
100664         * modules/sys_select-tests: Depend on it.
100665         * modules/sys_socket-c++-tests: New file, extracted from
100666         modules/sys_socket-tests.
100667         * modules/sys_socket-tests: Depend on it.
100668         * modules/sys_stat-c++-tests: New file, extracted from
100669         modules/sys_stat-tests.
100670         * modules/sys_stat-tests: Depend on it.
100671         * modules/sys_time-c++-tests: New file, extracted from
100672         modules/sys_time-tests.
100673         * modules/sys_time-tests: Depend on it.
100674         * modules/time-c++-tests: New file, extracted from modules/time-tests.
100675         * modules/time-tests: Depend on it.
100676         * modules/unistd-c++-tests: New file, extracted from
100677         modules/unistd-tests.
100678         * modules/unistd-tests: Depend on it.
100679         * modules/wchar-c++-tests: New file, extracted from
100680         modules/wchar-tests.
100681         * modules/wchar-tests: Depend on it.
100682         * modules/wctype-c++-tests: New file, extracted from
100683         modules/wctype-tests.
100684         * modules/wctype-tests: Depend on it.
100685         Reported by Simon Josefsson.
100687 2010-03-28  Bruno Haible  <bruno@clisp.org>
100689         gnulib-tool: Allow 'foo-tests' module even if there is no module 'foo'.
100690         * gnulib-tool (func_exists_module): New function, extracted from
100691         func_verify_module.
100692         (func_verify_module): Use it.
100693         (func_get_dependencies): Synthetize a dependency from 'foo-tests' to
100694         'foo' only if 'foo' exists.
100695         * doc/gnulib.texi (Extra tests modules): Explain how to split a tests
100696         module.
100698 2010-03-28  Bruno Haible  <bruno@clisp.org>
100700         gnulib-tool: Add support for special categories of tests.
100701         * gnulib-tool: New options --with-c++-tests, --with-longrunning-tests,
100702         --with-privileged-tests, --with-unportable-tests, --with-all-tests.
100703         (func_usage): Document them.
100704         (inc_cxx_tests, inc_longrunning_tests, inc_privileged_tests,
100705         inc_unportable_tests, inc_all_tests): New variables.
100706         (func_acceptable): Consider these variables.
100707         (func_modules_transitive_closure): Make it work when the 'Status' field
100708         consists of multiple words.
100709         (func_import): Store and restore the values of inc_cxx_tests,
100710         inc_longrunning_tests, inc_privileged_tests, inc_unportable_tests,
100711         inc_all_tests in gnulib-comp.m4.
100712         (func_create_testdir): Set inc_all_tests to true.
100713         * doc/gnulib.texi (Extra tests modules): New section.
100714         Suggested by Jim Meyering.
100716 2010-03-28  Bruno Haible  <bruno@clisp.org>
100718         ansi-c++-opt: Allow turning off the C++ build by default.
100719         * m4/ansi-c++.m4 (gl_CXX_CHOICE): Let CXX_CHOICE default to 'no' if
100720         gl_CXX_CHOICE_DEFAULT_NO is defined.
100721         Requested by Eric Blake.
100723 2010-03-28  Bruno Haible  <bruno@clisp.org>
100725         unistd: Avoid #define replacements in C++ mode.
100726         * lib/unistd.in.h (socket, connect, accept, bind, getpeername,
100727         getsockname, getsockopt, listen, recv, send, recvfrom, sendto,
100728         setsockopt, shutdown, select): In C++, attach a warning to the function
100729         if possible, rather than #defining the symbol to a dysfunctional alias.
100730         Reported by John W. Eaton <jwe@gnu.org>.
100732 2010-03-28  Bruno Haible  <bruno@clisp.org>
100734         Fix link errors on mingw.
100735         * lib/sys_ioctl.in.h (ioctl): Fix declaration idiom.
100736         * modules/sys_ioctl-tests (Makefile.am): Link test-sys_ioctl-c++ with
100737         $(LIBSOCKET).
100738         * modules/sys_select-tests (Makefile.am): Link test-sys_select-c++ with
100739         $(LIBSOCKET).
100741 2010-03-28  Bruno Haible  <bruno@clisp.org>
100742             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
100744         lib-ignore: Determine different options for different compilers.
100745         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Set a variable which
100746         depends on the current language (C/C++/Fortran). Don't set LDFLAGS.
100747         Add comments.
100748         (_gl_IGNORE_UNUSED_LIBRARIES_OPTIONS): New macro.
100749         * NEWS: Mention the change.
100751 2010-03-27  Bruno Haible  <bruno@clisp.org>
100753         Remove unused GNULIB_XYZ macro definitions.
100754         * modules/dup3 (configure.ac): Remove gl_MODULE_INDICATOR invocation.
100755         * modules/fseek (configure.ac): Likewise.
100756         * modules/ioctl (configure.ac): Likewise.
100757         * modules/open (configure.ac): Likewise.
100758         * modules/stdlib-safer (configure.ac): Likewise.
100760 2010-03-27  Bruno Haible  <bruno@clisp.org>
100762         Add a remark about certain modules.
100763         * modules/malloc (Comment): New section.
100764         * modules/realloc (Comment): Likewise.
100765         * modules/sigpipe (Comment): Likewise.
100767 2010-03-27  Bruno Haible  <bruno@clisp.org>
100769         Resolve conflict between the two kinds of module indicators.
100770         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_FOR_TESTS): Define
100771         GNULIB_TEST_XYZ instead of GNULIB_XYZ.
100772         * modules/canonicalize (configure.ac): Invoke
100773         gl_MODULE_INDICATOR_FOR_TESTS.
100774         * tests/test-canonicalize-lgpl.c: Test GNULIB_TEST_XYZ instead of
100775         GNULIB_XYZ.
100776         * tests/test-dirent-c++.cc: Likewise.
100777         * tests/test-dirent-safer.c: Likewise.
100778         * tests/test-dup2.c: Likewise.
100779         * tests/test-fchdir.c: Likewise.
100780         * tests/test-fcntl-h-c++.cc: Likewise.
100781         * tests/test-getopt.c: Likewise.
100782         * tests/test-getopt.h: Likewise.
100783         * tests/test-langinfo-c++.cc: Likewise.
100784         * tests/test-locale-c++.cc: Likewise.
100785         * tests/test-math-c++.cc: Likewise.
100786         * tests/test-pty-c++.cc: Likewise.
100787         * tests/test-search-c++.cc: Likewise.
100788         * tests/test-signal-c++.cc: Likewise.
100789         * tests/test-spawn-c++.cc: Likewise.
100790         * tests/test-stdio-c++.cc: Likewise.
100791         * tests/test-stdlib-c++.cc: Likewise.
100792         * tests/test-string-c++.cc: Likewise.
100793         * tests/test-sys_ioctl-c++.cc: Likewise.
100794         * tests/test-sys_select-c++.cc: Likewise.
100795         * tests/test-sys_socket-c++.cc: Likewise.
100796         * tests/test-sys_stat-c++.cc: Likewise.
100797         * tests/test-sys_time-c++.cc: Likewise.
100798         * tests/test-time-c++.cc: Likewise.
100799         * tests/test-unistd-c++.cc: Likewise.
100800         * tests/test-wchar-c++.cc: Likewise.
100801         * tests/uninorm/test-u8-nfc.c: Likewise.
100802         * tests/uninorm/test-u8-nfd.c: Likewise.
100803         * tests/uninorm/test-u8-nfkc.c: Likewise.
100804         * tests/uninorm/test-u8-nfkd.c: Likewise.
100805         * tests/uninorm/test-u16-nfc.c: Likewise.
100806         * tests/uninorm/test-u16-nfd.c: Likewise.
100807         * tests/uninorm/test-u16-nfkc.c: Likewise.
100808         * tests/uninorm/test-u16-nfkd.c: Likewise.
100809         * tests/uninorm/test-u32-nfc.c: Likewise.
100810         * tests/uninorm/test-u32-nfc-big.c: Likewise.
100811         * tests/uninorm/test-u32-nfd.c: Likewise.
100812         * tests/uninorm/test-u32-nfd-big.c: Likewise.
100813         * tests/uninorm/test-u32-nfkc.c: Likewise.
100814         * tests/uninorm/test-u32-nfkc-big.c: Likewise.
100815         * tests/uninorm/test-u32-nfkd.c: Likewise.
100816         * tests/uninorm/test-u32-nfkd-big.c: Likewise.
100817         * tests/uninorm/test-u32-normalize-big.c: Likewise.
100819 2010-03-27  Bruno Haible  <bruno@clisp.org>
100821         Distinguish two kinds of module indicators.
100822         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_FOR_TESTS): Renamed from
100823         gl_MODULE_INDICATOR.
100824         (gl_MODULE_INDICATOR): New macro.
100825         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Invoke
100826         gl_MODULE_INDICATOR_FOR_TESTS instead of gl_MODULE_INDICATOR.
100827         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Likewise.
100828         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Likewise.
100829         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Likewise.
100830         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Likewise.
100831         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Likewise.
100832         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Likewise.
100833         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Likewise.
100834         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Likewise.
100835         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Likewise.
100836         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Likewise.
100837         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Likewise.
100838         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Likewise.
100839         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Likewise.
100840         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Likewise.
100841         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Likewise.
100842         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Likewise.
100843         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Likewise.
100844         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Likewise.
100845         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Likewise.
100846         * modules/cloexec (configure.ac): Likewise.
100847         * modules/getopt-gnu (configure.ac): Likewise.
100848         * modules/uninorm/u8-normalize (configure.ac): Likewise.
100849         * modules/uninorm/u16-normalize (configure.ac): Likewise.
100850         * modules/uninorm/u32-normalize (configure.ac): Likewise.
100851         * modules/fdopendir (configure.ac): Invoke gl_MODULE_INDICATOR.
100853 2010-03-27  Bruno Haible  <bruno@clisp.org>
100855         New module description field 'Comment'.
100856         * gnulib-tool: New option --extract-comment.
100857         (func_usage): Document it.
100858         (sed_extract_prog, sed_extract_field_header): Support 'Comment' field.
100859         (func_get_comment): New function.
100860         * modules/TEMPLATE-EXTENDED: Add a blank Comment field.
100862 2010-03-27  Bruno Haible  <bruno@clisp.org>
100864         Addendum to 2010-02-07 commit.
100865         * gnulib-tool (func_usage): Document --extract-applicability option.
100867 2010-03-27  Bruno Haible  <bruno@clisp.org>
100869         Use GNULIB_POSIXCHECK instead of GNULIB_PORTCHECK.
100870         * lib/time.in.h (asctime, asctime_r, ctime, ctime_r): Test
100871         GNULIB_POSIXCHECK, not GNULIB_PORTCHECK. Provide compile-time warnings
100872         rather than link errors.
100874 2010-03-27  Bruno Haible  <bruno@clisp.org>
100876         Avoid side effects from tests-related modules on the compilation of lib.
100877         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_CONDITION): New macro.
100878         (gl_MODULE_INDICATOR_SET_VARIABLE): Use its expansion as a value.
100879         * gnulib-tool (func_emit_tests_Makefile_am): Accept a witness_macro
100880         parameter. Emit into AM_CPPFLAGS a definition of the designated C
100881         macro.
100882         (func_import): Define a witness macro. Assign it a value that depends
100883         on the current package. Override gl_MODULE_INDICATOR_CONDITION for the
100884         tests-related modules.
100885         (func_create_testdir): Update func_emit_tests_Makefile_am invocation.
100886         Reported by Jim Meyering.
100888 2010-03-27  Bruno Haible  <bruno@clisp.org>
100890         Factorize common .m4 code.
100891         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_SET_VARIABLE): New macro.
100892         * m4/arpa_inet_h.m4 (gl_ARPA_INET_MODULE_INDICATOR): Use it.
100893         * m4/ctype.m4 (gl_CTYPE_MODULE_INDICATOR): Likewise.
100894         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Likewise.
100895         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Likewise.
100896         * m4/iconv_h.m4 (gl_ICONV_MODULE_INDICATOR): Likewise.
100897         * m4/inttypes.m4 (gl_INTTYPES_MODULE_INDICATOR): Likewise.
100898         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Likewise.
100899         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Likewise.
100900         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Likewise.
100901         * m4/netdb_h.m4 (gl_NETDB_MODULE_INDICATOR): Likewise.
100902         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Likewise.
100903         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Likewise.
100904         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Likewise.
100905         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Likewise.
100906         * m4/stddef_h.m4 (gl_STDDEF_MODULE_INDICATOR): Likewise.
100907         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Likewise.
100908         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Likewise.
100909         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Likewise.
100910         * m4/strings_h.m4 (gl_STRINGS_MODULE_INDICATOR): Likewise.
100911         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_MODULE_INDICATOR): Likewise.
100912         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Likewise.
100913         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Likewise.
100914         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Likewise.
100915         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Likewise.
100916         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Likewise.
100917         * m4/sys_times_h.m4 (gl_SYS_TIMES_MODULE_INDICATOR): Likewise.
100918         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_MODULE_INDICATOR): Likewise.
100919         * m4/sys_wait_h.m4 (gl_SYS_WAIT_MODULE_INDICATOR): Likewise.
100920         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Likewise.
100921         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Likewise.
100922         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Likewise.
100924 2010-03-27  Bruno Haible  <bruno@clisp.org>
100926         Fix a compilation error on Cygwin with g++ >= 4.3.
100927         * lib/sys_stat.in.h (lchmod): Don't warn about the use of this function
100928         if it is undefined or if we alias it to chmod.
100929         (lstat): Don't warn about the use of this function if it is undefined
100930         or if we alias it to stat.
100931         Reported by Simon Josefsson.
100933 2010-03-27  Bruno Haible  <bruno@clisp.org>
100935         * m4/getlogin.m4 (gl_FUNC_GETLOGIN): Renamed from gl_GETLOGIN.
100936         * modules/getlogin (configure.ac): Update.
100938         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Renamed from gl_GETLOGIN_R.
100939         * modules/getlogin_r (configure.ac): Update.
100941         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Renamed from gl_INET_NTOP.
100942         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Update.
100943         * modules/inet_ntop (configure.ac): Update.
100945         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Renamed from gl_INET_PTON.
100946         * modules/inet_pton (configure.ac): Update.
100948         * m4/mbslen.m4 (gl_FUNC_MBSLEN): Renamed from gl_MBSLEN.
100949         * modules/mbslen (configure.ac): Update.
100951         * m4/pty.m4 (gl_FUNC_FORKPTY): Renamed from gl_FORKPTY.
100952         (gl_FUNC_OPENPTY): Renamed from gl_OPENPTY.
100953         * modules/forkpty (configure.ac): Update.
100954         * modules/openpty (configure.ac): Update.
100956 2010-03-26  Simon Josefsson  <simon@josefsson.org>
100958         * top/maint.mk (sc_texinfo_acronym): Don't infloop if there is
100959         no *.texi files.  Reported by Eric Blake <eblake@redhat.com>.
100961 2010-03-25  Eric Blake  <eblake@redhat.com>
100963         maint: use pragma consistently across replacement headers
100964         * lib/ctype.in.h (system_header): Hoist for consistent placement.
100965         * lib/dirent.in.h (system_header): Likewise.
100966         * lib/errno.in.h (system_header): Likewise.
100967         * lib/float.in.h (system_header): Likewise.
100968         * lib/getopt.in.h (system_header): Likewise.
100969         * lib/iconv.in.h (system_header): Likewise.
100970         * lib/inttypes.in.h (system_header): Likewise.
100971         * lib/langinfo.in.h (system_header): Likewise.
100972         * lib/locale.in.h (system_header): Likewise.
100973         * lib/math.in.h (system_header): Likewise.
100974         * lib/netdb.in.h (system_header): Likewise.
100975         * lib/netinet_in.in.h (system_header): Likewise.
100976         * lib/pty.in.h (system_header): Likewise.
100977         * lib/sched.in.h (system_header): Likewise.
100978         * lib/se-selinux.in.h (system_header): Likewise.
100979         * lib/search.in.h (system_header): Likewise.
100980         * lib/spawn.in.h (system_header): Likewise.
100981         * lib/stdarg.in.h (system_header): Likewise.
100982         * lib/stdint.in.h (system_header): Likewise.
100983         * lib/string.in.h (system_header): Likewise.
100984         * lib/strings.in.h (system_header): Likewise.
100985         * lib/sys_file.in.h (system_header): Likewise.
100986         * lib/sys_ioctl.in.h (system_header): Likewise.
100987         * lib/sys_socket.in.h (system_header): Likewise.
100988         * lib/sys_times.in.h (system_header): Likewise.
100989         * lib/sys_utsname.in.h (system_header): Likewise.
100990         * lib/sys_wait.in.h (system_header): Likewise.
100991         * lib/sysexits.in.h (system_header): Likewise.
100992         * lib/unistd.in.h (system_header): Likewise.
100993         * lib/wctype.in.h (system_header): Likewise.
100995         arpa/inet: fix mingw compilation warning
100996         * lib/arpa_inet.in.h (system_header): Hoist to be unconditional.
100997         Reported by Matthew Bolte.
100999 2010-03-25  Bruno Haible  <bruno@clisp.org>
101001         Avoid collision between gnulib wrapper and libintl wrapper.
101002         * lib/printf.c (printf): Don't define if a printf wrapper is already
101003         defined in intl/printf.c.
101004         Reported by Michel Boaventura <michel@michelboaventura.com>.
101006 2010-03-25  Bruno Haible  <bruno@clisp.org>
101008         Use ANSI C.
101009         * lib/readutmp.h (getutent): Provide ANSI C prototype.
101011 2010-03-25  Bruno Haible  <bruno@clisp.org>
101013         Minor formatting changes.
101014         * lib/acosl.c: Insert space before function argument list.
101015         * lib/argz.c: Likewise.
101016         * lib/asinl.c: Likewise.
101017         * lib/expl.c: Likewise.
101018         * lib/gen-uni-tables.c: Likewise.
101019         * lib/gettext.h: Likewise.
101020         * lib/glthread/lock.h: Likewise.
101021         * lib/tanl.c: Likewise.
101022         * lib/uniname/uniname.c: Likewise.
101023         * tests/test-idpriv-drop.c: Likewise.
101024         * tests/test-idpriv-droptemp.c: Likewise.
101025         * tests/test-lock.c: Likewise.
101026         * tests/test-tls.c: Likewise.
101027         * lib/argp-help.c: Insert space before function-like macro argument
101028         list.
101029         * lib/memcmp.c: Likewise.
101030         * tests/test-base64.c: Likewise.
101031         * lib/localename.c: Insert space before sizeof's argument list.
101032         * lib/safe-alloc.h: Likewise.
101033         * lib/file-set.h: Insert space before macro argument list.
101034         * tests/test-argp.c: Likewise.
101035         * lib/argp-namefrob.h: Insert space before function parameter list.
101036         * lib/getaddrinfo.c: Likewise.
101037         * lib/netdb.in.h: Likewise.
101038         * lib/parse-duration.h: Likewise.
101039         * lib/parse-duration.c: Likewise.
101040         * lib/poll.c: Likewise.
101041         * lib/select.c: Likewise.
101042         * lib/trim.h: Likewise.
101043         * tests/test-usleep.c: Likewise.
101044         * lib/ldexpl.c: Insert space before function parameter list and before
101045         function argument list.
101046         * lib/logl.c: Likewise.
101047         * lib/sqrtl.c: Likewise.
101048         * lib/trim.c: Likewise.
101049         * lib/cosl.c: Use GNU style indentation. Insert space before function
101050         argument list.
101051         * lib/sinl.c: Likewise.
101052         * lib/tsearch.c: Insert space after 'for'.
101053         Reported by Jim Meyering.
101055 2010-03-23  Pádraig Brady  <P@draigBrady.com>  (tiny change)
101057         * maint.mk (sc_Wundef_boolean): Check for the presence of the
101058         config header before grepping, as it's not present before
101059         autoreconf/configure are run.  Reported by Simon Josefsson.
101061 2010-03-23  Bruno Haible  <bruno@clisp.org>
101063         pt_chown: Make it work with automake < 1.11.
101064         * modules/pt_chown (Makefile.am): Define pkglibexecdir.
101065         Reported by Simon Josefsson.
101067 2010-03-23  Bruno Haible  <bruno@clisp.org>
101069         pt_chown: Don't depend on GPLed modules.
101070         * lib/pt_chown.c: Don't include idpriv.h.
101071         (main): Don't drop privileges.
101072         * modules/pt_chown (Depends-on): Remove idpriv-drop.
101073         Reported by Simon Josefsson.
101075 2010-03-24  Simon Josefsson  <simon@josefsson.org>
101077         * top/maint.mk (sc_texinfo_acronym): Add rule, based on
101078         suggestions from karl@freefriends.org (Karl Berry).
101080 2010-03-22  Eric Blake  <eblake@redhat.com>
101082         gethostname: further tweaks
101083         * lib/unistd.in.h (includes): Only worry about <winsock2.h> if we
101084         are overriding gethostname.
101085         Suggested by Bruno Haible.
101087 2010-03-21  Bruno Haible  <bruno@clisp.org>
101089         Fix comments.
101090         * lib/forkpty.c (rpl_forkpty): Fix comment.
101091         * lib/openpty.c (rpl_openpty): Likewise.
101092         Reported by Eric Blake.
101094 2010-03-22  Eric Blake  <eblake@redhat.com>
101096         gethostname: fix build on mingw
101097         * lib/unistd.in.h (includes): Work around fact that mingw
101098         <winsock2.h> re-includes <unistd.h>, by avoiding any
101099         redeclarations if we are being included by <winsock2.h>.
101100         Reported by Matthias Bolte.
101102 2010-03-21  Bruno Haible  <bruno@clisp.org>
101104         forkpty: Provide replacement on AIX, HP-UX, IRIX, Solaris.
101105         * lib/forkpty.c (forkpty): New replacement function, from glibc with
101106         modifications.
101107         * lib/pty.in.h (forkpty): Update declaration. Add comments.
101108         * m4/pty.m4 (gl_FORKPTY): If forkpty is not declared, arrange to
101109         provide the replacement.
101110         * modules/forkpty (Depends-on): Add openpty, login_tty.
101111         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Initialize HAVE_FORKPTY.
101112         * modules/pty (Makefile.am): Substitute HAVE_FORKPTY.
101113         * doc/glibc-functions/forkpty.texi: More supported platforms.
101114         * config/srclist.txt: Add forkpty.c (commented).
101116 2010-03-21  Bruno Haible  <bruno@clisp.org>
101118         * modules/forkpty-tests: Use the common TEMPLATE-TESTS.
101119         (Makefile.am): Verify that PTY_LIB is defined.
101121         * modules/openpty-tests: Use the common TEMPLATE-TESTS.
101123 2010-03-21  Bruno Haible  <bruno@clisp.org>
101125         Tests for module 'login_tty'.
101126         * modules/login_tty-tests: New file.
101127         * tests/test-login_tty.c: New file.
101129         New module 'login_tty'.
101130         * lib/login_tty.c: New file.
101131         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): New macro.
101132         * modules/login_tty: New file.
101133         * doc/glibc-functions/login_tty.texi: Mention the new module.
101135 2010-03-21  Bruno Haible  <bruno@clisp.org>
101137         login_tty: Documentation.
101138         * doc/glibc-functions/login_tty.texi: New file.
101139         * doc/gnulib.texi (Glibc <utmp.h>): Include it.
101141 2010-03-21  Bruno Haible  <bruno@clisp.org>
101143         pty: Consistent macro naming.
101144         * m4/pty_h.m4 (gl_PTY_H): Renamed from gl_PTY.
101145         * m4/pty.m4 (gl_FORKPTY, gl_OPENPTY): Update.
101146         * modules/pty (configure.ac): Update.
101148 2010-03-21  Bruno Haible  <bruno@clisp.org>
101150         Tests for openpty: Make stricter.
101151         * tests/test-openpty.c (main): Add test of canonical processing and
101152         erase.
101153         * modules/openpty-tests (Makefile.am): Verify that PTY_LIB is defined.
101155         openpty: Provide replacement on AIX, HP-UX, IRIX, Solaris.
101156         * lib/openpty.c (openpty): New replacement function.
101157         * lib/pty.in.h: Include <termios.h>.
101158         (openpty): Update declaration. Add comments.
101159         * m4/pty.m4 (gl_OPENPTY): Require AC_USE_SYSTEM_EXTENSIONS. If openpty
101160         is not declared, arrange to provide the replacement. Check for _getpty
101161         and posix_openpt.
101162         * modules/openpty (Depends-on): Add extensions, fcntl-h, ioctl.
101163         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Initialize HAVE_OPENPTY.
101164         * modules/pty (Makefile.am): Substitute HAVE_OPENPTY.
101165         * modules/pty-tests (test_pty_c___LDADD): New variable.
101166         * doc/glibc-functions/openpty.texi: More supported platforms.
101168 2010-03-21  Bruno Haible  <bruno@clisp.org>
101170         setenv: Tweaks.
101171         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Include necessary headers in
101172         the test program.
101173         * doc/posix-functions/setenv.texi: Update platforms list.
101175 2010-03-21  Bruno Haible  <bruno@clisp.org>
101177         New module 'unlockpt'.
101178         * lib/unlockpt.c: New file, from glibc with modifications.
101179         * m4/unlockpt.m4: New file.
101180         * modules/unlockpt: New file.
101181         * lib/stdlib.in.h (unlockpt): New declaration.
101182         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether unlockpt is declared.
101183         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_UNLOCKPT, HAVE_UNLOCKPT.
101184         * modules/stdlib (Makefile.am): Substitute GNULIB_UNLOCKPT,
101185         HAVE_UNLOCKPT.
101186         * doc/posix-functions/unlockpt.texi: Mention the new module.
101187         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::unlockpt.
101188         * config/srclist.txt: Add unlockpt.c (commented).
101190 2010-03-21  Jim Meyering  <meyering@redhat.com>
101192         maint.mk: prohibit inclusion of "intprops.h" without use
101193         * top/maint.mk (sc_prohibit_intprops_without_use): New rule.
101195 2010-03-21  Bruno Haible  <bruno@clisp.org>
101197         New module 'grantpt'.
101198         * lib/grantpt.c: New file, from glibc with modifications.
101199         * m4/grantpt.m4: New file.
101200         * modules/grantpt: New file.
101201         * lib/stdlib.in.h (grantpt): New declaration.
101202         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether grantpt is declared.
101203         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_GRANTPT, HAVE_GRANTPT.
101204         * modules/stdlib (Makefile.am): Substitute GNULIB_GRANTPT,
101205         HAVE_GRANTPT.
101206         * doc/posix-functions/grantpt.texi: Mention the new module.
101207         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::grantpt.
101208         * config/srclist.txt: Add grantpt.c (commented).
101210 2010-03-21  Bruno Haible  <bruno@clisp.org>
101212         New module 'pt_chown'.
101213         * lib/pt_chown.c: New file, from glibc with modifications.
101214         * lib/pty-private.h: New file, from glibc with modifications.
101215         * modules/pt_chown: New file.
101216         * config/srclist.txt: Add pt_chown.c, pty-private.h (commented).
101218 2010-03-21  Bruno Haible  <bruno@clisp.org>
101220         Tests for module 'ptsname'.
101221         * modules/ptsname-tests: New file.
101222         * tests/test-ptsname.c: New file.
101224         New module 'ptsname'.
101225         * lib/ptsname.c: New file, from glibc with modifications.
101226         * m4/ptsname.m4: New file.
101227         * modules/ptsname: New file.
101228         * lib/stdlib.in.h (ptsname): New declaration.
101229         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether ptsname is declared.
101230         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_PTSNAME, HAVE_PTSNAME.
101231         * modules/stdlib (Makefile.am): Substitute GNULIB_PTSNAME,
101232         HAVE_PTSNAME.
101233         * doc/posix-functions/ptsname.texi: Mention the new module.
101234         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::ptsname.
101235         * config/srclist.txt: Add ptsname.c (commented).
101237 2010-03-21  Bruno Haible  <bruno@clisp.org>
101239         Tests for module 'ttyname_r'.
101240         * modules/ttyname_r-tests: New file.
101241         * tests/test-ttyname_r.c: New file.
101243         New module 'ttyname_r'.
101244         * lib/ttyname_r.c: New file.
101245         * m4/ttyname_r.m4: New file.
101246         * modules/ttyname_r: New file.
101247         * lib/unistd.in.h (ttyname_r): New declaration.
101248         * m4/unistd_h.m4 (gl_UNISTD_H): Check whether ttyname_r is declared.
101249         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_TTYNAME_R, HAVE_TTYNAME_R.
101250         * modules/unistd (Makefile.am): Substitute GNULIB_TTYNAME_R,
101251         HAVE_TTYNAME_R.
101252         * tests/test-unistd-c++.cc: Check GNULIB_NAMESPACE::ttyname_r.
101253         * doc/posix-functions/ttyname_r.texi: Mention the new module.
101255 2010-03-20  Bruno Haible  <bruno@clisp.org>
101257         signal: Undefine macro definitions in C++ mode.
101258         * lib/signal.in.h (sigismember, sigemptyset, sigaddset, sigdelset,
101259         sigfillset): Undefine macro definitions from the system header in C++
101260         mode.
101261         Reported by John W. Eaton <jwe@gnu.org>.
101263 2010-03-20  Bruno Haible  <bruno@clisp.org>
101265         Ensure no #include statements inside extern "C" { ... }.
101266         * lib/obstack.h: Shrink extern "C" { ... } region so that it does not
101267         contain #include statements.
101268         * lib/time.in.h: Likewise.
101270 2010-03-20  Bruno Haible  <bruno@clisp.org>
101272         Make _GL_WARN_ON_USE usable in C++ and C mode in the same compilation.
101273         * build-aux/warn-on-use.h (_GL_WARN_EXTERN_C): New macro.
101274         (_GL_WARN_ON_USE, _GL_WARN_ON_USE_CXX): Likewise.
101275         Reported by John W. Eaton <jwe@gnu.org>.
101277 2010-03-20  Bruno Haible  <bruno@clisp.org>
101279         * m4/unlink.m4 (gl_FUNC_UNLINK): Fix last commit.
101280         Reported by Jim Meyering.
101282 2010-03-20  Bruno Haible  <bruno@clisp.org>
101284         pipe: Set errno upon failure.
101285         * lib/pipe.h: Specify that when -1 is returned, errno is set.
101286         * lib/pipe.c (create_pipe): Set errno when returning -1. Use the right
101287         errno value in error message.
101289 2010-03-20  Bruno Haible  <bruno@clisp.org>
101290             Jim Meyering  <meyering@redhat.com>
101292         lchown: Avoid "unused variable" warning.
101293         * lib/lchown.c (rpl_lchown): Move variable 'st' into #if block.
101295 2010-03-20  Bruno Haible  <bruno@clisp.org>
101297         Work around unlink() bug on MacOS X 10.5.6.
101298         * lib/unlink.c (rpl_unlink): If UNLINK_PARENT_BUG is defined, fail when
101299         attempting to unlink a parent directory.
101300         * m4/unlink.m4 (gl_FUNC_UNLINK): Require AC_CANONICAL_HOST. Test for
101301         MacOS X 10.5 bug. If the bug is present, define UNLINK_PARENT_BUG and
101302         activate for the replacement function.
101303         * doc/posix-functions/unlink.texi: Mention the MacOS X 10.5 bug.
101305 2010-03-20  Bruno Haible  <bruno@clisp.org>
101307         Fix link errors on Solaris 8.
101308         * modules/dirent-tests (test_dirent_c___LDADD): Add LIB_NANOSLEEP.
101309         * modules/wctype-tests (test_wctype_c___LDADD): Likewise.
101311 2010-03-19  Jim Meyering  <meyering@redhat.com>
101313         regcomp.c: make non-_LIBC implementation of build_range_exp consistent
101314         The _LIBC implementation of build_range_exp correctly honors the
101315         RE_NO_EMPTY_RANGES flag when checking for reversed range endpoints.
101316         However, the non-_LIBC implementation would ignore that syntax-bit
101317         flag and return REG_ERANGE unconditionally.
101318         This change makes it honor that flag.
101319         * lib/regcomp.c (build_range_exp) [!_LIBC]: Add a parameter: "syntax".
101320         Make two pointer parameters "const".
101321         Use "syntax" bits in order to honor RE_NO_EMPTY_RANGES.
101322         (parse_bracket_exp): Update caller.
101324         regex.m4: correct the reversed range endpoint ([b-a]) test
101325         * m4/regex.m4: When requiring that [b-a] evoke failure,
101326         use RE_NO_EMPTY_RANGES.  This makes this entire configure-time
101327         test pass once again for x86-based systems.
101329 2010-03-19  Bruno Haible  <bruno@clisp.org>
101331         scandir: Fix link error on Solaris 8.
101332         * lib/scandir.c (_D_EXACT_NAMLEN, _D_ALLOC_NAMLEN): New fallback
101333         macros.
101335 2010-03-19  Bruno Haible  <bruno@clisp.org>
101337         getusershell: Fix documentation.
101338         * doc/glibc-functions/endusershell.texi: Refer to the getusershell
101339         module.
101340         * doc/glibc-functions/setusershell.texi: Likewise.
101342         getusershell: Provide declaration, missing on Solaris 9.
101343         * lib/unistd.in.h (getusershell, setusershell, endusershell): Declare
101344         also if HAVE_GETUSERSHELL && !HAVE_DECL_GETUSERSHELL.
101345         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): When the function exists,
101346         check whether it is declared. Set HAVE_DECL_GETUSERSHELL.
101347         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
101348         HAVE_DECL_GETUSERSHELL, not HAVE_GETUSERSHELL.
101349         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETUSERSHELL, not
101350         HAVE_GETUSERSHELL.
101351         * doc/glibc-functions/getusershell.texi: Mention the Solaris problem.
101353 2010-03-19  Bruno Haible  <bruno@clisp.org>
101355         wctype: Provide iswblank function.
101356         * lib/wctype.in.h (iswblank): Provide a replacement also when iswcntrl
101357         exists and is fine.
101358         * m4/wctype_h.m4 (gl_WCTYPE_H): Also check whether iswcntrl exists.
101359         * modules/wctype (Makefile.am): Substitute HAVE_ISWBLANK.
101360         * tests/test-wctype.c (main): Re-enable the iswblank tests.
101361         * doc/posix-functions/iswblank.texi: Update.
101363 2010-03-19  Bruno Haible  <bruno@clisp.org>
101365         Tests of module 'pty' in C++ mode.
101366         * modules/pty-tests: New file.
101367         * tests/test-pty-c++.cc: New file.
101368         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
101370 2010-03-19  Eric Blake  <eblake@redhat.com>
101372         logb: fix documentation
101373         * doc/posix-functions/logb.texi (logb): Gnulib fixes the cygwin
101374         1.5 declaration bug.
101376         forkpty, openpty: prefer glibc's const-safe prototype
101377         * lib/forkpty.c (rpl_forkpty): New file.
101378         * lib/openpty.c (rpl_openpty): Likewise.
101379         * modules/forkpty (Files): Distribute it.
101380         * modules/openpty (Files): Likewise.
101381         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Add new witnesses.  Move decl
101382         check...
101383         * m4/pty.m4 (gl_FORKPTY, gl_OPENPTY): ...here.  Request
101384         replacement for non-const BSD signature.
101385         * modules/pty (Makefile.am): Substitute witnesses.
101386         * lib/pty.in.h (forkpty, openpty): Declare replacements.
101387         * tests/test-forkpty.c: Update signature check.
101388         * tests/test-openpty.c: Likewise.
101389         * doc/glibc-functions/forkpty.texi (forkpty): Document the fix.
101390         * doc/glibc-functions/openpty.texi (openpty): Likewise.
101392         forkpty, openpty: split functions into new modules
101393         * modules/pty (Makefile.am): Substitute new witnesses.
101394         (Libraries): Move library detection...
101395         * modules/forkpty: ...into new module.
101396         * modules/openpty: Another new module.
101397         * modules/pty-tests: Rename and split...
101398         * modules/forkpty-tests: ...to this...
101399         * modules/openpty-tests: ...and this.
101400         * tests/test-pty.c: Rename and split...
101401         * tests/test-forkpty.c: ...to this...
101402         * tests/test-openpty.c: ...and this.
101403         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Add new witnesses.
101404         (gl_PTY): Split library searching...
101405         * m4/pty.m4 (gl_PTY_LIB): ...into new file.
101406         (gl_FORKPTY, gl_OPENPTY): New macros.
101407         * lib/pty.in.h (forkpty, openpty): Honor new witnesses.
101408         * NEWS: Mention the split.
101409         * MODULES.html.sh (Misc): Document the modules.
101410         * doc/glibc-functions/forkpty.texi (forkpty): Likewise.
101411         * doc/glibc-functions/openpty.texi (openpty): Likewise.
101413         pty: improve replacement header
101414         * lib/pty.in.h: New file.
101415         * modules/pty (Files): Ship it.
101416         (Makefile.am): Always build replacement.
101417         * m4/pty.m4: Rename...
101418         * m4/pty_h.m4: ...to this.
101419         (gl_PTY): Modernize setting of witness macros; update check of
101420         forkpty to take proper advantage of cache.
101421         (gl_PTY_MODULE_INDICATOR, gl_PTY_H_DEFAULTS): New macros.
101423         getopt: avoid compiler warning
101424         * lib/getopt.c (attribute_hidden): Remove unused macro.
101426 2010-03-18  Bruno Haible  <bruno@clisp.org>
101428         Fix link errors on Solaris 8.
101429         * modules/iconv-h-tests (test_iconv_h_c___LDADD): Add LIB_NANOSLEEP.
101430         * modules/search-tests (test_search_c___LDADD): Likewise.
101431         * modules/signal-tests (test_signal_c___LDADD): Likewise.
101432         * modules/spawn-tests (test_spawn_c___LDADD): Likewise.
101433         * modules/stdio-tests (test_stdio_c___LDADD): Likewise.
101434         * modules/sys_select-tests (test_sys_select_c___LDADD): Likewise.
101435         * modules/sys_socket-tests (test_sys_socket_c___LDADD): Likewise.
101436         * modules/sys_time-tests (test_sys_time_c___LDADD): Likewise.
101437         * modules/wchar-tests (test_wchar_c___LDADD): Likewise.
101439 2010-03-18  Bruno Haible  <bruno@clisp.org>
101441         Fix bug introduced on 2010-03-14.
101442         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): New macro.
101443         (gl_SPAWN_H): Require it.
101444         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Likewise.
101445         Reported by Simon Josefsson.
101447 2010-03-18  Bruno Haible  <bruno@clisp.org>
101449         Fix typo introduced on 2009-12-31.
101450         * m4/spawn_h.m4 (gl_SPAWN_H): Check for the declaration of
101451         posix_spawn_file_actions_adddup2.
101453 2010-03-17  Bert Wesarg  <bert.wesarg@googlemail.com>  (tiny change)
101454         and Eric Blake  <eblake@redhat.com>
101456         test-vc-list-files-git: make more robust
101457         * tests/test-vc-list-files-git.sh: Unset problematic environment
101458         variables.  Chain commands together.
101460 2010-03-17  Ludovic Courtès  <ludo@gnu.org>  (tiny change)
101462         * m4/pty.m4: Unset $ac_cv_have_decl_forkpty before the second
101463         `AC_CHECK_DECL' invocation.
101465 2010-03-15  Sergey Poznyakoff  <gray@gnu.org.ua>
101467         * lib/inttostr.c (inttostr): Make sure the invocation of verify
101468         appears before executable statements. Suggested by Petr Sumbera
101469         <Petr.Sumbera@Sun.COM>.
101471 2010-03-14  Bruno Haible  <bruno@clisp.org>
101473         * tests/test-flock.c (test_exclusive): Comment out a test that causes
101474         portability problems. Instead use a simpler test.
101475         (main): Check that invalid arguments are rejected only on Linux.
101477 2010-03-14  Bruno Haible  <bruno@clisp.org>
101479         Fix bug introduced on 2009-12-31.
101480         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Invoke
101481         gl_PREREQ_SYS_H_WINSOCK2 always.
101482         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise. Remove
101483         SYS_SOCKET_H variable.
101484         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Remove test for flock.
101485         Update comments.
101486         * m4/ctype.m4 (gl_CTYPE_H): Update comments.
101487         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
101488         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
101489         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
101490         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H): Likewise.
101492 2010-03-14  Bruno Haible  <bruno@clisp.org>
101494         Fix values returned by sinl, cosl.
101495         * lib/trigl.h: Add specification comments.
101496         * lib/sincosl.c (kernel_sinl, kernel_cosl): Fix comments and formula
101497         that combines the values from the precomputed table with the values of
101498         the Chebyshev polynomials.
101500 2010-03-14  Bruno Haible  <bruno@clisp.org>
101502         Fix compilation error when modules 'posix_spawn[p]' are not used.
101503         * m4/spawn_h.m4 (gl_SPAWN_H): Set HAVE_POSIX_SPAWN here.
101504         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): ... not here.
101506 2010-03-14  Bruno Haible  <bruno@clisp.org>
101508         Fix compilation error on mingw when module 'time_r' is not used.
101509         * lib/time.in.h (localtime_r, gmtime_r): Declare only if GNULIB_TIME_R
101510         is 1.
101511         * tests/test-time-c++.cc (localtime_r, gmtime_r): Likewise.
101512         * modules/time_r (configure.ac): Invoke gl_TIME_MODULE_INDICATOR.
101513         * modules/time (Makefile.am): Substitute GNULIB_TIME_R.
101514         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_TIME_R.
101516 2010-03-14  Bruno Haible  <bruno@clisp.org>
101518         Fix compilation error with Sun C.
101519         * lib/strtol.c: Use LLONG_MIN instead of GCC specific LONG_LONG_MIN.
101520         Use LLONG_MAX instead of GCC specific LONG_LONG_MAX. Use ULLONG_MAX
101521         instead of GCC specific ULONG_LONG_MAX.
101522         * lib/xstrtoll.c: Likewise.
101523         * lib/xstrtoull.c: Likewise.
101525 2010-03-13  Bruno Haible  <bruno@clisp.org>
101527         Allow the user to disable C++ code and tests.
101528         * m4/ansi-c++.m4 (gl_CXX_CHOICE): New macro.
101529         (gl_PROG_ANSI_CXX): Require it.
101531 2010-03-13  Bruno Haible  <bruno@clisp.org>
101533         * DEPENDENCIES (libtool): Mention libtool 2.2.x requirement in special
101534         cases.
101536 2010-03-13  Bruno Haible  <bruno@clisp.org>
101538         Test that gnulib does not break the standard C++ headers.
101539         * tests/test-locale-c++2.cc: New file.
101540         * modules/locale-tests (Files): Add it.
101541         (Makefile.am): Compile it for test-locale-c++.
101542         * tests/test-math-c++2.cc: New file.
101543         * modules/math-tests (Files): Add it.
101544         (Makefile.am): Compile it for test-math-c++.
101545         * tests/test-signal-c++2.cc: New file.
101546         * modules/signal-tests (Files): Add it.
101547         (Makefile.am): Compile it for test-signal-c++.
101548         * tests/test-stdio-c++2.cc: New file.
101549         * modules/stdio-tests (Files): Add it.
101550         (Makefile.am): Compile it for test-stdio-c++.
101551         * tests/test-stdlib-c++2.cc: New file.
101552         * modules/stdlib-tests (Files): Add it.
101553         (Makefile.am): Compile it for test-stdlib-c++.
101554         * tests/test-string-c++2.cc: New file.
101555         * modules/string-tests (Files): Add it.
101556         (Makefile.am): Compile it for test-string-c++.
101557         * tests/test-time-c++2.cc: New file.
101558         * modules/time-tests (Files): Add it.
101559         (Makefile.am): Compile it for test-time-c++.
101560         Reported by John W. Eaton <jwe@gnu.org>.
101562 2010-03-13  Bruno Haible  <bruno@clisp.org>
101564         * gnulib-tool (func_usage): Clarify which options are available for
101565         --create-testdir and --create-megatestdir.
101567 2010-03-13  Bruno Haible  <bruno@clisp.org>
101569         Fix compilation error with glibc >= 2.10 and g++ >= 4.4.
101570         * build-aux/warn-on-use.h (_GL_WARN_ON_USE_CXX): New macro.
101571         * build-aux/c++defs.h (_GL_CXXALIASWARN1): New macro.
101572         * lib/string.in.h (memchr, memrchr, rawmemchr, strchrnul, strpbrk,
101573         strstr, strcasestr): Use _GL_CXXALIASWARN1 instead of _GL_CXXALIASWARN
101574         when appropriate.
101575         Reported by Jim Meyering.
101577 2010-03-12  Simon Josefsson  <simon@josefsson.org>
101579         * gnulib-tool (func_import): Explain origin of code.
101581 2010-03-12  Bruno Haible  <bruno@clisp.org>
101583         Fix problem with automake's definition of CXXLINK.
101584         * gnulib-tool (func_create_testdir): After LT_INIT, also use LT_LANG.
101585         Reported by Simon Josefsson and Ludovic Courtès.
101587 2010-03-12  Bruno Haible  <bruno@clisp.org>
101589         * doc/gnulib-intro.texi (Steady Development): Mention Ian Beckwith's
101590         stable releases.
101592 2010-03-11  Bruno Haible  <bruno@clisp.org>
101594         Fix problems with overloaded C++ definitions of memchr, strpbrk, etc.
101595         * build-aux/c++defs.h (_GL_CXXALIAS_SYS_CAST2): Make it work regardless
101596         whether the system provides one variant or multiple variants of the
101597         function.
101598         * lib/string.in.h (memchr, strpbrk): Use _GL_CXXALIAS_SYS_CAST2 for all
101599         C++ compilers.
101600         (memrchr, rawmemchr, strchrnul, strstr, strcasestr): Use
101601         _GL_CXXALIAS_SYS_CAST2 instead of _GL_CXXALIAS_SYS.
101602         Reported by Jim Meyering.
101604 2010-03-09  Simon Josefsson  <simon@josefsson.org>
101606         * gnulib-tool (LIBTOOLPATH): Fix cut'n'paste bug.
101608 2010-03-08  Bruno Haible  <bruno@clisp.org>
101610         gnulib-tool: Add support for --libtool in --create-testdir.
101611         * gnulib-tool (LIBTOOLPATH, LIBTOOLIZE): New variables.
101612         (func_create_testdir): Emit LT_INIT invocations. Invoke LIBTOOLIZE.
101614 2010-03-08  Eric Blake  <eblake@redhat.com>
101616         gnulib-tool.texi: mention possibility of git submodule
101617         * doc/gnulib-tool.texi (VCS Issues): Add details about using git
101618         submodules.
101619         * doc/.gitignore: Ignore another generated file.
101621 2010-03-08  Karl Berry  <karl@gnu.org>
101623         * doc/gnulib-tool.texi (VCS Issues): Mention third option
101624         of committing gnulib files while skipping others.
101626 2010-03-07  Bruno Haible  <bruno@clisp.org>
101628         Tests of module 'wctype' in C++ mode.
101629         * tests/test-wctype-c++.cc: New file.
101630         * modules/wctype-tests (Files): Add it and tests/signature.h.
101631         (Depends-on): Add ansi-c++-opt.
101632         (Makefile.am): Arrange to compile and run test-wctype-c++.
101634         Tests of module 'wchar' in C++ mode.
101635         * tests/test-wchar-c++.cc: New file.
101636         * modules/wchar-tests (Files): Add it and tests/signature.h.
101637         (Depends-on): Add ansi-c++-opt.
101638         (Makefile.am): Arrange to compile and run test-wchar-c++.
101639         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Invoke
101640         gl_MODULE_INDICATOR.
101642         Tests of module 'unistd' in C++ mode.
101643         * tests/test-unistd-c++.cc: New file.
101644         * modules/unistd-tests (Files): Add it and tests/signature.h.
101645         (Depends-on): Add ansi-c++-opt.
101646         (Makefile.am): Arrange to compile and run test-unistd-c++.
101647         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Invoke
101648         gl_MODULE_INDICATOR.
101650         Tests of module 'time' in C++ mode.
101651         * tests/test-time-c++.cc: New file.
101652         * modules/time-tests (Files): Add it and tests/signature.h.
101653         (Depends-on): Add ansi-c++-opt.
101654         (Makefile.am): Arrange to compile and run test-time-c++.
101655         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
101657         Tests of module 'sys_time' in C++ mode.
101658         * tests/test-sys_time-c++.cc: New file.
101659         * modules/sys_time-tests (Files): Add it and tests/signature.h.
101660         (Depends-on): Add ansi-c++-opt.
101661         (Makefile.am): Arrange to compile and run test-sys_time-c++.
101662         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Invoke
101663         gl_MODULE_INDICATOR.
101665         Tests of module 'sys_stat' in C++ mode.
101666         * tests/test-sys_stat-c++.cc: New file.
101667         * modules/sys_stat-tests (Files): Add it and tests/signature.h.
101668         (Depends-on): Add ansi-c++-opt.
101669         (Makefile.am): Arrange to compile and run test-sys_stat-c++.
101670         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Invoke
101671         gl_MODULE_INDICATOR.
101673         Tests of module 'sys_socket' in C++ mode.
101674         * tests/test-sys_socket-c++.cc: New file.
101675         * modules/sys_socket-tests (Files): Add it and tests/signature.h.
101676         (Depends-on): Add ansi-c++-opt.
101677         (Makefile.am): Arrange to compile and run test-sys_socket-c++.
101678         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Invoke
101679         gl_MODULE_INDICATOR.
101681         Tests of module 'sys_select' in C++ mode.
101682         * tests/test-sys_select-c++.cc: New file.
101683         * modules/sys_select-tests (Files): Add it and tests/signature.h.
101684         (Depends-on): Add ansi-c++-opt.
101685         (Makefile.am): Arrange to compile and run test-sys_select-c++.
101686         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Invoke
101687         gl_MODULE_INDICATOR.
101689         Tests of module 'sys_ioctl' in C++ mode.
101690         * tests/test-sys_ioctl-c++.cc: New file.
101691         * modules/sys_ioctl-tests (Files): Add it and tests/signature.h.
101692         (Depends-on): Add ansi-c++-opt.
101693         (Makefile.am): Arrange to compile and run test-sys_ioctl-c++.
101694         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Invoke
101695         gl_MODULE_INDICATOR.
101697         Tests of module 'string' in C++ mode.
101698         * tests/test-string-c++.cc: New file.
101699         * modules/string-tests (Files): Add it and tests/signature.h.
101700         (Depends-on): Add ansi-c++-opt.
101701         (Makefile.am): Arrange to compile and run test-string-c++.
101702         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Invoke
101703         gl_MODULE_INDICATOR.
101705         Tests of module 'stdlib' in C++ mode.
101706         * tests/test-stdlib-c++.cc: New file.
101707         * modules/stdlib-tests (Files): Add it and tests/signature.h.
101708         (Depends-on): Add ansi-c++-opt.
101709         (Makefile.am): Arrange to compile and run test-stdlib-c++.
101710         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Invoke
101711         gl_MODULE_INDICATOR.
101713         Tests of module 'stdio' in C++ mode.
101714         * tests/test-stdio-c++.cc: New file.
101715         * modules/stdio-tests (Files): Add it and tests/signature.h.
101716         (Depends-on): Add ansi-c++-opt.
101717         (Makefile.am): Arrange to compile and run test-stdio-c++.
101718         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Invoke
101719         gl_MODULE_INDICATOR.
101721         Tests of module 'spawn' in C++ mode.
101722         * tests/test-spawn-c++.cc: New file.
101723         * modules/spawn-tests (Files): Add it and tests/signature.h.
101724         (Depends-on): Add ansi-c++-opt.
101725         (Makefile.am): Arrange to compile and run test-spawn-c++.
101726         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Invoke
101727         gl_MODULE_INDICATOR.
101729         Tests of module 'signal' in C++ mode.
101730         * tests/test-signal-c++.cc: New file.
101731         * modules/signal-tests (Files): Add it and tests/signature.h.
101732         (Depends-on): Add ansi-c++-opt.
101733         (Makefile.am): Arrange to compile and run test-signal-c++.
101734         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Invoke
101735         gl_MODULE_INDICATOR.
101737         Tests of module 'search' in C++ mode.
101738         * tests/test-search-c++.cc: New file.
101739         * modules/search-tests (Files): Add it and tests/signature.h.
101740         (Depends-on): Add ansi-c++-opt.
101741         (Makefile.am): Arrange to compile and run test-search-c++.
101742         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Invoke
101743         gl_MODULE_INDICATOR.
101745         Tests of module 'math' in C++ mode.
101746         * tests/test-math-c++.cc: New file.
101747         * modules/math-tests (Files): Add it and tests/signature.h.
101748         (Depends-on): Add ansi-c++-opt.
101749         (Makefile.am): Arrange to compile and run test-math-c++.
101750         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
101752         Tests of module 'locale' in C++ mode.
101753         * tests/test-locale-c++.cc: New file.
101754         * modules/locale-tests (Files): Add it and tests/signature.h.
101755         (Depends-on): Add ansi-c++-opt.
101756         (Makefile.am): Arrange to compile and run test-locale-c++.
101757         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Invoke
101758         gl_MODULE_INDICATOR.
101760         Tests of module 'langinfo' in C++ mode.
101761         * tests/test-langinfo-c++.cc: New file.
101762         * modules/langinfo-tests (Files): Add it and tests/signature.h.
101763         (Depends-on): Add ansi-c++-opt.
101764         (Makefile.am): Arrange to compile and run test-langinfo-c++.
101765         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Invoke
101766         gl_MODULE_INDICATOR.
101768         Tests of module 'iconv-h' in C++ mode.
101769         * tests/test-iconv-h-c++.cc: New file.
101770         * modules/iconv-h-tests (Files): Add it and tests/signature.h.
101771         (Depends-on): Add ansi-c++-opt.
101772         (Makefile.am): Arrange to compile and run test-iconv-h-c++.
101774         Tests of module 'glob' in C++ mode.
101775         * tests/test-glob-c++.cc: New file.
101776         * modules/glob-tests (Files): Add it.
101777         (Depends-on): Add ansi-c++-opt.
101778         (Makefile.am): Arrange to compile and run test-glob-c++.
101780         Tests of module 'fcntl-h' in C++ mode.
101781         * tests/test-fcntl-h-c++.cc: New file.
101782         * modules/fcntl-h-tests (Files): Add it and tests/signature.h.
101783         (Depends-on): Add ansi-c++-opt.
101784         (Makefile.am): Arrange to compile and run test-fcntl-h-c++.
101785         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Invoke
101786         gl_MODULE_INDICATOR.
101788         Tests of module 'dirent' in C++ mode.
101789         * tests/test-dirent-c++.cc: New file.
101790         * modules/dirent-tests (Files): Add it and tests/signature.h.
101791         (Depends-on): Add ansi-c++-opt.
101792         (Makefile.am): Arrange to compile and run test-dirent-c++.
101793         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Invoke
101794         gl_MODULE_INDICATOR.
101796         New module 'ansi-c++-opt'.
101797         * modules/ansi-c++-opt: New file.
101798         * m4/ansi-c++.m4: New file, from GNU gettext with modifications.
101800         Document C++ namespace mode.
101801         * doc/gnulib.texi (A C++ namespace for gnulib): New section.
101803         wctype: Avoid #define replacements in C++ mode.
101804         * lib/wctype.in.h: Include c++defs.h, warn-on-use.h.
101805         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower,
101806         iswprint, iswpunct, iswspace, iswupper, iswxdigit, towlower, towupper):
101807         In C++, define a namespaced alias symbol.
101808         * m4/wctype_h.m4 (gl_WCTYPE_H): Don't set WCTYPE_H.
101809         * modules/wctype (Depends-on): Add c++defs, warn-on-use.
101810         (Makefile.am): Provide a wctype.h replacement always. Update wctype.h
101811         rule.
101813         wchar: Avoid #define replacements in C++ mode.
101814         * lib/wchar.in.h: Include c++defs.h.
101815         (btowc, wctob, mbsinit, mbrtowc, mbrlen, mbsrtowcs, mbsnrtowcs,
101816         wcrtomb, wcsrtombs, wcsnrtombs): In C++, define a namespaced alias
101817         symbol.
101818         (wcwidth): Likewise. Fix prototype to be POSIX compliant.
101819         * modules/wchar (Depends-on): Add c++defs.
101820         (Makefile.am): Update wchar.h rule.
101822         unistd: Avoid #define replacements in C++ mode.
101823         * lib/unistd.in.h: Include c++defs.h.
101824         (chown, close, dup, dup2, dup3, euidaccess, faccessat, fchdir,
101825         fchownat, fsync, ftruncate, getcwd, getdomainname, getdtablesize,
101826         getgroups, gethostname, getlogin, getlogin_r, getpagesize,
101827         getusershell, setusershell, endusershell, lchown, link, linkat, lseek,
101828         pipe2, pread, readlink, readlinkat, rmdir, sleep, symlink, symlinkat,
101829         unlink, unlinkat, usleep, write): In C++, define a namespaced alias
101830         symbol.
101831         (environ): Update.
101832         * modules/unistd (Depends-on): Add c++defs.
101833         (Makefile.am): Update unistd.h rule.
101835         time: Avoid #define replacements in C++ mode.
101836         * lib/time.in.h: Include c++defs.h, warn-on-use.h.
101837         (nanosleep, mktime, localtime_r, gmtime_r, strptime, timegm): In C++,
101838         define a namespaced alias symbol.
101839         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): New macro.
101840         (gl_HEADER_TIME_H_DEFAULTS): Initialize also GNULIB_MKTIME,
101841         GNULIB_NANOSLEEP, GNULIB_STRPTIME, GNULIB_TIMEGM.
101842         * modules/time (Depends-on): Add c++defs, warn-on-use.
101843         (Makefile.am): Update time.h rule.
101844         * modules/mktime (configure.ac): Invoke gl_TIME_MODULE_INDICATOR.
101845         * modules/nanosleep (configure.ac): Likewise.
101846         * modules/strptime (configure.ac): Likewise.
101847         * modules/timegm (configure.ac): Likewise.
101849         sys_time: Avoid #define replacements in C++ mode.
101850         * lib/sys_time.in.h: Include c++defs.h.
101851         (gettimeofday): In C++, define a namespaced alias symbol.
101852         * modules/sys_time (Depends-on): Add c++defs.
101853         (Makefile.am): Update sys/time.h rule.
101855         sys_stat: Avoid #define replacements in C++ mode.
101856         * lib/sys_stat.in.h: Include c++defs.h.
101857         (fchmodat, fstat, fstatat, futimens, lchmod, lstat, mkdir, mkdirat,
101858         mkfifo, mkfifoat, mknod, mknodat, utimensat): In C++, define a
101859         namespaced alias symbol.
101860         In C++, define a namespaced alias symbol.
101861         * modules/sys_stat (Depends-on): Add c++defs.
101862         (Makefile.am): Update sys/stat.h rule.
101864         sys_socket: Avoid #define replacements in C++ mode.
101865         * lib/sys_socket.in.h: Handle the case of recursive include on Cygwin.
101866         Include c++defs.h. Include warn-on-use.h earlier. Enable the function
101867         definitions also when the system has a <sys/socket.h>.
101868         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
101869         listen, recv, send, recvfrom, sendto, setsockopt, shutdown, accept4):
101870         In C++, define a namespaced alias symbol.
101871         * modules/sys_socket (Depends-on): Add c++defs.
101872         (Makefile.am): Update sys/socket.h rule.
101874         sys_select: Avoid #define replacements in C++ mode.
101875         * lib/sys_select.in.h: Include c++defs.h. Enable the function
101876         definitions also when the system has a <sys/select.h>.
101877         (select): In C++, define a namespaced alias symbol.
101878         * modules/sys_select (Depends-on): Add c++defs.
101879         (Makefile.am): Update sys/select.h rule.
101881         sys_ioctl: Avoid #define replacements in C++ mode.
101882         * lib/sys_ioctl.in.h: Include c++defs.h.
101883         (ioctl): In C++, define a namespaced alias symbol.
101884         * modules/sys_ioctl (Depends-on): Add c++defs.
101885         (Makefile.am): Update sys/ioctl.h rule.
101887         string: Avoid #define replacements in C++ mode.
101888         * lib/string.in.h: Include c++defs.h.
101889         (stpncpy): Define to rpl_stpncpy, not gnu_stpncpy.
101890         (memchr, memmem, mempcpy, memrchr, rawmemchr, stpcpy, stpncpy,
101891         strchrnul, strdup, strndup, strnlen, strpbrk, strsep, strstr,
101892         strcasestr, strtok_r, mbslen, mbschr, mbsrchr, mbspbrk, strerror,
101893         strsignal, strverscmp): In C++, define a namespaced alias symbol.
101894         * modules/string (Depends-on): Add c++defs.
101895         (Makefile.am): Update string.h rule.
101897         stdlib: Avoid #define replacements in C++ mode.
101898         * lib/stdlib.in.h: Include c++defs.h.
101899         (atoll, calloc, canonicalize_file_name, getloadavg, getsubopt, malloc,
101900         mkdtemp, mkostemp, mkostemps, mkstemp, mkstemps, putenv, random_r,
101901         srandom_r, initstate_r, setstate_r, realloc, realpath, rpmatch, setenv,
101902         strtod, strtoll, strtoull, unsetenv): In C++, define a namespaced alias
101903         symbol.
101904         * modules/stdlib (Depends-on): Add c++defs.
101905         (Makefile.am): Update stdlib.h rule.
101907         stdio: Avoid #define replacements in C++ mode.
101908         * lib/stdio.in.h: Include c++defs.h.
101909         (dprintf, fclose, fflush, fopen, fprintf, fpurge, fputc, fputs,
101910         freopen, fseek, fseeko, ftell, ftello, fwrite, getdelim, getline,
101911         obstack_printf, obstack_vprintf, perror, popen, printf, fputc, putchar,
101912         puts, remove, rename, renameat, snprintf, sprintf, asprintf, vasprintf,
101913         vdprintf, vfprintf, vprintf, vsnprintf, vsprintf): In C++, define a
101914         namespaced alias symbol.
101915         * modules/stdio (Depends-on): Add c++defs.
101916         (Makefile.am): Update stdio.h rule.
101918         spawn: Avoid #define replacements in C++ mode.
101919         * lib/spawn.in.h: Include c++defs.h.
101920         (posix_spawn, posix_spawnp, posix_spawnattr_init,
101921         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
101922         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
101923         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
101924         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
101925         posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy,
101926         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
101927         posix_spawnattr_setschedparam, posix_spawn_file_actions_init,
101928         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addopen,
101929         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
101930         In C++, define a namespaced alias symbol.
101931         * modules/spawn (Depends-on): Add c++defs.
101932         (Makefile.am): Update spawn.h rule.
101934         signal: Avoid #define replacements in C++ mode.
101935         * lib/signal.in.h: Include c++defs.h.
101936         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset,
101937         sigpending, sigprocmask, signal, raise, sigaction): In C++, define a
101938         namespaced alias symbol.
101939         * modules/signal (Depends-on): Add c++defs.
101940         (Makefile.am): Update signal.h rule.
101942         search: Avoid #define replacements in C++ mode.
101943         * lib/search.in.h: Include c++defs.h.
101944         (_gl_search_compar_fn, _gl_search_action_fn): New types.
101945         (tsearch, tfind, tdelete, twalk): In C++, define a namespaced alias
101946         symbol.
101947         * modules/search (Depends-on): Add c++defs.
101948         (Makefile.am): Update search.h rule.
101950         math: Avoid #define replacements in C++ mode.
101951         * lib/math.in.h: Include c++defs.h.
101952         (frexp, acosl, asinl, atanl, ceilf, ceill, cosl, expl, floorf, floorl,
101953         frexpl, ldexpl, logl, roundf, round, roundl, sinl, sqrtl, tanl, truncf,
101954         trunc, truncl): In C++, define a namespaced alias symbol.
101955         * modules/math (Depends-on): Add c++defs.
101956         (Makefile.am): Update math.h rule.
101958         locale: Avoid #define replacements in C++ mode.
101959         * lib/locale.in.h: Include c++defs.h.
101960         (duplocale): In C++, define a namespaced alias symbol.
101961         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize HAVE_DUPLOCALE.
101962         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Set HAVE_DUPLOCALE.
101963         * modules/locale (Depends-on): Add c++defs.
101964         (Makefile.am): Update locale.h rule. Substitute HAVE_DUPLOCALE.
101966         langinfo: Avoid #define replacements in C++ mode.
101967         * lib/langinfo.in.h: Include c++defs.h.
101968         (nl_langinfo): In C++, define a namespaced alias symbol.
101969         * modules/langinfo (Depends-on): Add c++defs.
101970         (Makefile.am): Update langinfo.h rule.
101972         iconv-h: Avoid #define replacements in C++ mode.
101973         * lib/iconv.in.h: Include c++defs.h, warn-on-use.h.
101974         (iconv_open, iconv, iconv_close): In C++, define a namespaced alias
101975         symbol.
101976         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H
101977         whenever iconv is present.
101978         * modules/iconv-h (Depends-on): Add c++defs, warn-on-use.
101979         (Makefile.am): Update iconv.h rule.
101981         glob: Avoid #define replacements in C++ mode.
101982         * lib/glob.in.h: Include c++defs.h, warn-on-use.h.
101983         (_gl_glob_errfunc_fn): New type.
101984         (glob, globfree, glob_pattern_p): In C++, define a namespaced alias
101985         symbol.
101986         * modules/glob (Depends-on): Add c++defs, warn-on-use.
101987         (Makefile.am): Update glob.h rule.
101989         fcntl-h: Avoid #define replacements in C++ mode.
101990         * lib/fcntl.in.h: Include c++defs.h.
101991         (fcntl, open, openat): In C++, define a namespaced alias symbol.
101992         * modules/fcntl-h (Depends-on): Add c++defs.
101993         (Makefile.am): Update fcntl.h rule.
101995         dirent: Avoid #define replacements in C++ mode.
101996         * lib/dirent.in.h: Include c++defs.h.
101997         (closedir, fdopendir, opendir, scandir, alphasort): In C++, define a
101998         namespaced alias symbol.
101999         (dirfd): Update declaration.
102000         * modules/dirent (Depends-on): Add c++defs.
102001         (Makefile.am): Update dirent.h rule.
102003         ctype: Make it usable in C++ code.
102004         * lib/ctype.in.h: Include c++defs.h.
102005         (isblank): Declare as extern "C".
102006         * modules/ctype (Depends-on): Add c++defs.
102007         (Makefile.am): Update ctype.h rule.
102009         New module 'c++defs'.
102010         * modules/c++defs: New file.
102011         * build-aux/c++defs.h: New file.
102012         Reported by John W. Eaton <jwe@gnu.org>.
102014 2010-03-07  Bruno Haible  <bruno@clisp.org>
102016         logb: Provide missing declaration for Cygwin.
102017         * lib/math.in.h (logb): New declaration.
102018         * m4/logb.m4: New file.
102019         * modules/logb (Files): Add m4/logb.m4.
102020         (Depends-on): Add math.
102021         (configure.ac): Invoke gl_FUNC_LOGB, gl_MATH_MODULE_INDICATOR.
102022         * m4/math_h.m4 (gl_MATH_H): Check also for logb declaration.
102023         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGB, HAVE_DECL_LOGB.
102024         * modules/math (Makefile.am): Substitute GNULIB_LOGB, HAVE_DECL_LOGB.
102025         * doc/posix-functions/logb.texi: Mention the Cygwin bug.
102027 2010-03-07  Bruno Haible  <bruno@clisp.org>
102029         Fix test-cond link error.
102030         * tests/test-cond.c: Include <stdio.h>.
102032 2010-03-07  Bruno Haible  <bruno@clisp.org>
102034         Fix test-dirent-safer link error.
102035         * modules/dirent-safer-tests (Makefile.am): Define
102036         test_dirent_safer_LDADD.
102038 2010-03-07  Bruno Haible  <bruno@clisp.org>
102040         * gnulib-tool (func_create_testdir): Don't use 'lib-ignore' module
102041         among default module list.
102043 2010-03-07  Bruno Haible  <bruno@clisp.org>
102045         Fix link error on platforms with GNU libiconv.
102046         * modules/unistr/u8-strcoll-tests (Makefile): Define
102047         test_u8_strcoll_LDADD.
102048         * modules/unistr/u16-strcoll-tests (Makefile): Define
102049         test_u16_strcoll_LDADD.
102050         * modules/unistr/u32-strcoll-tests (Makefile): Define
102051         test_u32_strcoll_LDADD.
102053 2010-03-07  Bruno Haible  <bruno@clisp.org>
102055         Use POSIX declarations for socket functions.
102056         * lib/sys_socket.in.h (rpl_connect, rpl_accept, rpl_bind,
102057         rpl_getpeername, rpl_getsockname, rpl_recv, rpl_send, rpl_recvfrom,
102058         rpl_sendto): Change declaration to match POSIX.
102059         * lib/connect.c (rpl_connect): Likewise.
102060         * lib/accept.c (rpl_accept): Likewise.
102061         * lib/bind.c (rpl_bind): Likewise.
102062         * lib/getpeername.c (rpl_getpeername): Likewise.
102063         * lib/getsockname.c (rpl_getsockname): Likewise.
102064         * lib/recv.c (rpl_recv): Likewise.
102065         * lib/send.c (rpl_send): Likewise.
102066         * lib/recvfrom.c (rpl_recvfrom): Likewise.
102067         * lib/sendto.c (rpl_sendto): Likewise.
102069 2010-03-06  Bruno Haible  <bruno@clisp.org>
102071         Clarify access, euidaccess, faccessat.
102072         * doc/posix-functions/faccessat.texi: Mention security problem under
102073         "Other problems", not "Portability problems".
102074         * doc/posix-functions/access.texi: Likewise. Mention a related security
102075         problem.
102076         * doc/glibc-functions/euidaccess.texi: Mention security problems.
102077         * lib/euidaccess.c: Add comments about platforms.
102078         * lib/unistd.in.h (access, euidaccess): Add warnings.
102080 2010-03-07  Bruno Haible  <bruno@clisp.org>
102082         Ensure posix_spawnattr_{get,set}sched{policy,param} are defined.
102083         * lib/spawn.in.h (POSIX_SPAWN_SETSCHEDPARAM): Define fallback.
102084         (POSIX_SPAWN_SETSCHEDULER): Likewise.
102085         (POSIX_SPAWN_USEVFORK): Define in a way that works when
102086         POSIX_SPAWN_SETSCHEDPARAM and POSIX_SPAWN_SETSCHEDULER are zero.
102087         (posix_spawnattr_getschedpolicy, posix_spawnattr_setschedpolicy): Also
102088         declare when POSIX_SPAWN_SETSCHEDULER is zero.
102089         (posix_spawnattr_getschedparam, posix_spawnattr_setschedparam): Also
102090         declare when POSIX_SPAWN_SETSCHEDPARAM is zero.
102091         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test whether
102092         POSIX_SPAWN_SETSCHEDULER or POSIX_SPAWN_SETSCHEDPARAM are zero.
102093         * modules/posix_spawnattr_getschedparam (configure.ac): Enable the
102094         replacement also when POSIX_SPAWN_SETSCHEDPARAM is zero.
102095         * modules/posix_spawnattr_setschedparam (configure.ac): Likewise.
102096         * modules/posix_spawnattr_getschedpolicy (configure.ac): Enable the
102097         replacement also when POSIX_SPAWN_SETSCHEDULER is zero.
102098         * modules/posix_spawnattr_setschedpolicy (configure.ac): Likewise.
102099         * lib/spawnattr_getschedparam.c (posix_spawnattr_getschedparam): Do
102100         nothing if POSIX_SPAWN_SETSCHEDPARAM is zero.
102101         * lib/spawnattr_setschedparam.c (posix_spawnattr_setschedparam):
102102         Likewise.
102103         * lib/spawnattr_getschedpolicy.c (posix_spawnattr_getschedpolicy): Do
102104         nothing if POSIX_SPAWN_SETSCHEDULER is zero.
102105         * lib/spawnattr_setschedpolicy.c (posix_spawnattr_setschedpolicy):
102106         Likewise.
102107         * tests/test-spawn.c (main): Make it work when
102108         POSIX_SPAWN_SETSCHEDPARAM and POSIX_SPAWN_SETSCHEDULER are zero.
102110 2010-03-07  Bruno Haible  <bruno@clisp.org>
102112         Fix incorrect Makefile.am generation in German locale.
102113         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
102114         Execute sed command with character range in C locale.
102116 2010-03-06  Bruno Haible  <bruno@clisp.org>
102118         Tests for module 'iconv-h'.
102119         * modules/iconv-h-tests: New file.
102120         * tests/test-iconv-h.c: New file.
102122         New module 'iconv-h'.
102123         * modules/iconv-h: New file.
102124         * modules/iconv_open (Files): Remove lib/iconv.in.h, m4/iconv_h.m4.
102125         (Depends-on): Add iconv-h. Remove include_next, arg-nonnull.
102126         (configure.ac): Remove gl_ICONV_H.
102127         (Makefile.am): Remove rule for iconv.h.
102129 2010-03-06  Bruno Haible  <bruno@clisp.org>
102131         More consistent naming of *.m4 files.
102132         * m4/wctype_h.m4: Renamed from m4/wctype.m4.
102133         * modules/wctype (Files): Update.
102135         More consistent naming of *.m4 files.
102136         * m4/wchar_h.m4: Renamed from m4/wchar.m4.
102137         * modules/wchar (Files): Update.
102139 2010-03-06  Jim Meyering  <meyering@redhat.com>
102141         euidaccess: relax license to LGPLv2+
102142         * modules/euidaccess (License): Relax to LGPLv2+.
102144 2010-03-06  Bruno Haible  <bruno@clisp.org>
102146         Prefer lib_SOURCES over unconditional AC_LIBOBJ.
102147         * modules/exitfail (configure.ac): Remove AC_LIBOBJ invocation.
102148         (Makefile.am): Augment lib_SOURCES instead.
102150 2010-03-04  Jim Meyering  <meyering@redhat.com>
102152         utime: remove obsolete module
102153         This module, like autoconf's AC_FUNC_UTIME_NULL macro, has been
102154         unnecessary for years, and has been marked as obsolete for 10 months.
102155         * modules/utime: Remove file.
102156         * lib/utime.c: Remove file.
102157         * m4/utime.m4: Remove file.
102158         * m4/utimes-null.m4: Remove file.
102159         * doc/posix-functions/utime.texi (utime): Remove reference to
102160         the module.  Move the sole "fixed by gnulib" item into the
102161         "problems not fixed by Gnulib" list.
102162         * MODULES.html.sh (func_all_modules): Remove reference to "utime".
102164 2010-03-05  Simon Josefsson  <simon@josefsson.org>
102166         * modules/exit (License): Relax license to LGPLv2+.
102167         (Status): Mark as obsolete.
102168         * NEWS: Mention deprecated 'exit' module.
102169         * doc/posix-functions/exit.texi: Recommend 'stdlib' module instead
102170         of now obsolete 'exit'.
102172 2010-03-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
102174         fts-lgpl: remove unused module
102175         * modules/fts-lgpl: Remove.
102176         * MODULES.html.sh (func_all_modules): Adjust.
102177         * check-module (find_included_lib_files): Adjust.
102178         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove.
102180 2010-03-02  Ben Walton  <bwalton@artsci.utoronto.ca>  (tiny change)
102182         copy-acl: enhance Solaris ACL error handling
102183         * lib/copy-acl.c (qcopy_acl): Also ignore EOPNOTSUPP.
102184         * lib/set-mode-acl.c (qset_acl): Likewise.
102186 2010-03-02  Bruno Haible  <bruno@clisp.org>
102188         spawn: Don't override the system defined values on FreeBSD 8.
102189         * lib/spawn.in.h (POSIX_SPAWN_RESETIDS, POSIX_SPAWN_SETPGROUP,
102190         POSIX_SPAWN_SETSIGDEF, POSIX_SPAWN_SETSIGMASK,
102191         POSIX_SPAWN_SETSCHEDPARAM, POSIX_SPAWN_SETSCHEDULER): Don't redefine
102192         if HAVE_POSIX_SPAWN is 1.
102193         Reported by Johan van Selst <johans@stack.nl> via Eric Blake.
102195 2010-03-01  Bruno Haible  <bruno@clisp.org>
102197         * doc/gnulib-tool.texi (Initial import): Clarify the requirements
102198         regarding Automake.
102200 2010-02-25  Bruno Haible  <bruno@clisp.org>
102202         Fix breakage of gnulib-tool with ksh, introduced on 2010-02-21.
102203         * gnulib-tool: Define 'echo' as a function only before the ksh alias
102204         setting, not afterwards.
102205         Reported by Ben Walton <bwalton@artsci.utoronto.ca>.
102207 2010-02-24  Eric Blake  <eblake@redhat.com>
102209         bootstrap, git-version-gen: use timestamp
102210         * build-aux/git-version-gen (scriptversion): Force UTC.
102211         * build-aux/bootstrap (scriptversion): New variable.
102213         bootstrap: allow older git
102214         * build-aux/bootstrap (GNULIB_SRCDIR): Add fallback if git is
102215         older than 1.6.4.  Requested by the libvirt project.
102217 2010-02-23  Eric Blake  <eblake@redhat.com>
102219         warn-on-use: work with old autoconf
102220         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Accomodate older
102221         AS_VAR semantics of autoconf 2.60.
102222         Reported by Bruno Haible.
102224         bootstrap: improve some comments
102225         * build-aux/bootstrap: Drop unneeded emacs hint.  Add some
102226         clarification comments.
102228         gettimeofday: provide correct function
102229         * lib/gettimeofday.c (gettimeofday): Provide rpl_gettimeofday only
102230         when replacement is declared, otherwise provide gettimeofday.
102231         Reported by Michael Goffioul.
102233 2010-02-23  Jim Meyering  <meyering@redhat.com>
102235         lib-ignore: relax license to "unlimited", not LGPLv2+
102236         * modules/lib-ignore (License): Relax to "unlimited".
102238 2010-02-23  Jim Meyering  <meyering@redhat.com>
102240         lib-ignore: relax license to LGPLv2+
102241         * modules/lib-ignore (License): Relax to LGPLv2+.
102243 2010-02-22  Eric Blake  <eblake@redhat.com>
102245         lseek: avoid bash 3.2 broken pipe bug
102246         * m4/lseek.m4 (gl_FUNC_LSEEK): Drain pipe, to avoid spurious
102247         warning from bash 3.2.
102248         Reported by Ben Pfaff, with analysis from Bruno Haible.
102250         bootstrap: support non-FSF copyright holder
102251         * build-aux/bootstrap (COPYRIGHT_HOLDER, with_gettext): Allow
102252         bootstrap.conf override of COPYRIGHT_HOLDER.
102253         (MSGID_BUGS_ADDRESS): Allow URL rather than email.
102255         bootstrap: interoperate with gettext 0.14.1
102256         * build-aux/bootstrap (slurp): Fix typo when using older gettext.
102258         bootstrap: allow for alternate submodule location
102259         * build-aux/bootstrap (gnulib_path): New variable; use instead of
102260         hardcoding submodule location.
102261         (gnulib_mk): Allow direct use of Makefile.am.
102263         bootstrap: use GNULIB_SRCDIR to reduce disk usage
102264         * build-aux/bootstrap (GNULIB_SRCDIR): If set, use as a reference,
102265         rather than reconfiguring where the submodule points.
102267         gettimeofday: restore support for platforms that lack function
102268         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Also compile
102269         replacement if function is missing.
102270         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): New witness.
102271         * modules/sys_time (Makefile.am): Substitute it.
102272         * lib/sys_time.in.h (gettimeofday): Check it.
102273         Reported by Michael Goffioul.
102275 2010-02-21  Bruno Haible  <bruno@clisp.org>
102277         * lib/stdio.in.h (obstack_printf): Fix typo.
102279 2010-02-21  Jose E. Marchesi  <jemarch@gnu.org>
102281         vc-list-files: use bzr ls's -R option
102282         * build-aux/vc-list-files: Invoke bazaar to generate a recursive
102283         list of versioned files based on 'dir' (usage of -R in 'bzr ls').
102285 2010-02-21  Jim Meyering  <meyering@redhat.com>
102287         init.sh: fix EXEEXT shims to work also for names like test-prog
102288         * tests/init.sh: Re-exec a better shell, when needed.
102289         If the current shell lacks support for posix $(...), an init.sh-using
102290         test will now try to find a shell that supports that.  If EXEEXT is
102291         nonempty, we also require support for hyphen-in-alias-name and shell
102292         substitutions like ${var#glob}.  Failure to find such a shell results
102293         in a skipped test.
102295 2010-02-21  Bruno Haible  <bruno@clisp.org>
102297         Really work around "broken pipe" error message from bash 3.2.
102298         * gnulib-tool (func_reset_sigpipe): Remove function.
102299         (echo): In bash 3.2, define to a function that uses printf.
102300         Analyzed by Ralf Wildenhues, Chet Ramey, Ben Pfaff.
102302 2010-02-20  Bruno Haible  <bruno@clisp.org>
102304         Restore support for automake 1.9.6 with autoconf 2.61.
102305         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): Ensure MKDIR_P is AC_SUBSTed.
102306         Reported by James Youngman <jay@gnu.org>.
102308 2010-02-20  Bruno Haible  <bruno@clisp.org>
102310         Improve *printf warning condition.
102311         * lib/stdio.in.h (fprintf, printf, vfprintf, vprintf): Emit warning
102312         also if GNULIB_POSIXCHECK is defined, the *-posix module is not used,
102313         and the function is overridden due to SIGPIPE emulation.
102315 2010-02-20  Bruno Haible  <bruno@clisp.org>
102317         * lib/stdio.in.h: Tweak comments.
102319 2010-02-19  Bruno Haible  <bruno@clisp.org>
102321         Make it easier to find modules. New gnulib-tool option '--find'.
102322         * gnulib-tool: New option --find.
102323         (func_usage): Document it.
102324         (func_sanitize_modulelist): New function, extracted from
102325         func_all_modules.
102326         (func_all_modules): Invoke it.
102327         * doc/gnulib-tool.texi (Which modules?): New node.
102329 2010-02-18  Markus Duft  <mduft@gentoo.org>  (tiny change)
102331         * lib/sys_select.in.h: Provide select replacement even if
102332         sys/select.h exists on a system, for Interix.
102334 2010-02-18  Jim Meyering  <meyering@redhat.com>
102336         init.sh: don't use $(...) just yet
102337         * tests/init.sh (create_exe_shim_functions_): Use `...`, not $(...),
102338         to accommodate e.g., Solaris' /bin/sh.
102340 2010-02-17  Bruno Haible  <bruno@clisp.org>
102342         * doc/posix-headers/netdb.texi: Mention NetBSD 5.0 problem.
102343         Reported by Ludovic Courtès <ludo@gnu.org>.
102345 2010-02-16  Simon Josefsson  <simon@josefsson.org>
102347         * modules/userspec-tests (test_userspec_LDADD): Add variable, for
102348         linking with -lintl.
102350 2010-02-17  Simon Josefsson  <simon@josefsson.org>
102352         * lib/netdb.in.h (AI_V4MAPPED, AI_ALL, AI_ADDRCONFIG): Define to 0
102353         if not provided by the system's netdb.h.  Reported by
102354         ludo@gnu.org (Ludovic Courtès).
102356 2010-02-15  Jim Meyering  <meyering@redhat.com>
102358         init.sh: improve portability and efficiency
102359         * tests/init.sh (find_exe_basenames_): Remove unnecessary use of
102360         "dummy" in a for loop.
102361         Use '!', not '^' to select the complement of a character set used
102362         in a "case" statement.
102363         Use shell variable manipulation, a la ${...%.exe}, rather than sed.
102364         Suggestions from Eric Blake.
102366         init.sh: automatically accommodate programs with the .exe suffix
102367         Automatically arrange for an invocation of "prog" to execute the
102368         program named "prog$EXEEXT" (usually prog.exe).  Thus, all invocations
102369         may use the simpler "prog", yet still work when built on a system
102370         that requires specifying the added suffix.
102371         Do this by constructing a function named "prog" that invokes
102372         "prog.exe" for each .exe file in selected directories.
102373         * tests/init.sh (find_exe_basenames_): New function.
102374         (create_exe_shim_functions_): New function.
102375         (path_prepend_): Use it.
102377         maint.mk: mark syntax-check sc_*.m rules as .PHONY
102378         * top/maint.mk ($(syntax-check-rules)): Add .PHONY, so that
102379         "make -t syntax-check" doesn't create a ton of sc_*.m files.
102381 2010-02-14  Jim Meyering  <meyering@redhat.com>
102383         maint.mk: prohibit inclusion of "hash-pjw.h" without_use
102384         * top/maint.mk (sc_prohibit_hash_without_use): Re-add "@".
102385         (sc_prohibit_hash_pjw_without_use): New rule.
102387         maint.mk: allow the default upload destination dir to be overridden
102388         * top/maint.mk (upload_dest_dir_): Define with a default that
102389         preserves the status quo.
102390         (emit_upload_commands): Use it, rather than hard-coding $(PACKAGE).
102391         Reported by Peter Simons.
102393         maint.mk: prohibit inclusion of "hash.h" without_use
102394         * top/maint.mk (sc_prohibit_hash_without_use): New rule.
102396 2010-02-10  Jim Meyering  <meyering@redhat.com>
102398         maint.mk: prohibit inclusion of "ignore-value.h" without_use
102399         * top/maint.mk (sc_prohibit_ignore_value_without_use): New rule.
102401 2010-02-09  Eric Blake  <ebb9@byu.net>
102402         and Bruno Haible  <bruno@clisp.org>
102404         obstack-printf-posix: ensure declaration
102405         * m4/obstack-printf.m4 (gl_DECL_OBSTACK_PRINTF): New macro,
102406         extracted from gl_FUNC_OBSTACK_PRINTF.
102407         (gl_FUNC_OBSTACK_PRINTF): Invoke it.
102408         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX):
102409         Likewise.
102410         * lib/stdio.in.h (obstack_printf, obstack_vprintf): Declare also
102411         if GNULIB_OBSTACK_PRINTF_POSIX is 1 and GNULIB_OBSTACK_PRINTF is
102412         0.
102414 2010-02-08  Bruno Haible  <bruno@clisp.org>
102416         gnulib-tool: Fix typo in 2010-02-07 commit.
102417         * gnulib-tool (func_get_dependencies): Fix typo in last commit.
102418         Reported by Eric Blake.
102420 2010-02-07  Bruno Haible  <bruno@clisp.org>
102422         gnulib-tool: Fix up caching patches.
102423         * gnulib-tool: New options --cache-modules, --no-cache-modules. Remove
102424         option --no-cache. Use associative arrays when supported by the shell.
102425         (sed_comments): New variable.
102426         (modcache): Renamed from do_cache.
102427         (sed_extract_field_header): Renamed from sed_extract_cache_prog. Don't
102428         abbreviate unnecessarily.
102429         (have_associative): New variable.
102430         (func_cache_var): Define correctly for bash 1.x. Define in an optimized
102431         way also for ksh and zsh.
102432         (func_init_sed_convert_to_cache_statements): New function, extracted
102433         from func_cache_lookup_module. Add support for associative arrays.
102434         Don't set the c_MODULE_cached variable here. Ignore all lines before
102435         the first field header. Remove only the final newline, not all trailing
102436         newlines. Support empty fields correctly. Limit the use of 'eval' to
102437         assignments.
102438         (func_get_description, func_get_status, func_get_notice,
102439         func_get_applicability, func_get_filelist, func_get_dependencies,
102440         func_get_autoconf_early_snippet, func_get_autoconf_snippet,
102441         func_get_automake_snippet, func_get_include_directive,
102442         func_get_link_directive, func_get_license, func_get_maintainer):
102443         Update documentation. List the unoptimized code first. Add support for
102444         associative arrays. Limit the use of 'eval' to assignments.
102445         (func_get_applicability): Undo stylistic pessimisations.
102446         (func_get_automake_snippet, func_get_include_directive): Reduce code
102447         duplication.
102448         (func_modules_transitive_closure, func_modules_add_dummy,
102449         func_modules_notice, func_modules_to_filelist, func_add_file,
102450         func_update_file, func_emit_lib_Makefile_am, func_emit_po_Makevars,
102451         func_emit_po_POTFILES_in, func_emit_tests_Makefile_am, func_import,
102452         func_create_testdir, func_create_megatestdir): Update documentation.
102454 2010-01-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
102456         * gnulib-tool (func_cache_lookup_module): Store the module name
102457         belonging to the cache variable; error out if two different
102458         module names map to the same cache variable name.
102460 2010-01-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
102462         gnulib-tool: Make caching optional.
102463         * gnulib-tool: Accept option --no-cache, turning off $do_cache.
102464         Update matching short versions of --no-changelog.
102465         (func_usage): Update.
102466         (sed_extract_cache_prog): Renamed from ...
102467         (sed_extract_prog): ... this; revert to old extraction script.
102468         (func_get_description, func_get_status)
102469         (func_get_notice, func_get_applicability, func_get_filelist)
102470         (func_get_dependencies, func_get_autoconf_early_snippet)
102471         (func_get_autoconf_snippet, func_get_automake_snippet)
102472         (func_get_include_directive, func_get_link_directive)
102473         (func_get_license, func_get_maintainer): If $do_cache is false,
102474         use old, non-caching extraction scripts.
102475         Suggestion by Bruno Haible.
102477 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
102479         gnulib-tool: cache module metainformation.
102480         * gnulib-tool (sed_extract_prog): Match newline before each
102481         header, and rewrite header to a shell variable suffix.
102482         (func_cache_var, func_cache_lookup_module): New functions,
102483         to turn a module name into a cache variable prefix, and to
102484         look up and cache module metainformation.
102485         (func_get_description, func_get_status)
102486         (func_get_notice, func_get_applicability, func_get_filelist)
102487         (func_get_dependencies, func_get_autoconf_early_snippet)
102488         (func_get_autoconf_snippet, func_get_automake_snippet)
102489         (func_get_include_directive, func_get_link_directive)
102490         (func_get_license, func_get_maintainer): Use
102491         func_cache_lookup_module.
102493 2010-02-07  Bruno Haible  <bruno@clisp.org>
102495         fnctl: Fix missing dependency.
102496         * modules/fcntl (Depends-on): Add getdtablesize.
102497         Reported by John W. Eaton <jwe@gnu.org>.
102499 2010-02-05  Sergey Poznyakoff  <gray@gnu.org.ua>
102501         Argp: fix recognition of short alias options.
102503         * lib/argp-parse.c (convert_options): Fix improper use of
102504         `|' between character values.
102505         * tests/test-argp.c (group1_option): New alias option
102506         --read (-r).
102507         (group1_parser): Special handling for 'r'.
102508         (test15): New test case.
102509         (test_fun): Add test15.
102510         * tests/test-argp-2.sh: Update expected --help and --usage
102511         outputs.
102513 2010-02-05  Sergey Poznyakoff  <gray@gnu.org.ua>
102515         * tests/test-argp.c: Fix indentation.
102517 2010-02-04  Eric Blake  <ebb9@byu.net>
102519         gettimeofday: expose type of second argument
102520         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Do better detection
102521         of glibc extension signature, and define GETTIMEOFDAY_TIMEZONE.
102522         * tests/test-gettimeofday.c: Use it to silence warning.
102523         * doc/posix-functions/gettimeofday.texi (gettimeofday): Document
102524         the issue.
102526 2010-02-03  Jim Meyering  <meyering@redhat.com>
102528         regcomp.c: avoid the sole warning from gcc's -Wtype-limits
102529         * lib/regcomp.c (TYPE_SIGNED): Define.
102530         (parse_dup_op): Use it to avoid the sole warning from -Wtype-limits.
102532         regcomp.c: avoid a new -Wshadow warning
102533         * lib/regcomp.c (create_initial_state): Do not shadow local "err".
102535 2010-02-01  Jim Meyering  <meyering@redhat.com>
102537         removing useless parentheses in cpp #define directives
102538         For motivation, see commit c0221df4, "define STREQ(a,b)
102539         consistently, removing useless parentheses"
102540         * lib/memcmp.c (CMP_LT_OR_GT): Remove useless parentheses.
102541         * lib/mountlist.c (MNT_IGNORE): Likewise.
102542         * lib/trim.h (trim, trim_trailing, trim_leading): Likewise.
102544 2010-02-01  Eric Blake  <ebb9@byu.net>
102546         sys_time: use link-warning
102547         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Split defaults...
102548         (gl_HEADER_SYS_TIME_H_DEFAULTS): ...into new macro.
102549         (gl_SYS_TIME_MODULE_INDICATOR): New macro.
102550         * modules/sys_time (Depends-on): Add warn-on-use.
102551         (Makefile.am): Always build replacement.
102552         (configure.ac): Update substitutions.
102553         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY)
102554         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Include defaults, and no longer
102555         bother with SYS_TIME_H.
102556         * modules/gettimeofday (configure.ac): Declare indicator.
102557         * lib/sys_time.in.h (gettimeofday): Warn if gnulib module is not
102558         in use.
102560         closein-tests: silence compiler warning
102561         * tests/test-closein.c (main): Ignore fread result.
102562         * modules/closein-tests (Depends-on): Add ignore-value.
102564         tests: silence warning about system return
102565         * tests/test-areadlink-with-size.c (main): Ignore system result.
102566         * tests/test-areadlink.c (main): Likewise.
102567         * tests/test-areadlinkat-with-size.c (main): Likewise.
102568         * tests/test-areadlinkat.c (main): Likewise.
102569         * tests/test-canonicalize-lgpl.c (main): Likewise.
102570         * tests/test-canonicalize.c (main): Likewise.
102571         * tests/test-chown.c (main): Likewise.
102572         * tests/test-fchownat.c (main): Likewise.
102573         * tests/test-fdutimensat.c (main): Likewise.
102574         * tests/test-fstatat.c (main): Likewise.
102575         * tests/test-futimens.c (main): Likewise.
102576         * tests/test-lchown.c (main): Likewise.
102577         * tests/test-link.c (main): Likewise.
102578         * tests/test-linkat.c (main): Likewise.
102579         * tests/test-lstat.c (main): Likewise.
102580         * tests/test-mkdir.c (main): Likewise.
102581         * tests/test-mkdirat.c (main): Likewise.
102582         * tests/test-mkfifo.c (main): Likewise.
102583         * tests/test-mkfifoat.c (main): Likewise.
102584         * tests/test-mknod.c (main): Likewise.
102585         * tests/test-readlink.c (main): Likewise.
102586         * tests/test-remove.c (main): Likewise.
102587         * tests/test-rename.c (main): Likewise.
102588         * tests/test-renameat.c (main): Likewise.
102589         * tests/test-rmdir.c (main): Likewise.
102590         * tests/test-symlink.c (main): Likewise.
102591         * tests/test-symlinkat.c (main): Likewise.
102592         * tests/test-unlink.c (main): Likewise.
102593         * tests/test-unlinkat.c (main): Likewise.
102594         * tests/test-utimens.c (main): Likewise.
102595         * tests/test-utimensat.c (main): Likewise.
102596         * modules/areadlink-tests (Depends-on): Add ignore-value.
102597         * modules/areadlink-with-size-tests (Depends-on): Likewise.
102598         * modules/areadlinkat-tests (Depends-on): Likewise.
102599         * modules/areadlinkat-with-size-tests (Depends-on): Likewise.
102600         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
102601         * modules/canonicalize-tests (Depends-on): Likewise.
102602         * modules/chown-tests (Depends-on): Likewise.
102603         * modules/fdutimensat-tests (Depends-on): Likewise.
102604         * modules/futimens-tests (Depends-on): Likewise.
102605         * modules/lchown-tests (Depends-on): Likewise.
102606         * modules/link-tests (Depends-on): Likewise.
102607         * modules/linkat-tests (Depends-on): Likewise.
102608         * modules/lstat-tests (Depends-on): Likewise.
102609         * modules/mkdir-tests (Depends-on): Likewise.
102610         * modules/mkfifo-tests (Depends-on): Likewise.
102611         * modules/mkfifoat-tests (Depends-on): Likewise.
102612         * modules/mknod-tests (Depends-on): Likewise.
102613         * modules/openat-tests (Depends-on): Likewise.
102614         * modules/readlink-tests (Depends-on): Likewise.
102615         * modules/remove-tests (Depends-on): Likewise.
102616         * modules/rename-tests (Depends-on): Likewise.
102617         * modules/renameat-tests (Depends-on): Likewise.
102618         * modules/rmdir-tests (Depends-on): Likewise.
102619         * modules/symlink-tests (Depends-on): Likewise.
102620         * modules/symlinkat-tests (Depends-on): Likewise.
102621         * modules/unlink-tests (Depends-on): Likewise.
102622         * modules/utimens-tests (Depends-on): Likewise.
102623         * modules/utimensat-tests (Depends-on): Likewise.
102625 2010-01-31  Bruno Haible  <bruno@clisp.org>
102627         Perform the same test for many <math.h> functions.
102628         * m4/mathfunc.m4 (gl_COMMON_DOUBLE_MATHFUNC,
102629         gl_COMMON_DOUBLE_MATHFUNC_TEST): New macros.
102630         * m4/sqrt.m4 (gl_FUNC_SQRT): Invoke gl_COMMON_DOUBLE_MATHFUNC instead
102631         of gl_MATHFUNC.
102632         * modules/acos (configure.ac): Likewise.
102633         * modules/asin (configure.ac): Likewise.
102634         * modules/atan (configure.ac): Likewise.
102635         * modules/atan2 (configure.ac): Likewise.
102636         * modules/cbrt (configure.ac): Likewise.
102637         * modules/copysign (configure.ac): Likewise.
102638         * modules/cos (configure.ac): Likewise.
102639         * modules/cosh (configure.ac): Likewise.
102640         * modules/erf (configure.ac): Likewise.
102641         * modules/erfc (configure.ac): Likewise.
102642         * modules/exp (configure.ac): Likewise.
102643         * modules/fmod (configure.ac): Likewise.
102644         * modules/hypot (configure.ac): Likewise.
102645         * modules/j0 (configure.ac): Likewise.
102646         * modules/j1 (configure.ac): Likewise.
102647         * modules/jn (configure.ac): Likewise.
102648         * modules/lgamma (configure.ac): Likewise.
102649         * modules/log (configure.ac): Likewise.
102650         * modules/log10 (configure.ac): Likewise.
102651         * modules/log1p (configure.ac): Likewise.
102652         * modules/pow (configure.ac): Likewise.
102653         * modules/remainder (configure.ac): Likewise.
102654         * modules/sin (configure.ac): Likewise.
102655         * modules/sinh (configure.ac): Likewise.
102656         * modules/tan (configure.ac): Likewise.
102657         * modules/tanh (configure.ac): Likewise.
102658         * modules/y0 (configure.ac): Likewise.
102659         * modules/y1 (configure.ac): Likewise.
102660         * modules/yn (configure.ac): Likewise.
102661         Suggested by Paolo Bonzini.
102663 2010-01-31  Bruno Haible  <bruno@clisp.org>
102665         * m4/getline.m4 (gl_FUNC_GETLINE): Add comment about REPLACE_GETLINE.
102667 2010-01-31  Bruno Haible  <bruno@clisp.org>
102669         Work around getdelim() bug on FreeBSD 8.0.
102670         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Test whether getdelim supports an
102671         initially NULL line. Set REPLACE_GETDELIM if getdelim exists but does
102672         not work.
102673         * lib/stdio.in.h (getdelim): Define as an alias if REPLACE_GETDELIM
102674         is 1.
102675         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize REPLACE_GETDELIM.
102676         * modules/stdio (Makefile.am): Also substitute REPLACE_GETDELIM.
102677         * tests/test-getdelim.c (main): Also test result for a NULL buffer and
102678         a non-zero size.
102679         * doc/posix-functions/getdelim.texi: Mention the FreeBSD bug.
102681 2010-01-31  Bruno Haible  <bruno@clisp.org>
102683         Work around getline() bug on FreeBSD 8.0.
102684         * m4/getline.m4 (gl_FUNC_GETLINE): Also test result for a NULL buffer
102685         and a non-zero size.
102686         * tests/test-getline.c (main): Likewise.
102687         * doc/posix-functions/getline.texi: Mention the FreeBSD bug.
102688         Reported by Dennis <noordsij@cs.helsinki.fi> via Eric Blake.
102690 2010-01-28  Eric Blake  <ebb9@byu.net>
102692         regex: fix build failure
102693         * lib/regex_internal.h (__GNUC_PREREQ): Define for non-glibc
102694         platforms.
102696 2010-01-28  Jim Meyering  <meyering@redhat.com>
102698         regex: do not ignore memory allocation failure
102699         * lib/regex_internal.c (create_cd_newstate): Detect
102700         re_node_set_init_copy failure.   Extracted from glibc commit
102701         2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
102703         regex: sync more white-space changes from libc
102704         * lib/regex_internal.c: White-space only changes.
102705         * lib/regexec.c: Likewise.
102707         regex: add many uses of __attribute_warn_unused_result__
102708         * lib/regex_internal.c: Use __attribute_warn_unused_result__.
102709         * lib/regexec.c: Likewise.
102710         Extracted from a messy glibc commit.
102712         regcomp.c: spelling and merge-artifact from glibc
102713         * lib/regcomp.c: Merge remainder of glibc's
102714         2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
102716         regcomp.c: sync white-space changes from glibc
102717         * lib/regcomp.c: Merge to accommodate white space
102718         changes from glibc's 2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
102720         regcomp.c: do not ignore internal return values
102721         * lib/regcomp.c: Do not ignore internal return values.
102722         This is from glibc's 2da42bc06566bc89785e580fa1ac89b4c9f2a63c,
102723         but without its white-space changes and spelling fixes.
102725         regex_internal.h: define __attribute_warn_unused_result__
102726         * lib/regex_internal.h (__attribute_warn_unused_result__): Define.
102728         maint: add a syntax-check rule to check for vulnerable Makefile.in
102729         * top/maint.mk (sc_vulnerable_makefile_CVE-2009-4029): New rule.
102731 2010-01-27  Jim Meyering  <meyering@redhat.com>
102733         ncftpput-ftp: clean up spaces
102734         * build-aux/ncftpput-ftp: Make Copyright line consistent.
102735         Remove trailing blanks.
102737 2010-01-27  Simon Josefsson  <simon@josefsson.org>
102739         * build-aux/git-version-gen: Fix copyright statement.
102740         * build-aux/gnupload: Likewise.
102741         * tests/test-arcfour.c: Likewise.
102742         * tests/test-arctwo.c: Likewise.
102743         * tests/test-count-one-bits.c: Likewise.
102744         * tests/test-crc.c: Likewise.
102745         * tests/test-des.c: Likewise.
102746         * tests/test-gc-arcfour.c: Likewise.
102747         * tests/test-gc-arctwo.c: Likewise.
102748         * tests/test-gc-des.c: Likewise.
102749         * tests/test-gc-hmac-md5.c: Likewise.
102750         * tests/test-gc-hmac-sha1.c: Likewise.
102751         * tests/test-gc-md2.c: Likewise.
102752         * tests/test-gc-md4.c: Likewise.
102753         * tests/test-gc-md5.c: Likewise.
102754         * tests/test-gc-pbkdf2-sha1.c: Likewise.
102755         * tests/test-gc-rijndael.c: Likewise.
102756         * tests/test-gc-sha1.c: Likewise.
102757         * tests/test-gc.c: Likewise.
102758         * tests/test-gethostname.c: Likewise.
102759         * tests/test-gettimeofday.c: Likewise.
102760         * tests/test-hash.c: Likewise.
102761         * tests/test-hmac-md5.c: Likewise.
102762         * tests/test-hmac-sha1.c: Likewise.
102763         * tests/test-md2.c: Likewise.
102764         * tests/test-md4.c: Likewise.
102765         * tests/test-md5.c: Likewise.
102766         * tests/test-memchr.c: Likewise.
102767         * tests/test-memchr2.c: Likewise.
102768         * tests/test-memcmp.c: Likewise.
102769         * tests/test-memmem.c: Likewise.
102770         * tests/test-memrchr.c: Likewise.
102771         * tests/test-rawmemchr.c: Likewise.
102772         * tests/test-read-file.c: Likewise.
102773         * tests/test-rijndael.c: Likewise.
102774         * tests/test-sockets.c: Likewise.
102775         * tests/test-strchrnul.c: Likewise.
102776         * tests/test-strstr.c: Likewise.
102777         * tests/test-strtod.c: Likewise.
102778         * build-aux/ncftpput-ftp: Likewise.
102780 2010-01-26  Eric Blake  <ebb9@byu.net>
102782         ignore-value: update recommended header name
102783         * modules/ignore-value (Include): Only use <> for headers that
102784         exist in glibc.
102786 2010-01-26  Jim Meyering  <meyering@redhat.com>
102788         test-userspec.c: avoid compiler warnings
102789         * tests/test-userspec.c (main): Avoid shadowing ("uid"),
102790         and "initialization discards qualifiers..." warnings.
102791         Put the first "uid" in its own scope, and make char* members "const".
102793 2010-01-25  Bruno Haible  <bruno@clisp.org>
102795         gnulib-tool: Make warning diagnostics consistent.
102796         * gnulib-tool (func_warning): New function.
102797         Use it everywhere where gnulib-tool produces output to stderr and it is
102798         not a fatal error.
102800 2010-01-25  Bruno Haible  <bruno@clisp.org>
102802         Fix test dependencies.
102803         * modules/xstrtol-tests (Depends-on): Add inttypes.
102804         * modules/xstrtoll-tests (Depends-on): Likewise. Remove xstrtoll.
102806 2010-01-25  Pádraig Brady  <P@draigBrady.com>
102808         syntax-check: detect incorrect boolean macro values in config.h
102809         * modules/maintainer-makefile (configure.ac): Parameterize the location
102810         of config.h which will be available to makefiles as $(CONFIG_INCLUDE).
102811         The logic is from Eric Blake and the location indicated by Jim Meyering.
102812         Note the more natural CONFIG_HEADER name is prohibited by automake
102813         for backwards compatibility reasons.
102814         * top/maint.mk (sc_Wundef_boolean): New rule.
102816 2010-01-25  Jim Meyering  <meyering@redhat.com>
102818         bootstrap: detect MacOS 10.6's shasum, too
102819         * build-aux/bootstrap: Also recognize MacOS 10.6's shasum.
102820         Suggested by Thomas Treichl <Thomas.Treichl@gmx.net>.
102822 2010-01-23  Jim Meyering  <meyering@redhat.com>
102824         xstrtoll: new module
102825         * modules/xstrtoll: New file.
102826         * MODULES.html.sh (Numeric conversion functions): Add xstrtoll.
102827         * lib/xstrtol.h [HAVE_LONG_LONG_INT]: Declare xstrtoll and xstrtoull.
102828         * lib/xstrtoll.c, lib/xstrtoull.c: New files.
102829         ./configure fails if you use this module and lack "long long".
102830         * modules/xstrtoll-tests: New module.
102831         * tests/test-xstrtoll.c, tests/test-xstrtoull.c: New files.
102832         * tests/test-xstrtoll.sh: Like test-xstrtol.c, but use the
102833         new init.sh-based test framework.
102835 2010-01-24  Bruno Haible  <bruno@clisp.org>
102837         Tests for module 'yn'.
102838         * modules/yn-tests: New file.
102839         * tests/test-yn.c: New file.
102841         Tests for module 'y1'.
102842         * modules/y1-tests: New file.
102843         * tests/test-y1.c: New file.
102845         Tests for module 'y0'.
102846         * modules/y0-tests: New file.
102847         * tests/test-y0.c: New file.
102849         Tests for module 'tanh'.
102850         * modules/tanh-tests: New file.
102851         * tests/test-tanh.c: New file.
102853         Tests for module 'tan'.
102854         * modules/tan-tests: New file.
102855         * tests/test-tan.c: New file.
102857         Tests for module 'sqrt'.
102858         * modules/sqrt-tests: New file.
102859         * tests/test-sqrt.c: New file.
102861         Tests for module 'sinh'.
102862         * modules/sinh-tests: New file.
102863         * tests/test-sinh.c: New file.
102865         Tests for module 'sin'.
102866         * modules/sin-tests: New file.
102867         * tests/test-sin.c: New file.
102869         Tests for module 'rint'.
102870         * modules/rint-tests: New file.
102871         * tests/test-rint.c: New file.
102873         Tests for module 'remainder'.
102874         * modules/remainder-tests: New file.
102875         * tests/test-remainder.c: New file.
102877         Tests for module 'pow'.
102878         * modules/pow-tests: New file.
102879         * tests/test-pow.c: New file.
102881         Tests for module 'nextafter'.
102882         * modules/nextafter-tests: New file.
102883         * tests/test-nextafter.c: New file.
102885         Tests for module 'modf'.
102886         * modules/modf-tests: New file.
102887         * tests/test-modf.c: New file.
102889         Tests for module 'logb'.
102890         * modules/logb-tests: New file.
102891         * tests/test-logb.c: New file.
102893         Tests for module 'log1p'.
102894         * modules/log1p-tests: New file.
102895         * tests/test-log1p.c: New file.
102897         Tests for module 'log10'.
102898         * modules/log10-tests: New file.
102899         * tests/test-log10.c: New file.
102901         Tests for module 'log'.
102902         * modules/log-tests: New file.
102903         * tests/test-log.c: New file.
102905         Tests for module 'lgamma'.
102906         * modules/lgamma-tests: New file.
102907         * tests/test-lgamma.c: New file.
102909         Tests for module 'ldexp'.
102910         * modules/ldexp-tests: New file.
102911         * tests/test-ldexp.c: New file.
102913         Tests for module 'jn'.
102914         * modules/jn-tests: New file.
102915         * tests/test-jn.c: New file.
102917         Tests for module 'j1'.
102918         * modules/j1-tests: New file.
102919         * tests/test-j1.c: New file.
102921         Tests for module 'j0'.
102922         * modules/j0-tests: New file.
102923         * tests/test-j0.c: New file.
102925         Tests for module 'hypot'.
102926         * modules/hypot-tests: New file.
102927         * tests/test-hypot.c: New file.
102929         Tests for module 'fmod'.
102930         * modules/fmod-tests: New file.
102931         * tests/test-fmod.c: New file.
102933         Tests for module 'fabs'.
102934         * modules/fabs-tests: New file.
102935         * tests/test-fabs.c: New file.
102937         Tests for module 'exp'.
102938         * modules/exp-tests: New file.
102939         * tests/test-exp.c: New file.
102941         Tests for module 'erfc'.
102942         * modules/erfc-tests: New file.
102943         * tests/test-erfc.c: New file.
102945         Tests for module 'erf'.
102946         * modules/erf-tests: New file.
102947         * tests/test-erf.c: New file.
102949         Tests for module 'cosh'.
102950         * modules/cosh-tests: New file.
102951         * tests/test-cosh.c: New file.
102953         Tests for module 'cos'.
102954         * modules/cos-tests: New file.
102955         * tests/test-cos.c: New file.
102957         Tests for module 'copysign'.
102958         * modules/copysign-tests: New file.
102959         * tests/test-copysign.c: New file.
102961         Tests for module 'cbrt'.
102962         * modules/cbrt-tests: New file.
102963         * tests/test-cbrt.c: New file.
102965         Tests for module 'atan2'.
102966         * modules/atan2-tests: New file.
102967         * tests/test-atan2.c: New file.
102969         Tests for module 'atan'.
102970         * modules/atan-tests: New file.
102971         * tests/test-atan.c: New file.
102973         Tests for module 'asin'.
102974         * modules/asin-tests: New file.
102975         * tests/test-asin.c: New file.
102977         Tests for module 'acos'.
102978         * modules/acos-tests: New file.
102979         * tests/test-acos.c: New file.
102981 2010-01-24  Bruno Haible  <bruno@clisp.org>
102983         Fix tests for common <math.h> functions.
102984         * m4/mathfunc.m4 (gl_MATHFUNC): Take two additional parameters. Use a
102985         code snippet that references the function pointer, rather than merely
102986         calling the function. Substitute the FUNC_LIBM variable.
102987         * m4/sqrt.m4 (gl_FUNC_SQRT): Update gl_MATHFUNC invocation.
102988         * modules/acos (configure.ac): Likewise.
102989         * modules/asin (configure.ac): Likewise.
102990         * modules/atan (configure.ac): Likewise.
102991         * modules/atan2 (configure.ac): Likewise.
102992         * modules/cbrt (configure.ac): Likewise.
102993         * modules/copysign (configure.ac): Likewise.
102994         * modules/cos (configure.ac): Likewise.
102995         * modules/cosh (configure.ac): Likewise.
102996         * modules/erf (configure.ac): Likewise.
102997         * modules/erfc (configure.ac): Likewise.
102998         * modules/exp (configure.ac): Likewise.
102999         * modules/fabs (configure.ac): Likewise.
103000         * modules/fmod (configure.ac): Likewise.
103001         * modules/hypot (configure.ac): Likewise.
103002         * modules/j0 (configure.ac): Likewise.
103003         * modules/j1 (configure.ac): Likewise.
103004         * modules/jn (configure.ac): Likewise.
103005         * modules/ldexp (configure.ac): Likewise.
103006         * modules/lgamma (configure.ac): Likewise.
103007         * modules/log (configure.ac): Likewise.
103008         * modules/log10 (configure.ac): Likewise.
103009         * modules/log1p (configure.ac): Likewise.
103010         * modules/logb (configure.ac): Likewise.
103011         * modules/modf (configure.ac): Likewise.
103012         * modules/nextafter (configure.ac): Likewise.
103013         * modules/pow (configure.ac): Likewise.
103014         * modules/remainder (configure.ac): Likewise.
103015         * modules/rint (configure.ac): Likewise.
103016         * modules/sin (configure.ac): Likewise.
103017         * modules/sinh (configure.ac): Likewise.
103018         * modules/tan (configure.ac): Likewise.
103019         * modules/tanh (configure.ac): Likewise.
103020         * modules/y0 (configure.ac): Likewise.
103021         * modules/y1 (configure.ac): Likewise.
103022         * modules/yn (configure.ac): Likewise.
103024 2010-01-24  Bruno Haible  <bruno@clisp.org>
103026         Tests: Defeat inlining of math functions by GCC >= 4.3.0.
103027         * tests/test-acosl.c (x): New variable.
103028         (main): Store argument in x and fetch it from x.
103029         * tests/test-asinl.c (x): New variable.
103030         (main): Store argument in x and fetch it from x.
103031         * tests/test-atanl.c (x): New variable.
103032         (main): Store argument in x and fetch it from x.
103033         * tests/test-cosl.c (x): New variable.
103034         (main): Store argument in x and fetch it from x.
103035         * tests/test-expl.c (x): New variable.
103036         (main): Store argument in x and fetch it from x.
103037         * tests/test-logl.c (x): New variable.
103038         (main): Store argument in x and fetch it from x.
103039         * tests/test-sinl.c (x): New variable.
103040         (main): Store argument in x and fetch it from x.
103041         * tests/test-sqrtl.c (x): New variable.
103042         (main): Store argument in x and fetch it from x.
103043         * tests/test-tanl.c (x): New variable.
103044         (main): Store argument in x and fetch it from x.
103046 2010-01-24  Bruno Haible  <bruno@clisp.org>
103048         Provide EXEEXT and srcdir in TESTS_ENVIRONMENT by default.
103049         * gnulib-tool (func_emit_tests_Makefile_am): Add EXEEXT and srcdir
103050         assignments to the initial TESTS_ENVIRONMENT.
103051         * doc/gnulib.texi (Unit test modules): Document it.
103052         * modules/acl-tests (Makefile.am): Drop EXEEXT assignment from
103053         TESTS_ENVIRONMENT.
103054         * modules/btowc-tests (Makefile.am): Likewise.
103055         * modules/c-stack-tests (Makefile.am): Likewise.
103056         * modules/c-strcase-tests (Makefile.am): Likewise.
103057         * modules/copy-file-tests (Makefile.am): Likewise.
103058         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
103059         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
103060         * modules/mbrtowc-tests (Makefile.am): Likewise.
103061         * modules/mbscasecmp-tests (Makefile.am): Likewise.
103062         * modules/mbscasestr-tests (Makefile.am): Likewise.
103063         * modules/mbschr-tests (Makefile.am): Likewise.
103064         * modules/mbscspn-tests (Makefile.am): Likewise.
103065         * modules/mbsinit-tests (Makefile.am): Likewise.
103066         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
103067         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
103068         * modules/mbspbrk-tests (Makefile.am): Likewise.
103069         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
103070         * modules/mbsrchr-tests (Makefile.am): Likewise.
103071         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
103072         * modules/mbsspn-tests (Makefile.am): Likewise.
103073         * modules/mbsstr-tests (Makefile.am): Likewise.
103074         * modules/nl_langinfo-tests (Makefile.am): Likewise.
103075         * modules/unicase/locale-language-tests (Makefile.am): Likewise.
103076         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
103077         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
103078         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
103079         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
103080         * modules/uniwbrk/ulc-wordbreaks-tests (Makefile.am): Likewise.
103081         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
103082         * modules/wcrtomb-tests (Makefile.am): Likewise.
103083         * modules/wcsnrtombs-tests (Makefile.am): Likewise.
103084         * modules/wcsrtombs-tests (Makefile.am): Likewise.
103085         * modules/quotearg-tests (Makefile.am): Drop EXEEXT and srcdir
103086         assignments from TESTS_ENVIRONMENT.
103087         * modules/argp-tests (Makefile.am): Drop TESTS_ENVIRONMENT
103088         augmentation.
103089         * modules/argp-version-etc-tests (Makefile.am): Likewise.
103090         * modules/atexit-tests (Makefile.am): Likewise.
103091         * modules/binary-io-tests (Makefile.am): Likewise.
103092         * modules/closein-tests (Makefile.am): Likewise.
103093         * modules/dprintf-posix-tests (Makefile.am): Likewise.
103094         * modules/exclude-tests (Makefile.am): Likewise.
103095         * modules/fflush-tests (Makefile.am): Likewise.
103096         * modules/fpending-tests (Makefile.am): Likewise.
103097         * modules/fprintf-posix-tests (Makefile.am): Likewise.
103098         * modules/freadahead-tests (Makefile.am): Likewise.
103099         * modules/freadptr-tests (Makefile.am): Likewise.
103100         * modules/freadseek-tests (Makefile.am): Likewise.
103101         * modules/fseek-tests (Makefile.am): Likewise.
103102         * modules/fseeko-tests (Makefile.am): Likewise.
103103         * modules/ftell-tests (Makefile.am): Likewise.
103104         * modules/ftello-tests (Makefile.am): Likewise.
103105         * modules/idpriv-drop-tests (Makefile.am): Likewise.
103106         * modules/idpriv-droptemp-tests (Makefile.am): Likewise.
103107         * modules/lseek-tests (Makefile.am): Likewise.
103108         * modules/parse-duration-tests (Makefile.am): Likewise.
103109         * modules/perror-tests (Makefile.am): Likewise.
103110         * modules/pipe-filter-gi-tests (Makefile.am): Likewise.
103111         * modules/pipe-filter-ii-tests (Makefile.am): Likewise.
103112         * modules/pipe-tests (Makefile.am): Likewise.
103113         * modules/pread-tests (Makefile.am): Likewise.
103114         * modules/printf-posix-tests (Makefile.am): Likewise.
103115         * modules/select-tests (Makefile.am): Likewise.
103116         * modules/sigpipe-tests (Makefile.am): Likewise.
103117         * modules/tsearch-tests (Makefile.am): Likewise.
103118         * modules/unicase/ulc-casecmp-tests (Makefile.am): Likewise.
103119         * modules/unicase/ulc-casecoll-tests (Makefile.am): Likewise.
103120         * modules/uniname/uniname-tests (Makefile.am): Likewise.
103121         * modules/uniwidth/width-tests (Makefile.am): Likewise.
103122         * modules/vdprintf-posix-tests (Makefile.am): Likewise.
103123         * modules/version-etc-tests (Makefile.am): Likewise.
103124         * modules/vfprintf-posix-tests (Makefile.am): Likewise.
103125         * modules/vprintf-posix-tests (Makefile.am): Likewise.
103126         * modules/xalloc-die-tests (Makefile.am): Likewise.
103127         * modules/xprintf-posix-tests (Makefile.am): Likewise.
103128         * modules/xstrtoimax-tests (Makefile.am): Likewise.
103129         * modules/xstrtol-tests (Makefile.am): Likewise.
103130         * modules/xstrtoumax-tests (Makefile.am): Likewise.
103131         * modules/yesno-tests (Makefile.am): Likewise.
103132         Suggested by Jim Meyering.
103134 2010-01-24  Bruno Haible  <bruno@clisp.org>
103136         More documentation.
103137         * doc/gnulib.texi (Writing modules): New chapter.
103138         (Miscellaneous Notes): Move sections "Comments" and "Header files" to
103139         the new chapter.
103141 2010-01-24  Jim Meyering  <meyering@redhat.com>
103143         maint.mk: do not prepend "./" after filtering
103144         * top/maint.mk (_prepend_srcdir_prefix): New variable
103145         (VC_LIST_EXCEPT): Use it to avoid prepending (post-filter)
103146         "./" when $(srcdir) is ".".
103148         define STREQ(a,b) consistently, removing useless parentheses
103149         #define STREQ(a, b) (strcmp ((a), (b)) == 0) is over-parenthesized,
103150         since the only risk is that "a" or "b" contains an unparenthesized
103151         comma, but if either did that, STREQ would have 3 or more arguments.
103152         Hence, #define STREQ(a, b) (strcmp (a, b) == 0) is better.
103153         * lib/fts.c (STREQ): Remove unnecessary parentheses.
103154         * lib/hash-triple.c (STREQ): Likewise.
103155         * tests/test-argv-iter.c (STREQ): Use a and b, not s1 and s2.
103156         * lib/getugroups.c (STREQ): Likewise.
103158 2010-01-23  Jim Meyering  <meyering@redhat.com>
103160         maint.mk: fix syntax-check in a non-srcdir build directory
103161         * top/maint.mk (_dot_escaped_srcdir): Remove erroneous backslash,
103162         introduced in my 2010-01-21 commit, a6da6c45.  Reported by Eric Blake.
103164 2010-01-22  Jim Meyering  <meyering@redhat.com>
103166         userspec: add unit tests
103167         * tests/test-userspec.c: New file.
103168         * modules/userspec-tests: Likewise.
103170 2010-01-21  Jim Meyering  <meyering@redhat.com>
103172         maint.mk: handle source file names containing "." robustly
103173         * top/maint.mk (_dot_escaped_srcdir): Define.
103174         (VC_LIST): Use it in LHS of sed substitution.
103176 2010-01-21  Jiri Denemark  <jdenemar@redhat.com>
103178         maint.mk: fix VC_LIST_EXCEPT for srcdir != builddir
103179         * top/maint.mk (VC_LIST_EXCEPT): Preprocess the output of
103180         $(VC_LIST) to remove a prefix of '$(srcdir)/', so that it works
103181         from a non-srcdir build.
103183 2010-01-20  Eric Blake  <ebb9@byu.net>
103185         warn-on-use: use instead of link-warning
103186         * modules/stdio (Depends-on, Makefile.am): Drop link-warning.
103187         * modules/unistd (Depends-on, Makefile.am): Likewise.
103188         * modules/arpa_inet (Depends-on): Replace link-warning with
103189         warn-on-use.
103190         (Makefile.am): Update rules accordingly.
103191         * modules/ctype (Depends-on, Makefile.am): Likewise.
103192         * modules/dirent (Depends-on, Makefile.am): Likewise.
103193         * modules/fcntl-h (Depends-on, Makefile.am): Likewise.
103194         * modules/inttypes (Depends-on, Makefile.am): Likewise.
103195         * modules/langinfo (Depends-on, Makefile.am): Likewise.
103196         * modules/locale (Depends-on, Makefile.am): Likewise.
103197         * modules/math (Depends-on, Makefile.am): Likewise.
103198         * modules/search (Depends-on, Makefile.am): Likewise.
103199         * modules/signal (Depends-on, Makefile.am): Likewise.
103200         * modules/spawn (Depends-on, Makefile.am): Likewise.
103201         * modules/stdlib (Depends-on, Makefile.am): Likewise.
103202         * modules/string (Depends-on, Makefile.am): Likewise.
103203         * modules/strings (Depends-on, Makefile.am): Likewise.
103204         * modules/sys_file (Depends-on, Makefile.am): Likewise.
103205         * modules/sys_ioctl (Depends-on, Makefile.am): Likewise.
103206         * modules/sys_select (Depends-on, Makefile.am): Likewise.
103207         * modules/sys_socket (Depends-on, Makefile.am): Likewise.
103208         * modules/sys_stat (Depends-on, Makefile.am): Likewise.
103209         * modules/sys_times (Depends-on, Makefile.am): Likewise.
103210         * modules/sys_utsname (Depends-on, Makefile.am): Likewise.
103211         * modules/wchar (Depends-on, Makefile.am): Likewise.
103212         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Check which functions
103213         should be poisoned.
103214         * m4/ctype.m4 (gl_CTYPE_H): Likewise.
103215         * m4/dirent_h.m4 (gl_DIRENT_H): Likewise.
103216         * m4/fcntl_h.m4 (gl_FCNTL_H): Likewise.
103217         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
103218         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
103219         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
103220         * m4/math_h.m4 (gl_MATH_H): Likewise.
103221         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
103222         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
103223         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
103224         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
103225         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
103226         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
103227         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Likewise.
103228         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H_DEFAULTS): Likewise.
103229         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
103230         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
103231         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
103232         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
103233         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
103234         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
103235         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
103236         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
103237         * lib/arpa_inet.in.h: Use _GL_WARN_ON_USE instead of
103238         GL_LINK_WARNING.
103239         * lib/ctype.in.h: Likewise.
103240         * lib/dirent.in.h: Likewise.
103241         * lib/fcntl.in.h: Likewise.
103242         * lib/inttypes.in.h: Likewise.
103243         * lib/langinfo.in.h: Likewise.
103244         * lib/locale.in.h: Likewise.
103245         * lib/math.in.h: Likewise.
103246         * lib/search.in.h: Likewise.
103247         * lib/signal.in.h: Likewise.
103248         * lib/spawn.in.h: Likewise.
103249         * lib/stdio.in.h: Likewise.
103250         * lib/stdlib.in.h: Likewise.
103251         * lib/string.in.h: Likewise.
103252         * lib/strings.in.h: Likewise.
103253         * lib/sys_file.in.h: Likewise.
103254         * lib/sys_ioctl.in.h: Likewise.
103255         * lib/sys_select.in.h: Likewise.
103256         * lib/sys_socket.in.h: Likewise.
103257         * lib/sys_stat.in.h: Likewise.
103258         * lib/sys_times.in.h: Likewise.
103259         * lib/sys_utsname.in.h: Likewise.
103260         * lib/unistd.in.h: Likewise.
103261         * lib/wchar.in.h: Likewise.
103263 2010-01-20  Bruno Haible  <bruno@clisp.org>
103265         Avoid duplicate -lm.
103266         * m4/isnan.m4 (gl_ISNAN): Avoid duplicate -lm in $ISNAN_LIBM.
103267         * m4/round.m4 (gl_FUNC_ROUND): Avoid duplicate -lm in $ROUND_LIBM.
103268         * m4/roundf.m4 (gl_FUNC_ROUNDF): Avoid duplicate -lm in $ROUNDF_LIBM.
103269         * m4/roundl.m4 (gl_FUNC_ROUNDL): Avoid duplicate -lm in $ROUNDL_LIBM.
103270         * m4/acosl.m4 (gl_FUNC_ACOSL): Avoid duplicate -lm in $ACOSL_LIBM.
103271         * m4/cosl.m4 (gl_FUNC_COSL): Avoid duplicate -lm in $COSL_LIBM.
103272         * m4/logl.m4 (gl_FUNC_LOGL): Avoid duplicate -lm in $LOGL_LIBM.
103273         * m4/sinl.m4 (gl_FUNC_SINL): Avoid duplicate -lm in $SINL_LIBM.
103274         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Avoid duplicate -lm in $SQRTL_LIBM.
103275         * m4/tanl.m4 (gl_FUNC_TANL): Avoid duplicate -lm in $TANL_LIBM.
103276         * m4/asinl.m4 (gl_FUNC_ASINL): Same change, for consistency.
103277         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
103278         Reported by Paolo Bonzini.
103280 2010-01-19  Bruno Haible  <bruno@clisp.org>
103282         langinfo, nl_langinfo: Relicense under LGPLv2+.
103283         * modules/langinfo (License): Change to LGPLv2+.
103284         * modules/nl_langinfo (License): Likewise.
103285         Patch by David Lutterkort <lutter@redhat.com>.
103287 2010-01-19  Bruno Haible  <bruno@clisp.org>
103289         Avoid compilation error with cc on OSF/1 5.1.
103290         * lib/fcntl.in.h: Include <unistd.h> after the #include_next <fcntl.h>
103291         statement, not before.
103292         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
103294 2010-01-18  Bruno Haible  <bruno@clisp.org>
103296         Avoid a link error due to the __printf__ symbol.
103297         * lib/stdio.in.h (__attribute__): Define to empty also for gcc 2.5.x
103298         and 2.6.x.
103299         (__format__, __printf__): Remove definitions.
103300         * lib/argp-fmtstream.h: Likewise.
103301         * lib/argp.h: Likewise.
103302         * lib/error.h: Likewise.
103303         * lib/vasnprintf.h: Likewise.
103304         * lib/xprintf.h: Likewise.
103305         * lib/xvasprintf.h: Likewise.
103306         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
103308 2010-01-18  Bruno Haible  <bruno@clisp.org>
103310         Tests for module 'tanl'.
103311         * modules/tanl-tests: New file.
103312         * tests/test-tanl.c: New file.
103314         Tests for module 'sqrtl'.
103315         * modules/sqrtl-tests: New file.
103316         * tests/test-sqrtl.c: New file.
103318         Tests for module 'sinl'.
103319         * modules/sinl-tests: New file.
103320         * tests/test-sinl.c: New file.
103322         Tests for module 'logl'.
103323         * modules/logl-tests: New file.
103324         * tests/test-logl.c: New file.
103326         Tests for module 'expl'.
103327         * modules/expl-tests: New file.
103328         * tests/test-expl.c: New file.
103330         Tests for module 'cosl'.
103331         * modules/cosl-tests: New file.
103332         * tests/test-cosl.c: New file.
103334         Tests for module 'atanl'.
103335         * modules/atanl-tests: New file.
103336         * tests/test-atanl.c: New file.
103338         Tests for module 'asinl'.
103339         * modules/asinl-tests: New file.
103340         * tests/test-asinl.c: New file.
103342         Tests for module 'acosl'.
103343         * modules/acosl-tests: New file.
103344         * tests/test-acosl.c: New file.
103346         New modules acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl.
103347         * lib/math.in.h (acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl,
103348         tanl): Use the standard gnulib idiom.
103349         * lib/cosl.c: Don't include trigl.c and sincosl.c.
103350         * lib/sinl.c: Likewise.
103351         * lib/tanl.c: Don't include trigl.c.
103352         (kernel_tanl): Make static.
103353         * lib/sincosl.c: Include trigl.h first.
103354         * lib/trigl.c: Likewise.
103355         * m4/acosl.m4: New file.
103356         * m4/asinl.m4: New file.
103357         * m4/atanl.m4: New file.
103358         * m4/cosl.m4: New file.
103359         * m4/expl.m4: New file.
103360         * m4/logl.m4: New file.
103361         * m4/sinl.m4: New file.
103362         * m4/sqrtl.m4: New file.
103363         * m4/tanl.m4: New file.
103364         * m4/mathl.m4: Remove file.
103365         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_* and HAVE_*
103366         variables for acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl.
103367         Don't initialize GNULIB_MATHL.
103368         * modules/acosl: New file.
103369         * modules/asinl: New file.
103370         * modules/atanl: New file.
103371         * modules/cosl: New file.
103372         * modules/expl: New file.
103373         * modules/logl: New file.
103374         * modules/sinl: New file.
103375         * modules/sqrtl: New file.
103376         * modules/tanl: New file.
103377         * modules/math (Makefile.am): Substitute GNULIB_* and HAVE_* variables
103378         for acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl. Don't
103379         substitute GNULIB_MATHL.
103380         * modules/mathl: Rewritten.
103381         * doc/posix-functions/acosl.texi: Mention the 'acosl' module.
103382         * doc/posix-functions/asinl.texi: Mention the 'asinl' module.
103383         * doc/posix-functions/atanl.texi: Mention the 'atanl' module.
103384         * doc/posix-functions/cosl.texi: Mention the 'cosl' module.
103385         * doc/posix-functions/expl.texi: Mention the 'expl' module.
103386         * doc/posix-functions/logl.texi: Mention the 'logl' module.
103387         * doc/posix-functions/sinl.texi: Mention the 'sinl' module.
103388         * doc/posix-functions/sqrtl.texi: Mention the 'sqrtl' module.
103389         * doc/posix-functions/tanl.texi: Mention the 'tanl' module.
103391 2010-01-18  Bruno Haible  <bruno@clisp.org>
103393         sqrt: Make gl_FUNC_SQRT requirable.
103394         * m4/sqrt.m4: New file.
103395         * modules/sqrt (Files): Add it.
103396         (configure.ac): Invoke gl_FUNC_SQRT.
103398 2010-01-18  Bruno Haible  <bruno@clisp.org>
103400         New modules for common <math.h> functions.
103401         * m4/mathfunc.m4: New file.
103402         * modules/acos: New file.
103403         * modules/asin: New file.
103404         * modules/atan: New file.
103405         * modules/atan2: New file.
103406         * modules/cbrt: New file.
103407         * modules/copysign: New file.
103408         * modules/cos: New file.
103409         * modules/cosh: New file.
103410         * modules/erf: New file.
103411         * modules/erfc: New file.
103412         * modules/exp: New file.
103413         * modules/fabs: New file.
103414         * modules/fmod: New file.
103415         * modules/hypot: New file.
103416         * modules/j0: New file.
103417         * modules/j1: New file.
103418         * modules/jn: New file.
103419         * modules/ldexp: New file.
103420         * modules/lgamma: New file.
103421         * modules/log: New file.
103422         * modules/log10: New file.
103423         * modules/log1p: New file.
103424         * modules/logb: New file.
103425         * modules/modf: New file.
103426         * modules/nextafter: New file.
103427         * modules/pow: New file.
103428         * modules/remainder: New file.
103429         * modules/rint: New file.
103430         * modules/sin: New file.
103431         * modules/sinh: New file.
103432         * modules/sqrt: New file.
103433         * modules/tan: New file.
103434         * modules/tanh: New file.
103435         * modules/y0: New file.
103436         * modules/y1: New file.
103437         * modules/yn: New file.
103438         * doc/posix-functions/acos.texi: Mention the 'acos' module.
103439         * doc/posix-functions/asin.texi: Mention the 'asin' module.
103440         * doc/posix-functions/atan.texi: Mention the 'atan' module.
103441         * doc/posix-functions/atan2.texi: Mention the 'atan2' module.
103442         * doc/posix-functions/cbrt.texi: Mention the 'cbrt' module.
103443         * doc/posix-functions/copysign.texi: Mention the 'copysign' module.
103444         * doc/posix-functions/cos.texi: Mention the 'cos' module.
103445         * doc/posix-functions/cosh.texi: Mention the 'cosh' module.
103446         * doc/posix-functions/erf.texi: Mention the 'erf' module.
103447         * doc/posix-functions/erfc.texi: Mention the 'erfc' module.
103448         * doc/posix-functions/exp.texi: Mention the 'exp' module.
103449         * doc/posix-functions/fabs.texi: Mention the 'fabs' module.
103450         * doc/posix-functions/fmod.texi: Mention the 'fmod' module.
103451         * doc/posix-functions/hypot.texi: Mention the 'hypot' module.
103452         * doc/posix-functions/j0.texi: Mention the 'j0' module.
103453         * doc/posix-functions/j1.texi: Mention the 'j1' module.
103454         * doc/posix-functions/jn.texi: Mention the 'jn' module.
103455         * doc/posix-functions/ldexp.texi: Mention the 'ldexp' module.
103456         * doc/posix-functions/lgamma.texi: Mention the 'lgamma' module.
103457         * doc/posix-functions/log.texi: Mention the 'log' module.
103458         * doc/posix-functions/log10.texi: Mention the 'log10' module.
103459         * doc/posix-functions/log1p.texi: Mention the 'log1p' module.
103460         * doc/posix-functions/logb.texi: Mention the 'logb' module.
103461         * doc/posix-functions/modf.texi: Mention the 'modf' module.
103462         * doc/posix-functions/nextafter.texi: Mention the 'nextafter' module.
103463         * doc/posix-functions/pow.texi: Mention the 'pow' module.
103464         * doc/posix-functions/remainder.texi: Mention the 'remainder' module.
103465         * doc/posix-functions/rint.texi: Mention the 'rint' module.
103466         * doc/posix-functions/sin.texi: Mention the 'sin' module.
103467         * doc/posix-functions/sinh.texi: Mention the 'sinh' module.
103468         * doc/posix-functions/sqrt.texi: Mention the 'sqrt' module.
103469         * doc/posix-functions/tan.texi: Mention the 'tan' module.
103470         * doc/posix-functions/tanh.texi: Mention the 'tanh' module.
103471         * doc/posix-functions/y0.texi: Mention the 'y0' module.
103472         * doc/posix-functions/y1.texi: Mention the 'y1' module.
103473         * doc/posix-functions/yn.texi: Mention the 'yn' module.
103475 2010-01-18  Jim Meyering  <meyering@redhat.com>
103477         ignore-value: relax license to LGPLv2+
103478         * modules/ignore-value (License): Relax to LGPLv2+.
103480         getdate: don't leak when TZ contains two or more '"'s
103481         * lib/getdate.y (get_date): Don't leak a copy of TZ for each
103482         double quote in TZ after the first one.
103484         readtokens: do not leak internal token_lengths buffer
103485         * lib/readtokens.c (readtokens): Free the local, lengths,
103486         when the supplied "token_lengths" parameter is NULL.
103488 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
103490         Fix a couple of missing LIBTHREAD link failures on AIX.
103491         * modules/git-merge-changelog (git_merge_changelog_LDADD): Add
103492         $(LIBTHREAD).
103493         * modules/strsignal-tests (test_strsignal_LDADD): Likewise.
103495         Link test-poll against INET_PTON_LIB.
103496         * modules/poll-tests (test_poll_LDADD): Add $(INET_PTON_LIB),
103497         for inet_pton on Solaris 10.
103499 2010-01-17  Bruno Haible  <bruno@clisp.org>
103501         unistdio/*-sprintf: Fix typo in module description.
103502         * modules/unistdio/u8-sprintf (Depends-on): Fix typo.
103503         * modules/unistdio/u8-u8-sprintf (Depends-on): Likewise.
103504         * modules/unistdio/u16-sprintf (Depends-on): Likewise.
103505         * modules/unistdio/u16-u16-sprintf (Depends-on): Likewise.
103506         * modules/unistdio/u32-sprintf (Depends-on): Likewise.
103507         * modules/unistdio/u32-u32-sprintf (Depends-on): Likewise.
103508         * modules/unistdio/ulc-sprintf (Depends-on): Likewise.
103509         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
103511 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
103513         gnulib-tool: fix filelist for AIX, HP-UX ksh.
103514         * gnulib-tool (func_filter_filelist): Do not quote possibly-empty
103515         variables in shell case patterns, for AIX and HP-UX ksh.
103517         Split large sed scripts, for HP-UX sed.
103518         * modules/stdio: Split sed scripts around 50 sed commands,
103519         to avoid HP-UX limit of 99 commands, in the near future.
103520         * modules/string: Likewise.
103521         * modules/unistd: Likewise.
103523         gnulib-tool: avoid writing in the current directory.
103524         * gnulib-tool (func_emit_lib_Makefile_am)
103525         (func_emit_tests_Makefile_am): Put temporary files in $tmp,
103526         not in the current directory, so concurrent gnulib-tool
103527         instances do not interfere.
103529 2010-01-16  Jim Meyering  <meyering@redhat.com>
103531         doc: update users.txt
103532         * users.txt: Add grep.
103533         (diffutils, gzip): Update URLs.
103535 2010-01-12  Bruno Haible  <bruno@clisp.org>
103537         posix_spawn: Avoid test failure on Cygwin.
103538         * tests/test-posix_spawn3.c (DATA_FILENAME) [CYGWIN]: Use less risky
103539         characters.
103540         Reported by Simon Josefsson.
103542 2010-01-12  Bruno Haible  <bruno@clisp.org>
103544         * tests/test-cond.c (main): When skipping the test, show the reason.
103546 2010-01-12  Simon Josefsson  <simon@josefsson.org>
103548         * lib/striconv.c (str_cd_iconv): Avoid if before free.
103550 2010-01-12  Simon Josefsson  <simon@josefsson.org>
103552         * top/maint.mk (VC_LIST_EXCEPT): Filter list through
103553         VC_LIST_ALWAYS_EXCLUDE_REGEX.
103555 2010-01-12  Eric Blake  <ebb9@byu.net>
103557         build: guarantee AS_VAR_IF
103558         * m4/warnings.m4 (gl_WARN_ADD): Use autoconf name.
103559         (gl_AS_VAR_IF): Move...
103560         * m4/gnulib-common.m4 (AS_VAR_IF): ...here.
103561         Reported by Simon Josefsson.
103563 2010-01-12  Simon Josefsson  <simon@josefsson.org>
103565         * lib/stdio.in.h: Fix typo.
103567 2010-01-12  Simon Josefsson  <simon@josefsson.org>
103569         * m4/gc.m4: Check if linking to libgcrypt also needs linking to
103570         libgpg-error.
103572 2010-01-12  Simon Josefsson  <simon@josefsson.org>
103574         * tests/test-xalloc-die.sh: Use $EXEEXT.
103576 2010-01-12  Simon Josefsson  <simon@josefsson.org>
103577             Bruno Haible  <bruno@clisp.org>
103579         getlogin, getlogin_r: Avoid test failure.
103580         * tests/test-getlogin.c: Include <stdio.h>.
103581         (main): Skip the test when the function fails because stdin is not a
103582         tty.
103583         * tests/test-getlogin_r.c: Include <stdio.h>.
103584         (main): Skip the test when the function fails because stdin is not a
103585         tty.
103587 2010-01-11  Eric Blake  <ebb9@byu.net>
103589         tests: avoid more large file warnings
103590         * tests/test-fflush.c: Avoid warning about ftell use.
103591         * tests/test-fseek.c: Avoid warning about fseek use.
103593 2010-01-10  Bruno Haible  <bruno@clisp.org>
103595         nproc: Work better on Linux when /proc and /sys are not mounted.
103596         * lib/nproc.c (num_processors): Use num_processors_via_affinity_mask ()
103597         as lower bound when, on glibc/Linux systems,
103598         sysconf (_SC_NPROCESSORS_CONF) returns 1.
103599         Suggested by Pádraig Brady <P@draigbrady.com>.
103600         Reported by Dmitry V. Levin <ldv@altlinux.org>.
103602         nproc: Refactor.
103603         * lib/nproc.c (num_processors_via_affinity_mask): New function,
103604         extracted from num_processors.
103605         (num_processors): Call it.
103607 2010-01-11  Jim Meyering  <meyering@redhat.com>
103609         utimecmp: avoid new warning from upcoming gcc-4.5.0
103610         * lib/utimecmp.c (BILLION): Define using #define rather than an
103611         anonymous enum, to placate upcoming gcc-4.5.0's -Wenum-compare.
103613 2010-01-11  Eric Blake  <ebb9@byu.net>
103615         math: add portability warnings for classification macros
103616         * modules/math (Depends-on): Add warn-on-use.
103617         (Makefile.am): Provide new substitutions.
103618         * m4/math_h.m4 (gl_MATH_H): Require inline.
103619         * lib/math.in.h (_GL_WARN_REAL_FLOATING_DECL)
103620         (_GL_WARN_REAL_FLOATING_IMPL): New helper macros.
103621         (isfinite, isinf, isnan, signbit) [GNULIB_POSIXCHECK]: Use them to
103622         implement warnings.
103624         unistd: warn on use of environ without module
103625         * modules/unistd (Depends-on): Add warn-on-use.
103626         (Makefile.am): Provide new substitutions.
103627         * m4/unistd_h.m4 (gl_UNISTD_H): Check for inline and environ.
103628         * lib/unistd.in.h (environ): Wrap with a warning helper function.
103630         stdio: warn on suspicious uses
103631         * modules/stdio (Depends-on): Add warn-on-use.
103632         (Makefile.am): Provide new substitutions.
103633         * m4/stdio_h.m4 (gl_STDIO_H): Check for inline, ftello, and
103634         fseeko.
103635         * lib/stdio.in.h (gets): Always warn on use.
103636         (fseek, ftell): Adjust when warnings are issued, and honor
103637         _GL_NO_LARGE_FILES as a way to silence the warning.
103638         * tests/test-fpurge.c [!GNULIB_FSEEK]: Use new means to squelch
103639         any warning about large file offsets.
103640         * tests/test-freadable.c [!GNULIB_FSEEK]: Likewise.
103641         * tests/test-freading.c [!GNULIB_FSEEK]: Likewise.
103642         * tests/test-fseeko.c [!GNULIB_FSEEK]: Likewise.
103643         * tests/test-ftell.c [!GNULIB_FSEEK]: Likewise.
103644         * tests/test-ftello.c [!GNULIB_FSEEK]: Likewise.
103645         * tests/test-fwritable.c [!GNULIB_FSEEK]: Likewise.
103646         * tests/test-fwriting.c [!GNULIB_FSEEK]: Likewise.
103647         * tests/test-getopt.c [!GNULIB_FTELL]: Likewise.
103649         warn-on-use: new module
103650         * modules/warn-on-use: New file.
103651         * build-aux/warn-on-use.h: Likewise.
103652         * m4/warn-on-use.m4: Likewise.
103653         * MODULES.html.sh (Support for building): Mention it.
103655 2010-01-10  Bruno Haible  <bruno@clisp.org>
103657         Tests for module 'unistr/u32-strdup'.
103658         * modules/unistr/u32-strdup-tests: New file.
103659         * tests/unistr/test-u32-strdup.c: New file.
103661         Tests for module 'unistr/u16-strdup'.
103662         * modules/unistr/u16-strdup-tests: New file.
103663         * tests/unistr/test-u16-strdup.c: New file.
103665         Tests for module 'unistr/u8-strdup'.
103666         * modules/unistr/u8-strdup-tests: New file.
103667         * tests/unistr/test-u8-strdup.c: New file.
103668         * tests/unistr/test-strdup.h: New file.
103670         Tests for module 'unistr/u32-strncmp'.
103671         * modules/unistr/u32-strncmp-tests: New file.
103672         * tests/unistr/test-u32-strncmp.c: New file.
103674         Tests for module 'unistr/u16-strncmp'.
103675         * modules/unistr/u16-strncmp-tests: New file.
103676         * tests/unistr/test-u16-strncmp.c: New file.
103678         Tests for module 'unistr/u8-strncmp'.
103679         * modules/unistr/u8-strncmp-tests: New file.
103680         * tests/unistr/test-u8-strncmp.c: New file.
103681         * tests/unistr/test-strncmp.h: New file.
103683         Tests for module 'unistr/u32-strcoll'.
103684         * modules/unistr/u32-strcoll-tests: New file.
103685         * tests/unistr/test-u32-strcoll.c: New file.
103687         Tests for module 'unistr/u16-strcoll'.
103688         * modules/unistr/u16-strcoll-tests: New file.
103689         * tests/unistr/test-u16-strcoll.c: New file.
103691         Tests for module 'unistr/u8-strcoll'.
103692         * modules/unistr/u8-strcoll-tests: New file.
103693         * tests/unistr/test-u8-strcoll.c: New file.
103695         Tests for module 'unistr/u32-strcmp'.
103696         * modules/unistr/u32-strcmp-tests: New file.
103697         * tests/unistr/test-u32-strcmp.c: New file.
103698         * tests/unistr/test-u32-strcmp.h: New file.
103700         Tests for module 'unistr/u16-strcmp'.
103701         * modules/unistr/u16-strcmp-tests: New file.
103702         * tests/unistr/test-u16-strcmp.c: New file.
103703         * tests/unistr/test-u16-strcmp.h: New file.
103705         Tests for module 'unistr/u8-strcmp'.
103706         * modules/unistr/u8-strcmp-tests: New file.
103707         * tests/unistr/test-u8-strcmp.c: New file.
103708         * tests/unistr/test-u8-strcmp.h: New file.
103709         * tests/unistr/test-strcmp.h: New file.
103711         Tests for module 'unistr/u32-strncat'.
103712         * modules/unistr/u32-strncat-tests: New file.
103713         * tests/unistr/test-u32-strncat.c: New file.
103715         Tests for module 'unistr/u16-strncat'.
103716         * modules/unistr/u16-strncat-tests: New file.
103717         * tests/unistr/test-u16-strncat.c: New file.
103719         Tests for module 'unistr/u8-strncat'.
103720         * modules/unistr/u8-strncat-tests: New file.
103721         * tests/unistr/test-u8-strncat.c: New file.
103722         * tests/unistr/test-strncat.h: New file.
103724         Tests for module 'unistr/u32-strcat'.
103725         * modules/unistr/u32-strcat-tests: New file.
103726         * tests/unistr/test-u32-strcat.c: New file.
103728         Tests for module 'unistr/u16-strcat'.
103729         * modules/unistr/u16-strcat-tests: New file.
103730         * tests/unistr/test-u16-strcat.c: New file.
103732         Tests for module 'unistr/u8-strcat'.
103733         * modules/unistr/u8-strcat-tests: New file.
103734         * tests/unistr/test-u8-strcat.c: New file.
103735         * tests/unistr/test-strcat.h: New file.
103737         Tests for module 'unistr/u32-stpncpy'.
103738         * modules/unistr/u32-stpncpy-tests: New file.
103739         * tests/unistr/test-u32-stpncpy.c: New file.
103741         Tests for module 'unistr/u16-stpncpy'.
103742         * modules/unistr/u16-stpncpy-tests: New file.
103743         * tests/unistr/test-u16-stpncpy.c: New file.
103745         Tests for module 'unistr/u8-stpncpy'.
103746         * modules/unistr/u8-stpncpy-tests: New file.
103747         * tests/unistr/test-u8-stpncpy.c: New file.
103748         * tests/unistr/test-stpncpy.h: New file.
103750         Tests for module 'unistr/u32-strncpy'.
103751         * modules/unistr/u32-strncpy-tests: New file.
103752         * tests/unistr/test-u32-strncpy.c: New file.
103754         Tests for module 'unistr/u16-strncpy'.
103755         * modules/unistr/u16-strncpy-tests: New file.
103756         * tests/unistr/test-u16-strncpy.c: New file.
103758         Tests for module 'unistr/u8-strncpy'.
103759         * modules/unistr/u8-strncpy-tests: New file.
103760         * tests/unistr/test-u8-strncpy.c: New file.
103761         * tests/unistr/test-strncpy.h: New file.
103763         Tests for module 'unistr/u32-stpcpy'.
103764         * modules/unistr/u32-stpcpy-tests: New file.
103765         * tests/unistr/test-u32-stpcpy.c: New file.
103767         Tests for module 'unistr/u16-stpcpy'.
103768         * modules/unistr/u16-stpcpy-tests: New file.
103769         * tests/unistr/test-u16-stpcpy.c: New file.
103771         Tests for module 'unistr/u8-stpcpy'.
103772         * modules/unistr/u8-stpcpy-tests: New file.
103773         * tests/unistr/test-u8-stpcpy.c: New file.
103774         * tests/unistr/test-stpcpy.h: New file.
103776         Tests for module 'unistr/u32-strcpy'.
103777         * modules/unistr/u32-strcpy-tests: New file.
103778         * tests/unistr/test-u32-strcpy.c: New file.
103780         Tests for module 'unistr/u16-strcpy'.
103781         * modules/unistr/u16-strcpy-tests: New file.
103782         * tests/unistr/test-u16-strcpy.c: New file.
103784         Tests for module 'unistr/u8-strcpy'.
103785         * modules/unistr/u8-strcpy-tests: New file.
103786         * tests/unistr/test-u8-strcpy.c: New file.
103787         * tests/unistr/test-strcpy.h: New file.
103789         Tests for module 'unistr/u32-strnlen'.
103790         * modules/unistr/u32-strnlen-tests: New file.
103791         * tests/unistr/test-u32-strnlen.c: New file.
103793         Tests for module 'unistr/u16-strnlen'.
103794         * modules/unistr/u16-strnlen-tests: New file.
103795         * tests/unistr/test-u16-strnlen.c: New file.
103797         Tests for module 'unistr/u8-strnlen'.
103798         * modules/unistr/u8-strnlen-tests: New file.
103799         * tests/unistr/test-u8-strnlen.c: New file.
103800         * tests/unistr/test-strnlen.h: New file.
103802         Tests for module 'unistr/u32-strlen'.
103803         * modules/unistr/u32-strlen-tests: New file.
103804         * tests/unistr/test-u32-strlen.c: New file.
103806         Tests for module 'unistr/u16-strlen'.
103807         * modules/unistr/u16-strlen-tests: New file.
103808         * tests/unistr/test-u16-strlen.c: New file.
103810         Tests for module 'unistr/u8-strlen'.
103811         * modules/unistr/u8-strlen-tests: New file.
103812         * tests/unistr/test-u8-strlen.c: New file.
103814         Tests for module 'unistr/u32-prev'.
103815         * modules/unistr/u32-prev-tests: New file.
103816         * tests/unistr/test-u32-prev.c: New file.
103818         Tests for module 'unistr/u16-prev'.
103819         * modules/unistr/u16-prev-tests: New file.
103820         * tests/unistr/test-u16-prev.c: New file.
103822         Tests for module 'unistr/u8-prev'.
103823         * modules/unistr/u8-prev-tests: New file.
103824         * tests/unistr/test-u8-prev.c: New file.
103826         Tests for module 'unistr/u32-next'.
103827         * modules/unistr/u32-next-tests: New file.
103828         * tests/unistr/test-u32-next.c: New file.
103830         Tests for module 'unistr/u16-next'.
103831         * modules/unistr/u16-next-tests: New file.
103832         * tests/unistr/test-u16-next.c: New file.
103834         Tests for module 'unistr/u8-next'.
103835         * modules/unistr/u8-next-tests: New file.
103836         * tests/unistr/test-u8-next.c: New file.
103838         Tests for module 'unistr/u32-strmbtouc'.
103839         * modules/unistr/u32-strmbtouc-tests: New file.
103840         * tests/unistr/test-u32-strmbtouc.c: New file.
103842         Tests for module 'unistr/u16-strmbtouc'.
103843         * modules/unistr/u16-strmbtouc-tests: New file.
103844         * tests/unistr/test-u16-strmbtouc.c: New file.
103846         Tests for module 'unistr/u8-strmbtouc'.
103847         * modules/unistr/u8-strmbtouc-tests: New file.
103848         * tests/unistr/test-u8-strmbtouc.c: New file.
103850         Tests for module 'unistr/u32-strmblen'.
103851         * modules/unistr/u32-strmblen-tests: New file.
103852         * tests/unistr/test-u32-strmblen.c: New file.
103854         Tests for module 'unistr/u16-strmblen'.
103855         * modules/unistr/u16-strmblen-tests: New file.
103856         * tests/unistr/test-u16-strmblen.c: New file.
103858         Tests for module 'unistr/u8-strmblen'.
103859         * modules/unistr/u8-strmblen-tests: New file.
103860         * tests/unistr/test-u8-strmblen.c: New file.
103862         Tests for module 'unistr/u32-cpy-alloc'.
103863         * modules/unistr/u32-cpy-alloc-tests: New file.
103864         * tests/unistr/test-u32-cpy-alloc.c: New file.
103866         Tests for module 'unistr/u16-cpy-alloc'.
103867         * modules/unistr/u16-cpy-alloc-tests: New file.
103868         * tests/unistr/test-u16-cpy-alloc.c: New file.
103870         Tests for module 'unistr/u8-cpy-alloc'.
103871         * modules/unistr/u8-cpy-alloc-tests: New file.
103872         * tests/unistr/test-u8-cpy-alloc.c: New file.
103873         * tests/unistr/test-cpy-alloc.h: New file.
103875         Tests for module 'unistr/u32-mbsnlen'.
103876         * modules/unistr/u32-mbsnlen-tests: New file.
103877         * tests/unistr/test-u32-mbsnlen.c: New file.
103879         Tests for module 'unistr/u16-mbsnlen'.
103880         * modules/unistr/u16-mbsnlen-tests: New file.
103881         * tests/unistr/test-u16-mbsnlen.c: New file.
103883         Tests for module 'unistr/u8-mbsnlen'.
103884         * modules/unistr/u8-mbsnlen-tests: New file.
103885         * tests/unistr/test-u8-mbsnlen.c: New file.
103887         Tests for module 'unistr/u32-chr'.
103888         * modules/unistr/u32-chr-tests: New file.
103889         * tests/unistr/test-u32-chr.c: New file.
103891         Tests for module 'unistr/u16-chr'.
103892         * modules/unistr/u16-chr-tests: New file.
103893         * tests/unistr/test-u16-chr.c: New file.
103895         Tests for module 'unistr/u8-chr'.
103896         * modules/unistr/u8-chr-tests: New file.
103897         * tests/unistr/test-u8-chr.c: New file.
103898         * tests/unistr/test-chr.h: New file, based on tests/test-memchr.c.
103900         Tests for module 'unistr/u32-cmp2'.
103901         * modules/unistr/u32-cmp2-tests: New file.
103902         * tests/unistr/test-u32-cmp2.c: New file.
103904         Tests for module 'unistr/u16-cmp2'.
103905         * modules/unistr/u16-cmp2-tests: New file.
103906         * tests/unistr/test-u16-cmp2.c: New file.
103908         Tests for module 'unistr/u8-cmp2'.
103909         * modules/unistr/u8-cmp2-tests: New file.
103910         * tests/unistr/test-u8-cmp2.c: New file.
103911         * tests/unistr/test-cmp2.h: New file, based on tests/unistr/test-cmp.h.
103913         Tests for module 'unistr/u32-cmp'.
103914         * modules/unistr/u32-cmp-tests: New file.
103915         * tests/unistr/test-u32-cmp.c: New file.
103917         Tests for module 'unistr/u16-cmp'.
103918         * modules/unistr/u16-cmp-tests: New file.
103919         * tests/unistr/test-u16-cmp.c: New file.
103921         Tests for module 'unistr/u8-cmp'.
103922         * modules/unistr/u8-cmp-tests: New file.
103923         * tests/unistr/test-u8-cmp.c: New file.
103924         * tests/unistr/test-cmp.h: New file, based on tests/test-memcmp.c.
103926         Tests for module 'unistr/u32-set'.
103927         * modules/unistr/u32-set-tests: New file.
103928         * tests/unistr/test-u32-set.c: New file.
103930         Tests for module 'unistr/u16-set'.
103931         * modules/unistr/u16-set-tests: New file.
103932         * tests/unistr/test-u16-set.c: New file.
103934         Tests for module 'unistr/u8-set'.
103935         * modules/unistr/u8-set-tests: New file.
103936         * tests/unistr/test-u8-set.c: New file.
103937         * tests/unistr/test-set.h: New file.
103939         Tests for module 'unistr/u32-move'.
103940         * modules/unistr/u32-move-tests: New file.
103941         * tests/unistr/test-u32-move.c: New file.
103943         Tests for module 'unistr/u16-move'.
103944         * modules/unistr/u16-move-tests: New file.
103945         * tests/unistr/test-u16-move.c: New file.
103947         Tests for module 'unistr/u8-move'.
103948         * modules/unistr/u8-move-tests: New file.
103949         * tests/unistr/test-u8-move.c: New file.
103950         * tests/unistr/test-move.h: New file.
103952         Tests for module 'unistr/u32-cpy'.
103953         * modules/unistr/u32-cpy-tests: New file.
103954         * tests/unistr/test-u32-cpy.c: New file.
103956         Tests for module 'unistr/u16-cpy'.
103957         * modules/unistr/u16-cpy-tests: New file.
103958         * tests/unistr/test-u16-cpy.c: New file.
103960         Tests for module 'unistr/u8-cpy'.
103961         * modules/unistr/u8-cpy-tests: New file.
103962         * tests/unistr/test-u8-cpy.c: New file.
103963         * tests/unistr/test-cpy.h: New file.
103965 2010-01-09  Bruno Haible  <bruno@clisp.org>
103967         Tests for module 'unistr/u32-uctomb'.
103968         * modules/unistr/u32-uctomb-tests: New file.
103969         * tests/unistr/test-u32-uctomb.c: New file.
103971         Tests for module 'unistr/u16-uctomb'.
103972         * modules/unistr/u16-uctomb-tests: New file.
103973         * tests/unistr/test-u16-uctomb.c: New file.
103975         Tests for module 'unistr/u8-uctomb'.
103976         * modules/unistr/u8-uctomb-tests: New file.
103977         * tests/unistr/test-u8-uctomb.c: New file.
103979         Tests for module 'unistr/u32-mbtoucr'.
103980         * modules/unistr/u32-mbtoucr-tests: New file.
103981         * tests/unistr/test-u32-mbtoucr.c: New file.
103983         Tests for module 'unistr/u16-mbtoucr'.
103984         * modules/unistr/u16-mbtoucr-tests: New file.
103985         * tests/unistr/test-u16-mbtoucr.c: New file.
103987         Tests for module 'unistr/u8-mbtoucr'.
103988         * modules/unistr/u8-mbtoucr-tests: New file.
103989         * tests/unistr/test-u8-mbtoucr.c: New file.
103991         Tests for module 'unistr/u32-mbtouc'.
103992         * modules/unistr/u32-mbtouc-tests: New file.
103993         * tests/unistr/test-u32-mbtouc.c: New file.
103995         Tests for module 'unistr/u16-mbtouc'.
103996         * modules/unistr/u16-mbtouc-tests: New file.
103997         * tests/unistr/test-u16-mbtouc.c: New file.
103999         Tests for module 'unistr/u8-mbtouc'.
104000         * modules/unistr/u8-mbtouc-tests: New file.
104001         * tests/unistr/test-u8-mbtouc.c: New file.
104003         Tests for module 'unistr/u32-mbtouc-unsafe'.
104004         * modules/unistr/u32-mbtouc-unsafe-tests: New file.
104005         * tests/unistr/test-u32-mbtouc-unsafe.c: New file.
104006         * tests/unistr/test-u32-mbtouc.h: New file.
104008         Tests for module 'unistr/u16-mbtouc-unsafe'.
104009         * modules/unistr/u16-mbtouc-unsafe-tests: New file.
104010         * tests/unistr/test-u16-mbtouc-unsafe.c: New file.
104011         * tests/unistr/test-u16-mbtouc.h: New file.
104013         Tests for module 'unistr/u8-mbtouc-unsafe'.
104014         * modules/unistr/u8-mbtouc-unsafe-tests: New file.
104015         * tests/unistr/test-u8-mbtouc-unsafe.c: New file.
104016         * tests/unistr/test-u8-mbtouc.h: New file.
104018         Tests for module 'unistr/u32-mblen'.
104019         * modules/unistr/u32-mblen-tests: New file.
104020         * tests/unistr/test-u32-mblen.c: New file.
104022         Tests for module 'unistr/u16-mblen'.
104023         * modules/unistr/u16-mblen-tests: New file.
104024         * tests/unistr/test-u16-mblen.c: New file.
104026         Tests for module 'unistr/u8-mblen'.
104027         * modules/unistr/u8-mblen-tests: New file.
104028         * tests/unistr/test-u8-mblen.c: New file.
104030         Tests for module 'unistr/u32-to-u16'.
104031         * modules/unistr/u32-to-u16-tests: New file.
104032         * tests/unistr/test-u32-to-u16.c: New file.
104034         Tests for module 'unistr/u32-to-u8'.
104035         * modules/unistr/u32-to-u8-tests: New file.
104036         * tests/unistr/test-u32-to-u8.c: New file.
104038         Tests for module 'unistr/u16-to-u32'.
104039         * modules/unistr/u16-to-u32-tests: New file.
104040         * tests/unistr/test-u16-to-u32.c: New file.
104042         Tests for module 'unistr/u16-to-u8'.
104043         * modules/unistr/u16-to-u8-tests: New file.
104044         * tests/unistr/test-u16-to-u8.c: New file.
104046         Tests for module 'unistr/u8-to-u32'.
104047         * modules/unistr/u8-to-u32-tests: New file.
104048         * tests/unistr/test-u8-to-u32.c: New file.
104050         Tests for module 'unistr/u8-to-u16'.
104051         * modules/unistr/u8-to-u16-tests: New file.
104052         * tests/unistr/test-u8-to-u16.c: New file.
104054         Tests for module 'unistr/u32-check'.
104055         * modules/unistr/u32-check-tests: New file.
104056         * tests/unistr/test-u32-check.c: New file.
104058         Tests for module 'unistr/u16-check'.
104059         * modules/unistr/u16-check-tests: New file.
104060         * tests/unistr/test-u16-check.c: New file.
104062         Tests for module 'unistr/u8-check'.
104063         * modules/unistr/u8-check-tests: New file.
104064         * tests/unistr/test-u8-check.c: New file.
104066         * tests/unictype/test-categ_byname.c: Include <stdbool.h>.
104067         (category_equals): New function.
104068         (main): Add more tests.
104069         * modules/unictype/category-byname-tests (Depends-on): Add stdbool.
104071         * tests/unictype/test-bidi_byname.c (main): Add more tests.
104073 2010-01-10  Bruno Haible  <bruno@clisp.org>
104075         unistr/u*-strcoll: Try harder to distinguish different strings.
104076         * lib/unistr/u-strcoll.h (FUNC): When sl1 and sl2 are the same,
104077         compare s1 and s2 to see if they are different.
104079 2010-01-10  Bruno Haible  <bruno@clisp.org>
104081         unistr/u*-stpncpy: Fix the return value.
104082         * lib/unistr.h (u8_stpncpy, u16_stpncpy, u32_stpncpy): Make the
104083         description of the return value consistent with stpncpy in glibc.
104084         * lib/unistr/u-stpncpy.h (FUNC): Return the pointer past the last
104085         written non-NUL unit.
104087 2010-01-10  Bruno Haible  <bruno@clisp.org>
104089         unistr/u*-next: Add missing dependencies.
104090         * modules/unistr/u8-next (Depends-on): Add unistr/u8-strmbtouc.
104091         * modules/unistr/u16-next (Depends-on): Add unistr/u16-strmbtouc.
104092         * modules/unistr/u32-next (Depends-on): Add unistr/u32-strmbtouc.
104094 2010-01-10  Bruno Haible  <bruno@clisp.org>
104096         unistr/u8-mbsnlen: Fix return value for incomplete character.
104097         * lib/unistr/u8-mbsnlen.c (u8_mbsnlen): Use u8_mbtoucr instead of
104098         u8_mblen.
104099         * modules/unistr/u8-mbsnlen (Depends-on): Add unistr/u8-mbtoucr.
104100         Remove unistr/u8-mblen.
104101         * lib/unistr/u16-mbsnlen.c (u16_mbsnlen): Use u16_mbtoucr instead of
104102         u16_mblen.
104103         * modules/unistr/u16-mbsnlen (Depends-on): Add unistr/u16-mbtoucr.
104104         Remove unistr/u16-mblen.
104106 2010-01-10  Bruno Haible  <bruno@clisp.org>
104108         wchar: Fix compilation error when <wchar.h> is used from coreutils.
104109         * lib/wchar.in.h: Treat __need_wint_t like __need_mbstate_t.
104110         Reported by Brian Gough <bjg@gnu.org> and
104111         Chris Clayton <chris2553@googlemail.com> via
104112         Mike Frysinger <vapier@gentoo.org> and Jim Meyering <jim@meyering.net>.
104114 2010-01-09  Bruno Haible  <bruno@clisp.org>
104116         unistr/u16-to-u32: Reject invalid input.
104117         * lib/unistr/u16-to-u32.c (u16_to_u32): Call u16_mbtoucr instead of
104118         u16_mbtouc.
104119         * modules/unistr/u16-to-u32 (Depends-on): Add unistr/u16-mbtoucr.
104120         Remove unistr/u16-mbtouc.
104122         unistr/u16-to-u8: Reject invalid input.
104123         * lib/unistr/u16-to-u8.c (u16_to_u8): Call u16_mbtoucr instead of
104124         u16_mbtouc.
104125         * modules/unistr/u16-to-u8 (Depends-on): Add unistr/u16-mbtoucr.
104126         Remove unistr/u16-mbtouc.
104128         unistr/u8-to-u32: Reject invalid input.
104129         * lib/unistr/u8-to-u32.c (u8_to_u32): Call u8_mbtoucr instead of
104130         u8_mbtouc.
104131         * modules/unistr/u8-to-u32 (Depends-on): Add unistr/u8-mbtoucr.
104132         Remove unistr/u8-mbtouc.
104134         unistr/u8-to-u16: Reject invalid input.
104135         * lib/unistr/u8-to-u16.c (u8_to_u16): Call u8_mbtoucr instead of
104136         u8_mbtouc.
104137         * modules/unistr/u8-to-u16 (Depends-on): Add unistr/u8-mbtoucr.
104138         Remove unistr/u8-mbtouc.
104140 2010-01-09  Bruno Haible  <bruno@clisp.org>
104142         Tests for module 'getlogin'.
104143         * modules/getlogin-tests: New file.
104144         * tests/test-getlogin.c: New file.
104146         New module 'getlogin'.
104147         * lib/unistd.in.h (getlogin): New declaration.
104148         * lib/getlogin.c: New file.
104149         * m4/getlogin.m4: New file.
104150         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETLOGIN,
104151         HAVE_GETLOGIN.
104152         * modules/unistd (Makefile.am): Substitute GNULIB_GETLOGIN,
104153         HAVE_GETLOGIN.
104154         * modules/getlogin: New file.
104155         * doc/posix-functions/getlogin.texi: Mention the new module.
104156         Reported by John W. Eaton <jwe@gnu.org>.
104158 2010-01-09  Bruno Haible  <bruno@clisp.org>
104160         getlogin_r: Support for native Windows.
104161         * lib/getlogin_r.c: Include <windows.h>
104162         (getlogin_r): Implement for native Windows.
104163         * tests/test-getlogin_r.c (main): Also test with a huge buffer.
104164         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>
104165         via John W. Eaton <jwe@gnu.org>.
104167 2010-01-09  Bruno Haible  <bruno@clisp.org>
104169         getlogin_r: Small fixes.
104170         * lib/getlogin_r.c (getlogin_r): Don't set errno if the function
104171         succeeds.
104172         * m4/getlogin_r.m4 (gl_GETLOGIN_R): Require gl_USE_SYSTEM_EXTENSIONS
104173         before testing whether getlogin_r is declared. No need to set
104174         HAVE_DECL_GETLOGIN_R to 1.
104175         (gl_PREREQ_GETLOGIN_R): Don't check for the getlogin_r declaration.
104177 2010-01-09  Bruno Haible  <bruno@clisp.org>
104179         * lib/unistd.in.h (getlogin_r): Add comment.
104181 2010-01-09  Bruno Haible  <bruno@clisp.org>
104183         Tests for module 'getlogin_r'.
104184         * modules/getlogin_r-tests: New file.
104185         * tests/test-getlogin_r.c: New file.
104187 2010-01-09  Jim Meyering  <meyering@redhat.com>
104189         maint.mk: extend proper_name_utf8-vs-LIBICONV-checking rule
104190         * top/maint.mk (sc_proper_name_utf8_requires_ICONV): Adapt to work
104191         also when $(LIBICONV) is part of LDADD, rather than ${prog}_LDADD.
104193 2010-01-08  Simon Josefsson  <simon@josefsson.org>
104195         * lib/dup2.c (rpl_dup2): Improve comment.
104197 2010-01-08  Eric Blake  <ebb9@byu.net>
104199         maint.mk: allow packages to add makefile @@ exceptions
104200         * top/maint.mk (_makefile_at_at_check_exceptions): New hook.
104201         (sc_makefile_check): Rename...
104202         (sc_makefile_at_at_check): ...to this, and use hook.
104204         dup2: work around mingw bug
104205         * lib/dup2.c (rpl_dup2): Sanitize return value on mingw.
104206         Reported by Simon Josefsson.
104208 2010-01-07  John W. Eaton  <jwe@octave.org>  (tiny change)
104210         glob: Fix C++ compilation.
104211         * lib/glob.in.h [__cplusplus]: Define __BEGIN_DECLS and __END_DECLS for
104212         C++.
104214 2010-01-07  Bruno Haible  <bruno@clisp.org>
104216         Fix indentation of wctype.in.h, broken since 2007-01-06.
104217         * lib/wctype.in.h: Fix indentation of preprocessor directives.
104219 2010-01-07  Bruno Haible  <bruno@clisp.org>
104221         mbslen: Avoid collision with system function.
104222         * lib/string.in.h [MirBSD]: Include <wchar.h>.
104223         (mbslen): Undefine first. Alias mbslen to rpl_mbslen.
104224         * m4/mbslen.m4: New file.
104225         * modules/mbslen (Files): Add it.
104226         (configure.ac): Invoke gl_MBSLEN.
104227         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize HAVE_MBSLEN.
104228         * modules/string (Makefile.am): Substitute HAVE_MBSLEN.
104229         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>
104230         via Ian Beckwith <ianb@erislabs.net>.
104232 2010-01-07  Bruno Haible  <bruno@clisp.org>
104234         dirent: Document the last fix.
104235         * doc/posix-headers/dirent.texi: Document the bug of missing 'ino_t'.
104237 2010-01-07  Bruno Haible  <bruno@clisp.org>
104239         stdio: Ensure <stdio.h> defines off_t, ssize_t, va_list.
104240         * lib/stdio.in.h: Include <sys/types.h> unconditionally.
104241         * tests/test-stdio.c: Verify that fpos_t, off_t, size_t, ssize_t,
104242         va_list are defined.
104243         * doc/posix-headers/stdio.texi: Document the bug of missing types.
104244         Reported by Eric Blake.
104246 2010-01-07  Bruno Haible  <bruno@clisp.org>
104248         xlist, xoset: Fix missing dependency bug, introduced on 2009-12-13.
104249         * modules/xlist (Depends-on): Add 'list',
104250         * modules/xoset (Depends-on): Add 'oset'.
104251         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
104253 2010-01-07  Bruno Haible  <bruno@clisp.org>
104255         * doc/posix-functions/strcasecmp.texi: Clarify the platforms.
104256         * doc/posix-functions/strncasecmp.texi: Likewise.
104258 2010-01-07  Bruno Haible  <bruno@clisp.org>
104260         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Simplify logic.
104262 2010-01-07  John W. Eaton  <jwe@octave.org>
104264         wctype: allow C++ use
104265         * lib/wctype.in.h: Add extern "C" block for C++.
104267 2010-01-06  Eric Blake  <ebb9@byu.net>
104269         maint.mk: detect incorrect GFDL usage
104270         * top/maint.mk (_GFDL_regexp, sc_GFDL_version): New rule.
104272 2010-01-06  Jim Meyering  <meyering@redhat.com>
104273         and Eric Blake  <ebb9@byu.net>
104275         maint.mk: ignore multi-line copyright in NEWS
104276         * top/maint.mk (NEWS_hash): Add immunity to multi-line copyright.
104278 2010-01-06  Eric Blake  <ebb9@byu.net>
104280         select: add missing dependency
104281         * modules/select-tests (Depends-on): Move sockets dependency...
104282         * modules/select (Depends-on): ...here.
104283         Reported by Ian Beckwith.
104285         doc: regenerate INSTALL
104286         * doc/INSTALL: Reflect recent autoconf update.
104287         * doc/INSTALL.ISO: Likewise.
104288         * doc/INSTALL.UTF-8: Likewise.
104290         pread: fix compilation on glibc
104291         * m4/pread.m4 (gl_FUNC_PREAD): Request all interfaces.
104292         Reported by Ralf Wildenhues.
104294         dirent: fix test failure
104295         * lib/dirent.in.h (includes): Guarantee ino_t.
104296         Reported by Ralf Wildenhues.
104298 2010-01-06  Petr Salinger  <Petr.Salinger@seznam.cz>  (tiny change)
104300         linkat, renameat: avoid bad free
104301         * lib/at-func2.c (at_func2): Fix typo.
104302         Reported via Ian Beckwith, from http://bugs.debian.org/561117.
104304 2010-01-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
104306         cleanup after gl_FUNC_READLINK, for gl_FUNC_SYMLINK test
104307         * m4/readlink.m4 (gl_FUNC_READLINK): Remove conftest.lnk2,
104308         to avoid failure of symlink test later.
104310 2010-01-06  Eric Blake  <ebb9@byu.net>
104312         stdio, unistd: guarantee ssize_t
104313         * lib/unistd.in.h (includes): Ensure that types required by POSIX
104314         2008 are exposed when needed.
104315         * lib/stdio.in.h (includes): Likewise.
104316         Reported by Ralf Wildenhues.
104318 2010-01-06  Paolo Bonzini  <bonzini@gnu.org>
104320         nl_langinfo: do not call AC_CHECK_FUNC_ONCE inside if.
104321         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Do not call
104322         AC_CHECK_FUNC_ONCE inside if, do not adjust ac_cv_func_nl_langinfo.
104324 2010-01-06  Jim Meyering  <meyering@redhat.com>
104326         readtokens: this module *does* require xalloc.h
104327         It uses only functions that were omitted by the old syntax-check rule.
104328         * lib/readtokens.c: Include "xalloc.h" once again.
104329         * modules/readtokens (Depends-on): Add xalloc.
104330         This reverts part of 0e0f8f12ec241c0f1c1f21f960bb5cf908a0fa3c.
104332 2010-01-05  Eric Blake  <ebb9@byu.net>
104334         maint: support 'make announcement' from a VPATH build
104335         * top/maint.mk (announcement): Look for correct NEWS file.
104337 2010-01-05  Aurelien Jarno  <aurelien@aurel32.net>  (tiny change)
104339         utimens (fdutimens): ignore a negative FD, per contract
104340         * lib/utimens.c (fdutimens) [HAVE_FUTIMENS]: Call futimens only
104341         when we have a valid file descriptor.  Otherwise, using a brand
104342         new glibc (with just-patched futimens that now fails with EBADF)
104343         would cause this function to fail with ENOSYS.
104344         Reported by Guillaume Ayoub in http://bugs.debian.org/563726.
104345         See also http://bugzilla.redhat.com/552320.
104347 2010-01-05  Eric Blake  <ebb9@byu.net>
104349         strcase: document what it provides
104350         * doc/posix-functions/strcasecmp.texi (strcasecmp): Mention the
104351         gnulib module.
104352         * doc/posix-functions/strncasecmp.texi (strncasecmp): Likewise.
104353         Reported by Dilyan Palauzov <Dilyan.Palauzov@aegee.org>.
104355 2010-01-05  Jim Meyering  <meyering@redhat.com>
104357         maint: remove useless inclusions of "xalloc.h"
104358         * lib/getloadavg.c: Remove useless inclusion of "xalloc.h".
104359         * lib/readtokens.c: Likewise.
104360         * lib/same.c: Likewise.
104361         * modules/getloadavg (Depends-on): Remove xalloc.
104362         * modules/readtokens: Likewise.
104363         * modules/same: Likewise.
104365         maint.mk: include 4 more function names in alloca.h-checking regexp
104366         * top/maint.mk (sc_prohibit_xalloc_without_use): Use more complete
104367         regexp.  Before, we would give a false-positive (saying alloca.h
104368         is included unnecessarily) when the only uses involved omitted symbols.
104370         xalloc.h: use consistent formatting
104371         * lib/xalloc.h: Move declarations to start in the first column.
104373 2010-01-05  Eric Blake  <ebb9@byu.net>
104375         mkdir: avoid xalloc
104376         * lib/mkdir.c (includes): Drop unused header.
104377         Reported by John W. Eaton.
104379 2010-01-04  Jim Meyering  <meyering@redhat.com>
104381         nl_langinfo: avoid configure-time syntax error
104382         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): When we've already tested
104383         for nl_langinfo.h, AC_CHECK_FUNCS_ONCE([nl_langinfo]) expands to
104384         the empty string.  Don't let that provoke a shell syntax error.
104386         regcomp, regexec, fnmatch: avoid array bounds read error
104387         * lib/regcomp.c (build_equiv_class): From glibc:
104388         Use only the low 24 bits of a findidx return value as an index
104389         into the weights array.  Patch by Ulrich Drepper:
104390         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commit;h=b7d1c5fa30
104391         * lib/regexec.c (check_node_accept_bytes): Likewise.
104392         * lib/fnmatch_loop.c (FCT): Likewise.
104394         regcomp: skip collseq lookup when there are no rules
104395         * lib/regcomp.c (lookup_collation_sequence_value): From glibc:
104396         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a532a41df58
104398         regcomp: recognize ill-formed { } expressions
104399         * lib/regcomp.c (parse_dup_op): From glibc:
104400         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a87cd2894cb
104402         regcomp: fix typo in comment
104403         * lib/regcomp.c (duplicate_node_closure): Sync from glibc.
104404         s/satisfy/satisfies/.
104406         regcomp: sync from glibc: remove dead store
104407         * lib/regcomp.c (duplicate_node_closure): Remove useless
104408         search_duplicated_node call and dead store.
104410         regcomp: sync from glibc; always use nl_langinfo
104411         * lib/regcomp.c (init_dfa) [!LIBC]: Always use nl_langinfo (CODESET),
104412         now that gnulib provides it.  Recognize UTF8 as well as UTF-8.
104413         * modules/regex (Depends-on): Add nl_langinfo.
104415 2010-01-04  Eric Blake  <ebb9@byu.net>
104417         fdopendir: fix configure test
104418         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for existing file.
104420 2010-01-01  Bruno Haible  <bruno@clisp.org>
104422         wchar: Remove unused configure check.
104423         * m4/wchar.m4 (gl_WCHAR_H): Don't test whether <wchar.h> is standalone.
104425 2010-01-01  Eric Blake  <ebb9@byu.net>
104427         headers: make check of system header explicit
104428         * m4/netdb_h.m4 (gl_HEADER_NETDB): Don't exploit knowledge of
104429         gl_CHECK_NEXT_HEADER internals, but call AC_CHECK_HEADERS_ONCE
104430         ourselves.
104431         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
104432         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
104433         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
104434         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise, for gt_INTTYPES_PRI
104435         internals.
104436         * m4/wchar.m4 (gl_WCHAR_H): Skip followup test if header is
104437         missing.
104438         Suggested by Bruno Haible.
104440 2010-01-01  Jim Meyering  <meyering@redhat.com>
104442         ChangeLog: tweak to eliminate unnecessary copyright line
104443         * ChangeLog: Remove a copyright line that was mistakenly updated
104444         by today's update-copyright run.  Reported by Eric Blake.
104446         test-update-copyright: don't let envvar setting cause test failure
104447         * tests/test-update-copyright.sh: Set UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
104449 2010-01-01  Bruno Haible  <bruno@clisp.org>
104451         localename: Avoid gcc warning.
104452         * lib/localename.c (gl_locale_name_thread_unsafe): Don't define this
104453         function if it is not used.
104455 2010-01-01  Jim Meyering  <meyering@redhat.com>
104457         update nearly all FSF copyright year lists to include 2010
104458         Use the same procedure as for 2009, outlined in
104459         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/20081
104461         version-etc: set COPYRIGHT_YEAR to 2010
104462         * lib/version-etc.c (COPYRIGHT_YEAR): Manually update the enum.
104464 2009-12-31  Eric Blake  <ebb9@byu.net>
104466         doc: correct availability of cygwin 1.5.x getopt
104467         * doc/posix-functions/optarg.texi (optarg): Cygwin supplies getopt
104468         variables.
104469         * doc/posix-functions/opterr.texi (opterr): Likewise.
104470         * doc/posix-functions/optind.texi (optind): Likewise.
104471         * doc/posix-functions/optopt.texi (optopt): Likewise.
104472         * doc/posix-functions/tzname.texi (tzname): Likewise.
104474         openat: update maintainer
104475         * modules/openat (Maintainer): Add myself.
104477         utimens: avoid shadowing warning
104478         * lib/utimens.c (fdutimens, lutimens): Consolidate separate stat
104479         buffers into one, to avoid shadowing, as well as avoiding a
104480         redundant stat.
104481         Reported by Jim Meyering.
104483         test-dup2: avoid compiler warning
104484         * tests/test-dup2.c (is_inheritable): Only define if used.
104486 2010-01-01  Bruno Haible  <bruno@clisp.org>
104488         vasnprintf: Avoid passing an 'rpl_mbstate_t *' to the system's wcrtomb.
104489         * lib/vasnprintf.c (VASNPRINTF): If GNULIB_defined_mbstate_t is
104490         defined, use wctomb instead of wcrtomb.
104492 2010-01-01  Bruno Haible  <bruno@clisp.org>
104494         iconv: Reject native Solaris iconv.
104495         * m4/iconv.m4 (AM_ICONV_LINK): Recognize native Solaris iconv() bug.
104496         * doc/posix-functions/iconv.texi: Document native Solaris iconv() bug.
104498 2009-12-31  Bruno Haible  <bruno@clisp.org>
104500         * tests/test-signal.c (main): Remove test of 'SIG'.
104502 2009-12-31  Bruno Haible  <bruno@clisp.org>
104504         spawn: Fix incomplete fix.
104505         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
104506         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
104507         warnings for GNULIB_POSIXCHECK again.
104508         Reported by Eric Blake.
104510 2009-12-31  Bruno Haible  <bruno@clisp.org>
104512         Avoid namespace pollution on glibc systems.
104513         * lib/spawn.in.h: Don't include <sched.h>, <signal.h> on glibc systems.
104514         * lib/sys_times.in.h: Don't include <time.h> on glibc systems.
104515         * lib/wchar.in.h: Don't include <stddef.h>, <stdio.h>, <time.h> on
104516         glibc systems.
104518 2009-12-31  Bruno Haible  <bruno@clisp.org>
104520         * m4/wchar.m4 (gl_WCHAR_H): Remove gl_STDDEF_H invocation.
104521         (gl_REPLACE_WCHAR_H): Turn into a no-op.
104522         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Likewise.
104523         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H): Likewise.
104524         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H): Likewise.
104525         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H): Likewise.
104526         * m4/sys_ioctl_h.m4 (gl_REPLACE_SYS_IOCTL_H): Likewise.
104528 2009-12-31  Bruno Haible  <bruno@clisp.org>
104530         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Invoke
104531         gl_CHECK_NEXT_HEADERS before testing ac_cv_header_sys_select_h, not
104532         afterwards.
104534 2009-12-31  Bruno Haible  <bruno@clisp.org>
104536         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H_DEFAULTS): Don't set
104537         SYS_UTSNAME_H.
104539 2009-12-31  Bruno Haible  <bruno@clisp.org>
104541         spawn: Fix misapplied patch.
104542         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
104543         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
104544         warnings for GNULIB_POSIXCHECK.
104546 2009-12-31  Bruno Haible  <bruno@clisp.org>
104548         times: Update after sys_times changed.
104549         * m4/times.m4: New file, extracted from modules/times. Set HAVE_TIMES.
104550         * modules/times (Files): Add it.
104551         (configure.ac): Invoke gl_FUNC_TIMES.
104553 2009-12-31  Bruno Haible  <bruno@clisp.org>
104555         Use AC_C_INLINE where necessary.
104556         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Require AC_C_INLINE.
104557         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
104558         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
104559         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
104560         * m4/mbfile.m4 (gl_MBFILE): Likewise.
104561         * m4/mbiter.m4 (gl_MBITER): Likewise.
104562         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
104563         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
104564         * m4/wait-process.m4 (gl_WAIT_PROCESS): Likewise.
104565         * modules/u64 (configure.ac): Likewise.
104567 2009-12-31  Bruno Haible  <bruno@clisp.org>
104569         Use AC_C_INLINE instead of module 'inline' where possible.
104570         * modules/inline (Description): Clarify purpose.
104571         * m4/count-one-bits.m4 (gl_COUNT_ONE_BITS): Require AC_C_INLINE.
104572         * modules/count-one-bits (Depends-on): Remove inline.
104573         * m4/openat.m4 (gl_PREREQ_OPENAT): Require AC_C_INLINE.
104574         * modules/openat (Depends-on): Remove inline.
104575         * modules/fdutimensat (Depends-on, configure.ac): Require AC_C_INLINE
104576         instead of depending on module 'inline'.
104577         * modules/filevercmp (Depends-on, configure.ac): Likewise.
104578         * modules/unicase/cased (Depends-on, configure.ac): Likewise.
104579         * modules/unicase/ignorable (Depends-on, configure.ac): Likewise.
104580         * modules/unictype/category-of (Depends-on, configure.ac): Likewise.
104581         * modules/unictype/category-test (Depends-on, configure.ac): Likewise.
104582         * modules/unictype/ctype-alnum (Depends-on, configure.ac): Likewise.
104583         * modules/unictype/ctype-alpha (Depends-on, configure.ac): Likewise.
104584         * modules/unictype/ctype-blank (Depends-on, configure.ac): Likewise.
104585         * modules/unictype/ctype-cntrl (Depends-on, configure.ac): Likewise.
104586         * modules/unictype/ctype-digit (Depends-on, configure.ac): Likewise.
104587         * modules/unictype/ctype-graph (Depends-on, configure.ac): Likewise.
104588         * modules/unictype/ctype-lower (Depends-on, configure.ac): Likewise.
104589         * modules/unictype/ctype-print (Depends-on, configure.ac): Likewise.
104590         * modules/unictype/ctype-punct (Depends-on, configure.ac): Likewise.
104591         * modules/unictype/ctype-space (Depends-on, configure.ac): Likewise.
104592         * modules/unictype/ctype-upper (Depends-on, configure.ac): Likewise.
104593         * modules/unictype/ctype-xdigit (Depends-on, configure.ac): Likewise.
104594         * modules/unictype/property-alphabetic (Depends-on, configure.ac):
104595         Likewise.
104596         * modules/unictype/property-ascii-hex-digit (Depends-on,
104597         configure.ac): Likewise.
104598         * modules/unictype/property-bidi-arabic-digit (Depends-on,
104599         configure.ac): Likewise.
104600         * modules/unictype/property-bidi-arabic-right-to-left (Depends-on,
104601         configure.ac): Likewise.
104602         * modules/unictype/property-bidi-block-separator (Depends-on,
104603         configure.ac): Likewise.
104604         * modules/unictype/property-bidi-boundary-neutral (Depends-on,
104605         configure.ac): Likewise.
104606         * modules/unictype/property-bidi-common-separator (Depends-on,
104607         configure.ac): Likewise.
104608         * modules/unictype/property-bidi-control (Depends-on, configure.ac):
104609         Likewise.
104610         * modules/unictype/property-bidi-embedding-or-override (Depends-on,
104611         configure.ac): Likewise.
104612         * modules/unictype/property-bidi-eur-num-separator (Depends-on,
104613         configure.ac): Likewise.
104614         * modules/unictype/property-bidi-eur-num-terminator (Depends-on,
104615         configure.ac): Likewise.
104616         * modules/unictype/property-bidi-european-digit (Depends-on,
104617         configure.ac): Likewise.
104618         * modules/unictype/property-bidi-hebrew-right-to-left (Depends-on,
104619         configure.ac): Likewise.
104620         * modules/unictype/property-bidi-left-to-right (Depends-on,
104621         configure.ac): Likewise.
104622         * modules/unictype/property-bidi-non-spacing-mark (Depends-on,
104623         configure.ac): Likewise.
104624         * modules/unictype/property-bidi-other-neutral (Depends-on,
104625         configure.ac): Likewise.
104626         * modules/unictype/property-bidi-pdf (Depends-on, configure.ac):
104627         Likewise.
104628         * modules/unictype/property-bidi-segment-separator (Depends-on,
104629         configure.ac): Likewise.
104630         * modules/unictype/property-bidi-whitespace (Depends-on,
104631         configure.ac): Likewise.
104632         * modules/unictype/property-combining (Depends-on, configure.ac):
104633         Likewise.
104634         * modules/unictype/property-composite (Depends-on, configure.ac):
104635         Likewise.
104636         * modules/unictype/property-currency-symbol (Depends-on,
104637         configure.ac): Likewise.
104638         * modules/unictype/property-dash (Depends-on, configure.ac): Likewise.
104639         * modules/unictype/property-decimal-digit (Depends-on, configure.ac):
104640         Likewise.
104641         * modules/unictype/property-default-ignorable-code-point (Depends-on,
104642         configure.ac): Likewise.
104643         * modules/unictype/property-deprecated (Depends-on, configure.ac):
104644         Likewise.
104645         * modules/unictype/property-diacritic (Depends-on, configure.ac):
104646         Likewise.
104647         * modules/unictype/property-extender (Depends-on, configure.ac):
104648         Likewise.
104649         * modules/unictype/property-format-control (Depends-on, configure.ac):
104650         Likewise.
104651         * modules/unictype/property-grapheme-base (Depends-on, configure.ac):
104652         Likewise.
104653         * modules/unictype/property-grapheme-extend (Depends-on, configure.ac):
104654         Likewise.
104655         * modules/unictype/property-grapheme-link (Depends-on, configure.ac):
104656         Likewise.
104657         * modules/unictype/property-hex-digit (Depends-on, configure.ac):
104658         Likewise.
104659         * modules/unictype/property-hyphen (Depends-on, configure.ac):
104660         Likewise.
104661         * modules/unictype/property-id-continue (Depends-on, configure.ac):
104662         Likewise.
104663         * modules/unictype/property-id-start (Depends-on, configure.ac):
104664         Likewise.
104665         * modules/unictype/property-ideographic (Depends-on, configure.ac):
104666         Likewise.
104667         * modules/unictype/property-ids-binary-operator (Depends-on,
104668         configure.ac): Likewise.
104669         * modules/unictype/property-ids-trinary-operator (Depends-on,
104670         configure.ac): Likewise.
104671         * modules/unictype/property-ignorable-control (Depends-on,
104672         configure.ac): Likewise.
104673         * modules/unictype/property-iso-control (Depends-on, configure.ac):
104674         Likewise.
104675         * modules/unictype/property-join-control (Depends-on, configure.ac):
104676         Likewise.
104677         * modules/unictype/property-left-of-pair (Depends-on, configure.ac):
104678         Likewise.
104679         * modules/unictype/property-line-separator (Depends-on, configure.ac):
104680         Likewise.
104681         * modules/unictype/property-logical-order-exception (Depends-on,
104682         configure.ac): Likewise.
104683         * modules/unictype/property-lowercase (Depends-on, configure.ac):
104684         Likewise.
104685         * modules/unictype/property-math (Depends-on, configure.ac): Likewise.
104686         * modules/unictype/property-non-break (Depends-on, configure.ac):
104687         Likewise.
104688         * modules/unictype/property-not-a-character (Depends-on, configure.ac):
104689         Likewise.
104690         * modules/unictype/property-numeric (Depends-on, configure.ac):
104691         Likewise.
104692         * modules/unictype/property-other-alphabetic (Depends-on,
104693         configure.ac): Likewise.
104694         * modules/unictype/property-other-default-ignorable-code-point
104695         (Depends-on, configure.ac): Likewise.
104696         * modules/unictype/property-other-grapheme-extend (Depends-on,
104697         configure.ac): Likewise.
104698         * modules/unictype/property-other-id-continue (Depends-on,
104699         configure.ac): Likewise.
104700         * modules/unictype/property-other-id-start (Depends-on, configure.ac):
104701         Likewise.
104702         * modules/unictype/property-other-lowercase (Depends-on, configure.ac):
104703         Likewise.
104704         * modules/unictype/property-other-math (Depends-on, configure.ac):
104705         Likewise.
104706         * modules/unictype/property-other-uppercase (Depends-on, configure.ac):
104707         Likewise.
104708         * modules/unictype/property-paired-punctuation (Depends-on,
104709         configure.ac): Likewise.
104710         * modules/unictype/property-paragraph-separator (Depends-on,
104711         configure.ac): Likewise.
104712         * modules/unictype/property-pattern-syntax (Depends-on, configure.ac):
104713         Likewise.
104714         * modules/unictype/property-pattern-white-space (Depends-on,
104715         configure.ac): Likewise.
104716         * modules/unictype/property-private-use (Depends-on, configure.ac):
104717         Likewise.
104718         * modules/unictype/property-punctuation (Depends-on, configure.ac):
104719         Likewise.
104720         * modules/unictype/property-quotation-mark (Depends-on, configure.ac):
104721         Likewise.
104722         * modules/unictype/property-radical (Depends-on, configure.ac):
104723         Likewise.
104724         * modules/unictype/property-sentence-terminal (Depends-on,
104725         configure.ac): Likewise.
104726         * modules/unictype/property-soft-dotted (Depends-on, configure.ac):
104727         Likewise.
104728         * modules/unictype/property-space (Depends-on, configure.ac): Likewise.
104729         * modules/unictype/property-terminal-punctuation (Depends-on,
104730         configure.ac): Likewise.
104731         * modules/unictype/property-titlecase (Depends-on, configure.ac):
104732         Likewise.
104733         * modules/unictype/property-unassigned-code-value (Depends-on,
104734         configure.ac): Likewise.
104735         * modules/unictype/property-unified-ideograph (Depends-on,
104736         configure.ac): Likewise.
104737         * modules/unictype/property-uppercase (Depends-on, configure.ac):
104738         Likewise.
104739         * modules/unictype/property-variation-selector (Depends-on,
104740         configure.ac): Likewise.
104741         * modules/unictype/property-white-space (Depends-on, configure.ac):
104742         Likewise.
104743         * modules/unictype/property-xid-continue (Depends-on, configure.ac):
104744         Likewise.
104745         * modules/unictype/property-xid-start (Depends-on, configure.ac):
104746         Likewise.
104747         * modules/unictype/property-zero-width (Depends-on, configure.ac):
104748         Likewise.
104749         * modules/unictype/syntax-c-ident (Depends-on, configure.ac): Likewise.
104750         * modules/unictype/syntax-java-ident (Depends-on, configure.ac):
104751         Likewise.
104753 2009-12-31  Bruno Haible  <bruno@clisp.org>
104755         Remove unnecessary AC_C_INLINE invocation.
104756         * m4/popen.m4 (gl_PREREQ_POPEN): Don't invoke AC_C_INLINE. Not needed
104757         since 2009-08-21.
104759 2009-12-31  Jim Meyering  <meyering@redhat.com>
104761         maint.mk: don't require explicit gpg_key_ID in cfg.mk
104762         * top/maint.mk (gpg_key_ID): Derive key ID from signed release tag.
104763         With this change, we can all remove the gpg_key_ID = ... definition
104764         from our respective cfg.mk files.
104766         maint.mk: create announcement template in ~/, not in /tmp
104767         * top/maint.mk (emit_upload_commands): Adjust.
104768         (release-prep): Emit into ~/announce-..., not /tmp/announce-...
104769         Remove temporary file, .ci-msg.
104771 2009-12-31  Eric Blake  <ebb9@byu.net>
104773         link-warning: always build headers with link warnings
104774         * modules/arpa_inet (Makefile.am): Always build replacement
104775         header.
104776         * modules/ctype (Makefile.am): Likewise.
104777         * modules/dirent (Makefile.am): Likewise.
104778         * modules/inttypes (Makefile.am): Likewise.
104779         * modules/langinfo (Makefile.am): Likewise.
104780         * modules/locale (Makefile.am): Likewise.
104781         * modules/spawn (Makefile.am): Likewise.
104782         * modules/sys_file (Makefile.am): Likewise.
104783         * modules/sys_ioctl (Makefile.am): Likewise.
104784         * modules/sys_select (Makefile.am): Likewise.
104785         * modules/sys_socket (Makefile.am): Likewise.
104786         * modules/sys_times (Makefile.am): Likewise.
104787         * modules/sys_utsname (Makefile.am): Likewise.
104788         * modules/sys_wait (Makefile.am): Likewise.
104789         * modules/wchar (Makefile.am): Likewise.
104790         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET)
104791         (gl_ARPA_INET_H_DEFAULTS): Drop unneeded variable.
104792         * m4/ctype.m4 (gl_CTYPE_H_DEFAULTS): Likewise.
104793         * m4/isblank.m4 (gl_FUNC_ISBLANK): Likewise.
104794         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H, gl_DIRENT_H_DEFAULTS):
104795         Likewise.
104796         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
104797         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
104798         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_H_DEFAULTS):
104799         Likewise.
104800         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H, gl_SPAWN_H_DEFAULTS):
104801         Likewise.
104802         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Likewise.
104803         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H, gl_REPLACE_SYS_IOCTL_H)
104804         (gl_SYS_IOCTL_H_DEFAULTS): Likewise.
104805         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
104806         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
104807         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
104808         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
104809         * m4/wchar.m4 (gl_WCHAR_H, gl_REPLACE_WCHAR_H)
104810         (gl_WCHAR_H_DEFAULTS): Likewise.
104812 2009-12-31  Eric Blake  <ebb9@byu.net>
104814         signal, spawn: use link warnings
104815         * lib/signal.in.h (sigset_t): Make unconditional.
104816         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset)
104817         (sigpending, sigprocmask, sigaction): Add link warnings.
104818         * lib/spawn.in.h (posix_spawn, posix_spawnp, posix_spawnattr_init)
104819         (posix_spawnattr_destroy, posix_spawnattr_getsigdefault)
104820         (posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask)
104821         (posix_spawnattr_setsigmask, posix_spawnattr_getflags)
104822         (posix_spawnattr_setflags, posix_spawnattr_getpgroup)
104823         (posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy)
104824         (posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam)
104825         (posix_spawnattr_setschedparam, posix_spawn_file_actions_init)
104826         (posix_spawn_file_actions_destroy)
104827         (posix_spawn_file_actions_addopen)
104828         (posix_spawn_file_actions_addclose)
104829         (posix_spawn_file_actions_adddup2): Likewise.
104830         * m4/signal_h.m4 (gl_SIGNAL_H): Guarantee uid_t.
104831         * tests/test-signal.c (main): Enhance test.
104833         spawn: improve wrapper support
104834         * m4/spawn_h.m4 (gl_SPAWN_H): Check for type existence.
104835         (gl_SPAWN_H_DEFAULTS): New defaults.
104836         * modules/spawn (Makefile.am): Substitute them.
104837         * lib/spawn.in.h: (posix_spawnattr_t, posix_spawn_file_actions_t):
104838         Only declare if missing or broken.
104840         sys_times, sys_utsname: use include_next
104841         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Support wrapping an existing
104842         header.
104843         (gl_SYS_TIMES_H_DEFAULTS): Add another variable.
104844         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
104845         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
104846         * modules/sys_times (Depends-on): Add include_next.
104847         (Makefile.am): Substitute additional values.
104848         * modules/sys_utsname (Depends-on, Makefile.am): Likewise.
104849         * lib/sys_times.in.h (includes): Include native header, if
104850         available.
104851         * lib/sys_utsname.in.h (includes): Likewise.
104852         * tests/test-sys_times.c (main): Enhance test.
104854         fdutimensat: revert prior patch
104855         * modules/fdutimensat (Depends-on): Re-add inline; it is needed by
104856         utimens.h.
104857         Reported by Bruno Haible.
104859 2009-12-30  Eric Blake  <ebb9@byu.net>
104861         sys_wait: drop link-warning dependency
104862         * modules/sys_wait (Depends-on, Makefile.am): Drop unneeded
104863         link-warning efforts.
104864         * lib/sys_wait.in.h: Likewise.
104866         fdutimensat: remove bogus dependency
104867         * modules/fdutimensat (Depends-on): Drop inline.
104869         unistd: fix typo
104870         * lib/unistd.in.h (linkat) [GNULIB_POSIXCHECK]: Fix typo.
104872 2009-12-30  Bruno Haible  <bruno@clisp.org>
104874         Fix compilation error with Solaris cc.
104875         * lib/unicase/u8-is-invariant.c: Include <stdbool.h>.
104876         * lib/unicase/u16-is-invariant.c: Likewise.
104877         * lib/unicase/u32-is-invariant.c: Likewise.
104878         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
104880 2009-12-30  Bruno Haible  <bruno@clisp.org>
104882         Fix test crash.
104883         * tests/test-localename.c (test_locale_name_thread): Skip unavailable
104884         locales.
104885         Reported by Simon Josefsson <simon@josefsson.org>.
104887 2009-12-30  Bruno Haible  <bruno@clisp.org>
104889         Fix compilation error on most platforms.
104890         * tests/test-localename.c (categories): Define only if HAVE_NEWLOCALE.
104891         Reported by Simon Josefsson <simon@josefsson.org>
104892         and Nelson H. F. Beebe <beebe@math.utah.edu>.
104894 2009-12-30  Eric Blake  <ebb9@byu.net>
104896         futimens, utimensat: work around ntfs-3g bug
104897         * lib/utimensat.c (rpl_utimensat): Drop attempts to cache whether
104898         a ctime bug is present, and expand workaround to cover ntfs-3g.
104899         * lib/utimens.c (fdutimens, lutimens): Likewise.
104900         (utimensat_ctime_really, detect_ctime_bug): Drop cache mechanism.
104901         (validate_timespec): Adjust return value.
104902         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Update comment.
104903         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
104904         Reported by ctrn3e8 <ctrn3e8@gmail.com>.
104906 2009-12-29  Eric Blake  <ebb9@byu.net>
104908         link-warning: make usage consistent
104909         * modules/ctype (Depends-on): Add link-warning.
104910         (Makefile.am): Update rules accordingly.
104911         * modules/langinfo (Depends-on, Makefile.am): Likewise.
104912         * modules/locale (Depends-on, Makefile.am): Likewise.
104913         * modules/sys_file (Makefile.am): Likewise.
104914         * modules/getopt-posix (Makefile.am): Delete unused link warning
104915         efforts.
104916         * lib/ctype.in.h (GL_LINK_WARNING): Ensure definition before use.
104917         * lib/langinfo.in.h (GL_LINK_WARNING): Likewise.
104918         * lib/locale.in.h (GL_LINK_WARNING): Likewise.
104919         * lib/sys_file.in.h (GL_LINK_WARNING): Likewise.
104921         stdio: remove unused variables
104922         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Remove unused variables.
104923         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Likewise.
104924         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
104926         tests: test more substitute headers
104927         * modules/ctype-tests: New file.
104928         * modules/dirent-tests: Likewise.
104929         * modules/spawn-tests: Likewise.
104930         * modules/sys_file-tests: Likewise.
104931         * modules/sys_ioctl-tests: Likewise.
104932         * modules/sys_wait-tests: Likewise.
104933         * tests/test-ctype.c: Likewise.
104934         * tests/test-dirent.c: Likewise.
104935         * tests/test-spawn.c: Likewise.
104936         * tests/test-sys_file.c: Likewise.
104937         * tests/test-sys_ioctl.c: Likewise.
104938         * tests/test-sys_wait.c: Likewise.
104939         * m4/spawn_h.m4 (gl_SPAWN_H): Replace header if it is missing.
104940         * lib/sys_file.in.h (LOCK_SH, LOCK_EX, LOCK_UN, LOCK_NB): Provide
104941         whether or not flock is in use.
104943         tests: remove License section from module
104944         * modules/arpa_inet-tests: Remove unneeded section.
104945         * modules/byteswap-tests: Likewise.
104946         * modules/ceilf-tests: Likewise.
104947         * modules/ceill-tests: Likewise.
104948         * modules/crypto/des-tests: Likewise.
104949         * modules/crypto/gc-arcfour-tests: Likewise.
104950         * modules/crypto/gc-arctwo-tests: Likewise.
104951         * modules/crypto/gc-des-tests: Likewise.
104952         * modules/crypto/gc-hmac-md5-tests: Likewise.
104953         * modules/crypto/gc-hmac-sha1-tests: Likewise.
104954         * modules/crypto/gc-md2-tests: Likewise.
104955         * modules/crypto/gc-md4-tests: Likewise.
104956         * modules/crypto/gc-md5-tests: Likewise.
104957         * modules/crypto/gc-pbkdf2-sha1-tests: Likewise.
104958         * modules/crypto/gc-rijndael-tests: Likewise.
104959         * modules/crypto/gc-sha1-tests: Likewise.
104960         * modules/crypto/gc-tests: Likewise.
104961         * modules/crypto/md2-tests: Likewise.
104962         * modules/crypto/md4-tests: Likewise.
104963         * modules/fcntl-h-tests: Likewise.
104964         * modules/floorf-tests: Likewise.
104965         * modules/floorl-tests: Likewise.
104966         * modules/frexp-nolibm-tests: Likewise.
104967         * modules/frexp-tests: Likewise.
104968         * modules/frexpl-nolibm-tests: Likewise.
104969         * modules/frexpl-tests: Likewise.
104970         * modules/getaddrinfo-tests: Likewise.
104971         * modules/inttypes-tests: Likewise.
104972         * modules/isfinite-tests: Likewise.
104973         * modules/isinf-tests: Likewise.
104974         * modules/ldexpl-tests: Likewise.
104975         * modules/locale-tests: Likewise.
104976         * modules/math-tests: Likewise.
104977         * modules/netdb-tests: Likewise.
104978         * modules/netinet_in-tests: Likewise.
104979         * modules/printf-frexp-tests: Likewise.
104980         * modules/printf-frexpl-tests: Likewise.
104981         * modules/priv-set-tests: Likewise.
104982         * modules/random_r-tests: Likewise.
104983         * modules/round-tests: Likewise.
104984         * modules/roundf-tests: Likewise.
104985         * modules/roundl-tests: Likewise.
104986         * modules/search-tests: Likewise.
104987         * modules/select-tests: Likewise.
104988         * modules/signal-tests: Likewise.
104989         * modules/stdbool-tests: Likewise.
104990         * modules/stddef-tests: Likewise.
104991         * modules/stdint-tests: Likewise.
104992         * modules/stdio-tests: Likewise.
104993         * modules/stdlib-tests: Likewise.
104994         * modules/string-tests: Likewise.
104995         * modules/strings-tests: Likewise.
104996         * modules/sys_select-tests: Likewise.
104997         * modules/sys_socket-tests: Likewise.
104998         * modules/sys_stat-tests: Likewise.
104999         * modules/sys_time-tests: Likewise.
105000         * modules/sys_utsname-tests: Likewise.
105001         * modules/sysexits-tests: Likewise.
105002         * modules/time-tests: Likewise.
105003         * modules/trunc-tests: Likewise.
105004         * modules/truncf-tests: Likewise.
105005         * modules/truncl-tests: Likewise.
105006         * modules/tsearch-tests: Likewise.
105007         * modules/unistd-tests: Likewise.
105008         * modules/wchar-tests: Likewise.
105009         * modules/wctype-tests: Likewise.
105011         tests: fix license on several tests
105012         * tests/test-des.c: Update to GPLv3+.
105013         * tests/test-flock.c: Likewise.
105014         * tests/test-fsync.c: Likewise.
105015         * tests/test-futimens.h: Likewise.
105016         * tests/test-gc-arcfour.c: Likewise.
105017         * tests/test-gc-arctwo.c: Likewise.
105018         * tests/test-gc-des.c: Likewise.
105019         * tests/test-gc-hmac-md5.c: Likewise.
105020         * tests/test-gc-hmac-sha1.c: Likewise.
105021         * tests/test-gc-md2.c: Likewise.
105022         * tests/test-gc-md4.c: Likewise.
105023         * tests/test-gc-md5.c: Likewise.
105024         * tests/test-gc-pbkdf2-sha1.c: Likewise.
105025         * tests/test-gc-rijndael.c: Likewise.
105026         * tests/test-gc-sha1.c: Likewise.
105027         * tests/test-gc.c: Likewise.
105028         * tests/test-getcwd.c: Likewise.
105029         * tests/test-link.c: Likewise.
105030         * tests/test-link.h: Likewise.
105031         * tests/test-lutimens.h: Likewise.
105032         * tests/test-md2.c: Likewise.
105033         * tests/test-md4.c: Likewise.
105034         * tests/test-mkdir.h: Likewise.
105035         * tests/test-rename.c: Likewise.
105036         * tests/test-rename.h: Likewise.
105037         * tests/test-safe-alloc.c: Likewise.
105038         * tests/test-utimens-common.h: Likewise.
105039         * tests/test-utimens.h: Likewise.
105041         maint: sync license texts
105042         * config/srclist.txt: Add gpl-1.3.texi, lgpl-1.3.texi.
105043         * doc/gpl-3.0.texi: Revert copyright year update.
105044         * doc/lgpl-3.0.texi: Likewise.
105046 2009-12-29  Jim Meyering  <meyering@redhat.com>
105048         update nearly all FSF copyright year lists to include 2009
105049         The files named by the following are exempted:
105050             grep -v '^#' config/srclist.txt|grep -v '^$' | while read src dst; do
105051               test -f "$dst" && { echo "$dst"; continue; }
105052               test -d "$dst" || continue
105053               echo "$dst"/$(basename "$src")
105054             done > exempt
105055             git ls-files tests/unictype >> exempt
105056         In the remaining files, convert to all-interval notation if
105057         - there is already at least one year interval like 2000-2003
105058         - the file is maintained by me
105059         - the file is in lib/uni*/, where that style already prevails
105060         Otherwise, use update-copyright's default.
105062 2009-12-29  Simon Josefsson  <simon@josefsson.org>
105063         and Eric Blake  <ebb9@byu.net>
105065         tests: don't require debug system() to pass
105066         * tests/test-lstat.h (test_lstat_func): Move debug cleanup...
105067         * tests/test-rmdir.h (test_rmdir_func): Likewise.
105068         * tests/test-unlink.h (test_unlink_func): Likewise.
105069         * tests/test-fstatat.c (main): ...into callers.
105070         * tests/test-lstat.c (main): Likewise.
105071         * tests/test-rmdir.c (main): Likewise.
105072         * tests/test-unlink.c (main): Likewise.
105073         * tests/test-unlinkat.c (main): Likewise.
105074         * tests/test-areadlink-with-size.c (main): Don't require a
105075         debug-only system call to pass, aiding cross-testing to mingw.
105076         * tests/test-areadlink.c (main): Likewise.
105077         * tests/test-areadlinkat-with-size.c (main): Likewise.
105078         * tests/test-areadlinkat.c (main): Likewise.
105079         * tests/test-canonicalize-lgpl.c (main): Likewise.
105080         * tests/test-canonicalize.c (main): Likewise.
105081         * tests/test-chown.c (main): Likewise.
105082         * tests/test-fchownat.c (main): Likewise.
105083         * tests/test-lchown.c (main): Likewise.
105084         * tests/test-fdutimensat.c (main): Likewise.
105085         * tests/test-futimens.c (main): Likewise.
105086         * tests/test-link.c (main): Likewise.
105087         * tests/test-linkat.c (main): Likewise.
105088         * tests/test-mkdir.c (main): Likewise.
105089         * tests/test-mkdirat.c (main): Likewise.
105090         * tests/test-mkfifo.c (main): Likewise.
105091         * tests/test-mkfifoat.c (main): Likewise.
105092         * tests/test-mknod.c (main): Likewise.
105093         * tests/test-readlink.c (main): Likewise.
105094         * tests/test-remove.c (main): Likewise.
105095         * tests/test-rename.c (main): Likewise.
105096         * tests/test-renameat.c (main): Likewise.
105097         * tests/test-symlink.c (main): Likewise.
105098         * tests/test-symlinkat.c (main): Likewise.
105099         * tests/test-utimens.c (main): Likewise.
105100         * tests/test-utimensat.c (main): Likewise.
105102 2009-12-29  Simon Josefsson  <simon@josefsson.org>
105104         * modules/selinux-h (selinux/selinux.h, selinux/context.h): Depend
105105         on $(UNUSED_PARAMETER_H) to avoid build failure.
105107 2009-12-28  Jim Meyering  <meyering@redhat.com>
105109         update-copyright: you may specify a max. line length other than 72
105110         * build-aux/update-copyright: Honor $UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
105112         maint: use consistent FSF copyright line syntax
105113         * lib/posixtm.c: Add missing comma in FSF copyright line.
105114         * lib/posixtm.h: Likewise.
105115         * lib/getugroups.c: Add missing ", Inc.".
105117         pmccabe2html: emit consistent FSF copyright; remove trailing blanks
105118         * build-aux/pmccabe2html: Insert comma before "Inc." in emitted
105119         FSF copyright line.  Remove trailing blanks.
105121 2009-12-28  Eric Blake  <ebb9@byu.net>
105123         test-dup2: reduce dependencies
105124         * modules/cloexec (Configure.ac): Set witness.
105125         * modules/dup2-tests (Depends-on): Drop cloexec.
105126         * tests/test-dup2.c (main): Skip portion of test if cloexec module
105127         not present.
105128         Suggested by Bruno Haible.
105130 2009-12-26  Bruno Haible  <bruno@clisp.org>
105132         Remove an unneeded dependency.
105133         * modules/fseterr (Depends-on): Remove dup2.
105135 2009-12-26  Eric Blake  <ebb9@byu.net>
105137         tests: use macros.h in more places
105138         * tests/macros.h (ASSERT): Depend on ASSERT_STREAM.
105139         (ASSERT_STREAM): Provide default of stderr.
105140         * tests/test-dirent-safer.c: Include macros.h, using alternate
105141         stream for assertions.
105142         * tests/test-dup-safer.c: Likewise.
105143         * tests/test-freopen-safer.c: Likewise.
105144         * tests/test-getopt.c: Likewise.
105145         * tests/test-openat-safer.c: Likewise.
105146         * tests/test-pipe.c: Likewise.
105147         * tests/test-popen-safer.c: Likewise.
105148         * modules/dirent-safer-tests (Files): Include macros.h.
105149         * modules/unistd-safer-tests (Files): Likewise.
105150         * modules/freopen-safer-tests (Files): Likewise.
105151         * modules/getopt-posix-tests (Files): Likewise.
105152         * modules/openat-safer-tests (Files): Likewise.
105153         * modules/pipe-tests (Files): Likewise.
105155 2009-12-26  Bruno Haible  <bruno@clisp.org>
105157         javacomp-script: Portability fix.
105158         * m4/javacomp.m4 (gt_JAVACOMP): Fix creation of conftestver.class so
105159         that it also works on Solaris.
105161 2009-12-26  Bruno Haible  <bruno@clisp.org>
105163         localename: Fix storage allocation of gl_locale_name_thread's result.
105164         * lib/localename.c (SIZE_BITS, string_hash, struct hash_node,
105165         HASH_TABLE_SIZE, struniq_hash_table, struniq_lock, struniq): Define on
105166         all platforms that have 'uselocale'.
105167         (gl_locale_name_thread_unsafe): New function, extracted from
105168         gl_locale_name_thread.
105169         (gl_locale_name_thread): Call struniq on all platforms that have
105170         'uselocale'.
105171         * tests/test-localename.c (test_locale_name_thread): Check that the
105172         resulting strings are permanently allocated.
105173         * modules/localename-tests (Depends-on): Add strdup.
105175 2009-12-26  Bruno Haible  <bruno@clisp.org>
105177         * tests/test-localename.c (categories): Fill in the strings.
105179 2009-12-26  Jim Meyering  <meyering@redhat.com>
105181         isdir: complete the removal of m4/isdir.m4
105182         * modules/isdir (configure.ac): Remove reference to gl_ISDIR.
105184         isdir: clean up, since at least grep still uses it
105185         * lib/isdir.c: Include "isdir.h".
105186         (S_ISDIR): Remove now-unneeded definition.
105187         * modules/isdir (Files): Add lib/isdir.h.
105188         * lib/isdir.h: New file, with declaration.
105189         * m4/isdir.m4: Remove file -- unneeded.
105191 2009-12-25  Bruno Haible  <bruno@clisp.org>
105193         selinux-h: Make generated .h files standalone.
105194         * lib/se-context.in.h: Arrange to include _GL_UNUSED_PARAMETER
105195         definition. Use _GL_UNUSED_PARAMETER instead of _GL_UNUSED.
105196         * lib/se-selinux.in.h: Likewise.
105197         * modules/selinux-h (Depends-on): Add unused-parameter.
105198         (Makefile.am): Insert definition of _GL_UNUSED_PARAMETER into
105199         selinux/selinux.h and selinux/context.h.
105200         Suggested by Eric Blake.
105202 2009-12-25  Bruno Haible  <bruno@clisp.org>
105204         Move gl_FCNTL_O_FLAGS to a separate .m4 file.
105205         * m4/fcntl-o.m4: New file, extracted from m4/fcntl_h.m4.
105206         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): Remove macro.
105207         * modules/fcntl-h (Files): Add m4/fcntl-o.m4.
105208         * modules/localcharset (Files): Likewise. Remove m4/fcntl_h.m4.
105210 2009-12-24  Bruno Haible  <bruno@clisp.org>
105212         openat: Fix warning.
105213         * lib/openat-proc.c: Include <unistd.h>.
105215 2009-12-24  Bruno Haible  <bruno@clisp.org>
105217         New module 'unused-parameter'.
105218         * build-aux/unused-parameter.h: New file, extracted from earlier
105219         gnulib-common.m4.
105220         * modules/unused-parameter: New file.
105221         * lib/unistr.h: Include unused-parameter.h.
105222         (u32_mbtouc_unsafe, u32_mbtouc): Use _GL_UNUSED_PARAMETER instead of
105223         _GL_UNUSED.
105224         * modules/unistr/base (Depends-on): Add unused-parameter.
105226 2009-12-24  Bruno Haible  <bruno@clisp.org>
105228         Add missing dependencies to 'extensions' module.
105229         * m4/extensions.m4: Add comment.
105230         * modules/accept4 (Depends-on): Add extensions.
105231         * modules/dup3 (Depends-on): Likewise.
105232         * modules/fcntl (Depends-on): Likewise.
105233         * modules/futimens (Depends-on): Likewise.
105234         * modules/mknod (Depends-on): Likewise.
105235         * modules/pipe2 (Depends-on): Likewise.
105236         * modules/stat-time (Depends-on): Likewise.
105237         * modules/strcasestr-simple (Depends-on): Likewise.
105238         * modules/strsignal (Depends-on): Likewise.
105239         * modules/utimensat (Depends-on): Likewise.
105240         * modules/localcharset (Depends-on): Likewise. Needed because of
105241         gl_FCNTL_O_FLAGS.
105242         * modules/wcrtomb (Depends-on): Likewise. Needed because of
105243         AC_TYPE_MBSTATE_T.
105244         * modules/wcsnrtombs (Depends-on): Likewise.
105245         * modules/wcsrtombs (Depends-on): Likewise.
105247 2009-12-24  Bruno Haible  <bruno@clisp.org>
105249         binary-io: Avoid gcc warning due to SET_BINARY.
105250         * lib/binary-io.h (SET_BINARY): Cast the result to void.
105251         Reported by Jim Meyering <jim@meyering.net>. Suggestion by Eric Blake.
105253 2009-12-24  Bruno Haible  <bruno@clisp.org>
105255         Avoid future namespace pollution on glibc systems.
105256         * lib/arpa_inet.in.h: Don't include <sys/socket.h> on glibc systems.
105257         * lib/sys_ioctl.in.h: Don't include <unistd.h> on glibc systems.
105258         * lib/sys_select.in.h: Don't include <sys/time.h> and <string.h> on
105259         glibc systems.
105261 2009-12-24  Bruno Haible  <bruno@clisp.org>
105263         Refactor common macros used in tests.
105264         * tests/macros.h: New file.
105265         * tests/test-areadlink.c: Include macros.h. Don't include <stdio.h>
105266         and/or <stdlib.h>, if appropriate.
105267         (ASSERT, SIZEOF): Remove macros.
105268         * tests/test-areadlink-with-size.c: Likewise.
105269         * tests/test-areadlinkat.c: Likewise.
105270         * tests/test-areadlinkat-with-size.c: Likewise.
105271         * tests/test-argmatch.c: Likewise.
105272         * tests/test-argv-iter.c: Likewise.
105273         * tests/test-array-mergesort.c: Likewise.
105274         * tests/test-array_list.c: Likewise.
105275         * tests/test-array_oset.c: Likewise.
105276         * tests/test-avltree_list.c: Likewise.
105277         * tests/test-avltree_oset.c: Likewise.
105278         * tests/test-avltreehash_list.c: Likewise.
105279         * tests/test-base64.c: Likewise.
105280         * tests/test-binary-io.c: Likewise.
105281         * tests/test-bitrotate.c: Likewise.
105282         * tests/test-btowc.c: Likewise.
105283         * tests/test-byteswap.c: Likewise.
105284         * tests/test-c-ctype.c: Likewise.
105285         * tests/test-c-stack.c: Likewise.
105286         * tests/test-c-strcasecmp.c: Likewise.
105287         * tests/test-c-strcasestr.c: Likewise.
105288         * tests/test-c-strncasecmp.c: Likewise.
105289         * tests/test-c-strstr.c: Likewise.
105290         * tests/test-canonicalize-lgpl.c: Likewise.
105291         * tests/test-canonicalize.c: Likewise.
105292         * tests/test-carray_list.c: Likewise.
105293         * tests/test-ceilf1.c: Likewise.
105294         * tests/test-ceilf2.c: Likewise.
105295         * tests/test-ceill.c: Likewise.
105296         * tests/test-chown.c: Likewise.
105297         * tests/test-cloexec.c: Likewise.
105298         * tests/test-copy-acl.c: Likewise.
105299         * tests/test-copy-file.c: Likewise.
105300         * tests/test-count-one-bits.c: Likewise.
105301         * tests/test-dprintf-posix.c: Likewise.
105302         * tests/test-dup2.c: Likewise.
105303         * tests/test-dup3.c: Likewise.
105304         * tests/test-duplocale.c: Likewise.
105305         * tests/test-fbufmode.c: Likewise.
105306         * tests/test-fchdir.c: Likewise.
105307         * tests/test-fchownat.c: Likewise.
105308         * tests/test-fcntl-safer.c: Likewise.
105309         * tests/test-fcntl.c: Likewise.
105310         * tests/test-fdopendir.c: Likewise.
105311         * tests/test-fdutimensat.c: Likewise.
105312         * tests/test-fflush2.c: Likewise.
105313         * tests/test-file-has-acl.c: Likewise.
105314         * tests/test-filevercmp.c: Likewise.
105315         * tests/test-flock.c: Likewise.
105316         * tests/test-floorf1.c: Likewise.
105317         * tests/test-floorf2.c: Likewise.
105318         * tests/test-floorl.c: Likewise.
105319         * tests/test-fnmatch.c: Likewise.
105320         * tests/test-fopen.h: Likewise.
105321         * tests/test-fpending.c: Likewise.
105322         * tests/test-fprintf-posix.c: Likewise.
105323         * tests/test-fpurge.c: Likewise.
105324         * tests/test-freadable.c: Likewise.
105325         * tests/test-freadahead.c: Likewise.
105326         * tests/test-freading.c: Likewise.
105327         * tests/test-freadptr.c: Likewise.
105328         * tests/test-freadptr2.c: Likewise.
105329         * tests/test-freadseek.c: Likewise.
105330         * tests/test-freopen.c: Likewise.
105331         * tests/test-frexp.c: Likewise.
105332         * tests/test-frexpl.c: Likewise.
105333         * tests/test-fseek.c: Likewise.
105334         * tests/test-fseeko.c: Likewise.
105335         * tests/test-fstatat.c: Likewise.
105336         * tests/test-fstrcmp.c: Likewise.
105337         * tests/test-fsync.c: Likewise.
105338         * tests/test-ftell.c: Likewise.
105339         * tests/test-ftello.c: Likewise.
105340         * tests/test-func.c: Likewise.
105341         * tests/test-futimens.c: Likewise.
105342         * tests/test-fwritable.c: Likewise.
105343         * tests/test-fwriting.c: Likewise.
105344         * tests/test-getcwd.c: Likewise.
105345         * tests/test-getdate.c: Likewise.
105346         * tests/test-getdelim.c: Likewise.
105347         * tests/test-getdtablesize.c: Likewise.
105348         * tests/test-getgroups.c: Likewise.
105349         * tests/test-getline.c: Likewise.
105350         * tests/test-getndelim2.c: Likewise.
105351         * tests/test-glob.c: Likewise.
105352         * tests/test-hash.c: Likewise.
105353         * tests/test-i-ring.c: Likewise.
105354         * tests/test-iconv-utf.c: Likewise.
105355         * tests/test-iconv.c: Likewise.
105356         * tests/test-idpriv-drop.c: Likewise.
105357         * tests/test-idpriv-droptemp.c: Likewise.
105358         * tests/test-inet_ntop.c: Likewise.
105359         * tests/test-inet_pton.c: Likewise.
105360         * tests/test-isblank.c: Likewise.
105361         * tests/test-isfinite.c: Likewise.
105362         * tests/test-isinf.c: Likewise.
105363         * tests/test-isnan.c: Likewise.
105364         * tests/test-isnand.h: Likewise.
105365         * tests/test-isnanf.h: Likewise.
105366         * tests/test-isnanl.h: Likewise.
105367         * tests/test-lchown.c: Likewise.
105368         * tests/test-ldexpl.c: Likewise.
105369         * tests/test-link.c: Likewise.
105370         * tests/test-linkat.c: Likewise.
105371         * tests/test-linked_list.c: Likewise.
105372         * tests/test-linkedhash_list.c: Likewise.
105373         * tests/test-localename.c: Likewise.
105374         * tests/test-lseek.c: Likewise.
105375         * tests/test-lstat.c: Likewise.
105376         * tests/test-mbmemcasecmp.c: Likewise.
105377         * tests/test-mbmemcasecoll.c: Likewise.
105378         * tests/test-mbrtowc.c: Likewise.
105379         * tests/test-mbscasecmp.c: Likewise.
105380         * tests/test-mbscasestr1.c: Likewise.
105381         * tests/test-mbscasestr2.c: Likewise.
105382         * tests/test-mbscasestr3.c: Likewise.
105383         * tests/test-mbscasestr4.c: Likewise.
105384         * tests/test-mbschr.c: Likewise.
105385         * tests/test-mbscspn.c: Likewise.
105386         * tests/test-mbsinit.c: Likewise.
105387         * tests/test-mbsncasecmp.c: Likewise.
105388         * tests/test-mbsnrtowcs.c: Likewise.
105389         * tests/test-mbspbrk.c: Likewise.
105390         * tests/test-mbspcasecmp.c: Likewise.
105391         * tests/test-mbsrchr.c: Likewise.
105392         * tests/test-mbsrtowcs.c: Likewise.
105393         * tests/test-mbsspn.c: Likewise.
105394         * tests/test-mbsstr1.c: Likewise.
105395         * tests/test-mbsstr2.c: Likewise.
105396         * tests/test-mbsstr3.c: Likewise.
105397         * tests/test-memchr.c: Likewise.
105398         * tests/test-memchr2.c: Likewise.
105399         * tests/test-memcmp.c: Likewise.
105400         * tests/test-memmem.c: Likewise.
105401         * tests/test-memrchr.c: Likewise.
105402         * tests/test-mkdir.c: Likewise.
105403         * tests/test-mkdirat.c: Likewise.
105404         * tests/test-mkfifo.c: Likewise.
105405         * tests/test-mkfifoat.c: Likewise.
105406         * tests/test-mknod.c: Likewise.
105407         * tests/test-nanosleep.c: Likewise.
105408         * tests/test-nl_langinfo.c: Likewise.
105409         * tests/test-obstack-printf.c: Likewise.
105410         * tests/test-open.c: Likewise.
105411         * tests/test-openat.c: Likewise.
105412         * tests/test-pipe-filter-gi1.c: Likewise.
105413         * tests/test-pipe-filter-gi2-main.c: Likewise.
105414         * tests/test-pipe-filter-ii1.c: Likewise.
105415         * tests/test-pipe-filter-ii2-main.c: Likewise.
105416         * tests/test-pipe2.c: Likewise.
105417         * tests/test-popen.h: Likewise.
105418         * tests/test-posixtm.c: Likewise.
105419         * tests/test-pread.c: Likewise.
105420         * tests/test-printf-frexp.c: Likewise.
105421         * tests/test-printf-frexpl.c: Likewise.
105422         * tests/test-printf-posix.c: Likewise.
105423         * tests/test-priv-set.c: Likewise.
105424         * tests/test-quotearg.c: Likewise.
105425         * tests/test-random_r.c: Likewise.
105426         * tests/test-rawmemchr.c: Likewise.
105427         * tests/test-rbtree_list.c: Likewise.
105428         * tests/test-rbtree_oset.c: Likewise.
105429         * tests/test-rbtreehash_list.c: Likewise.
105430         * tests/test-readlink.c: Likewise.
105431         * tests/test-remove.c: Likewise.
105432         * tests/test-rename.c: Likewise.
105433         * tests/test-renameat.c: Likewise.
105434         * tests/test-rmdir.c: Likewise.
105435         * tests/test-round1.c: Likewise.
105436         * tests/test-roundf1.c: Likewise.
105437         * tests/test-roundl.c: Likewise.
105438         * tests/test-safe-alloc.c: Likewise.
105439         * tests/test-sameacls.c: Likewise.
105440         * tests/test-set-mode-acl.c: Likewise.
105441         * tests/test-setenv.c: Likewise.
105442         * tests/test-sigaction.c: Likewise.
105443         * tests/test-signbit.c: Likewise.
105444         * tests/test-sleep.c: Likewise.
105445         * tests/test-snprintf-posix.c: Likewise.
105446         * tests/test-snprintf.c: Likewise.
105447         * tests/test-sprintf-posix.c: Likewise.
105448         * tests/test-stat-time.c: Likewise.
105449         * tests/test-stat.c: Likewise.
105450         * tests/test-strcasestr.c: Likewise.
105451         * tests/test-strchrnul.c: Likewise.
105452         * tests/test-strerror.c: Likewise.
105453         * tests/test-striconv.c: Likewise.
105454         * tests/test-striconveh.c: Likewise.
105455         * tests/test-striconveha.c: Likewise.
105456         * tests/test-strsignal.c: Likewise.
105457         * tests/test-strstr.c: Likewise.
105458         * tests/test-strtod.c: Likewise.
105459         * tests/test-strverscmp.c: Likewise.
105460         * tests/test-symlink.c: Likewise.
105461         * tests/test-symlinkat.c: Likewise.
105462         * tests/test-trunc1.c: Likewise.
105463         * tests/test-trunc2.c: Likewise.
105464         * tests/test-truncf1.c: Likewise.
105465         * tests/test-truncf2.c: Likewise.
105466         * tests/test-truncl.c: Likewise.
105467         * tests/test-uname.c: Likewise.
105468         * tests/test-unlink.c: Likewise.
105469         * tests/test-unlinkat.c: Likewise.
105470         * tests/test-unsetenv.c: Likewise.
105471         * tests/test-usleep.c: Likewise.
105472         * tests/test-utimens.c: Likewise.
105473         * tests/test-utimensat.c: Likewise.
105474         * tests/test-vasnprintf-posix.c: Likewise.
105475         * tests/test-vasnprintf-posix2.c: Likewise.
105476         * tests/test-vasnprintf.c: Likewise.
105477         * tests/test-vasprintf-posix.c: Likewise.
105478         * tests/test-vasprintf.c: Likewise.
105479         * tests/test-vdprintf-posix.c: Likewise.
105480         * tests/test-vfprintf-posix.c: Likewise.
105481         * tests/test-vprintf-posix.c: Likewise.
105482         * tests/test-vsnprintf-posix.c: Likewise.
105483         * tests/test-vsnprintf.c: Likewise.
105484         * tests/test-vsprintf-posix.c: Likewise.
105485         * tests/test-wcrtomb.c: Likewise.
105486         * tests/test-wcsnrtombs.c: Likewise.
105487         * tests/test-wcsrtombs.c: Likewise.
105488         * tests/test-wctype.c: Likewise.
105489         * tests/test-wcwidth.c: Likewise.
105490         * tests/test-xfprintf-posix.c: Likewise.
105491         * tests/test-xmemdup0.c: Likewise.
105492         * tests/test-xprintf-posix.c: Likewise.
105493         * tests/test-xvasprintf.c: Likewise.
105494         * tests/unicase/test-locale-language.c: Likewise.
105495         * tests/unicase/test-mapping-part1.h: Likewise.
105496         * tests/unicase/test-predicate-part1.h: Likewise.
105497         * tests/unicase/test-u8-casecmp.c: Likewise.
105498         * tests/unicase/test-u8-casecoll.c: Likewise.
105499         * tests/unicase/test-u8-casefold.c: Likewise.
105500         * tests/unicase/test-u8-is-cased.c: Likewise.
105501         * tests/unicase/test-u8-is-casefolded.c: Likewise.
105502         * tests/unicase/test-u8-is-lowercase.c: Likewise.
105503         * tests/unicase/test-u8-is-titlecase.c: Likewise.
105504         * tests/unicase/test-u8-is-uppercase.c: Likewise.
105505         * tests/unicase/test-u8-tolower.c: Likewise.
105506         * tests/unicase/test-u8-totitle.c: Likewise.
105507         * tests/unicase/test-u8-toupper.c: Likewise.
105508         * tests/unicase/test-u16-casecmp.c: Likewise.
105509         * tests/unicase/test-u16-casecoll.c: Likewise.
105510         * tests/unicase/test-u16-casefold.c: Likewise.
105511         * tests/unicase/test-u16-is-cased.c: Likewise.
105512         * tests/unicase/test-u16-is-casefolded.c: Likewise.
105513         * tests/unicase/test-u16-is-lowercase.c: Likewise.
105514         * tests/unicase/test-u16-is-titlecase.c: Likewise.
105515         * tests/unicase/test-u16-is-uppercase.c: Likewise.
105516         * tests/unicase/test-u16-tolower.c: Likewise.
105517         * tests/unicase/test-u16-totitle.c: Likewise.
105518         * tests/unicase/test-u16-toupper.c: Likewise.
105519         * tests/unicase/test-u32-casecmp.c: Likewise.
105520         * tests/unicase/test-u32-casecoll.c: Likewise.
105521         * tests/unicase/test-u32-casefold.c: Likewise.
105522         * tests/unicase/test-u32-is-cased.c: Likewise.
105523         * tests/unicase/test-u32-is-casefolded.c: Likewise.
105524         * tests/unicase/test-u32-is-lowercase.c: Likewise.
105525         * tests/unicase/test-u32-is-titlecase.c: Likewise.
105526         * tests/unicase/test-u32-is-uppercase.c: Likewise.
105527         * tests/unicase/test-u32-tolower.c: Likewise.
105528         * tests/unicase/test-u32-totitle.c: Likewise.
105529         * tests/unicase/test-u32-toupper.c: Likewise.
105530         * tests/unicase/test-ulc-casecmp.c: Likewise.
105531         * tests/unicase/test-ulc-casecoll.c: Likewise.
105532         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
105533         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
105534         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
105535         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
105536         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
105537         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
105538         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
105539         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
105540         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
105541         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
105542         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
105543         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
105544         * tests/unictype/test-bidi_byname.c: Likewise.
105545         * tests/unictype/test-bidi_name.c: Likewise.
105546         * tests/unictype/test-bidi_of.c: Likewise.
105547         * tests/unictype/test-bidi_test.c: Likewise.
105548         * tests/unictype/test-block_list.c: Likewise.
105549         * tests/unictype/test-block_of.c: Likewise.
105550         * tests/unictype/test-block_test.c: Likewise.
105551         * tests/unictype/test-categ_and.c: Likewise.
105552         * tests/unictype/test-categ_and_not.c: Likewise.
105553         * tests/unictype/test-categ_byname.c: Likewise.
105554         * tests/unictype/test-categ_name.c: Likewise.
105555         * tests/unictype/test-categ_none.c: Likewise.
105556         * tests/unictype/test-categ_of.c: Likewise.
105557         * tests/unictype/test-categ_or.c: Likewise.
105558         * tests/unictype/test-categ_test_withtable.c: Likewise.
105559         * tests/unictype/test-combining.c: Likewise.
105560         * tests/unictype/test-decdigit.c: Likewise.
105561         * tests/unictype/test-digit.c: Likewise.
105562         * tests/unictype/test-mirror.c: Likewise.
105563         * tests/unictype/test-numeric.c: Likewise.
105564         * tests/unictype/test-pr_byname.c: Likewise.
105565         * tests/unictype/test-pr_test.c: Likewise.
105566         * tests/unictype/test-predicate-part1.h: Likewise.
105567         * tests/unictype/test-scripts.c: Likewise.
105568         * tests/unictype/test-sy_c_ident.c: Likewise.
105569         * tests/unictype/test-sy_java_ident.c: Likewise.
105570         * tests/unilbrk/test-u8-possible-linebreaks.c: Likewise.
105571         * tests/unilbrk/test-u8-width-linebreaks.c: Likewise.
105572         * tests/unilbrk/test-u16-possible-linebreaks.c: Likewise.
105573         * tests/unilbrk/test-u16-width-linebreaks.c: Likewise.
105574         * tests/unilbrk/test-u32-possible-linebreaks.c: Likewise.
105575         * tests/unilbrk/test-u32-width-linebreaks.c: Likewise.
105576         * tests/unilbrk/test-ulc-possible-linebreaks.c: Likewise.
105577         * tests/unilbrk/test-ulc-width-linebreaks.c: Likewise.
105578         * tests/uninorm/test-canonical-decomposition.c: Likewise.
105579         * tests/uninorm/test-compat-decomposition.c: Likewise.
105580         * tests/uninorm/test-composition.c: Likewise.
105581         * tests/uninorm/test-decomposing-form.c: Likewise.
105582         * tests/uninorm/test-decomposition.c: Likewise.
105583         * tests/uninorm/test-u8-nfc.c: Likewise.
105584         * tests/uninorm/test-u8-nfd.c: Likewise.
105585         * tests/uninorm/test-u8-nfkc.c: Likewise.
105586         * tests/uninorm/test-u8-nfkd.c: Likewise.
105587         * tests/uninorm/test-u8-normcmp.c: Likewise.
105588         * tests/uninorm/test-u8-normcoll.c: Likewise.
105589         * tests/uninorm/test-u16-nfc.c: Likewise.
105590         * tests/uninorm/test-u16-nfd.c: Likewise.
105591         * tests/uninorm/test-u16-nfkc.c: Likewise.
105592         * tests/uninorm/test-u16-nfkd.c: Likewise.
105593         * tests/uninorm/test-u16-normcmp.c: Likewise.
105594         * tests/uninorm/test-u16-normcoll.c: Likewise.
105595         * tests/uninorm/test-u32-nfc.c: Likewise.
105596         * tests/uninorm/test-u32-nfd.c: Likewise.
105597         * tests/uninorm/test-u32-nfkc.c: Likewise.
105598         * tests/uninorm/test-u32-nfkd.c: Likewise.
105599         * tests/uninorm/test-u32-normalize-big.c: Likewise.
105600         * tests/uninorm/test-u32-normcmp.c: Likewise.
105601         * tests/uninorm/test-u32-normcoll.c: Likewise.
105602         * tests/uninorm/test-uninorm-filter-nfc.c: Likewise.
105603         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
105604         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
105605         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
105606         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
105607         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
105608         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
105609         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
105610         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
105611         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
105612         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
105613         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
105614         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
105615         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
105616         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
105617         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
105618         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
105619         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
105620         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
105621         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
105622         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
105623         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
105624         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
105625         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
105626         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
105627         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
105628         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
105629         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
105630         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
105631         * tests/uniwbrk/test-u8-wordbreaks.c: Likewise.
105632         * tests/uniwbrk/test-u16-wordbreaks.c: Likewise.
105633         * tests/uniwbrk/test-u32-wordbreaks.c: Likewise.
105634         * tests/uniwbrk/test-ulc-wordbreaks.c: Likewise.
105635         * tests/uniwidth/test-u8-strwidth.c: Likewise.
105636         * tests/uniwidth/test-u8-width.c: Likewise.
105637         * tests/uniwidth/test-u16-strwidth.c: Likewise.
105638         * tests/uniwidth/test-u16-width.c: Likewise.
105639         * tests/uniwidth/test-u32-strwidth.c: Likewise.
105640         * tests/uniwidth/test-u32-width.c: Likewise.
105641         * tests/uniwidth/test-uc_width.c: Likewise.
105642         * tests/uniwidth/test-uc_width2.c: Likewise.
105643         * modules/acl-tests (Files): Add tests/macros.h.
105644         * modules/areadlink-tests (Files): Likewise.
105645         * modules/areadlink-with-size-tests (Files): Likewise.
105646         * modules/areadlinkat-tests (Files): Likewise.
105647         * modules/areadlinkat-with-size-tests (Files): Likewise.
105648         * modules/argmatch-tests (Files): Likewise.
105649         * modules/argv-iter-tests (Files): Likewise.
105650         * modules/array-list-tests (Files): Likewise.
105651         * modules/array-mergesort-tests (Files): Likewise.
105652         * modules/array-oset-tests (Files): Likewise.
105653         * modules/avltree-list-tests (Files): Likewise.
105654         * modules/avltree-oset-tests (Files): Likewise.
105655         * modules/avltreehash-list-tests (Files): Likewise.
105656         * modules/base64-tests (Files): Likewise.
105657         * modules/binary-io-tests (Files): Likewise.
105658         * modules/bitrotate-tests (Files): Likewise.
105659         * modules/btowc-tests (Files): Likewise.
105660         * modules/byteswap-tests (Files): Likewise.
105661         * modules/c-ctype-tests (Files): Likewise.
105662         * modules/c-stack-tests (Files): Likewise.
105663         * modules/c-strcase-tests (Files): Likewise.
105664         * modules/c-strcasestr-tests (Files): Likewise.
105665         * modules/c-strstr-tests (Files): Likewise.
105666         * modules/canonicalize-lgpl-tests (Files): Likewise.
105667         * modules/canonicalize-tests (Files): Likewise.
105668         * modules/carray-list-tests (Files): Likewise.
105669         * modules/ceilf-tests (Files): Likewise.
105670         * modules/ceill-tests (Files): Likewise.
105671         * modules/chown-tests (Files): Likewise.
105672         * modules/cloexec-tests (Files): Likewise.
105673         * modules/copy-file-tests (Files): Likewise.
105674         * modules/count-one-bits-tests (Files): Likewise.
105675         * modules/dprintf-posix-tests (Files): Likewise.
105676         * modules/dup2-tests (Files): Likewise.
105677         * modules/dup3-tests (Files): Likewise.
105678         * modules/duplocale-tests (Files): Likewise.
105679         * modules/fbufmode-tests (Files): Likewise.
105680         * modules/fchdir-tests (Files): Likewise.
105681         * modules/fcntl-safer-tests (Files): Likewise.
105682         * modules/fcntl-tests (Files): Likewise.
105683         * modules/fdopendir-tests (Files): Likewise.
105684         * modules/fdutimensat-tests (Files): Likewise.
105685         * modules/fflush-tests (Files): Likewise.
105686         * modules/filevercmp-tests (Files): Likewise.
105687         * modules/flock-tests (Files): Likewise.
105688         * modules/floorf-tests (Files): Likewise.
105689         * modules/floorl-tests (Files): Likewise.
105690         * modules/fnmatch-tests (Files): Likewise.
105691         * modules/fopen-safer-tests (Files): Likewise.
105692         * modules/fopen-tests (Files): Likewise.
105693         * modules/fpending-tests (Files): Likewise.
105694         * modules/fprintf-posix-tests (Files): Likewise.
105695         * modules/fpurge-tests (Files): Likewise.
105696         * modules/freadable-tests (Files): Likewise.
105697         * modules/freadahead-tests (Files): Likewise.
105698         * modules/freading-tests (Files): Likewise.
105699         * modules/freadptr-tests (Files): Likewise.
105700         * modules/freadseek-tests (Files): Likewise.
105701         * modules/freopen-tests (Files): Likewise.
105702         * modules/frexp-nolibm-tests (Files): Likewise.
105703         * modules/frexp-tests (Files): Likewise.
105704         * modules/frexpl-nolibm-tests (Files): Likewise.
105705         * modules/frexpl-tests (Files): Likewise.
105706         * modules/fseek-tests (Files): Likewise.
105707         * modules/fseeko-tests (Files): Likewise.
105708         * modules/fstrcmp-tests (Files): Likewise.
105709         * modules/fsync-tests (Files): Likewise.
105710         * modules/ftell-tests (Files): Likewise.
105711         * modules/ftello-tests (Files): Likewise.
105712         * modules/func-tests (Files): Likewise.
105713         * modules/futimens-tests (Files): Likewise.
105714         * modules/fwritable-tests (Files): Likewise.
105715         * modules/fwriting-tests (Files): Likewise.
105716         * modules/getcwd-tests (Files): Likewise.
105717         * modules/getdate-tests (Files): Likewise.
105718         * modules/getdelim-tests (Files): Likewise.
105719         * modules/getdtablesize-tests (Files): Likewise.
105720         * modules/getgroups-tests (Files): Likewise.
105721         * modules/getline-tests (Files): Likewise.
105722         * modules/getndelim2-tests (Files): Likewise.
105723         * modules/glob-tests (Files): Likewise.
105724         * modules/hash-tests (Files): Likewise.
105725         * modules/i-ring-tests (Files): Likewise.
105726         * modules/iconv-tests (Files): Likewise.
105727         * modules/iconv_open-utf-tests (Files): Likewise.
105728         * modules/idpriv-drop-tests (Files): Likewise.
105729         * modules/idpriv-droptemp-tests (Files): Likewise.
105730         * modules/inet_ntop-tests (Files): Likewise.
105731         * modules/inet_pton-tests (Files): Likewise.
105732         * modules/isblank-tests (Files): Likewise.
105733         * modules/isfinite-tests (Files): Likewise.
105734         * modules/isinf-tests (Files): Likewise.
105735         * modules/isnan-tests (Files): Likewise.
105736         * modules/isnand-nolibm-tests (Files): Likewise.
105737         * modules/isnand-tests (Files): Likewise.
105738         * modules/isnanf-nolibm-tests (Files): Likewise.
105739         * modules/isnanf-tests (Files): Likewise.
105740         * modules/isnanl-nolibm-tests (Files): Likewise.
105741         * modules/isnanl-tests (Files): Likewise.
105742         * modules/lchown-tests (Files): Likewise.
105743         * modules/ldexpl-tests (Files): Likewise.
105744         * modules/link-tests (Files): Likewise.
105745         * modules/linkat-tests (Files): Likewise.
105746         * modules/linked-list-tests (Files): Likewise.
105747         * modules/linkedhash-list-tests (Files): Likewise.
105748         * modules/localename-tests (Files): Likewise.
105749         * modules/lseek-tests (Files): Likewise.
105750         * modules/lstat-tests (Files): Likewise.
105751         * modules/mbmemcasecmp-tests (Files): Likewise.
105752         * modules/mbmemcasecoll-tests (Files): Likewise.
105753         * modules/mbrtowc-tests (Files): Likewise.
105754         * modules/mbscasecmp-tests (Files): Likewise.
105755         * modules/mbscasestr-tests (Files): Likewise.
105756         * modules/mbschr-tests (Files): Likewise.
105757         * modules/mbscspn-tests (Files): Likewise.
105758         * modules/mbsinit-tests (Files): Likewise.
105759         * modules/mbsncasecmp-tests (Files): Likewise.
105760         * modules/mbsnrtowcs-tests (Files): Likewise.
105761         * modules/mbspbrk-tests (Files): Likewise.
105762         * modules/mbspcasecmp-tests (Files): Likewise.
105763         * modules/mbsrchr-tests (Files): Likewise.
105764         * modules/mbsrtowcs-tests (Files): Likewise.
105765         * modules/mbsspn-tests (Files): Likewise.
105766         * modules/mbsstr-tests (Files): Likewise.
105767         * modules/memchr-tests (Files): Likewise.
105768         * modules/memchr2-tests (Files): Likewise.
105769         * modules/memcmp-tests (Files): Likewise.
105770         * modules/memmem-tests (Files): Likewise.
105771         * modules/memrchr-tests (Files): Likewise.
105772         * modules/mkdir-tests (Files): Likewise.
105773         * modules/mkfifo-tests (Files): Likewise.
105774         * modules/mkfifoat-tests (Files): Likewise.
105775         * modules/mknod-tests (Files): Likewise.
105776         * modules/nanosleep-tests (Files): Likewise.
105777         * modules/nl_langinfo-tests (Files): Likewise.
105778         * modules/obstack-printf-tests (Files): Likewise.
105779         * modules/open-tests (Files): Likewise.
105780         * modules/openat-tests (Files): Likewise.
105781         * modules/pipe-filter-gi-tests (Files): Likewise.
105782         * modules/pipe-filter-ii-tests (Files): Likewise.
105783         * modules/pipe2-tests (Files): Likewise.
105784         * modules/popen-safer-tests (Files): Likewise.
105785         * modules/popen-tests (Files): Likewise.
105786         * modules/posixtm-tests (Files): Likewise.
105787         * modules/pread-tests (Files): Likewise.
105788         * modules/printf-frexp-tests (Files): Likewise.
105789         * modules/printf-frexpl-tests (Files): Likewise.
105790         * modules/printf-posix-tests (Files): Likewise.
105791         * modules/priv-set-tests (Files): Likewise.
105792         * modules/quotearg-tests (Files): Likewise.
105793         * modules/random_r-tests (Files): Likewise.
105794         * modules/rawmemchr-tests (Files): Likewise.
105795         * modules/rbtree-list-tests (Files): Likewise.
105796         * modules/rbtree-oset-tests (Files): Likewise.
105797         * modules/rbtreehash-list-tests (Files): Likewise.
105798         * modules/readlink-tests (Files): Likewise.
105799         * modules/remove-tests (Files): Likewise.
105800         * modules/rename-tests (Files): Likewise.
105801         * modules/renameat-tests (Files): Likewise.
105802         * modules/rmdir-tests (Files): Likewise.
105803         * modules/round-tests (Files): Likewise.
105804         * modules/roundf-tests (Files): Likewise.
105805         * modules/roundl-tests (Files): Likewise.
105806         * modules/safe-alloc-tests (Files): Likewise.
105807         * modules/setenv-tests (Files): Likewise.
105808         * modules/sigaction-tests (Files): Likewise.
105809         * modules/signbit-tests (Files): Likewise.
105810         * modules/sleep-tests (Files): Likewise.
105811         * modules/snprintf-posix-tests (Files): Likewise.
105812         * modules/snprintf-tests (Files): Likewise.
105813         * modules/sprintf-posix-tests (Files): Likewise.
105814         * modules/stat-tests (Files): Likewise.
105815         * modules/stat-time-tests (Files): Likewise.
105816         * modules/strcasestr-tests (Files): Likewise.
105817         * modules/strchrnul-tests (Files): Likewise.
105818         * modules/strerror-tests (Files): Likewise.
105819         * modules/striconv-tests (Files): Likewise.
105820         * modules/striconveh-tests (Files): Likewise.
105821         * modules/striconveha-tests (Files): Likewise.
105822         * modules/strsignal-tests (Files): Likewise.
105823         * modules/strstr-tests (Files): Likewise.
105824         * modules/strtod-tests (Files): Likewise.
105825         * modules/strverscmp-tests (Files): Likewise.
105826         * modules/symlink-tests (Files): Likewise.
105827         * modules/symlinkat-tests (Files): Likewise.
105828         * modules/trunc-tests (Files): Likewise.
105829         * modules/truncf-tests (Files): Likewise.
105830         * modules/truncl-tests (Files): Likewise.
105831         * modules/uname-tests (Files): Likewise.
105832         * modules/unicase/cased-tests (Files): Likewise.
105833         * modules/unicase/ignorable-tests (Files): Likewise.
105834         * modules/unicase/locale-language-tests (Files): Likewise.
105835         * modules/unicase/tolower-tests (Files): Likewise.
105836         * modules/unicase/totitle-tests (Files): Likewise.
105837         * modules/unicase/toupper-tests (Files): Likewise.
105838         * modules/unicase/u8-casecmp-tests (Files): Likewise.
105839         * modules/unicase/u8-casecoll-tests (Files): Likewise.
105840         * modules/unicase/u8-casefold-tests (Files): Likewise.
105841         * modules/unicase/u8-is-cased-tests (Files): Likewise.
105842         * modules/unicase/u8-is-casefolded-tests (Files): Likewise.
105843         * modules/unicase/u8-is-lowercase-tests (Files): Likewise.
105844         * modules/unicase/u8-is-titlecase-tests (Files): Likewise.
105845         * modules/unicase/u8-is-uppercase-tests (Files): Likewise.
105846         * modules/unicase/u8-tolower-tests (Files): Likewise.
105847         * modules/unicase/u8-totitle-tests (Files): Likewise.
105848         * modules/unicase/u8-toupper-tests (Files): Likewise.
105849         * modules/unicase/u16-casecmp-tests (Files): Likewise.
105850         * modules/unicase/u16-casecoll-tests (Files): Likewise.
105851         * modules/unicase/u16-casefold-tests (Files): Likewise.
105852         * modules/unicase/u16-is-cased-tests (Files): Likewise.
105853         * modules/unicase/u16-is-casefolded-tests (Files): Likewise.
105854         * modules/unicase/u16-is-lowercase-tests (Files): Likewise.
105855         * modules/unicase/u16-is-titlecase-tests (Files): Likewise.
105856         * modules/unicase/u16-is-uppercase-tests (Files): Likewise.
105857         * modules/unicase/u16-tolower-tests (Files): Likewise.
105858         * modules/unicase/u16-totitle-tests (Files): Likewise.
105859         * modules/unicase/u16-toupper-tests (Files): Likewise.
105860         * modules/unicase/u32-casecmp-tests (Files): Likewise.
105861         * modules/unicase/u32-casecoll-tests (Files): Likewise.
105862         * modules/unicase/u32-casefold-tests (Files): Likewise.
105863         * modules/unicase/u32-is-cased-tests (Files): Likewise.
105864         * modules/unicase/u32-is-casefolded-tests (Files): Likewise.
105865         * modules/unicase/u32-is-lowercase-tests (Files): Likewise.
105866         * modules/unicase/u32-is-titlecase-tests (Files): Likewise.
105867         * modules/unicase/u32-is-uppercase-tests (Files): Likewise.
105868         * modules/unicase/u32-tolower-tests (Files): Likewise.
105869         * modules/unicase/u32-totitle-tests (Files): Likewise.
105870         * modules/unicase/u32-toupper-tests (Files): Likewise.
105871         * modules/unicase/ulc-casecmp-tests (Files): Likewise.
105872         * modules/unicase/ulc-casecoll-tests (Files): Likewise.
105873         * modules/uniconv/u8-conv-from-enc-tests (Files): Likewise.
105874         * modules/uniconv/u8-conv-to-enc-tests (Files): Likewise.
105875         * modules/uniconv/u8-strconv-from-enc-tests (Files): Likewise.
105876         * modules/uniconv/u8-strconv-to-enc-tests (Files): Likewise.
105877         * modules/uniconv/u16-conv-from-enc-tests (Files): Likewise.
105878         * modules/uniconv/u16-conv-to-enc-tests (Files): Likewise.
105879         * modules/uniconv/u16-strconv-from-enc-tests (Files): Likewise.
105880         * modules/uniconv/u16-strconv-to-enc-tests (Files): Likewise.
105881         * modules/uniconv/u32-conv-from-enc-tests (Files): Likewise.
105882         * modules/uniconv/u32-conv-to-enc-tests (Files): Likewise.
105883         * modules/uniconv/u32-strconv-from-enc-tests (Files): Likewise.
105884         * modules/uniconv/u32-strconv-to-enc-tests (Files): Likewise.
105885         * modules/unictype/bidicategory-byname-tests (Files): Likewise.
105886         * modules/unictype/bidicategory-name-tests (Files): Likewise.
105887         * modules/unictype/bidicategory-of-tests (Files): Likewise.
105888         * modules/unictype/bidicategory-test-tests (Files): Likewise.
105889         * modules/unictype/block-list-tests (Files): Likewise.
105890         * modules/unictype/block-of-tests (Files): Likewise.
105891         * modules/unictype/block-test-tests (Files): Likewise.
105892         * modules/unictype/category-C-tests (Files): Likewise.
105893         * modules/unictype/category-Cc-tests (Files): Likewise.
105894         * modules/unictype/category-Cf-tests (Files): Likewise.
105895         * modules/unictype/category-Cn-tests (Files): Likewise.
105896         * modules/unictype/category-Co-tests (Files): Likewise.
105897         * modules/unictype/category-Cs-tests (Files): Likewise.
105898         * modules/unictype/category-L-tests (Files): Likewise.
105899         * modules/unictype/category-Ll-tests (Files): Likewise.
105900         * modules/unictype/category-Lm-tests (Files): Likewise.
105901         * modules/unictype/category-Lo-tests (Files): Likewise.
105902         * modules/unictype/category-Lt-tests (Files): Likewise.
105903         * modules/unictype/category-Lu-tests (Files): Likewise.
105904         * modules/unictype/category-M-tests (Files): Likewise.
105905         * modules/unictype/category-Mc-tests (Files): Likewise.
105906         * modules/unictype/category-Me-tests (Files): Likewise.
105907         * modules/unictype/category-Mn-tests (Files): Likewise.
105908         * modules/unictype/category-N-tests (Files): Likewise.
105909         * modules/unictype/category-Nd-tests (Files): Likewise.
105910         * modules/unictype/category-Nl-tests (Files): Likewise.
105911         * modules/unictype/category-No-tests (Files): Likewise.
105912         * modules/unictype/category-P-tests (Files): Likewise.
105913         * modules/unictype/category-Pc-tests (Files): Likewise.
105914         * modules/unictype/category-Pd-tests (Files): Likewise.
105915         * modules/unictype/category-Pe-tests (Files): Likewise.
105916         * modules/unictype/category-Pf-tests (Files): Likewise.
105917         * modules/unictype/category-Pi-tests (Files): Likewise.
105918         * modules/unictype/category-Po-tests (Files): Likewise.
105919         * modules/unictype/category-Ps-tests (Files): Likewise.
105920         * modules/unictype/category-S-tests (Files): Likewise.
105921         * modules/unictype/category-Sc-tests (Files): Likewise.
105922         * modules/unictype/category-Sk-tests (Files): Likewise.
105923         * modules/unictype/category-Sm-tests (Files): Likewise.
105924         * modules/unictype/category-So-tests (Files): Likewise.
105925         * modules/unictype/category-Z-tests (Files): Likewise.
105926         * modules/unictype/category-Zl-tests (Files): Likewise.
105927         * modules/unictype/category-Zp-tests (Files): Likewise.
105928         * modules/unictype/category-Zs-tests (Files): Likewise.
105929         * modules/unictype/category-and-not-tests (Files): Likewise.
105930         * modules/unictype/category-and-tests (Files): Likewise.
105931         * modules/unictype/category-byname-tests (Files): Likewise.
105932         * modules/unictype/category-name-tests (Files): Likewise.
105933         * modules/unictype/category-none-tests (Files): Likewise.
105934         * modules/unictype/category-of-tests (Files): Likewise.
105935         * modules/unictype/category-or-tests (Files): Likewise.
105936         * modules/unictype/category-test-withtable-tests (Files): Likewise.
105937         * modules/unictype/combining-class-tests (Files): Likewise.
105938         * modules/unictype/ctype-alnum-tests (Files): Likewise.
105939         * modules/unictype/ctype-alpha-tests (Files): Likewise.
105940         * modules/unictype/ctype-blank-tests (Files): Likewise.
105941         * modules/unictype/ctype-cntrl-tests (Files): Likewise.
105942         * modules/unictype/ctype-digit-tests (Files): Likewise.
105943         * modules/unictype/ctype-graph-tests (Files): Likewise.
105944         * modules/unictype/ctype-lower-tests (Files): Likewise.
105945         * modules/unictype/ctype-print-tests (Files): Likewise.
105946         * modules/unictype/ctype-punct-tests (Files): Likewise.
105947         * modules/unictype/ctype-space-tests (Files): Likewise.
105948         * modules/unictype/ctype-upper-tests (Files): Likewise.
105949         * modules/unictype/ctype-xdigit-tests (Files): Likewise.
105950         * modules/unictype/decimal-digit-tests (Files): Likewise.
105951         * modules/unictype/digit-tests (Files): Likewise.
105952         * modules/unictype/mirror-tests (Files): Likewise.
105953         * modules/unictype/numeric-tests (Files): Likewise.
105954         * modules/unictype/property-alphabetic-tests (Files): Likewise.
105955         * modules/unictype/property-ascii-hex-digit-tests (Files): Likewise.
105956         * modules/unictype/property-bidi-arabic-digit-tests (Files): Likewise.
105957         * modules/unictype/property-bidi-arabic-right-to-left-tests (Files):
105958         Likewise.
105959         * modules/unictype/property-bidi-block-separator-tests (Files):
105960         Likewise.
105961         * modules/unictype/property-bidi-boundary-neutral-tests (Files):
105962         Likewise.
105963         * modules/unictype/property-bidi-common-separator-tests (Files):
105964         Likewise.
105965         * modules/unictype/property-bidi-control-tests (Files): Likewise.
105966         * modules/unictype/property-bidi-embedding-or-override-tests (Files):
105967         Likewise.
105968         * modules/unictype/property-bidi-eur-num-separator-tests (Files):
105969         Likewise.
105970         * modules/unictype/property-bidi-eur-num-terminator-tests (Files):
105971         Likewise.
105972         * modules/unictype/property-bidi-european-digit-tests (Files): Likewise.
105973         * modules/unictype/property-bidi-hebrew-right-to-left-tests (Files):
105974         Likewise.
105975         * modules/unictype/property-bidi-left-to-right-tests (Files): Likewise.
105976         * modules/unictype/property-bidi-non-spacing-mark-tests (Files):
105977         Likewise.
105978         * modules/unictype/property-bidi-other-neutral-tests (Files): Likewise.
105979         * modules/unictype/property-bidi-pdf-tests (Files): Likewise.
105980         * modules/unictype/property-bidi-segment-separator-tests (Files):
105981         Likewise.
105982         * modules/unictype/property-bidi-whitespace-tests (Files): Likewise.
105983         * modules/unictype/property-byname-tests (Files): Likewise.
105984         * modules/unictype/property-combining-tests (Files): Likewise.
105985         * modules/unictype/property-composite-tests (Files): Likewise.
105986         * modules/unictype/property-currency-symbol-tests (Files): Likewise.
105987         * modules/unictype/property-dash-tests (Files): Likewise.
105988         * modules/unictype/property-decimal-digit-tests (Files): Likewise.
105989         * modules/unictype/property-default-ignorable-code-point-tests (Files):
105990         Likewise.
105991         * modules/unictype/property-deprecated-tests (Files): Likewise.
105992         * modules/unictype/property-diacritic-tests (Files): Likewise.
105993         * modules/unictype/property-extender-tests (Files): Likewise.
105994         * modules/unictype/property-format-control-tests (Files): Likewise.
105995         * modules/unictype/property-grapheme-base-tests (Files): Likewise.
105996         * modules/unictype/property-grapheme-extend-tests (Files): Likewise.
105997         * modules/unictype/property-grapheme-link-tests (Files): Likewise.
105998         * modules/unictype/property-hex-digit-tests (Files): Likewise.
105999         * modules/unictype/property-hyphen-tests (Files): Likewise.
106000         * modules/unictype/property-id-continue-tests (Files): Likewise.
106001         * modules/unictype/property-id-start-tests (Files): Likewise.
106002         * modules/unictype/property-ideographic-tests (Files): Likewise.
106003         * modules/unictype/property-ids-binary-operator-tests (Files): Likewise.
106004         * modules/unictype/property-ids-trinary-operator-tests (Files):
106005         Likewise.
106006         * modules/unictype/property-ignorable-control-tests (Files): Likewise.
106007         * modules/unictype/property-iso-control-tests (Files): Likewise.
106008         * modules/unictype/property-join-control-tests (Files): Likewise.
106009         * modules/unictype/property-left-of-pair-tests (Files): Likewise.
106010         * modules/unictype/property-line-separator-tests (Files): Likewise.
106011         * modules/unictype/property-logical-order-exception-tests (Files):
106012         Likewise.
106013         * modules/unictype/property-lowercase-tests (Files): Likewise.
106014         * modules/unictype/property-math-tests (Files): Likewise.
106015         * modules/unictype/property-non-break-tests (Files): Likewise.
106016         * modules/unictype/property-not-a-character-tests (Files): Likewise.
106017         * modules/unictype/property-numeric-tests (Files): Likewise.
106018         * modules/unictype/property-other-alphabetic-tests (Files): Likewise.
106019         * modules/unictype/property-other-default-ignorable-code-point-tests
106020         (Files): Likewise.
106021         * modules/unictype/property-other-grapheme-extend-tests (Files):
106022         Likewise.
106023         * modules/unictype/property-other-id-continue-tests (Files): Likewise.
106024         * modules/unictype/property-other-id-start-tests (Files): Likewise.
106025         * modules/unictype/property-other-lowercase-tests (Files): Likewise.
106026         * modules/unictype/property-other-math-tests (Files): Likewise.
106027         * modules/unictype/property-other-uppercase-tests (Files): Likewise.
106028         * modules/unictype/property-paired-punctuation-tests (Files): Likewise.
106029         * modules/unictype/property-paragraph-separator-tests (Files): Likewise.
106030         * modules/unictype/property-pattern-syntax-tests (Files): Likewise.
106031         * modules/unictype/property-pattern-white-space-tests (Files): Likewise.
106032         * modules/unictype/property-private-use-tests (Files): Likewise.
106033         * modules/unictype/property-punctuation-tests (Files): Likewise.
106034         * modules/unictype/property-quotation-mark-tests (Files): Likewise.
106035         * modules/unictype/property-radical-tests (Files): Likewise.
106036         * modules/unictype/property-sentence-terminal-tests (Files): Likewise.
106037         * modules/unictype/property-soft-dotted-tests (Files): Likewise.
106038         * modules/unictype/property-space-tests (Files): Likewise.
106039         * modules/unictype/property-terminal-punctuation-tests (Files):
106040         Likewise.
106041         * modules/unictype/property-test-tests (Files): Likewise.
106042         * modules/unictype/property-titlecase-tests (Files): Likewise.
106043         * modules/unictype/property-unassigned-code-value-tests (Files):
106044         Likewise.
106045         * modules/unictype/property-unified-ideograph-tests (Files): Likewise.
106046         * modules/unictype/property-uppercase-tests (Files): Likewise.
106047         * modules/unictype/property-variation-selector-tests (Files): Likewise.
106048         * modules/unictype/property-white-space-tests (Files): Likewise.
106049         * modules/unictype/property-xid-continue-tests (Files): Likewise.
106050         * modules/unictype/property-xid-start-tests (Files): Likewise.
106051         * modules/unictype/property-zero-width-tests (Files): Likewise.
106052         * modules/unictype/scripts-tests (Files): Likewise.
106053         * modules/unictype/syntax-c-ident-tests (Files): Likewise.
106054         * modules/unictype/syntax-c-whitespace-tests (Files): Likewise.
106055         * modules/unictype/syntax-java-ident-tests (Files): Likewise.
106056         * modules/unictype/syntax-java-whitespace-tests (Files): Likewise.
106057         * modules/unilbrk/u8-possible-linebreaks-tests (Files): Likewise.
106058         * modules/unilbrk/u8-width-linebreaks-tests (Files): Likewise.
106059         * modules/unilbrk/u16-possible-linebreaks-tests (Files): Likewise.
106060         * modules/unilbrk/u16-width-linebreaks-tests (Files): Likewise.
106061         * modules/unilbrk/u32-possible-linebreaks-tests (Files): Likewise.
106062         * modules/unilbrk/u32-width-linebreaks-tests (Files): Likewise.
106063         * modules/unilbrk/ulc-possible-linebreaks-tests (Files): Likewise.
106064         * modules/unilbrk/ulc-width-linebreaks-tests (Files): Likewise.
106065         * modules/uninorm/canonical-decomposition-tests (Files): Likewise.
106066         * modules/uninorm/compat-decomposition-tests (Files): Likewise.
106067         * modules/uninorm/composition-tests (Files): Likewise.
106068         * modules/uninorm/decomposing-form-tests (Files): Likewise.
106069         * modules/uninorm/decomposition-tests (Files): Likewise.
106070         * modules/uninorm/filter-tests (Files): Likewise.
106071         * modules/uninorm/nfc-tests (Files): Likewise.
106072         * modules/uninorm/nfd-tests (Files): Likewise.
106073         * modules/uninorm/nfkc-tests (Files): Likewise.
106074         * modules/uninorm/nfkd-tests (Files): Likewise.
106075         * modules/uninorm/u8-normcmp-tests (Files): Likewise.
106076         * modules/uninorm/u8-normcoll-tests (Files): Likewise.
106077         * modules/uninorm/u16-normcmp-tests (Files): Likewise.
106078         * modules/uninorm/u16-normcoll-tests (Files): Likewise.
106079         * modules/uninorm/u32-normcmp-tests (Files): Likewise.
106080         * modules/uninorm/u32-normcoll-tests (Files): Likewise.
106081         * modules/unistdio/u8-asnprintf-tests (Files): Likewise.
106082         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
106083         * modules/unistdio/u8-vasprintf-tests (Files): Likewise.
106084         * modules/unistdio/u8-vsnprintf-tests (Files): Likewise.
106085         * modules/unistdio/u8-vsprintf-tests (Files): Likewise.
106086         * modules/unistdio/u16-asnprintf-tests (Files): Likewise.
106087         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
106088         * modules/unistdio/u16-vasprintf-tests (Files): Likewise.
106089         * modules/unistdio/u16-vsnprintf-tests (Files): Likewise.
106090         * modules/unistdio/u16-vsprintf-tests (Files): Likewise.
106091         * modules/unistdio/u32-asnprintf-tests (Files): Likewise.
106092         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
106093         * modules/unistdio/u32-vasprintf-tests (Files): Likewise.
106094         * modules/unistdio/u32-vsnprintf-tests (Files): Likewise.
106095         * modules/unistdio/u32-vsprintf-tests (Files): Likewise.
106096         * modules/unistdio/ulc-asnprintf-tests (Files): Likewise.
106097         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
106098         * modules/unistdio/ulc-vasprintf-tests (Files): Likewise.
106099         * modules/unistdio/ulc-vsnprintf-tests (Files): Likewise.
106100         * modules/unistdio/ulc-vsprintf-tests (Files): Likewise.
106101         * modules/uniwbrk/u8-wordbreaks-tests (Files): Likewise.
106102         * modules/uniwbrk/u16-wordbreaks-tests (Files): Likewise.
106103         * modules/uniwbrk/u32-wordbreaks-tests (Files): Likewise.
106104         * modules/uniwbrk/ulc-wordbreaks-tests (Files): Likewise.
106105         * modules/uniwidth/u8-strwidth-tests (Files): Likewise.
106106         * modules/uniwidth/u8-width-tests (Files): Likewise.
106107         * modules/uniwidth/u16-strwidth-tests (Files): Likewise.
106108         * modules/uniwidth/u16-width-tests (Files): Likewise.
106109         * modules/uniwidth/u32-strwidth-tests (Files): Likewise.
106110         * modules/uniwidth/u32-width-tests (Files): Likewise.
106111         * modules/uniwidth/width-tests (Files): Likewise.
106112         * modules/unlink-tests (Files): Likewise.
106113         * modules/unsetenv-tests (Files): Likewise.
106114         * modules/usleep-tests (Files): Likewise.
106115         * modules/utimens-tests (Files): Likewise.
106116         * modules/utimensat-tests (Files): Likewise.
106117         * modules/vasnprintf-posix-tests (Files): Likewise.
106118         * modules/vasnprintf-tests (Files): Likewise.
106119         * modules/vasprintf-posix-tests (Files): Likewise.
106120         * modules/vasprintf-tests (Files): Likewise.
106121         * modules/vdprintf-posix-tests (Files): Likewise.
106122         * modules/vfprintf-posix-tests (Files): Likewise.
106123         * modules/vprintf-posix-tests (Files): Likewise.
106124         * modules/vsnprintf-posix-tests (Files): Likewise.
106125         * modules/vsnprintf-tests (Files): Likewise.
106126         * modules/vsprintf-posix-tests (Files): Likewise.
106127         * modules/wcrtomb-tests (Files): Likewise.
106128         * modules/wcsnrtombs-tests (Files): Likewise.
106129         * modules/wcsrtombs-tests (Files): Likewise.
106130         * modules/wctype-tests (Files): Likewise.
106131         * modules/wcwidth-tests (Files): Likewise.
106132         * modules/xmemdup0-tests (Files): Likewise.
106133         * modules/xprintf-posix-tests (Files): Likewise.
106134         * modules/xvasprintf-tests (Files): Likewise.
106136 2009-12-24  Eric Blake  <ebb9@byu.net>
106138         test-nanosleep: fix typo
106139         * tests/test-nanosleep.c (SIGNATURE_CHECK): Fix typo in previous
106140         patch.
106141         Reported by Bruno Haible.
106143 2009-12-24  Bruno Haible  <bruno@clisp.org>
106145         Reduce namespace pollution on glibc systems.
106146         * lib/inttypes.in.h: Don't include <stdint.h> on glibc systems.
106147         * lib/stdlib.in.h: Don't include <stdint.h>, <unistd.h> on glibc
106148         systems.
106149         * lib/unistd.in.h: Don't include <stdio.h>, <fcntl.h>, <stdlib.h>,
106150         <getopt.h> on glibc systems.
106151         * lib/fcntl.in.h: Don't include <sys/stat.h>, <unistd.h> on glibc
106152         systems.
106153         * lib/fcntl.c: Include <unistd.h> here instead.
106155 2009-12-24  Bruno Haible  <bruno@clisp.org>
106157         * lib/stdlib.in.h (includes): Fix typo in today's commit.
106159 2009-12-24  Eric Blake  <ebb9@byu.net>
106161         tests: add signature checks
106162         * tests/signature.h (SIGNATURE_CHECK): New file.
106163         * modules/atexit-tests (Files): Use it.
106164         * modules/btowc-tests (Files): Likewise.
106165         * modules/canonicalize-lgpl-tests (Files): Likewise.
106166         * modules/ceilf-tests (Files): Likewise.
106167         * modules/ceill-tests (Files): Likewise.
106168         * modules/chown-tests (Files): Likewise.
106169         * modules/dprintf-posix-tests (Files): Likewise.
106170         * modules/dup2-tests (Files): Likewise.
106171         * modules/dup3-tests (Files): Likewise.
106172         * modules/duplocale-tests (Files): Likewise.
106173         * modules/fchdir-tests (Files): Likewise.
106174         * modules/fcntl-tests (Files): Likewise.
106175         * modules/fdopendir-tests (Files): Likewise.
106176         * modules/fflush-tests (Files): Likewise.
106177         * modules/flock-tests (Files): Likewise.
106178         * modules/floorf-tests (Files): Likewise.
106179         * modules/floorl-tests (Files): Likewise.
106180         * modules/fnmatch-tests (Files): Likewise.
106181         * modules/fopen-tests (Files): Likewise.
106182         * modules/fprintf-posix-tests (Files): Likewise.
106183         * modules/freopen-tests (Files): Likewise.
106184         * modules/frexp-nolibm-tests (Files): Likewise.
106185         * modules/frexp-tests (Files): Likewise.
106186         * modules/frexpl-nolibm-tests (Files): Likewise.
106187         * modules/frexpl-tests (Files): Likewise.
106188         * modules/fseek-tests (Files): Likewise.
106189         * modules/fseeko-tests (Files): Likewise.
106190         * modules/fsync-tests (Files): Likewise.
106191         * modules/ftell-tests (Files): Likewise.
106192         * modules/ftello-tests (Files): Likewise.
106193         * modules/futimens-tests (Files): Likewise.
106194         * modules/getaddrinfo-tests (Files): Likewise.
106195         * modules/getcwd-tests (Files): Likewise.
106196         * modules/getdelim-tests (Files): Likewise.
106197         * modules/getdtablesize-tests (Files): Likewise.
106198         * modules/getgroups-tests (Files): Likewise.
106199         * modules/gethostname-tests (Files): Likewise.
106200         * modules/getline-tests (Files): Likewise.
106201         * modules/getopt-posix-tests (Files): Likewise.
106202         * modules/gettimeofday-tests (Files): Likewise.
106203         * modules/glob-tests (Files): Likewise.
106204         * modules/iconv-tests (Files): Likewise.
106205         * modules/inet_ntop-tests (Files): Likewise.
106206         * modules/inet_pton-tests (Files): Likewise.
106207         * modules/isblank-tests (Files): Likewise.
106208         * modules/lchown-tests (Files): Likewise.
106209         * modules/ldexpl-tests (Files): Likewise.
106210         * modules/link-tests (Files): Likewise.
106211         * modules/linkat-tests (Files): Likewise.
106212         * modules/lseek-tests (Files): Likewise.
106213         * modules/lstat-tests (Files): Likewise.
106214         * modules/mbrtowc-tests (Files): Likewise.
106215         * modules/mbsinit-tests (Files): Likewise.
106216         * modules/mbsnrtowcs-tests (Files): Likewise.
106217         * modules/mbsrtowcs-tests (Files): Likewise.
106218         * modules/memchr-tests (Files): Likewise.
106219         * modules/memcmp-tests (Files): Likewise.
106220         * modules/memmem-tests (Files): Likewise.
106221         * modules/memrchr-tests (Files): Likewise.
106222         * modules/mkdir-tests (Files): Likewise.
106223         * modules/mkfifo-tests (Files): Likewise.
106224         * modules/mkfifoat-tests (Files): Likewise.
106225         * modules/mknod-tests (Files): Likewise.
106226         * modules/nanosleep-tests (Files): Likewise.
106227         * modules/nl_langinfo-tests (Files): Likewise.
106228         * modules/obstack-printf-tests (Files): Likewise.
106229         * modules/open-tests (Files): Likewise.
106230         * modules/openat-tests (Files): Likewise.
106231         * modules/perror-tests (Files): Likewise.
106232         * modules/pipe2-tests (Files): Likewise.
106233         * modules/poll-tests (Files): Likewise.
106234         * modules/popen-tests (Files): Likewise.
106235         * modules/posix_spawn-tests (Files): Likewise.
106236         * modules/posix_spawnp-tests (Files): Likewise.
106237         * modules/pread-tests (Files): Likewise.
106238         * modules/printf-posix-tests (Files): Likewise.
106239         * modules/pty-tests (Files): Likewise.
106240         * modules/random_r-tests (Files): Likewise.
106241         * modules/rawmemchr-tests (Files): Likewise.
106242         * modules/readlink-tests (Files): Likewise.
106243         * modules/remove-tests (Files): Likewise.
106244         * modules/rename-tests (Files): Likewise.
106245         * modules/renameat-tests (Files): Likewise.
106246         * modules/rmdir-tests (Files): Likewise.
106247         * modules/round-tests (Files): Likewise.
106248         * modules/roundf-tests (Files): Likewise.
106249         * modules/roundl-tests (Files): Likewise.
106250         * modules/select-tests (Files): Likewise.
106251         * modules/setenv-tests (Files): Likewise.
106252         * modules/sigaction-tests (Files): Likewise.
106253         * modules/sleep-tests (Files): Likewise.
106254         * modules/snprintf-posix-tests (Files): Likewise.
106255         * modules/snprintf-tests (Files): Likewise.
106256         * modules/sprintf-posix-tests (Files): Likewise.
106257         * modules/stat-tests (Files): Likewise.
106258         * modules/strcasestr-tests (Files): Likewise.
106259         * modules/strchrnul-tests (Files): Likewise.
106260         * modules/strerror-tests (Files): Likewise.
106261         * modules/strsignal-tests (Files): Likewise.
106262         * modules/strstr-tests (Files): Likewise.
106263         * modules/strtod-tests (Files): Likewise.
106264         * modules/strverscmp-tests (Files): Likewise.
106265         * modules/symlink-tests (Files): Likewise.
106266         * modules/symlinkat-tests (Files): Likewise.
106267         * modules/times-tests (Files): Likewise.
106268         * modules/trunc-tests (Files): Likewise.
106269         * modules/truncf-tests (Files): Likewise.
106270         * modules/truncl-tests (Files): Likewise.
106271         * modules/tsearch-tests (Files): Likewise.
106272         * modules/uname-tests (Files): Likewise.
106273         * modules/unlink-tests (Files): Likewise.
106274         * modules/unsetenv-tests (Files): Likewise.
106275         * modules/usleep-tests (Files): Likewise.
106276         * modules/utimensat-tests (Files): Likewise.
106277         * modules/vasprintf-tests (Files): Likewise.
106278         * modules/vdprintf-posix-tests (Files): Likewise.
106279         * modules/vfprintf-posix-tests (Files): Likewise.
106280         * modules/vprintf-posix-tests (Files): Likewise.
106281         * modules/vsnprintf-posix-tests (Files): Likewise.
106282         * modules/vsnprintf-tests (Files): Likewise.
106283         * modules/vsprintf-posix-tests (Files): Likewise.
106284         * modules/wcrtomb-tests (Files): Likewise.
106285         * modules/wcsnrtombs-tests (Files): Likewise.
106286         * modules/wcsrtombs-tests (Files): Likewise.
106287         * modules/wcwidth-tests (Files): Likewise.
106288         * tests/test-isfinite.c (isfinite): Ensure macro declaration.
106289         * tests/test-isinf.c (isinf): Likewise.
106290         * tests/test-isnan.c (isnan): Likewise.
106291         * tests/test-signbit.c (signbit): Likewise.
106292         * tests/test-select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): Ensure
106293         declaration, either as macro or with correct signature.
106294         (select): Ensure function under test is declared with correct
106295         signature in correct header.
106296         * tests/test-atexit.c (atexit): Likewise.
106297         * tests/test-btowc.c (btowc): Likewise.
106298         * tests/test-canonicalize-lgpl.c (realpath)
106299         (canonicalize_file_name): Likewise.
106300         * tests/test-ceilf1.c (ceilf): Likewise.
106301         * tests/test-ceill.c (ceill): Likewise.
106302         * tests/test-chown.c (chown): Likewise.
106303         * tests/test-dprintf-posix.c (dprintf): Likewise.
106304         * tests/test-dup2.c (dup2): Likewise.
106305         * tests/test-dup3.c (dup3): Likewise.
106306         * tests/test-duplocale.c (duplocale): Likewise.
106307         * tests/test-fchdir.c (fchdir): Likewise.
106308         * tests/test-fchownat.c (fchownat): Likewise.
106309         * tests/test-fcntl.c (fcntl): Likewise.
106310         * tests/test-fdopendir.c (fdopendir): Likewise.
106311         * tests/test-fflush.c (fflush): Likewise.
106312         * tests/test-flock.c (flock): Likewise.
106313         * tests/test-floorf1.c (floorf): Likewise.
106314         * tests/test-floorl.c (floorl): Likewise.
106315         * tests/test-fnmatch.c (fnmatch): Likewise.
106316         * tests/test-fopen.c (fopen): Likewise.
106317         * tests/test-fprintf-posix.c (fprintf): Likewise.
106318         * tests/test-freopen.c (freopen): Likewise.
106319         * tests/test-frexp.c (frexp): Likewise.
106320         * tests/test-frexpl.c (frexpl): Likewise.
106321         * tests/test-fseek.c (fseek): Likewise.
106322         * tests/test-fseeko.c (fseeko): Likewise.
106323         * tests/test-fstatat.c (fstatat): Likewise.
106324         * tests/test-fsync.c (fsync): Likewise.
106325         * tests/test-ftell.c (ftell): Likewise.
106326         * tests/test-ftello.c (ftello): Likewise.
106327         * tests/test-futimens.c (futimens): Likewise.
106328         * tests/test-getaddrinfo.c (getaddrinfo, freeaddrinfo)
106329         (gai_strerror): Likewise.
106330         * tests/test-getcwd.c (getcwd): Likewise.
106331         * tests/test-getdelim.c (getdelim): Likewise.
106332         * tests/test-getdtablesize.c (getdtablesize): Likewise.
106333         * tests/test-getgroups.c (getgroups): Likewise.
106334         * tests/test-gethostname.c (gethostname): Likewise.
106335         * tests/test-getline.c (getline): Likewise.
106336         * tests/test-getopt.c (getopt, getopt_long, getopt_long_only):
106337         Likewise.
106338         * tests/test-gettimeofday.c (gettimeofday): Likewise.
106339         * tests/test-glob.c (glob, globfree): Likewise.
106340         * tests/test-iconv.c (iconv, iconv_open, iconv_close): Likewise.
106341         * tests/test-inet_ntop.c (inet_ntop): Likewise.
106342         * tests/test-inet_pton.c (inet_pton): Likewise.
106343         * tests/test-isblank.c (isblank): Likewise.
106344         * tests/test-lchown.c (lchown): Likewise.
106345         * tests/test-ldexpl.c (ldexpl): Likewise.
106346         * tests/test-link.c (link): Likewise.
106347         * tests/test-linkat.c (linkat): Likewise.
106348         * tests/test-lseek.c (lseek): Likewise.
106349         * tests/test-lstat.c (lstat): Likewise.
106350         * tests/test-mbrtowc.c (mbrtowc): Likewise.
106351         * tests/test-mbsinit.c (mbsinit): Likewise.
106352         * tests/test-mbsnrtowcs.c (mbsnrtowcs): Likewise.
106353         * tests/test-mbsrtowcs.c (mbsrtowcs): Likewise.
106354         * tests/test-memchr.c (memchr): Likewise.
106355         * tests/test-memcmp.c (memcmp): Likewise.
106356         * tests/test-memmem.c (memmem): Likewise.
106357         * tests/test-memrchr.c (memrchr): Likewise.
106358         * tests/test-mkdir.c (mkdir): Likewise.
106359         * tests/test-mkdirat.c (mkdirat): Likewise.
106360         * tests/test-mkfifo.c (mkfifo): Likewise.
106361         * tests/test-mkfifoat.c (mkfifoat, mknodat): Likewise.
106362         * tests/test-mknod.c (mknod): Likewise.
106363         * tests/test-nanosleep.c (nanosleep): Likewise.
106364         * tests/test-nl_langinfo.c (nl_langinfo): Likewise.
106365         * tests/test-obstack-printf.c (obstack_printf, obstack_vprintf):
106366         Likewise.
106367         * tests/test-open.c (open): Likewise.
106368         * tests/test-openat.c (openat): Likewise.
106369         * tests/test-perror.c (perror): Likewise.
106370         * tests/test-pipe2.c (pipe2): Likewise.
106371         * tests/test-poll.c (poll): Likewise.
106372         * tests/test-popen.c (popen, pclose): Likewise.
106373         * tests/test-posix_spawn1.c (posix_spawnp, posix_spawnattr_init)
106374         (posix_spawnattr_destroy, posix_spawnattr_setsigmask)
106375         (posix_spawnattr_setflags, posix_spawn_file_actions_init)
106376         (posix_spawn_file_actions_destroy)
106377         (posix_spawn_file_actions_addclose)
106378         (posix_spawn_file_actions_addopen)
106379         (posix_spawn_file_actions_adddup2): Likewise.
106380         * tests/test-posix_spawn3.c (posix_spawn): Likewise.
106381         * tests/test-pread.c (pread): Likewise.
106382         * tests/test-printf-posix.c (printf): Likewise.
106383         * tests/test-pty.c (openpty, forkpty): Likewise.
106384         * tests/test-random_r.c (srandom_r, initstate_r, setstate_r)
106385         (random_r): Likewise.
106386         * tests/test-rawmemchr.c (rawmemchr): Likewise.
106387         * tests/test-readlink.c (readlink): Likewise.
106388         * tests/test-remove.c (remove): Likewise.
106389         * tests/test-rename.c (rename): Likewise.
106390         * tests/test-renameat.c (renameat): Likewise.
106391         * tests/test-rmdir.c (rmdir): Likewise.
106392         * tests/test-round1.c (round): Likewise.
106393         * tests/test-roundf1.c (roundf): Likewise.
106394         * tests/test-roundl.c (roundl): Likewise.
106395         * tests/test-setenv.c (setenv): Likewise.
106396         * tests/test-sigaction.c (sigaction): Likewise.
106397         * tests/test-sleep.c (sleep): Likewise.
106398         * tests/test-snprintf.c (snprintf): Likewise.
106399         * tests/test-sprintf-posix.c (sprintf): Likewise.
106400         * tests/test-stat.c (stat): Likewise.
106401         * tests/test-stpncpy.c (stpncpy): Likewise.
106402         * tests/test-strcasestr.c (strcasestr): Likewise.
106403         * tests/test-strchrnul.c (strchrnul): Likewise.
106404         * tests/test-strerror.c (strerror): Likewise.
106405         * tests/test-strsignal.c (strsignal): Likewise.
106406         * tests/test-strstr.c (strstr): Likewise.
106407         * tests/test-strtod.c (strtod): Likewise.
106408         * tests/test-strverscmp.c (strverscmp): Likewise.
106409         * tests/test-symlink.c (symlink): Likewise.
106410         * tests/test-symlinkat.c (symlinkat, readlinkat): Likewise.
106411         * tests/test-times.c (times): Likewise.
106412         * tests/test-trunc1.c (trunc): Likewise.
106413         * tests/test-truncf1.c (truncf): Likewise.
106414         * tests/test-truncl.c (truncl): Likewise.
106415         * tests/test-tsearch.c (tdelete, tfind, tsearch, twalk):
106416         Likewise.
106417         * tests/test-uname.c (uname): Likewise.
106418         * tests/test-unlink.c (unlink): Likewise.
106419         * tests/test-unlinkat.c (unlinkat): Likewise.
106420         * tests/test-unsetenv.c (unsetenv): Likewise.
106421         * tests/test-usleep.c (usleep): Likewise.
106422         * tests/test-utimensat.c (utimensat): Likewise.
106423         * tests/test-vasprintf.c (asprintf, vasprintf): Likewise.
106424         * tests/test-vdprintf-posix.c (vdprintf): Likewise.
106425         * tests/test-vfprintf-posix.c (vfprintf): Likewise.
106426         * tests/test-vprintf-posix.c (vprintf): Likewise.
106427         * tests/test-vsnprintf.c (vsnprintf): Likewise.
106428         * tests/test-vsprintf-posix.c (vsprintf): Likewise.
106429         * tests/test-wcrtomb.c (wcrtomb): Likewise.
106430         * tests/test-wcsnrtombs.c (wcsnrtombs): Likewise.
106431         * tests/test-wcsrtombs.c (wcsrtombs): Likewise.
106432         * tests/test-wcwidth.c (wcwidth): Likewise.
106434         build: pull in conditional headers during GNULIB_POSIXCHECK
106435         * lib/stdio.in.h (includes): Using GNULIB_POSIXCHECK also requires
106436         definitions from any conditionally-included headers.
106437         * lib/stdlib.in.h (includes): Likewise.
106438         * lib/unistd.in.h (includes): Likewise.
106440 2009-12-24  Bruno Haible  <bruno@clisp.org>
106442         * tests/test-argv-iter.c: Include header file being tested immediately
106443         after config.h.
106444         * tests/test-base64.c: Likewise.
106445         * tests/test-flock.c: Likewise.
106446         * tests/test-fsync.c: Likewise.
106447         * tests/test-getdate.c: Likewise.
106448         * tests/test-getndelim2.c: Likewise.
106449         * tests/test-isfinite.c: Likewise.
106450         * tests/test-isinf.c: Likewise.
106451         * tests/test-strerror.c: Likewise.
106452         * tests/test-strsignal.c: Likewise.
106454 2009-12-23  Eric Blake  <ebb9@byu.net>
106456         unistd: work around cygwin bug
106457         * lib/unistd.in.h (includes): Pick up headers needed for cygwin.
106458         * doc/posix-functions/unlinkat.texi (unlinkat): Document the bug.
106459         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
106461 2009-12-23  Bruno Haible  <bruno@clisp.org>
106463         localename: More tests.
106464         * tests/test-localename.c (SIZEOF): New macro.
106465         (categories): New variable.
106466         (test_locale_name, test_locale_name_posix, test_locale_name_environ,
106467         test_locale_name_default): Add test w.r.t. thread locale.
106468         (test_locale_name_thread): New function.
106469         (main): Invoke it.
106471         localename: Make aware of thread locale.
106472         * lib/localename.h (gl_locale_name_thread): New declaration.
106473         (gl_locale_name, gl_locale_name_posix, gl_locale_name_default): Clarify
106474         behaviour with respect to thread locale.
106475         * lib/localename.c: Include <limits.h>, <stddef.h>, <xlocale.h>,
106476         <langinfo.h>, glthread/lock.h.
106477         (SIZE_BITS): New macro.
106478         (string_hash): New function.
106479         (struct hash_node): New type.
106480         (HASH_TABLE_SIZE): New macro.
106481         (struniq_hash_table, struniq_lock): New variables.
106482         (struniq): New function.
106483         (gl_locale_name_thread): New function.
106484         (gl_locale_name): Invoke it.
106485         * m4/localename.m4 (gl_LOCALENAME): Test for uselocale function.
106486         * modules/localename (Depends-on): Add lock.
106487         Reported by Mike Gran <spk121@yahoo.com>.
106489 2009-12-23  Eric Blake  <ebb9@byu.net>
106491         va-args: new module
106492         * modules/va-args: New file.
106493         * m4/va-args.m4 (gl_VA_ARGS): Likewise.
106494         * MODULES.html.sh (Core language properties): Mention it.
106496         gnulib-common: prefer _GL_UNUSED over _UNUSED_PARAMETER_
106497         * m4/gnulib-common.m4 (gl_COMMON): Create a more-appropriately
106498         named alias for __attribute__((__unused__)).
106499         * lib/chown.c: Update client.
106500         * lib/fchmodat.c: Likewise.
106501         * lib/fts.c: Likewise.
106502         * lib/getdate.y: Likewise.
106503         * lib/getgroups.c: Likewise.
106504         * lib/getopt.c: Likewise.
106505         * lib/getugroups.c: Likewise.
106506         * lib/mkdir.c: Likewise.
106507         * lib/mkfifo.c: Likewise.
106508         * lib/mkfifoat.c: Likewise.
106509         * lib/mknod.c: Likewise.
106510         * lib/mknodat.c: Likewise.
106511         * lib/readlink.c: Likewise.
106512         * lib/se-context.in.h: Likewise.
106513         * lib/se-selinux.in.h: Likewise.
106514         * lib/sockets.c: Likewise.
106515         * lib/symlink.c: Likewise.
106516         * lib/symlinkat.c: Likewise.
106517         * lib/unicodeio.c: Likewise.
106518         * lib/unistr.h: Likewise.
106519         * tests/test-areadlink.c: Likewise.
106520         * tests/test-areadlinkat.c: Likewise.
106521         * tests/test-filenamecat.c: Likewise.
106522         * tests/test-fseeko.c: Likewise.
106523         * tests/test-ftello.c: Likewise.
106524         * tests/test-getdate.c: Likewise.
106525         * tests/test-getgroups.c: Likewise.
106526         * tests/test-gethostname.c: Likewise.
106527         * tests/test-quotearg.c: Likewise.
106528         * tests/test-version-etc.c: Likewise.
106529         * tests/test-xalloc-die.c: Likewise.
106530         * tests/test-xfprintf-posix.c: Likewise.
106531         * tests/test-xprintf-posix.c: Likewise.
106532         * tests/test-xvasprintf.c: Likewise.
106534         tests: avoid compiler warnings
106535         * tests/test-fcntl.c (main): Delete unused parameters.
106536         * tests/test-freopen-safer.c (main): Likewise.
106537         * tests/test-xalloc-die.c (main): Mark unused parameters.
106538         * tests/test-fseeko.c (main): Likewise.
106539         * tests/test-ftello.c (main): Likewise.
106540         * tests/test-nanosleep.c (main): Avoid declaration warning.
106541         * tests/test-sleep.c (main): Likewise.
106542         * tests/test-unsetenv.c (main): Silence warning about string
106543         literal.
106544         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
106546 2009-12-23  Bruno Haible  <bruno@clisp.org>
106548         * tests/test-localename.c (test_locale_name): New function, extracted
106549         from main. Also test mixed situations.
106550         (test_locale_name_posix, test_locale_name_environ,
106551         test_locale_name_default): New functions.
106552         (main): Invoke them all.
106553         * modules/localename-tests (configure.ac): Test for newlocale.
106555 2009-12-23  Bruno Haible  <bruno@clisp.org>
106557         unistd: Ensure getcwd gets declared before being overridden.
106558         * lib/unistd.in.h: Conditionally include <io.h>.
106560 2009-12-22  Bruno Haible  <bruno@clisp.org>
106562         wchar: Diagnose broken combination of glibc and gcc versions and flags.
106563         * m4/wchar.m4 (gl_WCHAR_H_INLINE_OK): New macro.
106564         (gl_WCHAR_H): Invoke it.
106565         * m4/btowc.m4 (gl_FUNC_BTOWC): Require it.
106566         * doc/posix-headers/wchar.texi: Mention the interoperability problem.
106567         Reported by Karl Berry <karl@freefriends.org>.
106569 2009-12-22  Eric Blake  <ebb9@byu.net>
106571         math, unistd: avoid redundant includes
106572         * lib/math.in.h (isnan): No need to re-include <math.h>.
106573         * lib/unistd.in.h (getcwd): Likewise, for <stdlib.h>.
106575         getsubopt: work around cygwin bug
106576         * lib/stdlib.in.h (includes): Move unistd inclusion sooner, to
106577         avoid conflicting with system getsubopt.
106578         * doc/posix-functions/getsubopt.texi (getsubopt): Document the
106579         bug.
106581         getopt: synchronize from glibc
106582         * lib/getopt.c (_getopt_initialize, _getopt_internal_r): Swap
106583         parameter order.  Adjust all callers.
106584         (_getopt_internal_r, main): Adjust quoting in error messages.
106585         Drop considerations for outdated POSIX 1003.2 error message.
106586         * lib/getopt1.c (_getopt_long_r, _getopt_long_only_r): Adjust
106587         callers.
106588         * lib/getopt_int.h (_getopt_internal_r): Adjust prototype.
106590         test-getopt: test stderr behavior
106591         * modules/getopt-posix-tests (Depends-on): Add dup2.
106592         * tests/test-getopt.c (ASSERT): Avoid stderr.
106593         (main): Move stderr to a temporary file.
106594         * tests/test-getopt.h (getopt_loop): No longer manipulate opterr.
106595         Instead, add parameter to inform caller if output occurred.
106596         (test_getopt): Adjust all existing tests to expect silence, and
106597         add new tests of leading ":".
106598         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
106599         glibc shortcomings with leading "-:" or "+:" in optstring.
106600         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
106601         Likewise.
106602         * doc/posix-functions/getopt.texi (getopt): Likewise.
106604         test-getopt: enhance test
106605         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require that getopt_long
106606         supports optind=0.
106607         * tests/test-getopt.c (OPTIND_MIN): Move...
106608         * tests/test-getopt.h (OPTIND_MIN): ...here.
106609         * tests/test-getopt_long.h (test_getopt_long): Add more coverage.
106610         Require that optind=0 works, since modern BSD supports it in
106611         addition to optreset, and since coreutils expects it.
106612         (test_getopt_long_only): New test.
106613         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
106614         glibc shortcomings with 'W;', and enforcement of optind=0.
106615         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
106616         Likewise.
106618 2009-12-21  Bruno Haible  <bruno@clisp.org>
106620         localename: Improvements for MacOS X and Cygwin.
106621         * lib/localename.h (gl_locale_name_environ): New declaration.
106622         * lib/localename.c (gl_locale_name_environ): New function, extracted from
106623         gl_locale_name_posix. Ignore dummy LANG values on MacOS X and Cygwin.
106624         (gl_locale_name_posix): Invoke it.
106625         (gl_locale_name_default): Add comments. Use Windows native API also on
106626         Cygwin.
106628 2009-12-21  Bruno Haible  <bruno@clisp.org>
106630         Update list of Win32 locale ids.
106631         * lib/localename.c (LANG_ROMANSH): Renamed from LANG_RHAETO_ROMANCE.
106632         (LANG_SAMI): Renamed from LANG_SAAMI.
106633         (LANG_BASHKIR, LANG_LUXEMBOURGISH, LANG_GREENLANDIC,
106634         LANG_MAPUDUNGUN, LANG_MOHAWK, LANG_BRETON, LANG_OCCITAN, LANG_CORSICAN,
106635         LANG_ALSATIAN, LANG_YAKUT, LANG_KICHE, LANG_KINYARWANDA, LANG_WOLOF,
106636         LANG_DARI, LANG_SCOTTISH_GAELIC): New macros.
106637         (SUBLANG_AFRIKAANS_SOUTH_AFRICA, SUBLANG_ALBANIAN_ALBANIA,
106638         SUBLANG_ALSATIAN_FRANCE, SUBLANG_AMHARIC_ETHIOPIA,
106639         SUBLANG_ARMENIAN_ARMENIA, SUBLANG_ASSAMESE_INDIA,
106640         SUBLANG_BASHKIR_RUSSIA, SUBLANG_BASQUE_BASQUE,
106641         SUBLANG_BELARUSIAN_BELARUS, SUBLANG_BRETON_FRANCE,
106642         SUBLANG_BULGARIAN_BULGARIA, SUBLANG_CAMBODIAN_CAMBODIA,
106643         SUBLANG_CATALAN_SPAIN, SUBLANG_CORSICAN_FRANCE,
106644         SUBLANG_CZECH_CZECH_REPUBLIC, SUBLANG_DANISH_DENMARK,
106645         SUBLANG_DARI_AFGHANISTAN, SUBLANG_DIVEHI_MALDIVES,
106646         SUBLANG_DUTCH_SURINAM, SUBLANG_ESTONIAN_ESTONIA,
106647         SUBLANG_FAEROESE_FAROE_ISLANDS, SUBLANG_FARSI_IRAN,
106648         SUBLANG_FINNISH_FINLAND, SUBLANG_FRISIAN_NETHERLANDS,
106649         SUBLANG_GALICIAN_SPAIN, SUBLANG_GEORGIAN_GEORGIA,
106650         SUBLANG_GREEK_GREECE, SUBLANG_GREENLANDIC_GREENLAND,
106651         SUBLANG_GUJARATI_INDIA, SUBLANG_HAUSA_NIGERIA_LATIN,
106652         SUBLANG_HEBREW_ISRAEL, SUBLANG_HINDI_INDIA, SUBLANG_HUNGARIAN_HUNGARY,
106653         SUBLANG_ICELANDIC_ICELAND, SUBLANG_IGBO_NIGERIA,
106654         SUBLANG_INDONESIAN_INDONESIA, SUBLANG_INUKTITUT_CANADA,
106655         SUBLANG_INUKTITUT_CANADA_LATIN, SUBLANG_IRISH_IRELAND,
106656         SUBLANG_JAPANESE_JAPAN, SUBLANG_KANNADA_INDIA,
106657         SUBLANG_KAZAK_KAZAKHSTAN, SUBLANG_KICHE_GUATEMALA,
106658         SUBLANG_KINYARWANDA_RWANDA, SUBLANG_KONKANI_INDIA,
106659         SUBLANG_KYRGYZ_KYRGYZSTAN, SUBLANG_LAO_LAOS, SUBLANG_LATVIAN_LATVIA,
106660         SUBLANG_LITHUANIAN_LITHUANIA, SUBLANG_LOWER_SORBIAN_GERMANY,
106661         SUBLANG_LUXEMBOURGISH_LUXEMBOURG, SUBLANG_MACEDONIAN_MACEDONIA,
106662         SUBLANG_MALAYALAM_INDIA, SUBLANG_MALTESE_MALTA,
106663         SUBLANG_MAORI_NEW_ZEALAND, SUBLANG_MAPUDUNGUN_CHILE,
106664         SUBLANG_MARATHI_INDIA, SUBLANG_MOHAWK_CANADA, SUBLANG_NEPALI_NEPAL,
106665         SUBLANG_OCCITAN_FRANCE, SUBLANG_ORIYA_INDIA,
106666         SUBLANG_PASHTO_AFGHANISTAN, SUBLANG_POLISH_POLAND,
106667         SUBLANG_ROMANSH_SWITZERLAND, SUBLANG_SAMI_NORTHERN_NORWAY,
106668         SUBLANG_SAMI_NORTHERN_SWEDEN, SUBLANG_SAMI_NORTHERN_FINLAND,
106669         SUBLANG_SAMI_LULE_NORWAY, SUBLANG_SAMI_LULE_SWEDEN,
106670         SUBLANG_SAMI_SOUTHERN_NORWAY, SUBLANG_SAMI_SOUTHERN_SWEDEN,
106671         SUBLANG_SAMI_SKOLT_FINLAND, SUBLANG_SAMI_INARI_FINLAND,
106672         SUBLANG_SANSKRIT_INDIA, SUBLANG_SINHALESE_SRI_LANKA,
106673         SUBLANG_SLOVAK_SLOVAKIA, SUBLANG_SLOVENIAN_SLOVENIA,
106674         SUBLANG_SOTHO_SOUTH_AFRICA, SUBLANG_SWAHILI_KENYA,
106675         SUBLANG_SWEDISH_SWEDEN, SUBLANG_SYRIAC_SYRIA,
106676         SUBLANG_TAGALOG_PHILIPPINES, SUBLANG_TAJIK_TAJIKISTAN,
106677         SUBLANG_TAMIL_INDIA, SUBLANG_TATAR_RUSSIA, SUBLANG_TELUGU_INDIA,
106678         SUBLANG_THAI_THAILAND, SUBLANG_TSWANA_SOUTH_AFRICA,
106679         SUBLANG_TURKISH_TURKEY, SUBLANG_TURKMEN_TURKMENISTAN,
106680         SUBLANG_UKRAINIAN_UKRAINE, SUBLANG_UPPER_SORBIAN_GERMANY,
106681         SUBLANG_VIETNAMESE_VIETNAM, SUBLANG_WELSH_UNITED_KINGDOM,
106682         SUBLANG_WOLOF_SENEGAL, SUBLANG_XHOSA_SOUTH_AFRICA,
106683         SUBLANG_YAKUT_RUSSIA, SUBLANG_YI_PRC, SUBLANG_YORUBA_NIGERIA,
106684         SUBLANG_ZULU_SOUTH_AFRICA): New macros.
106685         (gl_locale_name_from_win32_LANGID): Handle also the territory neutral
106686         locale ids. Add support for Alsatian, Bashkir, Breton, Corsican, Dari,
106687         Greenlandic, K'iche', Kinyarwanda, Luxembourgish, Mapudungun, Mohawk,
106688         Occitan, Scottish Gaelic, Wolof, Yakut. Change language code for Yi.
106689         Add more languages and countries for Sami, Sorbian. Add more countries
106690         for Serbian, Dutch. Add more scripts for Inuktitut. Be more precise
106691         for Pashto. Change country for Syriac, Tswana.
106693 2009-12-21  Eric Blake  <ebb9@byu.net>
106695         test-utimens: avoid spurious failure
106696         * tests/test-chown.h (nap): Factor...
106697         * tests/nap.h: ...into new file.
106698         * tests/test-lchown.h (nap): Avoid duplication.
106699         * tests/test-utimens-common.h (nap): Use shared implementation,
106700         necessary on file systems with 1-second resolution.
106701         * modules/chown-tests (Files): Include new file.
106702         * modules/fdutimensat-tests (Files): Likewise.
106703         * modules/futimens-tests (Files): Likewise.
106704         * modules/lchown-tests (Files): Likewise.
106705         * modules/openat-tests (Files): Likewise.
106706         * modules/utimens-tests (Files): Likewise.
106707         * modules/utimensat-tests (Files): Likewise.
106709 2009-12-19  Eric Blake  <ebb9@byu.net>
106711         futimens, utimensat: work around Linux bug
106712         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Detect ctime bug.
106713         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
106714         * lib/utimensat.c (rpl_utimensat): Work around it.
106715         * lib/futimens.c (rpl_futimens): Adjust comment.
106717         utimens: work around Linux ctime bug
106718         * lib/utimens.c (detect_ctime_bug): New helper function.
106719         (update_timespec): Differentiate between workaround needed for
106720         this bug vs. what is needed for systems that lack utimensat.
106721         (fdutimens, lutimens): Work around bug.
106723         utimens: check for ctime update
106724         * tests/test-utimens-common.h (check_ctime): Define.
106725         * tests/test-utimens.h (test_utimens): Expose the Linux bug.
106726         * tests/test-futimens.h (test_futimens): Likewise.
106727         * tests/test-lutimens.h (test_lutimens): Likewise.
106728         * doc/posix-functions/futimens.texi (futimens): Document the bug.
106729         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
106731 2009-12-19  Bruno Haible  <bruno@clisp.org>
106733         dprintf-posix: Check against memory leak fixed on 2009-12-15.
106734         * tests/test-dprintf-posix2.sh: New file.
106735         * tests/test-dprintf-posix2.c: New file.
106736         * modules/dprintf-posix-tests (Files): Add them.
106737         (configure.ac): Check for getrlimit and setrlimit.
106738         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
106740 2009-12-19  Bruno Haible  <bruno@clisp.org>
106742         fprintf-posix: Check against memory leak fixed on 2009-12-15.
106743         * tests/test-fprintf-posix3.sh: New file.
106744         * tests/test-fprintf-posix3.c: New file.
106745         * modules/fprintf-posix-tests (Files): Add them.
106746         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
106748 2009-12-19  Eric Blake  <ebb9@byu.net>
106750         dirfd: fix prototype
106751         * lib/dirent.in.h (dirfd): Argument is not const, per POSIX.
106752         * lib/dirfd.c (dirfd): Likewise.
106754         canonicalize: reduce memory usage
106755         * lib/canonicalize.c (canonicalize_filename_mode): Trim the
106756         allocation to size.
106757         Reported by Solar Designer <solar@openwall.com>.
106759 2009-12-19  Bruno Haible  <bruno@clisp.org>
106761         New module attribute 'Applicability'.
106762         * modules/TEMPLATE-EXTENDED: New field 'Applicability'.
106763         * gnulib-tool: New option --extract-applicability.
106764         (func_usage): Document it.
106765         (sed_extract_prog): Recognize it.
106766         (func_get_applicability): New function.
106767         (func_import): Generalize handling of 'link-warning' module.
106768         * modules/link-warning (Applicability): New section.
106769         * modules/arg-nonnull (Applicability): New section.
106770         Repoted by Simon Josefsson <simon@josefsson.org>.
106772 2009-12-19  Bruno Haible  <bruno@clisp.org>
106774         fflush: tweak
106775         * lib/fflush.c (update_fpos_cache): Don't use fpos_t on Cygwin.
106776         * lib/fseeko.c (rpl_fseeko): Likewise.
106778 2009-12-16  José E. Marchesi  <jemarch@gnu.org>  (tiny change)
106780         * lib/gl_list.h: Fix typo in comment.
106782 2009-12-16  Eric Blake  <ebb9@byu.net>
106784         fcntl: use to simplify other modules
106785         * modules/cloexec (Depends-on): Add fcntl.
106786         * modules/fchdir (Depends-on): Likewise.
106787         * modules/fd-safer-flag (Depends-on): Likewise.
106788         * modules/unistd-safer (Depends-on): Likewise.
106789         * modules/dup3 (configure.ac): Set module indicator.
106790         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Replace fcntl if fchdir is
106791         missing.
106792         * lib/fchdir.c (_gl_register_dup): Fix comment.
106793         * lib/cloexec.c (dup_cloexec): Simplify, by relying on fcntl.
106794         * lib/dup-safer.c (dup_safer): Likewise.
106795         * lib/dup-safer-flag.c (dup_safer_flag): Likewise.
106796         * lib/dup3.c (dup3): Likewise.
106797         * tests/test-fchdir.c (main): Enhance test.
106798         Fixes a dup_cloexec bug reported by Ondřej Vašík.
106800         fcntl: port portions of fcntl to mingw
106801         * m4/fcntl.m4 (gl_FUNC_FCNTL): Also build fcntl.c on mingw.
106802         * lib/fcntl.c (fcntl) <F_DUPFD, F_DUPFD_CLOEXEC, F_GETFD>: Provide
106803         replacement for mingw.
106804         * modules/fcntl (Description): Update.
106805         (Depends-on): Add dup2.
106806         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness.
106807         * modules/fcntl-h (Makefile.am): Substitute it.
106808         * lib/fcntl.in.h (fcntl): Update declaration.
106809         (F_DUPFD, F_GETFD): New macros, when needed.
106810         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
106811         * doc/posix-functions/fcntl.texi (fcntl): Likewise.
106812         * tests/test-fcntl.c (check_flags, main): Enhance test for items
106813         we now guarantee.
106815         fcntl: work around cygwin bug in F_DUPFD
106816         * m4/fcntl.m4 (gl_REPLACE_FCNTL): New macro.
106817         (gl_FUNC_FCNTL): Use it.  Test for F_DUPFD bug.
106818         * lib/fcntl.c (rpl_fcntl) <F_DUPFD>: Work around it.
106819         <F_DUPFD_CLOEXEC>: Reduce calls to _gl_register_dup.
106820         * doc/posix-functions/fcntl.texi (fcntl): Document it.
106822         fcntl: support F_DUPFD_CLOEXEC on systems with fcntl
106823         * modules/fcntl (Files): List new files.
106824         (configure.ac): Run a test.
106825         * m4/fcntl.m4 (gl_FUNC_FCNTL): New file.
106826         * lib/fcntl.c (rpl_fcntl): Likewise.
106827         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness defaults.
106828         (gl_FCNTL_H): Always replace fcntl.h.
106829         * modules/fcntl-h (Makefile.am): Substitute witnesses.
106830         * lib/fcntl.in.h (fcntl): Declare replacement.
106831         (F_DUPFD_CLOEXEC, GNULIB_defined_F_DUPFD_CLOEXEC): New macro when
106832         needed, plus a witness.
106833         * doc/posix-functions/fcntl.texi (fcntl): Document this.
106834         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
106835         * tests/test-fcntl.c: New file.
106836         * modules/fcntl-tests: Likewise.
106838         binary-io: avoid potential compilation warning
106839         * lib/binary-io.h [__DJGPP__]: Avoid null preprocessor
106840         directives.
106842         fflush: avoid compilation error on NetBSD
106843         * lib/fflush.c (update_fpos_cache): Use a union to safely convert
106844         between off_t and fpos_t, since the latter is sometimes a struct.
106845         * lib/fseeko.c (rpl_fseeko): Likewise.
106846         Reported by Alexander Nasonov <alnsn@yandex.ru>.
106848 2009-12-15  Eric Blake  <ebb9@byu.net>
106850         fcntl-h, stdio, sys_ioctl: fix declarations
106851         * lib/stdio.in.h (dprintf): Use of link warning on a variadic
106852         function must not take arguments.
106853         * lib/sys_ioctl.in.h (ioctl): Likewise.
106854         * lib/fcntl.in.h (openat): Likewise.  Declare extern.
106855         (open): Add a link warning.
106857 2009-12-15  Jim Meyering  <meyering@redhat.com>
106859         areadlink, areadlink-with-size: relax license to LGPLv2+
106860         * modules/areadlink (License): Relax to LGPLv2+.
106861         * modules/areadlink-with-size (License): Likewise.
106863 2009-12-15  Joel E. Denny  <jdenny@clemson.edu>
106864             Bruno Haible  <bruno@clisp.org>
106866         *printf: Fix memory leak.
106867         * lib/fprintf.c (fprintf): Free memory allocated by vasnprintf.
106868         * lib/vfprintf.c (vfprintf): Likewise.
106869         * lib/dprintf.c (dprintf): Likewise.
106870         * lib/vdprintf.c (vdprintf): Likewise.
106872 2009-12-14  Eric Blake  <ebb9@byu.net>
106874         accept4: adjust module dependencies
106875         * modules/accept4 (Depends-on): Use fcntl-h, not fcntl.
106877         utimens: one more try at avoiding compiler warning
106878         * lib/utimens.c (lutimens): Lower scope of result.
106880 2009-12-13  Bruno Haible  <bruno@clisp.org>
106882         Move the malloc checking from module 'list' to new module 'xlist'.
106883         * modules/xlist: New file.
106884         * lib/gl_xlist.h: New file.
106885         * lib/gl_xlist.c: New file.
106886         * lib/gl_list.h (gl_list_create_empty, gl_list_create,
106887         gl_list_node_set_value, gl_list_set_at, gl_list_add_first,
106888         gl_list_add_last, gl_list_add_before, gl_list_add_after,
106889         gl_list_nx_add_at, gl_sortedlist_add): Disable declarations.
106890         (gl_list_nx_create_empty, gl_list_nx_create, gl_list_node_nx_set_value,
106891         gl_list_nx_set_at, gl_list_nx_add_first, gl_list_nx_add_last,
106892         gl_list_nx_add_before, gl_list_nx_add_after, gl_list_nx_add_at,
106893         gl_sortedlist_nx_add): New declarations.
106894         (struct gl_list_implementation): Rename and change methods accordingly.
106895         (gl_list_nx_create_empty): Renamed from gl_list_create_empty.
106896         (gl_list_nx_create): Renamed from gl_list_create.
106897         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
106898         (gl_list_nx_set_at): Renamed from gl_list_set_at.
106899         (gl_list_nx_add_first): Renamed from gl_list_add_first.
106900         (gl_list_nx_add_last): Renamed from gl_list_add_last.
106901         (gl_list_nx_add_before): Renamed from gl_list_add_before.
106902         (gl_list_nx_add_after): Renamed from gl_list_add_after.
106903         (gl_list_nx_add_at): Renamed from gl_list_add_at.
106904         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
106905         * lib/gl_list.c (gl_list_nx_create_empty): Renamed from
106906         gl_list_create_empty.
106907         (gl_list_nx_create): Renamed from gl_list_create.
106908         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
106909         (gl_list_nx_set_at): Renamed from gl_list_set_at.
106910         (gl_list_nx_add_first): Renamed from gl_list_add_first.
106911         (gl_list_nx_add_last): Renamed from gl_list_add_last.
106912         (gl_list_nx_add_before): Renamed from gl_list_add_before.
106913         (gl_list_nx_add_after): Renamed from gl_list_add_after.
106914         (gl_list_nx_add_at): Renamed from gl_list_add_at.
106915         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
106916         * lib/gl_array_list.c: Don't include xalloc.h.
106917         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Return
106918         NULL upon out-of-memory.
106919         (gl_array_nx_create): Renamed from gl_array_create. Return NULL upon
106920         out-of-memory.
106921         (gl_array_node_nx_set_value): Renamed from gl_array_node_set_value.
106922         Change return type to 'int'.
106923         (gl_array_nx_set_at): Renamed from gl_array_set_at.
106924         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
106925         (gl_array_nx_add_first): Renamed from gl_array_add_first. Return NULL
106926         upon out-of-memory.
106927         (gl_array_nx_add_last): Renamed from gl_array_add_last. Return NULL
106928         upon out-of-memory.
106929         (gl_array_nx_add_before): Renamed from gl_array_add_before. Return NULL
106930         upon out-of-memory.
106931         (gl_array_nx_add_after): Renamed from gl_array_add_after. Return NULL
106932         upon out-of-memory.
106933         (gl_array_nx_add_at): Renamed from gl_array_add_at. Return NULL upon
106934         out-of-memory.
106935         (gl_array_sortedlist_nx_add): Renamed from gl_array_sortedlist_add.
106936         Update.
106937         (gl_array_list_implementation): Update.
106938         * lib/gl_carray_list.c: Don't include xalloc.h.
106939         (gl_carray_nx_create_empty): Renamed from gl_carray_create_empty.
106940         Return NULL upon out-of-memory.
106941         (gl_carray_nx_create): Renamed from gl_carray_create. Return NULL upon
106942         out-of-memory.
106943         (gl_carray_node_nx_set_value): Renamed from gl_carray_node_set_value.
106944         Change return type to 'int'.
106945         (gl_carray_nx_set_at): Renamed from gl_carray_set_at.
106946         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
106947         (gl_carray_nx_add_first): Renamed from gl_carray_add_first. Return NULL
106948         upon out-of-memory.
106949         (gl_carray_nx_add_last): Renamed from gl_carray_add_last. Return NULL
106950         upon out-of-memory.
106951         (gl_carray_nx_add_at): Renamed from gl_carray_add_at. Return NULL upon
106952         out-of-memory.
106953         (gl_carray_nx_add_before): Renamed from gl_carray_add_before. Update.
106954         (gl_carray_nx_add_after): Renamed from gl_carray_add_after. Update.
106955         (gl_carray_sortedlist_nx_add): Renamed from gl_carray_sortedlist_add.
106956         Update.
106957         (gl_carray_list_implementation): Update.
106958         * lib/gl_anyhash_list2.h (hash_resize): Do nothing upon out-of-memory.
106959         * lib/gl_anylinked_list2.h (gl_linked_nx_create_empty): Renamed from
106960         gl_linked_create_empty. Return NULL upon out-of-memory.
106961         (gl_linked_nx_create): Renamed from gl_linked_create. Return NULL upon
106962         out-of-memory.
106963         (gl_linked_node_nx_set_value): Renamed from gl_linked_node_set_value.
106964         Change return type to 'int'. Return -1 upon out-of-memory.
106965         (gl_linked_nx_set_at): Renamed from gl_linked_set_at. Return NULL upon
106966         out-of-memory.
106967         (gl_linked_nx_add_first): Renamed from gl_linked_add_first. Return NULL
106968         upon out-of-memory.
106969         (gl_linked_nx_add_last): Renamed from gl_linked_add_last. Return NULL
106970         upon out-of-memory.
106971         (gl_linked_nx_add_before): Renamed from gl_linked_add_before. Return
106972         NULL upon out-of-memory.
106973         (gl_linked_nx_add_after): Renamed from gl_linked_add_after. Return NULL
106974         upon out-of-memory.
106975         (gl_linked_nx_add_at): Renamed from gl_linked_add_at. Return NULL upon
106976         out-of-memory.
106977         (gl_linked_sortedlist_nx_add): Renamed from gl_linked_sortedlist_add.
106978         Update.
106979         * lib/gl_linked_list.c: Don't include xalloc.h.
106980         (gl_linked_list_implementation): Update.
106981         * lib/gl_linkedhash_list.c: Don't include xalloc.h.
106982         (add_to_bucket): Change return type to 'int'.
106983         (gl_linkedhash_list_implementation): Update.
106984         * lib/gl_anytree_list1.h (free_subtree): New function.
106985         * lib/gl_anytree_list2.h (gl_tree_nx_create_empty): Renamed from
106986         gl_tree_create_empty. Return NULL upon out-of-memory.
106987         (gl_tree_node_nx_set_value): Renamed from gl_tree_node_set_value.
106988         Change return type to 'int'. Return -1 upon out-of-memory.
106989         (gl_tree_nx_set_at): Renamed from gl_tree_set_at. Return NULL upon
106990         out-of-memory.
106991         (gl_tree_nx_add_at): Renamed from gl_tree_add_at. Update.
106992         (gl_tree_remove_node): New function, moved here from
106993         lib/gl_anyavltree_list2.h and lib/gl_anyrbtree_list2.h.
106994         (gl_tree_sortedlist_nx_add): Renamed from gl_tree_sortedlist_add.
106995         Update.
106996         * lib/gl_anyavltree_list2.h (create_subtree_with_contents): Use
106997         malloc, not xmalloc. Return NULL upon out-of-memory.
106998         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
106999         out-of-memory.
107000         (gl_tree_remove_node_from_tree): New function, extracted from
107001         gl_tree_remove_node.
107002         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
107003         upon out-of-memory.
107004         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
107005         out-of-memory.
107006         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
107007         upon out-of-memory.
107008         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
107009         upon out-of-memory.
107010         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
107011         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents): Use malloc,
107012         not xmalloc. Return NULL upon out-of-memory.
107013         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
107014         out-of-memory.
107015         (gl_tree_remove_node_from_tree): New function, extracted from
107016         gl_tree_remove_node.
107017         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
107018         upon out-of-memory.
107019         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
107020         out-of-memory.
107021         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
107022         upon out-of-memory.
107023         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
107024         upon out-of-memory.
107025         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
107026         * lib/gl_avltree_list.c: Don't include xalloc.h. Include
107027         gl_anytree_list1.h before gl_anyavltree_list2.h.
107028         (gl_avltree_list_implementation): Update.
107029         * lib/gl_rbtree_list.c: Don't include xalloc.h. Include
107030         gl_anytree_list1.h before gl_anyavltree_list2.h.
107031         (gl_rbtree_list_implementation): Update.
107032         * lib/gl_anytreehash_list1.h (add_to_bucket, add_nodes_to_buckets):
107033         Change return type to 'int'. Return -1 upon out-of-memory. Use
107034         __builtin_expect.
107035         * lib/gl_avltreehash_list.c: Don't include xalloc.h.
107036         (gl_avltreehash_list_implementation): Update.
107037         * lib/gl_rbtreehash_list.c: Don't include xalloc.h.
107038         (gl_rbtreehash_list_implementation): Update.
107039         * modules/array-list (Depends-on): Remove xalloc.
107040         * modules/carray-list (Depends-on): Likewise.
107041         * modules/linked-list (Depends-on): Likewise.
107042         * modules/linkedhash-list (Depends-on): Likewise.
107043         * modules/avltree-list (Depends-on): Likewise.
107044         * modules/rbtree-list (Depends-on): Likewise.
107045         * modules/avltreehash-list (Depends-on): Likewise.
107046         * modules/rbtreehash-list (Depends-on): Likewise.
107048         * modules/xsublist: New file.
107049         * lib/gl_xsublist.h: New file.
107050         * lib/gl_xsublist.c: New file.
107051         * lib/gl_sublist.h (gl_sublist_create): Disable declaration.
107052         (gl_sublist_nx_create): New declaration.
107053         * lib/gl_sublist.c: Don't include xalloc.h.
107054         (gl_sublist_nx_create_empty): Renamed from gl_sublist_create_empty.
107055         (gl_sublist_nx_create_fill): Renamed from gl_sublist_create_fill.
107056         (gl_sublist_node_nx_set_value): Renamed from gl_sublist_node_set_value.
107057         Change return type to 'int'. Return -1 upon out-of-memory.
107058         (gl_sublist_nx_set_at): Renamed from gl_sublist_set_at. Return NULL
107059         upon out-of-memory.
107060         (gl_sublist_nx_add_first): Renamed from gl_sublist_add_first. Return
107061         NULL upon out-of-memory.
107062         (gl_sublist_nx_add_last): Renamed from gl_sublist_add_last. Return NULL
107063         upon out-of-memory.
107064         (gl_sublist_nx_add_before): Renamed from gl_sublist_add_before. Return
107065         NULL upon out-of-memory.
107066         (gl_sublist_nx_add_after): Renamed from gl_sublist_add_after. Return
107067         NULL upon out-of-memory.
107068         (gl_sublist_nx_add_at): Renamed from gl_sublist_add_at. Return NULL
107069         upon out-of-memory.
107070         (gl_sublist_sortedlist_nx_add): Renamed from gl_sublist_sortedlist_add.
107071         (gl_sublist_list_implementation): Update.
107072         (gl_sublist_nx_create): Renamed from gl_sublist_create. Return NULL
107073         upon out-of-memory.
107074         * modules/sublist (Depends-on): Remove xalloc.
107076         * tests/test-array_list.c: Use gl_list_nx_* functions where possible.
107077         * tests/test-carray_list.c: Likewise.
107078         * tests/test-linked_list.c: Likewise.
107079         * tests/test-linkedhash_list.c: Likewise.
107080         * tests/test-avltree_list.c: Likewise.
107081         * tests/test-rbtree_list.c: Likewise.
107082         * tests/test-avltreehash_list.c: Likewise.
107083         * tests/test-rbtreehash_list.c: Likewise.
107084         * modules/array-list-tests (Makefile.am): Don't link with @LIBINTL@.
107085         * modules/carray-list-tests (Makefile.am): Likewise.
107086         * modules/linked-list-tests (Makefile.am): Likewise.
107087         * modules/linkedhash-list-tests (Makefile.am): Likewise.
107088         * modules/avltree-list-tests (Makefile.am): Likewise.
107089         * modules/rbtree-list-tests (Makefile.am): Likewise.
107090         * modules/avltreehash-list-tests (Makefile.am): Likewise.
107091         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
107093         * NEWS: Mention the changes.
107095         * lib/clean-temp.c: Include gl_xlist.h.
107096         * modules/clean-temp (Depends-on): Add xlist.
107098         * lib/git-merge-changelog.c: Include gl_xlist.h instead of gl_list.h.
107099         * modules/git-merge-changelog (Depends-on): Add xlist. Remove list.
107101         * tests/test-array_oset.c: Include gl_xlist.h.
107102         * modules/array-oset-tests (Depends-on): Add xlist.
107104         Reported by José E. Marchesi <jemarch@gnu.org>.
107106 2009-12-13  Bruno Haible  <bruno@clisp.org>
107108         Move the malloc checking from module 'oset' to new module 'xoset'.
107109         * modules/xoset: New file.
107110         * lib/gl_xoset.h: New file.
107111         * lib/gl_xoset.c: New file.
107112         * lib/gl_oset.h (gl_oset_create_empty, gl_oset_add): Disable
107113         declarations.
107114         (gl_oset_nx_create_empty, gl_oset_nx_add): New declarations.
107115         (struct gl_oset_implementation): Rename and change methods accordingly.
107116         (gl_oset_nx_create_empty): Renamed from gl_oset_create_empty.
107117         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
107118         'int'. Mark as __warn_unused_result__.
107119         * lib/gl_oset.c (gl_oset_nx_create_empty): Renamed from
107120         gl_oset_create_empty.
107121         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
107122         'int'.
107123         * lib/gl_array_oset.c: Don't include xalloc.h.
107124         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Use
107125         malloc, not xmalloc.
107126         (grow): Change return type to 'int'. Don't call xalloc_die.
107127         (gl_array_nx_add_at): Renamed from gl_array_add_at. Change return type
107128         to 'int'.
107129         (gl_array_nx_add): Renamed from gl_array_add. Change return type to
107130         'int'.
107131         (gl_array_oset_implementation): Update.
107132         * lib/gl_anytree_oset.h (gl_tree_nx_create_empty): Renamed from
107133         gl_tree_create_empty.
107134         (gl_tree_nx_add): Renamed from gl_tree_add. Change return type to
107135         'int'.
107136         * lib/gl_avltree_oset.c: Don't include xalloc.h.
107137         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
107138         xmalloc.
107139         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
107140         not xmalloc.
107141         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
107142         xmalloc.
107143         (gl_avltree_oset_implementation): Update.
107144         * lib/gl_rbtree_oset.c: Don't include xalloc.h.
107145         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
107146         xmalloc.
107147         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
107148         not xmalloc.
107149         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
107150         xmalloc.
107151         (gl_rbtree_oset_implementation): Update.
107152         * modules/array-oset (Depends-on): Remove xalloc.
107153         * modules/avltree-oset (Depends-on): Likewise.
107154         * modules/rbtree-oset (Depends-on): Likewise.
107155         * tests/test-array_oset.c: Use gl_oset_nx_* functions where possible.
107156         * tests/test-avltree_oset.c: Likewise.
107157         * tests/test-rbtree_oset.c: Likewise.
107158         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
107159         * modules/avltree-oset-tests (Makefile.am): Don't link with @LIBINTL@.
107160         * modules/rbtree-oset-tests (Makefile.am): Likewise.
107161         * NEWS: Mention the change.
107163 2009-12-05  Alfred M. Szmidt  <ams@gnu.org>
107165         maint.mk: allow a project to override release-prep commands
107166         * top/maint.mk (alpha, beta, stable): Move release-preparatory
107167         commands into a new rule.
107168         (release-prep): New rule.
107169         (release-prep-hook): New overridable variable.
107171 2009-12-13  Bruno Haible  <bruno@clisp.org>
107173         * lib/localcharset.c (locale_charset): Fix comment about use of GetACP.
107175 2009-12-13  Jim Meyering  <meyering@redhat.com>
107177         maint.mk (null_AM_MAKEFLAGS, built_programs): remove unused definitions
107178         * top/maint.mk (null_AM_MAKEFLAGS, built_programs): Remove definitions.
107180 2009-12-12  Bruno Haible  <bruno@clisp.org>
107182         duplocale: Tweak.
107183         * lib/duplocale.c (rpl_duplocale): Mark categories array as 'const'.
107185 2009-12-12  Karl Berry  <karl@gnu.org>
107187         * config/srclist.txt (strtoll.c): tab changes, no more sync.
107189 2009-12-12  Bruno Haible  <bruno@clisp.org>
107191         * m4/po.m4: Undo incorrect untabification.
107193 2009-12-12  Bruno Haible  <bruno@clisp.org>
107195         c-strtod, c-strtold: Use multithread-safe implementation on MacOS X.
107196         * modules/c-strtod (Depends-on): Add locale.
107197         * modules/c-strtold (Depends-on): Likewise.
107199 2009-12-12  Bruno Haible  <bruno@clisp.org>
107201         * lib/localcharset.c (locale_charset): Add comment about use of GetACP.
107203 2009-12-11  Eric Blake  <ebb9@byu.net>
107205         setenv: relax requirement in light of POSIX ruling
107206         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Test handling of "" but
107207         not NULL.
107208         * tests/test-setenv.c (main): Relax test.
107209         * tests/test-unsetenv.c (main): Likewise.
107210         * doc/posix-functions/setenv.texi (setenv): Document this.
107211         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
107213 2009-12-11  Bruno Haible  <bruno@clisp.org>
107215         New module 'fd-safer-flag'.
107216         * lib/dup-safer-flag.c: New file, extracted from lib/dup-safer.c.
107217         * lib/dup-safer.c (dup_safer_flag): Remove function.
107218         * lib/fd-safer-flag.c: New file, extracted from lib/fd-safer.c.
107219         * lib/fd-safer.c (fd_safer_flag): Remove function.
107220         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): Update condition.
107221         * modules/cloexec (configure.ac): Drop indicator macro.
107222         * modules/fd-safer-flag: New file.
107223         * modules/pipe2-safer (Depends-on): Add fd-safer-flag. Remove cloexec.
107224         * modules/stdlib-safer (Depends-on): Add fd-safer-flag.
107225         * modules/unistd-safer-tests (Depends-on): Add fd-safer-flag.
107227 2009-12-11  Bruno Haible  <bruno@clisp.org>
107229         Tests for module 'nl_langinfo'.
107230         * modules/nl_langinfo-tests: New file.
107231         * tests/test-nl_langinfo.sh: New file.
107232         * tests/test-nl_langinfo.c: New file.
107234         New module 'nl_langinfo'.
107235         * lib/nl_langinfo.c: New file.
107236         * m4/nl_langinfo.m4: New file.
107237         * modules/nl_langinfo: New file.
107238         * doc/posix-functions/nl_langinfo.texi: Mention the new module.
107240 2009-12-11  Bruno Haible  <bruno@clisp.org>
107242         Tests for module 'langinfo'.
107243         * modules/langinfo-tests: New file.
107244         * tests/test-langinfo.c: New file.
107246         New module 'langinfo'.
107247         * lib/langinfo.in.h: New file.
107248         * m4/langinfo_h.m4: New file.
107249         * modules/langinfo: New file.
107250         * doc/posix-headers/langinfo.texi: Mention the new module.
107252 2009-12-11  Bruno Haible  <bruno@clisp.org>
107254         * lib/config.charset: Untabify.
107256 2009-12-11  Bruno Haible  <bruno@clisp.org>
107258         * modules/unistd-safer (configure.ac): Drop indicator macro.
107260 2009-12-11  Bruno Haible  <bruno@clisp.org>
107262         Move pipe2-safer code to its own file.
107263         * lib/pipe2-safer.c: New file, extracted from lib/pipe-safer.c.
107264         * lib/pipe-safer.c (pipe2_safer): Remove function.
107265         * modules/pipe2-safer (Files): Add lib/pipe2-safer.c.
107266         (Makefile.am): Add it to lib_SOURCES.
107268 2009-12-10  Bruno Haible  <bruno@clisp.org>
107270         * lib/recvfrom.c (rpl_recvfrom): Allow the from argument to be NULL.
107272 2009-12-10  Bruno Haible  <bruno@clisp.org>
107274         Declare which arguments expect non-NULL values, for GCC and clang.
107275         * build-aux/arg-nonnull.h: New file.
107276         * modules/arg-nonnull: New file.
107277         * lib/arpa_inet.in.h (_GL_ARG_NONNULL): New placeholder.
107278         (inet_ntop, inet_pton): Use it.
107279         * lib/dirent.in.h (_GL_ARG_NONNULL): New placeholder.
107280         (closedir, dirfd, opendir, scandir, alphasort): Use it.
107281         * lib/fcntl.in.h (_GL_ARG_NONNULL): New placeholder.
107282         (open, openat): Use it.
107283         * lib/fnmatch.in.h (_GL_ARG_NONNULL): New placeholder.
107284         (fnmatch): Use it.
107285         * lib/getopt.in.h (_GL_ARG_NONNULL): New placeholder.
107286         (getopt, getopt_long, getopt_long_only): Use it.
107287         * lib/glob.in.h (_GL_ARG_NONNULL): New placeholder.
107288         * lib/glob-libc.h (glob, globfree, glob64, globfree64, glob_pattern_p):
107289         Use it.
107290         * lib/iconv.in.h (_GL_ARG_NONNULL): New placeholder.
107291         (iconv_open): Use it.
107292         * lib/inttypes.in.h (_GL_ARG_NONNULL): New placeholder.
107293         (strtoimax, strtoumax): Use it.
107294         * lib/locale.in.h (_GL_ARG_NONNULL): New placeholder.
107295         (duplocale): Use it.
107296         * lib/math.in.h (_GL_ARG_NONNULL): New placeholder.
107297         (frexp, frexpl): Use it.
107298         * lib/netdb.in.h (_GL_ARG_NONNULL): New placeholder.
107299         (getaddrinfo, freeaddrinfo, getnameinfo): Use it.
107300         * lib/search.in.h (_GL_ARG_NONNULL): New placeholder.
107301         (tsearch, tfind, tdelete, twalk): Use it.
107302         * lib/signal.in.h (_GL_ARG_NONNULL): New placeholder.
107303         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset,
107304         sigpending): Use it.
107305         * lib/spawn.in.h (_GL_ARG_NONNULL): New placeholder.
107306         (posix_spawn, posix_spawnp, posix_spawnattr_init,
107307         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
107308         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
107309         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
107310         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
107311         posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy,
107312         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
107313         posix_spawnattr_setschedparam, posix_spawn_file_actions_init,
107314         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addopen,
107315         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
107316         Use it.
107317         * lib/stdio.in.h (_GL_ARG_NONNULL): New placeholder.
107318         (dprintf, fclose, fopen, fprintf, fpurge, fputc, fputs, freopen,
107319         rpl_fseek, fseeko, rpl_ftell, ftello, fwrite, getdelim, getline,
107320         obstack_printf, obstack_vprintf, popen, printf, putc, puts, remove,
107321         rename, renameat, snprintf, sprintf, asprintf, vasprintf, vdprintf,
107322         vfprintf, vprintf, vsnprintf, vsprintf): Use it.
107323         * lib/stdlib.in.h (_GL_ARG_NONNULL): New placeholder.
107324         (atoll, canonicalize_file_name, getloadavg, getsubopt, mkdtemp,
107325         mkostemp, mkostemps, mkstemp, mkstemps, putenv, srandom_r, initstate_r,
107326         setstate_r, random_r, realpath, rpmatch, setenv, strtod, strtoll,
107327         strtoull, unsetenv): Use it.
107328         * lib/string.in.h (_GL_ARG_NONNULL): New placeholder.
107329         (memchr, memmem, mempcpy, memrchr, rawmemchr, stpcpy, stpncpy,
107330         strchrnul, strdup, strndup, strnlen, strpbrk, strsep, strstr,
107331         strcasestr, strtok_r, mbslen, mbsnlen, mbschr, mbsrchr, mbsstr,
107332         mbscasecmp, mbsncasecmp, mbspcasecmp, mbscasestr, mbscspn, mbspbrk,
107333         mbsspn, mbssep, mbstok_r, strverscmp): Use it.
107334         * lib/strings.in.h (_GL_ARG_NONNULL): New placeholder.
107335         (strcasecmp, strncasecmp): Use it.
107336         * lib/sys_socket.in.h (_GL_ARG_NONNULL): New placeholder.
107337         (rpl_connect, rpl_bind, rpl_getpeername, rpl_getsockname,
107338         rpl_getsockopt, rpl_recv, rpl_send, rpl_recvfrom, rpl_sendto,
107339         rpl_setsockopt): Use it.
107340         * lib/sys_stat.in.h (_GL_ARG_NONNULL): New placeholder.
107341         (fchmodat, fstat, fstatat, lchmod, rpl_lstat, mkdir, mkdirat, mkfifo,
107342         mkfifoat, mknod, mknodat, stat, utimensat): Use it.
107343         * lib/sys_time.in.h (_GL_ARG_NONNULL): New placeholder.
107344         (gettimeofday): Use it.
107345         * lib/sys_times.in.h (_GL_ARG_NONNULL): New placeholder.
107346         (times): Use it.
107347         * lib/sys_utsname.in.h (_GL_ARG_NONNULL): New placeholder.
107348         (uname): Use it.
107349         * lib/time.in.h (_GL_ARG_NONNULL): New placeholder.
107350         (nanosleep, mktime, localtime_r, gmtime_r, strptime, timegm): Use it.
107351         * lib/unistd.in.h (_GL_ARG_NONNULL): New placeholder.
107352         (chown, euidaccess, faccessat, _gl_register_fd, fchownat,
107353         getdomainname, gethostname, getlogin_r, lchown, link, linkat, pipe2,
107354         pread, readlink, readlinkat, rmdir, symlink, symlinkat, unlink,
107355         unlinkat, write): Use it.
107356         * lib/wchar.in.h (_GL_ARG_NONNULL): New placeholder.
107357         (mbsrtowcs, mbsnrtowcs, wcsrtombs, wcsnrtombs): Use it.
107358         * lib/argv-iter.h: Include arg-nonnull.h.
107359         (_ATTRIBUTE_NONNULL_): Remove macro.
107360         (argv_iter_init_argv, argv_iter_init_stream, argv_iter,
107361         argv_iter_n_args, argv_iter_free): Use _GL_ARG_NONNULL.
107362         * lib/canonicalize-lgpl.c (_GL_ARG_NONNULL): Define, to defeat gcc
107363         optimization.
107364         * lib/getaddrinfo.c (_GL_ARG_NONNULL): Likewise.
107365         * lib/getdelim.c (_GL_ARG_NONNULL): Likewise.
107366         * lib/glob.c (_GL_ARG_NONNULL): Likewise.
107367         * lib/random_r.c (_GL_ARG_NONNULL): Likewise.
107368         * lib/setenv.c (_GL_ARG_NONNULL): Likewise.
107369         * lib/strtod.c (_GL_ARG_NONNULL): Likewise.
107370         * lib/tsearch.c (_GL_ARG_NONNULL): Likewise.
107371         * lib/unsetenv.c (_GL_ARG_NONNULL): Likewise.
107372         * modules/arpa_inet (Depends-on): Add arg-nonnull.
107373         (Makefile.am): Insert arg-nonnull.h into arpa/inet.h.
107374         * modules/dirent (Depends-on): Add arg-nonnull.
107375         (Makefile.am): Insert arg-nonnull.h into dirent.h.
107376         * modules/fcntl-h (Depends-on): Add arg-nonnull.
107377         (Makefile.am): Insert arg-nonnull.h into fcntl.h.
107378         * modules/fnmatch (Depends-on): Add arg-nonnull.
107379         (Makefile.am): Insert arg-nonnull.h into fnmatch.h.
107380         * modules/getopt-posix (Depends-on): Add arg-nonnull.
107381         (Makefile.am): Insert arg-nonnull.h into getopt.h.
107382         * modules/glob (Depends-on): Add arg-nonnull.
107383         (Makefile.am): Insert arg-nonnull.h into glob.h.
107384         * modules/iconv_open (Depends-on): Add arg-nonnull.
107385         (Makefile.am): Insert arg-nonnull.h into iconv.h.
107386         * modules/inttypes (Depends-on): Add arg-nonnull.
107387         (Makefile.am): Insert arg-nonnull.h into inttypes.h.
107388         * modules/locale (Depends-on): Add arg-nonnull.
107389         (Makefile.am): Insert arg-nonnull.h into locale.h.
107390         * modules/math (Depends-on): Add arg-nonnull.
107391         (Makefile.am): Insert arg-nonnull.h into math.h.
107392         * modules/netdb (Depends-on): Add arg-nonnull.
107393         (Makefile.am): Insert arg-nonnull.h into netdb.h.
107394         * modules/search (Depends-on): Add arg-nonnull.
107395         (Makefile.am): Insert arg-nonnull.h into search.h.
107396         * modules/signal (Depends-on): Add arg-nonnull.
107397         (Makefile.am): Insert arg-nonnull.h into signal.h.
107398         * modules/spawn (Depends-on): Add arg-nonnull.
107399         (Makefile.am): Insert arg-nonnull.h into spawn.h.
107400         * modules/stdio (Depends-on): Add arg-nonnull.
107401         (Makefile.am): Insert arg-nonnull.h into stdio.h.
107402         * modules/stdlib (Depends-on): Add arg-nonnull.
107403         (Makefile.am): Insert arg-nonnull.h into stdlib.h.
107404         * modules/string (Depends-on): Add arg-nonnull.
107405         (Makefile.am): Insert arg-nonnull.h into string.h.
107406         * modules/strings (Depends-on): Add arg-nonnull.
107407         (Makefile.am): Insert arg-nonnull.h into strings.h.
107408         * modules/sys_socket (Depends-on): Add arg-nonnull.
107409         (Makefile.am): Insert arg-nonnull.h into sys/socket.h.
107410         * modules/sys_stat (Depends-on): Add arg-nonnull.
107411         (Makefile.am): Insert arg-nonnull.h into sys/stat.h.
107412         * modules/sys_time (Depends-on): Add arg-nonnull.
107413         (Makefile.am): Insert arg-nonnull.h into sys/time.h.
107414         * modules/sys_times (Depends-on): Add arg-nonnull.
107415         (Makefile.am): Insert arg-nonnull.h into sys/times.h.
107416         * modules/sys_utsname (Depends-on): Add arg-nonnull.
107417         (Makefile.am): Insert arg-nonnull.h into sys/utsname.h.
107418         * modules/time (Depends-on): Add arg-nonnull.
107419         (Makefile.am): Insert arg-nonnull.h into time.h.
107420         * modules/unistd (Depends-on): Add arg-nonnull.
107421         (Makefile.am): Insert arg-nonnull.h into unistd.h.
107422         * modules/wchar (Depends-on): Add arg-nonnull.
107423         (Makefile.am): Insert arg-nonnull.h into wchar.h.
107424         * modules/argv-iter (Depends-on): Add arg-nonnull.
107425         * tests/test-canonicalize.c (null_ptr): New function.
107426         (main): Use it.
107427         * tests/test-canonicalize-lgpl.c (null_ptr): New function.
107428         (main): Use it.
107429         * tests/test-memmem.c (null_ptr): New function.
107430         (main): Use it.
107431         Reported by Jim Meyering.
107433 2009-12-10  Bruno Haible  <bruno@clisp.org>
107435         Use spaces for indentation, not tabs.
107436         * lib/**/*.[hcy] except lib/reg*.[hc]: Untabify.
107437         * m4/*.m4: Untabify.
107438         * build-aux/*.h: Untabify.
107439         * tests/**/*.[hc]: Untabify.
107440         * README: New section "Indent with spaces, not TABs", based on
107441         coreutils/HACKING and comments by Pádraig Brady and Paolo Bonzini.
107442         * NEWS: Mention the change.
107444 2009-12-10  Bruno Haible  <bruno@clisp.org>
107446         pty test: Fix link error.
107447         * modules/pty-tests (Makefile.am): Add the default LDADD value to
107448         test_pty_LDADD.
107450 2009-12-07  Simon Josefsson  <simon@josefsson.org>
107452         * modules/pty: New file.
107453         * modules/pty-tests: New file.
107454         * m4/pty.m4: New file.
107455         * tests/test-pty.c: New file.
107456         * doc/glibc-headers/pty.texi: Modified.
107457         * doc/glibc-functions/forkpty.texi: Modified.
107458         * doc/glibc-functions/openpty.texi: Modified.
107460 2009-12-10  Bruno Haible  <bruno@clisp.org>
107462         Avoid syntax error in C++ mode.
107463         * lib/stdio.in.h (rename): Don't use parameter name 'new'.
107465 2009-12-10  Bruno Haible  <bruno@clisp.org>
107467         Use sed with option -e.
107468         * gnulib-tool (func_version, func_emit_copyright_notice,
107469         func_emit_initmacro_end, func_import, func_create_testdir): Pass
107470         option -e to sed.
107471         * modules/link-warning (Makefile.am): Likewise.
107473 2009-12-10  Jim Meyering  <meyering@redhat.com>
107475         mgetgroups: do not write bytes beyond end of malloc'd buffer
107476         * lib/mgetgroups.c: Fix an off-by-one error.  When we have no
107477         username, we call getgroups with a one-element-shorter buffer,
107478         but still told it the length was original, max_n_groups.
107480 2009-12-09  Eric Blake  <ebb9@byu.net>
107482         cloexec: relax license
107483         * modules/cloexec (Maintainer): Add myself.
107484         (License): Use LGPL, not GPL.
107486         link-warning: optimize generation
107487         * modules/link-warning (Makefile.am): Reduce process usage.
107489 2009-12-09  Bruno Haible  <bruno@clisp.org>
107491         * doc/posix-functions/unsetenv.texi: Mention Solaris 10 bug for which a
107492         workaround was added on 2009-11-17.
107494 2009-12-09  Jim Meyering  <meyering@redhat.com>
107495             Bruno Haible  <bruno@clisp.org>
107497         link-warning: Allow extra lines at the top of build-aux/link-warning.h.
107498         * modules/link-warning (Makefile.am): Make the comment-removing sed
107499         command more robust in the face of bootstrap-prepended comment lines.
107501 2009-12-09  Bruno Haible  <bruno@clisp.org>
107503         * lib/mgetgroups.c (mgetgroups): Don't remove duplicates if there is at
107504         most one group.
107506 2009-12-09  Simon Josefsson  <simon@josefsson.org>
107507             Bruno Haible  <bruno@clisp.org>
107509         * build-aux/link-warning.h: Add copyright notice.
107510         * modules/link-warning (Makefile.am): Generate link-warning.h from
107511         build-aux/link-warning.h. Update LINK_WARNING_H accordingly.
107512         * NEWS: Mention change in link-warning module.
107513         * modules/arpa_inet (Makefile.am): Add dependency to arpa/inet.h.
107514         * modules/dirent (Makefile.am): Add dependency to dirent.h.
107515         * modules/fcntl-h (Makefile.am): Add dependency to fcntl.h.
107516         * modules/getopt-posix (Makefile.am): Add dependency to getopt.h.
107517         * modules/inttypes (Makefile.am): Add dependency to inttypes.h.
107518         * modules/math (Makefile.am): Add dependency to math.h.
107519         * modules/search (Makefile.am): Add dependency to search.h.
107520         * modules/signal (Makefile.am): Add dependency to signal.h.
107521         * modules/spawn (Makefile.am): Add dependency to spawn.h.
107522         * modules/stdio (Makefile.am): Add dependency to stdio.h.
107523         * modules/stdlib (Makefile.am): Add dependency to stdlib.h.
107524         * modules/string (Makefile.am): Add dependency to string.h.
107525         * modules/strings (Makefile.am): Add dependency to strings.h.
107526         * modules/sys_ioctl (Makefile.am): Add dependency to sys/ioctl.h.
107527         * modules/sys_select (Makefile.am): Add dependency to sys/select.h.
107528         * modules/sys_socket (Makefile.am): Add dependency to sys/socket.h.
107529         * modules/sys_stat (Makefile.am): Add dependency to sys/stat.h.
107530         * modules/sys_times (Makefile.am): Add dependency to sys/times.h.
107531         * modules/sys_utsname (Makefile.am): Add dependency to sys/utsname.h.
107532         * modules/sys_wait (Makefile.am): Add dependency to sys/wait.h.
107533         * modules/unistd (Makefile.am): Add dependency to unistd.h.
107534         * modules/wchar (Makefile.am): Add dependency to wchar.h.
107536 2009-12-09  Bruno Haible  <bruno@clisp.org>
107538         fchdir: Optimize away rpl_fstat when possible.
107539         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set REPLACE_FSTAT only together with
107540         REPLACE_OPEN_DIRECTORY.
107541         * lib/fchdir.c (rpl_fstat): Define only when REPLACE_OPEN_DIRECTORY.
107543 2009-12-09  Bruno Haible  <bruno@clisp.org>
107545         * lib/fchdir.c: Update comment.
107547 2009-12-09  Bruno Haible  <bruno@clisp.org>
107549         * lib/cloexec.c (set_cloexec_flag): Clarify intent of dup2 call.
107551 2009-12-08  Eric Blake  <ebb9@byu.net>
107553         fchdir: avoid memory leak on re-registration.
107554         * lib/fchdir.c (ensure_dirs_slot): Avoid memory leak.
107556 2009-12-08  Jim Meyering  <meyering@redhat.com>
107558         init.sh: avoid Solaris 10 /bin/sh portability problem
107559         Solaris 10's /bin/sh does not pass '.' arguments 2.. to the
107560         sourced script:
107561           $ printf 'echo "$@"\n' > f; /bin/sh -c '. ./f bar'
107562           $ printf 'echo "$@"\n' > f; /bin/bash -c '. ./f bar'
107563           bar
107564         tests/init.sh relied on that, accepting a --set-path=DIR argument,
107565         and two tests used that idiom.
107566         * tests/init.sh: Update suggested usage comments.
107567         (path_prepend_): New function, to be used in place
107568         of the --src-path=DIR option.
107569         (setup_): Move PATH-prepending code into path_prepend_.
107570         * tests/test-pread.sh: Adapt to new usage.
107571         * tests/test-xalloc-die.sh: Likewise.
107573 2009-12-08  Simon Josefsson  <simon@josefsson.org>
107575         * doc/gnulib.texi (Glibc pty.h): Add.
107576         * doc/glibc-functions/forkpty.texi: Add.
107577         * doc/glibc-functions/openpty.texi: Add.
107578         Suggested by Bruno Haible.
107580 2009-12-08  Eric Blake  <ebb9@byu.net>
107582         fchdir: fix logic bugs
107583         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Fix logic bug.
107584         * tests/test-fchdir.c (main): Enhance test.
107585         * lib/fchdir.c (rpl_fstat): Always provide if fchdir replacement
107586         is in use.
107588         dup2: fix logic bugs
107589         * lib/dup2.c (dup2): Fix logic bugs.  Use HAVE_DUP2 rather than
107590         REPLACE_DUP2 to decide when rpl_dup2 is needed.
107591         * m4/dup2.m4 (gl_REPLACE_DUP2): Only define REPLACE_DUP2 when dup2
107592         exists.
107593         (gl_FUNC_DUP2): Drop unneeded AC_DEFINE.
107595 2009-12-07  Eric Blake  <ebb9@byu.net>
107597         unlink: fix m4 detection
107598         * m4/unlink.m4 (gl_FUNC_UNLINK): Include correct header.
107600         unistd-safer: add unit test
107601         * modules/unistd-safer-tests: New file.
107602         * tests/test-dup-safer.c: Likewise.
107603         * tests/test-cloexec.c (setmode): Avoid compiler warning.
107604         * tests/test-dup2.c (setmode): Likewise.
107605         * lib/cloexec.c (dup_cloexec): Fix mingw compile error.
107607         cloexec: preserve text vs. binary across dup_cloexec
107608         * lib/cloexec.c (dup_cloexec) [W32]: Query and use translation
107609         mode.
107610         * modules/dup2-tests (Depends-on): Add binary-io.
107611         * modules/cloexec-tests (Depends-on): Likewise.
107612         * tests/test-dup2.c (setmode, is_mode): New helpers.
107613         (main): Add tests that translation mode is preserved.
107614         * tests/test-cloexec.c (setmode, is_mode, main): Likewise.
107615         Reported by Bruno Haible.
107617         mgetgroups: reduce duplicate listings
107618         * lib/mgetgroups.c (mgetgroups): Reduce duplicates from the
107619         resulting array.
107620         * tests/test-chown.h (test_chown): Simplify client.
107621         * tests/test-lchown.h (test_lchown): Likewise.
107623 2009-12-06  Bruno Haible  <bruno@clisp.org>
107625         * lib/cloexec.c (dup_cloexec): Fix handling of _gl_register_dup return
107626         value.
107628 2009-12-06  Bruno Haible  <bruno@clisp.org>
107630         * lib/progname.c: Include stdio.h, stdlib.h.
107631         (set_program_name): Reject a NULL argument.
107633 2009-12-05  Eric Blake  <ebb9@byu.net>
107635         pipe2-safer: new module
107636         * modules/pipe2-safer: New file.
107637         * lib/unistd-safer.h (pipe2_safer): New prototype.
107638         * lib/unistd--.h (pipe2): New wrapper.
107639         * lib/pipe-safer.c (pipe2_safer): New function.
107640         * modules/pipe (Depends-on): Add pipe2-safer.
107641         * lib/pipe.c (create_pipe) [WIN32]: Let pipe2_safer do the work.
107643         stdlib-safer: preserve cloexec flag for mkostemp[s]
107644         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer): Use new
107645         fd_safer_flag.
107647         unistd-safer: allow preservation of cloexec status via flag
107648         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): New
107649         prototypes.
107650         * lib/dup-safer.c (dup_safer_flag): New function.
107651         * lib/fd-safer.c (fd_safer_flag): Likewise.
107652         * modules/cloexec (configure.ac): Set witness.
107654         test-dup2: enhance test
107655         * modules/dup2-tests (Depends-on): Add cloexec.
107656         * tests/test-dup2.c (main): Enhance test.
107658         cloexec: add dup_cloexec
107659         * lib/cloexec.h (dup_cloexec): New prototype.  Add copyright
107660         header and comments.
107661         * lib/cloexec.c (set_cloexec_flag): Add comments.
107662         (dup_cloexec): New function, with mingw implementation borrowed
107663         from...
107664         * lib/w32spawn.h (dup_noinherit): ...here.
107665         * modules/execute (Depends-on): Add cloexec.
107666         * modules/pipe (Depends-on): Likewise.
107667         * modules/cloexec (Depends-on): Add dup2.
107668         * modules/cloexec-tests (Files): New file.
107669         * tests/test-cloexec.c: Likewise.
107671         test-xalloc-die: fix test for mingw
107672         * modules/xalloc-die-tests (Files): Add tests/init.sh.
107673         * tests/test-xalloc-die.sh: Rewrite to use init.sh.  Strip
107674         directory and .exe suffix off argv[0] output.
107676         test-fseeko: fix test for mingw
107677         * tests/test-fseeko.c (fseek): Redefine GL_LINK_WARNING, rather
107678         than undefining fseek, so test will pass on mingw.
107680 2009-12-05  Bruno Haible  <bruno@clisp.org>
107682         * lib/progname.h (set_program_name): Clarify specification.
107683         * lib/progname.c (set_program_name): Likewise.
107684         Reported by Jim Meyering.
107686 2009-12-05  Jim Meyering  <meyering@redhat.com>
107688         maint.mk: backslash-escape parens in default regexp
107689         * top/maint.mk (news-check-regexp): Now that we're using grep -E,
107690         backslash-escape the literal parentheses.
107692         maint.mk: news-date-check: use grep -E
107693         * top/maint.mk (today): Define a Make variable, not a...
107694         (news-date-check): ...shell variable.
107695         (news-date-regexp): Use the Make variable.
107696         Use grep's -E option.  Change the failing diagnostic to mention
107697         the variable, $(news-date-regexp).
107699 2009-12-04  Alfred M. Szmidt  <ams@gnu.org>
107701         maintainer-makefile: allow customization of NEWS entry format
107702         * top/maint.mk (news-date-regexp): New overridable variable.
107703         (news-date-check): Use it.
107705 2009-12-04  Eric Blake  <ebb9@byu.net>
107707         mgetgroups: add xgetgroups, and avoid ENOSYS failures
107708         * lib/mgetgroups.h (xgetgroups): New prototype.
107709         * lib/mgetgroups.c (xgetgroups): New wrapper.
107710         (mgetgroups): Handle ENOSYS.
107711         * modules/mgetgroups (Depends-on): Add realloc.
107712         Reported by Scott Harrison <scott.gnu.2009@scottrix.co.uk>.
107714         mgetgroups: avoid argument promotion issues with -1
107715         * lib/mgetgroups.c (mgetgroups): A cast is required when checking
107716         for invalid gid_t.
107717         * tests/test-chown.h (getegid, test_chown): Likewise.
107718         * tests/test-lchown.h (getegid, test_lchown): Likewise.
107720 2009-12-03  Paolo Bonzini  <bonzini@gnu.org>
107722         exclude: Fix header file problems.
107723         * lib/exclude.h: Add multiple inclusion guards and include stdbool.h.
107725 2009-12-01  Jim Meyering  <meyering@redhat.com>
107727         fts: fts_open: do not let an empty string cause immediate failure
107728         This is required in support of GNU rm, for which the command
107729         "rm A '' B" must process and remove both A and B, in spite of
107730         the empty string argument.
107731         * lib/fts.c (fts_open): Do not let the presence of an empty string
107732         cause fts_open to fail immediately.  Most fts-using tools must be
107733         able to process all arguments, in order, and can be expected to
107734         diagnose such arguments themselves.
107736 2009-11-30  Eric Blake  <ebb9@byu.net>
107738         utimens: fix compilation error
107739         * lib/utimens.c (lutimens) [!HAVE_UTIMENSAT && HAVE_LUTIMES]:
107740         Declare variable at right scope.
107742 2009-11-29  Jim Meyering  <meyering@redhat.com>
107744         bootstrap: handle perl-5.11's changed --version output
107745         * build-aux/bootstrap (get_version): Handle perl separately,
107746         since perl-5.11's --version output is different.
107748 2009-11-28  Jim Meyering  <meyering@redhat.com>
107750         userspec: depend on the inttostr module, too
107751         * modules/userspec (Depends-on): Add inttostr.
107753         userspec: disallow an ID that maps to (uid_t)-1 or (gid_t)-1
107754         * lib/userspec.c (parse_with_separator): Do not accept a user ID
107755         number of MAXUID when it evaluates to (uid_t) -1.
107756         Likewise for group ID.  Reported by Matt McCutchen in
107757         <http://savannah.gnu.org/bugs/?28113>
107759         userspec: reformat to use spaces, not TABs
107760         * lib/userspec.c: Expand TABs to spaces.
107761         Add Emacs' "indent-tabs-mode: nil" hint.
107763 2009-11-27  Eric Blake  <ebb9@byu.net>
107765         getopt-gnu: flush out another BSD bug
107766         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Test for the bug.
107767         * tests/test-getopt.c (main): Check POSIXLY_CORRECT first, to
107768         flush out BSD bug.
107769         * tests/test-getopt.h (test_getopt): End lists with NULL.
107770         * tests/test-getopt_long.h (test_getopt_long): Likewise.
107771         (test_getopt_long_posix): Enhance test.
107772         * modules/getopt-posix-tests (Depends-on): Add stdbool.
107773         * doc/glibc-functions/getopt_long.texi (getopt_long): Mention
107774         getopt-gnu.
107775         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
107776         Likewise.
107778 2009-11-27  Simon Josefsson  <simon@josefsson.org>
107780         * modules/idpriv-droptemp-tests (Notice): Fix text.
107782 2009-11-27  Jim Meyering  <meyering@redhat.com>
107784         test-xalloc-die: avoid spurious failure due to libtool argv difference
107785         In a libtool-enabled project, this test would fail due to a difference
107786         in the emitted program name, e.g.,
107787         -test-xalloc-die: memory exhausted
107788         +/tmp/.../tests/.libs/lt-test-xalloc-die: memory exhausted
107789         Use program to avoid that.
107790         * modules/xalloc-die-tests (Depends-on): Add progname.
107791         * tests/test-xalloc-die.c: Include progname.h".
107792         (program_name): Remove decl.
107793         (main): Call set_program_name.
107794         * tests/test-xalloc-die.sh (compare): Remove unnecessary ${EXE}.
107796 2009-11-26  Richard Jones  <rjones@redhat.com>
107798         w32sock: leave win32 error in place.
107799         * lib/w32sock.h (set_winsock_errno): Do not call WSASetLastError.
107801 2009-11-26  Eric Blake  <ebb9@byu.net>
107803         init.sh: suggest to use skip_ and fail_ functions in comments
107804         * tests/init.sh: Add a sentence.
107806 2009-11-25  Bruno Haible  <bruno@clisp.org>
107808         init.sh: add documentation in comments
107809         * tests/init.sh: Add some developer and user documentation.
107811 2009-11-26  Jim Meyering  <meyering@redhat.com>
107813         init.sh: accommodate even those who specify bogus srcdir manually
107814         * tests/init.sh: Normally, srcdir is guaranteed by automake and
107815         configure-time tests to be sanitized, so that there is no need to
107816         use "$srcdir" in Makefile rules and shell scripts.  Using $srcdir
107817         (with no double quotes) suffices.  However, since tests may be
107818         invoked manually, and since you may explicitly set srcdir to the
107819         name of a directory containing spaces, do quote its uses here.
107820         * tests/test-pread.sh: Likewise.
107821         Suggested by Bruno Haible.
107823         test-pread.sh: avoid diagnostics for those who ignore SIGPIPE
107824         * tests/test-pread.sh: Write no data into the pipe, because
107825         test-pread actually reads none.  This avoids a diagnostic,
107826         "bash: echo: write error: Broken pipe", that arises in the unusual
107827         event something is ignoring SIGPIPE, and might be interpreted
107828         as some sort of failure.  Reported by Bruno Haible.
107830 2009-11-25  Jim Meyering  <meyering@redhat.com>
107832         test-pread: cover failure with ESPIPE and EINVAL
107833         * tests/test-pread.c (main): Test for failure, too.
107834         * tests/test-pread.sh: Invoke with stdin on a pipe.
107835         Suggested by Eric Blake.
107837         pread: improvement and fix
107838         * modules/pread (Depends-on): Depend on lseek, for portability to
107839         e.g., mingw.  Suggested by Eric Blake.
107840         * lib/pread.c (__libc_read): Define.  Reported by Richard W.M. Jones.
107842         unistd.in.h: correct declaration of pread
107843         * lib/unistd.in.h: Correct type of "buf" parameter: void*, not char*
107844         Reported by Richard W.M. Jones.
107846         test-pread.sh: distribute the test script
107847         * modules/pread-tests (Files): Include test-pread.sh.
107849         test-pread.sh: clean up
107850         * tests/test-pread.sh: Don't refer to $builddir. Just use equivalent ".".
107851         * modules/pread-tests (TESTS_ENVIRONMENT): Don't export builddir.
107852         That is unnecessary, since it's always ".".
107853         Suggestion from Eric Blake.
107855         test-pread.sh: make executable
107856         * tests/test-pread.sh: Set executable bit.
107857         Reported by Eric Blake.
107859         correct typo in test-pread.sh
107860         * tests/test-pread.sh: Add #! line.
107862         test pread
107863         * tests/test-pread.c: New file.
107864         * tests/test-pread.sh: Likewise.
107865         * modules/pread-tests: Likewise.
107867         pread: new module
107868         * modules/pread: New file.
107869         * lib/unistd.in.h (pread): Define/declare.
107870         * lib/pread.c (pread): New file.
107871         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define defaults.
107872         * modules/unistd (Makefile.am): Substitute witnesses.
107873         * doc/posix-functions/pread.texi (pread): Update.
107874         * MODULES.html.sh: Add pread.
107876 2009-11-25  Jim Meyering  <meyering@redhat.com>
107878         tests/init.sh: new file to be used via most *.sh tests
107879         * tests/init.sh: New file.
107881 2009-11-25  Eric Blake  <ebb9@byu.net>
107883         utimens: work around older Linux failure with symlinks
107884         * lib/utimens.c (lutimensat_works_really): New variable.
107885         (fdutimens, lutimens): Use it to manage kernels that support
107886         nanosecond times on files, but not on symlinks.
107887         Reported by Ondřej Vašík.
107889         utimes: fix configure grammar
107890         * m4/utimes.m4 (gl_FUNC_UTIMES): Delete spurious word.
107892 2009-11-25  Paolo Bonzini  <bonzini@gnu.org>
107894         regex: Fix fastmap for multibyte character ranges.
107895         * lib/regcomp.c (re_compute_fastmap_iter): Add all multibyte lead
107896         characters when a multibyte character range is included.
107898 2009-11-22  Andy Wingo  <wingo@pobox.com>
107900         version-etc: work also with AM_INIT_AUTOMAKE's no-define option
107901         * lib/version-etc.c [!defined PACKAGE]: Define to PACKAGE_TARNAME.
107903 2009-11-24  Bruno Haible  <bruno@clisp.org>
107905         doc: Most *_l functions exist in MacOS X 10.5.
107906         * doc/posix-functions/duplocale.texi: Update platforms list.
107907         * doc/posix-functions/freelocale.texi: Likewise.
107908         * doc/posix-functions/newlocale.texi: Likewise.
107909         * doc/posix-functions/uselocale.texi: Likewise.
107910         * doc/posix-functions/isalnum_l.texi: Likewise.
107911         * doc/posix-functions/isalpha_l.texi: Likewise.
107912         * doc/posix-functions/isblank_l.texi: Likewise.
107913         * doc/posix-functions/iscntrl_l.texi: Likewise.
107914         * doc/posix-functions/isdigit_l.texi: Likewise.
107915         * doc/posix-functions/isgraph_l.texi: Likewise.
107916         * doc/posix-functions/islower_l.texi: Likewise.
107917         * doc/posix-functions/isprint_l.texi: Likewise.
107918         * doc/posix-functions/ispunct_l.texi: Likewise.
107919         * doc/posix-functions/isspace_l.texi: Likewise.
107920         * doc/posix-functions/isupper_l.texi: Likewise.
107921         * doc/posix-functions/iswalnum_l.texi: Likewise.
107922         * doc/posix-functions/iswalpha_l.texi: Likewise.
107923         * doc/posix-functions/iswblank_l.texi: Likewise.
107924         * doc/posix-functions/iswcntrl_l.texi: Likewise.
107925         * doc/posix-functions/iswctype_l.texi: Likewise.
107926         * doc/posix-functions/iswdigit_l.texi: Likewise.
107927         * doc/posix-functions/iswgraph_l.texi: Likewise.
107928         * doc/posix-functions/iswlower_l.texi: Likewise.
107929         * doc/posix-functions/iswprint_l.texi: Likewise.
107930         * doc/posix-functions/iswpunct_l.texi: Likewise.
107931         * doc/posix-functions/iswspace_l.texi: Likewise.
107932         * doc/posix-functions/iswupper_l.texi: Likewise.
107933         * doc/posix-functions/iswxdigit_l.texi: Likewise.
107934         * doc/posix-functions/isxdigit_l.texi: Likewise.
107935         * doc/posix-functions/nl_langinfo_l.texi: Likewise.
107936         * doc/posix-functions/strcasecmp_l.texi: Likewise.
107937         * doc/posix-functions/strcoll_l.texi: Likewise.
107938         * doc/posix-functions/strfmon_l.texi: Likewise.
107939         * doc/posix-functions/strftime_l.texi: Likewise.
107940         * doc/posix-functions/strncasecmp_l.texi: Likewise.
107941         * doc/posix-functions/strxfrm_l.texi: Likewise.
107942         * doc/posix-functions/tolower_l.texi: Likewise.
107943         * doc/posix-functions/toupper_l.texi: Likewise.
107944         * doc/posix-functions/towctrans_l.texi: Likewise.
107945         * doc/posix-functions/towlower_l.texi: Likewise.
107946         * doc/posix-functions/towupper_l.texi: Likewise.
107947         * doc/posix-functions/wcscoll_l.texi: Likewise.
107948         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
107949         * doc/posix-functions/wctrans_l.texi: Likewise.
107950         * doc/posix-functions/wctype_l.texi: Likewise.
107951         * doc/glibc-functions/strptime_l.texi: Likewise.
107952         * doc/glibc-functions/strtod_l.texi: Likewise.
107953         * doc/glibc-functions/strtof_l.texi: Likewise.
107954         * doc/glibc-functions/strtol_l.texi: Likewise.
107955         * doc/glibc-functions/strtold_l.texi: Likewise.
107956         * doc/glibc-functions/strtoll_l.texi: Likewise.
107957         * doc/glibc-functions/strtoul_l.texi: Likewise.
107958         * doc/glibc-functions/strtoull_l.texi: Likewise.
107959         * doc/glibc-functions/wcsftime_l.texi: Likewise.
107960         * doc/glibc-functions/wcstod_l.texi: Likewise.
107961         * doc/glibc-functions/wcstof_l.texi: Likewise.
107962         * doc/glibc-functions/wcstol_l.texi: Likewise.
107963         * doc/glibc-functions/wcstold_l.texi: Likewise.
107964         * doc/glibc-functions/wcstoll_l.texi: Likewise.
107965         * doc/glibc-functions/wcstoul_l.texi: Likewise.
107966         * doc/glibc-functions/wcstoull_l.texi: Likewise.
107968 2009-11-24  Bruno Haible  <bruno@clisp.org>
107970         duplocale: Fix logic bug.
107971         * lib/duplocale.c: Don't include <langinfo.h>.
107972         (_NL_LOCALE_NAME): Remove macro.
107973         (rpl_duplocale): Use setlocale instead of nl_langinfo.
107974         * tests/test-duplocale.c (main): Also test duplocale after uselocale.
107976 2009-11-23  Jim Meyering  <meyering@redhat.com>
107978         test-update-copyright: don't hard-code /usr/bin/perl
107979         * tests/test-update-copyright.sh (YEAR): Use date +%Y, rather than
107980         perl to print the current year.  Gilles Espinasse reported that
107981         the replaced use of perl was hard-coded as /usr/bin/perl.
107983 2009-11-23  Bruno Haible  <bruno@clisp.org>
107985         duplocale: Add support for glibc 2.3.x.
107986         * lib/duplocale.c (rpl_duplocale): Add fallback code for glibc 2.3.x.
107988 2009-11-22  Bruno Haible  <bruno@clisp.org>
107990         vasnprintf: Tiny optimization.
107991         * lib/vasnprintf.c (decimal_point_char): Choose the fast path also on
107992         MacOS X.
107994 2009-11-22  Bruno Haible  <bruno@clisp.org>
107996         Tests for module 'duplocale'.
107997         * modules/duplocale-tests: New file.
107998         * tests/test-duplocale.c: New file.
108000         New module 'duplocale'.
108001         * m4/duplocale.m4: New file.
108002         * lib/locale.in.h (duplocale): New declaration.
108003         * lib/duplocale.c: New file.
108004         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_MODULE_INDICATOR,
108005         gl_LOCALE_H_DEFAULTS): New macros.
108006         (gl_LOCALE_H): Require gl_LOCALE_H_DEFAULTS. Invoke
108007         gl_CHECK_NEXT_HEADERS unconditionally. Invoke gl_REPLACE_LOCALE_H.
108008         * modules/locale (Makefile.am): Substitute also GNULIB_DUPLOCALE,
108009         REPLACE_DUPLOCALE.
108010         * modules/duplocale: New file.
108011         * doc/posix-functions/duplocale.texi: Mention the glibc bug.
108013 2009-11-22  Bruno Haible  <bruno@clisp.org>
108015         * modules/locale-tests (configure.ac): Test for newlocale function.
108016         * tests/test-locale.c: When the system has extended locale functions,
108017         verify that <locale.h> defines locale_t and LC_GLOBAL_LOCALE.
108019         locale: Make locale_t available when possible.
108020         * lib/locale.in.h: Include <xlocale.h> when it exists.
108021         * m4/locale_h.m4 (gl_LOCALE_H): Check for <xlocale.h> and arrange to
108022         replace <locale.h> if it does not define locale_t but <xlocale.h> does.
108023         * modules/locale (Depends-on): Add extensions.
108024         (Makefile.am): Also substitute HAVE_XLOCALE_H.
108025         * doc/posix-headers/locale.texi: Document the problem with locale_t.
108027 2009-11-22  Bruno Haible  <bruno@clisp.org>
108029         Add comments.
108030         * m4/dirent_h.m4 (gl_DIRENT_H): Add comment about gl_CHECK_NEXT_HEADERS
108031         invocation.
108032         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
108033         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
108034         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
108036 2009-11-22  Bruno Haible  <bruno@clisp.org>
108038         error: account for the possibility of freopen (stdout).
108039         * lib/error.c: Include <unistd.h>.
108040         (flush_stdout): New function, extracted from error and error_at_line.
108041         Determine stdout's fd dynamically.
108042         (error, error_at_line): Invoke flush_stdout.
108043         * m4/error.m4 (gl_PREREQ_ERROR): Require AC_C_INLINE.
108044         * modules/error (Depends-on): Add unistd.
108046 2009-11-22  Bruno Haible  <bruno@clisp.org>
108048         diffseq: Add comment.
108049         * lib/diffseq.h (IF_LINT): Add comment about pitfall.
108051 2009-11-22  Jim Meyering  <meyering@redhat.com>
108053         c-stack: avoid defining an unused static function
108054         * lib/c-stack.c (find_stack_direction): Do not define this function
108055         when it will not be used.
108057         diffseq: avoid spurious gcc warnings
108058         * lib/diffseq.h (IF_LINT2): Define.
108059         (compareseq): Use it to initialize two members of "part".
108060         This avoids two used-uninitialized warnings.
108062 2009-11-21  Jim Meyering  <meyering@redhat.com>
108064         c-stack: avoid "ignoring return value of `write'" warning
108065         * lib/c-stack.c: Include "ignore-value.h".
108066         (die): Explicitly ignore each write return value.
108067         * modules/c-stack (Depends-on): Add ignore-value.
108069 2009-11-21  Bruno Haible  <bruno@clisp.org>
108071         diffseq: reduce scope of variable 'best'.
108072         * lib/diffseq.h (diag) [USE_HEURISTIC]: Reduce scope of 'best'
108073         variable, earlier used for two different purposes.
108075 2009-11-21  Jim Meyering  <meyering@redhat.com>
108077         diffseq: remove useless assignment to "best"
108078         * lib/diffseq.h (diag) [USE_HEURISTIC]: Remove useless "best = 0"
108079         assignment.  At that point "best" is already guaranteed to be zero.
108081 2009-11-20  Eric Blake  <ebb9@byu.net>
108083         build: mention ftp redirector in release announcements
108084         * top/maint.mk (gnu_rel_host, url_dir_list): Provide defaults for
108085         values that used to come from cfg.mk; mention FTP redirect URL.
108086         * build-aux/announce-gen: Mention the mirror list.
108087         Suggested by Karl Berry.
108089         nanosleep: improve port to mingw
108090         * lib/nanosleep.c (rpl_nanosleep): Reject invalid arguments.
108091         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Incorporate LIBSOCKET into
108092         LIB_NANOSLEEP, but only when needed.
108093         * modules/select (Link): Document LIBSOCKET.
108094         * m4/select.m4 (gl_FUNC_SELECT): Ensure LIBSOCKET is defined early
108095         enough.
108097         nanosleep: work around cygwin bug
108098         * lib/nanosleep.c (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]:
108099         Fix logic bug when nanosleep fails.  Work around cygwin 1.5.x
108100         bug.
108101         (getnow): Delete, not needed.
108102         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): No longer require
108103         LIB_CLOCK_GETTIME.
108104         * modules/nanosleep (Depends-on): Add intprops and verify.  Drop
108105         clock-time, gettime.
108106         * doc/posix-functions/nanosleep.texi (nanosleep): Document the
108107         bug.
108108         * modules/nanosleep-tests: New test.
108109         * tests/test-nanosleep.c: New file.
108111         sleep: work around cygwin bug
108112         * lib/sleep.c (rpl_sleep): Work around the bug.
108113         * m4/sleep.m4 (gl_FUNC_SLEEP): Detect the bug.
108114         (gl_PREREQ_SLEEP): Delete unused macro.
108115         * modules/sleep (Depends-on): Add verify.
108116         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
108117         * modules/unistd (Makefile.am): Substitute witness.
108118         * lib/unistd.in.h (sleep): Update prototype.
108119         * doc/posix-functions/sleep.texi (sleep): Document the bug.
108120         * tests/test-sleep.c (main) [HAVE_DECL_ALARM]: Test it.
108121         * modules/sleep-tests (Depends-on): Check for alarm.
108123 2009-11-20  Jim Meyering  <meyering@redhat.com>
108125         maint.mk: improve sc_prohibit_magic_number_exit
108126         * top/maint.mk (sc_prohibit_magic_number_exit): Tighten regexp
108127         so it does not match uses like System.exit(1).
108128         Add comments showing how to correct all offenders.
108130 2009-11-19  Eric Blake  <ebb9@byu.net>
108132         xalloc-die-tests: add missing library
108133         * modules/xalloc-die-tests (Makefile.am): Add LDADD line.
108135         test-xvasprintf: silence compiler warnings
108136         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Mask
108137         empty string from gcc.
108139 2009-11-19  Jim Meyering  <meyering@redhat.com>
108141         xfreopen: new module, from coreutils
108142         * modules/xfreopen: New module.
108143         * lib/xfreopen.c: New file.
108144         * lib/xfreopen.h: New file.
108145         * MODULES.html.sh (File stream based Input/Output"): Add it.
108147 2009-11-19  Eric Blake  <ebb9@byu.net>
108149         manywarnings: depend on warnings
108150         * modules/manywarnings (Depends-on): Add warnings.
108152         build: avoid compiler warnings
108153         * lib/select.c (rpl_select): Delete unused variable.
108154         * lib/setsockopt.c (rpl_setsockopt): Avoid incompatible pointer.
108156 2009-11-18  Eric Blake  <ebb9@byu.net>
108158         tests: avoid false negative with --with-packager
108159         * tests/test-version-etc.sh: Discard packager information.
108160         * tests/test-argp-version-etc-1.sh: Likewise.
108161         Reported by Mike Frysinger.
108163         utimens: fix regression on Solaris
108164         * m4/utimens.m4 (gl_UTIMENS): Check for BSD bug.
108165         * lib/utimens.c (fdutimens): Revert 2009-11-08 change; Solaris 10
108166         can only change fd timestamps via futimesat.  Instead, use an
108167         additional witness macro to avoid BSD bug.
108168         Reported by Jim Meyering.
108170 2009-11-17  Eric Blake  <ebb9@byu.net>
108172         usleep: use it to simplify tests
108173         * modules/stat-time-tests (Depends-on): Add usleep.
108174         (configure.ac): Drop usleep check.
108175         * modules/chown-tests (Depends-on, configure.ac): Likewise.
108176         * modules/lchown-tests (Depends-on, configure.ac): Likewise.
108177         * modules/fdutimensat-tests (Depends-on, configure.ac): Likewise.
108178         * modules/futimens-tests (Depends-on, configure.ac): Likewise.
108179         * modules/openat-tests (Depends-on, configure.ac): Likewise.
108180         * modules/utimens-tests (Depends-on, configure.ac): Likewise.
108181         * modules/utimensat-tests (Depends-on, configure.ac): Likewise.
108182         * modules/pipe-filter-gi-tests (Depends-on, configure.ac):
108183         Likewise.
108184         * tests/test-chown.h (nap): Rely on nicer usleep semantics.
108185         * tests/test-lchown.h (nap): Likewise.
108186         * tests/test-pipe-filter-gi2-main.c (small_nap): Likewise.
108187         * tests/test-stat-time.c (nap): Likewise.
108188         * tests/test-utimens-common.h (nap): Update comments.
108190         usleep: new module
108191         * modules/usleep: New file.
108192         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
108193         * lib/usleep.c (usleep): Likewise.
108194         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
108195         * modules/unistd (Makefile.am): Substitute witnesses.
108196         * lib/unistd.in.h (usleep): Add declaration.
108197         * doc/pastposix-functions/usleep.texi (usleep): Document this.
108198         * MODULES.html.sh (Date and time): Likewise.
108199         * modules/usleep-tests (Depends-on): New test.
108200         * tests/test-usleep.c: New file.
108202         chown: work around OpenBSD bug
108203         * lib/chown.c (rpl_chown): Work around the bug.
108204         * lib/lchown.c (rpl_lchown): Attempt to do likewise.
108205         * m4/chown.m4 (gl_FUNC_CHOWN): Test for ctime bug.
108206         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for lchmod.
108207         * modules/chown (Depends-on): Add stdbool.
108208         * modules/lchown (Depends-on): Likewise.
108209         * doc/posix-functions/chown.texi (chown): Document the bug.
108210         * doc/posix-functions/lchown.texi (lchown): Likewise.
108211         * tests/test-lchown.h (test_chown): Relax test.
108213         mkstemp: avoid conflict with C++ keyword template
108214         * lib/mkdtemp.c (mkdtemp): Change spelling of template.
108215         * lib/mkostemp.c (mkostemp): Likewise.
108216         * lib/mkostemps.c (mkostemps): Likewise.
108217         * lib/mkstemp.c (mkstemp): Likewise.
108218         * lib/mkstemps.c (mkstemps): Likewise.
108220         xalloc-die-tests: optimize
108221         * tests/test-xalloc-die.sh: Reduce number of processes.
108223 2009-11-17  Simon Josefsson  <simon@josefsson.org>
108225         * gnulib-tool: Support LGPLv3+ licenses in module files.  Tiny
108226         patch from ludo@gnu.org (Ludovic Courtès).
108228 2009-11-17  Jim Meyering  <meyering@redhat.com>
108230         version-etc: use proper license string
108231         * modules/version-etc (License): Use LGPL, not LGPLv3+.
108232         * modules/version-etc-fsf: Likewise.
108234 2009-11-17  Simon Josefsson  <simon@josefsson.org>
108236         * tests/test-xalloc-die.sh: Add license.  Check that nothing is
108237         printed to stdout.  Deal with EOL differences.
108239 2009-11-17  Eric Blake  <ebb9@byu.net>
108241         unsetenv: work around Solaris bug
108242         * m4/setenv.m4 (gl_FUNC_UNSETENV): Check for bug.
108243         * lib/unsetenv.c (rpl_unsetenv): Work around it.
108244         Reported by Jim Meyering.
108246         vasnprintf: avoid compiler warnings
108247         * lib/vasnprintf.c (VASNPRINTF): Avoid shadowing our own local
108248         variables.
108249         * lib/printf-args.c (PRINTF_FETCHARGS): Avoid type mismatch.
108251 2009-11-17  Simon Josefsson  <simon@josefsson.org>
108253         * modules/xalloc-die-tests (Makefile.am): Drop XFAIL_TESTS
108254         settings since xalloc-die is no longer the self test,
108255         xalloc-die.sh is.
108257 2009-11-17  Jim Meyering  <meyering@redhat.com>
108259         test-xalloc-die.sh: make the code agree with the commit log
108260         * tests/test-xalloc-die.sh: Put "." at the front of $PATH, not
108261         at the end, just in case you happen to have a test-xalloc-die
108262         program in some other PATH directory.
108264         test-xalloc-die.sh: fix a portability bug
108265         * tests/test-xalloc-die.sh: Do not invoke via ./test-xalloc-die.
108266         Instead, set PATH to start with "." and invoke via "test-xalloc-die".
108267         Otherwise, argv[0] (as often seen in diagnostics) would be too
108268         system-dependent, sometimes with, and sometimes without the leading "./".
108270         version-etc-fsf: relax license to LGPLv3+
108271         * modules/version-etc-fsf (License): Relax license.
108273 2009-11-16  Eric Blake  <ebb9@byu.net>
108275         xalloc-die-tests: avoid printing null pointer
108276         * modules/xalloc-die-tests (Files, Makefile.am): Wrap execution in
108277         shell script.
108278         * tests/test-xalloc-die.c (program_name): Declare.
108279         * tests/test-xalloc-die.sh (tmpfiles): New file.
108281         setenv, unsetenv: work around various bugs
108282         * lib/setenv.c (setenv) [!HAVE_SETENV]: Resync from glibc.
108283         (setenv) [HAVE_SETENV]: Work around bugs.
108284         * lib/unsetenv.c (unsetenv) [HAVE_UNSETENV]: Work around bugs.
108285         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE, gl_FUNC_UNSETENV): Check
108286         for bugs.
108287         (gl_FUNC_SETENV): Write in terms of gl_FUNC_SETENV_SEPARATE.
108288         * m4/environ.m4 (gl_ENVIRON): Avoid expand-before-require.
108289         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Update defaults.
108290         * modules/stdlib (Makefile.am): Update substitutions.
108291         * lib/stdlib.in.h (setenv, unsetenv): Update prototypes.
108292         * doc/posix-functions/setenv.texi (setenv): Document the bugs.
108293         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
108294         * modules/setenv-tests: New test.
108295         * modules/unsetenv-tests: Likewise.
108296         * tests/test-setenv.c: New file.
108297         * tests/test-unsetenv.c: Likewise.
108299 2009-11-16  Jim Meyering  <meyering@redhat.com>
108301         version-etc: relax license to LGPLv3+
108302         * modules/version-etc (License): Relax license.
108304         better AC_REQUIRE expanded-before-required-warning avoidance
108305         * m4/chown.m4 (gl_FUNC_CHOWN, gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Define
108306         with AC_DEFUN_ONCE, rather than AC_DEFUN, to avoid AC_REQUIRE warnings.
108307         Suggested by Eric Blake.  This change also reverts commit 1b712ba8,
108308         which is no longer needed.
108310 2009-11-16  Eric Blake  <ebb9@byu.net>
108312         test-freading: clean up temporary file
108313         * tests/test-freading.c (main): Remove file on success, and use
108314         ASSERT more liberally.
108315         Reported by Jim Meyering.
108317 2009-11-16  Jim Meyering  <meyering@redhat.com>
108319         avoid new AC_REQUIRE expanded-before-required warnings
108320         * modules/chown (configure.ac): Require gl_FUNC_CHOWN, rather than
108321         merely using it.
108322         * modules/euidaccess (configure.ac): Likewise for gl_FUNC_EUIDACCESS.
108323         * modules/faccessat (configure.ac): Likewise for gl_FUNC_FACCESSAT.
108325 2009-11-15  Simon Josefsson  <simon@josefsson.org>
108327         * tests/test-xalloc-die.c: New file.
108328         * modules/xalloc-die-tests: New file.
108329         * gnulib-tool (func_emit_tests_Makefile_am): Also initialize
108330         XFAIL_TESTS so it can be appended by modules.
108332 2009-11-15  Simon Josefsson  <simon@josefsson.org>
108334         * lib/gc-pbkdf2-sha1.c: Remove comments from RFC 2898.  Reported
108335         by Vladimir 'phcoder' Serbinenko <phcoder@gmail.com>.
108337 2009-11-14  Eric Blake  <ebb9@byu.net>
108339         fnmatch: avoid compiler warning
108340         * lib/fnmatch_loop.c (NEW_PATTERN): Coerce addition to unsigned,
108341         to silence compiler warning about mismatch signedness in ?:.
108342         Reported by Robert Millan.
108344         intprops: add double-inclusion guard
108345         * lib/intprops.h: Allow idempotent includes.
108346         Suggested by Bruce Korb.
108348         openat: detect Solaris fchownat bug
108349         * lib/fchownat.c (rpl_fchownat): Work around Solaris bug.  Avoid
108350         penalizing glibc chownat when only lchownat is broken.
108351         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Replace fchownat if there are
108352         trailing slash bugs.
108353         * doc/posix-functions/fchownat.texi (fchownat): Document the bug.
108354         * modules/openat-tests (Files): Include more files.
108355         (Depends-on): Add mgetgroups, sleep, stat-time.
108356         (configure.ac): Add additional checks.
108357         (Makefile.am): Build new test.
108358         * tests/test-fchownat.c: New file.
108360         lchown: detect Solaris and FreeBSD bug
108361         * lib/lchown.c (rpl_lchown): Work around bug.
108362         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for trailing slash bugs.
108363         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
108364         * modules/unistd (Makefile.am): Populate it.
108365         * lib/unistd.in.h (lchown): Update declaration.
108366         * doc/posix-functions/lchown.texi (lchown): Document the bug.
108367         * modules/lchown-tests: New file.
108368         * tests/test-lchown.h (test_lchown): Likewise.
108369         * tests/test-lchown.c (main): Likewise.
108371         chown: detect Solaris and FreeBSD bug
108372         * lib/chown.c (rpl_chown): Work around bug.
108373         * m4/chown.m4 (gl_FUNC_CHOWN): Check for trailing slash bugs.
108374         (gl_PREREQ_CHOWN): Delete.
108375         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
108376         * modules/unistd (Makefile.am): Populate it.
108377         * lib/unistd.in.h (chown): Update declaration.
108378         * lib/lchown.c (chown): Update client.
108379         * modules/lchown (Depends-on): Add lstat.
108380         * doc/posix-functions/chown.texi (chown): Document the bug.
108381         * doc/posix-functions/getgroups.texi (getgroups): Document
108382         getgroups pitfall.
108383         * modules/chown-tests: New file.
108384         * tests/test-chown.h (test_chown): Likewise.
108385         * tests/test-chown.c (main): Likewise.
108387 2009-11-14  Robert Millan  <rmh.grub@aybabtu.com>  (tiny change)
108389         gnulib-tool: correctly detect absence of m4 directories
108390         * gnulib-tool: Avoid extra newline on data passed to wc -l.
108392 2009-11-14  Jim Meyering  <meyering@redhat.com>
108394         maint.mk: Prohibit inclusion of "xalloc.h" without use.
108395         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
108397 2009-11-14  John W. Eaton  <jwe@gnu.org>
108399         strftime.h: wrap function declaration in extern "C" block
108400         * lib/strftime.h (nstrftime) [__cplusplus]: Wrap declaration.
108402 2009-11-13  Eric Blake  <ebb9@byu.net>
108404         getgroups: avoid compiler warning
108405         * lib/getgroups.c (rpl_getgroups): Delete shadowed variable.
108407         getgroups: work around FreeBSD bug
108408         * lib/getgroups.c (rpl_getgroups): Work around the bug.
108409         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Detect the bug.
108410         * doc/posix-functions/getgroups.texi (getgroups): Document it.
108411         * tests/test-getgroups.c (main): Fix buffer overrun.
108413         getgroups: avoid compilation failure
108414         * lib/getgroups.c (includes): Include <stdint.h> for SIZE_MAX.
108415         * modules/getgroups (Depends-on): Add stdint.
108417 2009-11-13  Jim Meyering  <meyering@redhat.com>
108419         test-getgroups: avoid compilation failure
108420         * tests/test-getgroups.c: Include <stdint.h> for use of SIZE_MAX.
108422 2009-11-13  Eric Blake  <ebb9@byu.net>
108424         mgetgroups: new module, taken from coreutils
108425         * modules/mgetgroups: New file.
108426         * lib/mgetgroups.h: Likewise.
108427         * lib/mgetgroups.c (mgetgroups): Likewise.
108428         * m4/mgetgroups.m4 (gl_MGETGROUPS): Likewise.
108429         * MODULES.html.sh (Users and groups): Mention it.
108431         getgroups: don't expose GETGROUPS_T to user
108432         * lib/getgroups.c (rpl_getgroups): Change signature.  Copy array
108433         an element at a time if GETGROUPS_T is wrong size.
108434         * lib/getugroups.h (getugroups): Change signature.
108435         * lib/unistd.in.h (getgroups): Likewise.
108436         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Use replacement if
108437         signature needs fixing.
108438         * m4/getugroups.m4 (gl_GETUGROUPS): No longer need
108439         AC_TYPE_GETGROUPS.
108440         * modules/group-member (Depends-on): Add getgroups.
108441         * lib/group-member.c (group_info, get_group_info): Use gid_t.
108442         (group_member): Rely on getgroups replacement.
108443         * lib/getugroups.c (getugroups): Use gid_t.
108444         * tests/test-getgroups.c (main): Likewise.
108445         * NEWS: Mention the signature change.
108446         * doc/posix-functions/getgroups.texi (getgroups): Mention the
108447         problem with signature.
108448         * doc/glibc-functions/setgroups.texi (setgroups): Mention that
108449         GETGROUPS_T is still useful for setgroups.
108451         getgroups, getugroups: provide stubs for mingw
108452         * lib/getgroups.c (getgroups): Provide ENOSYS stub for mingw.
108453         * lib/getugroups.c (getugroups): Likewise.
108454         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Check for missing
108455         function.  Modernize replacement scheme.
108456         (gl_PREREQ_GETGROUPS): Delete.
108457         * m4/getugroups.m4 (gl_GETUGROUPS): Check for <grp.h>.
108458         * modules/getgroups (configure.ac): Declare witness.
108459         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
108460         * modules/unistd (Depends-on): Substitute witness.
108461         * lib/unistd.in.h (getgroups): Declare replacement.
108463         getgroups: avoid calling exit
108464         * modules/getgroups (Depends-on): Add malloc-posix and unistd,
108465         drop xalloc.
108466         * modules/getgroups-tests (Depends-on, Makefile.am): Drop unneeded
108467         dependencies.
108468         * lib/getgroups.c (rpl_getgroups): Fail with ENOMEM rather than
108469         exiting, in the rare case of malloc failure.
108471         getgroups: fix logic error
108472         * lib/getgroups.c (rpl_getgroups): Don't fail if current process
108473         has more than 20 groups.
108474         * modules/getgroups-tests: New test.
108475         * tests/test-getgroups.c: New file.
108477 2009-11-13  Simon Josefsson  <simon@josefsson.org>
108479         * tests/test-base64.c: Improve.
108481 2009-11-13  Simon Josefsson  <simon@josefsson.org>
108483         * tests/test-xvasprintf.c: Fix memory leak, suggested by Eric
108484         Blake <ebb9@byu.net>.
108486 2009-11-13  Simon Josefsson  <simon@josefsson.org>
108488         * tests/test-xvasprintf.c: Add %s%s related checks.
108490 2009-11-12  Eric Blake  <ebb9@byu.net>
108492         version-etc: match standards.texi style
108493         * lib/version-etc.c (emit_bug_reporting_address): Drop periods,
108494         and use <> only for URLs.
108496 2009-11-10  Kamil Dudka  <kdudka@redhat.com>
108498         fts: do not fail on a submount during traversal
108499         * lib/fts.c (fts_build): Read the stat info again after opening
108500         a directory if the FTS_TIGHT_CYCLE_CHECK flag is set.
108501         Original report at http://bugzilla.redhat.com/501848.
108503 2009-11-12  Jim Meyering  <meyering@redhat.com>
108505         bootstrap: sync from coreutils
108506         * build-aux/bootstrap (bootstrap_epilogue): New function.
108507         Use git_modules_config in one more place.  This make bootstrap's
108508         --gnulib-srcdir option more useful for testing.
108510         bootstrap: generalize autoheader check
108511         * build-aux/bootstrap: Look for AC_CONFIG_HEADER as well as
108512         AC_CONFIG_HEADERS.
108514 2009-11-11  Eric Blake  <ebb9@byu.net>
108516         mkfifoat: use new modules for Solaris and BSD bugs
108517         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Simplify.
108518         * lib/mkfifoat.c (mknodat): Split...
108519         * lib/mknodat.c (mknodat): ...into new file.
108520         * modules/mkfifoat (Files): Ship new file.
108521         (Depends-on): Add mkfifo, mknod.
108522         * modules/mkfifoat-tests (Files): Reuse mkfifo tests.
108523         (Depends-on): Add symlink.
108524         * tests/test-mkfifoat.c (main): Enhance test.  Drop portions now
108525         redundant with test_mkfifo.h.
108526         (do_mkfifoat, do_mknodat): New helpers.
108528         mknod: new module
108529         * modules/mknod: New file.
108530         * m4/mknod.m4 (gl_FUNC_MKNOD): Likewise.
108531         * lib/mknod.c (mknod): Likewise.
108532         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
108533         defaults.
108534         * modules/sys_stat (Makefile.am): Substitute them.
108535         * lib/sys_stat.in.h (mknod): Declare replacement.
108536         * MODULES.html.sh (Support for systems lacking POSIX:2008):
108537         Document it.
108538         * doc/posix-functions/mknod.texi (mknod): Likewise.
108539         * modules/mknod-tests: New test.
108540         * tests/test-mknod.c: Likewise.
108542         mkfifo: new module
108543         * modules/mkfifo: New file.
108544         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
108545         * lib/mkfifo.c (mkfifo): Likewise.
108546         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
108547         defaults.
108548         * modules/sys_stat (Makefile.am): Substitute them.
108549         * lib/sys_stat.in.h (mkfifo): Declare replacement.
108550         * MODULES.html.sh (Support for systems lacking POSIX:2008):
108551         Document it.
108552         * doc/posix-functions/mkfifo.texi (mkfifo): Likewise.
108553         * modules/mkfifo-tests: New test.
108554         * tests/test-mkfifo.h (test_mkfifo): New file, borrowed in part
108555         from test-mkfifoat.c.
108556         * tests/test-mkfifo.c: New file.
108558         readlink: detect FreeBSD bug
108559         * m4/readlink.m4 (gl_FUNC_READLINK): Also detect FreeBSD bug with
108560         slash on symlink.
108561         * doc/posix-functions/readlink.texi (readlink): Document the bug.
108562         * tests/test-readlink.h (test_readlink): Enhance test.
108564         symlink: detect FreeBSD bug
108565         * m4/symlink.m4 (gl_FUNC_SYMLINK): Also detect FreeBSD bug with
108566         slash on symlink.
108567         * doc/posix-functions/symlink.texi (symlink): Document the bug.
108568         * tests/test-symlink.h (test_symlink): Enhance test.
108570 2009-11-10  Eric Blake  <ebb9@byu.net>
108572         link: detect FreeBSD bug
108573         * m4/link.m4 (gl_FUNC_LINK): Also detect FreeBSD bug with slash on
108574         symlink.
108575         * doc/posix-functions/link.texi (link): Document the bug.
108576         * tests/test-link.h (test_link): Enhance test.
108577         * tests/test-linkat.c (main): Update caller.
108579         unlink, remove: detect FreeBSD bug
108580         * m4/unlink.m4 (gl_FUNC_UNLINK): Also detect FreeBSD bug with
108581         slash on symlink.
108582         * doc/posix-functions/unlink.texi (unlink): Document the bug.
108583         * doc/posix-functions/remove.texi (remove): Likewise.
108584         * tests/test-unlink.h (test_unlink): Enhance test.
108585         * tests/test-remove.c (main): Likewise.
108587 2009-11-09  Eric Blake  <ebb9@byu.net>
108589         rename: detect FreeBSD bug
108590         * m4/rename.m4 (gl_FUNC_RENAME): Also detect FreeBSD bug with
108591         slash on symlink.
108592         * modules/renameat-tests (Depends-on): Add filenamecat.
108593         * tests/test-rename.h (test_rename): Allow one more errno.
108594         * tests/test-renameat.c (main): Likewise.
108595         * doc/posix-functions/rename.texi (rename): Document the bug.
108597         open: detect FreeBSD bug
108598         * m4/open.m4 (gl_FUNC_OPEN): Also detect FreeBSD bug with slash on
108599         symlink.
108600         * doc/posix-functions/open.texi (open): Document the bug.
108601         * doc/posix-functions/utimes.texi (utimes): Likewise.
108602         * tests/test-open.h (test_open): Add parameters, and test symlink
108603         handling.
108604         * tests/test-open.c (main): Adjust caller.
108605         * tests/test-fcntl-safer.c (main): Likewise.
108606         * modules/open-tests (Depends-on): Add stdbool, symlink.
108607         * modules/fcntl-safer-tests (Depends-on): Likewise.
108608         * tests/test-openat.c (main): Add test-open tests.
108610         stat: detect FreeBSD bug
108611         * m4/stat.m4 (gl_FUNC_STAT): Also detect FreeBSD bug with slash on
108612         symlink.
108613         * doc/posix-functions/stat.texi (stat): Document the bug.
108614         * tests/test-stat.h (test_stat_func): Add argument.
108615         * tests/test-stat.c (main): Adjust caller.
108616         * tests/test-fstatat.c (main): Likewise.
108617         * modules/stat-tests (Depends-on): Add stdbool, symlink.
108618         Reported by Jim Meyering.
108620 2009-11-09  James Youngman  <jay@gnu.org>
108622         strftime.c: include ignore-value.h only when FPRINTFTIME is defined
108623         * lib/strftime.c: Correct placement of #include "ignore-value.h".
108625 2009-11-08  Jim Meyering  <meyering@redhat.com>
108627         utimens: remove invalid futimesat call
108628         * lib/utimens.c (fdutimens): Remove invalid futimesat call.
108629         It used the file descriptor of the target file as the DIR_FD
108630         parameter and NULL as the file name.  That caused failure with
108631         errno == EFAULT on FreeBSD-8.0-rc2
108633 2009-11-07  Eric Blake  <ebb9@byu.net>
108635         fflush, freadseek: use fseeko, not fseek
108636         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
108637         (clear_ungetc_buffer): Avoid potential problems on large files.
108638         * lib/freadseek.c (freadseek): Likewise.
108639         * modules/freadseek (Depends-on): Add fseeko.
108640         * modules/fseek (configure.ac): Set a witness.
108641         * tests/test-fflush.c (main): Use fseeko.
108642         * tests/test-fpurge.c (fseek): Disable link warning.
108643         * tests/test-freadable.c (fseek): Likewise.
108644         * tests/test-freading.c (fseek): Likewise.
108645         * tests/test-fseeko.c (fseek): Likewise.
108646         * tests/test-ftell.c (fseek): Likewise.
108647         * tests/test-ftello.c (fseek): Likewise.
108648         * tests/test-fwritable.c (fseek): Likewise.
108649         * tests/test-fwriting.c (fseek): Likewise.
108651 2009-11-06  Simon Josefsson  <simon@josefsson.org>
108653         * modules/memchr (Depends-on): Drop getpagesize dependency.
108655 2009-11-06  Simon Josefsson  <simon@josefsson.org>
108657         * build-aux/pmccabe2html: Disable execute bit.  Suggested by
108658         Reported by Ludovic Courtès.
108659         * build-aux/pmccabe2html: Improve example usage.
108660         * build-aux/pmccabe2html: Drop #! header.  Doc fix.
108662 2009-11-06  Jim Meyering  <meyering@redhat.com>
108664         do-release-commit-and-tag: New module.
108665         Automate the release-commit and tag process.
108666         * build-aux/do-release-commit-and-tag: New script, from coreutils.
108667         * modules/do-release-commit-and-tag: New file.
108668         * MODULES.html.sh (Support for maintaining and releasing): Add it.
108670 2009-11-06  Simon Josefsson  <simon@josefsson.org>
108672         * modules/select-tests (test_select_LDADD): Add $(INET_PTON_LIB)
108673         because test-select.c uses inet_pton.
108675 2009-11-06  Simon Josefsson  <simon@josefsson.org>
108677         * m4/getaddrinfo.m4: Add content of INET_NTOP_LIB to
108678         GETADDRINFO_LIB.  Bump serial number.
108679         * modules/getaddrinfo (Link): Only mention GETADDRINFO_LIB again.
108680         Suggested by Eric Blake <ebb9@byu.net>.
108682 2009-11-05  Eric Blake  <ebb9@byu.net>
108684         strtod: detect darwin bug
108685         * m4/strtod.m4 (gl_FUNC_STRTOD): Filter out darwin bug on "nan(".
108686         Reported by Leo Davis.
108688         freopen-safer: new module
108689         * modules/freopen-safer: New module.
108690         * m4/stdio-safer.m4 (gl_FREOPEN_SAFER): New macro.
108691         * lib/freopen-safer.c (freopen_safer): New file.
108692         * lib/stdio-safer.h (freopen_safer): New declaration.
108693         * lib/stdio--.h (freopen): New override.
108694         * MODULES.html.sh (File stream based Input/Output): Mention it.
108695         * doc/posix-functions/freopen.texi (freopen): Mention pitfalls and
108696         freopen-safer module.
108697         * doc/posix-functions/stderr.texi (stderr): Likewise.
108698         * doc/posix-functions/stdin.texi (stdin): Likewise.
108699         * doc/posix-functions/stdout.texi (stdout): Likewise.
108700         * modules/freopen-safer-tests: New test.
108701         * tests/test-reopen-safer.c: New file.
108703 2009-11-05  Jim Meyering  <meyering@redhat.com>
108705         maint.mk: Prohibit inclusion of "close-stream.h" without use.
108706         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
108708 2009-11-05  Simon Josefsson  <simon@josefsson.org>
108710         * modules/pmccabe2html (configure.ac): Check for pmccabe tool.
108712 2009-11-05  Simon Josefsson  <simon@josefsson.org>
108714         * modules/getaddrinfo (Link): Add $(INET_NTOP_LIB).
108716 2009-11-05  Simon Josefsson  <simon@josefsson.org>
108718         Fix link error.
108719         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
108720         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
108722 2009-11-05  Simon Josefsson  <simon@josefsson.org>
108724         * tests/test-func.c: Also test value of __func__.
108726 2009-11-05  Simon Josefsson  <simon@josefsson.org>
108728         * tests/test-sys_socket.c: Use smaller constant value, sa_family_t
108729         may be an 8-bit type.  Reported by Bruno Haible <bruno@clisp.org>.
108731 2009-11-05  Bruno Haible  <bruno@clisp.org>
108733         Fix link error.
108734         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
108735         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
108736         Reported by Brad Hards <bradh@frogmouth.net> via Simon Josefsson.
108738 2009-11-05  Bruno Haible  <bruno@clisp.org>
108740         Tests for module 'inet_pton'.
108741         * modules/inet_pton-tests: New file.
108742         * tests/test-inet_pton.c: New file.
108744 2009-11-05  Bruno Haible  <bruno@clisp.org>
108746         Tests for module 'inet_ntop'.
108747         * modules/inet_ntop-tests: New file.
108748         * tests/test-inet_ntop.c: New file.
108750 2009-11-04  Eric Blake  <ebb9@byu.net>
108752         stdlib-safer: wrap all mkstemp variants
108753         * modules/mkostemp (configure.ac): Set witness.
108754         * modules/mkostemps (configure.ac): Likewise.
108755         * modules/mkstemps (configure.ac): Likewise.
108756         * lib/stdlib-safer.h (mkostemp_safer, mkostemps_safer)
108757         (mkstemps_safer): Wrap more functions.
108758         * lib/stdlib--.h (mkostemp, mkostemps, mkstemps): Default the
108759         wrapping.
108760         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer)
108761         (mkstemps_safer): Implement the wrappers.
108763         mkstemps, mkostemps: new modules
108764         * modules/mkostemps: New module.
108765         * modules/mkstemps: Likewise.
108766         * lib/mkostemps.c (mkostemps): New file.
108767         * lib/mkstemps.c (mkstemps): Likewise.
108768         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Likewise.
108769         * m4/mkstemps.m4 (gl_FUNC_MKSTEMPS): Likewise.
108770         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Add witnesses.
108771         * modules/stdlib (Makefile.am): Substitute them.
108772         * lib/stdlib.in.h (mkostemps, mkstemps): Declare them.
108773         * doc/glibc-functions/mkstemps.texi (mkstemps): New file.
108774         * doc/glibc-functions/mkostemps.texi (mkostemps): Likewise.
108775         * doc/gnulib.texi (Glibc stdlib.h): Include them.
108776         * MODULES.html.sh (File system functions): Mention them.
108778         tempname: resync from glibc
108779         * lib/tempname.c (__gen_tempname): Add suffixlen argument.  Use
108780         same values for __GT_FILE as glibc.  Abort even when assertions
108781         are disabled.
108782         * lib/tempname.h (GT_FILE): Use glibc __GT_FILE, if available, and
108783         match its value otherwise.  Allow idempotent inclusion.
108784         * lib/mkdtemp.c (mkdtemp): Adjust caller.
108785         * lib/mkostemp.c (mkostemp): Likewise.
108786         * lib/mkstemp.c (mkstemp): Likewise.
108787         * lib/tmpfile.c (tmpfile): Likewise.
108788         * NEWS: Document this.
108790         utimens: fix use of futimens on older Linux
108791         * lib/utimens.c (fdutimens): Use updated, rather than original,
108792         timespec to avoid bug in older Linux kernel.
108793         Reported by Simon Josefsson.
108795 2009-11-04  Bruno Haible  <bruno@clisp.org>
108797         Make num_processors more flexible and consistent.
108798         * lib/nproc.h (enum nproc_query): New type.
108799         (num_processors): Add a 'query' argument.
108800         * lib/nproc.c: Include <stdlib.h>, <sched.h>, c-ctype.h.
108801         (num_processors): Add a 'query' argument. Test the value of the
108802         OMP_NUM_THREADS environment variable if requested. On Linux, NetBSD,
108803         mingw, count the number of CPUs available for the current process.
108804         * m4/nproc.m4 (gl_PREREQ_NPROC): Require AC_USE_SYSTEM_EXTENSIONS.
108805         Check for sched_getaffinity and sched_getaffinity_np.
108806         * modules/nproc (Depends-on): Add c-ctype, extensions.
108807         * NEWS: Mention the change.
108809 2009-11-03  Bruno Haible  <bruno@clisp.org>
108811         * NEWS: Document the new library dependencies of inet_ntop, inet_pton.
108813 2009-11-03  Jim Meyering  <meyering@redhat.com>
108815         test-getaddrinfo: avoid compilation failure on FreeBSD 7.2
108816         * tests/test-getaddrinfo.c (simple): Test for EAI_NODATA only
108817         if it is defined.
108819 2009-11-02  Eric Blake  <ebb9@byu.net>
108821         mktime, timegm: share common declaration
108822         * lib/mktime-internal.h: New file.
108823         * lib/mktime.c: Use it rather than open-coding a declaration.
108824         * lib/timegm.c: Likewise.
108825         * modules/mktime (Files): Ship it.
108826         * modules/timegm (Files): Likewise.
108827         Suggested by Bruno Haible.
108829         test-update-copyright: update test to match script changes
108830         * tests/test-update-copyright.sh: Avoid hard-coding perl
108831         location.  Don't update *.bak created by earlier runs.
108833 2009-11-02  Paul Eggert  <eggert@cs.ucla.edu>
108834             Simon Josefsson  <simon@josefsson.org>
108835             Bruno Haible  <bruno@clisp.org>
108837         Fix link error on Solaris 8.
108838         * m4/inet_pton.m4 (gl_INET_PTON): Search for the function inet_pton
108839         also in libnsl. Define also INET_PTON_LIB.
108840         * modules/inet_pton (Link): New section.
108842 2009-11-02  Simon Josefsson  <simon@josefsson.org>
108843             Bruno Haible  <bruno@clisp.org>
108845         * m4/inet_ntop.m4 (gl_INET_NTOP): Define also INET_NTOP_LIB.
108846         * modules/inet_ntop (Link): New section.
108847         Reported by Boyan Kasarov <bkasarov@gmail.com>.
108849 2009-11-02  Eric Blake  <ebb9@byu.net>
108851         maint: avoid compiler warnings in m4 macros
108852         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Avoid unused variable.
108853         * m4/rmdir.m4 (gl_FUNC_RMDIR): Include correct header.
108855 2009-11-02  Simon Josefsson  <simon@josefsson.org>
108857         * m4/pmccabe2html.m4: Remove file.
108858         * modules/pmccabe2html: Drop pmccabe2html.m4.  Don't call m4
108859         function.  Change maintainer.
108860         * build-aux/pmccabe2html: Use /bin/sh with magic instead of
108861         hard-coding path to awk.  Tiny patch from ludo@gnu.org (Ludovic
108862         Courtès).
108864 2009-10-31  Eric Blake  <ebb9@byu.net>
108866         fseeko: fix m4 regression
108867         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Use modern macro.  Fixes
108868         regression from 2009-10-27.
108869         Reported by Ralf Wildenhues.
108871 2009-10-31  Jim Meyering  <meyering@redhat.com>
108873         inttostr: aesthetics and improved (compile-time) safety
108874         Define inttype_is_signed rather than inttype_is_unsigned,
108875         since the sole use is via "#if inttype_is_signed".
108876         * lib/imaxtostr.c (inttype_is_signed): Define this, rather than
108877         inttype_is_unsigned.
108878         * lib/offtostr.c (inttype_is_signed): Likewise.
108879         * lib/uinttostr.c (inttype_is_signed): Likewise.
108880         * lib/umaxtostr.c (inttype_is_signed): Likewise.
108881         * lib/inttostr.c (inttostr): Use verify to cross-check the
108882         inttype_is_signed value and the signedness of the actual type.
108883         * modules/inttostr (Depends-on): Add verify.
108885 2009-10-30  Eric Blake  <ebb9@byu.net>
108887         build: avoid compiler warnings
108888         * lib/fchmodat.c (lchmod): Mark unused variables.
108889         * lib/getopt.c (_getopt_initialize): Likewise.
108890         * lib/mktime.c (__mktime_internal): Provide prototype.
108891         * lib/inttostr.c (inttostr): Avoid compiler warning even with
108892         older gcc that do not understand #pragma GCC diagnostic.
108893         * lib/uinttostr.c (inttype_is_unsigned): Define.
108894         * lib/umaxtostr.c (inttype_is_unsigned): Likewise.
108896 2009-10-30  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
108898         stat: fix compilation on AIX
108899         * lib/sys_stat.in.h (stat): Work with fact that large files on AIX
108900         only see struct stat64.
108902 2009-10-30  Eric Blake  <ebb9@byu.net>
108904         exclude: make more robust
108905         * lib/exclude.c (excluded_file_name): Abort on unexpected value,
108906         rather than masking a coding bug.
108907         Suggested by Bruno Haible.
108909 2009-10-30  Jim Meyering  <meyering@redhat.com>
108911         perl scripts: remove #!/usr/bin/perl in favor of more portable...
108912         Rather than putting #!/usr/bin/perl on the first line,
108913         start with a variant of what's recommended by "man perlrun" that
108914         invokes the first "perl" program from your shell's search path.
108915         * build-aux/gitlog-to-changelog: Replace #!... as above.
108916         Add a "Local Variables" perl mode setting.
108917         Prompted by a patch from Ludovic Courtès.
108918         Improved by Eric Blake.
108919         * build-aux/useless-if-before-free: Likewise.
108920         * build-aux/announce-gen: Likewise.
108921         * build-aux/update-copyright: Likewise.
108923 2009-10-29  Eric Blake  <ebb9@byu.net>
108925         filenamecat-lgpl: adjust clients
108926         * modules/linkat (Depends-on): Use filenamecat-lgpl, not
108927         filenamecat.
108928         * modules/renameat (Depends-on): Likewise.
108930         filenamecat: split into filenamecat-lgpl
108931         * modules/filenamecat-lgpl: New module.
108932         * modules/filenamecat (Files): Move library-safe files into
108933         filenamecat-lgpl.
108934         (Depends-on): Add filenamecat-lgpl.
108935         (configure.ac): Declare witness.
108936         * lib/filenamecat.h (file_name_concat): Only declare when using
108937         GPL module.
108938         * lib/filenamecat.c (longest_relative_suffix, mfile_name_concat):
108939         Move...
108940         * lib/filenamecat-lgpl.c: ...into new file.
108941         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT_LGPL): New macro.
108942         (gl_FILE_NAME_CONCAT): Use it.
108943         * MODULES.html.sh (File system functions): Mention new module.
108945         argp: avoid memory leak
108946         * modules/argp (Depends-on): Use dirname-lgpl, not dirname.
108947         * lib/argp-namefrob.h (__argp_base_name): Use last_component, not
108948         base_name, since the latter malloc()s and can call exit().
108949         Leak introduced 2006-07-03.
108951         dirname-lgpl: adjust clients that don't need full dirname
108952         * modules/backupfile (Depends-on): Use dirname-lgpl, not dirname.
108953         * modules/filenamecat (Depends-on): Likewise.
108954         * modules/linkat (Depends-on): Likewise.
108955         * modules/mkancesdirs (Depends-on): Likewise.
108956         * modules/mkdir (Depends-on): Likewise.
108957         * modules/openat (Depends-on): Likewise.
108958         * modules/savewd (Depends-on): Likewise.
108959         * modules/rename (Depends-on): Likewise.
108960         (License): Relax license.
108961         * modules/mkdir-tests (Depends-on): Drop progname.
108962         (Makefile.am): Delete unneeded LDADD.
108963         * modules/rename-tests (Depends-on, Makefile.am): Likewise.
108965         dirname: split into dirname-lgpl
108966         * modules/dirname-lgpl: New module.
108967         * modules/dirname (Files): Move library-safe files into
108968         dirname-lgpl.
108969         (Depends-on): Add dirname-lgpl.
108970         (configure.ac): Declare witness.
108971         * modules/double-slash-root (License): Relax license.
108972         * lib/dirname.h (base_name, dir_name): Only declare when using GPL
108973         module.
108974         * lib/dirname.c (dir_len, mdir_name): Move...
108975         * lib/dirname-lgpl.c: ...into new file.
108976         * lib/basename.c (last_component, base_len): Move...
108977         * lib/basename-lgpl.c: ...into new file.
108978         * m4/dirname.m4 (gl_DIRNAME_LGPL): New macro.
108979         (gl_DIRNAME): Use it.
108980         * MODULES.html.sh (Enhancements for POSIX:2008 functions):
108981         Mention new module.
108982         * modules/dirname-tests (Depends-on): Add progname.
108983         * tests/test-dirname.c (program_name): Delete.
108985         mkdir: make safe for libraries
108986         * modules/mkdir (Depends-on): Drop xalloc.
108987         * lib/mkdir.c (rpl_mkdir): Fail with ENOMEM rather than calling
108988         exit.
108990         tests: avoid some compiler warnings
108991         * tests/test-getaddrinfo.c (simple): Mark static, and allow string
108992         literals.
108993         * tests/test-memchr.c (main): Avoid type mismatch.
108994         * tests/test-arpa_inet.c (main): Avoid unused parameters.
108995         * tests/test-base64.c (main): Likewise.
108996         * tests/test-getdelim.c (main): Likewise.
108997         * tests/test-gethostname.c (main): Likewise.
108998         * tests/test-getline.c (main): Likewise.
108999         * tests/test-netinet_in.c (main): Likewise.
109000         * tests/test-select.c (open_server_socket, main): Likewise.
109001         * tests/test-select-stdin.c (main): Likewise.
109002         * tests/test-sockets.c (main): Likewise.
109003         * tests/test-strsignal.c (main): Likewise.
109004         * tests/test-sys_select.c (main): Likewise.
109005         * tests/test-sys_socket.c (main): Likewise.
109006         * tests/test-u64.c (main): Likewise.
109007         * tests/test-xfprintf-posix.c (main): Likewise.
109008         * tests/test-xvasprintf.c (test_xvasprintf, main): Likewise.
109010         sockets: avoid compiler warning
109011         * lib/sockets.c (gl_sockets_startup): Mark unused parameter.
109013         maint: detect usage(1) and other suspicious exits
109014         * top/maint.mk (sc_prohibit_magic_number_exit): New rule.
109016 2009-10-29  Jim Meyering  <meyering@redhat.com>
109018         timespec: long-to-int truncation could make timespec_cmp malfunction
109019         * lib/timespec.h (timespec_cmp): Do not interpret a difference of
109020         a multiple of 2^32 nanoseconds as no difference.
109022 2009-10-28  Jim Meyering  <meyering@redhat.com>
109024         fprintftime: wrap macro code argument in "do {...} while(0)"
109025         * lib/strftime.c (cpy) [FPRINTFTIME]: The second argument to the
109026         cpy macro must be a statement that can be followed by a semicolon.
109027         Now that the else clause contains a comment and is hence longer
109028         than one line, I require curly braces.  That in turn requires
109029         that we wrap this code block in the standard do...while(0).
109031         fprintftime: remove stray semicolon from previous change
109032         * lib/strftime.c (cpy) [FPRINTFTIME]: Remove trailing semicolon.
109034         fprintftime: avoid a warning about ignored fwrite return value
109035         * lib/strftime.c [FPRINTFTIME]: Include "ignore-value.h".
109036         (cpy) [FPRINTFTIME]: Ignore fwrite failure, even though technically,
109037         that is unsafe.
109038         * modules/fprintftime (Depends-on): Add ignore-value.
109040         exclude: avoid an unwarranted warning
109041         * lib/exclude.c (excluded_file_name): Initialize "rc" before switch.
109043 2009-10-27  Eric Blake  <ebb9@byu.net>
109045         fseek: avoid compilation failure when fflush is replaced
109046         * m4/fseek.m4 (gl_REPLACE_FSEEK): New macro.
109047         * m4/fseeko.m4 (gl_REPLACE_FSEEKO): Also replace fseek, if fseek
109048         module is in use.
109049         * lib/stdio.in.h (GNULIB_FSEEKO): Only poison fseek if fseek
109050         module is not in use; since REPLACE_FSEEK worked otherwise.
109051         (GNULIB_FTELLO): Likewise for ftell.
109052         Reported by Ian Beckwith and others.
109054 2009-10-27  Bruno Haible  <bruno@clisp.org>
109056         * lib/isnan.c (rpl_isnan[fdl]): Repeat the specification declaration.
109057         Reported by Jim Meyering.
109059 2009-10-27  Jim Meyering  <jim@meyering.net>
109060             Bruno Haible  <bruno@clisp.org>
109062         Avoid warning despite dropping the return value of fwrite.
109063         * lib/unicodeio.c: Include ignore-value.h.
109064         (fwrite_success_callback): Explicitly ignore fwrite's return value.
109065         * modules/unicodeio (Depends-on): Add ignore-value.
109067 2009-10-26  Eric Blake  <ebb9@byu.net>
109069         areadlinkat: fix fallback path
109070         * lib/at-func.c (AT_FUNC_NAME): Avoid signed comparison between
109071         pointer and zero.
109073 2009-10-22  Pádraig Brady  <P@draigBrady.com>
109075         Use a better IO block size for modern systems
109076         * lib/copy-file.c (copy_file_preserving): Used a 32KiB malloced buffer.
109077         * lib/md2.c: Likewise.
109078         * lib/md4.c: Likewise.
109079         * lib/md5.c: Likewise.
109080         * lib/sha1.c: Likewise.
109081         * lib/sha256.c: Likewise.
109082         * lib/sha512.c: Likewise.
109084 2009-10-22  Eric Blake  <ebb9@byu.net>
109086         tests: avoid several compiler warnings
109087         * tests/test-getcwd.c (main): Avoid buffer underflow.
109088         * tests/test-getdate.c (main): String literals are not safe with
109089         putenv, so use setenv.  Declare unused argument.
109090         * modules/getdate-tests (Depends-on): Add setenv.
109091         * tests/test-argv-iter.c (main): Declare unused argument.  Avoid
109092         problems with string literals in char *.
109093         * tests/test-hash.c (main): Avoid shadowing declaration.
109094         (insert_new): Treat string literals as char const *.
109095         * tests/test-getopt.h (test_getopt): Likewise.
109096         (getopt_loop): Alter types to minimize casting elsewhere.
109097         * tests/test-getopt_long.h (test_getopt_long, getopt_long_loop)
109098         (test_getopt_long_posix): Likewise.
109099         (do_getopt_long): Add wrapper to minimize casting.
109100         * tests/test-atexit.c (clear_temp_file): Use void.
109101         * tests/test-areadlink-with-size.c (main): Declare unused
109102         arguments.
109103         * tests/test-areadlink.c (main): Likewise.
109104         * tests/test-areadlinkat-with-size.c (main): Likewise.
109105         * tests/test-areadlinkat.c (main): Likewise.
109106         * tests/test-canonicalize-lgpl.c (main): Likewise.
109107         * tests/test-canonicalize.c (main): Likewise.
109108         * tests/test-dirent-safer.c (main): Likewise.
109109         * tests/test-dirname.c (main): Likewise.
109110         * tests/test-dup2.c (main): Likewise.
109111         * tests/test-fchdir.c (main): Likewise.
109112         * tests/test-fcntl-h.c (main): Likewise.
109113         * tests/test-fcntl-safer.c (main): Likewise.
109114         * tests/test-fdopendir.c (main): Likewise.
109115         * tests/test-fdutimensat.c (main): Likewise.
109116         * tests/test-fflush.c (main): Likewise.
109117         * tests/test-filenamecat.c (main): Likewise.
109118         * tests/test-filevercmp.c (main): Likewise.
109119         * tests/test-fopen-safer.c (main): Likewise.
109120         * tests/test-fopen.c (main): Likewise.
109121         * tests/test-fpending.c (main): Likewise.
109122         * tests/test-fpurge.c (main): Likewise.
109123         * tests/test-freading.c (main): Likewise.
109124         * tests/test-fstatat.c (main): Likewise.
109125         * tests/test-fsync.c (main): Likewise.
109126         * tests/test-futimens.c (main): Likewise.
109127         * tests/test-getndelim2.c (main): Likewise.
109128         * tests/test-gettimeofday.c (main): Likewise.
109129         * tests/test-getopt.c (main): Likewise.
109130         * tests/test-i-ring.c (main): Likewise.
109131         * tests/test-inttypes.c (main): Likewise.
109132         * tests/test-link.c (main): Likewise.
109133         * tests/test-lstat.c (main): Likewise.
109134         * tests/test-math.c (main): Likewise.
109135         * tests/test-md5.c (main): Likewise.
109136         * tests/test-memchr2.c (main): Likewise.
109137         * tests/test-memrchr.c (main): Likewise.
109138         * tests/test-mkdir.c (main): Likewise.
109139         * tests/test-mkdirat.c (main): Likewise.
109140         * tests/test-mkfifoat.c (main): Likewise.
109141         * tests/test-open.c (main): Likewise.
109142         * tests/test-openat-safer.c (main): Likewise.
109143         * tests/test-openat.c (main): Likewise.
109144         * tests/test-quotearg.c (main): Likewise.
109145         * tests/test-rawmemchr.c (main): Likewise.
109146         * tests/test-readlink.c (main): Likewise.
109147         * tests/test-remove.c (main): Likewise.
109148         * tests/test-rename.c (main): Likewise.
109149         * tests/test-renameat.c (main): Likewise.
109150         * tests/test-rmdir.c (main): Likewise.
109151         * tests/test-sha1.c (main): Likewise.
109152         * tests/test-signal.c (main): Likewise.
109153         * tests/test-sigaction.c (main): Likewise.
109154         * tests/test-stat.c (main): Likewise.
109155         * tests/test-stat-time.c (main): Likewise.
109156         * tests/test-stddef.c (main): Likewise.
109157         * tests/test-stdint.c (main): Likewise.
109158         * tests/test-stdio.c (main): Likewise.
109159         * tests/test-stdlib.c (main): Likewise.
109160         * tests/test-strchrnul.c (main): Likewise.
109161         * tests/test-strerror.c (main): Likewise.
109162         * tests/test-string.c (main): Likewise.
109163         * tests/test-strtod.c (main): Likewise.
109164         * tests/test-strverscmp.c (main): Likewise.
109165         * tests/test-symlink.c (main): Likewise.
109166         * tests/test-symlinkat.c (main): Likewise.
109167         * tests/test-sys_stat.c (main): Likewise.
109168         * tests/test-sys_time.c (main): Likewise.
109169         * tests/test-time.c (main): Likewise.
109170         * tests/test-unistd.c (main): Likewise.
109171         * tests/test-unlink.c (main): Likewise.
109172         * tests/test-unlinkat.c (main): Likewise.
109173         * tests/test-utimens.c (main): Likewise.
109174         * tests/test-utimensat.c (main): Likewise.
109175         * tests/test-version-etc.c (main): Likewise.
109176         * tests/test-wchar.c (main): Likewise.
109177         * tests/test-wctype.c (main): Likewise.
109178         * tests/test-xprintf-posix.c (main): Likewise.
109179         * tests/test-posixtm.c (main): Likewise.
109180         (STREQ): Delete unused macro.
109181         * tests/test-linkat.c (main): Declare unused arguments.  Avoid
109182         shadowed variables.
109183         * tests/test-memchr.c (main): Likewise.
109185 2009-10-21  Eric Blake  <ebb9@byu.net>
109187         areadlinkat: avoid failure on older glibc
109188         * lib/at-func.c (AT_FUNC_NAME): Check for explicit FUNC_FAIL,
109189         rather than mis-comparing 0 against FUNC_RESULT of char*.
109191 2009-10-21  Bruno Haible  <bruno@clisp.org>
109193         * modules/stpncpy (License): Relicense under LGPLv2+.
109194         Reported by David Lutterkort <lutter@redhat.com>.
109196 2009-10-20  Eric Blake  <ebb9@byu.net>
109198         utimensat: work around Solaris 9 bug
109199         * lib/utimens.c (fdutimens, lutimens): Force a stat if platform
109200         has trailing slash bugs.
109201         * tests/test-lutimens.h (test_lutimens): Enhance test.
109202         * tests/test-utimens.h (test_utimens): Likewise.
109203         * doc/posix-functions/utime.texi (utime): Enhance documentation.
109204         * doc/posix-functions/utimes.texi (utimes): Likewise.
109205         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
109206         * doc/glibc-functions/futimesat.texi (futimesat): Likewise.
109207         * doc/glibc-functions/lutimes.texi (lutimes): Likewise.
109208         * doc/posix-functions/futimens.texi (futimens): Likewise.
109210         fdutimensat: new module
109211         * modules/fdutimensat: New file.
109212         * lib/fdutimensat.c (fdutimensat): Likewise.
109213         * lib/utimens.h (fdutimensat, lutimensat): Declare new functions.
109214         * MODULES.html.sh (File system functions): Mention module.
109215         * modules/fdutimensat-tests: New test.
109216         * tests/test-fdutimensat.c: Likewise.
109218         doc: regenerate INSTALL
109219         * doc/INSTALL: Reflect recent autoconf update.
109220         * doc/INSTALL.ISO: Likewise.
109221         * doc/INSTALL.UTF-8: Likewise.
109223 2009-10-20  Pádraig Brady  <P@draigBrady.com>
109225         acl: warn if ACL support is not detected
109226         * m4/acl.m4 (gl_FUNC_ACL): Output a warning if ACL support is not found.
109228 2009-10-19  Giuseppe Scrivano  <gscrivano@gnu.org>
109230         * lib/nproc.h: Add extern "C" block for C++.
109232 2009-10-18  Reuben Thomas  <rrt@sc3d.org>
109233             Bruno Haible  <bruno@clisp.org>
109235         * doc/posix-functions/isascii.texi: Document the 2 alternative APIs.
109236         * doc/posix-functions/isalnum.texi: Document the 4 alternative APIs.
109237         * doc/posix-functions/isalpha.texi: Likewise.
109238         * doc/posix-functions/isblank.texi: Likewise.
109239         * doc/posix-functions/iscntrl.texi: Likewise.
109240         * doc/posix-functions/isdigit.texi: Likewise.
109241         * doc/posix-functions/isgraph.texi: Likewise.
109242         * doc/posix-functions/islower.texi: Likewise.
109243         * doc/posix-functions/isprint.texi: Likewise.
109244         * doc/posix-functions/ispunct.texi: Likewise.
109245         * doc/posix-functions/isspace.texi: Likewise.
109246         * doc/posix-functions/isupper.texi: Likewise.
109247         * doc/posix-functions/isxdigit.texi: Likewise.
109249 2009-10-18  Bruno Haible  <bruno@clisp.org>
109251         Tests for module 'isblank'.
109252         * modules/isblank-tests: New file.
109253         * tests/test-isblank.c: New file.
109255         New module 'isblank'.
109256         * lib/isblank.c: New file.
109257         * m4/isblank.m4: New file.
109258         * modules/isblank: New file.
109259         * doc/posix-functions/isblank.texi: Mention the new module.
109261 2009-10-18  Bruno Haible  <bruno@clisp.org>
109263         New module 'ctype'.
109264         * lib/ctype.in.h: New file.
109265         * m4/ctype.m4: New file.
109266         * modules/ctype: New file.
109267         * doc/posix-headers/ctype.texi: Mention the new module.
109269 2009-10-18  Jim Meyering  <meyering@redhat.com>
109271         m4: stylistic-only: hoist AC_SUBST to be adjacent to initialization
109272         Declare a variable like LIB_CLOCK_GETTIME to be AC_SUBSTituted
109273         right after its initialization, rather than farther down.
109274         Keeping these in close proximity makes it easier to ensure
109275         that each such variable is initialized.  E.g.,
109277             LIB_CLOCK_GETTIME=
109278             AC_SUBST([LIB_CLOCK_GETTIME])
109280         This change also increments these serial numbers.
109281         * m4/clock_time.m4 (gl_CLOCK_TIME): Hoist AC_SUBST use.
109282         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
109283         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
109285 2009-10-18  Bruno Haible  <bruno@clisp.org>
109287         Don't let environment variables perturb build.
109288         * m4/gethrxtime.m4 (gl_GETHRXTIME): Initialize LIB_GETHRXTIME here...
109289         (gl_PREREQ_GETHRXTIME): ... not here.
109291 2009-10-18  Bruno Haible  <bruno@clisp.org>
109293         Avoid symlink attack in localcharset module.
109294         * lib/localcharset.c: Include <fcntl.h>, <unistd.h>.
109295         (O_NOFOLLOW): Define fallback.
109296         (get_charset_aliases): Don't open the file if it is a symbolic link.
109297         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): New macro, extracted from
109298         gl_FCNTL_H.
109299         (gl_FCNTL_H): Require it.
109300         * m4/localcharset.m4 (gl_LOCALCHARSET): Likewise.
109301         * modules/localcharset (Files): Add m4/fcntl_h.m4.
109302         Reported by Fergal Glynn <fglynn@veracode.com>.
109304 2009-10-18  Bruno Haible  <bruno@clisp.org>
109306         Implement nproc for mingw.
109307         * lib/nproc.c: Include <windows.h>
109308         (num_processors): On native Windows platforms, try GetSystemInfo.
109310 2009-10-18  Bruno Haible  <bruno@clisp.org>
109312         Implement nproc for IRIX.
109313         * lib/nproc.c: Include <sys/sysmp.h>.
109314         (num_processors): On IRIX systems, try sysmp.
109315         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/sysmp.h and sysmp.
109317 2009-10-18  Bruno Haible  <bruno@clisp.org>
109319         Implement nproc for HP-UX.
109320         * lib/nproc.c: Include <sys/pstat.h>
109321         (num_processors): On HP-UX systems, try pstat_getdynamic.
109322         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/pstat.h and
109323         pstat_getdynamic.
109325 2009-10-18  Giuseppe Scrivano  <gscrivano@gnu.org>
109326             Bruno Haible  <bruno@clisp.org>
109328         Implement nproc for NetBSD, OpenBSD.
109329         * lib/nproc.c: Include <sys/types.h>, <sys/param.h>, <sys/sysctl.h>.
109330         (ARRAY_SIZE): New macro.
109331         (num_processors): On BSD systems, try sysctl of HW_NCPU.
109332         * m4/nproc.m4: New file.
109333         * modules/nproc (Files): Add m4/nproc.m4.
109334         (configure.ac): Invoke gl_NPROC. Remove AC_LIBOBJ invocation.
109335         (Makefile.am): Instead, augment lib_SOURCES.
109337 2009-10-18  Bruno Haible  <bruno@clisp.org>
109339         Fix recognition of sys/sysctl.h on OpenBSD 4.0.
109340         * m4/physmem.m4 (gl_PHYSMEM): Before including sys/sysctl.h, include
109341         sys/param.h.
109343 2009-10-16  Eric Blake  <ebb9@byu.net>
109345         utimensat: new module
109346         * modules/utimensat: New file.
109347         * lib/utimensat.c (utimensat): Likewise.
109348         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
109349         * lib/utimens.c (utimensat): Avoid recursion into rpl_utimensat,
109350         so we can work around Linux bugs.
109351         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
109352         * modules/sys_stat (Makefile.am): Substitute them.
109353         * lib/sys_stat.in.h (utimensat): Declare it.
109354         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
109355         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
109356         * modules/utimensat-tests: New test.
109357         * tests/test-utimensat.c: Likewise.
109359         utimens: let lutimens work on non-symlinks
109360         * lib/utimens.c (lutimens): Fall back to utimens rather than
109361         failing with ENOSYS, when file is not a symlink.
109362         (utimens): Reduce redirection.
109363         * tests/test-lutimens.h (test_lutimens): Update test to cover
109364         non-symlinks.
109365         * tests/test-utimens.h (test_utimens): Update test to cover
109366         symlinks.
109367         * tests/test-utimens.c (main): Update caller.
109369         utimens: cache whether utimensat syscall works
109370         * lib/utimens.c (utimensat_works_really): New cache variable.
109371         (fdutimens, lutimens): Use it to avoid failing syscall.
109373         test-stat-time, test-utimens: improve portability
109374         * tests/test-stat-time.c (nap): Lengthen delay to 20ms, for
109375         ext4 on alpha, and for cygwin.
109376         * tests/test-utimens-common.h: New file.
109377         (nap): Factor delays into single function.
109378         * tests/test-lutimens.h (test_lutimens): Use new header.
109379         * tests/test-futimens.h (test_futimens): Likewise.
109380         * tests/test-utimens.h (test_utimens): Likewise.  Also, force NFS
109381         timestamps to occur from same machine, as was done previously for
109382         test_utimens.
109383         * modules/utimens-tests (Files): Ship new file.
109384         * modules/futimens-tests (Files): Likewise.
109385         Reported in part by Jim Meyering.
109387         sys_stat: sort replacement declarations
109388         * lib/sys_stat.in.h: Sort declarations.
109389         * lib/futimens.c (futimens): Fix typo.
109391 2009-10-15  Jim Meyering  <meyering@redhat.com>
109393         don't let environment settings perturb build
109394         Setting the envvars, LIB_CLOCK_GETTIME, LIB_EACCESS or LIB_NANOSLEEP
109395         could cause a configure-time and/or build-time malfunction.
109396         Typically, a configure-time function-in-library test is performed
109397         via code like this:
109399           LIB_VAR=
109400           AC_SUBST([LIB_VAR])
109401           prefix_saved_LIBS=$LIBS
109402             AC_SEARCH_LIBS([FUNC], [LIB_NAME],
109403                        [test "$ac_cv_search_FUNC" = "none required" ||
109404                         LIB_VAR=$ac_cv_search_FUNC])
109405           LIBS=$prefix_saved_LIBS
109407         However, in each of the files affected by this change, the LIB_VAR=
109408         initialization was omitted.  Thus, when set in the environment, its
109409         value would propagate into generated Makefiles when FUNC is not found
109410         in LIB_NAME.
109411         * m4/clock_time.m4 (gl_CLOCK_TIME): Initialize AC_SUBST'd var.
109412         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
109413         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
109415 2009-10-14  Eric Blake  <ebb9@byu.net>
109417         fchdir: avoid infinite recursion in mingw
109418         * lib/fchdir.c (rpl_fstat): Call system fstat, rather than
109419         recursing.
109421         test-stat-time: port to mingw
109422         * tests/test-stat-time.c (force_unlink): Return a value.
109423         (test_ctime) [W32]: Fix compilation error.
109424         (nap): Don't call usleep with too large an argument.  Use
109425         force_unlink.
109426         * doc/pastposix-functions/usleep.texi (usleep): Document the
109427         portability issue.
109429 2009-10-13  Jim Meyering  <meyering@redhat.com>
109431         use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS in modules/*
109432         * modules/pipe-filter-gi: Use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS.
109433         * modules/pipe-filter-ii: Likewise.
109434         * modules/sys_socket-tests: Likewise.
109435         * modules/tsearch-tests: Likewise.
109436         * Makefile (sc_prefer_ac_check_funcs_once): New rule.
109437         (check): Depend on it.
109439 2009-10-12  Eric Blake  <ebb9@byu.net>
109441         utimens-tests: port to NFS file systems
109442         * tests/test-utimens.h (test_utimens): Refactor utimecmp
109443         comparisons to avoid spurious failures from timestamp drift
109444         between NFS machines.
109446 2009-10-12  Eric Blake  <ebb9@byu.net>
109448         stat-time-tests: minor cleanups
109449         * modules/stat-time-tests (configure.ac): Use AC_CHECK_FUNCS_ONCE.
109450         * tests/test-stat-time.c (nap): Separate assignment from call.
109451         Suggested by Paolo Bonzini and Bruno Haible.
109453         sys_stat: guarantee struct timespec
109454         * lib/sys_stat.in.h (includes): Always include <time.h>
109455         * modules/sys_stat (Depends-on): Add time.
109456         * tests/test-sys_stat.c: Guarantee struct timespec, as well as
109457         mode_t permission values.
109458         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document how to
109459         get at subsecond timestamps.
109461 2009-10-10  Eric Blake  <ebb9@byu.net>
109463         futimens: new module
109464         * modules/futimens: New file.
109465         * lib/futimens.c (futimens): Likewise.
109466         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Likewise.
109467         * lib/utimens.c (futimens): Avoid recursion into rpl_futimens, so
109468         we can work around Linux bugs.
109469         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
109470         * modules/sys_stat (Makefile.am): Substitute them.
109471         * lib/sys_stat.in.h (futimens): Declare it.
109472         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
109473         * doc/posix-functions/futimens.texi (futimens): Likewise.
109474         * modules/futimens-tests: New test.
109475         * tests/test-futimens.c: Likewise.
109477         utimens: introduce fdutimens
109478         * lib/utimens.h (fdutimens): New prototype.
109479         * lib/utimens.c (gl_futimens): Move guts...
109480         (fdutimens): ...to new interface.
109481         * tests/test-utimens.c (do_fdutimens): Use it.
109483         utimens: add UTIME_NOW and UTIME_OMIT support
109484         * lib/utimens.c (validate_timespec, update_timespec): New helper
109485         functions.
109486         (gl_futimens, lutimens): Use them.
109487         * modules/utimens (Depends-on): Add gettime, lstat, stat-time,
109488         stdbool, sys_stat.
109489         (Link): Mention resulting library dependency.
109490         * modules/utimecmp (Link): Likewise.
109491         * modules/utimens-tests (Depends-on): Drop stat-time, stdbool.
109492         (Makefile.am): Pick up library dependency.
109493         * lib/sys_stat.in.h (UTIME_NOW, UTIME_OMIT): Guarantee a
109494         definition.
109495         * tests/test-sys_stat.c: Test the definitions.
109496         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document this.
109497         * NEWS: Document library dependency.
109499         utimecmp: support symlink timestamps
109500         * lib/utimecmp.c (utimecmp): Use new interface.  Skip effort of
109501         hashing when possible.  Use pathconf when available.
109502         (SYSCALL_RESOLUTION): Recognize tighter resolution.
109503         * modules/utimecmp (Depends-on): Add lstat.
109505         utimens: add lutimens interface
109506         * lib/utimens.c (lutimens): New function.
109507         * m4/utimens.m4 (gl_UTIMENS): Check for lutimes.
109508         * lib/utimens.h (lutimens): Declare new interface.
109509         * tests/test-utimens.c (main): Enhance test.
109510         * tests/test-lutimens.h (test_lutimens): New file.
109511         * modules/utimens-tests (Files): Distribute it.
109512         (Depends-on): Add symlink.
109513         (configure.ac): Check for usleep.
109515         utimens: validate futimens usage
109516         * lib/utimens.c (gl_futimens): Require valid fd up front, using
109517         fewer syscalls on failure later on.  Avoid compiler warning on
109518         mingw.
109519         * modules/utimens (Depends-on): Add dup2.
109521         utimens: add test
109522         * modules/utimens-tests: New test.
109523         * tests/test-utimens.h: New file.
109524         * tests/test-futimens.h: Likewise.
109525         * tests/test-utimens.c: Likewise.
109527         doc: mention timestamp portability issues
109528         * doc/glibc-functions/lutimes.texi (lutimes): Refer to utimensat
109529         instead.
109530         * doc/posix-functions/utime.texi (utime): Likewise.
109531         * doc/posix-functions/utimes.texi (utimes): Likewise.
109532         * doc/glibc-functions/futimes.texi (futimes): Refer to futimens
109533         instead.
109534         * doc/posix-functions/futimens.texi (futimens): Mention utimens
109535         module.
109536         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
109537         Mention weakness with symlink timestamps.
109538         * doc/glibc-functions/futimesat.texi (futimesat): New file; refer
109539         to utimensat/futimens instead.
109540         * doc/gnulib.texi (Glibc sys/time.h): Include new file.
109542         test-dup2: enhance test
109543         * tests/test-dup2.c (main): Also check AT_FDCWD.
109545         test-stat-time: avoid more spurious failures
109546         * tests/test-stat-time.c (nap): Wait for 15ms rather than 2ms, for
109547         xfs; and avoid race if the two timestamps cross quantization edge.
109549         relocatable: prefer 'file system' over 'filesystem'
109550         * m4/relocatable-lib.m4 (gl_RELOCATABLE_NOP): Use AS_HELP_STRING.
109551         (gl_RELOCATABLE_LIBRARY_BODY): Fix spelling.
109552         * doc/relocatable-maint.texi (Supporting Relocation): Likewise.
109553         * doc/relocatable.texi (Enabling Relocatability): Likewise.
109554         * lib/relocatable.c (compute_curr_prefix): Likewise.
109556 2009-10-10  Jim Meyering  <meyering@redhat.com>
109558         stat-time-tests: check for the usleep function
109559         * modules/stat-time-tests (configure.ac): Now that we test HAVE_USLEEP.
109561 2009-10-10  Bruno Haible  <bruno@clisp.org>
109563         * modules/xnanosleep: Put the Link section after the Include section.
109565 2009-10-09  Eric Blake  <ebb9@byu.net>
109567         dup2: work around FreeBSD 6.1 bug
109568         * m4/dup2.m4 (gl_FUNC_DUP2): Detect bug.
109569         * doc/posix-functions/dup2.texi (dup2): Document it.
109570         Reported by Nelson H. F. Beebe and Jim Meyering.
109572         test-stat-time: port to buggy NFS clients
109573         * tests/test-stat-time.c (main) [W32]: Reduce ifdefs.
109574         (test_ctime): Also skip test if mtime and ctime are skewed.
109576         maint: prefer 'file system' over 'filesystem'
109577         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
109578         * doc/posix-functions/lstat.texi (lstat): Likewise.
109579         * lib/file-has-acl.c (file_has_acl): Likewise.
109580         * lib/fwriteerror.c [TEST]: Likewise.
109581         * tests/test-areadlink.h (test_areadlink): Likewise.
109582         * tests/test-areadlinkat-with-size.c (main): Likewise.
109583         * tests/test-areadlinkat.c (main): Likewise.
109584         * tests/test-canonicalize-lgpl.c (main): Likewise.
109585         * tests/test-canonicalize.c (main): Likewise.
109586         * tests/test-fstatat.c (main): Likewise.
109587         * tests/test-linkat.c (main): Likewise.
109588         * tests/test-lstat.h (test_lstat_func): Likewise.
109589         * tests/test-mkdir.h (test_mkdir): Likewise.
109590         * tests/test-readlink.h (test_readlink): Likewise.
109591         * tests/test-remove.c (main): Likewise.
109592         * tests/test-rename.h (test_rename): Likewise.
109593         * tests/test-renameat.c (main): Likewise.
109594         * tests/test-rmdir.h (test_rmdir_func): Likewise.
109595         * tests/test-symlink.h (test_symlink): Likewise.
109596         * tests/test-symlinkat.c (main): Likewise.
109597         * tests/test-unlink.h (test_unlink_func): Likewise.
109598         * tests/test-unlinkat.c (main): Likewise.
109600         maint: make realtime library usage explicit
109601         * modules/gethrxtime (Link): Mention LIB_GETHRXTIME.
109602         * modules/gettime (Link): Mention LIB_CLOCK_GETTIME.
109603         * modules/settime (Link): Likewise.
109604         * modules/xnanosleep (Link): Mention LIB_NANOSLEEP.
109606         test-stat-time: speed up execution
109607         * tests/test-stat-time.c (test_ctime) [!W32]: Avoid compiler
109608         warning on mingw.
109609         (nap): New helper function.
109610         (prepare_test): Use it to reduce sleep time.
109611         (test_mtime, test_ctime, test_birthtime): Allow for subsecond
109612         execution.
109613         * modules/stat-time-tests (configure.ac): Check for usleep.
109615 2009-10-09  Jim Meyering  <meyering@redhat.com>
109617         selinux-h: always use getfilecon wrappers
109618         * lib/getfilecon.c: New file.
109619         * lib/se-selinux.in.h: Use a better inclusion guard symbol name.
109620         [HAVE_SELINUX_SELINUX_H]: Include-next <selinux/selinux.h>.
109621         [!HAVE_SELINUX_SELINUX_H]: Use better parameter names.
109622         (fgetfilecon): Provide a stub.
109623         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Don't
109624         AC_SUBST SELINUX_SELINUX_H, since now we're generating that
109625         file unconditionally.
109626         When <selinux/selinux.h> is found, arrange to use wrappers.
109627         * modules/selinux-h (Files): Add getfilecon.c.
109628         (Makefile.am): Substitute include-next-related bits
109629         into the now-always-generated selinux/selinux.h file.
109630         * doc/glibc-functions/lgetfilecon.texi: New file.
109631         * doc/glibc-functions/fgetfilecon.texi: New file.
109632         * doc/glibc-functions/getfilecon.texi: New file.
109633         * doc/glibc-functions/getfilecon-desc.texi: New file.
109634         * doc/gnulib.texi (Glibc selinux/selinux.h): New section, by
109635         which to pull in the new files.
109636         * MODULES.html.sh (Misc): Add selinux-h.
109638 2009-10-08  Jim Meyering  <meyering@redhat.com>
109640         unistd: fix comment typo
109641         * lib/unistd.in.h (euidaccess): Fix a comment typo.
109643 2009-10-08  Eric Blake  <ebb9@byu.net>
109645         areadlink: use SIZE_MAX consistently
109646         * modules/areadlink (Depends-on): Add stdint.
109647         * modules/areadlink-with-size (Depends-on): Likewise.
109648         * lib/areadlink-with-size.c (includes): Drop stdio, since stdlib
109649         gives NULL; drop sys/types, since unistd gives size_t; and add
109650         stdint for SIZE_MAX.
109651         (SIZE_MAX): Rely on headers.
109652         * lib/areadlinkat-with-size.c (includes): Drop stdio, sys/types,
109653         and add stdint.
109654         * lib/areadlink.c (includes): Drop sys/types, and add stdint.
109655         (SIZE_MAX): Likewise.
109656         (INITIAL_BUF_SIZE): Turn into enum.
109657         * lib/areadlinkat.c (INITIAL_BUF_SIZE): Likewise.
109659 2009-10-08  Jim Meyering  <meyering@redhat.com>
109661         areadlinkat: avoid compilation failure
109662         * lib/areadlinkat.c: Include <stdint.h> for use of SIZE_MAX.
109663         Fix typo in comment.
109665 2009-10-07  Eric Blake  <ebb9@byu.net>
109667         areadlinkat-with-size: new module
109668         * modules/areadlinkat-with-size: New module.
109669         * lib/areadlinkat-with-size.c (areadlinkat_with_size): New file.
109670         * lib/areadlink.h (areadlinkat): Declare it.
109671         * MODULES.html.sh (File system functions): Mention it.
109672         * modules/areadlinkat-with-size-tests: New test.
109673         * tests/test-areadlinkat-with-size.c: New file.
109675         xreadlinkat: new module
109676         * modules/xreadlinkat: New module.
109677         * lib/xreadlinkat.c (xreadlinkat): New file.
109678         * lib/xreadlink.h (xreadlinkat): Declare it.
109679         * MODULES.html.sh (File system functions): Mention it.
109681         areadlinkat: new module
109682         * lib/at-func.c (FUNC_FAIL): New define.
109683         (AT_FUNC_NAME, VALIDATE_FLAG): Use it rather than raw -1.
109684         * modules/areadlinkat: New module.
109685         * lib/linkat.c (areadlinkat): Move...
109686         * lib/areadlinkat.c (areadlinkat): ...to new file.
109687         * lib/areadlink.h (areadlinkat): Declare it.
109688         * modules/linkat (Depends-on): Add areadlinkat.
109689         * MODULES.html.sh (File system functions): Mention it.
109690         * modules/areadlinkat-tests: New test.
109691         * tests/test-areadlinkat.c: New file.
109693         areadlink, areadlink-with-size: add tests
109694         * modules/areadlink-tests: New test.
109695         * modules/areadlink-with-size-tests: Likewise.
109696         * tests/test-areadlink.h: New file.
109697         * tests/test-areadlink.c: Likewise.
109698         * tests/test-areadlink-with-size.c: Likewise.
109700         maint: minor cleanups
109701         * lib/fts.c (ATTRIBUTE_UNUSED): Delete; use gnulib-guaranteed
109702         _UNUSED_PARAMETER_ instead.
109703         * lib/getdate.y (ATTRIBUTE_UNUSED): Likewise.
109704         * lib/utimens.c (ATTRIBUTE_UNUSED): Likewise.
109705         * modules/linkat-tests (Files): Distribute test-link.h.
109707         openat, utimens: whitespace cleanup
109708         * lib/openat.c: Prefer space throughout, rather than mix of 8
109709         spaces vs. tabs.
109710         * lib/at-func.c: Likewise.
109711         * lib/utimens.c: Likewise.
109713         openat: avoid using wrong fd
109714         * lib/openat.c (openat_permissive): Reject user's fd if saving the
109715         working directory chooses same fd.
109716         * lib/at-func.c (AT_FUNC_NAME): Likewise.
109718         mkdir, mkdirat: fix cygwin 1.5.x bug
109719         * lib/mkdir.c (rpl_mkdir) [FUNC_MKDIR_DOT_BUG]: Work around bug.
109720         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Move...
109721         * m4/mkdir.m4 (gl_FUNC_MKDIR): ...here, and add check for cygwin
109722         bug.
109723         (gl_PREREQ_MKDIR): Delete unused macro.
109724         * modules/mkdir (Files): Track file rename.
109725         (configure.ac): Update macro name.
109726         * modules/openat (Depends-on): Add mkdir.
109727         * doc/posix-functions/mkdir.texi (mkdir): Document the bug.
109729         mkdir, mkdirat: add tests
109730         * modules/mkdir-tests: New test.
109731         * tests/test-mkdir.h: New file.
109732         * tests/test-mkdir.c: Likewise.
109733         * tests/test-mkdirat.c: Likewise.
109734         * modules/openat-tests (Files): Add new files.
109735         (Makefile.am): Run new test.
109737 2009-10-06  Eric Blake  <ebb9@byu.net>
109739         doc: tweak *at function documentation
109740         * doc/posix-functions/faccessat.texi (faccessat): Mention
109741         known issue with replacement.
109742         * doc/posix-functions/fchdir.texi (fchdir): Likewise.
109743         * doc/posix-functions/linkat.texi (linkat): Likewise.
109744         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
109745         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
109746         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
109747         * doc/posix-functions/renameat.texi (renameat): Likewise.
109748         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
109750         openat: fix GNU/Hurd bug in unlinkat
109751         * m4/openat.m4 (gl_FUNC_OPENAT): Replace unlinkat if unlink is
109752         broken.
109753         * doc/posix-functions/unlink.texi (unlink): Document this.
109754         * doc/posix-functions/unlinkat.texi (unlinkat): Likewise.
109756         fdopendir: fix GNU/Hurd bug
109757         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for Hurd bug in
109758         allowing non-directory fds.
109759         * lib/fdopendir.c (rpl_fdopendir): Work around it.
109760         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
109761         * modules/dirent (Makefile.am): Substitute it.
109762         * lib/dirent.in.h (fdopendir): Declare replacement.
109763         * doc/posix-functions/fdopendir.texi (fdopendir): Document this.
109764         * tests/test-fdopendir.c (main): Test something other than
109765         /dev/null, since on Hurd that behaves like a directory.
109767         test-symlink: port to GNU/Hurd
109768         * tests/test-symlink.h (test_symlink): Relax expected errno.
109770         doc: tweak more cygwin information
109771         * doc/glibc-headers/getopt.texi (getopt.h): Cygwin 1.7 getopt is
109772         now compatible with glibc.
109773         * doc/posix-functions/getopt.texi (getopt): Likewise.
109775         getopt-gnu: add another test
109776         * tests/test-getopt_long.h (test_getopt_long_posix): New test, to
109777         guarantee behavior relied on by m4.
109778         * tests/test-getopt.c (main): Use it.
109779         * modules/getopt-posix-tests (Depends-on): Add setenv.
109780         See http://lists.gnu.org/r/bug-m4/2006-09/msg00028.html.
109782         getopt: fix compilation on darwin
109783         * lib/getopt.in.h (includes): Leave breadcrumbs during system
109784         include.
109785         * lib/unistd.in.h (getopt): Use them to avoid recursive include.
109786         Reported by Ludovic Courtès.
109788 2009-10-06  Bruno Haible  <bruno@clisp.org>
109790         * modules/size_max (Description): Discourage its use.
109791         Reported by Simon Josefsson.
109793 2009-10-06  Jim Meyering  <meyering@redhat.com>
109795         linkat: avoid compilation failure
109796         * lib/linkat.c: Include <stdint.h> for use of SIZE_MAX.
109798 2009-10-05  Eric Blake  <ebb9@byu.net>
109800         linkat: support Linux 2.6.17
109801         * m4/linkat.m4 (gl_FUNC_LINKAT): Default to always replacing
109802         linkat on Linux, but allow cache variable override.
109803         * lib/linkat.c (rpl_linkat): Define override.
109804         * modules/linkat (Depends-on): Add symlinkat.
109805         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add new default.
109806         * modules/unistd (Makefile.am): Substitute it.
109807         * lib/unistd.in.h (linkat): Declare replacement.
109808         Reported by Pádraig Brady.
109810         quotearg: port test to systems with C.UTF-8 locale
109811         * tests/test-quotearg.c (struct result_strings): Add another
109812         member, differentiating between C.ASCII and C.UTF-8 handling.
109813         (compare_strings): Add parameter.
109814         (main): Adjust all callers.
109816         getopt: avoid clash with FreeBSD _getopt_internal
109817         * lib/getopt.in.h (_getopt_internal): Override the name.
109818         * lib/getopt_int.h (includes): Pick up any overrides.
109819         Reported by Reuben Thomas.
109821         hash: allow C89 compilation
109822         * lib/hash.c (check_tuning): Move declaration before statement.
109823         Reported by Reuben Thomas.
109825 2009-10-05  Karl Berry  <karl@gnu.org>
109827         * doc/gnulib.texi: @include execvpe.texi, missing for several days.
109829 2009-10-04  Paolo Bonzini  <bonzini@gnu.org>
109830             Bruno Haible  <bruno@clisp.org>
109832         * lib/uname.c (uname): Use a table-driven algorithm to compute
109833         Windows NT versions.
109835 2009-10-04  Bruno Haible  <bruno@clisp.org>
109837         * lib/progname.c (set_program_name): Also remove the "lt-" prefix from
109838         program_invocation_short_name.
109839         * modules/progname (configure.ac): Test for presence of
109840         program_invocation_short_name.
109841         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
109843 2009-10-04  Bruno Haible  <bruno@clisp.org>
109845         * lib/progname.c (set_program_name): Fix comment.
109846         Reported by Jim Meyering.
109848 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
109849             Bruno Haible  <bruno@clisp.org>
109851         * lib/uname.c: Include <string.h>.
109852         (uname): Do only one call to GetVersionEx in the common case.
109854 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
109855             Bruno Haible  <bruno@clisp.org>
109857         * lib/uname.c (VER_PLATFORM_WIN32_CE, PROCESSOR_ARCHITECTURE_AMD64,
109858         PROCESSOR_ARCHITECTURE_IA32_ON_WIN64): Define fallbacks.
109859         (uname): Add support for Windows CE and various non-x86 CPU types.
109861 2009-10-03  Bruno Haible  <bruno@clisp.org>
109863         * gnulib-tool (func_create_testdir): Conditionally emit AM_PROG_CC_C_O
109864         invocation to tests/configure.ac.
109865         Reported by Ian Beckwith <ianb@erislabs.net>.
109867 2009-10-02  Eric Blake  <ebb9@byu.net>
109869         fchdir: avoid compiler warning
109870         * lib/fchdir.c (canonicalize_file_name)
109871         [!HAVE_CANONICALIZE_FILE_NAME]: Avoid compiler warning on mingw.
109873         test-open: support mingw errno values
109874         * tests/test-open.h (test_open): Relax test.
109875         * tests/test-fopen.h (test_fopen): Likewise.
109876         * tests/test-openat-safer.c (main): Likewise.
109878         open: fix opening directory on mingw
109879         * lib/open.c (open) [REPLACE_OPEN_DIRECTORY]: Correct typo.
109881         test-open: on GNU/Hurd, /dev/null is a directory
109882         * tests/test-fopen.h (main): Rename...
109883         (test_fopen): ...to this.  Use a guaranteed non-directory when
109884         confirming open behavior on trailing slash.
109885         * tests/test-openat-safer.c (main): Likewise.
109886         * tests/test-open.h (main): Likewise....
109887         (test_open): ...to this.
109888         * tests/test-fopen.c (main): Adjust caller.
109889         * tests/test-fopen-safer.c (main): Likewise.
109890         * tests/test-open.c (main): Likewise.
109891         * tests/test-fcntl-safer.c (main): Likewise.
109892         Reported by Samuel Thibault.
109894         rename, fchdir: don't ignore chdir failure
109895         * lib/fchdir.c (get_name): Abort on unexpected chdir failure.
109896         * lib/rename.c (rpl_rename) [W32]: Likewise.
109897         (rpl_rename) [RENAME_DEST_EXISTS_BUG]: Avoid one case of losing
109898         an empty destination directory if source cannot be renamed,
109899         although there is still possibility for failure.
109900         * doc/posix-functions/rename.texi (rename): Document the race.
109901         Reported by Jim Meyering.
109903         maint: cleanup whitespace in recent commits
109904         * lib/rename.c (rpl_rename): Remove tabs.
109905         * tests/test-link.h (test_link): Likewise.
109906         * lib/fchdir.c (get_name): Likewise.
109907         Reported by Jim Meyering.
109909 2009-10-02  Ben Pfaff  <blp@gnu.org>
109911         relocatable-prog-wrapper: Add missing dependency on
109912         double-slash-root.
109913         * modules/relocatable-prog-wrapper: Add dependency.
109914         Reported by Ian Beckwith <ianb@erislabs.net>.
109916 2009-10-02  Eric Blake  <ebb9@byu.net>
109918         renameat: fix Solaris bugs
109919         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Replace renameat if rename
109920         needed fixing.
109921         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): New witness.
109922         * modules/stdio (Makefile.am): Substitute it.
109923         * lib/stdio.in.h (renameat): Declare replacement.
109924         * lib/renameat.c (rpl_renameat): Implement fix.
109926         renameat: new module
109927         * modules/renameat: New file.
109928         * lib/renameat.c (renameat): Likewise.
109929         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Likewise.
109930         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
109931         * modules/stdio (Makefile.am): Substitute them.
109932         * lib/stdio.in.h (renameat): Declare it.
109933         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
109934         * doc/posix-functions/renameat.texi (renameat): Likewise.
109935         * modules/renameat-tests: New test.
109936         * tests/test-renameat.c: Likewise.
109938         rename: fix mingw bugs
109939         * lib/rename.c (rpl_rename) [W32]: Fix trailing slash and
109940         directory overwrite bugs.
109942         rename: fix another cygwin 1.5 bug
109943         * m4/rename.m4 (gl_FUNC_RENAME): Split cygwin bugs into two
109944         checks.
109945         * lib/rename.c (rpl_rename): Don't penalize NetBSD with
109946         unnecessary cygwin workarounds.  Also work around bug with moving
109947         full directory onto an empty one.
109948         * modules/rename (Depends-on): Add canonicalize-lgpl, rmdir.
109950         rename-dest-slash: merge into rename module
109951         * modules/rename-dest-slash (Status): Mark obsolete.
109952         (Depends-on): Add rename.
109953         (Files): Let rename do it all.
109954         * m4/rename.m4 (gl_FUNC_RENAME): Also test for NetBSD bugs,
109955         subsuming the test from gl_FUNC_RENAME_TRAILING_DEST_SLASH...
109956         * m4/rename-dest-slash.m4: ...so this file can be deleted.
109957         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Delete.
109958         * lib/rename.c (rpl_rename): Update comments.
109960         rename: fix cygwin 1.5.x bugs
109961         * m4/rename.m4 (gl_FUNC_RENAME): Detect cygwin bugs.
109962         * lib/rename.c (rpl_rename): Work around them.
109963         * modules/rename (Depends-on): Add same-inode.
109965         rename: fix Solaris 10 bug
109966         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
109967         * lib/rename.c (rpl_rename): Don't cripple POSIX behavior if this
109968         was the only bug.
109970         rename: fix Solaris 9 bug
109971         * lib/rename.c (rpl_rename): Rewrite to recognize trailing slash
109972         on non-directory.  Avoid calling exit.
109973         * modules/rename (Depends-on): Drop xalloc; add lstat, stdbool,
109974         strdup.
109975         * modules/rename-tests (Depends-on): Drop lstat.
109976         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
109977         (gl_PREREQ_RENAME): Delete unused macro.
109979         rename-dest-slash: fix NetBSD bug
109980         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Detect hard
109981         links.
109982         * modules/rename-dest-slash (Depends-on): Add same-inode.
109984         rename-tests: new test, exposes several platform bugs
109985         * modules/rename-tests: New file.
109986         * tests/test-rename.h: Likewise.
109987         * tests/test-rename.c: Likewise.
109988         * doc/posix-functions/rename.texi (rename): Improve documentation,
109989         including bugs that will eventually be fixed in gnulib.
109991 2009-10-02  Paolo Bonzini  <bonzini@gnu.org>
109993         * lib/uname.c: Include <stdlib.h>
109994         (uname): Assume version info is available.
109996 2009-10-02  Jim Meyering  <meyering@redhat.com>
109998         gnu-web-doc-update: correct --help output
109999         * build-aux/gnu-web-doc-update: Make --help output relevant.
110001         gnu-web-doc-update: add standard options
110002         * build-aux/gnu-web-doc-update: Add --help, --version, etc.
110004         gnu-web-doc-update: New module.
110005         Use this script to automatically update the on-line web documentation
110006         for your GNU project at http://www.gnu.org/software/$pkg/manual/
110007         * modules/gnu-web-doc-update: New file, from coreutils.
110008         * build-aux/gnu-web-doc-update: New script.
110010 2009-10-01  Paolo Bonzini  <bonzini@gnu.org>
110012         link: LoadLibrary is not needed.
110013         * lib/link.c: Use GetModuleHandle.
110015 2009-10-01  Eric Blake  <ebb9@byu.net>
110017         getopt: bump serial number
110018         * m4/getopt.m4: Increment serial number, to account for 2009-09-24
110019         change.
110021         tests: tighten link, rmdir, and remove tests
110022         * tests/test-link.h (includes): No need to use <config.h> here.
110023         Clean up if directory hard link was created, otherwise test for
110024         trailing '.'.
110025         * tests/test-linkat.c (main): Simplify.
110026         * tests/test-remove.c (main): Enhance test for trailing '.'.
110027         * tests/test-rmdir.h (test_rmdir_func): Likewise.
110029 2009-10-01  Jim Meyering  <meyering@redhat.com>
110031         maint.mk: requiring "make major" was annoying, for a "minor" release.
110032         What is intended is "stable", to contrast with alpha and beta,
110033         so require "make stable", not "make major".
110034         * build-aux/announce-gen (%valid_release_types): s/major/stable/.
110035         (get_tool_versions): Likewise.
110036         * top/maint.mk (ALL_RECURSIVE_TARGETS): s/major/stable/
110038 2009-09-30  Ben Pfaff  <blp@gnu.org>
110040         Fix broken build of replacement for Windows tmpfile().
110041         * lib/tmpfile.c (tmpfile): Fix call to gen_tempname() to provide
110042         flags argument added along with the 'mkostemp' module.
110044 2009-09-28  Bruno Haible  <bruno@clisp.org>
110046         Avoid identifier clash with POSIX function 'remove' defined as a macro.
110047         * lib/gl_list.h (struct gl_list_implementation): Rename field 'remove'
110048         to 'remove_elt'.
110049         (gl_list_remove): Update.
110050         * lib/gl_list.c (gl_list_remove): Update.
110051         * lib/gl_oset.h (struct gl_oset_implementation): Rename field 'remove'
110052         to 'remove_elt'.
110053         (gl_oset_remove): Update.
110054         * lib/gl_list.c (gl_oset_remove): Update.
110055         Reported by Eric Blake.
110057 2009-09-28  Eric Blake  <ebb9@byu.net>
110059         doc: mention yet more cygwin 1.7 status
110060         * doc/posix-functions/fexecve.texi (fexecve): Now implemented in
110061         cygwin.
110062         * doc/glibc-functions/execvpe.texi (execvpe): New file.
110063         * doc/gnulib.texi (Glibc unistd.h): Mention it.
110065         argp: fix test failure
110066         * lib/argp-help.c (hol_entry_cmp): Don't use _tolower on values
110067         that are not upper-case.  Pass correct range to tolower.
110069 2009-09-27  Jim Meyering  <meyering@redhat.com>
110071         test-yesno: work around sparc-dash here-document infelicity
110072         Without this change, the literal \177 byte in a here document
110073         would make dash 0.5.5.1-3 access uninitialized memory.
110074         * tests/test-yesno.sh: Don't put the \177 byte in the here document.
110075         Instead, use a marker, "@", and filter through tr to create the desired
110076         contents.  Reported as <http://bugs.debian.org/548493> by Kurt Roeckx.
110078 2009-09-27  Bruno Haible  <bruno@clisp.org>
110080         Disable untested support for new flavours of ACLs on AIX.
110081         * lib/file-has-acl.c (file_has_acl): Mark newer AIX code as work in
110082         progress.
110083         * lib/set-mode-acl.c (qset_acl): Likewise.
110085 2008-12-07  Bruno Haible  <bruno@clisp.org>
110087         Add support for new flavours of ACLs on AIX. (Untested.)
110088         * lib/file-has-acl.c [AIX] (acl_nfs4_nontrivial): New function.
110089         (file_has_acl): Add support for newer AIX.
110090         * lib/set-mode-acl.c (qset_acl): Likewise.
110091         * tests/test-sameacls.c (main): Fix use of aclx_get function. Hint by
110092         Rainer Tammer <tammer@tammer.net>.
110094 2009-09-26  Eric Blake  <ebb9@byu.net>
110096         argp: fix compilation of getopt
110097         * lib/getopt.in.h (includes): Use different guard than glibc.
110098         Reported by Sergey Poznyakoff.
110100         doc: mention more cygwin 1.7 status
110101         * doc/posix-functions/access.texi (access): Mention cygwin 1.5
110102         bug.
110103         * doc/posix-functions/execl.texi (execl): Likewise.
110104         * doc/posix-functions/execle.texi (execle): Likewise.
110105         * doc/posix-functions/execlp.texi (execlp): Likewise.
110106         * doc/posix-functions/execv.texi (execv): Likewise.
110107         * doc/posix-functions/execve.texi (execve): Likewise.
110108         * doc/posix-functions/execvp.texi (execvp): Likewise.
110109         * doc/glibc-functions/canonicalize_file_name.texi
110110         (canonicalize_file_name): Cygwin 1.7 now provides this.
110111         * doc/glibc-functions/euidaccess.texi (euidaccess): Likewise.
110112         * doc/posix-functions/fchmodat.texi (fchmodat): Mention limitation
110113         on AT_SYMLINK_NOFOLLOW.
110115 2009-09-24  Eric Blake  <ebb9@byu.net>
110117         test-linkat: make test more robust
110118         * tests/test-linkat.c (main): Avoid collision with EEXIST.
110120         getopt: fix inclusion guards for cygwin
110121         * modules/getopt-posix (Depends-on): Add include-next.
110122         (Makefile.am): Substitute more items in replacement header.
110123         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Also check for native
110124         <getopt.h>.
110125         * lib/getopt.in.h (includes): Use split inclusion guard, and
110126         prefer <getopt.h> over include <unistd.h> when one is present.
110127         (option): Also override name of 'struct option'.
110129         same-inode: revert prior change; it is not yet ready
110130         * NEWS: Undo mention of this change.
110131         * lib/same-inode.h (same-inode.h): Undo tri-state change.
110132         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
110133         * lib/cycle-check.c (cycle_check): Likewise.
110134         * lib/same.c (same_name): Likewise.
110135         * lib/at-func2.c (at_func2): Likewise.
110137 2009-09-23  Eric Blake  <ebb9@byu.net>
110139         linkat: new module
110140         * modules/linkat: New file.
110141         * lib/at-func2.c (at_func2): Likewise.
110142         * lib/linkat.c (linkat): Likewise.
110143         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
110144         * lib/openat-priv.h (at_func2): Add declaration.
110145         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
110146         * modules/unistd (Makefile.am): Substitute them.
110147         * lib/unistd.in.h (linkat): Declare it.
110148         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
110149         * doc/posix-functions/linkat.texi (linkat): Likewise.
110150         * doc/posix-functions/link.texi (link): Tweak wording.
110151         * tests/test-link.c (main): Move guts...
110152         * tests/test-link.h (test_link): ...into new file.
110153         * modules/linkat-tests: New test.
110154         * tests/test-linkat.c: Likewise.
110155         * modules/link-tests (Files): Ship new file.
110156         (Depends-on): Add stdbool.
110158         dirname: add library-safe mdir_name
110159         * lib/dirname.h (mdir_name): New prototype.
110160         * lib/dirname.c (dir_name): Move guts...
110161         (mdir_name): ...to new function that avoids xalloc_die.
110163         fchdir: another mingw fix
110164         * modules/fchdir (Depends-on): Drop canonicalize-lgpl.
110165         * lib/fchdir.c (get_name): New helper method; skips canonicalize
110166         on mingw (where it has not yet been ported), and make it optional
110167         elsewhere.
110168         (_gl_register_fd): Use it.
110170         same-inode: make SAME_INODE tri-state, to port to mingw
110171         * NEWS: Mention this change.
110172         * lib/same-inode.h (same-inode.h): Recognize mingw limitation of
110173         st_ino always being 0.
110174         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
110175         * lib/cycle-check.c (cycle_check): Likewise.
110176         * lib/same.c (same_name): Likewise.
110178         lstat: avoid mingw compilation error
110179         * m4/lstat.m4 (gl_FUNC_LSTAT): Avoid duplicate calls to
110180         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, and deal with missing
110181         lstat ourselves.
110182         * lib/lstat.c [!HAVE_LSTAT]: Do nothing if <sys/stat.h> override
110183         was adequate.
110184         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Let lstat module handle
110185         the checks for lstat.
110186         (gl_SYS_STAT_H_DEFAULTS): Set default for HAVE_LSTAT.
110188         link: fix test failure on Solaris 9
110189         * lib/link.c (rpl_link): Don't assume link will catch bogus
110190         trailing slash on source.
110192         test-symlinkat: enhance test
110193         * tests/test-readlink.c (main): Move guts...
110194         * tests/test-readlink.h (test_readlink): ...into new file.
110195         * tests/test-symlink.c (main): Move guts...
110196         * tests/test-symlink.h (test_symlink): ...into new file.
110197         * tests/test-symlinkat.c (main): Use new files for further
110198         coverage.
110199         (do_symlink, do_readlink): New helper functions.
110200         * modules/symlink-tests (Files): Ship new file.
110201         (Depends-on): Add stdbool.
110202         * modules/readlink-tests (Files): Ship new file.
110203         (Depends-on): Add stdbool.
110204         * modules/symlinkat-tests (Files): Use new files.
110206 2009-09-23  Eric Blake  <ebb9@byu.net>
110208         readlink: document portability issue with symlink length
110209         * doc/posix-functions/lstat.texi (lstat): Mention that some file
110210         systems have bogus st_size on symlinks, and mention the
110211         areadlink-with-size module.
110212         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
110213         * doc/posix-functions/readlink.texi (readlink): Mention the
110214         areadlink module, and ERANGE failure.
110215         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
110216         * tests/test-readlink.c (main): Relax test for AIX, HP-UX.
110218         readlink: fix Solaris 9 bug with trailing slash
110219         * lib/readlink.c (rpl_readlink): Work around trailing slash bug.
110220         * m4/readlink.m4 (gl_FUNC_READLINK): Detect the bug.
110221         * doc/posix-functions/readlink.texi (readlink): Document this.
110222         * modules/readlink-tests: New test.
110223         * tests/test-readlink.c: Likewise.
110225         readlink: fix cygwin 1.5.x bug with return type
110226         * m4/readlink.m4 (gl_FUNC_READLINK): Require correct signature.
110227         * lib/unistd.in.h (readlink): Use ssize_t.
110228         * lib/readlink.c (readlink): Likewise.
110229         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
110230         * modules/unistd (Makefile.am): Substitute it.
110231         * lib/unistd.in.h (readlink): Declare replacement.
110232         * doc/posix-functions/readlink.texi (readlink): Document this.
110234         symlink: use throughout gnulib
110235         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Omit symlink check.
110236         * lib/symlinkat.c (symlinkat) [!HAVE_SYMLINK]: Document why
110237         symlink is not used.
110238         * modules/symlinkat (Depends-on): Add symlink.
110239         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
110240         * modules/canonicalize-tests (Depends-on): Likewise.
110241         * modules/lstat-tests (Depends-on): Likewise.
110242         * modules/openat-tests (Depends-on): Likewise.
110243         * modules/remove-tests (Depends-on): Likewise.
110244         * modules/rmdir-tests (Depends-on): Likewise.
110245         * modules/unlink-tests (Depends-on): Likewise.
110246         * tests/test-canonicalize-lgpl.c (symlink): Delete stub.
110247         * tests/test-canonicalize.c (symlink): Likewise.
110248         * tests/test-fstatat.c (symlink): Likewise.
110249         * tests/test-lstat.c (symlink): Likewise.
110250         * tests/test-remove.c (symlink): Likewise.
110251         * tests/test-rmdir.c (symlink): Likewise.
110252         * tests/test-unlink.c (symlink): Likewise.
110253         * tests/test-unlinkat.c (symlink): Likewise.
110255         symlink: new module, for Solaris 9 bug
110256         * modules/symlink: New file.
110257         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
110258         * lib/symlink.c: Likewise.
110259         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
110260         * modules/unistd (Makefile.am): Substitute them.
110261         * lib/unistd.in.h (symlink): Declare replacement.
110262         * MODULES.html.sh (File system functions): Mention it.
110263         * doc/posix-functions/symlink.texi (symlink): Likewise.
110264         * modules/symlink-tests: New test.
110265         * tests/test-symlink.c: Likewise.
110267 2009-09-23  Bruno Haible  <bruno@clisp.org>
110269         * gnulib-tool (func_import): Add 'link-warning' to testsrelated_modules
110270         when needed.
110271         Test case: gnulib-tool --import --with-tests atexit inttypes.
110272         Reported by Pauli Miettinen <pauli.miettinen@cs.helsinki.fi>.
110274 2009-09-23  Bruno Haible  <bruno@clisp.org>
110276         * gnulib-tool (func_emit_tests_Makefile_am): Set uses_subdirs in a
110277         subcommand, not in a subshell.
110279 2009-09-22  Eric Blake  <ebb9@byu.net>
110281         unistd: sort replacement declarations
110282         * lib/unistd.in.h: Sort declarations.
110284         open, openat: minor optimization
110285         * lib/open.c (open): If open succeeded, len is non-zero.
110286         * lib/openat.c (rpl_openat): Likewise.
110288         link-follow: ensure correct result
110289         * m4/fcntl_h.m4 (gl_FCNTL_H): Clean up temporary file.
110290         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Likewise, and
110291         distinguish between possible failures.
110293 2009-09-21  Eric Blake  <ebb9@byu.net>
110295         fts: avoid compiler warning
110296         * lib/fts.c (dirent_inode_sort_may_be_useful)
110297         (leaf_optimization_applies) [!__linux__]: Mark unused parameters.
110299 2009-09-19  Bruno Haible  <bruno@clisp.org>
110301         * lib/progreloc.c (canonicalize_file_name): New declaration.
110303 2009-09-19  Eric Blake  <ebb9@byu.net>
110305         link: fix quoting
110306         * m4/link.m4 (gl_FUNC_LINK): Fix shell quoting.
110308         openat: fix openat bugs on Solaris 9
110309         * lib/openat.c (rpl_openat): Work around Solaris 9 bug.
110310         * m4/openat.m4 (gl_FUNC_OPENAT): Also replace openat on Solaris.
110311         * modules/openat (Depends-on): Add open.
110312         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Provide new default.
110313         * modules/fcntl-h (Makefile.am): Substitute it.
110314         * lib/fcntl.in.h (openat): Declare replacement.
110315         * doc/posix-functions/openat.texi (openat): Document this.
110317         openat: move fstatat and unlinkat into correct files
110318         * m4/openat.m4 (gl_FUNC_OPENAT): Adjust which files will be
110319         compiled.
110320         * lib/openat.c (fstatat, unlinkat): Move...
110321         * lib/fstatat.c (fstatat): ...into correct files.
110322         * lib/unlinkat.c (unlinkat): Likewise.
110324         openat: fix unlinkat bugs on Solaris 9
110325         * lib/unlinkat.c (unlinkat): New file.
110326         * modules/openat (Depends-on): Add unlink.
110327         (Files): Distribute it.
110328         * m4/openat.m4 (gl_FUNC_OPENAT): Mark unlinkat for replacement if
110329         trailing slash behavior is broken.
110330         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
110331         * modules/unistd (Makefile.am): Substitute it.
110332         * lib/unistd.in.h (unlinkat): Declare replacement.
110333         * doc/posix-functions/unlinkat.texi (unlinkat): Document this.
110335         openat: fix fstatat bugs on Solaris 9
110336         * lib/fstatat.c (rpl_fstatat): Copy recent fixes from lstat and
110337         stat.
110338         * doc/posix-functions/fstatat.texi (fstatat): Document this.
110340         test-unlinkat: enhance test, to expose Solaris 9 bug
110341         * tests/test-unlink.c (main): Factor guts...
110342         * tests/test-unlink.h (test_rmdir_func): ...into new file.
110343         * tests/test-rmdir.h (test_rmdir_func): Add parameter.
110344         * tests/test-rmdir.c (main): Adjust caller.
110345         * tests/test-unlinkat.c (main): Likewise.  Add unlink tests.
110346         (unlinker): New helper function.
110347         (rmdirat): Enhance check.
110348         * modules/rmdir-tests (Depends-on): Add stdbool.
110349         * modules/unlink-tests (Depends-on): Likewise.
110350         (Files): Add test-unlink.h.
110351         * modules/openat-tests (Files): Likewise.
110352         (Depends-on): Add unlinkdir.
110354         test-fstatat: new test, to expose Solaris 9 bugs
110355         * tests/test-stat.c (main): Factor guts...
110356         * tests/test-stat.h (test_stat_func): ...into new file.
110357         * tests/test-lstat.c (main): Factor guts...
110358         * tests/test-lstat.h (test_lstat_func): ...into new file.
110359         * tests/test-fstatat.c: New file.
110360         * modules/stat-tests (Files): Add test-stat.h.
110361         * modules/lstat-tests (Files): Add test-lstat.h.
110362         (Depends-on): Add stdbool.
110363         * modules/openat-tests (Depends-on): Add pathmax.
110364         (Files): Add test-lstat.h, test-stat.h, test-fstatat.c.
110365         (Makefile.am): Run new test.
110367         remove: new module, for mingw and Solaris 9 bugs
110368         * modules/remove: New file.
110369         * lib/remove.c: Likewise.
110370         * m4/remove.m4 (gl_FUNC_REMOVE): Likewise.
110371         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
110372         * modules/stdio (Makefile.am): Use them.
110373         * lib/stdio.in.h (remove): Declare replacement.
110374         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
110375         * doc/posix-functions/remove.texi (remove): Likewise.
110376         * modules/remove-tests: New test.
110377         * tests/test-remove.c: Likewise.
110379         unlink: new module, for Solaris 9 bug
110380         * modules/unlink: New file.
110381         * lib/unlink.c: Likewise.
110382         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
110383         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
110384         * modules/unistd (Makefile.am): Use them.
110385         * lib/unistd.in.h (stat): Declare replacement.
110386         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
110387         * doc/posix-functions/unlink.texi (unlink): Likewise.
110388         * modules/unlink-tests: New test.
110389         * tests/test-unlink.c: Likewise.
110391         lstat: fix Solaris 9 bug
110392         * lib/lstat.c (lstat): Also check for trailing slash on
110393         non-symlink, non-directories.  Use stat module to simplify logic.
110394         * doc/posix-functions/lstat.texi (lstat): Document it.
110395         * modules/lstat-tests (Depends-on): Add errno, same-inode.
110396         (configure.ac): Check for symlink.
110397         * tests/test-lstat.c (main): Add more tests.
110399         stat: add as dependency to other modules
110400         * modules/chown (Depends-on): Add stat.
110401         * modules/euidaccess (Depends-on): Likewise.
110402         * modules/fchdir (Depends-on): Likewise.
110403         * modules/isdir (Depends-on): Likewise.
110404         * modules/link (Depends-on): Likewise.
110405         * modules/lstat (Depends-on): Likewise.
110406         * modules/mkdir-p (Depends-on): Likewise.
110407         * modules/modechange (Depends-on): Likewise.
110408         * modules/open (Depends-on): Likewise.
110409         * modules/readlink (Depends-on): Likewise.
110410         * modules/same (Depends-on): Likewise.
110412         stat: fix Solaris 9 bug
110413         * m4/stat.m4 (gl_FUNC_STAT): Detect Solaris 9 bug with trailing
110414         slash.
110415         * lib/stat.c (rpl_stat): Work around it.
110416         * doc/posix-functions/stat.texi (stat): Update documentation.
110418         stat: new module, for mingw bug
110419         * modules/stat: New file.
110420         * lib/stat.c: Likewise.
110421         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
110422         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
110423         * modules/sys_stat (Makefile.am): Use them.
110424         * lib/sys_stat.in.h (stat): Declare replacement.
110425         * lib/openat.c (fstatat): Deal with lstat and stat being function
110426         macros.
110427         * modules/openat (Depends-on): Add inline.
110428         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
110429         * doc/posix-functions/stat.texi (stat): Likewise.
110430         * modules/stat-tests: New test.
110431         * tests/test-stat.c: Likewise.
110433 2009-09-19  Jim Meyering  <meyering@redhat.com>
110435         syntax-check: detect unnecessary inclusion of canonicalize.h
110436         * top/maint.mk (sc_prohibit_canonicalize_without_use): New rule.
110438 2009-09-19  Eric Blake  <ebb9@byu.net>
110440         canonicalize-lgpl: adjust clients to use correct header
110441         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
110442         (gl_CANONICALIZE_LGPL): Use correct shell quoting.
110443         * modules/relocatable-prog-wrapper (Files): Drop canonicalize.h.
110444         * lib/fchdir.c (includes): Use <stdlib.h>, not "canonicalize.h".
110445         * lib/progreloc.c (includes): Likewise.
110447 2009-09-19  Jim Meyering  <meyering@redhat.com>
110449         test-posixtm.c: correct a comment
110450         * tests/test-posixtm.c: Correct first-line comment.
110451         Spotted by Eric Blake.
110453 2009-09-16  Jim Meyering  <meyering@redhat.com>
110455         posixtm-tests: make T const-correct; add a test case
110456         * tests/test-posixtm.c (T): Declare const.
110457         Add a test for -(2^31+1).
110458         Remove useless can-succeed-only-in-2002 test.
110460         posixtm-tests: adjust the sole failing test
110461         * tests/test-posixtm.c: Correct 0000-01-01 00:00:00 test so that
110462         expected output matches what mktime now produces.  Cross-checked via
110463         erlang's calendar:datetime_to_gregorian_seconds({{1970,1,1},{0,0,0}})
110465         posixtm: move #ifdef'd tests into a new module
110466         * lib/posixtm.c (posixtime): Remove #ifdef'd tests.  Move to...
110467         * tests/test-posixtm.c: ... this new file.
110468         * modules/posixtm-tests: New module.
110470 2009-09-19  Eric Blake  <ebb9@byu.net>
110472         openat: simplify use of at-func.c
110473         * lib/at-func.c (includes): Include prerequisites here, to
110474         simplify requirements on client files.
110475         * lib/openat-priv.h: Add double-inclusion guard.
110476         * lib/faccessat.c (includes): Simplify.
110477         * lib/fchmodat.c (includes): Likewise.
110478         * lib/fchownat.c (includes): Likewise.
110479         * lib/mkdirat.c (includes): Likewise.
110480         * lib/mkfifoat.c (includes): Likewise.
110481         * lib/symlinkat.c (includes): Likewise.
110483         openat: allow return of fd 0
110484         * modules/chdir-long (Depends-on): Relax openat-safer to openat.
110485         * modules/save-cwd (Depends-on): Replace fcntl-safer with
110486         unistd-safer.
110487         * lib/chdir-long.c (includes): Replace "fcntl--.h" with
110488         <fcntl.h>; this module does not leak fds.
110489         * lib/openat.c (includes): Do not use "fcntl_safer"; plain openat
110490         must be allowed to return 0, leaving openat_safer to add the
110491         safety.
110492         (openat_permissive): Avoid writing to just-opened fd 2 if
110493         restoring the current directory fails.
110494         * lib/openat-die.c (openat_restore_fail): Add comment.
110495         * lib/save-cwd.c (includes): Make "fcntl--.h" conditional.
110496         (save_cwd): Guarantee safe fd, but without use of open_safer.
110497         * tests/test-openat.c: New test.
110498         * modules/openat-tests (Files, Makefile.am): Distribute and build
110499         new file.
110501         relocatable-prog-wrapper: fix build
110502         * modules/relocatable-prog-wrapper (Files): Update name of
110503         canonicalize m4 file, broken on 2009-09-17.
110504         Reported by emad hajjar <aleppos@hotmail.com>.
110506 2009-09-19  Bruno Haible  <bruno@clisp.org>
110508         * lib/safe-alloc.h: Use the standard header with GPL copyright.
110509         * lib/safe-alloc.c: Likewise.
110510         Reported by Ian Beckwith <ianb@erislabs.net>.
110512 2009-09-18  Bruno Haible  <bruno@clisp.org>
110514         * gnulib-tool: Add advice to "cannot find configure.ac" error message.
110515         Reported by <erobles@sensacd.com.mx>.
110517 2009-09-17  Eric Blake  <ebb9@byu.net>
110519         canonicalize: in CAN_ALL_BUT_LAST, allow trailing slash
110520         * lib/canonicalize.c (canonicalize_filename_mode): Skip trailing
110521         slashes when checking if last component is missing.
110522         * tests/test-canonicalize.c (main): Test this.
110524         canonicalize, canonicalize-lgpl: honor // if distinct from /
110525         * modules/canonicalize (Files): Add double-slash-root.m4.
110526         * modules/canonicalize-lgpl (Files): Likewise.
110527         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
110528         (gl_CANONICALIZE_LGPL_SEPARATE): Add dependency.
110529         * lib/canonicalize.c (DOUBLE_SLASH_IS_DISTINCT_ROOT): Provide
110530         fallback definition.
110531         (canonicalize_filename_mode): Use it to protect //.
110532         * lib/canonicalize-lgpl.c (DOUBLE_SLASH_IS_DISTINCT_ROOT)
110533         (__realpath): Likewise.
110534         * tests/test-canonicalize.c (main): Test this.
110535         * tests/test-canonicalize-lgpl.c (main): Likewise.
110536         * modules/canonicalize-tests (Depends-on): Add same-inode.
110537         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
110539         canonicalize-lgpl: fix glibc bug with trailing slash
110540         * m4/canonicalize-lgpl.m4: Move contents...
110541         * m4/canonicalize.m4: ...here.
110542         (gl_CANONICALIZE_LGPL): Factor realpath check...
110543         (gl_FUNC_REALPATH_WORKS): ...into new macro.  Enhance to catch
110544         glibc 2.3.5 bug, fixed 2005-04-27.
110545         (gl_FUNC_CANONICALIZE_FILENAME_MODE): Use it.
110546         (gl_PREREQ_CANONICALIZE_LGPL): Inline...
110547         (gl_CANONICALIZE_LGPL_SEPARATE): ...into this macro.
110548         * modules/canonicalize-lgpl (Files): Manage file rename.
110549         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
110550         * modules/stdlib (Makefile.am): Substitute witness.
110551         * lib/stdlib.in.h (canonicalize_file_name): Declare if replacement
110552         is needed.
110553         * lib/canonicalize-lgpl.c: Also compile if canonicalize_file_name
110554         replacement is required.
110555         * lib/canonicalize.c (canonicalize_file_name): Likewise.
110556         * doc/glibc-functions/canonicalize_file_name.texi
110557         (canonicalize_file_name): Document this.
110558         * doc/posix-functions/realpath.texi (realpath): Likewise.
110560         canonicalize-lgpl: reject non-directory with trailing slash
110561         * lib/canonicalize-lgpl.c (__realpath): Synchronize with glibc.
110562         * tests/test-canonicalize-lgpl.c (main): Enhance test.  This
110563         catches failures in glibc 2.3.5.
110564         * tests/test-canonicalize.c (main): Likewise.
110566         canonicalize-lgpl: use native realpath if it works
110567         * lib/canonicalize-lgpl.c (realpath): Guard with
110568         FUNC_REALPATH_WORKS.
110569         * lib/stdlib.in.h (realpath): Make declaration optional based on
110570         HAVE_REALPATH.
110571         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Check whether
110572         native realpath works.
110573         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
110574         * modules/stdlib (Makefile.am): Substitute witness.
110576         canonicalize, canonicalize-lgpl: use <stdlib.h>
110577         * modules/canonicalize-lgpl (Files): Drop canonicalize.h.
110578         (Include): Mention <stdlib.h>.
110579         (configure.ac): Mention functions we provide.
110580         * modules/canonicalize (configure.ac): Likewise.
110581         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Always replace
110582         realpath if canonicalize_file_name is missing.
110583         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide defaults.
110584         * modules/stdlib (Makefile.am): Substitute witnesses.
110585         * lib/stdlib.in.h (canonicalize_file_name, realpath): Declare.
110586         * lib/canonicalize-lgpl.c (includes): Adjust accordingly.
110587         * lib/canonicalize.h (canonicalize_file_name): Drop declaration.
110588         * NEWS: Document this.
110589         * doc/glibc-functions/canonicalize_file_name.texi
110590         (canonicalize_file_name): Likewise.
110591         * doc/posix-functions/realpath.texi (realpath): Likewise.
110592         * tests/test-canonicalize-lgpl.c (includes): Use <stdlib.h>.
110594         test-canonicalize: consolidate into single C program
110595         * tests/test-canonicalize.sh: Delete; move setup into...
110596         * tests/test-canonicalize.c (main): ...the program, making it
110597         easier to run in debugger.  Add some tests.
110598         * modules/canonicalize-tests (Files): Remove unused file.
110599         (Depends-on): Add progname.
110600         (configure.ac, Makefile.am): Simplify.
110602         test-canonicalize-lgpl: consolidate into single C program
110603         * tests/test-canonicalize-lgpl.sh: Delete; move setup into...
110604         * tests/test-canonicalize-lgpl.c (main): ...the program, making it
110605         easier to run in debugger.  Add some tests.
110606         * modules/canonicalize-lgpl-tests (Files): Remove unused file.
110607         (configure.ac, Makefile.am): Simplify.
110609         canonicalize: avoid resolvepath
110610         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Delete
110611         unnecessary checks.
110612         * lib/canonicalize.c (includes): Simplify.
110613         (canonicalize_file_name): Drop resolvepath implementation.
110614         * modules/canonicalize (Depends-on): Drop filenamecat.
110616         canonicalize: don't lose errno
110617         * lib/canonicalize.c (canonicalize_filename_mode): Protect errno
110618         over calls to free.
110620         canonicalize: simplify errno handling
110621         * lib/canonicalize.c (__set_errno): Delete macro, and use direct
110622         assignment.
110624         canonicalize, canonicalize-lgpl: update module dependencies
110625         * modules/canonicalize (Depends-on): Add extensions, lstat,
110626         pathmax, stdlib.
110627         (Files): Drop pathmax.h.
110628         (configure.ac): Adjust macro name.
110629         * modules/canonicalize-lgpl (Depends-on): Add errno, extensions,
110630         lstat, stdlib, sys_stat.
110631         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Rename...
110632         (gl_FUNC_CANONICALIZE_FILENAME_MODE): ...to this, and require
110633         extensions.
110634         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL)
110635         (gl_CANONICALIZE_LGPL_SEPARATE): Require extensions.
110636         (gl_PREREQ_CANONICALIZE_LGPL): Assume unistd.h.
110637         * lib/canonicalize.h (canonicalize_file_name): Use <stdlib.h>
110638         declaration, if available.
110639         * lib/canonicalize-lgpl.c [HAVE_READLINK]: Delete this condition;
110640         we can rely on the readlink module.
110641         (MAXSYMLINKS): Also consult SYMLOOP_MAX.
110642         (includes): Use <unistd.h> unconditionally.
110644 2009-09-17  Eric Blake  <ebb9@byu.net>
110646         maint: make Include sections of modules consistent
110647         * modules/alloca: Use only header name; no need to list #include.
110648         * modules/alloca-opt: Likewise.
110649         * modules/arpa_inet: Likewise.
110650         * modules/canon-host: Likewise.
110651         * modules/configmake: Likewise.
110652         * modules/dirent: Likewise.
110653         * modules/eealloc: Likewise.
110654         * modules/environ: Likewise.
110655         * modules/fchdir: Likewise.
110656         * modules/fcntl: Likewise.
110657         * modules/fcntl-h: Likewise.
110658         * modules/gethrxtime: Likewise.
110659         * modules/gettime: Likewise.
110660         * modules/ignore-value: Likewise.
110661         * modules/inet_ntop: Likewise.
110662         * modules/inet_pton: Likewise.
110663         * modules/inttypes: Likewise.
110664         * modules/isnand-nolibm: Likewise.
110665         * modules/isnanf-nolibm: Likewise.
110666         * modules/mbchar: Likewise.
110667         * modules/mbfile: Likewise.
110668         * modules/mbiter: Likewise.
110669         * modules/mbuiter: Likewise.
110670         * modules/netdb: Likewise.
110671         * modules/netinet_in: Likewise.
110672         * modules/nproc: Likewise.
110673         * modules/pagealign_alloc: Likewise.
110674         * modules/poll: Likewise.
110675         * modules/printf-frexp: Likewise.
110676         * modules/pthread: Likewise.
110677         * modules/putenv: Likewise.
110678         * modules/random_r: Likewise.
110679         * modules/relocatable-prog: Likewise.
110680         * modules/search: Likewise.
110681         * modules/select: Likewise.
110682         * modules/selinux-h: Likewise.
110683         * modules/settime: Likewise.
110684         * modules/signal: Likewise.
110685         * modules/size_max: Likewise.
110686         * modules/socklen: Likewise.
110687         * modules/ssize_t: Likewise.
110688         * modules/stdarg: Likewise.
110689         * modules/stdbool: Likewise.
110690         * modules/stddef: Likewise.
110691         * modules/stdint: Likewise.
110692         * modules/stdio: Likewise.
110693         * modules/stdlib: Likewise.
110694         * modules/string: Likewise.
110695         * modules/strings: Likewise.
110696         * modules/sys_file: Likewise.
110697         * modules/sys_ioctl: Likewise.
110698         * modules/sys_select: Likewise.
110699         * modules/sys_socket: Likewise.
110700         * modules/sys_stat: Likewise.
110701         * modules/sys_time: Likewise.
110702         * modules/sys_times: Likewise.
110703         * modules/sys_utsname: Likewise.
110704         * modules/sys_wait: Likewise.
110705         * modules/sysexits: Likewise.
110706         * modules/time: Likewise.
110707         * modules/times: Likewise.
110708         * modules/tmpfile: Likewise.
110709         * modules/trim: Likewise.
110710         * modules/unistd: Likewise.
110711         * modules/wchar: Likewise.
110712         * modules/wctype: Likewise.
110714 2009-09-17  Bruno Haible  <bruno@clisp.org>
110716         Make getdate.y compile on QNX and NetBSD 5 / i386.
110717         * m4/getdate.m4 (gl_GETDATE): Conditionally define
110718         TIME_T_FITS_IN_LONG_INT.
110719         * lib/getdate.y (long_time_t): New type.
110720         (relative_time): Change type of 'seconds' field to long_time_t.
110721         (get_date): Update types of local variables. Check against overflow
110722         during conversion from long_time_t to time_t.
110723         Reported by Matt Kraai <kraai@ftbfs.org>
110724         and Hasso Tepper <hasso@netbsd.org>.
110726 2009-09-17  Bruno Haible  <bruno@clisp.org>
110728         * modules/COPYING: Update copyright years.
110729         * modules/README: Likeiwse.
110730         * doc/gnulib-intro.texi (Copyright): Use a wildcard year.
110731         Reported by Ian Beckwith <ianb@erislabs.net>.
110733 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
110735         * users.txt: Update references for gnuit package.
110737 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
110739         * m4/getdelim.m4: Fix typo in copyright line.
110741 2009-09-17  Bruno Haible  <bruno@clisp.org>
110743         * lib/atoll.c: Use the standard header with GPL copyright.
110744         * lib/argz.in.h: Likewise.
110745         * lib/glob.c: Likewise.
110746         * lib/glob-libc.h: Likewise.
110747         * lib/random_r.c: Likewise.
110748         * lib/siglist.h: Likewise.
110749         * lib/strsignal.c: Likewise.
110750         Reported by Ian Beckwith <ianb@erislabs.net>.
110752 2009-09-17  Eric Blake  <ebb9@byu.net>
110754         rmdir: ensure correct dependency order
110755         * m4/rmdir.m4 (gl_FUNC_RMDIR): Require unistd defaults.
110757 2009-09-17  Bruno Haible  <bruno@clisp.org>
110759         Disable assertion that fails on NetBSD 5 / i386.
110760         * lib/mktime.c (ydhms_diff): Disable assertion about time_t size.
110761         Reported by Sam Steingold <sds@gnu.org>
110762         and Hasso Tepper <hasso@netbsd.org>.
110764 2009-09-16  Eric Blake  <ebb9@byu.net>
110766         unlinkdir: port to mingw
110767         * m4/unlinkdir.m4 (gl_UNLINKDIR): Add mingw to list of platforms
110768         on which no one can unlink a directory.
110770         stdlib: sort witness names
110771         * modules/stdlib (Makefile.am): Sort replacements.
110772         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
110773         * lib/stdlib.in.h: Likewise.
110775         parse-duration-tests: avoid link failure
110776         * modules/parse-duration-tests (test_parse_duration_LDADD): Add
110777         LIBINTL.
110778         Reported by Tom G. Christensen.
110780         openat-tests: ensure unlinkat behaves like rmdir
110781         * tests/test-rmdir.c (main): Factor guts...
110782         * tests/test-rmdir.h (test_rmdir_func): ...into new file.
110783         * modules/rmdir-tests (Files): Ship new file.
110784         * modules/openat-tests: New test.
110785         * tests/test-unlinkat.c: Likewise.
110787         rmdir-errno: mark obsolete, it is unsafe for cross-compilation
110788         * modules/rmdir-errno (Status, Notice): Now obsolete.
110790         rmdir: work around cygwin 1.5.x and mingw bugs
110791         * m4/rmdir.m4 (gl_FUNC_RMDIR): Detect the bugs.
110792         * lib/rmdir.c (rmdir): Work around it.
110793         * modules/rmdir (Status, Notice): No longer obsolete.
110794         (Files): Add dos.m4.
110795         (Depends-on): Add unistd.
110796         (configure.ac): Set witnesses.
110797         (License): Relax to LGPLv2+.
110798         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set defaults.
110799         * modules/unistd (Makefile.am): Substitute witnesses.
110800         * lib/unistd.in.h (rmdir): Declare replacement.
110801         * doc/posix-functions/rmdir.texi (rmdir): Document this.
110802         * modules/rmdir-tests: New tests.
110803         * tests/test-rmdir.c: Likewise.
110805 2009-09-15  Eric Blake  <ebb9@byu.net>
110807         fchdir: improve use of replacement functions
110808         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set appropriate witnesses.
110809         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add REPLACE_FSTAT.
110810         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add REPLACE_OPENDIR,
110811         REPLACE_CLOSEDIR.
110812         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_DUP.
110813         * modules/sys_stat (Makefile.am): Substitute correct witness.
110814         * modules/dirent (Makefile.am): Likewise.
110815         * modules/unistd (Makefile.am): Likewise.
110816         * lib/dirent.in.h (opendir, closedir): Use better witnesses.
110817         * lib/unistd.in.h (dup): Likewise.
110818         * lib/sys_stat.in.h (fstat): Likewise.
110820         maint: ignore gnulib-tool temp files
110821         * .gitignore: Ignore files created during gnulib-tool --test.
110823 2009-09-13  Jim Meyering  <meyering@redhat.com>
110825         posixtm: don't reject a time that specify "60" as the number of seconds
110826         * lib/posixtm.c (posixtime): The code to reject invalid dates
110827         would also reject a time specified with the .60 suffix.
110828         But POSIX allows that, in order to accommodate leap seconds.
110829         So don't reject it.
110830         (main): Adjust tests accordingly.
110831         * modules/posixtm (Depends-on): Add stpcpy.
110833 2009-09-11  Jim Meyering  <meyering@redhat.com>
110835         announce-gen: include [$release_type] in emitted Subject:
110836         * build-aux/announce-gen (get_tool_versions): Include [$release_type],
110837         e.g., [stable] in the emitted Subject: line.
110839 2009-09-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
110841         Remove obsolete macros from several modules.
110842         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Replace
110843         obsolete Autoconf macros with their modern counterparts.
110844         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Likewise.
110845         * m4/gc-camellia.m4 (gl_GC_CAMELLIA): Likewise.
110846         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
110847         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
110848         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Likewise.
110849         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
110850         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
110851         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
110852         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
110853         * m4/readline.m4 (gl_FUNC_READLINE): Likewise.
110854         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
110855         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
110856         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
110857         * m4/sockets.m4 (gl_SOCKETS): Likewise.
110858         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Likewise.
110859         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Likewise.
110860         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
110861         * m4/time_r.m4 (gl_TIME_R): Likewise.
110862         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
110863         * m4/vararrays.m4 (AC_C_VARARRAYS): Likewise.
110864         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
110866         Fix copyright header in build-aux scripts.
110867         * build-aux/git-version-gen: Fix copyright header to match GPLv3
110868         recommendation.
110869         * build-aux/ncftpput-ftp: Likewise.
110870         * build-aux/update-copyright: Likewise.
110872 2009-09-09  Eric Blake  <ebb9@byu.net>
110874         test-link: allow Linux choice of errno
110875         * tests/test-link.c (main): Relax test for alternate error.
110877         strndup: fix improper m4 caching
110878         * m4/strndup.m4 (gl_FUNC_STRNDUP): Rework to avoid side effects
110879         inside AC_CACHE_CHECK.  Use REPLACE_STRNDUP, not HAVE_STRNDUP.
110880         (gl_PREREQ_STRNDUP): Delete.
110881         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Update default.
110882         * modules/string (Makefile.am): Substitute it.
110883         * lib/string.in.h (strndup): Modernize prototype.
110885         getcwd: port to mingw
110886         * m4/getcwd.m4 (gl_FUNC_GETCWD): Mingw directories are very
110887         different from the POSIX assumptions made throughout the getcwd
110888         module; fortunately, the mingw getcwd does not need replacement.
110889         (gl_FUNC_GETCWD_NULL): Skip test on mingw.
110890         * modules/getcwd-tests: New test.
110891         * tests/test-getcwd.c: Likewise.
110893         link: fix platform bugs
110894         * m4/link.m4 (gl_FUNC_LINK): Detect Solaris and Cygwin bugs.
110895         * lib/link.c (link): Work around them.  Fix related mingw bug.
110896         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_LINK.
110897         * modules/unistd (Makefile.am): Substitute it.
110898         * lib/unistd.in.h (link): Declare replacement.
110899         * doc/posix-functions/link.texi (link): Document this.
110900         * modules/link (Depends-on): Add strdup-posix, sys_stat.
110902         test-link: consolidate into single C program, test more cases
110903         * tests/test-link.sh: Delete.
110904         * tests/test-link.c: Test more error conditions.  Exposes bugs on
110905         at least Cygwin and Solaris.
110906         * modules/link-tests (Files): Remove unused file.
110907         (Depends-on): Add errno, sys_stat.
110908         (Makefile.am): Simplify.
110910 2009-09-08  Bruno Haible  <bruno@clisp.org>
110912         Work around towlower, towupper bug on mingw.
110913         * lib/wctype.in.h (towlower, towupper) [__MINGW32__]: New replacements.
110914         * m4/wctype.m4 (gl_WCTYPE_H): Replace <wctype.h> also on mingw.
110915         * doc/posix-functions/towlower.texi: Mention the mingw bug.
110916         * doc/posix-functions/towupper.texi: Likewise.
110917         Reported by Eric Blake.
110919 2009-09-08  Jim Meyering  <meyering@redhat.com>
110921         build: don't try to run autoheader if we don't use it
110922         * build-aux/bootstrap: Define AUTOHEADER=true when AC_CONFIG_HEADERS
110923         is not used in configure.ac.
110925 2009-09-08  Eric Blake  <ebb9@byu.net>
110927         euidaccess: fix compilation error
110928         * lib/euidaccess.c (includes): Add <fcntl.h>, for AT_EACCESS.
110930         rawmemchr: relax license
110931         * modules/rawmemchr (License): Derived from glibc, so LGPLv2+ is
110932         okay.
110933         Reported by Jim Meyering.
110935         mkfifoat: new module
110936         * modules/mkfifoat: New file.
110937         * lib/mkfifoat.c: Likewise.
110938         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Likewise.
110939         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
110940         * modules/sys_stat (Makefile.am): Use them.
110941         * lib/sys_stat.in.h (mkfifoat, mknodat): Declare them.
110942         * MODULES.html.sh (File system functions): Mention module.
110943         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
110944         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
110945         * modules/mkfifoat-tests: New test.
110946         * tests/test-mkfifoat.c: Likewise.
110948         strchrnul: relax license
110949         * modules/strchrnul (License): Derived from glibc, so LGPLv2+ is
110950         okay.
110951         Reported by Jim Meyering.
110953 2009-09-08  Eric Blake  <ebb9@byu.net>
110955         fstatat: fix compilation on Solaris
110956         * lib/fstatat.c (includes): Add fcntl.h.
110957         Reported by Pádraig Brady.
110959 2009-09-07  Eric Blake  <ebb9@byu.net>
110961         rename: modernize replacement
110962         * modules/rename (Depends-on): Add stdio.
110963         (configure.ac): Declare witness.
110964         * m4/rename.m4 (gl_FUNC_RENAME): Ensure dependency order, and let
110965         stdio take care of replacement.
110966         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
110967         * modules/stdio (Makefile.am): Substitute them.
110968         * lib/stdio.in.h (rename): Declare replacement.
110969         * lib/rename.c (includes): Allow cross-compilation to non-windows
110970         machines.
110971         * doc/posix-functions/rename.texi (rename): Improve
110972         documentation.
110974         stdio: sort witness names
110975         * modules/stdio (Makefile.am): Sort replacements.
110976         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
110977         * lib/stdio.in.h: Likewise.
110979         getcwd: minor cleanups
110980         * lib/getcwd.c (AT_FDCWD): Delete; rely on <fcntl.h> instead.
110981         (is_ENAMETOOLONG): Delete; ENAMETOOLONG is portable.
110983         openat: provide more convenience names
110984         * modules/faccessat (configure.ac): Add C witness.
110985         * lib/unistd.in.h (readlinkat): Fix typo.
110986         * lib/openat.h (statat, lstatat, accessat, euidaccessat): New
110987         convenience wrappers.
110988         * top/maint.mk (sc_prohibit_openat_without_use): Allow these
110989         wrappers in syntax checks.
110991 2009-09-06  Eric Blake  <ebb9@byu.net>
110993         doc: fix comments in recent patches
110994         * lib/faccessat.c: Mention correct function.
110995         * lib/fchmodat.c: Likewise.
110996         * lib/fchownat.c: Likewise.
110997         * lib/symlinkat.c: Likewise.
110998         * doc/posix-headers/fcntl.texi (fcntl.h): Cygwin 1.7 has AT_*
110999         constants.
111001         faccessat, symlinkat: continue cleanup of previous patch
111002         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Ensure dependency order.
111003         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
111004         * modules/unistd (Makefile.am): Substitute GNULIB_READLINKAT.
111005         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Offer GNULIB_READLINKAT.
111006         * modules/symlinkat (configure.ac): Set GNULIB_READLINKAT.
111007         * lib/unistd.in.h (readlinkat): Declare if GNULIB_READLINKAT is
111008         set.
111010 2009-09-06  Bruno Haible  <bruno@clisp.org>
111012         * lib/sys_stat.in.h (fchmodat): Declare if GNULIB_FCHMODAT is set.
111013         (fstatat): Declare if GNULIB_FSTATAT is set.
111014         (mkdirat): Declare if GNULIB_MKDIRAT is set.
111015         * lib/unistd.in.h (fchownat): Declare if GNULIB_FCHOWNAT is set.
111016         (unlinkat): Declare if GNULIB_UNLINKAT is set.
111017         * modules/fcntl-h (Files): Remove m4/openat.m4.
111018         * modules/sys_stat (Files): Remove m4/openat.m4.
111019         (Makefile.am): Substitute GNULIB_FCHMODAT, GNULIB_FSTATAT,
111020         GNULIB_MKDIRAT instead of GNULIB_OPENAT.
111021         * modules/unistd (Files): Remove m4/openat.m4.
111022         (Makefile.am): Substitute GNULIB_FCHOWNAT, GNULIB_UNLINKAT instead of
111023         GNULIB_OPENAT.
111024         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize GNULIB_OPENAT,
111025         HAVE_OPENAT here. Don't require gl_OPENAT_DEFAULTS.
111026         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
111027         GNULIB_FCHMODAT, GNULIB_FSTATAT, GNULIB_MKDIRAT, HAVE_FCHMODAT,
111028         HAVE_FSTATAT, HAVE_MKDIRAT, REPLACE_FSTATAT here. Don't require
111029         gl_OPENAT_DEFAULTS.
111030         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_FCHOWNAT,
111031         GNULIB_UNLINKAT, HAVE_FCHOWNAT, HAVE_UNLINKAT, REPLACE_FCHOWNAT here.
111032         Don't require gl_OPENAT_DEFAULTS.
111033         * m4/openat.m4 (gl_FUNC_OPENAT): Require gl_FCNTL_H_DEFAULTS,
111034         gl_SYS_STAT_H_DEFAULTS, gl_UNISTD_H_DEFAULTS. Set GNULIB_FCHMODAT,
111035         GNULIB_FSTATAT, GNULIB_MKDIRAT, GNULIB_FCHOWNAT, GNULIB_UNLINKAT.
111036         (gl_OPENAT_DEFAULTS): Remove macro.
111038 2009-09-06  Bruno Haible  <bruno@clisp.org>
111040         * modules/openat (configure.ac): Remove unneeded witness.
111042 2009-09-06  Bruno Haible  <bruno@clisp.org>
111044         Set errno to ENOSYS when a function is entirely unsupported.
111045         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Set errno to ENOSYS instead of
111046         EOPNOTSUPP.
111047         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
111048         * modules/chown (Depends-on): Remove errno.
111050 2009-09-06  Bruno Haible  <bruno@clisp.org>
111052         * doc/posix-headers/fcntl.texi (AT_*): Mention affected platforms.
111054 2009-09-06  Bruno Haible  <bruno@clisp.org>
111056         * lib/sys_stat.in.h: Fix preprocessor command indentation.
111058 2009-09-06  Ben Pfaff  <blp@gnu.org>
111059             Bruno Haible  <bruno@clisp.org>
111061         Work around a glibc bug in strtok_r.
111062         * lib/string.in.h (strtok_r): Replace if REPLACE_STRTOK_R is set.
111063         Undefine if UNDEFINE_STRTOK_R is set.
111064         * lib/strtok_r.c (strtok_r, __strtok_r) [!_LIBC]: Don't undefine.
111065         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
111066         REPLACE_STRTOK_R and UNDEFINE_STRTOK_R.
111067         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Check against the glibc bug.
111068         * modules/string (Makefile.am): Substitute REPLACE_STRTOK_R,
111069         UNDEFINE_STRTOK_R.
111070         * doc/posix-functions/strtok_r.texi: Mention the glibc 2.7 bug.
111072 2009-09-06  Sergey Poznyakoff  <gray@gnu.org.ua>
111074         exclude: minor fix
111075         * lib/exclude.c: Include wctype.h
111077 2009-09-06  Akim Demaille  <demaille@gostai.com>
111079         bootstrap: improve error message
111080         * build-aux/bootstrap (find_tool): Upon failure, report the list
111081         of candidates.
111082         Honor the initial value of the envvar.
111084 2009-09-05  Eric Blake  <ebb9@byu.net>
111086         symlinkat: new module
111087         * modules/symlinkat: New file.
111088         * lib/symlinkat.c: Likewise.
111089         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
111090         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
111091         * modules/unistd (Makefile.am): Use them.
111092         * lib/unistd.in.h (symlinkat, readlinkat): Declare them.
111093         (faccessat) [GNULIB_POSIXCHECK]: Fix typo.
111094         * lib/at-func.c (FUNC_RESULT): New macro, defaulting to int.
111095         * MODULES.html.sh (File system functions): Mention module.
111096         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
111097         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
111098         * modules/symlinkat-tests: New test.
111099         * tests/test-symlinkat.c: Likewise.
111101         test-openat-safer: add more checks
111102         * tests/test-openat-safer.c (main): Check more code paths.
111104 2009-09-05  Jim Meyering  <meyering@redhat.com>
111106         syntax-check: detect unnecessary inclusion of openat.h
111107         * top/maint.mk (sc_prohibit_openat_without_use): New rule.
111109 2009-09-05  Bruno Haible  <bruno@clisp.org>
111111         Support towlower, towupper.
111112         * doc/posix-functions/towlower.texi: Mention module wctype.
111113         * doc/posix-functions/towupper.texi: Likewise.
111114         * lib/wctype.in.h (towlower, towupper): New functions.
111115         * tests/test-wctype.c: Include stdio.h, stdlib.h.
111116         (ASSERT): New macro.
111117         (e): New variable.
111118         (main): Test also towlower, towupper. Test WEOF argument.
111119         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
111121 2009-09-05  Bruno Haible  <bruno@clisp.org>
111123         Fix conversion behaviour when the input is invalid.
111124         * lib/striconveh.c (mem_cd_iconveh_internal): Fix storing of question
111125         mark occurring in first pass of indirect conversion.
111126         * tests/test-striconveh.c (main): Test conversion of invalid ASCII
111127         input.
111128         Found by clang's static analyzer.
111130 2009-09-05  Bruno Haible  <bruno@clisp.org>
111132         * tests/test-striconveh.c (main): Test indirect conversion on platforms
111133         where direct conversion is possible.
111135 2009-09-04  Eric Blake  <ebb9@byu.net>
111137         openat: fail with ENOENT on empty name
111138         * lib/openat-proc.c (openat_proc_name): Special-case the empty
111139         buffer.
111141         link-follow: fix logic bug in prior patch
111142         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Fix bug that
111143         reversed sense of yes and no in prior patch.  Avoid confusing
111144         compilation failure with desired semantics.
111146         link-follow: accommodate mingw and cross-compilation
111147         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Rename...
111148         (gl_FUNC_LINK_FOLLOWS_SYMLINK): ...to this.  Change
111149         cross-compilation results to -1, to make linkat easier to
111150         implement when cross-compiling.  Trivially support mingw.
111151         * modules/link-follow (configure.ac): Call new name.
111152         * NEWS: Mention this.
111154 2009-09-03  Eric Blake  <ebb9@byu.net>
111156         faccessat: compile replacement
111157         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Build replacement when
111158         needed.
111160         fts: fix compilation error
111161         * lib/fts.c (includes): Re-add "openat.h", for
111162         openat_needs_fchdir.
111164         faccessat: new module
111165         * modules/faccessat: New file.
111166         * lib/faccessat.c: Likewise.
111167         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
111168         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
111169         * modules/unistd (Makefile.am): Use it.
111170         * lib/unistd.in.h (faccessat): Declare it.
111171         (F_OK, X_OK, W_OK, R_OK): Provide definitions.
111172         * lib/fcntl.in.h (AT_SYMLINK_FOLLOW, AT_EACCESS): Likewise.
111173         * MODULES.html.sh (File system functions): Mention it.
111174         * doc/posix-functions/faccessat.texi (faccessat): Likewise.
111175         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
111177         euidaccess: prefer POSIX over non-standard implementation
111178         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Check for faccessat.
111179         * lib/euidaccess.c (euidaccess): Use it if available.
111181         openat: make template easier to use
111182         * lib/at-func.c (CALL_FUNC): Allow AT_FUNC_USE_F1_COND and
111183         AT_FUNC_F2 to be undefined.
111184         (VALIDATE_FLAG): New macro; use it to reject bad flags.
111185         (AT_FUNC_USE_F1_COND): Change sense to just flag bit.
111186         * lib/fchmodat.c (AT_FUNC_USE_F1_COND): Adjust.
111187         * lib/fchownat.c (AT_FUNC_USE_F1_COND): Likewise.
111188         * lib/openat.c (AT_FUNC_USE_F1_COND) [fstatat, unlinkat]:
111189         Likewise.
111190         * lib/mkdirat.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND): Delete.
111191         * lib/selinux-at.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND)
111192         [getfileconat, lgetfileconat, setfileconat, lsetfileconat]:
111193         Likewise.
111195         openat: declare in POSIX headers
111196         * NEWS: Mention this.
111197         * modules/openat (configure.ac): Declare witnesses.
111198         (Depends-on): Add fcntl-h, sys_stat, unistd.
111199         (Include): Mention correct headers.
111200         * modules/fcntl-h (Depends-on): Add link-warning.
111201         (Files): Add openat.m4.
111202         (Makefile.am): Substitute witnesses.
111203         * modules/sys_stat (Files, Makefile.am): Likewise.
111204         * modules/unistd (Files, Makefile.am): Likewise.
111205         * m4/openat.m4 (gl_FUNC_OPENAT, gl_FUNC_FCHOWNAT): Set witnesses.
111206         (gl_OPENAT_DEFAULTS): New macro.
111207         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Use it.
111208         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
111209         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
111210         (SYS_STAT_H): Remove unused variable.
111211         * doc/posix-headers/fcntl.texi (fcntl.h): Update content.
111212         * lib/fcntl--.h (includes): Remove unneeded header.
111213         * lib/openat-safer.c (includes): Likewise.
111214         * lib/openat.h (AT_FDCWD, AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR)
111215         (openat, fstatat, unlinkat, mkdirat, fchmodat, fchownat): Move to
111216         appropriate headers.
111217         (__OPENAT_PREFIX): Delete.
111218         * lib/fcntl.in.h (openat): Provide declaration.
111219         (AT_FDCWD): Fix Solaris bug.
111220         (AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR): Provide macros.
111221         * lib/sys_stat.in.h (fstatat, mkdirat): Provide declaration.
111222         * lib/fchmodat.c (includes):  Adjust to find declaration.
111223         * lib/fchownat.c (includes): Likewise.
111224         * lib/mkdirat.c (includes): Likewise.
111225         * lib/fstatat.c (includes): Likewise.  Ensure original fstatat is
111226         still visible.
111228 2009-09-02  Eric Blake  <ebb9@byu.net>
111230         errno: use consistently
111231         * lib/c-stack.c (ENOTSUP): <errno.h> guarantees a definition.
111232         * lib/canonicalize-lgpl.c (ENAMETOOLONG): Likewise.
111233         * lib/canonicalize.c (ELOOP): Likewise.
111234         * lib/inet_ntop.c (EAFNOSUPPORT): Likewise.
111235         * lib/inet_pton.c (EAFNOSUPPORT): Likewise.
111236         * lib/lchown.c (EOPNOTSUPP): Likewise.
111237         * lib/openat-priv.h (ENOSYS, EOPNOTSUPP): Likewise.
111238         * lib/savewd.c (ESTALE): Likewise.
111239         * lib/settime.c (ENOSYS): Likewise.
111240         * lib/utimens.c (ENOSYS): Likewise.
111241         * lib/xgethostname.c (ENAMETOOLONG): Likewise.
111242         * lib/chdir-safer.c (ELOOP): Likewise.
111243         (chdir_no_follow): Use HAVE_READLINK, not ELOOP, as witness.
111244         * modules/c-stack (Depends-on): Add errno.
111245         * modules/canonicalize (Depends-on): Likewise.
111246         * modules/chdir-safer (Depends-on): Likewise.
111247         * modules/fdopendir (Depends-on): Likewise.
111248         * modules/inet_ntop (Depends-on): Likewise.
111249         * modules/inet_pton (Depends-on): Likewise.
111250         * modules/lchown (Depends-on): Likewise.
111251         * modules/openat (Depends-on): Likewise.
111252         * modules/savewd (Depends-on): Likewise.
111253         * modules/settime (Depends-on): Likewise.
111254         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Check for readlink.
111256         fts: avoid leaking fds
111257         * modules/fts (Depends-on): Add cloexec.
111258         * lib/fts.c (opendirat, diropen, fts_build): Set close-on-exec
111259         flag.
111261         fts: make directory fds more robust
111262         * lib/fts.c (O_DIRECTORY): Let <fcntl.h> take care of this.
111263         (opendirat): Specify O_DIRECTORY, and add fallbacks for safety.
111265         backupfile, chdir-long, fts, savedir: make safer
111266         * lib/backupfile.c (includes): Use "dirent--.h", since
111267         numbered_backup can write to stderr during readdir.
111268         * lib/savedir.c (includes): Likewise.
111269         * lib/chdir-long.c (includes): Use "fcntl--.h", since openat
111270         emulation can write to stderr on failure.
111271         * lib/fts.c (includes) [!_LIBC]: Likewise for opendir and openat.
111272         * lib/getcwd.c: Document why opendir_safer is unused.
111273         * lib/glob.c: Likewise.
111274         * lib/scandir.c: Likewise.
111275         * lib/openat-proc.c: Likewise, for open_safer.
111276         * modules/backupfile (Depends-on): Add dirent-safer.
111277         * modules/savedir (Depends-on): Likewise.
111278         * modules/fts (Depends-on): Add dirent-safer and openat-safer.
111279         * modules/chdir-long (Depends-on): Add openat-safer.
111281         openat-safer: new module
111282         * modules/openat-safer: New file.
111283         * lib/openat-safer.c: Likewise.
111284         * m4/fcntl-safer.m4 (gl_OPENAT_SAFER): New macro.
111285         * lib/fcntl-safer.h (openat_safer): Declare.
111286         * lib/fcntl--.h (openat): Override.
111287         * MODULES.html.sh (File descriptor based I/O): Mention it.
111288         * lib/openat.h: Add double-inclusion guards.
111289         * lib/openat.c (includes): Only include "fcntl-safer.h", not
111290         "fcntl--.h", so we can implement openat.
111291         * modules/openat-safer-tests: New test.
111292         * tests/test-openat-safer.c: New file.
111294         dirent-safer: new module
111295         * modules/dirent-safer: New file.
111296         * lib/dirent--.h: Likewise.
111297         * lib/dirent-safer.h: Likewise.
111298         * lib/opendir-safer.c: Likewise.
111299         * m4/dirent-safer.m4: Likewise.
111300         * MODULES.html.sh (Enhancements for POSIX:2008): Mention it.
111301         * modules/dirent-safer-tests: New test.
111302         * tests/test-dirent-safer.c: New file.
111303         * lib/fdopendir.c (includes): Ensure fdopendir is also safe.
111305         fdopendir: optimize on mingw
111306         * lib/unistd.in.h (_gl_directory_name): New prototype.
111307         * lib/fchdir.c (_gl_directory_name): Implement it.
111308         (fchdir): Use it to simplify implementation.
111309         * lib/fdopendir.c (fdopendir) [REPLACE_FCHDIR]: Use metadata from
111310         fchdir, when available, to avoid calling [f]chdir().
111312         fdopendir: split into its own module
111313         * lib/openat.c (fdopendir): Move...
111314         * lib/fdopendir.c: ...into new file.
111315         * modules/fdopendir: New module.
111316         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): New file.
111317         * modules/openat (Depends-on): Add fdopendir.
111318         * m4/openat.m4 (gl_FUNC_OPENAT): No longer need to check for
111319         fdopendir here.
111320         * modules/savedir (Depends-on): Only need fdopendir, not full
111321         openat.
111322         * lib/savedir.c (include): Use <dirent.h>, not "openat.h".
111323         * lib/openat.h (fdopendir): Drop prototype.
111324         * lib/dirent.in.h (fdopendir): Provide prototype.
111325         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add replacements.
111326         * modules/dirent (Makefile.am): Substitute them.
111327         * MODULES.html.sh (File system functions): Mention it.
111328         * doc/posix-functions/fdopendir.texi (fdopendir): Likewise.
111329         * modules/fdopendir-tests: New file.
111330         * tests/test-fdopendir.c: Likewise.
111332         fchdir: use more consistent macro convention
111333         * lib/fcntl.in.h (_gl_register_fd): Move declaration to unistd.
111334         * lib/sys_stat.in.h (rpl_fstat): Declare via make-time
111335         REPLACE_FCHDIR, rather than relying on config.h macros.
111336         * lib/unistd.in.h (fchdir): Move all fchdir internal declarations
111337         inside a single make-time REPLACE_FCHDIR block, rather than using
111338         the config.h FCHDIR_REPLACEMENT.
111339         * m4/fchdir.m4 (gl_FUNC_FCHDIR): REPLACE_FCHDIR was already
111340         AC_SUBST'd, also AC_DEFINE it.  Don't define FCHDIR_REPLACEMENT.
111341         Manage fstat replacement.
111342         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Pick up
111343         REPLACE_FCHDIR.
111344         * modules/sys_stat (Files): Add m4/unistd_h.m4.
111345         (Makefile.am): Substitute REPLACE_FCHDIR.
111346         * lib/close.c (rpl_close): Use REPLACE_FCHDIR, not
111347         FCHDIR_REPLACEMENT.
111348         * lib/dup-safer.c (dup_safer): Likewise.
111349         * lib/dup2.c (rpl_dup2): Likewise.
111350         * lib/dup3.c (rpl_dup3): Likewise.
111351         * lib/open.c (rpl_open): Likewise.
111353         fchdir: simplify error handling, and support dup3
111354         * modules/fchdir (Depends-on): Use strdup-posix, not strdup.  Add
111355         stdbool, malloc-posix, realloc-posix.
111356         * lib/fchdir.c (struct dir_info_t): Delete saved_errno.
111357         (ensure_dirs_slot): Return false on allocation failure.
111358         (rpl_dup2): Delete.
111359         (_gl_register_dup): New function.
111360         (_gl_unregister_fd, rpl_opendir, rpl_dup): Update callers.
111361         (_gl_register_fd): Close fd on allocation failure.
111362         * lib/fcntl.in.h (_gl_register_fd): Update signature.
111363         * lib/unistd.in.h (_gl_register_dup) [FCHDIR_REPLACEMENT]: New
111364         prototype.
111365         (rpl_dup2_fchdir): Delete prototype.
111366         * lib/open.c (open): Update caller.
111367         * lib/dup2.c (dup2): Track fchdir metadata.
111368         * lib/dup3.c (dup3): Likewise.
111369         * m4/dup2.m4 (gl_REPLACE_DUP2): New macro.
111370         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Use it.
111372 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
111374         * gnulib-tool (func_create_testdir, func_create_megatestdir): Use
111375         AC_CONFIG_HEADERS instead of AM_CONFIG_HEADER. Use AC_CONFIG_FILES and
111376         don't pass arguments to AC_OUTPUT.
111378 2009-09-02  Bruno Haible  <bruno@clisp.org>
111380         * modules/mkdtemp (License): Relicense under LGPLv2+.
111381         Reported by Paolo Bonzini.
111383 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
111385         Replace uses of obsolete autoconf macros in Jim's modules.
111386         The Autoconf macros AC_TRY_CPP, AC_TRY_COMPILE, AC_TRY_LINK and
111387         AC_TRY_RUN have been obsolete since Autoconf 2.55, and each use
111388         can evoke a warning from autoconf when run with -Wobsolete
111389         enabled.  They were declared obsolete for good reasons (see
111390         the `AC_FOO_IFELSE vs AC_TRY_FOO' node in the Autoconf manual,
111391         recently renamed to `AC_ACT_IFELSE vs AC_TRY_ACT'), and we
111392         should not continue using the deprecated macros.
111393         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Replace
111394         obsolete Autoconf macros with modern counterparts.
111395         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
111396         * m4/dos.m4 (gl_AC_DOS): Likewise.
111397         * m4/fpending.m4 (gl_FUNC_FPENDING): Likewise.
111398         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Likewise.
111399         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Likewise.
111400         * m4/jm-winsz1.m4 (gl_WINSIZE_IN_PTEM): Likewise.
111401         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Likewise.
111402         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Likewise.
111403         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Likewise.
111404         * m4/mode_t.m4 (gl_PROMOTED_TYPE_MODE_T): Likewise.
111405         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
111406         Likewise.
111407         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
111408         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
111409         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Likewise.
111410         * m4/st_dm_mode.m4 (AC_STRUCT_ST_DM_MODE): Likewise.
111411         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
111412         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
111414 2009-09-01  Eric Blake  <ebb9@byu.net>
111416         fchdir: fix off-by-one bug in previous patch
111417         * lib/fchdir.c (rpl_fstat): Use correct bounds.
111418         (_gl_unregister_fd): Delete useless if.
111420 2009-09-01  Daniel P. Berrange  <berrange@redhat.com>
111422         maint.mk: sort the list of syntax-check rules
111423         * top/maint.mk (syntax-check-rules): Sort syntax-check rules, so it's
111424         easier to get a sense of progress when the rules are run sequentially
111425         and take a long time.
111427 2009-09-01  Simon Josefsson  <simon@josefsson.org>
111429         * modules/arpa_inet: Use $(MKDIR_P) instead of @MKDIR_P@.
111430         * modules/netinet_in: Likewise.
111431         * modules/sys_file: Likewise.
111432         * modules/sys_ioctl: Likewise.
111433         * modules/sys_select: Likewise.
111434         * modules/sys_socket: Likewise.
111435         * modules/sys_stat: Likewise.
111436         * modules/sys_time: Likewise.
111437         * modules/sys_times: Likewise.
111438         * modules/sys_utsname: Likewise.
111439         * modules/sys_wait: Likewise.
111441 2009-09-01  Jim Meyering  <meyering@redhat.com>
111443         fts: help ensure that return values are not ignored
111444         * lib/fts_.h (__GNUC_PREREQ): Define.
111445         (__attribute_warn_unused_result__): Define.
111446         (fts_children, fts_close, fts_open, fts_read): Declare with
111447         __attribute_warn_unused_result__.
111449         fts: fts_close now fails also when closing a dir file descriptor fails
111450         * lib/fts.c (fts_close): Detect close failure, not just fchdir failure,
111451         and propagate to caller, along with errno.
111453         announce-gen: correct formatting in --help output
111454         * build-aux/announce-gen (usage): Move the one-line description in
111455         --help output "up", to where it belongs, just after Usage:.
111457 2009-08-31  Eric Blake  <ebb9@byu.net>
111459         fchdir: port to mingw
111460         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Check for mingw bug.
111461         * lib/open.c (open) [FCHDIR_REPLACEMENT]: If directories can't be
111462         opened, then use a substitute.
111463         * lib/sys_stat.in.h (fstat) [REPLACE_OPEN_DIRECTORY]: Declare
111464         replacement.
111465         * lib/fchdir.c (fstat) [REPLACE_OPEN_DIRECTORY]: Implement it.
111466         (_gl_register_fd): No need to check stat if open already filters
111467         all directories.
111468         (fchdir): Fix error condition to match POSIX.
111469         * modules/fchdir (Depends-on): Add sys_stat.
111470         * doc/posix-functions/open.texi (open): Document the limitation.
111471         * modules/fchdir-tests: New file.
111472         * tests/test-fchdir.c: Likewise.
111474         canonicalize: allow cross-testing from cygwin to mingw
111475         * modules/canonicalize-tests (configure.ac): Define HAVE_SYMLINK.
111476         (Makefile.am): Pass it through TESTS_ENVIRONMENT.
111477         * modules/canonicalize-lgpl-tests (configure.ac, Makefile.am):
111478         Likewise.
111479         * tests/test-canonicalize.sh: Also skip test if 'ln -s' works, but
111480         target does not support symlinks.
111481         * tests/test-canonicalize-lgpl.sh: Likewise.
111483         chown: avoid compilation warning on mingw
111484         * m4/chown.m4 (gl_FUNC_CHOWN): Recognize missing chown.
111485         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Always return failure on
111486         mingw.
111487         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
111488         * modules/chown (Depends-on): Add errno.
111490 2009-08-31  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
111492         * gnulib-tool: Fix test whether $CONFIG_SHELL has a working 'echo'
111493         command.
111495 2009-08-31  Jim Meyering  <meyering@redhat.com>
111497         canonicalize: remove useless initialization
111498         * lib/canonicalize.c (canonicalize_filename_mode): Remove useless
111499         initialization of local, "end".
111501 2009-08-30  Bruno Haible  <bruno@clisp.org>
111503         Fix an unnecessary error on Solaris 10 on NFSv3 file systems.
111504         * lib/set-mode-acl.c (qset_acl) [Solaris 10 new]: Treat EOPNOTSUPP like
111505         ENOSYS.
111507 2009-08-30  Bruno Haible  <bruno@clisp.org>
111509         * tests/test-pipe-filter-ii1.sh: Prefer /usr/xpg6/bin/tr over
111510         /usr/xpg4/bin/tr when it exists.
111511         * tests/test-pipe-filter-gi1.sh: Likewise.
111513 2009-08-30  Bruno Haible  <bruno@clisp.org>
111515         Work around deficient /usr/bin/id program on Solaris.
111516         * tests/test-file-has-acl.sh (ID): New variable.
111517         * tests/test-set-mode-acl.sh (ID): Likewise.
111518         * tests/test-copy-acl.sh (ID): Likewise.
111519         * tests/test-copy-file.sh (ID): Likewise.
111521 2009-08-30  Bruno Haible  <bruno@clisp.org>
111523         New module 'xstriconveh'.
111524         * lib/xstriconveh.h: New file.
111525         * lib/xstriconveh.c: New file.
111526         * modules/xstriconveh: New file.
111528 2009-08-30  Bruno Haible  <bruno@clisp.org>
111530         Make it easier to use mem_cd_iconveh.
111531         * lib/striconveh.h (iconveh_t): New type.
111532         (iconveh_open, iconveh_close): New declarations.
111533         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
111534         with a single 'const iconveh_t *' argument.
111535         * lib/striconveh.c (iconveh_open, iconveh_close): New functions.
111536         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
111537         with a single 'const iconveh_t *' argument.
111538         (mem_iconveh, str_iconveh): Use iconveh_open, iconveh_close.
111539         * tests/test-striconveh.c (main): Update.
111540         * NEWS: Mention the change.
111542 2009-08-30  Bruno Haible  <bruno@clisp.org>
111544         * doc/posix-functions/iconv_open.texi: Mention indirect conversion
111545         problem.
111547 2009-08-30  Bruno Haible  <bruno@clisp.org>
111549         Work around iconv_open problem on Solaris.
111550         * lib/iconv_open-solaris.gperf: New file.
111551         * lib/iconv_open.c (ICONV_FLAVOR_SOLARIS): New macro.
111552         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Also handle Solaris.
111553         * modules/iconv_open (Files): Add lib/iconv_open-solaris.gperf.
111554         (Makefile.am): Add rule for iconv_open-solaris.h. Augment
111555         BUILT_SOURCES, MOSTLYCLEANFILES, MAINTAINERCLEANFILES, EXTRA_DIST.
111556         * doc/posix-functions/iconv_open.texi: Mention the Solaris problem.
111558 2009-08-29  Jim Meyering  <meyering@redhat.com>
111560         maint.mk: remove more coreutils-specific targets; XZ_OPT=-9ev
111561         * top/maint.mk (cvs-check): Remove target; it was just an alias
111562         to the better-named vc-diff-check.
111563         (maintainer-distcheck): Remove rule.  It was used only from
111564         the (alpha/beta/major) target, and all of its commands but one
111565         were coreutils-specific.
111566         (vc-dist): Remove rule.
111567         (alpha beta major): Run "$(MAKE) distcheck" explicitly.
111568         Run vc-diff-check, not vc-dist.
111569         Run $(MAKE) dist with XZ_OPT=-9ev.  Note spelling, with "-".
111571 2009-08-27  Bruno Haible  <bruno@clisp.org>
111573         * tests/test-bitrotate.c (main): Remove test that uses a shift count
111574         of 0.
111576 2009-08-27  Bruno Haible  <bruno@clisp.org>
111578         * tests/test-func.c (main): Don't verify sizeof __func__ on SunPRO C
111579         compilers.
111580         * doc/func.texi: Document the SunPRO C bug.
111582 2009-08-27  Bruno Haible  <bruno@clisp.org>
111584         Fix link error on Solaris.
111585         * tests/test-parse-duration.c (xstrdup): Remove function.
111587 2009-08-26  Pádraig Brady  <P@draigbrady.com>
111589         ignore-value: handle pointer types, too
111590         * lib/ignore-value.h (__attribute__): Remove definition.
111591         (ignore_value): Remove use of "__attribute__ ((unused))" in favor
111592         of a more concise and more-often effective "(void) i" statement.
111593         (ignore_ptr): New function to suppress warnings from functions that
111594         return pointers, and to make it explicit that one function doesn't
111595         handle all cases.
111597 2009-08-25  Bruno Haible  <bruno@clisp.org>
111599         dup2: work around a Linux bug.
111600         * m4/dup2.m4 (gl_FUNC_DUP2): Test for the Linux bug.
111601         * lib/dup2.c (rpl_dup2): Correct the return value if it is -EBADF.
111602         * doc/posix-functions/dup2.texi: Mention the Linux bug.
111603         Reported by Simon Josefsson.
111605 2009-08-25  Jim Meyering  <meyering@redhat.com>
111607         libguestfs uses gnulib
111608         * users.txt: Add libguestfs.
111610 2009-08-24  Eric Blake  <ebb9@byu.net>
111612         dup2, pipe2: fix some recent test failures on cygwin 1.5.x
111613         * lib/pipe2.c (includes): Add binary-io.h.
111614         * lib/dup2.c (rpl_dup2): Correct buggy errno value.
111616 2009-08-24  Bruno Haible  <bruno@clisp.org>
111618         Tolerate declared but missing accept4 syscall.
111619         * lib/accept4.c (accept4): Invoke original accept4 function first, if
111620         available.
111621         * lib/sys_socket.in.h (accept4): If the function is already present,
111622         override it.
111623         * m4/accept4.m4 (gl_FUNC_ACCEPT4): Remove AC_LIBOBJ invocation.
111624         * modules/accept4 (Makefile.am): Compile accept4.c always.
111625         Reported by Paolo Bonzini and Eric Blake.
111627 2009-08-23  Bruno Haible  <bruno@clisp.org>
111629         New module 'accept4'.
111630         * lib/sys_socket.in.h (accept4): New declaration.
111631         * lib/accept4.c: New file.
111632         * m4/accept4.m4: New file.
111633         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
111634         GNULIB_ACCEPT4, HAVE_ACCEPT4.
111635         * modules/sys_socket (Makefile.am): Substitute GNULIB_ACCEPT4,
111636         HAVE_ACCEPT4.
111637         * modules/accept4: New file.
111638         * doc/glibc-functions/accept4.texi: Mention the new module.
111640 2009-08-24  Jim Meyering  <meyering@redhat.com>
111642         progname: also set global program_invocation_name, when possible
111643         Before this change, a libtool-enabled program that calls glibc's
111644         error function would report the program name as
111645         "/abs/dir/.libs/lt-program_name" rather than the desired program_name.
111646         * modules/progname (configure.ac): Check for a declaration of
111647         program_invocation_name.
111648         * lib/progname.c:  Include <errno.h>.
111649         (set_program_name) [HAVE_DECL_PROGRAM_INVOCATION_NAME]:
111650         Set program_invocation_name.
111652 2009-08-23  Bruno Haible  <bruno@clisp.org>
111654         * lib/dup3.c: Include <string.h>.
111656 2009-08-23  Bruno Haible  <bruno@clisp.org>
111658         * lib/dup3.c (dup3): Test only once whether the system actually exists.
111659         * lib/pipe2.c (pipe2): Likewise.
111660         Suggested by Eric Blake.
111662 2009-08-23  Bruno Haible  <bruno@clisp.org>
111664         Tolerate declared but missing dup3 syscall.
111665         * lib/dup3.c (dup3): Invoke original dup3 function first, if available.
111666         * lib/unistd.in.h (dup3): If the function is already present,
111667         override it.
111668         * m4/dup3.m4 (gl_FUNC_DUP3): Remove AC_LIBOBJ invocation.
111669         * modules/dup3 (Makefile.am): Compile dup3.c always.
111670         Reported by Paolo Bonzini.
111672 2009-08-23  Bruno Haible  <bruno@clisp.org>
111674         Tolerate declared but missing pipe2 syscall.
111675         * lib/pipe2.c (pipe2): Invoke original pipe2 function first, if
111676         available.
111677         * lib/unistd.in.h (pipe2): If the function is already present,
111678         override it.
111679         * m4/pipe2.m4 (gl_FUNC_PIPE2): Remove AC_LIBOBJ invocation.
111680         * modules/pipe2 (Makefile.am): Compile pipe2.c always.
111681         Reported by Paolo Bonzini.
111683 2009-08-23  Bruno Haible  <bruno@clisp.org>
111685         * lib/pipe2.c (pipe2): Move #ifs inside function.
111687 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
111689         quotearg: document limitations of quote_these_too
111690         * lib/quotearg.c (quotearg_buffer_restyled): Add comments where
111691         those limitations are created.
111692         * lib/quotearg.h (set_char_quoting): Document that digits and
111693         letters that are special after backslash are not permitted.
111694         (quotearg_char): Cross-reference set_char_quoting documentation.
111696 2009-08-23  Joel E. Denny  <jdenny@clemson.edu>
111698         quotearg: implement custom_quoting_style
111699         * lib/quotearg.c: (struct quoting_options): Add left_quote and
111700         right_quote fields.
111701         (set_custom_quoting): New public function.
111702         (quotearg_buffer_restyled): Add left_quote and right_quote
111703         arguments, handle them very much like locale quoting, and update
111704         all uses.
111705         (quotearg_n_custom): New public function.
111706         (quotearg_n_custom_mem): New public function.
111707         (quotearg_custom): New public function.
111708         (quotearg_custom_mem): New public function.
111709         * lib/quotearg.h: Prototype and document new public functions.
111710         (enum quoting_style): For escape_quoting_style and
111711         clocale_quoting_style, comment that QA_SPLIT_TRIGRAPHS is
111712         ignored even though they're otherwise like c_quoting_style.
111713         Add custom_quoting_style member and document with comparison to
111714         clocale_quoting_style.
111715         * tests/test-quotearg.c (custom_quotes): New array.
111716         (custom_results): New array.
111717         (main): Extend to test custom quoting.
111719 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
111721         quotearg: fix right quote escaping when it's in quote_these_too
111722         * lib/quotearg.c (quotearg_buffer_restyled): Upon seeing a right
111723         quote, be sure to prepend only one backslash.
111724         * tests/test-quotearg.c (use_quote_double_quotes): New function.
111725         (main): Test it.
111727 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
111729         quotearg-tests: test escaping of embedded locale quotes
111730         * tests/test-quotearg.c (struct result_strings): Add member for
111731         new input.
111732         (LQ_ENC, RQ_ENC, RQ_ESC): New macros.
111733         (inputs): Add new input.
111734         (results_g): Add expected results.
111735         (flag_results): Likewise.
111736         (locale_results): Likewise.
111737         (compare_strings): Check those.
111739 2009-08-23  Bruno Haible  <bruno@clisp.org>
111741         Tests for module 'dup3'.
111742         * modules/dup3-tests: New file.
111743         * tests/test-dup3.c: New file.
111745         New module 'dup3'.
111746         * lib/unistd.in.h (dup3): New declaration.
111747         * lib/dup3.c: New file.
111748         * m4/dup3.m4: New file.
111749         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_DUP3 and
111750         HAVE_DUP3.
111751         * modules/unistd (Makefile.am): Substitute GNULIB_DUP3 and HAVE_DUP3.
111752         * modules/dup3: New file.
111753         * doc/glibc-functions/dup3.texi: Mention the new module.
111755 2009-08-23  Bruno Haible  <bruno@clisp.org>
111757         Tweak the dup2 test.
111758         * tests/test-dup2.c (main): Create the test file empty. Verify that an
111759         out-of-range fd yields EBADF. Verify that after writing to /dev/null,
111760         the test file is still empty. Fix argument order of lseek.
111762 2009-08-23  Bruno Haible  <bruno@clisp.org>
111764         Avoid test link errors when the modules getopt-gnu, gettext are used.
111765         * modules/getopt-posix-tests (Makefile.am): Define test_getopt_LDADD.
111766         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
111768 2009-08-23  Bruno Haible  <bruno@clisp.org>
111770         Fix getdtablesize() on mingw.
111771         * lib/getdtablesize.c (getdtablesize): Implement differently.
111772         * lib/unistd.in.h (getdtablesize): Improve comment.
111774 2009-08-23  Bruno Haible  <bruno@clisp.org>
111776         New module 'mkostemp'.
111777         Based on Ulrich Drepper's 2007-08-10 change in glibc.
111778         * lib/stdlib.in.h (mksotemp): New declaration.
111779         * lib/mkostemp.c: New file, from glibc with modifications.
111780         * lib/tempname.h (GT_FILE): Remove outdated comment.
111781         (gen_tempname): Add flags argument.
111782         * lib/tempname.c (__GT_BIGFILE): Remove macro.
111783         (__GT_FILE): Map to 1.
111784         (small_open, large_open): Remove macros.
111785         (__gen_tempname): Add flags argument. Remove code for __GT_BIGFILE.
111786         * lib/mkstemp.c (mkstemp): Update.
111787         * lib/mkdtemp.c (mkdtemp): Likewise.
111788         * m4/mkostemp.m4: New file.
111789         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_MKOSTEMP,
111790         HAVE_MKOSTEMP.
111791         * modules/stdlib (Makefile.am): Substitute GNULIB_MKOSTEMP,
111792         HAVE_MKOSTEMP.
111793         * modules/mkostemp: New file, based on modules/mkstemp.
111794         * doc/glibc-functions/mkostemp.texi: Mention the new module.
111795         * NEWS: Mention the change.
111797 2009-08-23  Bruno Haible  <bruno@clisp.org>
111799         * lib/pipe2.c (pipe2): Support O_TEXT, O_BINARY on all platforms.
111800         Reported by Eric Blake.
111802 2009-08-23  Bruno Haible  <bruno@clisp.org>
111804         * lib/pipe2.c (pipe2): Fix test of fcntl's return value.
111805         Reported by Eric Blake.
111807 2009-08-23  Bruno Haible  <bruno@clisp.org>
111809         * modules/fchdir (Depends-on): Use fcntl-h instead of fcntl.
111810         * modules/pipe2 (Depends-on): Likewise.
111812 2009-08-23  Eric Blake  <ebb9@byu.net>
111814         fcntl-h: add O_TTY_INIT support
111815         * lib/fcntl.in.h (O_TTY_INIT): Support another POSIX macro.
111816         * tests/test-fcntl-h.c (o): Test it.
111817         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
111819         fcntl-h: rename from fcntl, in preparation for fcntl(2)
111820         * modules/fcntl: Move <fcntl.h> header replacement...
111821         * modules/fcntl-h: ...to new name, so as not to collide with
111822         like-named function.
111823         * tests/test-fcntl.c: Rename...
111824         * tests/test-fcntl-h.c: ...to this.  Test FD_CLOEXEC.
111825         * modules/fcntl-tests: Rename...
111826         * modules/fcntl-h-tests: ...to this.  Update test file name.
111827         * modules/chdir-long (Depends-on): Update clients.
111828         * modules/chdir-safer (Depends-on): Likewise.
111829         * modules/fcntl-safer (Depends-on): Likewise.
111830         * modules/fts (Depends-on): Likewise.
111831         * modules/mkancesdirs (Depends-on): Likewise.
111832         * modules/mkdir-p (Depends-on): Likewise.
111833         * modules/open (Depends-on): Likewise.
111834         * modules/savewd (Depends-on): Likewise.
111835         * MODULES.html.sh (systems lacking POSIX:2008): Update name.
111836         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
111838 2009-08-22  Bruno Haible  <bruno@clisp.org>
111840         * modules/binary-io (License): Relicense under LGPL.
111841         * modules/pipe2 (License): Likewise.
111843 2009-08-22  Bruno Haible  <bruno@clisp.org>
111845         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Fix test of fcntl's
111846         return value.
111847         * lib/pipe-filter-gi.c (filter_init): Likewise.
111848         Reported by Eric Blake.
111850 2009-08-22  Bruno Haible  <bruno@clisp.org>
111852         * lib/pipe.c (create_pipe): Use pipe2 instead of _pipe.
111853         * modules/pipe (Depends-on): Add pipe2.
111855 2009-08-22  Bruno Haible  <bruno@clisp.org>
111857         Tests for module 'pipe2'.
111858         * modules/pipe2-tests: New file.
111859         * tests/test-pipe2.c: New file.
111861         New module 'pipe2'.
111862         * lib/unistd.in.h (pipe2): New declaration.
111863         * lib/pipe2.c: New file.
111864         * m4/pipe2.m4: New file.
111865         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_PIPE2 and
111866         HAVE_PIPE2.
111867         * modules/unistd (Makefile.am): Substitute GNULIB_PIPE2 and HAVE_PIPE2.
111868         * modules/pipe2: New file.
111869         * doc/glibc-functions/pipe2.texi: Mention the new module.
111871 2009-08-22  Bruno Haible  <bruno@clisp.org>
111873         Reference some new glibc functions.
111874         * doc/glibc-functions/accept4.texi: New file.
111875         * doc/glibc-functions/dup3.texi: New file.
111876         * doc/glibc-functions/mkostemp.texi: New file.
111877         * doc/glibc-functions/pipe2.texi: New file.
111878         * doc/gnulib.texi (Glibc stdlib.h): Refer to mkostemp.
111879         (Glibc sys/socket.h): Refer to accept4.
111880         (Glibc unistd.h): Refer to dup3, pipe2.
111881         Reported by Eric Blake.
111883 2009-08-22  Jim Meyering  <meyering@redhat.com>
111884             Bruno Haible  <bruno@clisp.org>
111886         annotate automake snippets with $(AM_V_GEN) and $(AM_V_at)
111887         This makes it so packages using automake-1.11's silent-rules option
111888         can print e.g., a single "GEN    configmake.h" line, rather than
111889         the 30+ statements that perform the job.  If you want to see the
111890         actual commands, you can still run "make V=1".
111891         * modules/alloca-opt: Add $(AM_V_GEN) and $(AM_V_at) prefixes
111892         so that make output is abbreviated when those variables are defined
111893         appropriately.
111894         * modules/argz: Likewise.
111895         * modules/arpa_inet: Likewise.
111896         * modules/byteswap: Likewise.
111897         * modules/configmake: Likewise.
111898         * modules/dirent: Likewise.
111899         * modules/errno: Likewise.
111900         * modules/fcntl: Likewise.
111901         * modules/float: Likewise.
111902         * modules/fnmatch: Likewise.
111903         * modules/getopt-posix: Likewise.
111904         * modules/glob: Likewise.
111905         * modules/iconv_open: Likewise.
111906         * modules/inttypes: Likewise.
111907         * modules/localcharset: Likewise.
111908         * modules/locale: Likewise.
111909         * modules/math: Likewise.
111910         * modules/netdb: Likewise.
111911         * modules/netinet_in: Likewise.
111912         * modules/poll: Likewise.
111913         * modules/posix_spawnp-tests: Likewise.
111914         * modules/sched: Likewise.
111915         * modules/search: Likewise.
111916         * modules/selinux-h: Likewise.
111917         * modules/signal: Likewise.
111918         * modules/spawn: Likewise.
111919         * modules/stdarg: Likewise.
111920         * modules/stdbool: Likewise.
111921         * modules/stddef: Likewise.
111922         * modules/stdint: Likewise.
111923         * modules/stdio: Likewise.
111924         * modules/stdlib: Likewise.
111925         * modules/string: Likewise.
111926         * modules/strings: Likewise.
111927         * modules/sys_file: Likewise.
111928         * modules/sys_ioctl: Likewise.
111929         * modules/sys_select: Likewise.
111930         * modules/sys_socket: Likewise.
111931         * modules/sys_stat: Likewise.
111932         * modules/sys_time: Likewise.
111933         * modules/sys_times: Likewise.
111934         * modules/sys_utsname: Likewise.
111935         * modules/sys_wait: Likewise.
111936         * modules/sysexits: Likewise.
111937         * modules/time: Likewise.
111938         * modules/unistd: Likewise.
111939         * modules/wchar: Likewise.
111940         * modules/wctype: Likewise.
111942 2009-08-22  Jim Meyering  <meyering@redhat.com>
111944         announce-gen: detect write failure
111945         * build-aux/announce-gen: Add Coda at end.
111946         Remove equivalent-but-more-verbose block at top.
111948 2009-08-19  Akim Demaille  <demaille@gostai.com>
111950         bootstrap: --help to stdout.
111951         * bootstrap (usage): Don't send --help to stderr.
111952         Use a here doc instead of a long string.
111954 2009-08-21  Eric Blake  <ebb9@byu.net>
111956         test-popen-safer: split from test-popen
111957         * tests/test-popen.c (main): Move...
111958         * tests/test-popen.h: ...into new file.
111959         * tests/test-popen-safer2.c: New file.
111960         * modules/popen-tests (Files): Add test-popen.h.
111961         * modules/popen-safer-tests (Files): Add test-popen-safer2.c.
111962         Suggested by Bruno Haible.
111964         test-fcntl-safer: split from test-open
111965         * tests/test-open.c (main): Move...
111966         * tests/test-open.h: ...into new file.
111967         * tests/test-fcntl-safer.c: New file.
111968         * modules/open-tests (Files): Add test-open.h.
111969         * modules/fcntl-safer-tests: New file.
111970         Suggested by Bruno Haible.
111972         test-fopen-safer: split from test-fopen
111973         * tests/test-fopen.c (main): Move...
111974         * tests/test-fopen.h: ...into new file.
111975         * tests/test-fopen-safer.c: New file.
111976         * modules/fopen-tests (Files): Add test-fopen.h.
111977         * modules/fopen-safer-tests: New file.
111978         Suggested by Bruno Haible.
111980 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
111982         popen-safer: test O_CLOEXEC at run-time.
111983         * lib/popen-safer.c: Test O_CLOEXEC at run-time.
111985 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
111987         fcntl: move more flags to the header
111988         * lib/cloexec.c: Do not define FD_CLOEXEC here.
111989         * lib/popen-safer.c: Do not alias O_NOINHERIT to O_CLOEXEC here.
111990         * lib/fcntl.in.h: Do both things here.
111992 2009-08-21  Jim Meyering  <meyering@redhat.com>
111994         consistently remove $@-t before redirecting to it
111995         * modules/argz: Remove $@-t and $@ before redirecting to the former.
111996         * modules/alloca-opt: Likewise.
111997         * modules/byteswap: Likewise.
111998         * modules/fnmatch: Likewise.
111999         * modules/getopt-posix: Likewise.
112000         * modules/glob: Likewise.
112001         * modules/poll: Likewise.
112002         * modules/posix_spawnp-tests: Likewise.
112003         * modules/sys_socket: Likewise.
112004         * modules/sysexits: Likewise.
112006 2009-08-21  Eric Blake  <ebb9@byu.net>
112008         popen: simplify access to original popen
112009         * lib/popen.c (rpl_popen): No need to worry about popen being a
112010         macro.
112011         Reported by Bruno Haible.
112013 2009-08-20  Eric Blake  <ebb9@byu.net>
112015         build: avoid some compiler warnings
112016         * lib/selinux-at.h: Use dir_fd, not dirfd, to avoid shadowing.
112017         * lib/exclude.c (fnmatch_pattern_has_wildcards): Use correct
112018         type.
112019         (new_exclude_segment, excluded_file_pattern_p)
112020         (excluded_file_name_p): Reduce scope.
112021         * lib/vasnprintf.c (decimal_point_char): Avoid warning on
112022         old-style declaration.
112024 2009-08-20  Simon Josefsson  <simon@josefsson.org>
112026         * tests/test-exclude1.sh: Handle Windows EOL.
112027         * tests/test-exclude2.sh: Likewise.
112028         * tests/test-exclude3.sh: Likewise.
112029         * tests/test-exclude4.sh: Likewise.
112030         * tests/test-exclude5.sh: Likewise.
112031         * tests/test-exclude6.sh: Likewise.
112032         * tests/test-exclude7.sh: Likewise.
112034 2009-08-19  Akim Demaille  <demaille@gostai.com>
112036         bootstrap: find sha1sum when named gsha1sum.
112037         * bootstrap (find_tool): New.
112038         ($SHA1SUM): New.
112039         Use it.
112041 2009-08-20  Jim Meyering  <meyering@redhat.com>
112043         maint.mk: _header_without_use: fix a quoting bug and remove a bash'ism
112044         * top/maint.mk (_header_without_use): Use "\\\\", not "\\" in the sed
112045         expression that converts "." in a file name to "\." in the resulting
112046         regexp.  Start with a dummy statement, so that prior shell variable
112047         definitions are expanded portably.  Reported by Simon Josefsson.
112049 2009-08-20  Paolo Bonzini  <bonzini@gnu.org>
112051         Fix polling for writeability of a screen buffer.
112052         * lib/poll.c: Distinguish input and screen buffers for the
112053         Win32 implementation.
112054         * lib/select.c: Likewise.
112056 2009-08-19  Eric Blake  <ebb9@byu.net>
112058         popen-safer: prevent popen from clobbering std descriptors
112059         * modules/popen-safer: New file.
112060         * lib/popen-safer.c: Likewise.
112061         * m4/stdio-safer.m4 (gl_POPEN_SAFER): New macro.
112062         * lib/stdio--.h (popen): Provide override.
112063         * lib/stdio-safer.h (popen_safer): Provide declaration.
112064         * tests/test-popen.c (includes): Partially test this.
112065         * modules/popen-safer-tests: New file, for more tests.
112066         * tests/test-popen-safer.c: Likewise.
112067         * MODULES.html.sh (file stream based Input/Output): Mention it.
112069         tests: test some of the *-safer modules
112070         * modules/fopen-safer (Depends-on): Add fopen.
112071         * modules/fcntl-safer (Depends-on): Add fcntl.
112072         * modules/stdlib-safer (Depends-on): Add stdlib.
112073         (configure.ac): Set indicator.
112074         * modules/unistd-safer (configure.ac): Likewise.
112075         * modules/tmpfile-safer (configure.ac): Likewise.
112076         (Depends-on): Add tmpfile.
112077         * lib/stdio--.h (fopen, tmpfile): Don't override unless module is
112078         active.
112079         * tests/test-fopen.c (includes): Test safer versions when they are
112080         in use.
112081         * tests/test-open.c (includes): Likewise.
112083         popen: fix cygwin 1.5 bug when stdin closed
112084         * doc/posix-functions/popen.texi (popen): Document cygwin bugs.
112085         * modules/popen: New file.
112086         * modules/popen-tests: Likewise.
112087         * tests/test-popen.c: Likewise.
112088         * m4/popen.m4: Likewise.
112089         * lib/popen.c: Likewise.
112090         * lib/stdio.in.h (popen): New declaration.
112091         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add popen.
112092         * modules/stdio (Makefile.am): Likewise.
112093         * MODULES.html.sh (systems lacking POSIX:2008): Mention it.
112095 2009-08-17  Joel E. Denny  <jdenny@clemson.edu>
112097         maint.mk: give full control over update-copyright exclusions
112098         * top/maint.mk (VC_LIST_EXCEPT): Instead of ChangeLog, use
112099         ${VC_LIST_EXCEPT_DEFAULT-ChangeLog} as the default exclusion.
112100         (update-copyright): Don't force inclusion of top-level
112101         ChangeLog.  Don't force exclusion of all COPYING files, but make
112102         them the default exclusion instead.
112104 2009-08-16  Bruno Haible  <bruno@clisp.org>
112106         Fix test failures on Solaris 10.
112107         * tests/uniconv/test-u8-conv-from-enc.c (main): Disable autodetect_jp
112108         tests when Solaris iconv() is used.
112109         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
112110         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
112111         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
112112         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
112113         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
112115 2009-08-16  Bruno Haible  <bruno@clisp.org>
112117         Fix test failures on Solaris 10.
112118         * tests/test-pipe-filter-ii1.sh: Determine the filename of a working
112119         'tr' program and pass it as first argument.
112120         * tests/test-pipe-filter-gi1.sh: Likewise.
112121         * tests/test-pipe-filter-ii1.c (main): Except the filename of a 'tr'
112122         program as first argument.
112123         * tests/test-pipe-filter-gi1.c (main): Likewise.
112125 2009-08-16  Eric Blake  <ebb9@byu.net>
112127         fpurge: fix previous commits
112128         * modules/fpurge (Makefile.am): Make replacement conditional,
112129         partially reverting 2007-04-29 change; missed in previous
112130         attempt.
112131         * m4/fpurge.m4 (gl_FUNC_FPURGE): Also compile fpurge.c when fpurge
112132         is missing.
112134 2009-08-16  Bruno Haible  <bruno@clisp.org>
112136         Clarify fpurge's effect on the file position.
112137         * lib/stdio.in.h (fpurge): Specify the file position after fpurge.
112138         * tests/test-fpurge.c (main): Make a second pass for checking the file
112139         position.
112141 2009-08-16  Bruno Haible  <bruno@clisp.org>
112143         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't compile fpurge.c if only the
112144         declaration of fpurge is missing.
112145         * tests/test-fpurge.c (main): Check that the file has not more contents
112146         than expected. Close the file before removing it.
112148 2009-08-15  Eric Blake  <ebb9@byu.net>
112150         fpurge: don't wrap working cygwin implementation
112151         * lib/fpurge.c (fpurge): Fix comment typo.
112152         * m4/fpurge.m4 (gl_FUNC_FPURGE): Detect BSD bug, allowing cygwin
112153         1.7 to avoid replacement.
112154         * tests/test-fpurge.c (main): Enhance test.
112156 2009-08-15  Eric Blake  <ebb9@byu.net>
112157         and Jim Meyering  <meyering@redhat.com>
112159         test-update-copyright: skip if perl is insufficient
112160         * tests/test-update-copyright.sh: Failure to run maintainer tool
112161         should not cause testsuite failure on cygwin 1.5.
112163 2009-08-14  Eric Blake  <ebb9@byu.net>
112165         doc: mention more functions added in cygwin 1.7.0
112166         * doc/posix-headers/limits.texi (limits.h): Update for recent
112167         cygwin additions.
112168         * doc/posix-headers/wordexp.texi (wordexp.h): Likewise.
112169         * doc/posix-functions/wordexp.texi (wordexp): Likewise.
112170         * doc/posix-functions/wordfree.texi (wordfree): Likewise.
112171         * doc/posix-functions/setlocale.texi (setlocale): Likewise.
112172         * doc/posix-functions/nl_langinfo.texi (nl_langinfo): Likewise.
112174 2009-08-14  Eric Blake  <ebb9@byu.net>
112176         maint.mk: simplify update-copyright rule
112177         * top/maint.mk (update-copyright-local): Delete, and document how
112178         to do it in cfg.mk instead.
112179         (update-copyright-exclude-regexp): Delete, and document how to do
112180         it in .x-update-copyright instead.
112181         (update-copyright): Simplify, thanks to VC_LIST_EXCEPT.  Don't
112182         exclude ChangeLog.
112184 2009-08-14  Bruno Haible  <bruno@clisp.org>
112186         * m4/wchar.m4 (gl_WCHAR_H): Undo invalid optimization in last commit.
112188 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
112190         maint.mk: support update-copyright-env
112191         * top/maint.mk (update-copyright-env): Define place-holder.
112192         (update-copyright): Expand $(update-copyright-env) before
112193         invoking update-copyright.
112195 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
112197         update-copyright: implement forced reformatting
112198         * build-aux/update-copyright: Implement and document
112199         UPDATE_COPYRIGHT_FORCE.
112200         * tests/test-update-copyright.sh: Test it.
112202 2009-08-14  Eric Blake  <ebb9@byu.net>
112203         and Bruno Haible  <bruno@clisp.org>
112205         stddef: fix NetBSD 5.0 NULL bug, rather than working around it
112206         * tests/test-locale.c: Revert previous patch related to NULL.
112207         * tests/test-stdio.c: Likewise.
112208         * tests/test-stdlib.c: Likewise.
112209         * tests/test-string.c: Likewise.
112210         * tests/test-unistd.c: Likewise.
112211         * modules/time-tests (Depends-on): Add verify.
112212         * modules/wchar-tests (Depends-on): Likewise.
112213         * tests/test-time.c: Test for NULL compliance.
112214         * tests/test-wchar.c: Likewise.
112215         * modules/locale (Depends-on): Add stddef.
112216         * modules/stdio (Depends-on): Likewise.
112217         * modules/stdlib (Depends-on): Likewise.
112218         * modules/string (Depends-on): Likewise.
112219         * modules/time (Depends-on): Likewise.
112220         * modules/unistd (Depends-on): Likewise.
112221         * modules/wchar (Depends-on): Likewise.
112222         * lib/locale.in.h (includes): Use <stddef.h> to fix NULL.
112223         * lib/stdlib.in.h (includes): Likewise.
112224         * lib/string.in.h (includes): Likewise.
112225         * lib/time.in.h (includes): Likewise.
112226         * lib/unistd.in.h (includes): Likewise.
112227         * m4/locale_h.m4 (gl_LOCALE_H): Replace locale.h if stddef.h was
112228         replaced.
112229         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
112230         * m4/stddef_h.m4: New file.
112231         * modules/stddef: Likewise.
112232         * lib/stddef.in.h: Likewise.
112233         * modules/stddef-tests: Likewise.
112234         * tests/test-stddef.c: Likewise.
112235         * MODULES.html.sh (Basic types <stddef.h>): Mention new module.
112236         * doc/posix-headers/stddef.texi (stddef.h): Document the bug.
112237         * doc/posix-headers/locale.texi (locale.h): Likewise.
112238         * doc/posix-headers/stdio.texi (stdio.h): Likewise.
112239         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
112240         * doc/posix-headers/string.texi (string.h): Likewise.
112241         * doc/posix-headers/time.texi (time.h): Likewise.
112242         * doc/posix-headers/unistd.texi (unistd.h): Likewise.
112243         * doc/posix-headers/wchar.texi (wchar.h): Likewise.
112245 2009-08-14  Eric Blake  <ebb9@byu.net>
112247         doc: improve git diff of texinfo files
112248         * .gitattributes: Add rule for *.texi files, with hint on how to
112249         use it.
112250         Copied from m4, and based on a report by Bruno Haible.
112252 2009-08-14  Bruno Haible  <bruno@clisp.org>
112254         Disable multithread support by default on Cygwin 1.5.x for real.
112255         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Fix last commit.
112257 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
112259         update-copyright: much ado about intervals
112260         * build-aux/update-copyright: Implement and document
112261         UPDATE_COPYRIGHT_USE_INTERVALS to control expansion and collapse
112262         of copyright year intervals.
112263         Also, document UPDATE_COPYRIGHT_YEAR.
112264         * tests/test-update-copyright.sh: Test it.
112266         update-copyright: convert 2-digit to 4-digit years
112267         * build-aux/update-copyright: Implement and document.
112268         * tests/test-update-copyright.sh: Update.
112270 2009-08-14  Jim Meyering  <meyering@redhat.com>
112272         test-exclude: avoid coreutils "make check" failure
112273         * tests/test-exclude.c (ARGMATCH_DIE_DECL) [ARGMATCH_DIE_DECL]: Define,
112274         just as in test-argmatch.c.
112276 2009-08-13  Eric Blake  <ebb9@byu.net>
112278         test-dup2: fix bad assumption
112279         * tests/test-dup2.c (main): Tolerate leaked fds from environment.
112280         Reported by Peter Breitenlohner <peb@mppmu.mpg.de>.
112282         test-version-etc: fix CRLF portability issue
112283         * tests/test-version-etc.sh: Use tr, not sed, as not all sed
112284         recognize \r.
112285         * tests/test-argp-version-etc-1.sh: Likewise.
112287         getopt: update client modules
112288         * modules/argp (Depends-on): Use getopt-gnu.
112289         * modules/git-merge-changelog (Depends-on): Likewise.
112290         * modules/long-options (Depends-on): Likewise.
112291         * modules/xstrtol (Depends-on): Likewise.
112293 2009-08-13  Simon Josefsson  <simon@josefsson.org>
112295         * tests/test-version-etc.sh: Don't fail on different
112296         project/version.  Don't fail on CRLF differences.  Rewrite to use
112297         multiple -e instead of multiple sed forks, suggested by Eric Blake
112298         <ebb9@byu.net>.
112299         * tests/test-argp-version-etc-1.sh: Likewise.
112301 2009-08-13  Simon Josefsson  <simon@josefsson.org>
112303         * tests/test-version-etc.sh: Don't fail on different
112304         project/version.
112306 2009-08-12  Bruno Haible  <bruno@clisp.org>
112308         Tests for modules 'getopt-posix', 'getopt-gnu'.
112309         * modules/getopt-posix-tests: New file.
112310         * tests/test-getopt.c: New file.
112311         * tests/test-getopt.h: New file.
112312         * tests/test-getopt_long.h: New file.
112314         New modules 'getopt-posix', 'getopt-gnu'.
112315         * modules/getopt-gnu: New file, renamed from modules/getopt.
112316         * modules/getopt-posix: New file.
112317         * modules/getopt: Turn into an obsolete alias for getopt-gnu.
112318         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX, gl_FUNC_GETOPT_GNU): New macros.
112319         (gl_GETOPT): Remove macro.
112320         (gl_GETOPT_CHECK_HEADERS): Do some checks only for gl_FUNC_GETOPT_GNU.
112321         Disable the test against BSD systems that declare optreset. Test
112322         against mingw bug. Test against lack of support of optional arguments
112323         on many platforms.
112324         * doc/glibc-headers/getopt.texi: Update module name and list of
112325         relevant platforms.
112326         * doc/posix-functions/getopt.texi: Mention modules 'getopt-posix' and
112327         'getopt-gnu' and more portability problems.
112328         * NEWS: Mention the changes.
112330 2009-08-12  Bruno Haible  <bruno@clisp.org>
112332         Ensure that optarg etc. get declared by <unistd.h>.
112333         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require
112334         AC_USE_SYSTEM_EXTENSIONS.
112335         * modules/getopt (Depends-on): Add 'extensions'.
112337 2009-08-12  Bruno Haible  <bruno@clisp.org>
112339         Avoid test link errors.
112340         * modules/pipe-filter-ii-tests (Makefile.am): Define
112341         test_pipe_filter_ii1_LDADD and test_pipe_filter_ii2_main_LDADD.
112342         * modules/pipe-filter-gi-tests (Makefile.am): Define
112343         test_pipe_filter_gi1_LDADD and test_pipe_filter_gi2_main_LDADD.
112344         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
112346 2009-08-12  Bruno Haible  <bruno@clisp.org>
112348         * m4/getopt.m4 (gl_REPLACE_GETOPT): New macro, was called
112349         gl_GETOPT_SUBSTITUTE before.
112350         (gl_GETOPT): Use it.
112351         * m4/argp.m4 (gl_ARGP): Update.
112352         Reported by Sergey Poznyakoff.
112354         * m4/getopt.m4: Reorder macros.
112355         (gl_GETOPT): Inline gl_GETOPT_SUBSTITUTE.
112356         (gl_GETOPT_SUBSTITUTE): Remove macro.
112358 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
112360         Minor improvement in gitlog-to-changelog
112362         * build-aux/gitlog-to-changelog: New option `--format' makes
112363         output format string configurable.
112365 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
112367         Optimize exclude: use hash tables for non-wildcard patterns.
112369         * lib/exclude.c: Include hash.h and mbuiter.h
112370         (struct exclude_pattern, exclude_segment): New data types.
112371         (struct exclude): Rewrite.
112372         (fnmatch_pattern_has_wildcards): New function.
112373         (new_exclude_segment, free_exclude_segment): New functions.
112374         (excluded_file_pattern_p, excluded_file_name_p): New functions.
112375         (excluded_file_name, add_exclude): Rewrite using new struct exclude.
112376         * lib/exclude.h (is_fnmatch_pattern): New prototype.
112377         * modules/exclude: Depend on hash and mbuiter.
112379         * modules/exclude-tests: New file.
112380         * tests/test-exclude.c: New file.
112381         * tests/test-exclude1.sh: New file.
112382         * tests/test-exclude2.sh: New file.
112383         * tests/test-exclude3.sh: New file.
112384         * tests/test-exclude4.sh: New file.
112385         * tests/test-exclude5.sh: New file.
112386         * tests/test-exclude6.sh: New file.
112387         * tests/test-exclude7.sh: New file.
112389 2009-08-12  Bruno Haible  <bruno@clisp.org>
112391         Ensure that getopt() gets declared by <unistd.h>.
112392         * lib/unistd.in.h: Conditionally include getopt.h.
112393         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Require gl_UNISTD_H_DEFAULTS.
112394         Set GNULIB_UNISTD_H_GETOPT.
112395         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
112396         GNULIB_UNISTD_H_GETOPT.
112397         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_GETOPT.
112399 2009-08-12  Bruno Haible  <bruno@clisp.org>
112401         Clarify logic.
112402         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS, gl_GETOPT_IFELSE): Use
112403         gl_replace_getopt instead of GETOPT_H.
112405 2009-08-12  Bruno Haible  <bruno@clisp.org>
112407         * m4/getopt.m4: Add comments.
112409 2009-08-12  Bruno Haible  <bruno@clisp.org>
112411         Disable multithread support by default on Cygwin 1.5.x.
112412         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): On Cygwin 1.5.x and older,
112413         set gl_use_threads=no if not specified otherwise.
112415 2009-08-11  Bruno Haible  <bruno@clisp.org>
112417         Avoid compilation error on NetBSD 5.0.
112418         * tests/test-locale.c: Write sizeof (NULL) instead of sizeof NULL.
112419         * tests/test-stdio.c: Likewise.
112420         * tests/test-stdlib.c: Likewise.
112421         * tests/test-string.c: Likewise.
112422         * tests/test-unistd.c: Likewise.
112423         Reported by Greg Troxel <gdt@ir.bbn.com>
112424         at <https://savannah.gnu.org/support/?106973>.
112426 2009-08-11  Bruno Haible  <bruno@clisp.org>
112428         * modules/dup2-tests (Depends-on): Remove close.
112430         Undo 2009-07-19 commit.
112431         * modules/acl-tests (Depends-on): Remove close.
112432         * modules/binary-io-tests (Depends-on): Likewise.
112433         * modules/closein-tests (Depends-on): Likewise.
112434         * modules/flock-tests (Depends-on): Likewise.
112435         * modules/fsync-tests (Depends-on): Likewise.
112436         * modules/lseek-tests (Depends-on): Likewise.
112437         * modules/pipe-tests (Depends-on): Likewise.
112438         * modules/posix_spawn-tests (Depends-on): Likewise.
112439         * modules/posix_spawnp-tests (Depends-on): Likewise.
112440         * modules/stat-time-tests (Depends-on): Likewise.
112441         * modules/yesno-tests (Depends-on): Likewise.
112443 2009-08-10  Bruno Haible  <bruno@clisp.org>
112445         * lib/vasnprintf.c (DCHAR_SET): Undefine at the end.
112447 2009-08-10  Bruno Haible  <bruno@clisp.org>
112449         Fix a gcc warning.
112450         * lib/write.c (rpl_write): Cast result of _get_osfhandle.
112452 2009-08-10  Bruno Haible  <bruno@clisp.org>
112454         Don't optimize AC_LIBOBJs, as they may appear in different contexts.
112455         * m4/close.m4 (gl_REPLACE_CLOSE): Execute AC_LIBOBJ unconditionally,
112456         not only the first time.
112457         * m4/fclose.m4 (gl_REPLACE_FCLOSE): Likewise.
112458         * m4/open.m4 (gl_REPLACE_OPEN): Likewise.
112459         * m4/strstr.m4 (gl_FUNC_STRSTR): Execute AC_LIBOBJ when REPLACE_STRSTR
112460         is 1, not only the first time.
112462 2009-08-10  Bruno Haible  <bruno@clisp.org>
112464         Make it possible to use module 'gethostname' without module 'close'.
112465         * lib/unistd.in.h (close): Evoke a link error only if
112466         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
112467         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
112468         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
112469         * modules/unistd (Makefile.am): Substitute
112470         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
112471         * lib/sys_ioctl.in.h (ioctl): Evoke a link error only if
112472         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
112473         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Initialize
112474         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
112475         * modules/sys_ioctl (Makefile.am): Substitute
112476         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
112477         * modules/socket (configure.ac): On native Windows, set
112478         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS and
112479         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
112480         Reported by Sam Steingold <sds@gnu.org>.
112482 2009-08-10  Bruno Haible  <bruno@clisp.org>
112484         * m4/close.m4 (gl_FUNC_CLOSE): Add comment.
112485         * modules/ioctl (configure.ac): Likewise.
112487 2009-08-10  Bruno Haible  <bruno@clisp.org>
112489         Avoid collision between gnulib wrapper and libintl wrapper.
112490         * lib/stdio-write.c (printf): Don't define if a printf wrapper is
112491         already defined in intl/printf.c.
112492         (vprintf): Test REPLACE_VPRINTF_POSIX, not REPLACE_VFPRINTF_POSIX.
112493         (vfprintf): Test REPLACE_VFPRINTF_POSIX, not REPLACE_VPRINTF_POSIX.
112495 2009-08-09  Bruno Haible  <bruno@clisp.org>
112497         Make <sys/select.h> really self-contained, also on Solaris 10.
112498         * lib/sys_select.in.h: Include <string.h>.
112499         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Test also against
112500         Solaris 10 problem.
112501         * tests/test-sys_select.c (main): Add check that FD_ZERO can be used.
112502         * doc/posix-headers/sys_select.texi: Mention the Solaris 10 problem.
112503         Reported by Jim Meyering.
112505 2009-08-09  Bruno Haible  <bruno@clisp.org>
112507         Avoid warnings from 'aclocal' that are due to a use of macro name
112508         AM_XGETTEXT_OPTION that is not defined in automake.
112509         * modules/argp (configure.ac): Hide use of AM_XGETTEXT_OPTION from
112510         automake.
112511         * modules/error (configure.ac): Likewise.
112512         * modules/propername (configure.ac): Likewise.
112513         * modules/vasprintf (configure.ac): Likewise.
112514         * modules/verror (configure.ac): Likewise.
112515         * modules/xprintf (configure.ac): Likewise.
112516         * modules/xvasprintf (configure.ac): Likewise.
112518 2009-08-08  Bruno Haible  <bruno@clisp.org>
112520         Avoid compilation error in C++ mode.
112521         * lib/gettimeofday.c (rpl_gettimeofday): Cast timezone argument.
112522         Reported by Sam Steingold <sds@gnu.org>.
112524 2009-08-08  Bruno Haible  <bruno@clisp.org>
112526         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Define HOST_NAME_MAX also
112527         for the various Unix platforms.
112528         * doc/posix-headers/limits.texi: Update platforms list regarding
112529         HOST_NAME_MAX.
112530         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
112532 2009-08-07  Jim Meyering  <meyering@redhat.com>
112534         selinux-at: fix typo in a comment
112535         * lib/selinux-at.h: s/getfileconat/getfilecon/ in a comment.
112536         Spotted by Paolo Bonzini.
112538         selinux-at: remove redundant m4 code, add documentation
112539         * modules/selinux-at (configure.ac): Remove redundant code.
112540         LIB_SELINUX is already set via the dependent module, selinux-h.
112541         (Include): Add quotes around selinux-at.h.
112542         * lib/selinux-at.h: Add documentation.
112543         Reported by Bruno Haible in
112544         http://marc.info/?l=gnulib-bug&m=124958988300749
112546 2009-08-07  Bruno Haible  <bruno@clisp.org>
112548         Avoid link error on MacOS X 10.3 and 10.4.
112549         * lib/argp-ba.c (argp_program_bug_address): Explicitly zero-initialize
112550         on non-ELF systems.
112551         * lib/argp-pv.c (argp_program_version): Likewise.
112552         Reported by Simon Josefsson.
112554 2009-08-07  Simon Josefsson  <simon@josefsson.org>
112556         * tests/test-version-etc.sh: Use $EXEEXT.
112558 2009-08-06  Joel E. Denny  <jdenny@clemson.edu>
112560         update-copyright: update documentation to point to maint.mk
112561         * build-aux/update-copyright: Here.
112563 2009-08-06  Jim Meyering  <meyering@redhat.com>
112565         maint.mk: support update-copyright-local
112566         * top/maint.mk (update-copyright-local): Define place-holder.
112567         (update-copyright): Depend on $(update-copyright-local).
112569 2009-08-06  Jim Meyering  <meyering@redhat.com>
112571         selinux-at: new module
112572         Initially written for coreutils, this module will soon be
112573         used by findutils, too.
112574         * MODULES.html.sh [Misc]: Add selinux-at.
112575         * lib/selinux-at.h: New file, from coreutils.
112576         * lib/selinux-at.c: Likewise.
112577         * modules/selinux-at: Likewise.
112578         (License): Change from LGPL to GPL, since it depends
112579         on the GPL'd openat module.
112581         doc: update README
112582         * README: Remove references to cogito.
112583         Remove cvs-repo-updating instructions from 2007.
112584         Don't imply that CVS is better if you have limited disk space.
112586 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
112588         update-copyright: support C-style comments
112589         * build-aux/update-copyright: Implement and document.
112590         * tests/test-update-copyright.sh: Test.
112592 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
112594         update-copyright: support omitted "(C)"
112595         * build-aux/update-copyright: Implement and document.  Also,
112596         allow variable whitespace before "(C)".
112597         * tests/test-update-copyright.sh: Test.
112599 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
112601         update-copyright: don't trip on non-FSF copyright statements
112602         * build-aux/update-copyright: Fix so that the first correctly
112603         formatted FSF copyright statement is recognized no matter what
112604         appears before it.  Update documentation.
112605         * tests/test-update-copyright.sh: Test that.
112607 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
112609         update-copyright: clean up code a little
112610         * build-aux/update-copyright: Append "_re" to the name of any
112611         variable holding a regular expression.
112612         Replace "old" and "new" with "stmt" in variable names.
112613         Do not accept 2-digit UPDATE_COPYRIGHT_YEAR, which was not
112614         handled correctly.
112615         Format code more consistently.
112617 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
112619         update-copyright-tests: improve portability
112620         * tests/test-update-copyright.sh: Use cmp if diff cannot handle
112621         -u or /dev/null.  Suggested by Jim Meyering and Eric Blake.
112623 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
112625         update-copyright: support @copyright{} and &copy;
112626         * build-aux/update-copyright: Implement and document.
112627         * tests/test-update-copyright.sh: Test.
112629 2009-08-04  Jim Meyering  <meyering@redhat.com>
112631         update-copyright-tests: correctly test EOL=\r\n handling
112632         * tests/test-update-copyright.sh: Put \r at the end of some lines
112633         for the dos-eol tests.  Based on a patch by Joel E. Denny.
112635         maint.mk: make update-copyright exclusion list more configurable
112636         * top/maint.mk (update-copyright): Default to excluding COPYING,
112637         but allow an override, in case someone does want to update that file.
112639         maint.mk: don't update copyright date in COPYING
112640         * top/maint.mk (update-copyright): Exclude COPYING.
112642         maint.mk: add a copyright-updating rule
112643         * top/maint.mk (update-copyright): New rule.
112644         Derived from coreutils/Makefile.am.
112646         update-copyright: rename some variables
112647         * build-aux/update-copyright: Rename a few variables for clarity.
112648         Tweak syntax.  List Joel E. Denny as coauthor.
112650 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
112652         update-copyright: fix bug for 2-digit last year and add tests
112653         * build-aux/update-copyright: Fix bug.
112654         Use UPDATE_COPYRIGHT_YEAR from environment as current year if
112655         specified.
112656         * modules/update-copyright-tests: New
112657         * tests/test-update-copyright.sh: New.
112659 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
112661         update-copyright: handle leading tabs in line prefix
112662         * build-aux/update-copyright: Count leading tabs as 8 spaces
112663         when computing margin.  This helps with the formatting of
112664         ChangeLogs, for example.
112665         Fix documentation a little.
112667 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
112669         update-copyright: support EOL=\r\n
112670         * build-aux/update-copyright: Implement that.
112672 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
112674         update-copyright: automatically format copyright statements
112675         * build-aux/update-copyright: Implement that.
112676         Also, be a little more predictable and safer by always failing
112677         when the full copyright format is not perfectly recognized as an
112678         unbroken whole.  Discussed at
112679         <http://lists.gnu.org/r/bug-gnulib/2009-07/msg00131.html>.
112680         Rewrite documentation.
112682 2009-08-03  Bruno Haible  <bruno@clisp.org>
112684         * m4/iconv.m4 (AM_ICONV): Fix displayed message with autoconf-2.64.
112686 2009-08-02  Bruno Haible  <bruno@clisp.org>
112688         Tests for module 'uname'.
112689         * modules/uname-tests: New file.
112690         * tests/test-uname.c: New file.
112692         New module 'uname'.
112693         * lib/uname.c: New file.
112694         * m4/uname.m4: New file.
112695         * modules/uname: New file.
112696         * doc/posix-functions/uname.texi: Mention the new module.
112698 2009-08-02  Bruno Haible  <bruno@clisp.org>
112700         Tests for module 'sys_utsname'.
112701         * modules/sys_utsname-tests: New file.
112702         * tests/test-sys_utsname.c: New file.
112704         New module 'sys_utsname'.
112705         * lib/sys_utsname.in.h: New file, based on glibc's <sys/utsname.h>.
112706         * m4/sys_utsname_h.m4: New file.
112707         * modules/sys_utsname: New file.
112708         * doc/posix-headers/sys_utsname.texi: Mention the new module.
112710 2009-08-02  Bruno Haible  <bruno@clisp.org>
112712         Implicitly initialize the sockets library.
112713         * lib/gethostname.c: Include sockets.h.
112714         (rpl_gethostname): Invoke gl_sockets_startup.
112715         * lib/socket.c: Include sockets.h.
112716         (rpl_socket): Invoke gl_sockets_startup.
112717         * modules/gethostname (Depends-on): Add sockets.
112718         * modules/socket (Depends-on): Likewise.
112719         * tests/test-poll.c: Don't include sockets.h.
112720         (main): Don't invoke gl_sockets_startup.
112721         * tests/test-select.c: Don't include sockets.h.
112722         (main): Don't invoke gl_sockets_startup.
112724 2009-08-02  Bruno Haible  <bruno@clisp.org>
112726         Allow multiple calls to gl_sockets_startup.
112727         * lib/sockets.c (initialized_sockets_version): New variable.
112728         (gl_sockets_startup): Do nothing if already called for this or a higher
112729         version.
112730         (gl_sockets_cleanup): Reset initialized_sockets_version.
112732 2009-08-03  Simon Josefsson  <simon@josefsson.org>
112734         * tests/test-argp-version-etc-1.sh: Use EXEEXT.  Don't fail on
112735         different project/version.
112737 2009-08-02  Paolo Bonzini  <bonzini@gnu.org>
112738             Bruno Haible  <bruno@clisp.org>
112740         Tests for module 'pipe-filter-gi'.
112741         * modules/pipe-filter-gi-tests: New file.
112742         * tests/test-pipe-filter-gi1.sh: New file.
112743         * tests/test-pipe-filter-gi1.c: New file.
112744         * tests/test-pipe-filter-gi2.sh: New file.
112745         * tests/test-pipe-filter-gi2-main.c: New file.
112746         * tests/test-pipe-filter-gi2-child.c: New file.
112748         New module 'pipe-filter-gi'.
112749         * lib/pipe-filter-gi.c: New file.
112750         * modules/pipe-filter-gi: New file.
112752 2009-08-02  Bruno Haible  <bruno@clisp.org>
112753             Paolo Bonzini  <bonzini@gnu.org>
112755         Tests for module 'pipe-filter-ii'.
112756         * modules/pipe-filter-ii-tests: New file.
112757         * tests/test-pipe-filter-ii1.sh: New file.
112758         * tests/test-pipe-filter-ii1.c: New file.
112759         * tests/test-pipe-filter-ii2.sh: New file.
112760         * tests/test-pipe-filter-ii2-main.c: New file.
112761         * tests/test-pipe-filter-ii2-child.c: New file.
112763         New module 'pipe-filter-ii'.
112764         * lib/pipe-filter.h: New file.
112765         * lib/pipe-filter-ii.c: New file.
112766         * lib/pipe-filter-aux.h: New file.
112767         * modules/pipe-filter-ii: New file.
112769 2009-08-02  Simon Josefsson  <simon@josefsson.org>
112771         * lib/gc-libgcrypt.c: Change copyright to FSF.
112772         * lib/gc-gnulib.c: Likewise.
112774 2009-08-02  Martin Lambers  <marlam@marlam.de>  (tiny change)
112776         * lib/gethostname.c: Include limits.h.
112778 2009-08-02  Simon Josefsson  <simon@josefsson.org>
112779             Bruno Haible  <bruno@clisp.org>
112781         Ensure HOST_NAME_MAX as part of the gethostname module.
112782         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): On native Windows platforms,
112783         define also HOST_NAME_MAX.
112784         * tests/test-gethostname.c: Include <limits.h>.
112785         (main): Check also HOST_NAME_MAX.
112786         * doc/posix-headers/limits.texi: Document the mingw problem.
112788 2009-08-02  Bruno Haible  <bruno@clisp.org>
112790         * lib/gethostname.c (gethostname): Fix handling of large len argument.
112791         Add comments.
112793 2009-03-31  Simon Josefsson  <simon@josefsson.org>
112795         * lib/gethostname.c: Add Windows wrapper.
112796         * m4/gethostname.m4: Look for gethostname in -lws2_32.
112797         * modules/gethostname: Depend on sys_socket & errno, for also
112798         added lib/w32sock.h.  Add GETHOSTNAME_LIB link directive.
112799         * modules/gethostname-tests: Link to @GETHOSTNAME_LIB@.
112801 2009-07-31  Jim Meyering  <meyering@redhat.com>
112803         getloadavg: fix symbol name in comment
112804         * lib/getloadavg.c: Correct a typo I introduced when adding
112805         comments to Matt's change: s/NLIST_POINTER/N_NAME_POINTER/.
112806         Matt Kraai spotted the problem.
112808 2009-07-29  Matt Kraai  <mkraai@beckman.com>
112810         getloadavg: check whether n_name is a pointer, for QNX 6.4.1
112811         * lib/getloadavg.c (getloadavg): Use the strcpy-into-nlist.n_name
112812         code also if ! defined N_NAME_POINTER.
112813         * m4/getloadavg.m4 (gl_GETLOADAVG): Add a link-test for N_NAME_POINTER.
112814         This is required on QNX 6.4.1, where /usr/include/nlist.h exists,
112815         but the n_name member is a 12-byte array.
112817 2009-07-29  Joel E. Denny  <jdenny@clemson.edu>
112819         update-copyright: generalize comment handling
112820         * build-aux/update-copyright: Handle copyright statements
112821         within more comment styles.
112822         Document usage.
112823         Report any file with an external copyright holder or parse failure.
112825 2009-07-29  Jim Meyering  <meyering@redhat.com>
112827         mktime: correct setting of REPLACE_MKTIME
112828         * m4/mktime.m4 (gl_FUNC_MKTIME): Set REPLACE_MKTIME=0, when required.
112830         update-copyright: new module
112831         * modules/update-copyright: New file.
112832         * build-aux/update-copyright: New file.
112833         * MODULES.html.sh (maint+release support): Add update-copyright.
112835 2009-07-27  Bruno Haible  <bruno@clisp.org>
112837         Fix compilation error when <ctime> is used and mktime is replaced.
112838         * lib/time.in.h (mktime): New declaration.
112839         * m4/mktime.m4 (gl_FUNC_MKTIME): Require gl_HEADER_TIME_H_DEFAULTS. Set
112840         REPLACE_MKTIME instead of defining mktime in config.h.
112841         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize REPLACE_MKTIME.
112842         * modules/time (Makefile.am): Substitute REPLACE_MKTIME.
112843         Reported by Ross McFarland <rwmcfa1@neces.com>.
112845 2009-07-27  Bruno Haible  <bruno@clisp.org>
112847         * lib/math.in.h (cosl, logl, sinl): Undefine before declaring it.
112848         Reported by Matt Kraai <mkraai@beckman.com>.
112850 2009-07-25  Jim Meyering  <meyering@redhat.com>
112852         maint.mk: avoid warnings about missing files
112853         * top/maint.mk (PREV_VERSION): Suppress stderr, to hide a
112854         diagnostic when .prev-version does not exist.
112855         (_cfg_mk): Define, so it can be empty when cfg.mk does not exist.
112856         (syntax-check-rules): Use $(_cfg_mk) to avoid a diagnostic about
112857         nonexistent cfg.mk.
112858         Suggestions from Simon Josefsson.
112860 2009-07-25  Bruno Haible  <bruno@clisp.org>
112862         * lib/math.in.h (cosl, logl, sinl): Don't declare if they are already
112863         defined as macros. Needed on QNX 6.4.1.
112864         Reported by Matt Kraai <mkraai@beckman.com>.
112866 2009-07-23  Jim Meyering  <meyering@redhat.com>
112868         maint.mk: invoke "make dist" with a working value of XZ_OPT
112869         * top/maint.mk (vc-dist): Use no "-" in the value of XZ_OPT.
112871 2009-07-22  Matt Kraai  <mkraai@beckman.com>  (tiny change)
112873         Make fseeko.c compile on QNX.
112874         * lib/fseeko.c (rpl_fseeko): Use the numerical value of _MWRITE.
112876 2009-07-22  Peter Simons  <simons@cryp.to>
112878         C++: wrap md2,md5,sha1,etc. function declarations in extern "C" scope
112879         * lib/md2.h [__cplusplus]: Wrap declarations in extern "C" scope.
112880         * lib/md4.h: Likewise.
112881         * lib/md5.h: Likewise.
112882         * lib/sha1.h: Likewise.
112883         * lib/sha256.h: Likewise.
112884         * lib/sha512.h: Likewise.
112886         tests-sha1: don't assign literal string to 'char *' variable
112887         * tests/test-sha1.c (main): Declare locals with "const" to match
112888         attributes of the right hand side.
112890 2009-07-21  Eric Blake  <ebb9@byu.net>
112892         dup2: fix more mingw problems
112893         * lib/dup2.c (rpl_dup2) [_WIN32]: Avoid hanging when duplicating
112894         fd to itself.
112895         * doc/posix-functions/dup2.texi (dup2): Document the bug.
112896         * lib/unistd.in.h (dup2) [REPLACE_FCHDIR]: Avoid name collision.
112897         * lib/fchdir.c (dup2): Manage preprocessor macros correctly.
112898         (rpl_dup2_fchdir): Rename from rpl_dup2, and let dup2 module take
112899         care of mingw bugs.
112901 2009-07-21  Jim Meyering  <meyering@redhat.com>
112903         vc-list-files: avoid failure when /bin/sh is dash
112904         * build-aux/vc-list-files: Avoid a shell portability problem with dash.
112905         On some Debian based systems, /bin/sh is a symlink to dash, and running
112906         this command would omit the "/" following each 'tests' prefix:
112907           dash -x build-aux/vc-list-files -C . tests
112908         That is because bash and dash work differently:
112909           $ for i in bash dash; do $i -c 'a=odd; a=ok b=$a; echo '$i' $b'; done
112910           bash ok
112911           dash odd
112913 2009-07-21  Eric Blake  <ebb9@byu.net>
112915         dup2-tests: test previous patch
112916         * modules/dup2-tests: New file.
112917         * tests/test-dup2.c: Likewise.
112918         * tests/test-open.c (main): Avoid unspecified behavior.
112919         * tests/test-pipe.c (child_main): Use dup2 semantics to simplify
112920         test.
112922         dup2: work around mingw and cygwin 1.5 bug
112923         * m4/dup2.m4 (gl_FUNC_DUP2): Detect mingw bug.
112924         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
112925         * modules/unistd (Makefile.am): Substitute it.
112926         * lib/unistd.in.h (dup2): Declare the replacement.
112927         * lib/dup2.c (dup2) [REPLACE_DUP2]: Implement it.
112928         * doc/posix-functions/dup2.texi (dup2): Document the bugs.
112929         * lib/fchdir.c (rpl_dup2): Don't collide with mingw replacement.
112930         * modules/execute (Depends-on): Add dup2.
112931         * modules/fseterr (Depends-on): Likewise.
112932         * modules/pipe (Depends-on): Likewise.
112933         * modules/posix_spawn-internal (Depends-on): Likewise.
112935 2009-07-21  Bruno Haible  <bruno@clisp.org>
112937         * modules/.gitattributes: New file.
112939 2009-07-20  Bruno Haible  <bruno@clisp.org>
112941         * tests/test-pipe.c (BACKUP_STDERR_FILENO): New macro.
112942         (main): Use it.
112944 2009-07-20  Eric Blake  <ebb9@byu.net>
112946         test-pipe: make a bit more robust.
112947         * tests/test-pipe.c (myerr): Allow error messages regardless of
112948         what we do to stderr.
112949         (test_pipe): Rearrange to avoid deadlock.
112950         (child_main): Try a larger read, to ensure we avoided deadlock.
112951         * lib/pipe.c (create_pipe) [_WIN32]: Fix comment.
112952         * lib/pipe.h (create_pipe_bidi): Document potential for deadlock
112953         if misused.
112955 2009-07-19  Jim Meyering  <meyering@redhat.com>
112957         fts: avoid false-positive cycle-detection
112958         * lib/fts.c (fts_read): Reinitialize cycle-detection data structures
112959         for each new command line argument.
112961 2009-07-19  Bruno Haible  <bruno@clisp.org>
112963         Fix build error on mingw with the modules sys_select and unistd.
112964         * modules/acl-tests (Depends-on): Add close.
112965         * modules/binary-io-tests (Depends-on): Likewise.
112966         * modules/closein-tests (Depends-on): Likewise.
112967         * modules/flock-tests (Depends-on): Likewise.
112968         * modules/fsync-tests (Depends-on): Likewise.
112969         * modules/lseek-tests (Depends-on): Likewise.
112970         * modules/pipe-tests (Depends-on): Likewise.
112971         * modules/posix_spawn-tests (Depends-on): Likewise.
112972         * modules/posix_spawnp-tests (Depends-on): Likewise.
112973         * modules/stat-time-tests (Depends-on): Likewise.
112974         * modules/yesno-tests (Depends-on): Likewise.
112976 2009-07-19  Bruno Haible  <bruno@clisp.org>
112978         Unify conditionals.
112979         * lib/pipe.h: Detect native Win32 by looking at _WIN32 and __WIN32__
112980         macros, not at the compiler macros.
112981         * lib/pipe.c: Likewise.
112982         * lib/execute.c: Likewise.
112983         * lib/spawni.c: Likewise.
112985 2009-07-19  Bruno Haible  <bruno@clisp.org>
112987         Fix handling of closed stdin/stdout/stderr on mingw.
112988         * lib/w32spawn.h: Include unistd.h.
112989         (dup_noinherit): Return -1 if the old handle is invalid. Allocate new
112990         file descriptor with O_NOINHERIT flag.
112991         (fd_safer_noinherit): New function, based on fd-safer.c.
112992         (dup_safer_noinherit): New function, based on dup-safer.c.
112993         (undup_safer_noinherit): New function.
112994         * lib/execute.c (execute) [WIN32]: Use dup_safer_noinherit instead of
112995         dup_noinherit. Use undup_safer_noinherit instead of dup2 and close.
112996         * lib/pipe.c (create_pipe) [WIN32]: Likewise. Use fd_safer_noinherit
112997         instead of fd_safer.
112998         * tests/test-pipe.c: Include <windows.h>.
112999         (child_main) [WIN32]: Test the handle of STDERR_FILENO, not its close()
113000         result.
113002         * tests/test-pipe.c (child_main, parent_main): New functions, extracted
113003         from main.
113004         (test_pipe): Pass an extra argument for disambiguation.
113005         (main): Invoke parent_main or child_main.
113007         * tests/test-pipe.c (test_pipe): Pass slave_process = true argument
113008         consistently.
113010 2009-07-18  Eric Blake  <ebb9@byu.net>
113012         test-pipe: fix mingw build
113013         * tests/test-pipe.c (main): Avoid fcntl on mingw.
113015 2009-07-18  Bruno Haible  <bruno@clisp.org>
113017         * modules/pipe-tests (Makefile.am): Fix typo.
113019 2009-07-18  Eric Blake  <ebb9@byu.net>
113021         error: fix mingw build
113022         * lib/error.c (error, error_at_line): Avoid fcntl on mingw.
113023         Reported by Bruno Haible.
113025         error: avoid undefined use of stdout
113026         * lib/error.c (error, error_at_line): Check that fd 1 is open
113027         before flushing stdout.  Avoids a crash on cygwin when libsigsegv
113028         is handling faults and the close_stdout module wants to report the
113029         detection of closed stdout as an error.
113031 2009-07-17  Eric Blake  <ebb9@byu.net>
113033         pipe: be robust in face of closed fds
113034         * lib/pipe.c (create_pipe): Closed standard descriptors in parent
113035         should cause child to misbehave.
113036         * modules/pipe-tests: New module.
113037         * tests/test-pipe.c: New file.
113038         * tests/test-pipe.sh: New file.
113039         Reported by Akim Demaille.
113041 2009-07-14  Bruno Haible  <bruno@clisp.org>
113043         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Guess it works on glibc systems.
113044         Reported by anonymous kc.
113046 2009-07-07  Jim Meyering  <meyering@redhat.com>
113048         maint.mk: don't look for translatable strings in *.m4 or *.mk
113049         * top/maint.mk (sc_po_check): Skip *.m4 and *.mk files,
113050         when searching for translatable strings.
113052 2009-07-05  Jim Meyering  <meyering@redhat.com>
113054         remove superfluous parentheses in STREQ definition
113055         * tests/test-argv-iter.c (STREQ): Remove redundant parentheses.
113056         * lib/getugroups.c (STREQ): Likewise.
113057         * lib/fnmatch.c (STREQ): Likewise.
113058         Spotted by Bruno Haible.
113060 2009-07-04  Jim Meyering  <meyering@redhat.com>
113062         argv-iter: new module
113063         * MODULES.html.sh: Add argv-iter.
113064         * lib/argv-iter.c, lib/argv-iter.h: New files.
113065         * modules/argv-iter: New file.
113066         * modules/argv-iter-tests: New file.
113067         * tests/test-argv-iter.c: Test it.
113069 2009-07-04  Bruno Haible  <bruno@clisp.org>
113071         Fix assertion.
113072         * lib/git-merge-changelog.c (compute_mapping): In the case where file1
113073         contains more exact copies of a given entry than file2, leave the extra
113074         copies unpaired rather than aborting.
113075         Reported by Eric Blake.
113077 2009-07-02  Bruno Haible  <bruno@clisp.org>
113079         Speedup git-merge-changelog for git cherry-pick.
113080         * lib/git-merge-changelog.c (struct entries_mapping): New type.
113081         (entries_mapping_get): New function, extracted from compute_mapping.
113082         (entries_mapping_reverse_get): New function.
113083         (compute_mapping): Add a 'full' argument. Return the result in a
113084         'struct entries_mapping'.
113085         (main): Update. Access the mappings through entries_mapping_get.
113086         Reported by Eric Blake.
113088 2009-07-02  Bruno Haible  <bruno@clisp.org>
113090         * lib/git-merge-changelog.c (compute_mapping): Fix determination of
113091         best_i.
113093 2009-07-02  Bruno Haible  <bruno@clisp.org>
113095         Speed up approximate search for matching ChangeLog entries.
113096         * lib/git-merge-changelog.c (entry_fstrcmp): Add a lower_bound
113097         argument. Call fstrcmp_bounded instead of fstrcmp.
113098         (compute_mapping, try_split_merged_entry, main): Update callers.
113100 2009-07-02  Bruno Haible  <bruno@clisp.org>
113102         * lib/git-merge-changelog.c (main): Add comment about git cherry-pick.
113104 2009-06-30  Bruno Haible  <bruno@clisp.org>
113106         Reduce the number of uc_is_cased calls.
113107         * lib/unicase.h (casing_suffix_context_t): Add
113108         'first_char_except_ignorable' field.
113109         * lib/unicase/context.h (SCC_FINAL_SIGMA_MASK): Remove macro.
113110         (SCC_MORE_ABOVE_MASK, SCC_BEFORE_DOT_MASK): Update.
113111         * lib/unicase/empty-suffix-context.c (unicase_empty_suffix_context):
113112         Update initializer.
113113         * lib/unicase/u-casemap.h (FUNC): Don't invoke uc_is_cased on
113114         case-ignorable characters.
113115         * lib/unicase/u-ct-totitle.h (FUNC): Likewise.
113116         * lib/unicase/u-suffix-context.h (FUNC2): Don't call uc_is_cased here.
113117         * modules/unicase/u8-suffix-context (Depends-on): Remove unicase/cased.
113118         * modules/unicase/u16-suffix-context (Depends-on): Likewise.
113119         * modules/unicase/u32-suffix-context (Depends-on): Likewise.
113121 2009-06-30  Bruno Haible  <bruno@clisp.org>
113123         Tests for module 'unicase/ignorable'.
113124         * modules/unicase/ignorable-tests: New file.
113125         * tests/unicase/test-ignorable.c: New file, generated by
113126         gen-uni-tables.
113128         Tests for module 'unicase/cased'.
113129         * modules/unicase/cased-tests: New file.
113130         * tests/unicase/test-cased.c: New file, generated by gen-uni-tables.
113131         * tests/unicase/test-predicate-part1.h: New file, derived from
113132         tests/unictype/test-predicate-part1.h.
113133         * tests/unicase/test-predicate-part2.h: New file, same as
113134         tests/unictype/test-predicate-part2.h.
113136         Fix evaluation of "Before C" condition of FINAL_SIGMA.
113137         * lib/gen-uni-tables.c (is_cased, is_case_ignorable): New functions.
113138         (output_casing_properties): New function.
113139         (main): Call it.
113140         * lib/unicase/cased.h: New file, generated by gen-uni-tables.
113141         * lib/unicase/cased.c: Include unictype/bitmap.h.
113142         (uc_is_cased): Define through a bitmap lookup.
113143         * lib/unicase/ignorable.h: New file, generated by gen-uni-tables.
113144         * lib/unicase/ignorable.c: Include unictype/bitmap.h.
113145         (uc_is_case_ignorable): Define through a bitmap lookup.
113146         * modules/unicase/cased (Files): Add lib/unicase/cased.h,
113147         lib/unictype/bitmap.h.
113148         (Depends-on): Add inline. Clean up.
113149         * modules/unicase/ignorable (Files): Add lib/unicase/ignorable.h,
113150         lib/unictype/bitmap.h.
113151         (Depends-on): Add inline. Clean up.
113152         * tests/unicase/test-u8-tolower.c (main): Add more tests of FINAL_SIGMA
113153         recognition.
113154         * tests/unicase/test-u16-tolower.c (main): Likewise.
113155         * tests/unicase/test-u32-tolower.c (main): Likewise.
113157 2009-06-30  Bruno Haible  <bruno@clisp.org>
113159         * lib/unicase/u8-casemap.c: Don't include uniwbrk.h.
113160         * lib/unicase/u16-casemap.c: Likewise.
113161         * lib/unicase/u32-casemap.c: Likewise.
113163 2009-06-29  Bruno Haible  <bruno@clisp.org>
113165         Define u32_casefold as a wrapper around u32_ct_casefold.
113166         * lib/unicase/u32-casefold.c: Update.
113167         * modules/unicase/u32-casefold (Depends-on): Add
113168         unicase/u32-ct-casefold, unicase/empty-prefix-context,
113169         unicase/empty-suffix-context. Clean up.
113171         Define u16_casefold as a wrapper around u16_ct_casefold.
113172         * lib/unicase/u16-casefold.c: Update.
113173         * modules/unicase/u16-casefold (Depends-on): Add
113174         unicase/u16-ct-casefold, unicase/empty-prefix-context,
113175         unicase/empty-suffix-context. Clean up.
113177         Define u8_casefold as a wrapper around u8_ct_casefold.
113178         * lib/unicase/u-casefold.h (FUNC): Delegate to U_CT_CASEFOLD.
113179         * lib/unicase/u8-casefold.c: Update.
113180         * modules/unicase/u8-casefold (Depends-on): Add unicase/u8-ct-casefold,
113181         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
113183         Define u32_totitle as a wrapper around u32_ct_totitle.
113184         * lib/unicase/u32-totitle.c: Update.
113185         * modules/unicase/u32-totitle (Depends-on): Add unicase/u32-ct-totitle,
113186         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
113188         Define u16_totitle as a wrapper around u16_ct_totitle.
113189         * lib/unicase/u16-totitle.c: Update.
113190         * modules/unicase/u16-totitle (Depends-on): Add unicase/u16-ct-totitle,
113191         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
113193         Define u8_totitle as a wrapper around u8_ct_totitle.
113194         * lib/unicase/u-totitle.h (is_cased, is_case_ignorable): Remove
113195         functions.
113196         (FUNC): Delegate to U_CT_TOTITLE.
113197         * lib/unicase/u8-totitle.c: Update.
113198         * modules/unicase/u8-totitle (Depends-on): Add unicase/u8-ct-totitle,
113199         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
113201         * lib/unicase/u32-tolower.c (u32_tolower): Update u32_casemap
113202         invocation.
113203         * modules/unicase/u32-tolower (Depends-on): Add
113204         unicase/empty-prefix-context, unicase/empty-suffix-context.
113206         * lib/unicase/u16-tolower.c (u16_tolower): Update u16_casemap
113207         invocation.
113208         * modules/unicase/u16-tolower (Depends-on): Add
113209         unicase/empty-prefix-context, unicase/empty-suffix-context.
113211         * lib/unicase/u8-tolower.c (u8_tolower): Update u8_casemap invocation.
113212         * modules/unicase/u8-tolower (Depends-on): Add
113213         unicase/empty-prefix-context, unicase/empty-suffix-context.
113215         * lib/unicase/u32-toupper.c (u32_toupper): Update u32_casemap
113216         invocation.
113217         * modules/unicase/u32-toupper (Depends-on): Add
113218         unicase/empty-prefix-context, unicase/empty-suffix-context.
113220         * lib/unicase/u16-toupper.c (u16_toupper): Update u16_casemap
113221         invocation.
113222         * modules/unicase/u16-toupper (Depends-on): Add
113223         unicase/empty-prefix-context, unicase/empty-suffix-context.
113225         * lib/unicase/u8-toupper.c (u8_toupper): Update u8_casemap invocation.
113226         * modules/unicase/u8-toupper (Depends-on): Add
113227         unicase/empty-prefix-context, unicase/empty-suffix-context.
113229         New module 'unicase/u32-ct-casefold'.
113230         * lib/unicase/u32-ct-casefold.c: New file.
113231         * modules/unicase/u32-ct-casefold: New file.
113233         New module 'unicase/u16-ct-casefold'.
113234         * lib/unicase/u16-ct-casefold.c: New file.
113235         * modules/unicase/u16-ct-casefold: New file.
113237         New module 'unicase/u8-ct-casefold'.
113238         * lib/unicase/u8-ct-casefold.c: New file.
113239         * lib/unicase/u-ct-casefold.h: New file, derived from
113240         lib/unicase/u-casefold.h.
113241         * modules/unicase/u8-ct-casefold: New file.
113243         New module 'unicase/u32-ct-totitle'.
113244         * lib/unicase/u32-ct-totitle.c: New file.
113245         * modules/unicase/u32-ct-totitle: New file.
113247         New module 'unicase/u16-ct-totitle'.
113248         * lib/unicase/u16-ct-totitle.c: New file.
113249         * modules/unicase/u16-ct-totitle: New file.
113251         New module 'unicase/u8-ct-totitle'.
113252         * lib/unicase/u8-ct-totitle.c: New file.
113253         * lib/unicase/u-ct-totitle.h: New file, derived from
113254         lib/unicase/u-totitle.h.
113255         * modules/unicase/u8-ct-totitle: New file.
113257         New module 'unicase/u32-ct-tolower'.
113258         * lib/unicase/u32-ct-tolower.c: New file.
113259         * modules/unicase/u32-ct-tolower: New file.
113261         New module 'unicase/u16-ct-tolower'.
113262         * lib/unicase/u16-ct-tolower.c: New file.
113263         * modules/unicase/u16-ct-tolower: New file.
113265         New module 'unicase/u8-ct-tolower'.
113266         * lib/unicase/u8-ct-tolower.c: New file.
113267         * modules/unicase/u8-ct-tolower: New file.
113269         New module 'unicase/u32-ct-toupper'.
113270         * lib/unicase/u32-ct-toupper.c: New file.
113271         * modules/unicase/u32-ct-toupper: New file.
113273         New module 'unicase/u16-ct-toupper'.
113274         * lib/unicase/u16-ct-toupper.c: New file.
113275         * modules/unicase/u16-ct-toupper: New file.
113277         New module 'unicase/u8-ct-toupper'.
113278         * lib/unicase/u8-ct-toupper.c: New file.
113279         * modules/unicase/u8-ct-toupper: New file.
113281         Add context arguments to u*_casemap functions.
113282         * lib/unicase/unicasemap.h: Include unicase.h.
113283         (u8_casemap, u16_casemap, u32_casemap): Add prefix_context and
113284         suffix_context arguments.
113285         * lib/unicase/u-casemap.h (is_cased, is_case_ignorable): Remove
113286         functions.
113287         (FUNC): Add prefix_context and suffix_context arguments. Use
113288         uc_is_cased and uc_is_case_ignorable.
113289         * lib/unicase/u8-casemap.c: Include caseprop.h and context.h.
113290         * lib/unicase/u16-casemap.c: Likewise.
113291         * lib/unicase/u32-casemap.c: Likewise.
113292         * modules/unicase/u8-casemap (Files): Add lib/unicase/context.h.
113293         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
113294         * modules/unicase/u16-casemap (Files): Add lib/unicase/context.h.
113295         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
113296         * modules/unicase/u32-casemap (Files): Add lib/unicase/context.h.
113297         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
113299         New module 'unicase/u32-suffix-context'.
113300         * lib/unicase/u32-suffix-context.c: New file.
113301         * modules/unicase/u32-suffix-context: New file.
113303         New module 'unicase/u16-suffix-context'.
113304         * lib/unicase/u16-suffix-context.c: New file.
113305         * modules/unicase/u16-suffix-context: New file.
113307         New module 'unicase/u8-suffix-context'.
113308         * lib/unicase/u8-suffix-context.c: New file.
113309         * lib/unicase/u-suffix-context.h: New file.
113310         * modules/unicase/u8-suffix-context: New file.
113312         New module 'unicase/empty-suffix-context'.
113313         * lib/unicase/empty-suffix-context.c: New file.
113314         * modules/unicase/empty-suffix-context: New file.
113316         New module 'unicase/u32-prefix-context'.
113317         * lib/unicase/u32-prefix-context.c: New file.
113318         * modules/unicase/u32-prefix-context: New file.
113320         New module 'unicase/u16-prefix-context'.
113321         * lib/unicase/u16-prefix-context.c: New file.
113322         * modules/unicase/u16-prefix-context: New file.
113324         New module 'unicase/u8-prefix-context'.
113325         * lib/unicase/u8-prefix-context.c: New file.
113326         * lib/unicase/u-prefix-context.h: New file.
113327         * lib/unicase/context.h: New file.
113328         * modules/unicase/u8-prefix-context: New file.
113330         New module 'unicase/empty-prefix-context'.
113331         * lib/unicase/empty-prefix-context.c: New file.
113332         * modules/unicase/empty-prefix-context: New file.
113334         New module 'unicase/ignorable'.
113335         * lib/unicase/ignorable.c: New file.
113336         * modules/unicase/ignorable: New file.
113338         New module 'unicase/cased'.
113339         * lib/unicase/caseprop.h: New file.
113340         * lib/unicase/cased.c: New file.
113341         * modules/unicase/cased: New file.
113343         New functions for case mapping of substrings.
113344         * lib/unicase.h (casing_prefix_context_t): New type.
113345         (unicase_empty_prefix_context): New variable.
113346         (u8_casing_prefix_context, u16_casing_prefix_context,
113347         u32_casing_prefix_context, u8_casing_prefixes_context,
113348         u16_casing_prefixes_context, u32_casing_prefixes_context): New
113349         declarations.
113350         (casing_suffix_context_t): New type.
113351         (unicase_empty_suffix_context): New variable.
113352         (u8_casing_suffix_context, u16_casing_suffix_context,
113353         u32_casing_suffix_context, u8_casing_suffixes_context,
113354         u16_casing_suffixes_context, u32_casing_suffixes_context,
113355         u8_ct_toupper, u16_ct_toupper, u32_ct_toupper, u8_ct_tolower,
113356         u16_ct_tolower, u32_ct_tolower, u8_ct_totitle, u16_ct_totitle,
113357         u32_ct_totitle, u8_ct_casefold, u16_ct_casefold, u32_ct_casefold): New
113358         declarations.
113360 2009-06-28  Jim Meyering  <meyering@redhat.com>
113362         boostrap: indent only with spaces
113363         * build-aux/bootstrap: Indent only with spaces, never TABs.
113365         bootstrap: split long lines
113366         * build-aux/bootstrap: Keep line length < 80.
113368         bootstrap: sync from coreutils
113369         * build-aux/bootstrap: Honor variables like $ACLOCAL, etc.,
113370         just as autoreconf does.  Verify a list of prerequisite
113371         package-name,version-number pairs if defined in bootstrap.conf.
113372         Refer to README-prereq, if prerequisites are not satisfied.
113374 2009-06-27  Eric Blake  <ebb9@byu.net>
113376         tests: add test for bogus NULL definition
113377         * tests/test-stdio.c: Ensure POSIX 2008 requirement on NULL.
113378         * tests/test-stdlib.c: Likewise.
113379         * tests/test-string.c: Likewise.
113380         * tests/test-locale.c: Likewise.
113381         * tests/test-unistd.c: Likewise.
113382         * modules/stdio-tests (Depends-on): Add verify.
113383         * modules/stdlib-tests (Depends-on): Likewise.
113384         * modules/string-tests (Depends-on): Likewise.
113385         * modules/locale-tests (Depends-on): Likewise.
113386         * modules/unistd-tests (Depends-on): Likewise.
113388 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
113390         * m4/selinux-context-h (gl_HEADERS_SELINUX_CONTEXT_H): Remove
113391         self-explaining comment.
113392         * m4/selinux-selinux-h: Update serial.
113393         (gl_LIBSELINUX): New macro, adding a warning for missing development
113394         packages to code extracted from...
113395         (gl_HEADERS_SELINUX_SELINUX_H): ... this one.  Require gl_LIBSELINUX.
113396         Add warning for missing development packages here, too.
113398 2009-06-26  Paolo Bonzini  <bonzini@gnu.org>
113400         * build-aux/bootstrap: Do not use GIT_CONFIG_LOCAL.
113402 2009-06-25  Eric Blake  <ebb9@byu.net>
113404         version-etc: fix regression
113405         * lib/version-etc.h (ATTRIBUTE_SENTINEL): Define for new enough
113406         gcc.
113407         (version_etc): Use it, to catch bugs with trailing NULL.
113408         * lib/version-etc.c (version_etc_arn): Delete unused argument.
113409         (version_etc_va): Fix logic bug.
113410         * modules/version-etc-tests: Add test.
113411         * tests/test-version-etc.c: New file.
113412         * tests/test-version-etc.sh: Likewise.
113414 2009-06-25  Sam Steingold  <sds@gnu.org>
113416         * mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): Include <stdlib.h>, for the
113417         mbtowc declaration.
113419 2009-06-25  Eric Blake  <ebb9@byu.net>
113421         fpurge: migrate into <stdio.h>
113422         * lib/fpurge.h: Delete...
113423         * lib/stdio.in.h (fpurge): ...and declare here, instead.
113424         * lib/fpurge.c (fpurge): Change declaring header.
113425         * modules/fpurge (Files): Drop deleted file.
113426         (Depends-on): Add stdio.
113427         (configure.ac): Set witness.
113428         * modules/stdio (Makefile.am): Support fpurge macros.
113429         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
113430         * m4/fpurge.m4 (gl_FUNC_FPURGE): Set appropriate variables.
113431         * lib/fflush.c: Update client.
113432         * tests/test-fpurge.c: Likewise.
113433         * NEWS: Mention the change.
113435 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
113437         * lib/argp-version-etc.c (program_authors): Add const
113438         qualifier.
113439         * lib/version-etc.c: Fix typos in the comments.
113440         * modules/argp-version-etc: Depends on version-etc.
113442 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
113444         argp-version-etc: new module.
113446         * lib/argp-version-etc.c: New file.
113447         * lib/argp-version-etc.h: New file.
113448         * modules/argp-version-etc: New file.
113449         * modules/argp-version-etc-tests: New file.
113450         * tests/test-argp-version-etc.c: New test.
113451         * tests/test-argp-version-etc-1.sh: New test.
113453 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
113455         Provide additional interfaces and documentation for version-etc
113456         module.
113458         * lib/version-etc.c (version_etc_arn, version_etc_ar): New
113459         interfaces.
113460         * lib/version-etc.h (version_etc_arn, version_etc_ar): New
113461         prototypes.
113463 2009-06-24  Bruno Haible  <bruno@clisp.org>
113465         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Fix description of
113466         HAVE_LIB${NAME} macro.
113467         Reported by Sam Steingold <sds@gnu.org>.
113469 2009-06-23  Simon Josefsson  <simon@josefsson.org>
113471         * modules/hash-tests (test_hash_LDADD): Link to libintl when
113472         needed.
113474 2009-06-21  Bruno Haible  <bruno@clisp.org>
113476         Make two consecutive identical invocations of AC_LIB_HAVE_LINKFLAGS
113477         work.
113478         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Reset HAVE_LIB${NAME}
113479         together with LIB${NAME}, LTLIB${NAME}.
113480         Reported by Sam Steingold <sds@gnu.org>.
113482 2009-06-20  Jim Meyering  <meyering@redhat.com>
113484         tests: make sc_require_test_exit_idiom more generic
113485         * top/maint.mk (Exit_witness_file): New overridable variable.
113486         (sc_require_test_exit_idiom): Don't hard-code tests/test-lib.sh.
113487         Relax test for /^Exit \$fail$$/ to just /^Exit ./.
113489 2009-06-19  Jim Meyering  <meyering@redhat.com>
113491         hash: reverse order of src/dst parameters in an internal interface
113492         * lib/hash.c (transfer_entries): Reverse order of parameters to
113493         put DST before SRC.  Adjust callers.
113495         tests: test-hash: avoid wholesale duplication
113496         * tests/test-hash.c (main): Don't copy/paste a 60-line loop.
113497         Instead, use a loop and add a single conditional.
113499         tests: test-hash: allow seed selection via a command line argument
113500         * tests/test-hash.c (get_seed): New function.
113501         (main): Use it.
113503 2009-06-19  Eric Blake  <ebb9@byu.net>
113505         hash: avoid memory leak on allocation failure
113506         * lib/hash.c: (hash_rehash): Avoid memory leak on allocation
113507         failure.  Factor repeated algorithm...
113508         (transfer_entries): ...into new helper routine.
113509         (hash_delete): React to hash_rehash return value.
113511         hash: reduce memory pressure in hash_rehash no-op case
113512         * lib/hash.c (next_prime): Avoid overflow.
113513         (hash_initialize): Factor bucket size computation...
113514         (compute_bucket_size): ...into new helper function.
113515         (hash_rehash): Use new function and open coding to reduce memory
113516         pressure, and avoid a memory leak in USE_OBSTACK code.
113517         Reported by Jim Meyering.
113519 2009-06-18  Eric Blake  <ebb9@byu.net>
113521         hash: make rotation more obvious
113522         * modules/hash (Depends-on): Add bitrotate and stdint.
113523         * lib/bitrotate.h (rotl_sz, rotr_sz): New functions.
113524         * lib/hash.c (headers): Drop limits.h.  Add stdint.h.
113525         (SIZE_MAX): Rely on headers for definition.
113526         (hash_string) [USE_DIFF_HASH]: Use rotl_sz.
113527         (raw_hasher): Use rotr_sz.
113528         Suggested by Jim Meyering.
113530         hash: fix memory leak in last patch
113531         * lib/hash.c (hash_rehash): Avoid memory leak.
113533         hash: avoid no-op rehashing
113534         * lib/hash.c (hash_rehash): Recognize useless rehash attempts.
113536         hash: provide default callback functions
113537         * lib/hash.c (raw_hasher, raw_comparator): New functions.
113538         (hash_initialize): Use them as defaults.
113539         * tests/test-hash.c (main): Test this.
113541         hash: minor optimization
113542         * lib/hash.c (hash_lookup, hash_find_entry): Avoid function call
113543         when possible.
113544         (hash_initialize): Document this promise.
113545         (hash_do_for_each, hash_clear, hash_free): Use C89 syntax.
113546         * tests/test-hash.c (hash_compare_strings): Test this.
113548 2009-06-18  Bruno Haible  <bruno@clisp.org>
113550         * m4/strstr.m4 (gl_FUNC_STRSTR): Skip linear time test if strstr is
113551         going to be replaced anyway.
113553 2009-06-18  Bruno Haible  <bruno@clisp.org>
113555         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Invoke AC_LIBOBJ only
113556         in one place.
113557         (gl_FUNC_STRCASESTR): Skip linear time test if strcasestr is going to
113558         be replaced anyway.
113560 2009-06-18  Eric Blake  <ebb9@byu.net>
113562         hash: check for resize before insertion
113563         * lib/hash.c (hash_insert): Check whether bucket usage exceeds
113564         threshold before insertion, so that a pathological hash_rehash
113565         that fills every bucket can still trigger another rehash.
113567 2009-06-18  Jim Meyering  <meyering@redhat.com>
113569         hash-tests: add a loop around the small tests
113570         * tests/test-hash.c (main): Repeat small tests with selected
113571         small initial table sizes.
113573 2009-06-17  Eric Blake  <ebb9@byu.net>
113575         hash: minor cleanups
113576         * lib/hash.h (hash_entry): Make opaque, by moving...
113577         * lib/hash.c (hash_entry): ...here.
113578         (hash_insert): Clarify restrictions on what can be inserted.
113579         (hash_get_next): Clarify when it is safe to remove an element
113580         during traversal.
113581         (check_tuning): Skip verification when tuning is known safe.
113582         (hash_initialize): Clarify restrictions on tuning.
113584 2009-06-17  Jim Meyering  <jim@meyering.net>
113585         and Eric Blake  <ebb9@byu.net>
113587         hash-tests: new module
113588         * modules/hash-tests: New file.
113589         * tests/test-hash.c: New file.
113591 2009-06-17  Eric Blake  <ebb9@byu.net>
113593         strstr-simple: document new module
113594         * MODULES.html.sh: Document new module.
113596         strstr, strcasestr: replace on platforms with broken memchr
113597         * modules/strstr: Split into...
113598         * modules/strstr-simple: ...new module that does not care about
113599         performance, but does care about glibc bug.
113600         * m4/strstr.m4 (gl_FUNC_STRSTR): Split...
113601         (gl_FUNC_STRSTR_SIMPLE): ...into new macro, which replaces strstr
113602         if platform memchr is broken, per Debian bug 521737.
113603         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): React to broken
113604         memchr.
113605         * m4/memchr.m4 (gl_FUNC_MEMCHR): Only expand once.
113606         * doc/posix-functions/strstr.texi (strstr): Document the fix.
113607         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
113608         * modules/mountlist (Depends-on): Add strstr-simple.
113609         * modules/gen-uni-tables (Depends-on): Likewise.
113610         * modules/argz (Depends-on): Add strstr.
113612 2009-06-17  Bruno Haible  <bruno@clisp.org>
113614         * modules/posix_spawn-internal (Depends-on): Add errno.
113616 2009-06-17  Bruno Haible  <bruno@clisp.org>
113618         Define missing ESTALE on Interix 3.5.
113619         * lib/errno.in.h (ESTALE): Assign a value if missing.
113620         * lib/strerror.c (rpl_strerror): Handle missing ESTALE and ECANCELED.
113621         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Also test whether ESTALE is
113622         missing.
113623         * doc/posix-headers/errno.texi: Mention the Interix bug.
113624         Reported by Jay Krell <jay.krell@cornell.edu> via Eric Blake.
113626 2009-06-15  Eric Blake  <ebb9@byu.net>
113628         memchr, memchr2: add valgrind exception
113629         * lib/memchr.valgrind: New file.
113630         * lib/memchr2.valgrind: New file.
113631         * modules/memchr (Files): Distribute valgrind file.
113632         * modules/memchr2 (Files): Likewise.
113634         docs: memchr is no longer obsolete
113635         * MODULES.html.sh: Move memchr from obsolete to string.h section.
113636         * lib/string.in.h (memchr): Simplify logic.
113638 2009-06-14  Jim Meyering  <meyering@redhat.com>
113640         link-follow: fix the "checking..." message to not mention trailing slash
113641         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): This test has
113642         never considered trailing slashes.
113644 2009-06-14  Bruno Haible  <bruno@clisp.org>
113646         * m4/memchr.m4: Mention also the bug on IA-64.
113647         * doc/posix-functions/memchr.texi: Likewise.
113649 2009-06-12  Eric Blake  <ebb9@byu.net>
113651         memchr: detect broken x86_64 and alpha implementations
113652         * modules/memchr-tests (Depends-on): Move mmap detection...
113653         * modules/memchr (Depends-on): ...here.
113654         (configure.ac): Set indicator.
113655         * lib/string.in.h (memchr): Declare replacement.
113656         * modules/string (Makefile.am): Trigger replacement.
113657         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
113658         * m4/memchr.m4 (gl_FUNC_MEMCHR): Use mmap to detect platform
113659         bugs.
113660         * doc/posix-functions/memchr.texi (memchr): Document the bug.
113661         * modules/getpagesize (License): Relax license.
113663 2009-06-11  Bruno Haible  <bruno@clisp.org>
113665         * lib/idpriv.h: Add more references.
113667 2009-06-08  Bruno Haible  <bruno@clisp.org>
113669         Tests for module 'idpriv-droptemp'.
113670         * modules/idpriv-droptemp-tests: New file.
113671         * tests/test-idpriv-droptemp.sh: New file.
113672         * tests/test-idpriv-droptemp.su.sh: New file.
113673         * tests/test-idpriv-droptemp.c: New file.
113675         New module 'idpriv-droptemp'.
113676         * lib/idpriv-droptemp.c: New file.
113677         * modules/idpriv-droptemp: New file.
113679 2009-06-08  Bruno Haible  <bruno@clisp.org>
113681         Tests for module 'idpriv-drop'.
113682         * modules/idpriv-drop-tests: New file.
113683         * tests/test-idpriv-drop.sh: New file.
113684         * tests/test-idpriv-drop.su.sh: New file.
113685         * tests/test-idpriv-drop.c: New file.
113687         New module 'idpriv-drop'.
113688         * lib/idpriv.h: New file.
113689         * lib-idpriv-drop.c: New file.
113690         * m4/idpriv.m4: New file.
113691         * modules/idpriv-drop: New file.
113693 2009-06-08  Bruno Haible  <bruno@clisp.org>
113695         * modules/unistdio/u8-vasnprintf (Depends-on): Add memchr.
113696         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
113697         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
113698         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
113699         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
113700         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
113701         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
113703 2009-06-08  Eric Blake  <ebb9@byu.net>
113705         test-strstr: use memory fence, when possible
113706         * tests/test-strstr.c (main): Use memory fence, in order to be
113707         more likely to trigger Debian bug 521737.
113708         * modules/strstr-tests (Files): Pull in additional files.
113710         memchr: no longer obsolete, for wider field testing
113711         * modules/memchr (Status, Notice): Delete, this module is no
113712         longer obsolete.
113713         * modules/vasnprintf (Depends-on): Add memchr.
113715 2009-06-07  Jim Meyering  <meyering@redhat.com>
113717         hash: declare some functions with the warn_unused_result attribute
113718         * lib/hash.h (__attribute__, ATTRIBUTE_WUR): Define.
113720 2009-06-07  Bruno Haible  <bruno@clisp.org>
113722         * tests/test-alignof.c: Don't test int64_t if it does not exist.
113723         Reported by Eric Blake.
113725 2009-06-06  Eric Blake  <ebb9@byu.net>
113727         test-alignof: fix typo with long double
113728         * tests/test-alignof.c (CHECK): Use longdouble typedef to avoid
113729         compiler error.
113731 2009-06-06  Neil Jerram  <neil@ossau.uklinux.net>  (tiny change)
113733         Escape non-texinfo { and }s.
113734         * doc/ld-output-def.texi (Visual Studio Compatibility): Fix
113735         markup error.
113737 2009-06-04  Jim Meyering  <meyering@redhat.com>
113739         gitlog-to-changelog: don't infloop on an empty commit log
113740         * build-aux/gitlog-to-changelog: Warn about an empty log message.
113741         Reported by Boris Petersen <transacid@centerim.org>.
113743 2009-06-03  Mike Frysinger  <vapier@gentoo.org>
113745         version-etc: extend for packagers
113746         Add three new configure options, intended for packagers:
113747           --with-packager="packager name"
113748           --with-packager-version="packager-specific version"
113749           --with-packager-bug-reports="packager bug reporting"
113750         An example with coreutils:
113751           $ ./configure \
113752             --with-packager=Gentoo \
113753             --with-packager-bug-report=http://bugs.gentoo.org/ \
113754             --with-packager-version="patchset 1.6"
113755           $ ./src/ls --version | head -n2
113756           ls (GNU coreutils) 7.1-dirty
113757           Packaged by Gentoo (patchset 1.6)
113758         Note that the bug reporting info via --help doesn't show up because
113759         coreutils uses its own custom emit_bug_reporting_address() implementation
113760         in src/system.h.  If it didn't, it'd look like:
113761           $ ./src/ls --help | tail -n4
113762           Report bugs to <bug-coreutils@gnu.org>.
113763           Report Gentoo bugs to <http://bugs.gentoo.org/>.
113764           GNU coreutils home page: <http://www.gnu.org/software/coreutils/>.
113765           General help using GNU software: <http://www.gnu.org/gethelp/>.
113766         * lib/version-etc.c: Print new information, if provided.
113767         * m4/version-etc.m4: New file.
113768         * modules/version-etc (Files): Add m4/version-etc.m4.
113769         (configure.ac): Add gl_VERSION_ETC.
113771 2009-05-31  Bruno Haible  <bruno@clisp.org>
113773         * tests/test-alignof.c: Include <stdint.h>. Check also 'long double'
113774         and 'int64_t'.
113775         * modules/alignof-tests (Dependencies): Add stdint.
113776         Reported by Eric Blake.
113778 2009-05-31  Bruno Haible  <bruno@clisp.org>
113780         * lib/alignof.h (alignof_slot, alignof_type, alignof): Document
113781         restriction due to compiler bugs.
113782         Reported by Eric Blake.
113784 2009-05-31  Simon Josefsson  <simon@josefsson.org>
113785             Bruno Haible  <bruno@clisp.org>
113787         Fix test-alignof failure.
113788         * lib/alignof.h (alignof_slot): New macro.
113789         (alignof_type): New macro, with the same semantics as the previous
113790         'alignof'.
113791         (alignof): Alias to alignof_slot.
113792         * tests/test-alignof.c (CHECK): Check alignof_slot, not alignof. Also
113793         check that the results are usable as constant expressions.
113795 2009-05-31  Bruno Haible  <bruno@clisp.org>
113797         * tests/zerosize-ptr.h (zerosize_ptr): Specify more details.
113798         * tests/test-memchr.c (main): Check that memchr does not read past the
113799         first occurrence of the byte.
113800         * tests/test-strstr.c (main): Update comment.
113801         Suggested by Eric Blake.
113803 2009-05-30  Bruno Haible  <bruno@clisp.org>
113805         * doc/ld-output-def.texi (Visual Studio Compatibility): Explain in more
113806         detail how to use dumpbin.
113807         Reported by David Byron <dbyron@dbyron.com>.
113809 2009-06-02  Simon Josefsson  <simon@josefsson.org>
113811         * tests/test-parse-duration.sh: Don't use non-portable 'read -u3'.
113813 2009-06-02  Simon Josefsson  <simon@josefsson.org>
113815         * m4/manywarnings.m4: Add GCC 4.4 warnings.
113817 2009-05-28  Bruno Haible  <bruno@clisp.org>
113819         * gnulib-tool (func_import): Don't do HAVE_CONFIG_H replacements on
113820         build-aux/ files.
113822 2009-05-28  Simon Josefsson  <simon@josefsson.org>
113824         * gnulib-tool (func_import): Transform license on build-aux/ files too.
113826 2009-05-27  Simon Josefsson  <simon@josefsson.org>
113828         * gnulib-tool (sed_transform_main_lib_file)
113829         (sed_transform_testsrelated_lib_file): : Don't use non-POSIX
113830         regexps.
113832 2009-05-26  Simon Josefsson  <simon@josefsson.org>
113834         * tests/test-strstr.c: Add another self-test.
113835         * tests/test-strstr.c: Rewrite to use malloc/strcpy instead of
113836         strdup.  Suggested by Eric Blake  <ebb9@byu.net>.
113838 2009-05-23  Bruno Haible  <bruno@clisp.org>
113840         * doc/havelib.texi (AC_LIB_HAVE_LINKFLAGS): Update for 2009-04-26
113841         change.
113843 2009-05-21  Bruno Haible  <bruno@clisp.org>
113845         Simplify use of mode_t varargs.
113846         * lib/open.c (open): Use PROMOTED_MODE_T instead of a conditional that
113847         uses 'mode_t' or 'int'.
113848         * lib/openat.c (openat): Likewise.
113849         * lib/open-safer.c (open_safer): Likewise.
113850         * m4/mode_t.m4: New file.
113851         * m4/open.m4 (gl_PREREQ_OPEN): Require gl_PROMOTED_TYPE_MODE_T.
113852         * m4/openat.m4 (gl_PREREQ_OPENAT): Likewise.
113853         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Likewise.
113854         * modules/open (Files): Add m4/mode_t.m4.
113855         * modules/openat (Files): Likewise.
113856         * modules/fcntl-safer (Files): Likewise.
113857         Suggested by Eric Blake.
113859 2009-05-21  Pádraig Brady  <P@draigbrady.com>
113861         * doc/glibc-functions/fallocate.texi: New file.
113862         * doc/gnulib.texi: Include it.
113864 2009-05-21  Eric Blake  <ebb9@byu.net>
113865             Bruno Haible  <bruno@clisp.org>
113867         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Remove redundant m4_quote
113868         invocations.
113869         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
113871 2009-05-21  Eric Blake  <ebb9@byu.net>
113872             Bruno Haible  <bruno@clisp.org>
113874         Second attempt to work around an AIX 5.3, 6.1 compiler bug with
113875         include_next. Fix of 2008-11-20 commit.
113876         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Also set
113877         NEXT_AS_FIRST_DIRECTIVE_FOO_H.
113878         * lib/math.in.h: Use NEXT_AS_FIRST_DIRECTIVE_MATH_H instead of
113879         NEXT_MATH_H.
113880         * modules/math (Makefile.am): Substitute NEXT_AS_FIRST_DIRECTIVE_MATH_H
113881         instead of NEXT_MATH_H.
113883 2009-05-21  Bruno Haible  <bruno@clisp.org>
113885         Avoid redefinition warnings for SIZE_MAX.
113886         * m4/size_max.m4 (gl_SIZE_MAX): Avoid redefining SIZE_MAX in config.h.
113887         Reported by Simon Josefsson.
113889 2009-05-21  Bruno Haible  <bruno@clisp.org>
113891         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_CACHE_CHECK instead of
113892         AC_CACHE_VAL.
113894 2009-05-20  Bruno Haible  <bruno@clisp.org>
113896         Make zeroptr.h work on mingw.
113897         * tests/zerosize-ptr.h: Test for the presence of <sys/mman.h> and
113898         mprotect.
113899         * modules/memchr-tests (configure.ac): Also test for sys/mman.h.
113900         * modules/memchr2-tests (configure.ac): Likewise.
113901         * modules/memcmp-tests (configure.ac): Likewise.
113902         * modules/memmem-tests (configure.ac): Likewise.
113903         * modules/memrchr-tests (configure.ac): Likewise.
113904         Reported by Simon Josefsson.
113906 2009-05-20  Simon Josefsson  <simon@josefsson.org>
113908         * tests/test-glob.c: Include string.h for strcmp prototype.
113910 2009-05-20  Simon Josefsson  <simon@josefsson.org>
113912         * modules/getdelim (Depends-on): Add explicit stdint, although it
113913         was implicitly already pulled in via realloc-posix.
113914         * lib/getdelim.c: Get SIZE_MAX from stdint.h.
113916 2009-05-20  Simon Josefsson  <simon@josefsson.org>
113918         MinGW and IRIX does not have sa_family_t type.  Reported by "Tom
113919         G. Christensen" <tgc@jupiterrise.com>.
113920         * m4/sys_socket_h.m4: Check for sa_family_t.
113921         * lib/sys_socket.in.h: Typedef sa_family_t when needed.
113922         * modules/sys_socket: Substitute HAVE_SA_FAMILY_T.
113923         * tests/test-sys_socket.c: Check that sa_family_t works.
113925 2009-05-18  Eric Blake  <ebb9@byu.net>
113927         maint.mk: allow gnulib_dir in VPATH build
113928         * top/maint.mk (gnulib_dir): Make relative to $(srcdir).
113930 2009-05-15  Jim Meyering  <meyering@redhat.com>
113932         maint.mk: Give gnulib_dir a default definition.
113933         * top/maint.mk (gnulib_dir): Define to 'gnulib', by default.
113934         Thus, most packages no longer need to specify this variable in cfg.mk
113936 2009-05-14  Tom Prince  <tom.prince@ualberta.net>  (tiny change)
113938         rename.m4: fix typos that would make non-mingw cross-configure fail
113939         * m4/rename.m4 (gl_FUNC_RENAME): Fix typos.
113941 2009-05-13  Eric Blake  <ebb9@byu.net>
113943         mmap-anon: avoid out-of-order autoconf expansion
113944         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Use correct
113945         SYSTEM_EXTENSIONS macro to silence warnings from autoconf 2.63b.
113946         * modules/memchr-tests (Depends-on): Add extensions.
113947         * modules/memchr2-tests (Depends-on): Add extensions.
113948         * modules/memcmp-tests (Depends-on): Add extensions.
113949         * modules/memmem-tests (Depends-on): Add extensions.
113950         * modules/memrchr-tests (Depends-on): Add extensions.
113952 2009-05-13  Bruno Haible  <bruno@clisp.org>
113954         Make some tests ISO C 99 compliant.
113955         * tests/zerosize-ptr.h: New file.
113956         * tests/test-memchr.c: Include zerosize-ptr.h.
113957         (main): Use a zero-size object pointer instead of NULL.
113958         * tests/test-memchr2.c: Include zerosize-ptr.h.
113959         (main): Use a zero-size object pointer instead of NULL.
113960         * tests/test-memcmp.c: Include zerosize-ptr.h.
113961         (main): Use a zero-size object pointer instead of NULL.
113962         * tests/test-memmem.c: Include zerosize-ptr.h.
113963         (main): Use a zero-size object pointer instead of NULL.
113964         * tests/test-memrchr.c: Include zerosize-ptr.h.
113965         (main): Use a zero-size object pointer instead of NULL.
113966         * modules/memchr-tests (Files): Add tests/zerosize-ptr.h,
113967         m4/mmap-anon.m4.
113968         (Depends-on): Add getpagesize.
113969         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
113970         * modules/memchr2-tests (Files): Add tests/zerosize-ptr.h,
113971         m4/mmap-anon.m4.
113972         (Depends-on): Add getpagesize.
113973         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
113974         * modules/memcmp-tests (Files): Add tests/zerosize-ptr.h,
113975         m4/mmap-anon.m4.
113976         (Depends-on): Add getpagesize.
113977         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
113978         * modules/memmem-tests (Files): Add tests/zerosize-ptr.h,
113979         m4/mmap-anon.m4.
113980         (Depends-on): Add getpagesize.
113981         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
113982         * modules/memrchr-tests (Files): Add tests/zerosize-ptr.h,
113983         m4/mmap-anon.m4.
113984         (Depends-on): Add getpagesize.
113985         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
113987 2009-05-12  Bruno Haible  <bruno@clisp.org>
113989         Tests for module 'alignof'.
113990         * modules/alignof-tests: New file.
113991         * tests/test-alignof.c: New file.
113993 2009-05-12  Bruno Haible  <bruno@clisp.org>
113995         Fix alignof macro.
113996         * lib/alignof.h (alignof): Remove special cases for AIX and HP-UX
113997         vendor compilers that are always correct.
113999 2009-05-12  Bruno Haible  <bruno@clisp.org>
114001         Make the MAP_ANONYMOUS detection work on HP-UX 11.
114002         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check whether mmap exists, but
114003         not whether its fully works.
114005 2009-05-12  Bruno Haible  <bruno@clisp.org>
114007         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Add comments.
114009 2009-05-12  Jim Meyering  <meyering@redhat.com>
114011         * top/maint.mk: Adjust backslash alignment.
114013 2009-05-11  Simon Josefsson  <simon@josefsson.org>
114015         * top/maint.mk: Make $(srcdir)/build-aux configurable.
114017 2009-05-11  Eric Blake  <ebb9@byu.net>
114019         argp: avoid undefined behavior
114020         * lib/argp-fmtstream.c (weak_alias): Pass correct types to ctype
114021         macros.
114023 2009-05-08  Simon Josefsson  <simon@josefsson.org>
114025         * tests/test-vc-list-files-git.sh: Do git config of user.email and
114026         user.name to prevent git commit from complaining.
114028 2009-05-10  Bruno Haible  <bruno@clisp.org>
114030         * gnulib-tool (func_import, func_create_testdir, copy-file): Change
114031         sed_rewrite_old_files, sed_rewrite_new_files, sed_rewrite_files so that
114032         it rewrites every file name only once.
114033         Reported by Simon Josefsson. Helped by Ralf Wildenhues.
114035 2009-05-08  Bruno Haible  <bruno@clisp.org>
114037         * lib/sys_socket.in.h (_SS_PADSIZE): Use a conditional expression
114038         instead of 'max'.
114040 2009-05-08  Simon Josefsson  <simon@josefsson.org>
114042         * m4/sys_socket_h.m4: Test for ws2tcpip.h earlier, needed for
114043         sockaddr_storage test.
114045 2009-05-07  Simon Josefsson  <simon@josefsson.org>
114047         * modules/sys_socket (Makefile.am): Substitute
114048         HAVE_STRUCT_SOCKADDR_STORAGE.  Depend on alignof.
114049         * m4/sys_socket_h.m4: Check for sockaddr_storage.
114050         * lib/sys_socket.in.h (sockaddr_storage): Define when needed.
114051         * tests/test-sys_socket.c: Check sockaddr_storage.
114053 2009-05-08  Bruno Haible  <bruno@clisp.org>
114055         New module 'alignof'.
114056         * lib/alignof.h: New file.
114057         * modules/alignof: New file.
114059 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
114060             Bruno Haible  <bruno@clisp.org>
114062         Fix test-file-has-acl on FreeBSD.
114063         * tests/test-file-has-acl.sh: Also test a directory. On FreeBSD, the
114064         mask is implicitly added.
114065         * tests/test-file-has-acl.c: Include <signal.h>.
114066         (main): Terminate the test after 5 seconds.
114067         * modules/acl-tests (configure.ac): Check for alarm function.
114069 2009-05-04  Bruno Haible  <bruno@clisp.org>
114071         Exploit new semantics of AC_DEFUN_ONCE available since 2009-01-26.
114072         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Remove outdated comment.
114073         * modules/errno (configure.ac): Drop AC_REQUIRE.
114074         * m4/multiarch.m4 (gl_MULTIARCH): Remove outdated comment.
114075         * modules/multiarch (configure.ac): Drop AC_REQUIRE.
114077 2009-05-04  Simon Josefsson  <simon@josefsson.org>
114079         * modules/glob-tests: New module.
114080         * tests/test-glob.c: Add.
114082 2009-05-04  Simon Josefsson  <simon@josefsson.org>
114084         * modules/fnmatch-tests: New module.
114085         * tests/test-fnmatch.c: Add.
114087 2009-05-04  Eric Blake  <ebb9@byu.net>
114089         maint: make the new no-submodule-changes rule VPATH-safe
114090         * top/maint.mk (no-submodule-changes): Don't assume a srcdir build.
114092 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
114093             Bruno Haible  <bruno@clisp.org>
114095         acl: Fix infinite loop on FreeBSD.
114096         * lib/acl_entries.c (acl_entries) [Linux, FreeBSD]: Fix interpretation
114097         of return value from acl_get_entry.
114098         * lib/file-has-acl.c (acl_access_nontrivial) [Linux, FreeBSD]:
114099         Likewise.
114101 2009-05-03  Bruno Haible  <bruno@clisp.org>
114103         * lib/acl-internal.h (acl_entries): Clarify return value.
114104         * lib/acl_entries.c (acl_entries): Likewise.
114106 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
114108         Bug fix in acl module.
114109         * lib/set-mode-acl.c: Use correct struct with ACL_SETACL.
114111 2009-05-03  Bruno Haible  <bruno@clisp.org>
114113         Create gperf-generated file in the source dir, not in the build dir.
114114         * modules/iconv_open (iconv_open-aix.h, iconv_open-hpux.h,
114115         iconv_open-irix.h, iconv_open-osf.h): Create file in the source tree.
114116         * modules/unicase/locale-language (unicase/locale-languages.h):
114117         Likewise.
114118         * modules/unicase/special-casing (unicase/special-casing-table.h):
114119         Likewise.
114120         * modules/unictype/property-byname (unictype/pr_byname.h): Likewise.
114121         * modules/unictype/scripts (unictype/scripts_byname.h): Likewise.
114122         * modules/uninorm/composition (uninorm/composition-table.h): Likewise.
114123         Reported by Ralf Wildenhues.
114125 2009-05-03  Bruno Haible  <bruno@clisp.org>
114127         * modules/fnmatch (Description, configure.ac): Taken from
114128         fnmatch-posix.
114129         * modules/fnmatch-posix: Turn into a symbolic reference to the
114130         'fnmatch' module, and deprecate.
114131         * doc/posix-functions/fnmatch.texi: Mention the fnmatch module.
114133 2009-05-03  Bruno Haible  <bruno@clisp.org>
114135         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF,
114136         gl_PREREQ_VASNPRINTF_LONG_DOUBLE): Define through AC_DEFUN_ONCE.
114137         Reported by Ralf Wildenhues.
114139 2009-05-04  Simon Josefsson  <simon@josefsson.org>
114141         * m4/fnmatch.m4: Fix fnmatch re-define.
114143 2009-04-27  David Bartley  <dtbartle@csclub.uwaterloo.ca>
114145         priv-set: new module and tests; adapt write-any-file
114146         * lib/priv-set.c: New file.
114147         * lib/priv-set.h: New file.
114148         * lib/unlinkdir.c: Make cannot_unlink_dir thread-safe.
114149         * lib/write-any-file.c: Simplify by using priv-set module.
114150         * m4/priv-set.m4: New file.
114151         * modules/priv-set: New file.
114152         * modules/unlinkdir: Add dependency on priv-set module.
114153         * modules/write-any-file: Likewise.
114155         Tests for module 'priv-set'.
114156         * modules/priv-set-tests: New file.
114157         * tests/test-priv-set.c: New file.
114159 2009-05-03  Jim Meyering  <meyering@redhat.com>
114160             Bruno Haible  <bruno@clisp.org>
114162         * lib/propername.c (proper_name_utf8): Ignore no-op translations;
114163         use the converted UTF-8 variant of the name instead.
114165 2009-05-03  Jim Meyering  <meyering@redhat.com>
114167         tests: tighten some getdate tests
114168         * tests/test-getdate.c (main): Tighten tests: require equality,
114169         not just greater than.  Set TZ envvar to UTC0.
114171 2009-05-03  Giuseppe Scrivano  <gscrivano@gnu.org>
114173         getdate: correctly interpret "next monday" when run on a Monday
114174         * lib/getdate.y (get_date): Correct the calculation of tm_mday so
114175         that e.g., "next tues" (when run on a tuesday) results in a date
114176         that is one week in the future, and not today's date.
114177         I.e., add a week when the wday is the same as the current one.
114178         Reported by Tom Broadhurst in http://savannah.gnu.org/bugs/?25406,
114179         and earlier by Martin Bernreuther and Jan Minář.
114180         * tests/test-getdate.c (main): Check that "next DAY" is always in
114181         the future and that "last DAY" is always in the past.
114183 2009-05-02  Jim Meyering  <meyering@redhat.com>
114185         build: ensure that a release build fails when a submodule is unclean
114186         * top/maint.mk (no-submodule-changes): New rule.
114187         (alpha beta major): Depend on it.
114189 2009-05-02  Bruno Haible  <bruno@clisp.org>
114191         Remove incompatibility between modules fnmatch-posix and fnmatch-gnu.
114192         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Use a
114193         shell variable gl_fnmatch_required to detect which variant is
114194         requested.
114195         (_AC_FUNC_FNMATCH_IF, _AC_LIBOBJ_FNMATCH): Remove macros. Inlined into
114196         gl_FUNC_FNMATCH_POSIX.
114197         * gnulib-tool (func_create_testdir, func_create_megatestdir): Don't
114198         exclude fnmatch-posix.
114200 2009-05-02  Bruno Haible  <bruno@clisp.org>
114202         Relicense mbsrtowcs and strnlen1 under LGPLv2+.
114203         * modules/mbsrtowcs (License): Change to LGPLv2+.
114204         * modules/strnlen1 (License): Likewise.
114205         Reported by Simon Josefsson.
114207 2009-05-02  Bruno Haible  <bruno@clisp.org>
114209         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Say "guessing no" instead of
114210         "cross".
114211         (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Update. Don't assume that
114212         gnulib-tool was called with option --source-base=lib.
114214 2009-05-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
114216         Use automake *-local hooks without commands, for extensibility.
114217         * modules/localcharset (Makefile.am): Rename install-exec-local
114218         rule to install-exec-localcharset, and make it a prerequisite of
114219         install-exec-local.  Likewise, rename the uninstall-local rule to
114220         uninstall-localcharset, and make it a prerequisite of the former.
114222 2009-05-01  Bruno Haible  <bruno@clisp.org>
114224         * lib/wchar.in.h (wcsnrtombs): Define if REPLACE_WCSNRTOMBS is 1.
114225         * m4/wcsnrtombs.m4 (gl_FUNC_WCSRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
114226         set REPLACE_WCSNRTOMBS if mbstate_t must be replaced.
114227         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSNRTOMBS.
114228         * modules/wchar (Makefile.am): Substitute REPLACE_WCSNRTOMBS.
114229         * modules/wcsnrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
114230         m4/locale-zh.m4, m4/codeset.m4.
114232         * m4/wcsrtombs.m4 (gl_FUNC_WCSNRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
114233         set REPLACE_WCSRTOMBS if mbstate_t must be replaced.
114234         * modules/wcsrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
114235         m4/locale-zh.m4.
114237         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Invoke gl_MBSTATE_T_BROKEN, and set
114238         REPLACE_WCRTOMB if mbstate_t must be replaced.
114239         * modules/wcrtomb (Files): Add m4/mbrtowc.m4.
114240         Reported by Jens Rehsack <rehsack@googlemail.com> via Eric Blake.
114242 2009-05-01  Bruno Haible  <bruno@clisp.org>
114244         Avoid compiler warnings when redefining macros defined by <libintl.h>.
114245         * lib/gettext.h [!ENABLE_NLS] (gettext, dgettext, dcgettext, ngettext,
114246         dngettext, dcngettext, textdomain, bindtextdomain,
114247         bind_textdomain_codeset): Undefine before redefining.
114249 2009-04-30  Bruno Haible  <bruno@clisp.org>
114251         Fix bug introduced on 2009-04-25.
114252         * lib/math.in.h (gl_signbitf_OPTIMIZED_MACRO,
114253         gl_signbitd_OPTIMIZED_MACRO, gl_signbitl_OPTIMIZED_MACRO): New macros.
114254         * lib/signbitf.c (gl_signbitd): Undefine if gl_signbitf_OPTIMIZED_MACRO
114255         is defined.
114256         * lib/signbitd.c (gl_signbitd): Undefine if gl_signbitd_OPTIMIZED_MACRO
114257         is defined.
114258         * lib/signbitl.c (gl_signbitd): Undefine if gl_signbitl_OPTIMIZED_MACRO
114259         is defined.
114260         Reported by Elbert_Pol <elbert.pol@gmail.com>.
114262 2009-04-28  Bruno Haible  <bruno@clisp.org>
114264         Comment tweaks.
114265         * lib/unistr.h (u*_cmp2): Clarify what memcmp2 is.
114266         * lib/uninorm.h (u*_normxfrm): Fix description of return value.
114267         * lib/unicase.h (u*_casexfrm): Likewise.
114268         Reported by Paolo Bonzini.
114270 2009-04-28  Bruno Haible  <bruno@clisp.org>
114272         Fix a compilation error.
114273         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Fix initializer.
114274         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
114275         Reported by Jim Meyering.
114277 2009-04-27  Bruno Haible  <bruno@clisp.org>
114279         New module 'libunistring'.
114280         * modules/libunistring: New file.
114281         * m4/libunistring.m4: New file.
114282         * MODULES.html.sh (Unicode string functions): Add it.
114284 2009-04-27  Eric Blake  <ebb9@byu.net>
114286         maint.mk: allow package-specific header to provide <config.h>
114287         * top/maint.mk (sc_require_config_h): New variable.
114288         (sc_require_config_h, sc_require_config_h_first): Use it.
114290 2009-04-27  Simon Josefsson  <simon@josefsson.org>
114292         * top/maint.mk (sc_avoid_if_before_free): Except
114293         useless-if-before-free script.
114295 2009-04-27  Eric Blake  <ebb9@byu.net>
114297         maintainer-makefile: depend on all required helper scripts
114298         * modules/maintainer-makefile (Depends-on): Add vc-list-files and
114299         useless-if-before-free.
114300         * top/maint.mk (VC_LIST, sc_avoid_if_before_free): Use local
114301         version, rather than assuming gnulib checkout is available.
114302         Reported by Simen Josefsson.
114304 2009-04-26  Bruno Haible  <bruno@clisp.org>
114306         Make the lib vs. lib64 recognition work on openSUSE 11 with "gcc -m32".
114307         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Ignore paths that end in
114308         "../" or "..".
114310 2009-04-26  Bruno Haible  <bruno@clisp.org>
114312         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Accept a fifth argument.
114313         * m4/libsigsegv.m4 (gl_LIBSIGSEGV): Simplify by using
114314         AC_LIB_HAVE_LINKFLAGS.
114316 2009-04-26  Bruno Haible  <bruno@clisp.org>
114318         Simplify calling convention of u*_conv_from_encoding.
114319         * lib/uniconv.h (u8_conv_from_encoding, u16_conv_from_encoding,
114320         u32_conv_from_encoding): Expect a resultbuf argument and return the
114321         result directly as a pointer.
114322         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Likewise.
114323         * lib/uniconv/u-conv-from-enc.h (FUNC): Likewise.
114324         * lib/uniconv/u-strconv-from-enc.h (FUNC): Update.
114325         * lib/unicase/ulc-casecmp.c (ulc_u8_casefold): Update.
114326         * lib/unicase/ulc-casexfrm.c (ulc_casexfrm): Update.
114327         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
114328         Update.
114329         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Update.
114330         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Update.
114331         * lib/vasnprintf.c (VASNPRINTF): Update.
114332         * tests/uniconv/test-u8-conv-from-enc.c (main): Update.
114333         * tests/uniconv/test-u16-conv-from-enc.c (main): Update.
114334         * tests/uniconv/test-u32-conv-from-enc.c (main): Update.
114335         * NEWS: Mention the change.
114337 2009-04-26  Bruno Haible  <bruno@clisp.org>
114339         Simplify calling convention of u*_conv_to_encoding.
114340         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
114341         u32_conv_to_encoding): Expect a resultbuf argument and return the
114342         result directly as a pointer.
114343         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
114344         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Preserve errno while
114345         freeing scaled_offsets if mem_iconveha failed.
114346         * lib/unicase/u-casexfrm.h (FUNC): Update.
114347         * lib/uninorm/u-normxfrm.h (FUNC): Update.
114348         * lib/vasnprintf.c (VASNPRINTF): Update.
114349         * tests/uniconv/test-u8-conv-to-enc.c (main): Update.
114350         * tests/uniconv/test-u16-conv-to-enc.c (main): Update.
114351         * tests/uniconv/test-u32-conv-to-enc.c (main): Update.
114352         * NEWS: Mention the change.
114354 2009-04-26  Bruno Haible  <bruno@clisp.org>
114356         Avoid test failures on AIX and OSF/1.
114357         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Avoid calling
114358         malloc(0).
114359         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
114360         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
114361         Likewise.
114362         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Likewise.
114363         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Likewise.
114364         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Fix memory leak.
114365         * lib/unistr/u-cpy-alloc.h (FUNC): Call malloc(1) instead of malloc(0).
114366         * doc/posix-functions/malloc.texi: Document the portability problem
114367         related to malloc(0).
114369 2009-04-26  Bruno Haible  <bruno@clisp.org>
114371         * modules/unistr/u8-cpy-alloc (Depends-on): Add malloc-posix.
114372         * modules/unistr/u16-cpy-alloc (Depends-on): Likewise.
114373         * modules/unistr/u32-cpy-alloc (Depends-on): Likewise.
114375 2009-04-25  Bruno Haible  <bruno@clisp.org>
114377         Avoid link error when creating a namespace clean library.
114378         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Don't define
114379         as macro with arguments if already defined as an alias.
114380         * lib/signbitf.c (gl_signbitf): Don't undefine.
114381         * lib/signbitd.c (gl_signbitd): Don't undefine.
114382         * lib/signbitl.c (gl_signbitl): Don't undefine.
114384 2009-04-25  Jim Meyering  <meyering@redhat.com>
114386         vc-list-files: fix another quoting bug
114387         * build-aux/vc-list-files: Avoid sed backslash expansion
114388         of pathological directory names.
114390 2009-04-25  Eric Blake  <ebb9@byu.net>
114392         vc-list-files: fix shell quoting error
114393         * build-aux/vc-list-files: Protect against $ in $dir.  Normalize
114394         timestamp.
114396 2009-04-25  Jim Meyering  <meyering@redhat.com>
114398         vc-list-files: restore lost functionality with subdir argument
114399         * build-aux/vc-list-files: When given a non-"." sub-directory
114400         argument, substitute the $dir/ prefix back onto each resulting name.
114401         Otherwise, coreutils' root_tests check would fail.
114403 2009-04-24  Eric Blake  <ebb9@byu.net>
114405         vc-list-files: ignore git symlinks
114406         * build-aux/vc-list-files (.git): Use ls-tree and a filter, rather
114407         than ls-files, to ignore git symlinks.
114409         maint.mk: import improvements from m4
114410         * top/maint.mk (VC-tag): Use signing key from cfg.mk.
114411         (move_if_change): Delete unused macro.
114412         (news-date-check, vc-diff-check): Support VPATH builds.
114413         (announcement): Likewise.  Split --bootstrap-tools list...
114414         (boostrap-tools): ...into separate list, which can be overridden
114415         in cfg.mk.
114416         (sc_avoid_if_before_free): Point to $(gnulib_dir), rather than
114417         requiring dependency on useless-if-before-free module.
114418         (VC_LIST, VC_LIST_EXCEPT): Likewise for vc-list-files module.
114419         Support VPATH builds.
114421 2009-04-24  Jim Meyering  <meyering@redhat.com>
114423         maint.mk: remove coreutils-specific rules and variables
114424         * top/maint.mk (bin, taint-distcheck, coreutils-path-check, t): Remove.
114425         (fake_home, install-transform-check, my-instcheck, pfx, TMPDIR): Remove.
114426         (t_prefix, t_taint, tp, warn_cflags, write_loser, my-distcheck): Remove.
114428         maint.mk: remove obsolete rule
114429         * top/maint.mk (rel-check): Remove rule.
114430         (WGET, WGETFLAGS): Remove now-unused variables.
114432 2009-04-24  Simon Josefsson  <simon@josefsson.org>
114434         * top/maint.mk (makefile-check): Renamed to sc_makefile_check for
114435         consistency.
114437         * modules/vc-list-files-tests (TESTS_ENVIRONMENT): Use
114438         '$(PATH_SEPARATOR)' instead of ':'.
114440 2009-04-24  Simon Josefsson  <simon@josefsson.org>
114442         * lib/getopt1.c (main): Use 'const' for static array.
114444 2009-04-24  Simon Josefsson  <simon@josefsson.org>
114446         * top/maint.mk: Sync with coreutils.
114447         * NEWS: Explain incompatibilities.
114449 2009-04-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
114450             Bruno Haible  <bruno@clisp.org>
114452         Fix cross-compilation results.
114453         * m4/btowc.m4 (gl_FUNC_BTOWC): Use no-op statement, rather than empty
114454         statement, as third argument of AC_TRY_RUN.
114455         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
114456         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL):
114457         Likewise.
114458         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
114459         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
114460         Likewise.
114461         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
114462         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise. Update for AIX 4.3.
114463         * doc/posix-functions/wcrtomb.texi: Mention the bug on AIX 4.3.
114465 2009-04-20  Bruno Haible  <bruno@clisp.org>
114467         Avoid test failure on mingw.
114468         * tests/uniwidth/test-uc_width2.sh: Convert newlines in output.
114470 2009-04-20  Bruno Haible  <bruno@clisp.org>
114472         Avoid compilation error on mingw.
114473         * modules/localename-tests (Depends-on): Add locale.
114475 2009-04-19  Bruno Haible  <bruno@clisp.org>
114477         Support for building a shared library on Windows platforms.
114478         * tests/uninorm/test-nfc.c (n): Don't define if WOE32DLL.
114479         (main): Test the presence of UNINORM_NFC here.
114480         * tests/uninorm/test-nfd.c (n): Don't define if WOE32DLL.
114481         (main): Test the presence of UNINORM_NFD here.
114482         * tests/uninorm/test-nfkc.c (n): Don't define if WOE32DLL.
114483         (main): Test the presence of UNINORM_NFKC here.
114484         * tests/uninorm/test-nfkd.c (n): Don't define if WOE32DLL.
114485         (main): Test the presence of UNINORM_NFKD here.
114487 2009-04-19  Bruno Haible  <bruno@clisp.org>
114489         Avoid a compiler warning.
114490         * tests/uninorm/test-u32-normalize-big.c (read_normalization_test_file):
114491         Change type of variable 'sequence'.
114493 2009-04-19  Bruno Haible  <bruno@clisp.org>
114495         * modules/configmake (Makefile.am): When the contents of configmake.h
114496         does not change, arrange to preserve its modification time.
114498 2009-04-17  Simon Josefsson  <simon@josefsson.org>
114500         * top/maint.mk (PO_DOMAIN): New variable, allows overriding of
114501         gettext domain.
114503 2009-04-16  Jim Meyering  <meyering@redhat.com>
114505         useless-if-before-free: improve conversion code
114506         * build-aux/useless-if-before-free: Adjust code-in-comment to match
114507         "...!= 0" as well as "...!= NULL".  emacs has one of the former.
114509 2009-04-14  Bruno Haible  <bruno@clisp.org>
114511         * modules/fcntl (Depends-on): Add extensions.
114512         * m4/fcntl_h.m4 (gl_FCNTL_H): Add a comment.
114514 2009-04-12  Ben Pfaff  <blp@gnu.org>
114516         Make fcntl module detect O_NOATIME, O_NOFOLLOW on GNU/Linux.
114517         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_USE_SYSTEM_EXTENSIONS.
114519 2009-03-20  Ben Pfaff  <blp@gnu.org>
114521         Make rename replace existing destinations on Windows.
114522         * m4/rename.m4: Add test for Mingw.
114523         * lib/rename.c: Add rename replacement that uses MoveFileEx with
114524         MOVEFILE_REPLACE_EXISTING to replace existing destination files.
114525         * doc/posix-functions/rename.texi: Document.
114527 2009-04-10  Bruno Haible  <bruno@clisp.org>
114529         New include file "iconveh.h".
114530         * lib/iconveh.h: New file, extracted from lib/striconveh.h.
114531         * lib/striconveh.h: Include it.
114532         (enum iconv_ilseq_handler): Remove definition.
114533         * lib/striconveha.h: Include <stddef.h> and iconveh.h instead of
114534         striconveh.h.
114535         * lib/striconveha.c: Include striconveh.h.
114536         * lib/uniconv.h: Include iconveh.h instead of striconveh.h.
114537         * modules/striconveh (Files): Add lib/iconveh.h.
114538         * modules/uniconv/base (Files): Add lib/iconveh.h. Remove
114539         lib/striconveh.h.
114541 2009-04-10  Bruno Haible  <bruno@clisp.org>
114543         * lib/uniconv.h: Update comment.
114545 2009-04-10  Bruno Haible  <bruno@clisp.org>
114547         * lib/unistr/u8-mbtouc-aux.c: Inside libunistring, define the function
114548         always.
114549         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
114550         * lib/unistr/u16-mbtouc-aux.c: Likewise.
114551         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
114552         * lib/unistr/u8-mbtouc.c: Inside libunistring, include
114553         "unistring-notinline.h", so that the function gets defined always.
114554         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
114555         * lib/unistr/u8-uctomb.c: Likewise.
114556         * lib/unistr/u16-mbtouc.c: Likewise.
114557         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
114558         * lib/unistr/u16-uctomb.c: Likewise.
114559         * lib/unistr/u32-mbtouc.c: Likewise.
114560         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
114561         * lib/unistr/u32-uctomb.c: Likewise.
114563 2009-04-10  Bruno Haible  <bruno@clisp.org>
114565         Mark 'utime' obsolete.
114566         * modules/utime (Status, Notice): New sections.
114567         Suggested by Jim Meyering.
114569         Fix cross-compile guess for utime test.
114570         * m4/utime.m4 (AC_FUNC_UTIME_NULL): Add definition from newest unstable
114571         autoconf.
114572         * doc/posix-functions/utime.texi: Give more precisions.
114573         Reported by Jan <ipif@ymail.com>.
114575 2009-04-09  Kamil Dudka  <kdudka@redhat.com>
114577         filevercmp: correct today's change
114578         * lib/filevercmp.c: Also handle coreutils' test inputs.
114579         * tests/test-filevercmp.c: Add inputs from one of coreutils' test scripts.
114581         Fix regression in 'filevercmp' module. Thanks Sven Joachim
114582         for reporting it.
114583         * lib/filevercmp.c: Special handle for "", "." and "..".
114584         * tests/test-filevercmp.c: Enlarge the set suite.
114586 2009-04-07  Jim Meyering  <meyering@redhat.com>
114588         useless-if-before-free: show how to remove braced useless free, too
114589         * build-aux/useless-if-before-free: still only in a comment, though.
114591 2009-04-07  Reuben Thomas  <rrt@sc3d.org>
114593         maint.mk: import changes to syntax-check macros from coreutils
114594         * top/maint.mk (_prohibit_regexp, _header_without_use): Define.
114595         Use them in the relevant macros.
114597 2009-04-06  Bruno Haible  <bruno@clisp.org>
114599         Fix unportable use of bit-fields.
114600         * lib/unicase/special-casing.h (struct special_casing_rule): Change the
114601         bit-field type from 'int' to 'signed int'. Otherwise Solaris cc,
114602         AIX xlc, and OSF/1 cc interpret it as 'unsigned int'.
114604 2009-04-06  Bruno Haible  <bruno@clisp.org>
114606         Avoid test failures on AIX and OSF/1.
114607         * tests/unicase/test-u8-casefold.c (check): Account for the possibility
114608         that malloc(0) = NULL.
114609         * tests/unicase/test-u8-tolower.c (check): Likewise.
114610         * tests/unicase/test-u8-totitle.c (check): Likewise.
114611         * tests/unicase/test-u8-toupper.c (check): Likewise.
114612         * tests/unicase/test-u16-casefold.c (check): Likewise.
114613         * tests/unicase/test-u16-tolower.c (check): Likewise.
114614         * tests/unicase/test-u16-totitle.c (check): Likewise.
114615         * tests/unicase/test-u16-toupper.c (check): Likewise.
114616         * tests/unicase/test-u32-casefold.c (check): Likewise.
114617         * tests/unicase/test-u32-tolower.c (check): Likewise.
114618         * tests/unicase/test-u32-totitle.c (check): Likewise.
114619         * tests/unicase/test-u32-toupper.c (check): Likewise.
114620         * tests/uninorm/test-u8-nfc.c (check): Likewise.
114621         * tests/uninorm/test-u8-nfd.c (check): Likewise.
114622         * tests/uninorm/test-u8-nfkc.c (check): Likewise.
114623         * tests/uninorm/test-u8-nfkd.c (check): Likewise.
114624         * tests/uninorm/test-u16-nfc.c (check): Likewise.
114625         * tests/uninorm/test-u16-nfd.c (check): Likewise.
114626         * tests/uninorm/test-u16-nfkc.c (check): Likewise.
114627         * tests/uninorm/test-u16-nfkd.c (check): Likewise.
114628         * tests/uninorm/test-u32-nfc.c (check): Likewise.
114629         * tests/uninorm/test-u32-nfd.c (check): Likewise.
114630         * tests/uninorm/test-u32-nfkc.c (check): Likewise.
114631         * tests/uninorm/test-u32-nfkd.c (check): Likewise.
114633 2009-04-05  Bruno Haible  <bruno@clisp.org>
114635         Work around an autoconf limitation.
114636         * gnulib-tool (func_emit_lib_Makefile_am): Omit the "Reproduce by"
114637         comment line if it would be longer than 3 KB.
114639 2009-04-05  Bruno Haible  <bruno@clisp.org>
114641         Avoid test failure with libiconv-1.13.
114642         * tests/test-striconveh.c (main): Allow result of libiconv 1.13 as one
114643         of the expected test results.
114645 2009-04-05  Bruno Haible  <bruno@clisp.org>
114647         * gnulib-tool (func_emit_lib_Makefile_am): Don't add the library to
114648         noinst_LTLIBRARIES if the Makefile.am in the same directory specifies
114649         that it should be installed.
114651 2009-04-05  Bruno Haible  <bruno@clisp.org>
114653         * gnulib-tool: New option --copy-file.
114654         (func_usage): Document it.
114655         (func_dest_tmpfilename): Moved out of func_import.
114656         (func_add_file, func_update_file): New functions, extracted from
114657         func_import.
114658         (func_import): Update.
114660 2009-04-05  Karl Berry  <karl@gnu.org>
114662         * README: prominently mention gnulib-tool.
114663         Rearrange sections so getting the code is near the top.
114665 2009-04-05  Bruno Haible  <bruno@clisp.org>
114667         * lib/unicase.h: Mention u*_cmp2.
114668         * lib/unicase/u-casecmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
114669         * lib/unicase/u8-casecmp.c: Use u8_cmp2 instead of u8_cmp.
114670         * lib/unicase/ulc-casecmp.c: Likewise.
114671         * lib/unicase/u16-casecmp.c: Use u16_cmp2 instead of u16_cmp.
114672         * lib/unicase/u32-casecmp.c: Use u32_cmp2 instead of u32_cmp.
114673         * modules/unicase/u8-casecmp (Depends-on): Add unistr/u8-cmp2, remove
114674         unistr/u8-cmp.
114675         * modules/unicase/ulc-casecmp (Depends-on): Likewise.
114676         * modules/unicase/u16-casecmp (Depends-on): Add unistr/u16-cmp2, remove
114677         unistr/u16-cmp.
114678         * modules/unicase/u32-casecmp (Depends-on): Add unistr/u32-cmp2, remove
114679         unistr/u32-cmp.
114681         * lib/uninorm.h: Mention u*_cmp2.
114682         * lib/uninorm/u-normcmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
114683         * lib/uninorm/u8-normcmp.c: Use u8_cmp2 instead of u8_cmp.
114684         * lib/uninorm/u16-normcmp.c: Use u16_cmp2 instead of u16_cmp.
114685         * lib/uninorm/u32-normcmp.c: Use u32_cmp2 instead of u32_cmp.
114686         * modules/uninorm/u8-normcmp (Depends-on): Add unistr/u8-cmp2, remove
114687         unistr/u8-cmp.
114688         * modules/uninorm/u16-normcmp (Depends-on): Add unistr/u16-cmp2, remove
114689         unistr/u16-cmp.
114690         * modules/uninorm/u32-normcmp (Depends-on): Add unistr/u32-cmp2, remove
114691         unistr/u32-cmp.
114693         New module 'unistr/u32-cmp2'.
114694         * lib/unistr/u32-cmp2.c: New file.
114695         * modules/unistr/u32-cmp2: New file.
114697         New module 'unistr/u16-cmp2'.
114698         * lib/unistr/u16-cmp2.c: New file.
114699         * modules/unistr/u16-cmp2: New file.
114701         New module 'unistr/u8-cmp2'.
114702         * lib/unistr.h (u8_cmp2, u16_cmp2, u32_cmp2): New declarations.
114703         * lib/unistr/u8-cmp2.c: New file.
114704         * lib/unistr/u-cmp2.h: New file.
114705         * modules/unistr/u8-cmp2: New file.
114707 2009-04-05  Bruno Haible  <bruno@clisp.org>
114709         * lib/unictype.h (uc_property_is_valid): New macro.
114710         * tests/unictype/test-pr_byname.c (main): Use it.
114712         * lib/unistr.h: Doc fixes.
114713         * lib/uniconv.h: Doc fixes.
114714         * lib/unictype.h: Doc fixes.
114716 2009-04-03  Paul Eggert  <eggert@cs.ucla.edu>
114718         Port coreutils 7.2 to Solaris 8.
114720         * modules/arpa_inet (arpa/inet.h): Depend on arpa_inet.in.h.
114721         * m4/inet_ntop.m4 (gl_INET_NTOP): Search for inet_ntop in -lnsl,
114722         for Solaris 8.  This is a bit of a hack, as it means it's the
114723         caller's responsibility to add -lnsl if needed, but most likely it
114724         won't be needed since only getaddrinfo uses this and getaddrinfo
114725         isn't needed on Solaris 8.
114727         * modules/fnmatch (Depends-on): Add mbsrtowcs, to fix a porting
114728         problem to Solaris 8 encountered with coreutils 7.2, which
114729         resulted in a message "fnmatch.c:292: warning: passing argument 4
114730         of 'mbsrtowcs' from incompatible pointer type".  Also, add mbsinit
114731         at the suggestion of Bruno Haible, since fnmatch uses mbsinit.
114733 2009-04-03  Simon Josefsson  <simon@josefsson.org>
114735         * m4/ld-version-script.m4: Add FIXME comment.
114737 2009-04-02  Simon Josefsson  <simon@josefsson.org>
114739         * doc/ld-output-def.texi: Use DLL_VERSION instead of confusing
114740         SOVERSION variable.
114742 2009-04-02  Bruno Haible  <bruno@clisp.org>
114744         * Makefile (info, html, dvi, pdf): Combine the rules.
114745         Suggested by Jim Meyering.
114747 2009-04-01  Bruno Haible  <bruno@clisp.org>
114749         * Makefile (info, html, dvi, pdf): New targets.
114750         Reported by Reuben Thomas <rrt@sc3d.org>.
114752 2009-04-01  Bruno Haible  <bruno@clisp.org>
114754         * doc/gnulib-tool.texi (Invoking gnulib-tool): Document how gnulib-tool
114755         can be put into PATH.
114756         Reported by Reuben Thomas <rrt@sc3d.org>. Suggested by Karl Berry.
114758 2009-04-01  Bruno Haible  <bruno@clisp.org>
114760         * doc/lib-symbol-visibility.texi: Follow texinfo style conventions.
114762 2009-04-01  Bruno Haible  <bruno@clisp.org>
114764         Rename module 'visibility'.
114765         * modules/lib-symbol-visibility: Renamed from modules/visibility.
114766         * doc/lib-symbol-visibility.texi: Renamed from visibility.texi.
114767         * doc/gnulib.texi: Update.
114768         * MODULES.html.sh (Misc): Update.
114769         * NEWS: Mention the change.
114771 2009-04-01  Simon Josefsson  <simon@josefsson.org>
114773         * modules/lib-msvc-compat: New module.  Thanks to Bruno Haible
114774         <bruno@clisp.org>, Ralf Wildenhues <Ralf.Wildenhues@gmx.de>, and
114775         Eric Blake <ebb9@byu.net> for review.
114776         * MODULES.html.sh: Add lib-msvc-compat.
114777         * doc/gnulib.texi: Link to new section.
114778         * m4/ld-output-def.m4: New file.
114779         * doc/ld-output-def.texi: New file.
114781 2009-04-01  Simon Josefsson  <simon@josefsson.org>
114783         Rename ld-version-script to lib-symbol-versions.  Suggested by
114784         Bruno Haible <bruno@clisp.org>.
114785         * modules/ld-version-script: Renamed to lib-symbol-versions.
114786         * doc/ld-version-script.texi: Fix module name.
114787         * MODULES.html.sh: Add lib-symbol-versions.
114789 2009-03-31  Simon Josefsson  <simon@josefsson.org>
114791         * modules/u64-tests: New file.
114792         * tests/test-u64.c: New file.
114794 2009-03-04  Simon Josefsson  <simon@josefsson.org>
114796         * MODULES.html.sh: Mention u64.
114797         * modules/u64: New module.
114798         * modules/crypto/sha512: Depend on u64 module instead of providing
114799         u64.h.
114801 2009-03-27  Eric Blake  <ebb9@byu.net>
114803         test-strerror: make debugging EAI_SYSTEM easier
114804         * modules/getaddrinfo-tests (Depends-on): Add strerror.
114805         * test-getaddrinfo.c (simple) [ENABLE_DEBUGGING]: Report errno if
114806         failure was EAI_SYSTEM.
114808 2009-03-25  Bruno Haible  <bruno@clisp.org>
114810         Fix a problem with --enable-relocatable on Solaris 7.
114811         * modules/relocatable-prog-wrapper (Depends-on): Add environ. Needed
114812         since 2008-02-24.
114814 2009-03-25  Eric Blake  <ebb9@byu.net>
114816         test-sockets: avoid gcc warning
114817         * tests/test-sockets.c (main): Silence compiler warning.
114819 2009-03-25  Paul Eggert  <eggert@cs.ucla.edu>
114821         New modules nproc, pthread, contributed by Glen Lenker.
114823         * MODULES.html.sh: Add pthread, nproc.
114824         * lib/nproc.c: New file.
114825         * lib/nproc.h: New file.
114826         * lib/pthread.in.h: New file.
114827         * m4/pthread.m4: New file.
114828         * modules/nproc: New file.
114829         * modules/pthread: New file.
114831 2009-03-24  Simon Josefsson  <simon@josefsson.org>
114833         * modules/unicase/locale-language-tests (test_locale_language_LDADD):
114834         New variable.
114836 2009-03-24  Kamil Dudka  <kdudka@redhat.com>
114838         filevercmp: handle simple~ and numbered.~3~ backup suffixes
114839         * lib/filevercmp.c: Handle simple~ and numbered.~3~ backup suffixes.
114840         * tests/test-filevercmp.c: Add tests for backup suffixes.
114842 2009-03-24  Simon Josefsson  <simon@josefsson.org>
114844         * modules/stdlib (Depends-on): Add stdint, needed when defining
114845         struct random_data on, for example, HP-UX 10.20.  Reported by
114846         Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
114848 2009-03-24  Simon Josefsson  <simon@josefsson.org>
114850         * lib/readline.c (readline): Call fflush on stdout after printing
114851         prompt.
114853 2009-03-20  Bruno Haible  <bruno@clisp.org>
114855         Remove dependency from 'close' module to -lws2_32 on native Windows.
114856         * lib/close-hook.h: New file.
114857         * lib/close-hook.c: New file.
114858         * lib/close.c: Include close-hook.h. Don't include <sys/socket.h>,
114859         w32sock.h.
114860         (_gl_close_fd_maybe_socket): Remove function.
114861         (rpl_close): Invoke execute_all_close_hooks instead of
114862         _gl_close_fd_maybe_socket.
114863         * lib/sockets.c: Include close-hook.h, w32sock.h.
114864         (close_fd_maybe_socket): New function, essentially from lib/close.c.
114865         (close_sockets_hook): New variable.
114866         (gl_sockets_startup): Register close_fd_maybe_socket as a hook.
114867         (gl_sockets_cleanup): Unregister it.
114868         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): Remove macro.
114869         * m4/close.m4 (gl_REPLACE_CLOSE): Undo 2009-02-05 change.
114870         * modules/close-hook: New file.
114871         * modules/close (Files): Remove lib/w32sock.h.
114872         (Depends-on): Add close-hook.
114873         (Link): Remove section.
114874         * modules/sockets (Files): Add lib/w32sock.h.
114875         (Depends-on): Add close-hook.
114876         * modules/sys_socket (configure.ac): Remove gl_MODULE_INDICATOR
114877         invocation.
114878         * NEWS: Mention that LIB_CLOSE is gone.
114880 2009-03-23  Eric Blake  <ebb9@byu.net>
114882         signal-tests: test previous patch
114883         * tests/test-signal.c: New file.
114884         * modules/signal-tests: Likewise.
114886         signal.h: always support 'volatile sig_atomic_t'
114887         * m4/signal_h.m4 (gl_SIGNAL_H): Check for AIX limitation.
114888         (gl_SIGNAL_H_DEFAULTS): Add a default.
114889         * modules/signal (Makefile.am): Substitute if needed.
114890         * lib/signal.in.h (sig_atomic_t): Redefine if needed, so that
114891         users can blindly add volatile.
114892         * doc/posix-headers/signal.texi (signal.h): Document it.
114893         Reported by Matthew Woehlke.
114895 2009-03-23  Jim Meyering  <meyering@redhat.com>
114897         pathmax: PATH_MAX: use pathconf only when available
114898         * lib/pathmax.h (PATH_MAX): Select the pathconf-using definition
114899         only if HAVE_PATHCONF is defined.  Patch by Sylvain Beucler.
114900         * m4/pathmax.m4 (gl_PATHMAX): Check for pathconf.
114901         This avoids a link failure in a PSP cross-compilation environment
114902         described in http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/17048
114904         * lib/vasnprintf.c (divide): Fix typo in comment.
114906 2009-03-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
114908         * gnulib-tool (func_filter_filelist): Fix comment.
114910 2009-03-20  Bruno Haible  <bruno@clisp.org>
114912         Make sockets.h self-contained.
114913         * lib/sockets.c: Include sockets.h first.
114914         * lib/sockets.h: Include <sys/socket.h> before using the SOCKET type.
114916 2009-03-19  Eric Blake  <ebb9@byu.net>
114918         doc: mention more functions added in cygwin 1.7.0
114919         * doc/posix-functions/log2.texi: Mention recent cygwin 1.7.0
114920         addition.
114921         * doc/posix-functions/log2f.texi: Likewise.
114923 2009-03-19  Jim Meyering  <meyering@redhat.com>
114925         fsusage: avoid syntax error due to statement-before-declaration
114926         * lib/fsusage.c (get_fs_usage): Put warning-avoidance statement
114927         after all declarations.  Reported by Matthew Woehlke in
114928         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/16231
114930 2009-03-18  Eric Blake  <ebb9@byu.net>
114932         build-aux/compile: sync from automake
114933         * build-aux/compile: New file, from automake.
114934         * config/srclist.txt: Mention build-aux/compile.
114936 2009-03-17  Bruno Haible  <bruno@clisp.org>
114938         * lib/git-merge-changelog.c: Fix typo in comment.
114939         Reported by Reuben Thomas <rrt@sc3d.org>.
114941 2009-03-17  Reuben Thomas  <rrt@sc3d.org>
114943         * m4/regex.m4: update and improve help for
114944         --without-included-regex.
114946 2009-03-17  Simon Josefsson  <simon@josefsson.org>
114948         * modules/isnanl-nolibm-tests (Files): Add tests/nan.h to avoid
114949         failure on missing include files.
114951 2009-03-17  Eric Blake  <ebb9@byu.net>
114953         doc: mention more functions added in cygwin 1.7.0
114954         * doc/posix-functions/fwprintf.texi: Mention recent cygwin 1.7.0
114955         addition.
114956         * doc/posix-functions/fwscanf.texi: Likewise.
114957         * doc/posix-functions/swprintf.texi: Likewise.
114958         * doc/posix-functions/swscanf.texi: Likewise.
114959         * doc/posix-functions/vfwprintf.texi: Likewise.
114960         * doc/posix-functions/vfwscanf.texi: Likewise.
114961         * doc/posix-functions/vswprintf.texi: Likewise.
114962         * doc/posix-functions/vswscanf.texi: Likewise.
114963         * doc/posix-functions/vwprintf.texi: Likewise.
114964         * doc/posix-functions/vwscanf.texi: Likewise.
114965         * doc/posix-functions/wcscasecmp.texi: Likewise.
114966         * doc/posix-functions/wcsdup.texi: Likewise.
114967         * doc/posix-functions/wcsftime.texi: Likewise.
114968         * doc/posix-functions/wcsncasecmp.texi: Likewise.
114969         * doc/posix-functions/wprintf.texi: Likewise.
114970         * doc/posix-functions/wscanf.texi: Likewise.
114971         * doc/glibc-functions/gethostbyname2.texi: Likewise.
114973 2009-03-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
114975         maint.mk: really add $(AM_MAKEFLAGS)
114976         * top/maint.mk (init-coverage, build-coverage): `$(AM_MAKEFLAGS)'
114977         was inadvertently omitted in the last commit.
114978         Spotted by Bruno Haible.
114980         maint.mk: use $(MAKE) $(AM_MAKEFLAGS) not make
114981         * top/maint.mk (init-coverage, build-coverage): Use `$(MAKE)
114982         $(AM_MAKEFLAGS)' rather than plain `make'.
114984         gnulib-tool: execute $MAKE not make
114985         * gnulib-tool: Default $MAKE to 'make'.
114986         (func_create_testdir, func_create_megatestdir): Use $MAKE rather
114987         than make.  Initialize $MAKE in the do-autobuild script.
114989         gnulib-tool: use $MAKE not make in generated files
114990         * gnulib-tool (func_create_megatestdir): Use $MAKE rather than
114991         make, in generated files.  Initialize $MAKE in the do-autobuild
114992         script.
114994         * top/GNUmakefile (_have-git-version-gen): Fix typo.
114996         GNUmakefile: disable parallelism only for multiple, recursive targets
114997         * top/GNUmakefile (ALL_RECURSIVE_TARGETS): New macro; allow user
114998         additions in the Makefile.
114999         (AM_RECURSIVE_TARGETS): New macro, override only if not provided
115000         by Automake.
115001         (.NOTPARALLEL): Only disable parallel builds if multiple targets
115002         are listed on the command line and at least one of them is
115003         listed in $(ALL_RECURSIVE_TARGETS).
115005 2009-03-14  Bruno Haible  <bruno@clisp.org>
115007         * modules/unilbrk/u8-possible-linebreaks (Depends-on): Replace
115008         utf8-ucs4-unsafe with unistr/u8-mbtouc-unsafe.
115009         * modules/unilbrk/u8-width-linebreaks (Depends-on): Likewise.
115010         * modules/unilbrk/u16-possible-linebreaks (Depends-on): Replace
115011         utf16-ucs4-unsafe with unistr/u16-mbtouc-unsafe.
115012         * modules/unilbrk/u16-width-linebreaks (Depends-on): Likewise.
115013         * modules/unistr/u8-chr (Depends-on): Replace ucs4-utf8 with
115014         unistr/u8-uctomb.
115015         * modules/unistr/u8-strchr (Depends-on): Likewise.
115016         * modules/unistr/u8-strrchr (Depends-on): Likewise.
115017         * modules/unistr/u16-chr (Depends-on): Replace ucs4-utf16 with
115018         unistr/u16-uctomb.
115019         * modules/unistr/u16-strchr (Depends-on): Likewise.
115020         * modules/unistr/u16-strrchr (Depends-on): Likewise.
115022 2009-03-12  Bruno Haible  <bruno@clisp.org>
115024         Work around select() bug on Interix 3.5.
115025         * lib/sys_select.in.h (select): Also replace if REPLACE_SELECT is 1.
115026         * lib/select.c (rpl_select): Add an implementation for Unix platforms.
115027         * m4/select.m4: New file.
115028         * m4/sys_select_h.m4 (gl_SYS_SELECT_H_DEFAULTS): Initialize REPLACE_SELECT.
115029         * modules/sys_select (Makefile.am): Substitute REPLACE_SELECT.
115030         * modules/select (Files): Add m4/select.m4.
115031         (configure.ac): Move conditional to m4/select.m4. Invoke gl_FUNC_SELECT.
115032         * modules/nanosleep (Depends-on): Add select.
115033         * modules/poll (Depends-on): Likewise.
115034         * doc/posix-functions/select.texi: Mention the Interix bug.
115035         Reported by Markus Duft <mduft@gentoo.org>.
115037         * lib/select.c: Renamed from lib/winsock-select.c.
115038         * modules/select (Files): Add lib/select.c, remove
115039         lib/winsock-select.c.
115040         (configure.ac): Update.
115042 2009-03-12  Jim Meyering  <meyering@redhat.com>
115044         avoid gcc warnings about unused macro definitions
115045         * lib/readtokens.c (STREQ): Remove unused definition.
115046         * lib/xmalloc.c (SIZE_MAX): Likewise.
115047         * lib/openat-die.c (N_): Likewise.
115048         * lib/mountlist.c (SIZE_MAX): Remove definition.
115049         Instead, include <stdint.h>.
115050         * lib/readutmp.c: Likewise.
115051         * modules/readutmp (Depends-on): Add stdint.
115052         * modules/mountlist (Depends-on): Add stdint.
115053         * lib/userspec.c (ISDIGIT): Move definition into #if block where used.
115055 2009-03-10  Bruno Haible  <bruno@clisp.org>
115057         Tests for module 'mbmemcasecoll'.
115058         * modules/mbmemcasecoll-tests: New file.
115059         * tests/test-mbmemcasecoll1.sh: New file.
115060         * tests/test-mbmemcasecoll2.sh: New file.
115061         * tests/test-mbmemcasecoll3.sh: New file.
115062         * tests/test-mbmemcasecoll.c: New file.
115064         New module 'mbmemcasecoll'.
115065         * lib/mbmemcasecoll.h: New file.
115066         * lib/mbmemcasecoll.c: New file.
115067         * modules/mbmemcasecoll: New file.
115069         * tests/test-mbmemcasecmp.h: New file, extracted from
115070         tests/test-mbmemcasecmp.c.
115071         * tests/test-mbmemcasecmp.c: Include test-mbmemcasecmp.h.
115072         (test_ascii, test_iso_8859_1, test_utf_8): Remove functions.
115073         (main): Update.
115074         * modules/mbmemcasecmp-tests (Files): Add tests/test-mbmemcasecmp.h.
115076 2009-03-09  Bruno Haible  <bruno@clisp.org>
115078         Tests for module 'mbmemcasecmp'.
115079         * modules/mbmemcasecmp-tests: New file.
115080         * tests/test-mbmemcasecmp1.sh: New file.
115081         * tests/test-mbmemcasecmp2.sh: New file.
115082         * tests/test-mbmemcasecmp3.sh: New file.
115083         * tests/test-mbmemcasecmp.c: New file.
115085         New module 'mbmemcasecmp'.
115086         * lib/mbmemcasecmp.h: New file.
115087         * lib/mbmemcasecmp.c: New file.
115088         * modules/mbmemcasecmp: New file.
115090 2009-03-09  Bruno Haible  <bruno@clisp.org>
115092         Tests for module 'unicase/ulc-casecoll'.
115093         * modules/unicase/ulc-casecoll-tests: New file.
115094         * tests/unicase/test-ulc-casecoll1.sh: New file.
115095         * tests/unicase/test-ulc-casecoll2.sh: New file.
115096         * tests/unicase/test-ulc-casecoll.c: New file.
115098         New module 'unicase/ulc-casecoll'.
115099         * lib/unicase.h (ulc_casecoll): New declaration.
115100         * lib/unicase/ulc-casecoll.c: New file.
115101         * modules/unicase/ulc-casecoll: New file.
115103         New module 'unicase/ulc-casexfrm'.
115104         * lib/unicase.h (ulc_casexfrm): New declaration.
115105         * lib/unicase/ulc-casexfrm.c: New file.
115106         * modules/unicase/ulc-casexfrm: New file.
115108 2009-03-09  Bruno Haible  <bruno@clisp.org>
115110         Followup to 2008-12-22 commit: Remove unnecessary AC_FUNC_MBRTOWC
115111         invocations.
115113         * m4/mbscasecmp.m4: Remove file.
115114         * modules/mbscasecmp (Files): Remove it and m4/mbrtowc.m4
115115         (configure.ac): Remove gl_FUNC_MBSCASECMP invocation.
115117         * m4/mbscasestr.m4: Remove file.
115118         * modules/mbscasestr (Files): Remove it and m4/mbrtowc.m4
115119         (configure.ac): Remove gl_FUNC_MBSCASESTR invocation.
115121         * m4/mbschr.m4: Remove file.
115122         * modules/mbschr (Files): Remove it and m4/mbrtowc.m4
115123         (configure.ac): Remove gl_FUNC_MBSCHR invocation.
115125         * m4/mbscspn.m4: Remove file.
115126         * modules/mbscspn (Files): Remove it and m4/mbrtowc.m4
115127         (configure.ac): Remove gl_FUNC_MBSCSPN invocation.
115129         * m4/mbslen.m4: Remove file.
115130         * modules/mbslen (Files): Remove it and m4/mbrtowc.m4
115131         (configure.ac): Remove gl_FUNC_MBSLEN invocation.
115133         * m4/mbsncasecmp.m4: Remove file.
115134         * modules/mbsncasecmp (Files): Remove it and m4/mbrtowc.m4
115135         (configure.ac): Remove gl_FUNC_MBSNCASECMP invocation.
115137         * m4/mbsnlen.m4: Remove file.
115138         * modules/mbsnlen (Files): Remove it and m4/mbrtowc.m4
115139         (configure.ac): Remove gl_FUNC_MBSNLEN invocation.
115141         * m4/mbspbrk.m4: Remove file.
115142         * modules/mbspbrk (Files): Remove it and m4/mbrtowc.m4
115143         (configure.ac): Remove gl_FUNC_MBSPBRK invocation.
115145         * m4/mbspcasecmp.m4: Remove file.
115146         * modules/mbspcasecmp (Files): Remove it and m4/mbrtowc.m4
115147         (configure.ac): Remove gl_FUNC_MBSPCASECMP invocation.
115149         * m4/mbsrchr.m4: Remove file.
115150         * modules/mbsrchr (Files): Remove it and m4/mbrtowc.m4
115151         (configure.ac): Remove gl_FUNC_MBSRCHR invocation.
115153         * m4/mbssep.m4: Remove file.
115154         * modules/mbssep (Files): Remove it and m4/mbrtowc.m4
115155         (configure.ac): Remove gl_FUNC_MBSSEP invocation.
115157         * m4/mbsspn.m4: Remove file.
115158         * modules/mbsspn (Files): Remove it and m4/mbrtowc.m4
115159         (configure.ac): Remove gl_FUNC_MBSSPN invocation.
115161         * m4/mbsstr.m4: Remove file.
115162         * modules/mbsstr (Files): Remove it and m4/mbrtowc.m4
115163         (configure.ac): Remove gl_FUNC_MBSSTR invocation.
115165         * m4/mbstok_r.m4: Remove file.
115166         * modules/mbstok_r (Files): Remove it and m4/mbrtowc.m4
115167         (configure.ac): Remove gl_FUNC_MBSTOK_R invocation.
115169         * m4/mbswidth.m4 (gl_MBSWIDTH): Remove AC_FUNC_MBRTOWC invocation.
115171         * m4/quotearg.m4 (gl_QUOTEARG): Remove mbsinit test and
115172         AC_TYPE_MBSTATE_T, AC_FUNC_MBRTOWC invocations.
115174         * modules/trim (configure.ac): Remove AC_FUNC_MBRTOWC invocation.
115176 2009-03-08  Bruno Haible  <bruno@clisp.org>
115178         Tests for module 'unicase/ulc-casecmp'.
115179         * modules/unicase/ulc-casecmp-tests: New file.
115180         * tests/unicase/test-ulc-casecmp1.sh: New file.
115181         * tests/unicase/test-ulc-casecmp2.sh: New file.
115182         * tests/unicase/test-ulc-casecmp.c: New file.
115184         New module 'unicase/ulc-casecmp'.
115185         * lib/unicase.h (ulc_casecmp): New declaration.
115186         * lib/unicase/ulc-casecmp.c: New file.
115187         * lib/unicase/u-casecmp.h (FUNC): Change argument types to
115188         'const SRC_UNIT *'.
115189         * lib/unicase/u8-casecmp.c (SRC_UNIT): Define like UNIT.
115190         * lib/unicase/u16-casecmp.c (SRC_UNIT): Likewise.
115191         * lib/unicase/u32-casecmp.c (SRC_UNIT): Likewise.
115192         * modules/unicase/ulc-casecmp: New file.
115194         Tests for module 'unicase/u32-is-cased'.
115195         * modules/unicase/u32-is-cased-tests: New file.
115196         * tests/unicase/test-u32-is-cased.c: New file.
115198         Tests for module 'unicase/u16-is-cased'.
115199         * modules/unicase/u16-is-cased-tests: New file.
115200         * tests/unicase/test-u16-is-cased.c: New file.
115202         Tests for module 'unicase/u8-is-cased'.
115203         * modules/unicase/u8-is-cased-tests: New file.
115204         * tests/unicase/test-u8-is-cased.c: New file.
115205         * tests/unicase/test-is-cased.h: New file.
115207         New module 'unicase/u32-is-cased'.
115208         * lib/unicase/u32-is-cased.c: New file.
115209         * modules/unicase/u32-is-cased: New file.
115211         New module 'unicase/u16-is-cased'.
115212         * lib/unicase/u16-is-cased.c: New file.
115213         * modules/unicase/u16-is-cased: New file.
115215         New module 'unicase/u8-is-cased'.
115216         * lib/unicase/u8-is-cased.c: New file.
115217         * lib/unicase/u-is-cased.h: New file.
115218         * modules/unicase/u8-is-cased: New file.
115220         Tests for module 'unicase/u32-is-casefolded'.
115221         * modules/unicase/u32-is-casefolded-tests: New file.
115222         * tests/unicase/test-u32-is-casefolded.c: New file.
115224         Tests for module 'unicase/u16-is-casefolded'.
115225         * modules/unicase/u16-is-casefolded-tests: New file.
115226         * tests/unicase/test-u16-is-casefolded.c: New file.
115228         Tests for module 'unicase/u8-is-casefolded'.
115229         * modules/unicase/u8-is-casefolded-tests: New file.
115230         * tests/unicase/test-u8-is-casefolded.c: New file.
115231         * tests/unicase/test-is-casefolded.h: New file.
115233         New module 'unicase/u32-is-casefolded'.
115234         * lib/unicase/u32-is-casefolded.c: New file.
115235         * modules/unicase/u32-is-casefolded: New file.
115237         New module 'unicase/u16-is-casefolded'.
115238         * lib/unicase/u16-is-casefolded.c: New file.
115239         * modules/unicase/u16-is-casefolded: New file.
115241         New module 'unicase/u8-is-casefolded'.
115242         * lib/unicase/u8-is-casefolded.c: New file.
115243         * modules/unicase/u8-is-casefolded: New file.
115245         Tests for module 'unicase/u32-is-titlecase'.
115246         * modules/unicase/u32-is-titlecase-tests: New file.
115247         * tests/unicase/test-u32-is-titlecase.c: New file.
115249         Tests for module 'unicase/u16-is-titlecase'.
115250         * modules/unicase/u16-is-titlecase-tests: New file.
115251         * tests/unicase/test-u16-is-titlecase.c: New file.
115253         Tests for module 'unicase/u8-is-titlecase'.
115254         * modules/unicase/u8-is-titlecase-tests: New file.
115255         * tests/unicase/test-u8-is-titlecase.c: New file.
115256         * tests/unicase/test-is-titlecase.h: New file.
115258         New module 'unicase/u32-is-titlecase'.
115259         * lib/unicase/u32-is-titlecase.c: New file.
115260         * modules/unicase/u32-is-titlecase: New file.
115262         New module 'unicase/u16-is-titlecase'.
115263         * lib/unicase/u16-is-titlecase.c: New file.
115264         * modules/unicase/u16-is-titlecase: New file.
115266         New module 'unicase/u8-is-titlecase'.
115267         * lib/unicase/u8-is-titlecase.c: New file.
115268         * modules/unicase/u8-is-titlecase: New file.
115270         Tests for module 'unicase/u32-is-lowercase'.
115271         * modules/unicase/u32-is-lowercase-tests: New file.
115272         * tests/unicase/test-u32-is-lowercase.c: New file.
115274         Tests for module 'unicase/u16-is-lowercase'.
115275         * modules/unicase/u16-is-lowercase-tests: New file.
115276         * tests/unicase/test-u16-is-lowercase.c: New file.
115278         Tests for module 'unicase/u8-is-lowercase'.
115279         * modules/unicase/u8-is-lowercase-tests: New file.
115280         * tests/unicase/test-u8-is-lowercase.c: New file.
115281         * tests/unicase/test-is-lowercase.h: New file.
115283         New module 'unicase/u32-is-lowercase'.
115284         * lib/unicase/u32-is-lowercase.c: New file.
115285         * modules/unicase/u32-is-lowercase: New file.
115287         New module 'unicase/u16-is-lowercase'.
115288         * lib/unicase/u16-is-lowercase.c: New file.
115289         * modules/unicase/u16-is-lowercase: New file.
115291         New module 'unicase/u8-is-lowercase'.
115292         * lib/unicase/u8-is-lowercase.c: New file.
115293         * modules/unicase/u8-is-lowercase: New file.
115295         Tests for module 'unicase/u32-is-uppercase'.
115296         * modules/unicase/u32-is-uppercase-tests: New file.
115297         * tests/unicase/test-u32-is-uppercase.c: New file.
115299         Tests for module 'unicase/u16-is-uppercase'.
115300         * modules/unicase/u16-is-uppercase-tests: New file.
115301         * tests/unicase/test-u16-is-uppercase.c: New file.
115303         Tests for module 'unicase/u8-is-uppercase'.
115304         * modules/unicase/u8-is-uppercase-tests: New file.
115305         * tests/unicase/test-u8-is-uppercase.c: New file.
115306         * tests/unicase/test-is-uppercase.h: New file.
115308         New module 'unicase/u32-is-uppercase'.
115309         * lib/unicase/u32-is-uppercase.c: New file.
115310         * modules/unicase/u32-is-uppercase: New file.
115312         New module 'unicase/u16-is-uppercase'.
115313         * lib/unicase/u16-is-uppercase.c: New file.
115314         * modules/unicase/u16-is-uppercase: New file.
115316         New module 'unicase/u8-is-uppercase'.
115317         * lib/unicase/u8-is-uppercase.c: New file.
115318         * modules/unicase/u8-is-uppercase: New file.
115320         New module 'unicase/u32-is-invariant'.
115321         * lib/unicase/u32-is-invariant.c: New file.
115322         * modules/unicase/u32-is-invariant: New file.
115324         New module 'unicase/u16-is-invariant'.
115325         * lib/unicase/u16-is-invariant.c: New file.
115326         * modules/unicase/u16-is-invariant: New file.
115328         New module 'unicase/u8-is-invariant'.
115329         * lib/unicase/u8-is-invariant.c: New file.
115330         * lib/unicase/invariant.h: New file.
115331         * lib/unicase/u-is-invariant.h: New file.
115332         * modules/unicase/u8-is-invariant: New file.
115334         Tests for module 'unicase/u32-casecoll'.
115335         * modules/unicase/u32-casecoll-tests: New file.
115336         * tests/unicase/test-u32-casecoll.c: New file.
115338         Tests for module 'unicase/u16-casecoll'.
115339         * modules/unicase/u16-casecoll-tests: New file.
115340         * tests/unicase/test-u16-casecoll.c: New file.
115342         Tests for module 'unicase/u8-casecoll'.
115343         * modules/unicase/u8-casecoll-tests: New file.
115344         * tests/unicase/test-u8-casecoll.c: New file.
115346         New module 'unicase/u32-casecoll'.
115347         * lib/unicase/u32-casecoll.c: New file.
115348         * modules/unicase/u32-casecoll: New file.
115350         New module 'unicase/u16-casecoll'.
115351         * lib/unicase/u16-casecoll.c: New file.
115352         * modules/unicase/u16-casecoll: New file.
115354         New module 'unicase/u8-casecoll'.
115355         * lib/unicase/u8-casecoll.c: New file.
115356         * lib/unicase/u-casecoll.h: New file.
115357         * modules/unicase/u8-casecoll: New file.
115359         New module 'unicase/u32-casexfrm'.
115360         * lib/unicase/u32-casexfrm.c: New file.
115361         * modules/unicase/u32-casexfrm: New file.
115363         New module 'unicase/u16-casexfrm'.
115364         * lib/unicase/u16-casexfrm.c: New file.
115365         * modules/unicase/u16-casexfrm: New file.
115367         New module 'unicase/u8-casexfrm'.
115368         * lib/unicase/u8-casexfrm.c: New file.
115369         * lib/unicase/u-casexfrm.h: New file.
115370         * modules/unicase/u8-casexfrm: New file.
115372         Tests for module 'unicase/u32-casecmp'.
115373         * modules/unicase/u32-casecmp-tests: New file.
115374         * tests/unicase/test-u32-casecmp.c: New file.
115376         Tests for module 'unicase/u16-casecmp'.
115377         * modules/unicase/u16-casecmp-tests: New file.
115378         * tests/unicase/test-u16-casecmp.c: New file.
115380         Tests for module 'unicase/u8-casecmp'.
115381         * modules/unicase/u8-casecmp-tests: New file.
115382         * tests/unicase/test-u8-casecmp.c: New file.
115383         * tests/unicase/test-casecmp.h: New file.
115385         New module 'unicase/u32-casecmp'.
115386         * lib/unicase/u32-casecmp.c: New file.
115387         * modules/unicase/u32-casecmp: New file.
115389         New module 'unicase/u16-casecmp'.
115390         * lib/unicase/u16-casecmp.c: New file.
115391         * modules/unicase/u16-casecmp: New file.
115393         New module 'unicase/u8-casecmp'.
115394         * lib/unicase/u8-casecmp.c: New file.
115395         * lib/unicase/u-casecmp.h: New file.
115396         * modules/unicase/u8-casecmp: New file.
115398         Tests for module 'unicase/u32-casefold'.
115399         * modules/unicase/u32-casefold-tests: New file.
115400         * tests/unicase/test-u32-casefold.c: New file.
115402         Tests for module 'unicase/u16-casefold'.
115403         * modules/unicase/u16-casefold-tests: New file.
115404         * tests/unicase/test-u16-casefold.c: New file.
115406         Tests for module 'unicase/u8-casefold'.
115407         * modules/unicase/u8-casefold-tests: New file.
115408         * tests/unicase/test-u8-casefold.c: New file.
115410         New module 'unicase/u32-casefold'.
115411         * lib/unicase/u32-casefold.c: New file.
115412         * modules/unicase/u32-casefold: New file.
115414         New module 'unicase/u16-casefold'.
115415         * lib/unicase/u16-casefold.c: New file.
115416         * modules/unicase/u16-casefold: New file.
115418         New module 'unicase/u8-casefold'.
115419         * lib/unicase/u8-casefold.c: New file.
115420         * lib/unicase/u-casefold.h: New file.
115421         * modules/unicase/u8-casefold: New file.
115423         New module 'unicase/tocasefold'.
115424         * lib/unicase/casefold.h: New file.
115425         * lib/unicase/tocasefold.c: New file.
115426         * lib/unicase/tocasefold.h: New file, generated by gen-uni-tables.c.
115427         * modules/unicase/tocasefold: New file.
115429         Tests for module 'unicase/u32-totitle'.
115430         * modules/unicase/u32-totitle-tests: New file.
115431         * tests/unicase/test-u32-totitle.c: New file.
115433         Tests for module 'unicase/u16-totitle'.
115434         * modules/unicase/u16-totitle-tests: New file.
115435         * tests/unicase/test-u16-totitle.c: New file.
115437         Tests for module 'unicase/u8-totitle'.
115438         * modules/unicase/u8-totitle-tests: New file.
115439         * tests/unicase/test-u8-totitle.c: New file.
115441         New module 'unicase/u32-totitle'.
115442         * lib/unicase/u32-totitle.c: New file.
115443         * modules/unicase/u32-totitle: New file.
115445         New module 'unicase/u16-totitle'.
115446         * lib/unicase/u16-totitle.c: New file.
115447         * modules/unicase/u16-totitle: New file.
115449         New module 'unicase/u8-totitle'.
115450         * lib/unicase/u8-totitle.c: New file.
115451         * lib/unicase/u-totitle.h: New file.
115452         * modules/unicase/u8-totitle: New file.
115454         Tests for module 'unicase/u32-tolower'.
115455         * modules/unicase/u32-tolower-tests: New file.
115456         * tests/unicase/test-u32-tolower.c: New file.
115458         Tests for module 'unicase/u16-tolower'.
115459         * modules/unicase/u16-tolower-tests: New file.
115460         * tests/unicase/test-u16-tolower.c: New file.
115462         Tests for module 'unicase/u8-tolower'.
115463         * modules/unicase/u8-tolower-tests: New file.
115464         * tests/unicase/test-u8-tolower.c: New file.
115466         New module 'unicase/u32-tolower'.
115467         * lib/unicase/u32-tolower.c: New file.
115468         * modules/unicase/u32-tolower: New file.
115470         New module 'unicase/u16-tolower'.
115471         * lib/unicase/u16-tolower.c: New file.
115472         * modules/unicase/u16-tolower: New file.
115474         New module 'unicase/u8-tolower'.
115475         * lib/unicase/u8-tolower.c: New file.
115476         * modules/unicase/u8-tolower: New file.
115478         Tests for module 'unicase/u32-toupper'.
115479         * modules/unicase/u32-toupper-tests: New file.
115480         * tests/unicase/test-u32-toupper.c: New file.
115482         Tests for module 'unicase/u16-toupper'.
115483         * modules/unicase/u16-toupper-tests: New file.
115484         * tests/unicase/test-u16-toupper.c: New file.
115486         Tests for module 'unicase/u8-toupper'.
115487         * modules/unicase/u8-toupper-tests: New file.
115488         * tests/unicase/test-u8-toupper.c: New file.
115490         New module 'unicase/u32-toupper'.
115491         * lib/unicase/u32-toupper.c: New file.
115492         * modules/unicase/u32-toupper: New file.
115494         New module 'unicase/u16-toupper'.
115495         * lib/unicase/u16-toupper.c: New file.
115496         * modules/unicase/u16-toupper: New file.
115498         New module 'unicase/u8-toupper'.
115499         * lib/unicase/u8-toupper.c: New file.
115500         * modules/unicase/u8-toupper: New file.
115502         New module 'unicase/u32-casemap'.
115503         * lib/unicase/u32-casemap.c: New file.
115504         * modules/unicase/u32-casemap: New file.
115506         New module 'unicase/u16-casemap'.
115507         * lib/unicase/u16-casemap.c: New file.
115508         * modules/unicase/u16-casemap: New file.
115510         New module 'unicase/u8-casemap'.
115511         * lib/unicase/unicasemap.h: New file.
115512         * lib/unicase/u8-casemap.c: New file.
115513         * lib/unicase/u-casemap.h: New file.
115514         * modules/unicase/u8-casemap: New file.
115516         New module 'unicase/special-casing'.
115517         * lib/unicase/special-casing.h: New file.
115518         * lib/unicase/special-casing.c: New file.
115519         * lib/unicase/special-casing-table.gperf: New file, generated by
115520         gen-uni-tables.c.
115521         * modules/unicase/special-casing: New file.
115523         Tests for module 'unicase/locale-language'.
115524         * modules/unicase/locale-language-tests: New file.
115525         * tests/unicase/test-locale-language.sh: New file.
115526         * tests/unicase/test-locale-language.c: New file.
115528         New module 'unicase/locale-language'.
115529         * lib/unicase/locale-language.c: New file.
115530         * lib/unicase/locale-languages.gperf: New file.
115531         * modules/unicase/locale-language: New file.
115533         Generate more tables for case conversion and case folding.
115534         * lib/gen-uni-tables.c (SCC_*): New enum items.
115535         (struct special_casing_rule): New type.
115536         (casing_rules, num_casing_rules, allocated_casing_rules): New
115537         variables.
115538         (add_casing_rule, fill_casing_rules): New functions.
115539         (struct casefold_rule): New type.
115540         (casefolding_rules, num_casefolding_rules,
115541         allocated_casefolding_rules): New variables.
115542         (fill_casefolding_rules): New function.
115543         (unicode_casefold): New variable.
115544         (to_casefold, redistribute_casefolding_rules, compare_casing_rules,
115545         sort_casing_rules, output_casing_rules): New functions.
115546         (main): Accept to more arguments: SpecialCasing.txt and
115547         CaseFolding.txt. Invoke fill_casing_rules, fill_casefolding_rules,
115548         redistribute_casefolding_rules, sort_casing_rules, output_casing_rules.
115549         Output mapping for casefolding.
115551         * lib/unicase.h: Include stdbool.h, uninorm.h.
115552         (u8_toupper, u16_toupper, u32_toupper, u8_tolower, u16_tolower,
115553         u32_tolower, u8_totitle, u16_totitle, u32_totitle): Add nf argument.
115554         (u8_casefold, u16_casefold, u32_casefold): Add iso639_language and nf
115555         arguments.
115556         (u8_casecmp, u16_casecmp, u32_casecmp): Add iso639_language, nf,
115557         resultp arguments.
115558         (u8_casexfrm, u16_casexfrm, u32_casexfrm): New declarations.
115559         (u8_casecoll, u16_casecoll, u32_casecoll): Add iso639_language, nf,
115560         resultp arguments.
115561         (u8_is_uppercase, u16_is_uppercase, u32_is_uppercase, u8_is_lowercase,
115562         u16_is_lowercase, u32_is_lowercase, u8_is_titlecase, u16_is_titlecase,
115563         u32_is_titlecase, u8_is_casefolded, u16_is_casefolded,
115564         u32_is_casefolded, u8_is_cased, u16_is_cased, u32_is_cased): New
115565         declarations.
115566         * modules/unicase/base (Depends-on): Add uninorm/base, stdbool.
115568 2009-03-08  Bruno Haible  <bruno@clisp.org>
115570         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
115571         u16_normcoll, u32_normcoll): Rename argument 'result' to 'resultp'.
115572         * lib/uninorm/u-normcmp.h (FUNC): Likewise.
115573         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
115575 2009-03-07  Bruno Haible  <bruno@clisp.org>
115577         Adjust u*_normcmp, u*_normcoll API.
115578         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
115579         u16_normcoll, u32_normcoll): Change failure conventions.
115580         * lib/uninorm/u-normcmp.h (FUNC): Upon failure, store the error code in
115581         errno and return -1.
115582         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
115584 2009-03-07  Bruno Haible  <bruno@clisp.org>
115586         Tests for module 'uninorm/u32-normcoll'.
115587         * modules/uninorm/u32-normcoll-tests: New file.
115588         * tests/uninorm/test-u32-normcoll.c: New file.
115590         Tests for module 'uninorm/u16-normcoll'.
115591         * modules/uninorm/u16-normcoll-tests: New file.
115592         * tests/uninorm/test-u16-normcoll.c: New file.
115594         Tests for module 'uninorm/u8-normcoll'.
115595         * modules/uninorm/u8-normcoll-tests: New file.
115596         * tests/uninorm/test-u8-normcoll.c: New file.
115598 2009-03-07  Bruno Haible  <bruno@clisp.org>
115600         * tests/uninorm/test-u32-normcmp.h: New file, extracted from
115601         tests/uninorm/test-u32-normcmp.c.
115602         * tests/uninorm/test-u32-normcmp.c: Include it.
115603         (test_nonascii): New function, extracted from main. Add some more
115604         tests.
115605         (main): Invoke test_ascii and test_nonascii.
115606         * modules/uninorm/u32-normcmp-tests (Files): Add
115607         tests/uninorm/test-u32-normcmp.h.
115608         (Depends-on): Remove uninorm/u32-normcmp.
115610         * tests/uninorm/test-u16-normcmp.h: New file, extracted from
115611         tests/uninorm/test-u16-normcmp.c.
115612         * tests/uninorm/test-u16-normcmp.c: Include it.
115613         (test_nonascii): New function, extracted from main. Add some more
115614         tests.
115615         (main): Invoke test_ascii and test_nonascii.
115616         * modules/uninorm/u16-normcmp-tests (Files): Add
115617         tests/uninorm/test-u16-normcmp.h.
115618         (Depends-on): Remove uninorm/u16-normcmp.
115620         * tests/uninorm/test-u8-normcmp.h: New file, extracted from
115621         tests/uninorm/test-u8-normcmp.c.
115622         * tests/uninorm/test-u8-normcmp.c: Include it.
115623         (test_nonascii): New function, extracted from main. Add some more
115624         tests.
115625         (main): Invoke test_ascii and test_nonascii.
115626         * modules/uninorm/u8-normcmp-tests (Files): Add
115627         tests/uninorm/test-u8-normcmp.h.
115628         (Depends-on): Remove uninorm/u8-normcmp.
115630 2009-03-07  Bruno Haible  <bruno@clisp.org>
115632         New module 'uninorm/u32-normcoll'.
115633         * lib/uninorm/u32-normcoll.c: New file.
115634         * modules/uninorm/u32-normcoll: New file.
115636         New module 'uninorm/u16-normcoll'.
115637         * lib/uninorm/u16-normcoll.c: New file.
115638         * modules/uninorm/u16-normcoll: New file.
115640         New module 'uninorm/u8-normcoll'.
115641         * lib/uninorm.h (u8_normcoll, u16_normcoll, u32_normcoll): New
115642         declarations.
115643         * lib/uninorm/u8-normcoll.c: New file.
115644         * lib/uninorm/u-normcoll.h: New file.
115645         * modules/uninorm/u8-normcoll: New file.
115647         New module 'uninorm/u32-normxfrm'.
115648         * lib/uninorm/u32-normxfrm.c: New file.
115649         * modules/uninorm/u32-normxfrm: New file.
115651         New module 'uninorm/u16-normxfrm'.
115652         * lib/uninorm/u16-normxfrm.c: New file.
115653         * modules/uninorm/u16-normxfrm: New file.
115655         New module 'uninorm/u8-normxfrm'.
115656         * lib/uninorm.h (u8_normxfrm, u16_normxfrm, u32_normxfrm): New
115657         declarations.
115658         * lib/uninorm/u8-normxfrm.c: New file.
115659         * lib/uninorm/u-normxfrm.h: New file.
115660         * modules/uninorm/u8-normxfrm: New file.
115662 2009-03-07  Bruno Haible  <bruno@clisp.org>
115664         * modules/uninorm/u8-normcmp (Depends-on): Add uninorm/base.
115665         * modules/uninorm/u16-normcmp (Depends-on): Likewise.
115666         * modules/uninorm/u32-normcmp (Depends-on): Likewise.
115668 2009-03-07  Bruno Haible  <bruno@clisp.org>
115670         New module 'memxfrm'.
115671         * lib/memxfrm.h: New file.
115672         * lib/memxfrm.c: New file.
115673         * modules/memxfrm: New file.
115675 2009-03-07  Bruno Haible  <bruno@clisp.org>
115677         New module 'memcmp2'.
115678         * lib/memcmp2.h: New file.
115679         * lib/memcmp2.c: New file.
115680         * modules/memcmp2: New file.
115682 2009-03-07  Bruno Haible  <bruno@clisp.org>
115684         Tests for module 'uninorm/decomposing-form'.
115685         * modules/uninorm/decomposing-form-tests: New file.
115686         * tests/uninorm/test-decomposing-form.c: New file.
115688         New module 'uninorm/decomposing-form'.
115689         * lib/uninorm.h (uninorm_decomposing_form): New declaration.
115690         * lib/uninorm/normalize-internal.h (struct unicode_normalization_form):
115691         Add 'decomposing_variant' field.
115692         * lib/uninorm/decomposing-form.c: New file.
115693         * lib/uninorm/nfc.c (uninorm_nfc): Update.
115694         * lib/uninorm/nfd.c (uninorm_nfd): Update.
115695         * lib/uninorm/nfkc.c (uninorm_nfkc): Update.
115696         * lib/uninorm/nfkd.c (uninorm_nfkd): Update.
115697         * modules/uninorm/decomposing-form: New file.
115698         * modules/uninorm/nfc (Depends-on): Add uninorm/nfd.
115699         * modules/uninorm/nfkc (Depends-on): Add uninorm/nfkd.
115701 2009-03-07  Bruno Haible  <bruno@clisp.org>
115703         * lib/uninorm/u-normcmp.h (FUNC): Use stack=allocated buffers for small
115704         strings.
115706 2009-03-06  Bruno Haible  <bruno@clisp.org>
115708         Tests for module 'uninorm/u32-normcmp'.
115709         * tests/uninorm/test-u32-normcmp.c: New file.
115710         * modules/uninorm/u32-normcmp-tests: New file.
115712         Tests for module 'uninorm/u16-normcmp'.
115713         * tests/uninorm/test-u16-normcmp.c: New file.
115714         * modules/uninorm/u16-normcmp-tests: New file.
115716         Tests for module 'uninorm/u8-normcmp'.
115717         * tests/uninorm/test-u8-normcmp.c: New file.
115718         * modules/uninorm/u8-normcmp-tests: New file.
115720         New module 'uninorm/u32-normcmp'.
115721         * lib/uninorm/u32-normcmp.c: New file.
115722         * modules/uninorm/u32-normcmp: New file.
115724         New module 'uninorm/u16-normcmp'.
115725         * lib/uninorm/u16-normcmp.c: New file.
115726         * modules/uninorm/u16-normcmp: New file.
115728         New module 'uninorm/u8-normcmp'.
115729         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp): New
115730         declarations.
115731         * lib/uninorm/u8-normcmp.c: New file.
115732         * lib/uninorm/u-normcmp.h: New file.
115733         * modules/uninorm/u8-normcmp: New file.
115735 2009-03-06  Bruno Haible  <bruno@clisp.org>
115737         * lib/w32spawn.h (dup_noinherit): Add cast, to avoid gcc warning.
115738         Reported by Eric Blake.
115740 2009-03-06  Eric Blake  <ebb9@byu.net>
115741             Bruno Haible  <bruno@clisp.org>
115743         * lib/spawni.c (__spawni) [WIN32_NATIVE]: Define as a stub.
115744         * modules/posix_spawn-tests (configure.ac): Define POSIX_SPAWN_PORTED
115745         condition.
115746         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
115747         * modules/posix_spawnp-tests (configure.ac): Define POSIX_SPAWN_PORTED
115748         condition.
115749         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
115751 2009-03-06  Eric Blake  <ebb9@byu.net>
115753         * lib/execute.c (execute) [WIN32_NATIVE]: Cast arguments of spawnvpe,
115754         to avoid compiler warnings.
115755         * lib/pipe.c (create_pipe) [WIN32_NATIVE]: Likewise.
115757 2009-03-05  Bruno Haible  <bruno@clisp.org>
115759         * tests/test-ftell.c (main): Disable test beyond end of file on
115760         FreeMiNT.
115761         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
115763 2009-03-05  Kamil Dudka  <kdudka@redhat.com>
115765         * lib/filevercmp.c: Move hidden files up in ordering.
115766         * tests/test-filevercmp.c: Add tests for hidden files.
115768 2009-03-04  Bruno Haible  <bruno@clisp.org>
115770         * modules/visibility (Makefile.am): Augment AM_CFLAGS.
115771         * gnulib-tool (func_emit_lib_Makefile_am): Emit initialization of
115772         AM_CFLAGS.
115773         Reported by Simon Josefsson.
115775 2009-03-03  Bruno Haible  <bruno@clisp.org>
115777         * doc/visibility.texi: Recommend to use HAVE_VISIBILITY as a C macro.
115778         Reported by Simon Josefsson.
115780         * doc/ld-version-script.texi: Update node reference.
115782 2009-03-03  Bruno Haible  <bruno@clisp.org>
115784         * modules/visibility (License): Change to 'unlimited'.
115785         Suggested by Simon Josefsson.
115787 2009-03-03  Jim Meyering  <meyering@redhat.com>
115789         unlinkdir: cannot_unlink_dir may modify process state
115790         * lib/unlinkdir.c (cannot_unlink_dir): Add a comment warning that
115791         it's neither thread-safe nor appropriate for use in a library.
115793 2009-03-03  Eric Blake  <ebb9@byu.net>
115795         test-closein: silence test under Darwin
115796         * tests/test-closein.sh: Ignore stderr from cat, since we don't
115797         care if it dies from EPIPE or EBADF.
115799 2009-03-03  Bruno Haible  <bruno@clisp.org>
115801         * doc/gnulib.texi: Include visibility.texi and ld-version-script.texi
115802         earlier.
115803         * doc/visibility.texi: Fix @node and @section.
115805 2009-03-03  Simon Josefsson  <simon@josefsson.org>
115807         * doc/gnulib.texi: Link to sections for ld version script and
115808         visibility.
115809         * doc/visibility.texi: Add @node and @section.
115810         * modules/ld-version-script: New module.
115811         * m4/ld-version-script.m4: New file.
115812         * doc/ld-version-script.texi: New file.
115814 2009-03-02  David Lutterkort  <lutter@redhat.com>
115816         * lib/safe-alloc.h (__GNUC_PREREQ): New macro.
115817         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
115819 2009-03-02  Bruno Haible  <bruno@clisp.org>
115821         * doc/visibility.texi: Mention libtool's -export-symbols option.
115823 2009-03-02  Jim Meyering  <meyering@redhat.com>
115825         announce-gen: new option: --no-print-checksums
115826         * build-aux/announce-gen (usage): Describe it.
115827         (print_checksums): Print a newline here, not in the [*] footnote.
115828         (main): Honor it.
115830 2009-03-01  Bruno Haible  <bruno@clisp.org>
115832         Use socklen_t in the native Windows replacements prototypes.
115833         * lib/sys_socket.in.h (rpl_getsockopt, rpl_setsockopt): Use socklen_t
115834         instead of 'int'.
115835         * lib/getsockopt.c (rpl_getsockopt): Likewise.
115836         * lib/setsockopt.c (rpl_setsockopt): Likewise.
115837         * modules/getsockopt (Depends-on): Add socklen.
115838         * modules/setsockopt (Depends-on): Add socklen.
115840 2009-03-01  Bruno Haible  <bruno@clisp.org>
115842         * gnulib-tool (sed): Do alias as "sed --posix" if sed's version is at
115843         least 4.2.
115845 2009-03-01  Eric Blake  <ebb9@byu.net>
115846             Bruno Haible  <bruno@clisp.org>
115848         * lib/wait-process.h (wait_subprocess): Describe effect of termsigp on
115849         error messages.
115850         * lib/wait-process.c (wait_subprocess): Omit error message about
115851         deadly signal sent to the child of termsigp != NULL.
115853 2009-03-01  Eric Blake  <ebb9@byu.net>
115855         * lib/wait-process.c (wait_subprocess): Remove unnecessary cast.
115857 2009-03-01  Bruno Haible  <bruno@clisp.org>
115859         Avoid a gcc warning.
115860         * tests/test-sched.c (b): Make global.
115861         Reported by Eric Blake.
115863 2009-01-19  Martin Lambers  <marlam@marlam.de>
115865         Provide POSIX semantics for socket timeout options on W32.
115866         * lib/setsockopt.c: Convert struct timeval to milliseconds on W32.
115867         * lib/getsockopt.c: Convert milliseconds to struct timeval on W32.
115868         * modules/setsockopt: Depend on sys_time module for struct timeval.
115869         * modules/getsockopt: Depend on sys_time module for struct timeval.
115871 2009-03-01  Simon Josefsson  <simon@josefsson.org>
115873         * lib/gai_strerror.c (values): Use EAI_INPROGRESS instead of
115874         __USE_GNU, for consistency with netdb.in.h.
115875         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
115877 2009-03-01  Bruno Haible  <bruno@clisp.org>
115879         More support for FreeMiNT.
115880         * lib/fseeko.c (rpl_fseeko): Complete last commit.
115881         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
115883 2009-03-01  Bruno Haible  <bruno@clisp.org>
115885         More support for FreeMiNT.
115886         * lib/fpurge.c (fpurge): Correct last commit.
115887         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
115889 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
115891         Fix unportable awk script in vc-list-files.
115892         * build-aux/vc-list-files: In the replacement awk script, use
115893         substr with a second argument of 1, not zero.
115894         Report by Simon Josefsson.
115896 2009-02-28  Bruno Haible  <bruno@clisp.org>
115898         More support for FreeMiNT.
115899         * lib/freading.c (freading) [__MINT__]: Use new macros that were added
115900         to FreeMiNT today.
115901         * lib/fwriting.c (fwriting): Likewise.
115902         Based on patch by Alan Hourihane <alanh@fairlite.co.uk>.
115904 2009-02-28  Bruno Haible  <bruno@clisp.org>
115906         * tests/test-freadseek.c (main): Disable test beyond end of file on
115907         FreeMiNT.
115908         * tests/test-ftello.c (main): Likewise.
115909         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
115911 2009-02-28  Bruno Haible  <bruno@clisp.org>
115913         Add tentative support for FreeMiNT.
115914         * lib/fbufmode.c (fbufmode) [__MINT__]: Add conditional code.
115915         * lib/fpurge.c (fpurge): Likewise.
115916         * lib/freadable.c (freadable): Likewise.
115917         * lib/freading.c (freading): Likewise.
115918         * lib/freadptr.c (freadptr): Likewise.
115919         * lib/freadseek.c (freadptrinc): Likewise.
115920         * lib/fseeko.c (rpl_fseeko): Likewise.
115921         * lib/fseterr.c (fseterr): Likewise.
115922         * lib/fwritable.c (fwritable): Likewise.
115923         * lib/fwriting.c (fwriting): Likewise.
115924         * lib/freadahead.c (freadahead): Likewise, based on code by Alan
115925         Hourihane.
115926         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
115928 2009-02-28  Bruno Haible  <bruno@clisp.org>
115930         * lib/wait-process.h (wait_subprocess): Clarify restriction regarding
115931         SIGCHLD.
115932         Reported by Jim Meyering.
115934 2009-02-28  Bruno Haible  <bruno@clisp.org>
115936         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Separate the two first tests.
115937         Mention the results of these tests on various platforms.
115938         * doc/posix-functions/fprintf.texi: Mention platforms in canonical
115939         order.
115940         * doc/posix-functions/printf.texi: Likewise.
115941         * doc/posix-functions/snprintf.texi: Likewise.
115942         * doc/posix-functions/sprintf.texi: Likewise.
115943         * doc/posix-functions/vfprintf.texi: Likewise.
115944         * doc/posix-functions/vprintf.texi: Likewise.
115945         * doc/posix-functions/vsnprintf.texi: Likewise.
115946         * doc/posix-functions/vsprintf.texi: Likewise.
115947         * doc/glibc-functions/obstack_printf.texi: Likewise.
115948         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
115950 2009-02-28  Bruno Haible  <bruno@clisp.org>
115952         * build-aux/po/Makefile.in.in: Update from GNU gettext 0.17.
115953         Reported by Loïc Minier <lool@dooz.org>.
115955 2009-02-27  Bruno Haible  <bruno@clisp.org>
115957         * gnulib-tool (func_import): Make the sed expression used to create the
115958         sed script for updating the .gitignore file POSIX compliant.
115959         Reported by Eric Blake.
115961 2009-02-27  Bruno Haible  <bruno@clisp.org>
115963         * gnulib-tool (sed): Don't alias as "sed --posix".
115964         Reported by Eric Blake.
115966 2009-02-27  Bruno Haible  <bruno@clisp.org>
115968         Avoid test link errors.
115969         * modules/uninorm/nfc-tests (test_u32_nfc_big_LDADD): New variable.
115970         * modules/uninorm/nfd-tests (test_u32_nfd_big_LDADD): New variable.
115971         * modules/uninorm/nfkc-tests (test_u32_nfkc_big_LDADD): New variable.
115972         * modules/uninorm/nfkd-tests (test_u32_nfkd_big_LDADD): New variable.
115973         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
115975 2009-02-27  Bruno Haible  <bruno@clisp.org>
115977         Avoid spurious "(cached)" in configure output.
115978         * m4/gnulib-common.m4 (gl_CACHE_VAL_SILENT): New macro.
115979         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Use it instead of AC_CACHE_VAL.
115980         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
115981         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
115982         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
115983         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Likewise.
115984         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
115985         * m4/stdarg.m4 (gl_STDARG_H): Likewise.
115986         Reported by Eric Blake.
115988 2009-02-27  Eric Blake  <ebb9@byu.net>
115990         printf: fix regression in previous patch
115991         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Fix compilation error.
115993 2009-02-27  Bruno Haible  <bruno@clisp.org>
115995         * lib/inttypes.in.h: Test merely whether _LP64 is defined, not its
115996         value.
115997         * lib/stdint.in.h: Likewise.
115998         Suggested by Eric Blake. Reported by Peter Bray <pdb_ml@yahoo.com.au>.
116000 2009-02-27  Eric Blake  <ebb9@byu.net>
116002         doc: mention more functions added in cygwin 1.7.0
116003         * doc/posix-functions/mbsnrtowcs.texi: Mention recent cygwin 1.7.0
116004         addition.
116005         * doc/posix-functions/open_wmemstream.texi: Likewise.
116006         * doc/posix-functions/wcsnlen.texi: Likewise.
116007         * doc/posix-functions/wcsnrtombs.texi: Likewise.
116008         * doc/posix-functions/wcstod.texi: Likewise.
116009         * doc/posix-functions/wcstof.texi: Likewise.
116010         * doc/posix-functions/wcstoimax.texi: Likewise.
116011         * doc/posix-functions/wcstok.texi: Likewise.
116012         * doc/posix-functions/wcstoumax.texi: Likewise.
116014         Detect bug in cygwin 1.5.x *printf on 1-character %ls.
116015         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Enhance filter.
116016         * doc/posix-functions/fprintf.texi: Update.
116017         * doc/posix-functions/printf.texi: Update.
116018         * doc/posix-functions/snprintf.texi: Update.
116019         * doc/posix-functions/sprintf.texi: Update.
116020         * doc/posix-functions/vfprintf.texi: Update.
116021         * doc/posix-functions/vprintf.texi: Update.
116022         * doc/posix-functions/vsnprintf.texi: Update.
116023         * doc/posix-functions/vsprintf.texi: Update.
116024         * doc/glibc-functions/obstack_printf.texi: Update.
116025         * doc/glibc-functions/obstack_vprintf.texi: Update.
116027 2009-02-26  Eric Blake  <ebb9@byu.net>
116029         avoid gcc 3.4.3 bug on long double NaN on Irix 6.5
116030         * tests/nan.h (NaNl): Rewrite as function on Irix, to avoid
116031         compilation bug by using runtime conversion.
116032         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
116033         * m4/isnanl.m4 (gl_FUNC_ISNANL): Likewise.
116034         * modules/ceill-tests (Files): Use nan.h.
116035         * modules/floorl-tests (Files): Likewise.
116036         * modules/frexpl-tests (Files): Likewise.
116037         * modules/isnanl-tests (Files): Likewise.
116038         * modules/ldexpl-tests (Files): Likewise.
116039         * modules/roundl-tests (Files): Likewise.
116040         * modules/truncl-tests (Files): Likewise.
116041         * tests/test-ceill.c (main): Use a working NaN.
116042         * tests/test-floorl.c (main): Likewise.
116043         * tests/test-frexpl.c (main): Likewise.
116044         * tests/test-isnan.c (test_long_double): Likewise.
116045         * tests/test-isnanl.h (main): Likewise.
116046         * tests/test-ldexpl.h (main): Likewise.
116047         * tests/test-roundl.h (main): Likewise.
116048         * tests/test-truncl.h (main): Likewise.
116049         See http://lists.gnu.org/r/bug-gnulib/2009-02/msg00190.html.
116051 2009-02-26  Eric Blake  <ebb9@byu.net>
116052             Bruno Haible  <bruno@clisp.org>
116054         Work around a *printf bug with %ls on Solaris.
116055         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Also test whether, when a
116056         precision is specified, sprintf stops converting the wide string
116057         argument when the number of bytes that have been produced by this
116058         conversion equals or exceeds the precision.
116059         * doc/posix-functions/fprintf.texi: Update.
116060         * doc/posix-functions/printf.texi: Update.
116061         * doc/posix-functions/snprintf.texi: Update.
116062         * doc/posix-functions/sprintf.texi: Update.
116063         * doc/posix-functions/vfprintf.texi: Update.
116064         * doc/posix-functions/vprintf.texi: Update.
116065         * doc/posix-functions/vsnprintf.texi: Update.
116066         * doc/posix-functions/vsprintf.texi: Update.
116067         * doc/glibc-functions/obstack_printf.texi: Update.
116068         * doc/glibc-functions/obstack_vprintf.texi: Update.
116070 2009-02-26  Eric Blake  <ebb9@byu.net>
116072         stdlib: favor compiler check of random.h
116073         * m4/stdlib_h.m4 (gl_STDLIB_H): Skip preprocessor check.  Needed
116074         to avoid an ObjC random.h installed by Swarm.
116076 2009-02-26  Bruno Haible  <bruno@clisp.org>
116078         Work around *printf bug with %g directive and 0.0 on HP-UX 10.20.
116079         * m4/printf.m4 (gl_PRINTF_INFINITE): Also test for %g output of -0.0.
116080         Reported by Gary V. Vaughan <gary@gnu.org>.
116082 2009-02-26  Bruno Haible  <bruno@clisp.org>
116084         Fix *printf behaviour regarding the %ls directive.
116085         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): New macro.
116086         * lib/vasnprintf.c (local_wcslen, VASNPRINTF): Handle
116087         NEED_PRINTF_DIRECTIVE_LS.
116088         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_LS): New macro.
116089         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
116090         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
116091         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS and test its result. Invoke
116092         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS.
116093         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Likewise.
116094         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
116095         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
116096         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
116097         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
116098         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
116099         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
116100         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
116101         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
116102         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
116103         * doc/posix-functions/fprintf.texi: Update.
116104         * doc/posix-functions/printf.texi: Update.
116105         * doc/posix-functions/snprintf.texi: Update.
116106         * doc/posix-functions/sprintf.texi: Update.
116107         * doc/posix-functions/vfprintf.texi: Update.
116108         * doc/posix-functions/vprintf.texi: Update.
116109         * doc/posix-functions/vsnprintf.texi: Update.
116110         * doc/posix-functions/vsprintf.texi: Update.
116111         * doc/glibc-functions/obstack_printf.texi: Update.
116112         * doc/glibc-functions/obstack_vprintf.texi: Update.
116113         Reported by Eric Blake.
116115 2009-02-25  Bruno Haible  <bruno@clisp.org>
116117         * m4/mbrtowc.m4 (gl_MBRTOWC_NUL_RETVAL): Update guess for Solaris 8
116118         with known value.
116119         Reported by Gary V. Vaughan <gary@gnu.org>.
116121 2009-02-25  Bruno Haible  <bruno@clisp.org>
116123         Work around mbrtowc bug in zh_CN.GB18030 locale on Solaris 8.
116124         * m4/mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): New macro.
116125         (gl_MBSTATE_T_BROKEN): Invoke it. Replace mbstate_t when it says "no".
116126         * doc/posix-functions/mbrtowc.texi: Document the Solaris 8 bug.
116127         Reported by Gary V. Vaughan <gary@gnu.org>.
116129 2009-02-25  Bruno Haible  <bruno@clisp.org>
116131         Work around broken INT8_MAX, UINT8_MAX etc. values on HP-UX 11.23.
116132         * m4/stdint.m4 (gl_STDINT_H): Also check whether the expansions of
116133         INT8_MAX, UINT8_MAX etc. contain casts to elementary types.
116134         * doc/posix-headers/stdint.texi: Mention the HP-UX bug.
116135         Reported by Gary V. Vaughan <gary@gnu.org>.
116137 2009-02-25  Eric Blake  <ebb9@byu.net>
116139         tests: skip fseek/ftell tests if ungetc is broken
116140         * m4/ungetc.m4: New file.
116141         * modules/fseek-tests: Split test, so ungetc dependency is
116142         separate from rest of test.
116143         * modules/fseeko-tests: Likewise.
116144         * modules/ftell-tests: Likewise.
116145         * modules/ftello-tests: Likewise.
116146         * tests/test-fseek.c (main): Isolate ungetc dependency.
116147         * tests/test-fseeko.c (main): Likewise.
116148         * tests/test-ftell.c (main): Likewise.
116149         * tests/test-ftello.c (main): Likewise.
116150         * tests/test-fseek2.sh: New file.
116151         * tests/test-fseeko2.sh: Likewise.
116152         * tests/test-ftell2.sh: Likewise.
116153         * tests/test-ftello2.sh: Likewise.
116155 2009-02-25  Ondřej Vašík  <ovasik@redhat.com>
116157         test-getaddrinfo: fix usage of skip return code 77
116158         * tests/test-gettaddrinfo.c: Return skip code 77 only
116159         for first occurrence of skip (4x77 is not 77)
116161 2009-02-25  Gary V. Vaughan  <gary@gnu.org>
116163         strtod: avoid C99 decl-after-statement
116164         * m4/strtod.m4 (gl_FUNC_STRTOD): Rearrange declaration.
116166 2009-02-24  Eric Blake  <ebb9@byu.net>
116168         strtod: detect HP-UX 11.31 bug
116169         * m4/strtod.m4 (gl_FUNC_STRTOD): Detect errno handling bug.
116170         Reported by Gary V. Vaughan.
116172 2009-02-23  Bruno Haible  <bruno@clisp.org>
116174         Fix invalid read past end of memory block.
116175         * lib/vasnprintf.c (DCHAR_SET): Define.
116176         (local_wcslen): Define only when needed.
116177         (local_strnlen, local_wcsnlen): New functions.
116178         (VASNPRINTF) [!USE_SNPRINTF && HAVE_WCHAR_T]: Implement the %s and %ls
116179         directives that involve a conversion ourselves.
116180         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for strnlen,
116181         wcsnlen, mbrtowc, wcrtomb.
116182         * tests/test-vasnprintf-posix.c (test_function): Add tests for %.*s.
116183         * tests/test-vasprintf-posix.c (test_function): Likewise.
116184         * tests/test-snprintf-posix.h (test_function): Likewise.
116185         * tests/test-sprintf-posix.h (test_function): Likewise.
116186         Reported by Ben Pfaff <blp@cs.stanford.edu>.
116188 2009-02-22  Bruno Haible  <bruno@clisp.org>
116190         Implement new clarified decomposition of Hangul syllables.
116191         * lib/uninorm/decomposition.c (uc_decomposition): For Hangul syllables
116192         of type LTV, return only a pairwise decomposition.
116193         * lib/uninorm/canonical-decomposition.c (uc_canonical_decomposition):
116194         Likewise.
116195         * tests/uninorm/test-decomposition.c (main): Updated expected result.
116196         * tests/uninorm/test-canonical-decomposition.c (main): Likewise.
116197         * tests/uninorm/test-compat-decomposition.c (main): Likewise.
116199 2009-02-22  Bruno Haible  <bruno@clisp.org>
116201         * lib/uninorm/u-normalize-internal.h (FUNC): At the end, handle
116202         zero-length results and shrink excess allocated memory.
116203         * tests/uninorm/test-u8-nfc.c (test_u8_nfc): Check empty string result.
116204         * tests/uninorm/test-u8-nfd.c (test_u8_nfd): Likewise.
116205         * tests/uninorm/test-u8-nfkc.c (test_u8_nfkc): Likewise.
116206         * tests/uninorm/test-u8-nfkd.c (test_u8_nfkd): Likewise.
116207         * tests/uninorm/test-u16-nfc.c (test_u16_nfc): Likewise.
116208         * tests/uninorm/test-u16-nfd.c (test_u16_nfd): Likewise.
116209         * tests/uninorm/test-u16-nfkc.c (test_u16_nfkc): Likewise.
116210         * tests/uninorm/test-u16-nfkd.c (test_u16_nfkd): Likewise.
116211         * tests/uninorm/test-u32-nfc.c (test_u32_nfc): Likewise.
116212         * tests/uninorm/test-u32-nfd.c (test_u32_nfd): Likewise.
116213         * tests/uninorm/test-u32-nfkc.c (test_u32_nfkc): Likewise.
116214         * tests/uninorm/test-u32-nfkd.c (test_u32_nfkd): Likewise.
116216 2009-02-21  Bruno Haible  <bruno@clisp.org>
116218         * doc/gnulib.texi: Include safe-alloc.texi earlier.
116219         * doc/safe-alloc.texi: Terminate sentences with a period. Use two
116220         spaces after a period. Put a space between a macro name and its
116221         argument list. Trivial rewordings.
116222         * lib/safe-alloc.c: Include safe-alloc.h right after config.h.
116223         * tests/test-safe-alloc.c: Likewise. Include stdlib.h.
116224         (main): Return 0 explicitly.
116226 2009-02-21  Bruno Haible  <bruno@clisp.org>
116228         Tests for module 'uninorm/filter'.
116229         * tests/uninorm/test-uninorm-filter-nfc.c: New file.
116230         * modules/uninorm/filter-tests: New file.
116232         New module 'uninorm/filter'.
116233         * lib/uninorm.h (uninorm_filter_create, uninorm_filter_write,
116234         uninorm_filter_flush, uninorm_filter_free): New declarations.
116235         * lib/uninorm/uninorm-filter.c: New file.
116236         * modules/uninorm/filter: New file.
116238 2009-02-21  Bruno Haible  <bruno@clisp.org>
116240         Tests for module 'uninorm/nfkc'.
116241         * tests/uninorm/test-nfkc.c: New file.
116242         * tests/uninorm/test-u8-nfkc.c: New file.
116243         * tests/uninorm/test-u16-nfkc.c: New file.
116244         * tests/uninorm/test-u32-nfkc.c: New file.
116245         * tests/uninorm/test-u32-nfkc-big.sh: New file.
116246         * tests/uninorm/test-u32-nfkc-big.c: New file.
116247         * modules/uninorm/nfkc-tests: New file.
116249         New module 'uninorm/nfkc'.
116250         * lib/uninorm/nfkc.c: New file.
116251         * modules/uninorm/nfkc: New file.
116253         Tests for module 'uninorm/nfkd'.
116254         * tests/uninorm/test-nfkd.c: New file.
116255         * tests/uninorm/test-u8-nfkd.c: New file.
116256         * tests/uninorm/test-u16-nfkd.c: New file.
116257         * tests/uninorm/test-u32-nfkd.c: New file.
116258         * tests/uninorm/test-u32-nfkd-big.sh: New file.
116259         * tests/uninorm/test-u32-nfkd-big.c: New file.
116260         * modules/uninorm/nfkd-tests: New file.
116262         New module 'uninorm/nfkd'.
116263         * lib/uninorm/nfkd.c: New file.
116264         * modules/uninorm/nfkd: New file.
116266         Tests for module 'uninorm/nfc'.
116267         * tests/uninorm/test-nfc.c: New file.
116268         * tests/uninorm/test-u8-nfc.c: New file.
116269         * tests/uninorm/test-u16-nfc.c: New file.
116270         * tests/uninorm/test-u32-nfc.c: New file.
116271         * tests/uninorm/test-u32-nfc-big.sh: New file.
116272         * tests/uninorm/test-u32-nfc-big.c: New file.
116273         * modules/uninorm/nfc-tests: New file.
116275         New module 'uninorm/nfc'.
116276         * lib/uninorm/nfc.c: New file.
116277         * modules/uninorm/nfc: New file.
116279         Tests for module 'uninorm/nfd'.
116280         * tests/uninorm/test-nfd.c: New file.
116281         * tests/uninorm/test-u8-nfd.c: New file.
116282         * tests/uninorm/test-u16-nfd.c: New file.
116283         * tests/uninorm/test-u32-nfd.c: New file.
116284         * tests/uninorm/test-u32-nfd-big.sh: New file.
116285         * tests/uninorm/test-u32-nfd-big.c: New file.
116286         * tests/uninorm/test-u32-normalize-big.h: New file.
116287         * tests/uninorm/test-u32-normalize-big.c: New file.
116288         * tests/uninorm/NormalizationTest.txt: New file, created from
116289         Unicode 5.1.0 NormalizationTest.txt.
116290         * modules/uninorm/nfd-tests: New file.
116292         New module 'uninorm/nfd'.
116293         * lib/uninorm/nfd.c: New file.
116294         * modules/uninorm/nfd: New file.
116296         New module 'uninorm/u32-normalize'.
116297         * lib/uninorm/u32-normalize.c: New file.
116298         * modules/uninorm/u32-normalize: New file.
116300         New module 'uninorm/u16-normalize'.
116301         * lib/uninorm/u16-normalize.c: New file.
116302         * modules/uninorm/u16-normalize: New file.
116304         New module 'uninorm/u8-normalize'.
116305         * lib/uninorm/u8-normalize.c: New file.
116306         * lib/uninorm/normalize-internal.h: New file.
116307         * lib/uninorm/u-normalize-internal.h: New file.
116308         * modules/uninorm/u8-normalize: New file.
116310         New module 'uninorm/decompose-internal'.
116311         * lib/uninorm/decompose-internal.c: New file.
116312         * modules/uninorm/decompose-internal: New file.
116314         Tests for module 'uninorm/composition'.
116315         * tests/uninorm/test-composition.c: New file.
116316         * modules/uninorm/composition-tests: New file.
116318         New module 'uninorm/composition'.
116319         * lib/uninorm/composition.c: New file.
116320         * lib/uninorm/composition-table.gperf: New file, generated by
116321         gen-uni-tables.
116322         * modules/uninorm/composition: New file.
116324         Tests for module 'uninorm/compat-decomposition'.
116325         * tests/uninorm/test-compat-decomposition.c: New file.
116326         * modules/uninorm/compat-decomposition-tests: New file.
116328         New module 'uninorm/compat-decomposition'.
116329         * lib/uninorm/decompose-internal.h: New file.
116330         * lib/uninorm/compat-decomposition.c: New file.
116331         * modules/uninorm/compat-decomposition: New file.
116333         Tests for module 'uninorm/canonical-decomposition'.
116334         * tests/uninorm/test-canonical-decomposition.c: New file.
116335         * modules/uninorm/canonical-decomposition-tests: New file.
116337         New module 'uninorm/canonical-decomposition'.
116338         * lib/uninorm/canonical-decomposition.c: New file.
116339         * modules/uninorm/canonical-decomposition: New file.
116341         Tests for module 'uninorm/decomposition'.
116342         * tests/uninorm/test-decomposition.c: New file.
116343         * modules/uninorm/decomposition-tests: New file.
116345         New module 'uninorm/decomposition'.
116346         * lib/uninorm/decomposition.c: New file.
116347         * modules/uninorm/decomposition: New file.
116349         New module 'uninorm/decomposition-table'.
116350         * lib/uninorm/decomposition-table.h: New file.
116351         * lib/uninorm/decomposition-table.c: New file.
116352         * lib/uninorm/decomposition-table1.h: New file, generated by
116353         gen-uni-tables.
116354         * lib/uninorm/decomposition-table2.h: New file, generated by
116355         gen-uni-tables.
116356         * modules/uninorm/decomposition-table: New file.
116358         * lib/gen-uni-tables.c (MAX_DECOMP_LENGTH): New macro.
116359         (UC_DECOMP_*): New enumeration items.
116360         (get_decomposition): New function.
116361         (struct decomp_table): New type.
116362         (output_decomposition, output_decomposition_tables): New functions.
116363         (unicode_composition_exclusions): New variable.
116364         (fill_composition_exclusions, debug_output_composition_tables): New
116365         functions.
116366         (main): Accept one more argument. Invoke fill_composition_exclusions.
116367         Output decomposition and composition tables.
116369         New module 'uninorm/base'.
116370         * lib/uninorm.h: New file.
116371         * lib/unictype.h: Update comment.
116372         * modules/uninorm/base: New file.
116374 2009-02-21  David Lutterkort  <lutter@redhat.com>
116376         Tests for module 'safe-alloc'.
116377         * tests/test-safe-alloc.c: New file.
116378         * modules/safe-alloc-tests: New file.
116380         New module 'safe-alloc'.
116381         * lib/safe-alloc.h: New file.
116382         * lib/safe-alloc.c: New file.
116383         * m4/safe-alloc.m4: New file.
116384         * modules/safe-alloc: New file.
116385         * doc/safe-alloc.texi: New file.
116386         * doc/gnulib.texi: Include it.
116387         * MODULES.html.sh (Memory management functions <stdlib.h>): Add
116388         safe-alloc.
116390 2009-02-18  Bruno Haible  <bruno@clisp.org>
116392         Fix link error on non-glibc systems.
116393         * modules/uniwbrk/ulc-wordbreaks-tests (test_ulc_wordbreaks_LDADD): New
116394         variable.
116395         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
116397 2009-02-18  Jim Meyering  <meyering@redhat.com>
116399         fts: avoid used-uninitialized error due to recent change
116400         * lib/fts.c (fts_read): Guard uses of the new member,
116401         parent->fts_n_dirs_remaining, since it's not relevant for
116402         the parent of a directory specified on the command-line.
116404 2009-02-17  James Youngman  <jay@gnu.org>
116405             Bruno Haible  <bruno@clisp.org>
116407         * m4/include_next.m4: Reformulate comment.
116409 2009-02-16  Jim Meyering  <meyering@redhat.com>
116411         fts: add #if guards so that the fts_lgpl module still builds
116412         * lib/fts.c: Guard just-added hash-table-using parts with
116413         #if GNULIB_FTS, so as not to break builds of the fts_lgpl module.
116414         Reported by Simon Josefsson.
116416 2009-02-15  Bruno Haible  <bruno@clisp.org>
116418         * modules/array-mergesort-tests: New file.
116419         * tests/test-array-mergesort.c: New file.
116421         New module 'array-mergesort'.
116422         * modules/array-mergesort: New file.
116423         * lib/array-mergesort.h: New file.
116425 2009-02-15  Bruno Haible  <bruno@clisp.org>
116427         Fix 2009-02-07 commit.
116428         * lib/gen-uni-tables.c (output_predicate, output_category,
116429         output_combclass, output_bidi_category, output_decimal_digit,
116430         output_digit, output_numeric, output_mirror, output_scripts,
116431         output_ident_category, output_simple_mapping): Fix format directives.
116432         (output_lbp, output_wbp): Don't convert -1 to a size_t implicitly.
116434 2009-02-15  Albert Chin-A-Young  <china@thewrittenword.com>
116436         * m4/include_next.m4: Update comment about IBM C 9.0/10.1 bug, now that
116437         fixes are available from IBM.
116439 2009-02-13  Jim Meyering  <meyering@redhat.com>
116441         fts: arrange not to stat non-directories in more cases
116442         This makes GNU find (when it doesn't need to stat each file)
116443         *much* more efficient at traversing reiserfs file systems.
116444         * lib/fts_.h (struct ftsent) [fts_n_dirs_remaining]: New member.
116445         (struct FTS) [fts_leaf_optimization_works_ht]: Add member.
116446         * lib/fts.c (fts_close): Free ->fts_leaf_optimization_works_ht.
116447         (S_MAGIC_REISERFS, S_MAGIC_PROC): Define.
116448         (leaf_optimization_applies): New function.
116449         (LCO_hash, LCO_compare): New helper functions.
116450         (link_count_optimize_ok): New function.
116451         (fts_stat): Initialize new member (if dir).
116452         (fts_read): Decrement parent's fts_n_dirs_remaining count if
116453         we've just stat'ed a directory.  Skip the stat call when possible.
116454         ---
116455         Note this AFS-related exchange:
116456         http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=143111
116457         and note find's pioctl call in find/fstype.c.
116458         But that is necessary only if you want to enable the
116459         optimization for AFS, and for now, I don't.
116461         fts: move a function definition "up" (no semantic change)
116462         * lib/fts.c (dirent_inode_sort_may_be_useful): Move definition
116463         "up" to precede upcoming use of a related function.
116465 2009-02-11  Jim Meyering  <meyering@redhat.com>
116467         fts: correct internal computation of nlinks (optimization-related)
116468         * lib/fts.c (fts_build): ISSET(FTS_NOSTAT) has no bearing on
116469         whether the current entry is a directory, so don't test it.
116471 2009-02-10  Bruno Haible  <bruno@clisp.org>
116473         Tests for module 'uniwbrk/ulc-wordbreaks'.
116474         * modules/uniwbrk/ulc-wordbreaks-tests: New file.
116475         * tests/uniwbrk/test-ulc-wordbreaks.sh: New file.
116476         * tests/uniwbrk/test-ulc-wordbreaks.c: New file.
116478         Tests for module 'uniwbrk/u32-wordbreaks'.
116479         * modules/uniwbrk/u32-wordbreaks-tests: New file.
116480         * tests/uniwbrk/test-u32-wordbreaks.c: New file.
116482         Tests for module 'uniwbrk/u16-wordbreaks'.
116483         * modules/uniwbrk/u16-wordbreaks-tests: New file.
116484         * tests/uniwbrk/test-u16-wordbreaks.c: New file.
116486         Tests for module 'uniwbrk/u8-wordbreaks'.
116487         * modules/uniwbrk/u8-wordbreaks-tests: New file.
116488         * tests/uniwbrk/test-u8-wordbreaks.c: New file.
116490 2009-02-10  Bruno Haible  <bruno@clisp.org>
116492         * modules/uniwbrk/u8-wordbreaks (Depends-on): Add uniwbrk/wordbreak
116493         property.
116494         * modules/uniwbrk/u16-wordbreaks (Depends-on): Likewise.
116495         * modules/uniwbrk/u32-wordbreaks (Depends-on): Likewise.
116496         * modules/uniwbrk/ulc-wordbreaks (Depends-on): Add localcharset.
116498 2009-02-10  Simon Josefsson  <simon@josefsson.org>
116500         * m4/sockets.m4: Call AC_C_INLINE since sockets.h now can use
116501         inline keywords.  Reported by Bruno Haible <bruno@clisp.org>.
116503 2009-02-10  Bruno Haible  <bruno@clisp.org>
116505         * lib/unilbrk/lbrktables.h: Renamed from lib/unilbrk/tables.h.
116506         * lib/unilbrk/lbrktables.c: Renamed from lib/unilbrk/tables.c.
116507         * modules/unilbrk/tables (Files, Makefile.am, Include): Update.
116508         * lib/unilbrk/u8-possible-linebreaks.c: Update.
116509         * lib/unilbrk/u16-possible-linebreaks.c: Likewise.
116510         * lib/unilbrk/u32-possible-linebreaks.c: Likewise.
116512 2009-02-09  Simon Josefsson  <simon@josefsson.org>
116514         * lib/sockets.h (gl_fd_to_handle): New function.
116516         * tests/test-sockets.c: Call gl_fd_to_handle.
116518 2009-02-09  Bruno Haible  <bruno@clisp.org>
116520         * doc/havelib.texi: Document the conventions on bi-arch systems.
116522 2009-02-08  Bruno Haible  <bruno@clisp.org>
116524         Document the AC_LIB_LINKFLAGS macro.
116525         * doc/havelib.texi: New file, mostly written on 2005-05-24.
116526         * doc/gnulib.texi: Include it.
116528 2009-02-08  Bruno Haible  <bruno@clisp.org>
116530         Fix wrong order of sections, compared to TOC.
116531         * doc/gnulib.texi: Include relocatable-maint.texi after the
116532         "Regular expressions" node, not before.
116534 2009-02-08  Bruno Haible  <bruno@clisp.org>
116536         Tests for module 'unicase/totitle'.
116537         * modules/unicase/totitle-tests: New file.
116539         Tests for module 'unicase/tolower'.
116540         * modules/unicase/tolower-tests: New file.
116542         Tests for module 'unicase/toupper'.
116543         * modules/unicase/toupper-tests: New file.
116544         * tests/unicase/test-mapping-part1.h: New file.
116545         * tests/unicase/test-mapping-part2.h: New file.
116547         New module 'unicase/totitle'.
116548         * modules/unicase/totitle: New file.
116549         * lib/unicase/totitle.c: New file.
116551         New module 'unicase/tolower'.
116552         * modules/unicase/tolower: New file.
116553         * lib/unicase/tolower.c: New file.
116555         New module 'unicase/toupper'.
116556         * modules/unicase/toupper: New file.
116557         * lib/unicase/toupper.c: New file.
116558         * lib/unicase/simple-mapping.h: New file.
116560         * lib/gen-uni-tables.c (output_simple_mapping_test): New function.
116561         (mapping_table): New structure.
116562         (output_simple_mapping): New function.
116563         (main): Invoke output_simple_mapping_test and output_simple_mapping.
116564         * modules/gen-uni-tables (Description): Update.
116565         * lib/unicase/toupper.h: New file, automatically generated by
116566         gen-uni-tables.
116567         * lib/unicase/tolower.h: New file, automatically generated by
116568         gen-uni-tables.
116569         * lib/unicase/totitle.h: New file, automatically generated by
116570         gen-uni-tables.
116571         * tests/unicase/test-uc_toupper.c: New file, automatically generated by
116572         gen-uni-tables.
116573         * tests/unicase/test-uc_tolower.c: New file, automatically generated by
116574         gen-uni-tables.
116575         * tests/unicase/test-uc_totitle.c: New file, automatically generated by
116576         gen-uni-tables.
116578         New module 'unicase/base'.
116579         * modules/unicase/base: New file.
116580         * lib/unicase.h: New file.
116582 2009-02-08  Bruno Haible  <bruno@clisp.org>
116584         New module 'uniwbrk/ulc-wordbreaks'.
116585         * modules/uniwbrk/ulc-wordbreaks: New file.
116586         * lib/uniwbrk/ulc-wordbreaks.c: New file.
116588         New module 'uniwbrk/u32-wordbreaks'.
116589         * modules/uniwbrk/u32-wordbreaks: New file.
116590         * lib/uniwbrk/u32-wordbreaks.c: New file.
116592         New module 'uniwbrk/u16-wordbreaks'.
116593         * modules/uniwbrk/u16-wordbreaks: New file.
116594         * lib/uniwbrk/u16-wordbreaks.c: New file.
116596         New module 'uniwbrk/u8-wordbreaks'.
116597         * modules/uniwbrk/u8-wordbreaks: New file.
116598         * lib/uniwbrk/u8-wordbreaks.c: New file.
116599         * lib/uniwbrk/u-wordbreaks.h: New file.
116601         New module 'uniwbrk/table'.
116602         * modules/uniwbrk/table: New file.
116603         * lib/uniwbrk/wbrktable.h: New file.
116604         * lib/uniwbrk/wbrktable.c: New file.
116606         New module 'uniwbrk/wordbreak-property'.
116607         * modules/uniwbrk/wordbreak-property: New file.
116608         * lib/uniwbrk/wordbreak-property.c: New file.
116610         * lib/gen-uni-tables.c (WBP_*): New enum items.
116611         (get_wbp, debug_output_wbp, debug_output_wbrk_tables): New functions.
116612         (unicode_org_wbp): New variable.
116613         (fill_org_wbp, debug_output_org_wbp, debug_output_org_wbrk_tables):
116614         New functions.
116615         (wbp_table): New structure.
116616         (output_wbp, output_wbrk_tables): New functions.
116617         (main): Accept additional argument. Invoke fill_org_wbp,
116618         debug_output_wbrk_tables, debug_output_org_wbrk_tables,
116619         output_wbrk_tables.
116620         * modules/gen-uni-tables (Description): Update.
116621         * lib/uniwbrk/wbrkprop.h: New file, automatically generated by
116622         gen-uni-tables.
116624         New module 'uniwbrk/base'.
116625         * modules/uniwbrk/base: New file.
116626         * lib/uniwbrk.h: New file.
116628 2009-02-08  Bruno Haible  <bruno@clisp.org>
116630         Update to Unicode 5.1.0.
116631         * lib/gen-uni-tables.c (is_property_alphabetic): Include
116632         U+2185..U+2188.
116633         (is_property_default_ignorable_code_point): Don't include characters
116634         of category Cc or Cs and not-a-characters.
116635         (get_lbp): Assume REVISION_22. Special handling of U+0609, U+060A,
116636         U+0D79, U+109E, U+109F, U+A60C.
116637         * lib/unictype/bidi_of.h: Regenerated.
116638         * lib/unictype/blocks.h: Regenerated.
116639         * lib/unictype/categ_C.h: Regenerated.
116640         * lib/unictype/categ_Cf.h: Regenerated.
116641         * lib/unictype/categ_Cn.h: Regenerated.
116642         * lib/unictype/categ_L.h: Regenerated.
116643         * lib/unictype/categ_Ll.h: Regenerated.
116644         * lib/unictype/categ_Lm.h: Regenerated.
116645         * lib/unictype/categ_Lo.h: Regenerated.
116646         * lib/unictype/categ_Lu.h: Regenerated.
116647         * lib/unictype/categ_M.h: Regenerated.
116648         * lib/unictype/categ_Mc.h: Regenerated.
116649         * lib/unictype/categ_Me.h: Regenerated.
116650         * lib/unictype/categ_Mn.h: Regenerated.
116651         * lib/unictype/categ_N.h: Regenerated.
116652         * lib/unictype/categ_Nd.h: Regenerated.
116653         * lib/unictype/categ_Nl.h: Regenerated.
116654         * lib/unictype/categ_No.h: Regenerated.
116655         * lib/unictype/categ_P.h: Regenerated.
116656         * lib/unictype/categ_Pd.h: Regenerated.
116657         * lib/unictype/categ_Pe.h: Regenerated.
116658         * lib/unictype/categ_Pf.h: Regenerated.
116659         * lib/unictype/categ_Pi.h: Regenerated.
116660         * lib/unictype/categ_Po.h: Regenerated.
116661         * lib/unictype/categ_Ps.h: Regenerated.
116662         * lib/unictype/categ_S.h: Regenerated.
116663         * lib/unictype/categ_Sk.h: Regenerated.
116664         * lib/unictype/categ_Sm.h: Regenerated.
116665         * lib/unictype/categ_So.h: Regenerated.
116666         * lib/unictype/categ_of.h: Regenerated.
116667         * lib/unictype/combining.h: Regenerated.
116668         * lib/unictype/ctype_alnum.h: Regenerated.
116669         * lib/unictype/ctype_alpha.h: Regenerated.
116670         * lib/unictype/ctype_graph.h: Regenerated.
116671         * lib/unictype/ctype_lower.h: Regenerated.
116672         * lib/unictype/ctype_print.h: Regenerated.
116673         * lib/unictype/ctype_punct.h: Regenerated.
116674         * lib/unictype/ctype_upper.h: Regenerated.
116675         * lib/unictype/decdigit.h: Regenerated.
116676         * lib/unictype/digit.h: Regenerated.
116677         * lib/unictype/mirror.h: Regenerated.
116678         * lib/unictype/numeric.h: Regenerated.
116679         * lib/unictype/pr_alphabetic.h: Regenerated.
116680         * lib/unictype/pr_bidi_arabic_digit.h: Regenerated.
116681         * lib/unictype/pr_bidi_arabic_right_to_left.h: Regenerated.
116682         * lib/unictype/pr_bidi_boundary_neutral.h: Regenerated.
116683         * lib/unictype/pr_bidi_eur_num_terminator.h: Regenerated.
116684         * lib/unictype/pr_bidi_left_to_right.h: Regenerated.
116685         * lib/unictype/pr_bidi_non_spacing_mark.h: Regenerated.
116686         * lib/unictype/pr_bidi_other_neutral.h: Regenerated.
116687         * lib/unictype/pr_combining.h: Regenerated.
116688         * lib/unictype/pr_dash.h: Regenerated.
116689         * lib/unictype/pr_decimal_digit.h: Regenerated.
116690         * lib/unictype/pr_default_ignorable_code_point.h: Regenerated.
116691         * lib/unictype/pr_deprecated.h: Regenerated.
116692         * lib/unictype/pr_diacritic.h: Regenerated.
116693         * lib/unictype/pr_extender.h: Regenerated.
116694         * lib/unictype/pr_format_control.h: Regenerated.
116695         * lib/unictype/pr_grapheme_base.h: Regenerated.
116696         * lib/unictype/pr_grapheme_extend.h: Regenerated.
116697         * lib/unictype/pr_grapheme_link.h: Regenerated.
116698         * lib/unictype/pr_id_continue.h: Regenerated.
116699         * lib/unictype/pr_id_start.h: Regenerated.
116700         * lib/unictype/pr_ideographic.h: Regenerated.
116701         * lib/unictype/pr_ignorable_control.h: Regenerated.
116702         * lib/unictype/pr_lowercase.h: Regenerated.
116703         * lib/unictype/pr_math.h: Regenerated.
116704         * lib/unictype/pr_numeric.h: Regenerated.
116705         * lib/unictype/pr_other_alphabetic.h: Regenerated.
116706         * lib/unictype/pr_other_default_ignorable_code_point.h: Regenerated.
116707         * lib/unictype/pr_other_grapheme_extend.h: Regenerated.
116708         * lib/unictype/pr_other_id_continue.h: Regenerated.
116709         * lib/unictype/pr_other_lowercase.h: Regenerated.
116710         * lib/unictype/pr_other_math.h: Regenerated.
116711         * lib/unictype/pr_punctuation.h: Regenerated.
116712         * lib/unictype/pr_sentence_terminal.h: Regenerated.
116713         * lib/unictype/pr_soft_dotted.h: Regenerated.
116714         * lib/unictype/pr_terminal_punctuation.h: Regenerated.
116715         * lib/unictype/pr_unassigned_code_value.h: Regenerated.
116716         * lib/unictype/pr_unified_ideograph.h: Regenerated.
116717         * lib/unictype/pr_uppercase.h: Regenerated.
116718         * lib/unictype/pr_xid_continue.h: Regenerated.
116719         * lib/unictype/pr_xid_start.h: Regenerated.
116720         * lib/unictype/pr_zero_width.h: Regenerated.
116721         * lib/unictype/scripts.h: Regenerated.
116722         * lib/unictype/scripts_byname.gperf: Regenerated.
116723         * lib/unictype/sy_java_ident.h: Regenerated.
116724         * lib/unilbrk/lbrkprop1.h: Regenerated.
116725         * lib/unilbrk/lbrkprop2.h: Regenerated.
116726         * tests/unictype/test-categ_C.c: Regenerated.
116727         * tests/unictype/test-categ_Cf.c: Regenerated.
116728         * tests/unictype/test-categ_Cn.c: Regenerated.
116729         * tests/unictype/test-categ_L.c: Regenerated.
116730         * tests/unictype/test-categ_Ll.c: Regenerated.
116731         * tests/unictype/test-categ_Lm.c: Regenerated.
116732         * tests/unictype/test-categ_Lo.c: Regenerated.
116733         * tests/unictype/test-categ_Lu.c: Regenerated.
116734         * tests/unictype/test-categ_M.c: Regenerated.
116735         * tests/unictype/test-categ_Mc.c: Regenerated.
116736         * tests/unictype/test-categ_Me.c: Regenerated.
116737         * tests/unictype/test-categ_Mn.c: Regenerated.
116738         * tests/unictype/test-categ_N.c: Regenerated.
116739         * tests/unictype/test-categ_Nd.c: Regenerated.
116740         * tests/unictype/test-categ_Nl.c: Regenerated.
116741         * tests/unictype/test-categ_No.c: Regenerated.
116742         * tests/unictype/test-categ_P.c: Regenerated.
116743         * tests/unictype/test-categ_Pd.c: Regenerated.
116744         * tests/unictype/test-categ_Pe.c: Regenerated.
116745         * tests/unictype/test-categ_Pf.c: Regenerated.
116746         * tests/unictype/test-categ_Pi.c: Regenerated.
116747         * tests/unictype/test-categ_Po.c: Regenerated.
116748         * tests/unictype/test-categ_Ps.c: Regenerated.
116749         * tests/unictype/test-categ_S.c: Regenerated.
116750         * tests/unictype/test-categ_Sk.c: Regenerated.
116751         * tests/unictype/test-categ_Sm.c: Regenerated.
116752         * tests/unictype/test-categ_So.c: Regenerated.
116753         * tests/unictype/test-ctype_alnum.c: Regenerated.
116754         * tests/unictype/test-ctype_alpha.c: Regenerated.
116755         * tests/unictype/test-ctype_graph.c: Regenerated.
116756         * tests/unictype/test-ctype_lower.c: Regenerated.
116757         * tests/unictype/test-ctype_print.c: Regenerated.
116758         * tests/unictype/test-ctype_punct.c: Regenerated.
116759         * tests/unictype/test-ctype_upper.c: Regenerated.
116760         * tests/unictype/test-decdigit.h: Regenerated.
116761         * tests/unictype/test-digit.h: Regenerated.
116762         * tests/unictype/test-numeric.h: Regenerated.
116763         * tests/unictype/test-pr_alphabetic.c: Regenerated.
116764         * tests/unictype/test-pr_bidi_arabic_digit.c: Regenerated.
116765         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Regenerated.
116766         * tests/unictype/test-pr_bidi_boundary_neutral.c: Regenerated.
116767         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Regenerated.
116768         * tests/unictype/test-pr_bidi_left_to_right.c: Regenerated.
116769         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Regenerated.
116770         * tests/unictype/test-pr_bidi_other_neutral.c: Regenerated.
116771         * tests/unictype/test-pr_combining.c: Regenerated.
116772         * tests/unictype/test-pr_dash.c: Regenerated.
116773         * tests/unictype/test-pr_decimal_digit.c: Regenerated.
116774         * tests/unictype/test-pr_default_ignorable_code_point.c: Regenerated.
116775         * tests/unictype/test-pr_deprecated.c: Regenerated.
116776         * tests/unictype/test-pr_diacritic.c: Regenerated.
116777         * tests/unictype/test-pr_extender.c: Regenerated.
116778         * tests/unictype/test-pr_format_control.c: Regenerated.
116779         * tests/unictype/test-pr_grapheme_base.c: Regenerated.
116780         * tests/unictype/test-pr_grapheme_extend.c: Regenerated.
116781         * tests/unictype/test-pr_grapheme_link.c: Regenerated.
116782         * tests/unictype/test-pr_id_continue.c: Regenerated.
116783         * tests/unictype/test-pr_id_start.c: Regenerated.
116784         * tests/unictype/test-pr_ideographic.c: Regenerated.
116785         * tests/unictype/test-pr_ignorable_control.c: Regenerated.
116786         * tests/unictype/test-pr_lowercase.c: Regenerated.
116787         * tests/unictype/test-pr_math.c: Regenerated.
116788         * tests/unictype/test-pr_numeric.c: Regenerated.
116789         * tests/unictype/test-pr_other_alphabetic.c: Regenerated.
116790         * tests/unictype/test-pr_other_default_ignorable_code_point.c:
116791         Regenerated.
116792         * tests/unictype/test-pr_other_grapheme_extend.c: Regenerated.
116793         * tests/unictype/test-pr_other_id_continue.c: Regenerated.
116794         * tests/unictype/test-pr_other_lowercase.c: Regenerated.
116795         * tests/unictype/test-pr_other_math.c: Regenerated.
116796         * tests/unictype/test-pr_punctuation.c: Regenerated.
116797         * tests/unictype/test-pr_sentence_terminal.c: Regenerated.
116798         * tests/unictype/test-pr_soft_dotted.c: Regenerated.
116799         * tests/unictype/test-pr_terminal_punctuation.c: Regenerated.
116800         * tests/unictype/test-pr_unassigned_code_value.c: Regenerated.
116801         * tests/unictype/test-pr_unified_ideograph.c: Regenerated.
116802         * tests/unictype/test-pr_uppercase.c: Regenerated.
116803         * tests/unictype/test-pr_xid_continue.c: Regenerated.
116804         * tests/unictype/test-pr_xid_start.c: Regenerated.
116805         * tests/unictype/test-pr_zero_width.c: Regenerated.
116807         Update to Unicode 5.1.0.
116808         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0487,
116809         U+0616..U+061A, U+0A51, U+0A75, U+0B44, U+0B62..U+0B63, U+0C62..U+0C63,
116810         U+0D44, U+0D62..U+0D63, U+1033..U+1035, U+103A, U+103D..U+103E,
116811         U+105E..U+1060, U+1071..U+1074, U+1082, U+1085..U+1086, U+108D,
116812         U+1B80..U+1B81, U+1BA2..U+1BA5, U+1BA8..U+1BA9, U+1C2C..U+1C33,
116813         U+1C36..U+1C37, U+1DCB..U+1DE6, U+2064, U+20F0, U+2DE0..U+2DFF,
116814         U+A66F..U+A672, U+A67C..U+A67D, U+A8C4, U+A926..U+A92D, U+A947..U+A951,
116815         U+AA29..U+AA2E, U+AA31..U+AA32, U+AA35..U+AA36, U+AA43, U+AA4C,
116816         U+FE24..U+FE26, U+101FD. Remove U+1929..U+192B.
116817         (nonspacing_table_ind): Update.
116818         * tests/uniwidth/test-uc_width2.sh: Update expected result.
116820         Update to Unicode 5.1.0.
116821         * lib/uniname/gen-uninames.lisp (main): Add the range 0x1Fxxx to the
116822         code transform.
116823         * lib/uniname/uniname.c (unicode_character_name,
116824         unicode_name_character): Add the range 0x1Fxxx to the code transform.
116825         * lib/uniname/uninames.h: Regenerated.
116826         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.1.0.
116828 2009-02-07  Bruno Haible  <bruno@clisp.org>
116830         Merge gen-ctype and gen-lbrk into a single program.
116831         * lib/gen-uni-tables.c: New file, incorporating
116832         lib/unictype/gen-ctype.c and lib/unilbrk/gen-lbrk.c.
116833         Add directory prefixes to the names of the generated files.
116834         * lib/unictype/gen-ctype.c: Remove file.
116835         * lib/unilbrk/gen-lbrk.c: Remove file.
116836         * modules/gen-uni-tables: New file.
116837         * modules/unictype/gen-ctype: Remove file.
116838         * modules/unilbrk/gen-lbrk: Remove file.
116840 2009-02-07  Bruno Haible  <bruno@clisp.org>
116842         * lib/unistr.h (u8_strcoll, u16_strcoll, u32_strcoll): New declations.
116844         New module 'unistr/u32-strcoll'.
116845         * modules/unistr/u32-strcoll: New file.
116846         * lib/unistr/u32-strcoll.c: New file.
116848         New module 'unistr/u16-strcoll'.
116849         * modules/unistr/u16-strcoll: New file.
116850         * lib/unistr/u16-strcoll.c: New file.
116852         New module 'unistr/u8-strcoll'.
116853         * modules/unistr/u8-strcoll: New file.
116854         * lib/unistr/u8-strcoll.c: New file.
116855         * lib/unistr/u-strcoll.h: New file.
116857 2009-02-07  Bruno Haible  <bruno@clisp.org>
116859         * test-mbrtowc4.sh (LOCALE_ZH_CN): Fix default value.
116860         * test-mbsnrtowcs4.sh (LOCALE_ZH_CN): Likewise.
116861         * test-mbsrtowcs4.sh (LOCALE_ZH_CN): Likewise.
116862         * test-wcrtomb.sh (LOCALE_ZH_CN): Likewise.
116863         * test-wcsnrtombs4.sh (LOCALE_ZH_CN): Likewise.
116864         * test-wcsrtombs4.sh (LOCALE_ZH_CN): Likewise.
116866 2009-02-07  Bruno Haible  <bruno@clisp.org>
116868         Make 64-bit clean.
116869         * lib/unictype/gen-ctype.c (output_predicate, output_category,
116870         output_combclass, output_bidi_category, output_decimal_digit,
116871         output_digit, output_numeric, output_mirror, output_scripts,
116872         output_ident_category): Use proper width specifier in format strings.
116874 2009-02-07  Bruno Haible  <bruno@clisp.org>
116876         * doc/posix-functions/dirfd.texi: Clarify situation on mingw. Document
116877         failure behaviour.
116879 2009-02-07  Jim Meyering  <meyering@redhat.com>
116881         regex: avoid compilation failure with upcoming gcc-4.4
116882         * lib/regex_internal.h: Revert e48d8b47fb3eee81d341b71c3e006efe9e3433a7
116883         [workaround for PGC prior to 6.1-2].  Otherwise, we'd get this:
116884         "... error: integer overflow in preprocessor expression".
116886 2009-02-05  Ben Pfaff  <blp@gnu.org>
116888         Fix link errors on Windows when close module is used.
116889         * modules/close: Add $(LIB_CLOSE) to Link section.
116890         * m4/close.m4 (gl_REPLACE_CLOSE): Substitute -lws2_32 into
116891         $(LIB_CLOSE) on Windows.
116893 2009-02-05  Jim Meyering  <meyering@redhat.com>
116895         still avoid unused-parameter warnings, but do it cleanly
116896         * lib/fsusage.c (UNUSED_PARAM): Remove definition.
116897         (get_fs_usage): Cast to void instead.
116898         * lib/mountlist.c (UNUSED_PARAM): Remove definition.
116899         (dev_from_mount_options, read_file_system_list): Cast to void.
116900         Prompted by Bruno Haible.
116902 2009-02-04  Jim Meyering  <meyering@redhat.com>
116904         fsusage.c: correct copyright year
116905         * lib/fsusage.c: Reflect year in which the change is pushed into
116907         avoid misc. warnings
116908         * lib/fsusage.c (UNUSED_PARAM): Define.
116909         (get_fs_usage): Mark parameter "disk" as unused.
116910         * lib/getugroups.c (getgrent): Use "void" in prototype.
116911         * lib/mountlist.c: Mark unused parameters.
116912         (read_file_system_list): Declare a local with "const".
116913         * lib/nanosleep.c (getnow): Declare static.
116914         * lib/strftime.c: Include strftime.h, for declaration of nstrftime.
116916         dirfd: set errno upon failure
116917         * lib/dirfd.c: Include <errno.h>.
116918         Set errno to ENOTSUP when returning -1.
116919         * modules/dirfd (Depends-on): Add errno.
116920         Suggested by John Kodis <kodis@comcast.net>.
116922 2009-02-01  Bruno Haible  <bruno@clisp.org>
116924         Don't assume sizeof (long) >= sizeof (void *).
116925         * lib/memcmp.c: Include stdint.h.
116926         (memcmp_bytes): Change argument types to op_t. Change type of srcp1,
116927         srcp2 to 'const byte *'.
116928         (memcmp_common_alignment, memcmp_not_common_alignment): Change argument
116929         types to uintptr_t.
116930         (rpl_memcmp): Change type of srcp1, srcp2 to 'uintptr_t'.
116931         * modules/memcmp (Depends-on): Add stdint.
116932         Reported by Ozkan Sezer <sezeroz@gmail.com>.
116934 2009-01-30  Eric Blake  <ebb9@byu.net>
116936         fix more require-before-expand issues
116937         * m4/pmccabe2html.m4 (gl_PMCCABE2HTML): Require, rather than
116938         expand, AC_PROG_AWK.
116939         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): Use AC_DEFUN_ONCE.
116941 2009-01-28  Eric Blake  <ebb9@byu.net>
116943         version-etc: use consistent URL formatting
116944         * lib/version-etc.c (emit_bug_reporting_address, version_etc_va):
116945         Improve formatting.  Use fputs for string without %.
116947 2009-01-28  Jim Meyering  <meyering@redhat.com>
116949         00gnulib.m4: add m4 quotes in shell comment to avoid autoconf warning
116950         * m4/00gnulib.m4 (AC_DEFUN_ONCE): Add quotes to avoid an
116951         "underquoted definition of NAME" from autoconf-2.59.
116953 2009-01-28  Bruno Haible  <bruno@clisp.org>
116955         * doc/gnulib.texi: Add "Obsolete modules" to index.
116957 2009-01-28  Jim Meyering  <meyering@redhat.com>
116959         useless-if-before-free: recognize more variants
116960         * build-aux/useless-if-before-free: Also recognize e.g.,
116961         if (NULL != p) free (p);
116963 2009-01-27  Mark McLoughlin  <markmc@redhat.com>
116965         test-getaddrinfo: skip (don't fail) this test when there's no network
116966         * tests/test-getaddrinfo.c: Skip test upon failure with EAI_AGAIN,
116967         on the presumption that it means you lack network access.
116969 2009-01-26  Jim Meyering  <meyering@redhat.com>
116971         fflush: avoid warnings on modern systems
116972         * lib/fflush.c (rpl_fflush): Move declarations of locals,
116973         pos and result, into scopes where they're used.
116975 2009-01-26  Eric Blake  <ebb9@byu.net>
116977         Silence warning reintroduced by recent extensions patch.
116978         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS)
116979         (gl_USE_SYSTEM_EXTENSIONS): Use AC_DEFUN_ONCE to silence newer
116980         autoconf.
116982         Backport improved autoconf semantics of AC_DEFUN_ONCE.
116983         * m4/00gnulib.m4: New file.
116984         * gnulib-tool (func_get_filelist): Always use it.
116985         * m4/gnulib-common.m4 (gl_COMMON): Force the file to be used.
116986         Reported by Bruno Haible, with suggestions from Paolo Bonzini.
116988 2009-01-25  Bruno Haible  <bruno@clisp.org>
116990         Make test-quotearg work on MacOS X and AIX.
116991         * tests/test-quotearg.sh: New file.
116992         * tests/locale/fr/LC_MESSAGES/test-quotearg.po: New file.
116993         * tests/locale/fr/LC_MESSAGES/test-quotearg.mo: New file.
116994         * tests/test-quotearg.c: Include <locale.h> and gettext.h. Don't
116995         include <libintl.h>.
116996         (fake_locale): Remove variable.
116997         (gettext, dgettext, dcgettext): Remove functions.
116998         (main): Instead of setting a fake locale, set a real locale. Call
116999         textdomain and bindtextdomain.
117000         * modules/quotearg-tests (Files): Add the new files.
117001         (Depends-on): Add gettext, setenv, unsetenv.
117002         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
117003         (Makefile.am): Add test-quotearg.sh to TESTS, remove test-quotearg.
117004         Augment TESTS_ENVIRONMENT.
117006 2009-01-25  Bruno Haible  <bruno@clisp.org>
117008         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove special code that hid the
117009         fr_FR.ISO8859-1 locale on MacOS X.
117010         * m4/locale-ja.m4 (gt_LOCALE_JA): Remove special code that hid the
117011         ja_JP.eucJP locale on MacOS X.
117012         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Remove special code that hid the
117013         zh_CN.GB18030 locale on MacOS X.
117015 2009-01-25  Bruno Haible  <bruno@clisp.org>
117017         Avoid link errors on MacOS X 10.3.
117018         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Add initializer.
117019         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
117021 2009-01-25  Bruno Haible  <bruno@clisp.org>
117023         * lib/pipe.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
117024         * m4/pipe.m4 (gl_PIPE): Remove tests for vfork() based code.
117025         * modules/pipe (Files): Remove m4/posix_spawn.m4.
117026         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
117027         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2,
117028         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
117029         posix_spawnattr_init, posix_spawnattr_setsigmask,
117030         posix_spawnattr_setflags, posix_spawnattr_destroy.
117032         * lib/execute.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
117033         * m4/execute.m4 (gl_EXECUTE): Remove tests for vfork() based code.
117034         * modules/execute (Files): Remove m4/posix_spawn.m4.
117035         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
117036         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
117037         posix_spawnattr_init, posix_spawnattr_setsigmask,
117038         posix_spawnattr_setflags, posix_spawnattr_destroy.
117040 2009-01-25  Bruno Haible  <bruno@clisp.org>
117042         * lib/glthread/threadlib.c: Include <stdlib.h>.
117044 2009-01-25  Bruno Haible  <bruno@clisp.org>
117046         * lib/glthread/threadlib.c (dummy): New declaration.
117048 2009-01-25  Bruno Haible  <bruno@clisp.org>
117050         * lib/mbrtowc.c (mbrtowc): Distinguish invalid and incomplete
117051         multibyte characters also for the GB18030 encoding. Don't crash when
117052         the encoding is unknown and nstate = 0. Needed on OSF/1 5.1.
117054 2009-01-25  Bruno Haible  <bruno@clisp.org>
117056         Avoid redefining 'struct random_data' on OSF/1 5.1.
117057         * lib/stdlib.in.h: Include <random.h> if it exists.
117058         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether <random.h> exists. Set
117059         HAVE_RANDOM_H. Include <random.h> when testing whether
117060         'struct random_data' exists.
117061         * modules/stdlib (Makefile.am): Substitute HAVE_RANDOM_H.
117063 2009-01-25  Bruno Haible  <bruno@clisp.org>
117065         Don't install charset.alias on MacOS X >= 10.3.
117066         * lib/localcharset.c (DARWIN7): New macro.
117067         (get_charset_aliases): Hardcode the result for Darwin7.
117068         * modules/localcharset (install-exec-local): Don't install
117069         charset.alias on MacOS X >= 10.3, if the file does not yet exist.
117071 2009-01-25  Bruno Haible  <bruno@clisp.org>
117073         Don't install charset.alias on mingw and Cygwin.
117074         * modules/localcharset (install-exec-local): Don't install
117075         charset.alias on mingw and Cygwin, if the file does not yet exist.
117076         The result for these platforms is hardcoded in localcharset.c.
117078 2009-01-25  Bruno Haible  <bruno@clisp.org>
117080         Make it possible again to use AC_GNU_SOURCE together with gnulib.
117081         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_GNU_SOURCE
117082         before requiring AC_USE_SYSTEM_EXTENSIONS.
117084 2009-01-25  Jim Meyering  <meyering@redhat.com>
117086         c-strtod: avoid warnings
117087         * lib/c-strtod.c (C_STRTOD): Cast nptr to (char *) to avoid
117088         "assignment discards qualifiers from pointer target type" warnings.
117090 2009-01-24  Bruno Haible  <bruno@clisp.org>
117092         Add support for non-UTF-8 locales on MacOS X.
117093         * lib/config.charset: Add CP1131, ARMSCII-8, PT154 to the list of
117094         canonical encodings. For Darwin 7 and newer, don't map traditional
117095         encodings to UTF-8.
117096         Reported by Vincent Lefevre <vincent@vinc17.org>
117097         at <http://savannah.gnu.org/bugs/?25235>.
117099 2009-01-24  Bruno Haible  <bruno@clisp.org>
117101         * doc/gnulib.texi (Obsolete modules): New section.
117102         Reported by Mike Frysinger <vapier@gentoo.org>.
117104 2009-01-24  Bruno Haible  <bruno@clisp.org>
117106         * doc/Makefile (%.pdf): Clarify where to find texmf.cnf.
117107         (%.dvi): New rule.
117109 2009-01-24  Bruno Haible  <bruno@clisp.org>
117111         * lib/c-strtod.h (c_strtod, c_strtold): Adjust specification.
117112         Reported by Eric Blake.
117114 2009-01-24  Bruno Haible  <bruno@clisp.org>
117116         * lib/c-stack.c (segv_handler): If !HAVE_XSI_STACK_OVERFLOW_HEURISTIC,
117117         set signo = 0 also if info->si_code <= 0. Needed on HP-UX 11.11.
117118         Reported by Gary V. Vaughan <gary@gnu.org>.
117120 2009-01-24  Bruno Haible  <bruno@clisp.org>
117122         * lib/c-strtod.h (c_strtod, c_strtold): Add specification.
117124 2009-01-23  Bruno Haible  <bruno@clisp.org>
117126         Make c-strtod, c-strtold usable in libraries.
117127         * lib/c-strtod.c: Include string.h instead of xalloc.h.
117128         (C_STRTOD): Call strdup instead of xstrdup.
117129         * modules/c-strtod (Depends-on): Add strdup-posix, remove xalloc.
117130         * modules/c-strtold (Depends-on): Likewise.
117131         * doc/c-strtod.texi: Remove the sentence mentioning xalloc_die.
117132         * NEWS: Mention the change.
117133         Reported by Michael Gold <mgold@ncf.ca>.
117135 2009-01-23  Jim Meyering  <meyering@redhat.com>
117137         c-strtod: when ENDPTR is non-NULL, set *ENDPTR in new failure path
117138         * lib/c-strtod.c (C_STRTOD) [LC_ALL_MASKC]: Ensure that when
117139         ENDPTR is non-NULL, *ENDPTR is set to NPTR upon failure.
117141 2009-01-23  Simon Josefsson  <simon@josefsson.org>
117143         * lib/version-etc.c: Add emit_bug_reporting_address, inspired by
117144         GNU CoreUtils.
117145         * lib/version-etc.h: Add prototype for emit_bug_reporting_address.
117146         * modules/version-etc (Description): Update.
117148 2009-01-22  Bruno Haible  <bruno@clisp.org>
117150         Cache the C locale object.
117151         * lib/c-strtod.c (c_locale_cache): New variable.
117152         (c_locale): New function.
117153         (C_STRTOD): Use it, and don't call freelocale.
117154         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOLD): Require AC_C_INLINE.
117155         Suggested by Paolo Bonzini.
117157 2009-01-21  Bruno Haible  <bruno@clisp.org>
117159         * lib/getloadavg.c (getloadavg): Check c_strtod result against error
117160         conditions other than overflow.
117162 2009-01-21  Bruno Haible  <bruno@clisp.org>
117164         * lib/c-strtod.c: Include errno.h.
117165         (C_STRTOD): Check against NULL return from newlocale. Preserve errno
117166         value from STRTOD_L and STRTOD.
117168 2009-01-21  Bruno Haible  <bruno@clisp.org>
117169         and Jim Meyering  <meyering@redhat.com>
117171         nanosleep: skip configure test (fail it) for apple universal builds
117172         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_MULTIARCH. In Apple
117173         universal builds, assume that nanosleep does not work.
117174         * modules/nanosleep (Depends-on): Add multiarch.
117176         mktime: skip configure test (fail it) for apple universal builds
117177         * m4/mktime.m4 (AC_FUNC_MKTIME): Require gl_MULTIARCH. In Apple
117178         universal builds, assume that mktime does not work.
117179         * modules/mktime (Depends-on): Add multiarch.
117181 2009-01-21  Eric Blake  <ebb9@byu.net>
117183         multiarch: avoid expand-before-require warning
117184         * modules/multiarch (configure.ac): Require, rather than expand,
117185         gl_MULTIARCH.
117186         * m4/multiarch.m4 (gl_MULTIARCH_BODY): Merge...
117187         (gl_MULTIARCH): ...into this macro, and use AC_DEFUN_ONCE to
117188         enforce that all clients require it.  Partial reversion of
117189         2008-12-29 patch.
117191         error: avoid expand-before-require warning
117192         * modules/errno (configure.ac): Require, rather than expand,
117193         gl_HEADER_ERRNO_H.
117194         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Merge...
117195         (gl_HEADER_ERRNO_H): ...into this macro, and use AC_DEFUN_ONCE to
117196         enforce that all clients require it.
117198         gnulib-tool: avoid warnings from using obsolete AC_GNU_SOURCE
117199         * gnulib-tool (func_dest_tmpfilename, func_create_testdir): Using
117200         obsolete AC_GNU_SOURCE causes out-of-order expansion; avoid it,
117201         and rely solely on gl_USE_SYSTEM_EXTENSIONS.
117203 2009-01-21  Paolo Bonzini  <bonzini@gnu.org>
117205         Revert:
117206         2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
117208         regex: do not depend on obsolete modules.
117209         * modules/regex: Remove memcmp and memmove.
117211 2009-01-20  Bruno Haible  <bruno@clisp.org>
117213         Make the 'link' module link on Windows NT 4.
117214         * lib/link.c (_WIN32_WINNT): Don't define.
117215         (CreateHardLinkFuncType): New type.
117216         (CreateHardLinkFunc, initialized): New variables.
117217         (initialize): New function.
117218         (link): Invoke CreateHardLink indirectly through the function pointer.
117220 2009-01-20  Bruno Haible  <bruno@clisp.org>
117222         Fix compilation failure on mingw.
117223         * tests/test-link.c (main): Don't assume that EOPNOTSUPP exists.
117225 2009-01-20  Michael Gold  <mgold@ncf.ca>  (tiny change)
117227         * doc/c-strtod.texi: Mention a couple of restrictions.
117229 2009-01-20  Jim Meyering  <meyering@redhat.com>
117231         gettimeofday: move more declarations out of functions
117232         * lib/gettimeofday.c: Move extern declarations of tzset and
117233         gmtime out of containing functions.  Prompted by Bruno Haible.
117235 2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
117237         regex: do not depend on obsolete modules.
117238         * modules/regex: Remove memcmp and memmove.
117240 2009-01-19  Bruno Haible  <bruno@clisp.org>
117242         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
117243         * modules/uniconv/u16-conv-from-enc (configure.ac): Require
117244         gl_BIGENDIAN, not AC_C_BIGENDIAN.
117245         * modules/uniconv/u16-conv-to-enc (configure.ac): Likewise.
117246         * modules/uniconv/u16-strconv-to-enc (configure.ac): Likewise.
117248 2009-01-19  Bruno Haible  <bruno@clisp.org>
117250         * tests/test-link.c: Include <errno.h>.
117251         (main): Exit with code 77 when a hard link cannot be created due to
117252         the file system.
117253         * tests/test-link.sh: Skip test when a hard link cannot be created due
117254         to the file system.
117255         Suggested by Eric Blake.
117257 2009-01-19  Martin Lambers  <marlam@marlam.de>
117259         * modules/link-tests: New file.
117260         * tests/test-link.sh: New file.
117261         * tests/test-link.c: New file.
117263 2009-01-19  Eric Blake  <ebb9@byu.net>
117265         doc: mention another function added in cygwin 1.7.0
117266         * doc/glibc-functions/glob_pattern_p.texi (glob_pattern_p):
117267         Another new function in cygwin 1.7.
117269 2009-01-19  Bruno Haible  <bruno@clisp.org>
117271         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
117272         * m4/gnulib-common.m4 (gl_BIGENDIAN): New macro.
117273         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require
117274         gl_BIGENDIAN, not AC_C_BIGENDIAN.
117275         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
117276         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
117277         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
117278         * m4/md4.m4 (gl_MD4): Likewise.
117279         * m4/md5.m4 (gl_MD5): Likewise.
117280         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Likewise.
117281         * m4/sha1.m4 (gl_SHA1): Likewise.
117282         * m4/sha256.m4 (gl_SHA256): Likewise.
117283         * m4/sha512.m4 (gl_SHA512): Likewise.
117285 2009-01-19  Bruno Haible  <bruno@clisp.org>
117287         * modules/uniname/uniname-tests (Depends-on): Add progname.
117288         * tests/uniname/test-uninames.c: Include progname.h.
117289         (main): Call set_program_name.
117291         * modules/unistdio/u8-vsprintf-tests (Depends-on): Add progname.
117292         * tests/unistdio/test-u8-vsprintf1.c: Include progname.h.
117293         (main): Call set_program_name.
117295         * modules/unistdio/u8-vsnprintf-tests (Depends-on): Add progname.
117296         * tests/unistdio/test-u8-vsnprintf1.c: Include progname.h.
117297         (main): Call set_program_name.
117299         * modules/unistdio/u16-vsprintf-tests (Depends-on): Add progname.
117300         * tests/unistdio/test-u16-vsprintf1.c: Include progname.h.
117301         (main): Call set_program_name.
117303         * modules/unistdio/u16-vsnprintf-tests (Depends-on): Add progname.
117304         * tests/unistdio/test-u16-vsnprintf1.c: Include progname.h.
117305         (main): Call set_program_name.
117307         * modules/unistdio/u32-vsprintf-tests (Depends-on): Add progname.
117308         * tests/unistdio/test-u32-vsprintf1.c: Include progname.h.
117309         (main): Call set_program_name.
117311         * modules/unistdio/u32-vsnprintf-tests (Depends-on): Add progname.
117312         * tests/unistdio/test-u32-vsnprintf1.c: Include progname.h.
117313         (main): Call set_program_name.
117315         * modules/unistdio/ulc-vsprintf-tests (Depends-on): Add progname.
117316         * tests/unistdio/test-ulc-vsprintf1.c: Include progname.h.
117317         (main): Call set_program_name.
117319         * modules/unistdio/ulc-vsnprintf-tests (Depends-on): Add progname.
117320         * tests/unistdio/test-ulc-vsnprintf1.c: Include progname.h.
117321         (main): Call set_program_name.
117323 2009-01-19  Eric Blake  <ebb9@byu.net>
117325         test-unistd: test previous patch
117326         * tests/test-unistd.c: Test *_FILENO macros.
117328         unistd: guarantee STDIN_FILENO here, for OS/2 EMX
117329         * lib/unistd.in.h (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
117330         Guarantee a definition.
117331         * doc/posix-headers/unistd.texi (unistd.h): Document the bug.
117332         * modules/unistd-safer (Depends-on): Add dependency on unistd.
117333         * lib/c-stack.c (STDERR_FILENO): Rely on <unistd.h>.
117334         * lib/dup-safer.c (STDERR_FILENO): Likewise.
117335         * lib/execute.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
117336         Likewise.
117337         * lib/fd-safer.c (STDIN_FILENO, STDERR_FILENO): Likewise.
117338         * lib/fopen-safer.c (STDERR_FILENO): Likewise.
117339         * lib/pipe.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
117340         Likewise.
117341         * lib/tmpfile-safer.c (STDERR_FILENO): Likewise.
117342         * tests/test-posix_spawn1.c (STDIN_FILENO, STDOUT_FILENO)
117343         (STDERR_FILENO): Likewise.
117344         * tests/test-posix_spawn2.c (STDIN_FILENO, STDOUT_FILENO)
117345         (STDERR_FILENO): Likewise.
117346         * tests/test-posix_spawn3.c (STDIN_FILENO, STDOUT_FILENO)
117347         (STDERR_FILENO): Likewise.
117348         Reported by Elbert Pol.
117350 2009-01-19  Eric Blake  <ebb9@byu.net>
117352         doc: mention more functions added in cygwin 1.7.0
117353         * doc/posix-functions/abort.texi (abort): Update wording related
117354         to cygwin.
117355         * doc/posix-functions/daylight.texi (daylight): Likewise.
117356         * doc/posix-functions/optarg.texi (optarg): Likewise.
117357         * doc/posix-functions/optarg.texi (opterr): Likewise.
117358         * doc/posix-functions/optarg.texi (optind): Likewise.
117359         * doc/posix-functions/optarg.texi (optopt): Likewise.
117360         * doc/posix-functions/wprintf.texi (wprintf): Cygwin wprintf never
117361         worked in 1.5.x, and was withdrawn in 1.7.
117362         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
117363         * doc/posix-functions/fprintf.texi (fprintf): Tighten mention of
117364         cygwin versions.
117365         * doc/posix-functions/perror.texi (perror): Likewise.
117366         * doc/posix-functions/printf.texi (printf): Likewise.
117367         * doc/posix-functions/snprintf.texi (snprintf): Likewise.
117368         * doc/posix-functions/sprintf.texi (sprintf): Likewise.
117369         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
117370         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
117371         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
117372         * doc/posix-functions/vsprintf.texi (vsprintf): Likewise.
117373         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
117374         Likewise.
117375         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
117376         Likewise.
117377         * doc/glibc-functions/cfmakeraw.texi (cfmakeraw): Cygwin 1.7 adds
117378         this function.
117379         * doc/glibc-functions/in6addr_any.texi (in6addr_any): Likewise.
117380         * doc/glibc-functions/in6addr_loopback.texi (in6addr_loopback):
117381         Likewise.
117382         * doc/glibc-functions/updwtmpx.texi (updwtmpx): Likewise.
117383         * doc/posix-functions/_Exit_C99.texi (_Exit): Likewise.
117384         * doc/posix-functions/confstr.texi (confstr): Likewise.
117385         * doc/posix-functions/dprintf.texi (dprintf): Likewise.
117386         * doc/posix-functions/fgetwc.texi (fgetwc): Likewise.
117387         * doc/posix-functions/fgetws.texi (fgetws): Likewise.
117388         * doc/posix-functions/fputwc.texi (fputwc): Likewise.
117389         * doc/posix-functions/fputws.texi (fputws): Likewise.
117390         * doc/posix-functions/fwide.texi (fwide): Likewise.
117391         * doc/posix-functions/getwc.texi (getwc): Likewise.
117392         * doc/posix-functions/getwchar.texi (getwchar): Likewise.
117393         * doc/posix-functions/putwc.texi (putwc): Likewise.
117394         * doc/posix-functions/putwchar.texi (putwchar): Likewise.
117395         * doc/posix-functions/sigignore.texi (sigignore): Likewise.
117396         * doc/posix-functions/ungetwc.texi (ungetwc): Likewise.
117397         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
117398         * doc/posix-functions/wcpcpy.texi (wcpcpy): Likewise.
117399         * doc/posix-functions/wcpncpy.texi (wcpncpy): Likewise.
117400         * doc/posix-functions/wcstol.texi (wcstol): Likewise.
117401         * doc/posix-functions/wcstoll.texi (wcstoll): Likewise.
117402         * doc/posix-functions/wcstoul.texi (wcstoul): Likewise.
117403         * doc/posix-functions/wcstoull.texi (wcstoull): Likewise.
117404         * doc/posix-functions/wcsxfrm.texi (wcsxfrm): Likewise.
117406 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
117408         ioctl: avoid warning: no previous prototype for 'rpl_ioctl'
117409         * lib/ioctl.c: Include <sys/ioctl.h>.
117411 2009-01-19  Simon Josefsson  <simon@josefsson.org>
117413         * modules/getdate-tests (Depends-on): Add progname.
117414         * tests/test-getdate.c: Use progname module, to avoid link errors
117415         on non-glibc systems.
117417 2009-01-18  Simon Josefsson  <simon@josefsson.org>
117419         * modules/filenamecat-tests (Depends-on): Add progname.
117420         * modules/fstrcmp-tests (Depends-on): Likewise.
117422         * tests/test-filenamecat.c: Use progname module, to avoid link
117423         errors on non-glibc systems.
117424         * tests/test-fstrcmp.c: Likewise.
117426 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
117428         gettimeofday: avoid warning: nested extern declaration of 'localtime'
117429         * lib/gettimeofday.c: Move extern declaration out of function.
117431 2009-01-18  Bruno Haible  <bruno@clisp.org>
117433         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mblen and mbrlen.
117434         * lib/strftime.c (HAVE_MBLEN, HAVE_MBRLEN): Remove macros.
117435         (MULTIBYTE_IS_FORMAT_SAFE): Define to 1 on all platforms except OSF/1.
117437 2009-01-18  Bruno Haible  <bruno@clisp.org>
117439         * lib/strftime.c (MEMPCPY): Remove unused macro.
117440         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mempcpy.
117442 2009-01-18  Martin Lambers  <marlam@marlam.de>
117444         New module 'link'.
117445         * lib/unistd.in.h (link): New declaration.
117446         * lib/link.c: New file.
117447         * m4/link.m4: New file.
117448         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_LINK,
117449         HAVE_LINK.
117450         * modules/unistd (Makefile.am): Substitute GNULIB_LINK, HAVE_LINK.
117451         * modules/link: New file.
117452         * doc/posix-functions/link.texi: Mention the new module.
117454 2009-01-18  Bruno Haible  <bruno@clisp.org>
117456         * tests/test-avltree_list.c (main): Call set_program_name.
117457         * tests/test-avltree_oset.c (main): Likewise.
117458         * tests/test-obstack-printf.c: Include progname.h.
117459         (main): Call set_program_name.
117460         * tests/test-quotearg.c: Include progname.h.
117461         (main): Call set_program_name.
117462         * tests/test-xmemdup0.c: Include progname.h.
117463         (main): Call set_program_name.
117465 2009-01-18  Bruno Haible  <bruno@clisp.org>
117467         New module 'alphasort'.
117468         * lib/dirent.in.h (alphasort): New declaration.
117469         * lib/alphasort.c: New file, from glibc with modifications.
117470         * m4/alphasort.m4: New file.
117471         * modules/alphasort: New file.
117472         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_ALPHASORT,
117473         HAVE_ALPHASORT.
117474         * modules/dirent (Makefile.am): Substitute GNULIB_ALPHASORT,
117475         HAVE_ALPHASORT.
117476         * doc/posix-functions/alphasort.texi: Mention the new module and the
117477         portability problems.
117479 2009-01-18  Bruno Haible  <bruno@clisp.org>
117481         New module 'scandir'.
117482         * lib/dirent.in.h (scandir): New declaration.
117483         * lib/scandir.c: New file, from glibc with modifications.
117484         * m4/scandir.m4: New file.
117485         * modules/scandir: New file.
117486         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_SCANDIR,
117487         HAVE_SCANDIR.
117488         * modules/dirent (Makefile.am): Substitute GNULIB_SCANDIR,
117489         HAVE_SCANDIR.
117490         * doc/posix-functions/scandir.texi: Mention the new module and the
117491         portability problems.
117493 2009-01-17  Bruno Haible  <bruno@clisp.org>
117495         * gnulib-tool (func_remove_prefix): Escape all dots in the prefix.
117496         Update documentation.
117497         (func_remove_suffix): Escape all dots in the suffix. Update
117498         documentation.
117499         (func_filter_filelist): Update documentation.
117500         Reported by Ralf Wildenhues.
117502 2009-01-17  Bruno Haible  <bruno@clisp.org>
117504         * modules/dprintf-posix-tests: New file.
117505         * tests/test-dprintf-posix.sh: New file.
117506         * tests/test-dprintf-posix.c: New file.
117508         New modules 'dprintf', 'dprintf-posix'.
117509         * lib/stdio.in.h (dprintf): New declaration.
117510         * lib/dprintf.c: New file.
117511         * m4/dprintf.m4: New file.
117512         * m4/dprintf-posix.m4: New file.
117513         * modules/dprintf: New file.
117514         * modules/dprintf-posix: New file.
117515         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_DPRINTF,
117516         HAVE_DPRINTF, REPLACE_DPRINTF.
117517         * modules/stdio (Makefile.am): Substitute also GNULIB_DPRINTF,
117518         HAVE_DPRINTF, REPLACE_DPRINTF.
117519         * doc/posix-functions/dprintf.texi: Mention the new modules.
117521 2009-01-17  Bruno Haible  <bruno@clisp.org>
117523         * modules/vdprintf-posix-tests: New file.
117524         * tests/test-vdprintf-posix.sh: New file.
117525         * tests/test-vdprintf-posix.c: New file.
117527         New modules 'vdprintf', 'vdprintf-posix'.
117528         * lib/stdio.in.h (vdprintf): New declaration.
117529         * lib/vdprintf.c: New file.
117530         * m4/vdprintf.m4: New file.
117531         * m4/vdprintf-posix.m4: New file.
117532         * modules/vdprintf: New file.
117533         * modules/vdprintf-posix: New file.
117534         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_VDPRINTF,
117535         HAVE_VDPRINTF, REPLACE_VDPRINTF.
117536         * modules/stdio (Makefile.am): Substitute also GNULIB_VDPRINTF,
117537         HAVE_VDPRINTF, REPLACE_VDPRINTF.
117538         * doc/posix-functions/vdprintf.texi: Mention the new modules.
117540 2009-01-17  Bruno Haible  <bruno@clisp.org>
117542         Fix replacement of fopen on mingw.
117543         * m4/fopen.m4 (gl_FUNC_FOPEN): Define FOPEN_TRAILING_SLASH_BUG also on
117544         mingw.
117546 2009-01-17  Bruno Haible  <bruno@clisp.org>
117548         Fix compilation error on HP-UX 11.00, present since 2008-09-24.
117549         * lib/fopen.c: Include <sys/types.h> and <sys/types.h>.
117551 2009-01-17  Bruno Haible  <bruno@clisp.org>
117553         Avoid test-fflush2.sh failure on mingw.
117554         * tests/test-fflush2.c: Include binary-io.h.
117555         (main): Put standard input into binary mode.
117556         * modules/fflush-tests (Depends-on): Add binary-io.
117558 2009-01-17  Bruno Haible  <bruno@clisp.org>
117560         * lib/wchar.in.h: In another particular situation, include only the
117561         system's <wchar.h> file.
117562         (_GL_ALREADY_INCLUDING_WCHAR_H): New macro.
117563         Reported by Albert Chin-A-Young <china@thewrittenword.com>
117564         and Thomas Guyot-Sionnest <dermoth@aei.ca>.
117566 2009-01-17  Bruno Haible  <bruno@clisp.org>
117568         Support for stripping executables in --enable-relocatable.
117569         * build-aux/install-reloc: Expect one more argument, or an environment
117570         variable RELOC_STRIP_PROG. If set, strip the destination program and
117571         its wrapper.
117572         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV, set
117573         RELOC_STRIP_PROG.
117574         * doc/relocatable-maint.texi (Supporting Relocation): Mention the need
117575         to set RELOCATABLE_STRIP.
117576         * NEWS: Mention the new Makefile requirement.
117578 2009-01-17  Bruno Haible  <bruno@clisp.org>
117580         * build-aux/install-reloc: Remove debugging information left over by
117581         C compiler on MacOS X.
117583 2009-01-17  Bruno Haible  <bruno@clisp.org>
117585         Update use of _NSGetExecutablePath after API change in MacOS X 10.4.
117586         * lib/progreloc.c (find_executable): Fix type of pointer passed to
117587         _NSGetExecutablePath.
117589 2009-01-16  Jim Meyering  <meyering@redhat.com>
117591         strerror: avoid warnings about discarding "const"
117592         * lib/strerror.c (rpl_strerror): Instead of returning a const
117593         string from each and every "case", use a variable, and add a single
117594         cast after the switch.
117596 2009-01-16  Albert Chin-A-Young  <china@thewrittenword.com>
117598         * lib/arpa_inet.in.h: Add extern "C" block for C++.
117600 2009-01-16  Bruno Haible  <bruno@clisp.org>
117602         * m4/printf.m4 (gl_SNPRINTF_SIZE1, gl_VSNPRINTF_ZEROSIZE_C99): Use an
117603         array initializer syntax that also works in C++ mode.
117604         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
117606 2009-01-16  Jim Meyering  <meyering@redhat.com>
117608         poll: suppress a warning
117609         * lib/poll.c: Use #pragma GCC diagnostic ignored "-Wtype-limits"
117610         to ignore "...unsigned expression < 0 is always false" warnings.
117612 2009-01-16  Daniel P. Berrange  <berrange@redhat.com>
117614         poll: remove declarations of unused variables
117615         * lib/poll.c (poll) [WIN32_NATIVE]: Remove declarations of unused
117616         sockbuf and optlen.
117618 2009-01-15  Bruno Haible  <bruno@clisp.org>
117620         Make fflush-after-ungetc POSIX compliant on BSD systems.
117621         * lib/fflush.c (clear_ungetc_buffer_preserving_position): New function.
117622         (clear_ungetc_buffer): Implement also for other systems.
117623         (rpl_fflush): On glibc systems, invoke
117624         clear_ungetc_buffer_preserving_position. Otherwise, invoke
117625         clear_ungetc_buffer after fetching the stream's position, not before.
117627 2009-01-15  Bruno Haible  <bruno@clisp.org>
117629         Make fflush-after-ungetc POSIX compliant on glibc systems.
117630         * m4/fflush.m4 (gl_FUNC_FFLUSH): Test also the behaviour of fflush
117631         after ungetc.
117632         * lib/fflush.c (clear_ungetc_buffer): Implement for glibc systems.
117633         (rpl_fflush): On glibc systems, simply call the system's fflush
117634         function after clearing the ungetc buffer.
117635         * lib/fseeko.c (rpl_fseeko): Don't try to lseek past the end of file.
117636         Instead, lseek only to the end of file, then use the system's fseeko
117637         for the rest. On glibc systems, reset the EOF indicator bit.
117639 2009-01-15  Jim Meyering  <meyering@redhat.com>
117641         openmp.m4: revert quote-adding change, for portability to older autoconf
117642         * m4/openmp.m4: Remove the quotes added on 2009-01-14.
117643         This reverts part of 42d1eda5dcce2d68deab7a642e7f29bcd7144a0d.
117644         Simon Josefsson noticed the problem when using autoconf-2.61.
117646 2009-01-15  Bruno Haible  <bruno@clisp.org>
117648         * tests/test-fflush2.sh: Invoke test-fflush2 twice.
117649         * tests/test-fflush2.c (ASSERT): Always fail.
117650         (main): Add two tests for fflush() after ungetc(), taking into account
117651         the Austin Group's clarification.
117652         Suggested by Eric Blake.
117654 2009-01-15  Albert Chin-A-Young  <china@thewrittenword.com>
117656         mktime.m4: remove K&R-style function prototypes
117657         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove K&R-style function prototypes
117658         for the Sun C++ compiler.
117660 2009-01-14  Bruno Haible  <bruno@clisp.org>
117662         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_WCHAR_H): New macro, defined
117663         while including <wchar.h>.
117664         * lib/wchar.in.h: In two particular situations on HP-UX, include only
117665         the system's <wchar.h> file.
117666         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
117668 2009-01-14  Bruno Haible  <bruno@clisp.org>
117670         * m4/csharp.m4: Don't mention gettext on the serial number line.
117671         * m4/csharpexec.m4: Likewise.
117672         * m4/eaccess.m4: Likewise.
117673         * m4/javaexec.m4: Likewise.
117674         * m4/sig_atomic_t.m4: Likewise.
117675         * m4/tmpdir.m4: Likewise.
117676         * m4/intldir.m4: Bump gettext version.
117677         * m4/lib-ld.m4: Likewise.
117679 2009-01-14  Bruno Haible  <bruno@clisp.org>
117681         * lib/progname.c (set_program_name): Add more comments.
117682         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
117684 2009-01-14  Simon Josefsson  <simon@josefsson.org>
117686         * lib/sys_stat.in.h: Include sys/types.h for nlink_t on systems
117687         were sys/stat.h does not define it.
117689 2009-01-14  Jim Meyering  <meyering@redhat.com>
117691         many *.m4 files: improve m4 quoting
117692         99% of this change was performed by running the following commands:
117693         git ls-files | grep '\.m4$' | xargs perl -pi \
117694           -e 's/(AC_\w+\()([^[()]+?)([,)])/$1\[$2]$3/g;' \
117695           -e 's/(AC_\w+\((?:\[[^,]+?\], ){1})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
117696           -e 's/(AC_\w+\((?:\[[^,]+?\], ){2})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
117697           -e 's/(AC_\w+\((?:\[[^,]+?\], ){3})([^,[()]+?)([,)])/$1\[$2]$3/g'
117698         perl -pi -e 's/\[\.\.\.\]/.../' m4/onceonly.m4
117699         The remainder were to add Copyright dates, increment serial numbers,
117700         undo some changes in comments, exclude m4/intl.m4, and add quotes
117701         around the "1" in ",1" where the unusual spacing prohibited the
117702         above regexps from doing the job.  For more details, see
117703         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16175>.
117704         * m4/acl.m4: Modified.
117705         * m4/afs.m4: Likewise.
117706         * m4/alloca.m4: Likewise.
117707         * m4/argp.m4: Likewise.
117708         * m4/argz.m4: Likewise.
117709         * m4/atexit.m4: Likewise.
117710         * m4/bison-i18n.m4: Likewise.
117711         * m4/bison.m4: Likewise.
117712         * m4/byteswap.m4: Likewise.
117713         * m4/c-stack.m4: Likewise.
117714         * m4/c-strtod.m4: Likewise.
117715         * m4/calloc.m4: Likewise.
117716         * m4/canonicalize-lgpl.m4: Likewise.
117717         * m4/chown.m4: Likewise.
117718         * m4/clock_time.m4: Likewise.
117719         * m4/codeset.m4: Likewise.
117720         * m4/copy-file.m4: Likewise.
117721         * m4/csharp.m4: Likewise.
117722         * m4/csharpcomp.m4: Likewise.
117723         * m4/csharpexec.m4: Likewise.
117724         * m4/d-ino.m4: Likewise.
117725         * m4/d-type.m4: Likewise.
117726         * m4/dirfd.m4: Likewise.
117727         * m4/double-slash-root.m4: Likewise.
117728         * m4/eaccess.m4: Likewise.
117729         * m4/eealloc.m4: Likewise.
117730         * m4/environ.m4: Likewise.
117731         * m4/errno_h.m4: Likewise.
117732         * m4/euidaccess.m4: Likewise.
117733         * m4/execute.m4: Likewise.
117734         * m4/fatal-signal.m4: Likewise.
117735         * m4/fchdir.m4: Likewise.
117736         * m4/fcntl_h.m4: Likewise.
117737         * m4/fileblocks.m4: Likewise.
117738         * m4/filenamecat.m4: Likewise.
117739         * m4/findprog.m4: Likewise.
117740         * m4/flexmember.m4: Likewise.
117741         * m4/fnmatch.m4: Likewise.
117742         * m4/fopen.m4: Likewise.
117743         * m4/fpending.m4: Likewise.
117744         * m4/fprintf-posix.m4: Likewise.
117745         * m4/free.m4: Likewise.
117746         * m4/frexp.m4: Likewise.
117747         * m4/frexpl.m4: Likewise.
117748         * m4/fsusage.m4: Likewise.
117749         * m4/ftruncate.m4: Likewise.
117750         * m4/gc-camellia.m4: Likewise.
117751         * m4/gc-random.m4: Likewise.
117752         * m4/gc.m4: Likewise.
117753         * m4/getaddrinfo.m4: Likewise.
117754         * m4/getcwd-abort-bug.m4: Likewise.
117755         * m4/getcwd-path-max.m4: Likewise.
117756         * m4/getdate.m4: Likewise.
117757         * m4/getdomainname.m4: Likewise.
117758         * m4/getgroups.m4: Likewise.
117759         * m4/gethostname.m4: Likewise.
117760         * m4/gethrxtime.m4: Likewise.
117761         * m4/getline.m4: Likewise.
117762         * m4/getloadavg.m4: Likewise.
117763         * m4/getndelim2.m4: Likewise.
117764         * m4/getpass.m4: Likewise.
117765         * m4/gettext.m4: Likewise.
117766         * m4/gettime.m4: Likewise.
117767         * m4/gettimeofday.m4: Likewise.
117768         * m4/gnulib-common.m4: Likewise.
117769         * m4/group-member.m4: Likewise.
117770         * m4/host-os.m4: Likewise.
117771         * m4/iconv.m4: Likewise.
117772         * m4/iconv_open.m4: Likewise.
117773         * m4/inet_ntop.m4: Likewise.
117774         * m4/inet_pton.m4: Likewise.
117775         * m4/inline.m4: Likewise.
117776         * m4/intldir.m4: Likewise.
117777         * m4/intlmacosx.m4: Likewise.
117778         * m4/intmax.m4: Likewise.
117779         * m4/intmax_t.m4: Likewise.
117780         * m4/inttypes.m4: Likewise.
117781         * m4/inttypes_h.m4: Likewise.
117782         * m4/inttypes-pri.m4: Likewise.
117783         * m4/isapipe.m4: Likewise.
117784         * m4/isnand.m4: Likewise.
117785         * m4/isnanf.m4: Likewise.
117786         * m4/isnanl.m4: Likewise.
117787         * m4/javacomp.m4: Likewise.
117788         * m4/javaexec.m4: Likewise.
117789         * m4/jm-winsz1.m4: Likewise.
117790         * m4/jm-winsz2.m4: Likewise.
117791         * m4/lchown.m4: Likewise.
117792         * m4/lcmessage.m4: Likewise.
117793         * m4/ldexpl.m4: Likewise.
117794         * m4/lib-ld.m4: Likewise.
117795         * m4/lib-link.m4: Likewise.
117796         * m4/libsigsegv.m4: Likewise.
117797         * m4/link-follow.m4: Likewise.
117798         * m4/localcharset.m4: Likewise.
117799         * m4/locale-fr.m4: Likewise.
117800         * m4/locale-ja.m4: Likewise.
117801         * m4/locale-tr.m4: Likewise.
117802         * m4/locale-zh.m4: Likewise.
117803         * m4/lock.m4: Likewise.
117804         * m4/longlong.m4: Likewise.
117805         * m4/ls-mntd-fs.m4: Likewise.
117806         * m4/lstat.m4: Likewise.
117807         * m4/malloc.m4: Likewise.
117808         * m4/mathl.m4: Likewise.
117809         * m4/mbrtowc.m4: Likewise.
117810         * m4/mbstate_t.m4: Likewise.
117811         * m4/mbswidth.m4: Likewise.
117812         * m4/memchr.m4: Likewise.
117813         * m4/memcmp.m4: Likewise.
117814         * m4/memcpy.m4: Likewise.
117815         * m4/memmem.m4: Likewise.
117816         * m4/memmove.m4: Likewise.
117817         * m4/mempcpy.m4: Likewise.
117818         * m4/memrchr.m4: Likewise.
117819         * m4/memset.m4: Likewise.
117820         * m4/minmax.m4: Likewise.
117821         * m4/mkdir-slash.m4: Likewise.
117822         * m4/mkdtemp.m4: Likewise.
117823         * m4/mktime.m4: Likewise.
117824         * m4/mmap-anon.m4: Likewise.
117825         * m4/mountlist.m4: Likewise.
117826         * m4/nanosleep.m4: Likewise.
117827         * m4/nls.m4: Likewise.
117828         * m4/nocrash.m4: Likewise.
117829         * m4/open.m4: Likewise.
117830         * m4/openat.m4: Likewise.
117831         * m4/openmp.m4: Likewise.
117832         * m4/pathmax.m4: Likewise.
117833         * m4/perl.m4: Likewise.
117834         * m4/physmem.m4: Likewise.
117835         * m4/pipe.m4: Likewise.
117836         * m4/po.m4: Likewise.
117837         * m4/poll.m4: Likewise.
117838         * m4/posixtm.m4: Likewise.
117839         * m4/posixver.m4: Likewise.
117840         * m4/printf-frexp.m4: Likewise.
117841         * m4/printf-frexpl.m4: Likewise.
117842         * m4/printf-posix.m4: Likewise.
117843         * m4/printf-posix-rpl.m4: Likewise.
117844         * m4/printf.m4: Likewise.
117845         * m4/progtest.m4: Likewise.
117846         * m4/putenv.m4: Likewise.
117847         * m4/readline.m4: Likewise.
117848         * m4/readlink.m4: Likewise.
117849         * m4/readutmp.m4: Likewise.
117850         * m4/realloc.m4: Likewise.
117851         * m4/regex.m4: Likewise.
117852         * m4/relocatable.m4: Likewise.
117853         * m4/relocatable-lib.m4: Likewise.
117854         * m4/rename-dest-slash.m4: Likewise.
117855         * m4/rename.m4: Likewise.
117856         * m4/rmdir-errno.m4: Likewise.
117857         * m4/rmdir.m4: Likewise.
117858         * m4/roundf.m4: Likewise.
117859         * m4/roundl.m4: Likewise.
117860         * m4/rpmatch.m4: Likewise.
117861         * m4/save-cwd.m4: Likewise.
117862         * m4/selinux-selinux-h.m4: Likewise.
117863         * m4/setenv.m4: Likewise.
117864         * m4/settime.m4: Likewise.
117865         * m4/sig2str.m4: Likewise.
117866         * m4/sig_atomic_t.m4: Likewise.
117867         * m4/signalblocking.m4: Likewise.
117868         * m4/signbit.m4: Likewise.
117869         * m4/sigpipe.m4: Likewise.
117870         * m4/sockets.m4: Likewise.
117871         * m4/sockpfaf.m4: Likewise.
117872         * m4/st_dm_mode.m4: Likewise.
117873         * m4/stat-time.m4: Likewise.
117874         * m4/stdbool.m4: Likewise.
117875         * m4/stdint.m4: Likewise.
117876         * m4/stdint_h.m4: Likewise.
117877         * m4/stpcpy.m4: Likewise.
117878         * m4/stpncpy.m4: Likewise.
117879         * m4/strcase.m4: Likewise.
117880         * m4/strchrnul.m4: Likewise.
117881         * m4/strcspn.m4: Likewise.
117882         * m4/strdup.m4: Likewise.
117883         * m4/strftime.m4: Likewise.
117884         * m4/strndup.m4: Likewise.
117885         * m4/strnlen.m4: Likewise.
117886         * m4/strpbrk.m4: Likewise.
117887         * m4/strptime.m4: Likewise.
117888         * m4/strsep.m4: Likewise.
117889         * m4/strtod.m4: Likewise.
117890         * m4/strtoimax.m4: Likewise.
117891         * m4/strtok_r.m4: Likewise.
117892         * m4/strtol.m4: Likewise.
117893         * m4/strtoll.m4: Likewise.
117894         * m4/strtoul.m4: Likewise.
117895         * m4/strtoull.m4: Likewise.
117896         * m4/strtoumax.m4: Likewise.
117897         * m4/strverscmp.m4: Likewise.
117898         * m4/threadlib.m4: Likewise.
117899         * m4/timegm.m4: Likewise.
117900         * m4/tm_gmtoff.m4: Likewise.
117901         * m4/tmpdir.m4: Likewise.
117902         * m4/tmpfile.m4: Likewise.
117903         * m4/tzset.m4: Likewise.
117904         * m4/uintmax_t.m4: Likewise.
117905         * m4/unlinkdir.m4: Likewise.
117906         * m4/unlocked-io.m4: Likewise.
117907         * m4/uptime.m4: Likewise.
117908         * m4/userspec.m4: Likewise.
117909         * m4/utimbuf.m4: Likewise.
117910         * m4/utime.m4: Likewise.
117911         * m4/utimes-null.m4: Likewise.
117912         * m4/utimes.m4: Likewise.
117913         * m4/vararrays.m4: Likewise.
117914         * m4/vasnprintf.m4: Likewise.
117915         * m4/vfprintf-posix.m4: Likewise.
117916         * m4/vprintf-posix.m4: Likewise.
117917         * m4/wait-process.m4: Likewise.
117918         * m4/wchar_t.m4: Likewise.
117919         * m4/wint_t.m4: Likewise.
117920         * m4/write-any-file.m4: Likewise.
117921         * m4/yield.m4: Likewise.
117923 2009-01-13  Bruno Haible  <bruno@clisp.org>
117925         Avoid test-copy-file.sh failures when ACL support insufficient.
117926         * modules/copy-file-tests (Makefile.am): Pass USE_ACL in
117927         TESTS_ENVIRONMENT.
117928         * tests/test-copy-file.sh: Skip the ACL comparisons if USE_ACL is 0.
117929         Reported by Jim Meyering.
117931 2009-01-13  Bruno Haible  <bruno@clisp.org>
117933         * modules/unistdio/u-printf-args (Files): Add m4/stdint_h.m4 and
117934         m4/inttypes_h.m4, needed by m4/intmax_t.m4.
117935         * modules/unistdio/u8-printf-parse (Files): Likewise.
117936         * modules/unistdio/u32-printf-parse (Files): Likewise.
117937         * modules/unistdio/ulc-printf-parse (Files): Likewise.
117939 2009-01-13  Simon Josefsson  <simon@josefsson.org>
117941         * modules/unistdio/u16-printf-parse (Files): Add m4/stdint_h.m4
117942         and m4/inttypes_h.m4 too.
117944 2009-01-12  Eric Blake  <ebb9@byu.net>
117946         tests: IRIX 6.2 cc can't compile -0.0 into .data
117947         * tests/test-ceill.c (minus_zero): Compute -0.0L at runtime,
117948         rather than at compile-time.
117949         * tests/test-floorl.c (minus_zero): Likewise.
117950         * tests/test-frexpl.c (minus_zero): Likewise.
117951         * tests/test-isnan.c (minus_zerol): Likewise.
117952         * tests/test-isnanl.h (minus_zero): Likewise.
117953         * tests/test-ldexpl.c (minus_zero): Likewise.
117954         * tests/test-roundl.c (minus_zero): Likewise.
117955         * tests/test-signbit.c (minus_zerol): Likewise.
117956         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
117957         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
117958         * tests/test-truncl.c (minus_zero): Likewise.
117959         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
117960         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
117961         Reported by Tom G. Christensen and Nelson H. F. Beebe.
117963 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
117965         regex: fix glibc bug 9697
117966         * lib/regcomp.c (re_compile_fastmap_iter): Rewrite COMPLEX_BRACKET
117967         handling.
117969 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
117971         regex: fix glibc bug 697
117972         * lib/regexec.c (prune_impossible_nodes): Handle sifted_states[0]
117973         being NULL also if there are no backreferences.
117975 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
117977         regex: merge glibc changes
117978         * lib/regcomp.c (re_compile_fastmap_iter): Use __mbrtowc.
117979         * lib/regex_internal.c (build_wcs_buffer, build_wcs_upper_buffer,
117980         re_string_skip_chars, re_string_reconstruct): Likewise.
117981         * lib/regex_internal.h [!_LIBC] (__mbrtowc): New #define.
117983 2009-01-07  Jim Meyering  <meyering@redhat.com>
117985         poll: filter through cppi
117986         * lib/poll.c: Indent cpp directives to reflect nesting.
117988 2009-01-07  Daniel P. Berrange  <berrange@redhat.com>
117990         poll: don't return uninitialized
117991         * lib/poll.c (poll) [WIN32_NATIVE]: Initialize "rc".
117993 2009-01-06  Jeremy Olexa  <darkside@gentoo.org>  (tiny change)
117995         avoid compile failure on AIX 6.1
117996         * lib/getloadavg.c [HAVE_LIBPERFSTAT]: Include <sys/protosw.h>.
117997         Details in http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/15465
117999 2009-01-04  Jim Meyering  <meyering@redhat.com>
118001         remove duplicate inclusion of <stdio.h>
118002         * tests/test-fprintf-posix.c: Likewise.
118003         * tests/test-printf-posix.c: Likewise.
118004         * tests/test-snprintf-posix.c: Likewise.
118005         * tests/test-sprintf-posix.c: Likewise.
118006         * tests/test-vasprintf-posix.c: Likewise.
118007         * tests/test-vfprintf-posix.c: Likewise.
118008         * tests/test-vprintf-posix.c: Likewise.
118009         * tests/test-vsnprintf-posix.c: Likewise.
118010         * tests/test-vsprintf-posix.c: Likewise.
118012 2009-01-03  Jim Meyering  <meyering@redhat.com>
118014         gnulib-tool: fix sed-based filtering
118015         * gnulib-tool (func_filter_filelist): Remove extra backslash
118016         in sed_fff_filter definition.
118018 2009-01-02  Jim Meyering  <meyering@redhat.com>
118020         strftime: avoid compilation failure on Solaris 2.6
118021         * modules/strftime (Depends-on): Add mbrlen and mbsinit.
118022         * lib/strftime.c [DO_MULTIBYTE]: Include <wchar.h> unconditionally.
118023         Don't #define mbrlen or mbsinit, since now they're guaranteed to
118024         be available.  Reported by Tom G. Christensen.  Details in
118025         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16180>.
118027 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
118028             Bruno Haible  <bruno@clisp.org>
118030         Speed up gnulib-tool by doing more string processing through shell
118031         built-ins.
118032         * gnulib-tool (fast_func_append): New variable.
118033         (func_remove_prefix, func_remove_suffix): New functions.
118034         (fast_func_remove_prefix, fast_func_remove_suffix): New variables.
118035         (func_filter_filelist): New function.
118036         (func_get_dependencies): Use func_remove_suffix instead of sed.
118037         (func_get_automake_snippet): Use func_filter_filelist instead of a
118038         subshell and sed invocation.
118040 2009-01-01  Bruno Haible  <bruno@clisp.org>
118042         Fix a security bug.
118043         * gnulib-tool (func_import, import, update): Don't allow the characters
118044         '"', '$', '`', '\' in macro arguments that become part of commands that
118045         are evaluated.
118047 2009-01-01  Bruno Haible  <bruno@clisp.org>
118049         * gnulib-tool (func_reset_sigpipe): Add more comments.
118051 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
118053         * gnulib-tool (func_modules_add_dummy, func_emit_lib_Makefile_am,
118054         func_emit_tests_Makefile_am, func_import): Abort loops early if we
118055         already know the answer.
118057 2009-01-01  Jim Meyering  <meyering@redhat.com>
118059         * lib/version-etc.c (version_etc_va): Update copyright year.
118061 2008-12-30  Bruno Haible  <bruno@clisp.org>
118063         * m4/lib-prefix.m4 (AC_LIB_LINKFLAGS_BODY): Don't overwrite
118064         LIB${NAME}_PREFIX when considering the dependencies of lib${name}.
118065         Reported by Charles Wilson <cygwin@cwilson.fastmail.fm>.
118067 2008-12-29  Eric Blake  <ebb9@byu.net>
118069         multiarch: avoid autoconf AC_REQUIRE bug
118070         * m4/multiarch.m4 (gl_MULTIARCH): Split body...
118071         (gl_MULTIARCH_BODY): ...into new macro, to work around bug in Autoconf
118072         2.63 and older.
118073         Reported by Bruno Haible, and analyzed in
118074         http://lists.gnu.org/r/bug-autoconf/2008-12/msg00039.html
118076 2008-12-29  Bruno Haible  <bruno@clisp.org>
118078         * gnulib-tool (func_import): When generating sed-ignore-removed, handle
118079         files in subdirectories correctly.
118080         Reported by Ralf Wildenhues.
118082 2008-12-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
118084         * gnulib-tool (func_update_ignorelist): Use 'join - FILE'
118085         rather than 'join FILE -', for Solaris join.
118087 2008-12-29  Bruno Haible  <bruno@clisp.org>
118089         * m4/codeset.m4 (AM_LANGINFO_CODESET): More systematic m4 argument
118090         quoting.
118091         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
118092         * m4/glibc2.m4 (gt_GLIBC2): Likewise.
118093         * m4/glibc21.m4 (gl_GLIBC21): Likewise.
118094         * m4/iconv.m4 (AM_ICONV_LINK, AM_ICONV): Likewise.
118095         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
118096         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Likewise.
118097         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Likewise.
118098         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Likewise.
118099         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
118100         * m4/lcmessage.m4 (gt_LC_MESSAGES): Likewise.
118101         * m4/nls.m4 (AM_NLS): Likewise.
118102         * m4/po.m4 (AM_PO_SUBDIRS): Likewise.
118103         * m4/printf-posix.m4 (gt_PRINTF_POSIX): Likewise.
118104         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
118105         * m4/size_max.m4 (gl_SIZE_MAX): Likewise.
118106         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Likewise.
118107         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
118108         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Likewise.
118109         * m4/visibility.m4 (gl_VISIBILITY): Likewise.
118110         * m4/wchar_t.m4 (gt_TYPE_WCHAR_T): Likewise.
118111         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
118112         * m4/xsize.m4 (gl_XSIZE): Likewise.
118113         Suggested by Jim Meyering.
118115 2008-11-17  Bruce Korb  <bkorb@gnu.org>
118117         * lib/parse-duration.h: non-iso form accepts years, months weeks, too
118118         * lib/parse-duration.c: use a switch instead of cascading if's.
118120 2008-12-29  Eric Blake  <ebb9@byu.net>
118122         wchar.h: supply WEOF on Irix 5.3
118123         * lib/wchar.in.h (wint_t): Also supply WEOF.
118124         * lib/wctype.in.h (wint_t): Likewise.
118125         * doc/posix-headers/wchar.texi (wchar.h): Document the bug.
118126         * doc/posix-headers/wctype.texi (wctype.h): Likewise.
118127         Reported by Tom G. Christensen.
118129 2008-12-26  Bruno Haible  <bruno@clisp.org>
118131         * m4/multiarch.m4 (gl_MULTIARCH): Recognize also the architecture names
118132         i486, i586, i686.
118134 2008-12-26  Bruno Haible  <bruno@clisp.org>
118136         * lib/stdlib.in.h (struct random_data): Fix indentation of comments.
118138 2008-12-26  Bruno Haible  <bruno@clisp.org>
118140         * lib/stdint.in.h: Move the include of <wchar.h> down until after all
118141         the types are defined. Also conditionalize it on __STDC_LIMIT_MACROS,
118142         not __STDC_CONSTANT_MACROS.
118143         Reported by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
118145 2008-12-25  Bruno Haible  <bruno@clisp.org>
118147         Add support for universal builds to vasnprintf.
118148         * m4/printf.m4 (gl_PRINTF_ENOMEM): Require gl_MULTIARCH. In Apple
118149         universal builds, guess no.
118150         * modules/vasnprintf-posix (Depends-on): Add multiarch.
118151         * modules/vasprintf-posix (Depends-on): Likewise.
118152         * modules/fprintf-posix (Depends-on): Likewise.
118153         * modules/vfprintf-posix (Depends-on): Likewise.
118154         * modules/snprintf-posix (Depends-on): Likewise.
118155         * modules/vsnprintf-posix (Depends-on): Likewise.
118156         * modules/sprintf-posix (Depends-on): Likewise.
118157         * modules/vsprintf-posix (Depends-on): Likewise.
118158         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
118159         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
118160         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
118161         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
118162         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
118163         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
118164         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
118166         Add support for universal builds to <inttypes.h>.
118167         * lib/inttypes.in.h (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX,
118168         _SCNu64_PREFIX): In Apple
118169         universal builds, define directly, using _LP64.
118170         * m4/inttypes.m4 (gl_INTTYPES_H): In Apple universal builds, set
118171         INT64_MAX_EQ_LONG_MAX and UINT64_MAX_EQ_ULONG_MAX to -1.
118172         * modules/inttypes (Depends-on): Add multiarch.
118173         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
118175         Add support for universal builds to <stdint.h>.
118176         * lib/stdint.in.h (PDFDIFF_MIN, PTRDIFF_MAX, SIZE_MAX): In Apple
118177         universal builds, define directly, using _LP64.
118178         * m4/stdint.m4 (gl_STDINT_TYPE_PROPERTIES): Require gl_MULTIARCH. In
118179         Apple universal builds, don't test for the size and suffix of ptrdiff_t
118180         and size_t.
118181         * modules/stdint (Depends-on): Add multiarch.
118182         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
118184         New module 'multiarch'.
118185         * modules/multiarch: New file.
118186         * m4/multiarch.m4: New file.
118188 2008-12-25  Bruno Haible  <bruno@clisp.org>
118190         * gnulib-tool (func_create_testdir): Avoid failure of mv command.
118192 2008-12-25  Bruno Haible  <bruno@clisp.org>
118194         * modules/btowc (License): Relicense under LGPLv2+.
118195         * modules/mbsinit (License): Likewise.
118196         * modules/mbrtowc (License): Likewise.
118197         * modules/wcrtomb (License): Likewise.
118198         * modules/streq (License): Likewise.
118199         Reported by David Lutterkort <lutter@redhat.com>.
118201 2008-12-23  Bruno Haible  <bruno@clisp.org>
118203         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Fix conditional and comment.
118205 2008-12-23  Bruno Haible  <bruno@clisp.org>
118207         Module getaddrinfo requires linking with $(GETADDRINFO_LIB).
118208         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Put link options into
118209         GETADDRINFO_LIB, not in LIBS.
118210         * modules/getaddrinfo (Link): Set to $(GETADDRINFO_LIB).
118211         * modules/canon-host (Link): Likewise.
118212         * NEWS: Mention the change.
118213         * modules/getaddrinfo-tests (test_getaddrinfo_LDADD): Add the
118214         GETADDRINFO_LIB.
118216 2008-12-22  Bruno Haible  <bruno@clisp.org>
118218         * doc/posix-functions/iswalnum_l.texi: Mention limitation of wchar_t.
118219         * doc/posix-functions/iswalpha_l.texi: Likewise.
118220         * doc/posix-functions/iswblank_l.texi: Likewise.
118221         * doc/posix-functions/iswcntrl_l.texi: Likewise.
118222         * doc/posix-functions/iswctype_l.texi: Likewise.
118223         * doc/posix-functions/iswdigit_l.texi: Likewise.
118224         * doc/posix-functions/iswgraph_l.texi: Likewise.
118225         * doc/posix-functions/iswlower_l.texi: Likewise.
118226         * doc/posix-functions/iswprint_l.texi: Likewise.
118227         * doc/posix-functions/iswpunct_l.texi: Likewise.
118228         * doc/posix-functions/iswspace_l.texi: Likewise.
118229         * doc/posix-functions/iswupper_l.texi: Likewise.
118230         * doc/posix-functions/iswxdigit_l.texi: Likewise.
118231         * doc/posix-functions/mbsnrtowcs.texi: Likewise.
118232         * doc/posix-functions/open_wmemstream.texi: Likewise.
118233         * doc/posix-functions/swscanf.texi: Likewise.
118234         * doc/posix-functions/towctrans_l.texi: Likewise.
118235         * doc/posix-functions/towlower.texi: Likewise.
118236         * doc/posix-functions/towlower_l.texi: Likewise.
118237         * doc/posix-functions/towupper.texi: Likewise.
118238         * doc/posix-functions/towupper_l.texi: Likewise.
118239         * doc/posix-functions/vfwprintf.texi: Likewise.
118240         * doc/posix-functions/vfwscanf.texi: Likewise.
118241         * doc/posix-functions/vswscanf.texi: Likewise.
118242         * doc/posix-functions/vwprintf.texi: Likewise.
118243         * doc/posix-functions/vwscanf.texi: Likewise.
118244         * doc/posix-functions/wcpcpy.texi: Likewise.
118245         * doc/posix-functions/wcpncpy.texi: Likewise.
118246         * doc/posix-functions/wcscasecmp.texi: Likewise.
118247         * doc/posix-functions/wcscasecmp_l.texi: Likewise.
118248         * doc/posix-functions/wcscoll_l.texi: Likewise.
118249         * doc/posix-functions/wcsdup.texi: Likewise.
118250         * doc/posix-functions/wcsncasecmp.texi: Likewise.
118251         * doc/posix-functions/wcsncasecmp_l.texi: Likewise.
118252         * doc/posix-functions/wcsnlen.texi: Likewise.
118253         * doc/posix-functions/wcsnrtombs.texi: Likewise.
118254         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
118255         * doc/posix-functions/wctrans_l.texi: Likewise.
118256         * doc/posix-functions/wctype_l.texi: Likewise.
118257         * doc/glibc-functions/fgetwc_unlocked.texi: Likewise.
118258         * doc/glibc-functions/fgetws_unlocked.texi: Likewise.
118259         * doc/glibc-functions/fputwc_unlocked.texi: Likewise.
118260         * doc/glibc-functions/fputws_unlocked.texi: Likewise.
118261         * doc/glibc-functions/getwc_unlocked.texi: Likewise.
118262         * doc/glibc-functions/getwchar_unlocked.texi: Likewise.
118263         * doc/glibc-functions/putwc_unlocked.texi: Likewise.
118264         * doc/glibc-functions/putwchar_unlocked.texi: Likewise.
118265         * doc/glibc-functions/wcschrnul.texi: Likewise.
118266         * doc/glibc-functions/wcsftime_l.texi: Likewise.
118267         * doc/glibc-functions/wcstod_l.texi: Likewise.
118268         * doc/glibc-functions/wcstof_l.texi: Likewise.
118269         * doc/glibc-functions/wcstol_l.texi: Likewise.
118270         * doc/glibc-functions/wcstold_l.texi: Likewise.
118271         * doc/glibc-functions/wcstoll_l.texi: Likewise.
118272         * doc/glibc-functions/wcstoq.texi: Likewise.
118273         * doc/glibc-functions/wcstoul_l.texi: Likewise.
118274         * doc/glibc-functions/wcstoull_l.texi: Likewise.
118275         * doc/glibc-functions/wcstouq.texi: Likewise.
118276         * doc/glibc-functions/wmempcpy.texi: Likewise.
118278 2008-12-22  Ingo Weinhold  <ingo_weinhold@gmx.de>  (tiny change)
118279             Eric Blake  <ebb9@byu.net>
118280             Paolo Bonzini  <bonzini@gnu.org>
118281             Bruno Haible  <bruno@clisp.org>
118283         Make c-stack work on Haiku.
118284         * lib/c-stack.c (SA_ONSTACK): Define fallback.
118285         (c_stack_action): Use SA_ONSTACK flag.
118287 2008-12-22  Bruno Haible  <bruno@clisp.org>
118289         * m4/locale-fr.m4 (gt_LOCALE_FR_UTF8): Treat Haiku like BeOS.
118291 2008-12-22  Bruno Haible  <bruno@clisp.org>
118293         Work around mbrlen() bugs on AIX, HP-UX, OSF/1, Solaris.
118294         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): Set REPLACE_MBRLEN if mbrtowc is
118295         being overridden.
118296         (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL, gl_MBRLEN_NUL_RETVAL):
118297         New macros.
118298         * lib/wchar.in.h (mbrlen): Override if REPLACE_MBRLEN is set.
118299         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBRLEN.
118300         * modules/wchar (Makefile.am): Substitute REPLACE_MBRLEN.
118301         * doc/posix-functions/mbrlen.texi: Mention the various platform bugs.
118303 2008-12-22  Bruno Haible  <bruno@clisp.org>
118305         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Remove unused variable
118306         from test code.
118308 2008-12-22  Eric Blake  <ebb9@byu.net>
118310         Avoid gcc warnings on cygwin.
118311         * lib/regex_internal.c (re_string_reconstruct) [!RE_ENABLE_I18N]:
118312         Avoid unused variable.
118313         * lib/regexec.c (check_arrival_add_next_nodes) [!RE_ENABLE_I18N]:
118314         Likewise.
118316 2008-12-22  Bruno Haible  <bruno@clisp.org>
118318         Remove HAVE_MBRTOWC conditionals.
118319         * lib/mbscasecmp.c: Include mbuiter.h unconditionally.
118320         (mbscasecmp): Assume mbrtowc function.
118321         * lib/mbscasestr.c: Include mbuiter.h unconditionally.
118322         (knuth_morris_pratt_multibyte, mbscasestr): Assume mbrtowc function.
118323         * lib/mbschr.c: Include mbuiter.h unconditionally.
118324         (mbschr): Assume mbrtowc function.
118325         * lib/mbscspn.c: Include mbuiter.h unconditionally.
118326         (mbscspn): Assume mbrtowc function.
118327         * lib/mbslen.c: Include mbuiter.h unconditionally.
118328         (mbslen): Assume mbrtowc function.
118329         * lib/mbsncasecmp.c: Include mbuiter.h unconditionally.
118330         (mbsncasecmp): Assume mbrtowc function.
118331         * lib/mbsnlen.c: Include mbiter.h unconditionally.
118332         (mbsnlen): Assume mbrtowc function.
118333         * lib/mbspbrk.c: Include mbuiter.h unconditionally.
118334         (mbspbrk): Assume mbrtowc function.
118335         * lib/mbspcasecmp.c: Include mbuiter.h unconditionally.
118336         (mbspcasecmp): Assume mbrtowc function.
118337         * lib/mbsrchr.c: Include mbuiter.h unconditionally.
118338         (mbsrchr): Assume mbrtowc function.
118339         * lib/mbssep.c: Include mbuiter.h unconditionally.
118340         (mbssep): Assume mbrtowc function.
118341         * lib/mbsspn.c: Include mbuiter.h unconditionally.
118342         (mbsspn): Assume mbrtowc function.
118343         * lib/mbsstr.c: Include mbuiter.h unconditionally.
118344         (knuth_morris_pratt_multibyte, mbsstr): Assume mbrtowc function.
118345         * lib/mbstok_r.c: Include mbuiter.h unconditionally.
118346         (mbstok_r): Assume mbrtowc function.
118347         * lib/propername.c: Include mbuiter.h unconditionally.
118348         (mbsstr_trimmed_wordbounded): Assume mbrtowc function.
118349         * lib/trim.c: Include mbchar.h, mbiter.h unconditionally.
118350         (trim2): Assume mbrtowc function.
118351         * lib/mbswidth.c (mbsinit): Remove fallback definition.
118352         (mbsnwidth): Assume mbrtowc function.
118353         * modules/mbswidth (Depends-on): Add mbrtowc, mbsinit.
118354         * lib/quotearg.c (MB_CUR_MAX, mbstate_t, mbrtowc, iswprint): Remove
118355         fallback definitions.
118356         * modules/quotearg (Depends-on): Add mbrtowc, mbsinit.
118358 2008-12-22  Bruno Haible  <bruno@clisp.org>
118360         * doc/posix-functions/mbtowc.texi: Mention a glibc bug.
118362 2008-12-22  Paolo Bonzini  <bonzini@gnu.org>
118364         * modules/regex: Request emulations for the mb*/wc* functions we need.
118365         * m4/regex.m4: Don't look for those functions here.
118366         * lib/regex_internal.h: Do not check HAVE_WCRTOMB and HAVE_MBRTOWC.
118368 2008-12-22  Bruno Haible  <bruno@clisp.org>
118370         * modules/fnmatch (Depends-on): Remove duplicated dependency.
118372 2008-12-21  Bruno Haible  <bruno@clisp.org>
118374         Make mbiter.h, mbuiter.h, mbfile.h usable unconditionally.
118375         * modules/mbiter (Depends-on): Add mbrtowc, mbsinit.
118376         (Include): Remove conditionalization.
118377         * modules/mbuiter (Depends-on): Add mbrtowc, mbsinit.
118378         (Include): Remove conditionalization.
118379         * modules/mbfile (Depends-on): Add mbrtowc, mbsinit.
118380         (Include): Remove conditionalization.
118381         * m4/mbiter.m4 (gl_MBITER): Deprecate the use of AC_FUNC_MBRTOWC.
118382         * m4/mbfile.m4 (gl_MBFILE): Likewise.
118383         * NEWS: Mention the change.
118384         Reported by Alan Hourihane <alanh@fairlite.co.uk>
118385         via Sergey Poznyakoff <gray@gnu.org.ua>.
118387 2008-12-21  Bruno Haible  <bruno@clisp.org>
118389         * MODULES.html.sh (Extended multibyte and wide character utilities
118390         <wchar.h>): Add btowc, wctob, mbsinit, mbrlen, mbrtowc, mbsrtowcs,
118391         wcrtomb, wcsrtombs.
118392         (Support for systems lacking POSIX:2008): Add accept, bind, close,
118393         connect, fclose, getpeername, getsockname, getsockopt, hostent, listen,
118394         mbsnrtowcs, posix_spawn*, recv, recvfrom, sched, select, send, sendto,
118395         setsockopt, shutdown, socket, spawn, sys_wait, wcsnrtombs, write.
118397 2008-12-21  Bruno Haible  <bruno@clisp.org>
118399         * MODULES.html.sh: Change section titles to refer to POSIX:2008.
118401 2008-12-21  Bruno Haible  <bruno@clisp.org>
118403         * modules/wcsnrtombs-tests: New file.
118404         * tests/test-wcsnrtombs1.sh: New file.
118405         * tests/test-wcsnrtombs2.sh: New file.
118406         * tests/test-wcsnrtombs3.sh: New file.
118407         * tests/test-wcsnrtombs4.sh: New file.
118408         * tests/test-wcsnrtombs.c: New file.
118410         New module 'wcsnrtombs'.
118411         * lib/wchar.in.h (wcsnrtombs): New declaration.
118412         * lib/wcsnrtombs.c: New file.
118413         * lib/wcsrtombs-state.c: New file.
118414         * lib/wcsrtombs.c: Refer to _gl_wcsrtombs_state.
118415         (internal_state): Remove variable.
118416         * m4/wcsnrtombs.m4: New file.
118417         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): Add wcsrtombs-state.c to the
118418         compilation units.
118419         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNRTOMBS,
118420         HAVE_WCSNRTOMBS.
118421         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNRTOMBS,
118422         HAVE_WCSNRTOMBS.
118423         * modules/wcsnrtombs: New file.
118424         * modules/wcsrtombs (Files): Add lib/wcsrtombs-state.c.
118425         * doc/posix-functions/wcsnrtombs.texi: Mention the new module.
118427 2008-12-21  Bruno Haible  <bruno@clisp.org>
118429         * modules/wcsrtombs-tests: New file.
118430         * tests/test-wcsrtombs1.sh: New file.
118431         * tests/test-wcsrtombs2.sh: New file.
118432         * tests/test-wcsrtombs3.sh: New file.
118433         * tests/test-wcsrtombs4.sh: New file.
118434         * tests/test-wcsrtombs.c: New file.
118436         New module 'wcsrtombs'.
118437         * lib/wchar.in.h (wcsrtombs): New declaration.
118438         * lib/wcsrtombs.c: New file.
118439         * m4/wcsrtombs.m4: New file.
118440         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSRTOMBS,
118441         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
118442         * modules/wchar (Makefile.am): Substitute GNULIB_WCSRTOMBS,
118443         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
118444         * modules/wcsrtombs: New file.
118445         * doc/posix-functions/wcsrtombs.texi: Mention the new module and the
118446         bugs.
118448 2008-12-21  Bruno Haible  <bruno@clisp.org>
118450         Work around a wcrtomb() bug on Solaris 10 and OSF/1 5.1.
118451         * lib/wchar.in.h (wcrtomb): Override if REPLACE_WCRTOMB is set.
118452         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Test the return value of wcrtomb
118453         with NULL destination argument in various locales. Set REPLACE_WCRTOMB
118454         if not correct.
118455         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCRTOMB.
118456         * modules/wchar (Makefile.am): Substitute REPLACE_WCRTOMB.
118457         * modules/wcrtomb (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
118458         m4/locale-zh.m4, m4/codeset.m4.
118459         * doc/posix-functions/wcrtomb.texi: Document the bug.
118461 2008-12-21  Bruno Haible  <bruno@clisp.org>
118463         Work around a btowc() bug on IRIX 6.5.
118464         * lib/wchar.in.h (btowc): Override if REPLACE_BTOWC is set.
118465         * m4/btowc.m4 (gl_FUNC_BTOWC): Test whether btowc(EOF) is correct. Set
118466         REPLACE_WTOBC if not.
118467         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_BTOWC.
118468         * modules/wchar (Makefile.am): Substitute REPLACE_BTOWC.
118469         * doc/posix-functions/btowc.texi: Mention the IRIX bug.
118471 2008-12-21  Bruno Haible  <bruno@clisp.org>
118473         * modules/wcrtomb-tests: New file.
118474         * tests/test-wcrtomb.sh: New file.
118475         * tests/test-wcrtomb.c: New file.
118477         New module 'wcrtomb'.
118478         * lib/wchar.in.h (wcrtomb): New declaration.
118479         * lib/wcrtomb.c: New file.
118480         * m4/wcrtomb.m4: New file.
118481         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCRTOMB,
118482         HAVE_WCRTOMB.
118483         * modules/wchar (Makefile.am): Substitute GNULIB_WCRTOMB,
118484         HAVE_WCRTOMB.
118485         * modules/wcrtomb: New file.
118486         * doc/posix-functions/wcrtomb.texi: Mention the new module.
118488 2008-12-21  Bruno Haible  <bruno@clisp.org>
118490         * modules/mbrtowc (Files): Add m4/codeset.m4, needed by m4/locale-fr.m4.
118491         * modules/mbsrtowcs (Files): Likewise.
118492         * modules/wctob (Files): Likewise.
118493         * modules/c-strcase-tests (Files): Likewise.
118494         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
118495         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
118496         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
118497         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
118498         * modules/vasnprintf-posix-tests (Files): Likewise.
118500 2008-12-21  William Pursell  <bill.pursell@gmail.com>
118502         gitlog-to-changelog: pass all command-line arguments to git-log
118503         * build-aux/gitlog-to-changelog: When producing a ChangeLog,
118504         it is sometimes convenient to filter the commits in various ways.
118505         gitlog-to-changelog only allows --since to specify a start date,
118506         but git-log itself supports many other filtering mechanisms.
118507         At the moment, I want to filter by branch name.  Rather than
118508         adding a --branch option to gitlog-to-changelog, it seems more
118509         flexible to simply pass all options directly to git-log and let
118510         git do the work.  Notice that this effectively makes --since a
118511         redundant option for gitlog-to-changelog, but removing it would
118512         require current usage to change since calls would then require
118513         an additional '--'.
118515 2008-12-21  Bruno Haible  <bruno@clisp.org>
118517         * modules/mbsnrtowcs-tests: New file.
118518         * tests/test-mbsnrtowcs1.sh: New file.
118519         * tests/test-mbsnrtowcs2.sh: New file.
118520         * tests/test-mbsnrtowcs3.sh: New file.
118521         * tests/test-mbsnrtowcs4.sh: New file.
118522         * tests/test-mbsnrtowcs.c: New file.
118524         New module 'mbsnrtowcs'.
118525         * lib/wchar.in.h (mbsnrtowcs): New declaration.
118526         * lib/mbsnrtowcs.c: New file.
118527         * lib/mbsrtowcs-state.c: New file.
118528         * lib/mbsrtowcs.c: Refer to _gl_mbsrtowcs_state.
118529         (internal_state): Remove variable.
118530         * m4/mbsnrtowcs.m4: New file.
118531         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Add mbsrtowcs-state.c to the
118532         compilation units.
118533         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSNRTOWCS,
118534         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
118535         * modules/wchar (Makefile.am): Substitute GNULIB_MBSNRTOWCS,
118536         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
118537         * modules/mbsnrtowcs: New file.
118538         * modules/mbsrtowcs (Files): Add lib/mbsrtowcs-state.c.
118539         * doc/posix-functions/mbsnrtowcs.texi: Mention the new module and a
118540         portability problem.
118542 2008-12-21  Bruno Haible  <bruno@clisp.org>
118544         Work around mbsrtowcs bug.
118545         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): New macro.
118546         (gl_FUNC_MBSRTOWCS): Invoke it.
118547         * modules/mbsrtowcs (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
118548         m4/locale-zh.m4.
118549         * doc/posix-functions/mbsrtowcs.texi: Document the bug.
118551 2008-12-21  Bruno Haible  <bruno@clisp.org>
118553         * tests/test-mbsrtowcs.c (main): Execute the loop also for unlimited=1.
118555 2008-12-21  Bruno Haible  <bruno@clisp.org>
118557         Update doc for AIX.
118558         * doc/pastposix-functions/wcswcs.texi: Mention that AIX has only a
118559         16-bit wchar_t type.
118560         * doc/posix-functions/btowc.texi: Likewise.
118561         * doc/posix-functions/fgetwc.texi: Likewise.
118562         * doc/posix-functions/fgetws.texi: Likewise.
118563         * doc/posix-functions/fputwc.texi: Likewise.
118564         * doc/posix-functions/fputws.texi: Likewise.
118565         * doc/posix-functions/fwide.texi: Likewise.
118566         * doc/posix-functions/fwprintf.texi: Likewise.
118567         * doc/posix-functions/fwscanf.texi: Likewise.
118568         * doc/posix-functions/getwchar.texi: Likewise.
118569         * doc/posix-functions/getwc.texi: Likewise.
118570         * doc/posix-functions/iswalnum.texi: Likewise.
118571         * doc/posix-functions/iswalpha.texi: Likewise.
118572         * doc/posix-functions/iswblank.texi: Likewise.
118573         * doc/posix-functions/iswcntrl.texi: Likewise.
118574         * doc/posix-functions/iswctype.texi: Likewise.
118575         * doc/posix-functions/iswdigit.texi: Likewise.
118576         * doc/posix-functions/iswgraph.texi: Likewise.
118577         * doc/posix-functions/iswlower.texi: Likewise.
118578         * doc/posix-functions/iswprint.texi: Likewise.
118579         * doc/posix-functions/iswpunct.texi: Likewise.
118580         * doc/posix-functions/iswspace.texi: Likewise.
118581         * doc/posix-functions/iswupper.texi: Likewise.
118582         * doc/posix-functions/iswxdigit.texi: Likewise.
118583         * doc/posix-functions/mbrtowc.texi: Likewise.
118584         * doc/posix-functions/mbsrtowcs.texi: Likewise.
118585         * doc/posix-functions/mbstowcs.texi: Likewise.
118586         * doc/posix-functions/mbtowc.texi: Likewise.
118587         * doc/posix-functions/putwchar.texi: Likewise.
118588         * doc/posix-functions/putwc.texi: Likewise.
118589         * doc/posix-functions/swprintf.texi: Likewise.
118590         * doc/posix-functions/tolower.texi: Likewise.
118591         * doc/posix-functions/toupper.texi: Likewise.
118592         * doc/posix-functions/towctrans.texi: Likewise.
118593         * doc/posix-functions/ungetwc.texi: Likewise.
118594         * doc/posix-functions/vswprintf.texi: Likewise.
118595         * doc/posix-functions/wcrtomb.texi: Likewise.
118596         * doc/posix-functions/wcscat.texi: Likewise.
118597         * doc/posix-functions/wcschr.texi: Likewise.
118598         * doc/posix-functions/wcscmp.texi: Likewise.
118599         * doc/posix-functions/wcscoll.texi: Likewise.
118600         * doc/posix-functions/wcscpy.texi: Likewise.
118601         * doc/posix-functions/wcscspn.texi: Likewise.
118602         * doc/posix-functions/wcsftime.texi: Likewise.
118603         * doc/posix-functions/wcslen.texi: Likewise.
118604         * doc/posix-functions/wcsncat.texi: Likewise.
118605         * doc/posix-functions/wcsncmp.texi: Likewise.
118606         * doc/posix-functions/wcsncpy.texi: Likewise.
118607         * doc/posix-functions/wcspbrk.texi: Likewise.
118608         * doc/posix-functions/wcsrchr.texi: Likewise.
118609         * doc/posix-functions/wcsrtombs.texi: Likewise.
118610         * doc/posix-functions/wcsspn.texi: Likewise.
118611         * doc/posix-functions/wcsstr.texi: Likewise.
118612         * doc/posix-functions/wcstod.texi: Likewise.
118613         * doc/posix-functions/wcstof.texi: Likewise.
118614         * doc/posix-functions/wcstoimax.texi: Likewise.
118615         * doc/posix-functions/wcstok.texi: Likewise.
118616         * doc/posix-functions/wcstold.texi: Likewise.
118617         * doc/posix-functions/wcstoll.texi: Likewise.
118618         * doc/posix-functions/wcstol.texi: Likewise.
118619         * doc/posix-functions/wcstombs.texi: Likewise.
118620         * doc/posix-functions/wcstoull.texi: Likewise.
118621         * doc/posix-functions/wcstoul.texi: Likewise.
118622         * doc/posix-functions/wcstoumax.texi: Likewise.
118623         * doc/posix-functions/wcswidth.texi: Likewise.
118624         * doc/posix-functions/wcsxfrm.texi: Likewise.
118625         * doc/posix-functions/wctob.texi: Likewise.
118626         * doc/posix-functions/wctomb.texi: Likewise.
118627         * doc/posix-functions/wctrans.texi: Likewise.
118628         * doc/posix-functions/wctype.texi: Likewise.
118629         * doc/posix-functions/wcwidth.texi: Likewise.
118630         * doc/posix-functions/wmemchr.texi: Likewise.
118631         * doc/posix-functions/wmemcmp.texi: Likewise.
118632         * doc/posix-functions/wmemcpy.texi: Likewise.
118633         * doc/posix-functions/wmemmove.texi: Likewise.
118634         * doc/posix-functions/wmemset.texi: Likewise.
118635         * doc/posix-functions/wprintf.texi: Likewise.
118636         * doc/posix-functions/wscanf.texi: Likewise.
118638 2008-12-21  Bruno Haible  <bruno@clisp.org>
118640         Update doc for HP-UX 11.11.
118641         * doc/posix-functions/btowc.texi: Clarify that the function is missing
118642         in HP-UX version 11.00, not in all versions of HP-UX 11.
118643         * doc/posix-functions/fwide.texi: Likewise.
118644         * doc/posix-functions/fwprintf.texi: Likewise.
118645         * doc/posix-functions/fwscanf.texi: Likewise.
118646         * doc/posix-functions/inet_ntop.texi: Likewise.
118647         * doc/posix-functions/inet_pton.texi: Likewise.
118648         * doc/posix-functions/mbrlen.texi: Likewise.
118649         * doc/posix-functions/mbrtowc.texi: Likewise.
118650         * doc/posix-functions/mbsinit.texi: Likewise.
118651         * doc/posix-functions/mbsrtowcs.texi: Likewise.
118652         * doc/posix-functions/swprintf.texi: Likewise.
118653         * doc/posix-functions/swscanf.texi: Likewise.
118654         * doc/posix-functions/towctrans.texi: Likewise.
118655         * doc/posix-functions/vfwprintf.texi: Likewise.
118656         * doc/posix-functions/vswprintf.texi: Likewise.
118657         * doc/posix-functions/vwprintf.texi: Likewise.
118658         * doc/posix-functions/wcrtomb.texi: Likewise.
118659         * doc/posix-functions/wcsrtombs.texi: Likewise.
118660         * doc/posix-functions/wcsstr.texi: Likewise.
118661         * doc/posix-functions/wctob.texi: Likewise.
118662         * doc/posix-functions/wctrans.texi: Likewise.
118663         * doc/posix-functions/wmemchr.texi: Likewise.
118664         * doc/posix-functions/wmemcmp.texi: Likewise.
118665         * doc/posix-functions/wmemcpy.texi: Likewise.
118666         * doc/posix-functions/wmemmove.texi: Likewise.
118667         * doc/posix-functions/wmemset.texi: Likewise.
118668         * doc/posix-functions/wprintf.texi: Likewise.
118669         * doc/posix-functions/wscanf.texi: Likewise.
118671 2008-12-21  Bruno Haible  <bruno@clisp.org>
118673         Work around a portability problem.
118674         * tests/test-mbsrtowcs.c (main): Use a temporary conversion state.
118675         * doc/posix-functions/mbsrtowcs.texi: Document the portability problem.
118677 2008-12-20  Bruno Haible  <bruno@clisp.org>
118679         * lib/wchar.in.h (mbsrtowcs): Redefine if REPLACE_MBSRTOWCS is set.
118680         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Invoke gl_MBSTATE_T_BROKEN. Set
118681         REPLACE_MBSRTOWCS if mbsrtowcs needs to be overridden.
118682         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSRTOWCS.
118683         * modules/wchar (Makefile.am): Substitute REPLACE_MBSRTOWCS.
118685         Work around mbrtowc bugs on AIX, HP-UX, OSF/1, Solaris.
118686         * lib/wchar.in.h (mbstate_t): Redefine also if REPLACE_MBSTATE_T is
118687         set.
118688         (GNULIB_defined_mbstate_t): New macro.
118689         (mbsinit): Redefine if REPLACE_MBSINIT is set.
118690         (mbrtowc): Redefine if REPLACE_MBRTOWC is set.
118691         * lib/mbrtowc.c (rpl_mbrtowc): Add an alternative implementation that
118692         reuses the system's mbrtowc function but works around the bugs.
118693         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN, gl_MBRTOWC_INCOMPLETE_STATE,
118694         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL): New
118695         macros.
118696         (gl_FUNC_MBRTOWC): Invoke them. Set REPLACE_MBRTOWC if mbrtowc needs to
118697         be overridden. Optionally define MBRTOWC_NULL_ARG_BUG,
118698         MBRTOWC_RETVAL_BUG, MBRTOWC_NUL_RETVAL_BUG.
118699         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_MBSTATE_T_BROKEN. Set
118700         REPLACE_MBSINIT if mbsinit needs to be overridden.
118701         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSTATE_T,
118702         REPLACE_MBSINIT, REPLACE_MBRTOWC.
118703         * modules/wchar (Makefile.am): Substitute REPLACE_MBSTATE_T,
118704         REPLACE_MBSINIT, REPLACE_MBRTOWC.
118705         * modules/mbrtowc (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
118706         m4/locale-zh.m4.
118707         (Depends): Add mbsinit.
118708         * modules/mbsinit (Depends): Add mbrtowc.
118709         * doc/posix-functions/mbrtowc.texi: Mention the various bugs.
118711 2008-12-20  Bruno Haible  <bruno@clisp.org>
118713         * tests/test-mbrtowc.c (main): Change sample string in EUC-JP encoding
118714         so that there are no conversion errors on AIX.
118715         * tests/test-mbsrtowcs.c (main): LIkewise.
118717 2008-12-20  Bruno Haible  <bruno@clisp.org>
118719         Work around wctob bug on Solaris <= 9.
118720         * lib/wchar.in.h (wctob): Redefine if REPLACE_WCTOB is set.
118721         * m4/wctob.m4 (gl_FUNC_WCTOB): Test whether wctob works.
118722         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCTOB.
118723         * modules/wchar (Makefile.am): Substitute REPLACE_WCTOB.
118724         * modules/wctob (Files): Add m4/locale-fr.m4.
118725         * doc/posix-functions/wctob.texi: Mention the Solaris bug.
118727 2008-12-20  Bruno Haible  <bruno@clisp.org>
118729         * doc/posix-functions/select.texi: Mention Solaris 2.6 bug with
118730         /dev/null.
118731         * tests/test-select-in.sh: Likewise.
118732         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
118734 2008-12-20  Bruno Haible  <bruno@clisp.org>
118736         Don't pretend that Cygwin has a ja_JP.EUC-JP locale.
118737         * m4/locale-ja.m4 (gt_LOCALE_JA): Add test for MB_CUR_MAX. Needed on
118738         Cygwin 1.5.x.
118740 2008-12-20  Bruno Haible  <bruno@clisp.org>
118742         Ensure mbstate_t is defined on HP-UX 11.11.
118743         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Require
118744         AC_CANONICAL_HOST. On HP-UX, define _XOPEN_SOURCE to 500.
118745         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Require
118746         AC_USE_SYSTEM_EXTENSIONS.
118747         * modules/fnmatch (Depends-on): Add extensions.
118748         * modules/mbrlen (Depends-on): Likewise.
118749         * modules/mbrtowc (Depends-on): Likewise.
118750         * modules/mbsinit (Depends-on): Likewise.
118751         * modules/mbsrtowcs (Depends-on): Likewise.
118752         * modules/mbswidth (Depends-on): Likewise.
118753         * modules/quotearg (Depends-on): Likewise.
118754         * modules/strftime (Depends-on): Likewise.
118756 2008-12-20  Bruno Haible  <bruno@clisp.org>
118758         Ensure wctob is declared on IRIX 6.5.
118759         * lib/wchar.in.h (wctob): Declare also when HAVE_DECL_WCTOB is 0.
118760         * m4/wctob.m4 (gl_FUNC_WCTOB): Set HAVE_DECL_WCTOB instead of
118761         HAVE_WCTOB. Also test whether <wchar.h> declares wctob.
118762         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize HAVE_DECL_WCTOB instead
118763         of HAVE_WCTOB.
118764         * modules/wchar (Makefile.am): Substitute HAVE_DECL_WCTOB instead of
118765         HAVE_WCTOB.
118766         * doc/posix-functions/wctob.texi: Mention missing declaration on IRIX.
118768 2008-12-19  Bruno Haible  <bruno@clisp.org>
118770         * modules/mbsrtowcs-tests: New file.
118771         * tests/test-mbsrtowcs1.sh: New file.
118772         * tests/test-mbsrtowcs2.sh: New file.
118773         * tests/test-mbsrtowcs3.sh: New file.
118774         * tests/test-mbsrtowcs4.sh: New file.
118775         * tests/test-mbsrtowcs.c: New file.
118777         New module 'mbsrtowcs'.
118778         * lib/wchar.in.h (mbsrtowcs): New declaration.
118779         * lib/mbsrtowcs.c: New file.
118780         * m4/mbsrtowcs.m4: New file.
118781         * modules/mbsrtowcs: New file.
118782         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSRTOWCS and
118783         HAVE_MBSRTOWCS.
118784         * modules/wchar (Makefile.am): Substitute GNULIB_MBSRTOWCS and
118785         HAVE_MBSRTOWCS.
118786         * doc/posix-functions/mbsrtowcs.texi: Document the new module.
118788 2008-12-19  Bruno Haible  <bruno@clisp.org>
118790         New module 'mbrlen'.
118791         * lib/wchar.in.h (mbrlen): New declaration.
118792         * lib/mbrlen.c: New file.
118793         * m4/mbrlen.m4: New file.
118794         * modules/mbrlen: New file.
118795         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRLEN and
118796         HAVE_MBRLEN.
118797         * modules/wchar (Makefile.am): Substitute GNULIB_MBRLEN and
118798         HAVE_MBRLEN.
118799         * doc/posix-functions/mbrlen.texi: Document the new module.
118801 2008-12-19  Bruno Haible  <bruno@clisp.org>
118803         * lib/mbrtowc.c: Include verify.h. Verify an assumption.
118804         * modules/mbrtowc (Depends-on): Add verify.
118805         Suggested by Paul Eggert.
118807 2008-12-18  Bruno Haible  <bruno@clisp.org>
118809         * modules/mbsinit-tests: New file.
118810         * tests/test-mbsinit.sh: New file.
118811         * tests/test-mbsinit.c: New file.
118813 2008-12-18  Bruno Haible  <bruno@clisp.org>
118815         * modules/mbrtowc-tests: New file.
118816         * tests/test-mbrtowc1.sh: New file.
118817         * tests/test-mbrtowc2.sh: New file.
118818         * tests/test-mbrtowc3.sh: New file.
118819         * tests/test-mbrtowc4.sh: New file.
118820         * tests/test-mbrtowc.c: New file.
118822         New module 'mbrtowc'.
118823         * lib/wchar.in.h (mbstate_t): Override when the system does not have
118824         mbsinit and mbrtowc.
118825         (mbrtowc): New declaration.
118826         * lib/mbrtowc.c: New file.
118827         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC, gl_PREREQ_MBRTOWC): New macros.
118828         * modules/mbrtowc: New file.
118829         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRTOWC and
118830         HAVE_MBRTOWC.
118831         * modules/wchar (Makefile.am): Substitute GNULIB_MBRTOWC and
118832         HAVE_MBRTOWC.
118833         * doc/posix-functions/mbrtowc.texi: Document the new module.
118835 2008-12-18  Bruno Haible  <bruno@clisp.org>
118837         New module 'wctob'.
118838         * lib/wchar.in.h (wctob): New declaration.
118839         * lib/wctob.c: New file.
118840         * m4/wctob.m4: New file.
118841         * modules/wctob: New file.
118842         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCTOB and
118843         HAVE_WCTOB.
118844         * modules/wchar (Makefile.am): Substitute GNULIB_WCTOB and HAVE_WCTOB.
118845         * doc/posix-functions/wctob.texi: Document the new module.
118847 2008-12-18  Bruno Haible  <bruno@clisp.org>
118849         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_REPLACE_WCHAR_H.
118850         * m4/btowc.m4 (gl_FUNC_BTOWC): Likewise.
118852 2008-12-18  Simon Josefsson  <simon@josefsson.org>
118854         * lib/flock.c: Use proper #if symbol in check.  Reported by "Tom
118855         G. Christensen" <tgc@jupiterrise.com>.
118857         * lib/flock.c: Need to include errno.h.  Reported by "Tom
118858         G. Christensen" <tgc@jupiterrise.com>.
118860         * lib/flock.c: Need to include string.h.  Reported by "Tom
118861         G. Christensen" <tgc@jupiterrise.com> and Eric Blake
118862         <ebb9@byu.net>.
118864 2008-12-18  Bruno Haible  <bruno@clisp.org>
118866         * m4/locale-ja.m4: New file, from GNU gettext.
118868 2008-12-17  Bruno Haible  <bruno@clisp.org>
118870         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Don't override in autoconf >= 2.60.
118871         Suggested by Eric Blake.
118873 2008-12-17  Bruno Haible  <bruno@clisp.org>
118875         * m4/errno_h.m4 (AC_COMPUTE_INT): Provide fallback definition.
118877 2008-12-17  Bruno Haible  <bruno@clisp.org>
118879         * lib/mbsinit.c: Include verify.h. Verify an assumption.
118880         * modules/mbsinit (Depends-on): Add verify.
118881         Suggested by Paul Eggert.
118883 2008-12-17  Bruno Haible  <bruno@clisp.org>
118885         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Renamed from gl_FUNC_MBRTOWC.
118886         * m4/mbfile.m4 (gl_MBFILE): Use AC_FUNC_MBRTOWC instead of
118887         gl_FUNC_MBRTOWC.
118888         * m4/mbiter.m4 (gl_MBITER): LIkewise.
118889         * m4/mbscasecmp.m4 (gl_PREREQ_MBSCASECMP): Likewise.
118890         * m4/mbscasestr.m4 (gl_PREREQ_MBSCASESTR): Likewise.
118891         * m4/mbschr.m4 (gl_PREREQ_MBSCHR): Likewise.
118892         * m4/mbscspn.m4 (gl_PREREQ_MBSCSPN): Likewise.
118893         * m4/mbslen.m4 (gl_PREREQ_MBSLEN): Likewise.
118894         * m4/mbsncasecmp.m4 (gl_PREREQ_MBSNCASECMP): Likewise.
118895         * m4/mbsnlen.m4 (gl_PREREQ_MBSNLEN): Likewise.
118896         * m4/mbspbrk.m4 (gl_PREREQ_MBSPBRK): Likewise.
118897         * m4/mbspcasecmp.m4 (gl_PREREQ_MBSPCASECMP): Likewise.
118898         * m4/mbsrchr.m4 (gl_PREREQ_MBSRCHR): Likewise.
118899         * m4/mbssep.m4 (gl_PREREQ_MBSSEP): Likewise.
118900         * m4/mbsspn.m4 (gl_PREREQ_MBSSPN): Likewise.
118901         * m4/mbsstr.m4 (gl_PREREQ_MBSSTR): Likewise.
118902         * m4/mbstok_r.m4 (gl_PREREQ_MBSTOK_R): Likewise.
118903         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
118904         * m4/quotearg.m4 (gl_QUOTEARG): Likewise.
118905         * modules/trim (configure.ac): Likewise.
118907 2008-12-17  Bruno Haible  <bruno@clisp.org>
118909         * modules/btowc-tests: New file.
118910         * tests/test-btowc1.sh: New file.
118911         * tests/test-btowc2.sh: New file.
118912         * tests/test-btowc.c: New file.
118914         New module 'btowc'.
118915         * lib/wchar.in.h (btowc): New declaration.
118916         * lib/btowc.c: New file.
118917         * m4/btowc.m4: New file.
118918         * modules/btowc: New file.
118919         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_BTOWC and
118920         HAVE_BTOWC.
118921         * modules/wchar (Makefile.am): Substitute GNULIB_BTOWC and HAVE_BTOWC.
118922         * doc/posix-functions/btowc.texi: Document the new module.
118924 2008-12-17  Bruno Haible  <bruno@clisp.org>
118926         New module 'mbsinit'.
118927         * lib/wchar.in.h (mbsinit): New declaration.
118928         * lib/mbsinit.c: New file.
118929         * m4/mbsinit.m4: New file.
118930         * modules/mbsinit: New file.
118931         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSINIT and
118932         HAVE_MBSINIT.
118933         * modules/wchar (Makefile.am): Substitute GNULIB_MBSINIT and
118934         HAVE_MBSINIT.
118935         * doc/posix-functions/mbsinit.texi: Document the new module.
118937 2008-12-16  Bruno Haible  <bruno@clisp.org>
118939         * lib/unistd.in.h: Add comment.
118940         * tests/test-environ.c: Don't include <stdlib.h>.
118942 2008-12-16  Bruno Haible  <bruno@clisp.org>
118944         * lib/parse-duration.h (parse_duration): Document return value
118945         convention.
118946         * lib/parse-duration.c: Include specification header first. Add
118947         comments.
118948         (_): Remove macro.
118949         (parse_year_month_day, parse_hour_minute_second): Move side effects
118950         outside of strchr call.
118951         (parse_non_iso8601): Move side effects outside of isspace call.
118952         (parse_duration): Don't test errno is res != BAD_TIME. Remove fprintf
118953         call.
118955 2008-12-16  Bruno Haible  <bruno@clisp.org>
118957         * tests/test-parse-duration.sh: Produce no output when the test
118958         succeeds.
118960 2008-12-16  Bruno Haible  <bruno@clisp.org>
118962         * tests/test-parse-duration.sh: Fix quoting of $tmp and $tmpf
118963         expressions.
118965 2008-12-15  Bruno Haible  <bruno@clisp.org>
118967         * doc/glibc-functions/fgetxattr.texi: Tweak wording.
118968         * doc/glibc-functions/flistxattr.texi: Likewise.
118969         * doc/glibc-functions/fopencookie.texi: Likewise.
118970         * doc/glibc-functions/fremovexattr.texi: Likewise.
118971         * doc/glibc-functions/fsetxattr.texi: Likewise.
118972         * doc/glibc-functions/getxattr.texi: Likewise.
118973         * doc/glibc-functions/lgetxattr.texi: Likewise.
118974         * doc/glibc-functions/listxattr.texi: Likewise.
118975         * doc/glibc-functions/llistxattr.texi: Likewise.
118976         * doc/glibc-functions/lremovexattr.texi: Likewise.
118977         * doc/glibc-functions/lsetxattr.texi: Likewise.
118978         * doc/glibc-functions/removexattr.texi: Likewise.
118979         * doc/glibc-functions/setxattr.texi: Likewise.
118980         * doc/posix-functions/open_memstream.texi: Likewise.
118982 2008-12-15  Eric Blake  <ebb9@byu.net>
118984         Update doc for cygwin 1.7.
118985         * doc/posix-functions/faccessat.texi: Cygwin 1.7 added several new
118986         functions.
118987         * doc/posix-functions/fchmodat.texi: Likewise.
118988         * doc/posix-functions/fchownat.texi: Likewise.
118989         * doc/posix-functions/fdopendir.texi: Likewise.
118990         * doc/posix-functions/fmemopen.texi: Likewise.
118991         * doc/posix-functions/freeaddrinfo.texi: Likewise.
118992         * doc/posix-functions/fstatat.texi: Likewise.
118993         * doc/posix-functions/futimens.texi: Likewise.
118994         * doc/posix-functions/gai_strerror.texi: Likewise.
118995         * doc/posix-functions/getaddrinfo.texi: Likewise.
118996         * doc/posix-functions/getnameinfo.texi: Likewise.
118997         * doc/posix-functions/if_freenameindex.texi: Likewise.
118998         * doc/posix-functions/if_indextoname.texi: Likewise.
118999         * doc/posix-functions/if_nameindex.texi: Likewise.
119000         * doc/posix-functions/if_nametoindex.texi: Likewise.
119001         * doc/posix-functions/insque.texi: Likewise.
119002         * doc/posix-functions/linkat.texi: Likewise.
119003         * doc/posix-functions/llrint.texi: Likewise.
119004         * doc/posix-functions/llrintf.texi: Likewise.
119005         * doc/posix-functions/llrintl.texi: Likewise.
119006         * doc/posix-functions/lockf.texi: Likewise.
119007         * doc/posix-functions/lrintl.texi: Likewise.
119008         * doc/posix-functions/mkdirat.texi: Likewise.
119009         * doc/posix-functions/mkfifoat.texi: Likewise.
119010         * doc/posix-functions/mknodat.texi: Likewise.
119011         * doc/posix-functions/mq_close.texi: Likewise.
119012         * doc/posix-functions/mq_getattr.texi: Likewise.
119013         * doc/posix-functions/mq_notify.texi: Likewise.
119014         * doc/posix-functions/mq_open.texi: Likewise.
119015         * doc/posix-functions/mq_receive.texi: Likewise.
119016         * doc/posix-functions/mq_send.texi: Likewise.
119017         * doc/posix-functions/mq_setattr.texi: Likewise.
119018         * doc/posix-functions/mq_timedreceive.texi: Likewise.
119019         * doc/posix-functions/mq_timedsend.texi: Likewise.
119020         * doc/posix-functions/mq_unlink.texi: Likewise.
119021         * doc/posix-functions/open_memstream.texi: Likewise.
119022         * doc/posix-functions/openat.texi: Likewise.
119023         * doc/posix-functions/posix_fadvise.texi: Likewise.
119024         * doc/posix-functions/posix_fallocate.texi: Likewise.
119025         * doc/posix-functions/posix_madvise.texi: Likewise.
119026         * doc/posix-functions/posix_memalign.texi: Likewise.
119027         * doc/posix-functions/posix_openpt.texi: Likewise.
119028         * doc/posix-functions/readlinkat.texi: Likewise.
119029         * doc/posix-functions/remque.texi: Likewise.
119030         * doc/posix-functions/renameat.texi: Likewise.
119031         * doc/posix-functions/rintl.texi: Likewise.
119032         * doc/posix-functions/sem_unlink.texi: Likewise.
119033         * doc/posix-functions/shm_open.texi: Likewise.
119034         * doc/posix-functions/shm_unlink.texi: Likewise.
119035         * doc/posix-functions/signgam.texi: Likewise.
119036         * doc/posix-functions/sigset.texi: Likewise.
119037         * doc/posix-functions/stpcpy.texi: Likewise.
119038         * doc/posix-functions/stpncpy.texi: Likewise.
119039         * doc/posix-functions/strerror.texi: Likewise.
119040         * doc/posix-functions/strtod.texi: Likewise.
119041         * doc/posix-functions/symlinkat.texi: Likewise.
119042         * doc/posix-functions/unlinkat.texi: Likewise.
119043         * doc/posix-functions/utimensat.texi: Likewise.
119044         * doc/glibc-functions/bindresvport.texi: Likewise.
119045         * doc/glibc-functions/dn_expand.texi: Likewise.
119046         * doc/glibc-functions/exp10.texi: Likewise.
119047         * doc/glibc-functions/exp10f.texi: Likewise.
119048         * doc/glibc-functions/fgetxattr.texi: Likewise.
119049         * doc/glibc-functions/flistxattr.texi: Likewise.
119050         * doc/glibc-functions/fopencookie.texi: Likewise.
119051         * doc/glibc-functions/freeifaddrs.texi: Likewise.
119052         * doc/glibc-functions/fremovexattr.texi: Likewise.
119053         * doc/glibc-functions/fsetxattr.texi: Likewise.
119054         * doc/glibc-functions/getifaddrs.texi: Likewise.
119055         * doc/glibc-functions/getxattr.texi: Likewise.
119056         * doc/glibc-functions/lgetxattr.texi: Likewise.
119057         * doc/glibc-functions/listxattr.texi: Likewise.
119058         * doc/glibc-functions/llistxattr.texi: Likewise.
119059         * doc/glibc-functions/lremovexattr.texi: Likewise.
119060         * doc/glibc-functions/lsetxattr.texi: Likewise.
119061         * doc/glibc-functions/pow10.texi: Likewise.
119062         * doc/glibc-functions/pow10f.texi: Likewise.
119063         * doc/glibc-functions/rcmd_af.texi: Likewise.
119064         * doc/glibc-functions/removexattr.texi: Likewise.
119065         * doc/glibc-functions/res_init.texi: Likewise.
119066         * doc/glibc-functions/res_mkquery.texi: Likewise.
119067         * doc/glibc-functions/res_query.texi: Likewise.
119068         * doc/glibc-functions/res_querydomain.texi: Likewise.
119069         * doc/glibc-functions/res_send.texi: Likewise.
119070         * doc/glibc-functions/rresvport_af.texi: Likewise.
119071         * doc/glibc-functions/setxattr.texi: Likewise.
119072         * doc/glibc-functions/strcasestr.texi: Likewise.
119074 2008-12-15  Bruno Haible  <bruno@clisp.org>
119076         Fix compilation error on OSF/1 4.0.
119077         * lib/sys_select.in.h: When invoked from OSF/1 <sys/types.h> or
119078         <sys/time.h>, simply delegate to the system header.
119079         Reported by Daniel Richard G. <oss@teragram.com>.
119081 2008-12-15  Bruno Haible  <bruno@clisp.org>
119083         * doc/posix-functions/openat.texi: Mention the 'openat' module.
119084         * doc/posix-functions/fchmodat.texi: Likewise.
119085         * doc/posix-functions/fchownat.texi: Likewise.
119086         * doc/posix-functions/fdopendir.texi: Likewise.
119087         * doc/posix-functions/fstatat.texi: Likewise.
119088         * doc/posix-functions/mkdirat.texi: Likewise.
119089         * doc/posix-functions/unlinkat.texi: Likewise.
119091 2008-12-14  Bruno Haible  <bruno@clisp.org>
119093         Update doc for POSIX:2008.
119094         * doc/posix-functions/faccessat.texi: New file.
119095         * doc/posix-functions/fchmodat.texi: New file.
119096         * doc/posix-functions/fchownat.texi: New file.
119097         * doc/posix-functions/fdopendir.texi: New file.
119098         * doc/posix-functions/fstatat.texi: New file.
119099         * doc/posix-functions/futimens.texi: New file.
119100         * doc/posix-functions/linkat.texi: New file.
119101         * doc/posix-functions/mkdirat.texi: New file.
119102         * doc/posix-functions/mkfifoat.texi: New file.
119103         * doc/posix-functions/mknodat.texi: New file.
119104         * doc/posix-functions/open_wmemstream.texi: New file.
119105         * doc/posix-functions/openat.texi: New file.
119106         * doc/posix-functions/psiginfo.texi: New file.
119107         * doc/posix-functions/pthread_mutex_consistent.texi: New file.
119108         * doc/posix-functions/pthread_mutexattr_getrobust.texi: New file.
119109         * doc/posix-functions/pthread_mutexattr_setrobust.texi: New file.
119110         * doc/posix-functions/readlinkat.texi: New file.
119111         * doc/posix-functions/renameat.texi: New file.
119112         * doc/posix-functions/strerror_l.texi: New file.
119113         * doc/posix-functions/symlinkat.texi: New file.
119114         * doc/posix-functions/unlinkat.texi: New file.
119115         * doc/posix-functions/utimensat.texi: New file.
119116         * doc/gnulib.texi (Function Substitutes): Add these subsections.
119118 2008-12-14  Bruno Haible  <bruno@clisp.org>
119120         Update doc for POSIX:2008.
119121         * doc/posix-functions/alphasort.texi: Renamed from
119122         doc/glibc-functions/alphasort.texi.
119123         * doc/posix-functions/dirfd.texi: Renamed from
119124         doc/glibc-functions/dirfd.texi.
119125         * doc/posix-functions/dprintf.texi: Renamed from
119126         doc/glibc-functions/dprintf.texi.
119127         * doc/posix-functions/duplocale.texi: Renamed from
119128         doc/glibc-functions/duplocale.texi.
119129         * doc/posix-functions/fexecve.texi: Renamed from
119130         doc/glibc-functions/fexecve.texi.
119131         * doc/posix-functions/fmemopen.texi: Renamed from
119132         doc/glibc-functions/fmemopen.texi.
119133         * doc/posix-functions/freelocale.texi: Renamed from
119134         doc/glibc-functions/freelocale.texi.
119135         * doc/posix-functions/getdate_err.texi: Renamed from
119136         doc/glibc-functions/getdate_err.texi.
119137         * doc/posix-functions/isalnum_l.texi: Renamed from
119138         doc/glibc-functions/isalnum_l.texi.
119139         * doc/posix-functions/isalpha_l.texi: Renamed from
119140         doc/glibc-functions/isalpha_l.texi.
119141         * doc/posix-functions/isblank_l.texi: Renamed from
119142         doc/glibc-functions/isblank_l.texi.
119143         * doc/posix-functions/iscntrl_l.texi: Renamed from
119144         doc/glibc-functions/iscntrl_l.texi.
119145         * doc/posix-functions/isdigit_l.texi: Renamed from
119146         doc/glibc-functions/isdigit_l.texi.
119147         * doc/posix-functions/isgraph_l.texi: Renamed from
119148         doc/glibc-functions/isgraph_l.texi.
119149         * doc/posix-functions/islower_l.texi: Renamed from
119150         doc/glibc-functions/islower_l.texi.
119151         * doc/posix-functions/isprint_l.texi: Renamed from
119152         doc/glibc-functions/isprint_l.texi.
119153         * doc/posix-functions/ispunct_l.texi: Renamed from
119154         doc/glibc-functions/ispunct_l.texi.
119155         * doc/posix-functions/isspace_l.texi: Renamed from
119156         doc/glibc-functions/isspace_l.texi.
119157         * doc/posix-functions/isupper_l.texi: Renamed from
119158         doc/glibc-functions/isupper_l.texi.
119159         * doc/posix-functions/iswalnum_l.texi: Renamed from
119160         doc/glibc-functions/iswalnum_l.texi.
119161         * doc/posix-functions/iswalpha_l.texi: Renamed from
119162         doc/glibc-functions/iswalpha_l.texi.
119163         * doc/posix-functions/iswblank_l.texi: Renamed from
119164         doc/glibc-functions/iswblank_l.texi.
119165         * doc/posix-functions/iswcntrl_l.texi: Renamed from
119166         doc/glibc-functions/iswcntrl_l.texi.
119167         * doc/posix-functions/iswctype_l.texi: Renamed from
119168         doc/glibc-functions/iswctype_l.texi.
119169         * doc/posix-functions/iswdigit_l.texi: Renamed from
119170         doc/glibc-functions/iswdigit_l.texi.
119171         * doc/posix-functions/iswgraph_l.texi: Renamed from
119172         doc/glibc-functions/iswgraph_l.texi.
119173         * doc/posix-functions/iswlower_l.texi: Renamed from
119174         doc/glibc-functions/iswlower_l.texi.
119175         * doc/posix-functions/iswprint_l.texi: Renamed from
119176         doc/glibc-functions/iswprint_l.texi.
119177         * doc/posix-functions/iswpunct_l.texi: Renamed from
119178         doc/glibc-functions/iswpunct_l.texi.
119179         * doc/posix-functions/iswspace_l.texi: Renamed from
119180         doc/glibc-functions/iswspace_l.texi.
119181         * doc/posix-functions/iswupper_l.texi: Renamed from
119182         doc/glibc-functions/iswupper_l.texi.
119183         * doc/posix-functions/iswxdigit_l.texi: Renamed from
119184         doc/glibc-functions/iswxdigit_l.texi.
119185         * doc/posix-functions/isxdigit_l.texi: Renamed from
119186         doc/glibc-functions/isxdigit_l.texi.
119187         * doc/posix-functions/mbsnrtowcs.texi: Renamed from
119188         doc/glibc-functions/mbsnrtowcs.texi.
119189         * doc/posix-functions/mkdtemp.texi: Renamed from
119190         doc/glibc-functions/mkdtemp.texi.
119191         * doc/posix-functions/newlocale.texi: Renamed from
119192         doc/glibc-functions/newlocale.texi.
119193         * doc/posix-functions/nl_langinfo_l.texi: Renamed from
119194         doc/glibc-functions/nl_langinfo_l.texi.
119195         * doc/posix-functions/open_memstream.texi: Renamed from
119196         doc/glibc-functions/open_memstream.texi.
119197         * doc/posix-functions/opterr.texi: Renamed from
119198         doc/glibc-functions/opterr.texi.
119199         * doc/posix-functions/optind.texi: Renamed from
119200         doc/glibc-functions/optind.texi.
119201         * doc/posix-functions/optopt.texi: Renamed from
119202         doc/glibc-functions/optopt.texi.
119203         * doc/posix-functions/psignal.texi: Renamed from
119204         doc/glibc-functions/psignal.texi.
119205         * doc/posix-functions/scandir.texi: Renamed from
119206         doc/glibc-functions/scandir.texi.
119207         * doc/posix-functions/sched_get_priority_min.texi: Renamed from
119208         doc/glibc-functions/sched_get_priority_min.texi.
119209         * doc/posix-functions/signgam.texi: Renamed from
119210         doc/glibc-functions/signgam.texi.
119211         * doc/posix-functions/stpcpy.texi: Renamed from
119212         doc/glibc-functions/stpcpy.texi.
119213         * doc/posix-functions/stpncpy.texi: Renamed from
119214         doc/glibc-functions/stpncpy.texi.
119215         * doc/posix-functions/strcasecmp_l.texi: Renamed from
119216         doc/glibc-functions/strcasecmp_l.texi.
119217         * doc/posix-functions/strcoll_l.texi: Renamed from
119218         doc/glibc-functions/strcoll_l.texi.
119219         * doc/posix-functions/strfmon_l.texi: Renamed from
119220         doc/glibc-functions/strfmon_l.texi.
119221         * doc/posix-functions/strftime_l.texi: Renamed from
119222         doc/glibc-functions/strftime_l.texi.
119223         * doc/posix-functions/strncasecmp_l.texi: Renamed from
119224         doc/glibc-functions/strncasecmp_l.texi.
119225         * doc/posix-functions/strndup.texi: Renamed from
119226         doc/glibc-functions/strndup.texi.
119227         * doc/posix-functions/strnlen.texi: Renamed from
119228         doc/glibc-functions/strnlen.texi.
119229         * doc/posix-functions/strsignal.texi: Renamed from
119230         doc/glibc-functions/strsignal.texi.
119231         * doc/posix-functions/strxfrm_l.texi: Renamed from
119232         doc/glibc-functions/strxfrm_l.texi.
119233         * doc/posix-functions/timer_gettime.texi: Renamed from
119234         doc/glibc-functions/timer_gettime.texi.
119235         * doc/posix-functions/tolower_l.texi: Renamed from
119236         doc/glibc-functions/tolower_l.texi.
119237         * doc/posix-functions/toupper_l.texi: Renamed from
119238         doc/glibc-functions/toupper_l.texi.
119239         * doc/posix-functions/towctrans_l.texi: Renamed from
119240         doc/glibc-functions/towctrans_l.texi.
119241         * doc/posix-functions/towlower_l.texi: Renamed from
119242         doc/glibc-functions/towlower_l.texi.
119243         * doc/posix-functions/towupper_l.texi: Renamed from
119244         doc/glibc-functions/towupper_l.texi.
119245         * doc/posix-functions/uselocale.texi: Renamed from
119246         doc/glibc-functions/uselocale.texi.
119247         * doc/posix-functions/vdprintf.texi: Renamed from
119248         doc/glibc-functions/vdprintf.texi.
119249         * doc/posix-functions/wcpcpy.texi:
119250         Renamed from doc/glibc-functions/wcpcpy.texi.
119251         * doc/posix-functions/wcpncpy.texi: Renamed from
119252         doc/glibc-functions/wcpncpy.texi.
119253         * doc/posix-functions/wcscasecmp.texi: Renamed from
119254         doc/glibc-functions/wcscasecmp.texi.
119255         * doc/posix-functions/wcscasecmp_l.texi: Renamed from
119256         doc/glibc-functions/wcscasecmp_l.texi.
119257         * doc/posix-functions/wcscoll_l.texi: Renamed from
119258         doc/glibc-functions/wcscoll_l.texi.
119259         * doc/posix-functions/wcsdup.texi: Renamed from
119260         doc/glibc-functions/wcsdup.texi.
119261         * doc/posix-functions/wcsncasecmp.texi: Renamed from
119262         doc/glibc-functions/wcsncasecmp.texi.
119263         * doc/posix-functions/wcsncasecmp_l.texi: Renamed from
119264         doc/glibc-functions/wcsncasecmp_l.texi.
119265         * doc/posix-functions/wcsnlen.texi: Renamed from
119266         doc/glibc-functions/wcsnlen.texi.
119267         * doc/posix-functions/wcsnrtombs.texi: Renamed from
119268         doc/glibc-functions/wcsnrtombs.texi.
119269         * doc/posix-functions/wcsxfrm_l.texi: Renamed from
119270         doc/glibc-functions/wcsxfrm_l.texi.
119271         * doc/posix-functions/wctrans_l.texi: Renamed from
119272         doc/glibc-functions/wctrans_l.texi.
119273         * doc/posix-functions/wctype_l.texi: Renamed from
119274         doc/glibc-functions/wctype_l.texi.
119275         * doc/gnulib.texi (Function Substitutes): Add these subsections.
119276         (Glibc ctype.h, Glibc dirent.h, Glibc getopt.h, Glibc math.h,
119277         Glibc sched.h, Glibc signal.h, Glibc stdio.h, Glibc stdlib.h,
119278         Glibc string.h, Glibc time.h, Glibc unistd.h, Glibc wchar.h): Remove
119279         these subsections.
119280         (Glibc langinfo.h, Glibc locale.h, Glibc monetary.h, Glibc wctype.h):
119281         Remove sections.
119283 2008-12-14  Bruno Haible  <bruno@clisp.org>
119285         Update doc for POSIX:2008.
119286         * doc/posix-functions/*.texi: Update URL of POSIX specification.
119288 2008-12-14  Bruno Haible  <bruno@clisp.org>
119290         Update doc for POSIX:2008.
119291         * doc/pastposix-functions/bcmp.texi: Renamed from
119292         doc/posix-functions/bcmp.texi.
119293         * doc/pastposix-functions/bcopy.texi: Renamed from
119294         doc/posix-functions/bcopy.texi.
119295         * doc/pastposix-functions/bsd_signal.texi: Renamed from
119296         doc/posix-functions/bsd_signal.texi.
119297         * doc/pastposix-functions/bzero.texi: Renamed from
119298         doc/posix-functions/bzero.texi.
119299         * doc/pastposix-functions/ecvt.texi: Renamed from
119300         doc/posix-functions/ecvt.texi.
119301         * doc/pastposix-functions/fcvt.texi: Renamed from
119302         doc/posix-functions/fcvt.texi.
119303         * doc/pastposix-functions/ftime.texi: Renamed from
119304         doc/posix-functions/ftime.texi.
119305         * doc/pastposix-functions/gcvt.texi: Renamed from
119306         doc/posix-functions/gcvt.texi.
119307         * doc/pastposix-functions/getcontext.texi: Renamed from
119308         doc/posix-functions/getcontext.texi.
119309         * doc/pastposix-functions/gethostbyaddr.texi: Renamed from
119310         doc/posix-functions/gethostbyaddr.texi.
119311         * doc/pastposix-functions/gethostbyname.texi: Renamed from
119312         doc/posix-functions/gethostbyname.texi.
119313         * doc/pastposix-functions/getwd.texi: Renamed from
119314         doc/posix-functions/getwd.texi.
119315         * doc/pastposix-functions/h_errno.texi: Renamed from
119316         doc/posix-functions/h_errno.texi.
119317         * doc/pastposix-functions/index.texi: Renamed from
119318         doc/posix-functions/index.texi.
119319         * doc/pastposix-functions/makecontext.texi: Renamed from
119320         doc/posix-functions/makecontext.texi.
119321         * doc/pastposix-functions/mktemp.texi: Renamed from
119322         doc/posix-functions/mktemp.texi.
119323         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Renamed from
119324         doc/posix-functions/pthread_attr_getstackaddr.texi.
119325         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Renamed from
119326         doc/posix-functions/pthread_attr_setstackaddr.texi.
119327         * doc/pastposix-functions/rindex.texi: Renamed from
119328         doc/posix-functions/rindex.texi.
119329         * doc/pastposix-functions/scalb.texi: Renamed from
119330         doc/posix-functions/scalb.texi.
119331         * doc/pastposix-functions/setcontext.texi: Renamed from
119332         doc/posix-functions/setcontext.texi.
119333         * doc/pastposix-functions/swapcontext.texi: Renamed from
119334         doc/posix-functions/swapcontext.texi.
119335         * doc/pastposix-functions/ualarm.texi: Renamed from
119336         doc/posix-functions/ualarm.texi.
119337         * doc/pastposix-functions/usleep.texi: Renamed from
119338         doc/posix-functions/usleep.texi.
119339         * doc/pastposix-functions/vfork.texi: Renamed from
119340         doc/posix-functions/vfork.texi.
119341         * doc/pastposix-functions/wcswcs.texi: Renamed from
119342         doc/posix-functions/wcswcs.texi.
119343         * doc/gnulib.texi (Legacy Function Substitutes): New chapter.
119344         (Function Substitutes): Update.
119346 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
119348         * modules/relocatable-prog-wrapper (Depends-on): Add errno, needed by
119349         m4/strerror.m4.
119351 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
119352             Bruno Haible  <bruno@clisp.org>
119354         * modules/unilbrk/tables (Depends-on): Add unilbrk/base.
119356 2008-12-13  Bruno Haible  <bruno@clisp.org>
119358         * modules/strtoull (Depends-on): Remove unistd.
119360 2008-12-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
119362         * modules/strtoull (Depends-on): Add stdlib.
119364 2008-12-11  Simon Josefsson  <simon@josefsson.org>
119366         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add more warnings.
119368 2008-12-10  Jim Meyering  <meyering@redhat.com>
119370         gl_ASSERT: don't say assertions are disabled when they're not
119371         * m4/assert.m4 (gl_ASSERT): Do not make configure report
119372         "checking whether to enable assertions... no", when they are in
119373         fact enabled.  This is solely a bug in the output of configure.
119374         In spite of saying "no", NDEBUG was not defined in that case.
119375         Also, as noted by Eric Blake, leave assertions enabled upon
119376         --enable-assert=INVALID.
119378 2008-12-10  Bruno Haible  <bruno@clisp.org>
119380         Change MODULES.html to refer to POSIX:2008 where possible.
119381         * MODULES.html.sh (POSIX2008_URL): New variable.
119382         (posix_headers): Remove sys/timeb, ucontext.
119383         (posix2001_headers): New variable.
119384         (posix_functions): Remove bcmp, bcopy, bsd_signal, bzero, ecvt, fcvt,
119385         ftime, gcvt, getcontext, gethostbyaddr, gethostbyname, getwd, h_errno,
119386         index, makecontext, mktemp, pthread_attr_getstackaddr,
119387         pthread_attr_setstackaddr, rindex, scalb, setcontext, swapcontext,
119388         ualarm, usleep, vfork, wcswcs. Add the new POSIX:2008 functions.
119389         (posix2001_functions): New variable.
119390         (func_module): Use URLs to POSIX:2008 where possible and to POSIX:2001
119391         otherwise.
119393 2008-12-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
119395         add missing include to parse-duration.c
119396         * lib/parse-duration.c: #include "xalloc.h", for xstrdup.
119397         * modules/parse-duration (Depends-on): Add xalloc.
119399         fix sed script reading maint.mk
119400         * top/maint.mk (MYSELF): New macro, define as $(srcdir)/$(ME).
119401         (syntax-check-rules): Use it.
119403 2008-12-09  Bruno Haible  <bruno@clisp.org>
119405         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Add another check, that fails on
119406         MacOS X 10.4/PowerPC.
119407         Reported by Simon Josefsson.
119409 2008-12-08  Jim Meyering  <meyering@redhat.com>
119411         work around mingw's lack of some S_IF definitions
119412         * lib/fts.c (S_IFLNK, S_IFSOCK): Define if not already defined.
119413         Reported by Simon Josefsson.
119415 2008-12-08  Bruno Haible  <bruno@clisp.org>
119417         * m4/signbitl.m4 (gl_SIGNBIT_TEST_PROGRAM): Add a link check of signbit
119418         applied to variables. Needed on MacOS X 10.4/PowerPC.
119419         Reported by Simon Josefsson.
119421 2008-12-08  William Pursell  <bill.pursell@gmail.com>  (tiny change)
119422         and Eric Blake  <ebb9@byu.net>
119424         assert: honor --enable-assert
119425         * m4/assert.m4 (gl_ASSERT): Synchronize with autoconf 2.64, in
119426         order to honor --enable-assert, rather than treating it as a
119427         synonym for --disable-assert.
119429 2008-12-08  Jim Meyering  <meyering@redhat.com>
119431         * lib/posixtm.c: Remove now-useless declaration of mktime.
119433         * build-aux/announce-gen (get_tool_versions): Accept .xz tarballs.
119435 2008-12-07  Bruno Haible  <bruno@clisp.org>
119437         * tests/test-lock.c (test_lock, test_rwlock, test_recursive_lock,
119438         test_once): Mark functions as static.
119439         * tests/test-tls.c (test_tls): Likewise.
119441 2008-12-07  Bruno Haible  <bruno@clisp.org>
119443         * lib/striconveha.h (uniconv_register_autodetect): Renamed from
119444         iconv_register_autodetect.
119446 2008-12-07  Jim Meyering  <meyering@redhat.com>
119448         posixtm.c: avoid a warning
119449         * lib/posixtm.c (posixtime): Don't initialize tm0.
119450         It's no longer needed to placate gcc4's -Wuninitialized,
119451         and the attempt to placate would elicit a new warning.
119453         unicodeio.c: mark unused parameters
119454         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
119455         (fallback_failure_callback): Likewise.
119457 2008-12-07  Bruno Haible  <bruno@clisp.org>
119459         * gnulib-tool (func_create_testdir): When building the tests
119460         subdirectory, ignore the modules gnumakefile and maintainer-makefile.
119461         Reported by Simon Josefsson.
119463 2008-12-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
119465         * doc/manywarnings.texi, doc/gnulib-intro.texi: Fix typos.
119467 2008-12-06  Bruno Haible  <bruno@clisp.org>
119469         * lib/c-stack.h (c_stack_action): Clarify possible side effects.
119470         Suggested by Eric Blake.
119472 2008-12-06  Bruno Haible  <bruno@clisp.org>
119474         Fix a c-stack test failure on MacOS X.
119475         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Require
119476         AC_CANONICAL_HOST. Define FAULT_YIELDS_SIGBUS. If set, install a signal
119477         handler for SIGBUS as well.
119478         * lib/c-stack.c (c_stack_action): If FAULT_YIELDS_SIGBUS is set,
119479         install a signal handler for SIGBUS as well.
119480         Reported by Bruce Dugan <bld0401@gmail.com> via Eric Blake.
119482 2008-12-06  Bruno Haible  <bruno@clisp.org>
119484         Advocacy documentation.
119485         * doc/gnulib-intro.texi (Benefits): New section.
119486         * doc/gnulib.texi: Update.
119488 2008-12-06  Bruno Haible  <bruno@clisp.org>
119490         Document the 'manywarnings' module.
119491         * doc/manywarnings.texi: New file.
119492         * doc/gnulib.texi: Include it.
119494 2008-12-05  Eric Blake  <ebb9@byu.net>
119496         tests: silence some gcc warnings
119497         * tests/test-getdate.c (LOG) [!DEBUG]: Mark no-op void.
119498         * tests/uniwidth/test-uc_width2.c (finish_interval): Avoid printf
119499         type mismatches.
119501 2008-12-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
119502             Bruno Haible  <bruno@clisp.org>
119504         * m4/openmp.m4 (AC_OPENMP): Do not define with Autoconf 2.62 or newer.
119506 2008-11-29  Jim Meyering  <meyering@redhat.com>
119508         unicodeio.c: mark unused parameters
119509         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
119510         (fallback_failure_callback): Likewise.
119512         fts: fix a thinko
119513         * lib/fts.c (s_ifmt_shift_bits): Remove function.  Not needed after all.
119514         (set_stat_type): Return S_IF*-valued "type" directly.
119515         Prompted by James Youngman's spotting a related bug.
119516         Confirmed by further testing through find.
119518         fts: provide dirent.d_type via FTSENT.fts_statp, when possible
119519         * lib/fts.c (D_TYPE): Define.
119520         (DT_UNKNOWN, DT_BLK, DT_CHR) [HAVE_STRUCT_DIRENT_D_TYPE]: Define.
119521         (DT_DIR, DT_FIFO, DT_LNK, DT_REG, DT_SOCK): Likewise.
119522         (s_ifmt_shift_bits): New function.
119523         (set_stat_type): New function.
119524         (fts_build): When not calling fts_stat, call set_stat_type
119525         to propagate dirent.d_type info to fts_read caller.
119526         * lib/fts_.h (FTSENT) [FTS_DEFER_STAT]: Mention that
119527         fts_statp->st_mode type information may be valid.
119529 2008-11-28  Simon Josefsson  <simon@josefsson.org>
119531         * lib/sys_time.in.h: Add extern "C" block for C++.  Suggested by
119532         Brian Dessent <brian@dessent.net>.  Reported by Sam Steingold
119533         <sds@gnu.org>.
119535 2008-11-20  Bruno Haible  <bruno@clisp.org>
119537         Attempt to work around an AIX 5.3, 6.1 compiler bug with include_next.
119538         * lib/math.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of
119539         INCLUDE_NEXT.
119540         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also
119541         INCLUDE_NEXT_AS_FIRST_DIRECTIVE.
119542         * modules/math (Makefile.am): Substitute
119543         INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of INCLUDE_NEXT.
119544         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
119546 2008-11-18  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
119547             Bruno Haible  <bruno@clisp.org>
119549         * lib/stdint.in.h: Define all type macros so that their expansion is
119550         a single typedef'ed token. Fixes a compilation failure in Boost which
119551         does "using ::int8_t;".
119553 2008-11-18  Simon Josefsson  <simon@josefsson.org>
119555         * m4/manywarnings.m4: New file with gl_MANYWARN_COMPLEMENT and
119556         gl_MANYWARN_ALL_GCC.
119557         * m4/warnings.m4: Removed gl_WARN_SUPPORTED and
119558         gl_WARN_COMPLEMENT.  Suggested by Bruno Haible <bruno@clisp.org>.
119559         * modules/manywarnings: New file.
119560         * MODULES.html.sh: Mention manywarnings module.
119562 2008-11-18  Bruno Haible  <bruno@clisp.org>
119564         * doc/gnulib-tool.texi (Unit tests): New section.
119566 2008-11-18  Simon Josefsson  <simon@josefsson.org>
119568         * top/maint.mk (refresh-po): Fix sed regexp to avoid problems with
119569         paths like 'lib/po/foo.po'.
119571 2008-11-17  Simon Josefsson  <simon@josefsson.org>
119573         * m4/warnings.m4: Improve code.  Reported by Ralf Wildenhues
119574         <Ralf.Wildenhues@gmx.de> and Paolo Bonzini <bonzini@gnu.org>.
119576 2008-11-17  Simon Josefsson  <simon@josefsson.org>
119578         * m4/warnings.m4: Use CPPFLAGS to really check whether the
119579         parameter works.
119581 2008-11-17  Simon Josefsson  <simon@josefsson.org>
119583         * m4/warnings.m4: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.
119585 2008-11-17  Bruce Korb  <bkorb@gnu.org>
119587         * modules/parse-duration-tests: New file.
119588         * tests/test-parse-duration.sh: New file.
119589         * tests/test-parse-duration.c: New file.
119591         New module 'parse-duration'.
119592         * lib/parse-duration.h: New file.
119593         * lib/parse-duration.c: New file.
119594         * modules/parse-duration: New file.
119596 2008-11-17  Bruno Haible  <bruno@clisp.org>
119598         * tests/test-select-out.sh: Comment out the first pipe test.
119599         Reported by Simon Josefsson.
119601 2008-11-17  Bruno Haible  <bruno@clisp.org>
119603         * modules/getaddrinfo (Depends-on): Add servent, hostent.
119604         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_SERVENT and
119605         gl_HOSTENT.
119607 2008-11-17  Bruno Haible  <bruno@clisp.org>
119609         * m4/sockets.m4 (gl_SOCKETS): After trying -lsocket, try also
119610         -lnetwork and -lnet. Needed for Haiku and BeOS.
119612 2008-11-16  Bruno Haible  <bruno@clisp.org>
119614         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix indentation.
119616 2008-11-16  Bruno Haible  <bruno@clisp.org>
119618         Avoid test failure on Haiku.
119619         * tests/test-fsync.c: Include <errno.h>.
119620         (main): Don't require that fsync (0) fails.
119622 2008-11-15  Bruno Haible  <bruno@clisp.org>
119624         New module 'hostent'.
119625         * modules/hostent: New file.
119626         * m4/hostent.m4: New file, based on code in m4/getaddrinfo.m4.
119628 2008-11-15  Bruno Haible  <bruno@clisp.org>
119630         New module 'servent'.
119631         * modules/servent: New file.
119632         * m4/servent.m4: New file, based on code in m4/getaddrinfo.m4.
119634 2008-11-15  Bruno Haible  <bruno@clisp.org>
119636         Avoid generating same test program with two different rules.
119637         * modules/frexp-nolibm-tests (Makefile.am): Rename test program from
119638         test-frexp to test-frexp-nolibm.
119639         * modules/frexpl-nolibm-tests (Makefile.am): Rename test program from
119640         test-frexpl to test-frexpl-nolibm.
119642 2008-11-15  Bruno Haible  <bruno@clisp.org>
119644         * modules/frexpl-tests (Makefile.am): Link test-frexpl with
119645         $(FREXPL_LIBM).
119647 2008-11-15  Bruno Haible  <bruno@clisp.org>
119649         * lib/netdb.in.h: Activate the definitions also when the system's
119650         <netdb.h> has 'struct addrinfo'.
119651         * m4/netdb_h.m4 (gl_HEADER_NETDB): Replace netdb.h also when it lacks
119652         EAI_OVERFLOW or AI_NUMERICSERV.
119653         * doc/posix-headers/netdb.texi: Document the problem.
119655 2008-11-15  Bruno Haible  <bruno@clisp.org>
119657         * tests/test-sched.c: Test also the existence of the SCHED_* macros.
119659         Make the 'sched' module work on platforms where <sched.h> exists but
119660         is incomplete (such as Haiku).
119661         * lib/sched.in.h; Include the system's <sched.h> if it exists.
119662         (SCHED_FIFO, SCHED_RR, SCHED_OTHER): New macros.
119663         * m4/sched_h.m4 (gl_SCHED_H): Test whether <sched.h> exists and also
119664         defines SCHED_FIFO, SCHED_RR, SCHED_OTHER. Set HAVE_SCHED_H,
119665         HAVE_STRUCT_SCHED_PARAM.
119666         * modules/sched (Depends-on): Add include_next.
119667         (Makefile.am): Substitute HAVE_SCHED_H, INCLUDE_NEXT,
119668         PRAGMA_SYSTEM_HEADER, NEXT_SCHED_H, HAVE_STRUCT_SCHED_PARAM.
119669         * doc/posix-headers/sched.texi: Document the issue.
119671 2008-11-13  Jim Meyering  <meyering@redhat.com>
119673         test-argp-2: avoid test failure when PACKAGE_BUGREPORT is defined
119674         * tests/test-argp-2.sh: When PACKAGE_BUGREPORT was defined, this
119675         test would fail due to the difference in the Report bugs to ...
119676         line.  The expected address is empty, "<>", while the actual
119677         would contain e.g., "<bug-tar@gnu.org>".  Filter out any address.
119679 2008-11-12  Bruno Haible  <bruno@clisp.org>
119681         lstat: don't compile lstat.c on systems lacking lstat
119682         * m4/lstat.m4 (gl_FUNC_LSTAT): Don't compile lstat.c on systems
119683         which don't have lstat; this is handled by lib/sys_stat.in.h already.
119684         Reported by Daniel P. Berrange via Jim Meyering.
119686 2008-11-12  Jim Meyering  <meyering@redhat.com>
119688         * lib/unicodeio.c (unicode_to_mb): Correct spelling of u8_uctomb.
119690 2008-11-12  Simon Josefsson  <simon@josefsson.org>
119692         * modules/warnings (configure.ac): Do AC_SUBST([WARN_CFLAGS]) here
119693         instead.
119695 2008-11-12  Bruno Haible  <bruno@clisp.org>
119697         * lib/unicodeio.c: Include unistr.h.
119698         (utf8_wctomb): Remove function.
119699         (unicode_to_mb): Use utf8_uctomb instead of utf8_wctomb.
119701 2008-11-12  Simon Josefsson  <simon@josefsson.org>
119703         * m4/warnings.m4 (gl_WARN_INIT): Remove, suggested by Ralf
119704         Wildenhues <Ralf.Wildenhues@gmx.de> and Bruno Haible
119705         <bruno@clisp.org>.
119706         * modules/warnings (configure.ac): Don't call gl_WARN_INIT.
119708 2008-11-12  Simon Josefsson  <simon@josefsson.org>
119710         * doc/warnings.texi: New file, from Bruno Haible <bruno@clisp.org>.
119711         * doc/gnulib.texi: Add section for warnings.
119713 2008-11-11  Bruno Haible  <bruno@clisp.org>
119715         * lib/sockets.h: Add a comment.
119717 2008-11-11  Karl Berry  <karl@gnu.org>
119719         * config/srclist.txt (fdl.texi): add, syncing from gnustandards.
119721 2008-11-11  Eric Blake  <ebb9@byu.net>
119723         fdl.texi: avoid git symlinks
119724         * doc/fdl.texi: Copy, rather than link, fdl-1.3.texi.
119726 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
119728         * m4/warnings.m4 (gl_WARN_ADD): Don't AC_SUBST the empty string.
119730 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
119732         * m4/warnings.m4 (gl_WARN_INIT): Substitute WARN_CFLAGS.
119733         (gl_WARN_ADD): Substitute $2 if literal.
119735 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
119737         * m4/warning.m4: Remove.
119739 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
119741         * m4/warnings.m4: Almost complete rewrite. :-)
119743 2008-11-10  Simon Josefsson  <simon@josefsson.org>
119745         * modules/warnings: New module.
119746         * m4/warnings.m4: New file.
119747         * MODULES.html.sh: Mention warnings module.
119748         With review improvements from Paolo Bonzini <bonzini@gnu.org> and
119749         Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
119751 2008-11-10  Eric Blake  <ebb9@byu.net>
119753         fdl.texi: make a symlink to the latest version
119754         * doc/standards.texi: Revert today's earlier change.
119755         * doc/fdl-1.2.texi: Rename from old fdl.texi...
119756         * doc/fdl.texi: ...and replace this with a symlink to the newer
119757         fdl-1.3.texi.
119759 2008-11-10  Bruno Haible  <bruno@clisp.org>
119761         * tests/test-select-fd.c (main): Accept the result file name as fourth
119762         argument.
119763         * tests/test-select-in.sh: Pass t-select-in.tmp as fourth argument.
119764         * tests/test-select-out.sh: Pass t-select-out.tmp as fourth argument.
119766 2008-11-10  Bruno Haible  <bruno@clisp.org>
119768         * lib/netdb.in.h: Use HAVE_STRUCT_ADDRINFO, HAVE_DECL_GETADDRINFO,
119769         HAVE_DECL_FREEADDRINFO, HAVE_DECL_GAI_STRERROR, HAVE_DECL_GETNAMEINFO
119770         as autoconf-substituted macros.
119771         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Initialize these variables to 1.
119772         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require
119773         gl_NETDB_H_DEFAULTS. Set these variables.
119774         * modules/netdb (Makefile.am): Substitute these variables.
119776 2008-11-10  Eric Blake  <ebb9@byu.net>
119778         standards.texi: include correct file for FDL 1.3
119779         * doc/standards.texi (GNU Free Documentation License): Change
119780         include file to pull in FDL 1.3, not 1.2.
119782         fdl.texi: revert accidental change to license
119783         * doc/fdl.texi: This is FDL 1.2, not 1.3.
119785 2008-11-10  Bruno Haible  <bruno@clisp.org>
119787         * m4/printf.m4 (gl_PRINTF_ENOMEM): Guess yes on Haiku. Use the
119788         cross-compiling guesses also when the native compile gives no result.
119790 2008-11-10  Bruno Haible  <bruno@clisp.org>
119792         * lib/spawni.c (__spawni): Force variable into the stack.
119794 2008-11-10  Bruno Haible  <bruno@clisp.org>
119796         Add support for Haiku.
119797         * lib/fbufmode.c (fbufmode): Test a symbol that is not only defined on
119798         glibc and BeOS, but also on Haiku.
119799         * lib/fpurge.c (fpurge): Likewise.
119800         * lib/freadable.c (freadable): Likewise.
119801         * lib/freadahead.c (freadahead): Likewise.
119802         * lib/freading.c (freading): Likewise.
119803         * lib/freadptr.c (freadptr): Likewise.
119804         * lib/freadseek.c (freadptrinc): Likewise.
119805         * lib/fseeko.c (rpl_fseeko): Likewise.
119806         * lib/fseterr.c (fseterr): Likewise.
119807         * lib/fwritable.c (fwritable): Likewise.
119808         * lib/fwriting.c (fwriting): Likewise.
119809         Reported by Ingo Weinhold <ingo_weinhold@gmx.de>.
119811 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
119813         * lib/config.charset: Treat Haiku like BeOS.
119815 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
119817         * lib/binary-io.h (O_BINARY, O_TEXT): Treat Haiku like BeOS.
119818         * lib/fcntl.in.h (O_BINARY, O_TEXT): Likewise.
119820 2008-11-08  Bruno Haible  <bruno@clisp.org>
119822         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Avoid using AC_CHECK_DECL inside
119823         AC_CACHE_CHECK.
119825 2008-11-08  Bruno Haible  <bruno@clisp.org>
119827         * modules/select-tests (configure.ac): Check for unistd.h, sys/wait.h.
119829 2008-11-08  Bruno Haible  <bruno@clisp.org>
119831         * tests/test-select-fd.c: New file.
119832         * tests/test-select-in.sh: New file.
119833         * tests/test-select-out.sh: New file.
119834         * tests/test-select-stdin.c: New file.
119835         * modules/select-tests (Files): Add the new files.
119836         (Depends-on): Add gettimeofday.
119837         (Makefile.am): Add test-select-in.sh, test-select-out.sh to TESTS.
119838         Set TESTS_ENVIRONMENT. Add test-select-fd, test-select-stdin to
119839         check_PROGRAMS. Define test_select_fd_LDADD, test_select_stdin_LDADD.
119841 2008-11-06  Alexander V. Lukyanov  <lav@netis.ru>
119842             Bruno Haible  <bruno@clisp.org>
119844         * lib/sys_stat.in.h: Enclose function definitions in extern "C".
119846 2008-10-12  Giuseppe Scrivano  <gscrivano@gnu.org>
119848         * build-aux/pmccabe2html: Added support for C++ source files.
119850 2008-11-05  Ben Pfaff  <blp@gnu.org>
119852         Fix lib/close.c build on Windows.
119853         * modules/close (Files): Add lib/w32sock.h.
119855 2008-11-05  Joel E. Denny  <jdenny@ces.clemson.edu>
119857         Accept Bison's NEWS format.
119858         * build-aux/announce-gen (print_news_deltas): Tweak
119859         $re_prefix.
119861 2008-11-04  Bruno Haible  <bruno@clisp.org>
119863         * modules/random_r (Maintainer): Add glibc.
119865 2008-11-04  Simon Josefsson  <simon@josefsson.org>
119867         * doc/alloca-opt.texi: Change license to GFDLv1.3+, as suggested
119868         by karl@freefriends.org (Karl Berry).
119869         * doc/alloca.texi: Likewise.
119870         * doc/c-ctype.texi: Likewise.
119871         * doc/c-strcase.texi: Likewise.
119872         * doc/c-strcaseeq.texi: Likewise.
119873         * doc/c-strcasestr.texi: Likewise.
119874         * doc/c-strstr.texi: Likewise.
119875         * doc/c-strtod.texi: Likewise.
119876         * doc/c-strtold.texi: Likewise.
119877         * doc/ctime.texi: Likewise.
119878         * doc/error.texi: Likewise.
119879         * doc/fdl.texi: Likewise.
119880         * doc/gcd.texi: Likewise.
119881         * doc/getdate.texi: Likewise.
119882         * doc/gnulib-intro.texi: Likewise.
119883         * doc/gnulib-tool.texi: Likewise.
119884         * doc/gnulib.texi: Likewise.
119885         * doc/inet_ntoa.texi: Likewise.
119886         * doc/maintain.texi: Likewise.
119887         * doc/make-stds.texi: Likewise.
119888         * doc/quote.texi: Likewise.
119889         * doc/regexprops-generic.texi: Likewise.
119890         * doc/standards.texi: Likewise.
119891         * doc/verify.texi: Likewise.
119892         * doc/visibility.texi: Likewise.
119893         * doc/gnulib.texi (GNU Free Documentation License): Include
119894         fdl-1.3.texi instead of fdl.texi.
119896 2008-11-04  Simon Josefsson  <simon@josefsson.org>
119898         * doc/fdl-1.3.texi: New file, from
119899         <http://www.gnu.org/licenses/fdl-1.3.texi>.
119900         * modules/fdl-1.3: Add.
119901         * MODULES.html.sh: Add fdl-1.3.
119903 2008-11-03  Bruno Haible  <bruno@clisp.org>
119905         Make determination of absolute name of header file work with AIX xlc.
119906         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Require
119907         AC_CANONICAL_HOST. On AIX, use "$CPP -C" rather than "$CPP" for
119908         preprocessing.
119909         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
119910         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
119912 2008-11-03  Simon Josefsson  <simon@josefsson.org>
119914         * top/maint.mk (COVERAGE_CCOPTS): Use --coverage instead of
119915         -fprofile-arcs -ftest-coverage.  Suggested by Ludovic Courtès
119916         <ludo@gnu.org>.
119918 2008-11-02  Bruno Haible  <bruno@clisp.org>
119920         Mark 'strpbrk' obsolete.
119921         * modules/strpbrk (Status, Notice): New sections.
119922         * modules/strtok_r (Depends-on): Add strpbrk.
119924 2008-11-02  Bruno Haible  <bruno@clisp.org>
119926         Mark 'strdup' obsolete.
119927         * modules/strdup (Status, Notice): New sections.
119928         * modules/findprog (Depends-on): Add strdup.
119929         * modules/getaddrinfo (Depends-on): Likewise.
119930         * modules/localename (Depends-on): Likewise.
119931         * modules/relocatable-lib (Depends-on): Likewise.
119932         * modules/relocatable-lib-lgpl (Depends-on): Likewise.
119933         * modules/relocatable-prog (Depends-on): Likewise.
119934         * modules/trim (Depends-on): Likewise.
119935         * modules/unictype/gen-ctype (Depends-on): Likewise.
119936         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
119938 2008-11-02  Bruno Haible  <bruno@clisp.org>
119940         Mark 'strcspn' obsolete.
119941         * modules/strcspn (Status, Notice): New sections.
119943 2008-11-02  Bruno Haible  <bruno@clisp.org>
119945         Mark 'rmdir' obsolete.
119946         * modules/rmdir (Status, Notice): New sections.
119947         * modules/clean-temp (Depends-on): Add rmdir.
119948         * modules/openat (Depends-on): Likewise.
119950 2008-11-02  Bruno Haible  <bruno@clisp.org>
119952         Mark 'raise' obsolete.
119953         * modules/raise (Status, Notice): New sections.
119954         (Include): Specify <signal.h>.
119955         * modules/stdio (Depends-on): Add raise.
119956         * modules/write (Depends-on): Likewise.
119958 2008-11-02  Bruno Haible  <bruno@clisp.org>
119960         Mark 'memset' obsolete.
119961         * modules/memset (Status, Notice): New sections.
119963 2008-11-02  Bruno Haible  <bruno@clisp.org>
119965         Mark 'memmove' obsolete.
119966         * modules/memmove (Status, Notice): New sections.
119967         * modules/argp (Depends-on): Add memmove.
119968         * modules/argz (Depends-on): Likewise.
119969         * modules/canonicalize (Depends-on): Likewise.
119970         * modules/canonicalize-lgpl (Depends-on): Likewise.
119971         * modules/fts (Depends-on): Likewise.
119972         * modules/getcwd (Depends-on): Likewise.
119973         * modules/human (Depends-on): Likewise.
119974         * modules/regex (Depends-on): Likewise.
119975         * modules/striconveh (Depends-on): Likewise.
119976         * modules/trim (Depends-on): Likewise.
119977         * modules/unistr/u8-move (Depends-on): Likewise.
119978         * modules/unistr/u16-move (Depends-on): Likewise.
119979         * modules/unistr/u32-move (Depends-on): Likewise.
119981 2008-11-02  Bruno Haible  <bruno@clisp.org>
119983         Mark 'memcpy' obsolete.
119984         * modules/memcpy (Status, Notice): New sections.
119986 2008-11-02  Bruno Haible  <bruno@clisp.org>
119988         Mark 'memcmp' obsolete.
119989         * modules/memcmp (Status, Notice): New sections.
119990         * modules/argmatch (Depends-on): Add memchr.
119991         * modules/backupfile (Depends-on): Likewise.
119992         * modules/c-strcasestr (Depends-on): Likewise.
119993         * modules/crypto/des (Depends-on): Likewise.
119994         * modules/csharpcomp (Depends-on): Likewise.
119995         * modules/fnmatch (Depends-on): Likewise.
119996         * modules/git-merge-changelog (Depends-on): Likewise.
119997         * modules/isnand (Depends-on): Likewise.
119998         * modules/isnand-nolibm (Depends-on): Likewise.
119999         * modules/isnanf (Depends-on): Likewise.
120000         * modules/isnanf-nolibm (Depends-on): Likewise.
120001         * modules/isnanl (Depends-on): Likewise.
120002         * modules/isnanl-nolibm (Depends-on): Likewise.
120003         * modules/mbchar (Depends-on): Likewise.
120004         * modules/memcoll (Depends-on): Likewise.
120005         * modules/quotearg (Depends-on): Likewise.
120006         * modules/regex (Depends-on): Likewise.
120007         * modules/relocatable-prog (Depends-on): Likewise.
120008         * modules/same (Depends-on): Likewise.
120009         * modules/signbit (Depends-on): Likewise.
120010         * modules/strcasestr-simple (Depends-on): Likewise.
120011         * modules/unictype/gen-ctype (Depends-on): Likewise.
120012         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
120013         * modules/uniname/uniname (Depends-on): Likewise.
120014         * modules/unistr/u8-cmp (Depends-on): Likewise.
120016 2008-11-02  Bruno Haible  <bruno@clisp.org>
120018         Mark 'memchr' obsolete.
120019         * modules/memchr (Status, Notice): New sections.
120020         * modules/argp (Depends-on): Add memchr.
120021         * modules/base64 (Depends-on): Likewise.
120022         * modules/c-strcasestr (Depends-on): Likewise.
120023         * modules/chdir-long (Depends-on): Likewise.
120024         * modules/fnmatch (Depends-on): Likewise.
120025         * modules/getsubopt (Depends-on): Likewise.
120026         * modules/git-merge-changelog (Depends-on): Likewise.
120027         * modules/glob (Depends-on): Likewise.
120028         * modules/strcasestr-simple (Depends-on): Likewise.
120029         * modules/strnlen (Depends-on): Likewise.
120031 2008-11-02  Bruno Haible  <bruno@clisp.org>
120033         Mark 'atexit' obsolete.
120034         * modules/atexit (Status, Notice): New sections.
120035         * modules/chdir-long (Depends-on): Add atexit.
120036         * modules/wait-process (Depends-on): Likewise.
120038 2008-11-02  Bruno Haible  <bruno@clisp.org>
120040         * gnulib-tool: New option --with-obsolete.
120041         (func_usage): Document it.
120042         (func_modules_transitive_closure): Drop obsolete dependencies if
120043         incobsolete is not true.
120044         (func_import): Read and save the incobsolete variable to the cache.
120046 2008-11-02  Bruno Haible  <bruno@clisp.org>
120048         * modules/TEMPLATE-EXTENDED: New field 'Status'.
120049         * gnulib-tool: New option --extract-status.
120050         (func_usage): Document it.
120051         (sed_extract_prog): Recognize it.
120052         (func_get_status): New function.
120054 2008-10-30  Simon Josefsson  <simon@josefsson.org>
120056         * modules/sockets (License): Change from LGPL to LGPLv2+.
120058 2008-10-28  Simon Josefsson  <simon@josefsson.org>
120060         * top/maint.mk: Add coverage rules, inspired by scripts in gnupdf.
120062 2008-10-28  Simon Josefsson  <simon@josefsson.org>
120064         * MODULES.html.sh (Support for systems lacking POSIX:2001):
120065         Mention times and sys_times.
120066         * modules/sys_times, modules/sys_times-tests: New modules.
120067         * modules/times, modules/times-tests: Likewise
120068         * m4/sys_times_h.m4: New file.
120069         * lib/sys_times.in.h: Likewise
120070         * lib/times.c: Likewise.
120071         * tests/test-sys_times.c: Likewise.
120072         * tests/test-times.c: Likewise.
120073         * doc/posix-headers/sys_times.texi: Update.
120074         * doc/posix-functions/times.texi: Update.
120076 2008-10-28  Jim Meyering  <meyering@redhat.com>
120078         * modules/tempname (Depends-on): Add lstat.
120080         * modules/lstat (License): Relicense: LGPL -> LGPLv2+.
120082 2008-10-28  Simon Josefsson  <simon@josefsson.org>
120084         * gnulib-tool (func_emit_tests_Makefile_am): Revert last commit.
120085         * modules/argp-tests (test_argp_LDADD): Set EXEEXT here instead,
120086         using idiom used elsewhere in gnulib.
120088 2008-10-27  Jim Meyering  <meyering@redhat.com>
120090         * modules/gethostname (License): Relicense: LGPL -> LGPLv2+.
120092 2008-10-27  Simon Josefsson  <simon@josefsson.org>
120094         * gnulib-tool (func_emit_tests_Makefile_am): Set EXEEXT in
120095         TESTS_ENVIRONMENT, for shell scripts that needs to call built
120096         programs.
120097         * tests/test-argp-2.sh: Use $EXEEXT when needed.
120099 2008-10-27  Simon Josefsson  <simon@josefsson.org>
120101         * lib/sys_stat.in.h (lstat): Fix declaration for mingw.
120103 2008-10-27  Bruno Haible  <bruno@clisp.org>
120105         * tests/test-lstat.c: Include <stdio.h>.
120107 2008-10-27  Simon Josefsson  <simon@josefsson.org>
120109         * modules/lstat-tests: New module.
120110         * tests/test-lstat.c: New file.
120112 2008-10-26  Jim Meyering  <meyering@redhat.com>
120114         * lib/mkdir.c (rpl_mkdir) [_WIN32...]: Mark mode as an unused parameter.
120116 2008-10-26  Simon Josefsson  <simon@josefsson.org>
120117             Bruno Haible  <bruno@clisp.org>
120119         Fix a clash between the type DATADIR on Windows and the macro DATADIR.
120120         * modules/configmake (Include): Add a note that the include must come
120121         after all system headers.
120122         * lib/javaversion.c: Include configmake.h after all other includes.
120124 2008-10-26  Bruno Haible  <bruno@clisp.org>
120126         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Set default of
120127         HAVE_STRUCT_RANDOM_DATA to 1.
120128         (gl_STDLIB_H): Simplify.
120130 2008-10-26  Simon Josefsson  <simon@josefsson.org>
120132         * m4/stdlib_h.m4: Check for struct random_data.  Initialize and
120133         substitute HAVE_STRUCT_RANDOM_DATA.
120134         * lib/stdlib.in.h [!HAVE_STRUCT_RANDOM_DATA]: Provide struct
120135         random_data.
120136         * modules/stdlib (Makefile.am): Substitute
120137         HAVE_STRUCT_RANDOM_DATA.
120139 2008-10-26  Simon Josefsson  <simon@josefsson.org>
120141         * doc/gnulib.texi (@copying): Use GFDLv1.2+.
120142         * doc/gnulib-intro.texi (Copyright): Likewise.
120144 2008-10-26  Simon Josefsson  <simon@josefsson.org>
120146         * doc/gnulib.texi (Header files): C++ fixes, based on Bruno's
120147         findings.
120149 2008-10-25  Ben Pfaff  <blp@cs.stanford.edu>
120150             Bruno Haible  <bruno@clisp.org>
120152         * lib/unistd.in.h: Include <winsock2.h>.
120153         (socket, connect,accept, bind, getpeername, getsockname, getsockopt,
120154         listen, recv, send, recvfrom, sendto, setsockopt, shutdown, select):
120155         Provide dummy declarations.
120156         (gethostname): Override.
120157         * lib/sys_socket.in.h (gethostname): Provide dummy declaration.
120158         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Invoke
120159         gl_PREREQ_SYS_H_WINSOCK2.
120160         * modules/gethostname (Files): Add m4/sys_socket_h.m4.
120161         * doc/posix-functions/gethostname.texi: More details.
120163 2008-10-25  Bruno Haible  <bruno@clisp.org>
120165         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
120166         gl_UNISTD_H_DEFAULTS, gl_SYS_IOCTL_H_DEFAULTS only if they exist.
120167         * modules/sys_socket (Files): Remove m4/unistd_h.m4, m4/sys_ioctl_h.m4.
120169         * lib/sys_socket.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); Move macro from
120170         here ...
120171         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); ... to here.
120172         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Remove invocation of
120173         gl_UNISTD_H_DEFAULTS.
120175 2008-10-25  Eric Blake  <ebb9@byu.net>
120177         signbit: avoid spurious compiler failure
120178         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Move non-constant
120179         declarations inside function.
120181 2008-10-24  Simon Josefsson  <simon@josefsson.org>
120182             Bruno Haible  <bruno@clisp.org>
120184         * lib/stdlib.in.h (@GNULIB_RANDOM_R@): Include stdint.h.
120185         * modules/random_r (Depends-on): Add stdint.
120187 2008-10-24  Bruno Haible  <bruno@clisp.org>
120189         * modules/intprops (License): Change to LGPLv2+, with approval by Paul
120190         Eggert.
120191         * modules/strerror (License): Likewise.
120193 2008-10-24  Jim Meyering  <meyering@redhat.com>
120195         sys_socket: fix typo that inhibited expansion of @GNULIB_SEND@
120196         * modules/sys_socket (Depends-on) [Depends-on]: Fix typo.
120198 2008-10-24  Eric Blake  <ebb9@byu.net>
120200         getgroups: fix compilation when getgroups is available
120201         * lib/getgroups.c (includes): Include <unistd.h> for getgroups,
120202         but with <config.h> override of getgroups disabled.
120204 2008-10-24  Simon Josefsson  <simon@josefsson.org>
120206         * doc/gnulib.texi (Header files): Add note about C++ problems.
120207         Explained by Bruno Haible <bruno@clisp.org>.
120209 2008-10-23  Bruno Haible  <bruno@clisp.org>
120211         Define a dummy SA_NODEFER macro on Interix.
120212         * lib/signal.in.h (SA_NODEFER): Define fallback.
120213         Reported by Aleksey Cheusov <cheusov@tut.by> via
120214         Thomas Klausner <wiz@netbsd.org> and Eric Blake.
120216 2008-10-23  Bruno Haible  <bruno@clisp.org>
120218         * modules/freadahead (License): Change to LGPLv2+.
120219         Suggested by Simon Josefsson.
120221 2008-10-23  Jim Meyering  <meyering@redhat.com>
120223         random_r: new module
120224         * modules/random_r: New file.
120225         * m4/random_r.m4: New file.
120226         * lib/random_r.c: New file, from glibc.
120227         * modules/random_r-tests: New file.
120228         * tests/test-random_r.c: New file.
120229         * lib/stdlib.in.h (srandom_r, initstate_r, setstate_r, random_r):
120230          Declare.
120231         (RAND_MAX): Define.
120232         * m4/stdlib_h.m4: Define and AC_SUBST GNULIB_RANDOM_R and HAVE_RANDOM_R.
120233         * modules/stdlib: Substitute them, too.
120234         * MODULES.html.sh (Extra functions based on POSIX:2001) [Misc]: Add it.
120235         * doc/glibc-functions/initstate_r.texi: Mention the new module.
120236         * doc/glibc-functions/random_r.texi: Likewise.
120237         * doc/glibc-functions/setstate_r.texi: Likewise.
120238         * doc/glibc-functions/srandom_r.texi: Likewise.
120239         * config/srclist.txt: Mention it.
120241 2008-10-23  David Lutterkort  <lutter@redhat.com>
120243         * modules/selinux-h: Search for LIB_SELINUX and mark it as a
120244         link requirement
120246 2008-10-23  Jim Meyering  <meyering@redhat.com>
120248         selinux-h: mark parameters of stub functions as intentionally unused
120249         * lib/se-selinux.in.h: Mark parameters as _UNUSED_PARAMETER_.
120250         * lib/se-context.in.h: Likewise.
120252 2008-10-22  Simon Josefsson  <simon@josefsson.org>
120254         * lib/sys_socket.in.h (FD_ISSET): Fix warnings under mingw.
120256 2008-10-22  Simon Josefsson  <simon@josefsson.org>
120258         * m4/getgroups.m4: Avoid invoking test with wrong parameters.
120260 2008-10-22  Eric Blake  <ebb9@byu.net>
120262         glthread/thread: avoid compiler warning
120263         * lib/glthread/thread.c (gl_thread_exit_func) [USE_WIN32_THREADS]:
120264         Add unreachable abort to silence compiler.
120266 2008-10-22  Eric Blake  <ebb9@byu.net>
120268         netdb: also supply struct addrinfo for cygwin 1.5.x
120269         * m4/netdb_h.m4 (gl_HEADER_NETDB): Check for incomplete header on
120270         older cygwin.
120271         * lib/netdb.in.h [!HAVE_STRUCT_ADDRINFO]: Also supply contents for
120272         cygwin.
120273         * doc/posix-headers/netdb.texi (netdb.h): Document this.
120275 2008-10-22  Bruno Haible  <bruno@clisp.org>
120277         * users.txt: Update entry about pspp.
120279 2008-10-21  Bruno Haible  <bruno@clisp.org>
120281         Simplification.
120282         * lib/sys_socket.in.h (_gl_close_fd_maybe_socket): Remove declaration.
120283         * lib/close.c (_gl_close_fd_maybe_socket): Make static.
120285         Simplification.
120286         * lib/ioctl.c (ioctl): Don't undefine.
120287         * lib/socket.c (socket): Don't undefine.
120289         Remove unused module indicator macros.
120290         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Don't define
120291         GNULIB_$1 as a C macro.
120293         * doc/posix-functions/close.texi: Undo last change.
120294         * doc/posix-functions/ioctl.texi: Merge the two paragraphs about
120295         Windows platforms.
120297 2008-10-21  Bruno Haible  <bruno@clisp.org>
120299         Add gethostname() declaration to <unistd.h>.
120300         * lib/unistd.in.h (gethostname): New declaration.
120301         * lib/gethostname.c: Include <unistd.h>.
120302         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Require
120303         gl_UNISTD_H_DEFAULTS. Set HAVE_GETHOSTNAME.
120304         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETHOSTNAME
120305         and HAVE_GETHOSTNAME.
120306         * modules/gethostname (Depends-on): Add unistd.
120307         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
120308         (Include): Specify <unistd.h>.
120309         * modules/unistd (Makefile.am): Substitute GNULIB_GETHOSTNAME and
120310         HAVE_GETHOSTNAME.
120311         * tests/test-gethostname.c: Include <unistd.h> first.
120313 2008-10-21  Bruno Haible  <bruno@clisp.org>
120315         * modules/poll-tests (Depends-on): Add sys_ioctl, ioctl.
120316         * modules/select-tests (Depends-on): Likewise.
120317         Reported by Simon Josefsson.
120319 2008-10-21  Simon Josefsson  <simon@josefsson.org>
120321         * lib/close.c: Add _gl_close_fd_maybe_socket from winsock.c.
120322         * lib/accept.c: New file, based on winsock.c.
120323         * lib/bind.c: New file, based on winsock.c.
120324         * lib/connect.c: New file, based on winsock.c.
120325         * lib/getpeername.c: New file, based on winsock.c.
120326         * lib/getsockname.c: New file, based on winsock.c.
120327         * lib/getsockopt.c: New file, based on winsock.c.
120328         * lib/ioctl.c: New file, based on winsock.c.
120329         * lib/listen.c: New file, based on winsock.c.
120330         * lib/recv.c: New file, based on winsock.c.
120331         * lib/recvfrom.c: New file, based on winsock.c.
120332         * lib/send.c: New file, based on winsock.c.
120333         * lib/sendto.c: New file, based on winsock.c.
120334         * lib/setsockopt.c: New file, based on winsock.c.
120335         * lib/shutdown.c: New file, based on winsock.c.
120336         * lib/socket.c: New file, based on winsock.c.
120337         * lib/w32sock.h: New file, based on winsock.c.
120338         * lib/winsock.c: Remove file.
120339         * modules/accept: Likewise.
120340         * modules/bind: Likewise.
120341         * modules/connect: Likewise.
120342         * modules/getpeername: Likewise.
120343         * modules/getsockname: Likewise.
120344         * modules/getsockopt: Likewise.
120345         * modules/ioctl: Likewise.
120346         * modules/listen: Likewise.
120347         * modules/recv: Likewise.
120348         * modules/recvfrom: Likewise.
120349         * modules/send: Likewise.
120350         * modules/sendto: Likewise.
120351         * modules/setsockopt: Likewise.
120352         * modules/shutdown: Likewise.
120353         * modules/socket: Use socket.c instead of winsock.c.
120354         * modules/sys_socket: Remove (unneeded?) dependency on winsock.c.
120355         * doc/posix-functions/accept.texi: Doc fix.
120356         * doc/posix-functions/bind.texi: Doc fix.
120357         * doc/posix-functions/close.texi: Doc fix.
120358         * doc/posix-functions/connect.texi: Doc fix.
120359         * doc/posix-functions/getpeername.texi: Doc fix.
120360         * doc/posix-functions/getsockname.texi: Doc fix.
120361         * doc/posix-functions/getsockopt.texi: Doc fix.
120362         * doc/posix-functions/ioctl.texi: Doc fix.
120363         * doc/posix-functions/listen.texi: Doc fix.
120364         * doc/posix-functions/recv.texi: Doc fix.
120365         * doc/posix-functions/recvfrom.texi: Doc fix.
120366         * doc/posix-functions/send.texi: Doc fix.
120367         * doc/posix-functions/sendto.texi: Doc fix.
120368         * doc/posix-functions/setsockopt.texi: Doc fix.
120369         * doc/posix-functions/shutdown.texi: Doc fix.
120370         * doc/posix-functions/socket.texi: Doc fix.
120372 2008-10-20  Bruno Haible  <bruno@clisp.org>
120374         Take into account the role of SIGABRT_COMPAT on Windows 2008.
120375         * lib/sigprocmask.c (SIGABRT_COMPAT, SIGABRT_COMPAT_MASK): New macros.
120376         (sigismember, sigaddset, sigdelset, sigfillset, rpl_signal): Handle it
120377         as an alias for SIGABRT.
120378         * lib/sigaction.c (SIGABRT_COMPAT): New macro.
120379         (sigaction): Map it to SIGABRT.
120380         Reported by Ramiro Polla <ramiro.polla@gmail.com> via Eric Blake.
120382 2008-10-20  Bruno Haible  <bruno@clisp.org>
120384         * lib/fts.c: Don't include lstat.h.
120385         * lib/openat.c: Include <sys/stat.h> instead of lstat.h.
120387         Move the lstat() declaration to <sys/stat.h>.
120388         * lib/lstat.h: Remove file.
120389         * lib/sys_stat.in.h: Add special invocation convention.
120390         (lstat): New declaration.
120391         * lib/lstat.c (orig_lstat): New function.
120392         (rpl_lstat): Use orig_lstat instead of lstat.
120393         * m4/lstat.m4 (gl_FUNC_LSTAT): Require gl_SYS_STAT_H_DEFAULTS and
120394         AC_C_INLINE. Set REPLACE_LSTAT.
120395         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LSTAT
120396         and REPLACE_LSTAT.
120397         * modules/lstat (Files): Remove lib/lstat.h.
120398         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
120399         (Include): Specify <sys/stat.h> instead of lstat.h.
120400         * modules/sys_stat (Makefile.am): Substitute GNULIB_LSTAT and
120401         REPLACE_LSTAT.
120402         * NEWS: Mention the change.
120404 2008-10-20  Bruno Haible  <bruno@clisp.org>
120406         * modules/posix_spawn-tests: New file.
120407         * tests/test-posix_spawn3.c: New file.
120409 2008-10-20  Bruno Haible  <bruno@clisp.org>
120411         * modules/posix_spawnp-tests (Depends-on): Add sys_wait.
120412         * tests/test-posix_spawn1.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
120413         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Remove fallback definitions.
120414         * tests/test-posix_spawn2.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
120415         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Likewise.
120417 2008-10-20  Bruno Haible  <bruno@clisp.org>
120419         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Test against another bug
120420         of posix_spawn on AIX 5.3.
120422 2008-10-20  Bruno Haible  <bruno@clisp.org>
120424         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Make the check on MacOS X.
120426 2008-10-20  Bruno Haible  <bruno@clisp.org>
120428         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Use AC_LANG_SOURCE instead
120429         of AC_LANG_PROGRAM.
120431 2008-10-20  Simon Josefsson  <simon@josefsson.org>
120433         * lib/netdb.in.h: Don't define GNU specific constants until they
120434         are supported or needed.  Reported by Bruno Haible
120435         <bruno@clisp.org>.
120437 2008-10-20  Simon Josefsson  <simon@josefsson.org>
120439         * lib/canon-host.c: Include netdb.h instead of getaddrinfo.h.
120441 2008-10-20  Simon Josefsson  <simon@josefsson.org>
120443         * lib/getaddrinfo.h: Remove file.
120444         * modules/getaddrinfo: Reflect move from getaddrinfo.h to netdb.h.
120445         * m4/getaddrinfo.m4: Call gl_HEADER_NETDB.  Don't check for netdb.h.
120446         * lib/netdb.in.h: Add declarations from getaddrinfo.h.
120447         * m4/netdb_h.m4: Initialize GNULIB_GETADDRINFO to 0.
120448         * modules/netdb: Substitute GNULIB_GETADDRINFO.
120449         * lib/getaddrinfo.c: Include netdb.h instead of getaddrinfo.h.
120450         * tests/test-getaddrinfo.c: Likewise.
120451         * lib/gai_strerror.c: Likewise.  Also drop HAVE_NETDB_H check.
120452         * NEWS: Mention change.
120454 2008-10-19  Bruno Haible  <bruno@clisp.org>
120456         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Remove unneeded code.
120458 2008-10-19  Bruno Haible  <bruno@clisp.org>
120460         * lib/wait-process.c: Include simply <sys/wait.h>.
120461         (waitpid, WTERMSIG, WCOREDUMP, WEXITSTATUS, WIFSIGNALED, WIFEXITED,
120462         WIFSTOPPED): Remove fallback definitions.
120463         * modules/wait-process (Depends-on): Add sys_wait.
120465         New module 'sys_wait'.
120466         * modules/sys_wait: New file.
120467         * lib/sys_wait.in.h: New file, partially copied from
120468         lib/wait-process.c.
120469         * m4/sys_wait_h.m4: New file.
120470         * doc/posix-headers/sys_wait.texi: Mention the new module.
120472 2008-10-19  Bruno Haible  <bruno@clisp.org>
120474         * m4/wait-process.m4 (gl_WAIT_PROCESS): Remove test for unistd.h.
120476 2008-10-19  Bruno Haible  <bruno@clisp.org>
120478         Assume that waitpid() fills an 'int' status, not a 'union wait'.
120479         * lib/wait-process.c (WAIT_T): Remove type.
120480         (WTERMSIG, WCOREDUMP, WEXITSTATUS): Define fallbacks using bit masks.
120481         (wait_subprocess): Update.
120483 2008-10-19  Bruno Haible  <bruno@clisp.org>
120485         New module 'atoll'.
120486         * modules/atoll: New file.
120487         * lib/stdlib.in.h (atoll): New declaration.
120488         * lib/atoll.c: New file, from glibc with modifications.
120489         * m4/atoll.m4: New file.
120490         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_ATOLL,
120491         HAVE_ATOLL.
120492         * modules/stdlib (Makefile.am): Substitute GNULIB_ATOLL, HAVE_ATOLL.
120493         * doc/posix-functions/atoll.texi: Mention the new module.
120495 2008-10-19  Bruno Haible  <bruno@clisp.org>
120497         Add strtoull() declaration to <stdlib.h>.
120498         * lib/stdlib.in.h (strtoull): New declaration.
120499         * m4/strtoull.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
120500         Set HAVE_STRTOULL.
120501         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOULL,
120502         HAVE_STRTOULL.
120503         * modules/strtoull (Depends-on): Add stdlib.
120504         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
120505         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOULL,
120506         HAVE_STRTOULL.
120508 2008-10-19  Bruno Haible  <bruno@clisp.org>
120510         Add strtoll() declaration to <stdlib.h>.
120511         * lib/stdlib.in.h (strtoll): New declaration.
120512         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
120513         Set HAVE_STRTOLL.
120514         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOLL,
120515         HAVE_STRTOLL.
120516         * modules/strtoll (Depends-on): Add stdlib.
120517         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
120518         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOLL, HAVE_STRTOLL.
120520 2008-10-19  Bruno Haible  <bruno@clisp.org>
120522         * modules/bcopy (Depends-on): Add strings.
120523         (Include): Specify <strings.h>.
120525 2008-10-19  Bruno Haible  <bruno@clisp.org>
120527         * doc/posix-functions/atexit.texi: Update doc regarding mingw.
120529 2008-10-19  Bruno Haible  <bruno@clisp.org>
120531         * lib/openat-die.c (openat_save_fail, openat_restore_fail): Rename
120532         the parameter from 'errno' to 'errnum'. Fixes a compilation error on
120533         mingw.
120535 2008-10-19  Bruno Haible  <bruno@clisp.org>
120537         * lib/atanl.c: Don't include isnanl.h.
120538         * lib/cosl.c: Likewise.
120539         * lib/ldexpl.c: Likewise.
120540         * lib/logl.c: Likewise.
120541         * lib/sinl.c: Likewise.
120542         * lib/sqrtl.c: Likewise.
120543         * lib/tanl.c: Likewise.
120545         Move the isnanf(), isnand(), isnanl() declarations to <math.h>.
120546         * lib/isnanf.h: Remove file.
120547         * lib/isnand.h: Remove file.
120548         * lib/isnanl.h: Remove file.
120549         * lib/math.in.h: Include the contents of lib/isnanf.h, lib/isnand.h,
120550         lib/isnanl.h. Use HAVE_ISNANF, HAVE_ISNAND, HAVE_ISNANL as substituted
120551         macros.
120552         * m4/isnanf.m4 (gl_FUNC_ISNANF): Require gl_MATH_H_DEFAULTS. Set
120553         HAVE_ISNANF, don't define it as a C macro.
120554         * m4/isnand.m4 (gl_FUNC_ISNAND): Require gl_MATH_H_DEFAULTS. Set
120555         HAVE_ISNAND, don't define it as a C macro.
120556         * m4/isnanl.m4 (gl_FUNC_ISNANL): Require gl_MATH_H_DEFAULTS. Set
120557         HAVE_ISNANL, don't define it as a C macro.
120558         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_ISNAN[FDL] and
120559         HAVE_ISNAN[FDL].
120560         * modules/isnanf (Files): Remove lib/isnanf.h.
120561         (Depends-on): Add math.
120562         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
120563         (Include): Specify <math.h> instead of isnanf.h.
120564         * modules/isnand (Files): Remove lib/isnand.h.
120565         (Depends-on): Add math.
120566         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
120567         (Include): Specify <math.h> instead of isnand.h.
120568         * modules/isnanl (Files): Remove lib/isnanl.h.
120569         (Depends-on): Add math.
120570         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
120571         (Include): Specify <math.h> instead of isnanl.h.
120572         * modules/math (Makefile.am): Substitute GNULIB_ISNAN[FDL] and
120573         HAVE_ISNAN[FDL].
120574         * tests/test-isnanf.c: Include <math.h> instead of isnanf.h.
120575         * tests/test-isnand.c: Include <math.h> instead of isnand.h.
120576         * tests/test-isnanl.c: Include <math.h> instead of isnanl.h.
120577         * NEWS: Mention the change.
120579 2008-10-18  Bruno Haible  <bruno@clisp.org>
120581         Add getusershell(), setusershell(), endusershell() declarations to
120582         <unistd.h>.
120583         * lib/unistd.in.h (getusershell, setusershell, endusershell): New
120584         declarations.
120585         * lib/getusershell.c: Include unistd.h.
120586         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): Require
120587         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
120588         HAVE_GETUSERSHELL.
120589         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETUSERSHELL
120590         and HAVE_GETUSERSHELL.
120591         * modules/getusershell (Depends-on): Add unistd, extensions.
120592         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
120593         (Include): Specify <unistd.h>.
120594         * modules/unistd (Makefile.am): Substitute GNULIB_GETUSERSHELL and
120595         HAVE_GETUSERSHELL.
120597 2008-10-18  Bruno Haible  <bruno@clisp.org>
120599         Add a getloadavg() declaration to <stdlib.h>.
120600         * lib/stdlib.in.h; Include <sys/loadavg.h> when needed for the
120601         getloadavg declaration.
120602         (getloadavg): New declaration.
120603         * lib/getloadavg.c: Include <stdlib.h> first.
120604         * m4/getloadavg.m4 (gl_GETLOADAVG): Require gl_STDLIB_H_DEFAULTS and
120605         AC_USE_SYSTEM_EXTENSIONS. Test whether sys/loadavg.h exists. Set
120606         HAVE_SYS_LOADAVG_H and HAVE_DECL_GETLOADAVG.
120607         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_GETLOADAVG,
120608         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
120609         * modules/getloadavg (Depends-on): Add stdlib, extensions.
120610         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
120611         (Include): Specify <stdlib.h>.
120612         * modules/stdlib (Makefile.am): Substitute GNULIB_GETLOADAVG,
120613         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
120615 2008-10-18  Bruno Haible  <bruno@clisp.org>
120617         * lib/dirchownmod.c: Don't include lchmod.h.
120619         Move the lchmod() declaration to <sys/stat.h>.
120620         * lib/lchmod.h: Remove file.
120621         * lib/sys_stat.in.h: Add placeholder for GL_LINK_WARNING.
120622         (lchmod): New declaration, moved here from lib/lchown.h.
120623         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Require gl_SYS_STAT_H_DEFAULTS and
120624         AC_USE_SYSTEM_EXTENSIONS. Set HAVE_LCHMOD.
120625         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LCHMOD
120626         and HAVE_LCHMOD.
120627         * modules/lchmod (Files): Remove lib/lchmod.h.
120628         (Depends-on): Add sys_stat, extensions.
120629         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
120630         (Include): Specify <sys/stat.h> instead of lchmod.h.
120631         * modules/sys_stat (Depends-on): Add link-warning.
120632         (Makefile.am): Substitute GNULIB_LCHMOD, HAVE_LCHMOD, and the
120633         definition of GL_LINK_WARNING.
120634         * NEWS: Mention the change.
120636 2008-10-18  Bruno Haible  <bruno@clisp.org>
120638         * lib/fchdir.c: Don't include dirfd.h.
120639         * lib/fts.c: Likewise.
120640         * lib/getcwd.c: Likewise.
120641         * lib/glob.c: Likewise.
120643         Move the dirfd() declaration to <dirent.h>.
120644         * lib/dirfd.h: Remove file.
120645         * lib/dirent.in.h: Add placeholder for GL_LINK_WARNING.
120646         (dirfd): New declaration.
120647         * lib/dirfd.c: Include <dirent.h> instead of dirfd.h.
120648         * m4/dirfd.m4 (gl_FUNC_DIRFD): Require gl_DIRENT_H_DEFAULTS and
120649         AC_USE_SYSTEM_EXTENSIONS. Invoke gl_REPLACE_DIRENT_H. Set
120650         HAVE_DECL_DIRFD.
120651         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_DIRFD and
120652         HAVE_DECL_DIRFD.
120653         * modules/dirfd (Files): Remove lib/dirfd.h.
120654         (Depends-on): Add dirent, extensions.
120655         (configure.ac): Invoke gl_DIRENT_MODULE_INDICATOR.
120656         (Include): Specify <dirent.h> instead of dirfd.h.
120657         * modules/dirent (Depends-on): Add link-warning.
120658         (Makefile.am): Substitute GNULIB_DIRFD, HAVE_DECL_DIRFD, and
120659         definition of GL_LINK_WARNING.
120660         * NEWS: Mention the change.
120662 2008-10-18  Bruno Haible  <bruno@clisp.org>
120664         Move the euidaccess() declaration to <unistd.h>.
120665         * lib/euidaccess.h: Remove file.
120666         * lib/unistd.in.h (euidaccess): New declaration.
120667         * lib/euidaccess.c: Don't include euidaccess.h.
120668         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Require gl_UNISTD_H_DEFAULTS.
120669         Don't check whether euidaccess is declared. Set HAVE_EUIDACCESS.
120670         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_EUIDACCESS
120671         and HAVE_EUIDACCESS.
120672         * modules/euidaccess (Files): Remove lib/euidaccess.h.
120673         (Depends-on): Add unistd.
120674         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
120675         (Include): Specify <unistd.h> instead of euidaccess.h.
120676         * modules/unistd (Makefile.am): Substitute GNULIB_EUIDACCESS and
120677         HAVE_EUIDACCESS.
120678         * NEWS: Mention the change.
120680 2008-10-18  Bruno Haible  <bruno@clisp.org>
120682         * lib/xgetdomainname.c: Include <unistd.h> instead of getdomainname.h.
120684         Move the getdomainname() declaration to <unistd.h>.
120685         * lib/getdomainname.h: Remove file.
120686         * lib/unistd.in.h (getdomainname): New declaration.
120687         * lib/getdomainname.c: Include <unistd.h> instead of getdomainname.h.
120688         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Require
120689         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
120690         HAVE_GETDOMAINNAME.
120691         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
120692         GNULIB_GETDOMAINNAME and HAVE_GETDOMAINNAME.
120693         * modules/getdomainname (Files): Remove lib/getdomainname.h.
120694         (Depends-on): Add unistd, extensions.
120695         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
120696         (Includes): Specify <unistd.h> instead of getdomainname.h.
120697         * modules/unistd (Makefile.am): Substitute GNULIB_GETDOMAINNAME and
120698         HAVE_GETDOMAINNAME.
120699         * NEWS: Mention the change.
120701 2008-10-18  Bruno Haible  <bruno@clisp.org>
120703         * modules/dirent: New file.
120704         * m4/dirent_h.m4: New file.
120705         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_DIRENT_H_DEFAULTS.
120706         Invoke gl_REPLACE_DIRENT_H. Don't assign DIRENT_H directly.
120707         * modules/fchdir (Files): Remove lib/dirent.in.h.
120708         (Depends-on): Add dirent.
120709         (Makefile.am): Move rules to modules/dirent.
120710         * doc/posix-headers/dirent.texi: Mention the new module.
120712 2008-10-18  Bruno Haible  <bruno@clisp.org>
120714         Avoid -Wunused-parameter warnings in public gnulib header files.
120715         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _UNUSED_PARAMETER_ as a
120716         macro.
120717         * lib/unistr.h (u32_mbtouc_unsafe, u32_mbtouc): Use it.
120719 2008-10-18  Bruno Haible  <bruno@clisp.org>
120721         * doc/glibc-functions/dirfd.texi: Mention the module 'dirfd'.
120722         * doc/glibc-functions/error.texi: Mention the module 'error'.
120723         * doc/glibc-functions/euidaccess.texi: Mention the module 'euidaccess'.
120724         * doc/glibc-functions/getdomainname.texi: Mention the module
120725         'getdomainname'.
120726         * doc/glibc-functions/getloadavg.texi: Mention the module 'getloadavg'.
120727         * doc/glibc-functions/getpagesize.texi: Mention the module
120728         'getpagesize'.
120729         * doc/glibc-functions/getusershell.texi: Mention the module
120730         'getusershell'.
120731         * doc/glibc-functions/isnanl.texi: Mention the module 'isnanl'.
120732         * doc/glibc-functions/lchmod.texi: Mention the module 'lchmod'.
120733         * doc/glibc-functions/mempcpy.texi: Mention the module 'mempcpy'.
120734         * doc/glibc-functions/memrchr.texi: Mention the module 'memrchr'.
120735         * doc/glibc-functions/mkdtemp.texi: Mention the module 'mkdtemp'.
120736         * doc/glibc-functions/rpmatch.texi: Mention the module 'rpmatch'.
120737         * doc/glibc-functions/stpcpy.texi: Mention the module 'stpcpy'.
120738         * doc/glibc-functions/stpncpy.texi: Mention the module 'stpncpy'.
120739         * doc/glibc-functions/strchrnul.texi: Mention the module 'strchrnul'.
120740         * doc/glibc-functions/strndup.texi: Mention the module 'strndup'.
120741         * doc/glibc-functions/strnlen.texi: Mention the module 'strnlen'.
120742         * doc/glibc-functions/strsep.texi: Mention the module 'strsep'.
120743         * doc/glibc-functions/timegm.texi: Mention the module 'timegm'.
120744         * doc/glibc-functions/vasprintf.texi: Mention the module 'vasprintf'.
120746 2008-10-17  Bruno Haible  <bruno@clisp.org>
120748         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): On platforms other than
120749         HP-UX and IRIX, use -0.0L.
120750         * tests/test-ceill.c (minus_zero): Likewise.
120751         * tests/test-floorl.c (minus_zero): Likewise.
120752         * tests/test-frexpl.c (minus_zero): Likewise.
120753         * tests/test-isnan.c (minus_zerol): Likewise.
120754         * tests/test-isnanl.h (minus_zero): Likewise.
120755         * tests/test-ldexpl.c (minus_zero): Likewise.
120756         * tests/test-roundl.c (minus_zero): Likewise.
120757         * tests/test-signbit.c (minus_zerol): Likewise.
120758         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
120759         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
120760         * tests/test-truncl.c (minus_zero): Likewise.
120761         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
120762         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
120763         Reported by Markus Armbruster <armbru@redhat.com> via Jim Meyering
120764         and by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
120766 2008-10-17  Bruno Haible  <bruno@clisp.org>
120768         Avoid gcc warnings because of #pragma GCC system_header on older gcc.
120769         * lib/arpa_inet.in.h: Encloses reference to PRAGMA_SYSTEM_HEADER so
120770         that it gets activated only for gcc >= 3.0.
120771         * lib/dirent.in.h: Likewise.
120772         * lib/errno.in.h: Likewise.
120773         * lib/fcntl.in.h: Likewise.
120774         * lib/float.in.h: Likewise.
120775         * lib/iconv.in.h: Likewise.
120776         * lib/inttypes.in.h: Likewise.
120777         * lib/locale.in.h: Likewise.
120778         * lib/math.in.h: Likewise.
120779         * lib/netdb.in.h: Likewise.
120780         * lib/netinet_in.in.h: Likewise.
120781         * lib/search.in.h: Likewise.
120782         * lib/signal.in.h: Likewise.
120783         * lib/spawn.in.h: Likewise.
120784         * lib/stdarg.in.h: Likewise.
120785         * lib/stdint.in.h: Likewise.
120786         * lib/stdio.in.h: Likewise.
120787         * lib/stdlib.in.h: Likewise.
120788         * lib/string.in.h: Likewise.
120789         * lib/strings.in.h: Likewise.
120790         * lib/sys_file.in.h: Likewise.
120791         * lib/sys_ioctl.in.h: Likewise.
120792         * lib/sys_select.in.h: Likewise.
120793         * lib/sys_socket.in.h: Likewise.
120794         * lib/sys_stat.in.h: Likewise.
120795         * lib/sys_time.in.h: Likewise.
120796         * lib/sysexits.in.h: Likewise.
120797         * lib/time.in.h: Likewise.
120798         * lib/unistd.in.h: Likewise.
120799         * lib/wchar.in.h: Likewise.
120800         * lib/wctype.in.h: Likewise.
120801         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
120803 2008-10-17  Jim Meyering  <meyering@redhat.com>
120805         ignore-value: don't depend on inline module
120806         * modules/ignore-value (Depends-on): Remove 'inline'.
120807         (configure.ac): Instead, add AC_REQUIRE([AC_C_INLINE]) here.
120808         Suggestion from Bruno Haible.
120810 2008-10-17  Bruno Haible  <bruno@clisp.org>
120812         New implementation of condition variables for Win32.
120813         * lib/glthread/cond.h (struct gl_waitqueue_link): New type.
120814         (gl_linked_waitqueue_t): New type.
120815         (gl_cond_t): Use it.
120816         * lib/glthread/cond.c (struct gl_waitqueue_element): New type.
120817         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_remove,
120818         gl_waitqueue_notify_first, gl_waitqueue_notify_all): New functions.
120819         (glthread_cond_init_func, glthread_cond_wait_func,
120820         glthread_cond_timedwait_func, glthread_cond_signal_func,
120821         glthread_cond_broadcast_func, glthread_cond_destroy_func):
120822         Reimplemented on the basis of gl_linked_waitqueue_t.
120823         * lib/glthread/lock.h (gl_carray_waitqueue_t): Renamed from
120824         gl_waitqueue_t.
120825         (gl_rwlock_t): Update.
120826         * lib/glthread/lock.c (gl_waitqueue_t): Alias to gl_carray_waitqueue_t.
120828 2008-10-17  Simon Josefsson  <simon@josefsson.org>
120830         * modules/recvfrom (Depends-on): Add dependency on getpeername.
120831         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
120833 2008-10-17  Jim Meyering  <meyering@redhat.com>
120835         ignore-value: new module
120836         * modules/ignore-value: New file.
120837         * lib/ignore-value.h: New file.
120838         * MODULES.html.sh (Compiler warning management): New section,
120839         just for this module.  More to come.
120841 2008-10-16  Paul Eggert  <eggert@cs.ucla.edu>
120843         open-safer.c: avoid 'signed and unsigned in conditional...' warning
120844         * lib/open-safer.c (open_safer): Use an "if/else" statement in place
120845         of the ternary operator.  Reported by Reuben Thomas <rrt@sc3d.org>.
120847 2008-10-16  Jim Meyering  <meyering@redhat.com>
120849         openat-die.c: avoid 'no previous prototype' warning
120850         * lib/openat-die.c: Include "openat.h".
120851         Reported by Reuben Thomas <rrt@sc3d.org>.
120853 2008-10-16  Simon Josefsson  <simon@josefsson.org>
120855         * m4/netdb_h.m4: Assume that if netdb.h exists, it works.
120856         * lib/netdb.in.h: Fix typo.
120857         Reported by Bruno Haible  <bruno@clisp.org>
120859         * lib/netdb.in.h: Include sys/socket.h for platforms without
120860         netdb.h, to get structures like hostent on MinGW.
120861         * modules/netdb (Depends-on): Add sys_socket.
120863 2008-10-15  Simon Josefsson  <simon@josefsson.org>
120865         * modules/netdb, modules/netdb-tests: New file.
120866         * m4/netdb_h.m4: New file.
120867         * lib/netdb.in.h: Add, currently just an empty file pending
120868         definitions.
120869         * tests/test-netdb.c: New file.
120870         * doc/posix-headers/netdb.texi: Mention that we replace it if
120871         needed.
120872         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
120873         netdb.
120875 2008-10-15  Simon Josefsson  <simon@josefsson.org>
120877         * doc/gnulib.texi (Getaddrinfo and WINVER): Sync documentation
120878         with code.
120880 2008-10-13  Bruno Haible  <bruno@clisp.org>
120882         * lib/glthread/cond.c (glthread_cond_wait_func,
120883         glthread_cond_timedwait_func): Add a comment.
120885 2008-10-13  Yoann Vandoorselaere  <yoann@prelude-ids.org>
120887         * tests/test-poll.c: Include <sys/ioctl.h>, for ioctl().
120888         * tests/test-select.c: Likewise,
120890 2008-10-13  Bruno Haible  <bruno@clisp.org>
120892         * lib/glthread/cond.c (glthread_cond_wait_func,
120893         glthread_cond_timedwait_func): Fix variable name.
120894         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
120896 2008-10-13  Paolo Bonzini  <bonzini@gnu.org>
120898         fix getaddrinfo emulation for systems with struct sockaddr.sa_len
120899         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Detect
120900         struct sockaddr.sa_len.
120901         * lib/getaddrinfo.c (getaddrinfo): Set it if appropriate.
120903 2008-10-13  Simon Josefsson  <simon@josefsson.org>
120905         * build-aux/pmccabe2html: Add css and css_url parameters.
120907 2008-10-12  Bruno Haible  <bruno@clisp.org>
120909         * tests/test-sameacls.c (main) [AIX]: Clear type argument before
120910         calling aclx_get.
120911         Reported by Rainer Tammer <tammer@tammer.net>.
120913 2008-10-12  Bruno Haible  <bruno@clisp.org>
120915         Use msvcrt aware primitives for creation/termination of Win32 threads.
120916         * lib/glthread/thread.c: Include <process.h>.
120917         (glthread_create_func): Use _beginthreadex instead of CreateThread.
120918         (wrapper_func): Update signature.
120919         (gl_thread_exit_func): Use _endthreadex instead of EndThread.
120921 2008-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
120922             Bruno Haible  <bruno@clisp.org>
120924         Provide a Win32 implementation of the 'cond' module.
120925         * lib/glthread/cond.h [USE_WIN32]: New implementation.
120926         * lib/glthread/cond.c (glthread_cond_init_func,
120927         glthread_cond_wait_func, glthread_cond_timedwait_func,
120928         glthread_cond_signal_func, glthread_cond_broadcast_func,
120929         glthread_cond_destroy_func) [USE_WIN32]: New functions.
120930         * modules/cond (Dependencies): Add gettimeofday.
120932 2008-10-11  Bruno Haible  <bruno@clisp.org>
120934         Make sleep work on older versions of mingw.
120935         * m4/sleep.m4 (gl_FUNC_SLEEP): Test whether 'sleep' is declared, not
120936         only whether it exists.
120937         * doc/posix-functions/sleep.texi: Mention the problem with older
120938         versions of mingw.
120940 2008-10-11  Bruno Haible  <bruno@clisp.org>
120942         New module 'shutdown'.
120943         * modules/shutdown: New file.
120944         * lib/sys_socket.in.h (shutdown): New declaration.
120945         * lib/winsock.c (shutdown): New function.
120946         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
120947         GNULIB_SHUTDOWN.
120948         * modules/sys_socket (Makefile.am): Substitute GNULIB_SHUTDOWN.
120949         * doc/posix-functions/shutdown.texi: Document the new module.
120951 2008-10-11  Jim Meyering  <meyering@redhat.com>
120953         * lib/fclose.c: Fix typo in comment: s/close/fclose/.
120955 2008-10-11  Bruno Haible  <bruno@clisp.org>
120957         New module 'fclose'.
120958         * modules/fclose: New file.
120959         * lib/stdio.in.h (fclose): New declaration.
120960         * lib/fclose.c: New file.
120961         * m4/fclose.m4: New file.
120962         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FCLOSE,
120963         REPLACE_FCLOSE.
120964         * m4/close.m4 (gl_REPLACE_CLOSE): Invoke gl_REPLACE_FCLOSE.
120965         * modules/stdio (Makefile.am): Substitute GNULIB_FCLOSE,
120966         REPLACE_FCLOSE.
120967         * modules/close (Depends-on): fclose.
120968         * doc/posix-functions/fclose.texi: Mention the problem on Windows.
120970 2008-10-11  Bruno Haible  <bruno@clisp.org>
120972         * lib/winsock.c (_gl_close_fd_maybe_socket): If closesocket fails,
120973         set errno and don't call _close.
120975 2008-10-10  Bruno Haible  <bruno@clisp.org>
120977         * lib/copy-acl.c (qcopy_acl) [CYGWIN]: Call chmod before setting the
120978         ACL, not afterwards. Fixes test failure on Cygwin.
120980 2008-10-09  Ben Pfaff  <blp@gnu.org>
120982         * build-aux/announce-gen: Fix gnulib version related part of usage
120983         message.  Die with a useful error message if no tarballs are
120984         found.
120986 2008-10-10  Jim Meyering  <meyering@redhat.com>
120988         bootstrap: use git's --depth=N option only if it's supported
120989         * build-aux/bootstrap: Work with git-1.4.4.4, which does not
120990         recognize the --depth option.  Reported by Pádraig Brady.
120992 2008-10-09  Bruno Haible  <bruno@clisp.org>
120994         New module 'ioctl'.
120995         * modules/ioctl: New file.
120996         * lib/sys_socket.in.h (ioctl): Remove declaration.
120997         * lib/winsock.c: Include <sys/ioctl.h>.
120998         (rpl_ioctl): Define only of the gnulib module 'ioctl' is present.
120999         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
121000         gl_SYS_IOCTL_H_DEFAULTS. Set also SYS_IOCTL_H_HAVE_WINSOCK2_H.
121001         * modules/sys_socket (Files): Add m4/sys_ioctl_h.m4.
121002         * doc/posix-functions/ioctl.texi: Mention the new module.
121004 2008-10-09  Bruno Haible  <bruno@clisp.org>
121006         New module 'sys_ioctl'.
121007         * lib/sys_ioctl.in.h: New file.
121008         * m4/sys_ioctl_h.m4: New file.
121009         * modules/sys_ioctl: New file.
121010         * doc/glibc-headers/sys_ioctl.texi: Mention the new module.
121012 2008-10-09  Bruno Haible  <bruno@clisp.org>
121014         * lib/sys_socket.in.h (ioctl): Make signature POSIX compliant.
121015         * lib/winsock.c: Include <stdarg.h>.
121016         (rpl_ioctl): Change to second argument 'int' and then varargs.
121018 2008-10-09  Bruno Haible  <bruno@clisp.org>
121020         * m4/close.m4 (gl_FUNC_CLOSE): Arrange to replace the close() function
121021         when the sys_socket module is present and the system has <winsock2.h>.
121023 2008-10-09  Bruno Haible  <bruno@clisp.org>
121025         * doc/posix-functions/close.texi: Mention module 'close' instead of
121026         module 'sys_socket'.
121028 2008-10-09  Bruno Haible  <bruno@clisp.org>
121030         * doc/glibc-headers/sys_ioctl.texi: New file.
121031         * doc/gnulib.texi: Include it.
121033 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
121034             Bruno Haible  <bruno@clisp.org>
121036         Combine the two replacements of 'close'.
121037         * lib/sys_socket.in.h (close): Define to a reminder to include
121038         <unistd.h>.
121039         (_gl_close_fd_maybe_socket): New declaration.
121040         (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): New macro.
121041         * lib/winsock.c (close): Remove undefinition.
121042         (_gl_close_fd_maybe_socket): Renamed from rpl_close. Define only when
121043         needed for the gnulib module 'close'.
121044         * lib/unistd.in.h (close): If the gnulib module 'close' is not used,
121045         define to an error symbol or to a warning, if suitable.
121046         * lib/close.c: Include <sys/socket.h>.
121047         (rpl_close): Invoke _gl_close_fd_maybe_socket when gnulib defines it.
121048         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Set also
121049         UNISTD_H_HAVE_WINSOCK2_H.
121050         (gl_SYS_SOCKET_H_DEFAULTS): Require gl_UNISTD_H_DEFAULTS.
121051         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
121052         UNISTD_H_HAVE_WINSOCK2_H.
121053         * modules/sys_socket (Files): Add m4/unistd_h.m4.
121054         (configure.ac): Set a module indicator.
121055         (Makefile.am): Substitute GNULIB_CLOSE.
121056         * modules/unistd (Makefile.am): Substitute UNISTD_H_HAVE_WINSOCK2_H.
121057         * modules/poll-tests (Depends-on): Add close.
121058         * modules/select-tests (Depends-on): Likewise.
121060 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
121061             Bruno Haible  <bruno@clisp.org>
121063         New module 'close'.
121064         * modules/close: New file.
121065         * lib/unistd.in.h (close): Move declaration out of the
121066         FCHDIR_REPLACEMENT scope.
121067         (_gl_unregister_fd): New declaration.
121068         * lib/close.c: New file.
121069         * lib/fchdir.c (rpl_close): Remove function.
121070         * m4/close.m4: New file.
121071         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
121072         close.
121073         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_CLOSE and
121074         REPLACE_CLOSE.
121075         * modules/unistd (Makefile.am): Substitute GNULIB_CLOSE and
121076         REPLACE_CLOSE.
121077         * modules/fchdir (Depends-on): Add close.
121079 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
121080             Bruno Haible  <bruno@clisp.org>
121082         * lib/fcntl.in.h (open): Simplify conditionals.
121083         (_gl_register_fd): New declaration.
121084         * lib/fchdir.c (rpl_open): Remove function.
121085         * lib/open.c: When FCHDIR_REPLACEMENT is defined, compile the file
121086         also.
121087         (open): When FCHDIR_REPLACEMENT is defined, invoke _gl_register_fd.
121088         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
121089         open.
121091 2008-10-09  Jim Meyering  <meyering@redhat.com>
121093         GNUmakefile: use the more name-space-friendly "_version"
121094         * top/GNUmakefile (_dummy): Update.
121095         (_version): Rename from "version".
121097 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
121098             Bruno Haible  <bruno@clisp.org>
121100         * lib/fchdir.c (_gl_unregister_fd): New functions, extracted from
121101         rpl_close.
121102         (_gl_register_fd): New function, extracted from rpl_open.
121103         (rpl_close, rpl_closedir): Use _gl_unregister_fd.
121104         (rpl_open, rpl_opendir): Use _gl_register_fd.
121106 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
121108         Fix organization of 'open' replacement.
121109         * m4/open.m4 (gl_REPLACE_OPEN): New macro.
121110         (gl_FUNC_OPEN): Use it.
121111         (gl_PREREQ_OPEN): Add a : to make the body non-empty.
121113 2008-10-08  Bruno Haible  <bruno@clisp.org>
121115         * modules/getdate-tests (test_getdata_LDADD): Add LIBINTL.
121117 2008-10-08  Simon Josefsson  <simon@josefsson.org>
121119         * m4/sys_socket_h.m4: Don't AC_LIBOBJ(winsock).  The file is
121120         AC_LIBOBJ'ed by each gnulib module that needs it (e.g., socket,
121121         listen).
121123 2008-10-08  Eric Blake  <ebb9@byu.net>
121125         GNUmakefile: add 'make version' target
121126         * top/GNUmakefile (_curr-ver): Split version update rules...
121127         (version): ...into a target.
121129 2008-10-07  Bruno Haible  <bruno@clisp.org>
121131         Use a more portable replacement expression for -0.0L.
121132         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Use -LDBL_MIN * LDBL_MIN
121133         instead of -0.0L. Fix m4 quotation.
121135         * tests/test-signbit.c: Include <float.h>.
121136         (minus_zero): New variable.
121137         (test_signbitl): Use minus_zero instead of -zero.
121138         * modules/signbit-tests (Depends-on): Add float.
121140         * tests/test-ceill.c: Include <float.h>.
121141         (zero): Remove variable.
121142         (minus_zero): New variable.
121143         (main): Use minus_zero instead of -zero.
121144         * modules/ceill-tests (Depends-on): Add float.
121146         * tests/test-floorl.c: Include <float.h>.
121147         (zero): Remove variable.
121148         (minus_zero): New variable.
121149         (main): Use minus_zero instead of -zero.
121150         * modules/floorl-tests (Depends-on): Add float.
121152         * tests/test-roundl.c: Include <float.h>.
121153         (zero): Remove variable.
121154         (minus_zero): New variable.
121155         (main): Use minus_zero instead of -zero.
121156         * modules/roundl-tests (Depends-on): Add float.
121158         * tests/test-truncl.c: Include <float.h>.
121159         (zero): Remove variable.
121160         (minus_zero): New variable.
121161         (main): Use minus_zero instead of -zero.
121162         * modules/truncl-tests (Depends-on): Add float.
121164         * tests/test-frexpl.c (zero): Remove variable.
121165         (minus_zero): New variable.
121166         (main): Use minus_zero instead of -zero.
121167         * modules/frexpl-tests (Depends-on): Add float.
121169         * tests/test-isnan.c (zerol): Remove variable.
121170         (minus_zerol): New variable.
121171         (test_long_double): Use minus_zerol instead of -zerol.
121172         * modules/isnan-tests (Depends-on): Add float.
121174         * tests/test-isnanl.h (zero): Remove variable.
121175         (minus_zero): New variable.
121176         (main): Use minus_zero instead of -zero.
121177         * modules/isnanl-nolibm-tests (Depends-on): Add float.
121178         * modules/isnanl-tests (Depends-on): Add float.
121180         * tests/test-ldexpl.c (zero): Remove variable.
121181         (minus_zero): New variable.
121182         (main): Use minus_zero instead of -zero.
121183         * modules/ldexpl-tests (Depends-on): Add float.
121185         * tests/test-snprintf-posix.h (zerol): Remove variable.
121186         (minus_zerol): New variable.
121187         (test_function): Use minus_zerol instead of -zerol.
121188         * modules/snprintf-posix-tests (Depends-on): Add float.
121189         * modules/vsnprintf-posix-tests (Depends-on): Add float.
121191         * tests/test-sprintf-posix.h (zerol): Remove variable.
121192         (minus_zerol): New variable.
121193         (test_function): Use minus_zerol instead of -zerol.
121194         * modules/sprintf-posix-tests (Depends-on): Add float.
121195         * modules/vsprintf-posix-tests (Depends-on): Add float.
121197         * tests/test-vasnprintf-posix.c (zerol): Remove variable.
121198         (minus_zerol): New variable.
121199         (test_function): Use minus_zerol instead of -zerol.
121200         * modules/vasnprintf-posix-tests (Depends-on): Add float.
121202         * tests/test-vasprintf-posix.c (zerol): Remove variable.
121203         (minus_zerol): New variable.
121204         (test_function): Use minus_zerol instead of -zerol.
121205         * modules/vasprintf-posix-tests (Depends-on): Add float.
121207 2008-10-07  Simon Josefsson  <simon@josefsson.org>
121209         * MODULES.html.sh (Support for building documentation): Mention
121210         pmccabe2html.  Sort entries.
121212         Add pmccabe2html module, from gnupdf.
121213         * build-aux/pmccabe.css: New file.
121214         * build-aux/pmccabe2html: New file.
121215         * m4/pmccabe2html.m4: New file.
121216         * modules/pmccabe2html: New file.
121218 2008-10-07  Richard W.M. Jones  <rjones@redhat.com>
121220         flock: new module
121221         * MODULES.html.sh: Add to list of modules.
121222         * lib/flock.c: flock implementation for Windows and Unix systems
121223         which have fcntl.
121224         * doc/glibc-functions/flock.texi: Update documentation.
121225         * lib/sys_file.in.h: <sys/file.h> header file.
121226         * m4/flock.m4: M4 macros.
121227         * m4/sys_file_h.m4: M4 macros for replacement sys/file.h.
121228         * modules/flock: flock module.
121229         * modules/flock-tests: flock tests module.
121230         * modules/sys_file: sys/file.h module.
121231         * tests/test-flock.c: test suite for flock.
121233 2008-10-06  Jim Meyering  <meyering@redhat.com>
121235         bootstrap: check for LT_INIT more portably still ;-)
121236         * build-aux/bootstrap: Don't rely on \>, since it's not portable.
121237         Spotted by Bruno Haible.
121239 2008-10-06  Eric Blake  <ebb9@byu.net>
121241         test-signbit: avoid tripping Irix cc bug on -0.0L
121242         * tests/test-signbit.c (minus_zerol): Delete, and replace with
121243         '-zerol'.  This may break on HP-UX/hppa, but at least makes the
121244         entire testsuite consistent and avoids an Irix 6.2 bug.
121246 2008-10-05  Bruno Haible  <bruno@clisp.org>
121247             Jim Meyering  <jim@meyering.net>
121249         Add an option for ignoring EPIPE during close_stdout.
121250         * lib/closeout.h: Include <stdbool.h>.
121251         (close_stdout_set_ignore_EPIPE): New declaration.
121252         * lib/closeout.c: Include <stdbool.h>.
121253         (ignore_EPIPE): New variable.
121254         (close_stdout_set_ignore_EPIPE): New function.
121255         (close_stdout): Ignore EPIPE error if ignore_EPIPE is set.
121256         * lib/close-stream.c (close_stream): Mention the possible EPIPE
121257         failure.
121258         * modules/closeout (Depends-on): Add stdbool.
121260 2008-10-05  Bruno Haible  <bruno@clisp.org>
121262         * modules/accept: New file.
121263         * modules/bind: New file.
121264         * modules/connect: New file.
121265         * modules/getpeername: New file.
121266         * modules/getsockname: New file.
121267         * modules/getsockopt: New file.
121268         * modules/listen: New file.
121269         * modules/recv: New file.
121270         * modules/recvfrom: New file.
121271         * modules/send: New file.
121272         * modules/sendto: New file.
121273         * modules/setsockopt: New file.
121274         * modules/socket: New file.
121275         * lib/sys_socket.in.h: Include the GL_LINK_WARNING definition.
121276         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
121277         listen, recv, send, recvfrom, sendto, setsockopt): Declare only when
121278         the particular module is requested. Add a link warning when the
121279         particular module is not requested.
121280         * lib/winsock.c (rpl_socket, rpl_connect, rpl_accept, rpl_bind,
121281         rpl_getpeername, rpl_getsockname, rpl_getsockopt, rpl_listen, rpl_recv,
121282         rpl_send, rpl_recvfrom, rpl_sendto, rpl_setsockopt): Define only when
121283         the particular module is requested.
121284         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR,
121285         gl_SYS_SOCKET_H_DEFAULTS): New macros.
121286         (gl_HEADER_SYS_SOCKET): Require gl_SYS_SOCKET_H_DEFAULTS.
121287         * modules/sys_socket (Depends-on): Add link-warning.
121288         (Makeifle.am): Substitute GNULIB_SOCKET, GNULIB_CONNECT, GNULIB_ACCEPT,
121289         GNULIB_BIND, GNULIB_GETPEERNAME, GNULIB_GETSOCKNAME, GNULIB_GETSOCKOPT,
121290         GNULIB_LISTEN, GNULIB_RECV, GNULIB_SEND, GNULIB_RECVFROM,
121291         GNULIB_SENDTO, GNULIB_SETSOCKOPT, and the definition of
121292         GL_LINK_WARNING.
121293         * doc/posix-functions/accept.texi: Mention the new module 'accept'.
121294         * doc/posix-functions/bind.texi: Mention the new module 'bind'.
121295         * doc/posix-functions/connect.texi: Mention the new module 'connect'.
121296         * doc/posix-functions/getpeername.texi: Mention the new module
121297         'getpeername'.
121298         * doc/posix-functions/getsockname.texi: Mention the new module
121299         'getsockname'.
121300         * doc/posix-functions/getsockopt.texi: Mention the new module
121301         'getsockopt'.
121302         * doc/posix-functions/listen.texi: Mention the new module 'listen'.
121303         * doc/posix-functions/recv.texi: Mention the new module 'recv'.
121304         * doc/posix-functions/recvfrom.texi: Mention the new module 'recvfrom'.
121305         * doc/posix-functions/send.texi: Mention the new module 'send'.
121306         * doc/posix-functions/sendto.texi: Mention the new module 'sendto'.
121307         * doc/posix-functions/setsockopt.texi: Mention the new module
121308         'setsockopt'.
121309         * doc/posix-functions/socket.texi: Mention the new module 'socket'.
121310         * modules/poll-tests (Depends-on): Add socket, bind, getsockopt,
121311         listen, connect, accept.
121312         * modules/select-tests (Depends-on): Likewise.
121314 2008-10-05  Bruno Haible  <bruno@clisp.org>
121316         * lib/winsock.c (strerror): Remove unused #undef.
121317         (rpl_close): Remove unused local variable.
121319         * modules/sys_socket (Depends-on); Add errno.
121321 2008-10-05  Bruno Haible  <bruno@clisp.org>
121323         * lib/sys_select.in.h: Include the GL_LINK_WARNING definition.
121324         (select): Add a link warning when the 'select' module is not used.
121325         * modules/sys_select (Depends-on): Add link-warning.
121326         (Makefile.am): Substitute the definition of GL_LINK_WARNING.
121327         Suggested by Paolo Bonzini.
121329 2008-10-05  Jim Meyering  <meyering@redhat.com>
121331         bootstrap: check for LT_INIT more portably
121332         * build-aux/bootstrap: Avoid using grep -E, since it's not
121333         portable enough.  Suggestion from Bruno Haible.
121335 2008-10-05  Bruno Haible  <bruno@clisp.org>
121337         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem
121338         as being fixed by gnulib.
121340 2008-10-05  Bruno Haible  <bruno@clisp.org>
121342         * modules/select-tests: New file, mostly copied from
121343         modules/sys_select-tests.
121344         * tests/test-select.c: New file, mostly copied from
121345         tests/test-sys_select.c.
121346         * tests/test-sys_select.c: Move most of the code to tests/test-select.c.
121347         * modules/sys_select-tests (Depends-on): Remove all dependencies.
121348         (Makefile.am): Remove test_sys_select_LDADD.
121350         * lib/sys_select.in.h (select): If GNULIB_SELECT is not set, define it
121351         to an undefined symbol, for an error message.
121352         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): New macro.
121353         (gl_SYS_SELECT_H_DEFAULTS): New macro.
121354         (gl_HEADER_SYS_SELECT): Require it. Don't require compilation of
121355         winsock-select.c here.
121356         * modules/sys_select (Files): Remove lib/winsock-select.c.
121357         (Depends-on): Remove alloca.
121358         (Makefile.am): Substitute GNULIB_SELECT.
121359         * modules/select: New file.
121360         * doc/posix-functions/select.texi: Update.
121362 2008-10-05  Bruno Haible  <bruno@clisp.org>
121364         * lib/spawn_faction_addclose.c (__sysconf): Use getdtablesize always.
121365         * lib/spawn_faction_adddup2.c (__sysconf): Likewise.
121366         * lib/spawn_faction_addopen.c (__sysconf): Likewise.
121367         * modules/posix_spawn_file_actions_addclose (Depends-on): Add
121368         getdtablesize.
121369         * modules/posix_spawn_file_actions_adddup2 (Depends-on): Likewise.
121370         * modules/posix_spawn_file_actions_addopen (Depends-on): Likewise.
121372 2008-10-05  Bruno Haible  <bruno@clisp.org>
121374         * modules/getdtablesize-tests: New file.
121375         * tests/test-getdtablesize.c: New file.
121377         New module 'getdtablesize'.
121378         * lib/unistd.in.h (getdtablesize): New declaration.
121379         * lib/getdtablesize.c: New file.
121380         * m4/getdtablesize.m4: New file.
121381         * modules/getdtablesize: New file.
121382         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
121383         GNULIB_GETDTABLESIZE, HAVE_GETDTABLESIZE.
121384         * modules/unistd (Makefile.am): Substitute GNULIB_GETDTABLESIZE,
121385         HAVE_GETDTABLESIZE.
121386         * doc/glibc-functions/getdtablesize.texi: Mention the new module.
121388 2008-10-05  Bruno Haible  <bruno@clisp.org>
121390         * modules/sched (Makefile.am): Fix typo.
121391         Reported by Simon Josefsson.
121393 2008-10-05  Jim Meyering  <meyering@redhat.com>
121395         bootstrap: check for LT_INIT, too
121396         * build-aux/bootstrap: Both AC_PROG_LIBTOOL and AM_PROG_LIBTOOL
121397         are deprecated.  Suggestion from Ralf Wildenhues.
121399 2008-10-05  Bruno Haible  <bruno@clisp.org>
121401         * lib/spawn.in.h (POSIX_SPAWN_*): Use the system's values, rather than
121402         overriding them by ours.
121403         (POSIX_SPAWN_USEVFORK): Use the next free bit position.
121405 2008-10-05  Jim Meyering  <meyering@redhat.com>
121407         bootstrap: check for AC_PROG_LIBTOOL as well as AM_PROG_LIBTOOL
121408         * build-aux/bootstrap: Check for AC_PROG_LIBTOOL, as well as the
121409         obsolete AM_PROG_LIBTOOL.  Spotted by Debarshi Ray <rishi@gnu.org>.
121411 2008-10-04  Bruno Haible  <bruno@clisp.org>
121413         * modules/dup2 (License): Change to LGPLv2+.
121414         * modules/sleep (License): Likewise.
121415         * modules/perror (License): Likewise.
121416         * modules/fopen (License): Change to LGPLv2+, with approval by Eric
121417         Blake.
121418         * modules/signal (License): Likewise.
121419         * modules/sigprocmask (License): Likewise.
121420         * modules/raise (License): Change to LGPLv2+, with approval by Jim
121421         Meyering.
121423 2008-10-04  Bruno Haible  <bruno@clisp.org>
121425         * lib/spawn.in.h (POSIX_SPAWN_*): Undefine before redefining.
121426         Reported by Rainer Tammer <tammer@tammer.net>.
121428 2008-10-03  Paolo Bonzini  <bonzini@gnu.org>
121429             Bruno Haible  <bruno@clisp.org>
121431         * lib/errno.in.h (EWOULDBLOCK) [win32]: Define to EAGAIN.
121432         * lib/winsock.c (set_winsock_errno): Map WSAEWOULDBLOCK to EWOULDBLOCK.
121433         * lib/strerror.c (rpl_strerror): Remove error string for EWOULDBLOCK.
121435 2008-10-03  Kamil Dudka  <kdudka@redhat.com>
121437         filevercmp: new module
121438         * lib/filevercmp.h: New function filevercmp comparing version strings.
121439         * lib/filevercmp.c: Implementation of filevercmp function.
121440         * modules/filevercmp: Module metadata.
121441         * tests/test-filevercmp.c: Unit test for new module.
121442         * modules/filevercmp-tests: Unit test metadata.
121443         * MODULES.html.sh: Add filevercmp module.
121445 2008-10-03  Bruno Haible  <bruno@clisp.org>
121447         * lib/c-ctype.h: Add comment.
121448         Reported by Jim Meyering.
121450 2008-10-02  Bruno Haible  <bruno@clisp.org>
121452         * modules/posix_spawn-internal (Depends-on): Add 'open'.
121454 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
121456         * build-aux/bootstrap: Allow renaming bootstrap, and change the
121457         name of bootstrap.conf accordingly.
121459 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
121461         * build-aux/bootstrap: Install git-merge-changelog configuration
121462         items into .gitconfig if needed.
121464 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
121466         * build-aux/bootstrap: Recognize `gnulib' being a submodule in a
121467         git repository, and initialize/update it accordingly.
121469 2008-10-02  Richard W.M. Jones  <rjones@redhat.com>
121471         * modules/fsync-tests: New file.
121472         * tests/test-fsync.c: New file.
121474         New module 'fsync'.
121475         * lib/fsync.c: New file.
121476         * m4/fsync.m4: New file.
121477         * modules/fsync: New file.
121478         * lib/unistd.in.h (fsync): New declaration.
121479         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define and AC_SUBST both
121480         GNULIB_FSYNC and HAVE_FSYNC.
121481         * modules/unistd: Substitute GNULIB_FSYNC and HAVE_FSYNC.
121482         * MODULES.html.sh (posix_functions): Add fsync.
121483         * doc/posix-functions/fsync.texi: Mention the new module.
121485 2008-10-02  Jim Meyering  <meyering@redhat.com>
121487         fts.c: sync with similar code from coreutils' remove.c
121488         * lib/fts.c (dirent_inode_sort_may_be_useful): Merge from coreutils.
121489         Guard also with "#if defined __linux__", since for now at least,
121490         this code is Linux-kernel-specific.
121492 2008-10-02  Jim Meyering  <meyering@redhat.com>
121494         fts: bug fixes
121495         * lib/fts.c: Remove unnecessary "defined" in cpp directive.
121496         Include <sys/vfs.h>, not <sys/statfs.h>.
121498         * m4/fts.m4 (gl_FUNC_FTS_CORE): Fix typo s/vfs/vfs.h/.
121499         Include <sys/vfs.h>, not <sys/statfs.h>.
121501 2008-10-01  Bruno Haible  <bruno@clisp.org>
121503         Avoid the broken posix_spawn function on AIX 5.3 and 6.1.
121504         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): New macro.
121505         (gl_POSIX_SPAWN_BODY): Invoke it. Set REPLACE_POSIX_SPAWN if needed.
121506         * doc/posix-functions/posix_spawn.texi: Mention the AIX bugs.
121507         * doc/posix-functions/posix_spawnp.texi: Likewise.
121508         * m4/execute.m4 (gl_EXECUTE): Invoke gl_POSIX_SPAWN_WORKS, to check
121509         whether posix_spawn actually works.
121510         * m4/pipe.m4 (gl_PIPE): Likewise.
121511         * modules/execute (Files): Add m4/posix_spawn.m4.
121512         * modules/pipe (Files): Add m4/posix_spawn.m4.
121513         Reported and analyzed by Rainer Tammer <tammer@tammer.net>.
121515 2008-10-01  Jim Meyering  <meyering@redhat.com>
121517         remove trailing spaces
121518         * NEWS: Likewise.
121519         * lib/poll.c (poll): Likewise.
121520         * lib/sys_socket.in.h (SHUT_RDWR): Likewise.
121521         * lib/winsock.c (rpl_close): Likewise.
121522         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Likewise.
121523         * modules/yield: Likewise.
121524         * tests/test-poll.c (connect_to_socket, poll1): Likewise.
121525         * tests/test-sys_select.c (connect_to_socket): Likewise.
121527         fts.c: adjust a new interface to be more generally useful
121528         * lib/fts.c (dirent_inode_sort_may_be_useful): Take an FD parameter.
121529         (fts_build): Adjust caller.
121531 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121533         * modules/cond-tests: New file.
121534         * tests/test-cond.c: New file.
121536 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121537             Bruno Haible  <bruno@clisp.org>
121539         * modules/cond (Dependencies): Add errno, time.
121540         * lib/glthread/cond.h: Include <time.h>.
121541         (gl_cond_define, gl_cond_define_initialized): Use the same definition
121542         across platforms.
121544 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121545             Bruno Haible  <bruno@clisp.org>
121547         * m4/thread.m4 (gl_THREAD): Fix detection of pthread_atfork function.
121549 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121550             Bruno Haible  <bruno@clisp.org>
121552         * modules/tls-tests (Depends-on): Add thread, yield.
121553         (configure.ac): Remove all checks.
121554         (test_tls_LDADD): Use YIELD_LIB instead of LIBSCHED.
121555         * tests/test-tls.c (gl_thread_t, gl_thread_join, gl_thread_yield,
121556         gl_thread_self): Remove definitions. Include glthread/thread.h and
121557         glthread/yield.h instead.
121558         (test_tls): Pass an additional NULL argument to gl_thread_join.
121560 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121561             Bruno Haible  <bruno@clisp.org>
121563         * modules/lock-tests (Depends-on): Add thread, yield.
121564         (configure.ac): Remove all checks.
121565         (test_lock_LDADD): Use YIELD_LIB instead of LIBSCHED.
121566         * tests/test-lock.c (gl_thread_t, gl_thread_join, gl_thread_yield,
121567         gl_thread_self): Remove definitions. Include glthread/thread.h and
121568         glthread/yield.h instead.
121569         (test_lock, test_rwlock, test_recursive_lock, test_once): Pass an
121570         additional NULL argument to gl_thread_join.
121572 2008-09-30  Bruno Haible  <bruno@clisp.org>
121574         Fix the Win32 implementation of the 'thread' module.
121575         * lib/glthread/thread.h [USE_WIN32_THREADS] (gl_thread_t): Change to a
121576         pointer type.
121577         (gl_thread_self): Invoke gl_thread_self_func.
121578         (gl_thread_self_func): New declaration.
121579         * lib/glthread/thread.c [USE_WIN32_THREADS] (self_key): New variable.
121580         (do_init_self_key, init_self_key): New functions.
121581         (struct gl_thread_struct): Renamed from 'struct thread_extra'.
121582         Remove some fields.
121583         (running_threads, running_lock): Remove variables.
121584         (get_current_thread_handle): New function.
121585         (gl_thread_self_func, wrapper_func, glthread_create_func,
121586         glthread_join_func, gl_thread_exit_func): Largely rewritten and
121587         simplified.
121589 2008-09-30  Bruno Haible  <bruno@clisp.org>
121591         * lib/winsock-select.c (win32_poll_handle): Add shortcut for regular
121592         files.
121594 2008-09-30  Jim Meyering  <meyering@redhat.com>
121596         fts.m4: correct the test for statfs.f_type
121597         * m4/fts.m4 (gl_FUNC_FTS_CORE): Include <sys/statfs.h>
121598         when checking for statfs.f_type.
121600 2008-09-15  Simon Josefsson  <simon@josefsson.org>
121602         tests: avoid some compiler warnings
121603         * tests/test-memchr.c (main): Pass NULL indirectly.
121604         * tests/test-getdate.c (main): Remove unused variable 'ret'.
121606 2008-09-29  Ondřej Vašík  <ovasik@redhat.com>
121608         getdate.y: disallow countable dayshifts like "4 yesterday ago"
121609         * lib/getdate.y (relative_time_table) [tDAY_SHIFT]: New type for
121610         exactly specified dayshifts.
121611         (dayshift): New rule.
121612         (rel): Add dayshift.
121613         (relative_time_table) [tomorrow, yesterday, today, now]:
121614         Use tDAY_SHIFT in place of tDAY_UNIT.
121615         * tests/test-getdate.c: Add tests for now-disallowed countable
121616         dayshifts, e.g., "4 yesterday ago".
121618 2008-09-29  Bruno Haible  <bruno@clisp.org>
121620         * tests/test-posix_spawn1.c: Renamed from tests/test-posix_spawn.c.
121621         * tests/test-posix_spawn1.in.sh: Renamed from
121622         tests/test-posix_spawn.in.sh.
121623         * tests/test-posix_spawn2.c: New file.
121624         * tests/test-posix_spawn2.in.sh: New file.
121625         * modules/posix_spawnp-tests (Files): Update.
121626         (Makefile.am): Update. Add test-posix_spawn2 to the tests.
121628 2008-09-29  Bruno Haible  <bruno@clisp.org>
121630         Propagate effects of putenv/setenv/unsetenv to child processes.
121631         * lib/execute.c (execute): Use spawnvpe instead of spawnvp.
121632         * lib/pipe.c (create_pipe): Likewise.
121634 2008-09-29  Bruno Haible  <bruno@clisp.org>
121636         Enable use of shell scripts as executables in mingw.
121637         * lib/execute.c (execute): When spawnv fails with error ENOEXEC,
121638         run the program as a shell script.
121639         * lib/pipe.c (create_pipe): Likewise.
121640         * lib/w32spawn.h (prepare_spawn): Add a hidden element in front of the
121641         resulting array.
121643 2008-09-29  Eric Blake  <ebb9@byu.net>
121645         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Fix typo.
121647 2008-08-24  Paolo Bonzini  <bonzini@gnu.org>
121649         * doc/posix-functions/accept.texi: Update mingw problems.
121650         * doc/posix-functions/bind.texi: Update mingw problems.
121651         * doc/posix-functions/close.texi: Update mingw problems.
121652         * doc/posix-functions/connect.texi: Update mingw problems.
121653         * doc/posix-functions/getpeername.texi: Update mingw problems.
121654         * doc/posix-functions/getsockname.texi: Update mingw problems.
121655         * doc/posix-functions/getsockopt.texi: Update mingw problems.
121656         * doc/posix-functions/ioctl.texi: Update mingw problems.
121657         * doc/posix-functions/listen.texi: Update mingw problems.
121658         * doc/posix-functions/recv.texi: Update mingw problems.
121659         * doc/posix-functions/recvfrom.texi: Update mingw problems.
121660         * doc/posix-functions/select.texi: Update mingw problems.
121661         * doc/posix-functions/send.texi: Update mingw problems.
121662         * doc/posix-functions/sendto.texi: Update mingw problems.
121663         * doc/posix-functions/setsockopt.texi: Update mingw problems.
121664         * doc/posix-functions/socket.texi: Update mingw problems.
121666 2008-09-29  Paolo Bonzini  <bonzini@gnu.org>
121667             Bruno Haible  <bruno@clisp.org>
121669         * lib/sys_select.in.h: Include sys/time.h.
121670         * m4/sys_select.h.m4: Test that struct timeval is fully defined.
121671         * modules/sys_select: Depend on sys_time.
121672         * tests/test-sys_select.c: Test that sys/select.h defines struct
121673         timeval fully.
121675 2008-09-29  Bruno Haible  <bruno@clisp.org>
121677         * lib/sys_socket.in.h: Wrap the definitions in 'extern "C"'.
121678         * lib/sys_select.in.h: Likewise.
121680 2008-09-29  Bruno Haible  <bruno@clisp.org>
121682         * lib/winsock.c (rpl_close, rpl_socket): Remove unused variables.
121684 2008-09-29  Bruno Haible  <bruno@clisp.org>
121686         * m4/sockets.m4 (gl_SOCKETS): Check also for the need to use -lsocket.
121687         Set LIBSOCKET instead of augmenting LIBS.
121688         * modules/sockets (Link): New section.
121689         * modules/sockets-tests (test_sockets_LDADD): New variable.
121690         * modules/sys_select-tests (test_sys_select_LDADD): New variable.
121691         * modules/poll-tests (test_poll_LDADD): New variable.
121692         * NEWS: Document the change.
121694 2008-09-29  Bruno Haible  <bruno@clisp.org>
121696         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): New macro.
121697         * m4/inet_ntop.m4 (gl_INET_NTOP): Invoke it instead of assigning
121698         ARPA_INET_H directly.
121699         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
121701 2008-09-28  Bruno Haible  <bruno@clisp.org>
121703         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): New macro, extracted
121704         from gl_HEADER_SYS_SOCKET.
121705         (gl_HEADER_SYS_SOCKET): Invoke it.
121706         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
121708 2008-09-28  Bruno Haible  <bruno@clisp.org>
121710         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem.
121711         * tests/test-sys_select.c: Include <sys/time.h>, for struct timeval.
121712         Needed on OSF/1 4.0.
121714 2008-09-28  Bruno Haible  <bruno@clisp.org>
121716         Override open more carefully.
121717         * lib/open.c (orig_open): New function.
121718         (rpl_open): Use orig_open instead of open.
121719         * lib/fcntl.in.h: Add special invocation convention.
121720         * m4/open.m4 (gl_PREREQ_OPEN): New macro.
121721         (gl_FUNC_OPEN): Invoke it.
121723         Override freopen more carefully.
121724         * lib/freopen.c (orig_freopen): New function.
121725         (rpl_freopen): Use orig_freopen instead of freopen.
121726         * m4/freopen.m4 (gl_PREREQ_FREOPEN): New macro.
121727         (gl_FUNC_FREOPEN): Invoke it.
121729         Override fopen more carefully.
121730         * lib/fopen.c (orig_fopen): New function.
121731         (rpl_fopen): Use orig_fopen instead of fopen.
121732         * m4/fopen.m4 (gl_PREREQ_FOPEN): New macro.
121733         (gl_FUNC_FOPEN): Invoke it.
121734         Needed on AIX. Reported by Rainer Tammer <tammer@tammer.net>.
121736 2008-09-28  Bruno Haible  <bruno@clisp.org>
121738         * lib/pipe.h (create_pipe_out, create_pipe_bidi): Add comment about
121739         SIGPIPE.
121741 2008-09-28  Bruno Haible  <bruno@clisp.org>
121743         * tests/test-sigaction.c (handler, main): Disable the check whether
121744         SA_RESETHAND has reverted the installed handler to SIG_DFL. Needed on
121745         glibc systems with LinuxThreads.
121747 2008-09-28  Bruno Haible  <bruno@clisp.org>
121749         * doc/posix-functions/freopen.texi: Mention the trailing slash problem.
121751         * lib/stdio.in.h (fopen, freopen): Undefine before redefining. Needed
121752         with AIX xlc.
121753         * lib/fcntl.in.h (open): Likewise.
121754         Reported by Rainer Tammer <tammer@tammer.net>.
121756 2008-09-28  Bruno Haible  <bruno@clisp.org>
121758         * modules/posix_spawnp-tests: New file.
121759         * tests/test-posix_spawn.c: New file.
121760         * tests/test-posix_spawn.in.sh: New file.
121762         New module 'posix_spawnp'.
121763         * modules/posix_spawnp: New file.
121764         * lib/spawnp.c: New file, from GNU libc with modifications.
121765         * doc/posix-functions/posix_spawnp.texi: Mention the new module.
121767         New module 'posix_spawn'.
121768         * modules/posix_spawn: New file.
121769         * lib/spawn.c: New file, from GNU libc with modifications.
121770         * doc/posix-functions/posix_spawn.texi: Mention the new module.
121772         New module 'posix_spawnattr_destroy'.
121773         * modules/posix_spawnattr_destroy: New file.
121774         * lib/spawnattr_destroy.c: New file, from GNU libc with modifications.
121775         * doc/posix-functions/posix_spawnattr_destroy.texi: Mention the new
121776         module.
121778         New module 'posix_spawnattr_setsigmask'.
121779         * modules/posix_spawnattr_setsigmask: New file.
121780         * lib/spawnattr_setsigmask.c: New file, from GNU libc with
121781         modifications.
121782         * doc/posix-functions/posix_spawnattr_setsigmask.texi: Mention the
121783         new module.
121785         New module 'posix_spawnattr_getsigmask'.
121786         * modules/posix_spawnattr_getsigmask: New file.
121787         * lib/spawnattr_getsigmask.c: New file, from GNU libc with
121788         modifications.
121789         * doc/posix-functions/posix_spawnattr_getsigmask.texi: Mention the
121790         new module.
121792         New module 'posix_spawnattr_setsigdefault'.
121793         * modules/posix_spawnattr_setsigdefault: New file.
121794         * lib/spawnattr_setdefault.c: New file, from GNU libc with
121795         modifications.
121796         * doc/posix-functions/posix_spawnattr_setsigdefault.texi: Mention the
121797         new module.
121799         New module 'posix_spawnattr_getsigdefault'.
121800         * modules/posix_spawnattr_getsigdefault: New file.
121801         * lib/spawnattr_getdefault.c: New file, from GNU libc with
121802         modifications.
121803         * doc/posix-functions/posix_spawnattr_getsigdefault.texi: Mention the
121804         new module.
121806         New module 'posix_spawnattr_setschedpolicy'.
121807         * modules/posix_spawnattr_setschedpolicy: New file.
121808         * lib/spawnattr_setschedpolicy.c: New file, from GNU libc with
121809         modifications.
121810         * doc/posix-functions/posix_spawnattr_setschedpolicy.texi: Mention the
121811         new module.
121813         New module 'posix_spawnattr_getschedpolicy'.
121814         * modules/posix_spawnattr_getschedpolicy: New file.
121815         * lib/spawnattr_getschedpolicy.c: New file, from GNU libc with
121816         modifications.
121817         * doc/posix-functions/posix_spawnattr_getschedpolicy.texi: Mention the
121818         new module.
121820         New module 'posix_spawnattr_setschedparam'.
121821         * modules/posix_spawnattr_setschedparam: New file.
121822         * lib/spawnattr_setschedparam.c: New file, from GNU libc with
121823         modifications.
121824         * doc/posix-functions/posix_spawnattr_setschedparam.texi: Mention the
121825         new module.
121827         New module 'posix_spawnattr_getschedparam'.
121828         * modules/posix_spawnattr_getschedparam: New file.
121829         * lib/spawnattr_getschedparam.c: New file, from GNU libc with
121830         modifications.
121831         * doc/posix-functions/posix_spawnattr_getschedparam.texi: Mention the
121832         new module.
121834         New module 'posix_spawnattr_setpgroup'.
121835         * modules/posix_spawnattr_setpgroup: New file.
121836         * lib/spawnattr_setpgroup.c: New file, from GNU libc with
121837         modifications.
121838         * doc/posix-functions/posix_spawnattr_setpgroup.texi: Mention the new
121839         module.
121841         New module 'posix_spawnattr_getpgroup'.
121842         * modules/posix_spawnattr_getpgroup: New file.
121843         * lib/spawnattr_getpgroup.c: New file, from GNU libc with
121844         modifications.
121845         * doc/posix-functions/posix_spawnattr_getpgroup.texi: Mention the new
121846         module.
121848         New module 'posix_spawnattr_setflags'.
121849         * modules/posix_spawnattr_setflags: New file.
121850         * lib/spawnattr_setflags.c: New file, from GNU libc with modifications.
121851         * doc/posix-functions/posix_spawnattr_setflags.texi: Mention the new
121852         module.
121854         New module 'posix_spawnattr_getflags'.
121855         * modules/posix_spawnattr_getflags: New file.
121856         * lib/spawnattr_getflags.c: New file, from GNU libc with modifications.
121857         * doc/posix-functions/posix_spawnattr_getflags.texi: Mention the new
121858         module.
121860         New module 'posix_spawnattr_init'.
121861         * modules/posix_spawnattr_init: New file.
121862         * lib/spawnattr_init.c: New file, from GNU libc with modifications.
121863         * doc/posix-functions/posix_spawnattr_init.texi: Mention the new
121864         module.
121866         New module 'posix_spawn_file_actions_destroy'.
121867         * modules/posix_spawn_file_actions_destroy: New file.
121868         * lib/spawn_faction_destroy.c: New file, from GNU libc with
121869         modifications.
121870         * doc/posix-functions/posix_spawn_file_actions_destroy.texi: Mention
121871         the new module.
121873         New module 'posix_spawn_file_actions_addopen'.
121874         * modules/posix_spawn_file_actions_addopen: New file.
121875         * lib/spawn_faction_addopen.c: New file, from GNU libc with
121876         modifications.
121877         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Mention
121878         the new module.
121880         New module 'posix_spawn_file_actions_adddup2'.
121881         * modules/posix_spawn_file_actions_adddup2: New file.
121882         * lib/spawn_faction_adddup2.c: New file, from GNU libc with
121883         modifications.
121884         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Mention
121885         the new module.
121887         New module 'posix_spawn_file_actions_addclose'.
121888         * modules/posix_spawn_file_actions_addclose: New file.
121889         * lib/spawn_faction_addclose.c: New file, from GNU libc with
121890         modifications.
121891         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
121892         the new module.
121894         New module 'posix_spawn_file_actions_init'.
121895         * modules/posix_spawn_file_actions_init: New file.
121896         * lib/spawn_faction_init.c: New file, from GNU libc with modifications.
121897         * doc/posix-functions/posix_spawn_file_actions_init.texi: Mention the
121898         new module.
121900         New module 'posix_spawn-internal'.
121901         * modules/posix_spawn-internal: New file.
121902         * lib/spawn_int.h: New file, from GNU libc with modifications.
121903         * lib/spawni.c: New file, from GNU libc with modifications.
121904         * m4/posix_spawn.m4: New file.
121906         New module 'spawn'.
121907         * modules/spawn: New file.
121908         * lib/spawn.in.h: New file, from GNU libc with modifications.
121909         * m4/spawn_h.m4: New file.
121910         * doc/posix-headers/spawn.texi: Mention the new module.
121912 2008-09-28  Bruno Haible  <bruno@clisp.org>
121914         * modules/sched-tests: New file.
121915         * tests/test-sched.c: New file.
121917         New module 'sched'.
121918         * modules/sched: New file.
121919         * lib/sched.in.h: New file.
121920         * m4/sched_h.m4: New file.
121921         * doc/posix-headers/sched.texi: Mention the new module.
121923 2008-09-27  Eric Blake  <ebb9@byu.net>
121925         Fix previous patch, and tweak references to $0.
121926         * posix-modules: Call func_gnulib_dir before using $gnulib_dir.
121927         (func_version, func_gnulib_dir): Don't call this program
121928         gnulib-tool.
121929         (func_gnulib_dir, func_tmpdir, func_fatal_error): Avoid shell bugs
121930         with using $0 in function.
121931         * gnulib-tool (func_gnulib_dir, func_tmpdir): Likewise.
121932         (func_fatal_error): Reuse the name the user invoked us with.
121934 2008-09-27  Bruno Haible  <bruno@clisp.org>
121936         * m4/iconv_h.m4 (gl_REPLACE_ICONV_H): New macro.
121937         (gl_ICONV_H_DEFAULTS): Initialize ICONV_H here...
121938         (gl_ICONV_H): Not here.
121939         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H
121940         instead of assigning ICONV_H directly.
121942         * m4/wchar.m4 (gl_REPLACE_WCHAR_H): New macro.
121943         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Invoke it instead of assigning
121944         WCHAR_H directly.
121946 2008-09-27  Bruno Haible  <bruno@clisp.org>
121948         * lib/arpa_inet.in.h: Include the GL_LINK_WARNING anchor.
121949         * modules/arpa_inet (Depends-on): Add link-warning.
121950         (Makefile.am): Insert the definition of GL_LINK-WARNING.
121951         * modules/unistd (Makefile.am): Likewise.
121953 2008-09-26  Bruno Haible  <bruno@clisp.org>
121955         * posix-modules (cvsdatestamp, last_checkin_date, version): Remove
121956         variables.
121957         (func_version): Essentially copied from gnulib-tool.
121958         (func_exit, func_gnulib_dir, func_tmpdir, func_fatal_error,
121959         func_readlink): Copied from gnulib-tool.
121961 2008-09-26  Bruno Haible  <bruno@clisp.org>
121963         * gnulib-tool (func_version): Change directory to $gnulib_dir before
121964         invoking git-version-gen.
121966 2008-09-26  Bruno Haible  <bruno@clisp.org>
121968         * posix-modules: Update to directory names changed on 2008-01-19.
121969         Remove commas in output before splitting into words. No more need to
121970         avoid 'ftruncate' since 2007-02-19.
121972 2008-09-26  Bruno Haible  <bruno@clisp.org>
121974         * doc/posix-headers/errno.texi: Remove mention of module 'EOVERFLOW'.
121976 2008-09-26  Bruno Haible  <bruno@clisp.org>
121978         * lib/fwriteerror.c (do_fwriteerror): Ignore error EPIPE.
121979         * modules/fwriteerror (Depends-on): Add errno.
121981 2008-09-26  Bruno Haible  <bruno@clisp.org>
121983         * tests/test-vc-list-files-git.sh: Explain reason for skipping test.
121984         * tests/test-vc-list-files-cvs.sh: Likewise.
121986 2008-09-26  Bruno Haible  <bruno@clisp.org>
121988         * doc/posix-headers/sys_resource.texi: Reorder items.
121990 2008-09-26  Jim Meyering  <meyering@redhat.com>
121992         fts: tweak inode comparison function
121993         * lib/fts.c (fts_compare_ino): Sort on increasing, not decreasing
121994         inode numbers, as documented.
121996         fts: sort dirent entries on inode number before traversing
121997         This avoids a quadratic, seek-related performance penalty when
121998         operating on a directory containing many entries (measurable at 10k;
121999         3.5 hours at 2 million entries with a cold cache) on certain types
122000         of file systems, including ext3 and ext4, but not tmpfs.
122001         * lib/fts.c (DT_MUST_BE, NOT_AN_INODE_NUMBER, D_INO): Define.
122002         (FTS_INODE_SORT_DIR_ENTRIES_THRESHOLD): Define if not defined.
122003         (S_MAGIC_TMPFS, S_MAGIC_NFS): Define.
122004         (fs_handles_readdir_ordered_dirents_efficiently): New function.
122005         (dirent_inode_sort_may_be_useful, fts_compare_ino): Likewise.
122006         (fts_build): Set the stat.st_ino member from D_INO.
122007         If it is likely to be useful, sort dirent entries on inode number.
122009         * m4/fts.m4 (gl_FUNC_FTS_CORE): Check for fstatfs, sys/vfs.h,
122010         and the struct statfs.f_type member.
122011         * modules/fts (Depends-on): Add d-ino.
122013 2008-09-26  Bruno Haible  <bruno@clisp.org>
122015         * modules/sigpipe-die (Depends-on): Add sigpipe.
122017         * lib/stdio.in.h (fprintf, vfprintf, printf, vprintf, fputc, putc,
122018         putchar, fputs, puts, fwrite): Replace when REPLACE_STDIO_WRITE_FUNCS
122019         and GNULIB_STDIO_H_SIGPIPE are set.
122020         * lib/stdio-write.c: New file.
122021         * m4/stdio_h.m4 (gl_STDIO_H): Set GNULIB_FPRINTF, GNULIB_PRINTF,
122022         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
122023         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
122024         REPLACE_STDIO_WRITE_FUNCS.
122025         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FPRINTF, GNULIB_PRINTF,
122026         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
122027         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
122028         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
122029         * modules/stdio (Files): Add lib/stdio-write.c.
122030         (Makefile.am): Substitute GNULIB_FPRINTF, GNULIB_PRINTF,
122031         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
122032         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
122033         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
122034         * m4/fprintf-posix.m4 (gl_REPLACE_FPRINTF): Define
122035         REPLACE_FPRINTF_POSIX.
122036         * m4/printf-posix-rpl.m4 (gl_REPLACE_PRINTF): Define
122037         REPLACE_PRINTF_POSIX.
122038         * m4/vfprintf-posix.m4 (gl_REPLACE_VFPRINTF): Define
122039         REPLACE_VFPRINTF_POSIX.
122040         * m4/vprintf-posix.m4 (gl_REPLACE_VPRINTF): Define
122041         REPLACE_VPRINTF_POSIX.
122042         * doc/posix-functions/fprintf.texi: Mention the sigpipe module and the
122043         SIGPIPE issue.
122044         * doc/posix-functions/fputc.texi: Likewise.
122045         * doc/posix-functions/fputs.texi: Likewise.
122046         * doc/posix-functions/fwrite.texi: Likewise.
122047         * doc/posix-functions/printf.texi: Likewise.
122048         * doc/posix-functions/putc.texi: Likewise.
122049         * doc/posix-functions/putchar.texi: Likewise.
122050         * doc/posix-functions/puts.texi: Likewise.
122051         * doc/posix-functions/vfprintf.texi: Likewise.
122052         * doc/posix-functions/vprintf.texi: Likewise.
122054         * modules/safe-write (Depends-on): Add write.
122056         * modules/sigpipe-tests: New file.
122057         * tests/test-sigpipe.c: New file.
122058         * tests/test-sigpipe.sh: New file.
122060         * modules/write: New file.
122061         * lib/unistd.in.h: Include <sys/types.h>.
122062         (write): New declaration.
122063         * lib/write.c: New file.
122064         * m4/write.m4: New file.
122065         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
122066         GNULIB_UNISTD_H_SIGPIPE, GNULIB_WRITE, REPLACE_WRITE.
122067         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_SIGPIPE,
122068         GNULIB_WRITE, REPLACE_WRITE.
122069         * doc/posix-functions/write.texi: Mention the write, sigpipe modules
122070         and the SIGPIPE issue.
122072         * lib/signal.in.h (SIGPIPE): Define to a replacement value.
122073         (raise): New declaration.
122074         * lib/sigprocmask.c (SIGPIPE_handler): New variable.
122075         (ext_signal): New function.
122076         (rpl_raise): New function.
122077         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
122078         GNULIB_SIGNAL_H_SIGPIPE.
122079         * modules/signal (Makefile.am): Substitute GNULIB_SIGNAL_H_SIGPIPE.
122080         * doc/posix-headers/signal.texi: Mention the SIGPIPE issue.
122082         * modules/sigpipe: New file.
122083         * m4/sigpipe.m4: New file.
122085 2008-09-25  Derek Price  <derek@ximbiot.com>
122086             Bruno Haible  <bruno@clisp.org>
122088         * gnulib-tool (func_import): Report all license incompatibilities, not
122089         just the first one.
122091 2008-09-25  Bruno Haible  <bruno@clisp.org>
122093         * gnulib-tool (func_import): When computing the edits, consider not
122094         only the Makefile.ams that exist but also those that will be generated.
122096 2008-09-25  Simon Josefsson  <simon@josefsson.org>
122098         * modules/sys_select-tests (Depends-on): Remove sys_select itself,
122099         fixes gnulib-tool --test warning about duplicate dependency.
122101 2008-09-25  Bruno Haible  <bruno@clisp.org>
122103         * gnulib-tool: Don't ask the user to perform edits in the generated
122104         Makefile.ams.
122105         (func_emit_lib_Makefile_am): Emit empty SUBDIRS. Execute edits that
122106         apply to the Makefile.am being generated.
122107         (func_emit_tests_Makefile_am): Execute edits that apply to the
122108         Makefile.am being generated.
122109         (func_import): Setup list of Makefile.am edits before emitting the
122110         Makefile.ams, not at the end.
122111         (func_create_testdir): Update.
122112         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
122114 2008-09-25  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
122116         * gnulib-tool (func_import): Store the --tests-base option in the
122117         comment in gnulib-cache.m4.
122119 2008-09-24  Paolo Bonzini  <bonzini@gnu.org>
122121         * NEWS: Document increased portability that sys_select now provides.
122123         * lib/sys_select.in.h: Install select wrapper.
122124         * lib/sys_socket.in.h: Use more descriptive name when there is no
122125         select wrapper.
122126         * lib/winsock-select.c: New.
122127         * m4/sys_select_h.m4: Compile lib/winsock-select.c if WinSock is used.
122128         Require gl_HEADER_SYS_SOCKET.
122129         * modules/sys_select: Depend on alloca, add lib/winsock-select.c.
122130         * modules/sys_select-tests: Copy dependencies from modules/poll-tests.
122131         * tests/test-sys_select.c: Add functional tests.
122133 2008-09-24  Eric Blake  <ebb9@byu.net>
122135         open, fopen: close fd leak in last patch
122136         * lib/open.c (rpl_open): Close fd before returning error.
122137         * lib/fopen.c (rpl_fopen): Close fd before returning error.
122138         * doc/posix-functions/open.texi (open): Document that Irix also
122139         has the bug.
122140         * doc/posix-functions/fopen.texi (fopen): Likewise.
122141         Reported by Paolo Bonzini.
122143 2008-09-24  Bruno Haible  <bruno@clisp.org>
122145         Ensure that a filename ending in a slash cannot be used to access a
122146         non-directory.
122147         * lib/open.c (rpl_open): When the filename ends in a slash, use fstat()
122148         to check whether it's really a directory.
122149         * lib/fopen.c: Include fcntl.h, unistd.h.
122150         (rpl_fopen): When the filename ends in a slash, use open(), fstat(),
122151         and fdopen().
122152         * modules/fopen (Depends-on): Add unistd.
122153         * tests/test-open.c (main): Try to open "/dev/null/" as a directory.
122154         * tests/test-fopen.c (main): Likewise.
122155         * doc/posix-functions/open.texi: Mention the HP-UX, Solaris bug.
122156         * doc/posix-functions/fopen.texi: Likewise.
122157         Reported by Eric Blake.
122159 2008-09-23  Eric Blake  <ebb9@byu.net>
122161         c-stack: avoid compiler optimizations when provoking overflow
122162         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Make
122163         recursion harder to optimize, to ensure a stack overflow occurs.
122164         * tests/test-c-stack.c (recurse): Likewise.
122165         Borrowed from libsigsegv.
122167         c-stack: work around Irix sigaltstack bug
122168         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check
122169         whether sigaltstack uses wrong end of stack_t (copied in part from
122170         libsigsegv).
122171         * lib/c-stack.c (c_stack_action) [!HAVE_LIBSIGSEGV]: Work around
122172         Irix bug, without requiring an over-allocation.
122173         * doc/posix-functions/sigaltstack.texi (sigaltstack): Document the
122174         bug.
122176         fopen: document mingw bug on directories
122177         * doc/posix-functions/fopen.texi (fopen): Mention mingw bug for
122178         not allowing a stream visiting a directory, even though reading
122179         from such a stream is not portable.
122181 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
122183         * lib/poll.c: Rewrite.
122184         * modules/poll: Depend on alloca.
122186 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
122188         * lib/sys_socket.in.h: Do not implement rpl_setsockopt here,
122189         instead define prototypes for a full set of wrappers.  Ensure
122190         that Cygwin does not use the compatibility code, which is only
122191         for MinGW.
122192         * lib/winsock.c: New.
122193         * m4/sys_socket_h.m4: Compile lib/winsock.c if WinSock is being used.
122194         * modules/sys_socket: Add lib/winsock.c.
122196         * modules/poll-tests: Add errno and perror.
122197         * tests/test-poll.c: Use ioctl, not ioctlsocket.
122199 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
122201         * tests/test-poll.c: Downgrade minimum needed Winsock version.
122203 2008-09-23  Bruno Haible  <bruno@clisp.org>
122205         * doc/posix-functions/*: Add info about functions missing on IRIX 5.3.
122206         * doc/glibc-functions/*: Likewise.
122208 2008-09-23  Simon Josefsson  <simon@josefsson.org>
122210         * tests/test-perror.sh (tmpfiles): Cleanup temporary files on
122211         success.
122213 2008-09-22  Eric Blake  <ebb9@byu.net>
122214             Bruno Haible  <bruno@clisp.org>
122216         vasnprintf: fix x86/glibc regression on printf("%La", 0.0L)
122217         * lib/vasnprintf.c (VASNPRINTF): Support 0.0 on platforms that
122218         supply %A but mishandle pseudo-NaN.
122219         Reported by Simon Josefsson.
122221 2008-09-21  Bruno Haible  <bruno@clisp.org>
122223         * tests/test-lock.c (main): Tweak skip message.
122224         * tests/test-tls.c (main): Likewise.
122226 2008-09-21  Bruno Haible  <bruno@clisp.org>
122228         * m4/sigaction.m4 (gl_SIGACTION): Remove unnecessary AC_SUBST. Check
122229         whether 'struct sigaction' has sa_sigaction here...
122230         (gl_PREREQ_SIG_HANDLER_H): ... not here.
122231         (gl_PREREQ_SIGACTION): Remove unnecessary AC_SUBST.
122233 2008-09-21  Bruno Haible  <bruno@clisp.org>
122235         * MODULES.html.sh (Support for obsolete systems lacking ANSI C 89): New
122236         section.
122237         (Support for systems lacking ANSI C 89): Move stdlib, exit, strtol,
122238         strtoul, memchr, memcmp, memcpy, memmove, memset, strcspn, strpbrk to
122239         the new section.
122240         (Support for obsolete systems lacking POSIX:2001): New section.
122241         (String handling <string.h>): Move strdup to the new section.
122242         Suggested by Simon Josefsson and Paolo Bonzini.
122244 2008-09-21  Bruno Haible  <bruno@clisp.org>
122246         * tests/test-vasnprintf-posix.c (test_function): Allow 3-digit
122247         exponents in %e and %g results on 'long double'. Needed for mingw's
122248         improved *printf functions.
122249         * tests/test-vasprintf-posix.c (test_function): Likewise.
122250         * tests/test-snprintf-posix.h (test_function): Likewise.
122251         * tests/test-sprintf-posix.h (test_function): Likewise.
122252         Reported by Eric Blake.
122254 2008-09-21  Bruno Haible  <bruno@clisp.org>
122256         * tests/test-snprintf-posix.h (test_function): Remove useless ASSERTs.
122257         * tests/test-sprintf-posix.h (test_function): Likewise.
122259 2008-09-21  Bruno Haible  <bruno@clisp.org>
122261         * modules/getpass (Depends-on): Add strdup-posix.
122263         New module 'strdup-posix'.
122264         * modules/strdup-posix: New file.
122265         * m4/strdup.m4 (gl_FUNC_STRDUP_POSIX): New macro.
122266         * lib/string.in.h (strdup): Replace if REPLACE_STRDUP is 1.
122267         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
122268         REPLACE_STRDUP.
122269         * modules/string (Makefile.am): Substitute REPLACE_STRDUP.
122270         * doc/posix-functions/strdup.texi: Mention module strdup-posix.
122271         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
122272         strdup-posix.
122274         * modules/strdup (Depends-on): Remove malloc-posix.
122276 2008-09-20  Bruno Haible  <bruno@clisp.org>
122278         * lib/fstrcmp.c: Add data about branch probabilities, from Ralf
122279         Wildenhues.
122281 2008-09-20  Bruno Haible  <bruno@clisp.org>
122283         Ensure that wint_t gets defined on IRIX 5.3.
122284         * lib/wchar.in.h (wint_t): Define if not defined by the system.
122285         * lib/wctype.in.h (wint_t): Likewise.
122286         (__wctype_wint_t): Remove type.
122287         (isw*): Use wint_t instead of __wctype_wint_t.
122288         * m4/wchar.m4 (gl_WCHAR_H): Invoke gt_TYPE_WINT_T and set HAVE_WINT_T.
122289         * modules/wchar (Files): Add m4/wint_t.m4.
122290         (Makefile.am): Substitute HAVE_WINT_T.
122291         * tests/test-wchar.c: Check that wchar_t and wint_t are defined.
122292         * tests/test-wctype.c: Check that wint_t is defined.
122293         * doc/posix-headers/wchar.texi: Mention the IRIX 5 problem.
122294         * doc/posix-headers/wctype.texi: Likewise.
122295         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
122297 2008-09-18  Bruno Haible  <bruno@clisp.org>
122299         * gnulib-tool (func_exit): Update comment.
122301 2008-09-18  Simon Josefsson  <simon@josefsson.org>
122303         * modules/getaddrinfo (Depends-on): Remove strdup, this module
122304         assumes strdup exists and does not depend on strdup to return
122305         ENOMEM on out of memory conditions.
122307 2008-09-18  Bruno Haible  <bruno@clisp.org>
122309         * lib/vasnprintf.c (VASNPRINTF): When printing ±0.0L in
122310         NEED_PRINTF_INFINITE_LONG_DOUBLE case with 'e' format, always use two
122311         digits for the exponent.
122313 2008-09-18  Jim Meyering  <meyering@redhat.com>
122314             Bruno Haible  <bruno@clisp.org>
122316         * lib/vasnprintf.c (decimal_point_char): Define also if
122317         NEED_PRINTF_INFINITE_LONG_DOUBLE.
122319 2008-09-16  Bruno Haible  <bruno@clisp.org>
122320         and Eric Blake  <ebb9@byu.net>
122322         vasnprintf: support Irix 5.3
122323         * lib/vasnprintf.c (VASNPRINTF): Also handle -0.0L on platforms
122324         that mishandle long double infinity.
122325         Reported by Tom G. Christensen.
122327 2008-09-16  Bruno Haible  <bruno@clisp.org>
122329         * doc/glibc-functions/scandir.texi: Mention the function is missing on
122330         Solaris 9.
122331         * doc/glibc-functions/alphasort.texi: Likewise.
122332         Reported by Michael Haubenwallner <michael.haubenwallner@salomon.at>.
122334 2008-09-16  Jim Meyering  <meyering@redhat.com>
122336         posix-shell.m4: reject opensolaris's "sh (AT&T Research) 1993-12-28 s+"
122337         * m4/posix-shell.m4 (gl_POSIX_SHELL): Reject a shell that lets
122338         a umask modification leak out of a subshell.  Otherwise, the
122339         opensolaris /bin/sh would be accepted and thus cause unwarranted
122340         failures in the coreutils test suite.
122342 2008-09-16  Paolo Bonzini  <bonzini@gnu.org>
122344         * tests/test-poll.c (connect_to_socket): Allow non-blocking connect
122345         to succeed.
122347 2008-09-16  Jim Meyering  <meyering@redhat.com>
122349         avoid spurious test failure when library is built without ACL support
122350         * m4/acl.m4 (USE_ACL): Define as a shell variable, too, for...
122351         * modules/acl-tests (Makefile.am) [TESTS_ENVIRONMENT]: Add USE_ACL.
122352         * tests/test-file-has-acl.sh: Skip if USE_ACL == 0.
122353         * tests/test-copy-acl.sh: Likewise.
122355 2008-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
122357         * lib/fstrcmp.c (fstrcmp_bounded): Use a second, less quick upper bound
122358         based on character occurrence counts.
122360 2008-09-15  Eric Blake  <ebb9@byu.net>
122362         tests: avoid some compiler warnings
122363         * tests/test-memchr.c (main): Pass NULL indirectly.
122364         * tests/test-closein.c (main): Avoid unused variable.
122366 2008-09-15  Bruno Haible  <bruno@clisp.org>
122368         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test for all the macros that
122369         are missing on OpenBSD 4.0 individually.
122370         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
122372 2008-09-15  Bruno Haible  <bruno@clisp.org>
122374         * doc/posix-headers/errno.texi: Mention the Cygwin problem.
122375         * doc/posix-functions/strerror.texi: Mention also Cygwin.
122376         * doc/posix-functions/perror.texi: Likewise.
122377         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test also whether ECANCELED
122378         is missing.
122379         Reported by Eric Blake.
122381         * lib/errno.in.h: Use replacement values >= 2000.
122382         Reported by Eric Blake.
122384 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
122386         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Add field 'edit_count_limit'.
122387         (EARLY_ABORT): Return true when the edit_count has grown too beyond the
122388         limit.
122389         (fstrcmp_bounded): Initialize the edit_count_limit. Return 0 when
122390         compareseq was aborted.
122392 2008-09-14  Bruno Haible  <bruno@clisp.org>
122394         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Combine xvec_edit_count and
122395         yvec_edit_count.
122396         (NOTE_DELETE, NOTE_INSERT): Increment the combined edit count.
122397         (fstrcmp_bounded): Simplify result computation accordingly.
122399 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
122401         * lib/fstrcmp.h (fstrcmp_bounded): New declaration.
122402         (fstrcmp): Define in terms of fstrcmp_bounded.
122403         * lib/fstrcmp.c (fstrcmp_bounded): Renamed from fstrcmp. Add
122404         lower_bound argument.
122405         Return quickly if the result is certainly < lower_bound.
122406         * tests/test-fstrcmp.c (check_fstrcmp): Test also fstrcmp_bounded.
122408 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
122410         * lib/diffseq.h (EARLY_ABORT): New macro.
122411         (compareseq): Change return type to bool. Return true when EARLY_ABORT
122412         evaluates to true.
122414 2008-09-14  Bruno Haible  <bruno@clisp.org>
122416         * modules/perror-tests: New file.
122417         * tests/test-perror.sh: New file.
122418         * tests/test-perror.c: New file.
122420         New module 'perror'.
122421         * lib/stdio.in.h (perror): New declaration.
122422         * lib/perror.c: New file.
122423         * m4/perror.m4: New file.
122424         * modules/perror: New file.
122425         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add perror.
122426         * doc/posix-functions/perror.texi: Mention the perror module.
122427         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_PERROR,
122428         REPLACE_PERROR.
122429         * modules/stdio (Makefile.am): Substitute GNULIB_PERROR,
122430         REPLACE_PERROR.
122432 2008-09-14  Bruno Haible  <bruno@clisp.org>
122434         * modules/stdio (Makefile.am): Reorder to match the order in
122435         lib/stdio.in.h.
122436         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
122438 2008-09-13  Bruno Haible  <bruno@clisp.org>
122440         * lib/sys_socket.in.h (EINPROGRESS, ...): Remove definitions.
122442 2008-09-13  Bruno Haible  <bruno@clisp.org>
122444         Extend strerror to cover the added errno values.
122445         * lib/strerror.c: Include errno.h and winsock2.h if it exists.
122446         (rpl_strerror): Provide error messages for the added errno values and
122447         for the WSA* values.
122448         * m4/strerror.m4 (gl_FUNC_STRERROR): Test REPLACE_STRERROR.
122449         (gl_FUNC_STRERROR_SEPARATE): If errno.h is replaced, always replace
122450         strerror.
122451         (gl_PREREQ_STRERROR): Test whether winsock2.h exists.
122452         * modules/strerror (Depends-on): Add errno.
122453         * doc/posix-functions/strerror.texi: Document the change.
122454         * tests/test-strerror.c (main): Check also the string for ETIMEDOUT
122455         and EOVERFLOW.
122457 2008-09-13  Bruno Haible  <bruno@clisp.org>
122459         * modules/EOVERFLOW: Remove file.
122460         * m4/eoverflow.m4: Remove file.
122461         * modules/EOVERFLOW-tests: Remove file.
122462         * tests/test-EOVERFLOW.c: Remove file.
122463         * modules/fprintf-posix (Depends-on): Replace EOVERFLOW with errno.
122464         * modules/ftell (Depends-on): Likewise.
122465         * modules/getdelim (Depends-on): Likewise.
122466         * modules/getugroups (Depends-on): Likewise.
122467         * modules/poll (Depends-on): Likewise.
122468         * modules/snprintf (Depends-on): Likewise.
122469         * modules/sprintf-posix (Depends-on): Likewise.
122470         * modules/vasnprintf (Depends-on): Likewise.
122471         * modules/vasprintf (Depends-on): Likewise.
122472         * modules/vfprintf-posix (Depends-on): Likewise.
122473         * modules/vsnprintf (Depends-on): Likewise.
122474         * modules/vsprintf-posix (Depends-on): Likewise.
122475         * modules/xvasprintf (Depends-on): Likewise.
122476         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
122477         * modules/unistdio/u8-vasprintf (Depends-on): Likewise.
122478         * modules/unistdio/u8-vsnprintf (Depends-on): Likewise.
122479         * modules/unistdio/u8-vsprintf (Depends-on): Likewise.
122480         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
122481         * modules/unistdio/u8-u8-vasprintf (Depends-on): Likewise.
122482         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Likewise.
122483         * modules/unistdio/u8-u8-vsprintf (Depends-on): Likewise.
122484         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
122485         * modules/unistdio/u16-u16-vasprintf (Depends-on): Likewise.
122486         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Likewise.
122487         * modules/unistdio/u16-u16-vsprintf (Depends-on): Likewise.
122488         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
122489         * modules/unistdio/u16-vasprintf (Depends-on): Likewise.
122490         * modules/unistdio/u16-vsnprintf (Depends-on): Likewise.
122491         * modules/unistdio/u16-vsprintf (Depends-on): Likewise.
122492         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
122493         * modules/unistdio/u32-vasprintf (Depends-on): Likewise.
122494         * modules/unistdio/u32-vsnprintf (Depends-on): Likewise.
122495         * modules/unistdio/u32-vsprintf (Depends-on): Likewise.
122496         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
122497         * modules/unistdio/u32-u32-vasprintf (Depends-on): Likewise.
122498         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Likewise.
122499         * modules/unistdio/u32-u32-vsprintf (Depends-on): Likewise.
122500         * modules/unistdio/ulc-fprintf (Depends-on): Likewise.
122501         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
122502         * modules/unistdio/ulc-vasprintf (Depends-on): Likewise.
122503         * modules/unistdio/ulc-vfprintf (Depends-on): Likewise.
122504         * modules/unistdio/ulc-vsnprintf (Depends-on): Likewise.
122505         * modules/unistdio/ulc-vsprintf (Depends-on): Likewise.
122506         * MODULES.html.sh: Remove EOVERFLOW.
122507         * NEWS: Mention the change.
122509 2008-09-13  Bruno Haible  <bruno@clisp.org>
122511         * modules/errno-tests: New file.
122512         * tests/test-errno.c: New file, incorporating tests/test-EOVERFLOW.c.
122514         * lib/errno.in.h: New file.
122515         * m4/errno_h.m4: New file, borrowing from m4/eoverflow.m4.
122516         * modules/errno: New file.
122517         * doc/posix-headers/errno.texi: Update documentation.
122518         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add errno.
122520 2008-09-13  Bruno Haible  <bruno@clisp.org>
122522         * tests/test-poll.c: Use #if for native Windows, rather than testing
122523         __MSVCRT__.
122525 2008-09-13  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
122526             Bruno Haible  <bruno@clisp.org>
122528         * lib/glob.c: Don't include <pwd.h> on native Windows.
122529         (WINDOWS32): New macro.
122530         (glob) [WINDOW32]: Provide a reasonable replacement for getenv("HOME").
122532 2008-09-13  Bruno Haible  <bruno@clisp.org>
122534         * lib/glthread/cond.h [USE_SOLARIS_THREADS]
122535         (ETIMEDOUT): Remove macro.
122536         (glthread_cond_timedwait_multithreaded): New declaration.
122537         (glthread_cond_timedwait): Use it.
122538         * lib/glthread/cond.c [USE_SOLARIS_THREADS]
122539         (glthread_cond_timedwait_multithreaded): New function.
122541 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
122543         * modules/poll-tests: Do not check for io.h.
122544         * tests/test-poll.c: Check for __MSVCRT__ instead.
122546 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
122548         * lib/sys_socket.in.h (EINPROGRESS): Define for Winsock case.
122549         * modules/poll-tests: Add inet_pton, stdbool, sockets.
122550         * tests/test-poll.c: Use them.  Use _pipe on Windows.
122552 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
122554         * modules/poll-tests: New.
122555         * tests/test-poll.c: New.
122557 2008-09-12  Eric Blake  <ebb9@byu.net>
122559         frexp: test for NetBSD failure on -0.0
122560         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Enhance test, since some, but
122561         not all, bugs from NetBSD 3.0 have been fixed.
122562         * doc/posix-functions/frexp.texi (frexp): Document bug.
122563         Reported by Thomas Klausner.
122565         signbit: work around bug of HP-UX 10.20 cc with -0.0 literal
122566         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Rewrite test to avoid
122567         literal -0.0.
122568         Reported by Jonathan C. Patschke <jp@centtech.com>.
122570 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
122572         * lib/glthread/cond.h: Use dummy implementation also if
122573         USE_WIN32_THREADS.
122575 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
122577         * modules/fnmatch-posix (License): Change to LGPLv2+.
122578         * modules/fnmatch-gnu (License): Likewise.
122580 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
122582         * lib/poll.c (poll): Fix polling unconnected server sockets on WIN32.
122584 2008-09-11  Jim Meyering  <meyering@redhat.com>
122586         * users.txt: Add gtk-vnc.
122588 2008-09-08  Simon Josefsson  <simon@josefsson.org>
122590         * tests/test-bitrotate.c: Test 8/16-bit rotates with 0 and maximum
122591         rotate amounts.
122593         * lib/bitrotate.h: Doc fix, mention that N can be wider than minimally
122594         required for 16-bit and 8-bit rotates.
122595         * lib/bitrotate.h (rotl64, rotr64, rotl32, rotl32, rotl16, rotr16,
122596         rotl8, rotr8): Use UINT64_MAX, UINT32_MAX, UINT16_MAX, and
122597         UINT8_MAX instead of hard-coded constants.
122598         Suggested by Paul Eggert.
122600 2008-09-07  Bruno Haible  <bruno@clisp.org>
122602         * tests/test-striconveh.c (main): Check behaviour when converting from
122603         UTF-7.
122605         Make striconveh work better with stateful encodings.
122606         * lib/striconveh.c (iconv_carefully, iconv_carefully_1): Don't assume
122607         that iconv does not increment the inptr when returning -1/EINVAL.
122609 2008-09-07  Bruno Haible  <bruno@clisp.org>
122611         * build-aux/config.rpath: Update according to libtool-2.2.6.
122612         * build-aux/config.libpath: Likewise.
122614 2008-09-06  Bruno Haible  <bruno@clisp.org>
122616         * lib/freadahead.c (freadahead): Add conditional for SLOW_BUT_NO_HACKS.
122617         * lib/freadptr.c (freadptr): Likewise.
122618         * lib/freadseek.c (freadptrinc): Likewise.
122619         Reported by Simon Josefsson.
122621 2008-09-06  Bruno Haible  <bruno@clisp.org>
122623         * modules/freadptr (License): Change to LGPLv2+.
122624         * modules/freadseek (License): Likewise.
122625         Suggested by Eric Blake.
122627         * modules/memchr2 (License): Change to LGPLv2+.
122628         Approved by Eric Blake.
122630 2008-09-04  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
122631             Bruno Haible  <bruno@clisp.org>
122633         Make gnulib-tool work with native 'sed' on AIX.
122634         * gnulib-tool (sed_noop): New variable.
122635         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am, func_import,
122636         func_add_or_update, func_create_testdir): Use it to initialize sed
122637         script variables.
122638         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
122640 2008-09-04  Albert Chin  <bug-gnulib@mlists.thewrittenword.com>
122641             Bruno Haible  <bruno@clisp.org>
122643         * m4/include_next.m4 (gl_INCLUDE_NEXT): Add check whether #include_next
122644         also works after #include directives.
122646 2008-09-04  Ondřej Vašík  <ovasik@redhat.com>
122648         getdate.y: reject an out-of-range timezone value
122649         * lib/getdate.y (time_zone_hhmm): Reject any TZ offset that is outside
122650         the range [-24...+24].  When specified with only one or two digits,
122651         * tests/test-getdate.c: Tests for the fix.
122652         * doc/getdate.texi: Document this change.
122654 2008-09-03  Bruno Haible  <bruno@clisp.org>
122656         * doc/glibc-functions/strverscmp.texi: Mention the strverscmp module.
122658 2008-09-02  Simon Josefsson  <simon@josefsson.org>
122660         * lib/bitrotate.h (rotl64, rotr64): Add.  Suggested by Bruce Korb
122661         <bruce.korb@gmail.com> with ideas from Ben Pfaff
122662         <blp@cs.stanford.edu>, Bruno Haible <bruno@clisp.org> and Eric
122663         Blake <ebb9@byu.net>.
122665         * tests/test-bitrotate.c: Add more test vectors.
122667 2008-09-02  Eric Blake  <ebb9@byu.net>
122669         vasnprintf-posix: handle large precision via %.*d
122670         * lib/vasnprintf.c (VASNPRINTF): Don't pass precision to snprintf
122671         when handling it ourselves.
122672         * tests/test-vasnprintf-posix.c (test_function): Add test.
122673         * tests/test-snprintf-posix.h (test_function): Likewise.
122674         * tests/test-sprintf-posix.h (test_function): Likewise.
122675         * tests/test-vasprintf-posix.c (test_function): Likewise.
122676         Reported by Alain Guibert.
122678 2008-09-01  Eric Blake  <ebb9@byu.net>
122680         c-stack: make configure-time check more robust
122681         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check for
122682         successful sigaction call.
122683         Reported by Tom G. Christensen.
122685 2008-09-01  Bruno Haible  <bruno@clisp.org>
122687         New module 'findprog-lgpl'.
122688         * modules/findprog-lgpl: New file.
122689         * lib/findprog-lgpl.c: New file.
122690         * lib/findprog.c: Compile nothing in findprog.c if findprog-lgpl.c is
122691         also compiled. Consider the possibly defined symbol IN_FINDPROG_LGPL
122692         to decide whether to use strdup or xstrdup, concatenated_filename or
122693         xconcatenated_filename.
122695 2008-09-01  Bruno Haible  <bruno@clisp.org>
122697         Split module 'concat-filename' into 'concat-filename' (LGPL) and
122698         'xconcat-filename' (GPL).
122699         * modules/concat-filename (Depends-on): Add malloc-posix, remove xalloc.
122700         (License): Change to LGPLv2+.
122701         * modules/xconcat-filename: New file.
122702         * lib/concat-filename.h (concatenated_filename): Change specification.
122703         (xconcatenated_filename): New declaration.
122704         * lib/concat-filename.c: Include errno.h, stdlib.h, not xalloc.h.
122705         (concatenated_filename): Use malloc instead of xalloc. Handle out-of-
122706         memory situations.
122707         * lib/xconcat-filename.c: New file.
122708         * NEWS: Mention the change.
122709         * lib/findprog.c: Include concat-filename.h, not filename.h.
122710         (find_in_path): Use xconcatenated_filename instead of
122711         concatenated_filename.
122712         * lib/javacomp.c: Include concat-filename.h, not filename.h.
122713         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
122714         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
122715         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
122716         is_oldgcj_14_13_usable, is_javac_usable): Use xconcatenated_filename
122717         instead of concatenated_filename.
122718         * lib/javaexec.c: Include concat-filename.h, not filename.h.
122719         (execute_java_class): Use xconcatenated_filename instead of
122720         concatenated_filename.
122721         * modules/findprog (Depends-on): Add xconcat-filename, remove filename.
122722         * modules/javacomp (Depends-on): Likewise.
122723         * modules/javaexec (Depends-on): Likewise.
122725 2008-09-01  Bruno Haible  <bruno@clisp.org>
122727         Split module 'filename' into 'filename' and 'concat-filename'.
122728         * modules/filename: Keep only lib/filename.h.
122729         (License): Change to LGPLv2+.
122730         * modules/concat-filename: New file, extracted from modules/filename.
122731         * lib/filename.h (concatenated_filename): Remove declaration.
122732         * lib/concat-filename.h: New file, extracted from lib/filename.h.
122733         * lib/concat-filename.c: Include concat-filename.h.
122734         * NEWS: Mention the change.
122736 2008-09-01  Simon Josefsson  <simon@josefsson.org>
122738         * lib/bitrotate.h (rotl8, rotr8): Add.
122740         * modules/bitrotate (configure.ac): Need
122741         AC_REQUIRE([AC_C_INLINE]).
122742         (Description): Mention stdint.h.  Reported by Bruno Haible
122743         <bruno@clisp.org>.
122745         * lib/bitrotate.h (rotr16, rotl16): Fix mask value.  Reported by
122746         Paolo Bonzini <bonzini@gnu.org>.
122748 2008-08-31  Bruno Haible  <bruno@clisp.org>
122750         Assume Solaris specific bi-arch conventions on Solaris systems.
122751         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On Solaris in 64-bit
122752         mode, set acl_libdirstem to lib/64. Also set acl_libdirstem2.
122753         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): If acl_libdirstem does not
122754         work, try acl_libdirstem2 as fallback. Otherwise treat acl_libdirstem2
122755         like acl_libdirstem.
122756         (AC_LIB_LINKFLAGS_FROM_LIBS): Treat acl_libdirstem2 like
122757         acl_libdirstem.
122758         * NEWS: Mention the change.
122759         Reported by Ben Taylor <bentaylor.solx86@gmail.com>.
122761 2008-08-31  Jim Meyering  <meyering@redhat.com>
122763         * lib/strftime.h: Add comments describing the two added arguments.
122765         remove duplicate #include directives
122766         * lib/chdir-long.c [TEST_CHDIR]: Remove duplicate #include <stdio.h>.
122767         * lib/putenv.c: Remove duplicate #include <stdlib.h>.
122769 2008-08-31  Bruno Haible  <bruno@clisp.org>
122771         New module 'sigpipe-die'.
122772         * modules/sigpipe-die: New file.
122773         * lib/sigpipe-die.h: New file.
122774         * lib/sigpipe-die.c: New file.
122775         * MODULES.html.sh (Signal handling): Add sigpipe-die.
122777 2008-08-31  Bruno Haible  <bruno@clisp.org>
122779         Don't override previously installed signal handlers.
122780         * lib/fatal-signal.c (saved_sigactions): New variable.
122781         (uninstall_handlers): Reset the signal to the saved handler, not
122782         to SIG_DFL (except when ignored).
122783         (install_handlers): Save the previous handlers.
122785 2008-08-30  Bruno Haible  <bruno@clisp.org>
122787         * gnulib-tool (func_reset_sigpipe): New function.
122788         (func_get_automake_snippet, func_modules_transitive_closure,
122789         func_import): Invoke it before a join command that reads from stdin,
122790         to avoid "echo: write error: Broken pipe" error messages on stderr.
122791         Reported by Sam Steingold <sds@gnu.org>.
122793 2008-08-30  Bruno Haible  <bruno@clisp.org>
122795         * m4/fopen.m4 (gl_FUNC_FOPEN): Test against bug with trailing slash.
122796         Code copied from m4/open.m4.
122797         * lib/fopen.c (rpl_fopen): Return NULL if the mode specifies write
122798         access and the filename ends in a slash. Code copied from lib/open.c.
122799         * doc/posix-functions/fopen.texi: Document bug with trailing slash.
122800         * tests/test-fopen.c (main): Check against bug with trailing slash.
122802 2008-08-29  Bruno Haible  <bruno@clisp.org>
122804         Avoid some "gcc -pedantic" warnings.
122805         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also PRAGMA_SYSTEM_HEADER.
122806         * lib/arpa_inet.in.h: Use PRAGMA_SYSTEM_HEADER.
122807         * lib/dirent.in.h: Likewise.
122808         * lib/fcntl.in.h: Likewise.
122809         * lib/float.in.h: Likewise.
122810         * lib/iconv.in.h: Likewise.
122811         * lib/inttypes.in.h: Likewise.
122812         * lib/locale.in.h: Likewise.
122813         * lib/math.in.h: Likewise.
122814         * lib/netinet_in.in.h: Likewise.
122815         * lib/search.in.h: Likewise.
122816         * lib/signal.in.h: Likewise.
122817         * lib/stdarg.in.h: Likewise.
122818         * lib/stdint.in.h: Likewise.
122819         * lib/stdio.in.h: Likewise.
122820         * lib/stdlib.in.h: Likewise.
122821         * lib/string.in.h: Likewise.
122822         * lib/strings.in.h: Likewise.
122823         * lib/sys_select.in.h: Likewise.
122824         * lib/sys_socket.in.h: Likewise.
122825         * lib/sys_stat.in.h: Likewise.
122826         * lib/sys_time.in.h: Likewise.
122827         * lib/sysexits.in.h: Likewise.
122828         * lib/time.in.h: Likewise.
122829         * lib/unistd.in.h: Likewise.
122830         * lib/wchar.in.h: Likewise.
122831         * lib/wctype.in.h: Likewise.
122832         * modules/arpa_inet (Makefile.am): Also substitute PRAGMA_SYSTEM_HEADER.
122833         * modules/fchdir (Makefile.am): Likewise.
122834         * modules/fcntl (Makefile.am): Likewise.
122835         * modules/float (Makefile.am): Likewise.
122836         * modules/iconv_open (Makefile.am): Likewise.
122837         * modules/inttypes (Makefile.am): Likewise.
122838         * modules/locale (Makefile.am): Likewise.
122839         * modules/math (Makefile.am): Likewise.
122840         * modules/netinet_in (Makefile.am): Likewise.
122841         * modules/search (Makefile.am): Likewise.
122842         * modules/signal (Makefile.am): Likewise.
122843         * modules/stdarg (Makefile.am): Likewise.
122844         * modules/stdint (Makefile.am): Likewise.
122845         * modules/stdio (Makefile.am): Likewise.
122846         * modules/stdlib (Makefile.am): Likewise.
122847         * modules/string (Makefile.am): Likewise.
122848         * modules/strings (Makefile.am): Likewise.
122849         * modules/sys_select (Makefile.am): Likewise.
122850         * modules/sys_socket (Makefile.am): Likewise.
122851         * modules/sys_stat (Makefile.am): Likewise.
122852         * modules/sys_time (Makefile.am): Likewise.
122853         * modules/sysexits (Makefile.am): Likewise.
122854         * modules/time (Makefile.am): Likewise.
122855         * modules/unistd (Makefile.am): Likewise.
122856         * modules/wchar (Makefile.am): Likewise.
122857         * modules/wctype (Makefile.am): Likewise.
122858         Reported by Reuben Thomas <rrt@sc3d.org>.
122860 2008-08-29  Bruno Haible  <bruno@clisp.org>
122862         * m4/include_next.m4 (gl_INCLUDE_NEXT): Don't define HAVE_INCLUDE_NEXT
122863         any more.
122865 2008-08-29  Simon Josefsson  <simon@josefsson.org>
122867         * MODULES.html.sh (Misc): Add bitrotate.
122869         * modules/bitrotate: New file.
122871         * lib/bitrotate.h: New file.
122873         * modules/bitrotate-tests: New file.
122875         * tests/test-bitrotate.c: New file.
122877         * modules/crypto/gc-arctwo, modules/crypto/arctwo: Add dependency
122878         on the bitrotate module.
122880         * lib/arctwo.c: Use new bitrotate module.
122882 2008-08-29  Jim Meyering  <meyering@redhat.com>
122884         bootstrap: merge changes from coreutils
122885         * build-aux/bootstrap (cp_mark_as_generated): Preserve perms
122886         of copied files.  Remove a kludge, now that this is fixed.
122887         * build-aux/bootstrap: Fix unportable expr usage. (by Ralf Wildenhues)
122888         * build-aux/bootstrap: Remove $bt and $bt2 also when not using gettext.
122889         * build-aux/bootstrap: Remove coreutils-specific SUBDIRS-related code.
122891 2008-08-29  Bruno Haible  <bruno@clisp.org>
122893         * MODULES.html.sh: Remove --cvs-urls option.
122895 2008-08-28  Jose E. Marchesi  <jemarch@gnu.org>  (tiny change)
122897         maint.mk: adjust to file name change
122898         * top/maint.mk: s/Makefile.cfg/cfg.mk/.
122900 2008-08-28  Jim Meyering  <meyering@redhat.com>
122902         * modules/getndelim2 (License): Relicense to LGPLv2+.
122903         Approved by Richard Stallman for the version of 1995, and by
122904         Paul Eggert, Bruno Haible, Eric Blake for their contributions.
122906 2008-08-27  Paolo Bonzini  <bonzini@gnu.org>
122908         * lib/getdelim.c (flockfile, funlockfile): Make all of them
122909         dummy if one is not available.  Do not touch them if
122910         USE_UNLOCKED_IO, instead letting unlocked-io.h do that.
122911         (getc_maybe_unlocked): New.
122912         * m4/getdelim.m4 (gl_PREREQ_GETDELIM): Check for getc_unlocked.
122914 2008-08-26  Eric Blake  <ebb9@byu.net>
122916         doc/INSTALL: resync from autoconf
122917         * doc/Makefile (INSTALL, INSTALL.ISO, INSTALL.UTF-8): Simplify.
122918         (INSTALL_PRELUDE): Delete; this is done more efficiently by
122919         moving...
122920         * install.texi [!autoconf]: ...here.  Resync from autoconf.
122921         * INSTALL: Regenerate.
122922         * INSTALL.ISO: New file.
122923         * INSTALL.UTF-8: Likewise.
122925 2008-08-26  Jim Meyering  <meyering@redhat.com>
122927         GNUmakefile: cfg.mk definitions override default autoreconf-rerun policy
122928         * top/GNUmakefile (_is-dist-target, _is-install-target): Make
122929         these definitions conditional, so that they may be overridden, too.
122931 2008-08-26  Bruno Haible  <bruno@clisp.org>
122933         Generate INSTALL file variants with prettier quotes.
122934         * doc/Makefile (INSTALL_PRELUDE): New macro.
122935         (INSTALL): Use it.
122936         (INSTALL.ISO, INSTALL.UTF-8): New rules.
122938 2008-08-26  Bruno Haible  <bruno@clisp.org>
122940         Run makeinfo in an English locale.
122941         * doc/Makefile (MAKEINFO): New variable.
122943 2008-08-26  Bruno Haible  <bruno@clisp.org>
122945         * doc/Makefile (INSTALL): Use --no-validate instead of --no-warn.
122946         Suggested by Eric Blake.
122948 2008-08-25  Bruno Haible  <bruno@clisp.org>
122950         * doc/Makefile (INSTALL): Generate with @firstparagraphindent set.
122952 2008-08-25  Eric Blake  <ebb9@byu.net>
122954         c-stack: test that stack overflow can be caught
122955         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Also check
122956         that platform allows handling stack overflow; at least OS/2 EMX
122957         has sigaltstack, but crashes before transferring control to
122958         handler on stack overflow.
122959         * lib/c-stack.c [HAVE_SIGALTSTACK]: Adjust conditions to also
122960         check for HAVE_STACK_OVERFLOW_HANDLING.
122961         Reported by Elbert Pol.
122963 2008-08-25  Bruno Haible  <bruno@clisp.org>
122965         * doc/posix-functions/strftime.texi: Fix description of strftime
122966         module.
122968 2008-08-24  Bruno Haible  <bruno@clisp.org>
122970         * tests/uniwidth/test-uc_width2.c: New file.
122971         * tests/uniwidth/test-uc_width2.sh: New file.
122972         * modules/uniwidth/width-tests (Files): Add the new files.
122973         (TESTS): Add uniwidth/test-uc_width2.sh.
122974         (TESTS_ENVIRONMENT): New variable.
122975         (check_PROGRAMS): Add test-uc_width2.
122976         (test_uc_width2_SOURCES): New variable.
122978         Fix uc_width(0x00AB) bug, introduced on 2007-07-08.
122979         * lib/uniwidth/width.c (nonspacing_table_data): Set bit for 0x00AD,
122980         not 0x00AB.
122981         Reported by Alexander V. Lukyanov <lav@netis.ru>.
122983 2008-08-22  Eric Blake  <ebb9@byu.net>
122985         test-lock, test-tls: mention why a test is skipped
122986         * tests/test-lock.c (main) [!USE_*_THREADS]: Print why test is
122987         skipped.
122988         * tests/test-tls.c (main) [!USE_*_THREADS]: Likewise.
122990         count-one-bits: relax license
122991         * modules/count-one-bits (License): Relicense to LGPLv2+.
122992         Suggested by Ludovic Courtès, approved by Ben Pfaff.
122994 2008-08-22  Andreas Schwab  <schwab@suse.de>
122996         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX):
122997         Remove spurious space in assignment.
122999 2008-08-21  Simon Josefsson  <simon@josefsson.org>
123001         * m4/autobuild.m4: Use TZ=UTC0 instead of TZ=UTC.  Reported by
123002         Paul Eggert <eggert@CS.UCLA.EDU>.
123004 2008-08-20  Paolo Bonzini  <bonzini@gnu.org>
123006         * modules/gettext: Add m4/threadlib.m4.
123008 2008-08-19  Eric Blake  <ebb9@byu.net>
123010         test-c-stack: fix compilation failure on FreeBSD 5.0
123011         * tests/test-c-stack.c [HAVE_SETRLIMIT]: Include prerequisite
123012         headers before <sys/resource.h>.
123013         * doc/posix-headers/sys_resource.texi (sys/resource.h): Document
123014         the bug.
123015         Reported by Nelson H. F. Beebe.
123017         strverscmp: migrate from "strverscmp.h" to <string.h>
123018         * modules/string (Makefile.am): Add new hooks.
123019         * modules/strverscmp (Files): Remove strverscmp.h.
123020         (Depends-on): Add string.
123021         (configure.ac): Add indicator.
123022         (Include): Mention new header.
123023         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Provide new
123024         defaults.
123025         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Inform string module of
123026         results.
123027         * lib/strverscmp.h: Delete.
123028         * lib/string.in.h (strverscmp): Provide declaration, when needed.
123029         * tests/test-strverscmp.c (includes): Adjust client.
123030         * lib/check-version.c (includes): Likewise.
123031         * NEWS: Document the change.
123033         strverscmp: add unit test
123034         * modules/strverscmp-tests: New file.
123035         * tests/test-strverscmp.c: Likewise.
123037 2008-08-19  Simon Josefsson  <simon@josefsson.org>
123039         * lib/gc-gnulib.c: Indentation cleanup.  Add some comments
123040         regarding Windows crypto stuff, from Mono.
123042 2008-08-19  Adam Strzelecki  <ono@java.pl>  (tiny change)
123044         * lib/gc-gnulib.c: Use CRYPT_VERIFY_CONTEXT.  Try to use Intel CSP
123045         if present, for intel RND.  Return error on failures.
123047 2008-08-18  Ben Pfaff  <blp@gnu.org>
123049         gitlog-to-changelog: give better diagnostic for failed pipe-open
123050         * build-aux/gitlog-to-changelog: Improve error message: suggest
123051         that the version of Git may be too old.
123053 2008-08-18  Simon Josefsson  <simon@josefsson.org>
123055         * m4/autobuild.m4: Use TZ=UTC to avoid time zone complexity.  Use
123056         ISO 8601 format.  Suggested by Greg Troxel <gdt@ir.bbn.com>.
123058 2008-08-18  Bruno Haible  <bruno@clisp.org>
123060         * lib/glthread/thread.h [USE_SOLARIS_THREADS]: Use thread_in_use(), not
123061         pthread_in_use().
123063 2008-08-18  Bruno Haible  <bruno@clisp.org>
123065         * lib/glthread/threadlib.c: Include <pthread.h>.
123067 2008-08-18  Bruno Haible  <bruno@clisp.org>
123069         * lib/glthread/lock.h [USE_SOLARIS_THREADS]: Fix
123070         glthread_recursive_lock_* macros.
123071         * lib/glthread/lock.c (glthread_recursive_lock_destroy_multithreaded):
123072         Fix syntax error.
123074 2008-08-18  Bruno Haible  <bruno@clisp.org>
123076         * lib/glthread/thread.c: Avoid forcing a context switch right after
123077         thread creation.
123079 2008-08-17  Bruno Haible  <bruno@clisp.org>
123081         * lib/glthread/thread.c: New file, based on code from tests/test-lock.c.
123082         * lib/glthread/thread.h: Provide Win32 specific implementation.
123083         * modules/thread (Files): Add lib/glthread/thread.c.
123084         (Depends-on): Add lock.
123085         (Makefile.am): Add glthread/thread.c to lib_SOURCES.
123087 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
123089         New module 'yield'.
123090         * modules/yield: New file.
123091         * lib/glthread/yield.h: New file.
123092         * m4/yield.m4: New file.
123093         * MODULES.html.sh (Multithreading): Add yield.
123095 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
123097         New module 'thread'.
123098         * modules/thread: New file.
123099         * lib/glthread/thread.h: New file.
123100         * m4/thread.m4: New file.
123101         * MODULES.html.sh (Multithreading): Add thread.
123103 2008-08-17  Bruno Haible  <bruno@clisp.org>
123105         * lib/glthread/lock.h: Include <stdlib.h> always.
123106         * lib/glthread/tls.h: Likewise.
123107         * lib/glthread/cond.h: Likewise.
123109 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
123111         New module 'cond'.
123112         * modules/cond: New file.
123113         * lib/glthread/cond.h: New file.
123114         * lib/glthread/cond.c: New file.
123115         * m4/cond.m4: New file.
123116         * MODULES.html.sh (Multithreading): Add cond.
123118 2008-08-16  Eric Blake  <ebb9@byu.net>
123120         c-stack: fix regression on Irix 5.3 from 2008-06-21
123121         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Move check for
123122         sa_sigaction...
123123         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): ...here.
123124         (gl_PREREQ_SIGACTION): Depend on sig-handler.h prereq's.
123125         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Set the default.
123126         * modules/signal (Makefile.am): Use the value.
123127         * lib/signal.in.h (sa_sigaction) [HAVE_SIGACTION
123128         && !HAVE_STRUCT_SIGACTION_SA_SIGACTION]: Define.
123129         * doc/posix-headers/signal.texi (signal.h): Document this
123130         portability issue.
123131         * doc/posix-functions/sigaction.texi (sigaction): Likewise.
123132         Reported by Tom G. Christensen.
123134 2008-08-17  Bruno Haible  <bruno@clisp.org>
123136         New module 'threadlib'.
123137         * modules/threadlib: New file.
123138         * lib/glthread/threadlib.c: New file, extracted from
123139         lib/glthread/lock.c.
123140         * lib/glthread/lock.c (dummy_thread_func, glthread_in_use): Remove
123141         functions.
123142         * m4/threadlib.m4: New file, from m4/lock.m4, renaming gl_LOCK to
123143         gl_THREADLIB and gl_LOCK_EARLY to gl_THREADLIB_EARLY.
123144         * m4/lock.m4 (gl_LOCK_EARLY, gl_LOCK_EARLY_BODY, gl_LOCK_BODY): Remove
123145         macros.
123146         (gl_LOCK): Just require gl_THREADLIB and perform checks for lock.h.
123147         (gl_DISABLE_THREADS): Remove macro.
123148         * modules/lock (Files): Remove build-aux/config.rpath.
123149         (Depends-on): Remove havelib. Add threadlib.
123150         (configure.ac-early): Remove section.
123151         * m4/tls.m4 (gl_TLS): Require gl_THREADLIB instead of gl_LOCK.
123152         * modules/tls (Depends-on): Remove lock. Add threadlib.
123153         (Link): New section, copied from threadlib.
123154         * MODULES.html.sh (Multithreading): Add threadlib.
123156 2008-08-14  Bruno Haible  <bruno@clisp.org>
123158         * lib/glthread/lock.h (glthread_lock_lock, glthread_lock_unlock,
123159         glthread_lock_destroy, glthread_rwlock_rdlock, glthread_rwlock_wrlock,
123160         glthread_rwlock_unlock, glthread_rwlock_destroy,
123161         glthread_recursive_lock_lock, glthread_recursive_lock_unlock,
123162         glthread_recursive_lock_destroy): Define as macros always.
123163         * lib/glthread/lock.c (glthread_lock_lock_func): Renamed from
123164         glthread_lock_lock.
123165         (glthread_lock_unlock_func): Renamed from glthread_lock_unlock.
123166         (glthread_lock_destroy_func): Renamed from glthread_lock_destroy.
123167         (glthread_rwlock_rdlock_func): Renamed from glthread_rwlock_rdlock.
123168         (glthread_rwlock_wrlock_func): Renamed from glthread_rwlock_wrlock.
123169         (glthread_rwlock_unlock_func): Renamed from glthread_rwlock_unlock.
123170         (glthread_rwlock_destroy_func): Renamed from glthread_rwlock_destroy.
123171         (glthread_recursive_lock_lock_func): Renamed from
123172         glthread_recursive_lock_lock.
123173         (glthread_recursive_lock_unlock_func): Renamed from
123174         glthread_recursive_lock_unlock.
123175         (glthread_recursive_lock_destroy_func): Renamed from
123176         glthread_recursive_lock_destroy.
123178 2008-08-14  Bruno Haible  <bruno@clisp.org>
123180         * lib/glthread/lock.h: Renamed from lib/lock.h.
123181         * lib/glthread/lock.c: Renamed from lib/lock.c. Update includes.
123182         * lib/glthread/tls.h: Renamed from lib/tls.h.
123183         * lib/glthread/tls.c: Renamed from lib/tls.c. Update includes.
123184         * lib/fstrcmp.c: Update includes.
123185         * lib/strsignal.c: Update includes.
123186         * modules/lock (Files, Makefile.am): Update.
123187         (Include): Change to "glthread/lock.h".
123188         * modules/tls (Files, Makefile.am): Update.
123189         (Include): Change to "glthread/tls.h".
123190         * tests/test-lock.c: Update includes.
123191         * tests/test-tls.c: Update includes.
123192         * NEWS: Mention the renamed header files.
123194 2008-08-11  Jim Meyering  <meyering@redhat.com>
123196         * lib/fts_.h: Fix grammar (insert a missing "is") in a comment.
123198 2008-08-11  Eric Blake  <ebb9@byu.net>
123200         test-c-stack: avoid C99-ism
123201         * tests/test-c-stack.c (main): Fix whitespace, move declaration
123202         before statement.
123203         Reported by Alain Guibert.
123205 2008-08-10  Jim Meyering  <meyering@redhat.com>
123207         ensure that return value of uinttostr et al are not ignored
123208         * lib/inttostr.h (__GNUC_PREREQ): Define.
123209         (__attribute_warn_unused_result__): Define.
123210         (offtostr, imaxtostr, umaxtostr, uinttostr): Apply the attribute.
123212 2008-08-07  Paolo Bonzini  <bonzini@gnu.org>
123214         * lib/lock.c (glthread_recursive_lock_init_multithreaded)
123215         [!PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Fix typo.
123217 2008-08-07  Jim Meyering  <meyering@redhat.com>
123219         * m4/inet_pton.m4: Fix typo in comment: s/inet_ntop/inet_pton/.
123221         * modules/mkstemp (License): Relicense under LGPLv2+.
123222         * modules/tempname (License): Likewise.
123224 2008-08-06  Bruno Haible  <bruno@clisp.org>
123226         * lib/poll.c (poll): Further micro-optimization.
123228 2008-08-06  Jim Meyering  <meyering@redhat.com>
123230         inet_pton.c: use locale-independent tolower
123231         * lib/inet_pton.c: Include <c-ctype.h> rather than <ctype.h>.
123232         (inet_pton6): Use c_tolower rather than tolower.
123233         * modules/inet_pton (Depends-on): Add c-ctype.
123235 2008-08-06  Paolo Bonzini  <bonzini@gnu.org>
123237         * lib/poll.c (poll): Avoid division when timeout is 0, cache
123238         _SC_OPEN_MAX, avoid repeated access to errno.  Check for nfd < 0.
123240 2008-08-06  Jim Meyering  <meyering@redhat.com>
123242         * modules/inet_pton (License): Relicense under LGPLv2+.
123244 2008-08-03  Bruno Haible  <bruno@clisp.org>
123246         Additional non-aborting API for lock and tls.
123247         * lib/lock.h: Include <errno.h>.
123248         (glthread_lock_init): New macro/function.
123249         (gl_lock_init): Define as wrapper around glthread_lock_init.
123250         (glthread_lock_lock): New macro/function.
123251         (gl_lock_lock): Define as wrapper around glthread_lock_lock.
123252         (glthread_lock_unlock): New macro/function.
123253         (gl_lock_unlock): Define as wrapper around glthread_lock_unlock.
123254         (glthread_lock_destroy): New macro/function.
123255         (gl_lock_destroy): Define as wrapper around glthread_lock_destroy.
123256         (glthread_rwlock_init): New macro/function.
123257         (gl_rwlock_init): Define as wrapper around glthread_rwlock_init.
123258         (glthread_rwlock_rdlock): New macro/function.
123259         (gl_rwlock_rdlock): Define as wrapper around glthread_rwlock_rdlock.
123260         (glthread_rwlock_wrlock): New macro/function.
123261         (gl_rwlock_wrlock): Define as wrapper around glthread_rwlock_wrlock.
123262         (glthread_rwlock_unlock): New macro/function.
123263         (gl_rwlock_unlock): Define as wrapper around glthread_rwlock_unlock.
123264         (glthread_rwlock_destroy): New macro/function.
123265         (gl_rwlock_destroy): Define as wrapper around glthread_rwlock_destroy.
123266         (glthread_recursive_lock_init): New macro/function.
123267         (gl_recursive_lock_init): Define as wrapper around
123268         glthread_recursive_lock_init.
123269         (glthread_recursive_lock_lock): New macro/function.
123270         (gl_recursive_lock_lock): Define as wrapper around
123271         glthread_recursive_lock_lock.
123272         (glthread_recursive_lock_unlock): New macro/function.
123273         (gl_recursive_lock_unlock): Define as wrapper around
123274         glthread_recursive_lock_unlock.
123275         (glthread_recursive_lock_destroy): New macro/function.
123276         (gl_recursive_lock_destroy): Define as wrapper around
123277         glthread_recursive_lock_destroy.
123278         (glthread_once): New macro/function.
123279         (gl_once): Define as wrapper around glthread_once.
123280         Update function declarations.
123281         * lib/lock.c (glthread_rwlock_init_multithreaded): Renamed from
123282         glthread_rwlock_init. Return error code.
123283         (glthread_rwlock_rdlock_multithreaded): Renamed from
123284         glthread_rwlock_rdlock. Return error code.
123285         (glthread_rwlock_wrlock_multithreaded): Renamed from
123286         glthread_rwlock_wrlock. Return error code.
123287         (glthread_rwlock_unlock_multithreaded): Renamed from
123288         glthread_rwlock_unlock. Return error code.
123289         (glthread_rwlock_destroy_multithreaded): Renamed from
123290         glthread_rwlock_destroy. Return error code.
123291         (glthread_recursive_lock_init_multithreaded): Renamed from
123292         glthread_recursive_lock_init. Return error code.
123293         (glthread_recursive_lock_lock_multithreaded): Renamed from
123294         glthread_recursive_lock_lock. Return error code.
123295         (glthread_recursive_lock_unlock_multithreaded): Renamed from
123296         glthread_recursive_lock_unlock. Return error code.
123297         (glthread_recursive_lock_destroy_multithreaded): Renamed from
123298         glthread_recursive_lock_destroy. Return error code.
123299         (glthread_once_call): Make static.
123300         (glthread_once_multithreaded): Renamed from glthread_once.
123301         * lib/tls.h: Include <errno.h>.
123302         (glthread_tls_key_init): New macro/function.
123303         (gl_tls_key_init): Define as wrapper around glthread_tls_key_init.
123304         (glthread_tls_set): New macro/function.
123305         (gl_tls_set): Define as wrapper around glthread_tls_set.
123306         (glthread_tls_key_destroy): New macro/function.
123307         (gl_tls_key_destroy): Define as wrapper around glthread_tls_key_destroy.
123308         Update function declarations.
123309         * lib/tls.c (glthread_tls_get_multithreaded): Renamed from
123310         glthread_tls_get.
123311         Suggested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
123313 2008-08-04  Eric Blake  <ebb9@byu.net>
123315         gnumakefile: use space, not TAB, outside of targets
123316         * top/GNUmakefile (_dummy): Fix whitespace error in prior edit.
123318 2008-08-02  Jim Meyering  <meyering@redhat.com>
123320         getdate.y: avoid locale-dependent date parsing failure
123321         In Turkish locales, getdate would fail to recognize keywords
123322         containing a lowercase "i".  The solution is not to rely on
123323         locale-sensitive case-conversion.
123324         * lib/getdate.y: Include <c-ctype.h> rather than <ctype.h>.
123325         (lookup_word): Use c_toupper in place of toupper.
123326         (yylex, get_date): Use c_ prefixed variants of isspace and isalpha, too.
123327         Reported by Vefa Bicakci <bicave@superonline.com> in
123328         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/14184>.
123329         * modules/getdate (Depends-on): Add c-ctype.
123331 2008-08-02  Bruno Haible  <bruno@clisp.org>
123333         * gnulib-tool (func_import): When updating or creating a .gitignore
123334         file, prepend each added line with a slash, and ignore leading slashes
123335         from the existing lines.
123336         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
123338 2008-08-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
123340         Portability fix for GNU make 3.79.1.
123341         * top/GNUmakefile: Avoid 'else COND', which older GNU make
123342         versions do not understand.
123344 2008-08-01  Bruno Haible  <bruno@clisp.org>
123346         Work around bug of HP-UX 10.20 cc with -0.0 literal.
123347         * tests/test-isnanf.h (zero): New variable.
123348         (main): Avoid literal -0.0f.
123349         * tests/test-isnand.h (zero): New variable.
123350         (main): Avoid literal -0.0.
123351         * tests/test-isnanl.h (zero): New variable.
123352         (main): Avoid literal -0.0L.
123353         * tests/test-isnan.c (zerof, zerod, zerol): New variables.
123354         (test_float, test_double, test_long_double): Avoid literals -0.0f,
123355         -0.0, -0.0L.
123356         * tests/test-signbit.c (test_signbitf): Avoid literal -0.0f.
123357         (test_signbitd): Avoid literal -0.0.
123358         (test_signbitl): Avoid literal -0.0L.
123359         * tests/test-ceilf1.c (zero): New variable.
123360         (main): Avoid literal -0.0f.
123361         * tests/test-ceill.c (zero): New variable.
123362         (main): Avoid literal -0.0L.
123363         * tests/test-floorf1.c (zero): New variable.
123364         (main): Avoid literal -0.0f.
123365         * tests/test-floorl.c (zero): New variable.
123366         (main): Avoid literal -0.0L.
123367         * tests/test-roundf1.c (zero): New variable.
123368         (main): Avoid literal -0.0f.
123369         * tests/test-round1.c (zero): New variable.
123370         (main): Avoid literal -0.0.
123371         * tests/test-roundl.c (zero): New variable.
123372         (main): Avoid literal -0.0L.
123373         * tests/test-truncf1.c (zero): New variable.
123374         (main): Avoid literal -0.0f.
123375         * tests/test-trunc1.c (zero): New variable.
123376         (main): Avoid literal -0.0.
123377         * tests/test-truncl.c (zero): New variable.
123378         (main): Avoid literal -0.0L.
123379         * tests/test-frexp.c (zero): New variable.
123380         (main): Avoid literal -0.0.
123381         * tests/test-frexpl.c (zero): New variable.
123382         (main): Avoid literal -0.0L.
123383         * tests/test-ldexpl.c (zero): New variable.
123384         (main): Avoid literal -0.0L.
123385         * tests/test-snprintf-posix.h (have_minus_zero): Avoid literal -0.0.
123386         (zerod, zerol): New variables.
123387         (test_function): Avoid literals -0.0, -0.0L.
123388         * tests/test-sprintf-posix.h (have_minus_zero): Avoid literal -0.0.
123389         (zerod, zerol): New variables.
123390         (test_function): Avoid literals -0.0, -0.0L.
123391         * tests/test-vasnprintf-posix.c (have_minus_zero): Avoid literal -0.0.
123392         (zerod, zerol): New variables.
123393         (test_function): Avoid literals -0.0, -0.0L.
123394         * tests/test-vasprintf-posix.c (have_minus_zero): Avoid literal -0.0.
123395         (zerod, zerol): New variables.
123396         (test_function): Avoid literals -0.0, -0.0L.
123397         * tests/test-strtod.c (zero): New variable.
123398         (main): Avoid literal -0.0.
123399         Reported by Jonathan C. Patschke <jp@centtech.com>.
123401 2008-07-31  Jim Meyering  <meyering@redhat.com>
123403         sha256.h: correct definition of SHA224_DIGEST_SIZE
123404         * lib/sha256.h (SHA224_DIGEST_SIZE): Define to 28, not 24.
123405         Reported by Paulie Pena IV <paulie4@gmail.com>.
123406         Define as 224 / 8, rather than as a literal.
123407         (SHA256_DIGEST_SIZE): Define as 256/8 rather than equivalent literal.
123408         * lib/sha512.h (SHA384_DIGEST_SIZE): Likewise, define as equiv: 384/8.
123409         (SHA512_DIGEST_SIZE): Likewise, define as equivalent quotient: 512/8.
123411 2008-07-31  Bruno Haible  <bruno@clisp.org>
123413         * lib/regex_internal.h (BITSET_WORD_BITS): Make first conditional work
123414         on HP-UX 10.20 with "cc -Ae". Fix second conditional.
123415         Reported by Jonathan Patschke <jp@centtech.com>.
123417 2008-07-31  Bruno Haible  <bruno@clisp.org>
123419         * gnulib-tool (func_import): Make change from 2008-06-23 more robust.
123420         Reported by Paolo Bonzini <bonzini@gnu.org>.
123422 2008-07-30  Eric Blake  <ebb9@byu.net>
123424         test-strtod: allow compilation without -lm
123425         * tests/test-strtod.c (main): Avoid link dependence on fabs.
123426         Reported by Dennis Clarke <blastwave@gmail.com>.
123428 2008-07-28  Jim Meyering  <meyering@redhat.com>
123430         bootstrap: work also when there are no .po files in po/
123431         * build-aux/bootstrap (update_po_files): Complete the change
123432         that I began in bc960df8c789c878f1c1c54a28a3c2648dead8d9.
123434 2008-07-27  Jim Meyering  <meyering@redhat.com>
123436         * users.txt: Add zile.
123438 2008-07-26  Ben Pfaff  <blp@gnu.org>
123440         Add missing dependencies on new m4/exponent[fdl].m4 files.
123441         * modules/isnanf-nolibm: Add m4/exponentf.m4.
123442         * modules/isnand-nolibm: Add m4/exponentd.m4.
123443         * modules/isnanl-nolibm: Add m4/exponentl.m4.
123444         * modules/signbit-tests: Use m4/exponent[fdl].m4 instead of
123445         m4/isnan[fdl].m4, because the macros actually used moved.
123446         Reported by Jim Meyering.
123448 2008-07-14  Ben Pfaff  <blp@gnu.org>
123450         Add isinf module.
123451         * lib/isinf.c: New file.
123452         * lib/math.in.h: Define isinf macro if we have decided to replace
123453         it.
123454         * m4/isinf.m4: New file.
123455         * m4/math_h.m4: Initialize and substitute variables for isinf
123456         module.
123457         * modules/isinf: New file.
123458         * modules/isinf-tests: New file.
123459         * modules/math: Add substitutions for new module.
123460         * tests/test-isinf.c: New file.
123461         * doc/posix-functions/isinf.texi: Mention new module.
123462         * MODULES.html.sh: Mention new module.
123464 2008-07-14  Ben Pfaff  <blp@gnu.org>
123466         Factor out some macros for use by additional modules.
123467         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Move into new file
123468         exponentf.m4.
123469         * m4/isnand.m4 (gl_DOUBLE_EXPONENT_LOCATION): Move into new file
123470         exponentd.m4.
123471         * m4/isnanl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Move into new
123472         file exponentl.m4.
123473         * m4/exponentf.m4: New file.
123474         * m4/exponentd.m4: New file.
123475         * m4/exponentl.m4: New file.
123476         * modules/isnanf: Use new file m4/exponentf.m4.
123477         * modules/isnand: Use new file m4/exponentd.m4.
123478         * modules/isnanl: Use new file m4/exponentl.m4.
123480 2008-07-23  Ulrich Drepper  <drepper@redhat.com>
123482         mktime.c: normalize tp->tm_isdst value to -1/0/1.
123483         * lib/mktime.c (__mktime_internal): Normalize tp->tm_isdst value.
123484         Reported by Michael Ringe <Michael.Ringe@gmx.de> in
123485         <http://sourceware.org/bugzilla/show_bug.cgi?id=6723>.
123487         * lib/canonicalize-lgpl.c (__realpath): Avoid buffer overflow after
123488         readlink on platforms without PATH_MAX.
123490 2008-07-21  Eric Blake  <ebb9@byu.net>
123492         Warn, not fail, on stale version.
123493         * top/GNUmakefile (_curr-ver): Tone down previous patch.
123495         Don't allow installation with stale devel version number.
123496         * top/GNUmakefile (_is-install-target): New macro.
123497         (_curr-ver): Forbid installation with stale version number.
123499 2008-07-20  Bruno Haible  <bruno@clisp.org>
123501         * modules/c-stack-tests (Makefile.am): Add LIBSIGSEGV to
123502         TESTS_ENVIRONMENT.
123503         * tests/test-c-stack2.sh: React differently if LIBSIGSEGV is in use.
123505 2008-07-20  Bruno Haible  <bruno@clisp.org>
123507         * lib/c-stack.h (c_stack_action): Add documentation.
123508         * lib/c-stack.c (c_stack_action): Remove incomplete documentation.
123510 2008-07-20  Bruno Haible  <bruno@clisp.org>
123512         * modules/canonicalize-lgpl (License): Relicense under LGPLv2+.
123513         * modules/readlink (License): Likewise.
123515 2008-07-17  Eric Blake  <ebb9@byu.net>
123517         * modules/c-stack (Link): Fix typo.
123519         Make c-stack use libsigsegv, when available.
123520         * modules/c-stack (Depends-on): Add libsigsegv.
123521         * modules/c-stack-tests (Makefile.am): Link with libsigsegv, if
123522         needed.
123523         * lib/c-stack.c (SIGSTKSZ): Define fallback.
123524         (segv_handler, overflow_handler, c_stack_action)
123525         [HAVE_LIBSIGSEGV && !HAVE_XSI_STACK_OVERFLOW_HEURISTIC]: Add new
123526         implementation when libsigsegv is available, but only when using
123527         the library is necessary.
123528         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Add
123529         comment, explaining why XSI check fails on Linux.
123530         (gl_PREREQ_C_STACK): Supply LIBCSTACK, LTLIBCSTACK.
123531         * tests/test-c-stack2.sh: Tweak skip message.
123532         * NEWS: Document new link-time requirements.
123534 2008-07-16  Eric Blake  <ebb9@byu.net>
123536         c-stack: Expose false positives when not using libsigsegv.
123537         * modules/c-stack-tests (Files): Expand test.
123538         * tests/test-c-stack.c (main): Add means to conditionally trigger
123539         non-overflow SIGSEGV.
123540         * tests/test-c-stack2.sh: New file.
123542 2008-07-14  Bruno Haible  <bruno@clisp.org>
123544         * m4/libsigsegv.m4: Remove unneeded AC_PREREQ.
123545         Reported by Eric Blake.
123547 2008-07-14  Sam Steingold  <sds@gnu.org>
123548             Bruno Haible  <bruno@clisp.org>
123550         New module libsigsegv.
123551         * modules/libsigsegv: New file.
123552         * m4/libsigsegv.m4: New file, from GNU clisp sigsegv.m4 with
123553         modifications.
123554         * MODULES.html.sh (Signal handling): New section.
123556 2008-07-14  Bruno Haible  <bruno@clisp.org>
123558         * modules/unictype/ctype-* (Description): Add the word "function".
123559         Improves the resulting doc in MODULES.html.
123561 2008-07-12  Ben Pfaff  <blp@gnu.org>
123563         Add longlong module.
123564         * modules/longlong: New file.
123566 2008-07-12  Bruno Haible  <bruno@clisp.org>
123568         * m4/isnan.m4 (gl_ISNAN): When the replacement is used, set ISNAN_LIBM
123569         to empty.
123571 2008-07-10  Ben Pfaff  <blp@gnu.org>
123573         Add isnan module.
123574         * doc/posix-functions/isnan.texi: Mention new module.
123575         * lib/math.in.h: Define isnan macro if we have decided to replace
123576         it.
123577         * m4/isnan.m4: New file.
123578         * m4/isnanl.m4 (gl_FUNC_ISNANL): Factor out some code into new
123579         macro gl_BUILD_ISNANL so that isnan.m4 can use that functionality
123580         also.
123581         (gl_FUNC_ISNANL_NO_LIBM): Factor out same code, to reduce
123582         redundancy.
123583         * m4/math_h.m4: Initialize and substitute variables for isnan
123584         module.
123585         * modules/isnan: New file.
123586         * modules/isnan-tests: New file.
123587         * modules/math: Add substitutions for new module.
123588         * tests/test-isnan.c: New file.
123589         * MODULES.html.sh: Mention new module.
123591 2008-07-10  Ben Pfaff  <blp@gnu.org>
123593         Add isnanf module.
123594         * lib/isnanf.m4: New file.
123595         * m4/isnanf.m4 (gl_FUNC_ISNANF): New macro.
123596         (gl_HAVE_ISNANF_IN_LIBM): New macro.
123597         (gl_BUILD_ISNANF): New macro used by gl_FUNC_ISNANF,
123598         gl_FUNC_ISNANF_NO_LIBM, and gl_FUNC_ISNAN.
123599         * modules/isnanf: New file.
123600         * modules/isnanf-tests: New file.
123601         * modules/isnanf-nolibm-tests: Add tests/test-isnanf.h to list of
123602         files.
123603         * tests/test-isnanf-nolibm.c: factored most of its contents into
123604         new file tests/test-isnanf.h.
123605         * tests/test-isnanf.h: New file.
123606         * tests/test-isnanf.c: New file.
123607         * MODULES.html.sh: Mention new module.
123608         * doc/glibc-functions/isnanf.texi: Mention new module.
123610 2008-07-10  Ben Pfaff  <blp@gnu.org>
123612         Add isnand module.
123613         * lib/isnand.h: New file.
123614         * m4/isnand.m4 (gl_FUNC_ISNAND): New macro.
123615         (gl_FUNC_ISNAND_NO_LIBM): Split partially into new macro
123616         gl_HAVE_ISNAND_NO_LIBM so that gl_FUNC_ISNAND can use that
123617         functionality also.
123618         (gl_BUILD_ISNAND): New macro used by gl_FUNC_ISNAND,
123619         gl_FUNC_ISNAND_NO_LIBM, and gl_FUNC_ISNAN.
123620         (gl_HAVE_ISNAND_IN_LIBM): New macro.
123621         * modules/isnand: New file.
123622         * modules/isnand-tests: New file.
123623         * modules/isnand-nolibm-tests: Add tests/test-isnand.h to list of
123624         files.
123625         * tests/test-isnand-nolibm.c: factored most of its contents into
123626         new file tests/test-isnand.h.
123627         * tests/test-isnand.h: New file.
123628         * tests/test-isnand.c: New file.
123629         * MODULES.html.sh: Mention new module.
123631 2008-07-10  Ben Pfaff  <blp@gnu.org>
123633         * lib/isnanf.h: Rename lib/isnanf-nolibm.h.
123634         * lib/isnand.h: Rename lib/isnand-nolibm.h.
123635         * tests/test-isnanf.c: Rename tests/test-isnanf-nolibm.c.
123636         * tests/test-isnand.c: Rename tests/test-isnand-nolibm.c.
123637         * modules/isnanf-nolibm: Update references to renamed files.
123638         * modules/isnand-nolibm: Likewise.
123639         * modules/isnanf-nolibm-tests: Likewise.
123640         * modules/isnand-nolibm-tests: Likewise.
123641         * lib/frexp.c: Likewise.
123642         * lib/isfinite.c: Likewise.
123643         * lib/signbitd.c: Likewise.
123644         * lib/signbitf.c: Likewise.
123645         * lib/vasnprintf.c: Likewise.
123646         * tests/test-ceilf1.c: Likewise.
123647         * tests/test-ceilf2.c: Likewise.
123648         * tests/test-floorf1.c: Likewise.
123649         * tests/test-floorf2.c: Likewise.
123650         * tests/test-frexp.c: Likewise.
123651         * tests/test-round1.c: Likewise.
123652         * tests/test-round2.c: Likewise.
123653         * tests/test-roundf1.c: Likewise.
123654         * tests/test-strtod.c: Likewise.
123655         * tests/test-trunc1.c: Likewise.
123656         * tests/test-trunc2.c: Likewise.
123657         * tests/test-truncf1.c: Likewise.
123658         * tests/test-truncf2.c: Likewise.
123659         * NEWS: Mention the renamed header files.
123661 2008-07-11  Jim Meyering  <meyering@redhat.com>
123663         vc-list-files: make the last-resort awk code more portable
123664         * build-aux/vc-list-files: Don't rely on awk's "sub" command.
123665         /bin/awk from OpenSolaris 11's SUNWesu version 2008.03.22.10.56
123666         does not support it.
123668 2008-07-10  Eric Blake  <ebb9@byu.net>
123670         Work with tar's bootstrap.
123671         * gnulib-tool (func_emit_initmacro_end): Use m4_defn in the case
123672         where LIBSOURCES_DIR contains .#bootmp but must not be treated as
123673         an m4 comment.
123675 2008-07-09  Jim Meyering  <meyering@redhat.com>
123677         posix-shell.m4: fix typo that made this test malfunction
123678         * m4/posix-shell.m4: Remove capitalization in variable name.
123680 2008-07-08  Bruno Haible  <bruno@clisp.org>
123682         * m4/onceonly.m4: Update comments.
123683         Reported by Ben Pfaff <blp@cs.stanford.edu>.
123685 2008-07-04  Jim Meyering  <meyering@redhat.com>
123687         * users.txt: Add vc-dwim.
123688         (bison, coreutils): Use the gitweb URL.
123690 2008-07-03  Jim Meyering  <meyering@redhat.com>
123692         * users.txt: Add libffcall.  From Sam Steingold.
123694 2008-07-03  Ondřej Vašík  <ovasik@redhat.com>
123696         getdate.y: do not ignore TZ with relative day, month or year offset
123697         * lib/getdate.y (get_date): Move the tz-handling block to follow the
123698         relative-date-handling, since otherwise, the latter would clobber the
123699         sole output (an updated Start value) of the tz-handling block.
123700         * tests/test-getdate.c: Tests for the fix
123702 2008-07-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
123704         Recognize 'foo_LIBRARIES += libgnu.a'.
123705         * gnulib-tool (func_emit_lib_Makefile_am): Recognize if a
123706         makefile snippet has already specified an installation location,
123707         also using '+='.
123709 2008-07-02  Ondřej Vašík  <ovasik@redhat.com>
123711         getdate.y: factor out common actions
123712         * lib/getdate.y (apply_relative_time, set_hhmmss): New functions.
123713         Use them in place of open-coded actions.
123715 2008-07-01  Simon Josefsson  <simon@josefsson.org>
123717         Add self-test for getdate module.
123718         * modules/getdate-tests: New file.
123719         * tests/test-getdate.c: New file.
123721 2008-06-29  Bruno Haible  <bruno@clisp.org>
123723         * gnulib-tool (func_import): Put gnulib-comp.m4 into .cvsignore or
123724         .gitignore.
123725         Reported by Sylvain Beucler <beuc@beuc.net>.
123727 2008-06-29  Bruno Haible  <bruno@clisp.org>
123729         * doc/gnulib-tool.texi (VCS Issues): Mention --no-vc-files option.
123730         * m4/gnulib-tool.m4: Update to match current gnulib-tool.
123732 2008-06-29  Bruno Haible  <bruno@clisp.org>
123734         * gnulib-tool (func_import): Recommend to put gnulib-cache.m4 into
123735         EXTRA_DIST.
123736         Reported by Sylvain Beucler <beuc@beuc.net>.
123738 2008-06-26  Jim Meyering  <meyering@redhat.com>
123740         make several modules depend on the "open" module
123741         This provides slightly increased consistency when opening-for-write
123742         the name of a non-directory spelled with a trailing slash.
123743         * modules/chdir-safer: Likewise.
123744         * modules/chown: Likewise.
123745         * modules/clean-temp: Likewise.
123746         * modules/copy-file: Likewise.
123747         * modules/fchdir: Likewise.
123748         * modules/fcntl-safer: Likewise.
123749         * modules/pipe: Likewise.
123750         * modules/utime: Likewise.
123751         Prompted by Eric Blake and Bruno Haible.
123753 2008-06-24  Andreas Schwab  <schwab@suse.de>
123755         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Don't test whether compound
123756         literals can be used as initializers for global variables.
123758 2008-06-23  Eric Blake  <ebb9@byu.net>
123760         Make gnulib-cache.m4 easier to diff.
123761         * gnulib-tool (func_import): Allow newlines when reading cached
123762         gl_MODULES, and generate newlines when creating gnulib-cache.m4.
123764 2008-06-23  Bruno Haible  <bruno@clisp.org>
123766         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): Remove macro.
123767         (gl_PREREQ_SIGPROCMASK): Don't invoke it.
123768         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): New macro, moved here from
123769         m4/signalblocking.m4.
123770         (gl_PREREQ_SIGACTION): Don't invoke it.
123771         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Invoke
123772         gl_PREREQ_SIG_HANDLER_H.
123773         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
123774         Don't check for sigaction here.
123776 2008-06-23  Bruno Haible  <bruno@clisp.org>
123778         * lib/fatal-signal.c (fatal_signal_handler): Update comment.
123779         (install_handlers): Don't set the SA_RESETHAND flag.
123781 2008-06-23  Bruno Haible  <bruno@clisp.org>
123783         * m4/sigaction.m4: Comment fixes.
123784         * lib/signal.in.h: Likewise.
123786 2008-06-23  Eric Blake  <ebb9@byu.net>
123788         Fix typo.
123789         * tests/test-sigaction.c (MASK_SA_FLAGS): Add missing operator.
123791         Avoid SA_ namespace.
123792         * tests/test-sigaction.c (MASK_SA_FLAGS): Rename from SA_MASK.
123793         Reported by Ralf Wildenhues.
123795         Avoid test failure due to SA_RESTORER.
123796         * tests/test-sigaction.c (SA_MASK): New macro.
123797         (main): Avoid failing due to extension flags being set.
123798         Reported by Jim Meyering.
123800         Revert use of sig-handler.h in sigprocmask.c.
123801         * modules/sigprocmask (Files): Don't rely on sig-handler.h, since
123802         it requires the existence of struct sigaction.
123803         * lib/sigprocmask.c (handler_t): Restore typedef.
123804         (rpl_signal, old_handlers): Use local type.
123806 2008-06-22  Bruno Haible  <bruno@clisp.org>
123808         * tests/test-stdint.c: Disable the INTMAX_MAX preprocessor test
123809         conditionally.
123810         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
123812 2008-06-22  Bruno Haible  <bruno@clisp.org>
123814         * doc/posix-functions/siginterrupt.texi: Move note.
123816         * lib/signal.in.h (SA_RESTART): New macro.
123817         * lib/sigaction.c: Update comment.
123819         * m4/sigaction.m4 (gl_SIGACTION): Require gl_SIGNAL_H_DEFAULTS.
123821         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): New macro.
123822         (gl_PREREQ_SIGPROCMASK): Invoke it.
123823         * m4/sigaction.m4 (gl_PREREQ_SIGACTION): Likewise.
123825         * lib/nanosleep.c (rpl_nanosleep): Setup newact only when it is needed.
123827         * lib/sigprocmask.c: Update a comment.
123829 2008-06-21  Eric Blake  <ebb9@byu.net>
123831         Use sigaction module rather than signal().
123832         * modules/c-stack (Depends-on): Add sigaction.
123833         * modules/fatal-signal (Depends-on): Likewise.
123834         * modules/nanosleep (Depends-on): Likewise.
123835         * modules/sigprocmask (Files): Add sig-handler.h.
123836         * modules/sigaction (Files): Likewise.
123837         * lib/sig-handler.h (get_handler): New file, suggested by Paul
123838         Eggert.
123839         * lib/c-stack.c (SIGACTION_WORKS): Simplify conditions.
123840         (c_stack_action) [!SIGACTION_WORKS]: Use sigaction, not signal.
123841         * lib/fatal-signal.c (uninstall_handlers, install_handlers)
123842         (init_fatal_signals): Likewise.
123843         * lib/nanosleep.c (rpl_nanosleep): Likewise.
123844         (siginterrupt): Delete fallback.
123845         * lib/sigprocmask.c (handler_t, old_handlers): Use sa_handler_t
123846         instead.
123847         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Drop check for
123848         siginterrupt.
123850         New module sigaction, for mingw.
123851         * modules/sigaction: New module...
123852         * modules/sigaction-tests: ...and its test.
123853         * m4/sigaction.m4: New file.
123854         * lib/sigaction.c: Likewise.
123855         * tests/test-sigaction.c: Likewise.
123856         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Add sigaction variables.
123857         * modules/signal (Makefile.am): Likewise.
123858         * lib/signal.in.h (!@HAVE_SIGACTION@): Define replacements when
123859         needed.
123860         * doc/posix-headers/signal.texi (signal.h): Mention provided
123861         types.
123862         * doc/posix-functions/siginterrupt.texi (siginterrupt): Mention
123863         that sigaction is preferable.
123864         * doc/posix-functions/sigaction.texi (sigaction): Mention new
123865         module.
123866         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
123867         sigaction.
123869         Improve robustness of sigprocmask by overriding signal.
123870         * lib/signal.in.h (rpl_signal): Override signal when sigprocmask
123871         is in use.
123872         * lib/sigprocmask.c (blocked_handler): Reinstall block handler.
123873         (SIGKILL, SIGSTOP): Provide fallbacks.
123874         (rpl_signal): Implement.
123875         (old_handlers, blocked_set): Mark volatile, since sigprocmask and
123876         signal can be called inside handlers.
123878         Fix nanosleep module on mingw.
123879         * modules/nanosleep (Depends-on): Add sys_select.
123880         * lib/nanosleep.c (HAVE_SYS_SELECT_H): Rely on gnulib module.
123882         Fix licensing of sigprocmask.
123883         * modules/raise (License): Relicense as LGPL.
123885 2008-06-21  Bruno Haible  <bruno@clisp.org>
123887         * lib/propername.c (proper_name_utf8): Don't use the transliterated
123888         result if it contains question marks.
123889         Reported by Michael Geng <linux@michaelgeng.de>.
123891 2008-06-19  Bruno Haible  <bruno@clisp.org>
123893         Fix CVS-ism.
123894         * doc/gnulib.texi: Include updated-stamp.texi.
123895         * doc/Makefile (GNULIB_TEXI_FILES): New variable.
123896         (updated-stamp.texi): New rule.
123897         (gnulib.info): Depend on it.
123898         * doc/.gitignore: Add updated-stamp.texi.
123899         Based on a patch by Thien-Thi Nguyen <ttn@gnuvola.org>.
123901 2008-06-19  Bruno Haible  <bruno@clisp.org>
123903         * doc/Makefile (gnulib.info): Update and simplify dependencies.
123904         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
123906 2008-06-19  Eric Blake  <ebb9@byu.net>
123908         Fix VPATH 'make dist' with GNU make and non-VCS tarball.
123909         * top/GNUmakefile (_curr-ver): Don't use $(srcdir) unnecessarily.
123910         Reported by Stepan Kasal.
123912 2008-06-18  Bruno Haible  <bruno@clisp.org>
123914         * lib/fatal-signal.c (init_fatal_signals): Add comment.
123915         Reported by Eric Blake.
123917 2008-06-18  Eric Blake  <ebb9@byu.net>
123919         Work around cygwin 1.5.25 strsignal bug.
123920         * tests/test-strsignal.c: Allow for const char *.
123921         * doc/glibc-functions/strsignal.texi (strsignal): Document the bug.
123923 2008-06-18  Simon Josefsson  <simon@josefsson.org>
123925         * users.txt: Update URL to article and add author/date
123926         information.
123928 2008-06-17  Bruno Haible  <bruno@clisp.org>
123930         New macro gl_DISABLE_THREADS.
123931         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Use value gl_use_threads_default
123932         if the user did not pass --enable-threads or --disable-threads option.
123933         (gl_DISABLE_THREADS): New macro.
123934         Reported by Eric Blake <ebb9@byu.net>.
123936 2008-06-17  Bruno Haible  <bruno@clisp.org>
123938         * lib/tls.h (gl_tls_key_init): Evaluate the destructor argument also
123939         when the macro ignores it.
123940         Based on a patch by Eric Blake <ebb9@byu.net>.
123942 2008-06-17  Bruno Haible  <bruno@clisp.org>
123944         * modules/tls (License): Change to LGPLv2+.
123945         Reported by Eric Blake.
123947 2008-06-17  Eric Blake  <ebb9@byu.net>
123949         Simplify c-stack prerequisites.
123950         * lib/c-stack.c (includes): Remove unused <sys/resource.h>.
123951         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Posix 200x
123952         no longer requires <ucontext.h> to exist.  Optimize setrlimit
123953         check.
123954         (gl_PREREQ_C_STACK): Remove check for unused getcontext and
123955         <sys/resource.h>.
123957         Move c-stack test into testsuite.
123958         * modules/c-stack-tests: New file.
123959         * lib/c-stack.c [DEBUG]: Move test program...
123960         * tests/test-c-stack.c: ...into this new file.  Skip rather than
123961         fail test if sigaltstack is lacking.
123962         * tests/test-c-stack.sh: New driver file.
123964 2008-06-16  Eric Blake  <ebb9@byu.net>
123966         Use raise module consistently.
123967         * modules/fatal-signal (Depends-on): Add raise.
123968         * modules/sigprocmask (Depends-on): Likewise.
123969         * lib/fatal-signal.c (fatal_signal_handler): Rely on raise.
123970         * lib/sigprocmask.c (sigprocmask): Likewise.
123971         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
123972         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Likewise.
123974         Fix compliance bug in sigpending.
123975         * lib/sigprocmask.c (sigpending): Return pending array via
123976         parameter, not return value.
123978 2008-06-14  Eric Blake  <ebb9@byu.net>
123980         Improve obstack-printf test code.
123981         * tests/test-obstack-printf.c (test_function): Fix comment, and
123982         simplify usage of obstack_* in macros.  Add a test for coverage.
123983         Reported by Bruno Haible.
123985 2008-06-14  Bruno Haible  <bruno@clisp.org>
123987         * lib/obstack_printf.c (obstack_vprintf): Define the stack-allocated
123988         array size as a constant, not as a const variable.
123989         * m4/obstack-printf.m4 (gl_FUNC_OBSTACK_PRINTF): Require
123990         AC_USE_SYSTEM_EXTENSIONS.
123991         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
123992         Test whether the obstack_printf function actually exists.
123993         * modules/obstack-printf (Depends-on): Add extensions.
123994         (Include): Remove obstack.h.
123995         * modules/obstack-printf-posix (Depends-on): Add extensions.
123996         (Include): Remove obstack.h.
123998 2008-06-13  Eric Blake  <ebb9@byu.net>
124000         Add obstack-printf and obstack-printf-posix modules.
124001         * modules/obstack-printf: New file.
124002         * modules/obstack-printf-posix: Likewise.
124003         * MODULES.html.sh (Misc): Mention them.
124004         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
124005         Likewise.
124006         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
124007         Likewise.
124008         * modules/stdio (Makefile.am): Accomodate new modules.
124009         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
124010         * lib/stdio.in.h (rpl_obstack_printf, rpl_obstack_vprintf):
124011         Declare.
124012         * lib/obstack_printf.c (obstack_printf, obstack_vprintf): New
124013         functions.
124014         * m4/obstack-printf.m4 (gl_OBSTACK_PRINTF)
124015         (gl_REPLACE_OBSTACK_PRINTF): New macros
124016         * m4/obstack-printf-posix.m4 (gl_OBSTACK_PRINTF_POSIX): Likewise.
124017         * tests/test-obstack-printf.c: New file.
124018         * modules/obstack-printf-tests: Likewise.
124019         * modules/obstack-printf-posix-tests: Likewise.
124021 2008-06-11  Bruno Haible  <bruno@clisp.org>
124023         * m4/open.m4 (gl_FUNC_OPEN): Add test against trailing slash bug.
124024         * lib/open.c: Include errno.h.
124025         (open): Fail when attempting to write to a file that has a trailing
124026         slash.
124027         * tests/test-open.c (main): Test against trailing slash bug.
124028         * doc/posix-functions/open.texi: Mention the trailing slash bug.
124030 2008-06-10  Bruno Haible  <bruno@clisp.org>
124032         * tests/test-vc-list-files-git.sh: Make double use of 'exit'. Needed
124033         for $? to work inside the trap command, with various /bin/sh-s.
124034         * tests/test-vc-list-files-cvs.sh: Likewise.
124036 2008-06-10  Bruno Haible  <bruno@clisp.org>
124038         * lib/acl-internal.h: Don't include gettext.h here.
124039         * lib/set-mode-acl.c: Include gettext.h here.
124040         * lib/copy-acl.c: Likewise.
124042 2008-06-10  Bruno Haible  <bruno@clisp.org>
124044         * lib/wait-process.h (wait_subprocess): Add termsigp argument.
124045         * lib/wait-process.c (wait_subprocess): Likewise.
124046         * lib/execute.h (execute): Add termsigp argument.
124047         * lib/execute.c (execute): Likewise.
124048         * lib/csharpcomp.c (compile_csharp_using_pnet,
124049         compile_csharp_using_mono, compile_csharp_using_sscli): Update.
124050         * lib/csharpexec.c (execute_csharp_using_pnet,
124051         execute_csharp_using_mono, execute_csharp_using_sscli): Update.
124052         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
124053         compile_using_javac, compile_using_jikes, is_envjavac_gcj,
124054         is_envjavac_gcj43, is_gcj_present, is_gcj_43, is_javac_present,
124055         is_jikes_present): Update.
124056         * lib/javaexec.c (execute_java_class): Update.
124057         * lib/javaversion.c (execute_and_read_line): Update.
124058         * NEWS: Document the changes.
124059         Reported by Eric Blake.
124061 2008-06-10  Eric Blake  <ebb9@byu.net>
124063         Add missing include.
124064         * tests/test-strstr.c (includes): Add <signal.h>.
124065         * tests/test-strcasestr.c (includes): Likewise.
124066         * tests/test-memmem.c (includes): Likewise.
124068 2008-06-10  Bruno Haible  <bruno@clisp.org>
124070         * lib/wait-process.c (wait_subprocess): Add an assertion.
124072 2008-06-10  Bruno Haible  <bruno@clisp.org>
124074         * lib/wait-process.c (wait_subprocess): Try to fix waitid() based code.
124076 2008-06-10  Bruno Haible  <bruno@clisp.org>
124078         * tests/test-memmem.c (main): Reset SIGALRM to default handling before
124079         using alarm().
124080         * tests/test-strcasestr.c (main): Likewise.
124081         * tests/test-strstr.c (main): Likewise.
124083 2008-06-09  Bruno Haible  <bruno@clisp.org>
124085         Work around the Solaris 10 ACE ACLs ABI change.
124086         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): Don't
124087         declare if ACL_NO_TRIVIAL is present.
124088         (ACE_ACCESS_ALLOWED_ACE_TYPE, ACE_ACCESS_DENIED_ACE_TYPE,
124089         NEW_ACE_OWNER, NEW_ACE_GROUP, NEW_ACE_IDENTIFIER_GROUP, ACE_EVERYONE,
124090         NEW_ACE_READ_DATA, NEW_ACE_WRITE_DATA, NEW_ACE_EXECUTE): New macros.
124091         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): Don't
124092         define if ACL_NO_TRIVIAL is present.
124093         (acl_ace_nontrivial): Detect whether the old or new ABI is in use,
124094         and use the current ABI.
124095         (file_has_acl): Use same #if condition as elsewhere.
124096         * lib/set-mode-acl.c (qset_acl): Detect whether the old or new ABI is
124097         in use, and use the current ABI.
124098         * doc/acl-resources.txt: More doc about newer Solaris 10 versions.
124099         Reported by Jim Meyering.
124101 2008-06-09  Eric Blake  <ebb9@byu.net>
124103         Work around environments that (stupidly) ignore SIGALRM.
124104         * m4/strstr.m4 (gl_FUNC_STRSTR): Reset SIGALRM to default handling
124105         before using alarm().
124106         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
124107         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
124108         Reported by Ian Beckwith <ianb@erislabs.net>.
124110         Produce autobuild blurb earlier in log.
124111         * modules/autobuild (configure.ac-early): Move AB_INIT here.
124113 2008-06-09  Jim Meyering  <meyering@redhat.com>
124114         and Ondřej Vašík  <ovasik@redhat.com>
124116         utimens.c: correct kernel bug work-around
124117         Ondřej Vašík found that the invalid return value of 280 indicates
124118         failure, not success, and the kernel bug we're trying to work
124119         around affects not just the utimensat call, but also the fallback
124120         futimens call.
124121         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Simulate failure,
124122         not success.
124123         [HAVE_FUTIMENS]: Use the same work-around, here.
124125 2008-06-09  Jim Meyering  <meyering@redhat.com>
124127         add more guards around definition of ACE_-related code
124128         * lib/file-has-acl.c (acl_ace_nontrivial): Define only if
124129         ALLOW and ACE_OWNER are also defined.
124131 2008-06-08  Bruno Haible  <bruno@clisp.org>
124133         * lib/acl-internal.h: Add me as co-author.
124134         * lib/file-has-acl.c: Likewise.
124135         * lib/set-mode-acl.c: Likewise.
124136         * lib/copy-acl.c: Likewise.
124138 2008-06-08  Bruno Haible  <bruno@clisp.org>
124140         Add support for AIX ACLs.
124141         * lib/acl-internal.h (acl_nontrivial): New declaration.
124142         * lib/file-has-acl.c (acl_nontrivial): New function.
124143         (file_has_acl): Add implementation using AIX 4 ACL API.
124144         * lib/set-mode-acl.c (qset_acl): Likewise.
124145         * lib/copy-acl.c (qcopy_acl): Likewise.
124147 2008-06-08  Bruno Haible  <bruno@clisp.org>
124149         Add support for HP-UX ACLs.
124150         * lib/acl-internal.h (acl_nontrivial): New declaration.
124151         * lib/file-has-acl.c (acl_nontrivial): New function.
124152         (file_has_acl): Add implementation using HP-UX 11 ACL API.
124153         * lib/set-mode-acl.c (qset_acl): Likewise.
124154         * lib/copy-acl.c (qcopy_acl): Likewise.
124156 2008-06-08  Bruno Haible  <bruno@clisp.org>
124158         Add support for Cygwin ACLs.
124159         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro for Solaris-like API.
124160         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Don't optimize away
124161         the chmod_or_fchmod call.
124162         * lib/copy-acl.c (qcopy_acl) [!MODE_INSIDE_ACL]: Likewise.
124164 2008-06-08  Bruno Haible  <bruno@clisp.org>
124166         Fix bug with setuid modes in Solaris 10+ code.
124167         * lib/set-mode-acl.c (qset_acl): Call chmod_or_fchmod when acl_set
124168         succeeded, when the mode contains some special bits.
124170 2008-06-08  Bruno Haible  <bruno@clisp.org>
124172         Add support for Solaris 7..10 ACLs.
124173         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): New
124174         declarations.
124175         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): New
124176         functions.
124177         (file_has_acl): Add implementation using Solaris 7..10 ACL API.
124178         * lib/set-mode-acl.c (qset_acl): Likewise.
124179         * lib/copy-acl.c (qcopy_acl): Likewise.
124181 2008-06-08  Bruno Haible  <bruno@clisp.org>
124183         * lib/acl-internal.h (acl_extended_nontrivial) [MacOS X]: New
124184         declaration.
124185         * lib/file-has-acl.c (acl_extended_nontrivial) [MacOS X]: New function.
124186         (acl_access_nontrivial): Remove MacOS X case.
124187         (file_has_acl): Use acl_extended_nontrivial.
124188         * lib/copy-acl.c (qcopy_acl): Likewise.
124190 2008-06-08  Bruno Haible  <bruno@clisp.org>
124192         * lib/set-mode-acl.c (qset_acl): Trivial code simplifications.
124194 2008-06-08  Jim Meyering  <meyering@redhat.com>
124196         * modules/acl (Maintainer): Add Bruno Haible.
124198 2008-06-07  Bruno Haible  <bruno@clisp.org>
124200         Improve support for Tru64 ACLs.
124201         * lib/file-has-acl.c (file_has_acl): Don't test the ACL_TYPE_DEFAULT
124202         ACL on OSF/1.
124204 2008-06-07  Bruno Haible  <bruno@clisp.org>
124206         Add support for MacOS X ACLs.
124207         * lib/file-has-acl.c (file_has_acl): Use ACL_TYPE_EXTENDED instead of
124208         ACL_TYPE_ACCESS and ACL_TYPE_DEFAULT.
124209         * lib/set-mode-acl.c (qset_acl): Likewise.
124210         * lib/copy-acl.c (qcopy_acl): Likewise.
124212 2008-06-07  Bruno Haible  <bruno@clisp.org>
124214         Fix memory leak introduced on 2008-05-22.
124215         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Free ACLs after
124216         use.
124218 2008-06-07  Bruno Haible  <bruno@clisp.org>
124220         * lib/set-mode-acl.c (qset_acl): Use acl_init(), not acl_from_text(),
124221         to construct an empty ACL.
124223 2008-06-07  Bruno Haible  <bruno@clisp.org>
124225         * lib/set-mode-acl.c (chmod_or_fchmod): Document return value
124226         precisely.
124227         * lib/copy-acl.c (qcopy_acl): Trivial code simplifications.
124229 2008-06-07  Bruno Haible  <bruno@clisp.org>
124231         * lib/copy-acl.c (qcopy_acl): Make the #if branches independent.
124232         * lib/set-mode-acl.c (qset_acl): Choose better local variable names.
124234 2008-06-07  Bruno Haible  <bruno@clisp.org>
124236         * doc/posix-functions/_setjmp.texi: Explain the use of this function
124237         regardless of POSIX.
124238         * doc/posix-functions/_longjmp.texi: Likewise.
124239         * doc/posix-functions/setjmp.texi: Mention HP-UX as not counting as a
124240         SystemV platform in this case.
124242 2008-06-06  Eric Blake  <ebb9@byu.net>
124244         Document abort() bugs.
124245         * doc/posix-functions/abort.texi (abort): Mention anomalies.
124247         * doc/posix-functions/setjmp.texi (setjmp): Mingw has setjmp.
124248         * doc/posix-functions/sigsetjmp.texi (sigsetjmp): Cygwin has
124249         sigsetjmp.
124250         * doc/posix-functions/siglongjmp.texi (siglongjmp): Cygwin has
124251         siglongjmp, but only as a macro.
124252         * doc/posix-functions/_longjmp.texi (_longjmp): Mention that this
124253         is obsolete.
124254         * doc/posix-functions/_setjmp.texi (_setjmp): Likewise.
124256         Tweak documentation to cover cygwin argz bugs.
124257         * m4/argz.m4 (gl_FUNC_ARGZ): Mention date of last known cygwin
124258         argz bug fix; no code change needed since no cygwin releases
124259         occurred between the last fix and the bug being tested.
124260         * doc/glibc-functions/argz_add.texi (argz_add): Document the argz
124261         module and recently fixed cygwin bugs.
124262         * doc/glibc-functions/argz_add_sep.texi (argz_add_sep): Likewise.
124263         * doc/glibc-functions/argz_append.texi (argz_append): Likewise.
124264         * doc/glibc-functions/argz_count.texi (argz_count): Likewise.
124265         * doc/glibc-functions/argz_create.texi (argz_create): Likewise.
124266         * doc/glibc-functions/argz_create_sep.texi (argz_create_sep):
124267         Likewise.
124268         * doc/glibc-functions/argz_delete.texi (argz_delete): Likewise.
124269         * doc/glibc-functions/argz_extract.texi (argz_extract): Likewise.
124270         * doc/glibc-functions/argz_insert.texi (argz_insert): Likewise.
124271         * doc/glibc-functions/argz_next.texi (argz_next): Likewise.
124272         * doc/glibc-functions/argz_replace.texi (argz_replace): Likewise.
124273         * doc/glibc-functions/argz_stringify.texi (argz_stringify):
124274         Likewise.
124276         Avoid gcc warning on cygwin.
124277         * lib/copy-acl.c (qcopy_acl) [!HAVE_ACL_GET_FILE &&
124278         !ACL_NO_TRIVIAL]: Avoid unused variable.
124280 2008-06-05  Eric Blake  <ebb9@byu.net>
124282         Be tolerant of UNKNOWN version in gnulib-tool test dir.
124283         * top/GNUmakefile (_dummy): Warn rather than reconfigure if
124284         git-version-gen fails to come up with a version.
124285         Reported by Simon Josefsson.
124287 2008-06-05  Jim Meyering  <meyering@redhat.com>
124288             Paul Eggert  <eggert@cs.ucla.edu>
124290         utimens.c: work around a probable Linux kernel bug
124291         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Work around what
124292         appears to be a kernel bug that causes utimensat to return 280
124293         instead of 0, indicating success.
124295 2008-06-04  Bruno Haible  <bruno@clisp.org>
124297         * lib/copy-acl.c (qcopy_acl): Call qset_acl, not set_acl. Fixes
124298         2008-06-01 commit.
124300 2008-06-04  Bruno Haible  <bruno@clisp.org>
124302         * lib/acl-internal.h (acl_access_nontrivial): New declaration.
124303         * lib/file-has-acl.c (acl_access_nontrivial): New function.
124304         (file_has_acl): Use it. Save errno afterwards.
124305         * lib/copy-acl.c (qcopy_acl): Use acl_access_nontrivial.
124307 2008-06-03  Bruno Haible  <bruno@clisp.org>
124309         * lib/file-has-acl.c (file_has_acl): Put Solaris 10 code after POSIX-
124310         draft code. Simplify #ifs.
124311         * lib/set-mode-acl.c (qset_acl): Don't test for symlink if !USE_ACL.
124312         Put Solaris code after POSIX-draft code. Fix comments regarding
124313         Solaris 10, HP-UX. Mention Cygwin.
124314         * lib/copy-acl.c (qcopy_acl): Simplify #ifs.
124316 2008-06-03  Eric Blake  <ebb9@byu.net>
124318         Provide fallback for older kernels.
124319         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT, HAVE_FUTIMENS]:
124320         Provide runtime fallback if kernel lacks support.
124321         Reported by Mike Frysinger.
124323 2008-06-02  Bruno Haible  <bruno@clisp.org>
124325         * lib/acl-internal.h (ACL_NOT_WELL_SUPPORTED): Include EOPNOTSUPP if
124326         it exists.
124328 2008-06-02  Bruno Haible  <bruno@clisp.org>
124330         * lib/acl_entries.c (acl_entries): Rewrite to use acl_get_entry.
124331         * lib/copy-acl.c (qcopy_acl): Update comment.
124333 2008-06-02  Bruno Haible  <bruno@clisp.org>
124335         * lib/acl-entries.h: Enclose most definitions in #ifs for POSIX-draft
124336         like ACL APIs.
124338 2008-06-02  Bruno Haible  <bruno@clisp.org>
124340         * tests/test-file-has-acl.sh: Use different code for Cygwin.
124341         * tests/test-set-mode-acl.sh: Likewise.
124342         * tests/test-copy-acl.sh: Likewise.
124343         * tests/test-copy-file.sh: Likewise.
124345 2008-06-02  Bruno Haible  <bruno@clisp.org>
124347         * tests/test-file-has-acl.sh: Remove unused code.
124349 2008-06-01  Bruno Haible  <bruno@clisp.org>
124351         * lib/copy-acl.c (qcopy_acl): New function, extracted from copy_acl.
124352         (copy_acl): Just a wrapper around qcopy_acl that emits the error
124353         messages.
124354         * lib/set-mode-acl.c (qset_acl): Document return value precisely.
124356 2008-06-01  Bruno Haible  <bruno@clisp.org>
124358         * m4/acl.m4 (gl_FUNC_ACL): Separate the POSIX-like and the Solaris
124359         tests. Test for libpacl, needed for OSF/1. Test for extended ACLs,
124360         needed for MacOS X. Test for HP-UX API. Test for newer and older AIX
124361         APIs.
124362         * modules/acl-tests (configure.ac): Remove tests now contained in
124363         m4/acl.m4.
124365 2008-06-02  Jim Meyering  <meyering@redhat.com>
124367         announce-gen: use a better key-server host name
124368         * build-aux/announce-gen (main): Recommend keys.gnupg.net, since
124369         it may be more consistently reliable.  Suggested by Werner Koch
124370         in <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/13717>.
124372 2008-06-01  Bruno Haible  <bruno@clisp.org>
124374         * lib/stdio-impl.h (fp_ub): Use fp_. Needed for DragonFly BSD.
124375         Reported by Voroskoi Andras <voroskoi@gmail.com>.
124377 2008-06-01  Voroskoi Andras  <voroskoi@gmail.com>  (tiny change)
124379         * lib/stdio-impl.h [__DragonFly__]: Fix typo.
124381 2008-06-01  Bruno Haible  <bruno@clisp.org>
124383         New ACL tests.
124384         * tests/test-file-has-acl.sh: New file.
124385         * tests/test-file-has-acl.c: New file.
124386         * tests/test-set-mode-acl.sh: New file.
124387         * tests/test-set-mode-acl.c: New file.
124388         * tests/test-copy-acl.sh: New file, based on tests/test-copy-file.sh.
124389         * tests/test-copy-acl.c: New file.
124390         * modules/acl-tests: New file, based on modules/copy-file-tests.
124391         * modules/copy-file-tests (Files): Remove tests/test-sameacls.c.
124392         (Depends-on): Add acl-tests.
124393         (configure.ac): Remove checks.
124394         (Makefile.am): Don't create test-sameacls program here any more.
124396 2008-06-01  Bruno Haible  <bruno@clisp.org>
124398         * tests/test-copy-file.sh: Portability fixes for Solaris, HP-UX, IRIX.
124399         * tests/test-sameacls.c: Include progname.h.
124400         (main): Invoke set_program_name. Portability fixes for MacOS X,
124401         Solaris, HP-UX.
124403 2008-06-01  Bruno Haible  <bruno@clisp.org>
124405         * lib/freadahead.c (freadahead) [__DragonFly__]: Use the __sreadahead
124406         function.
124407         Reported by VOROSKOI Andras <voroskoi@gmail.com>.
124409 2008-06-01  Bruno Haible  <bruno@clisp.org>
124411         * modules/rpmatch (Depends-on): Add strdup.
124413 2008-06-01  Bruno Haible  <bruno@clisp.org>
124415         * lib/pipe.c: Include unistd-safer.h.
124416         (create_pipe): Ensure the returned file descriptors are not in {0,1,2}.
124417         * modules/pipe (Depends-on): Add unistd-safer.
124419 2008-05-30  Simon Josefsson  <simon@josefsson.org>
124421         * modules/autobuild (configure.ac): Call AB_INIT.
124423 2008-05-30  Simon Josefsson  <simon@josefsson.org>
124425         * tests/test-getaddrinfo.c: Don't print debug messages by default.
124426         Suggested by Bruno Haible <bruno@clisp.org>.
124428 2008-05-30  Simon Josefsson  <simon@josefsson.org>
124430         * tests/test-base64.c: Cast size_t to unsigned long when invoking
124431         printf.  Use %lu instead of %d.  Reported by Bruno Haible
124432         <bruno@clisp.org>.
124434 2008-05-29  Eric Blake  <ebb9@byu.net>
124436         Prefer new POSIX 200x interfaces over futimesat.
124437         * m4/utimens.m4 (gl_UTIMENS): Check for futimens, utimensat.
124438         * lib/utimens.c (gl_futimens): Use them for nanosecond resolution
124439         when available.
124440         [HAVE_BUGGY_NFS_TIME_STAMPS]: Allow C89 compilation.
124442 2008-05-28  Bruno Haible  <bruno@clisp.org>
124444         * modules/stpcpy (License): Change to LGPLv2+.
124445         Requested by David Lutterkort <dlutter@redhat.com>.
124447 2008-05-27  Bruno Haible  <bruno@clisp.org>
124449         * lib/localename.c (SUBLANG_TIBETAN_BHUTAN): Force value 2. Needed for
124450         current mingw.
124451         Reported by Jose E. Marchesi <jemarch@gnu.org>.
124453 2008-05-27  Bruno Haible  <bruno@clisp.org>
124455         * modules/iconv_open (Link): New section, from module 'iconv'.
124456         * modules/striconv (Link): Likewise.
124457         * modules/striconveh (Link): Likewise.
124458         * modules/xstriconv (Link): Likewise.
124459         * modules/unicodeio (Link): Likewise.
124460         * modules/propername (Link): Likewise.
124461         Reported by Jim Meyering.
124463 2008-05-26  Jim Meyering  <meyering@redhat.com>
124465         sha256: do not artificially restrict buffer length to be < 2^32
124466         * lib/sha256.h (struct sha256_ctx) [buflen]: Change type from
124467         uint32_t to size_t.
124468         * lib/sha256.c (sha256_conclude_ctx): Change type of a local
124469         to match.
124471         avoid unaligned access errors, e.g., on sparc
124472         * lib/sha512.c (sha512_conclude_ctx): Use set_uint64 rather than
124473         direct access through a possibly-unaligned uint64* pointer.
124474         * lib/sha256.c (sha256_conclude_ctx): Use set_uint32 rather than
124475         direct access through a possibly-unaligned uint32* pointer.
124476         Prompted by this patch from Tom "spot" Callaway:
124477         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/13638
124479         sha512.c: fix typo in comment
124480         * lib/sha512.c (sha512_conclude_ctx): Length is 128-bit, not 64-bit.
124482 2008-05-25  Bruno Haible  <bruno@clisp.org>
124484         * lib/set-mode-acl.c: Renamed from lib/acl.c.
124485         * modules/acl (Files): Add lib/set-mode-acl.c, remove lib/acl.c.
124486         (Makefile.am): Update lib_SOURCES.
124488 2008-05-25  Bruno Haible  <bruno@clisp.org>
124490         * m4/acl.m4 (gl_FUNC_ACL): Don't set LIB_ACL_TRIVIAL.
124492 2008-05-25  Jim Meyering  <meyering@redhat.com>
124494         useless-if-before-free: freed expr may have white-space differences
124495         * build-aux/useless-if-before-free: Recognize cases in which the
124496         freed expression differs from the tested one in embedded white
124497         space, e.g., if (p[i + 1]) free(p[i+1]).  Correct thinko in prev:
124498         $1 was used, so we can't make any regexp shy.  Improved tests now
124499         detect this.
124501         useless-if-before-free: accept white space in the expression.
124502         * build-aux/useless-if-before-free: For now, any white space
124503         in the expression must be identical in the free argument.
124505         useless-if-before-free: efficiency tweak
124506         * build-aux/useless-if-before-free: Make the expression-matching
124507         regexp "shy".
124508         Make the *outer* regexp shy, not the expr-matching one.
124510         update code-in-comment to accept cast of free arg
124511         * build-aux/useless-if-before-free: Update regexp.
124513 2008-05-25  Bruno Haible  <bruno@clisp.org>
124515         * tests/test-sameacls.c: Renamed from tests/test-copy-file-sameacls.c.
124516         * modules/copy-file-tests (Files, Makefile.am): Update.
124517         * tests/test-copy-file.c (func_test_copy): Update.
124519 2008-05-24  Andreas Färber  <andreas.faerber@web.de>  (tiny change)
124521         * lib/stdbool.in.h [__HAIKU__]: Disable __BEOS__ workarounds.
124523 2008-05-23  Bruno Haible  <bruno@clisp.org>
124525         Improve support for ACLs on OSF/1.
124526         * lib/acl.c (qset_acl): For OSF/1, use a string that ends in a comma.
124527         Remove fallback for unknown flavors of ACLs.
124529 2008-05-22  Bruno Haible  <bruno@clisp.org>
124531         Add support for ACLs on OSF/1.
124532         * lib/acl-internal.h (acl_get_fd, acl_set_fd): New inline function
124533         replacements.
124534         (acl_free_text): New macro fallback.
124535         * lib/acl_entries.c (acl_entries): Use acl_free_text instead of
124536         acl_free.
124537         * m4/acl.m4 (gl_FUNC_ACL): Look also in libpacl library. Test for
124538         acl_free_text function. Require AC_C_INLINE.
124540 2008-05-22  Bruno Haible  <bruno@clisp.org>
124542         Make copy_acl work on MacOS X 10.5.
124543         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro.
124544         (ACL_NOT_WELL_SUPPORTED): On MacOS X, also handle ENOENT.
124545         * lib/acl.c (qset_acl): Add different code branch for !MODE_INSIDE_ACL.
124546         If MODE_INSIDE_ACL, don't assume that every system has the same text
124547         representation for ACLs as FreeBSD.
124548         * lib/copy-acl.c (copy_acl): Add support for platforms with
124549         !MODE_INSIDE_ACL.
124550         * lib/file-has-acl.c (file_has_acl): Likewise.
124551         * m4/acl.m4 (gl_FUNC_ACL): Test for some functions that are witness of
124552         FreeBSD, MacOS X, or IRIX, respectively.
124554 2008-05-22  Bruno Haible  <bruno@clisp.org>
124556         * lib/acl.h: Don't include <sys/acl.h>.
124557         (GETACLCNT): Move fallback to lib/acl-internal.h.
124558         * lib/acl-internal.h: Include <sys/acl.h> here.
124559         (GETACLCNT): New macro fallback, moved here from lib/acl.h.
124561 2008-05-22  Bruno Haible  <bruno@clisp.org>
124563         Split off copy_acl function to separate file.
124564         * lib/copy-acl.c: New file, extracted from lib/acl.c.
124565         * lib/acl.c (copy_acl): Moved function to separate file.
124566         * m4/acl.m4 (gl_FUNC_ACL): Remove unconditional AC_LIBOBJs.
124567         * modules/acl (Files): Add lib/copy-acl.c.
124568         (Makefiles.am): Augment lib_SOURCES.
124570 2008-05-22  Bruno Haible  <bruno@clisp.org>
124572         * modules/copy-file-tests: New file.
124573         * tests/test-copy-file.sh: New file.
124574         * tests/test-copy-file.c: New file.
124575         * tests/test-copy-file-sameacls.c: New file.
124577 2008-05-22  Eric Blake  <ebb9@byu.net>
124579         Avoid gcc warning.
124580         * tests/test-memcmp.c (main): Pass NULL indirectly.
124582 2008-05-21  Bruno Haible  <bruno@clisp.org>
124584         Add reference doc about ACLs.
124585         * doc/acl-resources.txt: New file.
124586         * doc/acl-cygwin.txt: New file.
124588 2008-05-21  Bruno Haible  <bruno@clisp.org>
124590         Avoid one more warning from gcc.
124591         * lib/vasnprintf.c (IF_LINT): Update comments.
124592         (VASNPRINTF): Use it also for the 'prefix' array initializer.
124594 2008-05-21  Jim Meyering  <meyering@redhat.com>
124596         avoid a warning from gcc
124597         * lib/vasnprintf.c (IF_LINT): Define.
124598         (scale10_round_decimal_long_double):
124599         Use it to avoid a "may be used uninitialized" warning.
124600         (scale10_round_decimal_double): Likewise.
124602 2008-05-21  Simon Josefsson  <simon@josefsson.org>
124604         * m4/memcmp.m4: When cross-compiling, assume memcmp works if it is
124605         declared.
124607 2008-05-20  Bruno Haible  <bruno@clisp.org>
124609         * tests/test-memcmp.c (main): Test also the sign of the result. Test
124610         against two known bugs; code taken from autoconf's AC_FUNC_MEMCMP.
124612 2008-05-20  Simon Josefsson  <simon@josefsson.org>
124614         * modules/memcmp-tests: New file.
124615         * tests/test-memcmp.c: New file.
124617 2008-05-19  Bruno Haible  <bruno@clisp.org>
124619         * modules/propername (Notice, configure.ac): Put quoted "..." into
124620         --keyword option.
124621         * lib/propername.h: Update comments accordingly.
124622         Reported by Eric Blake.
124624 2008-05-19  Martin Lambers  <marlam@marlam.de>  (tiny change)
124626         * modules/getpass-gnu (Depends-on): Add fseeko.
124628 2008-05-19  Simon Josefsson  <simon@josefsson.org>
124630         * modules/base64-tests: New file.
124632 2008-05-19  Bo Borgerson  <gigabo@gmail.com>
124634         * lib/base64.c (base64_decode_ctx): If a decode context structure
124635         was passed in use it to ignore newlines.  If a context structure
124636         was _not_ passed in, continue to treat newlines as garbage (this
124637         is the historical behavior).  Formerly base64_decode.
124638         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
124639         takes a decode context structure.
124640         * lib/base64.h (base64_decode): Macro for four-argument calls.
124641         (base64_decode_alloc): Likewise.
124642         * lib/base64.c (base64_decode_ctx): If a decode context structure
124643         was passed in use it to ignore newlines.  If a context structure
124644         was _not_ passed in, continue to treat newlines as garbage (this
124645         is the historical behavior).  Formerly base64_decode.
124646         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
124647         takes a decode context structure.
124648         * lib/base64.h (base64_decode): Macro for four-argument calls.
124649         (base64_decode_alloc): Likewise.
124651 2008-05-19  Jim Meyering  <meyering@redhat.com>
124653         avoid a warning from gcc
124654         * lib/trim.c (IF_LINT): Define.
124655         (trim2): Use it to avoid a "may be used uninitialized" warning.
124657         Fix doc typo.
124658         * doc/glibc-functions/getpass.texi (getpass): s/PATH_MAX/PASS_MAX/.
124660 2008-05-19  Bruno Haible  <bruno@clisp.org>
124662         * doc/glibc-functions/getpass.texi: Document limits of other
124663         implementations.
124665 2008-05-19  Simon Josefsson  <simon@josefsson.org>
124666             Bruno Haible <bruno@clisp.org>
124668         * doc/glibc-functions/getpass.texi: Document gnulib implementation.
124670 2008-05-18  Bruno Haible  <bruno@clisp.org>
124672         * modules/propername: New file, from GNU gettext.
124673         * lib/propername.h: New file, from GNU gettext.
124674         * lib/propername.c: New file, from GNU gettext.
124675         * MODULES.html.sh (Internationalization functions): Add propername.
124677 2008-05-16  Jim Meyering  <meyering@redhat.com>
124678             Bruno Haible  <bruno@clisp.org>
124680         Avoid some warnings from "gcc -Wshadow".
124681         * lib/vasnprintf.c (exp, remainder): Define to different identifiers.
124683 2008-05-15  Eric Blake  <ebb9@byu.net>
124685         Extend previous patch to cygwin 1.7.0.
124686         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a
124687         fast implementation in cygwin >= 1.7.0.
124688         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
124689         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
124691 2008-05-15  Bruno Haible  <bruno@clisp.org>
124693         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a fast
124694         implementation in glibc >= 2.9.
124695         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
124696         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
124698 2008-05-15  Bruno Haible  <bruno@clisp.org>
124700         * MODULES.html.sh (Internationalization functions): Remove linebreak.
124701         (Unicode string functions): Add unilbrk/*.
124702         Reported by Karl Berry.
124704 2008-05-15  Eric Blake  <ebb9@byu.net>
124706         Fix violation of <stdbool.h> replacement in regex.
124707         * lib/regcomp.c (re_compile_internal): Avoid implicit cast to bool.
124708         * lib/regexec.c (re_search_internal): Likewise.
124709         Reported by Heinrich Mislik <Heinrich.Mislik@univie.ac.at>.
124711 2008-05-15  Jim Meyering  <meyering@redhat.com>
124713         avoid distracting test output when git or cvs is not found
124714         * tests/test-vc-list-files-cvs.sh: Suppress 'init' error output.
124715         * tests/test-vc-list-files-git.sh: Likewise.
124717 2008-05-15  Eric Blake  <ebb9@byu.net>
124719         Glibc finally accepted the memmem speedup code, bugzilla #5514.
124720         * doc/glibc-functions/memmem.texi (memmem): Mention last broken
124721         glibc version.
124722         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
124723         * doc/posix-functions/strstr.texi (strstr): Likewise.
124724         * lib/str-two-way.h (MAX): Sychronize with glibc.
124726 2008-05-15  Paolo Bonzini  <bonzini@gnu.org>
124728         * lib/regcomp.c (optimize_utf8): Add a note on why we test
124729         opr.ctx_type.
124730         (calc_first): Initialize constraint field.
124731         (duplicate_node_closure): Use it instead of special casing ANCHORS.
124732         Fix grammar.
124733         (duplicate_node): Merge constraint field for all node types.
124734         (calc_eclosure_iter): Look at constraint field for all node types.
124735         * lib/regex_internal.c (create_cd_newstate): Don't look at
124736         opr.ctx_type.
124738 2008-05-14  Bruno Haible  <bruno@clisp.org>
124740         Help GCC to do better code generation.
124741         * lib/eealloc.h (eemalloc) [GCC >= 3]: Declare with attribute 'malloc'.
124742         * lib/pagealign_alloc.h (pagealign_alloc, pagealign_xalloc): Likewise.
124743         * lib/xalloc.h (ATTRIBUTE_MALLOC): New macro.
124744         (xmalloc, xzalloc, xcalloc, xmemdup, xstrdup, xnmalloc, xcharalloc):
124745         Declare with attribute 'malloc' if supported.
124747 2008-05-14  Lasse Collin  <lasse.collin@tukaani.org>
124749         use "echo STR|wc -c" rather than unportable "expr length STR"
124750         * build-aux/mktempd (mktempd): Vendor-supplied expr from at least
124751         OpenBSD 4.3 and Solaris 10 do not honor expr's "length" function.
124753 2008-05-14  Jim Meyering  <meyering@redhat.com>
124755         use dd ibs=$n count=1 ... rather than less-portable head -c$n
124756         * build-aux/mktempd (rand_bytes): head's -cN option is not accepted
124757         by Solaris 10's /bin/head or by the one from HP-UX 11.x.
124758         Reported in http://sourceforge.net/forum/message.php?msg_id=4960334
124759         via Collin Lasse.
124761 2008-05-14  Eric Blake  <ebb9@byu.net>
124763         Avoid quadratic growth in gl_LIBSOURCES.
124764         * gnulib-tool (func_emit_initmacro_done): s/\(m4_append\)_uniq/\1/.
124765         Suggested by Bruno Haible.
124767         Test xmemdup0.
124768         * modules/xmemdup0-tests: New file.
124769         * tests/test-xmemdup0.c: Likewise.
124771 2008-05-13  Eric Blake  <ebb9@byu.net>
124773         Split xmemdup0 into its own module.
124774         * modules/xmemdup0: New file.
124775         * lib/xmemdup0.h: Likewise.
124776         * lib/xmemdup0.c: Likewise.
124777         * MODULES.html.sh (Memory management functions): Add xmemdup0.
124778         * lib/xalloc.h (xmemdup0): Remove.
124779         * lib/xmalloc.c (xmemdup0): Likewise.
124781 2008-05-13  Eric Blake  <ebb9@byu.net>
124782             Bruno Haible  <bruno@clisp.org>
124784         Reduce number of forks required during autoconf.
124785         * gnulib-tool (func_emit_initmacro_start): Prepare gl_LIBSOURCES_LIST
124786         and gl_LIBSOURCES_DIR.
124787         (func_emit_initmacro_end): Use them here in a single m4_syscmd...
124788         (func_emit_initmacro_done) <gl_LIBSOURCES>: ...rather than in one
124789         m4_syscmd per file.
124790         <m4_foreach_w>: Move...
124791         * m4/gnulib-common.m4 (m4_foreach_w): ...here.
124793 2008-05-13  Eric Blake  <ebb9@byu.net>
124795         * gnulib-tool: Fix various comment typos.
124797 2008-05-12  Bruno Haible  <bruno@clisp.org>
124799         Tailor the linebreaking algorithm.
124800         * lib/unilbrk/tables.c (unilbrk_table): Change (IS,AL) entry.
124802 2008-05-12  Bruno Haible  <bruno@clisp.org>
124804         Update to Unicode 5.0.0.
124805         * lib/unilbrk/tables.h (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
124806         LBP_JV, LBP_JT. Redistribute values.
124807         (unilbrk_table): Change size.
124808         * lib/unilbrk/tables.c (unilbrk_table): Change size. Update to match
124809         Unicode TR#14 rev. 22.
124810         * lib/unilbrk/gen-lbrk.c (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
124811         LBP_JV, LBP_JT. Redistribute values.
124812         (get_lbp): Update to match Unicode TR#14 rev. 21/22 and Unicode 5.0.0.
124813         (debug_output_lbp, fill_org_lbp, debug_output_org_lbp, output_lbp):
124814         Update.
124815         * lib/unilbrk/lbrkprop1.h: Regenerated.
124816         * lib/unilbrk/lbrkprop2.h: Regenerated.
124817         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks):
124818         Change handling of LBP_CM after LBP_ZW. Update for new value of LBP_BK.
124819         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
124820         Likewise.
124821         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
124822         Likewise.
124823         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update expected
124824         result.
124825         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
124826         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
124827         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
124828         * tests/unilbrk/test-u8-width-linebreaks.c (main): Likewise.
124829         * tests/unilbrk/test-u16-width-linebreaks.c (main): Likewise.
124830         * tests/unilbrk/test-u32-width-linebreaks.c (main): Likewise.
124832 2008-05-11  Bruno Haible  <bruno@clisp.org>
124834         * lib/unilbrk/gen-lbrk.c (output_lbp): Fix whitespace.
124836 2008-05-11  Bruno Haible  <bruno@clisp.org>
124838         * lib/unilbrk/gen-lbrk.c: New file, from GNU gettext (gen-lbrkprop.c).
124839         * modules/unilbrk/gen-lbrk: New file.
124841 2008-05-11  Bruno Haible  <bruno@clisp.org>
124843         * m4/sha256.m4 (gl_SHA256): Require AC_C_INLINE.
124844         * m4/sha512.m4 (gl_SHA512): Likewise.
124846 2008-05-11  Jim Meyering  <meyering@redhat.com>
124848         New modules: crypto/sha256, crypto/sha512 (from coreutils)
124849         * modules/crypto/sha256: New file.
124850         * modules/crypto/sha512: Likewise.
124851         * lib/sha256.c: Likewise.
124852         * lib/sha256.h: Likewise.
124853         * lib/sha512.c: Likewise.
124854         * lib/sha512.h: Likewise.
124855         * lib/u64.h: Likewise.
124856         * m4/sha256.m4: Likewise.
124857         * m4/sha512.m4: Likewise.
124858         * MODULES.html.sh (Cryptographic computations (low-level)): List them.
124860 2008-05-10  Bruno Haible  <bruno@clisp.org>
124862         * MODULES.html.sh (Environment variables <stdlib.h>): Add unsetenv.
124863         (Input/Output <stdio.h>): Add xprintf.
124864         (Signal handling <signal.h>): Add strsignal.
124865         (Cryptographic computations (high-level)): Add crypto/gc-camellia.
124866         (Core language properties): Add func.
124867         (Mathematics <math.h>): Add ceil, floor, frexp-nolibm.
124868         (Support for systems lacking POSIX:2001): Add environ, EOVERFLOW,
124869         strings.
124870         (Enhancements for POSIX:2001 functions): Add iconv_open-utf.
124871         (Input/output): New section.
124872         (File system functions): Add openat-die, stat-macros.
124873         (Networking functions): Add sockets.
124874         (Unicode string functions): Add unictype/*.
124875         (Support for building libraries and executables): Add gperf.
124876         (Support for building documentation): Add agpl-3.0.
124877         (Misc): Add nocrash.
124879 2008-05-10  Bruno Haible  <bruno@clisp.org>
124881         * modules/unictype/gen-ctype: New file.
124883 2008-05-10  Jim Meyering  <meyering@redhat.com>
124885         Make chdir-safer.c more efficient on a system with no symlinks.
124886         * lib/chdir-safer.c (chdir_no_follow): Skip lstat and fstat calls
124887         also if ELOOP is zero.  Suggested by Bruno Haible.
124889         Make chdir-safer.c slightly safer.
124890         * lib/chdir-safer.c (chdir_no_follow): Test HAVE_WORKING_O_NOFOLLOW,
124891         not O_NOFOLLOW, in case the latter is nonzero and open ignores it.
124893         Avoid compile failure on systems without ELOOP (like mingw).
124894         * lib/chdir-safer.c (ELOOP): Define if not already defined.
124895         Reported by Bruno Haible.
124897 2008-05-10  Bruno Haible  <bruno@clisp.org>
124899         * lib/unilbrk/ulc-common.c: Include c-strcaseeq.h instead of streq.h.
124900         (is_utf8_encoding): Use a case-insensitive comparison.
124901         * modules/unilbrk/ulc-common (Depends-on): Add c-strcaseeq. Remove
124902         streq.
124904 2008-05-10  Bruno Haible  <bruno@clisp.org>
124906         * lib/unilbrk/ulc-common.c: Don't include <stdlib.h>.
124907         (iconv_string_length, iconv_string_keeping_offsets): Remove functions.
124908         * lib/unilbrk/ulc-common.h (iconv_string_length,
124909         iconv_string_keeping_offsets): Remove declarations.
124910         * lib/unilbrk/ulc-possible-linebreaks.c: Include <string.h>, uniconv.h.
124911         Don't include <iconv.h>, streq.h, xsize.h.
124912         (ulc_possible_linebreaks): Use u8_conv_from_encoding for doing the
124913         conversion.
124914         * lib/unilbrk/ulc-width-linebreaks.c: Include uniconv.h. Don't include
124915         <iconv.h>, streq.h, xsize.h.
124916         (ulc_width_linebreaks): Use u8_conv_from_encoding for doing the
124917         conversion.
124918         * modules/unilbrk/ulc-common (Depends-on): Remove iconv.
124919         * modules/unilbrk/ulc-possible-linebreaks (Depends-on): Add
124920         uniconv/u8-conv-from-enc. Remove iconv_open, streq, xsize.
124921         * modules/unilbrk/ulc-width-linebreaks (Depends-on): Likewise.
124923 2008-05-10  Bruno Haible  <bruno@clisp.org>
124925         * modules/unilbrk/ulc-width-linebreaks-tests: New file.
124926         * tests/unilbrk/test-ulc-width-linebreaks.c: New file.
124928         * modules/unilbrk/u32-width-linebreaks-tests: New file.
124929         * tests/unilbrk/test-u32-width-linebreaks.c: New file.
124931         * modules/unilbrk/u16-width-linebreaks-tests: New file.
124932         * tests/unilbrk/test-u16-width-linebreaks.c: New file.
124934         * modules/unilbrk/u8-width-linebreaks-tests: New file.
124935         * tests/unilbrk/test-u8-width-linebreaks.c: New file.
124937         * modules/unilbrk/ulc-possible-linebreaks-tests: New file.
124938         * tests/unilbrk/test-ulc-possible-linebreaks.c: New file.
124940         * modules/unilbrk/u32-possible-linebreaks-tests: New file.
124941         * tests/unilbrk/test-u32-possible-linebreaks.c: New file.
124943         * modules/unilbrk/u16-possible-linebreaks-tests: New file.
124944         * tests/unilbrk/test-u16-possible-linebreaks.c: New file.
124946         * modules/unilbrk/u8-possible-linebreaks-tests: New file.
124947         * tests/unilbrk/test-u8-possible-linebreaks.c: New file.
124949 2008-05-10  Bruno Haible  <bruno@clisp.org>
124951         Split up 'linebreak' module.
124952         * lib/unilbrk.h: New file, based on lib/linebreak.h.
124953         * lib/unilbrk/lbrkprop1.h: New file, extracted from lib/lbrkprop.h.
124954         * lib/unilbrk/lbrkprop2.h: New file, renamed from lib/lbrkprop.h with
124955         modifications.
124956         * lib/unilbrk/tables.h: New file, extracted from lib/linebreak.c.
124957         * lib/unilbrk/tables.c: New file, extracted from lib/linebreak.c.
124958         * lib/unilbrk/u8-possible-linebreaks.c: New file, extracted from
124959         lib/linebreak.c.
124960         * lib/unilbrk/u16-possible-linebreaks.c: New file, extracted from
124961         lib/linebreak.c.
124962         * lib/unilbrk/u32-possible-linebreaks.c: New file, extracted from
124963         lib/linebreak.c.
124964         * lib/unilbrk/ulc-common.h: New file, extracted from lib/linebreak.c.
124965         * lib/unilbrk/ulc-common.c: New file, extracted from lib/linebreak.c.
124966         * lib/unilbrk/ulc-possible-linebreaks.c: New file, extracted from
124967         lib/linebreak.c.
124968         * lib/unilbrk/u8-width-linebreaks.c: New file, extracted from
124969         lib/linebreak.c.
124970         * lib/unilbrk/u16-width-linebreaks.c: New file, extracted from
124971         lib/linebreak.c.
124972         * lib/unilbrk/u32-width-linebreaks.c: New file, extracted from
124973         lib/linebreak.c.
124974         * lib/unilbrk/ulc-width-linebreaks.c: New file, extracted from
124975         lib/linebreak.c.
124976         * modules/unilbrk/base: New file.
124977         * modules/unilbrk/tables: New file.
124978         * modules/unilbrk/u8-possible-linebreaks: New file.
124979         * modules/unilbrk/u16-possible-linebreaks: New file.
124980         * modules/unilbrk/u32-possible-linebreaks: New file.
124981         * modules/unilbrk/ulc-common: New file.
124982         * modules/unilbrk/ulc-possible-linebreaks: New file.
124983         * modules/unilbrk/u8-width-linebreaks: New file.
124984         * modules/unilbrk/u16-width-linebreaks: New file.
124985         * modules/unilbrk/u32-width-linebreaks: New file.
124986         * modules/unilbrk/ulc-width-linebreaks: New file.
124987         * lib/linebreak.h: Remove file.
124988         * lib/linebreak.c: Remove file.
124989         * m4/linebreak.m4: Remove file.
124990         * modules/linebreak: Remove file.
124991         * NEWS: Mention the changes.
124993 2008-05-09  Eric Blake  <ebb9@byu.net>
124995         Add xmemdup0.
124996         * lib/xalloc.h (xmemdup0): New prototype and C++ typesafe
124997         implementation.
124998         * lib/xmalloc.c (xmemdup0): New C implementation.
125000 2008-05-08  Bruno Haible  <bruno@clisp.org>
125002         * m4/wctype.m4 (gl_WCTYPE_H): Correct indentation.
125004 2008-05-07  Eric Blake  <ebb9@byu.net>
125006         Support cross-compilation of <wctype.h>.
125007         * m4/wctype.m4 (gl_WCTYPE_H): Fix improper nesting in
125008         AC_CACHE_CHECK.
125010 2008-05-06  Soren Hansen  <soren@ubuntu.com>  (tiny change)
125012         * build-aux/vc-list-files: Add support for bzr.
125014 2008-05-03  Jim Meyering  <meyering@redhat.com>
125016         avoid failed assertion with tight malloc
125017         * tests/test-getndelim2.c: Correct an off-by-one assertion.
125019 2008-05-03  Simon Josefsson  <simon@josefsson.org>
125021         * m4/inet_pton.m4: Set HAVE_DECL_INET_PTON to 0 when declarations
125022         are needed from arpa/inet.h.
125023         * m4/inet_ntop.m4: Likewise, for HAVE_DECL_INET_NTOP.
125024         Reported by Bruno Haible.
125026 2008-05-02  Jim Meyering  <meyering@redhat.com>
125028         avoid compilation error on FreeBSD 6
125029         * tests/test-getaddrinfo.c [!defined EAI_NODATA] (EAI_NODATA): Define.
125031 2008-05-01  Jim Meyering  <meyering@redhat.com>
125033         useless-if-before-free: correct --help's exit status description
125034         * build-aux/useless-if-before-free (usage): Like grep, exit 0
125035         for one or more matches, etc.  Reported by Bruno Haible.
125037         vc-list-files: make the stand-alone gnulib test work
125038         * modules/vc-list-files-tests (configure.ac):
125039         Define and AC_SUBST abs_aux_dir.
125040         (Makefile.am) [TESTS_ENVIRONMENT]: Rather than passing
125041         $(abs_top_srcdir) to each script and having each of them
125042         duplicate the work of setting PATH, set PATH here, using
125043         the new variable, abs_aux_dir instead.
125044         * tests/test-vc-list-files-cvs.sh: Don't set PATH here.
125045         * tests/test-vc-list-files-git.sh: Likewise.
125046         Reported by Bruno Haible.
125048 2008-05-01  Bruno Haible  <bruno@clisp.org>
125050         * lib/getndelim2.c (getndelim2): Fix newsize computation during
125051         reallocation. Rename 'done' to 'found_delimiter'.
125053 2008-05-01  Jim Meyering  <meyering@redhat.com>
125055         vc-list-files: accommodate /bin/sh like the one from Solaris 10
125056         * build-aux/vc-list-files: Use `...`, not $(...).
125058 2008-04-30  Jim Meyering  <meyering@redhat.com>
125060         add tests for vc-list-files
125061         * modules/vc-list-files-tests: New module.
125062         * tests/test-vc-list-files-cvs.sh: New file.
125063         * tests/test-vc-list-files-git.sh: New file.
125065         avoid a warning from gcc
125066         * lib/getndelim2.c (IF_LINT): Define.
125067         (getndelim2): Use it to avoid a "may be used uninitialized" warning.
125069         vc-list-files: work properly with build-aux/cvsu, too
125070         * build-aux/vc-list-files: Hoist the "./"-removing code to apply
125071         to all cvs-based clauses.
125073         vc-list-files: work properly in the CVS+awk case, too
125074         * build-aux/vc-list-files: In the CVS+awk case, remove "./" prefix.
125076         vc-list-files: avoid use of ${*-*} that fails when /bin/sh is dash
125077         * build-aux/vc-list-files: Simplify ${*-*} to $dir, since we no longer
125078         take more than one file argument, so .  Add quotes, just in case $dir
125079         ever contains a shell meta-character.  Prompted by Soren Hansen in
125080         <http://thread.gmane.org/gmane.comp.emulators.libvirt/6221/focus=6240>.
125082 2008-04-29  Eric Blake  <ebb9@byu.net>
125084         Optimize getndelim2 to use block operations when possible.
125085         * modules/getndelim2 (Depends-on): Add stdbool, freadptr,
125086         freadseek, and memchr2.
125087         * lib/getndelim2.c (getndelim2): Use them for block reads.
125089 2008-04-29  Bruno Haible  <bruno@clisp.org>
125091         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_USE_SYSTEM_EXTENSIONS.
125092         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
125093         * modules/inet_ntop (Depends-on): Add extensions.
125094         * modules/inet_pton (Depends-on): Likewise.
125095         Reported by Simon Josefsson.
125097 2008-04-29  Jim Meyering  <meyering@redhat.com>
125099         When the is more than one match in a block, match all of them.
125100         * build-aux/useless-if-before-free: Iterate through each block
125101         until there are no more matches.
125103         Fix broken useless-if-before-free script.
125104         * build-aux/useless-if-before-free: Fix typo: missing "?" after
125105         the expression to match cast of argument to free-like function.
125107 2008-04-29  Eric Blake  <ebb9@byu.net>
125109         Use new header.
125110         * lib/getaddrinfo.c (includes): s/"inet_ntop.h"/<arpa/inet.h>/.
125112 2008-04-29  Jim Meyering  <meyering@redhat.com>
125114         Avoid test segfault on x86_64 due to lack of inet_ntop declaration.
125115         * tests/test-getaddrinfo.c: Include <arpa/inet.h>, now guaranteed
125116         by gnulib to exist and to declare e.g., inet_ntop.
125117         Don't include "inet_ntop.h", now removed.
125119         * m4/arpa_inet_h.m4: Remove trailing blanks.
125121 2008-04-29  Eric Blake  <ebb9@byu.net>
125123         Silence valgrind on safe reads beyond potential array bounds.
125124         * lib/rawmemchr.valgrind: New file.
125125         * lib/strchrnul.valgrind: Likewise.
125126         * modules/rawmemchr (Files): Distribute new file.
125127         * modules/strchrnul (Files): Likewise.
125128         Suggested by Bruno Haible.
125130 2008-04-29  Bruno Haible  <bruno@clisp.org>
125132         * lib/arpa_inet.in.h: Include system's <arpa/inet.h> if it exists.
125133         (inet_ntop, inet_pton): Change portability warning's wording.
125134         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Set HAVE_ARPA_INET_H.
125135         Invoke gl_CHECK_NEXT_HEADERS.
125136         (gl_ARPA_INET_H_DEFAULTS): Initialize ARPA_INET_H.
125137         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_ARPA_INET_H_DEFAULTS and
125138         set ARPA_INET_H.
125139         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
125140         * modules/arpa_inet (Description): No longer only for systems that
125141         lack it.
125142         (Depends-on): Add include_next.
125143         (Makeile.am): Substitute INCLUDE_NEXT, NEXT_ARPA_INET_H,
125144         HAVE_ARPA_INET_H.
125146 2008-04-29  Jim Meyering  <meyering@redhat.com>
125148         * modules/mkdir (License): Re-license as LGPLv2+.
125150 2008-04-29  Bruno Haible  <bruno@clisp.org>
125152         * modules/rawmemchr (Maintainer): Set to Eric.
125153         * modules/strchrnul (Maintainer): Likewise.
125155 2008-04-29  Simon Josefsson  <simon@josefsson.org>
125157         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Set
125158         HAVE_DECL_INET_NTOP and HAVE_DECL_INET_PTON.
125160         * modules/arpa_inet (arpa/inet.h): Use them.
125162 2008-04-28  Eric Blake  <ebb9@byu.net>
125164         Test getndelim2.
125165         * modules/getndelim2-tests: New file.
125166         * tests/test-getndelim2.c: Likewise.
125167         * lib/getndelim2.c (getndelim2): Never return 0.  Lock the
125168         stream.
125169         * m4/getndelim2.m4 (gl_GETNDELIM2): Check for lock functions.
125171         * MODULES.html.sh: Document new module.
125173 2008-04-20  Bruno Haible  <bruno@clisp.org>
125175         * lib/c-stack.c (die): Use raise.
125176         * modules/c-stack (Depends-on): Add raise.
125178 2008-04-28  Bruno Haible  <bruno@clisp.org>
125180         Expect rpmatch to be declared.
125181         * lib/yesno.c (rpmatch): Remove declaration.
125183         Declare rpmatch.
125184         * lib/stdlib.in.h (rpmatch): New declaration.
125185         * lib/rpmatch.c: Include <stdlib.h> first.
125186         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Require AC_USE_SYSTEM_EXTENSIONS and
125187         gl_STDLIB_H_DEFAULTS. Set HAVE_RPMATCH.
125188         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_RPMATCH,
125189         HAVE_RPMATCH.
125190         * modules/rpmatch (Depends-on): Add stdlib, extensions.
125191         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
125192         (Include): Set to <stdlib.h>.
125193         * modules/stdlib (Makefile.am): Substitute GNULIB_RPMATCH and
125194         HAVE_RPMATCH.
125195         * NEWS: Document the change.
125197 2008-04-28  Bruno Haible  <bruno@clisp.org>
125199         Change rpmatch to use nl_langinfo when appropriate.
125200         * lib/rpmatch.c: Include stdbool.h, string.h, langinfo.h.
125201         (N_): New macro.
125202         (localized_pattern): New function/macro.
125203         (try): Remove match, nomatch arguments. Copy the pattern into safe
125204         memory before caching it.
125205         (rpmatch): Use localized_pattern. Add translator comments.
125206         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Test for nl_langinfo and YESEXPR.
125207         Suggested by Eric Blake.
125208         * modules/rpmatch (Depends-on): Add stdbool.
125210 2008-04-28  Eric Blake  <ebb9@byu.net>
125212         Add rawmemchr module, matching glibc.
125213         * modules/string (Makefile.am): New indicator.
125214         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set it.
125215         * lib/string.in.h (rawmemchr): Declare when appropriate.
125216         * modules/rawmemchr: New file.
125217         * m4/rawmemchr.m4: Likewise.
125218         * lib/rawmemchr.c: Likewise.
125219         * modules/rawmemchr-tests: Likewise.
125220         * tests/test-rawmemchr.c: Likewise.
125221         * doc/glibc-functions/rawmemchr.texi (rawmemchr): Document
125222         module.
125223         * modules/strchrnul (Depends-on): Add rawmemchr.
125224         * lib/strchrnul.c (strchrnul): Optimize a corner case.
125226         Whitespace cleanup.
125227         * tests/test-strchrnul.c: Reindent.
125228         * lib/strchrnul.c: Likewise.
125230         Optimize and test strchrnul.
125231         * lib/strchrnul.c (strchrnul): Rewrite to do parallel search.
125232         * modules/strchrnul-tests: New file.
125233         * tests/test-strchrnul.c: Likewise.
125235         Remove intprops dependency.
125236         * modules/memchr (Depends-on): Remove intprops.
125237         * modules/memrchr (Depends-on): Likewise.
125238         * modules/memchr2 (Depends-on): Likewise.
125239         * lib/memchr.c (__memchr): Hand-inline the TYPE_MAXIMUM check.
125240         * lib/memrchr.c (__memrchr): Likewise.
125241         * lib/memrchr2.c (memchr2): Likewise.
125242         Reported by Simon Josefsson.
125244 2008-04-28  Simon Josefsson  <simon@josefsson.org>
125246         * m4/sys_socket_h.m4: Move AC_REQUIRE([AC_C_INLINE]) to top.
125247         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
125249 2008-04-28  Simon Josefsson  <simon@josefsson.org>
125251         * lib/inet_ntop.h, lib/inet_pton.h: Remove files.
125253         * lib/inet_ntop.c: Include arpa/inet.h instead of inet_ntop.h.
125255         * lib/inet_pton.c: Include arpa/inet.h instead of inet_pton.h.
125257         * lib/arpa_inet.in.h [@GNULIB_INET_NTOP@]: Inline inet_ntop.h
125258         declarations.
125259         [@GNULIB_INET_PTON@]: Inline inet_pton.h declarations.
125261         * m4/inet_pton.m4: Don't check for header files.
125263         * m4/inet_ntop.m4: Don't check for header files.
125265 2008-04-28  Simon Josefsson  <simon@josefsson.org>
125267         * m4/sys_socket_h.m4: Require AC_C_INLINE when necessary.
125268         * lib/sys_socket.in.h (setsockopt): Use proper win32 tests (don't
125269         trigger for cygwin).
125270         Reported by Bruno Haible  <bruno@clisp.org>.
125272 2008-04-28  Bruno Haible  <bruno@clisp.org>
125274         * doc/posix-functions/strdup.texi: Mention mingw problem.
125276 2008-04-27  Bruno Haible  <bruno@clisp.org>
125278         * modules/stat-time-tests (Depends-on): Add sleep.
125279         * tests/test-stat-time.c (force_unlink): New function.
125280         (cleanup): Use it.
125281         (test_mtime): Remove the ctime related tests.
125282         (test_ctime): New function, containing the ctime related tests.
125283         (main): Call test_ctime, except on native Windows platforms.
125285 2008-04-27  Bruno Haible  <bruno@clisp.org>
125287         * lib/rpmatch.c (rpmatch): Add some comments.
125288         Reported by James Youngman <jay@gnu.org>.
125290 2008-04-27  Bruno Haible  <bruno@clisp.org>
125292         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Also test the behaviour on
125293         quiet NaNs.
125295 2008-04-27  Bruno Haible  <bruno@clisp.org>
125297         Make test-yesno.sh work on mingw.
125298         * tests/test-yesno.sh: Postprocess the output to convert CR/LF to LF.
125299         * tests/test-yesno.c: Include yesno.h first. Include binary-io.h.
125300         (main): Set stdin to binary mode.
125301         * modules/yesno-tests (Depends-on): Add binary-io.
125303 2008-04-27  Bruno Haible  <bruno@clisp.org>
125305         Fix 'isfinite' on x86, x86_64, ia64 platforms.
125306         * tests/test-isfinite.c (test_isfinitel): Also test the behavior on
125307         argument that lie outside the IEEE 854 domain.
125308         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): New macro.
125309         (gl_ISFINITE): Use it.
125310         * doc/posix-functions/isfinite.texi: Document the fixed bugs.
125312 2008-04-27  Bruno Haible  <bruno@clisp.org>
125314         Allow local renaming in config.h.
125315         * lib/memrchr.c (memrchr): Don't undefine outside libc.
125317 2008-04-27  Bruno Haible  <bruno@clisp.org>
125319         * lib/memchr.c (__memchr): Change type of 'i'.
125320         * lib/memchr2.c (memchr2): Likewise.
125322 2008-04-26  Eric Blake  <ebb9@byu.net>
125323         and Bruno Haible  <bruno@clisp.org>
125325         Optimize and test memrchr.
125326         * modules/memrchr (Depends-on): Add intprops.
125327         * lib/memrchr.c (__memrchr): Avoid false positives in loop.
125328         * modules/memrchr-tests: New file.
125329         * tests/test-memrchr.c: New file.
125331 2008-04-26  Bruno Haible  <bruno@clisp.org>
125333         Add tentative support for DragonFly BSD.
125334         * lib/stdio-impl.h: Add macros for DragonFly BSD.
125335         * lib/fbufmode.c (fbufmode): Update conditionals. Use fp_ instead of
125336         fp.
125337         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
125338         restore_seek_optimization, update_fpos_cache, rpl_fflush: Likewise.
125339         * lib/fpurge.c (fpurge): Likewise.
125340         * lib/freadable.c (freaadable): Likewise.
125341         * lib/freadahead.c (freadahead): Likewise.
125342         * lib/freading.c (freading): Likewise.
125343         * lib/freadptr.c (freadptr): Likewise.
125344         * lib/freadseek.c (freadptrinc): Likewise.
125345         * lib/fseeko.c (fseeko): Likewise.
125346         * lib/fseterr.c (fseterr): Likewise.
125347         * lib/fwritable.c (fwritable): Likewise.
125348         * lib/fwriting.c (fwriting): Likewise.
125350 2008-04-26  Bruno Haible  <bruno@clisp.org>
125352         * lib/stdio-impl.h: New file.
125353         * lib/fbufmode.c: Include stdio-impl.h.
125354         (fbufmode): Use fp_, remove redundant #defines.
125355         * lib/fflush.c: Include stdio-impl.h.
125356         (clear_ungetc_buffer): Remove redundant #defines.
125357         * lib/fpurge.c: Include stdio-impl.h.
125358         (fpurge): Remove redundant #defines.
125359         * lib/freadable.c: Include stdio-impl.h.
125360         (freadable): Remove redundant #defines.
125361         * lib/freadahead.c: Include stdio-impl.h.
125362         (freadahead): Remove redundant #defines.
125363         * lib/freading.c: Include stdio-impl.h.
125364         (freading): Remove redundant #defines.
125365         * lib/freadptr.c: Include stdio-impl.h.
125366         (freadptr): Remove redundant #defines.
125367         * lib/freadseek.c: Include stdio-impl.h.
125368         (freadptrinc): Remove redundant #defines.
125369         * lib/fseeko.c: Include stdio-impl.h.
125370         (rpl_fseeko): Remove redundant #defines.
125371         * lib/fseterr.c: Include stdio-impl.h.
125372         (fseterr): Remove redundant #defines.
125373         * lib/fwritable.c: Include stdio-impl.h.
125374         (fwritable: Remove redundant #defines.
125375         * lib/fwriting.c: Include stdio-impl.h.
125376         (fwriting): Remove redundant #defines.
125377         * modules/fbufmode (Files): Add lib/stdio-impl.h.
125378         * modules/fflush (Files): Likewise.
125379         * modules/fpurge (Files): Likewise.
125380         * modules/freadable (Files): Likewise.
125381         * modules/freadahead (Files): Likewise.
125382         * modules/freading (Files): Likewise.
125383         * modules/freadptr (Files): Likewise.
125384         * modules/freadseek (Files): Likewise.
125385         * modules/fseeko (Files): Likewise.
125386         * modules/fseterr (Files): Likewise.
125387         * modules/fwritable (Files): Likewise.
125388         * modules/fwriting (Files): Likewise.
125390 2008-04-26  Bruno Haible  <bruno@clisp.org>
125392         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
125393         restore_seek_optimization, update_fpos_cache): New functions, extracted
125394         from rpl_fflush.
125395         (rpl_fflush): Use them.
125396         * m4/fflush.m4 (gl_PREREQ_FFLUSH): New macro.
125397         (gl_REPLACE_FFLUSH): Use it.
125399 2008-04-26  Bruno Haible  <bruno@clisp.org>
125401         * tests/test-xstrtol.sh: Work around limitation of an old 'tr' program
125402         on Solaris.
125403         * tests/test-xstrtoimax.sh: Likewise.
125404         * tests/test-xstrtoumax.sh: Likewise.
125405         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
125407 2008-04-26  Bruno Haible  <bruno@clisp.org>
125409         * modules/memchr-tests: New file.
125410         * tests/test-memchr.c; New file, based on tests/test-memchr2.c.
125412 2008-04-26  Eric Blake  <ebb9@byu.net>
125413             Bruno Haible  <bruno@clisp.org>
125415         * lib/memchr.c: Include intprops.h.
125416         (__memchr): Optimize parallel detection of matching bytes. Rename local
125417         variables. Add explanatory comments.
125419 2008-04-26  Bruno Haible  <bruno@clisp.org>
125421         Fix module 'memchr', broken since 2000-10-28.
125422         * lib/memchr.c: Outside glibc, define memchr, not __memchr.
125424 2008-04-26  Bruno Haible  <bruno@clisp.org>
125426         * lib/memchr2.c (memchr2): Rename local variables. Add explanatory
125427         comments.
125429 2008-04-25  Eric Blake  <ebb9@byu.net>
125431         Use native fstatat on cygwin 1.7.0.
125432         * m4/openat.m4 (gl_FUNC_OPENAT): Make sure lstat check is made
125433         first.
125435 2008-04-23  Eric Blake  <ebb9@byu.net>
125437         Improve memchr2 performance.
125438         * lib/memchr2.c (memchr2): Further optimize parallel detection of
125439         NUL bytes.
125440         * modules/memchr2 (Depends-on): Use intprops.h.
125442 2008-04-23  Simon Josefsson  <simon@josefsson.org>
125444         * lib/sys_socket.in.h (setsockopt): Be more type safe by declaring
125445         an inline function instead of a CPP macro.  Patch by Ben Pfaff
125446         <blp@cs.stanford.edu>.
125448 2008-04-23  Simon Josefsson  <simon@josefsson.org>
125450         * lib/arpa_inet.in.h: New file.
125452         * modules/arpa_inet (Files): Add lib/arpa_inet.in.h.
125453         (Makefile.am): Sed in substitute header file.
125455         * m4/arpa_inet_h.m4: Add gl_ARPA_INET_H_DEFAULTS and
125456         gl_ARPA_INET_MODULE_INDICATOR.  Use them.
125458         * modules/inet_ntop (configure.ac): Use
125459         gl_ARPA_INET_MODULE_INDICATOR.
125461         * modules/inet_pton (configure.ac): Use
125462         gl_ARPA_INET_MODULE_INDICATOR.
125464 2008-04-22  Jim Meyering  <meyering@redhat.com>
125466         * modules/verify (License): Re-license as LGPLv2+.
125468 2008-04-22  Simon Josefsson  <simon@josefsson.org>
125470         * lib/sys_socket.in.h: Define setsockopt macro to cast fourth
125471         parameter to void* as per POSIX standard (MinGW uses char*).
125473 2008-04-21  Bruno Haible  <bruno@clisp.org>
125475         * lib/wctype.in.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
125476         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
125477         Define to replacements if REPLACE_ISWCNTRL is 1.
125478         * m4/wctype.m4 (gl_WCTYPE_H): Test whether the isw* functions work.
125479         If not, set WCTYPE_H to nonempty and REPLACE_ISWCNTRL to 1.
125480         * modules/wctype (Makefile.am): Substitute REPLACE_ISWCNTRL.
125481         * doc/posix-functions/iswalnum.texi: Mention the 'wctype' module and
125482         what it fixes.
125483         * doc/posix-functions/iswalpha.texi: Likewise.
125484         * doc/posix-functions/iswblank.texi: Likewise.
125485         * doc/posix-functions/iswcntrl.texi: Likewise.
125486         * doc/posix-functions/iswdigit.texi: Likewise.
125487         * doc/posix-functions/iswgraph.texi: Likewise.
125488         * doc/posix-functions/iswlower.texi: Likewise.
125489         * doc/posix-functions/iswprint.texi: Likewise.
125490         * doc/posix-functions/iswpunct.texi: Likewise.
125491         * doc/posix-functions/iswspace.texi: Likewise.
125492         * doc/posix-functions/iswupper.texi: Likewise.
125493         * doc/posix-functions/iswxdigit.texi: Likewise.
125494         Reported by Alain Guibert.
125496 2008-04-21  Bruno Haible  <bruno@clisp.org>
125498         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Fix typo in last commit.
125499         Patch by Alain Guibert.
125501 2008-04-21  Bruno Haible  <bruno@clisp.org>
125503         Fix test failures on mingw.
125504         * tests/test-xstrtol.c (print_no_progname): New function.
125505         (main): Install it in error_print_progname hook.
125506         * tests/test-xstrtol.sh: Convert CR/LF to NL in output.
125507         * tests/test-xstrtoimax.sh: Likewise.
125508         * tests/test-xstrtoumax.sh: Likewise.
125510 2008-04-21  Bruno Haible  <bruno@clisp.org>
125512         Fix test failure on mingw.
125513         * tests/test-argp-2.sh (func_compare): Remove CRs from sed's output.
125515 2008-04-21  Bruno Haible  <bruno@clisp.org>
125517         * lib/localename.c (SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN):
125518         Actually assign a value.
125520 2008-04-20  Bruno Haible  <bruno@clisp.org>
125522         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl',
125523         take 2.
125524         * lib/canonicalize.c (canonicalize_file_name): Elide if the
125525         'canonicalize-lgpl' module is also used.
125526         * lib/canonicalize-lgpl.c: Undo last change.
125527         * modules/canonicalize-lgpl (configure.ac): Invoke gl_MODULE_INDICATOR.
125529 2008-04-20  Bruno Haible  <bruno@clisp.org>
125531         * lib/mkdir.c (mkdir): Undefine after the includes, not right after
125532         config.h. Provide _mkdir based fallback for mingw.
125533         * lib/sys_stat.in.h (mkdir): Define through an 'extern' declaration
125534         if REPLACE_MKDIR is 1. Otherwise, test for mingw directly.
125535         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Require
125536         gl_SYS_STAT_H_DEFAULTS. When doing the replacement, set REPLACE_MKDIR
125537         rather than defining mkdir in config.h.
125538         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): New macro.
125539         (gl_SYS_STAT_H_DEFAULTS): New macro.
125540         (gl_HEADER_SYS_STAT_H): Require it. Don't set HAVE_DECL_MKDIR and
125541         HAVE_IO_H any more.
125542         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKDIR instead of
125543         HAVE_DECL_MKDIR and HAVE_IO_H.
125545 2008-04-20  Bruno Haible  <bruno@clisp.org>
125547         * lib/isapipe.c: Port to native Windows platforms.
125549 2008-04-20  Bruno Haible  <bruno@clisp.org>
125551         * lib/gc-gnulib.c: Include <windows.h> before <wincrypt.h>.
125553 2008-04-21  Eric Blake  <ebb9@byu.net>
125555         Work around preprocessors that don't handle UINTMAX_MAX.
125556         * lib/memchr2.c (memchr2): Avoid embedded #if.
125557         Reported by Alain Guibert, fix suggested by Bruno Haible.
125559 2008-04-21  Simon Josefsson  <simon@josefsson.org>
125561         * doc/posix-functions/strftime.texi (strftime): Explain better
125562         Windows incompatibility.  Suggested by Micah Cowan
125563         <micah@cowan.name>.
125565 2008-04-20  Bruno Haible  <bruno@clisp.org>
125567         * modules/uniconv/u32-conv-to-enc (Depends-on): Add unistr/u32-mblen,
125568         unistr/u8-mblen.
125570 2008-04-20  Bruno Haible  <bruno@clisp.org>
125572         Fix test failure on platforms with non-GNU iconv.
125573         * lib/uniconv/u16-conv-to-enc.c (u16_to_u8_lenient): New function.
125574         (U_TO_U8): Use it, rather than u16_to_u8.
125575         * lib/uniconv/u-conv-to-enc.h (FUNC): Allow an incomplete sequence of
125576         units at the end of the input string.
125577         * modules/uniconv/u16-conv-to-enc (Depends-on): Update.
125579 2008-04-20  Bruno Haible  <bruno@clisp.org>
125581         * tests/uniconv/test-u8-conv-to-enc.c (main): Accept result == NULL
125582         when the resulting length is 0.
125583         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
125585 2008-04-20  Bruno Haible  <bruno@clisp.org>
125587         * m4/roundf.m4 (gl_FUNC_ROUNDF): Add test whether roundf actually
125588         works.
125589         * doc/posix-functions/roundf.texi: Mention roundf bug on mingw.
125591 2008-04-20  Bruno Haible  <bruno@clisp.org>
125593         * tests/test-tsearch.c (main): Don't use initstate if it is missing.
125594         * modules/tsearch-tests (configure.ac): Test for initstate function.
125596 2008-04-20  Bruno Haible  <bruno@clisp.org>
125598         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Also provided a substitute
125599         for nlink_t if missing.
125600         * tests/test-sys_stat.c: Check the existence of the nlink_t type.
125602 2008-04-19  Bruno Haible  <bruno@clisp.org>
125604         Work around snprintf bug on Linux libc5.
125605         * m4/printf.m4 (gl_SNPRINTF_SIZE1): New macro.
125606         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
125607         gl_SNPRINTF_SIZE1.
125608         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
125609         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Likewise. Replace snprintf if
125610         that test failed.
125611         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Likewise.
125612         * lib/vasnprintf.c (USE_SNPRINTF): Set to 0 on Linux libc5 systems.
125613         * modules/snprintf (Files): Add m4/printf.m4.
125614         * modules/vsnprintf (Files): Likewise.
125615         * doc/posix-functions/snprintf.texi: Document Linux libc5 problem.
125616         * doc/posix-functions/vsnprintf.texi: Likewise.
125618 2008-04-19  Bruno Haible  <bruno@clisp.org>
125620         * lib/vasnprintf.c (floorlog10l, floorlog10): Reduce maximum error
125621         from 0.0058 to less than 10^-7.
125623 2008-04-19  Bruno Haible  <bruno@clisp.org>
125625         Fix rounding when a precision is given.
125626         * lib/vasnprintf.c (is_borderline): New function.
125627         (VASNPRINTF): For %e and %g, consider replacing the digits 10....0 with
125628         9...9x.
125629         * tests/test-vasnprintf-posix.c (test_function): Test rounding with %f,
125630         %e, %g.
125631         * tests/test-vasprintf-posix.c (test_function): Likewise.
125632         * tests/test-snprintf-posix.h (test_function): Likewise.
125633         * tests/test-sprintf-posix.h (test_function): Likewise.
125634         * tests/test-fprintf-posix.h (test_function): Test rounding with %f.
125635         * tests/test-printf-posix.h (test_function): Likewise.
125636         * tests/test-printf-posix.output: Update.
125637         Reported by John Darrington <john@darrington.wattle.id.au> via
125638         Ben Pfaff <blp@cs.stanford.edu>.
125640 2008-04-18  Simon Josefsson  <simon@josefsson.org>
125642         * doc/posix-functions/strftime.texi (strftime): Clarify platform.
125643         Suggested by Bruno Haible <bruno@clisp.org>.
125645 2008-04-17  Bruno Haible  <bruno@clisp.org>
125647         * lib/lock.h (gl_lock_destroy, gl_rwlock_destroy,
125648         gl_recursive_lock_destroy): Provide no-op definitions for the dummy
125649         implementation.
125650         Patch by Bruce Merry <bmerry@gmail.com>.
125652 2008-04-17  Simon Josefsson  <simon@josefsson.org>
125654         * doc/posix-functions/strftime.texi (strftime): Mention that %e
125655         doesn't work under Windows.
125657 2008-04-16  Bruno Haible  <bruno@clisp.org>
125659         * lib/localename.c (LANG_MAORI, LANG_QUECHUA, LANG_SOTHO, LANG_UIGHUR):
125660         New macros.
125661         (SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_LATIN,
125662         SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_CYRILLIC,
125663         SUBLANG_CROATIAN_CROATIA, SUBLANG_CROATIAN_BOSNIA_HERZEGOVINA_LATIN,
125664         SUBLANG_MONGOLIAN_CYRILLIC_MONGOLIA, SUBLANG_MONGOLIAN_PRC,
125665         SUBLANG_QUECHUA_BOLIVIA, SUBLANG_QUECHUA_ECUADOR, SUBLANG_QUECHUA_PERU,
125666         SUBLANG_RUSSIAN_RUSSIA, SUBLANG_RUSSIAN_MOLDAVIA, SUBLANG_SPANISH_US,
125667         SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN, SUBLANG_UIGHUR_PRC): New
125668         macros.
125669         (gl_locale_name_from_win32_LANGID): Refine code for Croatian/Bosnian,
125670         Mongolian, Russian, Spanish, Tibetan. Add code for Maori, Quechua,
125671         Northern Sotho, Uighur.
125673 2008-04-16  Bruno Haible  <bruno@clisp.org>
125675         * lib/localename.c (SUBLANG_SINDHI_INDIA): New macro.
125676         (SUBLANG_SINDHI_PAKISTAN): Change value from 1 to 2.
125677         (gl_locale_name_from_win32_LANGID): Fix code for Sindhi.
125678         Reported by Daniel Bergström <daniel@octocode.com>.
125680 2007-12-25  KJK::Hyperion  <hackbunny@reactos.com>
125681             Bruno Haible  <bruno@clisp.org>
125683         * lib/localename.c (gl_locale_name_canonicalize) [WIN32_NATIVE]: New
125684         function.
125685         (gl_locale_name_from_win32_LANGID, gl_locale_name_from_win32_LCID):
125686         New functions, mostly extracted from gl_locale_name_default.
125687         (gl_locale_name_default): Use gl_locale_name_from_win32_LCID.
125689 2008-04-16  Eric Blake  <ebb9@byu.net>
125691         Adjust strtod detection to catch glibc 2.7 bug.
125692         * m4/strtod.m4 (gl_FUNC_STRTOD): Test "nan()" behavior.
125693         Reported by John Gatewood Ham.
125695 2008-04-16  Bruno Haible  <bruno@clisp.org>
125697         Add tentative support for Linux libc5.
125698         * lib/fbufmode.c (fbufmode) [__GNU_LIBRARY__==1]: Reuse glibc2 code.
125699         * lib/fpurge.c (fpurge): Likewise.
125700         * lib/freadable.c (freadable): Likewise.
125701         * lib/freadahead.c (freadahead): Likewise.
125702         * lib/freading.c (freading): Likewise.
125703         * lib/freadptr.c (freadptr): Likewise.
125704         * lib/freadseek.c (freadptrinc): Likewise.
125705         * lib/fseeko.c (rpl_fseeko): Likewise.
125706         * lib/fseterr.c (fseterr): Likewise.
125707         * lib/fwritable.c (fwritable): Likewise.
125708         * lib/fwriting.c (fwriting): Likewise.
125709         Reported by Alain Guibert <alguibert+bts@free.fr>.
125711 2008-04-15  Bruno Haible  <bruno@clisp.org>
125713         * modules/mathl (configure.ac): Define module indicator.
125715 2008-04-15  Bruno Haible  <bruno@clisp.org>
125717         * lib/logl.c (logl): Remove unused variables.
125719 2008-04-15  Bruno Haible  <bruno@clisp.org>
125721         * lib/uniconv/u-conv-to-enc.h (FUNC): Fix return value when U_TO_U8
125722         fails.
125724 2008-04-15  Bruno Haible  <bruno@clisp.org>
125726         * lib/trim.c (trim2): Fix argument of isspace() macro.
125728 2008-04-15  Paolo Bonzini  <bonzini@gnu.org>
125730         * lib/tanl.c (kernel_tanl): Rename flag to invert, initialize it
125731         to 0.
125732         * lib/trigl.c (ieee754_rem_pio2l): Fix range checks.
125734 2008-04-14  Bruno Haible  <bruno@clisp.org>
125736         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Fix underquoting of
125737         AC_LANG_PROGRAM argument.
125738         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Likewise.
125739         * m4/gethrxtime.m4 (gl_ARITHMETIC_HRTIME_T): Likewise.
125740         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
125741         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
125742         * m4/math_h.m4 (gl_MATH_H): Likewise.
125743         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
125744         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
125745         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
125746         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Likewise.
125747         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
125748         * m4/regex.m4 (gl_REGEX): Likewise.
125749         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Likewise.
125750         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET): Likewise.
125751         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
125752         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Likewise.
125753         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
125754         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
125755         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
125756         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
125758 2008-04-14  Jim Meyering  <meyering@redhat.com>
125760         test-strtod: fix typos: s/abs/fabs/
125761         * tests/test-strtod.c (main): Use fabs, not narrowing-to-int "abs".
125763 2008-04-13  Bruno Haible  <bruno@clisp.org>
125765         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl'.
125766         * lib/canonicalize-lgpl.c: Elide the contents if the 'canonicalize'
125767         module is also used and while not building the reloc-wrapper.
125769 2008-04-13  Bruno Haible  <bruno@clisp.org>
125771         * tests/test-getaddrinfo.c (simple): Ignore EAI_NODATA error.
125773 2008-04-13  Bruno Haible  <bruno@clisp.org>
125775         Fix AIX compilation failure introduced on 2008-04-02.
125776         * tests/test-frexp.c (exp): Undefine before redefining.
125777         * tests/test-frexpl.c (exp): Likewise.
125779 2008-04-13  Bruno Haible  <bruno@clisp.org>
125781         Work around a HP-UX stdio bug.
125782         * tests/test-ftell.c (main): Disable the fseek/ftell test on HP-UX.
125783         * tests/test-ftello.c (main): Likewise.
125784         * doc/posix-functions/ftell.texi: Mention HP-UX bug.
125785         * doc/posix-functions/ftello.texi: Likewise.
125787 2008-04-13  Bruno Haible  <bruno@clisp.org>
125789         Make test-signbit pass on HP-UX/hppa.
125790         * tests/test-signbit.c (minus_zerol): New variable.
125791         (test_signbitl): Use it.
125793 2008-04-13  Bruno Haible  <bruno@clisp.org>
125795         Make truncl work on OSF/1 4.0.
125796         * m4/truncl.m4 (gl_FUNC_TRUNCL): Test whether truncl actually works.
125797         Set REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
125798         * lib/math.in.h (truncl): Test REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
125799         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNCL, not
125800         HAVE_DECL_TRUNCL.
125801         * modules/math (Makefile.am): Substitute REPLACE_TRUNCL, not
125802         HAVE_DECL_TRUNCL.
125803         * doc/posix-functions/truncl.texi: Document the OSF/1 4.0 problem.
125805 2008-04-13  Bruno Haible  <bruno@clisp.org>
125807         * lib/unictype.h: Remove trailing comma from enumeration definitions.
125809 2008-04-13  Bruno Haible  <bruno@clisp.org>
125811         * lib/count-one-bits.h (COUNT_ONE_BITS): Rewrite verification
125812         expression, so as to avoid HP-UX 11 cc compiler bug.
125814 2008-04-13  Bruno Haible  <bruno@clisp.org>
125816         * m4/regex.m4 (gl_PREREQ_REGEX): Also check for <libintl.h>.
125818 2008-04-13  Bruno Haible  <bruno@clisp.org>
125820         * lib/git-merge-changelog.c: Remove empty declaration outside of
125821         functions.
125823 2008-04-13  Bruno Haible  <bruno@clisp.org>
125825         * modules/quotearg-tests (Makefile.am): Define test_quotearg_LDADD.
125827 2008-04-13  Bruno Haible  <bruno@clisp.org>
125829         * doc/posix-headers/sys_socket.texi: Document the problem on EMX.
125830         * lib/sys_socket.in.h (SHUT_RD, SHUT_WR, SHUT_RDWR): Define if missing.
125831         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Replace <sys/socket.h>
125832         also if it exists but lacks definitions of the SHUT_* macros.
125833         * modules/sys_socket (Description): Update.
125834         Reported by Elbert Pol <e.pol@chello.nl>.
125836 2008-04-13  Bruno Haible  <bruno@clisp.org>
125838         * lib/localcharset.c (OS2): Don't redefine if already defined.
125839         Reported by Elbert Pol <e.pol@chello.nl>.
125841 2008-04-13  Bruno Haible  <bruno@clisp.org>
125843         * lib/binary-io.h [__EMX__]: Include <io.h>.
125844         Reported by Elbert Pol <e.pol@chello.nl>.
125846 2008-04-12  Bruno Haible  <bruno@clisp.org>
125848         * lib/fpucw.h: Enable the definitions also for x86_64.
125849         Needed for NetBSD/x86_64.
125850         Reported by Thomas Klausner <tk@giga.or.at>.
125852 2008-04-12  Bruno Haible  <bruno@clisp.org>
125854         * tests/test-strtod.c: Include isnand.h.
125855         (main): Use isnand instead of isnan.
125856         Reported by Jim Meyering.
125858 2008-04-12  Bruno Haible  <bruno@clisp.org>
125860         * m4/isnanf.m4 (gl_ISNANF_WORKS): Add a test for a special NaN.
125861         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
125863 2008-04-12  Jim Meyering  <meyering@redhat.com>
125865         * m4/math_h.m4 (gl_MATH_H): Fix typos.
125867 2008-04-12  Bruno Haible  <bruno@clisp.org>
125869         * lib/freadptr.c (freadptr) [__EMX__]: Fix wrong assertion.
125870         Reported by Elbert Pol <e.pol@chello.nl>.
125872 2008-04-12  Eric Blake  <ebb9@byu.net>
125874         Work around Solaris 10 math.h bug.
125875         * m4/math_h.m4 (gl_MATH_H): Check for bug.
125876         (gl_MATH_H_DEFAULTS): Set up default.
125877         * modules/math (Makefile.am): Replace new indicators.
125878         * lib/math.in.h (NAN, HUGE_VAL): Provide replacements.
125879         * tests/test-math.c (main): Test this.
125880         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't rely on HUGE_VAL.
125881         * doc/posix-headers/math.texi (math.h): Mention bug.
125882         Reported by Nelson H. F. Beebe and Jim Meyering.
125884 2008-04-11  Bruno Haible  <bruno@clisp.org>
125886         Adapt to future versions of Apple GCC.
125887         * lib/argp-fmtstream.h (ARGP_FS_EI): Don't test __GNUC_GNU_INLINE__.
125888         Reported by Peter O'Gorman <peter@pogma.com>.
125890 2008-04-11  Bruno Haible  <bruno@clisp.org>
125892         * tests/test-getaddrinfo.c (simple): Ignore EAI_NONAME error.
125894 2008-04-11  Bruno Haible  <bruno@clisp.org>
125896         * modules/strsignal-tests (Makefile.am): Define test_strsignal_LDADD.
125898         * modules/getaddrinfo-tests (Makefile.am): Define
125899         test_getaddrinfo_LDADD.
125901 2008-04-11  Bruno Haible  <bruno@clisp.org>
125903         * lib/strsignal.c (_sys_siglist): Don't declare if already declared.
125904         (init): Fix syntax error.
125905         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Check whether _sys_siglist
125906         is declared.
125908 2008-04-11  Bruno Haible  <bruno@clisp.org>
125910         * lib/glob.c: Include <stdbool.h>. Needed at least with IRIX cc.
125911         * modules/glob (Depends-on): Add stdbool.
125913 2008-04-11  Bruno Haible  <bruno@clisp.org>
125915         * lib/trim.c: Include <string.h>.
125917 2008-04-11  Eric Blake  <ebb9@byu.net>
125919         Avoid compile failure on OS/2.
125920         * lib/regex_internal.h (internal_function): Disable optimization
125921         on OS/2 (__EMX__), where it caused compiler error.
125922         Reported by Elbert Pol.
125924 2008-04-11  Bruno Haible  <bruno@clisp.org>
125926         Flush the standard error stream before aborting. Needed on mingw.
125927         * tests/test-argmatch.c (ASSERT): Call fflush(stderr) before abort().
125928         * tests/test-array_list.c (ASSERT): Likewise.
125929         * tests/test-array_oset.c (ASSERT): Likewise.
125930         * tests/test-avltree_list.c (ASSERT): Likewise.
125931         * tests/test-avltree_oset.c (ASSERT): Likewise.
125932         * tests/test-avltreehash_list.c (ASSERT): Likewise.
125933         * tests/test-binary-io.c (ASSERT): Likewise.
125934         * tests/test-byteswap.c (ASSERT): Likewise.
125935         * tests/test-c-ctype.c (ASSERT): Likewise.
125936         * tests/test-c-strcasecmp.c (ASSERT): Likewise.
125937         * tests/test-c-strcasestr.c (ASSERT): Likewise.
125938         * tests/test-c-strncasecmp.c (ASSERT): Likewise.
125939         * tests/test-c-strstr.c (ASSERT): Likewise.
125940         * tests/test-canonicalize-lgpl.c (ASSERT): Likewise.
125941         * tests/test-canonicalize.c (ASSERT): Likewise.
125942         * tests/test-carray_list.c (ASSERT): Likewise.
125943         * tests/test-ceilf1.c (ASSERT): Likewise.
125944         * tests/test-ceilf2.c (ASSERT): Likewise.
125945         * tests/test-ceill.c (ASSERT): Likewise.
125946         * tests/test-count-one-bits.c (ASSERT): Likewise.
125947         * tests/test-fbufmode.c (ASSERT): Likewise.
125948         * tests/test-fflush2.c (ASSERT): Likewise.
125949         * tests/test-floorf1.c (ASSERT): Likewise.
125950         * tests/test-floorf2.c (ASSERT): Likewise.
125951         * tests/test-floorl.c (ASSERT): Likewise.
125952         * tests/test-fopen.c (ASSERT): Likewise.
125953         * tests/test-fpending.c (ASSERT): Likewise.
125954         * tests/test-fprintf-posix.c (ASSERT): Likewise.
125955         * tests/test-fpurge.c (ASSERT): Likewise.
125956         * tests/test-freadable.c (ASSERT): Likewise.
125957         * tests/test-freadahead.c (ASSERT): Likewise.
125958         * tests/test-freading.c (ASSERT): Likewise.
125959         * tests/test-freadptr.c (ASSERT): Likewise.
125960         * tests/test-freadptr2.c (ASSERT): Likewise.
125961         * tests/test-freadseek.c (ASSERT): Likewise.
125962         * tests/test-freopen.c (ASSERT): Likewise.
125963         * tests/test-frexp.c (ASSERT): Likewise.
125964         * tests/test-frexpl.c (ASSERT): Likewise.
125965         * tests/test-fseek.c (ASSERT): Likewise.
125966         * tests/test-fseeko.c (ASSERT): Likewise.
125967         * tests/test-fstrcmp.c (ASSERT): Likewise.
125968         * tests/test-ftell.c (ASSERT): Likewise.
125969         * tests/test-ftello.c (ASSERT): Likewise.
125970         * tests/test-func.c (ASSERT): Likewise.
125971         * tests/test-fwritable.c (ASSERT): Likewise.
125972         * tests/test-fwriting.c (ASSERT): Likewise.
125973         * tests/test-getdelim.c (ASSERT): Likewise.
125974         * tests/test-getline.c (ASSERT): Likewise.
125975         * tests/test-i-ring.c (ASSERT): Likewise.
125976         * tests/test-iconv-utf.c (ASSERT): Likewise.
125977         * tests/test-iconv.c (ASSERT): Likewise.
125978         * tests/test-isfinite.c (ASSERT): Likewise.
125979         * tests/test-isnand.c (ASSERT): Likewise.
125980         * tests/test-isnanf.c (ASSERT): Likewise.
125981         * tests/test-isnanl.h (ASSERT): Likewise.
125982         * tests/test-ldexpl.c (ASSERT): Likewise.
125983         * tests/test-linked_list.c (ASSERT): Likewise.
125984         * tests/test-linkedhash_list.c (ASSERT): Likewise.
125985         * tests/test-localename.c (ASSERT): Likewise.
125986         * tests/test-lseek.c (ASSERT): Likewise.
125987         * tests/test-mbscasecmp.c (ASSERT): Likewise.
125988         * tests/test-mbscasestr1.c (ASSERT): Likewise.
125989         * tests/test-mbscasestr2.c (ASSERT): Likewise.
125990         * tests/test-mbscasestr3.c (ASSERT): Likewise.
125991         * tests/test-mbscasestr4.c (ASSERT): Likewise.
125992         * tests/test-mbschr.c (ASSERT): Likewise.
125993         * tests/test-mbscspn.c (ASSERT): Likewise.
125994         * tests/test-mbsncasecmp.c (ASSERT): Likewise.
125995         * tests/test-mbspbrk.c (ASSERT): Likewise.
125996         * tests/test-mbspcasecmp.c (ASSERT): Likewise.
125997         * tests/test-mbsrchr.c (ASSERT): Likewise.
125998         * tests/test-mbsspn.c (ASSERT): Likewise.
125999         * tests/test-mbsstr1.c (ASSERT): Likewise.
126000         * tests/test-mbsstr2.c (ASSERT): Likewise.
126001         * tests/test-mbsstr3.c (ASSERT): Likewise.
126002         * tests/test-memchr2.c (ASSERT): Likewise.
126003         * tests/test-memmem.c (ASSERT): Likewise.
126004         * tests/test-open.c (ASSERT): Likewise.
126005         * tests/test-printf-frexp.c (ASSERT): Likewise.
126006         * tests/test-printf-frexpl.c (ASSERT): Likewise.
126007         * tests/test-printf-posix.c (ASSERT): Likewise.
126008         * tests/test-quotearg.c (ASSERT): Likewise.
126009         * tests/test-rbtree_list.c (ASSERT): Likewise.
126010         * tests/test-rbtree_oset.c (ASSERT): Likewise.
126011         * tests/test-rbtreehash_list.c (ASSERT): Likewise.
126012         * tests/test-round1.c (ASSERT): Likewise.
126013         * tests/test-roundf1.c (ASSERT): Likewise.
126014         * tests/test-roundl.c (ASSERT): Likewise.
126015         * tests/test-signbit.c (ASSERT): Likewise.
126016         * tests/test-sleep.c (ASSERT): Likewise.
126017         * tests/test-snprintf-posix.c (ASSERT): Likewise.
126018         * tests/test-snprintf.c (ASSERT): Likewise.
126019         * tests/test-sprintf-posix.c (ASSERT): Likewise.
126020         * tests/test-stat-time.c (ASSERT): Likewise.
126021         * tests/test-strcasestr.c (ASSERT): Likewise.
126022         * tests/test-strerror.c (ASSERT): Likewise.
126023         * tests/test-striconv.c (ASSERT): Likewise.
126024         * tests/test-striconveh.c (ASSERT): Likewise.
126025         * tests/test-striconveha.c (ASSERT): Likewise.
126026         * tests/test-strsignal.c (ASSERT): Likewise.
126027         * tests/test-strstr.c (ASSERT): Likewise.
126028         * tests/test-strtod.c (ASSERT): Likewise.
126029         * tests/test-trunc1.c (ASSERT): Likewise.
126030         * tests/test-trunc2.c (ASSERT): Likewise.
126031         * tests/test-truncf1.c (ASSERT): Likewise.
126032         * tests/test-truncf2.c (ASSERT): Likewise.
126033         * tests/test-truncl.c (ASSERT): Likewise.
126034         * tests/test-vasnprintf-posix.c (ASSERT): Likewise.
126035         * tests/test-vasnprintf-posix2.c (ASSERT): Likewise.
126036         * tests/test-vasnprintf.c (ASSERT): Likewise.
126037         * tests/test-vasprintf-posix.c (ASSERT): Likewise.
126038         * tests/test-vasprintf.c (ASSERT): Likewise.
126039         * tests/test-vfprintf-posix.c (ASSERT): Likewise.
126040         * tests/test-vprintf-posix.c (ASSERT): Likewise.
126041         * tests/test-vsnprintf-posix.c (ASSERT): Likewise.
126042         * tests/test-vsnprintf.c (ASSERT): Likewise.
126043         * tests/test-vsprintf-posix.c (ASSERT): Likewise.
126044         * tests/test-wcwidth.c (ASSERT): Likewise.
126045         * tests/test-xfprintf-posix.c (ASSERT): Likewise.
126046         * tests/test-xprintf-posix.c (ASSERT): Likewise.
126047         * tests/test-xvasprintf.c (ASSERT): Likewise.
126048         * tests/uniconv/test-u16-conv-from-enc.c (ASSERT): Likewise.
126049         * tests/uniconv/test-u16-conv-to-enc.c (ASSERT): Likewise.
126050         * tests/uniconv/test-u16-strconv-from-enc.c (ASSERT): Likewise.
126051         * tests/uniconv/test-u16-strconv-to-enc.c (ASSERT): Likewise.
126052         * tests/uniconv/test-u32-conv-from-enc.c (ASSERT): Likewise.
126053         * tests/uniconv/test-u32-conv-to-enc.c (ASSERT): Likewise.
126054         * tests/uniconv/test-u32-strconv-from-enc.c (ASSERT): Likewise.
126055         * tests/uniconv/test-u32-strconv-to-enc.c (ASSERT): Likewise.
126056         * tests/uniconv/test-u8-conv-from-enc.c (ASSERT): Likewise.
126057         * tests/uniconv/test-u8-conv-to-enc.c (ASSERT): Likewise.
126058         * tests/uniconv/test-u8-strconv-from-enc.c (ASSERT): Likewise.
126059         * tests/uniconv/test-u8-strconv-to-enc.c (ASSERT): Likewise.
126060         * tests/unictype/test-bidi_byname.c (ASSERT): Likewise.
126061         * tests/unictype/test-bidi_name.c (ASSERT): Likewise.
126062         * tests/unictype/test-bidi_of.c (ASSERT): Likewise.
126063         * tests/unictype/test-bidi_test.c (ASSERT): Likewise.
126064         * tests/unictype/test-block_list.c (ASSERT): Likewise.
126065         * tests/unictype/test-block_of.c (ASSERT): Likewise.
126066         * tests/unictype/test-block_test.c (ASSERT): Likewise.
126067         * tests/unictype/test-categ_and.c (ASSERT): Likewise.
126068         * tests/unictype/test-categ_and_not.c (ASSERT): Likewise.
126069         * tests/unictype/test-categ_byname.c (ASSERT): Likewise.
126070         * tests/unictype/test-categ_name.c (ASSERT): Likewise.
126071         * tests/unictype/test-categ_none.c (ASSERT): Likewise.
126072         * tests/unictype/test-categ_of.c (ASSERT): Likewise.
126073         * tests/unictype/test-categ_or.c (ASSERT): Likewise.
126074         * tests/unictype/test-categ_test_withtable.c (ASSERT): Likewise.
126075         * tests/unictype/test-combining.c (ASSERT): Likewise.
126076         * tests/unictype/test-decdigit.c (ASSERT): Likewise.
126077         * tests/unictype/test-digit.c (ASSERT): Likewise.
126078         * tests/unictype/test-mirror.c (ASSERT): Likewise.
126079         * tests/unictype/test-numeric.c (ASSERT): Likewise.
126080         * tests/unictype/test-pr_byname.c (ASSERT): Likewise.
126081         * tests/unictype/test-pr_test.c (ASSERT): Likewise.
126082         * tests/unictype/test-predicate-part1.h (ASSERT): Likewise.
126083         * tests/unictype/test-scripts.c (ASSERT): Likewise.
126084         * tests/unictype/test-sy_c_ident.c (ASSERT): Likewise.
126085         * tests/unictype/test-sy_java_ident.c (ASSERT): Likewise.
126086         * tests/unistdio/test-u16-asnprintf1.c (ASSERT): Likewise.
126087         * tests/unistdio/test-u16-vasnprintf1.c (ASSERT): Likewise.
126088         * tests/unistdio/test-u16-vasnprintf2.c (ASSERT): Likewise.
126089         * tests/unistdio/test-u16-vasnprintf3.c (ASSERT): Likewise.
126090         * tests/unistdio/test-u16-vasprintf1.c (ASSERT): Likewise.
126091         * tests/unistdio/test-u16-vsnprintf1.c (ASSERT): Likewise.
126092         * tests/unistdio/test-u16-vsprintf1.c (ASSERT): Likewise.
126093         * tests/unistdio/test-u32-asnprintf1.c (ASSERT): Likewise.
126094         * tests/unistdio/test-u32-vasnprintf1.c (ASSERT): Likewise.
126095         * tests/unistdio/test-u32-vasnprintf2.c (ASSERT): Likewise.
126096         * tests/unistdio/test-u32-vasnprintf3.c (ASSERT): Likewise.
126097         * tests/unistdio/test-u32-vasprintf1.c (ASSERT): Likewise.
126098         * tests/unistdio/test-u32-vsnprintf1.c (ASSERT): Likewise.
126099         * tests/unistdio/test-u32-vsprintf1.c (ASSERT): Likewise.
126100         * tests/unistdio/test-u8-asnprintf1.c (ASSERT): Likewise.
126101         * tests/unistdio/test-u8-vasnprintf1.c (ASSERT): Likewise.
126102         * tests/unistdio/test-u8-vasnprintf2.c (ASSERT): Likewise.
126103         * tests/unistdio/test-u8-vasnprintf3.c (ASSERT): Likewise.
126104         * tests/unistdio/test-u8-vasprintf1.c (ASSERT): Likewise.
126105         * tests/unistdio/test-u8-vsnprintf1.c (ASSERT): Likewise.
126106         * tests/unistdio/test-u8-vsprintf1.c (ASSERT): Likewise.
126107         * tests/unistdio/test-ulc-asnprintf1.c (ASSERT): Likewise.
126108         * tests/unistdio/test-ulc-vasnprintf1.c (ASSERT): Likewise.
126109         * tests/unistdio/test-ulc-vasnprintf2.c (ASSERT): Likewise.
126110         * tests/unistdio/test-ulc-vasnprintf3.c (ASSERT): Likewise.
126111         * tests/unistdio/test-ulc-vasprintf1.c (ASSERT): Likewise.
126112         * tests/unistdio/test-ulc-vsnprintf1.c (ASSERT): Likewise.
126113         * tests/unistdio/test-ulc-vsprintf1.c (ASSERT): Likewise.
126114         * tests/uniwidth/test-u16-strwidth.c (ASSERT): Likewise.
126115         * tests/uniwidth/test-u16-width.c (ASSERT): Likewise.
126116         * tests/uniwidth/test-u32-strwidth.c (ASSERT): Likewise.
126117         * tests/uniwidth/test-u32-width.c (ASSERT): Likewise.
126118         * tests/uniwidth/test-u8-strwidth.c (ASSERT): Likewise.
126119         * tests/uniwidth/test-u8-width.c (ASSERT): Likewise.
126120         * tests/uniwidth/test-uc_width.c (ASSERT): Likewise.
126121         Reported by Eric Blake.
126123 2008-04-11  Bruno Haible  <bruno@clisp.org>
126125         * lib/wchar.in.h: Tweak comment.
126127 2008-04-11  Bruno Haible  <bruno@clisp.org>
126129         Fix __GNUC_STDC_INLINE__ predefine with Apple GCC on MacOS X 10.5.
126130         * gnulib-tool (func_emit_initmacro_start): Emit an invocation of
126131         gl_COMMON.
126132         * m4/gnulib-common.m4 (gl_COMMON, gl_COMMON_BODY): New macros.
126134 2008-04-11  Bruno Haible  <bruno@clisp.org>
126136         * modules/git-merge-changelog (git_merge_changelog_LDADD): Add LIBINTL.
126138 2008-04-11  Simon Josefsson  <simon@josefsson.org>
126140         * lib/gc-gnulib.c: On Windows, use CryptGenRandom from CSP instead
126141         of attempting to use nonexistent /dev/*random.  Based on patch
126142         from Adam Strzelecki <ono@java.pl> in
126143         <http://lists.gnu.org/r/help-gsasl/2008-02/msg00000.html>.
126145 2008-04-08  Bruno Haible  <bruno@clisp.org>
126147         Add tentative support for emx+gcc.
126148         * lib/fbufmode.c (fbufmode) [__EMX__]: Add conditional code.
126149         * lib/fpurge.c (fpurge): Likewise.
126150         * lib/freadable.c (freadable): Likewise.
126151         * lib/freadahead.c (freadahead): Likewise.
126152         * lib/freading.c (freading): Likewise.
126153         * lib/freadptr.c (freadptr): Likewise.
126154         * lib/freadseek.c (freadptrinc): Likewise.
126155         * lib/fseeko.c (rpl_fseeko): Likewise.
126156         * lib/fseterr.c (fseterr): Likewise.
126157         * lib/fwritable.c (fwritable): Likewise.
126158         * lib/fwriting.c (fwriting): Likewise.
126159         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for emx+gcc.
126161 2008-04-09  Eric Blake  <ebb9@byu.net>
126163         Avoid some autoconf warnings.
126164         * m4/regex.m4 (gl_REGEX): s/AC_HELP_STRING/AS_HELP_STRING/.
126165         * m4/acl.m4 (gl_FUNC_ACL): Likewise.
126166         * m4/afs.m4 (gl_AFS): Likewise.
126167         * m4/gc-random.m4 (gl_GC_RANDOM): Likewise.
126168         * m4/include_next.m4 (gl_INCLUDE_NEXT): s/AC_FOREACH/m4_foreach_w/.
126169         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
126170         * m4/stdint.m4 (gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED)
126171         (gl_INTEGER_TYPE_SUFFIX): Likewise.
126172         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE)
126173         (AC_CHECK_DECLS_ONCE): Likewise.
126174         Rename file...
126175         * m4/onceonly.m4: ...to this, and delete 2.54 variant, now that
126176         gnulib-tool requires autoconf 2.59 or better.
126177         * gnulib-tool (func_get_filelist): s/\(onceonly\)_2_57.m4/\1.m4/.
126179 2008-04-08  Eric Blake  <ebb9@byu.net>
126181         Use 'git describe --match' if present (added in git 1.5.5).
126182         * build-aux/git-version-gen: Limit result to tags that match 'v*'
126183         if possible.
126185 2008-04-08  Bruno Haible  <bruno@clisp.org>
126187         Add tentative support for OpenServer.
126188         * lib/fbufmode.c (fbufmode): Add conditional define for _flag, _base,
126189         _ptr, _cnt.
126190         * lib/fpurge.c (fpurge): Likewise.
126191         * lib/freadable.c (freadable): Likewise.
126192         * lib/freadahead.c (freadahead): Likewise.
126193         * lib/freading.c (freading): Likewise.
126194         * lib/freadptr.c (freadptr): Likewise.
126195         * lib/freadseek.c (freadptrinc): Likewise.
126196         * lib/fseeko.c (rpl_fseeko): Likewise.
126197         * lib/fseterr.c (fseterr): Likewise.
126198         * lib/fwritable.c (fwritable): Likewise.
126199         * lib/fwriting.c (fwriting): Likewise.
126200         Reported by Roger Cornelius <rac@tenzing.org> and
126201         Brian K. White <brian@aljex.com>.
126203 2008-04-06  Jim Meyering  <meyering@redhat.com>
126205         * gnulib-tool (func_add_or_update): s/backuped/backed up/ in diagnostic
126207 2008-04-06  Bruno Haible  <bruno@clisp.org>
126209         Avoid possible error with non-ASCII bytes in UTF-8 locales.
126210         * tests/test-fprintf-posix.sh: Use "LC_ALL=C tr" instead of "tr".
126211         * tests/test-printf-posix.sh: Likewise.
126212         * tests/test-vfprintf-posix.sh: Likewise.
126213         * tests/test-vprintf-posix.sh: Likewise.
126214         * tests/test-xprintf-posix.sh: Likewise.
126216 2008-04-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
126218         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT): Fix quoting,
126219         hide error from 'ls', needed on OS/2.
126220         Report by Elbert Pol <elbert.pol@gmail.com>.
126222 2008-04-04  Eric Blake  <ebb9@byu.net>
126224         Make test-fseeko.c failures meaningful.
126225         * tests/test-fseeko.c: Print line number on failure.
126226         * tests/test-fseek.c: Likewise.
126227         Reported by Nelson H. F. Beebe.
126229         Improve strtod bug detection check.
126230         * m4/strtod.m4 (gl_FUNC_STRTOD): Also check for hex-float parsing,
126231         required for Solaris 10.
126232         Reported by Bob Friesenhahn and Nelson H. F. Beebe.
126234 2008-04-04  Bruno Haible  <bruno@clisp.org>
126236         * modules/relocatable-prog-wrapper (Files): Add m4/environ.m4. Needed
126237         by m4/setenv.m4.
126239 2008-04-03  Eric Blake  <ebb9@byu.net>
126241         Ensure sane .version contents.
126242         * top/GNUmakefile (_dummy): Also delete .version when rebuilding
126243         version string.
126244         * build-aux/git-version-gen: Improve documentation.
126246         Make GNU make output nicer.
126247         * top/GNUmakefile [!_have-Makefile]: Add dependency on
126248         MAKECMDGOALS to enforce message for all command line targets.  Set
126249         srcdir for use in maint.mk.
126251         Another maintainer tweak.
126252         * top/GNUmakefile (_is-dist-target): Allow maintainer-distcheck as
126253         a target that regenerates version.
126255 2008-04-03  Jim Meyering  <meyering@redhat.com>
126257         vc-list-files: don't cause coreutils "make po-check" failure
126258         * build-aux/vc-list-files: Skip postprocessing when $2 is '.'
126260 2008-04-03  Eric Blake  <ebb9@byu.net>
126262         Allow VPATH usage of vc-list-files.
126263         * build-aux/vc-list-files (scriptversion): Add timestamp.
126264         (options): Add --help, --version, -C.
126265         (CVS): Support installed cvsu.
126267 2008-04-02  Bruno Haible  <bruno@clisp.org>
126269         Avoid some "statement with no effect" warnings from gcc.
126270         * tests/test-wctype.c (main): Explicitly ignore unused values.
126271         Reported by Jim Meyering.
126273 2008-04-02  Jim Meyering  <meyering@redhat.com>
126275         Avoid some warnings from "gcc -Wshadow".
126276         * tests/test-frexp.c (exp): Define to a different identifier.
126277         * tests/test-frexpl.c (exp): Likewise.
126279 2008-04-03  Jim Meyering  <meyering@redhat.com>
126281         bootstrap: remove dangling *.[ch] symlinks from lib
126282         * build-aux/bootstrap [dangling symlink removal]: Move find's
126283         -depth option to precede all others, to avoid a warning.
126284         Remove *.[ch] files too, and from "$source_base" (usually lib/).
126286 2008-04-02  Bruno Haible  <bruno@clisp.org>
126288         Avoid some warnings from "gcc -Wshadow".
126289         * tests/tests-vfprintf-posix.c (my_fprintf): Move after test_function.
126290         * tests/tests-vprintf-posix.c (my_printf): Move after test_function.
126291         * tests/tests-vsnprintf-posix.c (my_snprintf): Move after test_function.
126292         * tests/tests-vsprintf-posix.c (my_sprintf): Move after test_function.
126293         Reported by Jim Meyering.
126295 2008-04-01  Bruno Haible  <bruno@clisp.org>
126297         Fix test to work on IRIX 6.5 with cc.
126298         * tests/test-math.c (numeric_equal): New function.
126299         (main): Use it.
126301 2008-04-01  Bruno Haible  <bruno@clisp.org>
126303         * doc/posix-headers/math.texi: Refine documentation of NAN problem.
126305 2008-04-01  Bruno Haible  <bruno@clisp.org>
126307         * tests/test-vasnprintf-posix.c: Include nan.h instead of <math.h>.
126308         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
126309         * modules/vasnprintf-posix-tests (Files): Add tests/nan.h.
126310         (Depends-on): Remove math.
126312         * tests/test-vasprintf-posix.c: Include nan.h instead of <math.h>.
126313         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
126314         * modules/vasprintf-posix-tests (Files): Add tests/nan.h.
126315         (Depends-on): Remove math.
126317         * tests/test-snprintf-posix.h: Include nan.h instead of <math.h>.
126318         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
126319         * modules/snprintf-posix-tests (Files): Add tests/nan.h.
126320         (Depends-on): Remove math.
126321         * modules/vsnprintf-posix-tests (Files): Add tests/nan.h.
126322         (Depends-on): Remove math.
126324         * tests/test-sprintf-posix.h: Include nan.h instead of <math.h>.
126325         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
126326         * modules/sprintf-posix-tests (Files): Add tests/nan.h.
126327         (Depends-on): Remove math.
126328         * modules/vsprintf-posix-tests (Files): Add tests/nan.h.
126329         (Depends-on): Remove math.
126331         * tests/test-round1.c: Include nan.h.
126332         (main): Use NaNd instead of NAN.
126333         * modules/round-tests (Files): Add tests/nan.h.
126335         * tests/test-trunc1.c: Include nan.h.
126336         (main): Use NaNd instead of NAN.
126337         * modules/trunc-tests (Files): Add tests/nan.h.
126339         * tests/test-roundf1.c: Include nan.h.
126340         (main): Use NaNf instead of NAN.
126341         * modules/roundf-tests (Files): Add tests/nan.h.
126343         * tests/test-truncf1.c: Include nan.h.
126344         (main): Use NaNf instead of NAN.
126345         * modules/truncf-tests (Files): Add tests/nan.h.
126347         * tests/test-ceilf1.c: Include nan.h.
126348         (main): Use NaNf instead of NAN.
126349         * modules/ceilf-tests (Files): Add tests/nan.h.
126351         * tests/test-floorf1.c: Include nan.h.
126352         (main): Use NaNf instead of NAN.
126353         * modules/floorf-tests (Files): Add tests/nan.h.
126355         * tests/test-isnanf.c: Include nan.h instead of <math.h>.
126356         (main): Use NaNf instead of NAN.
126357         * modules/isnanf-nolibm-tests (Files): Add tests/nan.h.
126359         * tests/test-isnand.c: Include nan.h instead of <math.h>.
126360         (main): Use NaNd instead of NAN.
126361         * modules/isnand-nolibm-tests (Files): Add tests/nan.h.
126363         * tests/test-frexp.c: Include nan.h.
126364         (main): Use NaNd instead of NAN.
126365         * modules/frexp-tests (Files): Add tests/nan.h.
126367         * lib/isnan.c: Don't include <math.h>.
126368         (FUNC): Don't use NAN macro.
126369         * modules/isnand-nolibm (Depends-on): Remove math.
126370         * modules/isnanf-nolibm (Depends-on): Remove math.
126371         * modules/isnanl (Depends-on): Remove math.
126372         * modules/isnanl-nolibm (Depends-on): Remove math.
126374         * tests/nan.h: New file.
126376 2008-04-01  Eric Blake  <ebb9@byu.net>
126378         Fix typos.
126379         * tests/test-strtod.c (main): s/FLT_/DBL_/ for minimum and epsilon
126380         values to be the right type.
126382         For now, cater to gnulib strtod inaccuracies.
126383         * tests/test-strtod.c (main): Allow 1-ulp error on expected
126384         fractional results.  While not as nice from a QoI perspective, it
126385         is a quicker patch than correctly implementing decimal to binary
126386         rounding.
126388 2008-03-31  Eric Blake  <ebb9@byu.net>
126390         Guarantee a definition of NAN.
126391         * lib/math.in.h (NAN): Define if missing.
126392         * tests/test-math.c (main): Test it.
126393         * doc/posix-headers/math.texi (math.h): Document this.
126394         * lib/isnan.c (rpl_isnand): Use it.
126395         * tests/test-ceilf1.c (NaN): Delete, and use NAN instead.
126396         * tests/test-floorf1.c (NaN): Likewise.
126397         * tests/test-frexp.c (NaN): Likewise.
126398         * tests/test-isnand.c (NaN): Likewise.
126399         * tests/test-isnanf.c (NaN): Likewise.
126400         * tests/test-round1.c (NaN): Likewise.
126401         * tests/test-roundf1.c (NaN): Likewise.
126402         * tests/test-snprintf-posix.h (NaN): Likewise.
126403         * tests/test-sprintf-posix.h (NaN): Likewise.
126404         * tests/test-trunc1.c (NaN): Likewise.
126405         * tests/test-truncf1.c (NaN): Likewise.
126406         * tests/test-vasnprintf-posix.c (NaN): Likewise.
126407         * tests/test-vasprintf-posix.c (NaN): Likewise.
126408         * modules/isnand-nolibm (Depends-on): Add math.
126409         * modules/isnanf-nolibm (Depends-on): Likewise.
126410         * modules/isnanl (Depends-on): Likewise.
126411         * modules/isnanl-nolibm (Depends-on): Likewise.
126412         * modules/snprintf-posix-tests (Depends-on): Likewise.
126413         * modules/sprintf-posix-tests (Depends-on): Likewise.
126414         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
126415         * modules/vsprintf-posix-tests (Depends-on): Likewise.
126416         * modules/vasnprintf-posix-tests (Depends-on): Likewise.
126417         * modules/vasprintf-posix-tests (Depends-on): Likewise.
126419 2008-03-31  Bruno Haible  <bruno@clisp.org>
126421         * tests/test-strtod.c (main): Update results for OSF/1 platforms.
126422         * doc/posix-functions/strtod.texi: Likewise.
126424 2008-03-31  Bruno Haible  <bruno@clisp.org>
126426         * tests/test-strtod.c (main): Don't use C99 syntax.
126428 2008-03-31  Bruno Haible  <bruno@clisp.org>
126430         * tests/test-strtod.c (main): Don't test NAN macro. Needed for Solaris.
126431         Reported by Eric Blake.
126433 2008-03-31  Jim Meyering  <meyering@redhat.com>
126435         Don't compare actual signbit return values.
126436         * tests/test-strtod.c (main): Rather, compare only their
126437         zero/non-zero nature.
126439 2008-03-31  Eric Blake  <ebb9@byu.net>
126441         More strtod documentation.
126442         * doc/posix-functions/strtod.texi (strtod): Interpret more test
126443         failures as distinct bugs.
126445 2008-03-30  Paul Eggert  <eggert@cs.ucla.edu>
126447         * lib/wchar.in.h [defined __need_mbstate_t]: Just include <wchar.h>.
126448         Problem reported by Erik Benada in
126449         <http://lists.gnu.org/r/bug-gnulib/2008-03/msg00249.html>.
126451 2008-03-30  Bruno Haible  <bruno@clisp.org>
126453         * tests/test-strtod.c: Add comments about which assertion fails on which
126454         platform.
126455         * doc/posix-functions/strtod.texi: Add info about many more platforms.
126457 2008-03-30  Eric Blake  <ebb9@byu.net>
126459         Test signbit behavior on zeros.
126460         * tests/test-signbit.c (test_signbitf): Add tests for zero.
126461         (test_signbitd, test_signbitl): Likewise.
126463         More strtod touchups.
126464         * tests/test-strtod.c (main): Ignore tests for signbit on NaN, and
126465         sign of negative underflow, for now.  Use .5, not .1.
126466         * doc/posix-functions/strtod.texi (strtod): Mention these
126467         limitations.
126468         Reported by Jim Meyering.
126470 2008-03-30  Bruno Haible  <bruno@clisp.org>
126472         * lib/striconveh.h (mem_iconveh, str_iconveh): Optimize the conversion
126473         from UTF-8 to UTF-8//TRANSLIT in the same way as from UTF-8 to UTF-8.
126475 2008-03-30  Bruno Haible  <bruno@clisp.org>
126477         Avoid failure when attempting to return empty iconv results on some
126478         platforms.
126479         * lib/striconveh.c (mem_cd_iconveh_internal): In the final memory
126480         allocation, don't report ENOMEM when the resulting string is empty.
126482 2008-03-30  Bruno Haible  <bruno@clisp.org>
126484         Fix buffer overrun.
126485         * lib/vasnprintf.c (VASNPRINTF): If !USE_SNPRINTF && pad_ourselves:
126486         Don't consider the width for tmp_length. Check count against tmp_length
126487         before doing the padding. Ensure enough allocation during padding.
126489 2008-03-30  Eric Blake  <ebb9@byu.net>
126491         strtod touchups.
126492         * lib/strtod.c (strtod): Avoid compiler warnings.
126493         Reported by Jim Meyering.
126495 2008-03-30  Bruno Haible  <bruno@clisp.org>
126497         * lib/unistdio/u-vsprintf.h (EOVERFLOW): Remove fallback.
126498         * modules/unistdio/ulc-vsprintf (Depends-on): Add EOVERFLOW.
126499         * modules/unistdio/u8-vsprintf (Depends-on): Add EOVERFLOW.
126500         * modules/unistdio/u8-u8-vsprintf (Depends-on): Add EOVERFLOW.
126501         * modules/unistdio/u16-vsprintf (Depends-on): Add EOVERFLOW.
126502         * modules/unistdio/u16-u16-vsprintf (Depends-on): Add EOVERFLOW.
126503         * modules/unistdio/u32-vsprintf (Depends-on): Add EOVERFLOW.
126504         * modules/unistdio/u32-u32-vsprintf (Depends-on): Add EOVERFLOW.
126506         * lib/unistdio/u-vsnprintf.h (EOVERFLOW): Remove fallback.
126507         * modules/unistdio/ulc-vsnprintf (Depends-on): Add EOVERFLOW.
126508         * modules/unistdio/u8-vsnprintf (Depends-on): Add EOVERFLOW.
126509         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Add EOVERFLOW.
126510         * modules/unistdio/u16-vsnprintf (Depends-on): Add EOVERFLOW.
126511         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Add EOVERFLOW.
126512         * modules/unistdio/u32-vsnprintf (Depends-on): Add EOVERFLOW.
126513         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Add EOVERFLOW.
126515         * lib/unistdio/u-vasprintf.h (EOVERFLOW): Remove fallback.
126516         * modules/unistdio/ulc-vasprintf (Depends-on): Add EOVERFLOW.
126517         * modules/unistdio/u8-vasprintf (Depends-on): Add EOVERFLOW.
126518         * modules/unistdio/u8-u8-vasprintf (Depends-on): Add EOVERFLOW.
126519         * modules/unistdio/u16-vasprintf (Depends-on): Add EOVERFLOW.
126520         * modules/unistdio/u16-u16-vasprintf (Depends-on): Add EOVERFLOW.
126521         * modules/unistdio/u32-vasprintf (Depends-on): Add EOVERFLOW.
126522         * modules/unistdio/u32-u32-vasprintf (Depends-on): Add EOVERFLOW.
126524         * lib/unistdio/ulc-vfprintf.c (EOVERFLOW): Remove fallback.
126525         * modules/unistdio/ulc-vfprintf (Depends-on): Add EOVERFLOW.
126527         * lib/unistdio/ulc-fprintf.c (EOVERFLOW): Remove fallback.
126528         * modules/unistdio/ulc-fprintf (Depends-on): Add EOVERFLOW.
126530         * lib/xvasprintf.c (EOVERFLOW): Remove fallback.
126531         * modules/xvasprintf (Depends-on): Add EOVERFLOW.
126533         * lib/vsprintf.c (EOVERFLOW): Remove fallback.
126534         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Drop gl_EOVERFLOW.
126535         * modules/vsprintf-posix (Depends-on): Add EOVERFLOW.
126537         * lib/vsnprintf.c (EOVERFLOW): Remove fallback.
126538         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Drop gl_EOVERFLOW.
126539         * modules/vsnprintf (Depends-on): Add EOVERFLOW.
126541         * lib/vfprintf.c (EOVERFLOW): Remove fallback.
126542         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Drop gl_EOVERFLOW.
126543         * modules/vfprintf-posix (Depends-on): Add EOVERFLOW.
126545         * lib/vasprintf.c (EOVERFLOW): Remove fallback.
126546         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Drop gl_EOVERFLOW.
126547         * modules/vasprintf (Depends-on): Add EOVERFLOW.
126549         * lib/vasnprintf.c (EOVERFLOW): Remove fallback.
126550         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Drop gl_EOVERFLOW.
126551         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Drop gl_EOVERFLOW.
126552         * modules/vasnprintf (Files): Remove m4/eoverflow.m4.
126553         (Depends-on): Add EOVERFLOW.
126554         * modules/unistdio/ulc-vasnprintf (Files): Remove m4/eoverflow.m4.
126555         (Depends-on): Add EOVERFLOW.
126556         * modules/unistdio/u8-vasnprintf (Files): Remove m4/eoverflow.m4.
126557         (Depends-on): Add EOVERFLOW.
126558         * modules/unistdio/u8-u8-vasnprintf (Files): Remove m4/eoverflow.m4.
126559         (Depends-on): Add EOVERFLOW.
126560         * modules/unistdio/u16-vasnprintf (Files): Remove m4/eoverflow.m4.
126561         (Depends-on): Add EOVERFLOW.
126562         * modules/unistdio/u16-u16-vasnprintf (Files): Remove m4/eoverflow.m4.
126563         (Depends-on): Add EOVERFLOW.
126564         * modules/unistdio/u32-vasnprintf (Files): Remove m4/eoverflow.m4.
126565         (Depends-on): Add EOVERFLOW.
126566         * modules/unistdio/u32-u32-vasnprintf (Files): Remove m4/eoverflow.m4.
126567         (Depends-on): Add EOVERFLOW.
126569         * lib/sprintf.c (EOVERFLOW): Remove fallback.
126570         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Drop gl_EOVERFLOW.
126571         * modules/sprintf-posix (Depends-on): Add EOVERFLOW.
126573         * lib/snprintf.c (EOVERFLOW): Remove fallback.
126574         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Drop gl_EOVERFLOW.
126575         * modules/snprintf (Depends-on): Add EOVERFLOW.
126577         * lib/poll.c (EOVERFLOW): Remove fallback.
126578         * modules/poll (Depends-on): Add EOVERFLOW.
126580         * lib/getugroups.c (EOVERFLOW): Remove fallback.
126581         * modules/getugroups (Depends-on): Add EOVERFLOW.
126583         * lib/getdelim.c (EOVERFLOW): Remove fallback.
126584         * modules/getdelim (Depends-on): Add EOVERFLOW.
126586         * lib/ftell.c (EOVERFLOW): Remove fallback.
126587         * modules/ftell (Depends-on): Add EOVERFLOW.
126589         * lib/fprintf.c (EOVERFLOW): Remove fallback.
126590         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Drop gl_EOVERFLOW.
126591         * modules/fprintf-posix (Depends-on): Add EOVERFLOW.
126593         * lib/c-stack.c (EOVERFLOW): Remove unused fallback.
126595         * modules/EOVERFLOW-tests: New file.
126596         * tests/test-EOVERFLOW.c: New file.
126598         * modules/EOVERFLOW: New file.
126599         * doc/posix-headers/errno.texi: Mention EOVERFLOW portability problem.
126601 2008-03-30  Bruno Haible  <bruno@clisp.org>
126603         Fix bug introduced on 2007-06-10.
126604         * lib/vasnprintf.c (VASNPRINTF): When performing zero-padding, use
126605         spaces instead of 0 digits for 's' also when ENABLE_UNISTDIO.
126607 2008-03-30  Bruno Haible  <bruno@clisp.org>
126609         Improve freadseek's efficiency after ungetc.
126610         * lib/freadseek.c: Include freadahead.h.
126611         (freadptrinc): New function, extracted from freadseek.
126612         (freadseek): Use it in a loop. Use freadahead to determine the number
126613         of loop iterations.
126614         * modules/freadseek (Depends-on): Add freadahead.
126615         (configure.ac): Require AC_C_INLINE.
126617 2008-03-30  Bruno Haible  <bruno@clisp.org>
126619         * lib/freadseek.c (freadseek): Don't ignore the return value of
126620         freadptr.
126622 2008-03-29  Eric Blake  <ebb9@byu.net>
126624         Add hex float support.
126625         * modules/strtod (Depends-on): Add c-ctype.
126626         (Link): Mention POW_LIB.
126627         * lib/strtod.c (strtod): Recognize hex floats.  Don't allow
126628         whitespace between 'e' and exponent.
126629         * tests/test-strtod.c (main): Enable hex float tests.
126630         * doc/posix-functions/strtod.texi (strtod): Document what gnulib
126631         now provides.
126633         Document various strtod bugs, with some fixes.
126634         * doc/posix-functions/strtod.texi (strtod): Document bugs with
126635         "-0x", "inf", "nan", and hex constants.
126636         * doc/posix-functions/atof.texi (atof): Likewise.
126637         * modules/stdlib (Makefile.am): Support strtod.
126638         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
126639         * m4/strtod.m4 (gl_FUNC_STRTOD): Fit in stdlib framework, and
126640         detect additional strtod bugs.
126641         * lib/stdlib.in.h (rpl_strtod): Add declarations.
126642         * lib/strtod.c (strtod): Return -0.0 on negative underflow.  Use
126643         bool where appropriate.  Parse 'inf' and 'nan'.
126644         * tests/test-strtod.c: New file.
126645         * modules/strtod (Depends-on): Add stdbool, stdlib.
126646         (configure.ac): Turn on module indicator.
126647         * modules/strtod-tests: New module.
126649 2008-03-29  Eric Blake  <ebb9@byu.net>
126651         Fix ftell on mingw.
126652         * lib/ftell.c (EOVERFLOW): Define if the system lacks it.
126653         * modules/ftell-tests (Depends-on): Add binary-io.
126654         * modules/ftello-tests (Depends-on): Likewise.
126655         * tests/test-ftell.c (main): Enhance test to cover behavior after
126656         ungetc.  Enforce binary mode.
126657         * tests/test-ftello.c (main): Likewise.
126659         Pass test-freadseek on cygwin.
126660         * modules/freadseek (Depends-on): Use freadptr, not freadahead.
126661         * lib/freadseek.c (freadseek): Don't increment beyond bounds of
126662         ungetc buffer.
126664         * tests/test-fflush2.c (main): Fix typo.
126666 2008-03-29  Bruno Haible  <bruno@clisp.org>
126668         * tests/test-fflush2.c (main): Temporarily disable the contents of
126669         this test.
126670         * m4/fflush.m4 (gl_FUNC_FFLUSH): Add a TODO.
126671         Reported by Eric Blake.
126673 2008-03-28  Simon Josefsson  <simon@josefsson.org>
126675         * lib/gc.h (enum Gc_hash): Add GC_SHA224.
126676         (GC_SHA224_DIGEST_SIZE): Add.
126678         * lib/gc-libgcrypt.c (gc_hash_open): Handle SHA-224.
126679         (gc_hash_digest_length): Likewise.
126680         (gc_hash_buffer): Likewise.
126682 2008-03-25  Bruno Haible  <bruno@clisp.org>
126684         * doc/gnulib-tool.texi (gettextize and autopoint): Explain in more
126685         detail which gettext release to use.
126686         Reported by Simon Josefsson.
126688 2008-03-26  Jim Meyering  <meyering@redhat.com>
126690         gnumakefile: remove file from $(top_builddir), not from $(top_srcdir)
126691         * modules/gnumakefile (clean-GNUmakefile): Also, use
126692         test ... && ... || : syntax rather than if-then ... fi.
126694         gnumakefile: Don't double-quote-expand $(VPATH) value.
126695         * modules/gnumakefile (clean-GNUmakefile): Use single quotes.
126697 2008-03-24  Eric Blake  <ebb9@byu.net>
126699         Alter GNUmakefile to install into top directory.
126700         * modules/maintainer-makefile: Split, and add dependency...
126701         * modules/gnumakefile: to this new module.
126702         * build-aux/GNUmakefile: Move...
126703         * top/GNUmakefile: ...here.
126704         * build-aux/maint.mk: Move...
126705         * top/maint.mk: ...here.
126706         * MODULES.html.sh (Support for maintaining...): Document new
126707         module.
126709 2008-03-23  Bruno Haible  <bruno@clisp.org>
126711         * gnulib-tool: New options --vc-files, --no-vc-files.
126712         (func_usage): Document them.
126713         (vc_files): New variable.
126714         (func_import): Consider vc_files.
126715         (func_create_testdir): Set vc_files to empty.
126716         Suggested by Jim Meyering and Karl Berry.
126718 2008-03-23  Bruno Haible  <bruno@clisp.org>
126720         Fix regex compilation error on HP-UX 11.
126721         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_TYPE_MBSTATE_T.
126722         * modules/regex (Files): Add m4/mbstate_t.m4.
126723         Reported by Ton Voon <ton.voon@altinity.com>.
126725 2008-03-23  Bruno Haible  <bruno@clisp.org>
126727         * doc/gnulib-tool.texi (gettextize and autopoint): New section.
126729 2008-03-23  Eric Blake  <ebb9@byu.net>
126730             Bruno Haible  <bruno@clisp.org>
126732         Install files from top/ in the destination directory.
126733         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
126734         augmentation also for the files from top/.
126735         (func_import, func_create_testdir): Rewrite file names:
126736         top/filename -> filename.
126738 2008-03-23  Bruno Haible  <bruno@clisp.org>
126740         Tweak "gnulib --version" output.
126741         * gnulib-tool (func_version): Replace "-dirty" suffix with "-modified".
126743 2008-03-23  Bruno Haible  <bruno@clisp.org>
126745         Tweak "gnulib --version" output.
126746         * gnulib-tool (func_version): Use date of last commit to ChangeLog,
126747         rather than contents of ChangeLog, when possible.
126749 2008-03-21  Eric Blake  <ebb9@byu.net>
126751         More --version tweaks.
126752         * gnulib-tool (func_version): Obey GNU Coding Standards.  Output
126753         date of last ChangeLog entry.
126755 2008-03-21  Jim Meyering  <meyering@redhat.com>
126757         * build-aux/GNUmakefile (_have-git-version-gen): Split long line.
126759 2008-03-20  Eric Blake  <ebb9@byu.net>
126761         VPATH fix.
126762         * build-aux/GNUmakefile (_have_git-version-gen): Look in correct dir.
126764 2008-03-20  Simon Josefsson  <simon@josefsson.org>
126766         * build-aux/GNUmakefile: Make git-version-gen optional.  Add
126767         _build-aux variable.  Suggested by Eric Blake <ebb9@byu.net>.
126769 2008-03-20  Eric Blake  <ebb9@byu.net>
126771         Sync GNUmakefile with coreutils.
126772         * build-aux/GNUmakefile (have-Makefile): Rename...
126773         (_have-Makefile): ...to this, for namespace consideration.
126774         (GNUmakefile.cfg): Include, if present.
126775         (_autoreconf): Define a default.
126776         (_is-dist-target): New rule for rebuilds to pick up intra-release
126777         version.
126778         (maint-cfg.mk): Rename...
126779         (cfg.mk): ...to this.
126781 2008-03-18  Jim Meyering  <meyering@redhat.com>
126783         New script and module: mktempd
126784         * MODULES.html.sh (maint+release support): Add mktempd.
126785         * build-aux/mktempd: New file.
126786         * modules/mktempd: New file.
126788 2008-03-15  Jim Meyering  <meyering@redhat.com>
126790         Undo last change.
126791         * lib/sha1.c, lib/md5.c: 63 != ~63.
126792         Reported by Andreas Schwab.
126794         sha1.c, md5.c: Hoist a redundant expression.
126795         * lib/sha1.c (sha1_process_bytes): AND-off the low bits in
126796         "ctx->buflen" only once, before calling *_process_block.
126797         * lib/md5.c (md5_process_bytes): Likewise.
126799 2008-03-14  Eric Blake  <ebb9@byu.net>
126801         Bump copyright year in files generated by gnulib-tool.
126802         * gnulib-tool (func_emit_copyright_notice): Extract copyright from
126803         gnulib-tool, rather than hard-coding it.
126805         Fix 'gnulib-tool --version' output to work with git.
126806         * gnulib-tool (func_gnulib_dir): New function, extracted from...
126807         (startup): ...here.
126808         (func_version): Use it to invoke git-version-gen, rather than
126809         relying on CVS keyword expansion.  Modernize wording.
126810         (cvsdatestamp, last_checkin_date, version): Kill unused
126811         variables.
126813 2008-03-12  Jim Meyering  <meyering@redhat.com>
126815         Recognize optional cast of the argument to free.
126816         * build-aux/useless-if-before-free: Update regexps.
126818         * build-aux/bootstrap (gnulib_tool): Remove trailing blanks.
126820 2008-03-11  Bruno Haible  <bruno@clisp.org>
126822         Extend AC_LIB_LINKFLAGS to the situation of several libraries provided
126823         by a single package.
126824         * m4/lib-link.m4 (AC_LIB_FROMPACKAGE): New macro.
126825         (AC_LIB_LINKFLAGS_BODY): Use the information stored by
126826         AC_LIB_FROMPACKAGE. Use AC_ARG_WITH instead of AC_LIB_ARG_WITH.
126827         Reported by Sam Steingold <sds@gnu.org>.
126829 2008-03-12  Sergey Poznyakoff  <gray@gnu.org.ua>
126831         * build-aux/bootstrap (version_controlled_file): Adapt for SVN
126832         repositories.
126834 2008-03-11  Bruno Haible  <bruno@clisp.org>
126836         Avoid conflicts between local macro definitions.
126837         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
126838         AC_LIB_LINKFLAGS_BODY): Use pushdef/popdef instead of define/undefine.
126840 2008-03-10  Peter O'Gorman  <bug-gnulib@mlists.thewrittenword.com>
126841             Bruno Haible  <bruno@clisp.org>
126843         Make va_copy work with some version of xlc on AIX 5.1.
126844         * lib/stdarg.in.h: New file.
126845         * m4/stdarg.m4 (gl_STDARG_H): Initialize STDARG_H and NEXT_STDARG_H.
126846         On AIX, use a <stdarg.h> file substitute.
126847         * modules/stdarg (Files): Add lib/stdarg.in.h.
126848         (Depends-on): Add include_next.
126849         (Makefile.am): Build a stdarg.h substitute if requested.
126850         * doc/posix-functions/va_copy.texi: Document the platforms lacking it.
126852 2008-03-10  Bruno Haible  <bruno@clisp.org>
126854         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Document a restriction.
126855         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
126856         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
126858 2008-03-10  Bruno Haible  <bruno@clisp.org>
126860         * modules/stdlib (Depends-on): Add include_next, remove
126861         absolute-header.
126863 2008-03-09  Bruno Haible  <bruno@clisp.org>
126865         * lib/freadahead.h (freadahead): Document more precisely.
126866         * lib/freadahead.c (freadahead): When an ungetc is in effect, return
126867         the sum of both buffer sizes.
126868         * tests/test-freadahead.c (main): Also test behaviour after ungetc.
126869         * NEWS: Document the change.
126871 2008-03-09  Bruno Haible  <bruno@clisp.org>
126873         Extend freadptr to return also the buffer size.
126874         * lib/freadptr.h (freadptr): Add sizep argument.
126875         * lib/freadptr.c: Include freadptr.h, not freadahead.h.
126876         (freadptr): Add sizep argument. Determine buffer size like freadahead
126877         does.
126878         * tests/test-freadptr.c: Don't include freadahead.h.
126879         (main): Adapt for new calling convention of freadptr.
126880         * tests/test-freadptr2.c: New file, based on tests/test-freadahead.c.
126881         * tests/test-freadptr2.sh: New file, based on tests/test-freadahead.sh.
126882         * modules/freadptr-tests (Files): Add tests/test-freadptr2.c,
126883         tests/test-freadptr2.sh.
126884         (Depends): Remove freadahead.
126885         (TESTS): Add test-freadptr2.sh.
126886         (check_PROGRAMS): Add test-freadptr2.
126888 2008-03-09  Bruno Haible  <bruno@clisp.org>
126890         * doc/Makefile (%.pdf): Explain how to remedy the save_size error.
126891         Report and solution by Simon Josefsson.
126893 2008-03-06  Bruno Haible  <bruno@clisp.org>
126895         Make fflush after ungetc work on BSD platforms.
126896         * lib/fflush.c (rpl_fflush): Discard ungetc buffer if possible.
126897         * tests/test-fflush2.c: New file.
126898         * tests/test-fflush2.sh: New file.
126899         * modules/fflush-tests (Files): Add tests/test-fflush2.sh,
126900         tests/test-fflush2.c.
126901         (Makefile.am): Build test-fflush2 and run test-fflush2.sh.
126902         * doc/posix-functions/fflush.texi: Document fflush after ungetc bug.
126904 2008-03-06  Eric Blake  <ebb9@byu.net>
126906         Likewise for ftello.
126907         * modules/ftello (Dependencies): Add extensions.
126908         * m4/ftello.m4 (gl_FUNC_FTELLO): Require AC_USE_SYSTEM_EXTENSIONS.
126910 2008-03-06  Bruno Haible  <bruno@clisp.org>
126912         * modules/fseeko (Dependencies): Add extensions.
126913         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Require AC_USE_SYSTEM_EXTENSIONS.
126914         Needed on glibc systems.
126916 2008-03-06  Bruno Haible  <bruno@clisp.org>
126918         * doc/gnulib-tool.texi (@nosuchmodulenote): Avoid line break inside
126919         email address.
126920         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
126922 2008-03-06  Bruno Haible  <bruno@clisp.org>
126924         * users.txt: Add libgnupdf.
126926 2008-03-06  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
126928         * doc/gnulib-tool.texi (@nosuchmodulenote): New macro.
126929         (Header File Substitutes, Function Substitutes,
126930         Glibc Header File Substitutes, Glibc Function Substitutes): Use it.
126931         (Build robot for gnulib): Fix typo.
126933 2008-03-06  Bruno Haible  <bruno@clisp.org>
126935         * doc/gnulib-tool.texi (VCS Issues): Small updates.
126936         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
126938 2008-03-06  Bruno Haible  <bruno@clisp.org>
126940         * doc/func.texi: New file, extracted from doc/gnulib.texi.
126941         * doc/gnulib.texi: Include it.
126943 2008-03-06  Simon Josefsson  <simon@josefsson.org>
126945         * modules/func (License): Change license to unlimited; there was
126946         no LGPL parts in the module anyway.
126948 2008-03-06  Simon Josefsson  <simon@josefsson.org>
126950         * modules/__func__: Renamed to modules/func.
126951         * modules/__func__-tests: Renamed to modules/func-tests.
126952         * tests/test-__func__.c: Renamed to tests/test-func.c.
126953         * m4/__func__.m4: Renamed to m4/func.m4.
126954         * doc/gnulib.texi (__func__): Section renamed to func.
126955         Suggested by Eric Blake <ebb9@byu.net>.
126957 2008-03-06  Simon Josefsson  <simon@josefsson.org>
126959         * doc/gnulib.texi (__func__): Use C99 terminology when talking
126960         about __func__.  Make example self-contained.  Suggested by Eric
126961         Blake <ebb9@byu.net>.
126963         * tests/test-__func__.c (main): Avoid extraneous () around __func.
126964         Suggested by Eric Blake <ebb9@byu.net>.
126966 2008-03-06  Simon Josefsson  <simon@josefsson.org>
126968         * modules/__func__: New file.
126969         * modules/__func__-tests: New file.
126970         * tests/test-__func__.c: New file.
126971         * m4/__func__.m4: New file.
126972         * doc/gnulib.texi (__func__): Document __func__ module.
126974 2008-03-05  Simon Josefsson  <simon@josefsson.org>
126976         * modules/byteswap (License): Re-license as LGPLv2+.
126978 2008-03-05  Simon Josefsson  <simon@josefsson.org>
126980         * doc/Makefile: Add pdf target.
126982 2008-03-05  Simon Josefsson  <simon@josefsson.org>
126984         * modules/inline (License): Use 'unlimited', since there are only
126985         *.m4 files in this module.
126987 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
126988             Bruno Haible  <bruno@clisp.org>
126990         Add support for HP C 7.1 on OpenVMS 8.3.
126991         * lib/alloca.in.h (alloca): Define as alias for DEC C on VMS.
126993 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
126995         Update VMS specifics.
126996         * lib/getopt.c [VMS]: Remove include of unixlib.h.
126998 2008-03-02  Jim Meyering  <meyering@redhat.com>
127000         Remove the last dependency on the "free" module.
127001         * m4/readutmp.m4 (gl_READUTMP): Don't require gl_FUNC_FREE.
127002         Reported by Bob Proulx.
127004         * lib/getdelim.c (getdelim): Don't leak memory upon failed realloc.
127006         Remove useless "if" tests before free.  Deprecate "free" module.
127007         * doc/posix-functions/free.texi: Mention that this
127008         module is no longer useful.
127009         * modules/free (Notice): Say this module is obsolete.
127010         * modules/readutmp (Depends-on): Remove free.
127011         * lib/save-cwd.c (free_cwd): Remove useless "if" before free.
127012         * lib/putenv.c (putenv): Likewise.
127013         * lib/gc-gnulib.c (gc_cipher_close): Likewise.
127014         * lib/getaddrinfo.c (freeaddrinfo): Likewise.
127015         * tests/test-c-strcasestr.c (main): Likewise.
127016         * tests/test-c-strstr.c (main): Likewise.
127017         * tests/test-mbscasestr1.c (main): Likewise.
127018         * tests/test-mbscasestr2.c (main): Likewise.
127019         * tests/test-mbsstr1.c (main): Likewise.
127020         * tests/test-mbsstr2.c (main): Likewise.
127021         * tests/test-memmem.c (main): Likewise.
127022         * tests/test-strcasestr.c (main): Likewise.
127023         * tests/test-striconv.c (main): Likewise.
127024         * tests/test-striconveh.c (main): Likewise.
127025         * tests/test-striconveha.c (main): Likewise.
127026         * tests/test-strstr.c (main): Likewise.
127028         * build-aux/git-version-gen: Adjust a comment and the Usage string.
127030         bootstrap: sync from coreutils again
127031         * build-aux/bootstrap: Remove dangling m4/*.m4 symlinks.
127033 2008-03-01  Jim Meyering  <meyering@redhat.com>
127035         bootstrap: sync from coreutils
127036         * build-aux/bootstrap (update_po_files): Copy a .po file into place
127037         also when the target doesn't exist.
127039 2008-03-01  Eric Blake  <ebb9@byu.net>
127041         Fix bugs in last patch.
127042         * lib/memchr2.c (memchr2): Fix typo.
127043         * tests/test-memchr2.c: Test previous bug, and don't use GNU
127044         extension.
127045         Reported by Bruce Korb.
127047         New module 'memchr2'.
127048         * modules/memchr2: New file.
127049         * modules/memchr2-tests: Likewise.
127050         * lib/memchr2.h: Likewise.
127051         * lib/memchr2.c: Likewise, based on memchr.c.
127052         * tests/test-memchr2.c: New test.
127053         * MODULES.html.sh (String handling): Add memchr2.
127055 2008-02-29  Bruno Haible  <bruno@clisp.org>
127057         * modules/freadseek-tests: New file.
127058         * tests/test-freadseek.sh: New file.
127059         * tests/test-freadseek.c: New file.
127061         New module 'freadseek'.
127062         * modules/freadseek: New file.
127063         * lib/freadseek.h: New file.
127064         * lib/freadseek.c: New file.
127065         * MODULES.html.sh (File stream based Input/Output): Add freadseek.
127067 2008-02-29  Sergey Poznyakoff  <gray@gnu.org.ua>
127069         * users.txt: Add anubis, cpio, mailfromd, mailutils, radius,
127070         wydawca.
127072         * m4/argp.m4 (gl_ARGP): Use AC_TRY_LINK to test if
127073         program_invocation_name and program_invocation_short_name are
127074         present.
127076 2008-02-28  Bruno Haible  <bruno@clisp.org>
127078         * tests/test-freadptr.c: Add a test for behaviour after ungetc.
127079         * tests/test-freadptr.sh: Also test non-seekable stdin.
127081 2008-02-28  Sergey Poznyakoff  <gray@gnu.org.ua>
127083         * build-aux/bootstrap (source_base, m4_base)
127084         (doc_base, tests_base): New variables.
127085         (gnulib_tool_options): Do not hardcode base directories, use
127086         the above variables instead.
127088 2008-02-28  Atsushi SAKAI  <sakaia@jp.fujitsu.com>
127090         * lib/xsize.h: Fix typo in comment: s/tupe/type/.
127092 2008-02-28  Bruno Haible  <bruno@clisp.org>
127094         * modules/freadptr-tests: New file.
127095         * tests/test-freadptr.sh: New file.
127096         * tests/test-freadptr.c: New file.
127098         New module 'freadptr'.
127099         * modules/freadptr: New file.
127100         * lib/freadptr.h: New file.
127101         * lib/freadptr.c: New file.
127102         * MODULES.html.sh (File stream based Input/Output): Add freadptr.
127104 2008-02-26  Karl Berry  <karl@freefriends.org>
127106         Sync from Libtool:
127107         * libltdl/argz.c (argz_add, argz_count): New functions.
127108         * libltdl/argz.in.h: Declare them.
127109         Report by Juan Manuel Guerrero <juan.guerrero@gmx.de>.
127111 2008-02-22  Bruno Haible  <bruno@clisp.org>
127113         * m4/time_r.m4 (gl_TIME_R): Also check that localtime_r's return type
127114         is a pointer type.  Needed for HP-UX 10.
127115         * doc/posix-functions/localtime_r.texi: Mention HP-UX 10.
127116         * doc/posix-functions/gmtime_r.texi: Likewise.
127117         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
127119 2008-02-24  Bruno Haible  <bruno@clisp.org>
127121         * modules/environ-tests: New file.
127122         * tests/test-environ.c: New file.
127124         New module 'environ'.
127125         * modules/environ: New file.
127126         * lib/unistd.in.h (environ): New declaration.
127127         * m4/environ.m4: New file.
127128         (gt_CHECK_VAR_DECL): Moved here from m4/setenv.m4. Undefine gt_cv_var
127129         after use.
127130         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ENVIRON and
127131         HAVE_DECL_ENVIRON.
127132         * modules/unistd (Makefile.am): Substitute also GNULIB_ENVIRON and
127133         HAVE_DECL_ENVIRON.
127134         * doc/posix-functions/environ.texi: Mention module 'environ'. Remove
127135         wrong claim that 'environ' is missing on some systems.
127136         * modules/execute (Depends-on): Add environ.
127137         * lib/execute.c (environ): Remove fallback declaration.
127138         * modules/pipe (Depends-on): Add environ.
127139         * lib/pipe.c (environ): Remove fallback declaration.
127140         * modules/setenv (Depends-on): Add environ.
127141         * lib/setenv.c (environ): Remove fallback declaration.
127142         * modules/unsetenv (Depends-on): Add environ.
127143         * lib/unsetenv.c (environ): Remove fallback declaration.
127144         * m4/setenv.m4 (gt_CHECK_VAR_DECL): Remove macro. Moved to
127145         m4/environ.m4.
127146         (gl_PREREQ_SETENV): Require gl_ENVIRON instead of testing for environ.
127147         (gl_PREREQ_UNSETENV): Likewise.
127149 2008-02-24  Bruno Haible  <bruno@clisp.org>
127151         * doc/posix-functions/environ.texi: Document the MacOS X problem.
127153 2008-02-20  Bob Proulx  <bob@proulx.com>
127155         Enable use of older two part flavor 'git describe'.
127156         * build-aux/git-version-gen: If using the older two part flavor of
127157         git version then recreate the third part now present in the
127158         newer three part flavor of git describe.
127160 2008-02-20  Martin Buchholz  <martin@xemacs.org>  (tiny change)
127162         * lib/fts.c (fts_build): Typo correction to comment.
127164 2008-02-17  Bruno Haible  <bruno@clisp.org>
127166         * lib/git-merge-changelog.c (main) [split_merged_entry]: Avoid
127167         generating no-op conflicts.
127169 2008-02-17  Bruno Haible  <bruno@clisp.org>
127171         Speed up by 10%.
127172         * lib/git-merge-changelog.c (main): Use the iterator to iterate through
127173         result_entries, rather than an index-based loop.
127175 2008-02-17  Bruno Haible  <bruno@clisp.org>
127177         Speed up by 25%.
127178         * lib/git-merge-changelog.c (struct entry): New fields 'hashcode',
127179         'hashcode_cached'.
127180         (entry_create): New function.
127181         (entry_hashcode): Use the cached hashcode if possible.
127182         (read_changelog_file, try_split_merged_entry): Use entry_create.
127184 2008-02-17  Bruno Haible  <bruno@clisp.org>
127186         Speed up from O(n^2) to O(n) for long ChangeLog files.
127187         * lib/git-merge-changelog.c: Include gl_rbtreehash_list.h.
127188         (read_changelog_file): Change implementation of entries_reversed list
127189         to rbtreehash.
127190         * modules/git-merge-changelog (Depends-on): Add rbtreehash-list.
127192 2008-02-17  Bruno Haible  <bruno@clisp.org>
127194         New option --split-merged-entry.
127195         * lib/git-merge-changelog.c (FSTRCMP_STRICTER_THRESHOLD): New macro.
127196         (find_paragraph_end, try_split_merged_entry): New functions.
127197         (long_options): Add option --split-merged-entry.
127198         (usage): Document option --split-merged-entry.
127199         (main): Implement option --split-merged-entry.
127200         Reported by Eric Blake.
127202 2008-02-17  Bruno Haible  <bruno@clisp.org>
127204         * lib/git-merge-changelog.c: Include c-strstr.h.
127205         (main): Support the "git pull --rebase" situation.
127206         * modules/git-merge-changelog (Depends-on): Add c-strstr.
127207         Reported by Eric Blake.
127209 2008-02-16  Eric Blake  <ebb9@byu.net>
127211         Avoid doubling \ in common case of "c-maybe" quoting style.
127212         * lib/quotearg.c (quotearg_buffer_restyled): Don't escape \ when
127213         eliding outer quotes.
127214         * lib/quotearg.h: Document this.
127215         * tests/test-quotearg.c (result_strings, inputs, results_g)
127216         (flag_results, locale_results): Test it by adding a new string to
127217         each test group.
127218         (compare_strings): Test new string.
127220 2008-02-13  Eric Blake  <ebb9@byu.net>
127222         Avoid trigraph quoting in default output.
127223         * lib/quotearg.h (enum quoting_flags): Add QA_SPLIT_TRIGRAPHS.
127224         * lib/quotearg.c (quotearg_buffer_restyled): Don't quote trigraphs
127225         unless explicitly requested.
127226         * tests/test-quotearg.c (flag_results, main): Add additional tests.
127228 2008-02-13  Lasse Collin  <lasse.collin@tukaani.org>
127230         Don't rely on signed integer overflowing to negative value.
127231         * lib/getugroups.c (getugroups): Include <limits.h>.
127232         Instead, compare against INT_MAX, and increment only if the test passes.
127234 2008-02-13  Jim Meyering  <meyering@redhat.com>
127235         and Eric Blake  <ebb9@byu.net>
127237         Avoid shadowing warning and compile errors on Linux.
127238         * tests/test-quotearg.c [ENABLE_NLS]: Disable <libintl.h>
127239         forwarding macros on Linux.
127240         (dcgettext): Define a stub, for Linux.
127241         (results_g, main): Avoid warnings.
127243 2008-02-12  Eric Blake  <ebb9@byu.net>
127245         Silence warning in last patch.
127246         * lib/quotearg.c (quotearg_buffer_restyled): Add missing const.
127248         Quotearg part 4: add tests, fix c-maybe colon quoting.
127249         * lib/quotearg.h: Improve documentation.
127250         * lib/quotearg.c (quotearg_buffer_restyled): Don't add extra
127251         escapes when adding outer quotes.  When quoting trigraphs, use
127252         valid C notation.  When quoting NUL, omit extra characters if next
127253         character is not digit.  Alter prototype.
127254         (quotearg_buffer, quotearg_alloc_mem, quotearg_n_options): Adjust
127255         callers.
127256         * modules/quotearg-tests: New module.
127257         * tests/test-quotearg.c: New test.
127259 2008-02-07  Eric Blake  <ebb9@byu.net>
127261         Quotearg part 3: add flag to control outer quote elision.
127262         * lib/quotearg.h (c_maybe_quoting_style): New style.
127263         (enum quoting_flags): Better documentation of flags.
127264         * lib/quotearg.c (quoting_style_args, quoting_style_vals): Add
127265         c-maybe style.
127266         (quotearg_buffer_restyled): Handle new flag to elide outer
127267         quotes.
127269         Quotearg part 2: add flag that can control NUL elision.
127270         * lib/quotearg.h (set_quoting_flags): New prototype.
127271         * lib/quotearg.c (struct quoting_options): Add flag field.
127272         (set_quoting_flags): New function.
127273         (quotearg_buffer_restyled): Add flags parameter.
127274         (quotearg_alloc_mem): Set the flag if length cannot be returned.
127275         (quotearg_n_options): Set the flag, since length cannot be
127276         returned.
127277         (quoting_options_from_style): Default flags correctly.
127279         Quotearg part 1: more wrappers, restore quotearg_char state.
127280         * lib/quotearg.h (quotearg_alloc_mem, quotearg_n_mem)
127281         (quotearg_mem, quotearg_style_mem, quotearg_char_mem)
127282         (quotearg_colon_mem): New wrappers.
127283         * lib/quotearg.c (quotearg_alloc, quotearg_char): Rewrite...
127284         (quotearg_alloc_mem, quotearg_char_mem): ...in terms of these new
127285         functions.
127286         (quotearg_n_mem, quotearg_mem, quotearg_style_mem)
127287         (quotearg_colon_mem): New functions.
127289 2008-02-11  Bruno Haible  <bruno@clisp.org>
127291         * modules/git-merge-changelog (Makefile.am): Don't use -L and -l for a
127292         library in the current directory: it does not work with parallel make.
127293         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
127295 2008-02-11  Bruno Haible  <bruno@clisp.org>
127297         * .gitattributes: New file.
127299 2008-02-11  Jim Meyering  <meyering@redhat.com>
127301         useless-if-before-free: Fix reversed exit values.
127302         * build-aux/useless-if-before-free: Use correct values
127303         for EXIT_MATCH and EXIT_NO_MATCH.
127305         * build-aux/useless-if-before-free: Close stdout carefully.
127307 2008-02-10  Bruno Haible  <bruno@clisp.org>
127309         New module 'git-merge-changelog'.
127310         * modules/git-merge-changelog: New file.
127311         * lib/git-merge-changelog.c: New file.
127313 2008-02-10  Jim Meyering  <meyering@redhat.com>
127315         useless-if-before-free: New option: --list (-l).
127317         useless-if-before-free: Don't exit immediately upon open failure.
127318         * build-aux/useless-if-before-free: Exit 2 for errors.
127319         Upon failure to open a file, don't exit immediately.
127320         Rather, just warn and continue with any remaining files.
127322 2008-02-10  Bruno Haible  <bruno@clisp.org>
127324         New abstract list operation 'node_set_value'.
127325         * lib/gl_list.h (gl_list_node_set_value): New function.
127326         (struct gl_list_implementation): New field node_set_value.
127327         * lib/gl_list.c (gl_list_node_set_value): New function.
127328         * lib/gl_array_list.c (gl_array_node_set_value): New function.
127329         (gl_array_list_implementation): Update.
127330         * lib/gl_carray_list.c (gl_carray_node_set_value): New function.
127331         (gl_carray_list_implementation): Update.
127332         * lib/gl_anylinked_list2.h (gl_linked_node_set_value): New function.
127333         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
127334         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
127335         * lib/gl_anytree_list2.h (gl_tree_node_set_value): New function.
127336         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
127337         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
127338         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
127339         Update.
127340         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
127341         * lib/gl_sublist.c (gl_sublist_node_set_value): New function.
127342         (gl_sublist_list_implementation): Update.
127344 2008-02-10  Bruno Haible  <bruno@clisp.org>
127346         * lib/diffseq.h: Write "ELEMENT const" instead of "const ELEMENT".
127347         Needed when ELEMENT is #defined to 'some_type *'.
127349 2008-02-10  Jim Meyering  <meyering@redhat.com>
127351         New script and module: useless-if-before-free
127352         * MODULES.html.sh (maint+release support): Add useless-if-before-free.
127353         * build-aux/useless-if-before-free: New file.
127354         * modules/useless-if-before-free: New file.
127356         * build-aux/gitlog-to-changelog: Use committer date, not author date.
127358         xstrtol_error: Fix typo.
127359         * lib/xstrtol-error.c (xstrtol_error): The parameter was unused:
127360         s/exit_failure/exit_status/.
127362 2008-02-09  Jim Meyering  <meyering@redhat.com>
127364         New script and module: gitlog-to-changelog
127365         * MODULES.html.sh (maint+release support): Add gitlog-to-changelog.
127366         * modules/gitlog-to-changelog: New file.
127367         * build-aux/gitlog-to-changelog: New file.
127369 2008-02-08  Jim Meyering  <meyering@redhat.com>
127371         Avoid two "parameter unused" warnings.
127372         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime):
127373         Mark "st" as used.
127375         Use "git COMMAND", not "git-COMMAND".
127376         * build-aux/bootstrap (version_controlled_file): s/git-rm/git-rm/.
127377         * build-aux/announce-gen (get_tool_versions): Correct a diagnostic.
127378         * build-aux/git-version-gen: Use "git status", not "git-status".
127380 2008-02-07  Bruno Haible  <bruno@clisp.org>
127382         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on native Woe32 systems.
127383         Avoids a crash on Windows Vista.
127384         Reported by Adam Strzelecki <ono@java.pl> via
127385         Simon Josefsson <simon@josefsson.org>.
127387 2008-02-06  Bruno Haible  <bruno@clisp.org>
127389         Fix *printf behaviour regarding the left-adjust flag on HP-UX 10.20.
127390         * m4/printf.m4 (gl_PRINTF_FLAG_LEFTADJUST): New macro.
127391         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_FLAG_LEFTADJUST.
127392         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST): New macro.
127393         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
127394         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
127395         gl_PRINTF_FLAG_LEFTADJUST and test its result. Invoke
127396         gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST.
127397         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
127398         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
127399         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
127400         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
127401         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
127402         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
127403         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
127404         * tests/test-vasnprintf-posix.c (test_function): Add testcases for the
127405         left-adjust flag.
127406         * tests/test-snprintf-posix.h (test_function): Likewise.
127407         * tests/test-sprintf-posix.h (test_function): Likewise.
127408         * tests/test-vasprintf-posix.c (test_function): Likewise.
127409         * doc/posix-functions/fprintf.texi: Update.
127410         * doc/posix-functions/printf.texi: Update.
127411         * doc/posix-functions/snprintf.texi: Update.
127412         * doc/posix-functions/sprintf.texi: Update.
127413         * doc/posix-functions/vfprintf.texi: Update.
127414         * doc/posix-functions/vprintf.texi: Update.
127415         * doc/posix-functions/vsnprintf.texi: Update.
127416         * doc/posix-functions/vsprintf.texi: Update.
127417         Reported by Peter Fales <psfales@alcatel-lucent.com>.
127419 2008-02-06  Bruno Haible  <bruno@clisp.org>
127421         Fix bug introduced on 2008-01-26.
127422         * lib/isnan.c (FUNC): Set to rpl_isnand, not rpl_isnan.
127424 2008-02-06  Bruno Haible  <bruno@clisp.org>
127426         Fix bug introduced on 2007-06-10.
127427         * lib/vasnprintf.c (VASNPRINTF): Perform zero-padding also if
127428         !NEED_PRINTF_FLAG_ZERO.
127430 2008-02-05  Peter O'Gorman  <pogma@thewrittenword.com>
127432         getloadavg: use libperfstat on AIX5
127433         * lib/getloadavg.c, m4/getloadavg.m4 [aix]: Use libperfstat
127435 2008-02-03  Bruno Haible  <bruno@clisp.org>
127437         * lib/diffseq.h: Add comments about required #includes.
127438         Reported by Michael Biggs <gnulib@doubleplum.net>.
127440 2008-02-01  Bruno Haible  <bruno@clisp.org>
127442         * users.txt: Add gnuit.
127444 2008-01-31  Bruno Haible  <bruno@clisp.org>
127446         * lib/md4.c (set_uint32): Mark as inline.
127447         * lib/md5.c (set_uint32): Likewise.
127448         * lib/sha1.c (set_uint32): Likewise.
127449         * m4/md4.m4 (gl_MD4): Require AC_C_INLINE.
127450         * m4/md5.m4 (gl_MD5): Likewise.
127451         * m4/sha1.m4 (gl_SHA1): Likewise.
127453 2008-01-31  Jim Meyering  <meyering@redhat.com>
127455         Use "sizeof VAR", rather than a literal "4".
127456         * lib/md5.c (md5_read_ctx): Use sizeof ctx->A, not 4.
127457         * lib/md4.c (md4_read_ctx): Likewise.
127458         * lib/sha1.c (sha1_read_ctx): Likewise.
127460 2008-01-31  Simon Josefsson  <simon@josefsson.org>
127462         * tests/test-sha1.c: New file, based on test-md5.c.
127464         * modules/crypto/sha1-tests: New file.
127466 2008-01-31  Simon Josefsson  <simon@josefsson.org>
127468         * lib/sha1.h (SHA1_DIGEST_SIZE): Define.
127470 2008-01-31  Jim Meyering  <meyering@redhat.com>
127472         Prefer "sizeof v" over the equivalent "4".
127473         * lib/md4.c (set_uint32): Use "sizeof v" as memcpy length, not 4.
127474         * lib/md5.c (set_uint32): Likewise.
127475         * lib/sha1.c (set_uint32): Likewise.
127477 2008-01-31  Simon Josefsson  <simon@josefsson.org>
127479         * lib/sha1.c (set_uint32): Mark function as static.
127481 2008-01-31  Simon Josefsson  <simon@josefsson.org>
127483         md2: clarify comments to say that alignment is not required.
127484         * lib/md2.h: Remove warning about alignment in comment.
127485         * lib/md2.c (md2_read_ctx, md2_finish_ctx): Doc fix, alignment has
127486         never been required.
127488 2008-01-31  Simon Josefsson  <simon@josefsson.org>
127490         md4: adapt alignment constraint fix from sha1.
127491         * lib/md4.c (set_uint32): New function, from sha1.c
127492         (md4_read_ctx): Use it.
127493         (md4_finish_ctx): Doc fix.
127494         * lib/md4.h: Doc fix.
127496 2008-01-31  Simon Josefsson  <simon@josefsson.org>
127498         md5: adapt alignment constraint fix from sha1.
127499         * lib/md5.c (set_uint32): New function, from sha1.c
127500         (md5_read_ctx): Use it.
127501         (md5_finish_ctx): Doc fix.
127502         * lib/md5.h: Doc fix.
127504 2008-01-30  Peter Palfrader  <weasel@debian.org>
127506         sha1: remove the result buffer alignment constraint
127507         * lib/sha1.c (set_uint32): New function.
127508         (sha1_read_ctx): Rewrite to remove the result buffer alignment
127509         constraint.
127510         (sha1_finish_ctx): Remove comment warning about alignment constraint.
127511         * lib/sha1.h: Likewise.
127513 2008-01-30  Andreas Schwab  <schwab@suse.de>
127514             Bruno Haible  <bruno@clisp.org>
127516         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Include <float.h> and ensure a
127517         correct definition of LDBL_MIN_EXP.
127519 2008-01-30  Karl Berry  <karl@gnu.org>
127521         * config/srclist-update: try to preserve x bit on updates.
127522         * config/srclistvars.sh: update for karl.
127524 2008-01-29  Jim Meyering  <meyering@redhat.com>
127526         vasnprintf.c: Avoid warning about unused label
127527         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Guard the
127528         "overflow" label definition and associated code with the
127529         same cpp condition that guards the sole use of that label.
127531 2008-01-26  Bruno Haible  <bruno@clisp.org>
127533         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM,
127534         gl_FUNC_ISNANL_WORKS): Test the GCC >= 4.0 built-in.
127535         * lib/isnanl.h (isnanl): Use the GCC >= 4.0 built-in.
127536         * lib/isnanl-nolibm.h (isnanl): Likewise.
127537         Reported by Paul Eggert <eggert@cs.ucla.edu>.
127539 2008-01-26  Bruno Haible  <bruno@clisp.org>
127541         * m4/isnand.m4 (gl_FUNC_ISNAND_NO_LIBM): Test the GCC >= 4.0 built-in.
127542         * lib/isnand.h (isnand): Use the GCC >= 4.0 built-in.
127544 2008-01-26  Bruno Haible  <bruno@clisp.org>
127546         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_ISNANF_WORKS): Test the
127547         GCC >= 4.0 built-in.
127548         * lib/isnanf.h (isnanf): Use the GCC >= 4.0 built-in.
127550 2008-01-26  Bruno Haible  <bruno@clisp.org>
127552         Rename isnan, applicable to 'double' only, to isnand.
127553         * modules/isnand-nolibm: Renamed from modules/isnan-nolibm.
127554         (Files): Add lib/isnand.h, lib/isnand.c. Remove lib/isnan.h.
127555         (configure.ac): Update.
127556         (Include): Replace "isnan.h" with "isnand.h".
127557         * m4/isnand.m4: Renamed from m4/isnan.m4.
127558         (gl_FUNC_ISNAND_NO_LIBM): Renamed from gl_FUNC_ISNAN_NO_LIBM. Set
127559         HAVE_ISNAND_IN_LIBC instead of HAVE_ISNAN_IN_LIBC. Build isnand.c
127560         instead of isnan.c.
127561         * lib/isnand.h: Renamed from lib/isnan.h. Test HAVE_ISNAND_IN_LIBC
127562         instead of HAVE_ISNAN_IN_LIBC.
127563         (isnand): Renamed from isnan.
127564         * lib/isnand.c: New file.
127565         * modules/isnand-nolibm-tests: Renamed from modules/isnan-nolibm-tests.
127566         (Files): Add tests/test-isnand.c. Remove tests/test-isnan.c.
127567         (Makefile.am): Update.
127568         * tests/test-isnand.c: Renamed from tests/test-isnan.c.
127569         Include isnand.h instead of isnan.h.
127570         (main): Test isnand instead of isnan.
127571         * modules/fprintf-posix (Depends-on): Add isnand-nolibm, remove
127572         isnan-nolibm.
127573         * modules/frexp (Depends-on): Likewise.
127574         * modules/frexp-tests (Depends-on): Likewise.
127575         * modules/frexp-nolibm (Depends-on): Likewise.
127576         * modules/frexp-nolibm-tests (Depends-on): Likewise.
127577         * modules/isfinite (Depends-on): Likewise.
127578         * modules/round-tests (Depends-on): Likewise.
127579         * modules/signbit (Depends-on): Likewise.
127580         * modules/signbit-tests (Depends-on): Likewise.
127581         * modules/snprintf-posix (Depends-on): Likewise.
127582         * modules/sprintf-posix (Depends-on): Likewise.
127583         * modules/trunc-tests (Depends-on): Likewise.
127584         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
127585         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
127586         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
127587         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
127588         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
127589         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
127590         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
127591         * modules/vasnprintf-posix (Depends-on): Likewise.
127592         * modules/vasprintf-posix (Depends-on): Likewise.
127593         * modules/vfprintf-posix (Depends-on): Likewise.
127594         * modules/vsnprintf-posix (Depends-on): Likewise.
127595         * modules/vsprintf-posix (Depends-on): Likewise.
127596         * lib/frexp.c: Include isnand.h instead of isnan.h.
127597         (ISNAN): Set to isnand instead of isnan.
127598         * lib/isfinite.c: Include isnand.h instead of isnan.h.
127599         (gl_isfinited): Use isnand instead of isnan.
127600         * lib/signbitd.c: Include isnand.h instead of isnan.h.
127601         (gl_signbitd): Use isnand instead of isnan.
127602         * lib/vasnprintf.c: Include isnand.h instead of isnan.h.
127603         (is_infinite_or_zero, VASNPRINTF): Use isnand instead of isnan.
127604         * tests/test-frexp.c: Include isnand.h instead of isnan.h.
127605         (main): Use isnand instead of isnan.
127606         * tests/test-round1.c: Include isnand.h.
127607         (main): Use isnand instead of isnan.
127608         * tests/test-round2.c: Include isnand.h instead of isnan.h.
127609         (ISNAN): Set to isnand instead of isnan.
127610         * tests/test-trunc1.c: Include isnand.h.
127611         (main): Use isnand instead of isnan.
127612         * tests/test-trunc2.c: Include isnand.h instead of isnan.h.
127613         (equal): Use isnand instead of isnan.
127614         * MODULES.html.sh (Mathematics <math.h>): Replace isnan-nolibm with
127615         isnand-nolibm.
127616         * NEWS: Mention the change.
127618 2008-01-25  Paul Eggert  <eggert@cs.ucla.edu>
127619             Bruno Haible  <bruno@clisp.org>
127621         * m4/signbit.m4 (gl_SIGNBIT): Require a macro definition. Test whether
127622         the GCC builtins for signbits are present and set
127623         REPLACE_SIGNBIT_USING_GCC if so.
127624         * lib/math.in.h (signbit): Define using GCC builtins if
127625         REPLACE_SIGNBIT_USING_GCC is set.
127626         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize
127627         REPLACE_SIGNBIT_USING_GCC.
127628         * modules/math (Makefile.am): Substitute REPLACE_SIGNBIT_USING_GCC.
127630 2008-01-25  Jim Meyering  <meyering@redhat.com>
127632         Prefer <config.h> over "config.h".  See autoconf doc for explanation.
127633         * lib/poll.c: Include <config.h>, not "config.h".
127634         * tests/test-getaddrinfo.c: Likewise.
127636 2008-01-25  Simon Josefsson  <simon@josefsson.org>
127638         * modules/sockets-tests: New file.
127640 2008-01-24  Simon Josefsson  <simon@josefsson.org>
127642         * modules/sockets: New module, can be used to call WSA_Startup and
127643         WSA_Cleanup when needed.
127645         * lib/sockets.h, lib/sockets.c: New files.
127647         * m4/sockets.m4: New file.
127649         * tests/test-sockets.c: New file.
127651 2008-01-19  Bruno Haible  <bruno@clisp.org>
127653         * doc/posix-headers: Renamed from doc/headers.
127654         * doc/posix-functions: Renamed from doc/functions.
127655         * doc/gnulib.texi: Update.
127657 2008-01-19  Bruno Haible  <bruno@clisp.org>
127659         * doc/glibc-functions/strcasestr.texi: Include contents of
127660         doc/functions/strcasestr.texi, fixing the list of platforms.
127661         * doc/functions/strcasestr.texi: Remove file.
127663 2008-01-19  Bruno Haible  <bruno@clisp.org>
127665         * doc/glibc-functions/memmem.texi: Include contents of
127666         doc/functions/memmem.texi.
127667         * doc/functions/memmem.texi: Remove file.
127669 2008-01-18  Bruno Haible  <bruno@clisp.org>
127671         * doc/glibc-functions/*.texi: New files.
127672         * doc/gnulib.texi (Glibc Function Substitutes): Completely rewritten
127673         to use the new files.
127675 2008-01-17  Bruno Haible  <bruno@clisp.org>
127677         * tests/test-gethostname.c (main): Fix printf statement.
127679 2008-01-17  Simon Josefsson  <simon@josefsson.org>
127681         * modules/gethostname-tests: New file.
127683         * tests/test-gethostname.c: New file.
127685 2008-01-17  Simon Josefsson  <simon@josefsson.org>
127687         * lib/gethostname.c: Include string.h unconditionally, strncpy is
127688         used by the UNAME case.  Reported by Bruno Haible
127689         <bruno@clisp.org>.
127691 2008-01-17  Eric Blake  <ebb9@byu.net>
127693         Convert c-strcasestr to be more efficient.
127694         * modules/c-strcasestr (Files): Use Two-Way, not KMP.
127695         (Depends-on): Add c-strcase, remove malloca, strnlen.
127696         * tests/test-c-strcasestr.c (main): Enhance test.
127697         * lib/c-strcasestr.c (c_strcasestr): Rewrite to new algorithm.
127699 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
127701         * build-aux/bootstrap (MSGID_BUGS_ADDRESS): New overridable variable.
127702         Use it in creating po/Makevars.
127704 2008-01-15  Simon Josefsson  <simon@josefsson.org>
127706         * lib/gc-libgcrypt.c (gc_init): Disable secure memory by default.
127707         Applications that requires it should initialize libgcrypt
127708         manually.
127710 2008-01-16  Simon Josefsson  <simon@josefsson.org>
127712         * lib/gethostname.c [!HAVE_UNAME]: Need string.h for strcpy.
127714 2008-01-15  Paul Eggert  <eggert@cs.ucla.edu>
127716         Fix problem with getdate on mingw32 reported by Simon Josefsson
127717         in <http://lists.gnu.org/r/bug-gnulib/2008-01/msg00192.html>.
127718         * lib/getdate.y (get_date): Check "HAVE_DECL_TZNAME", not "defined
127719         tzname", when deciding whether to declare tzname.
127720         * lib/strftime.c (tzname): Likewise.
127722 2008-01-15  Bruno Haible  <bruno@clisp.org>
127724         Work around a MacOS X 10.5 bug in frexpl().
127725         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Also check denormalized numbers.
127726         * doc/functions/frexpl.texi: Document the bug.
127727         Reported by Elias Pipping <pipping@gentoo.org>.
127729 2008-01-14  Eric Blake  <ebb9@byu.net>
127731         Touch up previous patch.
127732         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Fix typo.
127733         * doc/functions/strcasestr.texi (strcasestr): Document OpenBSD bug.
127735         Convert strcasestr module to use Two-Way algorithm.
127736         * modules/strcasestr-simple: New module, based on the old
127737         strcasestr, but with Two-Way rather than KMP.
127738         * modules/strcasestr (Depends-on): Change to strcasestr-simple.
127739         * lib/string.in.h (rpl_strcasestr): Declare.
127740         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Check for linear
127741         performance.
127742         * lib/strcasestr.c (strcasestr): Simplify, and avoid malloc.
127743         * modules/string (Makefile.am): Support strcasestr.
127744         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
127745         * modules/strcasestr-tests (Depends-on): Check for alarm.
127746         * tests/test-strcasestr.c: Augment test.
127747         * lib/str-two-way.h: Clean up stray macro.
127748         * NEWS: Document new module.
127749         * MODULES.html.sh (string handling): Likewise.
127750         * doc/functions/strcasestr.texi: New file.
127751         * doc/gnulib.texi (Function Substitutes): New node.  Move memmem
127752         here, since it is not a POSIX function.
127754 2008-01-14  Colin Watson  <cjwatson@debian.org>
127755             Bruno Haible  <bruno@clisp.org>
127757         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Also check whether strsignal
127758         works fine; if not, set REPLACE_STRSIGNAL.
127759         (gl_PREREQ_STRSIGNAL): Require AC_DECL_SYS_SIGLIST.
127760         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
127761         REPLACE_STRSIGNAL.
127762         * lib/string.in.h (strsignal): Consider REPLACE_STRSIGNAL.
127763         * modules/string (Makefile.am): Substitute REPLACE_STRSIGNAL.
127764         * tests/test-strsignal.c (main): Check out-of-range signal numbers.
127766 2008-01-14  Bruno Haible  <bruno@clisp.org>
127768         * modules/strsignal (Include): Change to <string.h>.
127770 2008-01-14  Colin Watson  <cjwatson@debian.org>
127772         * modules/argp (Notice): Add a notice recommending to change
127773         XGETTEXT_OPTIONS.
127774         (configure.ac): Invoke AM_XGETTEXT_OPTION if it exists.
127776 2008-01-13  Colin Watson  <cjwatson@debian.org>
127778         * modules/strsignal-tests: New file.
127779         * tests/test-strsignal.c: New file.
127781         * lib/strsignal.c: New file, from glibc with modifications.
127782         * lib/siglist.h: New file, from glibc with modifications.
127783         * lib/string.in.h (strsignal): New declaration.
127784         * m4/strsignal.m4: New file.
127785         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
127786         GNULIB_STRSIGNAL and HAVE_DECL_STRSIGNAL.
127787         * modules/strsignal: New file.
127788         * modules/string (Makefile.am): Substitute GNULIB_STRSIGNAL and
127789         HAVE_DECL_STRSIGNAL.
127791 2008-01-13  Bruno Haible  <bruno@clisp.org>
127793         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check that the
127794         locale encoding is not ASCII. Needed for OpenBSD 4.0.
127795         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
127796         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
127798 2008-01-13  Bruno Haible  <bruno@clisp.org>
127800         * lib/argp-fmtstream.h (__attribute__): Don't redefine if
127801         __STRICT_ANSI__ is set: it's not needed by any version of gcc.
127802         * lib/argp.h (__attribute__): Likewise.
127803         * lib/c-stack.c (__attribute__): Likewise.
127804         * lib/error.h (__attribute__): Likewise.
127805         * lib/fts.c (__attribute__): Likewise.
127806         * lib/openat.h (__attribute__): Likewise.
127807         * lib/stdio.in.h (__attribute__): Likewise.
127808         * lib/string.in.h (__attribute__): Likewise.
127809         * lib/utimens.c (__attribute__): Likewise.
127810         * lib/vasnprintf.h (__attribute__): Likewise.
127811         * lib/xalloc.h (__attribute__): Likewise.
127812         * lib/xprintf.h (__attribute__): Likewise.
127813         * lib/xstrtol.h (__attribute__): Likewise.
127814         * lib/xvasprintf.h (__attribute__): Likewise.
127816 2008-01-12  Bruno Haible  <bruno@clisp.org>
127818         * doc/gnulib.texi (Glibc Header File Substitutes): New chapter.
127819         * doc/glibc-headers/a.out.texi: New file.
127820         * doc/glibc-headers/aliases.texi: New file.
127821         * doc/glibc-headers/alloca.texi: New file.
127822         * doc/glibc-headers/ar.texi: New file.
127823         * doc/glibc-headers/argp.texi: New file.
127824         * doc/glibc-headers/argz.texi: New file.
127825         * doc/glibc-headers/byteswap.texi: New file.
127826         * doc/glibc-headers/crypt.texi: New file.
127827         * doc/glibc-headers/endian.texi: New file.
127828         * doc/glibc-headers/envz.texi: New file.
127829         * doc/glibc-headers/err.texi: New file.
127830         * doc/glibc-headers/error.texi: New file.
127831         * doc/glibc-headers/execinfo.texi: New file.
127832         * doc/glibc-headers/fpu_control.texi: New file.
127833         * doc/glibc-headers/fstab.texi: New file.
127834         * doc/glibc-headers/fts.texi: New file.
127835         * doc/glibc-headers/getopt.texi: New file.
127836         * doc/glibc-headers/ieee754.texi: New file.
127837         * doc/glibc-headers/ifaddrs.texi: New file.
127838         * doc/glibc-headers/libintl.texi: New file.
127839         * doc/glibc-headers/mcheck.texi: New file.
127840         * doc/glibc-headers/mntent.texi: New file.
127841         * doc/glibc-headers/obstack.texi: New file.
127842         * doc/glibc-headers/paths.texi: New file.
127843         * doc/glibc-headers/printf.texi: New file.
127844         * doc/glibc-headers/pty.texi: New file.
127845         * doc/glibc-headers/resolv.texi: New file.
127846         * doc/glibc-headers/shadow.texi: New file.
127847         * doc/glibc-headers/sysexits.texi: New file.
127848         * doc/glibc-headers/ttyent.texi: New file.
127850 2008-01-12  Jim Meyering  <meyering@redhat.com>
127852         announce-gen: emit Gnulib's git-based version string.
127853         * build-aux/announce-gen: Remove option: --gnulib-snapshot-time-stamp=S.
127854         New option --gnulib-version=V, where V is expected to be
127855         the output of running git describe in the gnulib directory.
127856         (get_tool_versions): Request feedback on xdelta.  I suspect it's
127857         not useful, and plan to stop publishing an xdelta file with each
127858         coreutils release.
127860         * build-aux/announce-gen: Also check for lzma-compressed files.
127862 2008-01-11  Bruno Haible  <bruno@clisp.org>
127864         * tests/test-memmem.c (main): Increase maximum allowed time.
127865         * tests/test-strstr.c (main): Likewise.
127867 2008-01-11  Bruno Haible  <bruno@clisp.org>
127869         * doc/functions/memmem.texi: Add more precisions about platforms.
127870         * doc/functions/strstr.texi: Likewise.
127872 2008-01-10  Eric Blake  <ebb9@byu.net>
127874         * m4/strstr.m4: Delete cruft from copy-n-paste.
127875         Reported by Bruno Haible.
127877 2008-01-10  Bruno Haible  <bruno@clisp.org>
127879         Make c-strstr rely on strstr.
127880         * lib/c-strstr.c: Don't include str-kmp.h.
127881         (c_strstr): Define in terms of strstr.
127882         * modules/c-strstr (Files): Remove lib/str-kmp.h.
127883         (Depends-on): Remove stdbool, malloca, strnlen. Add strstr.
127885 2008-01-10  Bruno Haible  <bruno@clisp.org>
127887         * doc/gnulib.texi (String Functions in C Locale): New section.
127888         * doc/c-ctype.texi: New file.
127889         * doc/c-strcase.texi: New file.
127890         * doc/c-strcaseeq.texi: New file.
127891         * doc/c-strcasestr.texi: New file.
127892         * doc/c-strstr.texi: New file.
127893         * doc/c-strtod.texi: New file.
127894         * doc/c-strtold.texi: New file.
127896 2008-01-10  Eric Blake  <ebb9@byu.net>
127898         * lib/relocatable.h: Fix a comment.
127900 2008-01-10  Eric Blake  <ebb9@byu.net>
127902         Share two-way algorithm.
127903         * lib/str-two-way.h: New file, merged from...
127904         * lib/memmem.c: ...here...
127905         * lib/strstr.c: ...and here.
127906         * modules/memmem (Files): Use it.
127907         * modules/strstr (Files): Likewise.
127909         Avoid quadratic strstr implementations.
127910         * lib/strstr.c: New file.
127911         * m4/strstr.m4: Likewise.
127912         * modules/strstr: Likewise.
127913         * modules/strstr-tests: Likewise.
127914         * tests/test-strstr.c: Likewise.
127915         * lib/string.in.h (rpl_strstr): Declare.
127916         (memmem) [GNULIB_POSIXCHECK]: Document speed issue.
127917         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Support strstr.
127918         * modules/string (Makefile.am): Likewise.
127919         * MODULES.html.sh (string handling): Mention new module.
127920         * doc/functions/strstr.texi (strstr): Document the bug.
127922 2008-01-10  Bruno Haible  <bruno@clisp.org>
127924         * lib/relocatable.h (relocate): State whether result is freshly
127925         allocated or not.
127926         * lib/relocatable.c (relocate): Return a freshly allocated string
127927         instead of a pointer to a privately held string.
127928         Reported by Sylvain Beucler <beuc@gnu.org>.
127930 2008-01-10  Colin Watson  <cjwatson@debian.org>
127932         * lib/canonicalize-lgpl.c [!_LIBC]: Fix typo in #if directive:
127933         s/S_ISNLK/S_ISLNK/.
127935 2008-01-09  Bruno Haible  <bruno@clisp.org>
127937         * doc/functions/memmem.texi: Use the same structure as snprintf.texi
127938         and other files.
127939         * m4/memmem.m4 (gl_FUNC_MEMMEM): Say "guessing no" instead of "no"
127940         if it's only a guess.
127941         * modules/memmem: Simplify by depending on memmem-simple.
127943 2008-01-09  Bruno Haible  <bruno@clisp.org>
127945         Work around OpenBSD 4.0 tdelete() bug.
127946         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Also check tdelete's return value.
127947         * lib/search.in.h: If REPLACE_TSEARCH is 1, define tsearch etc. as
127948         macros and don't redefine the enum values.
127949         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize REPLACE_TSEARCH.
127950         * modules/search (Makefile.am): Also substitute REPLACE_TSEARCH.
127951         * doc/functions/tdelete.texi: Document the OpenBSD 4.0 bug.
127953 2008-01-09  Bruno Haible  <bruno@clisp.org>
127955         * tests/test-wcwidth.c: Include <string.h> and localcharset.h.
127956         (main): Don't perform the tests if setlocale did not install a UTF-8
127957         locale. Needed on OpenBSD 4.0.
127958         * modules/wcwidth-tests (Depends-on): Add localcharset.
127960 2008-01-09  Paul Eggert  <eggert@cs.ucla.edu>
127962         gl_FUNC_ALLOCA no longer defines HAVE_ALLOCA_H unconditionally.
127963         See <http://lists.gnu.org/r/bug-gnulib/2007-12/msg00149.html>.
127964         * NEWS: announce this.
127965         * m4/alloca.m4 (gl_FUNC_ALLOCA): Don't define HAVE_ALLOCA_H.
127967 2008-01-09  Simon Josefsson  <simon@josefsson.org>
127968         and Eric Blake  <ebb9@byu.net>
127970         Add memmem-simple module.
127971         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): New macro.
127972         (gl_FUNC_MEMMEM): Separate performance from presence checks.
127973         * modules/memmem-simple: New file.
127974         * modules/memmem (Description): Tweak.
127975         * MODULES.html.sh (string handling): Mention new module.
127976         * doc/functions/memmem.texi (memmem): Distinguish which flaws are
127977         addressed by memmem-simple.
127978         * NEWS: Document the difference.
127980 2008-01-09  Eric Blake  <ebb9@byu.net>
127982         Give gcc some memmem optimization hints.
127983         * lib/string.in.h (memmem, memrchr, strchrnul, strnlen, strpbrk)
127984         (strcasestr): Declare as pure.
127985         * modules/memmem (Maintainer): Claim my implementation.
127987 2008-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
127989         Support AIX 6.1 and higher.
127990         * build-aux/config.libpath: Likewise.
127991         * build-aux/config.rpath: Likewise.
127993 2008-01-08  Jim Meyering  <meyering@redhat.com>
127994             Bruno Haible  <bruno@clisp.org>
127996         * lib/printf-parse.c (PRINTF_PARSE): Handle a size specifier "q"
127997         on MacOS X and a size specifier "I64" on mingw. Needed for PRIdMAX.
127998         Reported by Peter Fales in
127999         <http://lists.gnu.org/r/bug-coreutils/2007-12/msg00148.html>.
128001 2008-01-08  Bruno Haible  <bruno@clisp.org>
128003         * modules/unictype/category-of (Depends-on): Add
128004         unictype/category-none.
128005         * modules/unictype/category-and-tests (Depends-on): Add
128006         unictype/category-{L,N,Lu,Nd}.
128007         * modules/unictype/category-and-not-tests (Depends-on): Likewise.
128008         * modules/unictype/category-or-tests (Depends-on): Add
128009         unictype/category-{L,N}.
128010         * modules/unictype/category-name-tests (Depends-on): Add
128011         unictype/category-{Z,Nl}.
128012         Reported by Simon Josefsson.
128014 2008-01-08  Bruno Haible  <bruno@clisp.org>
128016         * lib/str-kmp.h (knuth_morris_pratt_unibyte): Document the calling
128017         convention better.
128018         * lib/mbsstr.c (knuth_morris_pratt_multibyte): Likewise.
128019         * lib/mbscasestr.c (knuth_morris_pratt_multibyte): Likewise.
128020         Reported by Peter Miller <millerp@canb.auug.org.au>.
128022 2008-01-08  Eric Blake  <ebb9@byu.net>
128024         Rewrite memmem to guarantee linear complexity without malloc.
128025         * lib/memmem.c (memmem): Use Two-Way rather than
128026         Knuth-Morris-Pratt, to allow O(1) space usage.
128027         (critical_factorization, two_way_short_needle)
128028         (two_way_long_needle): New functions.
128029         (knuth_morris_pratt): Delete.
128030         * modules/memmem (Depends-on): No longer need malloca or stdbool.
128031         Add stdint.
128032         * tests/test-memmem.c (main): Add tests for periodic needle and
128033         sublinear performance.
128034         * doc/functions/memmem.texi (memmem): Document other deficiencies
128035         in cygwin and older glibc.
128037 2008-01-08  Bruno Haible  <bruno@clisp.org>
128039         * modules/memmem-tests (Makefile.am): Remove TESTS_ENVIRONMENT
128040         augmentation.
128042 2008-01-08  Mike Frysinger  <vapier@gentoo.org>
128044         Add a configure time option: --disable-acl.
128045         * m4/acl.m4 (gl_FUNC_ACL): Wrap all ACL logic in a call to
128046         AC_ARG_ENABLE(acl).
128048 2008-01-06  Simon Josefsson  <simon@josefsson.org>
128050         * tests/test-localename.c: Don't include obsolete "setenv.h".
128052         * modules/localename-tests (Depends-on): Need unsetenv.
128054 2008-01-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128056         * DEPENDENCIES: Require Texinfo version 4.6 or newer.
128058 2008-01-06  Colin Watson  <cjwatson@debian.org>
128060         * users.txt: Add man-db.
128062 2008-01-07  Bruno Haible  <bruno@clisp.org>
128064         * doc/gnulib-intro.texi (Library vs Reusable Code): Restore the
128065         previous section name.
128067 2008-01-07  Bruno Haible  <bruno@clisp.org>
128069         * lib/progname.c (set_program_name): Don't strip off a leading
128070         "lt-" prefix outside a .libs directory.
128071         Suggested by Paul Eggert.
128073 2008-01-01  Sylvain Beucler  <beuc@gnu.org>
128074             Bruno Haible  <bruno@clisp.org>
128076         Improve memory cleanup in 'relocatable' module.
128077         * lib/relocatable.h (compute_curr_prefix): Change return type to
128078         'char *'.
128079         * lib/relocatable.c (compute_curr_prefix): Change return type to
128080         'char *'. Free curr_installdir after use.
128081         (relocate): Free curr_prefix_better after use.
128082         * lib/progreloc.c (prepare_relocate): Free curr_prefix after use.
128084 2008-01-01  Bruno Haible  <bruno@clisp.org>
128086         * tests/test-wcwidth.c (main): Relax test of U+2060. Avoids a test
128087         failure on older glibc systems.
128088         Reported by Peter Fales <psfales@alcatel-lucent.com>.
128090 2008-01-05  Eric Blake  <ebb9@byu.net>
128092         Avoid quadratic system memmem.
128093         * m4/memmem.m4 (gl_FUNC_MEMMEM): Check for quadratic memmem.
128094         Reported by Ralf Wildenhues.
128096         Fix memmem test for mingw.
128097         * modules/memmem-tests (configure.ac): Check for alarm.
128098         * tests/test-memmem.c (main): Avoid alarm on platforms that lack
128099         it.
128100         * doc/functions/memmem.texi: New file.
128101         * doc/gnulib.texi (Function Substitutes): Add memmem.
128102         Reported by Bruno Haible.
128104 2008-01-04  Bruno Haible  <bruno@clisp.org>
128106         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP):
128107         Require gl_HEADER_STRINGS_H_DEFAULTS, not
128108         gl_HEADER_STRING_H_DEFAULTS.
128110 2008-01-04  Eric Blake  <ebb9@byu.net>
128112         Shorten duration of memmem test.
128113         * tests/test-memmem.c (main): Use alarm to declare failure if test
128114         is taking too long.
128115         Reported by Ralf Wildenhues.
128117 2007-12-21  Simon Josefsson  <simon@josefsson.org>
128119         * modules/relocatable-prog-wrapper (Depends-on): Add intprops and
128120         string, needed by strerror.
128122 2008-01-03  Colin Watson  <cjwatson@debian.org>
128123             Bruno Haible  <bruno@clisp.org>
128125         * doc/gnulib-tool.texi (Localization): New section.
128127 2008-01-02  Bruno Haible  <bruno@clisp.org>
128129         * lib/memmem.c (knuth_morris_pratt, memmem): Change all 'char *'
128130         variables to 'unsigned char *' type.
128131         Reported by Paul Eggert.
128133 2008-01-02  Jim Meyering  <jim@meyering.net>
128135         * lib/version-etc.c (COPYRIGHT_YEAR): Increase for new year.
128137 2007-12-31  Jim Meyering  <jim@meyering.net>
128139         Avoid use of private FTS type name.
128140         * lib/fts.c (fts_sort): Use FTSENT rather than "struct _ftsent".
128142 2007-12-30  Karl Berry  <karl@gnu.org>
128144         * doc/gnulib.texi (Library vs. Reusable Code): remove period, to
128145         work around defect in Texinfo and/or the standalone Info browser.
128147 2007-12-30  Bruno Haible  <bruno@clisp.org>
128149         Unify 5 copies of the KMP code.
128150         * lib/str-kmp.h: New file.
128151         * lib/c-strcasestr.c: Include str-kmp.h.
128152         (knuth_morris_pratt): Remove function.
128153         (c_strcasestr): Update.
128154         * lib/c-strstr.c: Include str-kmp.h.
128155         (knuth_morris_pratt): Remove function.
128156         (c_strcasestr): Update.
128157         * lib/mbscasestr.c: Include str-kmp.h.
128158         (knuth_morris_pratt_unibyte): Remove function.
128159         * lib/mbsstr.c: Include str-kmp.h.
128160         (knuth_morris_pratt_unibyte): Remove function.
128161         * lib/strcasestr.c: Include str-kmp.h.
128162         (knuth_morris_pratt): Remove function.
128163         (strcasestr): Update.
128164         * modules/c-strcasestr (Files): Add lib/str-kmp.h.
128165         * modules/c-strstr (Files): Likewise.
128166         * modules/mbscasestr (Files): Likewise.
128167         * modules/mbsstr (Files): Likewise.
128168         * modules/strcasestr (Files): Likewise.
128169         Suggested by Paul Eggert.
128171 2007-12-30  Bruno Haible  <bruno@clisp.org>
128173         * lib/xmalloca.c (xmmalloca): Don't define if HAVE_ALLOCA is not
128174         defined.
128176 2007-12-30  Bruno Haible  <bruno@clisp.org>
128178         * lib/xmalloca.h: Include xalloc.h.
128179         (xnmalloca): New macro.
128181 2007-12-30  Bruno Haible  <bruno@clisp.org>
128183         * lib/malloca.h (nmalloca): New macro.
128184         * lib/c-strcasestr.c (knuth_morris_pratt): Use it.
128185         * lib/c-strstr.c (knuth_morris_pratt): Likewise.
128186         * lib/mbscasestr.c (knuth_morris_pratt_unibyte,
128187         knuth_morris_pratt_multibyte): Likewise.
128188         * lib/mbsstr.c (knuth_morris_pratt_unibyte,
128189         knuth_morris_pratt_multibyte): Likewise.
128190         * lib/memmem.c (knuth_morris_pratt): Likewise.
128191         * lib/strcasestr.c (knuth_morris_pratt): Likewise.
128193 2007-12-25  Bruno Haible  <bruno@clisp.org>
128195         Fixup after 2007-10-17 commit. Ensure that 'glob' stays under LGPLv2+.
128196         * lib/glob.c: Don't include openat.h.
128197         (link_exists2_p): Add back the code that deals with the
128198         !GLOB_ALTDIRFUNC case.
128199         (link_exists_p) [!_LIBC && !HAVE_FSTATAT]: Just call link_exists2_p and
128200         let it do the filename concatenation.
128201         * m4/glob.m4 (gl_PREREQ_GLOB): Add check for fstatat.
128202         * modules/glob (Depends-on): Remove openat.
128204 2007-12-31  Bruno Haible  <bruno@clisp.org>
128206         * modules/dirfd (License): Change to LGPLv2+.
128207         Approved by Jim Meyering.
128209 2007-12-29  Paul Eggert  <eggert@cs.ucla.edu>
128211         * lib/memmem.c (knuth_morris_pratt): Check for size_t overflow
128212         when multiplying M by sizeof (size_t).
128214 2007-12-10  Martin Lambers  <marlam@marlam.de>
128216         Override getpagesize on mingw.
128217         * lib/getpagesize.c: New file.
128218         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Enable replacement on mingw.
128219         * modules/getpagesize (Files): Add lib/getpagesize.c.
128220         * lib/unistd.in.h (getpagesize): Declare if we are using a replacement.
128221         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
128222         REPLACE_GETPAGESIZE.
128223         * modules/unistd (Makefile.am): Substitute REPLACE_GETPAGESIZE.
128225 2007-12-25  Bruno Haible  <bruno@clisp.org>
128227         * modules/localcharset (Notice): New field.
128228         (configure.ac): Define LOCALCHARSET_TESTS_ENVIRONMENT.
128229         Suggested by Ben Pfaff <blp@cs.stanford.edu>.
128231 2007-12-25  Paul Eggert  <eggert@cs.ucla.edu>
128232             Bruno Haible  <bruno@clisp.org>
128234         Avoid using the syntax symbol() in formatted documentation.
128235         * MODULES.html.sh (func_module): When replacing symbol() with a
128236         hyperlink, remove the parentheses. Show an error if some remain.
128237         Recognize and render the '...' syntax.
128238         * doc/alloca-opt.texi: Remove parentheses from symbol reference.
128239         Rework. Add paragraph about GCC's inlining.
128240         * doc/alloca.texi: Likewise.
128241         * doc/error.texi: Remove parentheses from symbol reference.
128242         * doc/gnulib-intro.texi: Likewise.
128243         * doc/gnulib.texi (alloca, alloca-opt): New nodes.
128244         * modules/fnmatch (Description): Reword to say "the ... function".
128245         * modules/full-read (Description): Likewise.
128246         * modules/full-write (Description): Likewise.
128247         * modules/safe-read (Description): Likewise.
128248         * modules/safe-write (Description): Likewise.
128249         * modules/strchrnul (Description): Likewise.
128250         * modules/trim (Description): Likewise.
128251         * modules/error (Description): Remove parentheses from symbol
128252         references.
128253         * modules/verror (Description): Likewise.
128254         Reported by Karl Berry.
128256 2007-12-25  Bruno Haible  <bruno@clisp.org>
128258         Fixup after 2007-10-16 commit.
128259         * lib/glob.c (glob_in_dir): Don't use ISO C99 syntax.
128261 2007-12-24  Bruno Haible  <bruno@clisp.org>
128263         Make --enable-relocatable work with DESTDIR.
128264         * build-aux/install-reloc: Accept another argument 'destdir'. Use it
128265         to compute installdir from destprog.
128266         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV,
128267         also set the RELOC_DESTDIR variable.
128268         Reported by Левашев Иван <octagram@bluebottle.com>.
128270 2007-12-24  Bruno Haible  <bruno@clisp.org>
128272         Fix link error due to xalloc_die().
128273         * lib/progreloc.c: When NO_XMALLOC is defined, use areadlink instead
128274         of xreadlink.
128275         * lib/relocwrapper.c: Update comments.
128276         * build-aux/install-reloc: Remove xreadlink.c from file list.
128277         * modules/relocatable-prog-wrapper (Files): Remove xreadlink.h and
128278         xreadlink.c.
128279         Reported by Левашев Иван <octagram@bluebottle.com>.
128281 2007-12-24  Bruno Haible  <bruno@clisp.org>
128283         Split setenv module into setenv and unsetenv. Get rid of setenv.h.
128284         * lib/setenv.h: Remove file.
128285         * lib/stdlib.in.h (setenv, unsetenv): New declarations, moved here from
128286         lib/setenv.h.
128287         * modules/setenv (Files): Remove lib/setenv.h, lib/unsetenv.c.
128288         (Depends-on): Add stdlib.
128289         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR. Don't invoke
128290         gl_FUNC_UNSETENV.
128291         (Include): Replace setenv.h with <stdlib.h>.
128292         * modules/unsetenv: New file.
128293         * lib/setenv.c: Include <stdlib.h> first, after alloca.h.
128294         * lib/unsetenv.c: Include <stdlib.h> first.
128295         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_SETENV_SEPARATE): Require
128296         gl_STDLIB_H_DEFAULTS. Conditionally set HAVE_SETENV to 0.
128297         (gl_FUNC_UNSETENV): Require gl_STDLIB_H_DEFAULTS. Conditionally set
128298         HAVE_UNSETENV to 0. Set VOID_UNSETENV as an AC_SUBSTed variable.
128299         * modules/stdlib (Makefile.am): Substitute also GNULIB_SETENV,
128300         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
128301         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_SETENV,
128302         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
128303         * doc/functions/unsetenv.texi: Update.
128304         * modules/xsetenv (Depends-on): Add unsetenv.
128305         * modules/getdate (Depends-on): Likewise.
128306         * lib/xsetenv.h: Include <stdlib.h> instead of setenv.h.
128307         * lib/xsetenv.c: Don't include setenv.h.
128308         * lib/getdate.y: Likewise.
128309         * lib/relocwrapper.c: Likewise.
128310         * modules/relocatable-prog-wrapper (Files): Remove lib/setenv.h.
128311         (Depends-on): Add stdlib.
128312         * NEWS: Mention the changes.
128313         Reported by Левашев Иван <octagram@bluebottle.com>.
128315 2007-12-23  Bruno Haible  <bruno@clisp.org>
128317         * lib/memmem.c (memmem): Use lowercase variable names. Tab
128318         indentation.
128320 2007-12-23  Bruno Haible  <bruno@clisp.org>
128322         * lib/c-strcasestr.c: Add more comments.
128323         * lib/c-strstr.c: Likewise.
128324         * lib/mbscasestr.c: Likewise.
128325         * lib/mbsstr.c: Likewise.
128326         * lib/strcasestr.c: Likewise.
128327         * lib/memmem.c: Likewise.
128329 2007-12-23  Bruno Haible  <bruno@clisp.org>
128331         * tests/test-memmem.c: Include <string.h> first.
128333 2007-12-22  Bruno Haible  <bruno@clisp.org>
128335         * gnulib-tool (func_create_testdir): Change $auxdir while generating
128336         the contents of $testsbase.
128337         Reported by Ralf Wildenhues.
128339 2007-12-22  Bruno Haible  <bruno@clisp.org>
128341         * gnulib-tool (func_emit_tests_Makefile_am): Replace local_ldadd with
128342         two variables local_ldadd_before, local_ldadd_last.
128344 2007-12-20  Eric Blake  <ebb9@byu.net>
128346         Work around circular library issue when cross-compiling.
128347         * lib/progname.c (set_program_name): Use strncmp, not memcmp, so
128348         that progname.o does not need to pull in rpl_memcmp.
128350 2007-12-19  Eric Blake  <ebb9@byu.net>
128352         Fix memmem to avoid O(n^2) worst-case complexity.
128353         * lib/memmem.c (knuth_morris_pratt): New function.
128354         (memmem): Use it if first few naive iterations fail.
128355         * m4/memmem.m4 (gl_FUNC_MEMMEM): Detect cygwin bug.
128356         * modules/memcmp (License): Set to LGPLv2+, not LGPL.
128357         * modules/memchr (License): Likewise.
128358         * modules/memmem (Depends-on): Add memcmp, memchr, stdbool, and
128359         malloca.
128360         * tests/test-memmem.c: Rewrite, borrowing ideas from
128361         test-mbsstr1.c; the old version wouldn't even compile!
128362         * modules/memmem-tests: New file.
128363         * lib/string.in.h (rpl_memmem): Add declaration.
128364         * modules/string (Makefile.am): Substitute REPLACE_MEMMEM.
128365         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Default for
128366         REPLACE_MEMMEM.
128368 2007-12-18  Paul Eggert  <eggert@cs.ucla.edu>
128370         Fix problem with _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H on VMS.
128371         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_INTTYPES_H): Define
128372         before any system include files, and undef after them all.  This
128373         should fix a problem on VMS reported by John E. Malmberg in
128374         <http://lists.gnu.org/r/bug-gnulib/2007-12/msg00118.html>.
128376 2007-12-17  Eric Blake  <ebb9@byu.net>
128378         Revert addition of verify, for BSD/OS.
128379         * lib/fseeko.c [!HAVE_FSEEKO]: Allow off_t > long, even though it
128380         can't handle large files, for the sake of obsolete platforms.
128381         * modules/fseeko (Depends-on): Remove verify.
128382         * doc/functions/fseeko.texi (fseeko): Document BSD/OS limitation.
128383         * doc/functions/ftello.texi (ftello): Likewise.
128384         * doc/functions/fgetpos.texi (fgetpos): Likewise.
128385         Reported by Larry Jones.
128387 2007-12-17  Petr Salinger  <Petr.Salinger@seznam.cz>
128389         getcwd.c: Use a more readable witness: HAVE_OPENAT_SUPPORT
128390         * lib/getcwd.c: Define and use HAVE_OPENAT_SUPPORT, in place of AT_FDCWD.
128392 2007-12-17  Jim Meyering  <meyering@redhat.com>
128394         Port to GNU/kFreeBSD - FreeBSD kernel + GNU libc,
128395         which has no openat syscall, yet <fcntl.h> does define AT_FDCWD.
128396         * lib/getcwd.c: Undef AT_FDCWD if there is no openat function.
128397         * modules/getcwd (Depends-on): Add openat.
128398         Reported by Petr Salinger.
128400 2007-12-17  Bruno Haible  <bruno@clisp.org>
128402         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Use GL_NOCRASH to
128403         avoid a segmentation fault of the configure test on x86_64 systems.
128405 2007-12-15  Jim Meyering  <meyering@redhat.com>
128407         * build-aux/gnupload (GPG): Don't hard-code absolute name of gpg binary.
128409 2007-12-13  Eric Blake  <ebb9@byu.net>
128411         Another fseek test.
128412         * tests/test-fseek.c (main): Also test ungetc handling.
128413         * tests/test-fseeko.c (main): Likewise.
128414         * modules/fseeko (Depends-on): Add verify.
128415         * lib/fseeko.c [!HAVE_FSEEKO]: Verify that off_t is not too
128416         large.
128417         Reported by Larry Jones.
128419         Fix fseeko on mingw.
128420         * lib/fseeko.c (rpl_fseeko) [_IOERR]: Reset EOF flag on successful
128421         seek.
128423         Beef up fseek tests.
128424         * tests/test-fseek.c (main): Also test eof handling.
128425         * tests/test-fseeko.c (main): Likewise.
128426         Reported by Larry Jones.
128428 2007-12-13  Larry Jones  <lawrence.jones@siemens.com>  (tiny change)
128430         Fix fseeko on BSD-based platforms.
128431         * lib/fseeko.c (rpl_fseeko) [__sferror]: Reset EOF flag on
128432         successful seek.
128434 2007-12-12  Eric Blake  <ebb9@byu.net>
128436         Allow circular dependency of separate libtests.a
128437         * gnulib-tool (func_emit_tests_Makefile_am): Add AM_LIBTOOLFLAGS
128438         when use_libtests.
128440 2007-12-11  Eric Blake  <ebb9@byu.net>
128442         Fix bug with -0.0L in previous patch.
128443         * lib/isnan.c (rpl_isnanl): Make robust to -0.0L and pad bits.
128444         * tests/test-isnan.c (main): Also test on zeroes.
128445         * tests/test-isnanf.c (main): Likewise.
128446         * tests/test-isnanl.h (main): Likewise.
128448         Detect pseudo-denormals on x86 even when cross-compiling.
128449         * lib/isnan.c (rpl_isnanl) [!KNOWN_EXPBIT0_LOCATION
128450         && USE_LONG_DOUBLE && x86]: Add one more check to filter out
128451         invalid bit patterns that happen to satisfy ==.
128453         Avoid link failures with separate libtests.a.
128454         * gnulib-tool (func_emit_tests_Makefile_am): Also list local_ldadd
128455         last, to satisfy circular dependencies.
128457 2007-12-11  Eric Blake  <ebb9@byu.net>
128458         and Bruno Haible  <bruno@clisp.org>
128460         Fix OpenBSD 4.0 <float.h> handling of long double.
128461         * m4/float_h.m4 (gl_FLOAT_H): Also claim OpenBSD is broken.
128462         * lib/float.in.h [__OpenBSD__]: Add fixes for OpenBSD.
128463         * doc/headers/float.texi (float.h): Document OpenBSD bug.
128465 2007-12-11  Jim Meyering  <meyering@redhat.com>
128467         * users.txt: Add libvirt.
128469         Support versions of autoconf prior to 2.59c.
128470         * gnulib-tool (func_emit_initmacro_done): Define m4_foreach_w
128471         if it is not already defined.
128473 2007-12-09  Bruno Haible  <bruno@clisp.org>
128475         Let 'gnulib-tool --import' collect sources needed for the tests in
128476         tests/ rather than in lib/.
128477         * gnulib-tool (func_emit_tests_Makefile_am): Accept use_libtests
128478         argument. If true, add rules to generate libtests.a, and put libtests.a
128479         into $(LDADD). Consider source files in subdirectories and set
128480         uses_subdirs.
128481         (func_emit_initmacro_start, func_emit_initmacro_end,
128482         func_emit_initmacro_done): Pass all arguments explicitly.
128483         (func_import): Determine two module lists main_modules,
128484         testsrelated_modules. Determine use_libtests. Determine two variables
128485         sed_transform_main_lib_file, sed_transform_testsrelated_lib_file
128486         instead of just sed_transform_lib_file. Determine two variables
128487         main_files and testsrelated_files. Compute 'files' as the union of
128488         both. Adjust sed_rewrite_old_files, sed_rewrite_new_files,
128489         func_add_or_update. In the generated gnulib-comp.m4, collect the
128490         object files for tests/ in different variables than those for lib/.
128491         Substitute LIBTESTS_LIBDEPS.
128492         (func_create_testdir): Combine the uses_subdirs results from
128493         func_emit_lib_Makefile_am and from func_emit_tests_Makefile_am.
128495 2007-12-09  Bruno Haible  <bruno@clisp.org>
128497         * gnulib-tool (func_emit_tests_Makefile_am): Expand references to
128498         the build-aux directory.
128500 2007-12-09  Bruno Haible  <bruno@clisp.org>
128502         * gnulib-tool (func_emit_tests_Makefile_am): Remove redundant code
128503         introduced on 2006-09-09.
128505 2007-12-07  Jim Meyering  <meyering@redhat.com>
128507         Let these macros work also with autoconf-2.59.
128508         * m4/getline.m4 (gl_FUNC_GETLINE): Require only autoconf-2.59.  2.60
128509         is not needed, since gnulib now permits use of AC_CHECK_DECLS_ONCE.
128510         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
128512 2007-12-06  Jim Meyering  <meyering@redhat.com>
128514         Avoid a configure-time syntax error in gl_FUNC_ACL.
128515         * m4/acl.m4 (gl_FUNC_ACL): Be careful to check for the acl_trivial
128516         function in each branch, before testing the cache variable.
128518 2007-12-04  Eric Blake  <ebb9@byu.net>
128520         Make scripts executable.
128521         * build-aux/config.guess: Add execute permissions.
128522         * build-aux/config.sub: Likewise.
128523         * build-aux/gendocs.sh: Likewise.
128525         Fix frexp on mingw.
128526         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Detect mingw bug when
128527         cross-compiling.
128528         * doc/functions/frexp.texi (frexp): Document the bug.
128530         Make cygwin fseeko check more reliable.
128531         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Use cygwin
128532         version numbers, rather than unrelated feature check.
128533         * doc/functions/fseeko.texi (fseeko): Tweak failure report.
128534         * doc/functions/ftello.texi (ftello): Likewise.
128535         Reported by Bruno Haible.
128537         * m4/strerror.m4: Bump version number.
128539 2007-12-03  Bruno Haible  <bruno@clisp.org>
128541         * doc/functions/mprotect.texi: Mention the mingw problem.
128543 2007-12-03  Eric Blake  <ebb9@byu.net>
128545         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Ensure
128546         REPLACE_STRERROR is initialized before this macro.
128548 2007-12-03  Paul Eggert  <eggert@cs.ucla.edu>
128550         Add support for Solaris 10 ACLs.  Also, ACLs are Gnulib, not Autoconf.
128551         * modules/acl (configure.ac): Rename AC_FUNC_ACL to gl_FUNC_ACL.
128552         * m4/acl.m4 (gl_FUNC_ACL): Renamed from AC_FUNC_ACL.  On Solaris,
128553         put -lsec in even for programs other than 'ls'.  This fixes a problem
128554         for gettext reported by Bruno Haible in
128555         <http://lists.gnu.org/r/bug-gnulib/2007-12/msg00007.html>.
128556         * lib/acl.c (copy_acl, qset_acl) [USE_ACL && defined ACL_NO_TRIVIAL]:
128557         Add support for Solaris 10.  This isn't efficient, but should get the
128558         job done for now.
128560 2007-12-03  James Youngman  <jay@gnu.org>
128562         * doc/regexprops-generic.texi: change "an close-group" to "a
128563         close-group" and "illegal" to "not allowed".
128565 2007-11-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128567         * lib/unictype/pr_byname.c: Include unictype/pr_byname.h instead of
128568         pr_byname.h. Needed for the rare case when the maintainer has done
128569         "make maintainer-clean" in the source directory and then attempts a
128570         build outside the source directory.
128571         * lib/unictype/scripts.c: Include unictype/scripts_byname.h instead of
128572         scripts_byname.h.
128574 2007-12-02  Martin Lambers  <marlam@marlam.de>
128575             Bruno Haible  <bruno@clisp.org>
128577         * lib/getpagesize.h: Remove file.
128578         * lib/unistd.in.h: Include declaration of getpagesize here.
128579         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Renamed from gl_GETPAGESIZE.
128580         Invoke gl_UNISTD_H_DEFAULTS. Set HAVE_GETPAGESIZE, HAVE_OS_H,
128581         HAVE_SYS_PARAM_H.
128582         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETPAGESIZE,
128583         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
128584         * modules/getpagesize (Files): Remove lib/getpagesize.h.
128585         (Depends-on): Add unistd.
128586         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
128587         (Include): Use <unistd.h> instead of getpagesize.h.
128588         * modules/unistd (Makefile.am): Substitute also GNULIB_GETPAGESIZE,
128589         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
128590         * m4/pagealign_alloc.m4 (gl_PREREQ_PAGEALIGN_ALLOC): Remove
128591         gl_GETPAGESIZE invocation, already handled by module dependency.
128592         * lib/pagealign_alloc.c: Don't include getpagesize.h.
128594 2007-12-02  Bruno Haible  <bruno@clisp.org>
128596         * modules/strings-tests: New file.
128597         * tests/test-strings.c: New file.
128599         Move declarations of str{,n}casecmp from <string.h> to <strings.h>.
128600         * lib/strings.in.h: New file.
128601         * lib/string.in.h (strcasecmp, strncasecmp): Remove declarations.
128602         * m4/strings_h.m4: New file.
128603         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Remove initialization
128604         of HAVE_STRCASECMP, HAVE_DECL_STRNCASECMP.
128605         * modules/strings: New file.
128606         * modules/string (Makefile.am): Update.
128607         * modules/strcase (Include): Mention <strings.h>, not <string.h>.
128608         Reported by Karl Berry.
128610 2007-12-01  Eric Blake  <ebb9@byu.net>
128612         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Rewrite to
128613         accommodate fix in cygwin 1.5.25.
128615 2007-12-01  Jim Meyering  <meyering@redhat.com>
128617         Fix a bug that inhibited much of the utf8-optimization in regcomp.c.
128618         * lib/regcomp.c (optimize_utf8): Fix a typo, s/idx/ctx_type/,
128619         that would inhibit utf8-optimization of a regexp containing line-
128620         or buffer-anchors, e.g., `^', `$'.
128622 2007-11-30  Bruno Haible  <bruno@clisp.org>
128624         * lib/lock.h (gl_recursive_lock_init) [PTHREAD &&
128625         PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Call
128626         glthread_recursive_lock_init.
128627         * lib/lock.c (glthread_recursive_lock_init)
128628         [PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: New function.
128629         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
128631 2007-11-28  Paul Eggert  <eggert@cs.ucla.edu>
128633         New function qset_acl, like set_acl but with syscall semantics.
128634         * lib/acl.h (qset_acl): New decl.
128635         * lib/acl.c (qset_acl): New function.
128636         (set_acl): Use new function.  Use more-consistent diagnostics.
128638 2007-11-28  Jim Meyering  <meyering@redhat.com>
128640         * modules/physmem (License): Change from GPL to LGPLv2+.
128642 2007-11-26  Bruno Haible  <bruno@clisp.org>
128644         * lib/vasnprintf.c (decode_long_double): Don't abort if the
128645         'long double' type has excess precision.
128646         Reported by Jim Meyering in
128647         <http://lists.gnu.org/r/bug-gnulib/2007-11/msg00120.html>.
128649 2007-11-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128651         * doc/fdl.texi, doc/gpl-3.0.texi, doc/lgpl-3.0.texi:
128652         Sync from <http://gnu.org/licenses>.
128653         * modules/agpl-3.0, doc/agpl-3.0.texi: New module,
128654         with license text from same location.
128655         * doc/maintain.texi, doc/standards.texi:  Sync from
128656         <http://savannah.gnu.org/projects/gnustandards>.
128658 2007-11-22  Ondřej Vašík  <ovasik@redhat.com>
128659         and Jim Meyering  <meyering@redhat.com>
128661         Adjust getdate' grammar to accept a slightly more regular language.
128662         E.g., accept "YYYYMMDD +N days" as well as "YYYYMMDD N days".
128663         Before, the former was rejected.
128664         * lib/getdate.y (digits_to_date_time): New function, factored
128665         out of ...
128666         (number): ...here.  Just call digits_to_date_time.
128667         (hybrid): New non-terminal to handle an <unsigned number,
128668         signed relative offset> sequence consistently.
128670 2007-11-18  Jim Meyering  <meyering@redhat.com>
128672         Pull my changes from coreutils:
128673         bootstrap: fix typo to enable use of $gnulib_tool_option_extras.
128674         * build-aux/bootstrap (gnulib_tool_options): Add a space before the
128675         use of $gnulib_tool_option_extras, so that it's separated from the
128676         preceding argument.
128678         Fix bootstrap failure to handle files like lib/uniwidth/cjk.h.
128679         * build-aux/bootstrap (cp_mark_as_generated): Create any required
128680         parent destination directories before copying a file into place.
128682 2007-11-18  Sergey Poznyakoff  <gray@gnu.org.ua>
128684         bootstrap: work also with 4-argument variant of AC_INIT
128685         * build-aux/bootstrap (gnulib_extra_files): Adjust sed command.
128687 2007-11-16  Paul Eggert  <eggert@cs.ucla.edu>
128689         Port test-getaddrinfo to Solaris.
128690         Problem reported by Bruno Haible in
128691         <http://lists.gnu.org/r/bug-gnulib/2007-03/msg00171.html>.
128692         * tests/test-getaddrinfo.c (simple): Add a comment asking for an
128693         explanation of setting 'hints'.
128694         Don't reject an implementation merely because it returns EAI_SERVICE.
128695         (EAI_SERVICE): Define to 0 if not defined.
128697 2007-11-15  Paul Eggert  <eggert@cs.ucla.edu>
128699         The license of gnu-make and posix-shell is now "GPLed build tool".
128700         * modules/gnu-make (License): Likewise.
128701         * modules/posix-shell (License): Likewise.
128703         New module posix-shell, for determining a POSIX shell
128704         or perhaps something that is close enough to a POSIX shell.
128705         * m4/posix-shell.m4: New file.
128706         * modules/posix-shell: New file.
128708         * MODULES.html.sh: Mention new module.
128710         New module gnu-make, for determining whether we're using GNU Make.
128711         * m4/gnu-make.m4: New file.
128712         * modules/gnu-make: New file.
128713         * MODULES.html.sh: Mention new module.
128715 2007-11-14  Jim Meyering  <meyering@redhat.com>
128717         Define a sometimes-link-required function using ARGMATCH_DIE_DECL.
128718         * tests/test-argmatch.c (ARGMATCH_DIE_DECL): When defined,
128719         use this macro to create a function _definition_.
128720         Remove useless "#undef ARGMATCH_DIE".
128722 2007-11-14  Bruno Haible  <bruno@clisp.org>
128724         * lib/config.charset: Update for OpenBSD 4.1.
128725         Reported and helped by Ben Pfaff <blp@cs.stanford.edu>.
128727 2007-11-12  Paul Eggert  <eggert@cs.ucla.edu>
128729         Document 64-bit #if problems in stdint.texi.
128730         * doc/headers/stdint.texi (stdint.h): Mention problems with
128731         64-bit-#if, and how to work around them.
128733         Don't insist on 'long long int' support in the preprocessor.  It
128734         breaks too many things.  For example, PRIdMAX still uses a 'long
128735         long int' format with the latest Sun compiler, even though
128736         HAVE_LONG_LONG_INT isn't defined due to that compiler's
128737         preprocessor problem.  This causes the latest coreutils to dump
128738         core on Solaris 10 sparc with the Sun C compiler.
128739         Instead, fix the 2007-10-16 problem in a different way, by evaluating
128740         the troublesome expressions at configure-time, not at #if-time.
128741         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): Don't test the
128742         preprocessor.
128743         * m4/inttypes.m4 (gl_INTTYPES_H): Move the #if checks into
128744         compile-time C checks, done at 'configure'-time.
128745         (gl_INTTYPES_CHECK_LONG_LONG_INT_CONDITION): New macro.
128746         * modules/inttypes (Makefile): Substitute the new symbols that
128747         gl_INTTYPES_H now generates.
128748         * lib/inttypes.in.h: Don't use constants wider than 'long' in #if.
128750 2007-11-12  Bruno Haible  <bruno@clisp.org>
128752         Tests for Unicode character classification functions.
128754         * modules/unictype/bidicategory-byname-tests: New file.
128755         * modules/unictype/bidicategory-name-tests: New file.
128756         * modules/unictype/bidicategory-of-tests: New file.
128757         * modules/unictype/bidicategory-test-tests: New file.
128758         * modules/unictype/block-list-tests: New file.
128759         * modules/unictype/block-of-tests: New file.
128760         * modules/unictype/block-test-tests: New file.
128761         * modules/unictype/category-C-tests: New file.
128762         * modules/unictype/category-Cc-tests: New file.
128763         * modules/unictype/category-Cf-tests: New file.
128764         * modules/unictype/category-Cn-tests: New file.
128765         * modules/unictype/category-Co-tests: New file.
128766         * modules/unictype/category-Cs-tests: New file.
128767         * modules/unictype/category-L-tests: New file.
128768         * modules/unictype/category-Ll-tests: New file.
128769         * modules/unictype/category-Lm-tests: New file.
128770         * modules/unictype/category-Lo-tests: New file.
128771         * modules/unictype/category-Lt-tests: New file.
128772         * modules/unictype/category-Lu-tests: New file.
128773         * modules/unictype/category-M-tests: New file.
128774         * modules/unictype/category-Mc-tests: New file.
128775         * modules/unictype/category-Me-tests: New file.
128776         * modules/unictype/category-Mn-tests: New file.
128777         * modules/unictype/category-N-tests: New file.
128778         * modules/unictype/category-Nd-tests: New file.
128779         * modules/unictype/category-Nl-tests: New file.
128780         * modules/unictype/category-No-tests: New file.
128781         * modules/unictype/category-P-tests: New file.
128782         * modules/unictype/category-Pc-tests: New file.
128783         * modules/unictype/category-Pd-tests: New file.
128784         * modules/unictype/category-Pe-tests: New file.
128785         * modules/unictype/category-Pf-tests: New file.
128786         * modules/unictype/category-Pi-tests: New file.
128787         * modules/unictype/category-Po-tests: New file.
128788         * modules/unictype/category-Ps-tests: New file.
128789         * modules/unictype/category-S-tests: New file.
128790         * modules/unictype/category-Sc-tests: New file.
128791         * modules/unictype/category-Sk-tests: New file.
128792         * modules/unictype/category-Sm-tests: New file.
128793         * modules/unictype/category-So-tests: New file.
128794         * modules/unictype/category-Z-tests: New file.
128795         * modules/unictype/category-Zl-tests: New file.
128796         * modules/unictype/category-Zp-tests: New file.
128797         * modules/unictype/category-Zs-tests: New file.
128798         * modules/unictype/category-and-not-tests: New file.
128799         * modules/unictype/category-and-tests: New file.
128800         * modules/unictype/category-byname-tests: New file.
128801         * modules/unictype/category-name-tests: New file.
128802         * modules/unictype/category-none-tests: New file.
128803         * modules/unictype/category-of-tests: New file.
128804         * modules/unictype/category-or-tests: New file.
128805         * modules/unictype/category-test-withtable-tests: New file.
128806         * modules/unictype/combining-class-tests: New file.
128807         * modules/unictype/ctype-alnum-tests: New file.
128808         * modules/unictype/ctype-alpha-tests: New file.
128809         * modules/unictype/ctype-blank-tests: New file.
128810         * modules/unictype/ctype-cntrl-tests: New file.
128811         * modules/unictype/ctype-digit-tests: New file.
128812         * modules/unictype/ctype-graph-tests: New file.
128813         * modules/unictype/ctype-lower-tests: New file.
128814         * modules/unictype/ctype-print-tests: New file.
128815         * modules/unictype/ctype-punct-tests: New file.
128816         * modules/unictype/ctype-space-tests: New file.
128817         * modules/unictype/ctype-upper-tests: New file.
128818         * modules/unictype/ctype-xdigit-tests: New file.
128819         * modules/unictype/decimal-digit-tests: New file.
128820         * modules/unictype/digit-tests: New file.
128821         * modules/unictype/mirror-tests: New file.
128822         * modules/unictype/numeric-tests: New file.
128823         * modules/unictype/property-alphabetic-tests: New file.
128824         * modules/unictype/property-ascii-hex-digit-tests: New file.
128825         * modules/unictype/property-bidi-arabic-digit-tests: New file.
128826         * modules/unictype/property-bidi-arabic-right-to-left-tests: New file.
128827         * modules/unictype/property-bidi-block-separator-tests: New file.
128828         * modules/unictype/property-bidi-boundary-neutral-tests: New file.
128829         * modules/unictype/property-bidi-common-separator-tests: New file.
128830         * modules/unictype/property-bidi-control-tests: New file.
128831         * modules/unictype/property-bidi-embedding-or-override-tests: New file.
128832         * modules/unictype/property-bidi-eur-num-separator-tests: New file.
128833         * modules/unictype/property-bidi-eur-num-terminator-tests: New file.
128834         * modules/unictype/property-bidi-european-digit-tests: New file.
128835         * modules/unictype/property-bidi-hebrew-right-to-left-tests: New file.
128836         * modules/unictype/property-bidi-left-to-right-tests: New file.
128837         * modules/unictype/property-bidi-non-spacing-mark-tests: New file.
128838         * modules/unictype/property-bidi-other-neutral-tests: New file.
128839         * modules/unictype/property-bidi-pdf-tests: New file.
128840         * modules/unictype/property-bidi-segment-separator-tests: New file.
128841         * modules/unictype/property-bidi-whitespace-tests: New file.
128842         * modules/unictype/property-byname-tests: New file.
128843         * modules/unictype/property-combining-tests: New file.
128844         * modules/unictype/property-composite-tests: New file.
128845         * modules/unictype/property-currency-symbol-tests: New file.
128846         * modules/unictype/property-dash-tests: New file.
128847         * modules/unictype/property-decimal-digit-tests: New file.
128848         * modules/unictype/property-default-ignorable-code-point-tests: New file.
128849         * modules/unictype/property-deprecated-tests: New file.
128850         * modules/unictype/property-diacritic-tests: New file.
128851         * modules/unictype/property-extender-tests: New file.
128852         * modules/unictype/property-format-control-tests: New file.
128853         * modules/unictype/property-grapheme-base-tests: New file.
128854         * modules/unictype/property-grapheme-extend-tests: New file.
128855         * modules/unictype/property-grapheme-link-tests: New file.
128856         * modules/unictype/property-hex-digit-tests: New file.
128857         * modules/unictype/property-hyphen-tests: New file.
128858         * modules/unictype/property-id-continue-tests: New file.
128859         * modules/unictype/property-id-start-tests: New file.
128860         * modules/unictype/property-ideographic-tests: New file.
128861         * modules/unictype/property-ids-binary-operator-tests: New file.
128862         * modules/unictype/property-ids-trinary-operator-tests: New file.
128863         * modules/unictype/property-ignorable-control-tests: New file.
128864         * modules/unictype/property-iso-control-tests: New file.
128865         * modules/unictype/property-join-control-tests: New file.
128866         * modules/unictype/property-left-of-pair-tests: New file.
128867         * modules/unictype/property-line-separator-tests: New file.
128868         * modules/unictype/property-logical-order-exception-tests: New file.
128869         * modules/unictype/property-lowercase-tests: New file.
128870         * modules/unictype/property-math-tests: New file.
128871         * modules/unictype/property-non-break-tests: New file.
128872         * modules/unictype/property-not-a-character-tests: New file.
128873         * modules/unictype/property-numeric-tests: New file.
128874         * modules/unictype/property-other-alphabetic-tests: New file.
128875         * modules/unictype/property-other-default-ignorable-code-point-tests: New file.
128876         * modules/unictype/property-other-grapheme-extend-tests: New file.
128877         * modules/unictype/property-other-id-continue-tests: New file.
128878         * modules/unictype/property-other-id-start-tests: New file.
128879         * modules/unictype/property-other-lowercase-tests: New file.
128880         * modules/unictype/property-other-math-tests: New file.
128881         * modules/unictype/property-other-uppercase-tests: New file.
128882         * modules/unictype/property-paired-punctuation-tests: New file.
128883         * modules/unictype/property-paragraph-separator-tests: New file.
128884         * modules/unictype/property-pattern-syntax-tests: New file.
128885         * modules/unictype/property-pattern-white-space-tests: New file.
128886         * modules/unictype/property-private-use-tests: New file.
128887         * modules/unictype/property-punctuation-tests: New file.
128888         * modules/unictype/property-quotation-mark-tests: New file.
128889         * modules/unictype/property-radical-tests: New file.
128890         * modules/unictype/property-sentence-terminal-tests: New file.
128891         * modules/unictype/property-soft-dotted-tests: New file.
128892         * modules/unictype/property-space-tests: New file.
128893         * modules/unictype/property-terminal-punctuation-tests: New file.
128894         * modules/unictype/property-test-tests: New file.
128895         * modules/unictype/property-titlecase-tests: New file.
128896         * modules/unictype/property-unassigned-code-value-tests: New file.
128897         * modules/unictype/property-unified-ideograph-tests: New file.
128898         * modules/unictype/property-uppercase-tests: New file.
128899         * modules/unictype/property-variation-selector-tests: New file.
128900         * modules/unictype/property-white-space-tests: New file.
128901         * modules/unictype/property-xid-continue-tests: New file.
128902         * modules/unictype/property-xid-start-tests: New file.
128903         * modules/unictype/property-zero-width-tests: New file.
128904         * modules/unictype/scripts-tests: New file.
128905         * modules/unictype/syntax-c-ident-tests: New file.
128906         * modules/unictype/syntax-c-whitespace-tests: New file.
128907         * modules/unictype/syntax-java-ident-tests: New file.
128908         * modules/unictype/syntax-java-whitespace-tests: New file.
128909         * tests/unictype/test-bidi_byname.c: New file.
128910         * tests/unictype/test-bidi_name.c: New file.
128911         * tests/unictype/test-bidi_of.c: New file.
128912         * tests/unictype/test-bidi_test.c: New file.
128913         * tests/unictype/test-block_list.c: New file.
128914         * tests/unictype/test-block_of.c: New file.
128915         * tests/unictype/test-block_test.c: New file.
128916         * tests/unictype/test-categ_and.c: New file.
128917         * tests/unictype/test-categ_and_not.c: New file.
128918         * tests/unictype/test-categ_byname.c: New file.
128919         * tests/unictype/test-categ_name.c: New file.
128920         * tests/unictype/test-categ_none.c: New file.
128921         * tests/unictype/test-categ_of.c: New file.
128922         * tests/unictype/test-categ_or.c: New file.
128923         * tests/unictype/test-categ_test_withtable.c: New file.
128924         * tests/unictype/test-combining.c: New file.
128925         * tests/unictype/test-decdigit.c: New file.
128926         * tests/unictype/test-digit.c: New file.
128927         * tests/unictype/test-mirror.c: New file.
128928         * tests/unictype/test-numeric.c: New file.
128929         * tests/unictype/test-pr_byname.c: New file.
128930         * tests/unictype/test-pr_test.c: New file.
128931         * tests/unictype/test-predicate-part1.h: New file.
128932         * tests/unictype/test-predicate-part2.h: New file.
128933         * tests/unictype/test-scripts.c: New file.
128934         * tests/unictype/test-sy_c_ident.c: New file.
128935         * tests/unictype/test-sy_java_ident.c: New file.
128937         * tests/unictype/test-categ_C.c: New file, generated by gen-ctype.c
128938         for Unicode 5.0.0.
128939         * tests/unictype/test-categ_Cc.c: Likewise.
128940         * tests/unictype/test-categ_Cf.c: Likewise.
128941         * tests/unictype/test-categ_Cn.c: Likewise.
128942         * tests/unictype/test-categ_Co.c: Likewise.
128943         * tests/unictype/test-categ_Cs.c: Likewise.
128944         * tests/unictype/test-categ_L.c: Likewise.
128945         * tests/unictype/test-categ_Ll.c: Likewise.
128946         * tests/unictype/test-categ_Lm.c: Likewise.
128947         * tests/unictype/test-categ_Lo.c: Likewise.
128948         * tests/unictype/test-categ_Lt.c: Likewise.
128949         * tests/unictype/test-categ_Lu.c: Likewise.
128950         * tests/unictype/test-categ_M.c: Likewise.
128951         * tests/unictype/test-categ_Mc.c: Likewise.
128952         * tests/unictype/test-categ_Me.c: Likewise.
128953         * tests/unictype/test-categ_Mn.c: Likewise.
128954         * tests/unictype/test-categ_N.c: Likewise.
128955         * tests/unictype/test-categ_Nd.c: Likewise.
128956         * tests/unictype/test-categ_Nl.c: Likewise.
128957         * tests/unictype/test-categ_No.c: Likewise.
128958         * tests/unictype/test-categ_P.c: Likewise.
128959         * tests/unictype/test-categ_Pc.c: Likewise.
128960         * tests/unictype/test-categ_Pd.c: Likewise.
128961         * tests/unictype/test-categ_Pe.c: Likewise.
128962         * tests/unictype/test-categ_Pf.c: Likewise.
128963         * tests/unictype/test-categ_Pi.c: Likewise.
128964         * tests/unictype/test-categ_Po.c: Likewise.
128965         * tests/unictype/test-categ_Ps.c: Likewise.
128966         * tests/unictype/test-categ_S.c: Likewise.
128967         * tests/unictype/test-categ_Sc.c: Likewise.
128968         * tests/unictype/test-categ_Sk.c: Likewise.
128969         * tests/unictype/test-categ_Sm.c: Likewise.
128970         * tests/unictype/test-categ_So.c: Likewise.
128971         * tests/unictype/test-categ_Z.c: Likewise.
128972         * tests/unictype/test-categ_Zl.c: Likewise.
128973         * tests/unictype/test-categ_Zp.c: Likewise.
128974         * tests/unictype/test-categ_Zs.c: Likewise.
128975         * tests/unictype/test-ctype_alnum.c: Likewise.
128976         * tests/unictype/test-ctype_alpha.c: Likewise.
128977         * tests/unictype/test-ctype_blank.c: Likewise.
128978         * tests/unictype/test-ctype_cntrl.c: Likewise.
128979         * tests/unictype/test-ctype_digit.c: Likewise.
128980         * tests/unictype/test-ctype_graph.c: Likewise.
128981         * tests/unictype/test-ctype_lower.c: Likewise.
128982         * tests/unictype/test-ctype_print.c: Likewise.
128983         * tests/unictype/test-ctype_punct.c: Likewise.
128984         * tests/unictype/test-ctype_space.c: Likewise.
128985         * tests/unictype/test-ctype_upper.c: Likewise.
128986         * tests/unictype/test-ctype_xdigit.c: Likewise.
128987         * tests/unictype/test-decdigit.h: Likewise.
128988         * tests/unictype/test-digit.h: Likewise.
128989         * tests/unictype/test-numeric.h: Likewise.
128990         * tests/unictype/test-pr_alphabetic.c: Likewise.
128991         * tests/unictype/test-pr_ascii_hex_digit.c: Likewise.
128992         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
128993         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Likewise.
128994         * tests/unictype/test-pr_bidi_block_separator.c: Likewise.
128995         * tests/unictype/test-pr_bidi_boundary_neutral.c: Likewise.
128996         * tests/unictype/test-pr_bidi_common_separator.c: Likewise.
128997         * tests/unictype/test-pr_bidi_control.c: Likewise.
128998         * tests/unictype/test-pr_bidi_embedding_or_override.c: Likewise.
128999         * tests/unictype/test-pr_bidi_eur_num_separator.c: Likewise.
129000         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
129001         * tests/unictype/test-pr_bidi_european_digit.c: Likewise.
129002         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
129003         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
129004         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
129005         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
129006         * tests/unictype/test-pr_bidi_pdf.c: Likewise.
129007         * tests/unictype/test-pr_bidi_segment_separator.c: Likewise.
129008         * tests/unictype/test-pr_bidi_whitespace.c: Likewise.
129009         * tests/unictype/test-pr_combining.c: Likewise.
129010         * tests/unictype/test-pr_composite.c: Likewise.
129011         * tests/unictype/test-pr_currency_symbol.c: Likewise.
129012         * tests/unictype/test-pr_dash.c: Likewise.
129013         * tests/unictype/test-pr_decimal_digit.c: Likewise.
129014         * tests/unictype/test-pr_default_ignorable_code_point.c: Likewise.
129015         * tests/unictype/test-pr_deprecated.c: Likewise.
129016         * tests/unictype/test-pr_diacritic.c: Likewise.
129017         * tests/unictype/test-pr_extender.c: Likewise.
129018         * tests/unictype/test-pr_format_control.c: Likewise.
129019         * tests/unictype/test-pr_grapheme_base.c: Likewise.
129020         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
129021         * tests/unictype/test-pr_grapheme_link.c: Likewise.
129022         * tests/unictype/test-pr_hex_digit.c: Likewise.
129023         * tests/unictype/test-pr_hyphen.c: Likewise.
129024         * tests/unictype/test-pr_id_continue.c: Likewise.
129025         * tests/unictype/test-pr_id_start.c: Likewise.
129026         * tests/unictype/test-pr_ideographic.c: Likewise.
129027         * tests/unictype/test-pr_ids_binary_operator.c: Likewise.
129028         * tests/unictype/test-pr_ids_trinary_operator.c: Likewise.
129029         * tests/unictype/test-pr_ignorable_control.c: Likewise.
129030         * tests/unictype/test-pr_iso_control.c: Likewise.
129031         * tests/unictype/test-pr_join_control.c: Likewise.
129032         * tests/unictype/test-pr_left_of_pair.c: Likewise.
129033         * tests/unictype/test-pr_line_separator.c: Likewise.
129034         * tests/unictype/test-pr_logical_order_exception.c: Likewise.
129035         * tests/unictype/test-pr_lowercase.c: Likewise.
129036         * tests/unictype/test-pr_math.c: Likewise.
129037         * tests/unictype/test-pr_non_break.c: Likewise.
129038         * tests/unictype/test-pr_not_a_character.c: Likewise.
129039         * tests/unictype/test-pr_numeric.c: Likewise.
129040         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
129041         * tests/unictype/test-pr_other_default_ignorable_code_point.c: Likewise.
129042         * tests/unictype/test-pr_other_grapheme_extend.c: Likewise.
129043         * tests/unictype/test-pr_other_id_continue.c: Likewise.
129044         * tests/unictype/test-pr_other_id_start.c: Likewise.
129045         * tests/unictype/test-pr_other_lowercase.c: Likewise.
129046         * tests/unictype/test-pr_other_math.c: Likewise.
129047         * tests/unictype/test-pr_other_uppercase.c: Likewise.
129048         * tests/unictype/test-pr_paired_punctuation.c: Likewise.
129049         * tests/unictype/test-pr_paragraph_separator.c: Likewise.
129050         * tests/unictype/test-pr_pattern_syntax.c: Likewise.
129051         * tests/unictype/test-pr_pattern_white_space.c: Likewise.
129052         * tests/unictype/test-pr_private_use.c: Likewise.
129053         * tests/unictype/test-pr_punctuation.c: Likewise.
129054         * tests/unictype/test-pr_quotation_mark.c: Likewise.
129055         * tests/unictype/test-pr_radical.c: Likewise.
129056         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
129057         * tests/unictype/test-pr_soft_dotted.c: Likewise.
129058         * tests/unictype/test-pr_space.c: Likewise.
129059         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
129060         * tests/unictype/test-pr_titlecase.c: Likewise.
129061         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
129062         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
129063         * tests/unictype/test-pr_uppercase.c: Likewise.
129064         * tests/unictype/test-pr_variation_selector.c: Likewise.
129065         * tests/unictype/test-pr_white_space.c: Likewise.
129066         * tests/unictype/test-pr_xid_continue.c: Likewise.
129067         * tests/unictype/test-pr_xid_start.c: Likewise.
129068         * tests/unictype/test-pr_zero_width.c: Likewise.
129069         * tests/unictype/test-sy_c_whitespace.c: Likewise.
129070         * tests/unictype/test-sy_java_whitespace.c: Likewise.
129072 2007-11-12  Bruno Haible  <bruno@clisp.org>
129074         Unicode character classification functions.
129075         * lib/unictype.h: New file.
129076         * modules/unictype/base: New file.
129077         * modules/unictype/category-L: New file.
129078         * modules/unictype/category-Lu: New file.
129079         * modules/unictype/category-Ll: New file.
129080         * modules/unictype/category-Lt: New file.
129081         * modules/unictype/category-Lm: New file.
129082         * modules/unictype/category-Lo: New file.
129083         * modules/unictype/category-M: New file.
129084         * modules/unictype/category-Mn: New file.
129085         * modules/unictype/category-Mc: New file.
129086         * modules/unictype/category-Me: New file.
129087         * modules/unictype/category-N: New file.
129088         * modules/unictype/category-Nd: New file.
129089         * modules/unictype/category-Nl: New file.
129090         * modules/unictype/category-No: New file.
129091         * modules/unictype/category-P: New file.
129092         * modules/unictype/category-Pc: New file.
129093         * modules/unictype/category-Pd: New file.
129094         * modules/unictype/category-Ps: New file.
129095         * modules/unictype/category-Pe: New file.
129096         * modules/unictype/category-Pi: New file.
129097         * modules/unictype/category-Pf: New file.
129098         * modules/unictype/category-Po: New file.
129099         * modules/unictype/category-S: New file.
129100         * modules/unictype/category-Sm: New file.
129101         * modules/unictype/category-Sc: New file.
129102         * modules/unictype/category-Sk: New file.
129103         * modules/unictype/category-So: New file.
129104         * modules/unictype/category-Z: New file.
129105         * modules/unictype/category-Zs: New file.
129106         * modules/unictype/category-Zl: New file.
129107         * modules/unictype/category-Zp: New file.
129108         * modules/unictype/category-C: New file.
129109         * modules/unictype/category-Cc: New file.
129110         * modules/unictype/category-Cf: New file.
129111         * modules/unictype/category-Cs: New file.
129112         * modules/unictype/category-Co: New file.
129113         * modules/unictype/category-Cn: New file.
129114         * modules/unictype/category-or: New file.
129115         * modules/unictype/category-of: New file.
129116         * modules/unictype/category-test: New file.
129117         * modules/unictype/category-test-withtable: New file.
129118         * modules/unictype/category-byname: New file.
129119         * modules/unictype/category-none: New file.
129120         * modules/unictype/category-and: New file.
129121         * modules/unictype/category-and-not: New file.
129122         * modules/unictype/category-name: New file.
129123         * modules/unictype/combining-class: New file.
129124         * modules/unictype/category-all: New file.
129125         * modules/unictype/bidicategory-all: New file.
129126         * modules/unictype/bidicategory-byname: New file.
129127         * modules/unictype/bidicategory-name: New file.
129128         * modules/unictype/bidicategory-of: New file.
129129         * modules/unictype/bidicategory-test: New file.
129130         * modules/unictype/decimal-digit: New file.
129131         * modules/unictype/digit: New file.
129132         * modules/unictype/numeric: New file.
129133         * modules/unictype/mirror: New file.
129134         * modules/unictype/property-white-space: New file.
129135         * modules/unictype/property-alphabetic: New file.
129136         * modules/unictype/property-other-alphabetic: New file.
129137         * modules/unictype/property-not-a-character: New file.
129138         * modules/unictype/property-default-ignorable-code-point: New file.
129139         * modules/unictype/property-other-default-ignorable-code-point: New
129140         file.
129141         * modules/unictype/property-deprecated: New file.
129142         * modules/unictype/property-logical-order-exception: New file.
129143         * modules/unictype/property-variation-selector: New file.
129144         * modules/unictype/property-private-use: New file.
129145         * modules/unictype/property-unassigned-code-value: New file.
129146         * modules/unictype/property-uppercase: New file.
129147         * modules/unictype/property-other-uppercase: New file.
129148         * modules/unictype/property-lowercase: New file.
129149         * modules/unictype/property-other-lowercase: New file.
129150         * modules/unictype/property-titlecase: New file.
129151         * modules/unictype/property-soft-dotted: New file.
129152         * modules/unictype/property-id-start: New file.
129153         * modules/unictype/property-other-id-start: New file.
129154         * modules/unictype/property-id-continue: New file.
129155         * modules/unictype/property-other-id-continue: New file.
129156         * modules/unictype/property-xid-start: New file.
129157         * modules/unictype/property-xid-continue: New file.
129158         * modules/unictype/property-pattern-white-space: New file.
129159         * modules/unictype/property-pattern-syntax: New file.
129160         * modules/unictype/property-join-control: New file.
129161         * modules/unictype/property-grapheme-base: New file.
129162         * modules/unictype/property-grapheme-extend: New file.
129163         * modules/unictype/property-other-grapheme-extend: New file.
129164         * modules/unictype/property-grapheme-link: New file.
129165         * modules/unictype/property-bidi-control: New file.
129166         * modules/unictype/property-bidi-left-to-right: New file.
129167         * modules/unictype/property-bidi-hebrew-right-to-left: New file.
129168         * modules/unictype/property-bidi-arabic-right-to-left: New file.
129169         * modules/unictype/property-bidi-european-digit: New file.
129170         * modules/unictype/property-bidi-eur-num-separator: New file.
129171         * modules/unictype/property-bidi-eur-num-terminator: New file.
129172         * modules/unictype/property-bidi-arabic-digit: New file.
129173         * modules/unictype/property-bidi-common-separator: New file.
129174         * modules/unictype/property-bidi-block-separator: New file.
129175         * modules/unictype/property-bidi-segment-separator: New file.
129176         * modules/unictype/property-bidi-whitespace: New file.
129177         * modules/unictype/property-bidi-non-spacing-mark: New file.
129178         * modules/unictype/property-bidi-boundary-neutral: New file.
129179         * modules/unictype/property-bidi-pdf: New file.
129180         * modules/unictype/property-bidi-embedding-or-override: New file.
129181         * modules/unictype/property-bidi-other-neutral: New file.
129182         * modules/unictype/property-hex-digit: New file.
129183         * modules/unictype/property-ascii-hex-digit: New file.
129184         * modules/unictype/property-ideographic: New file.
129185         * modules/unictype/property-unified-ideograph: New file.
129186         * modules/unictype/property-radical: New file.
129187         * modules/unictype/property-ids-binary-operator: New file.
129188         * modules/unictype/property-ids-trinary-operator: New file.
129189         * modules/unictype/property-zero-width: New file.
129190         * modules/unictype/property-space: New file.
129191         * modules/unictype/property-non-break: New file.
129192         * modules/unictype/property-iso-control: New file.
129193         * modules/unictype/property-format-control: New file.
129194         * modules/unictype/property-dash: New file.
129195         * modules/unictype/property-hyphen: New file.
129196         * modules/unictype/property-punctuation: New file.
129197         * modules/unictype/property-line-separator: New file.
129198         * modules/unictype/property-paragraph-separator: New file.
129199         * modules/unictype/property-quotation-mark: New file.
129200         * modules/unictype/property-sentence-terminal: New file.
129201         * modules/unictype/property-terminal-punctuation: New file.
129202         * modules/unictype/property-currency-symbol: New file.
129203         * modules/unictype/property-math: New file.
129204         * modules/unictype/property-other-math: New file.
129205         * modules/unictype/property-paired-punctuation: New file.
129206         * modules/unictype/property-left-of-pair: New file.
129207         * modules/unictype/property-combining: New file.
129208         * modules/unictype/property-composite: New file.
129209         * modules/unictype/property-decimal-digit: New file.
129210         * modules/unictype/property-numeric: New file.
129211         * modules/unictype/property-diacritic: New file.
129212         * modules/unictype/property-extender: New file.
129213         * modules/unictype/property-ignorable-control: New file.
129214         * modules/unictype/property-test: New file.
129215         * modules/unictype/property-byname: New file.
129216         * modules/unictype/property-all: New file.
129217         * modules/unictype/scripts: New file.
129218         * modules/unictype/scripts-all: New file.
129219         * modules/unictype/block-of: New file.
129220         * modules/unictype/block-test: New file.
129221         * modules/unictype/block-list: New file.
129222         * modules/unictype/block-all: New file.
129223         * modules/unictype/syntax-c-whitespace: New file.
129224         * modules/unictype/syntax-java-whitespace: New file.
129225         * modules/unictype/syntax-c-ident: New file.
129226         * modules/unictype/syntax-java-ident: New file.
129227         * modules/unictype/ctype-alnum: New file.
129228         * modules/unictype/ctype-alpha: New file.
129229         * modules/unictype/ctype-cntrl: New file.
129230         * modules/unictype/ctype-digit: New file.
129231         * modules/unictype/ctype-graph: New file.
129232         * modules/unictype/ctype-lower: New file.
129233         * modules/unictype/ctype-print: New file.
129234         * modules/unictype/ctype-punct: New file.
129235         * modules/unictype/ctype-space: New file.
129236         * modules/unictype/ctype-upper: New file.
129237         * modules/unictype/ctype-xdigit: New file.
129238         * modules/unictype/ctype-blank: New file.
129239         * lib/unictype/bidi_byname.c: New file.
129240         * lib/unictype/bidi_name.c: New file.
129241         * lib/unictype/bidi_of.c: New file.
129242         * lib/unictype/bidi_test.c: New file.
129243         * lib/unictype/bitmap.h: New file.
129244         * lib/unictype/block_test.c: New file.
129245         * lib/unictype/blocks.c: New file.
129246         * lib/unictype/categ_C.c: New file.
129247         * lib/unictype/categ_Cc.c: New file.
129248         * lib/unictype/categ_Cf.c: New file.
129249         * lib/unictype/categ_Cn.c: New file.
129250         * lib/unictype/categ_Co.c: New file.
129251         * lib/unictype/categ_Cs.c: New file.
129252         * lib/unictype/categ_L.c: New file.
129253         * lib/unictype/categ_Ll.c: New file.
129254         * lib/unictype/categ_Lm.c: New file.
129255         * lib/unictype/categ_Lo.c: New file.
129256         * lib/unictype/categ_Lt.c: New file.
129257         * lib/unictype/categ_Lu.c: New file.
129258         * lib/unictype/categ_M.c: New file.
129259         * lib/unictype/categ_Mc.c: New file.
129260         * lib/unictype/categ_Me.c: New file.
129261         * lib/unictype/categ_Mn.c: New file.
129262         * lib/unictype/categ_N.c: New file.
129263         * lib/unictype/categ_Nd.c: New file.
129264         * lib/unictype/categ_Nl.c: New file.
129265         * lib/unictype/categ_No.c: New file.
129266         * lib/unictype/categ_P.c: New file.
129267         * lib/unictype/categ_Pc.c: New file.
129268         * lib/unictype/categ_Pd.c: New file.
129269         * lib/unictype/categ_Pe.c: New file.
129270         * lib/unictype/categ_Pf.c: New file.
129271         * lib/unictype/categ_Pi.c: New file.
129272         * lib/unictype/categ_Po.c: New file.
129273         * lib/unictype/categ_Ps.c: New file.
129274         * lib/unictype/categ_S.c: New file.
129275         * lib/unictype/categ_Sc.c: New file.
129276         * lib/unictype/categ_Sk.c: New file.
129277         * lib/unictype/categ_Sm.c: New file.
129278         * lib/unictype/categ_So.c: New file.
129279         * lib/unictype/categ_Z.c: New file.
129280         * lib/unictype/categ_Zl.c: New file.
129281         * lib/unictype/categ_Zp.c: New file.
129282         * lib/unictype/categ_Zs.c: New file.
129283         * lib/unictype/categ_and.c: New file.
129284         * lib/unictype/categ_and_not.c: New file.
129285         * lib/unictype/categ_byname.c: New file.
129286         * lib/unictype/categ_name.c: New file.
129287         * lib/unictype/categ_none.c: New file.
129288         * lib/unictype/categ_of.c: New file.
129289         * lib/unictype/categ_or.c: New file.
129290         * lib/unictype/categ_test.c: New file.
129291         * lib/unictype/combining.c: New file.
129292         * lib/unictype/ctype_alnum.c: New file.
129293         * lib/unictype/ctype_alpha.c: New file.
129294         * lib/unictype/ctype_blank.c: New file.
129295         * lib/unictype/ctype_cntrl.c: New file.
129296         * lib/unictype/ctype_digit.c: New file.
129297         * lib/unictype/ctype_graph.c: New file.
129298         * lib/unictype/ctype_lower.c: New file.
129299         * lib/unictype/ctype_print.c: New file.
129300         * lib/unictype/ctype_punct.c: New file.
129301         * lib/unictype/ctype_space.c: New file.
129302         * lib/unictype/ctype_upper.c: New file.
129303         * lib/unictype/ctype_xdigit.c: New file.
129304         * lib/unictype/decdigit.c: New file.
129305         * lib/unictype/digit.c: New file.
129306         * lib/unictype/identsyntaxmap.h: New file.
129307         * lib/unictype/mirror.c: New file.
129308         * lib/unictype/numeric.c: New file.
129309         * lib/unictype/pr_alphabetic.c: New file.
129310         * lib/unictype/pr_ascii_hex_digit.c: New file.
129311         * lib/unictype/pr_bidi_arabic_digit.c: New file.
129312         * lib/unictype/pr_bidi_arabic_right_to_left.c: New file.
129313         * lib/unictype/pr_bidi_block_separator.c: New file.
129314         * lib/unictype/pr_bidi_boundary_neutral.c: New file.
129315         * lib/unictype/pr_bidi_common_separator.c: New file.
129316         * lib/unictype/pr_bidi_control.c: New file.
129317         * lib/unictype/pr_bidi_embedding_or_override.c: New file.
129318         * lib/unictype/pr_bidi_eur_num_separator.c: New file.
129319         * lib/unictype/pr_bidi_eur_num_terminator.c: New file.
129320         * lib/unictype/pr_bidi_european_digit.c: New file.
129321         * lib/unictype/pr_bidi_hebrew_right_to_left.c: New file.
129322         * lib/unictype/pr_bidi_left_to_right.c: New file.
129323         * lib/unictype/pr_bidi_non_spacing_mark.c: New file.
129324         * lib/unictype/pr_bidi_other_neutral.c: New file.
129325         * lib/unictype/pr_bidi_pdf.c: New file.
129326         * lib/unictype/pr_bidi_segment_separator.c: New file.
129327         * lib/unictype/pr_bidi_whitespace.c: New file.
129328         * lib/unictype/pr_byname.c: New file.
129329         * lib/unictype/pr_byname.gperf: New file.
129330         * lib/unictype/pr_combining.c: New file.
129331         * lib/unictype/pr_composite.c: New file.
129332         * lib/unictype/pr_currency_symbol.c: New file.
129333         * lib/unictype/pr_dash.c: New file.
129334         * lib/unictype/pr_decimal_digit.c: New file.
129335         * lib/unictype/pr_default_ignorable_code_point.c: New file.
129336         * lib/unictype/pr_deprecated.c: New file.
129337         * lib/unictype/pr_diacritic.c: New file.
129338         * lib/unictype/pr_extender.c: New file.
129339         * lib/unictype/pr_format_control.c: New file.
129340         * lib/unictype/pr_grapheme_base.c: New file.
129341         * lib/unictype/pr_grapheme_extend.c: New file.
129342         * lib/unictype/pr_grapheme_link.c: New file.
129343         * lib/unictype/pr_hex_digit.c: New file.
129344         * lib/unictype/pr_hyphen.c: New file.
129345         * lib/unictype/pr_id_continue.c: New file.
129346         * lib/unictype/pr_id_start.c: New file.
129347         * lib/unictype/pr_ideographic.c: New file.
129348         * lib/unictype/pr_ids_binary_operator.c: New file.
129349         * lib/unictype/pr_ids_trinary_operator.c: New file.
129350         * lib/unictype/pr_ignorable_control.c: New file.
129351         * lib/unictype/pr_iso_control.c: New file.
129352         * lib/unictype/pr_join_control.c: New file.
129353         * lib/unictype/pr_left_of_pair.c: New file.
129354         * lib/unictype/pr_line_separator.c: New file.
129355         * lib/unictype/pr_logical_order_exception.c: New file.
129356         * lib/unictype/pr_lowercase.c: New file.
129357         * lib/unictype/pr_math.c: New file.
129358         * lib/unictype/pr_non_break.c: New file.
129359         * lib/unictype/pr_not_a_character.c: New file.
129360         * lib/unictype/pr_numeric.c: New file.
129361         * lib/unictype/pr_other_alphabetic.c: New file.
129362         * lib/unictype/pr_other_default_ignorable_code_point.c: New file.
129363         * lib/unictype/pr_other_grapheme_extend.c: New file.
129364         * lib/unictype/pr_other_id_continue.c: New file.
129365         * lib/unictype/pr_other_id_start.c: New file.
129366         * lib/unictype/pr_other_lowercase.c: New file.
129367         * lib/unictype/pr_other_math.c: New file.
129368         * lib/unictype/pr_other_uppercase.c: New file.
129369         * lib/unictype/pr_paired_punctuation.c: New file.
129370         * lib/unictype/pr_paragraph_separator.c: New file.
129371         * lib/unictype/pr_pattern_syntax.c: New file.
129372         * lib/unictype/pr_pattern_white_space.c: New file.
129373         * lib/unictype/pr_private_use.c: New file.
129374         * lib/unictype/pr_punctuation.c: New file.
129375         * lib/unictype/pr_quotation_mark.c: New file.
129376         * lib/unictype/pr_radical.c: New file.
129377         * lib/unictype/pr_sentence_terminal.c: New file.
129378         * lib/unictype/pr_soft_dotted.c: New file.
129379         * lib/unictype/pr_space.c: New file.
129380         * lib/unictype/pr_terminal_punctuation.c: New file.
129381         * lib/unictype/pr_test.c: New file.
129382         * lib/unictype/pr_titlecase.c: New file.
129383         * lib/unictype/pr_unassigned_code_value.c: New file.
129384         * lib/unictype/pr_unified_ideograph.c: New file.
129385         * lib/unictype/pr_uppercase.c: New file.
129386         * lib/unictype/pr_variation_selector.c: New file.
129387         * lib/unictype/pr_white_space.c: New file.
129388         * lib/unictype/pr_xid_continue.c: New file.
129389         * lib/unictype/pr_xid_start.c: New file.
129390         * lib/unictype/pr_zero_width.c: New file.
129391         * lib/unictype/scripts.c: New file.
129392         * lib/unictype/sy_c_ident.c: New file.
129393         * lib/unictype/sy_c_whitespace.c: New file.
129394         * lib/unictype/sy_java_ident.c: New file.
129395         * lib/unictype/sy_java_whitespace.c: New file.
129397         * lib/unictype/bidi_of.h: New file, generated by gen-ctype.c for
129398         Unicode 5.0.0.
129399         * lib/unictype/blocks.h: Likewise.
129400         * lib/unictype/categ_C.h: Likewise.
129401         * lib/unictype/categ_Cc.h: Likewise.
129402         * lib/unictype/categ_Cf.h: Likewise.
129403         * lib/unictype/categ_Cn.h: Likewise.
129404         * lib/unictype/categ_Co.h: Likewise.
129405         * lib/unictype/categ_Cs.h: Likewise.
129406         * lib/unictype/categ_L.h: Likewise.
129407         * lib/unictype/categ_Ll.h: Likewise.
129408         * lib/unictype/categ_Lm.h: Likewise.
129409         * lib/unictype/categ_Lo.h: Likewise.
129410         * lib/unictype/categ_Lt.h: Likewise.
129411         * lib/unictype/categ_Lu.h: Likewise.
129412         * lib/unictype/categ_M.h: Likewise.
129413         * lib/unictype/categ_Mc.h: Likewise.
129414         * lib/unictype/categ_Me.h: Likewise.
129415         * lib/unictype/categ_Mn.h: Likewise.
129416         * lib/unictype/categ_N.h: Likewise.
129417         * lib/unictype/categ_Nd.h: Likewise.
129418         * lib/unictype/categ_Nl.h: Likewise.
129419         * lib/unictype/categ_No.h: Likewise.
129420         * lib/unictype/categ_P.h: Likewise.
129421         * lib/unictype/categ_Pc.h: Likewise.
129422         * lib/unictype/categ_Pd.h: Likewise.
129423         * lib/unictype/categ_Pe.h: Likewise.
129424         * lib/unictype/categ_Pf.h: Likewise.
129425         * lib/unictype/categ_Pi.h: Likewise.
129426         * lib/unictype/categ_Po.h: Likewise.
129427         * lib/unictype/categ_Ps.h: Likewise.
129428         * lib/unictype/categ_S.h: Likewise.
129429         * lib/unictype/categ_Sc.h: Likewise.
129430         * lib/unictype/categ_Sk.h: Likewise.
129431         * lib/unictype/categ_Sm.h: Likewise.
129432         * lib/unictype/categ_So.h: Likewise.
129433         * lib/unictype/categ_Z.h: Likewise.
129434         * lib/unictype/categ_Zl.h: Likewise.
129435         * lib/unictype/categ_Zp.h: Likewise.
129436         * lib/unictype/categ_Zs.h: Likewise.
129437         * lib/unictype/categ_of.h: Likewise.
129438         * lib/unictype/combining.h: Likewise.
129439         * lib/unictype/ctype_alnum.h: Likewise.
129440         * lib/unictype/ctype_alpha.h: Likewise.
129441         * lib/unictype/ctype_blank.h: Likewise.
129442         * lib/unictype/ctype_cntrl.h: Likewise.
129443         * lib/unictype/ctype_digit.h: Likewise.
129444         * lib/unictype/ctype_graph.h: Likewise.
129445         * lib/unictype/ctype_lower.h: Likewise.
129446         * lib/unictype/ctype_print.h: Likewise.
129447         * lib/unictype/ctype_punct.h: Likewise.
129448         * lib/unictype/ctype_space.h: Likewise.
129449         * lib/unictype/ctype_upper.h: Likewise.
129450         * lib/unictype/ctype_xdigit.h: Likewise.
129451         * lib/unictype/decdigit.h: Likewise.
129452         * lib/unictype/digit.h: Likewise.
129453         * lib/unictype/mirror.h: Likewise.
129454         * lib/unictype/numeric.h: Likewise.
129455         * lib/unictype/pr_alphabetic.h: Likewise.
129456         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
129457         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
129458         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
129459         * lib/unictype/pr_bidi_block_separator.h: Likewise.
129460         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
129461         * lib/unictype/pr_bidi_common_separator.h: Likewise.
129462         * lib/unictype/pr_bidi_control.h: Likewise.
129463         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
129464         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
129465         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
129466         * lib/unictype/pr_bidi_european_digit.h: Likewise.
129467         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
129468         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
129469         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
129470         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
129471         * lib/unictype/pr_bidi_pdf.h: Likewise.
129472         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
129473         * lib/unictype/pr_bidi_whitespace.h: Likewise.
129474         * lib/unictype/pr_combining.h: Likewise.
129475         * lib/unictype/pr_composite.h: Likewise.
129476         * lib/unictype/pr_currency_symbol.h: Likewise.
129477         * lib/unictype/pr_dash.h: Likewise.
129478         * lib/unictype/pr_decimal_digit.h: Likewise.
129479         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
129480         * lib/unictype/pr_deprecated.h: Likewise.
129481         * lib/unictype/pr_diacritic.h: Likewise.
129482         * lib/unictype/pr_extender.h: Likewise.
129483         * lib/unictype/pr_format_control.h: Likewise.
129484         * lib/unictype/pr_grapheme_base.h: Likewise.
129485         * lib/unictype/pr_grapheme_extend.h: Likewise.
129486         * lib/unictype/pr_grapheme_link.h: Likewise.
129487         * lib/unictype/pr_hex_digit.h: Likewise.
129488         * lib/unictype/pr_hyphen.h: Likewise.
129489         * lib/unictype/pr_id_continue.h: Likewise.
129490         * lib/unictype/pr_id_start.h: Likewise.
129491         * lib/unictype/pr_ideographic.h: Likewise.
129492         * lib/unictype/pr_ids_binary_operator.h: Likewise.
129493         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
129494         * lib/unictype/pr_ignorable_control.h: Likewise.
129495         * lib/unictype/pr_iso_control.h: Likewise.
129496         * lib/unictype/pr_join_control.h: Likewise.
129497         * lib/unictype/pr_left_of_pair.h: Likewise.
129498         * lib/unictype/pr_line_separator.h: Likewise.
129499         * lib/unictype/pr_logical_order_exception.h: Likewise.
129500         * lib/unictype/pr_lowercase.h: Likewise.
129501         * lib/unictype/pr_math.h: Likewise.
129502         * lib/unictype/pr_non_break.h: Likewise.
129503         * lib/unictype/pr_not_a_character.h: Likewise.
129504         * lib/unictype/pr_numeric.h: Likewise.
129505         * lib/unictype/pr_other_alphabetic.h: Likewise.
129506         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
129507         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
129508         * lib/unictype/pr_other_id_continue.h: Likewise.
129509         * lib/unictype/pr_other_id_start.h: Likewise.
129510         * lib/unictype/pr_other_lowercase.h: Likewise.
129511         * lib/unictype/pr_other_math.h: Likewise.
129512         * lib/unictype/pr_other_uppercase.h: Likewise.
129513         * lib/unictype/pr_paired_punctuation.h: Likewise.
129514         * lib/unictype/pr_paragraph_separator.h: Likewise.
129515         * lib/unictype/pr_pattern_syntax.h: Likewise.
129516         * lib/unictype/pr_pattern_white_space.h: Likewise.
129517         * lib/unictype/pr_private_use.h: Likewise.
129518         * lib/unictype/pr_punctuation.h: Likewise.
129519         * lib/unictype/pr_quotation_mark.h: Likewise.
129520         * lib/unictype/pr_radical.h: Likewise.
129521         * lib/unictype/pr_sentence_terminal.h: Likewise.
129522         * lib/unictype/pr_soft_dotted.h: Likewise.
129523         * lib/unictype/pr_space.h: Likewise.
129524         * lib/unictype/pr_terminal_punctuation.h: Likewise.
129525         * lib/unictype/pr_titlecase.h: Likewise.
129526         * lib/unictype/pr_unassigned_code_value.h: Likewise.
129527         * lib/unictype/pr_unified_ideograph.h: Likewise.
129528         * lib/unictype/pr_uppercase.h: Likewise.
129529         * lib/unictype/pr_variation_selector.h: Likewise.
129530         * lib/unictype/pr_white_space.h: Likewise.
129531         * lib/unictype/pr_xid_continue.h: Likewise.
129532         * lib/unictype/pr_xid_start.h: Likewise.
129533         * lib/unictype/pr_zero_width.h: Likewise.
129534         * lib/unictype/scripts.h: Likewise.
129535         * lib/unictype/scripts_byname.gperf: Likewise.
129536         * lib/unictype/sy_c_ident.h: Likewise.
129537         * lib/unictype/sy_c_whitespace.h: Likewise.
129538         * lib/unictype/sy_java_ident.h: Likewise.
129539         * lib/unictype/sy_java_whitespace.h: Likewise.
129541         * lib/unictype/Makefile: New file.
129542         * lib/unictype/gen-ctype.c: New file, based on gen-unicode-ctype.c in
129543         glibc.
129544         * lib/unictype/3level.h: New file, copied from glibc.
129545         * lib/unictype/3levelbit.h: New file.
129547 2007-11-11  Bruno Haible  <bruno@clisp.org>
129549         * modules/gperf: New file.
129550         * modules/iconv_open (Depends-on): Add it.
129551         (Makefile.am): Remove the GPERF definition.
129553 2007-11-11  Bruno Haible  <bruno@clisp.org>
129555         * m4/round.m4 (gl_FUNC_ROUND): Test against NetBSD 3.0 bug.
129556         * doc/functions/round.texi: Mention the NetBSD 3.0 bug.
129558 2007-11-11  Bruno Haible  <bruno@clisp.org>
129560         * tests/test-argmatch.c (ARGMATCH_DIE): Undefine.
129561         (usage): Remove function.
129563 2007-11-11  Bruno Haible  <bruno@clisp.org>
129565         * m4/roundf.m4 (gl_FUNC_ROUNDF): Use gl_FUNC_FLOORF_LIBS and
129566         gl_FUNC_CEILF_LIBS.
129567         * m4/round.m4 (gl_FUNC_ROUND): Use gl_FUNC_FLOOR_LIBS and
129568         gl_FUNC_CEIL_LIBS.
129569         * m4/roundl.m4 (gl_FUNC_ROUNDL): Use gl_FUNC_FLOORL_LIBS and
129570         gl_FUNC_CEILL_LIBS.
129571         * modules/roundf (Files): Add m4/floorf.m4, m4/ceilf.m4.
129572         * modules/round (Files): Add m4/floor.m4, m4/ceil.m4.
129573         * modules/roundl (Files): Add m4/floorl.m4, m4/ceill.m4.
129575 2007-11-11  Bruno Haible  <bruno@clisp.org>
129577         * m4/roundf.m4 (gl_FUNC_ROUNDF): Handle the case that floorf and
129578         roundf were declared but do not exist on functions.
129579         * m4/roundl.m4 (gl_FUNC_ROUNDL): Handle the case that floorl and
129580         roundl were declared but do not exist on functions.
129581         * lib/round.c (HAVE_FLOOR_AND_CEIL): Use HAVE_FLOORF_AND_CEILF and
129582         HAVE_FLOORL_AND_CEILL, respectively.
129583         Needed for Sun C on Solaris 10.
129585 2007-11-11  Bruno Haible  <bruno@clisp.org>
129587         * m4/roundf.m4 (gl_FUNC_ROUNDF): Set REPLACE_ROUNDF instead of
129588         HAVE_DECL_ROUNDF. Remove redundant AC_SUBST.
129589         * m4/round.m4 (gl_FUNC_ROUND): Set REPLACE_ROUND instead of
129590         HAVE_DECL_ROUND. Remove redundant AC_SUBST.
129591         * m4/roundl.m4 (gl_FUNC_ROUNDL): Set REPLACE_ROUNDL instead of
129592         HAVE_DECL_ROUNDL. Remove redundant AC_SUBST.
129593         * lib/math.in.h (roundf): Use REPLACE_ROUNDF instead of
129594         HAVE_DECL_ROUNDF.
129595         (round): Use REPLACE_ROUND instead of HAVE_DECL_ROUND.
129596         (roundl): Use REPLACE_ROUNDL instead of HAVE_DECL_ROUNDL.
129597         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_ROUND* instead
129598         of HAVE_DECL_ROUND*.
129599         * modules/math (Makefile.am): Update.
129601 2007-11-10  Bruno Haible  <bruno@clisp.org>
129603         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Use same check for
129604         ptrdiff_t as m4/intl.m4.
129606 2007-11-10  Jim Meyering  <meyering@redhat.com>
129608         Avoid link failure for the argmatch test.
129609         * tests/test-argmatch.c (usage): Define function to avoid a link
129610         failure: argmatch_die requires a usage function.
129612 2007-11-09  Bruno Haible  <bruno@clisp.org>
129614         * doc/functions/snprintf.texi: Mention BeOS deficiency.
129615         * doc/functions/vsnprintf.texi: Likewise.
129616         * lib/vasnprintf.c (VASNPRINTF): Ensure that we never call snprintf
129617         with a size argument < 2.
129619 2007-11-09  Bruno Haible  <bruno@clisp.org>
129621         * lib/vasnprintf.c (VASNPRINTF): Increase reallocation of snprintf
129622         buffer. Fixes an inefficiency introduced on 2007-11-03.
129624 2007-11-09  Bruno Haible  <bruno@clisp.org>
129626         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8) [BeOS]: Make this test return
129627         none instead of tr_TR. Fixes a failure of test-c-strcasecmp.c.
129629 2007-11-08  Jim Meyering  <meyering@redhat.com>
129631         Change cache variable name prefix "jm_" to "gl_" everywhere.
129632         * m4/d-type.m4, m4/jm-winsz1.m4, m4/jm-winsz2.m4, m4/link-follow.m4:
129633         * m4/putenv.m4, m4/strtoimax.m4, m4/strtoumax.m4, m4/unlink-busy.m4:
129634         * m4/uptime.m4: s/gl_/jm_/
129636 2007-11-07  Bruno Haible  <bruno@clisp.org>
129638         Update to GNU gettext 0.17.
129639         * m4/intl.m4: Update to GNU gettext 0.17.
129640         * m4/po.m4: Likewise.
129641         * modules/gettext (Files): Remove m4/ulonglong.m4.
129642         (configure.ac): Require gettext infrastructure from version 0.17.
129644 2007-11-06  Bruno Haible  <bruno@clisp.org>
129646         * lib/fbufmode.c (fbufmode) [QNX]: Use numerical values for flags; the
129647         symbolic values are not defined in a public header.
129648         * lib/freadable.c (freadable) [QNX]: Likewise.
129649         * lib/freadahead.c (freadahead) [QNX]: Likewise.
129650         * lib/freading.c (freading) [QNX]: Likewise.
129651         * lib/fseterr.c (fseterr) [QNX]: Likewise.
129652         * lib/fwritable.c (fwritable) [QNX]: Likewise.
129653         * lib/fwriting.c (fwriting) [QNX]: Likewise.
129654         * lib/fpurge.c (fpurge) [QNX]: Likewise. Add a return statement.
129655         Reported by Alain Magloire.
129657         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for QNX.
129659 2007-11-05  Bruno Haible  <bruno@clisp.org>
129661         * lib/vasnprintf.c (VASNPRINTF): Expand the NEED_PRINTF_DIRECTIVE_A
129662         code when NEED_PRINTF_LONG_DOUBLE or NEED_PRINTF_DOUBLE is set.
129663         Needed on Cygwin, where !NEED_PRINTF_DIRECTIVE_A && NEED_PRINTF_DOUBLE.
129664         Reported by Eric Blake.
129666 2007-10-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
129667             Bruno Haible  <bruno@clisp.org>
129669         * modules/malloc (configure.ac): Define GNULIB_MALLOC_GNU always.
129670         * modules/realloc (configure.ac): Define GNULIB_REALLOC_GNU always.
129671         * lib/realloc.c (SYSTEM_MALLOC_GLIBC_COMPATIBLE): New macro.
129672         (malloc): Undefine also before including <stdlib.h>.
129673         (rpl_realloc): Turn malloc(0) into malloc(1) if necessary.
129674         Needed on OSF/1 4.0.
129676 2007-11-05  Jim Meyering  <meyering@redhat.com>
129678         git-version-gen: sync from coreutils.
129679         * build-aux/git-version-gen: Add comments.
129680         Change the first '-' to '.' in the snapshot version string,
129681         e.g., 6.9-377-08144 -> 6.9.377-08144
129682         Remove first parameter.
129683         Don't declare a version "-dirty" merely because a time
129684         stamp has changed.
129686 2007-11-04  Bruno Haible  <bruno@clisp.org>
129688         * lib/lock.h: Protect all macro definitions containing an 'if'
129689         statement through a "do { ... } while (0)".
129690         * lib/tls.h: Likewise.
129692 2007-11-04  Bruno Haible  <bruno@clisp.org>
129694         * lib/vasnprintf.c (DCHAR_IS_TCHAR, DCHAR_CPY): Undefine at the end.
129696 2007-11-04  Bruno Haible  <bruno@clisp.org>
129698         * m4/printf.m4 (gl_PRINTF_ENOMEM): Use GL_NOCRASH.
129699         * modules/fprintf-posix (Depends-on): Add nocrash.
129700         * modules/snprintf-posix (Depends-on): Likewise.
129701         * modules/sprintf-posix (Depends-on): Likewise.
129702         * modules/vasnprintf-posix (Depends-on): Likewise.
129703         * modules/vasprintf-posix (Depends-on): Likewise.
129704         * modules/vfprintf-posix (Depends-on): Likewise.
129705         * modules/vsnprintf-posix (Depends-on): Likewise.
129706         * modules/vsprintf-posix (Depends-on): Likewise.
129707         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
129708         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
129709         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
129710         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
129711         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
129712         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
129713         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
129715 2007-11-04  Bruno Haible  <bruno@clisp.org>
129717         * modules/nocrash: New file.
129718         * m4/nocrash.m4: New file, taken from GNU clisp. Code taken from
129719         GNU libsigsegv, with permission of GNU libsigsegv's copyright holders.
129721 2007-11-04  Bruno Haible  <bruno@clisp.org>
129723         * tests/test-vasnprintf-posix.c (test_function): Add some tests of
129724         precision handling.
129725         * tests/test-vasprintf-posix.c (test_function): Likewise.
129726         * tests/test-snprintf-posix.h (test_function): Likewise.
129727         * tests/test-sprintf-posix.h (test_function): Likewise.
129729         Fix *printf behaviour for large precisions on mingw and BeOS.
129730         * m4/printf.m4 (gl_PRINTF_PRECISION): New macro.
129731         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_UNBOUNDED_PRECISION.
129732         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_PRECISION): New macro.
129733         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
129734         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
129735         gl_PRINTF_PRECISION and test its result. Invoke
129736         gl_PREREQ_VASNPRINTF_PRECISION.
129737         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
129738         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
129739         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
129740         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
129741         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
129742         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
129743         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
129744         * doc/functions/fprintf.texi: Update.
129745         * doc/functions/printf.texi: Update.
129746         * doc/functions/snprintf.texi: Update.
129747         * doc/functions/sprintf.texi: Update.
129748         * doc/functions/vfprintf.texi: Update.
129749         * doc/functions/vprintf.texi: Update.
129750         * doc/functions/vsnprintf.texi: Update.
129751         * doc/functions/vsprintf.texi: Update.
129753 2007-11-04  Bruno Haible  <bruno@clisp.org>
129755         * lib/vasnprintf.c (scale10_round_decimal_decoded): Fix shift loop.
129757 2007-11-04  Bruno Haible  <bruno@clisp.org>
129759         * modules/relocatable-prog (Files): Add m4/lib-ld.m4.
129760         Reported by Sylvain Beucler <beuc@gnu.org>.
129762 2007-11-03  Bruno Haible  <bruno@clisp.org>
129764         * tests/test-fprintf-posix2.sh: New file.
129765         * tests/test-fprintf-posix2.c: New file.
129766         * modules/fprintf-posix-tests (Files): Add them.
129767         (TESTS): Add test-fprintf-posix2.sh.
129768         (configure.ac): Check for getrlimit and setrlimit.
129769         (check_PROGRAMS): Add test-fprintf-posix2.
129771         * tests/test-printf-posix2.sh: New file.
129772         * tests/test-printf-posix2.c: New file.
129773         * modules/printf-posix-tests (Files): Add them.
129774         (TESTS): Add test-printf-posix2.sh.
129775         (configure.ac): Check for getrlimit and setrlimit.
129776         (check_PROGRAMS): Add test-printf-posix2.
129778         Fix *printf behaviour in out-of-memory situations on MacOS X and *BSD.
129779         * m4/printf.m4 (gl_PRINTF_ENOMEM): New macro.
129780         * lib/vasnprintf.c: Implement NEED_PRINTF_DOUBLE.
129781         (decode_double): New function, copied from decode_long_double.
129782         (scale10_round_decimal_decoded): New function, extracted from
129783         scale10_round_decimal_long_double.
129784         (scale10_round_decimal_long_double): Use it.
129785         (scale10_round_decimal_double): New function.
129786         (floorlog10): New function.
129787         (VASNPRINTF): Handle NEED_PRINTF_DOUBLE case.
129788         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_ENOMEM): New macro.
129789         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
129790         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
129791         gl_PRINTF_ENOMEM and test its result. Invoke
129792         gl_PREREQ_VASNPRINTF_ENOMEM.
129793         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
129794         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
129795         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
129796         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
129797         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
129798         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
129799         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
129800         * modules/fprintf-posix (Depends-on): Add frexp-nolibm.
129801         * modules/snprintf-posix (Depends-on): Likewise.
129802         * modules/sprintf-posix (Depends-on): Likewise.
129803         * modules/vasnprintf-posix (Depends-on): Likewise.
129804         * modules/vasprintf-posix (Depends-on): Likewise.
129805         * modules/vfprintf-posix (Depends-on): Likewise.
129806         * modules/vsnprintf-posix (Depends-on): Likewise.
129807         * modules/vsprintf-posix (Depends-on): Likewise.
129808         * doc/functions/fprintf.texi: Update.
129809         * doc/functions/printf.texi: Update.
129810         * doc/functions/snprintf.texi: Update.
129811         * doc/functions/sprintf.texi: Update.
129812         * doc/functions/vfprintf.texi: Update.
129813         * doc/functions/vprintf.texi: Update.
129814         * doc/functions/vsnprintf.texi: Update.
129815         * doc/functions/vsprintf.texi: Update.
129817 2007-11-03  Bruno Haible  <bruno@clisp.org>
129819         * modules/frexp-nolibm-tests: New file.
129821         * modules/frexp-nolibm: New file.
129822         * m4/frexp.m4 (gl_FUNC_FREXP_NO_LIBM): New macro.
129824 2007-11-03  Bruno Haible  <bruno@clisp.org>
129826         * lib/vasnprintf.c (VASNPRINTF): Don't assume that snprintf's return
129827         value is C99 compliant.
129828         Needed for OSF/1 5.1.
129830 2007-11-03  Bruno Haible  <bruno@clisp.org>
129832         Fix out-of-memory handling of vasnprintf.
129833         * lib/printf-parse.c: Include <errno.h>.
129834         (PRINTF_PARSE): When failing, set errno to EINVAL or ENOMEM.
129835         * lib/vasnprintf.c (VASNPRINTF): When PRINTF_PARSE fails, assume errno
129836         is already set.
129838 2007-11-02  Eric Blake  <ebb9@byu.net>
129840         Fix tests on cygwin.
129841         * modules/xprintf-posix-tests (Makefile.am): Link against -lintl.
129843 2007-11-01  Bruno Haible  <bruno@clisp.org>
129845         * lib/stdlib.in.h (putenv): Remove the "not POSIX compliant everywhere"
129846         warning.
129847         * doc/functions/putenv.texi: Clarify that the 'putenv' module is not
129848         needed for POSIX compatibility.
129850 2007-11-01  Paul Eggert  <eggert@cs.ucla.edu>
129852         * m4/putenv.m4 (gl_FUNC_PUTENV): Also mention that we're checking
129853         for compatibility with GNU.
129855 2007-11-01  Bruno Haible  <bruno@clisp.org>
129857         * lib/putenv.c: Include <stdlib.h>. Remove rpl_putenv declaration.
129858         (putenv): Renamed from rpl_putenv. Change argument type from
129859         'const char *' to 'char *'.
129860         * m4/putenv.m4 (gl_FUNC_PUTENV): Require gl_STDLIB_H_DEFAULTS. Instead
129861         of defining putenv in config.h, just set REPLACE_PUTENV.
129862         * modules/putenv (Depends-on): Add stdlib.
129863         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
129864         (Include): Use <stdlib.h>.
129865         * lib/stdlib.in.h (putenv): New declaration.
129866         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_PUTENV and
129867         REPLACE_PUTENV.
129868         * modules/stdlib (Makefile.am): Substitute GNULIB_PUTENV and
129869         REPLACE_PUTENV.
129870         Needed for MacOS X 10.5.0.
129871         Reported by Peter O'Gorman <peter@pogma.com>.
129873 2007-11-01  Jim Meyering  <meyering@redhat.com>
129875         Treat an empty date string exactly like "0".
129876         * lib/getdate.y (get_date): Once any isspace or TZ= prefix is consumed,
129877         if the remaining date string (to be parsed) is empty, use "0".
129878         Reported by Mischa Molhoek and discussed in this thread:
129879         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/11726>.
129881 2007-10-31  Bruno Haible  <bruno@clisp.org>
129883         * m4/intmax_t.m4 (gl_AC_TYPE_INTMAX_T, gt_AC_TYPE_INTMAX_T): Use
129884         AC_TYPE_LONG_LONG_INT instead of gl_AC_TYPE_LONG_LONG.
129885         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Use
129886         AC_TYPE_UNSIGNED_LONG_LONG_INT instead of gl_AC_TYPE_UNSIGNED_LONG_LONG.
129887         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Remove macro.
129888         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG): Remove macro.
129890 2007-10-31  Bruno Haible  <bruno@clisp.org>
129892         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): New macro, extracted
129893         from AC_TYPE_LONG_LONG_INT and AC_TYPE_UNSIGNED_LONG_LONG_INT.
129894         (AC_TYPE_LONG_LONG_INT): Use it.
129895         (AC_TYPE_UNSIGNED_LONG_LONG_INT): Moved here from m4/ulonglong.m4. Use
129896         it as well.
129897         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Remove macro; moved
129898         to m4/longlong.m4.
129899         * modules/stdint (Files): Remove m4/ulonglong.m4.
129900         * modules/strtoull (Files): Use m4/longlong.m4 instead of
129901         m4/ulonglong.m4.
129902         * modules/strtoumax (Files): Likewise.
129904 2007-10-30  Bruno Haible  <bruno@clisp.org>
129906         * modules/xvasprintf-posix: New file.
129907         Suggested by Eric Blake.
129909 2007-10-30  Bruno Haible  <bruno@clisp.org>
129911         * modules/xprintf-posix-tests: New file.
129912         * tests/test-xprintf-posix.sh: New file.
129913         * tests/test-xprintf-posix.c: New file.
129914         * tests/test-xfprintf-posix.c: New file.
129916         * modules/xprintf-posix: New file.
129918 2007-10-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
129920         * modules/fbufmode-tests (MOSTLYCLEANFILES): Remove temp files.
129921         * modules/freadable-tests (MOSTLYCLEANFILES): Likewise.
129922         * modules/fwritable-tests (MOSTLYCLEANFILES): Likewise.
129924 2007-10-29  Bruno Haible  <bruno@clisp.org>
129926         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Rename the cache variable to
129927         contain the special marker '_cv_'.
129928         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
129929         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
129930         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
129931         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Likewise.
129932         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
129933         Reported by Ralf Wildenhues.
129935 2007-10-29  Bruno Haible  <bruno@clisp.org>
129937         * gnulib-tool (func_import): When --lgpl is not specified, set
129938         sed_transform_lib_file to convert LGPL and GPLv2+ copyright headers to
129939         GPLv3.
129940         Reported by Simon Josefsson.
129942 2007-10-28  Bruno Haible  <bruno@clisp.org>
129944         * lib/math.in.h: Test REPLACE_ISFINITE instead of HAVE_DECL_ISFINITE.
129945         * m4/isfinite.m4 (gl_ISFINITE): Initialize REPLACE_ISFINITE instead of
129946         HAVE_DECL_ISFINITE.
129947         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
129948         * modules/math (Makefile.am): Substitute REPLACE_ISFINITE instead of
129949         HAVE_DECL_ISFINITE.
129951 2007-10-28  Bruno Haible  <bruno@clisp.org>
129953         * lib/stdint.in.h (_STDINT_MAX): Subtract 1 from an unused signed
129954         integer shift in the signed case. Fixes warnings with OSF/1 5.1 cc.
129956 2007-10-28  Bruno Haible  <bruno@clisp.org>
129958         Fix link errors with Sun C 5.0 on Solaris 10.
129959         * m4/floorf.m4 (gl_FUNC_FLOORF): Consider also the case that the
129960         function is declared but not present in the compiler's libm.
129961         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
129962         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
129963         * m4/ceill.m4 (gl_FUNC_CEILL: Likewise.
129964         * lib/math.in.h: Test REPLACE_CEILF instead of HAVE_DECL_CEILF.
129965         Test REPLACE_CEILL instead of HAVE_DECL_CEILL.
129966         Test REPLACE_FLOORF instead of HAVE_DECL_FLOORF.
129967         Test REPLACE_FLOORL instead of HAVE_DECL_FLOORL.
129968         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
129969         * modules/math (Makefile.am): Substitute REPLACE_CEILF instead of
129970         HAVE_DECL_CEILF, REPLACE_CEILL instead of HAVE_DECL_CEILL,
129971         REPLACE_FLOORF instead of HAVE_DECL_FLOORF, REPLACE_FLOORL instead of
129972         HAVE_DECL_FLOORL.
129974 2007-10-28  Bruno Haible  <bruno@clisp.org>
129976         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): New macro, extracted from
129977         gl_FUNC_FLOORL. Cache the result.
129978         (gl_FUNC_FLOORL): Use it.
129979         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): New macro, extracted from
129980         gl_FUNC_CEILL. Cache the result.
129981         (gl_FUNC_CEILL): Use it.
129983         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): New macro, extracted from
129984         gl_FUNC_FLOOR. Cache the result.
129985         (gl_FUNC_FLOOR): Use it.
129986         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): New macro, extracted from
129987         gl_FUNC_CEIL. Cache the result.
129988         (gl_FUNC_CEIL): Use it.
129990         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): New macro, extracted from
129991         gl_FUNC_FLOORF. Cache the result.
129992         (gl_FUNC_FLOORF): Use it.
129993         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): New macro, extracted from
129994         gl_FUNC_CEILF. Cache the result.
129995         (gl_FUNC_CEILF): Use it.
129997 2007-10-28  Bruno Haible  <bruno@clisp.org>
129999         * gnulib-tool: Allow specifying the LGPL version number through
130000         --lgpl=2 or --lgpl=3.
130001         (func_usage): Document --lgpl with argument.
130002         Handle --lgpl=... arguments.
130003         (func_import): Recognize also gl_LGPL calls with an argument. When
130004         --lgpl=2 is used and the module's license is just LGPL, report an
130005         error. Set sed_transform_lib_file according to the lgpl variable. In
130006         the generated files, use --lgpl or gl_LGPL invocations with argument,
130007         if necessary.
130008         * doc/gnulib-intro.texi (Copyright): Explain how to get modules under
130009         an LGPv2+ license.
130010         * doc/gnulib-tool.texi (Modified imports): Update explanation of
130011         gl_LGPL macro.
130013 2007-10-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
130014             Bruno Haible  <bruno@clisp.org>
130016         * lib/unistr.h (u8_uctomb_aux): Declare also if !HAVE_INLINE.
130017         (u16_uctomb_aux): Likewise.
130018         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Define also if
130019         !HAVE_INLINE.
130020         * lib/unistr/u16-uctomb-aux.c (u16_uctomb_aux): Likewise
130022 2007-10-28  Bruno Haible  <bruno@clisp.org>
130024         * modules/error: Add a notice recommending to change XGETTEXT_OPTIONS.
130025         Invoke AM_GETTEXT_OPTION if it exists.
130026         * modules/vasprintf: Likewise.
130027         * modules/verror: Likewise.
130028         * modules/xprintf: Likewise.
130029         * modules/xvasprintf: Likewise.
130031 2007-10-27  Ben Pfaff  <blp@gnu.org>
130033         * lib/math.in.h: Define isfinite macro and prototypes for
130034         gl_isfinitef, gl_isfinited, gl_isfinitel if we are providing
130035         implementations.
130036         * m4/math_h.m4: New substitutions for isfinite module.
130037         * lib/isfinite.c: New file.
130038         * m4/isfinite.m4: New file.
130039         * modules/math: Replace isfinite-related @VARS@ in math.in.h.
130040         * modules/isfinite: New file.
130041         * modules/isfinite-tests: New file.
130042         * tests/tests-isfinite.c: New file.
130043         * doc/functions/isfinite.texi: Mention isfinite module.
130044         * MODULES.html.sh: Mention new module.
130046 2007-10-27  Ben Pfaff  <blp@gnu.org>
130048         Ralf Wildenhues reported that Tru64 4.0D declares the round
130049         functions but does not have definitions.
130050         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): If the target function
130051         cannot be found in any library, set the output variable to
130052         "missing" instead of "".
130053         * m4/round.m4: Also use our substitute if we cannot find round in
130054         any library, even if it is declared.
130055         * m4/roundf.m4: Likewise for roundf.
130056         * m4/roundl.m4: Likewise for roundl.
130057         * lib/math.in.h: Undefine roundf, round, roundl before defining
130058         their replacements, to allow for hypothetical systems where these
130059         may be defined as macros but not available in libraries.
130061 2007-10-27  Bruno Haible  <bruno@clisp.org>
130063         * doc/gnulib.texi: Invoke @firstparagraphindent.
130064         * doc/gnulib-tool.texi (Simple update): Mention possible incompatible
130065         changes in gnulib.
130066         (Source changes): New section.
130068 2007-10-26  Bruno Haible  <bruno@clisp.org>
130070         * m4/gnulib-common.m4 (AC_C_RESTRICT): New overriding definition,
130071         borrowed from autoconf.
130073 2007-10-26  Bruno Haible  <bruno@clisp.org>
130075         * lib/strerror.c (rpl_strerror): Return "Unknown error ..." also if
130076         strerror returned the empty string. Needed on HP-UX 11.00.
130078 2007-10-24  Micah Cowan  <micah@cowan.name>
130080         Remove vestiges of cvs-gnulib-checkout process.  Now we use git.
130081         * build-aux/bootstrap: Remove support for now-unnecessary option,
130082         --cvs-user, and envvars CVS_USER, CVS_RSH.
130084 2007-10-24  Jim Meyering  <meyering@redhat.com>
130086         Avoid diagnostics from sha1sum when there is no cached checksum.
130087         * build-aux/bootstrap (update_po_files): Skip the sha1sum check
130088         if the po.s1 file hasn't been created yet.
130090         * build-aux/bootstrap: Sync from coreutils:
130091         2007-10-24  Jim Meyering  <meyering@redhat.com>
130092         Get gnulib from the git repository, not from an obsolete cvs one.
130093         * build-aux/bootstrap: Suggestion from Micah Cowan.
130094         2007-10-04  Jim Meyering  <jim@meyering.net>
130095         * build-aux/bootstrap (slurp): Adapt to _.h -> .in.h name change.
130096         (update_po_files): Work also when there are no .po files in po/.
130098 2007-10-24  Paul Eggert  <eggert@cs.ucla.edu>
130100         * README: Append ".git" to git and cg examples.
130101         Problem reported by Benoit Sigoure.
130103 2007-10-23  Micah Cowan  <micah@cowan.name>
130105         * users.txt: Add wget.
130107 2007-10-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
130109         Fix linking of some unistdio tests on FreeBSD.
130110         * modules/unistdio/u16-vsnprintf-tests
130111         (test_u16_vsprintf1_LDADD): Add @LIBINTL@.
130112         * modules/unistdio/u16-vsprintf-tests
130113         (test_u16_vsnprintf1_LDADD): Likewise.
130114         * modules/unistdio/u32-vsnprintf-tests
130115         (test_u32_vsnprintf1_LDADD): Likewise.
130116         * modules/unistdio/u32-vsprintf-tests
130117         (test_u32_vsprintf1_LDADD): Likewise.
130118         * modules/unistdio/u8-vsnprintf-tests
130119         (test_u8_vsnprintf1_LDADD): Likewise.
130120         * modules/unistdio/u8-vsprintf-tests
130121         (test_u8_vsprintf1_LDADD): Likewise.
130122         * modules/unistdio/ulc-vsnprintf-tests
130123         (test_ulc_vsnprintf1_LDADD): Likewise.
130124         * modules/unistdio/ulc-vsprintf-tests
130125         (test_ulc_vsprintf1_LDADD): Likewise.
130127         Fix linking of some uniconv tests on FreeBSD.
130128         * modules/uniconv/u16-conv-from-enc-tests
130129         (test_u16_conv_from_enc_LDADD): Link $(LDADD) before @LIBICONV@.
130130         * modules/uniconv/u16-conv-to-enc-tests
130131         (test_u16_conv_to_enc_LDADD): Likewise.
130132         * modules/uniconv/u16-strconv-from-enc-tests
130133         (test_u16_strconv_from_enc_LDADD): Likewise.
130134         * modules/uniconv/u16-strconv-to-enc-tests
130135         (test_u16_strconv_to_enc_LDADD): Likewise.
130136         * modules/uniconv/u32-conv-from-enc-tests
130137         (test_u32_conv_from_enc_LDADD): Likewise.
130138         * modules/uniconv/u32-conv-to-enc-tests
130139         (test_u32_conv_to_enc_LDADD): Likewise.
130140         * modules/uniconv/u32-strconv-from-enc-tests
130141         (test_u32_strconv_from_enc_LDADD): Likewise.
130142         * modules/uniconv/u32-strconv-to-enc-tests
130143         (test_u32_strconv_to_enc_LDADD): Likewise.
130144         * modules/uniconv/u8-conv-from-enc-tests
130145         (test_u8_conv_from_enc_LDADD): Likewise.
130146         * modules/uniconv/u8-conv-to-enc-tests
130147         (test_u8_conv_to_enc_LDADD): Likewise.
130148         * modules/uniconv/u8-strconv-from-enc-tests
130149         (test_u8_strconv_from_enc_LDADD): Likewise.
130150         * modules/uniconv/u8-strconv-to-enc-tests
130151         (test_u8_strconv_to_enc_LDADD): Likewise.
130153 2007-10-22  Bruno Haible  <bruno@clisp.org>
130155         * lib/stdint.in.h: Add check that intmax_t and uintmax_t have the same
130156         size.
130158 2007-10-22  Eric Blake  <ebb9@byu.net>
130160         Tweak x*printf documentation.
130161         * lib/xprintf.c (xprintf, xvprintf, xfprintf, xvfprintf): Adjust
130162         variable name and comments.
130163         Suggested by Bruno Haible.
130165 2007-10-22  Bruno Haible  <bruno@clisp.org>
130167         * lib/acl.c (copy_acl): Fix file name in comment.
130169 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
130171         Fix Tru64 problem with stdbool.h.
130172         * lib/stdbool.in.h (false, true):
130173         [! (defined __cplusplus || defined __BEOS__) && !defined __GNUC__]:
130174         Don't declare as an enum in this situation; it runs afoul of Tru64.
130175         Problem reported by Steven M. Schweda in
130176         <http://lists.gnu.org/r/bug-autoconf/2007-10/msg00019.html>.
130178 2007-10-22  Eric Blake  <ebb9@byu.net>
130180         Also wrap vf?printf.
130181         * lib/xprintf.h (xvprintf, xvfprintf): New declarations.
130182         * lib/xprintf.c (xprintf, xfprintf): Work for C89.
130183         (xvprintf, xvfprintf): New functions.
130185 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
130187         * modules/fstrcmp-tests (test_fstrcmp_LDADD): New, add
130188         @LIBINTL@ for FreeBSD 6.2, $(LIBTHREAD) for AIX 4.3.3.
130190         * lib/uniconv/u16-conv-to-enc.c (U_MBLEN): Define.
130191         * lib/uniconv/u32-conv-to-enc.c (U_MBLEN): Likewise.
130193 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
130195         * lib/acl.c (copy_acl): Adjust to IRIX 6.5.  Problem reported
130196         by Bruno Haible.
130198 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
130200         * lib/getloadavg.c
130201         [defined (__osf__) && (defined (__alpha) || defined (__alpha__)]:
130202         Undef `sys' after including sys/table.h, for Tru64 4.0D.
130204         * tests/test-i-ring.c: Work for C89.
130206 2007-10-22  Bruno Haible  <bruno@clisp.org>
130208         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Use -1ull, not
130209         -1u, in preprocessor expression, so that we don't test for the bug
130210         in HP-UX 11.00 cpp.  Testing for this bug caused problems; see
130211         <http://lists.gnu.org/r/bug-gnulib/2007-10/msg00329.html>.
130213 2007-10-22  Eric Blake  <ebb9@byu.net>
130215         * tests/test-yesno.sh: Silence stderr during test.
130217 2007-10-22  Simon Josefsson  <simon@josefsson.org>
130219         * modules/crypto/gc-camellia: New file.
130221         * m4/gc-camellia.m4: New file.
130223         * lib/gc-libgcrypt.c (gc_cipher_open): Support Camellia.
130225         * lib/gc.h (enum Gc_cipher): Add GC_CAMELLIA128, GC_CAMELLIA256.
130227 2007-10-22  Simon Josefsson  <simon@josefsson.org>
130229         * build-aux/maint.mk (gzip_rsyncable): Don't fail if gzip sends
130230         --help to stdout.  Reported by sms@antinode.org (Steven
130231         M. Schweda).
130233 2007-10-22  Simon Josefsson  <simon@josefsson.org>
130235         * users.txt: Fix link to libksba.
130237 2007-10-21  Ben Pfaff  <blp@gnu.org>
130239         * modules/roundf-tests: Add dependency on floorf, ceilf to allow
130240         round.c roundf implementation that depends on floorf and ceilf to
130241         be tested unconditionally.
130243 2007-10-21  Ben Pfaff  <blp@gnu.org>
130245         * m4/check-libm-func.m4: Removed.
130246         * m4/check-math-lib.m4: New file.
130247         * m4/round.m4: Rewrite to use gl_CHECK_MATH_LIB.
130248         * m4/roundf.m4: Ditto, and fix lack of HAVE_DECL_ROUNDF
130249         definition and lack of AC_LIBOBJ([roundf]).
130250         * m4/roundl.m4: Ditto, and similarly for roundl.
130251         * modules/round: Reference new m4 file.
130252         * modules/roundf: Ditto.
130253         * modules/roundl: Ditto.
130254         * tests/test-round2.c (main): Use ROUND instead of round.
130255         Bug report from Bruno Haible.
130257 2007-10-21  Bruno Haible  <bruno@clisp.org>
130259         * lib/printf-parse.c: Don't assume <stdint.h> exists in IN_LIBASPRINTF
130260         context.
130262 2007-10-21  Bruno Haible  <bruno@clisp.org>
130264         * tests/test-wcwidth.c (main): Allow negative result for some control
130265         characters.
130267         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check also the width of U+200B.
130268         Needed on OSF/1 5.1.
130270 2007-10-21  Bruno Haible  <bruno@clisp.org>
130272         * tests/test-floorf1.c: Include isnanf.h.
130273         (main): Use isnanf() instead of isnan().
130274         * tests/test-ceilf1.c: Include isnanf.h.
130275         (main): Use isnanf() instead of isnan().
130276         * tests/test-truncf1.c: Include isnanf.h.
130277         (main): Use isnanf() instead of isnan().
130278         * tests/test-roundf1.c: Include isnanf.h.
130279         (main): Use isnanf() instead of isnan().
130281 2007-10-21  Eric Blake  <ebb9@byu.net>
130283         * users.txt: Update URL for m4.
130285 2007-10-21  Bruno Haible  <bruno@clisp.org>
130287         * users.txt: Add clisp. Update URLs to Simon Josefsson's projects.
130289 2007-10-21  Bruno Haible  <bruno@clisp.org>
130291         * gnulib-tool (func_create_megatestdir): Determine the cvsdate from
130292         Git's management files if the CVS files are not present.
130294 2007-10-20  Bruno Haible  <bruno@clisp.org>
130296         * lib/count-one-bits.h (COUNT_ONE_BITS): Use the builtin also for
130297         gcc-3.4.x.
130299 2007-10-20  Ben Pfaff  <blp@gnu.org>
130301         * lib/math.in.h: Declare round, roundf, roundl if we are providing
130302         implementations.
130303         * m4/math_h.m4: New substitutions for round, roundf, roundl modules.
130304         * lib/round.c: New file.
130305         * lib/roundf.c: New file.
130306         * lib/roundl.c: New file.
130307         * m4/round.m4: New file.
130308         * m4/roundf.m4: New file.
130309         * m4/roundl.m4: New file.
130310         * m4/check-libm-func-m4: New file.
130311         * modules/math: Replace round, roundf, roundl related @VARS@ in
130312         math.in.h.
130313         * modules/round: New file.
130314         * modules/round-tests: New file.
130315         * modules/roundf: New file.
130316         * modules/roundf-tests: New file.
130317         * modules/roundl: New file.
130318         * modules/roundl-tests: New file.
130319         * tests/test-round1.c: New file.
130320         * tests/test-round2.c: New file.
130321         * tests/test-roundf1.c: New file.
130322         * tests/test-roundf2.c: New file.
130323         * tests/test-roundl.c: New file.
130324         * doc/functions/round.texi: Mention round module.
130325         * doc/functions/roundf.texi: Mention roundf module.
130326         * doc/functions/roundl.texi: Mention roundl module.
130327         * MODULES.html.sh: Mention new modules.
130328         Thanks to Bruno Haible for suggestions.
130330 2007-10-20  Jim Meyering  <meyering@redhat.com>
130332         * lib/xprintf.c: Include <config.h> unconditionally.
130334         Change xprintf's license to GPL.
130335         * modules/xprintf (License): s/LGPL/GPL/, since this module
130336         depends on modules (exit and exitfail) which are GPL.
130337         Suggestion from Bruno Haible.
130339         xprintf fixes.
130340         * lib/xprintf.c (xprintf, xfprintf): Use va_end.
130341         Use a clearer diagnostic.
130342         Patch from Bruno Haible.
130344 2007-10-20  Bruno Haible  <bruno@clisp.org>
130346         * lib/vasnprintf.c (VASNPRINTF): Don't report overflow if the available
130347         length is INT_MAX and sizeof (DCHAR_T) > sizeof (TCHAR_T).
130348         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
130350 2007-10-20  Bruno Haible  <bruno@clisp.org>
130352         * tests/test-floorf2.c (correct_result_p): Don't rely on excess
130353         precision in the comparison result > x - 1 or similar.
130354         * tests/test-ceilf2.c (correct_result_p): Likewise.
130355         * tests/test-truncf2.c (correct_result_p): Likewise.
130356         * tests/test-trunc2.c (correct_result_p): Likewise.
130357         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
130359 2007-10-20  Bruno Haible  <bruno@clisp.org>
130361         * modules/ceil: New file.
130362         * m4/ceil.m4: New file.
130363         * doc/functions/ceil.texi: Mention the 'ceil' module.
130365 2007-10-20  Bruno Haible  <bruno@clisp.org>
130367         * modules/floor: New file.
130368         * m4/floor.m4: New file.
130369         * doc/functions/floor.texi: Mention the 'floor' module.
130371 2007-10-20  Bruno Haible  <bruno@clisp.org>
130373         * modules/ceilf-tests (Depends-on): Add fprintf-posix. Needed for use
130374         of %a.
130375         * modules/floorf-tests (Depends-on): Likewise.
130376         * modules/truncf-tests (Depends-on): Likewise.
130377         * modules/trunc-tests (Depends-on): Likewise.
130378         Reported by Ben Pfaff.
130380 2007-10-19  Jim Meyering  <meyering@redhat.com>
130382         * lib/xprintf.c (xprintf, xfprintf): Test err < 0, not just "err".
130383         Don't bother testing specific errno values.  Just test ferror.
130385         New module: xprintf
130386         * modules/xprintf, lib/xprintf.c, lib/xprintf.h: New files.
130388 2007-10-19  Bruno Haible  <bruno@clisp.org>
130390         * modules/csharpexec (Makefile.am): Use @FOO@ syntax instead of $(FOO)
130391         syntax.
130392         * modules/javaexec (Makefile.am): Likewise.
130393         * modules/relocatable-prog (Makefile.am): Likewise.
130394         Suggested by Jim Meyering.
130396 2007-10-18  Bruno Haible  <bruno@clisp.org>
130398         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on glibc >= 2.3 systems.
130399         Reported by Jim Meyering.
130401 2007-10-18  Eric Blake  <ebb9@byu.net>
130403         * modules/filenamecat-tests (Makefile.am): Link against -lintl.
130405 2007-10-18  Bruno Haible  <bruno@clisp.org>
130407         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N, gl_SNPRINTF_DIRECTIVE_N): Put
130408         the format string into writable memory. Needed in Fortify conditions.
130410 2007-10-18  Colin Watson  <cjwatson@debian.org>  (tiny change)
130411             Bruno Haible  <bruno@clisp.org>
130413         * lib/trim.c: Include config.h unconditionally. Include trim.h always.
130414         Include ctype.h always. Include stdlib.h, not mbuiter.h, for MB_CUR_MAX.
130415         * modules/trim (Depends-on): Add mbchar.
130416         (configure.ac): Add gl_FUNC_MBRTOWC.
130417         (Makefile.am): Augment lib_SOURCES.
130419 2007-10-17  Paul Eggert  <eggert@cs.ucla.edu>
130421         Modify glob.c to use fstatat and dirfd, to simplify it.
130422         Suggested by Eric Blake.
130423         * lib/glob.c (__fxstatat64) [!_LIBC]: New macro.
130424         Don't include <stdbool.h>; not used.
130425         (link_exists2_p, glob_in_dir) [!_LIBC]: No longer a special case.
130426         (link_exists_p): Simplify implementation, since we can now assume
130427         dirfd and fstatat.
130428         * modules/glob (Depends-on): Add dirfd, openat.  Remove stdbool.
130430 2007-10-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
130432         * gnulib-tool (func_get_dependencies): Fix sed script to
130433         match only tests.
130435 2007-10-17  Bruno Haible  <bruno@clisp.org>
130437         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): On Cygwin, don't
130438         allow locale names without encoding suffix.
130439         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
130440         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
130442 2007-10-16  Bruno Haible  <bruno@clisp.org>
130444         * lib/getcwd.c (__getcwd): Define with explicit rpl_ prefix.
130445         * lib/getgroups.c (getgroups): Likewise.
130446         * lib/gettimeofday.c (localtime, gmtime, tzset): Likewise.
130448 2007-10-16  Bruno Haible  <bruno@clisp.org>
130450         * modules/absolute-header (License): Change from LGPL to LGPLv2+.
130451         * modules/malloc-posix (License): Likewise.
130452         * modules/realloc-posix (License): Likewise.
130453         * modules/calloc-posix (License): Likewise.
130454         * modules/intprops (License): Change from GPL to LGPL, with
130455         Paul Eggert's approval.
130457 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
130459         Merge glibc changes into lib/glob.c.
130461         * lib/glob.c (glob_in_dir): Sync with glibc/posix/glob.c, dated
130462         2007-10-15 04:59:03 UTC.  Here are the changes:
130464         2007-10-14  Ulrich Drepper  <drepper@redhat.com>
130466         * lib/glob.c: Reimplement link_exists_p to use fstatat64.
130468         * lib/glob.c: Add some branch prediction throughout.
130470         2007-10-07  Ulrich Drepper  <drepper@redhat.com>
130472         [BZ #5103]
130473         * lib/glob.c (glob): Recognize patterns starting \/.
130475         2007-02-14  Jakub Jelinek  <jakub@redhat.com>
130477         [BZ #3996]
130478         * lib/glob.c (attribute_hidden): Define if not defined.
130479         (glob): Unescape dirname, filename or username when needed and not
130480         GLOB_NOESCAPE.  Handle \/ correctly.  Handle GLOB_MARK if filename
130481         is NULL.  Handle unescaped [ in pattern without closing ].
130482         Don't pass GLOB_CHECK down to recursive glob for directories.
130483         (__glob_pattern_type): New function.
130484         (__glob_pattern_p): Implement using __glob_pattern_type.
130485         (glob_in_dir): Handle GLOB_NOCHECK patterns containing no meta
130486         characters and backslashes if not GLOB_NOESCAPE or unterminated [.
130487         Remove unreachable code.
130489         2006-09-30  Ulrich Drepper  <drepper@redhat.com>
130491         * lib/glob.c (glob_in_dir): Add some comments and asserts to
130492         explain why there are no leaks.
130494         2006-09-25  Jakub Jelinek  <jakub@redhat.com>
130496         [BZ #3253]
130497         * lib/glob.c (glob_in_dir): Don't alloca one struct globlink at a
130498         time, rather allocate increasingly bigger arrays of pointers, if
130499         possible with alloca, if too large with malloc.
130501 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
130503         Check for 64-bit int errors in HP-UX 10.20 preprocessor.
130504         Problem reported by H.Merijn Brand in
130505         <http://lists.gnu.org/r/bug-tar/2007-10/msg00018.html>.
130506         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Check preprocessor too.
130507         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
130509 2007-10-15  Bruno Haible  <bruno@clisp.org>
130511         * lib/fchdir.c (close, open, closedir, opendir, dup, dup2): Define
130512         with explicit rpl_ prefix.
130513         * lib/fopen.c (fopen): Likewise.
130514         * lib/freopen.c (freopen): Likewise.
130515         * lib/iconv.c (iconv): Likewise.
130516         * lib/iconv_close.c (iconv_close): Likewise.
130518 2007-10-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
130520         * m4/iconv_open (gl_FUNC_ICONV_OPEN_UTF): Fix cache variable name.
130522 2007-10-15  Bruno Haible  <bruno@clisp.org>
130524         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Use
130525         <stddef.h> instead of <stdlib.h> since we only need NULL.
130526         Reported by Ben Pfaff <blp@cs.stanford.edu>.
130528 2007-10-15  Bruno Haible  <bruno@clisp.org>
130530         * doc/gnulib-tool.texi (Initial import): Swap order of -I directives.
130531         Replace paragraph talking about LIBOBJS.
130532         Reported by Colin Watson <cjwatson@debian.org>.
130534 2007-10-15  Bruno Haible  <bruno@clisp.org>
130536         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Include
130537         <stdlib.h> before using NULL.
130539 2007-10-15  Simon Josefsson  <simon@josefsson.org>
130541         * m4/getaddrinfo.m4: Use NULL rather than 0 for pointers.
130542         Reported by Albert Chin <china@thewrittenword.com>.
130544 2007-10-14  Bruno Haible  <bruno@clisp.org>
130546         * modules/iconv_open-utf-tests: New file.
130547         * tests/test-iconv-utf.c: New file.
130549         Enhance iconv_open to support UTF-16BE, UTF-16LE, UTF-32BE, UTF-32LE.
130550         * modules/iconv_open-utf: New file.
130551         * lib/iconv.in.h (_ICONV_UTF8_UTF*, _ICONV_UTF*_UTF8): New macros.
130552         (iconv, iconv_close): New declarations.
130553         * lib/iconv_open.c: Include c-strcase.h. Don't require ICONV_FLAVOR to
130554         be defined.
130555         (iconv_open): Add special handling of conversion between UTF-8 and
130556         UTF-{16,32}{BE,LE}.
130557         * lib/iconv.c: New file, incorporating code from GNU libiconv 1.11.
130558         * lib/iconv_close.c: New file.
130559         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): New macro, extracted from
130560         gl_FUNC_ICONV_OPEN.
130561         (gl_FUNC_ICONV_OPEN): Use it.
130562         (gl_FUNC_ICONV_OPEN_UTF): New macro.
130563         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Initialize also REPLACE_ICONV
130564         and REPLACE_ICONV_UTF.
130565         * modules/iconv_open (Depends-on): Add c-strcase.
130566         (Makefile.am): Substitute also REPLACE_ICONV, REPLACE_ICONV_UTF,
130567         ICONV_CONST.
130568         * doc/functions/iconv_open.texi: Mention the iconv_open-utf module.
130570 2007-10-13  Albert Chin  <china@thewrittenword.com>
130571             Bruno Haible  <bruno@clisp.org>
130573         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Perform the test for getaddrinfo
130574         through a link check that includes <netdb.h>. Needed for OSF/1 5.1.
130576 2007-10-13  Bruno Haible  <bruno@clisp.org>
130578         * lib/argp-fmtstream.h (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is
130579         defined, use the ISO C99 inline semantics.
130580         * lib/argp.h (ARGP_EI): Likewise.
130582 2007-10-13  Bruno Haible  <bruno@clisp.org>
130584         Handle 'inline' change in gcc 4.3.0.
130585         * lib/argp-fmtstream.h (argp_fmtstream_putc, argp_fmtstream_puts,
130586         argp_fmtstream_write, argp_fmtstream_set_lmargin,
130587         argp_fmtstream_set_rmargin, argp_fmtstream_set_wmargin,
130588         argp_fmtstream_point): Disable 'extern' declaration if the function
130589         definition is going to be provided inline.
130590         (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is defined, use the GNU C inline
130591         semantics, not the ISO C99 inline semantics.
130592         * lib/argp.h (argp_usage, _option_is_short, _option_is_end): Disable
130593         'extern' declaration if the function definition is going to be provided
130594         inline.
130595         (ARGP_EI): Don't assume GNU C. If __GNUC_STDC_INLINE__ is defined, use
130596         the GNU C inline semantics, not the ISO C99 inline semantics. With
130597         GCC 4.2, avoid a warning.
130599 2007-10-13  Bruno Haible  <bruno@clisp.org>
130601         * lib/freading.h (freading): Enable the use of __freading for
130602         glibc >= 2.7.
130603         * lib/freading.c (freading): Likewise.
130605 2007-10-12  Paul Eggert  <eggert@cs.ucla.edu>
130607         * lib/argp-fmtstream.h (ARGP_FS_EI): Work around GCC 4.2.1 diagnostic
130608         "warning: C99 inline functions are not supported; using GNU89".
130610 2007-10-12  Bruno Haible  <bruno@clisp.org>
130612         * lib/ceil.c (FUNC): Avoid rounding errors for values near a power
130613         of 2.
130614         * tests/test-ceilf2.c: New file.
130615         * modules/ceilf-tests: (Files, Depends-on, Makefile.am): Add new test.
130617         * tests/test-ceilf1.c: Renamed from tests/test-ceilf.c.
130618         * modules/ceilf-tests: Update.
130620 2007-10-12  Bruno Haible  <bruno@clisp.org>
130622         * lib/floor.c (FUNC): Avoid rounding errors for values near a power
130623         of 2.
130624         * tests/test-floorf2.c: New file.
130625         * modules/floorf-tests: (Files, Depends-on, Makefile.am): Add new test.
130627         * tests/test-floorf1.c: Renamed from tests/test-floorf.c.
130628         * modules/floorf-tests: Update.
130630 2007-10-12  Bruno Haible  <bruno@clisp.org>
130632         * tests/test-trunc2.c: New file.
130633         * modules/trunc-tests: (Files, Depends-on, Makefile.am): Add new test.
130635         * tests/test-trunc1.c: Renamed from tests/test-trunc.c.
130636         * modules/trunc-tests: Update.
130638 2007-10-12  Bruno Haible  <bruno@clisp.org>
130640         * lib/trunc.c (FUNC): Avoid rounding errors for values near a power
130641         of 2.
130642         * tests/test-truncf2.c: New file.
130643         * modules/truncf-tests: (Files, Depends-on, Makefile.am): Add new test.
130645         * tests/test-truncf1.c: Renamed from tests/test-truncf.c.
130646         * modules/truncf-tests: Update.
130648 2007-10-11  Eric Blake  <ebb9@byu.net>
130650         Don't claim strerror is broken on Interix.
130651         * doc/functions/strerror.texi (strerror): Known broken systems are
130652         now Solaris 8, and not Interix.
130653         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): No longer filter out
130654         Interix on cross-compile.
130655         Reported by Martin Koeppe in
130656         http://lists.gnu.org/r/bug-gnulib/2007-10/msg00005.html.
130658 2007-10-11  Bruno Haible  <bruno@clisp.org>
130660         * modules/i-ring-tests: New file.
130661         * tests/test-i-ring.c: Renamed from lib/i-ring-test.c. Use ASSERT
130662         instead of assert.
130664 2007-10-11  Bruno Haible  <bruno@clisp.org>
130666         * modules/filenamecat-tests: New file.
130667         * tests/test-filenamecat.c: New file, extracted from lib/filenamecat.c.
130668         * lib/filenamecat.c: Remove test code.
130670 2007-10-11  Paul Eggert  <eggert@cs.ucla.edu>
130672         Simplify and modernize strerror substitute, partly to fix Solaris 8 bug.
130674         * lib/strerror.c: Include <string.h> always, to test interface,
130675         and to remove the need for the dummy.
130676         Include intprops.h to compute width instead of doing it ourselves
130677         and missing a CHAR_BIT declaration, which broke tar 1.19 on Solaris 8.
130678         (strerror): Define it to return NULL if there's no system strerror.
130679         (rpl_strerror): Use INT_STRLEN_BOUND to compute bound.
130680         Omit !HAVE_STRERROR code.  We don't need to worry about supporting
130681         ancient pre-strerror Unix systems well any more.  Saying "unknown
130682         system error" is enough.
130683         * lib/string.in.h (strerror): Simplify the ifdef to reflect the
130684         simpler strerror.c implementation.
130685         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE, gl_PREREQ_STDERROR):
130686         Simplify the tests to reflect the simpler strerror implementation.
130687         * modules/strerror (Depends-on): Add intprops.
130689 2007-10-09  Eric Blake  <ebb9@byu.net>
130691         Silence test-fpending.
130692         * modules/fpending-tests (Files): Add wrapper script.
130693         * tests/test-fpending.sh: New file.
130695 2007-10-09  Bruno Haible  <bruno@clisp.org>
130697         * MODULES.html.sh (func_module): Don't create a hyperlink for
130698         function names like 'printf_frexp'.
130699         (Misc): Add crc, memxor.
130700         (Characteristics of floating types): New section.
130701         (Mathematics): Add ceilf, ceill, floorf, floorl, frexpl-nolibm,
130702         isnanf-nolibm, signbit, trunc, truncf, truncl.
130703         (Enhancements for ISO C 99 functions): New subsection Input/output.
130704         (Support for systems lacking POSIX:2001): Add arpa_inet, calloc-posix,
130705         fcntl, fopen, freopen, fseek, fseeko, ftell, ftello, iconv_open,
130706         locale, malloc-posix, netinet_in, open, realloc-posix, signal, sleep.
130707         (Compatibility checks for POSIX:2001 functions): Add clock-time.
130708         (Enhancements for POSIX:2001 functions): Add chdir-long.
130709         (File system functions): Add areadlink, chdir-safer, read-file.
130710         Remove cycle-check.
130711         (File system as inode set): New section.
130712         (Date and time): Add gethrxtime.
130713         (Multithreading): Add openmp.
130714         (Internationalization functions): Add localename.
130715         (Unicode string functions): Add unistr/u*-mbsnlen.
130716         (Support for maintaining and releasing projects): Add git-version-gen.
130717         (Lone files): Remove directories.
130719 2007-10-08  Ben Pfaff  <blp@gnu.org>
130721         * lib/xmalloca.h: Fix typo in comment.
130723 2007-10-08  Paul Eggert  <eggert@cs.ucla.edu>
130725         * lib/xnanosleep.c (xnanosleep): Don't assume GCC 4.3.0 behavior
130726         when avoiding problems with integer overflow.  Use a portable test
130727         instead.
130729 2007-10-08  Simon Josefsson  <simon@josefsson.org>
130731         * modules/dummy (License): Change to LGPLv2+.
130732         * modules/float (License): Likewise
130733         * modules/realloc (License): Likewise
130734         * modules/stdlib (License): Likewise
130736 2007-10-07  Bruno Haible  <bruno@clisp.org>
130738         * trunc.c (TWO_MANT_DIG): Change type to DOUBLE.
130739         * floor.c (TWO_MANT_DIG): Likewise.
130740         * ceil.c (TWO_MANT_DIG): Likewise.
130741         Reported by Ben Pfaff.
130743 2007-10-07  Bruno Haible  <bruno@clisp.org>
130745         Avoid gcc warnings "declaration of 'exp' shadows a global declaration".
130746         * lib/math.in.h (frexp, frexpl): Change parameter name to 'expptr'.
130747         * lib/frexp.c (FUNC): Likewise.
130748         * lib/printf-frexp.h (printf_frexp): Likewise.
130749         * lib/printf-frexpl.h (printf_frexpl): Likewise.
130750         * lib/printf-frexp.c (FUNC): Likewise.
130751         Suggested by Jim Meyering.
130753 2007-10-07  Jim Meyering  <meyering@redhat.com>
130755         Make xnanosleep's integer overflow test more robust.
130756         * lib/xnanosleep.c (xnanosleep): Declare a temporary to be "volatile",
130757         so that gcc-4.3.0 doesn't optimize away this test for overflow.
130759 2007-10-07  Bruno Haible  <bruno@clisp.org>
130761         * NEWS: Mention the license change.
130763         * doc/gnulib-intro.texi (Copyright): Update the meaning of the license
130764         abbreviations in the modules files.
130766         Change copyright notice from GPLv2+ to GPLv3+.
130767         * README: Change copyright notice.
130768         * MODULES.html.sh: Likewise.
130769         * build-aux/bootstrap.conf: Likewise.
130770         * build-aux/config.libpath: Likewise.
130771         * build-aux/csharpcomp.sh.in: Likewise.
130772         * build-aux/csharpexec.sh.in: Likewise.
130773         * build-aux/install-reloc: Likewise.
130774         * build-aux/javacomp.sh.in: Likewise.
130775         * build-aux/javaexec.sh.in: Likewise.
130776         * build-aux/ldd.sh.in: Likewise.
130777         * build-aux/reloc-ldflags: Likewise.
130778         * build-aux/relocatable.sh.in: Likewise.
130779         * build-aux/x-to-1.in: Likewise.
130780         * check-module: Likewise.
130781         * config/srclistvars.sh: Likewise.
130782         * gnulib-tool: Likewise.
130783         * lib/acl-internal.h: Likewise.
130784         * lib/acl.c: Likewise.
130785         * lib/acl.h: Likewise.
130786         * lib/acl_entries.c: Likewise.
130787         * lib/areadlink-with-size.c: Likewise.
130788         * lib/areadlink.c: Likewise.
130789         * lib/areadlink.h: Likewise.
130790         * lib/argmatch.c: Likewise.
130791         * lib/argmatch.h: Likewise.
130792         * lib/argp-ba.c: Likewise.
130793         * lib/argp-eexst.c: Likewise.
130794         * lib/argp-fmtstream.c: Likewise.
130795         * lib/argp-fmtstream.h: Likewise.
130796         * lib/argp-fs-xinl.c: Likewise.
130797         * lib/argp-help.c: Likewise.
130798         * lib/argp-namefrob.h: Likewise.
130799         * lib/argp-parse.c: Likewise.
130800         * lib/argp-pin.c: Likewise.
130801         * lib/argp-pv.c: Likewise.
130802         * lib/argp-pvh.c: Likewise.
130803         * lib/argp-xinl.c: Likewise.
130804         * lib/argp.h: Likewise.
130805         * lib/at-func.c: Likewise.
130806         * lib/atanl.c: Likewise.
130807         * lib/backupfile.c: Likewise.
130808         * lib/backupfile.h: Likewise.
130809         * lib/basename.c: Likewise.
130810         * lib/binary-io.h: Likewise.
130811         * lib/byteswap.in.h: Likewise.
130812         * lib/c-stack.c: Likewise.
130813         * lib/c-stack.h: Likewise.
130814         * lib/c-strcasestr.c: Likewise.
130815         * lib/c-strcasestr.h: Likewise.
130816         * lib/c-strstr.c: Likewise.
130817         * lib/c-strstr.h: Likewise.
130818         * lib/c-strtod.c: Likewise.
130819         * lib/calloc.c: Likewise.
130820         * lib/canon-host.c: Likewise.
130821         * lib/canon-host.h: Likewise.
130822         * lib/canonicalize-lgpl.c: Likewise.
130823         * lib/canonicalize.c: Likewise.
130824         * lib/canonicalize.h: Likewise.
130825         * lib/ceil.c: Likewise.
130826         * lib/ceilf.c: Likewise.
130827         * lib/ceill.c: Likewise.
130828         * lib/chdir-long.c: Likewise.
130829         * lib/chdir-long.h: Likewise.
130830         * lib/chdir-safer.c: Likewise.
130831         * lib/chdir-safer.h: Likewise.
130832         * lib/chown.c: Likewise.
130833         * lib/classpath.c: Likewise.
130834         * lib/classpath.h: Likewise.
130835         * lib/clean-temp.c: Likewise.
130836         * lib/clean-temp.h: Likewise.
130837         * lib/cloexec.c: Likewise.
130838         * lib/close-stream.c: Likewise.
130839         * lib/closein.c: Likewise.
130840         * lib/closein.h: Likewise.
130841         * lib/closeout.c: Likewise.
130842         * lib/closeout.h: Likewise.
130843         * lib/concat-filename.c: Likewise.
130844         * lib/copy-file.c: Likewise.
130845         * lib/copy-file.h: Likewise.
130846         * lib/count-one-bits.h: Likewise.
130847         * lib/crc.c: Likewise.
130848         * lib/crc.h: Likewise.
130849         * lib/creat-safer.c: Likewise.
130850         * lib/csharpcomp.c: Likewise.
130851         * lib/csharpcomp.h: Likewise.
130852         * lib/csharpexec.c: Likewise.
130853         * lib/csharpexec.h: Likewise.
130854         * lib/cycle-check.c: Likewise.
130855         * lib/cycle-check.h: Likewise.
130856         * lib/diacrit.c: Likewise.
130857         * lib/diacrit.h: Likewise.
130858         * lib/diffseq.h: Likewise.
130859         * lib/dirchownmod.c: Likewise.
130860         * lib/dirent.in.h: Likewise.
130861         * lib/dirfd.c: Likewise.
130862         * lib/dirfd.h: Likewise.
130863         * lib/dirname.c: Likewise.
130864         * lib/dirname.h: Likewise.
130865         * lib/dummy.c: Likewise.
130866         * lib/dup-safer.c: Likewise.
130867         * lib/dup2.c: Likewise.
130868         * lib/eealloc.h: Likewise.
130869         * lib/error.c: Likewise.
130870         * lib/error.h: Likewise.
130871         * lib/euidaccess.c: Likewise.
130872         * lib/exclude.c: Likewise.
130873         * lib/exclude.h: Likewise.
130874         * lib/execute.c: Likewise.
130875         * lib/execute.h: Likewise.
130876         * lib/exitfail.c: Likewise.
130877         * lib/exitfail.h: Likewise.
130878         * lib/expl.c: Likewise.
130879         * lib/fatal-signal.c: Likewise.
130880         * lib/fatal-signal.h: Likewise.
130881         * lib/fbufmode.c: Likewise.
130882         * lib/fbufmode.h: Likewise.
130883         * lib/fchdir.c: Likewise.
130884         * lib/fchmodat.c: Likewise.
130885         * lib/fchownat.c: Likewise.
130886         * lib/fcntl--.h: Likewise.
130887         * lib/fcntl-safer.h: Likewise.
130888         * lib/fcntl.in.h: Likewise.
130889         * lib/fd-safer.c: Likewise.
130890         * lib/fflush.c: Likewise.
130891         * lib/file-has-acl.c: Likewise.
130892         * lib/file-set.c: Likewise.
130893         * lib/file-type.c: Likewise.
130894         * lib/file-type.h: Likewise.
130895         * lib/fileblocks.c: Likewise.
130896         * lib/filemode.c: Likewise.
130897         * lib/filemode.h: Likewise.
130898         * lib/filename.h: Likewise.
130899         * lib/filenamecat.c: Likewise.
130900         * lib/filenamecat.h: Likewise.
130901         * lib/findprog.c: Likewise.
130902         * lib/findprog.h: Likewise.
130903         * lib/float.in.h: Likewise.
130904         * lib/floor.c: Likewise.
130905         * lib/floorf.c: Likewise.
130906         * lib/floorl.c: Likewise.
130907         * lib/fopen-safer.c: Likewise.
130908         * lib/fopen.c: Likewise.
130909         * lib/fpending.c: Likewise.
130910         * lib/fpending.h: Likewise.
130911         * lib/fprintf.c: Likewise.
130912         * lib/fprintftime.h: Likewise.
130913         * lib/fpucw.h: Likewise.
130914         * lib/fpurge.c: Likewise.
130915         * lib/fpurge.h: Likewise.
130916         * lib/freadable.c: Likewise.
130917         * lib/freadable.h: Likewise.
130918         * lib/freadahead.c: Likewise.
130919         * lib/freadahead.h: Likewise.
130920         * lib/freading.c: Likewise.
130921         * lib/freading.h: Likewise.
130922         * lib/free.c: Likewise.
130923         * lib/freopen.c: Likewise.
130924         * lib/frexp.c: Likewise.
130925         * lib/frexpl.c: Likewise.
130926         * lib/fseek.c: Likewise.
130927         * lib/fseterr.c: Likewise.
130928         * lib/fseterr.h: Likewise.
130929         * lib/fstatat.c: Likewise.
130930         * lib/fstrcmp.c: Likewise.
130931         * lib/fstrcmp.h: Likewise.
130932         * lib/fsusage.c: Likewise.
130933         * lib/fsusage.h: Likewise.
130934         * lib/ftell.c: Likewise.
130935         * lib/ftello.c: Likewise.
130936         * lib/fts-cycle.c: Likewise.
130937         * lib/fts.c: Likewise.
130938         * lib/fts_.h: Likewise.
130939         * lib/full-read.c: Likewise.
130940         * lib/full-read.h: Likewise.
130941         * lib/full-write.c: Likewise.
130942         * lib/full-write.h: Likewise.
130943         * lib/fwritable.c: Likewise.
130944         * lib/fwritable.h: Likewise.
130945         * lib/fwriteerror.c: Likewise.
130946         * lib/fwriteerror.h: Likewise.
130947         * lib/fwriting.c: Likewise.
130948         * lib/fwriting.h: Likewise.
130949         * lib/gcd.c: Likewise.
130950         * lib/gcd.h: Likewise.
130951         * lib/getcwd.c: Likewise.
130952         * lib/getdate.h: Likewise.
130953         * lib/getdate.y: Likewise.
130954         * lib/getdomainname.c: Likewise.
130955         * lib/getdomainname.h: Likewise.
130956         * lib/getgroups.c: Likewise.
130957         * lib/gethostname.c: Likewise.
130958         * lib/gethrxtime.c: Likewise.
130959         * lib/gethrxtime.h: Likewise.
130960         * lib/getloadavg.c: Likewise.
130961         * lib/getndelim2.c: Likewise.
130962         * lib/getndelim2.h: Likewise.
130963         * lib/getnline.c: Likewise.
130964         * lib/getnline.h: Likewise.
130965         * lib/getopt.c: Likewise.
130966         * lib/getopt.in.h: Likewise.
130967         * lib/getopt1.c: Likewise.
130968         * lib/getopt_int.h: Likewise.
130969         * lib/getpagesize.h: Likewise.
130970         * lib/getsubopt.c: Likewise.
130971         * lib/gettime.c: Likewise.
130972         * lib/getugroups.c: Likewise.
130973         * lib/getugroups.h: Likewise.
130974         * lib/getusershell.c: Likewise.
130975         * lib/gl_anyavltree_list1.h: Likewise.
130976         * lib/gl_anyavltree_list2.h: Likewise.
130977         * lib/gl_anyhash_list1.h: Likewise.
130978         * lib/gl_anyhash_list2.h: Likewise.
130979         * lib/gl_anylinked_list1.h: Likewise.
130980         * lib/gl_anylinked_list2.h: Likewise.
130981         * lib/gl_anyrbtree_list1.h: Likewise.
130982         * lib/gl_anyrbtree_list2.h: Likewise.
130983         * lib/gl_anytree_list1.h: Likewise.
130984         * lib/gl_anytree_list2.h: Likewise.
130985         * lib/gl_anytree_oset.h: Likewise.
130986         * lib/gl_anytreehash_list1.h: Likewise.
130987         * lib/gl_anytreehash_list2.h: Likewise.
130988         * lib/gl_array_list.c: Likewise.
130989         * lib/gl_array_list.h: Likewise.
130990         * lib/gl_array_oset.c: Likewise.
130991         * lib/gl_array_oset.h: Likewise.
130992         * lib/gl_avltree_list.c: Likewise.
130993         * lib/gl_avltree_list.h: Likewise.
130994         * lib/gl_avltree_oset.c: Likewise.
130995         * lib/gl_avltree_oset.h: Likewise.
130996         * lib/gl_avltreehash_list.c: Likewise.
130997         * lib/gl_avltreehash_list.h: Likewise.
130998         * lib/gl_carray_list.c: Likewise.
130999         * lib/gl_carray_list.h: Likewise.
131000         * lib/gl_linked_list.c: Likewise.
131001         * lib/gl_linked_list.h: Likewise.
131002         * lib/gl_linkedhash_list.c: Likewise.
131003         * lib/gl_linkedhash_list.h: Likewise.
131004         * lib/gl_list.c: Likewise.
131005         * lib/gl_list.h: Likewise.
131006         * lib/gl_oset.c: Likewise.
131007         * lib/gl_oset.h: Likewise.
131008         * lib/gl_rbtree_list.c: Likewise.
131009         * lib/gl_rbtree_list.h: Likewise.
131010         * lib/gl_rbtree_oset.c: Likewise.
131011         * lib/gl_rbtree_oset.h: Likewise.
131012         * lib/gl_rbtreehash_list.c: Likewise.
131013         * lib/gl_rbtreehash_list.h: Likewise.
131014         * lib/gl_sublist.c: Likewise.
131015         * lib/gl_sublist.h: Likewise.
131016         * lib/group-member.c: Likewise.
131017         * lib/group-member.h: Likewise.
131018         * lib/hard-locale.c: Likewise.
131019         * lib/hard-locale.h: Likewise.
131020         * lib/hash-pjw.c: Likewise.
131021         * lib/hash-pjw.h: Likewise.
131022         * lib/hash-triple.c: Likewise.
131023         * lib/hash.c: Likewise.
131024         * lib/hash.h: Likewise.
131025         * lib/human.c: Likewise.
131026         * lib/human.h: Likewise.
131027         * lib/i-ring.c: Likewise.
131028         * lib/i-ring.h: Likewise.
131029         * lib/idcache.c: Likewise.
131030         * lib/imaxabs.c: Likewise.
131031         * lib/imaxdiv.c: Likewise.
131032         * lib/inet_pton.c: Likewise.
131033         * lib/inet_pton.h: Likewise.
131034         * lib/intprops.h: Likewise.
131035         * lib/inttostr.c: Likewise.
131036         * lib/inttostr.h: Likewise.
131037         * lib/inttypes.in.h: Likewise.
131038         * lib/isapipe.c: Likewise.
131039         * lib/isdir.c: Likewise.
131040         * lib/isnan.c: Likewise.
131041         * lib/isnan.h: Likewise.
131042         * lib/isnanf.c: Likewise.
131043         * lib/isnanf.h: Likewise.
131044         * lib/isnanl-nolibm.h: Likewise.
131045         * lib/isnanl.c: Likewise.
131046         * lib/isnanl.h: Likewise.
131047         * lib/javacomp.c: Likewise.
131048         * lib/javacomp.h: Likewise.
131049         * lib/javaexec.c: Likewise.
131050         * lib/javaexec.h: Likewise.
131051         * lib/javaversion.c: Likewise.
131052         * lib/javaversion.h: Likewise.
131053         * lib/javaversion.java: Likewise.
131054         * lib/lbrkprop.h: Likewise.
131055         * lib/lchmod.h: Likewise.
131056         * lib/lchown.c: Likewise.
131057         * lib/ldexpl.c: Likewise.
131058         * lib/linebreak.c: Likewise.
131059         * lib/linebreak.h: Likewise.
131060         * lib/linebuffer.c: Likewise.
131061         * lib/linebuffer.h: Likewise.
131062         * lib/locale.in.h: Likewise.
131063         * lib/logl.c: Likewise.
131064         * lib/long-options.c: Likewise.
131065         * lib/long-options.h: Likewise.
131066         * lib/lstat.c: Likewise.
131067         * lib/lstat.h: Likewise.
131068         * lib/math.in.h: Likewise.
131069         * lib/mbchar.c: Likewise.
131070         * lib/mbchar.h: Likewise.
131071         * lib/mbfile.h: Likewise.
131072         * lib/mbiter.h: Likewise.
131073         * lib/mbscasecmp.c: Likewise.
131074         * lib/mbscasestr.c: Likewise.
131075         * lib/mbschr.c: Likewise.
131076         * lib/mbscspn.c: Likewise.
131077         * lib/mbslen.c: Likewise.
131078         * lib/mbsncasecmp.c: Likewise.
131079         * lib/mbsnlen.c: Likewise.
131080         * lib/mbspbrk.c: Likewise.
131081         * lib/mbspcasecmp.c: Likewise.
131082         * lib/mbsrchr.c: Likewise.
131083         * lib/mbssep.c: Likewise.
131084         * lib/mbsspn.c: Likewise.
131085         * lib/mbsstr.c: Likewise.
131086         * lib/mbstok_r.c: Likewise.
131087         * lib/mbswidth.c: Likewise.
131088         * lib/mbswidth.h: Likewise.
131089         * lib/mbuiter.h: Likewise.
131090         * lib/memcasecmp.c: Likewise.
131091         * lib/memcasecmp.h: Likewise.
131092         * lib/memchr.c: Likewise.
131093         * lib/memcmp.c: Likewise.
131094         * lib/memcoll.c: Likewise.
131095         * lib/memcoll.h: Likewise.
131096         * lib/memcpy.c: Likewise.
131097         * lib/memrchr.c: Likewise.
131098         * lib/mkancesdirs.c: Likewise.
131099         * lib/mkdir-p.c: Likewise.
131100         * lib/mkdir-p.h: Likewise.
131101         * lib/mkdir.c: Likewise.
131102         * lib/mkdirat.c: Likewise.
131103         * lib/mkdtemp.c: Likewise.
131104         * lib/mkstemp-safer.c: Likewise.
131105         * lib/mkstemp.c: Likewise.
131106         * lib/modechange.c: Likewise.
131107         * lib/modechange.h: Likewise.
131108         * lib/mountlist.c: Likewise.
131109         * lib/mountlist.h: Likewise.
131110         * lib/mpsort.c: Likewise.
131111         * lib/nanosleep.c: Likewise.
131112         * lib/obstack.c: Likewise.
131113         * lib/obstack.h: Likewise.
131114         * lib/open-safer.c: Likewise.
131115         * lib/open.c: Likewise.
131116         * lib/openat-die.c: Likewise.
131117         * lib/openat-priv.h: Likewise.
131118         * lib/openat-proc.c: Likewise.
131119         * lib/openat.c: Likewise.
131120         * lib/openat.h: Likewise.
131121         * lib/pagealign_alloc.c: Likewise.
131122         * lib/pagealign_alloc.h: Likewise.
131123         * lib/physmem.c: Likewise.
131124         * lib/physmem.h: Likewise.
131125         * lib/pipe-safer.c: Likewise.
131126         * lib/pipe.c: Likewise.
131127         * lib/pipe.h: Likewise.
131128         * lib/posixtm.c: Likewise.
131129         * lib/posixtm.h: Likewise.
131130         * lib/posixver.c: Likewise.
131131         * lib/printf-frexp.c: Likewise.
131132         * lib/printf-frexp.h: Likewise.
131133         * lib/printf-frexpl.c: Likewise.
131134         * lib/printf-frexpl.h: Likewise.
131135         * lib/printf.c: Likewise.
131136         * lib/progname.c: Likewise.
131137         * lib/progname.h: Likewise.
131138         * lib/progreloc.c: Likewise.
131139         * lib/putenv.c: Likewise.
131140         * lib/quote.c: Likewise.
131141         * lib/quote.h: Likewise.
131142         * lib/quotearg.c: Likewise.
131143         * lib/quotearg.h: Likewise.
131144         * lib/raise.c: Likewise.
131145         * lib/readline.c: Likewise.
131146         * lib/readline.h: Likewise.
131147         * lib/readlink.c: Likewise.
131148         * lib/readtokens.c: Likewise.
131149         * lib/readtokens.h: Likewise.
131150         * lib/readtokens0.c: Likewise.
131151         * lib/readtokens0.h: Likewise.
131152         * lib/readutmp.c: Likewise.
131153         * lib/readutmp.h: Likewise.
131154         * lib/realloc.c: Likewise.
131155         * lib/relocwrapper.c: Likewise.
131156         * lib/rename-dest-slash.c: Likewise.
131157         * lib/rename.c: Likewise.
131158         * lib/rmdir.c: Likewise.
131159         * lib/rpmatch.c: Likewise.
131160         * lib/safe-read.c: Likewise.
131161         * lib/safe-read.h: Likewise.
131162         * lib/safe-write.c: Likewise.
131163         * lib/safe-write.h: Likewise.
131164         * lib/same-inode.h: Likewise.
131165         * lib/same.c: Likewise.
131166         * lib/same.h: Likewise.
131167         * lib/save-cwd.c: Likewise.
131168         * lib/save-cwd.h: Likewise.
131169         * lib/savedir.c: Likewise.
131170         * lib/savedir.h: Likewise.
131171         * lib/savewd.c: Likewise.
131172         * lib/savewd.h: Likewise.
131173         * lib/search.in.h: Likewise.
131174         * lib/setenv.c: Likewise.
131175         * lib/setenv.h: Likewise.
131176         * lib/settime.c: Likewise.
131177         * lib/sh-quote.c: Likewise.
131178         * lib/sh-quote.h: Likewise.
131179         * lib/sig2str.c: Likewise.
131180         * lib/sig2str.h: Likewise.
131181         * lib/signal.in.h: Likewise.
131182         * lib/signbitd.c: Likewise.
131183         * lib/signbitf.c: Likewise.
131184         * lib/signbitl.c: Likewise.
131185         * lib/sigprocmask.c: Likewise.
131186         * lib/sincosl.c: Likewise.
131187         * lib/sleep.c: Likewise.
131188         * lib/sprintf.c: Likewise.
131189         * lib/sqrtl.c: Likewise.
131190         * lib/stat-time.h: Likewise.
131191         * lib/stdio--.h: Likewise.
131192         * lib/stdio-safer.h: Likewise.
131193         * lib/stdlib--.h: Likewise.
131194         * lib/stdlib-safer.h: Likewise.
131195         * lib/stdlib.in.h: Likewise.
131196         * lib/stpcpy.c: Likewise.
131197         * lib/stpncpy.c: Likewise.
131198         * lib/strchrnul.c: Likewise.
131199         * lib/strcspn.c: Likewise.
131200         * lib/strerror.c: Likewise.
131201         * lib/strftime.c: Likewise.
131202         * lib/strftime.h: Likewise.
131203         * lib/striconveh.c: Likewise.
131204         * lib/striconveh.h: Likewise.
131205         * lib/striconveha.c: Likewise.
131206         * lib/striconveha.h: Likewise.
131207         * lib/stripslash.c: Likewise.
131208         * lib/strnlen1.c: Likewise.
131209         * lib/strnlen1.h: Likewise.
131210         * lib/strtod.c: Likewise.
131211         * lib/strtoimax.c: Likewise.
131212         * lib/strtok_r.c: Likewise.
131213         * lib/strtol.c: Likewise.
131214         * lib/strtoll.c: Likewise.
131215         * lib/strtoul.c: Likewise.
131216         * lib/strtoull.c: Likewise.
131217         * lib/sysexits.in.h: Likewise.
131218         * lib/tempname.c: Likewise.
131219         * lib/tempname.h: Likewise.
131220         * lib/timespec.h: Likewise.
131221         * lib/tls.c: Likewise.
131222         * lib/tls.h: Likewise.
131223         * lib/tmpdir.c: Likewise.
131224         * lib/tmpdir.h: Likewise.
131225         * lib/tmpfile-safer.c: Likewise.
131226         * lib/tmpfile.c: Likewise.
131227         * lib/trigl.c: Likewise.
131228         * lib/trigl.h: Likewise.
131229         * lib/trim.c: Likewise.
131230         * lib/trim.h: Likewise.
131231         * lib/trunc.c: Likewise.
131232         * lib/truncf.c: Likewise.
131233         * lib/truncl.c: Likewise.
131234         * lib/tsearch.c: Likewise.
131235         * lib/unicodeio.c: Likewise.
131236         * lib/unicodeio.h: Likewise.
131237         * lib/unistd--.h: Likewise.
131238         * lib/unistd-safer.h: Likewise.
131239         * lib/unistdio/ulc-fprintf.c: Likewise.
131240         * lib/unistdio/ulc-vfprintf.c: Likewise.
131241         * lib/unlinkdir.c: Likewise.
131242         * lib/unlinkdir.h: Likewise.
131243         * lib/unlocked-io.h: Likewise.
131244         * lib/unsetenv.c: Likewise.
131245         * lib/userspec.c: Likewise.
131246         * lib/utime.c: Likewise.
131247         * lib/utimecmp.c: Likewise.
131248         * lib/utimecmp.h: Likewise.
131249         * lib/utimens.c: Likewise.
131250         * lib/verify.h: Likewise.
131251         * lib/verror.c: Likewise.
131252         * lib/verror.h: Likewise.
131253         * lib/version-etc-fsf.c: Likewise.
131254         * lib/version-etc.c: Likewise.
131255         * lib/version-etc.h: Likewise.
131256         * lib/vfprintf.c: Likewise.
131257         * lib/vprintf.c: Likewise.
131258         * lib/vsprintf.c: Likewise.
131259         * lib/w32spawn.h: Likewise.
131260         * lib/wait-process.c: Likewise.
131261         * lib/wait-process.h: Likewise.
131262         * lib/wcwidth.c: Likewise.
131263         * lib/write-any-file.c: Likewise.
131264         * lib/xalloc-die.c: Likewise.
131265         * lib/xalloc.h: Likewise.
131266         * lib/xasprintf.c: Likewise.
131267         * lib/xgetcwd.c: Likewise.
131268         * lib/xgetcwd.h: Likewise.
131269         * lib/xgetdomainname.c: Likewise.
131270         * lib/xgetdomainname.h: Likewise.
131271         * lib/xgethostname.c: Likewise.
131272         * lib/xmalloc.c: Likewise.
131273         * lib/xmalloca.c: Likewise.
131274         * lib/xmalloca.h: Likewise.
131275         * lib/xmemcoll.c: Likewise.
131276         * lib/xnanosleep.c: Likewise.
131277         * lib/xreadlink.c: Likewise.
131278         * lib/xreadlink.h: Likewise.
131279         * lib/xsetenv.c: Likewise.
131280         * lib/xsetenv.h: Likewise.
131281         * lib/xstriconv.c: Likewise.
131282         * lib/xstriconv.h: Likewise.
131283         * lib/xstrndup.c: Likewise.
131284         * lib/xstrndup.h: Likewise.
131285         * lib/xstrtod.c: Likewise.
131286         * lib/xstrtod.h: Likewise.
131287         * lib/xstrtol-error.c: Likewise.
131288         * lib/xstrtol.c: Likewise.
131289         * lib/xstrtol.h: Likewise.
131290         * lib/xtime.h: Likewise.
131291         * lib/xvasprintf.c: Likewise.
131292         * lib/xvasprintf.h: Likewise.
131293         * lib/yesno.c: Likewise.
131294         * lib/yesno.h: Likewise.
131295         * posix-modules: Likewise.
131296         * tests/test-alloca-opt.c: Likewise.
131297         * tests/test-arcfour.c: Likewise.
131298         * tests/test-arctwo.c: Likewise.
131299         * tests/test-argmatch.c: Likewise.
131300         * tests/test-argp-2.sh: Likewise.
131301         * tests/test-argp.c: Likewise.
131302         * tests/test-arpa_inet.c: Likewise.
131303         * tests/test-array_list.c: Likewise.
131304         * tests/test-array_oset.c: Likewise.
131305         * tests/test-atexit.c: Likewise.
131306         * tests/test-avltree_list.c: Likewise.
131307         * tests/test-avltree_oset.c: Likewise.
131308         * tests/test-avltreehash_list.c: Likewise.
131309         * tests/test-base64.c: Likewise.
131310         * tests/test-binary-io.c: Likewise.
131311         * tests/test-byteswap.c: Likewise.
131312         * tests/test-c-ctype.c: Likewise.
131313         * tests/test-c-strcasecmp.c: Likewise.
131314         * tests/test-c-strcasestr.c: Likewise.
131315         * tests/test-c-strncasecmp.c: Likewise.
131316         * tests/test-c-strstr.c: Likewise.
131317         * tests/test-canonicalize-lgpl.c: Likewise.
131318         * tests/test-canonicalize.c: Likewise.
131319         * tests/test-carray_list.c: Likewise.
131320         * tests/test-ceilf.c: Likewise.
131321         * tests/test-ceill.c: Likewise.
131322         * tests/test-count-one-bits.c: Likewise.
131323         * tests/test-crc.c: Likewise.
131324         * tests/test-dirname.c: Likewise.
131325         * tests/test-fbufmode.c: Likewise.
131326         * tests/test-fcntl.c: Likewise.
131327         * tests/test-fflush.c: Likewise.
131328         * tests/test-floorf.c: Likewise.
131329         * tests/test-floorl.c: Likewise.
131330         * tests/test-fopen.c: Likewise.
131331         * tests/test-fprintf-posix.c: Likewise.
131332         * tests/test-fprintf-posix.h: Likewise.
131333         * tests/test-fpurge.c: Likewise.
131334         * tests/test-freadable.c: Likewise.
131335         * tests/test-freadahead.c: Likewise.
131336         * tests/test-freading.c: Likewise.
131337         * tests/test-freopen.c: Likewise.
131338         * tests/test-frexp.c: Likewise.
131339         * tests/test-frexpl.c: Likewise.
131340         * tests/test-fseek.c: Likewise.
131341         * tests/test-fseeko.c: Likewise.
131342         * tests/test-fseterr.c: Likewise.
131343         * tests/test-fstrcmp.c: Likewise.
131344         * tests/test-ftell.c: Likewise.
131345         * tests/test-ftello.c: Likewise.
131346         * tests/test-fwritable.c: Likewise.
131347         * tests/test-fwriting.c: Likewise.
131348         * tests/test-getaddrinfo.c: Likewise.
131349         * tests/test-getpass.c: Likewise.
131350         * tests/test-gettimeofday.c: Likewise.
131351         * tests/test-hmac-md5.c: Likewise.
131352         * tests/test-hmac-sha1.c: Likewise.
131353         * tests/test-iconv.c: Likewise.
131354         * tests/test-iconvme.c: Likewise.
131355         * tests/test-inttypes.c: Likewise.
131356         * tests/test-isnan.c: Likewise.
131357         * tests/test-isnanf.c: Likewise.
131358         * tests/test-isnanl-nolibm.c: Likewise.
131359         * tests/test-isnanl.c: Likewise.
131360         * tests/test-isnanl.h: Likewise.
131361         * tests/test-ldexpl.c: Likewise.
131362         * tests/test-linked_list.c: Likewise.
131363         * tests/test-linkedhash_list.c: Likewise.
131364         * tests/test-locale.c: Likewise.
131365         * tests/test-localename.c: Likewise.
131366         * tests/test-lock.c: Likewise.
131367         * tests/test-lseek.c: Likewise.
131368         * tests/test-malloca.c: Likewise.
131369         * tests/test-math.c: Likewise.
131370         * tests/test-mbscasecmp.c: Likewise.
131371         * tests/test-mbscasestr1.c: Likewise.
131372         * tests/test-mbscasestr2.c: Likewise.
131373         * tests/test-mbscasestr3.c: Likewise.
131374         * tests/test-mbscasestr4.c: Likewise.
131375         * tests/test-mbschr.c: Likewise.
131376         * tests/test-mbscspn.c: Likewise.
131377         * tests/test-mbsncasecmp.c: Likewise.
131378         * tests/test-mbspbrk.c: Likewise.
131379         * tests/test-mbspcasecmp.c: Likewise.
131380         * tests/test-mbsrchr.c: Likewise.
131381         * tests/test-mbsspn.c: Likewise.
131382         * tests/test-mbsstr1.c: Likewise.
131383         * tests/test-mbsstr2.c: Likewise.
131384         * tests/test-mbsstr3.c: Likewise.
131385         * tests/test-md5.c: Likewise.
131386         * tests/test-memmem.c: Likewise.
131387         * tests/test-netinet_in.c: Likewise.
131388         * tests/test-open.c: Likewise.
131389         * tests/test-printf-frexp.c: Likewise.
131390         * tests/test-printf-frexpl.c: Likewise.
131391         * tests/test-printf-posix.c: Likewise.
131392         * tests/test-printf-posix.h: Likewise.
131393         * tests/test-rbtree_list.c: Likewise.
131394         * tests/test-rbtree_oset.c: Likewise.
131395         * tests/test-rbtreehash_list.c: Likewise.
131396         * tests/test-read-file.c: Likewise.
131397         * tests/test-rijndael.c: Likewise.
131398         * tests/test-search.c: Likewise.
131399         * tests/test-signbit.c: Likewise.
131400         * tests/test-sleep.c: Likewise.
131401         * tests/test-snprintf-posix.c: Likewise.
131402         * tests/test-snprintf-posix.h: Likewise.
131403         * tests/test-snprintf.c: Likewise.
131404         * tests/test-sprintf-posix.c: Likewise.
131405         * tests/test-sprintf-posix.h: Likewise.
131406         * tests/test-stat-time.c: Likewise.
131407         * tests/test-stdbool.c: Likewise.
131408         * tests/test-stdint.c: Likewise.
131409         * tests/test-stdio.c: Likewise.
131410         * tests/test-stdlib.c: Likewise.
131411         * tests/test-stpncpy.c: Likewise.
131412         * tests/test-strcasestr.c: Likewise.
131413         * tests/test-striconv.c: Likewise.
131414         * tests/test-striconveh.c: Likewise.
131415         * tests/test-striconveha.c: Likewise.
131416         * tests/test-string.c: Likewise.
131417         * tests/test-sys_select.c: Likewise.
131418         * tests/test-sys_socket.c: Likewise.
131419         * tests/test-sys_stat.c: Likewise.
131420         * tests/test-sys_time.c: Likewise.
131421         * tests/test-sysexits.c: Likewise.
131422         * tests/test-time.c: Likewise.
131423         * tests/test-tls.c: Likewise.
131424         * tests/test-trunc.c: Likewise.
131425         * tests/test-truncf.c: Likewise.
131426         * tests/test-truncl.c: Likewise.
131427         * tests/test-unistd.c: Likewise.
131428         * tests/test-vasnprintf-posix.c: Likewise.
131429         * tests/test-vasnprintf-posix2.c: Likewise.
131430         * tests/test-vasnprintf.c: Likewise.
131431         * tests/test-vasprintf-posix.c: Likewise.
131432         * tests/test-vasprintf.c: Likewise.
131433         * tests/test-verify.c: Likewise.
131434         * tests/test-vfprintf-posix.c: Likewise.
131435         * tests/test-vprintf-posix.c: Likewise.
131436         * tests/test-vsnprintf-posix.c: Likewise.
131437         * tests/test-vsnprintf.c: Likewise.
131438         * tests/test-vsprintf-posix.c: Likewise.
131439         * tests/test-wchar.c: Likewise.
131440         * tests/test-wctype.c: Likewise.
131441         * tests/test-wcwidth.c: Likewise.
131442         * tests/test-xstrtol.c: Likewise.
131443         * tests/test-xvasprintf.c: Likewise.
131444         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
131445         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
131446         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
131447         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
131448         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
131449         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
131450         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
131451         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
131452         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
131453         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
131454         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
131455         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
131456         * tests/uniname/test-uninames.c: Likewise.
131457         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
131458         * tests/unistdio/test-u16-asnprintf1.h: Likewise.
131459         * tests/unistdio/test-u16-printf1.h: Likewise.
131460         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
131461         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
131462         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
131463         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
131464         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
131465         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
131466         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
131467         * tests/unistdio/test-u32-asnprintf1.h: Likewise.
131468         * tests/unistdio/test-u32-printf1.h: Likewise.
131469         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
131470         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
131471         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
131472         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
131473         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
131474         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
131475         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
131476         * tests/unistdio/test-u8-asnprintf1.h: Likewise.
131477         * tests/unistdio/test-u8-printf1.h: Likewise.
131478         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
131479         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
131480         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
131481         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
131482         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
131483         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
131484         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
131485         * tests/unistdio/test-ulc-asnprintf1.h: Likewise.
131486         * tests/unistdio/test-ulc-printf1.h: Likewise.
131487         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
131488         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
131489         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
131490         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
131491         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
131492         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
131493         * tests/uniwidth/test-u16-strwidth.c: Likewise.
131494         * tests/uniwidth/test-u16-width.c: Likewise.
131495         * tests/uniwidth/test-u32-strwidth.c: Likewise.
131496         * tests/uniwidth/test-u32-width.c: Likewise.
131497         * tests/uniwidth/test-u8-strwidth.c: Likewise.
131498         * tests/uniwidth/test-u8-width.c: Likewise.
131499         * tests/uniwidth/test-uc_width.c: Likewise.
131500         * config/srclist-update: Likewise.
131501         (fixlicense): Update to GPLv3+.
131503         Change copyright notice from LGPLv2.1+ to LGPLv3+.
131504         * tests/test-tsearch.c: Change copyright notice.
131506         Change copyright notice from LGPLv2.0+ to LGPLv3+.
131507         * lib/c-strcaseeq.h: Change copyright notice.
131508         * lib/streq.h: Likewise.
131509         * lib/uniconv.h: Likewise.
131510         * lib/uniconv/u-conv-from-enc.h: Likewise.
131511         * lib/uniconv/u-conv-to-enc.h: Likewise.
131512         * lib/uniconv/u-strconv-from-enc.h: Likewise.
131513         * lib/uniconv/u-strconv-to-enc.h: Likewise.
131514         * lib/uniconv/u16-conv-from-enc.c: Likewise.
131515         * lib/uniconv/u16-conv-to-enc.c: Likewise.
131516         * lib/uniconv/u16-strconv-from-enc.c: Likewise.
131517         * lib/uniconv/u16-strconv-from-locale.c: Likewise.
131518         * lib/uniconv/u16-strconv-to-enc.c: Likewise.
131519         * lib/uniconv/u16-strconv-to-locale.c: Likewise.
131520         * lib/uniconv/u32-conv-from-enc.c: Likewise.
131521         * lib/uniconv/u32-conv-to-enc.c: Likewise.
131522         * lib/uniconv/u32-strconv-from-enc.c: Likewise.
131523         * lib/uniconv/u32-strconv-from-locale.c: Likewise.
131524         * lib/uniconv/u32-strconv-to-enc.c: Likewise.
131525         * lib/uniconv/u32-strconv-to-locale.c: Likewise.
131526         * lib/uniconv/u8-conv-from-enc.c: Likewise.
131527         * lib/uniconv/u8-conv-to-enc.c: Likewise.
131528         * lib/uniconv/u8-strconv-from-enc.c: Likewise.
131529         * lib/uniconv/u8-strconv-from-locale.c: Likewise.
131530         * lib/uniconv/u8-strconv-to-enc.c: Likewise.
131531         * lib/uniconv/u8-strconv-to-locale.c: Likewise.
131532         * lib/uniname.h: Likewise.
131533         * lib/uniname/uniname.c: Likewise.
131534         * lib/unistdio.h: Likewise.
131535         * lib/unistdio/u-asnprintf.h: Likewise.
131536         * lib/unistdio/u-asprintf.h: Likewise.
131537         * lib/unistdio/u-printf-args.c: Likewise.
131538         * lib/unistdio/u-printf-args.h: Likewise.
131539         * lib/unistdio/u-printf-parse.h: Likewise.
131540         * lib/unistdio/u-snprintf.h: Likewise.
131541         * lib/unistdio/u-sprintf.h: Likewise.
131542         * lib/unistdio/u-vasprintf.h: Likewise.
131543         * lib/unistdio/u-vsnprintf.h: Likewise.
131544         * lib/unistdio/u-vsprintf.h: Likewise.
131545         * lib/unistdio/u16-asnprintf.c: Likewise.
131546         * lib/unistdio/u16-asprintf.c: Likewise.
131547         * lib/unistdio/u16-printf-parse.c: Likewise.
131548         * lib/unistdio/u16-snprintf.c: Likewise.
131549         * lib/unistdio/u16-sprintf.c: Likewise.
131550         * lib/unistdio/u16-u16-asnprintf.c: Likewise.
131551         * lib/unistdio/u16-u16-asprintf.c: Likewise.
131552         * lib/unistdio/u16-u16-snprintf.c: Likewise.
131553         * lib/unistdio/u16-u16-sprintf.c: Likewise.
131554         * lib/unistdio/u16-u16-vasnprintf.c: Likewise.
131555         * lib/unistdio/u16-u16-vasprintf.c: Likewise.
131556         * lib/unistdio/u16-u16-vsnprintf.c: Likewise.
131557         * lib/unistdio/u16-u16-vsprintf.c: Likewise.
131558         * lib/unistdio/u16-vasnprintf.c: Likewise.
131559         * lib/unistdio/u16-vasprintf.c: Likewise.
131560         * lib/unistdio/u16-vsnprintf.c: Likewise.
131561         * lib/unistdio/u16-vsprintf.c: Likewise.
131562         * lib/unistdio/u32-asnprintf.c: Likewise.
131563         * lib/unistdio/u32-asprintf.c: Likewise.
131564         * lib/unistdio/u32-printf-parse.c: Likewise.
131565         * lib/unistdio/u32-snprintf.c: Likewise.
131566         * lib/unistdio/u32-sprintf.c: Likewise.
131567         * lib/unistdio/u32-u32-asnprintf.c: Likewise.
131568         * lib/unistdio/u32-u32-asprintf.c: Likewise.
131569         * lib/unistdio/u32-u32-snprintf.c: Likewise.
131570         * lib/unistdio/u32-u32-sprintf.c: Likewise.
131571         * lib/unistdio/u32-u32-vasnprintf.c: Likewise.
131572         * lib/unistdio/u32-u32-vasprintf.c: Likewise.
131573         * lib/unistdio/u32-u32-vsnprintf.c: Likewise.
131574         * lib/unistdio/u32-u32-vsprintf.c: Likewise.
131575         * lib/unistdio/u32-vasnprintf.c: Likewise.
131576         * lib/unistdio/u32-vasprintf.c: Likewise.
131577         * lib/unistdio/u32-vsnprintf.c: Likewise.
131578         * lib/unistdio/u32-vsprintf.c: Likewise.
131579         * lib/unistdio/u8-asnprintf.c: Likewise.
131580         * lib/unistdio/u8-asprintf.c: Likewise.
131581         * lib/unistdio/u8-printf-parse.c: Likewise.
131582         * lib/unistdio/u8-snprintf.c: Likewise.
131583         * lib/unistdio/u8-sprintf.c: Likewise.
131584         * lib/unistdio/u8-u8-asnprintf.c: Likewise.
131585         * lib/unistdio/u8-u8-asprintf.c: Likewise.
131586         * lib/unistdio/u8-u8-snprintf.c: Likewise.
131587         * lib/unistdio/u8-u8-sprintf.c: Likewise.
131588         * lib/unistdio/u8-u8-vasnprintf.c: Likewise.
131589         * lib/unistdio/u8-u8-vasprintf.c: Likewise.
131590         * lib/unistdio/u8-u8-vsnprintf.c: Likewise.
131591         * lib/unistdio/u8-u8-vsprintf.c: Likewise.
131592         * lib/unistdio/u8-vasnprintf.c: Likewise.
131593         * lib/unistdio/u8-vasprintf.c: Likewise.
131594         * lib/unistdio/u8-vsnprintf.c: Likewise.
131595         * lib/unistdio/u8-vsprintf.c: Likewise.
131596         * lib/unistdio/ulc-asnprintf.c: Likewise.
131597         * lib/unistdio/ulc-asprintf.c: Likewise.
131598         * lib/unistdio/ulc-printf-parse.c: Likewise.
131599         * lib/unistdio/ulc-snprintf.c: Likewise.
131600         * lib/unistdio/ulc-sprintf.c: Likewise.
131601         * lib/unistdio/ulc-vasnprintf.c: Likewise.
131602         * lib/unistdio/ulc-vasprintf.c: Likewise.
131603         * lib/unistdio/ulc-vsnprintf.c: Likewise.
131604         * lib/unistdio/ulc-vsprintf.c: Likewise.
131605         * lib/unistr.h: Likewise.
131606         * lib/unistr/u-cpy-alloc.h: Likewise.
131607         * lib/unistr/u-cpy.h: Likewise.
131608         * lib/unistr/u-endswith.h: Likewise.
131609         * lib/unistr/u-move.h: Likewise.
131610         * lib/unistr/u-set.h: Likewise.
131611         * lib/unistr/u-startswith.h: Likewise.
131612         * lib/unistr/u-stpcpy.h: Likewise.
131613         * lib/unistr/u-stpncpy.h: Likewise.
131614         * lib/unistr/u-strcat.h: Likewise.
131615         * lib/unistr/u-strcpy.h: Likewise.
131616         * lib/unistr/u-strcspn.h: Likewise.
131617         * lib/unistr/u-strdup.h: Likewise.
131618         * lib/unistr/u-strlen.h: Likewise.
131619         * lib/unistr/u-strncat.h: Likewise.
131620         * lib/unistr/u-strncpy.h: Likewise.
131621         * lib/unistr/u-strnlen.h: Likewise.
131622         * lib/unistr/u-strpbrk.h: Likewise.
131623         * lib/unistr/u-strspn.h: Likewise.
131624         * lib/unistr/u-strstr.h: Likewise.
131625         * lib/unistr/u-strtok.h: Likewise.
131626         * lib/unistr/u16-check.c: Likewise.
131627         * lib/unistr/u16-chr.c: Likewise.
131628         * lib/unistr/u16-cmp.c: Likewise.
131629         * lib/unistr/u16-cpy-alloc.c: Likewise.
131630         * lib/unistr/u16-cpy.c: Likewise.
131631         * lib/unistr/u16-endswith.c: Likewise.
131632         * lib/unistr/u16-mblen.c: Likewise.
131633         * lib/unistr/u16-mbsnlen.c: Likewise.
131634         * lib/unistr/u16-mbtouc-aux.c: Likewise.
131635         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
131636         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
131637         * lib/unistr/u16-mbtouc.c: Likewise.
131638         * lib/unistr/u16-mbtoucr.c: Likewise.
131639         * lib/unistr/u16-move.c: Likewise.
131640         * lib/unistr/u16-next.c: Likewise.
131641         * lib/unistr/u16-prev.c: Likewise.
131642         * lib/unistr/u16-set.c: Likewise.
131643         * lib/unistr/u16-startswith.c: Likewise.
131644         * lib/unistr/u16-stpcpy.c: Likewise.
131645         * lib/unistr/u16-stpncpy.c: Likewise.
131646         * lib/unistr/u16-strcat.c: Likewise.
131647         * lib/unistr/u16-strchr.c: Likewise.
131648         * lib/unistr/u16-strcmp.c: Likewise.
131649         * lib/unistr/u16-strcpy.c: Likewise.
131650         * lib/unistr/u16-strcspn.c: Likewise.
131651         * lib/unistr/u16-strdup.c: Likewise.
131652         * lib/unistr/u16-strlen.c: Likewise.
131653         * lib/unistr/u16-strmblen.c: Likewise.
131654         * lib/unistr/u16-strmbtouc.c: Likewise.
131655         * lib/unistr/u16-strncat.c: Likewise.
131656         * lib/unistr/u16-strncmp.c: Likewise.
131657         * lib/unistr/u16-strncpy.c: Likewise.
131658         * lib/unistr/u16-strnlen.c: Likewise.
131659         * lib/unistr/u16-strpbrk.c: Likewise.
131660         * lib/unistr/u16-strrchr.c: Likewise.
131661         * lib/unistr/u16-strspn.c: Likewise.
131662         * lib/unistr/u16-strstr.c: Likewise.
131663         * lib/unistr/u16-strtok.c: Likewise.
131664         * lib/unistr/u16-to-u32.c: Likewise.
131665         * lib/unistr/u16-to-u8.c: Likewise.
131666         * lib/unistr/u16-uctomb-aux.c: Likewise.
131667         * lib/unistr/u16-uctomb.c: Likewise.
131668         * lib/unistr/u32-check.c: Likewise.
131669         * lib/unistr/u32-chr.c: Likewise.
131670         * lib/unistr/u32-cmp.c: Likewise.
131671         * lib/unistr/u32-cpy-alloc.c: Likewise.
131672         * lib/unistr/u32-cpy.c: Likewise.
131673         * lib/unistr/u32-endswith.c: Likewise.
131674         * lib/unistr/u32-mblen.c: Likewise.
131675         * lib/unistr/u32-mbsnlen.c: Likewise.
131676         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
131677         * lib/unistr/u32-mbtouc.c: Likewise.
131678         * lib/unistr/u32-mbtoucr.c: Likewise.
131679         * lib/unistr/u32-move.c: Likewise.
131680         * lib/unistr/u32-next.c: Likewise.
131681         * lib/unistr/u32-prev.c: Likewise.
131682         * lib/unistr/u32-set.c: Likewise.
131683         * lib/unistr/u32-startswith.c: Likewise.
131684         * lib/unistr/u32-stpcpy.c: Likewise.
131685         * lib/unistr/u32-stpncpy.c: Likewise.
131686         * lib/unistr/u32-strcat.c: Likewise.
131687         * lib/unistr/u32-strchr.c: Likewise.
131688         * lib/unistr/u32-strcmp.c: Likewise.
131689         * lib/unistr/u32-strcpy.c: Likewise.
131690         * lib/unistr/u32-strcspn.c: Likewise.
131691         * lib/unistr/u32-strdup.c: Likewise.
131692         * lib/unistr/u32-strlen.c: Likewise.
131693         * lib/unistr/u32-strmblen.c: Likewise.
131694         * lib/unistr/u32-strmbtouc.c: Likewise.
131695         * lib/unistr/u32-strncat.c: Likewise.
131696         * lib/unistr/u32-strncmp.c: Likewise.
131697         * lib/unistr/u32-strncpy.c: Likewise.
131698         * lib/unistr/u32-strnlen.c: Likewise.
131699         * lib/unistr/u32-strpbrk.c: Likewise.
131700         * lib/unistr/u32-strrchr.c: Likewise.
131701         * lib/unistr/u32-strspn.c: Likewise.
131702         * lib/unistr/u32-strstr.c: Likewise.
131703         * lib/unistr/u32-strtok.c: Likewise.
131704         * lib/unistr/u32-to-u16.c: Likewise.
131705         * lib/unistr/u32-to-u8.c: Likewise.
131706         * lib/unistr/u32-uctomb.c: Likewise.
131707         * lib/unistr/u8-check.c: Likewise.
131708         * lib/unistr/u8-chr.c: Likewise.
131709         * lib/unistr/u8-cmp.c: Likewise.
131710         * lib/unistr/u8-cpy-alloc.c: Likewise.
131711         * lib/unistr/u8-cpy.c: Likewise.
131712         * lib/unistr/u8-endswith.c: Likewise.
131713         * lib/unistr/u8-mblen.c: Likewise.
131714         * lib/unistr/u8-mbsnlen.c: Likewise.
131715         * lib/unistr/u8-mbtouc-aux.c: Likewise.
131716         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
131717         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
131718         * lib/unistr/u8-mbtouc.c: Likewise.
131719         * lib/unistr/u8-mbtoucr.c: Likewise.
131720         * lib/unistr/u8-move.c: Likewise.
131721         * lib/unistr/u8-next.c: Likewise.
131722         * lib/unistr/u8-prev.c: Likewise.
131723         * lib/unistr/u8-set.c: Likewise.
131724         * lib/unistr/u8-startswith.c: Likewise.
131725         * lib/unistr/u8-stpcpy.c: Likewise.
131726         * lib/unistr/u8-stpncpy.c: Likewise.
131727         * lib/unistr/u8-strcat.c: Likewise.
131728         * lib/unistr/u8-strchr.c: Likewise.
131729         * lib/unistr/u8-strcmp.c: Likewise.
131730         * lib/unistr/u8-strcpy.c: Likewise.
131731         * lib/unistr/u8-strcspn.c: Likewise.
131732         * lib/unistr/u8-strdup.c: Likewise.
131733         * lib/unistr/u8-strlen.c: Likewise.
131734         * lib/unistr/u8-strmblen.c: Likewise.
131735         * lib/unistr/u8-strmbtouc.c: Likewise.
131736         * lib/unistr/u8-strncat.c: Likewise.
131737         * lib/unistr/u8-strncmp.c: Likewise.
131738         * lib/unistr/u8-strncpy.c: Likewise.
131739         * lib/unistr/u8-strnlen.c: Likewise.
131740         * lib/unistr/u8-strpbrk.c: Likewise.
131741         * lib/unistr/u8-strrchr.c: Likewise.
131742         * lib/unistr/u8-strspn.c: Likewise.
131743         * lib/unistr/u8-strstr.c: Likewise.
131744         * lib/unistr/u8-strtok.c: Likewise.
131745         * lib/unistr/u8-to-u16.c: Likewise.
131746         * lib/unistr/u8-to-u32.c: Likewise.
131747         * lib/unistr/u8-uctomb-aux.c: Likewise.
131748         * lib/unistr/u8-uctomb.c: Likewise.
131749         * lib/unitypes.h: Likewise.
131750         * lib/uniwidth.h: Likewise.
131751         * lib/uniwidth/cjk.h: Likewise.
131752         * lib/uniwidth/u16-strwidth.c: Likewise.
131753         * lib/uniwidth/u16-width.c: Likewise.
131754         * lib/uniwidth/u32-strwidth.c: Likewise.
131755         * lib/uniwidth/u32-width.c: Likewise.
131756         * lib/uniwidth/u8-strwidth.c: Likewise.
131757         * lib/uniwidth/u8-width.c: Likewise.
131758         * lib/uniwidth/width.c: Likewise.
131760 2007-10-07  Bruno Haible  <bruno@clisp.org>
131762         * lib/inttypes.in.h: Change copyright notice from LGPL to GPL.
131763         The file is still under LGPL (see modules/inttypes).
131765 2007-10-06  Bruno Haible  <bruno@clisp.org>
131767         * modules/trunc (Dependencies): Add 'extensions'.
131768         * m4/trunc.m4 (gl_FUNC_TRUNC): Require gl_USE_SYSTEM_EXTENSIONS.
131769         Reported by Ben Pfaff <blp@gnu.org>.
131771 2007-10-06  Bruno Haible  <bruno@clisp.org>
131773         * modules/freopen-tests: New file.
131774         * tests/test-freopen.c: New file.
131776         * modules/fopen-tests: New file.
131777         * tests/test-fopen.c: New file.
131779         * modules/fopen: New file.
131780         * lib/fopen.c: New file.
131781         * m4/fopen.m4: New file.
131782         * modules/freopen: New file.
131783         * lib/freopen.c: New file.
131784         * m4/freopen.m4: New file.
131785         * lib/stdio.in.h (fopen, freopen): New declarations.
131786         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize also GNULIB_FOPEN,
131787         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
131788         * modules/stdio (Makefile.am): Substitute also GNULIB_FOPEN,
131789         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
131790         * doc/functions/fopen.texi: Mention the 'fopen' module.
131791         * doc/functions/freopen.texi: Mention the 'freopen' module.
131793 2007-10-06  Bruno Haible  <bruno@clisp.org>
131795         * modules/open-tests: New file.
131796         * tests/test-open.c: New file.
131798         * modules/open: New file.
131799         * lib/open.c: New file.
131800         * m4/open.m4: New file.
131801         * lib/fchdir.c (open): If the gnulib module 'open' is used, do what
131802         lib/open.c does.
131803         * lib/fcntl.in.h (open): Declare also if replaced by the 'open' module.
131804         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR, gl_FCNTL_H_DEFAULTS): New
131805         macros.
131806         (gl_FCNTL_H): Require gl_FCNTL_H_DEFAULTS.
131807         * modules/fcntl (Makefile.am): Also substitute GNULIB_OPEN and
131808         REPLACE_OPEN.
131809         * doc/functions/open.texi: Mention the 'open' module.
131811 2007-10-04  Bruno Haible  <bruno@clisp.org>
131813         * modules/ceill-tests: New file.
131814         * tests/test-ceill.c: New file.
131816         * modules/ceill: New file.
131817         * lib/ceill.c: Replace entire file.
131818         * m4/ceill.m4: New file.
131819         * lib/math.in.h (ceill): Replace declaration.
131820         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILL.
131821         * modules/math (Makefile.am): Substitute also GNULIB_CEILL.
131822         * doc/functions/ceill.texi: Mention the 'ceill' module.
131823         * modules/mathl (Files): Remove lib/ceill.c.
131824         (Depends-on): Add ceill.
131826 2007-10-04  Bruno Haible  <bruno@clisp.org>
131828         * modules/ceilf-tests: New file.
131829         * tests/test-ceilf.c: New file.
131831         * modules/ceilf: New file.
131832         * lib/ceil.c: New file.
131833         * lib/ceilf.c: New file.
131834         * m4/ceilf.m4: New file.
131835         * lib/math.in.h (ceilf): New declaration.
131836         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILF and
131837         HAVE_DECL_CEILF.
131838         * modules/math (Makefile.am): Substitute also GNULIB_CEILF and
131839         HAVE_DECL_CEILF.
131840         * doc/functions/ceilf.texi: Mention the 'ceilf' module.
131842 2007-10-04  Bruno Haible  <bruno@clisp.org>
131844         * modules/floorl-tests: New file.
131845         * tests/test-floorl.c: New file.
131847         * modules/floorl: New file.
131848         * lib/floorl.c: Replace entire file.
131849         * m4/floorl.m4: New file.
131850         * lib/math.in.h (floorl): Replace declaration.
131851         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORL.
131852         * modules/math (Makefile.am): Substitute also GNULIB_FLOORL.
131853         * doc/functions/floorl.texi: Mention the 'floorl' module.
131854         * modules/mathl (Files): Remove lib/floorl.c.
131855         (Depends-on): Add floorl.
131857 2007-10-04  Bruno Haible  <bruno@clisp.org>
131859         * modules/floorf-tests: New file.
131860         * tests/test-floorf.c: New file.
131862         * modules/floorf: New file.
131863         * lib/floor.c: New file.
131864         * lib/floorf.c: New file.
131865         * m4/floorf.m4: New file.
131866         * lib/math.in.h (floorf): New declaration.
131867         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORF and
131868         HAVE_DECL_FLOORF.
131869         * modules/math (Makefile.am): Substitute also GNULIB_FLOORF and
131870         HAVE_DECL_FLOORF.
131871         * doc/functions/floorf.texi: Mention the 'floorf' module.
131873 2007-10-04  Benoit Sigoure  <tsuna@lrde.epita.fr>
131874             Bruno Haible  <bruno@clisp.org>
131876         Advertise for the Git server instead of the CVS server.
131877         * doc/gnulib-intro.texi (Steady Development): Mention the Git
131878         repository instead of the CVS one.
131879         * doc/gnulib-tool.texi (VCS Issues): Renamed from "CVS Issues". Talk
131880         about all VCS systems generically.
131881         * doc/gnulib.texi (Introduction): Capitalize `Git'.
131883 2007-10-04  Bruno Haible  <bruno@clisp.org>
131885         * doc/gnulib.texi (Function Substitutes): Explain what an absent module
131886         means.
131887         Reported by Benoît Sigoure <tsuna@lrde.epita.fr>.
131889 2007-10-04  Bruno Haible  <bruno@clisp.org>
131891         * modules/truncl-tests: New file.
131892         * tests/test-truncl.c: New file.
131894         * modules/truncl: New file.
131895         * lib/truncl.c: New file.
131896         * m4/truncl.m4: New file.
131897         * lib/math.in.h (truncl): New declaration.
131898         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCL and
131899         HAVE_DECL_TRUNCL.
131900         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCL and
131901         HAVE_DECL_TRUNCL.
131902         * doc/functions/truncl.texi: Mention the 'truncl' module.
131904 2007-10-04  Bruno Haible  <bruno@clisp.org>
131906         * modules/truncf-tests: New file.
131907         * tests/test-truncf.c: New file.
131909         * modules/truncf: New file.
131910         * lib/trunc.c: Make paramerizable through USE_* macros.
131911         * lib/truncf.c: New file.
131912         * m4/truncf.m4: New file.
131913         * lib/math.in.h (truncf): New declaration.
131914         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCF and
131915         HAVE_DECL_TRUNCF.
131916         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCF and
131917         HAVE_DECL_TRUNCF.
131918         * doc/functions/truncf.texi: Mention the 'truncf' module.
131920 2007-10-03  Bruno Haible  <bruno@clisp.org>
131922         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
131923         augmentation also for tests modules.
131924         * modules/argp-tests (Makefile.am): Remove EXTRA_DIST augmentation.
131925         * modules/atexit-tests (Makefile.am): Likewise.
131926         * modules/binary-io-tests (Makefile.am): Likewise.
131927         * modules/c-strcase-tests (Makefile.am): Likewise.
131928         * modules/canonicalize-lgpl-tests (Makefile.am): Likewise.
131929         * modules/canonicalize-tests (Makefile.am): Likewise.
131930         * modules/closein-tests (Makefile.am): Likewise.
131931         * modules/fprintf-posix-tests (Makefile.am): Likewise.
131932         * modules/freadahead-tests (Makefile.am): Likewise.
131933         * modules/fseek-tests (Makefile.am): Likewise.
131934         * modules/fseeko-tests (Makefile.am): Likewise.
131935         * modules/ftell-tests (Makefile.am): Likewise.
131936         * modules/ftello-tests (Makefile.am): Likewise.
131937         * modules/isnanl-nolibm-tests (Makefile.am): Likewise.
131938         * modules/isnanl-tests (Makefile.am): Likewise.
131939         * modules/lseek-tests (Makefile.am): Likewise.
131940         * modules/mbscasecmp-tests (Makefile.am): Likewise.
131941         * modules/mbscasestr-tests (Makefile.am): Likewise.
131942         * modules/mbschr-tests (Makefile.am): Likewise.
131943         * modules/mbscspn-tests (Makefile.am): Likewise.
131944         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
131945         * modules/mbspbrk-tests (Makefile.am): Likewise.
131946         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
131947         * modules/mbsrchr-tests (Makefile.am): Likewise.
131948         * modules/mbsspn-tests (Makefile.am): Likewise.
131949         * modules/mbsstr-tests (Makefile.am): Likewise.
131950         * modules/printf-posix-tests (Makefile.am): Likewise.
131951         * modules/snprintf-posix-tests (Makefile.am): Likewise.
131952         * modules/sprintf-posix-tests (Makefile.am): Likewise.
131953         * modules/tsearch-tests (Makefile.am): Likewise.
131954         * modules/uniname/uniname-tests (Makefile.am): Likewise.
131955         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
131956         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
131957         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
131958         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
131959         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
131960         * modules/vfprintf-posix-tests (Makefile.am): Likewise.
131961         * modules/vprintf-posix-tests (Makefile.am): Likewise.
131962         * modules/vsnprintf-posix-tests (Makefile.am): Likewise.
131963         * modules/vsprintf-posix-tests (Makefile.am): Likewise.
131964         * modules/xstrtoimax-tests (Makefile.am): Likewise.
131965         * modules/xstrtol-tests (Makefile.am): Likewise.
131966         * modules/xstrtoumax-tests (Makefile.am): Likewise.
131967         * modules/yesno-tests (Makefile.am): Likewise.
131969 2007-10-03  Bruno Haible  <bruno@clisp.org>
131971         * modules/trunc-tests: New file.
131972         * tests/test-trunc.c: New file.
131974         * modules/trunc: New file.
131975         * lib/trunc.c: New file.
131976         * m4/trunc.m4: New file.
131977         * lib/math.in.h (trunc): New declaration.
131978         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNC and
131979         HAVE_DECL_TRUNC.
131980         * modules/math (Makefile.am): Substitute also GNULIB_TRUNC and
131981         HAVE_DECL_TRUNC.
131982         * doc/functions/trunc.texi: Mention the 'trunc' module.
131984 2007-10-03  Bruno Haible  <bruno@clisp.org>
131986         * tests/test-fpending.c: New file, mostly copied
131987         from coreutils/lib/t-fpending.c.
131988         * modules/fpending-tests: New file.
131990 2007-10-03  Bruno Haible  <bruno@clisp.org>
131992         Port the stdio extensions to QNX (untested).
131993         * lib/fseterr.c (fseterr): Add support for QNX.
131994         * lib/fbufmode.c (fbufmode): Likewise.
131995         * lib/freadable.c (freadable): Likewise.
131996         * lib/fwritable.c (fwritable): Likewise.
131997         * lib/freading.c (freading): Likewise.
131998         * lib/fwriting.c (fwriting): Likewise.
131999         * lib/freadahead.c (freadahed): Likewise.
132000         * lib/fpurge.c (fpurge): Likewise.
132001         * lib/fseeko.c (rpl_fseeko): Likewise.
132003 2007-10-03  Bruno Haible  <bruno@clisp.org>
132004             Jim Meyering  <jim@meyering.net>
132005             Eric Blake  <ebb9@byu.net>
132007         * doc/relocatable.texi: Use @command instead of @program.
132009 2007-10-02  Jim Meyering  <jim@meyering.net>
132011         Perform one more "_.h" -> ".in.h" substitution.
132012         * modules/unistd (Makefile.am) [unistd.h]: Use unistd.h.in
132013         instead of unistd_.h here, too.
132015 2007-10-01  Bruno Haible  <bruno@clisp.org>
132017         * gnulib-tool (func_emit_initmacro_done): Special case for alloca.c.
132018         Needed for the alloca-opt module.
132020 2007-09-30  Bruno Haible  <bruno@clisp.org>
132022         * lib/alloca.in.h: Renamed from lib/alloca_.h.
132023         * modules/alloca-opt (Files, Makefile.am): Use alloca.in.h instead of
132024         alloca_.h.
132025         * lib/argz.in.h: Renamed from lib/argz_.h.
132026         * modules/argz (Files, Makefile.am): Use argz.in.h instead of argz_.h.
132027         * lib/byteswap.in.h: Renamed from lib/byteswap_.h.
132028         * modules/byteswap (Files, Makefile.am): Use byteswap.in.h instead of
132029         byteswap_.h.
132030         * lib/dirent.in.h: Renamed from lib/dirent_.h.
132031         * modules/fchdir (Files, Makefile.am): Use dirent.in.h instead of
132032         dirent_.h.
132033         * lib/fcntl.in.h: Renamed from lib/fcntl_.h.
132034         * modules/fcntl (Files, Makefile.am): Use fcntl.in.h instead of
132035         fcntl_.h.
132036         * lib/float.in.h: Renamed from lib/float_.h.
132037         * modules/float (Files, Makefile.am): Use float.in.h instead of
132038         float_.h.
132039         * lib/fnmatch.in.h: Renamed from lib/fnmatch_.h.
132040         * modules/fnmatch (Files, Makefile.am): Use fnmatch.in.h instead of
132041         fnmatch_.h.
132042         * lib/getopt.in.h: Renamed from lib/getopt_.h.
132043         * modules/getopt (Files, Makefile.am): Use getopt.in.h instead of
132044         getopt_.h.
132045         * lib/glob.in.h: Renamed from lib/glob_.h.
132046         * modules/glob (Files, Makefile.am): Use glob.in.h instead of glob_.h.
132047         * lib/iconv.in.h: Renamed from lib/iconv_.h.
132048         * modules/iconv_open (Files, Makefile.am): Use iconv.in.h instead of
132049         iconv_.h.
132050         * lib/inttypes.in.h: Renamed from lib/inttypes_.h.
132051         * modules/inttypes (Files, Makefile.am): Use inttypes.in.h instead of
132052         inttypes_.h.
132053         * lib/locale.in.h: Renamed from lib/locale_.h.
132054         * modules/locale (Files, Makefile.am): Use locale.in.h instead of
132055         locale_.h.
132056         * lib/math.in.h: Renamed from lib/math_.h.
132057         * modules/math (Files, Makefile.am): Use math.in.h instead of math_.h.
132058         * lib/netinet_in.in.h: Renamed from lib/netinet_in_.h.
132059         * modules/netinet_in (Files, Makefile.am): Use netinet_in.in.h instead
132060         of netinet_in_.h. Add dependency.
132061         * lib/poll.in.h: Renamed from lib/poll_.h.
132062         * modules/poll (Files, Makefile.am): Use poll.in.h instead of poll_.h.
132063         * lib/search.in.h: Renamed from lib/search_.h.
132064         * modules/search (Files, Makefile.am): Use search.in.h instead of
132065         search_.h.
132066         * lib/signal.in.h: Renamed from lib/signal_.h.
132067         * modules/signal (Files, Makefile.am): Use signal.in.h instead of
132068         _signal.h.
132069         * lib/stdbool.in.h: Renamed from lib/stdbool_.h.
132070         * modules/stdbool (Files, Makefile.am): Use stdbool.in.h instead of
132071         stdbool_.h.
132072         * lib/stdint.in.h: Renamed from lib/stdint_.h.
132073         * modules/stdint (Files, Makefile.am): Use stdint.in.h instead of
132074         stdint_.h.
132075         * lib/stdio.in.h: Renamed from lib/stdio_.h.
132076         * modules/stdio (Files, Makefile.am): Use stdio.in.h instead of
132077         stdio_.h.
132078         * lib/stdlib.in.h: Renamed from lib/stdlib_.h.
132079         * modules/stdlib (Files, Makefile.am): Use stdlib.in.h instead of
132080         stdlib_.h.
132081         * lib/string.in.h: Renamed from lib/string_.h.
132082         * modules/string (Files, Makefile.am): Use string.in.h instead of
132083         string_.h.
132084         * doc/gnulib-tool.texi (Initial import): Update.
132085         * lib/sys_select.in.h: Renamed from lib/sys_select_.h.
132086         * modules/sys_select (Files, Makefile.am): Use sys_select.in.h instead
132087         of sys_select_.h. Add dependency.
132088         * lib/sys_socket.in.h: Renamed from lib/sys_socket_.h.
132089         * modules/sys_socket (Files, Makefile.am): Use sys_socket.in.h instead
132090         of sys_socket_.h.
132091         * lib/sys_stat.in.h: Renamed from lib/sys_stat_.h.
132092         * modules/sys_stat (Files, Makefile.am): Use sys_stat.in.h instead of
132093         sys_stat_.h.
132094         * lib/sys_time.in.h: Renamed from lib/sys_time_.h.
132095         * modules/sys_time (Files, Makefile.am): Use sys_time.in.h instead of
132096         sys_time_.h.
132097         * lib/sysexits.in.h: Renamed from lib/sysexits_.h.
132098         * modules/sysexits (Files, Makefile.am): Use sysexits.in.h instead of
132099         sysexits_.h.
132100         * lib/time.in.h: Renamed from lib/time_.h.
132101         * modules/time (Files, Makefile.am): Use time.in.h instead of time_.h.
132102         * lib/unistd.in.h: Renamed from lib/unistd_.h.
132103         * modules/unistd (Files, Makefile.am): Use unistd.in.h instead of
132104         unistd_.h.
132105         * lib/wchar.in.h: Renamed from lib/wchar_.h.
132106         * modules/wchar (Files, Makefile.am): Use wchar.in.h instead of
132107         wchar_.h.
132108         * lib/wctype.in.h: Renamed from lib/wctype_.h.
132109         * modules/wctype (Files, Makefile.am): Use wctype.in.h instead of
132110         wctype_.h.
132111         * build-aux/bootstrap (slurp): Update.
132112         * lib/.cppi-disable: Update.
132114 2007-09-30  Bruno Haible  <bruno@clisp.org>
132116         * tests/test-getaddrinfo.c (AF_UNSPEC): Provide a fallback definition.
132117         Needed on BeOS.
132119 2007-09-30  Bruno Haible  <bruno@clisp.org>
132121         * modules/dirname-tests (check_PROGRAMS): Renamed from noinst_PROGRAMS.
132123 2007-09-29  Bruno Haible  <bruno@clisp.org>
132125         * lib/stdio_.h (getdelim, getline): Add identifiers. Doc tweak.
132127 2007-09-29  Bruno Haible  <bruno@clisp.org>
132129         * lib/xreadlink.c (xreadlink): Simplify to a wrapper around areadlink.
132130         * modules/xreadlink (Depends-on): Add areadlink, remove readlink etc.
132131         * build-aux/install-reloc: Compile also areadlink.c.
132132         * modules/relocatable-prog-wrapper (Files): Add lib/areadlink.[hc].
132134 2007-09-29  Bruno Haible  <bruno@clisp.org>
132136         * gnulib-tool (func_emit_initmacro_done): Indentation.
132138 2007-09-29  Bruno Haible  <bruno@clisp.org>
132140         * README: Add CVS checkout update instructions.
132141         Info from Bob Proulx <bob@proulx.com>.
132143 2007-09-28  Eric Blake  <ebb9@byu.net>
132145         Provide move-if-change.
132146         * build-aux/move-if-change: New file, based on best practice
132147         rather than any canonical upstream location.
132149 2007-09-28  Jim Meyering  <jim@meyering.net>
132151         Fix canonicalize loop-detection corner case.
132152         Do not attempt to stat the symlink values stored via seen_triple.
132153         Without this, coreutils' tests/misc/readlink-fp-loop test would fail
132154         on linux-2.6.18, (but not 2.6.22).
132155         * lib/canonicalize.c (seen_triple): Use triple_compare_ino_str, not
132156         triple_compare.  The former compares dev,ino,filename, while the latter
132157         would actually stat dirname(filename) when dev and ino were equal.
132158         * lib/hash-triple.c: Install <string.h>.
132159         (STREQ): Define.
132160         (triple_compare_ino_str): New function.
132161         * lib/hash-triple.h (triple_compare_ino_str): Declare it.
132163 2007-09-28  Eric Blake  <ebb9@byu.net>
132165         Enforce that AC_REPLACE_FUNCS files exist.
132166         * gnulib-tool (func_emit_initmacro_done): Make AC_LIBSOURCES
132167         override check for typos.
132169         Fix test-closein on Solaris 10.
132170         * tests/test-closein.c (main): Don't assume stdin can be inherited
132171         closed on all systems.
132172         * tests/test-closein.sh: Likewise.
132173         Reported by Piotr Tarnowski.
132175 2007-09-28  Jim Meyering  <jim@meyering.net>
132177         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Fix typo in comment.
132179 2007-09-27  Jim Meyering  <jim@meyering.net>
132181         canonicalize: Avoid a false-positive cycle failure.
132182         * modules/canonicalize (Depends-on): Add file-set and hash-triple.
132183         Sort.  Remove cycle-check.
132184         * lib/canonicalize.c: Include file-set.h and hash-triple.h,
132185         not cycle-check.h.
132186         (seen_triple): New function.
132187         (canonicalize_filename_mode): Use it instead of cycle-check.
132188         * tests/test-canonicalize.c: Add a test for this bug.
132189         * tests/test-canonicalize.sh: Set up and run the test.
132191         New module, file-set, from coreutils.
132192         * modules/file-set: Define it.
132193         * lib/file-set.c, lib/file-set.h: Implement.
132195         New module, hash-triple, from coreutils.
132196         * modules/hash-triple: Define it.
132197         * lib/hash-triple.c, lib/hash-triple.h: Implement.
132199 2007-09-25  Eric Blake  <ebb9@byu.net>
132201         Fix strerror on Interix.
132202         * lib/string_.h (strerror): Declare replacement.
132203         * doc/functions/strerror.texi (strerror): Document the Interix
132204         shortcoming.
132205         * modules/string (Makefile.am): Support new hooks.
132206         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Add new hooks.
132207         * m4/strerror.m4 (gl_FUNC_STRERROR): Defer to
132208         gl_FUNC_STRERROR_SEPARATE.
132209         (gl_FUNC_STRERROR_SEPARATE): Check for Interix bug.
132210         * lib/strerror.c (rpl_strerror): Provide replacement.
132211         * modules/strerror (Depends-on): Add string.
132212         (configure.ac): Detect use of module.
132213         * tests/test-strerror.c: New file.
132214         * modules/strerror-tests: New test module.
132215         * modules/argp (Depends-on): Add strerror.
132216         * modules/error (Depends-on): Likewise.
132217         Reported by Martin Koeppe.
132219 2007-09-24  Bruno Haible  <bruno@clisp.org>
132221         * README: Update git instructions.
132223 2007-09-24  Eric Blake  <ebb9@byu.net>
132225         Revert fpending breakage from 2007-09-08.
132226         * m4/fpending.m4 (gl_FUNC_FPENDING): Don't require existence of
132227         __fpending.c.
132229 2007-09-24  Jim Meyering  <jim@meyering.net>
132231         filenamecat.c: Add a test.
132232         * lib/filenamecat.c (main) [TEST_FILE_NAME_CONCAT]: Add a test
132233         showing how the function works when DIR is the empty string.
132235 2007-09-21  Simon Josefsson  <simon@josefsson.org>
132237         * tests/test-canonicalize.sh: Turn on executable bit.
132239 2007-09-19  Eric Blake  <ebb9@byu.net>
132241         * README: Update CVS instructions.
132243 2007-09-18  Bruno Haible  <bruno@clisp.org>
132245         * modules/areadlink: New file.
132246         * lib/areadlink.h (areadlink): New declaration.
132247         * lib/areadlink.c: New file, based on lib/xreadlink.c.
132249 2007-09-17  Jim Meyering  <jim@meyering.net>
132251         * lib/savewd.c (ESTALE) [!defined]: Define.
132252         Reported to be required on Interix by Martin Koeppe.
132254 2007-09-17  Bruno Haible  <bruno@clisp.org>
132256         * gnulib-tool (func_version): Use $version.
132258 2007-09-16  Bruno Haible  <bruno@clisp.org>
132260         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE, gl_PRINTF_INFINITE,
132261         gl_PRINTF_INFINITE_LONG_DOUBLE): Increase buf's size from 100 to 10000.
132262         Needed on glibc-2.6.1 with -fstack-protector -D_FORTIFY_SOURCE=2.
132263         Reported by Greg Schafer <gschafer@zip.com.au>.
132265 2007-09-15  Bruno Haible  <bruno@clisp.org>
132267         * gnulib-tool (sed): Try a little harder to make bash understand the
132268         alias.
132269         Reported by Bruce Korb <bruce.korb@gmail.com>.
132271 2007-09-13  Eric Blake  <ebb9@byu.net>
132273         * ChangeLog: Remove conflict markers.
132275 2007-09-13  Simon Josefsson  <simon@josefsson.org>
132277         * lib/gc-gnulib.c (gc_hash_open): Catch NULL calloc return value.
132278         Reported by Bruno Haible <bruno@clisp.org>.
132280 2007-09-12  Bruno Haible  <bruno@clisp.org>
132282         * m4/lock.m4: Don't provide an AC_USE_SYSTEM_EXTENSIONS definition.
132283         (gl_LOCK_EARLY_BODY): Use AC_GNU_SOURCE when AC_USE_SYSTEM_EXTENSIONS
132284         is not defined.
132286 2007-09-12  Eric Blake  <ebb9@byu.net>
132288         Track CVS Autoconf on AC_USE_SYSTEM_EXTENSIONS.
132289         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Update to CVS
132290         Autoconf definition.
132291         * modules/euidaccess (Depends-on): Add extensions, for
132292         AC_USE_SYSTEM_EXTENSIONS with autoconf <= 2.59.
132293         * modules/fnmatch (Depends-on): Likewise.
132294         * modules/getaddrinfo (Depends-on): Likewise.
132295         * modules/getdelim (Depends-on): Likewise.
132296         * modules/getline (Depends-on): Likewise.
132297         * modules/getsubopt (Depends-on): Likewise.
132298         * modules/gettext (Depends-on): Likewise.
132299         * modules/group-member (Depends-on): Likewise.
132300         * modules/mbchar (Depends-on): Likewise.
132301         * modules/memmem (Depends-on): Likewise.
132302         * modules/mempcpy (Depends-on): Likewise.
132303         * modules/memrchr (Depends-on): Likewise.
132304         * modules/pagealign_alloc (Depends-on): Likewise.
132305         * modules/readutmp (Depends-on): Likewise.
132306         * modules/stpcpy (Depends-on): Likewise.
132307         * modules/stpncpy (Depends-on): Likewise.
132308         * modules/strchrnul (Depends-on): Likewise.
132309         * modules/strndup (Depends-on): Likewise.
132310         * modules/strsep (Depends-on): Likewise.
132311         * modules/strverscmp (Depends-on): Likewise.
132312         * modules/vasprintf (Depends-on): Likewise.
132313         * modules/wcwidth (Depends-on): Likewise.
132314         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): AC_GNU_SOURCE will be
132315         obsolete in Autoconf 2.62; use AC_USE_SYSTEM_EXTENSIONS instead.
132316         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_GNU): Likewise.
132317         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDR_INFO): Likewise.
132318         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
132319         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
132320         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Likewise.
132321         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
132322         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Likewise.
132323         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
132324         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
132325         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
132326         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
132327         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
132328         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC): Likewise.
132329         * m4/readutmp.m4 (gl_READUTMP): Likewise.
132330         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
132331         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
132332         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
132333         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
132334         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
132335         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
132336         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
132337         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Likewise.
132338         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): Likewise.
132339         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
132340         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Likewise, but provide fallback,
132341         so that lock.m4 can be used in gettext without extensions module.
132343 2007-09-11  Bruno Haible  <bruno@clisp.org>
132345         * m4/isc-posix.m4: Remove file.
132346         Suggested by Eric Blake.
132348 2007-09-11  Eric Blake  <ebb9@byu.net>
132350         * ChangeLog: Restore lines accidentally truncated 2007-04-06.
132352 2007-09-10  Bruno Haible  <bruno@clisp.org>
132354         * posix-modules: Fix typo in error message.
132355         Reported by Matt <mkraai@beckman.com>.
132357 2007-09-09  Bruno Haible  <bruno@clisp.org>
132359         * doc/functions/getdelim.texi: Update list of platforms lacking the
132360         function.
132361         * doc/functions/getline.texi: Likewise.
132363 2007-09-09  Jim Meyering  <jim@meyering.net>
132365         * lib/hash.c (hash_initialize): Detect calloc failure.
132366         Reported by Bruno Haible.
132368 2007-09-09  Bruno Haible  <bruno@clisp.org>
132370         * lib/canonicalize-lgpl.c (__realpath): Set errno to ENOMEM when
132371         malloc or realloc fails.
132373 2007-09-09  Bruno Haible  <bruno@clisp.org>
132375         * modules/getcwd (Depends-on): Add malloc-posix.
132376         * modules/glob (Depends-on): Likewise.
132377         * modules/putenv (Depends-on): Likewise.
132378         * modules/strdup (Depends-on): Likewise.
132379         * modules/getdelim (Depends-on): Add realloc-posix.
132380         * modules/read-file (Depends-on): Likewise.
132382 2007-09-09  Bruno Haible  <bruno@clisp.org>
132384         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): New macro.
132385         (gl_FUNC_MALLOC_POSIX): Require it.
132386         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
132387         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Likewise.
132388         * modules/realloc (Files): Add m4/malloc.m4.
132389         * modules/calloc (Files): Likewise.
132391 2007-09-09  Bruno Haible  <bruno@clisp.org>
132393         * modules/malloc-posix: New file.
132394         * modules/malloc (Depends-on): Add malloc-posix.
132395         * lib/malloc.c: Include errno.h.
132396         (rpl_malloc): Merge the requirements of a glibc-compatible malloc
132397         and a POSIX-compatible malloc into a single function. Set ENOMEM
132398         when returning NULL.
132399         * m4/malloc.m4: New file.
132400         * doc/functions/malloc.texi: Mention the malloc-posix module.
132401         * lib/stdlib_.h (malloc): New declaration.
132402         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
132403         GNULIB_MALLOC_POSIX and HAVE_MALLOC_POSIX.
132404         * modules/stdlib (stdlib.h): Substitute also GNULIB_MALLOC_POSIX
132405         and HAVE_MALLOC_POSIX.
132407 2007-09-09  Bruno Haible  <bruno@clisp.org>
132409         * modules/realloc-posix: New file.
132410         * modules/realloc (Depends-on): Add realloc-posix.
132411         * lib/realloc.c: Include errno.h.
132412         (rpl_realloc): Merge the requirements of a glibc-compatible realloc
132413         and a POSIX-compatible realloc into a single function. Set ENOMEM
132414         when returning NULL.
132415         * m4/realloc.m4: New file.
132416         * doc/functions/realloc.texi: Mention the realloc-posix module.
132417         * lib/stdlib_.h (realloc): New declaration.
132418         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
132419         GNULIB_REALLOC_POSIX and HAVE_REALLOC_POSIX.
132420         * modules/stdlib (stdlib.h): Substitute also GNULIB_REALLOC_POSIX
132421         and HAVE_REALLOC_POSIX.
132423 2007-09-09  Bruno Haible  <bruno@clisp.org>
132425         * modules/calloc-posix: New file.
132426         * modules/calloc (Depends-on): Add calloc-posix.
132427         * lib/calloc.c: Include errno.h.
132428         (rpl_calloc): Merge the requirements of a glibc-compatible calloc
132429         and a POSIX-compatible calloc into a single function. Set ENOMEM
132430         when returning NULL.
132431         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): New macro.
132432         * doc/functions/calloc.texi: Mention the calloc-posix module.
132433         * lib/stdlib_.h (calloc): New declaration.
132434         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
132435         GNULIB_CALLOC_POSIX and HAVE_CALLOC_POSIX.
132436         * modules/stdlib (stdlib.h): Substitute also GNULIB_CALLOC_POSIX
132437         and HAVE_CALLOC_POSIX.
132439 2007-09-09  Bruno Haible  <bruno@clisp.org>
132441         Allow for modules to show an arbitrary notice.
132442         * modules/TEMPLATE-EXTENDED: Add 'Notice' field.
132443         * gnulib-tool: New option --extract-notice.
132444         (func_usage): Document it.
132445         (sed_extract_prog): Update.
132446         (func_get_notice): New function.
132447         (func_modules_notice): New function.
132448         (func_import, func_create_testdir): Invoke it.
132449         Suggested by Jim Meyering.
132451 2007-09-09  Bruno Haible  <bruno@clisp.org>
132453         * gnulib-tool: New options --verbose, --quiet.
132454         (func_usage): Document them.
132455         (verbose): New variable.
132456         (func_execute_command): New function.
132457         (func_import): Don't show the module list and the file list if
132458         $verbose < 0.
132459         (func_create_testdir): Likewise. Use func_execute_command.
132460         (func_create_megatestdir): Use func_execute_command.
132462 2007-09-08  Bruno Haible  <bruno@clisp.org>
132464         * gnulib-tool (func_import): Prefer rsync over wget when available,
132465         for fetching the PO files.
132467 2007-09-08  Bruno Haible  <bruno@clisp.org>
132469         * posix-modules: New file. Portions copied from gnulib-tool.
132470         * doc/gnulib.texi (POSIX Substitutes Library): New chapter.
132472 2007-09-08  Jim Meyering  <jim@meyering.net>
132474         Rename __fpending.c -> fpending.c and __fpending.h -> fpending.h
132475         * lib/fpending.h: Rename from __fpending.h.
132476         * lib/fpending.c: Rename from __fpending.c.
132477         Include "fpending.h", not "__fpending.h".
132478         * lib/__fpending.h, lib/__fpending.c: Remove files.
132479         * modules/fpending (Files): Reflect new file names.
132480         * lib/close-stream.c: Include "fpending.h", not "__fpending.h".
132482 2007-09-08  Bruno Haible  <bruno@clisp.org>
132484         * m4/inttypes-h.m4: Remove stub file.
132486 2007-09-07  Simon Josefsson  <simon@josefsson.org>
132488         * doc/headers/stdint.texi: Discuss #include_next issue.
132490 2007-09-06  Paul Eggert  <eggert@cs.ucla.edu>
132492         * build-aux/bootstrap: Remove obsolete comment about wget --help.
132494 2007-09-06  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
132496         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Fix misspelling
132497         in variable name.
132499 2007-09-03  Jim Meyering  <jim@meyering.net>
132501         New module: git-version-gen.
132502         * modules/git-version-gen: New file.
132504         Import changes from coreutils for bootstrap script.
132506         * build-aux/bootstrap (WGET_COMMAND): Remove code to set this variable.
132508         bootstrap: uses rsync to download the .po files
132509         * build-aux/bootstrap (po_download_command_format): New global.
132510         (download_po_files): Use rsync.
132511         (update_po_files): Don't remove .po files after download,
132512         so future rsync runs can take advantage of the copies.
132514         * build-aux/bootstrap (gnulib_tool): Make sha1sum check quietly.
132516         Solve the unnecessary-.po-file-regeneration problem once and for all.
132517         * build-aux/bootstrap (download_po_files): New function, renamed from
132518         get_translations.  Now, downloads, but doesn't update LINGUAS.
132519         (update_po_files): New function.
132521         bootstrap: Ignore more.
132522         * build-aux/bootstrap (symlink_to_dir): Add a directory name like
132523         uniwidth to e.g., lib/.gitignore.
132524         (slurp): Handle the sys_stat_.h -> sys mapping, too.
132526         * build-aux/bootstrap: New setting: vc_ignore.
132527         (insert_sorted_if_absent): Create $file if absent.
132528         Adapt to new, possibly empty, list: $vc_ignore.
132530         bootstrap: generate more ignorable names
132531         * build-aux/bootstrap (slurp): When generating ignorable names,
132532         also map .sin to .sed, .gperf to .c, and .y to .c.
132534 2007-09-03  Jim Meyering  <jim@meyering.net>
132536         * build-aux/git-version-gen: New file, from coreutils.  For details, see
132537         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=bfe49f506
132539 2007-09-02  Bruno Haible  <bruno@clisp.org>
132541         Fix mis-recognition of 'mcs' on QNX 6.
132542         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Test whether the "mcs --version"
132543         output contains the string "Mono".
132544         * lib/csharpcomp.c (compile_csharp_using_mono): Likewise.
132545         Reported by <kraai@ftbfs.org> at <https://savannah.gnu.org/bugs/?18337>.
132547 2007-09-01  Bruno Haible  <bruno@clisp.org>
132549         Fix collision between uniwidth/* and linebreak modules.
132550         * lib/linebreak.h (locale_charset, uc_width, u8_width, u16_width,
132551         u32_width): Remove declarations.
132552         * lib/linebreak.c: Include uniwidth.h, uniwidth/cjk.h, streq.h.
132553         (u32_mbtouc_unsafe, streq9, streq8, streq7, streq6, streq5, streq4,
132554         streq3, streq2, streq1, streq0): Remove functions.
132555         (STREQ): Remove macro.
132556         (is_cjk_encoding): Remove function.
132557         (nonspacing_table_data, nonspacing_table_ind): Remove constants.
132558         (uc_width, u8_width, u16_width, u32_width): Remove functions.
132559         * modules/linebreak (Depends-on): Add streq, uniwidth/width.
132560         * NEWS: Document the change.
132562 2007-09-01  Bruno Haible  <bruno@clisp.org>
132564         * lib/streq.h: Add double-inclusion guard.
132566 2007-09-01  Karl Berry  <karl@gnu.org>
132568         * MODULES.html.sh: Rename mreadlink_with_size to areadlink_with_size.
132570 2007-08-28  Jim Meyering  <jim@meyering.net>
132572         Rename mreadlink_with_size to areadlink_with_size.
132573         * NEWS: Document the change.
132574         * lib/mreadlink-with-size.c (mreadlink_with_size): Rename this to...
132575         * lib/areadlink-with-size.c (areadlink_with_size): ...this.
132576         * lib/mreadlink.h: Rename this to...
132577         * lib/areadlink.h: ...this.
132578         * modules/mreadlink-with-size: Rename this to...
132579         * modules/areadlink-with-size: ...this.
132580         * lib/canonicalize.c: Reflect the renaming.
132581         * modules/canonicalize: Likewise.
132583 2007-08-26  Bruno Haible  <bruno@clisp.org>
132585         * gnulib-tool (func_import): When deciding which files to remove,
132586         consider also dangling symbolic links.
132587         Reported by Eric Blake.
132589 2007-08-26  Bruno Haible  <bruno@clisp.org>
132591         * gnulib-tool (func_ln_if_changed): Use "test -h", not "test -L".
132593 2007-08-23  Simon Josefsson  <simon@josefsson.org>
132595         * lib/readline.c: Don't include getline.h, the prototype is now
132596         found in stdio.h.
132598 2007-08-23  Jim Meyering  <jim@meyering.net>
132600         Getdelim touchup.
132601         * lib/getdelim.c (getdelim): Don't bother to save/restore errno
132602         around the funlockfile call, since funlockfile never sets errno.
132603         Don't set errno upon failed realloc.
132605 2007-08-22  Eric Blake  <ebb9@byu.net>
132607         Getline touchups.
132608         * lib/getdelim.c (getdelim): Revert regression that required *n to
132609         be 0 when *lineptr is NULL.  Preserve errno across funlockfile.
132610         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Check for declaration of
132611         getdelim, rather than whether implementation is missing.
132612         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise for getline.
132613         * lib/stdio_.h (getline): Also declare if replacement is
132614         required.
132615         * doc/functions/getdelim.texi: New file.
132616         * doc/functions/getline.texi: Likewise.
132617         * doc/gnulib.texi (Function Substitutes): Add new files.
132618         Reported by Bruno Haible.
132620 2007-08-22  Ludovic Courtès  <ludo@gnu.org>
132622         * users.txt: Add Guile.
132624 2007-08-22  Eric Blake  <ebb9@byu.net>
132626         * tests/test-getdelim.c (main): Use remove, not unlink.
132627         * tests/test-getline.c (main): Likewise.
132629         Move getline and getdelim into stdio.h, per POSIX 200x.
132630         * modules/getline (Files): Remove getline.h.
132631         (Depends-on): Add stdio.
132632         (configure.ac): Add module indicator.
132633         * modules/getdelim (Files): Remove getdelim.h.
132634         (Depends-on): Add stdio.
132635         (configure.ac): Add module indicator.
132636         * modules/stdio (Makefile.am): Work with new indicators.
132637         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
132638         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Work with stdio needs.
132639         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
132640         * lib/getdelim.h: Delete.
132641         * lib/getline.h: Delete.
132642         * lib/stdio_.h (getdelim, getline): Declare.
132643         * modules/getdelim-tests: New module.
132644         * modules/getline-tests: Likewise.
132645         * tests/test-getdelim.c: New file.
132646         * tests/test-getline.c: Likewise.
132647         * NEWS: Document the change.
132648         * lib/getline.c: Update choice of header.
132649         * lib/csharpcomp.c: Likewise.
132650         * lib/getpass.c: Likewise.
132651         * lib/javacomp.c: Likewise.
132652         * lib/javaversion.c: Likewise.
132653         * lib/yesno.c: Likewise.
132654         * lib/getdelim.c: Likewise.
132655         (getdelim): Set errno on failure, and avoid memory leak.
132657 2007-08-19  Bruno Haible  <bruno@clisp.org>
132659         * modules/closein (Depends-on): Add freadahead.
132660         * lib/closein.c: Include freadahead.h.
132661         (close_stdin): Skip the fseeko and fflush calls if freadahead(stdin)
132662         is zero.
132664 2007-08-19  Bruno Haible  <bruno@clisp.org>
132666         * modules/freadahead-tests: New file.
132667         * tests/test-freadahead.sh: New file.
132668         * tests/test-freadahead.c: New file.
132670         * modules/freadahead: New file.
132671         * lib/freadahead.h: New file.
132672         * lib/freadahead.c: New file.
132673         * MODULES.html.sh (File stream based Input/Output): Add freadahead,
132674         fbufmode, fpurge, freadable, fwritable.
132676 2007-08-19  Eric Blake  <ebb9@byu.net>
132678         Test yesno in combination with closein.
132679         * lib/yesno.c (yesno): Document use of stdin.
132680         * modules/yesno-tests (Files): New module.
132681         * tests/test-yesno.c (main): New file.
132682         * tests/test-yesno.sh: Likewise.
132684 2007-08-19  Bruno Haible  <bruno@clisp.org>
132686         * lib/fbufmode.c (fbufmode): Add tentative support for Solaris/AMD64.
132687         * lib/fseeko.c (rpl_fseeko): Likewise.
132688         * lib/fseterr.c (fseterr): Likewise.
132690 2007-08-19  Bruno Haible  <bruno@clisp.org>
132692         * tests/test-lseek.c (main): Disable a test for BeOS.
132693         * doc/functions/lseek.texi: Document the BeOS bug.
132695 2007-08-19  Bruno Haible  <bruno@clisp.org>
132696             Eric Blake  <ebb9@byu.net>
132698         * lib/lseek.c: Include <sys/stat.h>.
132699         (rpl_lseek): Add workaround code also for Unix platforms.
132700         Needed for BeOS.
132701         * m4/lseek.m4 (gl_FUNC_LSEEK): When cross-compiling, fail on BeOS.
132702         * doc/functions/lseek.texi: Document BeOS definiency.
132704 2007-08-18  Bruno Haible  <bruno@clisp.org>
132706         * modules/fstrcmp-tests: New file.
132707         * tests/test-fstrcmp.c: New file.
132709 2007-08-18  Bruno Haible  <bruno@clisp.org>
132711         * modules/fstrcmp: New file, from GNU gettext with modifications.
132712         * lib/fstrcmp.h: New file, from GNU gettext.
132713         * lib/fstrcmp.c: New file, from GNU gettext.
132714         * MODULES.html.sh (String handling): Add fstrcmp.
132716 2007-08-18  Bruno Haible  <bruno@clisp.org>
132718         * lib/diffseq.h (struct context): Change type of 'heuristic' field to
132719         'bool'.
132720         (diag, compareseq): Remove const from the ctxt argument.
132721         (USE_HEURISTIC): Undefine at the end.
132723 2007-08-18  Jim Meyering  <jim@meyering.net>
132725         New file: lib/idcache.h
132726         * NEWS: Mention the addition.
132727         * modules/idcache (Files): Add lib/idcache.h
132728         * lib/idcache.c: Include "idcache.h".
132729         Don't include <sys/types.h>.
132730         Add a FIXME comment.
132731         Move file-scoped "static" declarations to the top.
132732         * lib/idcache.h: New file.  Include <sys/types.h> here, instead.
132734 2007-08-17  Bruno Haible  <bruno@clisp.org>
132735         and Paul Eggert  <eggert@cs.ucla.edu>
132737         * MODULES.html.sh: Add diffseq.
132738         * modules/diffseq: New file.
132739         * lib/diffseq.h: New file, from GNU gettext with a few minor changes,
132740         extracted from GNU gettext's fstrcmp.c and GNU diff's analyze.c.
132742 2007-08-15  Paul Eggert  <eggert@cs.ucla.edu>
132744         Import changes from coreutils for bootstrap script.
132746         2007-07-21  Paul Eggert  <eggert@cs.ucla.edu>
132748         * build-aux/bootstrap (slurp): Work even in environments where
132749         "ls" defaults to "ls -A".  Put in a FIXME, though, since the
132750         current code does not slurp files whose names start with ".", and
132751         this looks like it might be a troublesome area.
132753         2007-07-11  Jim Meyering  <jim@meyering.net>
132755         If there's a GPL vN copyright comment, require that N == 3.
132757         2007-07-08  Jim Meyering  <jim@meyering.net>
132759         Run the coreutils-specific code only if tests/Makefile.am.in exists.
132760         * build-aux/bootstrap (mam_template): Move definition out of loop.
132762         Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*.
132764         * build-aux/bootstrap (symlink_to_dir): Rename function from
132765         symlink_to_gnulib.  Add a directory parameter.  Update all
132766         callers.
132767         (cp_mark_as_generated): Also check for -- and link to -- files in
132768         gl/.
132770         2007-07-08  Jim Meyering  <jim@meyering.net>
132772         Adapt to deeper hierarchy in gnulib.
132773         * build-aux/bootstrap (symlink_to_dir): If the destination
132774         directory doesn't exist, create it. This is required at least for
132775         "lib/uniwidth/cjk.h".
132777         2007-05-15  Jim Meyering  <jim@meyering.net>
132779         * build-aux/bootstrap: Now that generated Makefile.am files
132780         are no longer under version control, they must be created at
132781         bootstrap time.
132783 2007-08-14  Ben Pfaff  <blp@gnu.org>
132785         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
132787 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
132789         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
132790         given the changes below.
132791         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
132792         even on hosts that have padding bits beyond the supported 64.
132794 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
132796         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
132797         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
132798         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
132799         depends on it.
132800         (xstrtol_error): Remove.
132801         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
132802         but with a different signature.
132803         (ATTRIBUTE_NORETURN, __attribute__): New macros.
132804         * lib/xstrtol-error.c: Include exitfail.h.
132805         (xstrtol_fatal): New function, with a different signature from the
132806         old xstrtol_error, so that the caller need not worry about passing
132807         in an exit status, or about storage management of the option argument.
132808         (xstrtol_error): Now a static function.  Redo signature to
132809         implement xstrtol_fatal.  Output the correct number of hyphens in
132810         front of the option so that the caller need not worry about
132811         storage management.
132812         (N_): New macro.
132813         (_): Remove; not used now.
132814         * modules/xstrtol: Depend on getopt.
132815         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
132816         of old STRTOL_FATAL_ERROR macro.
132817         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
132818         of test program.
132819         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
132820         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
132822 2007-08-08  Eric Blake  <ebb9@byu.net>
132824         * lib/xstrtol-error.c: Add missing include.
132826         Move xstrtol messages into gnulib domain, when --pobase is used.
132827         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
132828         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
132829         * modules/xstrtol (Files): Distribute new file.
132830         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
132831         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
132832         * tests/test-xstrtol.c: ...into new file.
132833         * tests/test-xstrtoul.c: Also test xstrtoul.
132834         * tests/test-xstrtoimax.c: Also test xstrtoimax.
132835         * tests/test-xstrtoumax.c: Also test xstrtoumax.
132836         * tests/test-xstrtol.sh: Drive the tests.
132837         * tests/test-xstrtoimax.sh: Likewise.
132838         * tests/test-xstrtoumax.sh: Likewise.
132839         * modules/xstrtol-tests: New module.
132840         * modules/xstrtoimax-tests: Likewise.
132841         * modules/xstrtoumax-tests: Likewise.
132843 2007-08-08  Jim Meyering  <jim@meyering.net>
132845         New function: mfile_name_concat.
132846         * lib/filenamecat.c (mfile_name_concat): New function, just like
132847         file_name_concat, but return NULL upon failure rather than exiting
132848         with a diagnostic.
132849         * lib/filenamecat.h: Declare it.
132851 2007-08-07  Bruno Haible  <bruno@clisp.org>
132853         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
132854         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
132855         warning from gcc.
132856         Reported by Eric Blake.
132858 2007-08-07  Simon Josefsson  <simon@josefsson.org>
132860         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
132861         * modules/crypto/arcfour (License): Likewise.
132862         * modules/crypto/des-tests (License): Likewise.
132863         * modules/crypto/gc-arctwo-tests (License): Likewise.
132864         * modules/crypto/gc-des-tests (License): Likewise.
132865         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
132866         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
132867         * modules/crypto/gc-md2-tests (License): Likewise.
132868         * modules/crypto/gc-md4-tests (License): Likewise.
132869         * modules/crypto/gc-md5-tests (License): Likewise.
132870         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
132871         * modules/crypto/gc-rijndael-tests (License): Likewise.
132872         * modules/crypto/gc-sha1-tests (License): Likewise.
132873         * modules/crypto/gc-tests (License): Likewise.
132874         * modules/crypto/hmac-md5 (License): Likewise.
132875         * modules/crypto/hmac-sha1 (License): Likewise.
132876         * modules/crypto/md2-tests (License): Likewise.
132877         * modules/crypto/md4-tests (License): Likewise.
132878         * modules/crypto/md5 (License): Likewise.
132879         * modules/crypto/rijndael (License): Likewise.
132880         * modules/crypto/sha1 (License): Likewise.
132881         * modules/memxor (License): Likewise.
132883 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
132884         and Bruno Haible  <bruno@clisp.org>
132886         * NEWS: Describe interface changes to human, xstrtol.
132887         * lib/human.h: Include <xstrtol.h>.
132888         (human_options): Return enum strtol_error, not int.  Remove
132889         bool arg; take int * instead.
132890         * lib/human.c: Don't include "gettext.h".
132891         (_): Remove; no longer used.
132892         Don't include <xstrtol.h>, since human.h does it.
132893         (human_options): Adjust to abovementioned interface changes.
132894         Do not report error to stderr; that's now the caller's
132895         responsibility.
132896         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
132897         interface change.
132898         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
132899         Str, Argument_type_string.  All uses changed.  Put " argument"
132900         in diagnostics to make them clearer.  Change wording of suffix
132901         message for clarity.
132902         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
132903         Argument_type_string.
132904         (STRTOL_FATAL_WARN): Remove; no longer used.
132905         * modules/human (Depends-on): Remove gettext-h.
132907 2007-08-06  Simon Josefsson  <simon@josefsson.org>
132909         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
132911 2007-07-31  Bruno Haible  <bruno@clisp.org>
132913         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
132914         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
132915         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
132917 2007-07-31  Bruno Haible  <bruno@clisp.org>
132919         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
132920         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
132922 2007-07-30  Bruno Haible  <bruno@clisp.org>
132924         * modules/base64 (License): Use the synonymous term "LGPLv2+".
132925         * modules/c-ctype (License): Likewise.
132926         * modules/c-strcase (License): Likewise.
132927         * modules/check-version (License): Likewise.
132928         * modules/iconv (License): Likewise.
132929         * modules/iconv_open (License): Likewise.
132930         * modules/read-file (License): Likewise.
132931         * modules/striconv (License): Likewise.
132932         * modules/strverscmp (License): Likewise.
132933         * modules/vasprintf (License): Likewise.
132934         * modules/crypto/des (License): Likewise.
132935         * modules/crypto/gc (License): Likewise.
132936         * modules/crypto/gc-arcfour (License): Likewise.
132937         * modules/crypto/gc-arctwo (License): Likewise.
132938         * modules/crypto/gc-des (License): Likewise.
132939         * modules/crypto/gc-hmac-md5 (License): Likewise.
132940         * modules/crypto/gc-hmac-sha1 (License): Likewise.
132941         * modules/crypto/gc-md2 (License): Likewise.
132942         * modules/crypto/gc-md4 (License): Likewise.
132943         * modules/crypto/gc-md5 (License): Likewise.
132944         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
132945         * modules/crypto/gc-random (License): Likewise.
132946         * modules/crypto/gc-rijndael (License): Likewise.
132947         * modules/crypto/gc-sha1 (License): Likewise.
132948         * modules/crypto/md2 (License): Likewise.
132949         * modules/crypto/md4 (License): Likewise.
132951 2007-07-30  Jim Meyering  <jim@meyering.net>
132953         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
132954         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
132955         it has valid stat data.  This bug would cause du not to count the
132956         sizes of inaccessible directories.
132957         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
132958         in <http://bugzilla.redhat.com/250077>.
132960 2007-07-25  Peter O'Gorman  <peter@pogma.com>
132961             Bruno Haible  <bruno@clisp.org>
132963         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
132964         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
132965         #include_next, gives a diagnostic about it, but reports no error in
132966         the exit code.
132967         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
132969 2007-07-24  Ben Pfaff  <blp@gnu.org>
132971         Improve name: "count-one-bits" is better than "popcount".
132972         * MODULES.html.sh: Update name.
132973         * lib/popcount.h: Renamed lib/count-one-bits.h.
132974         (popcount): Renamed count_one_bits.
132975         (popcountl): Renamed count_one_bits_l.
132976         (popcountll): Renamed count_one_bits_ll.
132977         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
132978         * modules/popcount: Renamed module/count-one-bits.
132979         * modules/popcount-tests: Renamed module/count-one-bits-tests.
132980         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
132982 2007-07-23  Ben Pfaff  <blp@gnu.org>
132984         * lib/popcount.h (popcount32): Reduce size of constants, to allow
132985         better code generation, and add U to large constants to avoid
132986         warnings, in non-GCC case.
132987         Suggested by Bruno Haible.
132989 2007-07-23  Ben Pfaff  <blp@gnu.org>
132991         * lib/popcount.h: Use verify_true instead of if...abort.
132992         * modules/popcount: Depend on verify module.
132993         Suggested by Jim Meyering.
132995 2007-07-23  Bruno Haible  <bruno@clisp.org>
132997         * gnulib-tool (func_import): Create a .cvsignore file also when the
132998         directory is not yet in CVS but the toplevel directory is. When
132999         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
133000         Reported by Karl Berry.
133002 2007-07-22  Ben Pfaff  <blp@gnu.org>
133004         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
133005         case.
133006         Suggested by Eric Blake.
133008 2007-07-22  Ben Pfaff  <blp@gnu.org>
133010         New module: popcount.
133011         * MODULES.html.sh: Add popcount.
133012         * modules/popcount: New file.
133013         * modules/popcount-tests: New file.
133014         * tests/test-popcount.c: New file.
133015         * lib/popcount.h: New file.
133016         * m4/popcount.m4: New file.
133018 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
133020         * build-aux/announce-gen: Update to GPLv3.
133022         * build-aux/config.guess: Update from config.
133024 2007-07-21  Bruno Haible  <bruno@clisp.org>
133026         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
133027         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
133029 2007-07-20  Jim Meyering  <jim@meyering.net>
133031         * check-module: Diagnose a self-dependency.
133033 2007-07-19  Bruno Haible  <bruno@clisp.org>
133035         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
133036         empty.
133037         Reported by Eric Blake.
133039 2007-07-18  Bruno Haible  <bruno@clisp.org>
133041         * gnulib-tool: New options --po-base, --po-domain.
133042         (func_usage): Document them.
133043         (pobase, po_domain): New variables.
133044         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
133045         DEFAULT_TEXT_DOMAIN.
133046         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
133047         (func_import): Consider pobase and po_domain. Create a po/ directory.
133048         (func_create_testdir): Set pobase and po_domain to empty.
133049         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
133050         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
133052 2007-07-18  Bruno Haible  <bruno@clisp.org>
133054         * gnulib-tool (func_get_automake_snippet): Synthesize also an
133055         EXTRA_DIST augmentation for files in build-aux/.
133057 2007-07-16  Bruno Haible  <bruno@clisp.org>
133059         * modules/lseek (License): Use the synonymous term "LGPLv2+".
133060         * modules/getdelim (License): Likewise.
133062 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
133064         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
133065         * modules/d-type (License): Likewise.
133066         * modules/extensions (License): Likewise.
133067         * modules/fnmatch (License): Likewise.
133068         * modules/fseeko (License): Likewise.
133069         * modules/getaddrinfo (License): Likewise.
133070         * modules/getline (License): Likewise.
133071         * modules/getlogin_r (License): Likewise.
133072         * modules/getpass (License): Likewise.
133073         * modules/gettimeofday (License): Likewise.
133074         * modules/glob (License): Likewise.
133075         * modules/inet_ntop (License): Likewise.
133076         * modules/malloc (License): Likewise.
133077         * modules/malloca (License): Likewise.
133078         * modules/memmem (License): Likewise.
133079         * modules/mempcpy (License): Likewise.
133080         * modules/memset (License): Likewise.
133081         * modules/minmax (License): Likewise.
133082         * modules/mktime (License): Likewise.
133083         * modules/netinet_in (License): Likewise.
133084         * modules/pathmax (License): Likewise.
133085         * modules/poll (License): Likewise.
133086         * modules/regex (License): Likewise.
133087         * modules/snprintf (License): Likewise.
133088         * modules/stdbool (License): Likewise.
133089         * modules/stdint (License): Likewise.
133090         * modules/stdio (License): Likewise.
133091         * modules/strcase (License): Likewise.
133092         * modules/strcasestr (License): Likewise.
133093         * modules/strdup (License): Likewise.
133094         * modules/string (License): Likewise.
133095         * modules/strndup (License): Likewise.
133096         * modules/strnlen (License): Likewise.
133097         * modules/strpbrk (License): Likewise.
133098         * modules/strptime (License): Likewise.
133099         * modules/strsep (License): Likewise.
133100         * modules/sys_select (License): Likewise.
133101         * modules/sys_socket (License): Likewise.
133102         * modules/sys_stat (License): Likewise.
133103         * modules/sys_time (License): Likewise.
133104         * modules/time (License): Likewise.
133105         * modules/time_r (License): Likewise.
133106         * modules/timegm (License): Likewise.
133107         * modules/unistd (License): Likewise.
133108         * modules/vsnprintf (License): Likewise.
133109         * modules/wctype (License): Likewise.
133111 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133113         * modules/argz (License): LGPLv2+.
133115 2007-07-15  Karl Berry  <karl@gnu.org>
133117         * doc/gnulib.texi: revise node structure per new fdl.texi.
133119 2007-07-14  Bruno Haible  <bruno@clisp.org>
133121         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
133122         the output file.
133123         * lib/uniname/uninames.h: Regenerated.
133125 2007-07-14  Karl Berry  <karl@gnu.org>
133127         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
133128         omitting sectioning and index commands.
133130 2007-07-13  Bruno Haible  <bruno@clisp.org>
133132         New gnulib-tool option --more-symlinks.
133133         * gnulib-tool (func_usage): Document --more-symlinks.
133134         (do_copyrights): New variable.
133135         Recognize option --more-symlinks.
133136         (func_import): Don't add a copyright notice transform to
133137         sed_transform_lib_file if do_copyrights is empty.
133139 2007-07-13  Bruno Haible  <bruno@clisp.org>
133141         * lib/vasnprintf.c (decimal_point_char): Define also if
133142         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
133143         && !NEED_PRINTF_DIRECTIVE_A.
133144         Reported by Clemens Koller <clemens.koller@anagramm.de> via
133145         Gary V. Vaughan <gary@gnu.org>.
133147 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
133149         * lib/inttypes_.h: Undo previous change, since it was fixed
133150         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
133152 2007-07-13  Bruno Haible  <bruno@clisp.org>
133154         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
133155         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
133157 2007-07-13  Jim Meyering  <jim@meyering.net>
133159         df: Don't fail for Tru64's "file-on-file mount".
133160         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
133161         so we fall through and use statfs instead.  Details here:
133162         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
133163         Reported by Albert Chin.
133165 2007-07-13  Bruno Haible  <bruno@clisp.org>
133167         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
133168         * modules/configmake (License): Likewise.
133169         * modules/gettext (License): Likewise.
133170         * modules/gettext-h (License): Likewise.
133171         * modules/include_next (License): Likewise.
133172         * modules/link-warning (License): Likewise.
133173         * modules/localcharset (License): Likewise.
133174         * modules/localename (License): Likewise.
133175         * modules/lock (License): Likewise.
133176         * modules/relocatable-lib-lgpl (License): Likewise.
133177         * modules/size_max (License): Likewise.
133178         * modules/vasnprintf (License): Likewise.
133179         * modules/wchar (License): Likewise.
133180         * modules/xsize (License): Likewise.
133182 2007-07-13  Bruno Haible  <bruno@clisp.org>
133184         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
133185         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
133187 2007-07-12  Bruno Haible  <bruno@clisp.org>
133189         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
133190         in the modules files.
133192 2007-07-11  Karl Berry  <karl@gnu.org>
133194         * MODULES.html.sh (func_module): use
133195          sed -e '\|^'"${includefile}"'$|d'
133196          instead of /.../d, to avoid errors on $includefile's containing /.
133198 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
133200         * gnulib-tool (func_import): Avoid duplication of --avoid
133201         statements
133202         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
133203         names to `_' in variable names.
133205 2007-07-10  Eric Blake  <ebb9@byu.net>
133207         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
133208         * NEWS: Document this change.
133210 2007-07-08  Bruno Haible  <bruno@clisp.org>
133212         Update to Unicode 5.0.
133213         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
133214         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
133215         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
133216         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
133217         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
133218         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
133219         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
133220         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
133221         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
133222         U+10A3F, U+1D242..U+1D244.
133223         (nonspacing_table_ind): Update.
133224         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
133225         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
133227 2007-07-08  Bruno Haible  <bruno@clisp.org>
133229         Update to Unicode 5.0.
133230         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
133231         code transform. Extend the name index field of unicode_name_to_code and
133232         unicode_code_to_name from 16 to 24 bits.
133233         * lib/uniname/uniname.c (unicode_character_name,
133234         unicode_name_character): Add the range 0x12xxx to the code transform.
133235         * lib/uniname/uninames.h: Regenerated.
133236         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
133238 2007-07-07  Bruno Haible  <bruno@clisp.org>
133240         * modules/wcwidth-tests: New file.
133241         * tests/test-wcwidth.c: New file.
133243         Work around MacOS X wcwidth() bug.
133244         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
133245         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
133246         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
133247         original wcwidth in non-UTF-8 locales.
133248         * modules/wcwidth (Depends-on): Add localcharset, streq,
133249         uniwidth/width.
133250         * doc/functions/wcwidth.texi: Update.
133252 2007-07-07  Bruno Haible  <bruno@clisp.org>
133254         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
133255         (wcwidth): New declaration.
133256         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
133257         macros.
133258         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
133259         here. Prepare for creating <wchar.h> unconditionally.
133260         * modules/wchar (Depends-on): Add link-warning.
133261         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
133262         REPLACE_WCWIDTH, and GL_LINK_WARNING.
133263         * lib/wcwidth.h: Remove file.
133264         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
133265         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
133266         * modules/wcwidth (Files): Remove lib/wcwidth.h.
133267         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
133268         (Include): Replace wcwidth.h with <wchar.h>.
133269         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
133270         * lib/mbchar.h: Don't include wcwidth.h.
133271         * lib/mbswidth.c: Likewise.
133272         * NEWS: Mention the change.
133274 2007-07-07  Bruno Haible  <bruno@clisp.org>
133276         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
133277         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
133278         definition with an external declaration.
133279         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
133280         defined as a function. Remove AC_C_INLINE requirement.
133281         * modules/wcwidth (Files): Add lib/wcwidth.c.
133282         (Makefile.am): Remove redundant statement.
133284 2007-07-07  Bruno Haible  <bruno@clisp.org>
133286         * MODULES.html.sh (Unicode string functions): Add the new modules.
133288         * tests/uniwidth/test-u32-strwidth.c: New file.
133289         * modules/uniwidth/u32-strwidth-tests: New file.
133291         * lib/uniwidth/u32-strwidth.c: New file.
133292         * modules/uniwidth/u32-strwidth: New file.
133294         * tests/uniwidth/test-u16-strwidth.c: New file.
133295         * modules/uniwidth/u16-strwidth-tests: New file.
133297         * lib/uniwidth/u16-strwidth.c: New file.
133298         * modules/uniwidth/u16-strwidth: New file.
133300         * tests/uniwidth/test-u8-strwidth.c: New file.
133301         * modules/uniwidth/u8-strwidth-tests: New file.
133303         * lib/uniwidth/u8-strwidth.c: New file.
133304         * modules/uniwidth/u8-strwidth: New file.
133306         * tests/uniwidth/test-u32-width.c: New file.
133307         * modules/uniwidth/u32-width-tests: New file.
133309         * lib/uniwidth/u32-width.c: New file.
133310         * modules/uniwidth/u32-width: New file.
133312         * tests/uniwidth/test-u16-width.c: New file.
133313         * modules/uniwidth/u16-width-tests: New file.
133315         * lib/uniwidth/u16-width.c: New file.
133316         * modules/uniwidth/u16-width: New file.
133318         * tests/uniwidth/test-u8-width.c: New file.
133319         * modules/uniwidth/u8-width-tests: New file.
133321         * lib/uniwidth/u8-width.c: New file.
133322         * modules/uniwidth/u8-width: New file.
133324         * tests/uniwidth/test-uc_width.c: New file.
133325         * modules/uniwidth/width-tests: New file.
133327         * lib/uniwidth/width.c: New file, from GNU libiconv.
133328         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
133329         * modules/uniwidth/width: New file.
133331         * lib/uniwidth.h: New file, from GNU libiconv.
133332         * modules/uniwidth/base: New file.
133334 2007-07-07  Bruno Haible  <bruno@clisp.org>
133336         * lib/uniname.h: New file, from GNU gettext.
133337         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
133338         * lib/uniname/uninames.h: New file, from GNU gettext.
133339         * lib/uniname/uniname.c: New file, from GNU gettext.
133340         * tests/uniname/test-uninames.sh: New file.
133341         * tests/uniname/test-uninames.c: New file, from GNU gettext.
133342         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
133343         * modules/uniname/base: New file.
133344         * modules/uniname/uniname: New file.
133345         * modules/uniname/uniname-tests: New file.
133346         * MODULES.html.sh (Unicode string functions): Add the new modules.
133348 2007-07-06  Bruno Haible  <bruno@clisp.org>
133350         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
133352 2007-07-06  Bruno Haible  <bruno@clisp.org>
133354         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
133355         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
133356         includes <cygwin/sys_time.h> which includes <sys/select.h> which
133357         include <sys/time.h>.
133358         Reported by Eric Blake.
133360 2007-07-06  Eric Blake  <ebb9@byu.net>
133362         Fix testing canonicalize on cygwin.
133363         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
133364         Revert patch from 2007-06-19.
133365         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
133366         canonicalize module is also in use.
133367         * tests/test-canonicalize.c: New file.
133368         * tests/test-canonicalize.sh: Likewise.
133369         * modules/canonicalize-tests: Likewise.
133371 2007-07-06  Jim Meyering  <jim@meyering.net>
133373         * lib/getugroups.c (getugroups): Detect getgrent failure.
133374         Adjust comment to reflect reality: this function may return -1.
133376 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
133378         * build-aux/bootstrap (TP_URL,get_translations): Update to use
133379         the new TP address.
133380         (usage): Fix typo
133381         (gnulib_mk): New variable.
133383 2007-07-05  Jim Meyering  <jim@meyering.net>
133385         Don't let endgrent clobber errno, no matter how improbable.
133386         * lib/getugroups.c (getugroups): Save and restore errno around
133387         endgrent call.
133389         Close the group DB even when failing with 2^31 or more members.
133390         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
133392 2007-07-04  Jim Meyering  <jim@meyering.net>
133394         * lib/getugroups.h: New file.
133395         * lib/getugroups.c: Include "getugroups.h".
133396         Remove uses of "register" keyword.
133397         Move local variable, "cp", down into scope where used.
133398         Give "username" parameter the "const" attribute.
133399         * modules/getugroups (Files): Add lib/getugroups.h
133401 2007-07-04  Karl Berry  <karl@gnu.org>
133403         * MODULES.html.sh (func_all_modules): Complete rename of
133404         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
133406 2007-07-02  Bruno Haible  <bruno@clisp.org>
133408         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
133409         mode, when inttypes.h comes from gnulib.
133410         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
133412 2007-07-02  Simon Josefsson  <simon@josefsson.org>
133414         * NEWS: Mention lgpl module name change.
133416         * modules/lgpl-2.1: Renamed from lgpl.
133418         * NEWS: Mention gpl module name change.
133420         * modules/gpl-3.0: New file, based on gpl-2.0.
133422         * modules/gpl-2.0: Renamed from gpl.
133424         * modules/gpl: Fix filename, doc/gpl.texi is now found at
133425         doc/gpl-2.0.texi.
133427 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
133429         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
133430         #define __STDC_LIMIT_MACROS temporarily while including
133431         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
133432         Problem reported by Joel E. Denny in
133433         <http://lists.gnu.org/r/bug-gnulib/2007-07/msg00008.html>.
133435 2007-07-01  Bruno Haible  <bruno@clisp.org>
133437         * lib/unistdio.h: New file.
133438         * lib/unistdio/u-asnprintf.h: New file.
133439         * lib/unistdio/u-asprintf.h: New file.
133440         * lib/unistdio/u-printf-args.c: New file.
133441         * lib/unistdio/u-printf-args.h: New file.
133442         * lib/unistdio/u-printf-parse.h: New file.
133443         * lib/unistdio/u-snprintf.h: New file.
133444         * lib/unistdio/u-sprintf.h: New file.
133445         * lib/unistdio/u-vasprintf.h: New file.
133446         * lib/unistdio/u-vsnprintf.h: New file.
133447         * lib/unistdio/u-vsprintf.h: New file.
133448         * lib/unistdio/ulc-asnprintf.c: New file.
133449         * lib/unistdio/ulc-asprintf.c: New file.
133450         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
133451         * lib/unistdio/ulc-printf-parse.c: New file.
133452         * lib/unistdio/ulc-snprintf.c: New file.
133453         * lib/unistdio/ulc-sprintf.c: New file.
133454         * lib/unistdio/ulc-vasnprintf.c: New file.
133455         * lib/unistdio/ulc-vasprintf.c: New file.
133456         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
133457         * lib/unistdio/ulc-vsnprintf.c: New file.
133458         * lib/unistdio/ulc-vsprintf.c: New file.
133459         * lib/unistdio/u8-asnprintf.c: New file.
133460         * lib/unistdio/u8-asprintf.c: New file.
133461         * lib/unistdio/u8-printf-parse.c: New file.
133462         * lib/unistdio/u8-snprintf.c: New file.
133463         * lib/unistdio/u8-sprintf.c: New file.
133464         * lib/unistdio/u8-vasnprintf.c: New file.
133465         * lib/unistdio/u8-vasprintf.c: New file.
133466         * lib/unistdio/u8-vsnprintf.c: New file.
133467         * lib/unistdio/u8-vsprintf.c: New file.
133468         * lib/unistdio/u8-u8-asnprintf.c: New file.
133469         * lib/unistdio/u8-u8-asprintf.c: New file.
133470         * lib/unistdio/u8-u8-snprintf.c: New file.
133471         * lib/unistdio/u8-u8-sprintf.c: New file.
133472         * lib/unistdio/u8-u8-vasnprintf.c: New file.
133473         * lib/unistdio/u8-u8-vasprintf.c: New file.
133474         * lib/unistdio/u8-u8-vsnprintf.c: New file.
133475         * lib/unistdio/u8-u8-vsprintf.c: New file.
133476         * lib/unistdio/u16-asnprintf.c: New file.
133477         * lib/unistdio/u16-asprintf.c: New file.
133478         * lib/unistdio/u16-printf-parse.c: New file.
133479         * lib/unistdio/u16-snprintf.c: New file.
133480         * lib/unistdio/u16-sprintf.c: New file.
133481         * lib/unistdio/u16-vasnprintf.c: New file.
133482         * lib/unistdio/u16-vasprintf.c: New file.
133483         * lib/unistdio/u16-vsnprintf.c: New file.
133484         * lib/unistdio/u16-vsprintf.c: New file.
133485         * lib/unistdio/u16-u16-asnprintf.c: New file.
133486         * lib/unistdio/u16-u16-asprintf.c: New file.
133487         * lib/unistdio/u16-u16-snprintf.c: New file.
133488         * lib/unistdio/u16-u16-sprintf.c: New file.
133489         * lib/unistdio/u16-u16-vasnprintf.c: New file.
133490         * lib/unistdio/u16-u16-vasprintf.c: New file.
133491         * lib/unistdio/u16-u16-vsnprintf.c: New file.
133492         * lib/unistdio/u16-u16-vsprintf.c: New file.
133493         * lib/unistdio/u32-asnprintf.c: New file.
133494         * lib/unistdio/u32-asprintf.c: New file.
133495         * lib/unistdio/u32-printf-parse.c: New file.
133496         * lib/unistdio/u32-snprintf.c: New file.
133497         * lib/unistdio/u32-sprintf.c: New file.
133498         * lib/unistdio/u32-vasnprintf.c: New file.
133499         * lib/unistdio/u32-vasprintf.c: New file.
133500         * lib/unistdio/u32-vsnprintf.c: New file.
133501         * lib/unistdio/u32-vsprintf.c: New file.
133502         * lib/unistdio/u32-u32-asnprintf.c: New file.
133503         * lib/unistdio/u32-u32-asprintf.c: New file.
133504         * lib/unistdio/u32-u32-snprintf.c: New file.
133505         * lib/unistdio/u32-u32-sprintf.c: New file.
133506         * lib/unistdio/u32-u32-vasnprintf.c: New file.
133507         * lib/unistdio/u32-u32-vasprintf.c: New file.
133508         * lib/unistdio/u32-u32-vsnprintf.c: New file.
133509         * lib/unistdio/u32-u32-vsprintf.c: New file.
133510         * tests/unistdio/test-ulc-asnprintf1.c: New file.
133511         * tests/unistdio/test-ulc-asnprintf1.h: New file.
133512         * tests/unistdio/test-ulc-printf1.h: New file.
133513         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
133514         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
133515         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
133516         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
133517         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
133518         * tests/unistdio/test-ulc-vasprintf1.c: New file.
133519         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
133520         * tests/unistdio/test-ulc-vsprintf1.c: New file.
133521         * tests/unistdio/test-u8-asnprintf1.c: New file.
133522         * tests/unistdio/test-u8-asnprintf1.h: New file.
133523         * tests/unistdio/test-u8-printf1.h: New file.
133524         * tests/unistdio/test-u8-vasnprintf1.c: New file.
133525         * tests/unistdio/test-u8-vasnprintf2.c: New file.
133526         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
133527         * tests/unistdio/test-u8-vasnprintf3.c: New file.
133528         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
133529         * tests/unistdio/test-u8-vasprintf1.c: New file.
133530         * tests/unistdio/test-u8-vsnprintf1.c: New file.
133531         * tests/unistdio/test-u8-vsprintf1.c: New file.
133532         * tests/unistdio/test-u16-asnprintf1.c: New file.
133533         * tests/unistdio/test-u16-asnprintf1.h: New file.
133534         * tests/unistdio/test-u16-printf1.h: New file.
133535         * tests/unistdio/test-u16-vasnprintf1.c: New file.
133536         * tests/unistdio/test-u16-vasnprintf2.c: New file.
133537         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
133538         * tests/unistdio/test-u16-vasnprintf3.c: New file.
133539         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
133540         * tests/unistdio/test-u16-vasprintf1.c: New file.
133541         * tests/unistdio/test-u16-vsnprintf1.c: New file.
133542         * tests/unistdio/test-u16-vsprintf1.c: New file.
133543         * tests/unistdio/test-u32-asnprintf1.c: New file.
133544         * tests/unistdio/test-u32-asnprintf1.h: New file.
133545         * tests/unistdio/test-u32-printf1.h: New file.
133546         * tests/unistdio/test-u32-vasnprintf1.c: New file.
133547         * tests/unistdio/test-u32-vasnprintf2.c: New file.
133548         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
133549         * tests/unistdio/test-u32-vasnprintf3.c: New file.
133550         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
133551         * tests/unistdio/test-u32-vasprintf1.c: New file.
133552         * tests/unistdio/test-u32-vsnprintf1.c: New file.
133553         * tests/unistdio/test-u32-vsprintf1.c: New file.
133554         * modules/unistdio/base: New file.
133555         * modules/unistdio/u-printf-args: New file.
133556         * modules/unistdio/ulc-asnprintf: New file.
133557         * modules/unistdio/ulc-asprintf: New file.
133558         * modules/unistdio/ulc-fprintf: New file.
133559         * modules/unistdio/ulc-printf-parse: New file.
133560         * modules/unistdio/ulc-snprintf: New file.
133561         * modules/unistdio/ulc-sprintf: New file.
133562         * modules/unistdio/ulc-vasnprintf: New file.
133563         * modules/unistdio/ulc-vasprintf: New file.
133564         * modules/unistdio/ulc-vfprintf: New file.
133565         * modules/unistdio/ulc-vsnprintf: New file.
133566         * modules/unistdio/ulc-vsprintf: New file.
133567         * modules/unistdio/u8-asnprintf: New file.
133568         * modules/unistdio/u8-asprintf: New file.
133569         * modules/unistdio/u8-printf-parse: New file.
133570         * modules/unistdio/u8-snprintf: New file.
133571         * modules/unistdio/u8-sprintf: New file.
133572         * modules/unistdio/u8-vasnprintf: New file.
133573         * modules/unistdio/u8-vasprintf: New file.
133574         * modules/unistdio/u8-vsnprintf: New file.
133575         * modules/unistdio/u8-vsprintf: New file.
133576         * modules/unistdio/u8-u8-asnprintf: New file.
133577         * modules/unistdio/u8-u8-asprintf: New file.
133578         * modules/unistdio/u8-u8-snprintf: New file.
133579         * modules/unistdio/u8-u8-sprintf: New file.
133580         * modules/unistdio/u8-u8-vasnprintf: New file.
133581         * modules/unistdio/u8-u8-vasprintf: New file.
133582         * modules/unistdio/u8-u8-vsnprintf: New file.
133583         * modules/unistdio/u8-u8-vsprintf: New file.
133584         * modules/unistdio/u16-asnprintf: New file.
133585         * modules/unistdio/u16-asprintf: New file.
133586         * modules/unistdio/u16-printf-parse: New file.
133587         * modules/unistdio/u16-snprintf: New file.
133588         * modules/unistdio/u16-sprintf: New file.
133589         * modules/unistdio/u16-vasnprintf: New file.
133590         * modules/unistdio/u16-vasprintf: New file.
133591         * modules/unistdio/u16-vsnprintf: New file.
133592         * modules/unistdio/u16-vsprintf: New file.
133593         * modules/unistdio/u16-u16-asnprintf: New file.
133594         * modules/unistdio/u16-u16-asprintf: New file.
133595         * modules/unistdio/u16-u16-snprintf: New file.
133596         * modules/unistdio/u16-u16-sprintf: New file.
133597         * modules/unistdio/u16-u16-vasnprintf: New file.
133598         * modules/unistdio/u16-u16-vasprintf: New file.
133599         * modules/unistdio/u16-u16-vsnprintf: New file.
133600         * modules/unistdio/u16-u16-vsprintf: New file.
133601         * modules/unistdio/u32-asnprintf: New file.
133602         * modules/unistdio/u32-asprintf: New file.
133603         * modules/unistdio/u32-printf-parse: New file.
133604         * modules/unistdio/u32-snprintf: New file.
133605         * modules/unistdio/u32-sprintf: New file.
133606         * modules/unistdio/u32-vasnprintf: New file.
133607         * modules/unistdio/u32-vasprintf: New file.
133608         * modules/unistdio/u32-vsnprintf: New file.
133609         * modules/unistdio/u32-vsprintf: New file.
133610         * modules/unistdio/u32-u32-asnprintf: New file.
133611         * modules/unistdio/u32-u32-asprintf: New file.
133612         * modules/unistdio/u32-u32-snprintf: New file.
133613         * modules/unistdio/u32-u32-sprintf: New file.
133614         * modules/unistdio/u32-u32-vasnprintf: New file.
133615         * modules/unistdio/u32-u32-vasprintf: New file.
133616         * modules/unistdio/u32-u32-vsnprintf: New file.
133617         * modules/unistdio/u32-u32-vsprintf: New file.
133618         * modules/unistdio/ulc-asnprintf-tests: New file.
133619         * modules/unistdio/ulc-vasnprintf-tests: New file.
133620         * modules/unistdio/ulc-vasprintf-tests: New file.
133621         * modules/unistdio/ulc-vsnprintf-tests: New file.
133622         * modules/unistdio/ulc-vsprintf-tests: New file.
133623         * modules/unistdio/u8-asnprintf-tests: New file.
133624         * modules/unistdio/u8-vasnprintf-tests: New file.
133625         * modules/unistdio/u8-vasprintf-tests: New file.
133626         * modules/unistdio/u8-vsnprintf-tests: New file.
133627         * modules/unistdio/u8-vsprintf-tests: New file.
133628         * modules/unistdio/u16-asnprintf-tests: New file.
133629         * modules/unistdio/u16-vasnprintf-tests: New file.
133630         * modules/unistdio/u16-vasprintf-tests: New file.
133631         * modules/unistdio/u16-vsnprintf-tests: New file.
133632         * modules/unistdio/u16-vsprintf-tests: New file.
133633         * modules/unistdio/u32-asnprintf-tests: New file.
133634         * modules/unistdio/u32-vasnprintf-tests: New file.
133635         * modules/unistdio/u32-vasprintf-tests: New file.
133636         * modules/unistdio/u32-vsnprintf-tests: New file.
133637         * modules/unistdio/u32-vsprintf-tests: New file.
133638         * MODULES.html.sh (Unicode string functions): Add the new modules.
133640 2007-07-01  Bruno Haible  <bruno@clisp.org>
133642         * lib/sprintf.c (sprintf): Limit the available length estimation,
133643         to avoid address wraparound.
133644         * lib/vsprintf.c (vsprintf): Likewise.
133645         * modules/sprintf-posix (Dependencies): Add stdint.
133646         * modules/vsprintf-posix (Dependencies): Likewise.
133648 2007-07-01  Bruno Haible  <bruno@clisp.org>
133650         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
133651         Windows PATH as well. Conservative double-quoting. Comments.
133653 2007-07-01  Bruno Haible  <bruno@clisp.org>
133654             Eric Blake  <ebb9@byu.net>
133655             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133657         * gnulib-tool (self_abspathname): Fix algorithm to cope with
133658         empty components in $PATH, denoting '.'.
133660 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133662         * gnulib-tool: Fix indentation.
133663         (func_create_megatestdir): Likewise.
133664         Report by Bruno Haible.
133666 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133668         Sync from Automake.
133669         * build-aux/gnupload: Fix shell portability issues with for loops.
133670         Report by Karl Berry.
133672 2007-06-29  Simon Josefsson  <simon@josefsson.org>
133674         * build-aux/maint.mk (POURL): Use translationproject.org.
133676 2007-06-27  Simon Josefsson  <simon@josefsson.org>
133677             Bruno Haible  <bruno@clisp.org>
133679         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
133680         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
133681         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
133682         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
133683         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
133685 2007-06-27  Bruno Haible  <bruno@clisp.org>
133687         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
133688         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
133690 2007-06-26  Karl Berry  <karl@gnu.org>
133692         * MODULES.html.sh: remove xreadlink-with-size.
133694 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
133696         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
133697         method that I hope also handles the double-include problem noted
133698         by Bruno Haible in
133699         <http://lists.gnu.org/r/bug-gnulib/2007-05/msg00186.html>.
133701 2007-06-23  Bruno Haible  <bruno@clisp.org>
133703         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
133704         Don't let the 'mostlyclean' target fail if the last subdirectory could
133705         not be removed.
133706         Reported by Karl Berry.
133708 2007-06-23  Bruno Haible  <bruno@clisp.org>
133710         * gnulib-tool (echo): Add a speedier workaround for ksh.
133711         * tests/test-echo.sh: Likewise.
133713 2007-06-23  Bruno Haible  <bruno@clisp.org>
133715         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
133716         * tests/test-echo.sh: Likewise.
133718 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133720         * gnulib-tool (IFS): Initialize early, so we don't set it to
133721         empty later.
133722         (self_abspathname): Rewrite algorithm to set it, reindent.
133723         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
133724         (func_create_megatestdir): Merge some sed scripts.
133726 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
133728         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
133729         exposed by Sun Studio 11 cc on Solaris 8.
133731 2007-06-22  Bruno Haible  <bruno@clisp.org>
133733         * gnulib-tool (echo): Ensure the echo primitive does not interpret
133734         backslashes.
133735         * tests/test-echo.sh: New file.
133737 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133739         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
133740         simplify `sed_replace_build_aux' scripts, they are portable but
133741         echoing them with `echo' is not.
133742         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
133744 2007-06-21  Karl Berry  <karl@gnu.org>
133746         * config/srclist.txt: guess we can't handle the licenses via
133747         srclist at the moment.
133749 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
133751         * MODULES.html.sh: Add include_next.
133752         * modules/include_next: New file.
133754 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
133756         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
133757         INCLUDE_NEXT.
133758         (gl_CHECK_NEXT_HEADERS): New macro.
133759         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
133760         the obsolescent gl_ABSOLUTE_HEADER.
133761         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
133762         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
133763         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
133764         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
133765         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
133766         * m4/math_h.m4 (gl_MATH_H): Likewise.
133767         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
133768         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
133769         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
133770         * m4/stdint.m4 (gl_STDINT_H): Likewise.
133771         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
133772         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
133773         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
133774         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
133775         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
133776         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
133777         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
133778         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
133779         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
133780         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
133781         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
133782         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
133783         * m4/inttypes.m4 (gl_INTTYPES_H): Define
133784         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
133785         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
133786         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
133787         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
133788         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
133789         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
133790         * lib/float_.h: Likewise.
133791         * lib/inttypes_.h: Likewise.
133792         * lib/math_.h: Likewise.
133793         * lib/search_.h: Likewise.
133794         * lib/signal_.h: Likewise.
133795         * lib/stdint_.h: Likewise.
133796         * lib/stdio_.h: Likewise.
133797         * lib/stdlib_.h: Likewise.
133798         * lib/string_.h: Likewise.
133799         * lib/sys_stat_.h: Likewise.
133800         * lib/sys_time_.h: Likewise.
133801         * lib/time_.h: Likewise.
133802         * lib/unistd_.h: Likewise.
133803         * lib/wchar_.h: Likewise.
133804         * lib/wctype_.h: Likewise.
133805         * lib/dirent_.h: Likewise.
133806         * lib/iconv_.h: Likewise.
133807         * lib/locale_.h: Likewise.
133808         * lib/netinet_in_.h: Likewise.
133809         * lib/sys_select_.h: Likewise.
133810         * lib/sys_socket_.h: Likewise.
133811         * lib/sysexits_.h: Likewise.
133812         * modules/fcntl (Depends-on): Depend on include_next, not
133813         absolute_header.
133814         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
133815         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
133816         * modules/fchdir: Likewise.
133817         * modules/float: Likewise.
133818         * modules/iconv_open: Likewise.
133819         * modules/inttypes: Likewise.
133820         * modules/locale: Likewise.
133821         * modules/math: Likewise.
133822         * modules/netinet_in: Likewise.
133823         * modules/search: Likewise.
133824         * modules/signal: Likewise.
133825         * modules/stdint: Likewise.
133826         * modules/stdio: Likewise.
133827         * modules/stdlib: Likewise.
133828         * modules/string: Likewise.
133829         * modules/sys_select: Likewise.
133830         * modules/sys_socket: Likewise.
133831         * modules/sys_stat: Likewise.
133832         * modules/sys_time: Likewise.
133833         * modules/sysexits: Likewise.
133834         * modules/time: Likewise.
133835         * modules/unistd: Likewise.
133836         * modules/wchar: Likewise.
133837         * modules/wctype: Likewise.
133838         * modules/sys_stat: Change maintainer to "all".
133839         * modules/unistd: Likewise.
133841 2007-06-20  Karl Berry  <karl@gnu.org>
133843         * config/srclist.txt: track www changes in license files.
133845 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
133847         * build-aux/bootstrap: Remove stray dot.
133848         Make sure build_aux settings are honored when linking
133849         gnulib_extra_files.
133851 2007-06-19  Eric Blake  <ebb9@byu.net>
133853         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
133854         Allow compilation on cygwin.
133856 2007-06-19  Jim Meyering  <jim@meyering.net>
133858         xreadlink-with-size: Remove module.  No longer used.
133859         Ex-callers now use xreadlink or mreadlink-with-size.
133860         * modules/xreadlink-with-size: Remove module.
133861         * lib/xreadlink-with-size.c: Remove file.
133862         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
133863         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
133864         just before the function definition *is* accurate.
133866         Eliminate one way canonicalize_filename_mode could exit.
133867         * lib/canonicalize.c (canonicalize_filename_mode):
133868         Use mreadlink_with_size, not xreadlink_with_size.
133870 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
133872         Detect porting problems to FreeBSD/arm, which has time_t wider than
133873         long int.  Original problem reported for GNU diff by Xin Li in
133874         <http://lists.gnu.org/r/bug-gnu-utils/2007-06/msg00091.html>.
133875         * modules/getdate (Depends-on): Add intprops, verify.
133876         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
133877         is an integer type no wider than long int.
133879 2007-06-18  Jim Meyering  <jim@meyering.net>
133881         New module: mreadlink-with-size.
133882         * MODULES.html.sh: Add mreadlink-with-size.
133883         * modules/mreadlink-with-size: New module
133884         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
133885         not xreadlink-with-size.
133886         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
133888 2007-06-16  Bruno Haible  <bruno@clisp.org>
133890         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
133891         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
133892         Reported by Gary V. Vaughan <gary@gnu.org>.
133894 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
133896         Revamp lchown so that it lives in unistd.h where it belongs.
133897         * lib/lchown.h: Remove.
133898         * lib/dirchownmod.c: Don't include lib/lchown.h.
133899         * lib/fchownat.c: Likewise.
133900         * lib/openat.c: Likewise.
133901         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
133902         does not follow symlinks.
133903         (EOPNOTSUPP): Define if not defined.
133904         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
133905         is defined to 0.
133906         (lchown): New decl.
133907         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
133908         Do not check for lchown decl.
133909         Set REPLACE_LCHOWN.
133910         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
133911         REPLACE_LCHOWN.
133912         * modules/chown: Make it clear it follows symlinks.
133913         * modules/lchown: Make it clear it doesn't follow symlinks.
133914         (Files): Remove lib/lchown.h
133915         (Depends-on): Add unistd.
133916         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
133917         (Include): Include <unistd.h>, not "lchown.h".
133918         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
133919         REPLACE_LCHOWN.
133921 2007-06-15  Jim Meyering  <jim@meyering.net>
133923         Change license (GPL to LGPL) of fsusage and dependents.
133924         * modules/fsusage (License): Change to LGPL.
133925         * modules/full-read (License): Likewise.
133926         * modules/full-write (License): Likewise.
133927         * modules/safe-read (License): Likewise.
133928         * modules/safe-write (License): Likewise.
133930 2007-06-14  Ben Pfaff  <blp@gnu.org>
133932         Missing part of allocsa -> malloca transition.
133933         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
133934         gl_MALLOCA.
133936 2007-06-12  Bruno Haible  <bruno@clisp.org>
133938         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
133939         to ia64, x86_64, i386.
133940         Reported by Eric Blake.
133942 2007-06-12  Bruno Haible  <bruno@clisp.org>
133944         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
133945         cross-compiling to x86_64.
133947 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
133949         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
133950         glitch reported by Ralf Wildenhues in
133951         <http://lists.gnu.org/r/bug-gnulib/2007-06/msg00114.html>.
133953         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
133954         Vin Shelton.
133956 2007-06-11  Bruno Haible  <bruno@clisp.org>
133958         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
133959         replacement string.
133960         Reported by Eric Blake.
133962 2007-06-10  Bruno Haible  <bruno@clisp.org>
133964         Prepare vasnprintf code for use with Unicode strings.
133965         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
133966         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
133967         TYPE_U32_STRING.
133968         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
133969         a_u32_string variants.
133970         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
133971         * lib/printf-args.c: Don't include config.h and the specification
133972         header if PRINTF_FETCHARGS is already defined.
133973         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
133974         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
133975         TYPE_U16_STRING, TYPE_U32_STRING.
133976         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
133977         u16_directive, u16_directives, u32_directive, u32_directives): New
133978         types.
133979         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
133980         New declarations.
133981         * lib/printf-parse.c: Don't include config.h and the specification
133982         header if PRINTF_PARSE is already defined. Eliminate the set of
133983         parameters for WIDE_CHAR_VERSION; the user of this file must provide
133984         them now. Include c-ctype.h.
133985         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
133986         directive and CHAR_T_ONLY_ASCII.
133987         * lib/vasnprintf.c: Don't include config.h and the specification header
133988         if VASNPRINTF is already defined.
133989         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
133990         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
133991         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
133992         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
133993         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
133994         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
133995         code accordingly.
133996         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
133997         pad_ourselves also in this case, with the 'c' and 's' directives, and
133998         with a different notion of "width".
133999         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
134001 2007-06-10  Bruno Haible  <bruno@clisp.org>
134003         * modules/unistr/u32-mbsnlen: New file.
134004         * lib/unistr/u32-mbsnlen.c: New file.
134006         * modules/unistr/u16-mbsnlen: New file.
134007         * lib/unistr/u16-mbsnlen.c: New file.
134009         * modules/unistr/u8-mbsnlen: New file.
134010         * lib/unistr/u8-mbsnlen.c: New file.
134012         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
134013         declarations.
134015 2007-06-10  Bruno Haible  <bruno@clisp.org>
134017         * lib/string_.h (mbsnlen): New declaration.
134018         * lib/mbsnlen.c: New file.
134019         * m4/mbsnlen.m4: New file.
134020         * modules/mbsnlen: New file.
134021         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
134022         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
134023         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
134025 2007-06-10  Bruno Haible  <bruno@clisp.org>
134027         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
134029 2007-06-10  Bruno Haible  <bruno@clisp.org>
134031         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
134032         * lib/mbuiter.h: Likewise.
134034 2007-06-10  Bruno Haible  <bruno@clisp.org>
134036         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
134037         declaration.
134039 2007-06-10  Karl Berry  <karl@gnu.org>
134041         * config/srclist.txt: remove gettext entries, Bruno prefers
134042         to update individually.
134044 2007-06-10  Bruno Haible  <bruno@clisp.org>
134046         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
134047         'maxlen'. Ensure only length + width bytes are allocated, not
134048         length + 1 + width.
134050 2007-06-09  Bruno Haible  <bruno@clisp.org>
134052         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
134053         (CHAR_T): Remove macro.
134054         (VASNPRINTF): Update.
134056 2007-06-09  Bruno Haible  <bruno@clisp.org>
134058         * MODULES.html.sh (Unicode string functions): Add the new modules.
134060         * modules/uniconv/u32-conv-to-enc: New file.
134061         * lib/uniconv/u32-conv-to-enc.c: New file.
134062         * modules/uniconv/u32-conv-to-enc-tests: New file.
134063         * tests/uniconv/test-u32-conv-to-enc.c: New file.
134065         * modules/uniconv/u16-conv-to-enc: New file.
134066         * lib/uniconv/u16-conv-to-enc.c: New file.
134067         * lib/uniconv/u-conv-to-enc.h: New file.
134068         * modules/uniconv/u16-conv-to-enc-tests: New file.
134069         * tests/uniconv/test-u16-conv-to-enc.c: New file.
134071         * modules/uniconv/u8-conv-to-enc: New file.
134072         * lib/uniconv/u8-conv-to-enc.c: New file.
134073         * modules/uniconv/u8-conv-to-enc-tests: New file.
134074         * tests/uniconv/test-u8-conv-to-enc.c: New file.
134076         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
134077         u32_conv_to_encoding): New declarations.
134079 2007-06-09  Bruno Haible  <bruno@clisp.org>
134081         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
134083 2007-06-09  Bruno Haible  <bruno@clisp.org>
134085         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
134086         * modules/malloca: Renamed from modules/allocsa, updated.
134087         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
134088         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
134089         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
134090         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
134091         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
134092         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
134093         * modules/xmalloca: Renamed from modules/xallocsa, updated.
134094         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
134095         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
134096         * modules/c-strcasestr (Depends-on): Update.
134097         * lib/c-strcasestr.c: Update.
134098         * modules/c-strstr (Depends-on): Update.
134099         * lib/c-strstr.c: Update.
134100         * modules/canonicalize-lgpl (Depends-on): Update.
134101         * lib/canonicalize-lgpl.c: Update.
134102         * modules/clean-temp (Depends-on): Update.
134103         * lib/clean-temp.c: Update.
134104         * modules/csharpcomp (Depends-on): Update.
134105         * lib/csharpcomp.c: Update.
134106         * modules/csharpexec (Depends-on): Update.
134107         * lib/csharpexec.c: Update.
134108         * modules/javacomp (Depends-on): Update.
134109         * lib/javacomp.c: Update.
134110         * modules/javaexec (Depends-on): Update.
134111         * lib/javaexec.c: Update.
134112         * modules/mbscasestr (Depends-on): Update.
134113         * lib/mbscasestr.c: Update.
134114         * modules/mbsstr (Depends-on): Update.
134115         * lib/mbsstr.c: Update.
134116         * modules/setenv (Depends-on): Update.
134117         * lib/setenv.c: Update.
134118         * modules/strcasestr (Depends-on): Update.
134119         * lib/strcasestr.c: Update.
134120         * modules/striconveha (Depends-on): Update.
134121         * lib/striconveha.c: Update.
134122         * modules/relocatable-prog-wrapper (Files): Update.
134123         * lib/relocwrapper.c: Update.
134124         * build-aux/install-reloc: Update.
134125         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
134127 2007-06-08  Bruno Haible  <bruno@clisp.org>
134129         Port to uClibc.
134130         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
134131         * lib/fpurge.c (fpurge): Likewise.
134132         * lib/freading.c (freading): Likewise.
134133         * lib/fseeko.c (rpl_fseeko): Likewise.
134134         * lib/fseterr.c (fseterr): Likewise.
134135         * lib/fwriting.c (fwriting): Likewise.
134136         * tests/test-fflush.c (main): Avoid a failure on uClibc.
134138 2007-06-08  Bruno Haible  <bruno@clisp.org>
134140         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
134141         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
134142         * modules/gettext (Files): Add m4/intlmacosx.m4.
134144 2007-06-07  Bruno Haible  <bruno@clisp.org>
134146         * modules/localename-tests: New file.
134147         * tests/test-localename.c: New file.
134149         New module 'localename'.
134150         * lib/localename.h: New file.
134151         * lib/localename.c: New file, from GNU gettext.
134152         * m4/localename.m4: New file.
134153         * modules/localename: New file.
134155 2007-06-07  Bruno Haible  <bruno@clisp.org>
134157         Work around the lack of <wchar.h> on some builds of uClibc.
134158         * doc/headers/wchar.texi: Update.
134159         * lib/wchar_.h: Include <wchar.h> only if it exists.
134160         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
134161         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
134162         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
134163         doesn't exist.
134164         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
134165         * modules/mbfile (Depends-on): Add wchar.
134166         * modules/mbiter (Depends-on): Likewise.
134167         * modules/mbuiter (Depends-on): Likewise.
134168         Reported by Simon Josefsson.
134170 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
134172         Work around problem reported by Steven M. Schweda in
134173         <http://lists.gnu.org/r/bug-tar/2007-06/msg00002.html>:
134174         Tru64 5.1B with the Compaq compiler environment installed declares
134175         an 'isblank' function but does not define it in the C library.
134176         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
134177         * lib/regex_internal.h (isblank): Likewise.
134178         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
134179         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
134181 2007-06-05  Bruno Haible  <bruno@clisp.org>
134183         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
134184         ia64.
134185         * modules/printf-safe: New file.
134186         * modules/fprintf-posix (Depends-on): Add printf-safe.
134187         * modules/printf-posix (Depends-on): Likewise.
134188         * modules/snprintf-posix (Depends-on): Likewise.
134189         * modules/sprintf-posix (Depends-on): Likewise.
134190         * modules/vasnprintf-posix (Depends-on): Likewise.
134191         * modules/vasprintf-posix (Depends-on): Likewise.
134192         * modules/vfprintf-posix (Depends-on): Likewise.
134193         * modules/vprintf-posix (Depends-on): Likewise.
134194         * modules/vsnprintf-posix (Depends-on): Likewise.
134195         * modules/vsprintf-posix (Depends-on): Likewise.
134196         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
134197         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
134198         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
134199         "no" on i386, x86_64, ia64.
134200         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
134201         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
134202         on i386, x86_64, ia64.
134203         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
134204         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
134205         on i386, x86_64, ia64.
134206         * tests/test-vasnprintf-posix.c: Include float.h.
134207         (LDBL80_WORDS): New macro.
134208         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
134209         on i386, x86_64, ia64.
134210         * tests/test-vasprintf-posix.c: Include float.h.
134211         (LDBL80_WORDS): New macro.
134212         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
134213         on i386, x86_64, ia64.
134214         * tests/test-snprintf-posix.c: Include float.h.
134215         * tests/test-sprintf-posix.c: Likewise.
134216         * tests/test-vsnprintf-posix.c: Likewise.
134217         * tests/test-vsprintf-posix.c: Likewise.
134219 2007-06-05  Bruno Haible  <bruno@clisp.org>
134221         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
134222         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
134223         non-IEEE numbers on i386, x86_64, ia64.
134224         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
134225         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
134226         * tests/test-isnanl.h: Include float.h.
134227         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
134229 2007-06-05  Bruno Haible  <bruno@clisp.org>
134231         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
134232         also the %a / %A. Handle the %a / %A code before this extra handling.
134234 2007-06-05  Bruno Haible  <bruno@clisp.org>
134236         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
134237         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
134239 2007-06-05  Bruno Haible  <bruno@clisp.org>
134241         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
134242         typo in variable name.
134244 2007-06-05  Eric Blake  <ebb9@byu.net>
134246         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
134247         Reported by Simon Josefsson.
134249 2007-06-04  Bruno Haible  <bruno@clisp.org>
134251         Avoid test failures on some PowerPC platforms.
134252         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
134253         Define differently for PowerPC.
134254         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
134255         Reported by Gary V. Vaughan <gary@gnu.org>.
134257 2007-06-02  Bruno Haible  <bruno@clisp.org>
134259         Fix test-stdint failure on FreeBSD/ia64.
134260         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
134261         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
134262         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
134263         * doc/headers/stdint.texi: Update.
134265 2007-06-01  Bruno Haible  <bruno@clisp.org>
134267         * tests/test-binary-io.c (main): Pass a third argument to open().
134268         Reported by Gary V. Vaughan <gary@gnu.org>.
134270 2007-06-01  Bruno Haible  <bruno@clisp.org>
134272         * doc/functions/frexpl.texi: Update for mingw.
134274 2007-06-01  Bruno Haible  <bruno@clisp.org>
134276         * tests/test-lseek.c (main): Disable test of errno for invalid third
134277         argument.
134278         * doc/functions/lseek.texi: Update.
134279         Reported by Gary V. Vaughan <gary@gnu.org>.
134281 2007-05-28  Bruno Haible  <bruno@clisp.org>
134283         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
134285 2007-05-31  Eric Blake  <ebb9@byu.net>
134287         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
134288         cross compiling.
134290 2007-05-30  Eric Blake  <ebb9@byu.net>
134291         and Bruno Haible  <bruno@clisp.org>
134293         Work around mingw test failures exposed by m4-1.4.9b.
134294         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
134295         * tests/test-unistd.c: Disable uid_t and git_t tests for the
134296         moment.
134298 2007-05-30  Bruno Haible  <bruno@clisp.org>
134300         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
134301         assuming that they are closed. Needed on HP-UX 11.
134303 2007-05-29  Bruno Haible  <bruno@clisp.org>
134305         Fix a problem with #include_next.
134306         * lib/dirent_.h: Split the double-inclusion guard.
134307         * lib/fcntl_.h: Likewise.
134308         * lib/float_.h: Likewise.
134309         * lib/iconv_.h: Likewise.
134310         * lib/inttypes_.h: Likewise.
134311         * lib/locale_.h: Likewise.
134312         * lib/math_.h: Likewise.
134313         * lib/netinet_in_.h: Likewise.
134314         * lib/search_.h: Likewise.
134315         * lib/signal_.h: Likewise.
134316         * lib/stdint_.h: Likewise.
134317         * lib/stdio_.h: Likewise.
134318         * lib/stdlib_.h: Likewise.
134319         * lib/string_.h: Likewise.
134320         * lib/sys_select_.h: Likewise.
134321         * lib/sys_socket_.h: Likewise.
134322         * lib/sys_stat_.h: Likewise.
134323         * lib/sys_time_.h: Likewise.
134324         * lib/sysexits_.h: Likewise.
134325         * lib/time_.h: Likewise.
134326         * lib/unistd_.h: Likewise.
134327         * lib/wchar_.h: Likewise.
134328         * lib/wctype_.h: Likewise.
134330 2007-05-29  Bruno Haible  <bruno@clisp.org>
134332         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
134333         for the moment.
134335 2007-05-29  Bruno Haible  <bruno@clisp.org>
134337         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
134338         invocation.
134339         Reported by Eric Blake.
134341 2007-05-29  Bruno Haible  <bruno@clisp.org>
134343         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
134344         compiling case.
134346 2007-05-29  Eric Blake  <ebb9@byu.net>
134347             Bruno Haible  <bruno@clisp.org>
134349         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
134350         cross compiles.
134352 2007-05-28  Eric Blake  <ebb9@byu.net>
134354         * modules/closein-tests (test_closein_LDADD): Support test on
134355         cygwin with libtool.
134357 2007-05-28  Bruno Haible  <bruno@clisp.org>
134359         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
134360         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
134361         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
134362         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
134363         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
134364         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
134365         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
134366         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
134367         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
134369 2007-05-28  Eric Blake  <ebb9@byu.net>
134371         Unconditionally include <config.h> in unit tests.
134372         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
134373         * tests/test-allocsa.c, tests/test-arcfour.c,
134374         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
134375         tests/test-array_list.c, tests/test-array_oset.c,
134376         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
134377         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
134378         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
134379         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
134380         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
134381         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
134382         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
134383         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
134384         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
134385         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
134386         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
134387         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
134388         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
134389         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
134390         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
134391         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
134392         test-md5.c, test-memmem.c, test-printf-posix.c,
134393         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
134394         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
134395         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
134396         test-strcasestr.c, test-striconv.c, test-striconveh.c,
134397         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
134398         test-vasnprintf-posix2.c, test-vasnprintf.c,
134399         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
134400         test-vfprintf-posix.c, test-vprintf-posix.c,
134401         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
134402         test-xvasprintf.c: Likewise.
134404 2007-05-28  Bruno Haible  <bruno@clisp.org>
134406         * gnulib-tool (func_import): Remember the --with-tests command-line
134407         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
134408         Reported by Eric Blake.
134410 2007-05-28  Bruno Haible  <bruno@clisp.org>
134412         * modules/ftell-tests: New file.
134413         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
134414         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
134416         * lib/ftell.c: New file.
134417         * modules/ftell: New file.
134418         * m4/ftell.m4: New file.
134419         * doc/functions/ftell.texi: Update.
134420         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
134421         REPLACE_FTELL.
134422         * lib/stdio_.h (rpl_ftell): New declaration.
134423         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
134424         REPLACE_FTELL.
134426 2007-05-28  Eric Blake  <ebb9@byu.net>
134428         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
134430 2007-05-28  Bruno Haible  <bruno@clisp.org>
134432         * modules/fseek-tests: New file.
134433         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
134434         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
134436         * lib/fseek.c: New file.
134437         * modules/fseek: New file.
134438         * m4/fseek.m4: New file.
134439         * doc/functions/fseek.texi: Update.
134440         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
134441         REPLACE_FSEEK.
134442         * lib/stdio_.h (rpl_fseek): New declaration.
134443         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
134444         REPLACE_FSEEK.
134446 2007-05-28  Bruno Haible  <bruno@clisp.org>
134448         * lib/stdio_.h (fflush): More comments.
134450 2007-05-28  Bruno Haible  <bruno@clisp.org>
134452         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
134453         runtime test.
134455 2007-05-28  Eric Blake  <ebb9@byu.net>
134457         Improve lseek module.
134458         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
134459         * lib/unistd_.h (lseek): Scale back link warning message.
134460         * tests/test-lseek.c: Beef up test.
134461         * tests/test-lseek.sh: Exercise more facets of lseek.
134462         Reported by Bruno Haible.
134464 2007-05-28  Bruno Haible  <bruno@clisp.org>
134466         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
134467         to define.
134469 2007-05-27  Bruno Haible  <bruno@clisp.org>
134471         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
134473 2007-05-27  Bruno Haible  <bruno@clisp.org>
134475         * modules/openmp: New file.
134476         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
134477         Noah Misch.
134479 2007-05-26  Bruno Haible  <bruno@clisp.org>
134481         * modules/chdir-long (Depends-on): Add fchdir.
134482         * modules/chdir-safer (Depends-on): Likewise.
134483         * modules/fts (Depends-on): Likewise.
134484         * modules/fts-lgpl (Depends-on): Likewise.
134485         * modules/openat (Depends-on): Likewise.
134486         * modules/savewd (Depends-on): Likewise.
134488 2007-05-24  Eric Blake  <ebb9@byu.net>
134490         Fix lseek on mingw.
134491         * modules/lseek: New module.
134492         * m4/lseek.m4: New file.
134493         * lib/lseek.c: New file.
134494         * modules/lseek-tests: New file.
134495         * tests/test-lseek.c: New file.
134496         * tests/test-lseek.sh: New file.
134497         * MODULES.html.sh: Document lseek module.
134498         * modules/fflush (Depends-on): Add lseek, fseeko.
134499         * modules/fseeko (Depends-on): Likewise.
134500         * modules/ftello (Depends-on): Likewise.
134501         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
134502         broken.
134503         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
134504         broken.
134505         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
134506         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
134507         * lib/ftello.c (rpl_ftello): Likewise.
134508         * tests/test-fseeko.c (main): Test this.
134509         * tests/test-fseeko.sh: Likewise.
134510         * tests/test-ftello.c (main): Likewise.
134511         * tests/test-ftello.sh: Likewise.
134512         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
134513         implies replacing fseek.
134514         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
134515         HAVE_FTELLO.
134516         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
134517         * modules/unistd (Makefile.am): Likewise.
134518         * lib/unistd_.h (lseek): Declare a replacement.
134519         * doc/functions/lseek.texi (lseek): Document this fix.
134520         * doc/functions/fseek.texi (fseek): Likewise.
134521         * doc/functions/ftell.texi (ftell): Likewise.
134523 2007-05-24  Bruno Haible  <bruno@clisp.org>
134525         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
134526         in the printed representation of a NaN.
134527         * tests/test-vasprintf-posix.c (test_function): Likewise.
134528         * tests/test-snprintf-posix.h (test_function): Likewise.
134529         * tests/test-sprintf-posix.h (test_function): Likewise.
134530         Reported by Eric Blake.
134532 2007-05-23  Eric Blake  <ebb9@byu.net>
134534         Fix fseeko/ftello on cygwin 1.5.24.
134535         * doc/functions/fseeko.texi (fseeko): Document the fix.
134536         * doc/functions/ftello.texi (ftello): Document the fix.
134537         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
134538         * doc/functions/stdout.text (stdout): New file.
134539         * doc/functions/stderr.text (stderr): New file.
134540         * doc/gnulib.texi (Function Substitutes): Use new files.
134541         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
134542         prior to 1.7.0.
134543         * tests/test-ftello.c (main): Likewise for ftello.
134544         * tests/test-fseeko.sh: New file.
134545         * tests/test-ftello.sh: New file.
134546         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
134547         with seekable stdin.
134548         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
134549         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
134550         (gl_REPLACE_FSEEKO): New macro.
134551         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
134552         * modules/fseeko (Files): Distribute fseeko.c.
134553         * modules/ftello (Files): Distribute ftello.c.
134554         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
134555         mode.
134556         * lib/ftello.c (rpl_ftello): New file.
134557         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
134558         fseeko, ftello.
134559         (gl_STDIN_LARGE_OFFSET): New macro.
134560         * modules/stdio (Makefile.am): Perform the replacement.
134561         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
134563 2007-05-23  Bruno Haible  <bruno@clisp.org>
134565         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
134566         GNULIB_POSIXCHECK is defined.
134568 2007-05-21  Bruno Haible  <bruno@clisp.org>
134570         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
134571         Check also the output for NaN arguments. When cross-compiling, guess
134572         no on IRIX.
134573         * lib/vasnprintf.c: Update comments.
134574         * tests/test-vasnprintf-posix.c (strisnan): New function.
134575         (test_function): Use it.
134576         * tests/test-vasprintf-posix.c (strisnan): New function.
134577         (test_function): Use it.
134578         * tests/test-snprintf-posix.h (strisnan): New function.
134579         (test_function): Use it.
134580         * tests/test-sprintf-posix.h (strisnan): New function.
134581         (test_function): Use it.
134582         Reported by Eric Blake.
134584 2007-05-20  Bruno Haible  <bruno@clisp.org>
134586         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
134587         numbers that fails on BeOS.
134588         * doc/functions/frexpl.texi: Update.
134590 2007-05-20  Jim Meyering  <jim@meyering.net>
134592         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
134593         forced upon us by glibc-2.6.
134595 2007-05-20  Bruno Haible  <bruno@clisp.org>
134597         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
134598         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
134599         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
134600         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
134601         NEED_PRINTF_INFINITE.
134602         (is_infinitel): New function.
134603         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
134604         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
134605         gl_PREREQ_VASNPRINTF_INFINITE.
134606         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
134607         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
134608         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
134609         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
134610         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
134611         gl_PREREQ_VASNPRINTF_INFINITE.
134612         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
134613         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
134614         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
134615         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
134616         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
134617         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
134618         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
134619         * doc/functions/fprintf.texi: Update.
134620         * doc/functions/printf.texi: Update.
134621         * doc/functions/snprintf.texi: Update.
134622         * doc/functions/sprintf.texi: Update.
134623         * doc/functions/vfprintf.texi: Update.
134624         * doc/functions/vprintf.texi: Update.
134625         * doc/functions/vsnprintf.texi: Update.
134626         * doc/functions/vsprintf.texi: Update.
134628 2007-05-20  Bruno Haible  <bruno@clisp.org>
134630         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
134631         was not found in libc.
134632         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
134634 2007-05-20  Bruno Haible  <bruno@clisp.org>
134636         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
134637         printed as "-nan" instead of "nan".
134638         * tests/test-vasprintf-posix.c (test_function): Likewise.
134639         * tests/test-snprintf-posix.h (test_function): Likewise.
134640         * tests/test-sprintf-posix.h (test_function): Likewise.
134641         Needed for HP-UX 11.
134643 2007-05-20  Jim Meyering  <jim@meyering.net>
134645         Fix buggy test for the fchownat-deref bug.
134646         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
134647         symlink required for the run-test.  Without it, this test would
134648         always declare that fchownat doesn't work, and client code would
134649         unnecessarily use the replacement function with fixed libc.
134650         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
134651         Reported by Greg Schafer.
134653 2007-05-19  Bruno Haible  <bruno@clisp.org>
134655         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
134656         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
134657         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
134658         Needed for IRIX 6.5 and Solaris 2.5.1.
134660 2007-05-19  Bruno Haible  <bruno@clisp.org>
134662         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
134663         (test_function): Skip tests involving -0.0 on platforms where
134664         -0.0 = 0.0.
134665         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
134666         (test_function): Skip tests involving -0.0 on platforms where
134667         -0.0 = 0.0.
134668         * tests/test-snprintf-posix.h (have_minus_zero): New function.
134669         (test_function): Skip tests involving -0.0 on platforms where
134670         -0.0 = 0.0.
134671         * tests/test-sprintf-posix.h (have_minus_zero): New function.
134672         (test_function): Skip tests involving -0.0 on platforms where
134673         -0.0 = 0.0.
134674         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
134675         tests.
134676         * tests/test-printf-posix.h (test_function): Likewise.
134677         * tests/test-printf-posix.output: Remove all -0.0 related results.
134678         Needed for IRIX 6.5.
134680 2007-05-19  Bruno Haible  <bruno@clisp.org>
134682         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
134683         printed as "nan0x7fffffff" instead of "nan".
134684         * tests/test-vasprintf-posix.c (test_function): Likewise.
134685         * tests/test-snprintf-posix.h (test_function): Likewise.
134686         * tests/test-sprintf-posix.h (test_function): Likewise.
134687         * tests/test-fprintf-posix.h (NaN): Remove macro.
134688         (test_function): Remove all NaN related tests.
134689         * tests/test-printf-posix.h (NaN): Remove macro.
134690         (test_function): Remove all NaN related tests.
134691         * tests/test-printf-posix.output: Remove all NaN related results.
134692         Needed for IRIX 6.5.
134694 2007-05-19  Bruno Haible  <bruno@clisp.org>
134696         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
134697         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
134699 2007-05-19  Bruno Haible  <bruno@clisp.org>
134701         * lib/float_.h: New file.
134702         * m4/float_h.m4: New file.
134703         * modules/float: New file.
134704         * modules/isnanl (Dependencies): Add float.
134705         * modules/isnanl-nolibm (Dependencies): Likewise.
134706         * modules/mathl (Dependencies): Likewise.
134707         * modules/printf-frexpl (Dependencies): Likewise.
134708         * modules/signbit (Dependencies): Likewise.
134709         * modules/vasnprintf (Dependencies): Likewise.
134710         * doc/headers/float.texi: Update.
134712 2007-05-19  Jim Meyering  <jim@meyering.net>
134714         * lib/utimens.c (gl_futimens): Rename from futimens,
134715         now that glibc-2.6 declares futimens.
134716         * lib/utimens.h: Likewise.
134718 2007-05-19  Bruno Haible  <bruno@clisp.org>
134720         Avoid test failures on mingw.
134721         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
134722         * tests/test-printf-posix.sh: Likewise.
134723         * tests/test-vfprintf-posix.sh: Likewise.
134724         * tests/test-vprintf-posix.sh: Likewise.
134726 2007-05-19  Bruno Haible  <bruno@clisp.org>
134728         Fix *printf result for NaN, Inf, -0.0 on mingw.
134729         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
134730         * lib/vasnprintf.c: Include math.h and isnan.h.
134731         (is_infinite_or_zero): New function.
134732         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
134733         values in the %f, %F, %e, %E, %g, %G directives.
134734         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
134735         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
134736         gl_PRINTF_INFINITE and test its result. Invoke
134737         gl_PREREQ_VASNPRINTF_INFINITE.
134738         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
134739         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
134740         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
134741         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
134742         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
134743         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
134744         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
134745         * doc/functions/fprintf.texi: Update.
134746         * doc/functions/printf.texi: Update.
134747         * doc/functions/snprintf.texi: Update.
134748         * doc/functions/sprintf.texi: Update.
134749         * doc/functions/vfprintf.texi: Update.
134750         * doc/functions/vprintf.texi: Update.
134751         * doc/functions/vsnprintf.texi: Update.
134752         * doc/functions/vsprintf.texi: Update.
134754 2007-05-19  Bruno Haible  <bruno@clisp.org>
134756         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
134757         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
134758         Instead of multiplying with 10^k, set extra_zeroes to k.
134759         (scale10_round_long_double): Remove function.
134761 2007-05-18  Bruno Haible  <bruno@clisp.org>
134763         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
134764         introduced on 2007-05-06.
134766 2007-05-18  Bruno Haible  <bruno@clisp.org>
134768         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
134769         %g directives.
134770         * tests/test-vasprintf-posix.c (test_function): Likewise.
134771         * tests/test-snprintf-posix.h (test_function): Likewise.
134772         * tests/test-sprintf-posix.h (test_function): Likewise.
134774 2007-05-18  Bruno Haible  <bruno@clisp.org>
134776         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
134777         (strmatch): New function.
134778         (test_function): Test the %f directive on numbers of various exponents.
134779         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
134780         (strmatch): New function.
134781         (test_function): Test the %f directive on numbers of various exponents.
134782         * tests/test-snprintf-posix.h (strmatch): New function.
134783         (test_function): Test the %f directive on numbers of various exponents.
134784         * tests/test-sprintf-posix.h (strmatch): New function.
134785         (test_function): Test the %f directive on numbers of various exponents.
134786         * tests/test-snprintf-posix.c (SIZEOF): New macro.
134787         * tests/test-sprintf-posix.c (SIZEOF): New macro.
134788         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
134789         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
134791 2007-05-18  Bruno Haible  <bruno@clisp.org>
134793         Add support for 'long double' number output.
134794         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
134795         * lib/vasnprintf.c: Include math.h and float+.h.
134796         (mp_limb_t): New type.
134797         (GMP_LIMB_BITS): New macro.
134798         (mp_twolimb_t): New type.
134799         (GMP_TWOLIMB_BITS): New macro.
134800         (mpn_t): New type.
134801         (multiply, divide, convert_to_decimal, decode_long_double,
134802         scale10_round_long_double, scale10_round_decimal_long_double,
134803         floorlog10l): New functions.
134804         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
134805         for the %f, %F, %e, %E, %g, %G directives.
134806         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
134807         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
134808         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
134809         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
134810         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
134811         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
134812         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
134813         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
134814         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
134815         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
134816         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
134817         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
134818         * modules/snprintf-posix (Depends-on): Likewise.
134819         * modules/sprintf-posix (Depends-on): Likewise.
134820         * modules/vasnprintf-posix (Depends-on): Likewise.
134821         * modules/vasprintf-posix (Depends-on): Likewise.
134822         * modules/vfprintf-posix (Depends-on): Likewise.
134823         * modules/vsnprintf-posix (Depends-on): Likewise.
134824         * modules/vsprintf-posix (Depends-on): Likewise.
134825         * modules/vasnprintf (Files): Add lib/float+.h.
134826         * doc/functions/fprintf.texi: Update.
134827         * doc/functions/printf.texi: Update.
134828         * doc/functions/snprintf.texi: Update.
134829         * doc/functions/sprintf.texi: Update.
134830         * doc/functions/vfprintf.texi: Update.
134831         * doc/functions/vprintf.texi: Update.
134832         * doc/functions/vsnprintf.texi: Update.
134833         * doc/functions/vsprintf.texi: Update.
134835 2007-05-18  Bruno Haible  <bruno@clisp.org>
134837         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
134839 2007-05-18  Bruno Haible  <bruno@clisp.org>
134841         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
134842         for printing 64-bit integers. Needed for mingw.
134844 2007-05-18  Bruno Haible  <bruno@clisp.org>
134846         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
134847         gl_FUNC_FREXPL_WORKS.
134848         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
134850 2007-05-18  Bruno Haible  <bruno@clisp.org>
134852         * modules/frexpl-nolibm-tests: New file.
134854         * modules/frexpl-nolibm: New file.
134855         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
134857 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
134859         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
134860         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
134861         GCC 4.2, which otherwise issues a lot of warnings.
134862         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
134863         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
134864         Likewise.
134865         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
134866         * modules/iconv_open (iconv.h): Likewise.
134867         * modules/locale (locale.h): Likewise.
134868         * modules/netinet_in (netinet/in.h): Likewise.
134869         * modules/sys_select (sys_select.h): Likewise.
134870         * modules/sys_socket (sys/socket.h): Likewise.
134871         * modules/sys_stat (sys/stat.h): Likewise.
134872         * modules/sysexits (sysexits.h): Likewise.
134873         * modules/unistd (unistd.h): Likewise.
134875 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
134877         * modules/closein-tests (Makefile.am): Distribute
134878         `test-closein.sh'.
134880 2007-05-17  Bruno Haible  <bruno@clisp.org>
134882         * tests/test-printf-posix.output: Renamed from
134883         tests/test-fprintf-posix.out.
134884         * modules/fprintf-posix-tests: Update.
134885         * modules/printf-posix-tests: Update.
134886         * modules/vfprintf-posix-tests: Update.
134887         * modules/vprintf-posix-tests: Update.
134888         * tests/test-fprintf-posix.sh: Update.
134889         * tests/test-printf-posix.sh: Update.
134890         * tests/test-vfprintf-posix.sh: Update.
134891         * tests/test-vprintf-posix.sh: Update.
134892         Reported by Ralf Wildenhues.
134894 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
134896         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
134897         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
134898         GCC 4.2, which otherwise issues a lot of warnings.
134899         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
134900         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
134901         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
134902         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
134903         it should no longer be needed.
134904         * lib/string_.h: Likewise.
134905         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
134906         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
134907         * modules/inttypes (inttypes.h): Likewise.
134908         * modules/math (math.h): Likewise.
134909         * modules/search (search.h): Likewise.
134910         * modules/signal (signal.h): Likewise.
134911         * modules/stdint (stdint.h): Likewise.
134912         * modules/stdio (stdio.h): Likewise.
134913         * modules/stdlib (stdlib.h): Likewise.
134914         * modules/string (string.h): Likewise.
134915         * modules/sys_time (sys/time.h): Likewise.
134916         * modules/time (time.h): Likewise.
134917         * modules/wchar (wchar.h): Likewise.
134918         * modules/wctype (wtype.h): Likewise.
134920 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
134922         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
134924 2007-05-13  Bruno Haible  <bruno@clisp.org>
134926         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
134927         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
134928         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
134929         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
134930         (gl_PREREQ_STRTOK_R): Don't require it here.
134932 2007-05-13  Bruno Haible  <bruno@clisp.org>
134934         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
134935         when used in C++ mode.
134937 2007-05-12  Bruno Haible  <bruno@clisp.org>
134939         * lib/linebuffer.h: Tweak doc.
134940         * lib/linebuffer.c: Likewise.
134942 2007-05-12  James Youngman  <jay@gnu.org>
134944         * lib/linebuffer.c (readlinebuffer_delim): New function,
134945         like readlinebuffer, but use a caller-specified delimiter.
134946         (readlinebuffer): Just call readlinebuffer_delim with '\n'
134947         as the delimiter.
134948         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
134950 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
134952         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
134953         * modules/openat (Files): Remove openat-die.c.
134954         (Depends-on): Add openat-die.
134955         * modules/openat-die: New module.
134957 2007-05-06  Bruno Haible  <bruno@clisp.org>
134959         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
134960         Update with info about Cygwin.
134961         * doc/functions/fprintf.texi: Update.
134962         * doc/functions/printf.texi: Update.
134963         * doc/functions/snprintf.texi: Update.
134964         * doc/functions/sprintf.texi: Update.
134965         * doc/functions/vfprintf.texi: Update.
134966         * doc/functions/vprintf.texi: Update.
134967         * doc/functions/vsnprintf.texi: Update.
134968         * doc/functions/vsprintf.texi: Update.
134969         Reported by Eric Blake.
134971 2007-05-06  Bruno Haible  <bruno@clisp.org>
134973         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
134974         padding ourselves for the floating-point directives.
134975         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
134976         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
134977         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
134978         gl_PRINTF_FLAG_ZERO and test its result. Invoke
134979         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
134980         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
134981         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
134982         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
134983         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
134984         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
134985         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
134986         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
134987         * tests/test-snprintf-posix.h (test_function): Also check the width
134988         and some flags in the %f directive.
134989         * tests/test-sprintf-posix.h (test_function): Likewise.
134990         * tests/test-vasnprintf-posix.c (test_function): Likewise.
134991         * tests/test-vasprintf-posix.c (test_function): Likewise.
134992         * doc/functions/fprintf.texi: Update.
134993         * doc/functions/printf.texi: Update.
134994         * doc/functions/snprintf.texi: Update.
134995         * doc/functions/sprintf.texi: Update.
134996         * doc/functions/vfprintf.texi: Update.
134997         * doc/functions/vprintf.texi: Update.
134998         * doc/functions/vsnprintf.texi: Update.
134999         * doc/functions/vsprintf.texi: Update.
135001 2007-05-06  Bruno Haible  <bruno@clisp.org>
135003         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
135004         pass the ' flag character to sprintf or snprintf.
135005         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
135006         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
135007         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
135008         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
135009         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
135010         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
135011         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
135012         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
135013         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
135014         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
135015         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
135016         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
135017         * tests/test-snprintf-posix.h (test_function): Also check the grouping
135018         flag.
135019         * tests/test-sprintf-posix.h (test_function): Likewise.
135020         * tests/test-vasnprintf-posix.c (test_function): Likewise.
135021         * tests/test-vasprintf-posix.c (test_function): Likewise.
135022         * doc/functions/fprintf.texi: Update.
135023         * doc/functions/printf.texi: Update.
135024         * doc/functions/snprintf.texi: Update.
135025         * doc/functions/sprintf.texi: Update.
135026         * doc/functions/vfprintf.texi: Update.
135027         * doc/functions/vprintf.texi: Update.
135028         * doc/functions/vsnprintf.texi: Update.
135029         * doc/functions/vsprintf.texi: Update.
135031 2007-05-01  Bruno Haible  <bruno@clisp.org>
135033         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
135035 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
135037         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
135038         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
135040 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
135042         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
135043         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
135044         <http://lists.gnu.org/r/bug-gnulib/2007-05/msg00021.html>.
135046 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
135048         * lib/argp-help.c (struct hol_entry): New member `ord'.
135049         (HOL_ENTRY_PTRCMP): Use ord for comparison
135050         (hol_sort): Initialize ord.
135052 2007-05-01  Bruno Haible  <bruno@clisp.org>
135054         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
135055         Reported by Eric Blake.
135056         * doc/gnulib.texi (Function Substitutes): Update.
135058 2007-05-01  Bruno Haible  <bruno@clisp.org>
135060         * doc/functions.texi: Remove file, now redundant through
135061         doc/functions/*.texi.
135063 2007-05-01  Bruno Haible  <bruno@clisp.org>
135065         * modules/argp (Depends-on): Add sleep.
135067 2007-05-01  Bruno Haible  <bruno@clisp.org>
135069         * modules/sleep-tests: New file.
135070         * tests/test-sleep.c: New file.
135072         * modules/sleep: New file.
135073         * lib/sleep.c: New file.
135074         * m4/sleep.m4: New file.
135075         * lib/unistd_.h (sleep): New declaration.
135076         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
135077         HAVE_SLEEP.
135078         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
135079         * doc/functions/sleep.texi: Document the sleep module.
135081 2007-05-01  Bruno Haible  <bruno@clisp.org>
135083         * lib/sigprocmask.h: Remove file.
135084         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
135085         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
135086         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
135087         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
135088         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
135089         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
135090         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
135091         HAVE_SIGSET_T as a shell variable.
135092         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
135093         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
135094         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
135095         (Depends-on): Add signal. Remove verify.
135096         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
135097         (Include): Mention <signal.h> instead of sigprocmask.h.
135098         * NEWS: Mention the change.
135099         * lib/fatal-signal.c: Don't include sigprocmask.h.
135101 2007-05-01  Bruno Haible  <bruno@clisp.org>
135103         * modules/signal: New file.
135104         * lib/signal_.h: New file.
135105         * m4/signal_h.m4: New file.
135107 2007-05-01  Bruno Haible  <bruno@clisp.org>
135109         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
135110         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
135111         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
135112         HAVE_WCTYPE_CTMP_BUG into wctype.h.
135114 2007-05-01  Bruno Haible  <bruno@clisp.org>
135116         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
135117         configure time.
135118         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
135119         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
135120         * modules/sys_stat (Makefile.am): Substitute their values into
135121         sys/stat.h.
135123 2007-05-01  Bruno Haible  <bruno@clisp.org>
135125         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
135126         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
135127         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
135129 2007-05-01  Bruno Haible  <bruno@clisp.org>
135131         * doc/header/assert.texi: Undo last change: don't mention the gnulib
135132         'assert' module here.
135134 2007-05-01  Bruno Haible  <bruno@clisp.org>
135136         * doc/functions/*.texi: New files.
135137         * doc/functions/google-ranking.txt: New file.
135138         * doc/gnulib.texi (Function Substitutes): New chapter.
135139         (ctime, inet_ntoa): Remove sections.
135140         * doc/ctime.texi: Remove file.
135141         * doc/inet_ntoa.texi: Remove file.
135142         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
135143         dependencies.
135144         (%.info): New rule, specifying a --reference-limit.
135146 2007-05-01  Bruno Haible  <bruno@clisp.org>
135148         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
135150 2007-05-01  Bruno Haible  <bruno@clisp.org>
135152         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
135153         the portability of 'mkdir' to mingw systems.
135155 2007-05-01  Bruno Haible  <bruno@clisp.org>
135157         * doc/headers/google-ranking.txt: New file.
135159 2007-04-30  Eric Blake  <ebb9@byu.net>
135161         Prefer fseeko to fseek.
135162         * modules/getpass (Depends-on): Add fseeko.
135163         * lib/getpass.c (getpass): Use fseeko, not fseek.
135165 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
135167         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
135168         assumes the sorting is stable, while most qsort implementations
135169         are not.  Use argument addresses to ensure they never compare as
135170         equal.
135172         * tests/test-argp-2.sh (usage-indent test): Fix output
135173         (func_compare): Restore diff options
135174         * tests/test-argp.c: Restore #include "progname.h"
135176 2007-04-29  Bruno Haible  <bruno@clisp.org>
135178         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
135179         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
135180         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
135181         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
135182         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
135183         (configure.ac): Define CHECK_SNPRINTF_POSIX.
135184         (TESTS, check_PROGRAMS): Add test-snprintf.
135185         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
135186         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
135187         (TESTS, check_PROGRAMS): Add test-vsnprintf.
135188         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
135189         assertions that fail on HP-UX, OSF/1, or IRIX.
135190         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
135192 2007-04-29  Bruno Haible  <bruno@clisp.org>
135194         * MODULES.html.sh (posix_functions): Remove 'contents'.
135196 2007-04-29  Karl Berry  <karl@gnu.org>
135198         * config/srclist.txt (gendocs_template_min): new entry.
135200 2007-04-29  Bruno Haible  <bruno@clisp.org>
135202         Work around fpurge bug on BSD systems.
135203         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
135204         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
135205         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
135206         fpurge to rpl_fpurge if the system already has this function.
135207         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
135208         the case where the system already has this function. Correct invariants
135209         on BSD systems.
135210         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
135211         BSD systems.
135213 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
135215         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
135216         proposed by Sven Verdoolaege.
135218         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
135219         options.
135220         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
135221         (usage and help tests): Update
135223 2007-04-29  Bruno Haible  <bruno@clisp.org>
135225         * tests/test-fflush.c (main): Use a file of size 17, not 10.
135226         Print more information in case of failure. Disable a test on BeOS.
135228 2007-04-29  Bruno Haible  <bruno@clisp.org>
135230         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
135231         This helps debugging on systems on which no gdb is available.
135233 2007-04-29  Bruno Haible  <bruno@clisp.org>
135235         * lib/freading.h: Improve comments.
135236         * lib/fwriting.h: Likewise.
135237         * tests/test-freading.c (main): Don't check freading immediately after
135238         repositioning. Needed for glibc.
135240 2007-04-29  Bruno Haible  <bruno@clisp.org>
135242         * lib/freading.c (freading): Trivial simplification.
135244 2007-04-28  Bruno Haible  <bruno@clisp.org>
135246         * tests/test-fwriting.c (main): Also test the interaction between
135247         fflush and fwriting.
135248         * modules/fwriting-tests (Depends-on): Add fflush.
135250         * tests/test-freading.c (main): Also test the interaction between
135251         fflush and freading.
135252         * modules/freading-tests (Depends-on): Add fflush.
135254 2007-04-28  Bruno Haible  <bruno@clisp.org>
135256         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
135257         fseeko and ftello.
135258         Suggested by Eric Blake.
135260 2007-04-28  Jim Meyering  <jim@meyering.net>
135262         Avoid false-negative in gl_STDINT_H's C99 conformance test.
135263         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
135264         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
135266 2007-04-27  Eric Blake  <ebb9@byu.net>
135268         * doc/headers/assert.texi (assert.h): Document assert module use.
135270 2007-04-27  Bruno Haible  <bruno@clisp.org>
135272         * doc/headers/*.texi: New files.
135273         * doc/gnulib.texi (Header File Substitutes): New chapter.
135274         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
135275         dependencies.
135276         (standards.info ,standards.html, standards.dvi): Update dependencies.
135277         (mostlyclean, clean): New targets.
135279 2007-04-27  Bruno Haible  <bruno@clisp.org>
135281         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
135282         * modules/sysexits (Files, Makefile.am): Update.
135284         * lib/sys_socket_.h: Renamed from lib/socket_.h.
135285         * modules/sys_socket (Files, Makefile.am): Update.
135287         * lib/sys_stat_.h: Renamed from lib/stat_.h.
135288         * modules/sys_stat (Files, Makefile.am): Update.
135290 2007-04-27  Eric Blake  <ebb9@byu.net>
135292         * lib/freading.h: Improve comments.
135293         * lib/fwriting.h: Likewise.
135294         * lib/fflush.c: Likewise.
135296         Fix closein for mingw.
135297         * modules/closein-tests: Add tests for closein.
135298         * tests/test-closein.c: New file.
135299         * tests/test-closein.sh: Likewise.
135300         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
135301         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
135303 2007-04-27  Bruno Haible  <bruno@clisp.org>
135305         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
135306         version is < 6.
135307         * lib/math_.h [__DECC]: Likewise.
135308         * lib/stdio_.h [__DECC]: Likewise.
135309         * lib/stdlib_.h [__DECC]: Likewise.
135310         * lib/string_.h [__DECC]: Likewise.
135311         * lib/time_.h [__DECC]: Likewise.
135312         * lib/wchar_.h [__DECC]: Likewise.
135313         * lib/wctype_.h [__DECC]: Likewise.
135315 2007-04-27  Bruno Haible  <bruno@clisp.org>
135317         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
135319 2007-04-27  Bruno Haible  <bruno@clisp.org>
135321         * lib/fflush.c: Add comments.
135322         * modules/fpurge-tests (Depends-on): Add fflush.
135323         * modules/freadable-tests (Depends-on): Likewise.
135324         * modules/fwritable-tests (Depends-on): Likewise.
135326 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
135328         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
135329         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
135330         Report by Bruno Haible <bruno@clisp.org>.
135332 2007-04-26  Eric Blake  <ebb9@byu.net>
135334         Fix fflush on mingw.
135335         * modules/fflush (Depends-on): Add freading.
135336         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
135337         but unread data.
135339 2007-04-26  Eric Blake  <ebb9@byu.net>
135340         and Bruno Haible  <bruno@clisp.org>
135342         Implement freading and fwriting.
135343         * lib/freading.c: New file.
135344         * lib/freading.h: Likewise.
135345         * m4/freading.m4: Likewise.
135346         * modules/freading: Likewise.
135347         * modules/freading-tests: Likewise.
135348         * tests/test-freading.c: Likewise.
135349         * lib/fwriting.c: New file.
135350         * lib/fwriting.h: Likewise.
135351         * m4/fwriting.m4: Likewise.
135352         * modules/fwriting: Likewise.
135353         * modules/fwriting-tests: Likewise.
135354         * tests/test-fwriting.c: Likewise.
135355         * MODULES.html.sh (File stream based Input/Output): Mention them.
135357 2007-04-26  Bruno Haible  <bruno@clisp.org>
135359         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
135360         'long' when we assume it.
135361         Suggested by Eric Blake.
135363 2007-04-26  Bruno Haible  <bruno@clisp.org>
135365         Ensure fseeko, ftello are declared on glibc systems.
135366         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
135367         * modules/fseeko (configure.ac-early): Likewise.
135368         * modules/ftello (configure.ac-early): Likewise.
135369         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
135370         AC_FUNC_FSEEKO for this.
135371         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
135372         (gl_CHECK_FSEEKO): Remove macro.
135374 2007-04-26  Bruno Haible  <bruno@clisp.org>
135376         * tests/test-fflush.c (main): Also check the ftell result after
135377         fflush and fseek/fseeko.
135378         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
135379         file descriptor position cache in the stream.
135380         * lib/fseeko.c (rpl_fseeko): Likewise.
135382 2007-04-26  Bruno Haible  <bruno@clisp.org>
135384         * modules/fflush-tests (Depends-on): Add fseeko.
135386 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
135387             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
135389         * lib/argz_.h: ensure error_t definition is obtained in same
135390         mechanism system argz.h would have.
135391         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
135392         argz facilities are known bad.  Err on the side of caution if
135393         cross-compiling.
135395 2007-04-25  Eric Blake  <ebb9@byu.net>
135397         * lib/fpurge.c (includes): Use stdlib.h for free.
135398         * tests/test-fflush.c (main): Also test fflush-fseeko.
135400 2007-04-25  Bruno Haible  <bruno@clisp.org>
135402         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
135403         * lib/fseeko.c: New file.
135404         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
135405         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
135406         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
135407         gl_FUNC_FSEEKO.
135408         (gl_FUNC_FSEEKO): Invoke it.
135409         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
135410         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
135411         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
135413 2007-04-25  Bruno Haible  <bruno@clisp.org>
135415         * modules/fflush (Depends-on): Add ftello.
135417 2007-04-25  Bruno Haible  <bruno@clisp.org>
135419         * modules/ftello-tests: New file.
135420         * tests/test-ftello.c: New file.
135422         * modules/ftello: New file.
135423         * m4/ftello.m4: New file.
135424         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
135425         HAVE_FTELLO.
135426         * lib/stdio_.h (ftello): New declaration.
135427         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
135428         HAVE_FTELLO.
135430 2007-04-25  Bruno Haible  <bruno@clisp.org>
135432         * modules/fseeko-tests: New file.
135433         * tests/test-fseeko.c: New file.
135435         * modules/fseeko: New file.
135436         * m4/fseeko.m4: New file.
135437         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
135438         HAVE_FSEEKO.
135439         * lib/stdio_.h (fseeko): New declaration.
135440         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
135441         HAVE_FSEEKO.
135443 2007-04-25  Bruno Haible  <bruno@clisp.org>
135445         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
135447 2007-04-25  Bruno Haible  <bruno@clisp.org>
135449         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
135450         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
135451         * tests/test-unistd.c: Likewise.
135452         * tests/test-fcntl.c: Likewise.
135454 2007-04-23  Eric Blake  <ebb9@byu.net>
135456         * lib/fflush.c: Fix missing include.
135457         Reported by Bruno Haible.
135459 2007-04-23  Bruno Haible  <bruno@clisp.org>
135461         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
135462         Reported by Eric Blake.
135464 2007-04-23  Bruno Haible  <bruno@clisp.org>
135466         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
135468 2007-04-23  Bruno Haible  <bruno@clisp.org>
135470         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
135472 2007-04-23  Bruno Haible  <bruno@clisp.org>
135474         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
135475         Needed on HP-UX 11.
135477 2007-04-16  Eric Blake  <ebb9@byu.net>
135479         Make fflush rely on fpurge.
135480         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
135481         open coding all variants.
135482         * modules/fflush (Depends-on): Add fpurge and unistd.
135483         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
135484         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
135486         Fix --with-tests compilation on cygwin.
135487         * modules/argmatch-tests (Makefile.am): List gnulib library first
135488         in LDADD.
135489         * modules/argp-tests (Makefile.am): Likewise.
135490         * modules/array-list-tests (Makefile.am): Likewise.
135491         * modules/array-oset-tests (Makefile.am): Likewise.
135492         * modules/avltree-list-tests (Makefile.am): Likewise.
135493         * modules/avltree-oset-tests (Makefile.am): Likewise.
135494         * modules/avltreehash-list-tests (Makefile.am): Likewise.
135495         * modules/carray-list-tests (Makefile.am): Likewise.
135496         * modules/dirname-tests (Makefile.am): Likewise.
135497         * modules/frexp-tests (Makefile.am): Likewise.
135498         * modules/isnanl-tests (Makefile.am): Likewise.
135499         * modules/linked-list-tests (Makefile.am): Likewise.
135500         * modules/linkedhash-list-tests (Makefile.am): Likewise.
135501         * modules/lock-tests (Makefile.am): Likewise.
135502         * modules/rbtree-list-tests (Makefile.am): Likewise.
135503         * modules/rbtree-oset-tests (Makefile.am): Likewise.
135504         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
135505         * modules/tls-tests (Makefile.am): Likewise.
135506         * modules/tsearch-tests (Makefile.am): Likewise.
135507         * modules/xvasprintf-tests (Makefile.am): Likewise.
135509         Fix fpurge for cygwin.
135510         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
135511         value.
135512         * modules/fpurge-tests (Depends-on): Clean up trash.
135514 2007-04-16  Simon Josefsson  <simon@josefsson.org>
135516         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
135518         * m4/autobuild.m4: Re-indent.
135520 2007-04-13  Bruno Haible  <bruno@clisp.org>
135522         * modules/fpurge-tests: New file.
135523         * tests/test-fpurge.c: New file.
135525         * modules/fpurge: New file.
135526         * lib/fpurge.h: New file.
135527         * lib/fpurge.c: New file.
135528         * m4/fpurge.m4: New file.
135530 2007-04-13  Bruno Haible  <bruno@clisp.org>
135532         * modules/fbufmode-tests: New file.
135533         * tests/test-fbufmode.c: New file.
135535         * modules/fbufmode: New file.
135536         * lib/fbufmode.h: New file.
135537         * lib/fbufmode.c: New file.
135538         * m4/fbufmode.m4: New file.
135540 2007-04-13  Bruno Haible  <bruno@clisp.org>
135542         * modules/fwritable-tests: New file.
135543         * tests/test-fwritable.c: New file.
135545         * modules/fwritable: New file.
135546         * lib/fwritable.h: New file.
135547         * lib/fwritable.c: New file.
135548         * m4/fwritable.m4: New file.
135550 2007-04-13  Bruno Haible  <bruno@clisp.org>
135552         * modules/freadable-tests: New file.
135553         * tests/test-freadable.c: New file.
135555         * modules/freadable: New file.
135556         * lib/freadable.h: New file.
135557         * lib/freadable.c: New file.
135558         * m4/freadable.m4: New file.
135560 2007-04-13  Bruno Haible  <bruno@clisp.org>
135562         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
135563         MOSTLYCLEANFILES.
135565 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
135567         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
135568         gzip bootstrap.conf to avoid dragging in i18n machinery.
135569         (gnulib_tool_option): Use it.
135571 2007-04-13  Bruno Haible  <bruno@clisp.org>
135573         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
135574         %F directives.
135575         * tests/test-vasprintf-posix.c (test_function): Likewise.
135576         * tests/test-snprintf-posix.h (test_function): Likewise.
135577         * tests/test-sprintf-posix.h (test_function): Likewise.
135578         * tests/test-fprintf-posix.h (test_function): Likewise.
135579         * tests/test-printf-posix.h (test_function): Likewise.
135580         * tests/test-fprintf-posix.out: Likewise.
135582 2007-04-13  Bruno Haible  <bruno@clisp.org>
135584         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
135585         * modules/tls-tests (configure.ac): Likewise.
135586         Reported by Arto C. Nirkko <anirkko@insel.ch>.
135588 2007-04-13  Bruno Haible  <bruno@clisp.org>
135590         * lib/tls.c (glthread_tls_get): Fix return type.
135591         Patch by Arto C. Nirkko <anirkko@insel.ch>.
135593 2007-04-12  Eric Blake  <ebb9@byu.net>
135595         * modules/gettime (Depends-on): Remove gettime.
135596         Reported by Dmitry V. Levin.
135598 2007-04-12  Bruno Haible  <bruno@clisp.org>
135600         * modules/fflush (Include): Mention <stdio.h>.
135601         * modules/strtoimax (Include): Mention <inttypes.h>.
135602         * modules/strtoumax (Include): Likewise.
135604 2007-04-12  Eric Blake  <ebb9@byu.net>
135606         * .cvsignore: New file.
135607         * .gitignore: Likewise.
135609 2007-04-12  Bruno Haible  <bruno@clisp.org>
135611         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
135612         not before, since $(LDADD) often contains libgnu.a.
135613         * modules/striconv-tests (test_striconv_LDADD): Likewise.
135614         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
135615         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
135616         Needed on Cygwin.
135618 2007-04-12  Eric Blake  <ebb9@byu.net>
135620         Work around glibc's failure to flush stdin on fclose.
135621         * lib/closein.c (close_stdin): Flush stdin before closing.
135623         Work around glibc's failure to reset seekable stdin on exit.
135624         * modules/closein: New module.
135625         * lib/closein.c: New file.
135626         * lib/closein.h: Likewise.
135627         * m4/closein.m4: Likewise.
135628         * MODULES.html.sh (File stream based Input/Output): Document it.
135630 2007-04-12  Simon Josefsson  <simon@josefsson.org>
135632         * gnulib-tool: Rename generated 'autobuild' script to
135633         'do-autobuild' in --create-megatestdir output.
135635         * doc/gnulib.texi (Build robot for gnulib): Fix.
135637 2007-04-12  Simon Josefsson  <simon@josefsson.org>
135639         * modules/sysexits (Depends-on): Add absolute-header.
135641 2007-04-12  Eric Blake  <ebb9@byu.net>
135643         No need to preserve errno on success.
135644         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
135645         Reported by Bruno Haible.
135647 2007-04-12  Simon Josefsson  <simon@josefsson.org>
135649         * MODULES.html.sh (Support for maintaining and releasing
135650         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
135652 2007-04-12  Simon Josefsson  <simon@josefsson.org>
135654         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
135656 2007-04-12  Simon Josefsson  <simon@josefsson.org>
135658         * modules/autobuild: New module.
135660         * m4/autobuild.m4: New file.
135662 2007-04-11  Bruno Haible  <bruno@clisp.org>
135664         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
135665         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
135666         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
135667         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
135668         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
135669         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135670         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135671         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
135672         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135673         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135674         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
135675         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135676         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135677         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
135678         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135679         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135680         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
135681         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135682         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135683         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
135684         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135685         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135686         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
135687         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135688         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135689         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
135690         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
135691         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
135692         Reported by Eric Blake.
135694 2007-04-11  Bruno Haible  <bruno@clisp.org>
135696         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
135698 2007-04-10  Bruno Haible  <bruno@clisp.org>
135700         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
135701         for NaN and Infinity. Needed on FreeBSD 6.1.
135702         * tests/test-vasnprintf-posix.c (test_function): Undo last change
135703         regarding results for "%010a" of Infinity and NaN.
135704         * tests/test-vasprintf-posix.c (test_function): Likewise.
135705         * tests/test-snprintf-posix.h (test_function): Likewise.
135706         * tests/test-sprintf-posix.h (test_function): Likewise.
135707         * tests/test-fprintf-posix.h (test_function): Likewise.
135708         * tests/test-printf-posix.h (test_function): Likewise.
135709         * tests/test-fprintf-posix.out: Likewise.
135711 2007-04-10  Bruno Haible  <bruno@clisp.org>
135713         * modules/locale-tests: New file.
135714         * tests/test-locale.c: New file.
135716         * modules/locale: New file.
135717         * lib/locale_.h: New file.
135718         * m4/locale_h.m4: New file.
135720 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
135721             Bruno Haible  <bruno@clisp.org>
135723         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
135724         be determined, test for availability of the copysignf, copysign,
135725         copysignl functions.
135726         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
135727         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
135728         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
135730 2007-04-09  Eric Blake  <ebb9@byu.net>
135732         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
135733         * modules/stdio (Makefile.am): Support fflush.
135734         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
135735         * modules/fflush: New file.
135736         * lib/fflush.c: Likewise.
135737         * m4/fflush.m4: Likewise.
135738         * modules/fflush-tests: New test.
135739         * tests/test-fflush.c: Likewise.
135740         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
135742 2007-04-06  Bruno Haible  <bruno@clisp.org>
135744         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
135745         (VASNPRINTF): Use signbit for faster determination whether to print a
135746         minus sign.
135747         * modules/vasnprintf (Files): Remove lib/float+.h.
135748         * modules/fprintf-posix (Depends-on): Add signbit.
135749         * modules/snprintf-posix (Depends-on): Likewise.
135750         * modules/sprintf-posix (Depends-on): Likewise.
135751         * modules/vasnprintf-posix (Depends-on): Likewise.
135752         * modules/vasprintf-posix (Depends-on): Likewise.
135753         * modules/vfprintf-posix (Depends-on): Likewise.
135754         * modules/vsnprintf-posix (Depends-on): Likewise.
135755         * modules/vsprintf-posix (Depends-on): Likewise.
135757 2007-04-06  Bruno Haible  <bruno@clisp.org>
135759         * tests/test-frexp.c (main): Test also the sign bit of zero results.
135760         * tests/test-frexpl.c (main): Likewise.
135761         * tests/test-ldexpl.c (main): Likewise.
135762         * modules/frexp-tests (Depends-on): Add signbit.
135763         * modules/frexpl-tests (Depdends-on): Likewise.
135764         * modules/ldexpl-tests (Depdends-on): Likewise.
135766 2007-04-06  Bruno Haible  <bruno@clisp.org>
135768         * modules/signbit-tests: New file.
135769         * tests/test-signbit.c: New file.
135771         * modules/signbit: New file.
135772         * lib/signbitf.c: New file.
135773         * lib/signbitd.c: New file.
135774         * lib/signbitl.c: New file.
135775         * m4/signbit.m4: New file.
135776         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
135777         (signbit): New macro.
135778         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
135779         REPLACE_SIGNBIT.
135780         * modules/math (Makefile.am): Substitute also GNULIB_SIGNBIT and
135781         REPLACE_FREXPL into math.h.
135783 2007-04-06  Bruno Haible  <bruno@clisp.org>
135785         * modules/isnanf-nolibm-tests: New file.
135786         * tests/test-isnanf.c: New file.
135788         * modules/isnanf-nolibm: New file.
135789         * lib/isnanf.h: New file.
135790         * lib/isnanf.c: New file.
135791         * lib/isnan.c: Consider the USE_FLOAT macro.
135792         * m4/isnanf.m4: New file.
135794 2007-04-06  Bruno Haible  <bruno@clisp.org>
135796         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
135797         (Link): New section.
135799         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
135801 2007-04-06  Bruno Haible  <bruno@clisp.org>
135803         Assume the 'long double' type.
135804         * m4/longdouble.m4: Remove file.
135805         * config/srclist.txt: Don't mention longdouble.m4.
135806         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
135807         * lib/float+.h: Likewise.
135808         * lib/frexp.c: Likewise.
135809         * lib/printf-args.h: Likewise.
135810         * lib/printf-args.c: Likewise.
135811         * lib/printf-frexp.c: Likewise.
135812         * lib/printf-parse.c: Likewise.
135813         * lib/vasnprintf.c: Likewise.
135814         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
135815         * m4/intl.m4: Likewise.
135816         * m4/isnanl.m4: Likewise.
135817         * m4/printf.m4: Likewise.
135818         * m4/printf-frexpl.m4: Likewise.
135819         * m4/vasnprintf.m4: Likewise.
135820         * modules/allocsa (Files): Remove m4/longdouble.m4.
135821         * modules/gettext (Files): Likewise.
135822         * modules/relocatable-prog-wrapper (Files): Likewise.
135823         * modules/vasnprintf (Files): Likewise.
135824         * modules/isnanl (Files): Likewise.
135825         (Include): Simplify.
135826         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
135827         (Include): Simplify.
135828         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
135829         (Include): Simplify.
135830         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
135831         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
135832         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
135833         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
135834         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
135835         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
135836         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
135837         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
135838         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
135839         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
135840         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
135841         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
135842         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
135843         * tests/test-isnanl.c: Likewise.
135844         * tests/test-snprintf-posix.h: Likewise.
135845         * tests/test-sprintf-posix.h: Likewise.
135846         * tests/test-vasnprintf-posix.c: Likewise.
135847         * tests/test-vasnprintf-posix2.c: Likewise.
135848         * tests/test-vasprintf-posix.c: Likewise.
135850 2007-04-06  Bruno Haible  <bruno@clisp.org>
135852         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
135853         * lib/math_.h [__DECC]: Include the overridden include file through
135854         #include_next, outside the double-inclusion guard.
135855         * lib/stdio_.h [__DECC]: Likewise.
135856         * lib/stdlib_.h [__DECC]: Likewise.
135857         * lib/string_.h [__DECC]: Likewise.
135858         * lib/time_.h [__DECC]: Likewise.
135859         * lib/wchar_.h [__DECC]: Likewise.
135860         * lib/wctype_.h [__DECC]: Likewise.
135861         * lib/inttypes_.h [__DECC]: Likewise.
135862         Reported by Albert Chin <china@thewrittenword.com> in
135863         <http://lists.gnu.org/r/bug-gnulib/2007-04/msg00088.html>.
135865 2007-04-04  Eric Blake  <ebb9@byu.net>
135867         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
135868         1.5.x.
135870 2007-04-04  Bruno Haible  <bruno@clisp.org>
135872         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
135873         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
135875 2007-04-04  Bruno Haible  <bruno@clisp.org>
135877         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
135878         results for "%010a" of Infinity and NaN.
135879         * tests/test-vasprintf-posix.c (test_function): Likewise.
135880         * tests/test-snprintf-posix.h (test_function): Likewise.
135881         * tests/test-sprintf-posix.h (test_function): Likewise.
135882         * tests/test-fprintf-posix.h (test_function): Remove these tests.
135883         * tests/test-printf-posix.h (test_function): Likewise.
135884         * tests/test-fprintf-posix.out: Update.
135885         Needed for FreeBSD 6.1.
135887 2007-04-04  Bruno Haible  <bruno@clisp.org>
135889         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
135890         directly used by the gnulib modules nor by gnulib-tool.
135892 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
135894         * DEPENDENCIES: Give overall description of version dependency
135895         desirability.  Use more-typical names for apps.
135896         Add shell, coreutils, diffutils, grep, tar, gzip.
135898 2007-04-04  Simon Josefsson  <simon@josefsson.org>
135900         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
135902 2007-04-04  Karl Berry  <karl@gnu.org>
135904         * MODULES.html.sh (func_module): missing '.
135906 2007-04-03  Bruno Haible  <bruno@clisp.org>
135908         * modules/argmatch-tests (Makefile.am): New variable
135909         test_argmatch_LDADD.
135910         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
135911         * modules/array-list-tests (Makefile.am): New variable
135912         test_array_list_LDADD.
135913         * modules/array-oset-tests (Makefile.am): New variable
135914         test_array_oset_LDADD.
135915         * modules/avltree-list-tests (Makefile.am): New variable
135916         test_avltree_list_LDADD.
135917         * modules/avltree-oset-tests (Makefile.am): New variable
135918         test_avltree_oset_LDADD.
135919         * modules/avltreehash-list-tests (Makefile.am): New variable
135920         test_avltreehash_list_LDADD.
135921         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
135922         test_canonicalize_lgpl_LDADD.
135923         * modules/carray-list-tests (Makefile.am): New variable
135924         test_carray_list_LDADD.
135925         * modules/dirname-tests (Makefile.am): New variable
135926         test_dirname_LDADD.
135927         * modules/linked-list-tests (Makefile.am): New variable
135928         test_linked_list_LDADD.
135929         * modules/linkedhash-list-tests (Makefile.am): New variable
135930         test_linkedhash_list_LDADD.
135931         * modules/rbtree-list-tests (Makefile.am): New variable
135932         test_rbtree_list_LDADD.
135933         * modules/rbtree-oset-tests (Makefile.am): New variable
135934         test_rbtree_oset_LDADD.
135935         * modules/rbtreehash-list-tests (Makefile.am): New variable
135936         test_rbtreehash_list_LDADD.
135937         * modules/xvasprintf-tests (Makefile.am): New variable
135938         test_xvasprintf_LDADD.
135939         Reported by Eric Blake.
135941 2007-04-03  Eric Blake  <ebb9@byu.net>
135943         * DEPENDENCIES: Weaken m4 requirements.
135945 2007-04-03  Bruno Haible  <bruno@clisp.org>
135947         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
135948         * modules/isnanl-tests (configure.ac): Likewise.
135950 2007-04-03  Ben Pfaff  <blp@gnu.org>
135952         * modules/iconv_open: Add $(srcdir)/ to source directory
135953         references in Makefile fragments that call gperf, to fix VPATH
135954         builds.
135956 2007-04-03  Bruno Haible  <bruno@clisp.org>
135958         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
135959         * lib/ldexpl.c: Undo last change.
135961 2007-04-03  Bruno Haible  <bruno@clisp.org>
135963         * modules/printf-frexpl (Depends-on): Undo last change.
135964         (Files): Add m4/ldexpl.m4.
135966 2007-04-03  Bruno Haible  <bruno@clisp.org>
135968         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
135969         * modules/isnanl (Link): New section.
135971         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
135972         * modules/frexp (Link): New section.
135974         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
135975         * modules/frexpl (Link): New section.
135977         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
135978         * modules/ldexpl (Link): New section.
135980 2007-04-03  Bruno Haible  <bruno@clisp.org>
135982         * modules/TEMPLATE-EXTENDED: New file.
135983         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
135985 2007-04-03  Bruno Haible  <bruno@clisp.org>
135987         * DEPENDENCIES: New file.
135988         Suggested by Simon Josefsson.
135990 2007-04-03  Bruno Haible  <bruno@clisp.org>
135992         * doc/gnulib.texi: Escape @.
135994 2007-04-03  James Youngman  <jay@gnu.org>
135995         and Paul Eggert  <eggert@cs.ucla.edu>
135997         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
135998         birthtime on all systems that have birthtime, not just those which
135999         use st_birthtimensec rather than st_birthtim.  Putting zero in
136000         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
136001         that the birth time is not available for files on an NFS mount.
136003 2007-04-03  Simon Josefsson  <simon@josefsson.org>
136005         * modules/memxor: Move back from crypto/, suggested by Bruno.
136006         * modules/crypto/hmac-sha1: Fix memxor dependency.
136008         * modules/crypto/gc: Moved from ../.
136010 2007-04-02  Eric Blake  <ebb9@byu.net>
136012         * lib/ldexpl.c (includes): Avoid libm.
136014         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
136016 2007-04-02  Bruno Haible  <bruno@clisp.org>
136018         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
136019         on IRIX.
136021 2007-04-02  Bruno Haible  <bruno@clisp.org>
136023         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
136024         x86 or x86_64 platforms running MacOS X.
136025         Reported by Ryan Schmidt <@ryandesign.com>.
136027 2007-04-02  Bruno Haible  <bruno@clisp.org>
136029         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
136030         i386.
136032 2007-04-01  Simon Josefsson  <simon@josefsson.org>
136034         * modules/crypto/arcfour: Moved from ../.
136035         * modules/crypto/arcfour-tests: Moved from ../.
136036         * modules/crypto/arctwo: Moved from ../.
136037         * modules/crypto/arctwo-tests: Moved from ../.
136038         * modules/crypto/des: Moved from ../.
136039         * modules/crypto/des-tests: Moved from ../.
136040         * modules/crypto/gc-arcfour: Moved from ../.
136041         * modules/crypto/gc-arcfour-tests: Moved from ../.
136042         * modules/crypto/gc-arctwo: Moved from ../.
136043         * modules/crypto/gc-arctwo-tests: Moved from ../.
136044         * modules/crypto/gc-des: Moved from ../.
136045         * modules/crypto/gc-des-tests: Moved from ../.
136046         * modules/crypto/gc-hmac-md5: Moved from ../.
136047         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
136048         * modules/crypto/gc-hmac-sha1: Moved from ../.
136049         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
136050         * modules/crypto/gc-md2: Moved from ../.
136051         * modules/crypto/gc-md2-tests: Moved from ../.
136052         * modules/crypto/gc-md4: Moved from ../.
136053         * modules/crypto/gc-md4-tests: Moved from ../.
136054         * modules/crypto/gc-md5: Moved from ../.
136055         * modules/crypto/gc-md5-tests: Moved from ../.
136056         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
136057         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
136058         * modules/crypto/gc-random: Moved from ../.
136059         * modules/crypto/gc-rijndael: Moved from ../.
136060         * modules/crypto/gc-rijndael-tests: Moved from ../.
136061         * modules/crypto/gc-sha1: Moved from ../.
136062         * modules/crypto/gc-sha1-tests: Moved from ../.
136063         * modules/crypto/gc-tests: Moved from ../.
136064         * modules/crypto/hmac-md5: Moved from ../.
136065         * modules/crypto/hmac-md5-tests: Moved from ../.
136066         * modules/crypto/hmac-sha1: Moved from ../.
136067         * modules/crypto/hmac-sha1-tests: Moved from ../.
136068         * modules/crypto/md2: Moved from ../.
136069         * modules/crypto/md2-tests: Moved from ../.
136070         * modules/crypto/md4: Moved from ../.
136071         * modules/crypto/md4-tests: Moved from ../.
136072         * modules/crypto/md5: Moved from ../.
136073         * modules/crypto/md5-tests: Moved from ../.
136074         * modules/crypto/memxor: Moved from ../.
136075         * modules/crypto/rijndael: Moved from ../.
136076         * modules/crypto/rijndael-tests: Moved from ../.
136077         * modules/crypto/sha1: Moved from ../.
136079 2007-03-30  James Youngman  <jay@gnu.org>
136081         * tests/test-stat-time.c (prepare_test): use chmod() rather than
136082         rename() to change the ctime of a file (because ctime is unaffected
136083         by rename on jfs2 on AIX 5.1).
136084         (main): Start by doing cleanup, in case a previous run failed leaving
136085         test files behind.
136087 2007-03-31  Bruno Haible  <bruno@clisp.org>
136089         Support old proprietary implementations of iconv.
136090         * modules/iconv_open: New file.
136091         * lib/iconv_.h: New file.
136092         * m4/iconv_h.m4: New file.
136093         * lib/iconv_open.c: New file.
136094         * lib/iconv_open-aix.gperf: New file.
136095         * lib/iconv_open-hpux.gperf: New file.
136096         * lib/iconv_open-irix.gperf: New file.
136097         * lib/iconv_open-osf.gperf: New file.
136098         * m4/iconv_open.m4: New file.
136099         * modules/linebreak (Depends-on): Add iconv_open.
136100         * modules/striconv (Depends-on): Likewise.
136101         * modules/striconveh (Depends-on): Likewise.
136102         * modules/unicodeio (Depends-on): Likewise.
136103         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
136104         (iconv_t)(-1).
136105         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
136106         conversion if cd is (iconv_t)(-1).
136107         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
136108         is not possible.
136110 2007-03-31  Bruno Haible  <bruno@clisp.org>
136112         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
136113         work on Solaris either. Protect also second use of "autodetect_jp".
136115 2007-03-31  Bruno Haible  <bruno@clisp.org>
136117         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
136118         the function is not present.
136120 2007-03-31  Bruno Haible  <bruno@clisp.org>
136122         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
136123         the function is not present.
136125 2007-03-31  Bruno Haible  <bruno@clisp.org>
136127         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
136128         a bug in HP-UX iconv_open().
136130 2007-03-31  Bruno Haible  <bruno@clisp.org>
136132         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
136133         (Mathematics <math.h>): New section, add fpieee.
136134         (Input/output <stdio.h>): Add fseterr.
136135         (Mathematics <math.h>): New section, add printf-frexp.
136136         (Container data structures): Add sublist.
136137         (Core language properties): Add fpucw, inline.
136138         (Functions for greatest-width integer types <inttypes.h>): Add
136139         imaxabs, imaxdiv, inttypes.
136140         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
136141         isnanl-nolibm, ldexp.
136142         (Mathematics <math.h>): New section, add printf-frexpl.
136143         (Support for systems lacking POSIX:2001): Add fprintf-posix,
136144         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
136145         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
136146         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
136147         (Unicode string functions): Add unistr/u*-mbtoucr.
136148         (Java): Add javacomp-script, javaexec-script.
136149         (C#): Add csharpcomp-script, csharpexec-script.
136150         (Support for building libraries and executables): Add havelib,
136151         relocatable-*.
136152         (Support for maintaining and releasing projects): Renamed from
136153         'Support for maintaining and release projects'. Add announce-gen.
136155 2007-03-31  Bruno Haible  <bruno@clisp.org>
136157         * README: Talk primarily about git.
136158         (git and CVS): Renamed from CVS.
136159         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
136160         gnulib is available through git.
136161         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
136163 2007-03-30  Bruno Haible  <bruno@clisp.org>
136165         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
136166         * lib/poll_.h: Likewise.
136167         * lib/stat_.h: Likewise.
136168         * lib/sys_time_.h: Likewise.
136169         * lib/sysexit_.h: Likewise.
136170         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
136171         * lib/stdbool_.h: Likewise.
136172         * lib/byteswap_.h: Add double-inclusion guard.
136174 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
136176         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
136178 2007-03-30  Karl Berry  <karl@gnu.org>
136180         * config/srclist-update: double space after USA in the license
136181         substitution, since that's how it's usually (?) written.
136183 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
136185         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
136186         reported by Bruno Haible.
136188 2007-03-29  Bruno Haible  <bruno@clisp.org>
136190         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
136191         a bug in AIX iconv().
136193 2007-03-29  Bruno Haible  <bruno@clisp.org>
136195         * modules/ldexpl-tests: New file.
136196         * tests/test-ldexpl.c: New file.
136198 2007-03-29  Bruno Haible  <bruno@clisp.org>
136200         * lib/ldexpl.c: Include fpucw.h.
136201         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
136202         multiplication.
136203         * modules/ldexpl (Depends-on): Add fpucw.
136205 2007-03-29  Bruno Haible  <bruno@clisp.org>
136207         * modules/ldexpl: New file.
136208         * m4/ldexpl.m4: New file.
136209         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
136210         set.
136211         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
136212         REPLACE_LDEXPL.
136213         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
136214         REPLACE_LDEXPL.
136215         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
136216         gl_FUNC_LDEXPL_WORKS.
136217         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
136218         * modules/mathl (Files): Remove lib/ldexpl.c.
136219         (Depends-on): Add ldexpl.
136221 2007-03-29  Bruno Haible  <bruno@clisp.org>
136223         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
136225 2007-03-29  Bruno Haible  <bruno@clisp.org>
136227         * tests/test-striconveh.c (main): Don't assume that a direct conversion
136228         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
136229         and possibly also HP-UX.
136230         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
136231         work on AIX, IRIX, HP-UX, OSF/1.
136232         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
136233         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
136234         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
136235         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
136236         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
136237         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
136239 2007-03-29  Bruno Haible  <bruno@clisp.org>
136241         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
136243 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
136245         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
136246         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
136248 2007-03-29  Eric Blake  <ebb9@byu.net>
136250         * lib/acl-internal.h: Remove redundant include.
136251         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
136252         Cygwin when a file is locked.
136254 2007-03-29  Bruno Haible  <bruno@clisp.org>
136256         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
136257         file.
136258         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
136260 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
136262         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
136263         try to remove a parent directory if the child couldn't be removed
136264         (except for the first rmdir, which could fail because the child
136265         doesn't exist).  Problem reported by Jeff Blaine in
136266         <http://lists.gnu.org/r/bug-tar/2007-03/msg00014.html>.
136268 2007-03-28  Bruno Haible  <bruno@clisp.org>
136270         * lib/striconveh.c (utf8conv_carefully): New function.
136271         (mem_cd_iconveh_internal): Invoke it.
136273 2007-03-28  Bruno Haible  <bruno@clisp.org>
136275         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
136276         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
136277         input.
136278         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
136279         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
136280         unistr/u8-uctomb.
136282 2007-03-28  Bruno Haible  <bruno@clisp.org>
136284         * modules/unistr/u8-mbtoucr: New file.
136285         * lib/unistr/u8-mbtoucr.c: New file.
136286         * modules/unistr/u16-mbtoucr: New file.
136287         * lib/unistr/u16-mbtoucr.c: New file.
136288         * modules/unistr/u16-mbtoucr: New file.
136289         * lib/unistr/u16-mbtoucr.c: New file.
136290         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
136292 2007-03-27  Simon Josefsson  <simon@josefsson.org>
136293             Bruno Haible  <bruno@clisp.org>
136295         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
136296         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
136297         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
136299         * m4/stdio_h.m4: Add stubs for vasprintf too.
136301         * modules/stdio: Support vasprintf in sed command.
136303         * modules/vasprintf: Depend on stdio for prototypes.  Remove
136304         vasprintf.h.  Add stdio module indicator.
136306         * lib/stdio_.h: Declare asprintf and vasprintf, based on
136307         vasprintf.h.
136309         * lib/vasprintf.h: File removed.
136311         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
136312         * lib/vasprintf.c: Ditto.
136313         * lib/xvasprintf.c: Ditto.
136314         * tests/test-vasprintf-posix.c: Ditto.
136315         * tests/test-vasprintf.c: Ditto.
136317 2007-03-27  Bruno Haible  <bruno@clisp.org>
136319         Make vasnprintf multithread-safe.
136320         * lib/vasnprintf.c (decimal_point_char): New function.
136321         (VASNPRINTF): Use it.
136322         Suggested by Simon Josefsson.
136324 2007-03-27  Eric Blake  <ebb9@byu.net>
136326         Support sub-second birthtime on cygwin.
136327         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
136328         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
136329         (get_stat_birthtime): Also work with st_birthtim.
136331 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
136333         * lib/stat-time.h (USE_BIRTHTIME): Remove.
136334         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
136335         (get_stat_birthtime_ns): Do not try to use "spare" fields.
136336         (get_stat_birthtime_ns): Simplify compile-time tests.
136337         (get_stat_birthtime): Change the API to look like
136338         get_stat_mtime etc., except return a negative tv_nsec on error.
136339         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
136340         Don't check for "spare" fields.
136341         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
136342         or for struct stat.st_birthtime, as these tests aren't used.
136343         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
136345 2007-03-27  Bruno Haible  <bruno@clisp.org>
136347         * lib/stat-time.h: Include <sys/stat.h>.
136349 2007-03-27  James Youngman  <jay@gnu.org>
136351         * lib/stat-time.h (get_stat_birthtime): New function for
136352           retrieving st_birthtime as provided by UFS2 (hence *BSD).
136353         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
136354           and its variants.
136355         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
136356         * modules/stat-time-test: New file.
136357         * tests/test-stat-time.c: New test, devised by Bruno Haible.
136359 2007-03-26  Bruno Haible  <bruno@clisp.org>
136361         Better support of signalling NaNs.
136362         * lib/atanl.c: Include isnanl.h.
136363         (atanl): Perform test for NaN at the beginning of the function and
136364         through a call to isnanl.
136365         * lib/cosl.c: Include isnanl.h.
136366         (cosl): Perform test for NaN at the beginning of the function and
136367         through a call to isnanl.
136368         * lib/ldexpl.c: Include isnanl.h.
136369         (ldexpl): Perform test for NaN through a call to isnanl.
136370         * lib/logl.c: Include isnanl.h.
136371         (logl): Perform test for NaN at the beginning of the function and
136372         through a call to isnanl.
136373         * lib/sinl.c: Include isnanl.h.
136374         (sinl): Perform test for NaN at the beginning of the function and
136375         through a call to isnanl.
136376         * lib/sqrtl.c: Include isnanl.h.
136377         (sqrtl): Perform test for NaN at the beginning of the function and
136378         through a call to isnanl.
136379         * lib/tanl.c: Include isnanl.h.
136380         (tanl): Perform test for NaN at the beginning of the function and
136381         through a call to isnanl.
136382         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
136383         * modules/mathl (Depends-on): Add isnanl.
136385 2007-03-26  Eric Blake  <ebb9@byu.net>
136387         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
136388         regression in logic sense of previous patch.
136390 2007-03-26  Bruno Haible  <bruno@clisp.org>
136392         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
136393         unportable shell command "if ! ...".
136394         Reported by Ralf Wildenhues.
136396 2007-03-25  Bruno Haible  <bruno@clisp.org>
136398         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
136399         <sysexits.h> file, and only add EX_CONFIG.
136400         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
136401         absolute file name and whether it is sufficient. Substitute also
136402         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
136403         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
136404         ABSOLUTE_SYSEXITS_H into sysexits.h.
136406 2007-03-25  Bruno Haible  <bruno@clisp.org>
136408         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
136409         hints is NULL.
136411 2007-03-25  Bruno Haible  <bruno@clisp.org>
136413         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
136414         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
136416 2007-03-25  Bruno Haible  <bruno@clisp.org>
136418         * lib/vasnprintf.c: Include langinfo.h.
136419         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
136420         multithread-safe.
136421         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
136422         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
136423         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
136424         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
136425         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
136426         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
136427         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
136428         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
136429         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
136430         Reported by Simon Josefsson.
136432 2007-03-25  Bruno Haible  <bruno@clisp.org>
136434         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
136435         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
136436         * modules/vasnprintf (Depends-on): Add stdint.
136438 2007-03-25  Bruno Haible  <bruno@clisp.org>
136440         * modules/fpieee: New file.
136441         * m4/fpieee.m4: New file.
136442         * modules/isnan-nolibm (Depends-on): Add fpieee.
136443         * modules/isnanl-nolibm (Depends-on): Add fpieee.
136444         * modules/isnanl (Depends-on): Add fpieee.
136446 2007-03-25  Bruno Haible  <bruno@clisp.org>
136448         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
136450 2007-03-25  Bruno Haible  <bruno@clisp.org>
136452         Avoid test failures on IRIX 6.5.
136453         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
136454         (main): Use it.
136455         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
136456         macros.
136457         (main): Use them.
136459 2007-03-25  Bruno Haible  <bruno@clisp.org>
136461         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
136462         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
136463         exists but doesn't work.
136464         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
136465         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
136466         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
136467         * modules/math (Makefile.am): Substitute also REPLACE_FREXPL into
136468         math.h.
136470 2007-03-25  Bruno Haible  <bruno@clisp.org>
136472         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
136473         returns inf. Needed on IRIX 6.5.
136475 2007-03-25  Bruno Haible  <bruno@clisp.org>
136477         * tests/test-frexpl.c: Include isnanl-nolibm.h.
136478         (main): Use isnanl instead of x != x idiom.
136479         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
136481         * tests/test-frexp.c: Include isnan.h.
136482         (main): Use isnan instead of x != x idiom.
136483         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
136485 2007-03-25  Bruno Haible  <bruno@clisp.org>
136487         * tests/test-frexp.c (NaN): New function/macro.
136488         (main): Use it instead of 0.0 / 0.0.
136489         * tests/test-isnan.c (NaN): New function/macro.
136490         (main): Use it instead of 0.0 / 0.0.
136491         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
136492         (test_function): Use it instead of 0.0 / 0.0.
136493         * tests/test-vasprintf-posix.c (NaN): New function/macro.
136494         (test_function): Use it instead of 0.0 / 0.0.
136495         * tests/test-snprintf-posix.h (NaN): New function/macro.
136496         (test_function): Use it instead of 0.0 / 0.0.
136497         * tests/test-sprintf-posix.h (NaN): New function/macro.
136498         (test_function): Use it instead of 0.0 / 0.0.
136499         * tests/test-fprintf-posix.h (NaN): New function/macro.
136500         (test_function): Use it instead of 0.0 / 0.0.
136501         * tests/test-printf-posix.h (NaN): New function/macro.
136502         (test_function): Use it instead of 0.0 / 0.0.
136504         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
136506 2007-03-25  Bruno Haible  <bruno@clisp.org>
136508         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
136510 2007-03-25  Bruno Haible  <bruno@clisp.org>
136512         * lib/regexec.c (merge_state_with_log): Make static.
136514 2007-03-25  Bruno Haible  <bruno@clisp.org>
136516         * lib/trigl.c (kernel_rem_pio2): Make static.
136518 2007-03-25  Bruno Haible  <bruno@clisp.org>
136520         * lib/sincosl.c (sincosl_table): Make static.
136522 2007-03-25  Bruno Haible  <bruno@clisp.org>
136524         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
136525         if the compiler does not support C99.
136527 2007-03-25  Bruno Haible  <bruno@clisp.org>
136529         * modules/time (Makefile.am): Ensure all rule action lines start with a
136530         tab.
136532 2007-03-24  Bruno Haible  <bruno@clisp.org>
136534         * modules/tsearch-tests: New file.
136535         * tests/test-tsearch.sh: New file.
136536         * tests/test-tsearch.c: New file, mostly copied from glibc.
136538         * modules/search-tests: New file.
136539         * tests/test-search.c: New file.
136541         * modules/search: New file.
136542         * lib/search_.h: New file, incorporating lib/tsearch.h.
136543         * m4/search_h.m4: New file.
136544         * lib/tsearch.h: Remove file.
136545         * lib/tsearch.c: Include search.h instead of tsearch.h.
136546         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
136547         HAVE_TSEARCH.
136548         * modules/tsearch (Files): Remove lib/tsearch.h.
136549         (Depends-on): Add search.
136550         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
136551         (Include): Change tsearch.h into search.h.
136553 2007-03-24  Bruno Haible  <bruno@clisp.org>
136555         * modules/fpucw: New file.
136556         * lib/fpucw.h: New file.
136557         * lib/frexp.c: Include fpucw.h.
136558         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
136559         (FUNC): Use them.
136560         * lib/printf-frexp.c: Include fpucw.h.
136561         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
136562         (FUNC): Use them.
136563         * lib/vasnprintf.c: Include fpucw.h.
136564         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
136565         'long double' calculations.
136566         * tests/test-frexpl.c: Include fpucw.h.
136567         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
136568         * tests/test-printf-frexpl.c: Include fpucw.h.
136569         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
136570         * modules/frexpl (Depends-on): Add fpucw.
136571         * modules/printf-frexpl (Depends-on): Likewise.
136572         * modules/fprintf-posix (Depends-on): Likewise.
136573         * modules/snprintf-posix (Depends-on): Likewise.
136574         * modules/sprintf-posix (Depends-on): Likewise.
136575         * modules/vasnprintf-posix (Depends-on): Likewise.
136576         * modules/vasprintf-posix (Depends-on): Likewise.
136577         * modules/vfprintf-posix (Depends-on): Likewise.
136578         * modules/vsnprintf-posix (Depends-on): Likewise.
136579         * modules/vsprintf-posix (Depends-on): Likewise.
136580         * modules/frexpl-tests (Depends-on): Likewise.
136581         * modules/printf-frexpl-tests (Depends-on): Likewise.
136583 2007-03-24  Bruno Haible  <bruno@clisp.org>
136585         * lib/float+.h: New file.
136586         * lib/isnan.c: Include float+.h.
136587         (SIZE): New macro.
136588         (FUNC): Compare only SIZE bytes of the value.
136589         * lib/vasnprintf.c: Include float+.h.
136590         (VASNPRINTF): When comparing against +0.0L or +0.0, compare only
136591         SIZEOF_LDBL or SIZEOF_DBL bytes.
136592         * modules/isnan-nolibm (Files): Add lib/float+.h.
136593         * modules/isnanl-nolibm (Files): Add lib/float+.h.
136594         * modules/isnanl (Files): Add lib/float+.h.
136595         * modules/vasnprintf (Files): Add lib/float+.h.
136597 2007-03-24  Bruno Haible  <bruno@clisp.org>
136599         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
136600         include isnanl-nolibm.h.
136602 2007-03-24  Bruno Haible  <bruno@clisp.org>
136604         * tests/test-read-file.c (main): Don't produce spurious output for
136605         expected situations. Make the test fail if it encountered unexpected
136606         results.
136608 2007-03-24  Bruno Haible  <bruno@clisp.org>
136610         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
136611         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
136613 2007-03-24  Bruno Haible  <bruno@clisp.org>
136615         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
136617 2007-03-24  Bruno Haible  <bruno@clisp.org>
136619         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
136620         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
136622         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
136623         * modules/utf8-ucs4: Turn into a symbolic link to module
136624         unistr/u8-mbtouc.
136626         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
136627         utf8-ucs4-unsafe.
136628         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
136629         unistr/u8-mbtouc-unsafe.
136631         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
136632         * modules/utf16-ucs4: Turn into a symbolic link to module
136633         unistr/u16-mbtouc.
136635         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
136636         utf16-ucs4-unsafe.
136637         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
136638         unistr/u16-mbtouc-unsafe.
136640         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
136641         * modules/ucs4-utf8: Turn into a symbolic link to module
136642         unistr/u8-ubtomb.
136644         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
136645         * modules/ucs4-utf16: Turn into a symbolic link to module
136646         unistr/u16-ubtomb.
136648 2007-03-24  Bruno Haible  <bruno@clisp.org>
136650         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
136651         Enable the function only if HAVE_INLINE.
136652         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
136653         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
136654         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
136655         Enable the function only if HAVE_INLINE.
136656         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
136657         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
136658         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
136659         Enable the function only if HAVE_INLINE.
136660         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
136661         Enable the function only if HAVE_INLINE.
136662         * modules/utf8-ucs4: Update.
136663         * modules/utf8-ucs4-unsafe: Update.
136664         * modules/utf16-ucs4: Update.
136665         * modules/utf16-ucs4-unsafe: Update.
136666         * modules/ucs4-utf8: Update.
136667         * modules/ucs4-utf16: Update.
136669 2007-03-24  Bruno Haible  <bruno@clisp.org>
136671         * lib/utf8-ucs4.h: Remove file.
136672         * lib/utf8-ucs4-unsafe.h: Remove file.
136673         * lib/utf16-ucs4.h: Remove file.
136674         * lib/utf16-ucs4-unsafe.h: Remove file.
136675         * lib/ucs4-utf8.h: Remove file.
136676         * lib/ucs4-utf16.h: Remove file.
136677         * lib/unistr.h: Include their previous contents.
136678         * m4/utf-ucs4.m4: Remove file.
136679         * m4/ucs4-utf.m4: Remove file.
136680         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
136681         (Depends-on): Add unistr/base.
136682         (configure.ac): Remove gl_UTF_UCS4.
136683         (Makefile.am): Update.
136684         (Include): Change to unistr.h.
136685         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
136686         (Depends-on): Add unistr/base.
136687         (configure.ac): Remove gl_UTF_UCS4.
136688         (Makefile.am): Update.
136689         (Include): Change to unistr.h.
136690         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
136691         (Depends-on): Add unistr/base.
136692         (configure.ac): Remove gl_UTF_UCS4.
136693         (Makefile.am): Update.
136694         (Include): Change to unistr.h.
136695         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
136696         (Depends-on): Add unistr/base.
136697         (configure.ac): Remove gl_UTF_UCS4.
136698         (Makefile.am): Update.
136699         (Include): Change to unistr.h.
136700         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
136701         (Depends-on): Add unistr/base.
136702         (configure.ac): Remove gl_UCS4_UTF.
136703         (Makefile.am): Update.
136704         (Include): Change to unistr.h.
136705         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
136706         (Depends-on): Add unistr/base.
136707         (configure.ac): Remove gl_UCS4_UTF.
136708         (Makefile.am): Update.
136709         (Include): Change to unistr.h.
136710         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
136711         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
136712         utf8-ucs4-unsafe.h.
136713         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
136714         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
136715         utf16-ucs4-unsafe.h.
136716         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
136717         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
136718         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
136719         * lib/unistr/u8-strchr.c: Likewise.
136720         * lib/unistr/u8-strrchr.c: Likewise.
136721         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
136722         * lib/unistr/u16-strchr.c: Likewise.
136723         * lib/unistr/u16-strrchr.c: Likewise.
136724         * lib/striconveh.c: Update.
136725         * lib/linebreak.c: Update.
136727 2007-03-24  Bruno Haible  <bruno@clisp.org>
136729         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
136730         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
136732 2007-03-22  Bruno Haible  <bruno@clisp.org>
136734         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
136736 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
136738         * MODULES.html.sh (File system functions): New module write-any-file.
136739         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
136740         * m4/write-any-file.m4: New files.
136742 2007-03-23  Eric Blake  <ebb9@byu.net>
136744         * gnulib-tool: Rearrange space-tab sequences, since some editors
136745         like to eat them.
136747 2007-03-23  Eric Blake  <ebb9@byu.net>
136749         * lib/version-etc.c (version_etc_va): Update license wording to
136750         be more concise.  Recommended by Richard Stallman.
136752 2007-03-22  Bruno Haible  <bruno@clisp.org>
136754         * lib/poll.c (MSG_PEEK): New fallback definition.
136756 2007-03-22  Bruno Haible  <bruno@clisp.org>
136758         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
136759         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
136760         (main): Update.
136761         Fixes a compilation error on BeOS.
136763 2007-03-22  Bruno Haible  <bruno@clisp.org>
136765         * modules/frexpl-tests: New file.
136766         * tests/test-frexpl.c: New file.
136768         * modules/frexpl: New file.
136769         * m4/frexpl.m4: New file.
136770         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
136771         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
136772         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
136773         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
136774         (Depends-on): Add frexpl. Remove isnanl-nolibm.
136775         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
136777 2007-03-22  Bruno Haible  <bruno@clisp.org>
136779         * lib/frexpl.c: Share code with lib/frexp.c.
136780         * modules/mathl (Files): Add lib/frexp.c.
136781         (Depends-on): Add isnanl-nolibm.
136783 2007-03-22  Bruno Haible  <bruno@clisp.org>
136785         * modules/printf-frexp (Files): Add m4/frexp.m4.
136786         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
136787         only if the found frexp function actually works.
136789 2007-03-22  Bruno Haible  <bruno@clisp.org>
136791         * lib/frexp.c: Remove older implementation that uses divisions.
136793 2007-03-21  Bruno Haible  <bruno@clisp.org>
136795         * modules/frexp-tests: New file.
136796         * tests/test-frexp.c: New file.
136798         * modules/frexp: New file.
136799         * lib/frexp.c: New file.
136800         * m4/frexp.m4: New file.
136801         * lib/math_.h (frexp): New declaration.
136802         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
136803         REPLACE_FREXP.
136804         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
136806 2007-03-21  Bruno Haible  <bruno@clisp.org>
136808         * modules/isnanl-tests: New file.
136809         * tests/test-isnanl.c: New file.
136811         * modules/isnanl: New file.
136812         * lib/isnanl.h: New file.
136813         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
136814         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
136815         gl_FUNC_ISNANL_WORKS.
136816         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
136817         New macros.
136819 2007-03-21  Bruno Haible  <bruno@clisp.org>
136821         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
136822         lib/isnanl.h.
136823         (Include): Update.
136824         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
136825         * lib/vasnprintf.c: Update.
136826         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
136827         tests/test-isnanl.h, remove tests/test-isnanl.c.
136828         (Makefile.am): Update.
136829         * tests/test-isnanl-nolibm.c: New file.
136830         * tests/test-isnanl.h: New file.
136831         * tests/test-isnanl.c: Remove file.
136833 2007-03-21  Jim Meyering  <jim@meyering.net>
136835         When trying to open ".", treat ESTALE like EACCES.
136836         * lib/savewd.c (savewd_save): Resort to forking not just upon
136837         failure with EACCES, but also when errno is ESTALE.
136839 2007-03-20  Bruno Haible  <bruno@clisp.org>
136841         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
136842         Needed on AIX 5.1. Reported by Matthew Woehlke.
136844 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
136846         Suggestions by Bruno Haible:
136847         * lib/acl-internal.h: Include "gettext.h" rather than rolling
136848         our own.
136849         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
136850         * modules/acl (Depends-on): Add gettext.
136852 2007-03-19  Bruno Haible  <bruno@clisp.org>
136854         * modules/iconvme: Remove file.
136855         * lib/iconvme.h: Remove file.
136856         * lib/iconvme.c: Remove file.
136857         * m4/iconvme.m4: Remove file.
136859 2007-03-19  Bruno Haible  <bruno@clisp.org>
136861         * doc/relocatable-maint.texi: Break long shell script line.
136862         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
136864 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
136866         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
136867         handle file_has_acl.
136868         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
136869         * lib/acl.c: Move header inclusions and related macro defns into
136870         lib/acl-internal.h.
136871         (S_ISLNK): Remove defn, since that's now done for us.
136872         (file_has_acl): Move to lib/file-has-acl.c.
136873         Call acl_trivial if available.  This is the crucial part of the fix.
136874         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
136875         shared within the library.  Rewrite a bit, partly to make it compatible
136876         with the GNU coding style.
136877         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
136878         Remove unnecessary double-quotes.
136879         Don't test for acl_to_text; the build will catch that.
136880         Replace acl_entries if it doesn't exist and it is needed.
136881         Check for -lsec and acl_trivial (as used on Solaris 10).
136882         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
136883         lib/file-has-acl.c.
136884         (Depends-on): Add sys_stat, for S_ISLNK.
136886 2007-03-19  Ben Pfaff  <blp@gnu.org>
136888         * doc/gnulib.texi: Fix typos.
136889         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
136891 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
136893         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
136894         If size is zero here, buf must be zero.
136896 2007-03-19  Simon Josefsson  <simon@josefsson.org>
136898         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
136899         <bruno@clisp.org>.
136901 2007-03-18  Bruno Haible  <bruno@clisp.org>
136903         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
136904         Suggested by Eric Blake.
136906 2007-03-18  Ben Pfaff  <blp@gnu.org>
136908         * doc/relocatable.texi: Recommend using as prefix a directory
136909         that does not exist and will never be created.  Based on
136910         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
136911         and others.
136913 2007-03-17  Bruno Haible  <bruno@clisp.org>
136915         * lib/fchownat.c: Include lchown.h.
136917 2007-03-17  Bruno Haible  <bruno@clisp.org>
136919         Fix endless loop when the given allocated size was > INT_MAX.
136920         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
136921         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
136922         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
136923         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
136924         * lib/sprintf.c (sprintf): Likewise.
136926 2007-03-17  Bruno Haible  <bruno@clisp.org>
136928         * tests/test-argp-2.sh (func_compare): Output a context diff.
136930 2007-03-17  Bruno Haible  <bruno@clisp.org>
136932         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
136933         locale's decimal-point character.
136935 2007-03-17  Bruno Haible  <bruno@clisp.org>
136937         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
136938         before comparing it. Needed because on some platforms (e.g. x86) a
136939         'long double' occupies less bytes than sizeof (long double).
136941 2007-03-17  Bruno Haible  <bruno@clisp.org>
136943         * tests/test-crc.c (main): Make printf statements 64-bit clean.
136944         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
136945         * tests/test-getaddrinfo.c (simple): Likewise.
136946         * tests/test-read-file.c (main): Likewise.
136948 2007-03-17  Bruno Haible  <bruno@clisp.org>
136950         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
136952 2007-03-17  Bruno Haible  <bruno@clisp.org>
136954         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
136955         unused variable.
136957 2007-03-17  Bruno Haible  <bruno@clisp.org>
136959         * tests/test-c-strcasecmp.c: Include c-strcase.h.
136960         * tests/test-c-strncasecmp.c: Likewise.
136962 2007-03-17  Bruno Haible  <bruno@clisp.org>
136964         * modules/stdlib (Depends-on): Add unistd.
136965         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
136966         Needed for MacOS X 10.3.
136968 2007-03-17  Bruno Haible  <bruno@clisp.org>
136970         * lib/unistr/u-strdup.h: Include <stdlib.h>.
136972 2007-03-17  Bruno Haible  <bruno@clisp.org>
136974         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
136976 2007-03-17  Bruno Haible  <bruno@clisp.org>
136978         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
136979         to reflect files copied from gnulib (with or without modifications).
136980         Suggested by Jim Meyering.
136982 2007-03-17  Eric Blake  <ebb9@byu.net>
136984         * NEWS: Document stdlib change from 2007-02-18.
136986 2007-03-17  Jim Meyering  <jim@meyering.net>
136988         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
136989         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
136990         someone uses a name containing shell meta-characters.
136991         Reported by Alfred M. Szmidt.
136993         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
136995 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
136997         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
136998         and copy gettext configuration files only if configure.ac contains
136999         a use of AM_GNU_GETTEXT_VERSION.
137001 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
137003         * build-aux/bootstrap (gnulib_name): New variable.
137004         (gnulib_tool_options): Use it.
137006 2007-03-13  Simon Josefsson  <simon@josefsson.org>
137008         * tests/test-des.c: Use new namespace.
137010 2007-03-15  Bruno Haible  <bruno@clisp.org>
137012         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
137013         Reported by James Youngman <jay@gnu.org>.
137015 2007-03-15  Bruno Haible  <bruno@clisp.org>
137017         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
137018         declared prototype. Needed with cc on OSF/1 5.1.
137020 2007-03-15  Bruno Haible  <bruno@clisp.org>
137022         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
137023         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
137024         (struct gl_list_implementation): Add dispose_fn argument to the
137025         'create_empty', 'create' methods.
137026         (struct gl_list_impl_base): Add field 'dispose_fn'.
137027         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
137028         argument.
137029         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
137030         dispose_fn argument.
137031         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
137032         dispose_fn on the dropped values.
137033         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
137034         dispose_fn argument.
137035         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
137036         dropped values.
137037         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
137038         (gl_tree_remove_node): Call dispose_fn on the dropped value.
137039         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
137040         (gl_tree_remove_node): Call dispose_fn on the dropped value.
137041         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
137042         argument.
137043         (gl_tree_list_free): Call dispose_fn on the dropped values.
137044         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
137045         the dropped values.
137046         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
137047         Add dispose_fn argument.
137048         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
137049         Call dispose_fn on the dropped values.
137050         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
137051         Add dispose_fn argument.
137052         (gl_sublist_create): Initialize the 'dispose_fn' field.
137053         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
137054         * tests/test-array_list.c (main): Update.
137055         * tests/test-carray_list.c (main): Update.
137056         * tests/test-avltree_list.c (main): Update.
137057         * tests/test-rbtree_list.c (main): Update.
137058         * tests/test-avltreehash_list.c (main): Update.
137059         * tests/test-rbtreehash_list.c (main): Update.
137060         * tests/test-linked_list.c (main): Update.
137061         * tests/test-linkedhash_list.c (main): Update.
137062         * tests/test-array_oset.c (main): Update.
137064 2007-03-15  Bruno Haible  <bruno@clisp.org>
137066         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
137067         (gl_oset_create_empty): Add dispose_fn argument.
137068         (struct gl_oset_implementation): Add dispose_fn argument to
137069         'create_empty' method.
137070         (struct gl_oset_impl_base): Add dispose_fn field.
137071         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
137072         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
137073         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
137074         values.
137075         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
137076         (gl_tree_oset_free): Call dispose_fn on the dropped values.
137077         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
137078         dropped value.
137079         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
137080         dropped value.
137081         * tests/test-array_oset.c (main): Update.
137082         * tests/test-avltree_oset.c (main): Update.
137083         * tests/test-rbtree_oset.c (main): Update.
137084         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
137086 2007-03-13  Bruno Haible  <bruno@clisp.org>
137088         * tests/test-stdbool.c (i): Update after last patch.
137090 2007-03-12  Bruno Haible  <bruno@clisp.org>
137092         * lib/quotearg.c: Include <wctype.h> early, before the definition of
137093         the iswprint macro. Needed on Solaris 2.5.1.
137095 2007-03-12  Bruno Haible  <bruno@clisp.org>
137097         * tests/test-printf-frexp.c (main): Declare x as volatile.
137099 2007-03-12  Simon Josefsson  <simon@josefsson.org>
137101         * doc/gnulib.texi (Build robot for gnulib): New section.
137103 2007-03-12  Jim Meyering  <jim@meyering.net>
137105         * build-aux/bootstrap: New file.
137106         * build-aux/bootstrap.conf: New file, from coreutils.
137108 2007-03-11  Bruno Haible  <bruno@clisp.org>
137110         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
137112 2007-03-12  Simon Josefsson  <simon@josefsson.org>
137114         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
137115         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
137116         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
137118 2007-03-11  Bruno Haible  <bruno@clisp.org>
137120         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
137121         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
137123 2007-03-11  Bruno Haible  <bruno@clisp.org>
137125         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
137126         formula. Needed for SunPRO C 5.0.
137128 2007-03-11  Bruno Haible  <bruno@clisp.org>
137130         * modules/long-options (Depends-on): Add getopt.
137132 2007-03-11  Bruno Haible  <bruno@clisp.org>
137134         * modules/modechange (Depends-on): Add stdbool.
137136 2007-03-11  Bruno Haible  <bruno@clisp.org>
137138         * modules/i-ring (Depends-on): Add stdbool.
137140 2007-03-11  Bruno Haible  <bruno@clisp.org>
137142         * modules/gc-des (Depends-on): Add stdbool.
137144 2007-03-11  Bruno Haible  <bruno@clisp.org>
137146         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
137148 2007-03-11  Bruno Haible  <bruno@clisp.org>
137150         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
137152 2007-03-11  Bruno Haible  <bruno@clisp.org>
137154         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
137156 2007-03-11  Bruno Haible  <bruno@clisp.org>
137158         * lib/vasnprintf.c (sprintf): Undefine.
137160 2007-03-11  Bruno Haible  <bruno@clisp.org>
137162         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
137163         initializers in SunPRO C and Compaq C compilers.
137165 2007-03-11  Bruno Haible  <bruno@clisp.org>
137167         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
137168         decrementing code ANSI C compliant.
137170 2007-03-11  Bruno Haible  <bruno@clisp.org>
137172         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
137173         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
137175 2007-03-11  Bruno Haible  <bruno@clisp.org>
137177         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
137178         <stdbool.h> substitute doesn't pass.
137180 2007-03-11  Bruno Haible  <bruno@clisp.org>
137182         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
137184 2007-03-11  Bruno Haible  <bruno@clisp.org>
137186         * gnulib-tool (func_create_megatestdir): Create also an autobuild
137187         script, for submission to autobuild.josefsson.org.
137189 2007-03-10  Bruno Haible  <bruno@clisp.org>
137191         * modules/canonicalize-lgpl-tests: New file.
137192         * tests/test-canonicalize-lgpl.sh: New file.
137193         * tests/test-canonicalize-lgpl.c: New file.
137195         * modules/c-strcase-tests: New file.
137196         * tests/test-c-strcase.sh: New file.
137197         * tests/test-c-strcasecmp.c: New file.
137198         * tests/test-c-strncasecmp.c: New file.
137200         * modules/atexit-tests: New file.
137201         * tests/test-atexit.sh: New file.
137202         * tests/test-atexit.c: New file.
137204 2007-03-10  Bruno Haible  <bruno@clisp.org>
137206         * tests/test-binary-io.sh: Use temporary filenames that are not so
137207         likely to clash with those of other tests (in a parallel make).
137208         * tests/test-binary-io.c: Likewise.
137210 2007-03-10  Bruno Haible  <bruno@clisp.org>
137212         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
137213         fallback; use #error instead.
137214         Suggested by Simon Josefsson.
137216 2007-03-10  Bruno Haible  <bruno@clisp.org>
137218         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
137219         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
137220         first and the last.
137222 2007-03-10  Bruno Haible  <bruno@clisp.org>
137224         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
137226 2007-03-10  Bruno Haible  <bruno@clisp.org>
137228         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
137229         "make distcheck".
137230         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
137231         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
137232         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
137234 2007-03-10  Bruno Haible  <bruno@clisp.org>
137236         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
137237         variable.
137238         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
137239         variable.
137241 2007-03-09  Eric Blake  <ebb9@byu.net>
137242         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
137244         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
137245         types are not being provided by gnulib.
137246         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
137247         types are supported.
137249 2007-03-10  Bruno Haible  <bruno@clisp.org>
137251         * lib/stdio_.h (__attribute__): New macro.
137252         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
137253         vsprintf): Specify __attribute__ __format__ for GCC.
137254         Suggested by Eric Blake.
137256 2007-03-09  Bruno Haible  <bruno@clisp.org>
137258         * modules/printf-posix-tests: New file.
137259         * tests/test-printf-posix.sh: New file.
137260         * tests/test-printf-posix.c: New file.
137262         * modules/printf-posix: New file.
137263         * lib/printf.c: New file.
137264         * m4/printf-posix-rpl.m4: New file.
137265         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
137266         REPLACE_PRINTF.
137267         * lib/stdio_.h (printf): New declaration.
137268         (format, __format__, ____printf____, ____scanf____, ____strftime____,
137269         ____strfmon____): New macros.
137270         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
137271         REPLACE_PRINTF.
137273 2007-03-09  Bruno Haible  <bruno@clisp.org>
137275         * tests/test-vasnprintf-posix2.sh: New file.
137276         * tests/test-vasnprintf-posix2.c: New file.
137277         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
137278         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
137279         (Makefile.am): Activate test-vasnprintf-posix2.sh.
137281         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
137282         a locale dependent decimal point, rather than always '.'.
137284 2007-03-09  Eric Blake  <ebb9@byu.net>
137286         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
137287         spite of platforms like Tandem/NSK that define it to -1.
137289 2007-03-08  Bruno Haible  <bruno@clisp.org>
137291         * modules/vprintf-posix-tests: New file.
137292         * tests/test-vprintf-posix.sh: New file.
137293         * tests/test-vprintf-posix.c: New file.
137294         * tests/test-printf-posix.h: New file.
137296         * modules/vprintf-posix: New file.
137297         * lib/vprintf.c: New file.
137298         * m4/vprintf-posix.m4: New file.
137299         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
137300         REPLACE_VPRINTF.
137301         * lib/stdio_.h (vprintf): New declaration.
137302         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
137303         REPLACE_VPRINTF.
137305 2007-03-08  Bruno Haible  <bruno@clisp.org>
137307         * modules/fprintf-posix-tests: New file.
137308         * tests/test-fprintf-posix.sh: New file.
137309         * tests/test-fprintf-posix.c: New file.
137311         * modules/fprintf-posix: New file.
137312         * lib/fprintf.c: New file.
137313         * m4/fprintf-posix.m4: New file.
137314         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
137315         REPLACE_FPRINTF.
137316         * lib/stdio_.h (fprintf): New declaration.
137317         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
137318         REPLACE_FPRINTF.
137320 2007-03-08  Bruno Haible  <bruno@clisp.org>
137322         * modules/vfprintf-posix-tests: New file.
137323         * tests/test-vfprintf-posix.sh: New file.
137324         * tests/test-vfprintf-posix.c: New file.
137325         * tests/test-fprintf-posix.h: New file.
137326         * tests/test-fprintf-posix.out: New file.
137328         * modules/vfprintf-posix: New file.
137329         * lib/vfprintf.c: New file.
137330         * m4/vfprintf-posix.m4: New file.
137331         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
137332         REPLACE_VFPRINTF.
137333         * lib/stdio_.h (vfprintf): New declaration.
137334         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
137335         REPLACE_VFPRINTF.
137337 2007-03-08  Bruno Haible  <bruno@clisp.org>
137339         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
137341 2007-03-08  Bruno Haible  <bruno@clisp.org>
137343         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
137344         instead of 'expr' invocations.
137345         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
137346         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
137347         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
137348         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
137349         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
137350         Suggested by Paul Eggert.
137352 2007-03-08  Bruno Haible  <bruno@clisp.org>
137354         * modules/fseterr-tests: New file.
137355         * tests/test-fseterr.c: New file.
137357         * modules/fseterr: New file.
137358         * lib/fseterr.h: New file.
137359         * lib/fseterr.c: New file.
137361 2007-03-08  Bruno Haible  <bruno@clisp.org>
137363         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
137364         * lib/getopt_.h: Likewise.
137365         * lib/mbswidth.h: Likewise.
137366         * lib/setenv.h: Likewise.
137367         * lib/vasnprintf.h: Likewise.
137368         * lib/vasprintf.h: Likewise.
137369         * lib/verror.h: Likewise.
137370         * lib/xsetenv.h: Likewise.
137371         * lib/xvasprintf.h: Likewise.
137373 2007-03-08  Jim Meyering  <jim@meyering.net>
137375         * users.txt: Add parted.
137377         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
137379 2007-03-07  Bruno Haible  <bruno@clisp.org>
137381         * m4/printf.m4: Make the shell script snippets copy&pastable.
137383 2007-03-02  Bruno Haible  <bruno@clisp.org>
137385         * lib/netinet_in_.h: New file.
137386         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
137387         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
137388         * modules/netinet_in (Files): Add lib/netinet_in_.h.
137389         (Depends-on): Add absolute-header.
137390         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
137391         into netinet/in.h.
137393 2007-03-03  Bruno Haible  <bruno@clisp.org>
137395         * lib/sys_select_.h: New file.
137396         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
137397         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
137398         * modules/sys_select (Files): Add lib/sys_select_.h.
137399         (Depends-on): Add absolute-header.
137400         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
137401         into sys/select.h.
137403 2007-03-02  Bruno Haible  <bruno@clisp.org>
137405         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
137406         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
137407         values.
137408         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
137409         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
137410         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
137411         * modules/sys_socket (Depends-on): Add absolute-header.
137412         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
137413         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
137414         (Include): Remove requirement of inclusion of <sys/types.h>.
137416 2007-03-02  Bruno Haible  <bruno@clisp.org>
137418         * lib/byteswap_.h (bswap_32): Fix formula.
137420 2007-03-06  Bruno Haible  <bruno@clisp.org>
137422         * modules/sprintf-posix-tests: New file.
137423         * tests/test-sprintf-posix.c: New file.
137425         * modules/sprintf-posix: New file.
137426         * lib/sprintf.c: New file.
137427         * m4/sprintf-posix.m4: New file.
137428         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
137429         REPLACE_SPRINTF.
137430         * lib/stdio_.h (sprintf): New declaration.
137431         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
137432         REPLACE_SPRINTF.
137434 2007-03-06  Bruno Haible  <bruno@clisp.org>
137436         * modules/vsprintf-posix-tests: New file.
137437         * tests/test-vsprintf-posix.c: New file.
137438         * tests/test-sprintf-posix.h: New file.
137440         * modules/vsprintf-posix: New file.
137441         * lib/vsprintf.c: New file.
137442         * m4/vsprintf-posix.m4: New file.
137443         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
137444         REPLACE_VSPRINTF.
137445         * lib/stdio_.h (vsprintf): New declaration.
137446         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
137447         REPLACE_VSPRINTF.
137449 2007-03-06  Bruno Haible  <bruno@clisp.org>
137451         * modules/vsnprintf (Depend-on): Remove minmax.
137453 2007-03-06  Bruno Haible  <bruno@clisp.org>
137455         * modules/snprintf-posix-tests: New file.
137456         * tests/test-snprintf-posix.c: New file.
137458         * modules/snprintf-posix: New file.
137459         * m4/snprintf-posix.m4: New file.
137460         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
137461         gl_FUNC_SNPRINTF.
137462         (gl_FUNC_SNPRINTF): Invoke it.
137463         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
137464         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
137465         is set.
137466         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
137468 2007-03-06  Bruno Haible  <bruno@clisp.org>
137470         * modules/vsnprintf-posix-tests: New file.
137471         * tests/test-vsnprintf-posix.c: New file.
137472         * tests/test-snprintf-posix.h: New file.
137474         * modules/vsnprintf-posix: New file.
137475         * m4/vsnprintf-posix.m4: New file.
137476         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
137477         gl_FUNC_VSNPRINTF.
137478         (gl_FUNC_VSNPRINTF): Invoke it.
137479         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
137480         * lib/stdio_.h (vsnprintf): Define as a replacement if
137481         REPLACE_VSNPRINTF is set.
137482         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
137484 2007-03-06  Bruno Haible  <bruno@clisp.org>
137486         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
137487         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
137489 2007-03-06  Bruno Haible  <bruno@clisp.org>
137491         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
137492         (asinl): Declare also if HAVE_DECL_ASINL is set.
137493         (atanl): Declare also if HAVE_DECL_ATANL is set.
137494         (ceill): Declare also if HAVE_DECL_CEILL is set.
137495         (cosl): Declare also if HAVE_DECL_COSL is set.
137496         (expl): Declare also if HAVE_DECL_EXPL is set.
137497         (floorl): Declare also if HAVE_DECL_FLOORL is set.
137498         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
137499         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
137500         (logl): Declare also if HAVE_DECL_LOGL is set.
137501         (sinl): Declare also if HAVE_DECL_SINL is set.
137502         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
137503         (tanl): Declare also if HAVE_DECL_TANL is set.
137504         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
137505         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
137506         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
137507         declaration of frexpl, ldexpl.
137508         * modules/printf-frexpl (Depends-on): Add math.
137509         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
137511 2007-03-05  Bruno Haible  <bruno@clisp.org>
137513         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
137514         frexpl and ldexpl are declared.
137515         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
137517 2007-03-05  Bruno Haible  <bruno@clisp.org>
137519         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
137520         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
137522 2007-03-05  Bruno Haible  <bruno@clisp.org>
137524         * lib/stdio_.h: Include <stddef.h>.
137526 2007-03-05  Bruno Haible  <bruno@clisp.org>
137528         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
137530 2007-03-05  Bruno Haible  <bruno@clisp.org>
137532         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
137533         NetBSD 4, from Ralf Wildenhues.
137535 2007-03-04  Bruno Haible  <bruno@clisp.org>
137537         * lib/vasprintf.h: Update #if logic for the case when the functions
137538         exist but are overridden.
137540 2007-03-04  Bruno Haible  <bruno@clisp.org>
137542         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
137543         implementations: glibc-2.4 and MacOS X 10.3.
137544         * tests/test-vasnprintf-posix.c (test_function): Test also the case
137545         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
137546         * tests/test-vasprintf-posix.c (test_function): Likewise.
137548 2007-03-04  Bruno Haible  <bruno@clisp.org>
137550         * modules/vasprintf-posix-tests: New file.
137551         * tests/test-vasprintf-posix.c: New file.
137553         * modules/vasprintf-posix: New file.
137554         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
137555         defined.
137556         * m4/vasprintf-posix.m4: New file.
137557         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
137558         gl_FUNC_VASPRINTF.
137559         (gl_FUNC_VASPRINTF): Invoke it.
137560         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
137561         here.
137562         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
137564 2007-03-04  Bruno Haible  <bruno@clisp.org>
137566         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
137567         REPLACE_GETTIMEOFDAY.
137568         * modules/sys_time (Makefile.am): Likewise.
137569         * m4/sys_time_h.m4: Likewise.
137570         * m4/gettimeofday.m4: Likewise.
137572 2007-03-04  Bruno Haible  <bruno@clisp.org>
137574         * modules/vasnprintf-posix-tests: New file.
137575         * tests/test-vasnprintf-posix.c: New file.
137577         * modules/vasnprintf-posix: New file.
137578         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
137579         printf-frexpl.h.
137580         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
137581         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
137582         REPLACE_VASNPRINTF is defined.
137583         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
137584         gl_FUNC_VASNPRINTF.
137585         (gl_FUNC_VASNPRINTF): Invoke it.
137586         * m4/vasnprintf-posix.m4: New file.
137587         * m4/printf.m4: New file.
137589 2007-03-04  Bruno Haible  <bruno@clisp.org>
137591         Compile progreloc.c only if --enable-relocatable is specified.
137592         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
137593         if --enable-relocatable was specified.
137594         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
137595         lib_SOURCES.
137597 2007-03-04  Jim Meyering  <jim@meyering.net>
137599         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
137600         Use it consistently, rather than enumerating errno constants.
137602 2007-03-04  Bruno Haible  <bruno@clisp.org>
137604         * modules/xvasprintf-tests: New file.
137605         * tests/test-xvasprintf.c: New file.
137607         * modules/vasprintf-tests: New file.
137608         * tests/test-vasprintf.c: New file.
137610         * modules/vasnprintf-tests: New file.
137611         * tests/test-vasnprintf.c: New file.
137613         * modules/vsnprintf-tests: New file.
137614         * tests/test-vsnprintf.c: New file.
137616         * modules/snprintf-tests: New file.
137617         * tests/test-snprintf.c: New file.
137619 2007-03-04  Bruno Haible  <bruno@clisp.org>
137621         Compile relocatable.c only if --enable-relocatable is specified.
137622         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
137623         gl_RELOCATABLE_LIBRARY.
137624         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
137625         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
137626         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
137627         gl_RELOCATABLE_LIBRARY.
137628         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
137629         (Makefile.am): Remove lib_SOURCES.
137630         * modules/relocatable-lib-lgpl (configure.ac): Invoke
137631         gl_RELOCATABLE_LIBRARY.
137632         (Makefile.am): Remove lib_SOURCES.
137633         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
137634         always.
137635         * modules/relocatable-prog-wrapper (configure.ac): Invoke
137636         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
137638 2007-03-04  Bruno Haible  <bruno@clisp.org>
137640         * modules/argmatch-tests: New file.
137641         * tests/test-argmatch.c: New file.
137643         * tests/test-allocsa.c (main): Halve the number of loop runs.
137645         * modules/alloca-opt-tests: New file.
137646         * tests/test-alloca-opt.c: New file.
137648 2007-03-04  Jim Meyering  <jim@meyering.net>
137650         Work around difference between Linux ACLs and Solaris 10 ZFS.
137651         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
137652         for EINVAL.
137654 2007-03-03  Bruno Haible  <bruno@clisp.org>
137656         * modules/relocatable-prog (Depends-on): Add back progreloc's
137657         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
137659 2007-03-03  Bruno Haible  <bruno@clisp.org>
137661         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
137662         * modules/relocatable-lib: New file.
137664 2007-03-03  Bruno Haible  <bruno@clisp.org>
137666         * modules/relocatable-prog: Renamed from modules/relocatable.
137667         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
137669 2007-03-03  Bruno Haible  <bruno@clisp.org>
137671         * modules/relocatable-script (Files): Add doc/relocatable.texi,
137672         m4/relocatable-lib.m4.
137673         (Depends-on): Remove 'relocatable'.
137674         (configure.ac): Add gl_RELOCATABLE_NOP.
137676 2007-03-03  Bruno Haible  <bruno@clisp.org>
137678         * modules/relocatable-prog-wrapper: New file.
137679         * modules/relocatable (Depends-on): Add it. Remove all other
137680         dependencies except progname.
137681         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
137683         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
137684         (gl_FUNC_STRERROR): Nop.
137685         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
137687         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
137688         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
137690         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
137691         (gl_FUNC_READLINK): Update.
137693         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
137695 2007-03-03  Bruno Haible  <bruno@clisp.org>
137697         * lib/xreadlink.c: Include <unistd.h> unconditionally.
137698         * modules/xreadlink (Depends-on): Add unistd.
137699         * modules/xreadlink-with-size (Depends-on): Likewise.
137701 2007-03-03  Bruno Haible  <bruno@clisp.org>
137703         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
137704         extracted from gt_FUNC_SETENV.
137705         (gt_FUNC_SETENV): Remove macro.
137706         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
137707         remove gt_FUNC_SETENV.
137709 2007-03-03  Bruno Haible  <bruno@clisp.org>
137711         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
137712         ENABLE_RELOCATABLE here.
137713         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
137715 2007-03-03  Bruno Haible  <bruno@clisp.org>
137717         * modules/rbtreehash-list-tests (Depends-on): Add progname.
137718         * tests/test-rbtreehash_list.c: Include progname.h.
137719         (main): Call set_program_name.
137721         * modules/rbtree-oset-tests (Depends-on): Add progname.
137722         * tests/test-rbtree_oset.c: Include progname.h.
137723         (main): Call set_program_name.
137725         * modules/rbtree-list-tests (Depends-on): Add progname.
137726         * tests/test-rbtree_list.c: Include progname.h.
137727         (main): Call set_program_name.
137729         * modules/linked-list-tests (Depends-on): Add progname.
137730         * tests/test-linked_list.c: Include progname.h.
137731         (main): Call set_program_name.
137733 2007-03-03  Bruno Haible  <bruno@clisp.org>
137735         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
137736         All uses of __restrict changed to _Restrict_.
137737         * lib/glob_.h (__restrict): Remove macro.
137739 2007-03-02  Bruno Haible  <bruno@clisp.org>
137741         * modules/gettext (configure.ac): Require gettext infrastructure
137742         from version 0.16.1.
137744 2007-03-02  Bruno Haible  <bruno@clisp.org>
137746         * modules/linkedhash-list-tests (Depends-on): Add progname.
137747         * tests/test-linkedhash_list.c: Include progname.h.
137748         (main): Call set_program_name.
137750         * modules/carray-list-tests (Depends-on): Add progname.
137751         * tests/test-carray_list.c: Include progname.h.
137752         (main): Call set_program_name.
137754         * modules/avltreehash-list-tests (Depends-on): Add progname.
137755         * tests/test-avltreehash_list.c: Include progname.h.
137756         (main): Call set_program_name.
137758         * modules/avltree-oset-tests (Depends-on): Add progname.
137759         * tests/test-avltree_oset.c: Include progname.h.
137760         (main): Call set_program_name.
137762         * modules/avltree-list-tests (Depends-on): Add progname.
137763         * tests/test-avltree_list.c: Include progname.h.
137764         (main): Call set_program_name.
137766         * modules/array-oset-tests (Depends-on): Add progname.
137767         * tests/test-array_oset.c: Include progname.h.
137768         (main): Call set_program_name.
137770         * modules/array-list-tests (Depends-on): Add progname.
137771         * tests/test-array_list.c: Include progname.h.
137772         (main): Call set_program_name.
137774         * modules/argp-tests (Depends-on): Add progname.
137775         * tests/test-argp.c: Include argp.h first. Include progname.h.
137776         (main): Call set_program_name.
137778 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
137780         * doc/gnulib-tool.texi (Initial import): Reword description of
137781         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
137782         limited effect even if defined after the first system include.
137784 2007-03-01  Bruno Haible  <bruno@clisp.org>
137786         * build-aux/config.libpath: Update to libtool-1.5.22.
137787         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
137789 2007-03-01  Bruno Haible  <bruno@clisp.org>
137791         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
137792         foo_CFLAGS.
137793         Reported by Ralf Wildenhues.
137795 2007-03-01  Bruno Haible  <bruno@clisp.org>
137797         * build-aux/install-reloc: Remove object files left over by some
137798         compilers.
137799         Reported by Ralf Wildenhues.
137801 2007-03-01  Bruno Haible  <bruno@clisp.org>
137803         * build-aux/install-reloc: Break long lines.
137805 2007-03-01  Bruno Haible  <bruno@clisp.org>
137807         * doc/relocatable.texi: Document that it may not work on OpenBSD.
137808         Reported by Ralf Wildenhues.
137810 2007-03-01  Bruno Haible  <bruno@clisp.org>
137812         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
137813         include ordering constraints.
137815 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
137817         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
137818         <http://lists.gnu.org/r/bug-gnulib/2007-02/msg00136.html>.
137819         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
137820         as another example.
137821         * lib/time_.h: Fix misspelling.
137822         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
137823         Require gl_HEADER_TIME_H_DEFAULTS.
137824         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
137825         * m4/time_r.m4 (gl_TIME_R): Likewise.
137826         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
137828 2007-03-01  Bruno Haible  <bruno@clisp.org>
137830         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
137831         * m4/utimens.m4 (gl_UTIMENS): Likewise.
137833 2007-03-01  Jim Meyering  <jim@meyering.net>
137835         * modules/xreadlink (Maintainer): Add my name.
137836         * modules/xreadlink-with-size (Depends-on): Alphabetize.
137838 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
137839             Bruno Haible  <bruno@clisp.org>
137841         * build-aux/install-reloc: Compile also c-ctype.c.
137842         * build-aux/relocatable.sh.in: New file.
137843         * doc/relocatable.texi: New file.
137844         * doc/relocatable-maint.texi: New file.
137845         * doc/gnulib.texi: Include relocatable-maint.texi.
137846         * lib/progreloc.c: Include unistd.h unconditionally.
137847         * lib/relocwrapper.c: Include unistd.h unconditionally.
137848         Include c-ctype.h.
137849         (add_dotbin): Use c_tolower.
137850         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
137851         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
137852         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
137853         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
137854         to m4/relocatable-lib.m4.
137855         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
137856         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
137857         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
137858         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
137859         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
137860         * modules/relocatable: New file.
137861         * modules/relocatable-lib: New file.
137862         * modules/relocatable-script: New file.
137864 2007-02-28  Bruno Haible  <bruno@clisp.org>
137866         Import --enable-relocatable infrastructure.
137867         * build-aux/config.libpath: New file, from GNU gettext.
137868         * build-aux/install-reloc: New file, from GNU gettext.
137869         * build-aux/reloc-ldflags: New file, from GNU gettext.
137870         * lib/relocatable.h: New file, from GNU gettext.
137871         * lib/relocatable.c: New file, from GNU gettext.
137872         * lib/relocwrapper.c: New file, from GNU gettext.
137873         * m4/relocatable.m4: New file, from GNU gettext.
137875 2007-02-28  Bruno Haible  <bruno@clisp.org>
137877         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
137879         * modules/xreadlink: New file, from GNU gettext with modifications.
137880         * lib/xreadlink.c: New file, from GNU gettext.
137881         * lib/xreadlink.h: Add comments.
137882         (xreadlink): New declaration.
137884         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
137885         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
137886         lib/xreadlink-with-size.c.
137887         (configure.ac): Remove gl_XREADLINK invocation.
137888         (Makefile.am): Augment lib_SOURCES.
137889         * m4/xreadlink.m4: Remove file.
137890         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
137891         (xreadlink_with_size): Renamed from xreadink.
137892         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
137893         * modules/canonicalize (Depends-on): Replace xreadlink with
137894         xreadlink-with-size.
137895         * lib/canonicalize.c (canonicalize_filename_mode): Update.
137897 2007-02-25  Jim Meyering  <jim@meyering.net>
137899         * build-aux/announce-gen: When complaining about excess arguments,
137900         list them.
137902 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
137904         * README: Document signed integer overflow situation more
137905         accurately.
137907 2007-02-25  Bruno Haible  <bruno@clisp.org>
137909         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
137910         'a' or 'A' conversion.
137912 2007-02-25  Bruno Haible  <bruno@clisp.org>
137914         * modules/filename: Renamed from modules/pathname.
137915         (Files): Replace lib/pathname.h with lib/filename.h. Replace
137916         lib/concatpath.c with lib/concat-filename.c.
137917         (Makefile.am): Update.
137918         (Include): Replace pathname.h with filename.h.
137919         * lib/filename.h: Renamed from lib/pathname.h.
137920         (concatenated_filename): Renamed from concatenated_pathname.
137921         * lib/concat-filename.c: Renamed from lib/concatpath.c.
137922         (concatenated_filename): Renamed from concatenated_pathname.
137923         * lib/findprog.c: Include filename.h instead of pathname.h.
137924         (find_in_path): Update.
137925         * lib/javacomp.c: Include filename.h instead of pathname.h.
137926         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
137927         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
137928         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
137929         is_oldgcj_14_13_usable, is_javac_usable): Update.
137930         * lib/javaexec.c: Include filename.h instead of pathname.h.
137931         (execute_java_class): Update.
137932         * modules/findprog: Update.
137933         * modules/javacomp: Update.
137934         * modules/javaexec: Update.
137935         * MODULES.html.sh (File system functions): Add 'filename', remove
137936         'pathname'.
137938 2007-02-25  Bruno Haible  <bruno@clisp.org>
137940         * modules/printf-frexpl-tests: New file.
137941         * tests/test-printf-frexpl.c: New file.
137943         * modules/printf-frexpl: New file.
137944         * lib/printf-frexpl.h: New file.
137945         * lib/printf-frexpl.c: New file.
137946         * m4/printf-frexpl.m4: New file.
137948 2007-02-25  Bruno Haible  <bruno@clisp.org>
137950         * modules/printf-frexp-tests: New file.
137951         * tests/test-printf-frexp.c: New file.
137953         * modules/printf-frexp: New file.
137954         * lib/printf-frexp.h: New file.
137955         * lib/printf-frexp.c: New file.
137956         * m4/printf-frexp.m4: New file.
137958 2007-02-25  Bruno Haible  <bruno@clisp.org>
137960         Assume automake >= 1.10 for the tests.
137961         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
137962         * modules/arctwo-tests: Likewise.
137963         * modules/argp-tests: Likewise.
137964         * modules/avltree-list-tests: Likewise.
137965         * modules/avltree-oset-tests: Likewise.
137966         * modules/avltreehash-list-tests: Likewise.
137967         * modules/carray-list-tests: Likewise.
137968         * modules/crc-tests: Likewise.
137969         * modules/des-tests: Likewise.
137970         * modules/gc-arcfour-tests: Likewise.
137971         * modules/gc-arctwo-tests: Likewise.
137972         * modules/gc-des-tests: Likewise.
137973         * modules/gc-hmac-md5-tests: Likewise.
137974         * modules/gc-hmac-sha1-tests: Likewise.
137975         * modules/gc-md2-tests: Likewise.
137976         * modules/gc-md4-tests: Likewise.
137977         * modules/gc-md5-tests: Likewise.
137978         * modules/gc-pbkdf2-sha1-tests: Likewise.
137979         * modules/gc-rijndael-tests: Likewise.
137980         * modules/gc-sha1-tests: Likewise.
137981         * modules/gc-tests: Likewise.
137982         * modules/getaddrinfo-tests: Likewise.
137983         * modules/hmac-md5-tests: Likewise.
137984         * modules/hmac-sha1-tests: Likewise.
137985         * modules/linked-list-tests: Likewise.
137986         * modules/linkedhash-list-tests: Likewise.
137987         * modules/lock-tests: Likewise.
137988         * modules/md2-tests: Likewise.
137989         * modules/md4-tests: Likewise.
137990         * modules/md5-tests: Likewise.
137991         * modules/rbtree-list-tests: Likewise.
137992         * modules/rbtree-oset-tests: Likewise.
137993         * modules/rbtreehash-list-tests: Likewise.
137994         * modules/read-file-tests: Likewise.
137995         * modules/rijndael-tests: Likewise.
137996         * modules/stdint-tests: Likewise.
137997         * modules/tls-tests: Likewise.
137999 2007-02-24  Bruno Haible  <bruno@clisp.org>
138001         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
138002         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
138003         function; instead check whether isnan with a double argument links.
138004         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
138005         function; instead check whether isnan with a 'long double' argument
138006         links.
138007         Reported by Eric Blake <ebb9@byu.net>.
138009 2007-02-24  Bruno Haible  <bruno@clisp.org>
138011         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
138012         defined.
138013         * lib/isnanl.c: Remove all code. Just include isnan.c.
138014         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
138016 2007-02-25  Jim Meyering  <jim@meyering.net>
138018         Avoid conflicting types for 'unsetenv' on FreeBSD.
138019         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
138020         conflicting with FreeBSD's (5.0 and 6.1) function declaration
138021         in stdlib.h.
138023 2007-02-24  Bruno Haible  <bruno@clisp.org>
138025         * modules/isnanl-nolibm-tests: New file.
138026         * tests/test-isnanl.c: New file.
138028         * modules/isnanl-nolibm: New file.
138029         * lib/isnanl.h: New file.
138030         * lib/isnanl.c: New file.
138031         * m4/isnanl.m4: New file.
138033 2007-02-24  Bruno Haible  <bruno@clisp.org>
138035         * modules/isnan-nolibm-tests: New file.
138036         * tests/test-isnan.c: New file.
138038         * modules/isnan-nolibm: New file.
138039         * lib/isnan.h: New file.
138040         * lib/isnan.c: New file.
138041         * m4/isnan.m4: New file.
138043 2007-02-24  Bruno Haible  <bruno@clisp.org>
138045         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
138046         assume that an exponent fits in 20 bits.
138048 2007-02-24  Jim Meyering  <jim@meyering.net>
138050         * m4/regex.m4: Update the description of the configure-time option,
138051         --without-included-regex, to state accurately what the defaults are,
138052         and perhaps to give people an idea why using this option is risky.
138054 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
138056         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
138057         loops on small arguments.  This attempts to avoid the problem
138058         Bruno Haible reported for AIX 4.3.2 in
138059         <http://lists.gnu.org/r/bug-gnulib/2007-02/msg00309.html>.
138061 2007-02-23  Bruno Haible  <bruno@clisp.org>
138063         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
138064         Needed for help2man.
138066 2007-02-23  Karl Berry  <karl@gnu.org>
138068         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
138069         exists, foo.h should be cvs-ignored, not committed.
138071 2007-02-23  Eric Blake  <ebb9@byu.net>
138073         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
138074         * lib/stat-time.h (includes): Likewise.
138075         * lib/utimecmp.c (includes): Likewise.
138076         * lib/utimens.h (includes): Likewise.
138077         * lib/getdate.y (includes): Also include "timespec.h" for use
138078         internal to the module.
138079         * modules/utimens (Depends-on): Revert yesterday's patch.
138080         * modules/nanosleep (Depends-on): Add missing dependency.
138082 2007-02-22  Bruno Haible  <bruno@clisp.org>
138084         * lib/glob.c: Don't include getlogin_r.h.
138086 2007-02-22  Jim Meyering  <jim@meyering.net>
138088         * modules/utimens (Depends-on): Add timespec, required for
138089         utimens.h's inclusion of timespec.h.
138091 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
138093         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
138094         long unreadable paths in GNU/Linux.  Problem reported by Andreas
138095         Schwab in
138096         <http://lists.gnu.org/r/bug-gnulib/2007-02/msg00261.html>.
138097         I'll try to think of a better way to fix the Solaris problem.
138099         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
138100         like glibc; on Solaris 10, it fails with errno == EINVAL.
138101         POSIX says the behavior is unspecified if the first argument is NULL,
138102         so play it safe and never pass NULL to the system getcwd.
138104 2007-02-21  Jim Meyering  <jim@meyering.net>
138106         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
138107         of gettimeofday.  It would conflict with the one now always
138108         provided via sys_time_.h.  Reported by Matthew Woehlke, as
138109         an IRIX 6.5 build failure.
138111 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
138113         Minor fixups to port to Solaris 10 with Sun C 5.8.
138114         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
138115         * modules/getcwd (Depends-on): Add dirfd.
138116         * lib/putenv.c (putenv): #undef it.
138117         (rpl_putenv): New decl.
138118         (malloc, free): Include <stdlib.h> rather than prototyping separately.
138120 2007-02-20  Bruno Haible  <bruno@clisp.org>
138122         * modules/stdio-tests: New file.
138123         * tests/test-stdio.c: New file.
138125         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
138126         (Depends-on): Add stdio.
138127         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
138128         (Include): Use <stdio.h> instead of vsnprintf.h.
138129         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
138130         HAVE_DECL_VSNPRINTF.
138131         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
138133         * modules/snprintf (Files): Remove lib/snprintf.h.
138134         (Depends-on): Add stdio.
138135         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
138136         (Include): Use <stdio.h> instead of snprintf.h.
138137         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
138138         HAVE_DECL_SNPRINTF.
138139         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
138140         * lib/getaddrinfo.c: Likewise.
138142         * modules/stdio: New file.
138143         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
138144         * lib/snprintf.h: Remove file.
138145         * lib/vsnprintf.h: Remove file.
138146         * lib/.cppi-disable: Remove snprintf.h.
138147         * m4/stdio_h.m4: New file.
138148         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
138150 2007-02-20  Jim Meyering  <jim@meyering.net>
138152         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
138153         used by e.g., mingw.  From Bruno Haible.
138155 2007-02-19  Bruno Haible  <bruno@clisp.org>
138157         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
138158         warnings.
138159         Reported by Ben Pfaff <blp@cs.stanford.edu>.
138161 2007-02-19  Bruno Haible  <bruno@clisp.org>
138163         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
138164         from mingw users.
138166 2007-02-19  Bruno Haible  <bruno@clisp.org>
138168         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
138169         warnings.
138170         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
138172 2007-02-19  Jim Meyering  <jim@meyering.net>
138174         Don't use FD after a successful "fdopendir (fd)".
138175         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
138176         Reset it by calling dirfd on the just-obtained DIR*.
138178         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
138179         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
138181 2007-02-18  Bruno Haible  <bruno@clisp.org>
138183         * lib/readlink.c: Include <unistd.h>.
138184         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
138185         HAVE_READLINK.
138186         * modules/readlink (Depends-on): Add unistd.
138187         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
138188         (Include): Add <unistd.h>.
138190         * lib/getlogin_r.h: Remove file.
138191         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
138192         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
138193         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
138194         HAVE_DECL_GETLOGIN_R.
138195         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
138196         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
138197         (Include): Use <unistd.h> instead of getlogin_r.h.
138199         * lib/getcwd.h: Remove file.
138200         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
138201         * lib/xgetcwd.c: Likewise.
138202         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
138203         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
138204         * modules/getcwd (Files): Remove lib/getcwd.h.
138205         (Depends-on): Add unistd.
138206         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
138207         (Include): Use <unistd.h> instad of getcwd.h.
138209         * lib/ftruncate.c: Include <unistd.h> first.
138210         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
138211         Set HAVE_FTRUNCATE.
138212         * modules/ftruncate (Depends-on): Add unistd.
138213         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
138215         * lib/fchdir.c: Include <unistd.h> first.
138216         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
138217         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
138218         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
138219         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
138220         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
138222         * lib/dup2.c: Include <unistd.h> first.
138223         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
138224         HAVE_DUP2.
138225         * modules/dup2 (Depends-on): Add unistd.
138226         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
138228         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
138229         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
138230         REPLACE_CHOWN. Don't define chown as a macro here.
138231         * modules/chown (Depends-on): Add unistd.
138232         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
138234         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
138235         Add definition for GL_LINK_WARNING.
138236         (chown, dup2): New declarations.
138237         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
138238         link warning.
138239         (ftruncate): New declaration.
138240         (getcwd): New declaration, taken from old getcwd.h.
138241         (getlogin_r): New declaration, taken from old getlogin_r.h.
138242         (readlink): New declaration.
138243         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
138244         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
138245         (gl_PREREQ_UNISTD): Remove macro.
138246         (gl_UNISTD_MODULE_INDICATOR): New macro.
138247         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
138248         many new variables. Don't set UNISTD_H.
138249         * modules/unistd (Description): Change.
138250         (Depends-on): Add link-warning.
138251         (configure.ac): Update.
138252         (Makefile.am): Create unistd.h always. Substitute many new variables
138253         into it.
138255 2007-02-18  Bruno Haible  <bruno@clisp.org>
138257         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
138258         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
138259         HAVE_GETSUBOPT.
138260         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
138261         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
138262         * lib/getsubopt.h: Remove file.
138263         * modules/getsubopt (Files): Remove lib/getsubopt.h.
138264         (Depends-on): Add stdlib.
138265         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
138266         (Includes): Use <stdlib.h> instead of getsubopt.h.
138267         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
138268         Set HAVE_GETSUBOPT.
138269         * lib/getsubopt.c: Don't include getsubopt.h.
138271 2007-02-18  Bruno Haible  <bruno@clisp.org>
138273         * modules/fchdir (Depends-on): Add dup2.
138275 2007-02-18  Bruno Haible  <bruno@clisp.org>
138277         * lib/stdlib_.h: Handle glibc's special invocation convention
138278         specially.
138280 2007-02-18  Bruno Haible  <bruno@clisp.org>
138282         * modules/stdlib-tests: New file.
138283         * tests/test-stdlib.c: New file.
138285         * modules/mkstemp (Files): Remove lib/mkstemp.h.
138286         (Depends-on): Add stdlib.
138287         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
138288         (Includes): Use <stdlib.h> instead of mkstemp.h.
138289         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
138290         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
138291         * lib/mkstemp.c: Don't include mkstemp.h.
138292         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
138293         * lib/stdlib--.h: Don't include mkstemp.h.
138295         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
138296         (Depends-on): Add stdlib.
138297         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
138298         (Includes): Use <stdlib.h> instead of mkdtemp.h.
138299         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
138300         HAVE_MKDTEMP.
138301         * lib/mkdtemp.c: Don't include mkdtemp.h.
138302         * lib/clean-temp.c: Don't include mkdtemp.h.
138304         * modules/exit (Files): Remove lib/exit.h.
138305         (Depends-on): Add stdlib.
138306         (Makefile.am): Remove lib_SOURCES.
138307         (Include): Use <stdlib.h> instead of exit.h.
138308         * lib/argmatch.c: Don't include exit.h.
138309         * lib/execute.c: Likewise.
138310         * lib/pagealign_alloc.c: Likewise.
138311         * lib/pipe.c: Likewise.
138312         * lib/wait-process.c: Likewise.
138313         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
138314         * lib/exitfail.c: Likewise.
138315         * lib/savewd.c: Likewise.
138316         * lib/xsetenv.c: Likewise.
138318         * modules/stdlib: New file.
138319         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
138320         and extra comments about mkstemp().
138321         * lib/exit.h: Remove file.
138322         * lib/mkdtemp.h: Remove file.
138323         * lib/mkstemp.h: Remove file.
138324         * m4/stdlib_h.m4: New file.
138325         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
138327 2007-02-18  Bruno Haible  <bruno@clisp.org>
138329         * modules/math-tests: New file.
138330         * tests/test-math.c: New file.
138332         * modules/math: New file.
138333         * modules/mathl (Files): Remove lib/mathl.h.
138334         (Depends-on): Add math.
138335         (Makefile.am): Don't mention mathl.h.
138336         (Include): Use <math.h> instead of mathl.h.
138337         * lib/math_.h: New file.
138338         * lib/mathl.h: Remove file.
138339         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
138340         mathl.h.
138341         * lib/asinl.c: Likewise.
138342         * lib/atanl.c: Likewise.
138343         * lib/ceill.c: Likewise.
138344         * lib/cosl.c: Likewise.
138345         * lib/expl.c: Likewise.
138346         * lib/floorl.c: Likewise.
138347         * lib/frexpl.c: Likewise.
138348         * lib/ldexpl.c: Likewise.
138349         * lib/logl.c: Likewise.
138350         * lib/sincosl.c: Likewise.
138351         * lib/sinl.c: Likewise.
138352         * lib/sqrtl.c: Likewise.
138353         * lib/tanl.c: Likewise.
138354         * lib/trigl.c: Likewise.
138355         * m4/math_h.m4: New file.
138356         * MODULES.html.sh (Mathematics): Add math.
138358 2007-02-17  Bruno Haible  <bruno@clisp.org>
138360         * modules/wctype-tests: New file.
138361         * tests/test-wctype.c: New file.
138363         * modules/wchar-tests: New file.
138364         * tests/test-wchar.c: New file.
138366         * modules/unistd-tests: New file.
138367         * tests/test-unistd.c: New file.
138369         * modules/time-tests: New file.
138370         * tests/test-time.c: New file.
138372         * modules/sysexits-tests: New file.
138373         * tests/test-sysexits.c: New file.
138375         * modules/sys_time-tests: New file.
138376         * tests/test-sys_time.c: New file.
138378         * modules/sys_stat-tests: New file.
138379         * tests/test-sys_stat.c: New file.
138381         * modules/sys_socket-tests: New file.
138382         * tests/test-sys_socket.c: New file.
138384         * modules/sys_select-tests: New file.
138385         * tests/test-sys_select.c: New file.
138387         * modules/string-tests: New file.
138388         * tests/test-string.c: New file.
138390         * modules/stdbool-tests: New file.
138391         * tests/test-stdbool.c: New file.
138393         * modules/netinet_in-tests: New file.
138394         * tests/test-netinet_in.c: New file.
138396         * modules/inttypes-tests: New file.
138397         * tests/test-inttypes.c: New file.
138399         * modules/fcntl-tests: New file.
138400         * tests/test-fcntl.c: New file.
138402         * modules/byteswap-tests: New file.
138403         * tests/test-byteswap.c: New file.
138405         * modules/arpa_inet-tests: New file.
138406         * tests/test-arpa_inet.c: New file.
138408 2007-02-17  Bruno Haible  <bruno@clisp.org>
138410         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
138411         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
138412         if the corresponding module is not enabled. Emit link warnings if
138413         the function is used nevertheless.
138414         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
138415         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
138416         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
138417         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
138418         * modules/inttypes (Depends-on): Add link-warning.
138419         (Makefile.am): Copy the contents of build-aux/link-warning.h into
138420         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
138421         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
138422         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
138423         * modules/imaxdiv (configure.ac): Likewise.
138424         * modules/strtoimax (configure.ac): Likewise.
138425         * modules/strtoumax (configure.ac): Likewise.
138427 2007-02-17  Bruno Haible  <bruno@clisp.org>
138429         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
138430         gl_STRING_MODULE_INDICATOR_DEFAULTS.
138431         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
138432         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
138434 2007-02-17  Bruno Haible  <bruno@clisp.org>
138436         * modules/link-warning: New file.
138437         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
138438         * lib/string_.h (GL_LINK_WARNING): Remove definition.
138439         * modules/string (Depends-on): Add link-warning.
138440         (Makefile.am): Copy the contents of build-aux/link-warning.h into
138441         string.h.
138442         * MODULES.html.sh (Support for building libraries and executables): Add
138443         link-warning.
138445 2007-02-17  Bruno Haible  <bruno@clisp.org>
138447         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
138448         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
138449         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
138450         long lines.
138452 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
138453             Bruno Haible  <bruno@clisp.org>
138455         * modules/tmpfile: New file.
138456         * lib/tmpfile.c: New file.
138457         * m4/tmpfile.m4: New file.
138458         * MODULES.html.sh (func_all_modules): New section "Input/output".
138460 2007-02-15  Bruno Haible  <bruno@clisp.org>
138462         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
138463         (supports_delete_on_close): New function.
138464         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
138466 2007-02-14  Bruno Haible  <bruno@clisp.org>
138468         * modules/mbspcasecmp-tests: New file.
138469         * tests/test-mbspcasecmp.sh: New file.
138470         * tests/test-mbspcasecmp.c: New file.
138472         New module mbspcasecmp.
138473         * modules/mbspcasecmp: New file.
138474         * lib/mbspcasecmp.c: New file.
138475         * lib/string_.h (strncasecmp): Change warning message.
138476         (mbspcasecmp): New declaration.
138477         * m4/mbspcasecmp.m4: New file.
138478         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138479         GNULIB_MBSPCASECMP.
138480         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
138481         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
138483 2007-02-14  Bruno Haible  <bruno@clisp.org>
138485         * modules/mbsncasecmp-tests: New file.
138486         * tests/test-mbsncasecmp.sh: New file.
138487         * tests/test-mbsncasecmp.c: New file.
138489         New module mbsncasecmp.
138490         * modules/mbsncasecmp: New file.
138491         * lib/mbsncasecmp.c: New file.
138492         * lib/string_.h (mbsncasecmp): New declaration.
138493         * m4/mbsncasecmp.m4: New file.
138494         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138495         GNULIB_MBSNCASECMP.
138496         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
138497         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
138499 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
138501         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
138502         Verify that it doesn't overlap with our flags.
138503         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
138504         do not have the desired effect in multibyte locales; instead, use
138505         mbscasecmp.
138506         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
138507         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
138508         we don't require GNU fnmatch ourselves (if our users require it, they
138509         should do so explicitly).
138511         Fix regex code so it doesn't rely on strcasecmp.
138512         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
138513         Otherwise, include gnulib's langinfo.h.
138514         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
138515         undesirable behavior in non-C locales.  Instead, rely on localecharset.
138516         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
138517         * modules/regex (FILES): Remove m4/codeset.m4.
138518         (Depends-on): Add localcharset.  Remove strcase.
138520 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
138522         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
138523         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
138525 2007-02-13  Bruno Haible  <bruno@clisp.org>
138527         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
138528         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
138530 2007-02-12  Bruno Haible  <bruno@clisp.org>
138532         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
138533         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
138534         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
138535         time warning rather than a link error.
138537 2007-02-12  Bruno Haible  <bruno@clisp.org>
138539         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
138540         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
138541         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
138543 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
138545         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
138546         args, not 2.
138548 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
138550         New module 'time', so that apps can include <time.h> as per
138551         POSIX and GNU instead of separate include files like time_r.h
138552         and timegm.h.  This implementation tries out a simpler approach
138553         for replacing decls in standard include files (as compared to
138554         the string module), somewhat as an experiment.
138556         * config/srclist.txt: Comment out mktime.c for now.
138557         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
138558         since it doesn't apply any more.  Use generic wording instead.
138559         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
138560         'time'.
138561         * lib/time_.h, m4/time_h.m4, modules/time: New files.
138562         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
138563         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
138564         Don't include <sys/types.h>; no longer needed since we assume C89.
138565         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
138566         * lib/strftime.c: Likewise.
138567         * lib/time_r.c: Likewise.
138568         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
138569         * lib/nanosleep.c: Include <time.h> first, to check interface.
138570         * lib/strptime.c: Likewise.
138571         * lib/time_r.c: Likewise.
138572         * lib/timegm.c: Likewise.
138573         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
138574         needed.
138575         * lib/timegm.c: Don't include timegm.h; no longer needed.
138576         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
138577         time.h now handles any problems in that area.
138578         (struct timespec, nanosleep): Remove; time.h now arranges for these.
138579         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
138580         that time.h defines struct timespec.
138581         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
138582         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
138583         handles that.
138584         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
138585         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
138586         needed.  Set REPLACE_LOCALTIME.
138587         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
138588         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
138589         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
138590         nanosleep; time_h.m4 now does that.  Don't require
138591         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
138592         module handles this now.
138593         * modules/getdate (Depends-on): Remove timespec.  Add time.
138594         * modules/nanosleep (Depends-on): Likewise.
138595         * modules/stat-time (Depends-on): Likewise.
138596         * modules/nanosleep (Include): Include time.h, not timespec.h.
138597         * modules/strptime (Files): Remove lib/strptime.h.
138598         (Depends-on): Add extensions, time.
138599         (Include): Include time.h, not strptime.h.
138600         * modules/time_r (Files): Remove lib/time_r.h.
138601         (Depends-on): Add time.
138602         (Include): Include time.h, not time_r.h.
138603         * modules/timegm: Likewise.
138604         * modules/timespec (Description): Now does timespec-related decls
138605         of our own, instead of struct timespec itself.
138606         (Depends-on): Add time; remove extensions.
138607         (Maintainer): Add self.
138608         * modules/utimecmp (Depends-on): Add time; remove timespec.
138609         * modules/utimens (Depends-on): Likewise.
138610         * modules/xnanosleep (Depends-on): Likewise.
138612 2007-02-11  Bruno Haible  <bruno@clisp.org>
138614         * lib/c-strstr.c: Include allocsa.h.
138615         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
138616         * lib/c-strcasestr.c: Include allocsa.h.
138617         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
138618         * lib/strcasestr.c: Include allocsa.h.
138619         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
138620         * lib/mbsstr.c: Include allocsa.h.
138621         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
138622         allocsa/freesa instead of malloc/free.
138623         * lib/mbscasestr.c: Include allocsa.h.
138624         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
138625         allocsa/freesa instead of malloc/free.
138626         * modules/c-strstr (Depends-on): Add allocsa.
138627         * modules/c-strcasestr (Depends-on): Likewise.
138628         * modules/strcasestr (Depends-on): Likewise.
138629         * modules/mbsstr (Depends-on): Likewise.
138630         * modules/mbscasestr (Depends-on): Likewise.
138632 2007-02-11  Bruno Haible  <bruno@clisp.org>
138634         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
138636         * modules/mbsspn-tests: New file.
138637         * tests/test-mbsspn.sh: New file.
138638         * tests/test-mbsspn.c: New file.
138640 2007-02-11  Bruno Haible  <bruno@clisp.org>
138642         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
138644         * modules/mbspbrk-tests: New file.
138645         * tests/test-mbspbrk.sh: New file.
138646         * tests/test-mbspbrk.c: New file.
138648 2007-02-11  Bruno Haible  <bruno@clisp.org>
138650         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
138651         unneeded cast.
138653         * modules/mbscspn-tests: New file.
138654         * tests/test-mbscspn.sh: New file.
138655         * tests/test-mbscspn.c: New file.
138657 2007-02-11  Bruno Haible  <bruno@clisp.org>
138659         * modules/mbscasecmp-tests: New file.
138660         * tests/test-mbscasecmp.sh: New file.
138661         * tests/test-mbscasecmp.c: New file.
138663 2007-02-11  Bruno Haible  <bruno@clisp.org>
138665         Ensure O(n) worst-case complexity of mbscasestr.
138666         * lib/mbscasestr.c: Include stdbool.h.
138667         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
138668         functions.
138669         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
138670         the bookkeeping indicates that it's worth it.
138671         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
138673         * modules/mbscasestr-tests: New file.
138674         * tests/test-mbscasestr1.c: New file.
138675         * tests/test-mbscasestr2.sh: New file.
138676         * tests/test-mbscasestr2.c: New file.
138677         * tests/test-mbscasestr3.sh: New file.
138678         * tests/test-mbscasestr3.c: New file.
138679         * tests/test-mbscasestr4.sh: New file.
138680         * tests/test-mbscasestr4.c: New file.
138681         * m4/locale-tr.m4: New file.
138683 2007-02-11  Bruno Haible  <bruno@clisp.org>
138685         Ensure O(n) worst-case complexity of mbsstr.
138686         * lib/mbsstr.c: Include stdbool.h.
138687         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
138688         functions.
138689         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
138690         bookkeeping indicates that it's worth it.
138691         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
138693         * modules/mbsstr-tests: New file.
138694         * tests/test-mbsstr1.c: New file.
138695         * tests/test-mbsstr2.sh: New file.
138696         * tests/test-mbsstr2.c: New file.
138697         * tests/test-mbsstr3.sh: New file.
138698         * tests/test-mbsstr3.c: New file.
138699         * m4/locale-fr.m4: New file.
138701 2007-02-11  Bruno Haible  <bruno@clisp.org>
138703         * lib/mbsrchr.c (mbsrchr): Fix bug.
138705         * modules/mbsrchr-tests: New file.
138706         * tests/test-mbsrchr.sh: New file.
138707         * tests/test-mbsrchr.c: New file.
138709 2007-02-11  Bruno Haible  <bruno@clisp.org>
138711         * lib/mbschr.c (mbschr): Fix bug.
138713         * modules/mbschr-tests: New file.
138714         * tests/test-mbschr.sh: New file.
138715         * tests/test-mbschr.c: New file.
138716         * m4/locale-zh.m4: New file.
138718 2007-02-11  Bruno Haible  <bruno@clisp.org>
138720         Support for copying multibyte string iterators.
138721         * lib/mbiter.h: Include <string.h>.
138722         (mbiter_multi_copy): New function.
138723         (mbi_copy): New macro.
138724         * lib/mbuiter.h: Include <string.h>.
138725         (mbuiter_multi_copy): New function.
138726         (mbui_copy): New macro.
138728 2007-02-11  Bruno Haible  <bruno@clisp.org>
138730         New module mbslen.
138731         * modules/mbslen: New file.
138732         * lib/mbslen.c: New file.
138733         * lib/string_.h (mbslen): New declaration.
138734         * m4/mbslen.m4: New file.
138735         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138736         GNULIB_MBSLEN.
138737         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
138738         * MODULES.html.sh (Internationalization functions): Add mbslen.
138740 2007-02-11  Bruno Haible  <bruno@clisp.org>
138742         Ensure O(n) worst-case complexity of strcasestr substitute.
138743         * lib/strcasestr.c: Include stdbool.h.
138744         (knuth_morris_pratt): New function.
138745         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
138746         bookkeeping indicates that it's worth it.
138747         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
138749         * modules/strcasestr-tests: New file.
138750         * tests/test-strcasestr.c: New file.
138752 2007-02-11  Bruno Haible  <bruno@clisp.org>
138754         Ensure O(n) worst-case complexity of c_strcasestr.
138755         * lib/c-strcasestr.c: Include stdbool.h, string.h.
138756         (knuth_morris_pratt): New function.
138757         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
138758         the bookkeeping indicates that it's worth it.
138759         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
138761         * modules/c-strcasestr-tests: New file.
138762         * tests/test-c-strcasestr.c: New file.
138764 2007-02-11  Bruno Haible  <bruno@clisp.org>
138766         Ensure O(n) worst-case complexity of c_strstr.
138767         * lib/c-strstr.c: Include stdbool.h, string.h.
138768         (knuth_morris_pratt): New function.
138769         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
138770         bookkeeping indicates that it's worth it.
138771         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
138773         * lib/c-strstr.c: Complete rewrite for maintainability.
138775         * modules/c-strstr-tests: New file.
138776         * tests/test-c-strstr.c: New file.
138778 2007-02-11  Bruno Haible  <bruno@clisp.org>
138780         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
138781         5.2.1 and earlier, whereby \055 was treated just like the range
138782         delimiter '-'.
138783         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
138785 2007-02-08  Bruno Haible  <bruno@clisp.org>
138787         * modules/regex (Depends-on): Add stdbool.
138788         Reported by Dalibor Topic <robilad@kaffe.org>.
138790 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
138792         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
138793         Prefer returning from main to exiting from it.
138794         Remove unnecessary parens after sizeof.
138796 2007-02-05  Bruno Haible  <bruno@clisp.org>
138798         New module mbssep.
138799         * modules/mbssep: New file.
138800         * lib/mbssep.c: New file.
138801         * lib/string_.h (strsep): Add a conditional link warning.
138802         (mbssep): New declaration.
138803         * m4/mbssep.m4: New file.
138804         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138805         GNULIB_MBSSEP.
138806         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
138807         * MODULES.html.sh (Internationalization functions): Add mbssep.
138809 2007-02-05  Bruno Haible  <bruno@clisp.org>
138811         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
138812         Optimize search in case of 1 delimiter.
138814 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
138816         * lib/acl.h: Include sys/types.h before sys/acl.h.
138818 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
138820         Merge upstream fix for glibc bugzilla #3957:
138822         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
138824         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
138825         bit for RE_HAT_LISTS_NOT_NEWLINE.
138826         (build_charclass_op): Remove bogus comment.
138828 2007-02-05  Simon Josefsson  <simon@josefsson.org>
138830         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
138832 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
138834         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
138835         * lib/memmem.c [!defined _LIBC]: Include config.h.
138837 2007-02-04  Bruno Haible  <bruno@clisp.org>
138839         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
138840         warning message.
138842 2007-02-04  Bruno Haible  <bruno@clisp.org>
138844         New module mbstok_r.
138845         * modules/mbstok_r: New file.
138846         * lib/mbstok_r.c: New file.
138847         * lib/string_.h (strtok_r): Change argument names to match the
138848         comments. Add a conditional link warning.
138849         (mbstok_r): New declaration.
138850         * m4/mbstok_r.m4: New file.
138851         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138852         GNULIB_MBSTOK_R.
138853         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
138854         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
138856 2007-02-04  Bruno Haible  <bruno@clisp.org>
138858         New module mbsspn.
138859         * modules/mbsspn: New file.
138860         * lib/mbsspn.c: New file.
138861         * lib/string_.h (strspn): Add a conditional link warning.
138862         (mbsspn): New declaration.
138863         * m4/mbsspn.m4: New file.
138864         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138865         GNULIB_MBSSPN.
138866         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
138867         * MODULES.html.sh (Internationalization functions): Add mbsspn.
138869 2007-02-04  Bruno Haible  <bruno@clisp.org>
138871         New module mbspbrk.
138872         * modules/mbspbrk: New file.
138873         * lib/mbspbrk.c: New file.
138874         * lib/string_.h (strpbrk): Add a conditional link warning.
138875         (mbspbrk): New declaration.
138876         * m4/mbspbrk.m4: New file.
138877         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138878         GNULIB_MBSPBRK.
138879         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
138880         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
138882 2007-02-04  Bruno Haible  <bruno@clisp.org>
138884         New module mbscspn.
138885         * modules/mbscspn: New file.
138886         * lib/mbscspn.c: New file.
138887         * lib/string_.h (strcspn): Add a conditional link warning.
138888         (mbscspn): New declaration.
138889         * m4/mbscspn.m4: New file.
138890         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138891         GNULIB_MBSCSPN.
138892         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
138893         * MODULES.html.sh (Internationalization functions): Add mbscspn.
138895 2007-02-04  Bruno Haible  <bruno@clisp.org>
138897         New module mbscasestr, reduced goal of strcasestr.
138898         * modules/mbscasestr: New file.
138899         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
138900         (mbscasestr): Renamed from strcasestr.
138901         * lib/strcasestr.c: Don't include mbuiter.h.
138902         (strcasestr): Remove support for multibyte locales.
138903         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
138904         Change the conditional link warning.
138905         (mbscasestr): New declaration.
138906         * m4/mbscasestr.m4: New file.
138907         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
138908         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
138909         REPLACE_STRCASESTR.
138910         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
138911         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
138912         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
138913         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
138914         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
138915         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
138916         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
138917         (Depends-on): Remove mbuiter.
138918         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
138920 2007-02-04  Bruno Haible  <bruno@clisp.org>
138922         Simplify handling of strncasecmp.
138923         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
138924         the conditional link warning.
138925         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
138926         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
138927         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
138928         * modules/strcase (configure.ac): Don't invoke
138929         gl_STRING_MODULE_INDICATOR.
138930         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
138932 2007-02-04  Bruno Haible  <bruno@clisp.org>
138934         New module mbscasecmp, reduced goal of strcasecmp.
138935         * modules/mbscasecmp: New file.
138936         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
138937         (mbscasecmp): Renamed from strcasecmp.
138938         * lib/strcasecmp.c: Don't include mbuiter.h.
138939         (strcasecmp): Remove support for multibyte locales.
138940         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
138941         Change the conditional link warning.
138942         (mbscasecmp): New declaration.
138943         * m4/mbscasecmp.m4: New file.
138944         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
138945         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
138946         REPLACE_STRCASECMP.
138947         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
138948         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138949         GNULIB_MBSCASECMP.
138950         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
138951         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
138952         * modules/strcase (Files): Remove m4/mbrtowc.m4.
138953         (Depends-on): Remove mbuiter.
138954         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
138956 2007-02-04  Bruno Haible  <bruno@clisp.org>
138958         New module mbsstr. Remove module strstr.
138959         * modules/mbsstr: New file.
138960         * modules/strstr: Remove file.
138961         * lib/mbsstr.c: Renamed from lib/strstr.c.
138962         (mbsstr): Renamed from strstr.
138963         * lib/string_.h (strstr): Remove declaration. Change the conditional
138964         link warning.
138965         (mbsstr): New declaration.
138966         * m4/mbsstr.m4: New file.
138967         * m4/strstr.m4: Remove file.
138968         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
138969         REPLACE_STRSTR.
138970         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
138971         Don't initialize GNULIB_STRSTR.
138972         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
138973         substitute GNULIB_STRSTR and REPLACE_STRSTR.
138974         * MODULES.html.sh (Internationalization functions): Add mbsstr.
138975         (Support for systems lacking ANSI C 89): Remove strstr.
138977 2007-02-04  Bruno Haible  <bruno@clisp.org>
138979         New module mbsrchr.
138980         * modules/mbsrchr: New file.
138981         * lib/mbsrchr.c: New file.
138982         * lib/string_.h (strrchr): Add a conditional link warning.
138983         (mbsrchr): New declaration.
138984         * m4/mbsrchr.m4: New file.
138985         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138986         GNULIB_MBSRCHR.
138987         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
138988         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
138990 2007-02-04  Bruno Haible  <bruno@clisp.org>
138992         New module mbschr.
138993         * modules/mbschr: New file.
138994         * lib/mbschr.c: New file.
138995         * lib/string_.h (strchr): Add a conditional link warning.
138996         (mbschr): New declaration.
138997         * m4/mbschr.m4: New file.
138998         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
138999         GNULIB_MBSCHR.
139000         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
139001         * MODULES.html.sh (Internationalization functions): Add mbschr.
139003 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
139005         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
139007         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
139009 2007-02-04  Bruno Haible  <bruno@clisp.org>
139011         New module description section 'configure.ac-early'.
139012         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
139013         (func_get_autoconf_early_snippet): New function.
139014         (func_import, func_create_testdir): Use it. Remove special cases for
139015         modules 'extensions' and 'lock'.
139016         * modules/extensions (configure.ac-early): Require
139017         gl_USE_SYSTEM_EXTENSIONS.
139018         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
139020 2007-02-04  Bruno Haible  <bruno@clisp.org>
139022         Make use of gcj-4.3's -fsource and -ftarget option.
139023         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
139024         and if so try the options -fsource and -ftarget.
139025         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
139026         source_version, ftarget_option, target_version arguments.
139027         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
139028         (is_envjavac_oldgcj_14_14_usable): Renamed from
139029         is_envjavac_gcj_14_14_usable.
139030         (is_envjavac_oldgcj_14_13_usable): Renamed from
139031         is_envjavac_gcj_14_13_usable.
139032         (is_gcj_present): Update.
139033         (is_gcj_43, is_gcj43_usable): New functions.
139034         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
139035         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
139036         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
139037         try the options -fsource and -ftarget.
139039 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
139041         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
139042         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
139043         larger value.
139045 2007-02-03  Jim Meyering  <jim@meyering.net>
139047         Give tools a better chance to allocate space for very large buffers.
139048         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
139050         Make pwd and readlink work also when run with an unreadable parent dir
139051         on systems with openat support.
139052         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
139053         provided getcwd function, even when we have openat support.
139054         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
139056 2007-02-02  Bruno Haible  <bruno@clisp.org>
139058         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
139059         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
139060         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
139061         portability problems if one of these functions is only used on specific
139062         platforms.
139063         Reported by Paul Eggert.
139065 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
139067         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
139068         is causing more trouble than it's curing.
139069         * lib/regex_internal.h (__mempcpy): Remove.
139070         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
139071         (and make the code a tad smaller to boot).
139072         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
139074 2007-02-02  Jim Meyering  <jim@meyering.net>
139076         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
139077         section, not in the Makefile.am: one.
139079 2007-02-02  Eric Blake  <ebb9@byu.net>
139081         * lib/strchrnul.c: Always include config.h first.
139083         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
139084         gnulib strstr is not necessary here.
139086 2007-02-02  Simon Josefsson  <simon@josefsson.org>
139088         * m4/socklen.m4: Fix typo.
139090 2007-02-02  Eric Blake  <ebb9@byu.net>
139092         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
139093         * modules/netinet_in (Makefile.am): Likewise.
139095 2007-02-01  Bruno Haible  <bruno@clisp.org>
139097         * lib/string_.h (GL_LINK_WARNING): New macro.
139098         (strcasecmp, strstr, strcasestr): If provided by the system,
139099         conditionally define as a macro that leads to a warning instead of to
139100         an error.
139101         (strncasecmp): Conditionally define as a macro that leads to a warning.
139103 2007-02-01  Karl Berry  <karl@gnu.org>
139105         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
139107 2007-02-01  Bruno Haible  <bruno@clisp.org>
139109         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
139110         renamings.
139112 2007-02-01  Eric Blake  <ebb9@byu.net>
139114         * modules/regex (Depends-on): Revert dependence on mempcpy.
139115         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
139116         module's definition of mempcpy.
139117         Reported by Paul Eggert.
139119 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
139121         * lib/string_.h: If the gnulib module XYZ is not present, undefine
139122         the symbol XYZ before redefining it.  This fixes a problem with
139123         programs that don't use XYZ, when compiled on systems that define
139124         XYZ to something else.
139126 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
139128         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
139129         occurs when "mkdir -m foo" creates a setgid directory that is (1)
139130         writeable to group or other and (2) is intended to have a special
139131         mode bit that is set or cleared.  In such a case, the directory
139132         should be neither group- nor other-writeable until the special
139133         mode bits are right.
139135 2007-01-31  Eric Blake  <ebb9@byu.net>
139137         * modules/mountlist (Depends-on): Add strstr.
139139         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
139140         bug.
139141         * modules/string (Makefile.am): Remove redundant replacement.
139142         * modules/regex (Depends-on): Add mempcpy.
139144 2007-01-31  Bruno Haible  <bruno@clisp.org>
139146         New module description field 'Link'.
139147         * gnulib-tool (func_usage): Document --extract-link-directive.
139148         (sed_extract_prog): Recognize 'Link' directive.
139149         (func_get_link_directive): New function.
139150         (func_import): Show summary of link directives.
139151         Handle --extract-link-directive option.
139152         * modules/acl (Link): New section.
139153         * modules/clock-time (Link): New section.
139154         * modules/euidaccess (Link): New section.
139155         * modules/gettext (Link): New section.
139156         * modules/iconv (Link): New section.
139157         * modules/lock (Link): New section.
139158         * modules/nanosleep (Link): New section.
139159         * modules/readline (Link): New section.
139161 2007-01-27  Bruno Haible  <bruno@clisp.org>
139163         Enforce the use of gnulib modules for unportable <string.h> functions.
139164         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
139165         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
139166         (gl_HEADER_STRING_H_BODY): Require it.
139167         * lib/string_.h: If the gnulib module XYZ is not present, redefine
139168         the symbol XYZ to one that gives a link error.
139169         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
139170         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
139171         * modules/mempcpy (configure.ac): Likewise.
139172         * modules/memrchr (configure.ac): Likewise.
139173         * modules/stpcpy (configure.ac): Likewise.
139174         * modules/stpncpy (configure.ac): Likewise.
139175         * modules/strcase (configure.ac): Likewise.
139176         * modules/strcasestr (configure.ac): Likewise.
139177         * modules/strchrnul (configure.ac): Likewise.
139178         * modules/strdup (configure.ac): Likewise.
139179         * modules/strndup (configure.ac): Likewise.
139180         * modules/strnlen (configure.ac): Likewise.
139181         * modules/strpbrk (configure.ac): Likewise.
139182         * modules/strsep (configure.ac): Likewise.
139183         * modules/strstr (configure.ac): Likewise.
139184         * modules/strtok_r (configure.ac): Likewise.
139186 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
139188         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
139190 2007-01-30  Jim Meyering  <jim@meyering.net>
139192         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
139194 2007-01-29  Bruno Haible  <bruno@clisp.org>
139196         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
139197         * lib/execute.c: Likewise.
139198         * lib/pipe.c: Likewise.
139199         * lib/printf-args.h: Likewise.
139200         * lib/printf-args.c: Likewise.
139201         * lib/printf-parse.c: Likewise.
139202         * lib/vasnprintf.c: Likewise.
139204 2007-01-29  Eric Blake  <ebb9@byu.net>
139206         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
139207         declaration.
139209 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
139211         * lib/strptime.h (strptime): Use 'restrict' for args where
139212         POSIX requires this.
139213         * lib/strptime.c (strptime): Likewise.
139214         Change license notice from LGPL to GPL, since gnulib-tool will
139215         change this as needed.
139216         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
139217         defined.
139218         Include "strptime.h" first, to check interface.
139219         Do not #undef _LIBC and _NL_CURRENT.
139220         Do not include <stdlib.h>; no longer needed.
139221         Include "time_r.h" and declare ptime_locale_status
139222         only if _LIBC is not defined.
139223         (__P): Remove unused macro.
139224         (match_string): Bring back glibc version, but use it only if _LIBC
139225         is defined.
139226         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
139227         Remove unnecessary assertion and abort() call.
139228         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
139229         * m4/strptime.m4: Fix serial number comment.
139230         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
139231         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
139232         (Depends-on): Add time_r.
139234 2007-01-29  Bruno Haible  <bruno@clisp.org>
139236         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
139237         strptime.
139238         * modules/strptime (Depends-on): Add stdbool.
139239         * lib/strptime.h: Include <time.h> always. Add comments.
139241 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
139243         * modules/strptime: New file.
139244         * lib/strptime.h: New file.
139245         * lib/strptime.c: New file.
139246         * m4/strptime.m4: New file.
139248 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
139250         * MODULES.html.sh: New module mpsort.
139251         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
139253         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
139254         a circularity problem with HP-UX ia64 reported by Bob Proulx in
139255         <http://lists.gnu.org/r/bug-gnulib/2007-01/msg00394.html>.
139256         All uses changed.
139257         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
139258         All uses changed.
139259         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
139260         to _Restrict_.
139261         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
139262         the parameter matches the prototype.
139264 2007-01-28  Jim Meyering  <jim@meyering.net>
139266         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
139267         sys/time.h here, reverting that part of the previous patch:
139268         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
139270 2007-01-28  Bruno Haible  <bruno@clisp.org>
139272         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
139273         value of $(SYS_TIME_H).
139274         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
139275         remove it conditionally, too. [added by Jim Meyering]
139276         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
139277         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
139278         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
139279         GETTIMEOFDAY_REPLACEMENT to 1.
139281 2007-01-28  Bruno Haible  <bruno@clisp.org>
139283         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
139284         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
139285         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
139286         Set UNISTD_H instead of UNISTD_H2.
139287         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
139289 2007-01-28  Bruno Haible  <bruno@clisp.org>
139291         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
139292         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
139294 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139296         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
139297         (func_create_testdir): Ensure C locale for `grep' and `tr'
139298         character ranges.
139299         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
139300         ACLOCAL_AMFLAGS parsing state machine.
139302 2007-01-27  Bruno Haible  <bruno@clisp.org>
139304         * modules/unistr/base: Update.
139306 2007-01-27  Bruno Haible  <bruno@clisp.org>
139308         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
139309         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
139310         * modules/unistr/u32-mbtouc-unsafe: Renamed from
139311         modules/unistr/u32-mbtouc.
139312         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
139313         * lib/unistr.h: Update.
139314         * lib/linebreak.c: Update.
139315         * modules/unistr/u32-mbtouc: Renamed from
139316         modules/unistr/u32-mbtouc-safe.
139317         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
139318         * lib/unistr.h: Update.
139319         * lib/unistr/u32-to-u8.c: Update.
139320         * lib/unistr/u32-to-u16.c: Update.
139322 2007-01-27  Bruno Haible  <bruno@clisp.org>
139324         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
139325         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
139326         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
139327         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
139328         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
139329         * modules/unistr/u16-mbtouc-unsafe: Renamed from
139330         modules/unistr/u16-mbtouc.
139331         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
139332         * lib/unistr.h: Update.
139333         * lib/linebreak.c: Update.
139334         * modules/linebreak: Update.
139335         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
139336         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
139337         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
139338         * modules/unistr/u16-mbtouc: Renamed from
139339         modules/unistr/u16-mbtouc-safe.
139340         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
139341         * lib/unistr.h: Update.
139342         * lib/unistr/u16-to-u8.c: Update.
139343         * modules/unistr/u16-to-u8: Update.
139344         * lib/unistr/u16-to-u32.c: Update.
139345         * modules/unistr/u16-to-u32: Update.
139347 2007-01-27  Bruno Haible  <bruno@clisp.org>
139349         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
139350         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
139351         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
139352         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
139353         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
139354         * modules/unistr/u8-mbtouc-unsafe: Renamed from
139355         modules/unistr/u8-mbtouc.
139356         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
139357         * lib/unistr.h: Update.
139358         * lib/striconveh.c: Update.
139359         * modules/striconveh: Update.
139360         * lib/linebreak.c: Update.
139361         * modules/linebreak: Update.
139362         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
139363         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
139364         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
139365         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
139366         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
139367         * lib/unistr.h: Update.
139368         * lib/striconveh.c: Update.
139369         * modules/striconveh: Update.
139370         * lib/unistr/u8-to-u16.c: Update.
139371         * modules/unistr/u8-to-u16: Update.
139372         * lib/unistr/u8-to-u32.c: Update.
139373         * modules/unistr/u8-to-u32: Update.
139375 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139377         Sync from Libtool.
139378         * lib/argz.c: Do not include strings.h nor memory.h, include
139379         string.h unconditionally.  Patch by Simon Josefsson.
139381 2007-01-27  Bruno Haible  <bruno@clisp.org>
139383         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
139384         from gl_HEADER_STRING_H_BODY.
139385         (gl_HEADER_STRING_H_BODY): Require it.
139386         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
139387         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
139388         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
139389         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
139390         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
139391         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
139392         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
139393         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
139394         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
139395         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
139396         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
139397         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
139398         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
139399         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
139400         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
139402 2007-01-27  Bruno Haible  <bruno@clisp.org>
139404         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
139405         check_PROGRAMS into noinst_PROGRAMS.
139406         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
139407         check_PROGRAMS in this case.
139408         (func_import): Set for_test to false.
139409         (func_create_testdir): Set for_test to true.
139411 2007-01-27  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
139412             Bruno Haible  <bruno@clisp.org>
139414         * modules/strcasestr (Files): Remove lib/strcasestr.h.
139415         (Depends-on): Add string.
139416         (Includes): Use <string.h> instead of strcasestr.h.
139417         * modules/string (Makefile.am): Also substitute the value of
139418         REPLACE_STRCASESTR.
139419         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
139420         assume strcasestr is declared in <string.h> not <strings.h>. Also
139421         set REPLACE_STRCASESTR.
139422         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
139423         REPLACE_STRCASESTR.
139424         * lib/strcasestr.h: Remove file.
139425         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
139426         * lib/string_.h (strcasestr): New declaration.
139428 2007-01-27  Bruno Haible  <bruno@clisp.org>
139430         * lib/string_.h: Use 'extern'.
139432 2007-01-27  Jim Meyering  <jim@meyering.net>
139434         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
139435         of set-but-not-used local, "q".
139437         * lib/mempcpy.c: Include <config.h> before <string.h>.
139438         This fixes a compilation error on HP-UX, due to the system's
139439         "restrict"-using mempcpy prototype.
139441 2007-01-26  Bruno Haible  <bruno@clisp.org>
139443         Small optimization.
139444         * lib/javacomp.c: Include c-strstr.h.
139445          (is_envjavac_gcj): Use c_strstr instead of strstr.
139446         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
139448 2007-01-26  Bruno Haible  <bruno@clisp.org>
139450         * MODULES.html.sh (Unicode string functions): Add the new modules.
139452         * modules/uniconv/u32-strconv-to-locale: New file.
139453         * lib/uniconv/u32-strconv-to-locale.c: New file.
139455         * modules/uniconv/u16-strconv-to-locale: New file.
139456         * lib/uniconv/u16-strconv-to-locale.c: New file.
139458         * modules/uniconv/u8-strconv-to-locale: New file.
139459         * lib/uniconv/u8-strconv-to-locale.c: New file.
139461         * modules/uniconv/u32-strconv-from-locale: New file.
139462         * lib/uniconv/u32-strconv-from-locale.c: New file.
139464         * modules/uniconv/u16-strconv-from-locale: New file.
139465         * lib/uniconv/u16-strconv-from-locale.c: New file.
139467         * modules/uniconv/u8-strconv-from-locale: New file.
139468         * lib/uniconv/u8-strconv-from-locale.c: New file.
139470         * modules/uniconv/u32-strconv-to-enc: New file.
139471         * lib/uniconv/u32-strconv-to-enc.c: New file.
139472         * modules/uniconv/u32-strconv-to-enc-tests: New file.
139473         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
139475         * modules/uniconv/u16-strconv-to-enc: New file.
139476         * lib/uniconv/u16-strconv-to-enc.c: New file.
139477         * lib/uniconv/u-strconv-to-enc.h: New file.
139478         * modules/uniconv/u16-strconv-to-enc-tests: New file.
139479         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
139481         * modules/uniconv/u8-strconv-to-enc: New file.
139482         * lib/uniconv/u8-strconv-to-enc.c: New file.
139483         * modules/uniconv/u8-strconv-to-enc-tests: New file.
139484         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
139486         * modules/uniconv/u32-strconv-from-enc: New file.
139487         * lib/uniconv/u32-strconv-from-enc.c: New file.
139488         * modules/uniconv/u32-strconv-from-enc-tests: New file.
139489         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
139491         * modules/uniconv/u16-strconv-from-enc: New file.
139492         * lib/uniconv/u16-strconv-from-enc.c: New file.
139493         * modules/uniconv/u16-strconv-from-enc-tests: New file.
139494         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
139496         * modules/uniconv/u8-strconv-from-enc: New file.
139497         * lib/uniconv/u8-strconv-from-enc.c: New file.
139498         * lib/uniconv/u-strconv-from-enc.h: New file.
139499         * modules/uniconv/u8-strconv-from-enc-tests: New file.
139500         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
139502         * modules/uniconv/u32-conv-from-enc: New file.
139503         * lib/uniconv/u32-conv-from-enc.c: New file.
139504         * modules/uniconv/u32-conv-from-enc-tests: New file.
139505         * tests/uniconv/test-u32-conv-from-enc.c: New file.
139507         * modules/uniconv/u16-conv-from-enc: New file.
139508         * lib/uniconv/u16-conv-from-enc.c: New file.
139509         * lib/uniconv/u-conv-from-enc.h: New file.
139510         * modules/uniconv/u16-conv-from-enc-tests: New file.
139511         * tests/uniconv/test-u16-conv-from-enc.c: New file.
139513         * modules/uniconv/u8-conv-from-enc: New file.
139514         * lib/uniconv/u8-conv-from-enc.c: New file.
139515         * modules/uniconv/u8-conv-from-enc-tests: New file.
139516         * tests/uniconv/test-u8-conv-from-enc.c: New file.
139518         * modules/uniconv/base: New file.
139519         * lib/uniconv.h: New file.
139521 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
139523         * doc/gnulib-tool.texi (Initial import): Update to match current
139524         behavior with strdup module.
139525         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
139526         * lib/memmem.h: Remove; all uses removed.  This is now done
139527         by <string.h>.
139528         * lib/mempcpy.h: Likewise.
139529         * lib/memrchr.h: Likewise.
139530         * lib/stpcpy.h: Likewise.
139531         * lib/stpncpy.h: Likewise.
139532         * lib/strcase.h: Likewise.
139533         * lib/strchrnul.h: Likewise.
139534         * lib/strdup.h: Likewise.
139535         * lib/strndup.h: Likewise.
139536         * lib/strnlen.h: Likewise.
139537         * lib/strpbrk.h: Likewise.
139538         * lib/strsep.h: Likewise.
139539         * lib/strstr.h: Likewise.
139540         * lib/strtok_r.h: Likewise.
139541         * lib/string_.h: New file.
139542         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
139543         Rely on <string.h> instead.
139544         * lib/canon-host.c: Likewise.
139545         * lib/chdir-long.c: Likewise.
139546         * lib/concatpath.c: Likewise.
139547         * lib/exclude.c: Likewise.
139548         * lib/fchdir.c: Likewise.
139549         * lib/getaddrinfo.c: Likewise.
139550         * lib/getcwd.c: Likewise.
139551         * lib/getsubopt.c: Likewise.
139552         * lib/glob.c: Likewise.
139553         * lib/hard-locale.c: Likewise.
139554         * lib/iconvme.c: Likewise.
139555         * lib/javacomp.c: Likewise.
139556         * lib/mempcpy.c: Likewise.
139557         * lib/memrchr.c: Likewise.
139558         * lib/regex_internal.h: Likewise.
139559         * lib/stpncpy.c: Likewise.
139560         * lib/strcasecmp.c: Likewise.
139561         * lib/strchrnul.c: Likewise.
139562         * lib/strdup.c: Likewise.
139563         * lib/striconv.c: Likewise.
139564         * lib/striconveh.c: Likewise.
139565         * lib/striconveha.c: Likewise.
139566         * lib/strncasecmp.c: Likewise.
139567         * lib/strndup.c: Likewise.
139568         * lib/strnlen.c: Likewise.
139569         * lib/strsep.c: Likewise.
139570         * lib/strstr.c: Likewise.
139571         * lib/strtok_r.c: Likewise.
139572         * lib/userspec.c: Likewise.
139573         * lib/w32spawn.h: Likewise.
139574         * lib/xstrndup.c: Likewise.
139575         * lib/mountlist.c (strstr): Remove decl.
139576         * m4/string_h.m4: New file.
139577         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
139578         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
139579         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
139580         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
139581         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
139582         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
139583         Set REPLACE_STRCASECMP if necessary.
139584         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
139585         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
139586         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
139587         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
139588         HAVE_DECL_STRDUP if necessary.
139589         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
139590         since gl_FUNC_STRNDUP does that now.
139591         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
139592         Check for decl here...
139593         (gl_PREREQ_STRNLEN): ... not here.
139594         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
139595         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
139596         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
139597         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
139598         necessary.
139599         * modules/string: New file.
139600         * modules/memmem (Files): Remove special-purpose include file.
139601         (Depends-on): Add string.
139602         (Include): Include <string.h>, not the removed file.
139603         * modules/mempcpy: Likewise.
139604         * modules/memrchr: Likewise.
139605         * modules/stpcpy: Likewise.
139606         * modules/stpncpy: Likewise.
139607         * modules/strcase: Likewise.
139608         * modules/strchrnul: Likewise.
139609         * modules/strdup: Likewise.
139610         * modules/strndup: Likewise.
139611         * modules/strnlen: Likewise.
139612         * modules/strpbrk: Likewise.
139613         * modules/strsep: Likewise.
139614         * modules/strstr: Likewise.
139615         * modules/strtok_r: Likewise.
139616         * tests/test-dirname.c: Don't include "strdup.h", since
139617         <string.h> now suffices.
139618         * tests/test-memmem.c: Don't include "memmem.h", since
139619         <string.h> now suffices.
139621 2007-01-25  Bruno Haible  <bruno@clisp.org>
139623         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
139624         *resultp is 0.
139626         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
139627         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
139628         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
139629         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
139631         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
139632         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
139633         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
139634         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
139635         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
139636         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
139638 2007-01-24  Bruno Haible  <bruno@clisp.org>
139640         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
139641         <http://lists.gnu.org/r/bug-gnulib/2006-10/msg00279.html>.
139642         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
139643         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
139644         gl_FUNC_FTS_CORE.
139645         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
139646         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
139647         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
139648         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
139649         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
139650         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
139651         gl_FUNC_FCHOWNAT.
139652         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
139653         gl_FUNC_STRFTIME.
139654         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
139655         Reported by Ralf Wildenhues.
139657 2007-01-24  Bruno Haible  <bruno@clisp.org>
139659         Drop AC_REQUIRE calls that are redundant with the module dependencies.
139660         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
139661         gl_GETADDRINFO.
139662         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
139663         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
139664         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
139666 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
139668         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
139669         Don't use 'exit'; just return from 'main'.
139670         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
139672         * lib/fnmatch_.h: Readjust white space and comments to match
139673         glibc, to avoid spurious diffs.
139675 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
139677         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
139678         2004-12-01 change by Jakub Jelinek, since this code won't compile
139679         if !LIBC.  Problem reported by Bob Proulx.
139681 2007-01-23  Bruno Haible  <bruno@clisp.org>
139683         * lib/striconveh.c: Include c-strcaseeq.h.
139684         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
139685         * modules/striconveh (Depends-on): Add c-strcaseeq.
139687 2007-01-23  Bruno Haible  <bruno@clisp.org>
139689         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
139691         * modules/c-strcaseeq: New file.
139692         * lib/c-strcaseeq.h: New file.
139694         * modules/streq: New file.
139695         * lib/streq.h: New file.
139697 2007-01-23  Bruno Haible  <bruno@clisp.org>
139699         * modules/striconveha-tests: New file.
139700         * tests/test-striconveha.c: New file.
139702         * lib/striconveha.h: Include <stdbool.h>.
139703         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
139704         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
139705         (mem_iconveha_notranslit): Renamed from mem_iconveha.
139706         (mem_iconveha): New function.
139707         (str_iconveha_notranslit): Renamed from str_iconveha.
139708         (str_iconveha): New function.
139709         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
139710         c-strcase.
139712 2007-01-23  Bruno Haible  <bruno@clisp.org>
139714         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
139715         encodings without forgiving before trying any encoding with handler.
139716         (str_iconveha): Try all encodings without forgiving before trying any
139717         encoding with handler.
139719 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
139721         Import the following changes from libc.
139723         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
139725         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
139727         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
139729         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
139730         normal_bracket label.
139732         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
139734         [BZ #361]
139735         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
139736         to normal_bracket after fetching the next character.
139738 2007-01-22  Bruno Haible  <bruno@clisp.org>
139740         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
139741         argument.
139742         * lib/striconveh.c (iconv_carefully_1): New function.
139743         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
139744         argument.
139745         (str_cd_iconveh): Update.
139746         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
139747         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
139748         * tests/test-striconveh.c (MAGIC): New macro.
139749         (new_offsets): New function.
139750         (main): Test call with and without offsets.
139752 2007-01-22  Bruno Haible  <bruno@clisp.org>
139754         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
139755         * modules/sys_select (Makefile.am): Likewise.
139756         * modules/sys_socket (Makefile.am): Likewise.
139757         * modules/sys_time (Makefile.am): Likewise.
139759 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
139761         * modules/gettimeofday (License): Change from GPL to LGPL, since
139762         gettimeofday is a library function.
139764 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
139766         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
139768 2007-01-21  Bruno Haible  <bruno@clisp.org>
139770         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
139772 2007-01-21  Bruno Haible  <bruno@clisp.org>
139774         * modules/striconveha: New file.
139775         * lib/striconveha.h: New file.
139776         * lib/striconveha.c: New file.
139777         * MODULES.html.sh (Internationalization functions): Add striconveha.
139778         * lib/striconv.c (str_iconv): Optimize the case of an empty input
139779         string.
139780         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
139782 2007-01-21  Bruno Haible  <bruno@clisp.org>
139784         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
139785         * lib/striconveh.c (str_iconveh): Likewise.
139787 2007-01-21  Bruno Haible  <bruno@clisp.org>
139789         * lib/striconveh.h (mem_iconveh): New declaration.
139790         * lib/striconveh.c (mem_iconveh): New function.
139791         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
139793 2007-01-21  Bruno Haible  <bruno@clisp.org>
139795         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
139797         * lib/striconveh.h (mem_cd_iconveh): Change specification.
139798         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
139799         original result buffer.
139800         (str_cd_iconveh): Update.
139801         * tests/test-striconveh.c (main): Update.
139803         * lib/striconv.h (mem_cd_iconv): Change specification.
139804         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
139805         result buffer.
139806         (str_cd_iconv): Update.
139807         * tests/test-striconv.c (main): Update.
139809 2007-01-21  Bruno Haible  <bruno@clisp.org>
139811         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
139813 2007-01-20  Jim Meyering  <jim@meyering.net>
139815         * lib/userspec.c (parse_with_separator): If a user or group string
139816         starts with "+", skip the corresponding name-to-ID look-up, since
139817         such a look-up must fail: user and group names may not include "+".
139819 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
139821         * lib/poll.c: Include sys/time.h and time.h unconditionally,
139822         since we now assume the sys_time module.
139823         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
139824         check for sys/time.h; no longer needed.
139825         * modules/poll (Depends-on): Depend on sys_time.
139827 2007-01-18  Bruno Haible  <bruno@clisp.org>
139829         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
139830         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
139832         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
139833         gettimeofday.
139835         * tests/test-gettimeofday.c: Include <time.h>.
139836         (dummy): Remove variable.
139838         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
139839         gl_HEADER_SYS_TIME_H.
139840         (gl_HEADER_SYS_TIME_H): New macro.
139842         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
139843         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
139844         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
139845         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
139846         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
139847         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
139848         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
139849         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
139850         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
139851         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
139852         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
139854         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
139855         last change; it caused a compilation error when cross-compiling to
139856         Cygwin.
139858 2007-01-18  Jim Meyering  <jim@meyering.net>
139860         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
139861         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
139862         than the race-prone "test -d sys || mkdir sys".
139863         (configure.ac): Use AC_PROG_MKDIR_P.
139864         * modules/sys_select: Likewise.
139865         * modules/sys_socket: Likewise.
139866         * modules/sys_time: Likewise.
139868 2007-01-18  Eric Blake  <ebb9@byu.net>
139870         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
139871         replace gettimeofday.
139872         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
139873         name, to avoid infinite recursion.
139875 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
139877         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
139878         module sys_time.
139879         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
139880         assume timespec.h defines struct timeval.
139881         * lib/settime.c: Likewise.
139882         * lib/utimens.c: Likewise.
139883         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
139884         since we now assume the gettimeofday module.
139885         * lib/tempname.c (__gen_tempname): Likewise.
139886         * lib/gettimeofday.h: Remove.
139887         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
139888         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
139889         Include <time.h>, for 'time()'.
139890         (localtime_buffer_addr): Also use this workaround if
139891         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
139892         to simplify the uses.  All uses changed.
139893         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
139894         that #undef is inside {}, and 'const' follows type name consistently.
139895         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
139896         (gettimeofday): Do not use the maximum possible value for
139897         tv->tv_usec, since that might break usages other than ls.c.
139898         Instead, we'll leave ls.c alone.  This undoes today's patch
139899         by Bruno.  Add a compile-time warning for 1s-clock resolution;
139900         we've never observed the problem but might as well keep the
139901         canary.
139902         * lib/nanosleep.c: Include timespec.h first, for interface check.
139903         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
139904         now assume the sys_time module.
139905         * lib/tempname.c: Likewise.
139906         * lib/timespec.h: Likewise.
139907         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
139908         needed.
139909         * lib/strftime.c: Likewise.
139910         * lib/timespec.h: Likewise.
139911         * lib/posixtm.c: Include posixtm.h first, for interface check.
139912         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
139913         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
139914         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
139915         * lib/sys_time_.h: New file.
139916         * lib/timespec.h (struct timespec): Use long int, not long.
139917         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
139918         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
139919         Remove obsolescent call to AC_HEADER_TIME.
139920         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
139921         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
139922         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
139923         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
139924         Likewise.
139925         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
139926         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
139927         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
139928         into the sys_time module.  Check for gettimeofday just once.
139929         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
139930         for gettimeofday signature to just check the signature.  Merely
139931         compile it, since linking doesn't test signature.  Improve test for
139932         whether gettimeofday.o is actually needed.
139933         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
139934         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
139935         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
139936         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
139937         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
139938         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
139939         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
139940         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
139941         than worrying about sys/time.h.
139942         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
139943         Don't bother worrying about TIME_WITH_SYS_TIME.
139944         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
139945         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
139946         * m4/sys_time_h.m4: New file.
139947         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
139948         Don't include sys/time.h.  Return from main rather than exiting.
139949         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
139950         all uses changed.
139951         * modules/gethrxtime (Depends-on): Add sys_time.
139952         * modules/gettime (Depends-on): Likewise.
139953         * modules/gettimeofday (Depends-on): Likewise.
139954         * modules/nanosleep (Depends-on): Likewise.
139955         * modules/settime (Depends-on): Likewise.
139956         * modules/tempname (Depends-on): Likewise.
139957         * modules/utimens (Depends-on): Likewise.
139958         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
139959         (Include): Change back to <sys/time.h>.
139960         (Maintainer): Add self.
139961         * modules/sys_time: New file.
139962         * modules/tempname (Depends-on): Add gettimeofday.
139963         * tests/test-gettimeofday.c: Include <sys/time.h>
139964         rather than gettimeofday.h.
139966 2007-01-17  Bruno Haible  <bruno@clisp.org>
139968         * gnulib-tool (func_get_license): Revert last patch. Instead, let
139969         the license default to GPL.
139970         (func_create_testdir): Don't complain if a module is LGPL and its
139971         tests module depends on GPLed modules.
139973 2007-01-17  Bruno Haible  <bruno@clisp.org>
139975         * lib/gettimeofday.c (gettimeofday): Add code for the case
139976         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
139977         maximum possible value for tv->tv_usec, rather than the minimum one.
139979 2005-10-08  Martin Lambers  <marlam@marlam.de>
139980 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
139981 2007-01-16  Bruno Haible  <bruno@clisp.org>
139983         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
139984         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
139985         gl_FUNC_GETTIMEOFDAY.
139986         (Include): Add gettimeofday.h.
139987         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
139988         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
139989         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
139990         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
139991         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
139992         * lib/gettimeofday.h: New file.
139993         * lib/gettimeofday.c: Include <sys/timeb.h>.
139994         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
139995         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
139996         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
139997         fall back on time().
139999         * tests/test-gettimeofday.c: New file.
140000         * modules/gettimeofday-tests: New file.
140002 2007-01-16  Eric Blake  <ebb9@byu.net>
140004         * modules/fnmatch (Depends-on): Depend on wchar.
140005         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
140006         * m4/fnmatch.m4: Likewise.
140007         * modules/mbchar (Makefile.am): Assume <wchar.h>.
140008         * m4/mbchar.m4: Likewise.
140009         * modules/mbswidth (Depends-on): Depend on wchar.
140010         * lib/mbswidth.c: Assume <wchar.h>.
140011         * m4/mbswidth.m4: Likewise.
140012         * modules/quotearg (Depends-on): Depend on wchar.
140013         * lib/quotearg.c: Assume <wchar.h>.
140014         * m4/quotearg.m4: Likewise.
140015         * modules/regex (Depends-on): Depend on wchar.
140016         * lib/regex_internal.h: Assume <wchar.h>.
140017         * m4/regex.m4: Likewise.
140018         * modules/stdint (Depends-on): Depend on wchar.
140019         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
140020         * m4/stdint.m4: Likewise.
140021         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
140022         * modules/strftime (Depends-on): Depend on wchar.
140023         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
140024         * modules/strtol (Depends-on): Depend on wchar.
140025         * lib/strtol.c: Assume <wchar.h>.
140026         * modules/wcwidth (Depends-on): Depend on wchar.
140027         * lib/wcwidth.h: Assume <wchar.h>.
140028         * m4/wcwidth.m4: Likewise.
140030 2007-01-16  Bruno Haible  <bruno@clisp.org>
140032         * modules/csharpexec-script: New, created from...
140033         * modules/csharpexec: ... this.
140035 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
140037         * modules/javaexec-script: New, created from...
140038         * modules/javaexec: ... this.
140040 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
140042         * modules/poll (Dependencies): Add sys_select.
140044 2007-01-15  Jim Meyering  <jim@meyering.net>
140046         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
140047         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
140048         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
140049         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
140051 2007-01-15  Bruno Haible  <bruno@clisp.org>
140053         * modules/striconveh: New file.
140054         * lib/striconveh.h: New file.
140055         * lib/striconveh.c: New file.
140056         * MODULES.html.sh (Internationalization functions): Add striconveh.
140058         * modules/striconveh-tests: New file.
140059         * tests/test-striconveh.c: New file.
140061 2007-01-15  Bruno Haible  <bruno@clisp.org>
140063         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
140064         not from GNU libiconv or GNU libc.
140066 2007-01-15  Bruno Haible  <bruno@clisp.org>
140068         * doc/gnulib-intro.texi (Copyright): Explain the different license
140069         terms for module descriptions, autoconf macros, tests, documentation.
140071 2007-01-14  Bruno Haible  <bruno@clisp.org>
140073         * modules/striconv-tests: New file.
140074         * tests/test-striconv.c: New file.
140076 2007-01-14  Bruno Haible  <bruno@clisp.org>
140078         * modules/iconv-tests: New file.
140079         * tests/test-iconv.c: New file.
140081 2007-01-14  Bruno Haible  <bruno@clisp.org>
140083         * gnulib-tool (func_get_license): For test modules, use the license of
140084         the main module.
140086 2007-01-14  Bruno Haible  <bruno@clisp.org>
140088         * modules/iconv (Include): Clarify that <iconv.h> can only be included
140089         if iconv is found to exist.
140091 2007-01-14  Bruno Haible  <bruno@clisp.org>
140093         * modules/c-ctype-tests: New file.
140094         * tests/test-c-ctype.c: New file.
140096 2007-01-14  Bruno Haible  <bruno@clisp.org>
140098         * modules/binary-io-tests: New file.
140099         * tests/test-binary-io.sh: New file.
140100         * tests/test-binary-io.c: New file.
140102 2007-01-14  Bruno Haible  <bruno@clisp.org>
140104         * modules/array-oset-tests: New file.
140105         * tests/test-array_oset.c: New file.
140107 2007-01-14  Bruno Haible  <bruno@clisp.org>
140109         * modules/array-list-tests: New file.
140110         * tests/test-array_list.c: New file.
140112 2007-01-14  Bruno Haible  <bruno@clisp.org>
140114         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
140115         and make.
140116         Reported by Simon Josefsson in
140117         <http://lists.gnu.org/r/bug-gnulib/2007-01/msg00139.html>
140119 2007-01-14  Bruno Haible  <bruno@clisp.org>
140121         * modules/allocsa-tests: New file.
140122         * tests/test-allocsa.c: New file.
140124 2007-01-14  Bruno Haible  <bruno@clisp.org>
140126         * modules/fchdir (Depends-on): Add absolute-header.
140127         * modules/unistd (Depends-on): Likewise.
140129 2006-12-30  Bruno Haible  <bruno@clisp.org>
140131         * modules/fchdir: New file.
140132         * modules/unistd (Files): Add lib/unistd_.h.
140133         (Makefile.am): Generate unistd.h from unistd_.h.
140134         * lib/fchdir.c: New file.
140135         * lib/dirent_.h: New file.
140136         * lib/unistd_.h: New file.
140137         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
140138         * m4/fchdir.m4: New file.
140139         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
140140         (gl_HEADER_UNISTD): Invoke it.
140141         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
140142         function.
140143         * lib/backupfile.c (opendir, closedir): Undefine.
140144         * lib/chown.c (open, close): Undefine.
140145         * lib/clean-temp.c (open, close): Undefine.
140146         * lib/copy-file.c (open, close): Undefine.
140147         * lib/execute.c (open, close): Undefine.
140148         * lib/fsusage.c (open, close): Undefine.
140149         * lib/gc-gnulib.c (open, close): Undefine.
140150         * lib/getcwd.c (opendir, closedir): Undefine.
140151         * lib/glob.c (opendir, closedir): Undefine.
140152         * lib/javacomp.c (open, close): Undefine.
140153         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
140154         * lib/openat-proc.c (open, close): Undefine.
140155         * lib/pagealign_alloc.c (open, close): Undefine.
140156         * lib/pipe.c (open, close): Undefine.
140157         * lib/progreloc.c (open, close): Undefine.
140158         * lib/savedir.c (opendir, closedir): Undefine.
140159         * lib/utime.c (open, close): Undefine.
140160         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
140162 2007-01-10  Bruno Haible  <bruno@clisp.org>
140164         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
140166 2007-01-12  Eric Blake  <ebb9@byu.net>
140168         Provide a robust <wchar.h>.  Further simplifications are now
140169         possible in other modules, but not included here.
140170         * modules/wchar: New module.
140171         * m4/wchar.m4: New file.
140172         * lib/wchar_.h: Likewise.
140173         * modules/mbchar (Depends-on): Depend on wchar, as the first use
140174         of the new module.
140175         * MODULES.html.sh (Extended multibyte and wide character utilities):
140176         New section.
140178 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
140180         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
140181         to a reasonable default for memory allocation.
140182         (xreadlink): Don't allocate a huge buffer, to work around a buggy
140183         file system that reports garbage st_size values for symlinks.
140184         Problem reported by Liyang Hu.
140186 2007-01-11  Simon Josefsson  <simon@josefsson.org>
140188         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
140189         Emacs .#* auto-save files).
140191 2007-01-11  Bruno Haible  <bruno@clisp.org>
140193         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
140194         directory.
140196 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
140198         Use @...@ consistently in lib/wctype_.h.
140199         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
140200         on it being set to 1 or 0.
140201         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
140202         go back to AC_SUBSTing it.
140203         * modules/wctype (Makefile.am): Undo previous change.
140205 2007-01-10  Eric Blake  <ebb9@byu.net>
140207         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
140208         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
140209         * modules/wctype (Makefile.am): Likewise.
140210         Reported by Chris McGuire.
140212 2007-01-10  Jim Meyering  <jim@meyering.net>
140214         fts.c: a small readability/maintainability improvement
140215         * lib/fts.c (fts_read): Make this code slightly more readable and
140216         maintainable by hoisting the "sp->fts_cur = p" assignments to
140217         immediately follow the statements that set P.  Derived from
140218         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
140220 2007-01-10  Eric Blake  <ebb9@byu.net>
140222         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
140223         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
140224         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
140225         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
140226         Reported by Chris McGuire.
140228 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
140230         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
140231         in sed script.
140233 2007-01-09  Bruno Haible  <bruno@clisp.org>
140235         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
140236         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
140237         variables.
140238         (func_module): Use them.
140240 2007-01-09  Bruno Haible  <bruno@clisp.org>
140242         * modules/unistr/base: New file.
140243         * lib/unistr.h: New file.
140245         * modules/unistr/u8-to-u16: New file.
140246         * lib/unistr/u8-to-u16.c: New file.
140248         * modules/unistr/u8-to-u32: New file.
140249         * lib/unistr/u8-to-u32.c: New file.
140251         * modules/unistr/u16-to-u8: New file.
140252         * lib/unistr/u16-to-u8.c: New file.
140254         * modules/unistr/u16-to-u32: New file.
140255         * lib/unistr/u16-to-u32.c: New file.
140257         * modules/unistr/u32-to-u8: New file.
140258         * lib/unistr/u32-to-u8.c: New file.
140260         * modules/unistr/u32-to-u16: New file.
140261         * lib/unistr/u32-to-u16.c: New file.
140263         * modules/unistr/u8-check: New file.
140264         * modules/unistr/u16-check: New file.
140265         * modules/unistr/u32-check: New file.
140266         * lib/unistr/u8-check.c: New file.
140267         * lib/unistr/u16-check.c: New file.
140268         * lib/unistr/u32-check.c: New file.
140270         * modules/unistr/u8-chr: New file.
140271         * modules/unistr/u16-chr: New file.
140272         * modules/unistr/u32-chr: New file.
140273         * lib/unistr/u8-chr.c: New file.
140274         * lib/unistr/u16-chr.c: New file.
140275         * lib/unistr/u32-chr.c: New file.
140277         * modules/unistr/u8-cmp: New file.
140278         * modules/unistr/u16-cmp: New file.
140279         * modules/unistr/u32-cmp: New file.
140280         * lib/unistr/u8-cmp.c: New file.
140281         * lib/unistr/u16-cmp.c: New file.
140282         * lib/unistr/u32-cmp.c: New file.
140284         * modules/unistr/u8-cpy: New file.
140285         * modules/unistr/u16-cpy: New file.
140286         * modules/unistr/u32-cpy: New file.
140287         * lib/unistr/u8-cpy.c: New file.
140288         * lib/unistr/u16-cpy.c: New file.
140289         * lib/unistr/u32-cpy.c: New file.
140290         * lib/unistr/u-cpy.h: New file.
140292         * modules/unistr/u8-cpy-alloc: New file.
140293         * modules/unistr/u16-cpy-alloc: New file.
140294         * modules/unistr/u32-cpy-alloc: New file.
140295         * lib/unistr/u8-cpy-alloc.c: New file.
140296         * lib/unistr/u16-cpy-alloc.c: New file.
140297         * lib/unistr/u32-cpy-alloc.c: New file.
140298         * lib/unistr/u-cpy-alloc.h: New file.
140300         * modules/unistr/u8-endswith: New file.
140301         * modules/unistr/u16-endswith: New file.
140302         * modules/unistr/u32-endswith: New file.
140303         * lib/unistr/u8-endswith.c: New file.
140304         * lib/unistr/u16-endswith.c: New file.
140305         * lib/unistr/u32-endswith.c: New file.
140306         * lib/unistr/u-endswith.h: New file.
140308         * modules/unistr/u8-mblen: New file.
140309         * modules/unistr/u16-mblen: New file.
140310         * modules/unistr/u32-mblen: New file.
140311         * lib/unistr/u8-mblen.c: New file.
140312         * lib/unistr/u16-mblen.c: New file.
140313         * lib/unistr/u32-mblen.c: New file.
140315         * modules/unistr/u8-mbtouc: New file.
140316         * modules/unistr/u16-mbtouc: New file.
140317         * modules/unistr/u32-mbtouc: New file.
140318         * lib/unistr/u8-mbtouc.c: New file.
140319         * lib/unistr/u16-mbtouc.c: New file.
140320         * lib/unistr/u32-mbtouc.c: New file.
140322         * modules/unistr/u8-mbtouc-safe: New file.
140323         * modules/unistr/u16-mbtouc-safe: New file.
140324         * modules/unistr/u32-mbtouc-safe: New file.
140325         * lib/unistr/u8-mbtouc-safe.c: New file.
140326         * lib/unistr/u16-mbtouc-safe.c: New file.
140327         * lib/unistr/u32-mbtouc-safe.c: New file.
140329         * modules/unistr/u8-move: New file.
140330         * modules/unistr/u16-move: New file.
140331         * modules/unistr/u32-move: New file.
140332         * lib/unistr/u8-move.c: New file.
140333         * lib/unistr/u16-move.c: New file.
140334         * lib/unistr/u32-move.c: New file.
140335         * lib/unistr/u-move.h: New file.
140337         * modules/unistr/u8-next: New file.
140338         * modules/unistr/u16-next: New file.
140339         * modules/unistr/u32-next: New file.
140340         * lib/unistr/u8-next.c: New file.
140341         * lib/unistr/u16-next.c: New file.
140342         * lib/unistr/u32-next.c: New file.
140344         * modules/unistr/u8-prev: New file.
140345         * modules/unistr/u16-prev: New file.
140346         * modules/unistr/u32-prev: New file.
140347         * lib/unistr/u8-prev.c: New file.
140348         * lib/unistr/u16-prev.c: New file.
140349         * lib/unistr/u32-prev.c: New file.
140351         * modules/unistr/u8-set: New file.
140352         * modules/unistr/u16-set: New file.
140353         * modules/unistr/u32-set: New file.
140354         * lib/unistr/u8-set.c: New file.
140355         * lib/unistr/u16-set.c: New file.
140356         * lib/unistr/u32-set.c: New file.
140357         * lib/unistr/u-set.h: New file.
140359         * modules/unistr/u8-startswith: New file.
140360         * modules/unistr/u16-startswith: New file.
140361         * modules/unistr/u32-startswith: New file.
140362         * lib/unistr/u8-startswith.c: New file.
140363         * lib/unistr/u16-startswith.c: New file.
140364         * lib/unistr/u32-startswith.c: New file.
140365         * lib/unistr/u-startswith.h: New file.
140367         * modules/unistr/u8-stpcpy: New file.
140368         * modules/unistr/u16-stpcpy: New file.
140369         * modules/unistr/u32-stpcpy: New file.
140370         * lib/unistr/u8-stpcpy.c: New file.
140371         * lib/unistr/u16-stpcpy.c: New file.
140372         * lib/unistr/u32-stpcpy.c: New file.
140373         * lib/unistr/u-stpcpy.h: New file.
140375         * modules/unistr/u8-stpncpy: New file.
140376         * modules/unistr/u16-stpncpy: New file.
140377         * modules/unistr/u32-stpncpy: New file.
140378         * lib/unistr/u8-stpncpy.c: New file.
140379         * lib/unistr/u16-stpncpy.c: New file.
140380         * lib/unistr/u32-stpncpy.c: New file.
140381         * lib/unistr/u-stpncpy.h: New file.
140383         * modules/unistr/u8-strcat: New file.
140384         * modules/unistr/u16-strcat: New file.
140385         * modules/unistr/u32-strcat: New file.
140386         * lib/unistr/u8-strcat.c: New file.
140387         * lib/unistr/u16-strcat.c: New file.
140388         * lib/unistr/u32-strcat.c: New file.
140389         * lib/unistr/u-strcat.h: New file.
140391         * modules/unistr/u8-strchr: New file.
140392         * modules/unistr/u16-strchr: New file.
140393         * modules/unistr/u32-strchr: New file.
140394         * lib/unistr/u8-strchr.c: New file.
140395         * lib/unistr/u16-strchr.c: New file.
140396         * lib/unistr/u32-strchr.c: New file.
140398         * modules/unistr/u8-strcmp: New file.
140399         * modules/unistr/u16-strcmp: New file.
140400         * modules/unistr/u32-strcmp: New file.
140401         * lib/unistr/u8-strcmp.c: New file.
140402         * lib/unistr/u16-strcmp.c: New file.
140403         * lib/unistr/u32-strcmp.c: New file.
140405         * modules/unistr/u8-strcpy: New file.
140406         * modules/unistr/u16-strcpy: New file.
140407         * modules/unistr/u32-strcpy: New file.
140408         * lib/unistr/u8-strcpy.c: New file.
140409         * lib/unistr/u16-strcpy.c: New file.
140410         * lib/unistr/u32-strcpy.c: New file.
140411         * lib/unistr/u-strcpy.h: New file.
140413         * modules/unistr/u8-strcspn: New file.
140414         * modules/unistr/u16-strcspn: New file.
140415         * modules/unistr/u32-strcspn: New file.
140416         * lib/unistr/u8-strcspn.c: New file.
140417         * lib/unistr/u16-strcspn.c: New file.
140418         * lib/unistr/u32-strcspn.c: New file.
140419         * lib/unistr/u-strcspn.h: New file.
140421         * modules/unistr/u8-strdup: New file.
140422         * modules/unistr/u16-strdup: New file.
140423         * modules/unistr/u32-strdup: New file.
140424         * lib/unistr/u8-strdup.c: New file.
140425         * lib/unistr/u16-strdup.c: New file.
140426         * lib/unistr/u32-strdup.c: New file.
140427         * lib/unistr/u-strdup.h: New file.
140429         * modules/unistr/u8-strlen: New file.
140430         * modules/unistr/u16-strlen: New file.
140431         * modules/unistr/u32-strlen: New file.
140432         * lib/unistr/u8-strlen.c: New file.
140433         * lib/unistr/u16-strlen.c: New file.
140434         * lib/unistr/u32-strlen.c: New file.
140435         * lib/unistr/u-strlen.h: New file.
140437         * modules/unistr/u8-strmblen: New file.
140438         * modules/unistr/u16-strmblen: New file.
140439         * modules/unistr/u32-strmblen: New file.
140440         * lib/unistr/u8-strmblen.c: New file.
140441         * lib/unistr/u16-strmblen.c: New file.
140442         * lib/unistr/u32-strmblen.c: New file.
140444         * modules/unistr/u8-strmbtouc: New file.
140445         * modules/unistr/u16-strmbtouc: New file.
140446         * modules/unistr/u32-strmbtouc: New file.
140447         * lib/unistr/u8-strmbtouc.c: New file.
140448         * lib/unistr/u16-strmbtouc.c: New file.
140449         * lib/unistr/u32-strmbtouc.c: New file.
140451         * modules/unistr/u8-strncat: New file.
140452         * modules/unistr/u16-strncat: New file.
140453         * modules/unistr/u32-strncat: New file.
140454         * lib/unistr/u8-strncat.c: New file.
140455         * lib/unistr/u16-strncat.c: New file.
140456         * lib/unistr/u32-strncat.c: New file.
140457         * lib/unistr/u-strncat.h: New file.
140459         * modules/unistr/u8-strncmp: New file.
140460         * modules/unistr/u16-strncmp: New file.
140461         * modules/unistr/u32-strncmp: New file.
140462         * lib/unistr/u8-strncmp.c: New file.
140463         * lib/unistr/u16-strncmp.c: New file.
140464         * lib/unistr/u32-strncmp.c: New file.
140466         * modules/unistr/u8-strncpy: New file.
140467         * modules/unistr/u16-strncpy: New file.
140468         * modules/unistr/u32-strncpy: New file.
140469         * lib/unistr/u8-strncpy.c: New file.
140470         * lib/unistr/u16-strncpy.c: New file.
140471         * lib/unistr/u32-strncpy.c: New file.
140472         * lib/unistr/u-strncpy.h: New file.
140474         * modules/unistr/u8-strnlen: New file.
140475         * modules/unistr/u16-strnlen: New file.
140476         * modules/unistr/u32-strnlen: New file.
140477         * lib/unistr/u8-strnlen.c: New file.
140478         * lib/unistr/u16-strnlen.c: New file.
140479         * lib/unistr/u32-strnlen.c: New file.
140480         * lib/unistr/u-strnlen.h: New file.
140482         * modules/unistr/u8-strpbrk: New file.
140483         * modules/unistr/u16-strpbrk: New file.
140484         * modules/unistr/u32-strpbrk: New file.
140485         * lib/unistr/u8-strpbrk.c: New file.
140486         * lib/unistr/u16-strpbrk.c: New file.
140487         * lib/unistr/u32-strpbrk.c: New file.
140488         * lib/unistr/u-strpbrk.h: New file.
140490         * modules/unistr/u8-strrchr: New file.
140491         * modules/unistr/u16-strrchr: New file.
140492         * modules/unistr/u32-strrchr: New file.
140493         * lib/unistr/u8-strrchr.c: New file.
140494         * lib/unistr/u16-strrchr.c: New file.
140495         * lib/unistr/u32-strrchr.c: New file.
140497         * modules/unistr/u8-strspn: New file.
140498         * modules/unistr/u16-strspn: New file.
140499         * modules/unistr/u32-strspn: New file.
140500         * lib/unistr/u8-strspn.c: New file.
140501         * lib/unistr/u16-strspn.c: New file.
140502         * lib/unistr/u32-strspn.c: New file.
140503         * lib/unistr/u-strspn.h: New file.
140505         * modules/unistr/u8-strstr: New file.
140506         * modules/unistr/u16-strstr: New file.
140507         * modules/unistr/u32-strstr: New file.
140508         * lib/unistr/u8-strstr.c: New file.
140509         * lib/unistr/u16-strstr.c: New file.
140510         * lib/unistr/u32-strstr.c: New file.
140511         * lib/unistr/u-strstr.h: New file.
140513         * modules/unistr/u8-strtok: New file.
140514         * modules/unistr/u16-strtok: New file.
140515         * modules/unistr/u32-strtok: New file.
140516         * lib/unistr/u8-strtok.c: New file.
140517         * lib/unistr/u16-strtok.c: New file.
140518         * lib/unistr/u32-strtok.c: New file.
140519         * lib/unistr/u-strtok.h: New file.
140521         * modules/unistr/u8-uctomb: New file.
140522         * modules/unistr/u16-uctomb: New file.
140523         * modules/unistr/u32-uctomb: New file.
140524         * lib/unistr/u8-uctomb.c: New file.
140525         * lib/unistr/u16-uctomb.c: New file.
140526         * lib/unistr/u32-uctomb.c: New file.
140528         * MODULES.html.sh (Unicode string functions): Add the new modules.
140530 2007-01-08  Bruno Haible  <bruno@clisp.org>
140532         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
140533         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
140534         subdirectories.
140536 2007-01-08  Karl Berry  <karl@gnu.org>
140538         * doc/error.texi: mention that main() fns must set program_name
140539         when progname is used.
140541 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
140543         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
140544         WCTYPE_H is empty, for the benefit of builds from non-distclean
140545         directories.  Problem reported by Eric Blake in
140546         <http://lists.gnu.org/r/bug-gnulib/2007-01/msg00157.html>.
140548 2007-01-08  Bruno Haible  <bruno@clisp.org>
140550         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
140551         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
140552         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
140553         PROVIDE_CANONICALIZE_FILENAME_MODE.
140554         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
140556 2007-01-08  Bruno Haible  <bruno@clisp.org>
140558         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
140559         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
140560         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
140561         * lib/fts.c: Likewise.
140562         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
140564 2006-12-25  Bruno Haible  <bruno@clisp.org>
140566         * modules/utf8-ucs4-safe: New file.
140567         * lib/utf8-ucs4-safe.h: New file.
140568         * lib/unistr/utf8-ucs4-safe.c: New file.
140570         * modules/utf16-ucs4-safe: New file.
140571         * lib/utf16-ucs4-safe.h: New file.
140572         * lib/unistr/utf16-ucs4-safe.c: New file.
140574         * MODULES.html.sh (Unicode string functions): Add the new modules.
140576 2007-01-08  Bruno Haible  <bruno@clisp.org>
140578         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
140579         (Depends-on): Add unitypes.
140580         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
140581         (u8_mbtouc_aux): Move out to separate file.
140582         (u8_mbtouc): Use ucs4_t, uint8_t types.
140583         * lib/unistr/utf8-ucs4.c: New file.
140585         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
140586         (Depends-on): Add unitypes.
140587         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
140588         (u16_mbtouc_aux): Move out to separate file.
140589         (u16_mbtouc): Use ucs4_t, uint16_t types.
140590         * lib/unistr/utf16-ucs4.c: New file.
140592         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
140593         (Depends-on): Add unitypes.
140594         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
140595         (u8_uctomb_aux): Move out to separate file.
140596         (u8_uctomb): Use ucs4_t, uint8_t types.
140597         * lib/unistr/ucs4-utf8.c: New file.
140599         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
140600         (Depends-on): Add unitypes.
140601         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
140602         (u16_uctomb_aux): Move out to separate file.
140603         (u16_uctomb): Use ucs4_t, uint16_t types.
140604         * lib/unistr/ucs4-utf16.c: New file.
140606 2006-12-25  Bruno Haible  <bruno@clisp.org>
140608         * modules/unitypes: New file.
140609         * lib/unitypes.h: New file.
140610         * MODULES.html.sh (func_all_modules): New section "Unicode string
140611         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
140612         this section. Add unitypes.
140614 2007-01-08  Bruno Haible  <bruno@clisp.org>
140616         Avoid variable names that conflict with those from libtool.
140617         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
140618         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
140619         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
140620         library_names_spec to acl_library_names_spec, hardcode_* to
140621         acl_hardcode_*.
140622         Reported by Ralf Wildenhues.
140624 2007-01-08  Bruno Haible  <bruno@clisp.org>
140626         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
140627         definition.
140628         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
140629         definition.
140630         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
140631         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
140632         definition.
140633         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
140634         definition.
140635         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
140636         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
140637         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
140638         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
140639         definition.
140640         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
140641         definition.
140642         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
140643         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
140644         GC_USE_<algorithm>.
140645         * lib/gc-libgcrypt.c: Likewise.
140646         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
140647         * modules/gc-arctwo (configure.ac): Likewise.
140648         * modules/gc-des (configure.ac): Likewise.
140649         * modules/gc-hmac-md5 (configure.ac): Likewise.
140650         * modules/gc-hmac-sha1 (configure.ac): Likewise.
140651         * modules/gc-md2 (configure.ac): Likewise.
140652         * modules/gc-md4 (configure.ac): Likewise.
140653         * modules/gc-md5 (configure.ac): Likewise.
140654         * modules/gc-random (configure.ac): Likewise.
140655         * modules/gc-rijndael (configure.ac): Likewise.
140656         * modules/gc-sha1 (configure.ac): Likewise.
140658 2007-01-08  Bruno Haible  <bruno@clisp.org>
140660         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
140661         macro definition.
140662         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
140663         definition.
140664         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
140665         definition.
140666         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
140667         * modules/fcntl-safer (configure.ac): Likewise.
140668         * modules/fopen-safer (configure.ac): Likewise.
140669         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
140670         GNULIB_FWRITEERROR macro definition.
140672 2007-01-08  Bruno Haible  <bruno@clisp.org>
140674         * m4/gnulib-common.m4: New file.
140675         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
140676         (func_get_filelist): Add m4/gnulib-common.m4.
140678 2007-01-08  Bruno Haible  <bruno@clisp.org>
140680         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
140681         command.
140683 2007-01-08  Jim Meyering  <jim@meyering.net>
140685         Use a more robust test for a "can't happen" condition.
140686         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
140687         narrowed the st_size value.  Presuming the "can't happen" condition
140688         is true, that narrowing could conceivably convert an invalid st_size
140689         value into a valid one.  Instead, use a change based on Matthew
140690         Woehlke's original patch.
140692         Slight readability improvement: use an assert-like macro
140693         in place of literal "abort ()" uses.
140694         * lib/fts.c (fts_assert): Define.
140695         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
140696         Use this macro instead of a bare 'abort'.
140698 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
140700         Don't worry about using IRIX 5.3's wctype.h broken definitions;
140701         simply work around them.
140702         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
140703         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
140704         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
140705         declaring.
140706         Don't bother to define as macros, since the standard doesn't require it.
140707         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
140708         longer worry about IRIX 5.3.
140709         (HAVE_WCTYPE_CTMP_BUG): Remove.
140711 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
140713         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
140714         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
140715         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
140716         Problems reported by Georg Schwarz for IRIX 5.3.
140718         * gnulib-tool (autoconf_minversion): Take the maximum version number
140719         found, not the minimum.  Problem reported by James Youngman.
140721 2007-01-03  Karl Berry  <karl@gnu.org>
140723         * doc/error.texi: new file, explaining interaction with progname.
140724         * doc/gnulib.texi: include it.  Update copyright.
140726 2007-01-03  Simon Josefsson  <simon@josefsson.org>
140728         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
140729         AC_CANONICAL_HOST, to improve autobuild outputs.
140731 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
140732             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
140734         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
140735         sockets, server sockets, and other file descriptors.  Count errors
140736         to compute the return value.  Reorder the code a bit to be easier
140737         to follow.  Don't set event bits that were not requested (except
140738         POLLERR and POLLHUP).
140740 2007-01-01  Bruno Haible  <bruno@clisp.org>
140742         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
140744 2007-01-03  Jim Meyering  <jim@meyering.net>
140746         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
140748 2007-01-02  Bruno Haible  <bruno@clisp.org>
140750         * modules/settime (Include): Require timespec.h.
140751         * modules/nanosleep (Include): Likewise.
140753 2007-01-01  Bruno Haible  <bruno@clisp.org>
140755         * gnulib-tool (func_emit_copyright_notice): Bump year.
140756         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
140758 2007-01-01  Bruno Haible  <bruno@clisp.org>
140760         Improve support for OpenBSD.
140761         * build-aux/config.rpath (libname_spec): Export.
140762         (library_names_spec): New variable. Export.
140763         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
140764         library_names_spec from the config.rpath output. Locate shared library
140765         through the name pattern in library_names_spec.
140767 2007-01-01  Eric Blake  <ebb9@byu.net>
140769         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
140771 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
140773         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
140774         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
140775         assume the C locale, and avoid an "eval" that could cause trouble.
140776         Problem with SORT reported by Bob Proulx.
140778         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
140779         Define.  Trivial patch from Henning Nielsen Lund, originally
140780         sent to bug-grep@gnu.org today.
140782 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
140784         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
140785         struct stat.  Problem reported by Henning Nielsen Lund.
140786         * lib/acl.c: Include acl.h first, to check interface.  Don't
140787         bother to include sys/types.h and sys/stat.h again.
140789 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
140791         Import the following change from libc; problem reported by
140792         Sven Verdoolaege.
140794         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
140796         [BZ #1373]
140797         * lib/argp.h: Remove __NTH for __argp_usage inline function.
140799 2006-12-28  Jim Meyering  <jim@meyering.net>
140801         * build-aux/announce-gen: Do not assume that the package
140802         builds any of tar.gz, tar.bz2, and .xdelta files.
140803         Suggestion from Simon Josefsson.
140805 2006-12-28  Simon Josefsson  <simon@josefsson.org>
140807         * modules/announce-gen: New file.
140809 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
140811         * lib/mbchar.h: Just include <wctype.h>; the wctype module
140812         handles its gotchas now.
140813         * lib/mbswidth.c: Likewise.
140814         * lib/wcwidth.h: Likewise.
140815         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
140816         and iswcntrl; the wctype module does this stuff now.
140817         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
140818         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
140819         * modules/mbchar (Depends-on): Add wctype.
140820         * modules/mbswidth (Depends-on): Likewise.
140821         * modules/wcwidth (Depends-on): Likewise.
140823 2006-12-27  Eric Blake  <ebb9@byu.net>
140825         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
140826         module uses more than what <wctype.h> is required to provide.
140828 2006-12-26  Eric Blake  <ebb9@byu.net>
140830         * gnulib-tool (sed_extract_prog): Avoid space-tab.
140832 2006-12-26  Eric Blake  <ebb9@byu.net>
140834         * modules/absolute-header: New module.
140835         * modules/fcntl (Depends-on): Depend on it.
140836         * modules/inttypes (Depends-on): Likewise.
140837         * modules/stdint (Depends-on): Likewise.
140838         * modules/sys_stat (Depends-on): Likewise.
140839         * modules/wctype (Depends-on): Likewise.
140840         * MODULES.html.sh (Support for building libraries and
140841         executables): Document it.
140843 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
140845         * gnulib-tool (SED): Remove, undoing previous change.
140846         The problem was that it broke coreutils on Solaris, because
140847         "sed --posix" leaked into a makefile.
140848         (sed): New alias, if 'alias' and GNU sed.
140850 2006-12-24  Jim Meyering  <jim@meyering.net>
140852         Work around an fchownat bug in glibc-2.4:
140853         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
140854         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
140855         in spite of the -P option.
140856         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
140857         New macros.
140858         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
140859         * modules/openat (Files): Add lib/fchownat.c.
140860         * lib/openat.c (fchownat): Don't define here.  Move to...
140861         * lib/fchownat.c: ...this new file.
140863 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
140865         Fix bug reported by Bruno Haible in
140866         <http://lists.gnu.org/r/bug-gnulib/2006-12/msg00228.html>
140867         where quotearg.c didn't compile on Mac OS X 10.2 because it
140868         lacks <wchar.h> and wint_t.
140869         * lib/wctype_.h (__wctype_wint_t): New type.
140870         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
140871         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
140872         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
140873         Arg is now of type __wctype_wint_t, not wint_t.
140874         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
140875         substitute HAVE_WINT_T.
140876         * modules/wctype (Files): Add m4/wint_t.m4.
140877         (wctype.h): Substitute HAVE_WINT_T.
140879 2006-12-23  Bruno Haible  <bruno@clisp.org>
140881         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
140883 2006-12-23  Bruno Haible  <bruno@clisp.org>
140885         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
140886         S_ISLNK.
140887         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
140888         mingw.
140890 2006-12-22  Bruno Haible  <bruno@clisp.org>
140892         * lib/copy-file.c: Include acl.h.
140893         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
140894         Close the file descriptors only after being done with copy_acl.
140895         * modules/copy-file (Depends-on): Add acl.
140897 2006-12-22  Bruno Haible  <bruno@clisp.org>
140899         * gnulib-tool (SED): New variable.
140900         Use $SED instead of sed everywhere.
140902 2006-12-22  Bruno Haible  <bruno@clisp.org>
140904         * modules/no-c++: New file.
140905         * m4/no-c++.m4: New file.
140906         * MODULES.html.sh (Support for building libraries and executables):
140907         Add no-c++.
140909 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
140911         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
140912         Include <limits.h>, and use its INT_MAX to rewrite the
140913         j loop so that it does not overflow 'int'.  Problem reported by
140914         Ralf Wildenhues in
140915         <http://lists.gnu.org/r/bug-gnulib/2006-12/msg00084.html>.
140916         Play it safe by shifting left by 1 rather than multiplying by 2,
140917         as GCC is less likely to optimize this away when the value
140918         is signed (when it assumes overflow leads to undefined behavior).
140919         Also, don't assume time_t uses two's complement.
140921 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
140923         * MODULES.html.sh: New module wctype.
140924         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
140925         * lib/fnmatch.c: Don't bother to include <wchar.h> before
140926         <wctype.h>, since the new wctype module should fix this.
140927         * lib/quotearg.c: Include <wctype.h> unconditionally, since
140928         the wctype module should arrange for it.
140929         * lib/regex_internal.h: Likewise.
140930         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
140931         since the wctype module should handle this now.
140932         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
140933         * modules/fnmatch (Depends-on): Add wctype.
140934         * modules/quotearg (Depends-on): Likewise.
140935         * modules/regex (Depends-on): Likewise.
140937 2006-12-19  Bruno Haible  <bruno@clisp.org>
140939         * lib/strdup.h [C++]: Wrap definitions in extern "C".
140940         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
140942 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
140944         * modules/savewd (Depends-on): Fix dependency on fcntl.
140946 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
140948         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
140949         conforms to C99, rather than relying on the user's environment
140950         setting of STDINT_H.
140952 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
140953         and Eric Blake  <ebb9@byu.net>
140955         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
140956         This is more consistent with the other defines here.
140957         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
140958         Port to z/OS.  Problem reported by Paul Gilmartin.
140959         Change local vars to use gl_ prefix rather than ac_.
140960         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
140961         with other defines.
140962         * modules/double-slash-root: New module.
140963         * modules/dirname (Files): Remove m4/double-slash-root.m4.
140964         (Depends-on): Add double-slash-root.
140965         * MODULES.html.sh (File system functions): Mention new module.
140967 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
140969         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
140970         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
140971         This is for the benefit of gzip, which doesn't do i18n.
140973 2006-12-12  Jim Meyering  <jim@meyering.net>
140975         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
140976         Reported by Andreas Schwab <schwab@suse.de>.
140978 2006-12-12  Bruno Haible  <bruno@clisp.org>
140980         Merge these changes.
140981         2006-09-05  Bruno Haible  <bruno@clisp.org>
140982         * lib/iconvme.c (iconv_string): No need to save and restore errno when
140983         iconv_alloc succeeded.
140984         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
140985         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
140986         test for " && dest " at the end - dest is always != NULL there. Call
140987         iconv with 4xNULL arguments initially, to reset the state. Call iconv
140988         with 2xNULL arguments, also to flush the state storage. Handle the
140989         IRIX iconv behaviour. Realloc the final result, to throw away unused
140990         memory.
140992 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
140994         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
140995         and fchmodat unconditionally, since glibc 2.4 has them.
140996         Problem reported by Arkadiusz Miskiewicz.
140998 2006-12-10  Bruno Haible  <bruno@clisp.org>
141000         * gnulib-tool (func_import): Show the include files only for those
141001         modules that are copied and specified.
141002         Reported by Karl Berry.
141004 2006-12-08  Jim Meyering  <jim@meyering.net>
141006         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
141007         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
141009         * build-aux/announce-gen: Add two new options, both optional:
141010         --bootstrap-tools=TOOL_LIST
141011               a comma-separated list of tools, e.g.,
141012               autoconf,automake,bison,gnulib
141013         --gnulib-snapshot-date=DATE
141014               if gnulib is in the bootstrap tool list,
141015               then report this as the snapshot date.
141016               If not specified, use the current date/time.
141017               If you specify a date here, be sure it's UTC.
141019 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141021         * tests/test-argp-2.sh: Fix test to match actual output.
141022         (func_compare): Fix sed script to be portable.
141024 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
141026         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
141027         workaround for this case.  It is not autoconfigured now; offhand
141028         it's hard to see how to autoconfigure it.
141030 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
141032         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
141033         a directory that is about to be chowned.  Such a directory's
141034         initial file permissions should permit the owner only and this
141035         should not be changed until after the chown, since the group and
141036         other bits would be incorrect if they granted permission before
141037         the chown.
141039         Fix porting problem for iswctype reported by Georg Schwarz in:
141040         http://lists.gnu.org/r/bug-coreutils/2006-12/msg00017.html
141041         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
141042         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
141043         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
141044         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
141046 2006-12-03  Jim Meyering  <jim@meyering.net>
141048         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
141049         p->fts_statp may not yet be defined.
141050         (fts_read): Instead, set it in the caller, once p->fts_statp is
141051         sure to be defined, and corresponds to a top-level directory.
141052         This bug made du -x fail.  Here's the coreutils test case:
141053         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
141054         Reported by Mike Frysinger.
141056 2006-12-01  Jim Meyering  <jim@meyering.net>
141058         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
141059         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
141060         Reported by Simon Josefsson.
141062 2006-11-30  Jim Meyering  <jim@meyering.net>
141064         * m4/warning.m4: Use the all-permissive copyright notice
141065         recommended by RMS (rather than LGPL).
141066         * m4/vararrays.m4: Likewise.
141067         * m4/flexmember.m4: Likewise.
141069 2006-11-29  Bruno Haible  <bruno@clisp.org>
141071         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
141072         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
141073         using +=.
141074         Reported by Simon Josefsson <simon@josefsson.org>.
141076 2006-11-28  James Youngman  <jay@gnu.org>
141078         * README: Advise users that they might find the bug-gnulib@gnu.org
141079         and autotools-announce@gnu.org mailing lists useful.
141081 2006-11-28  Bruno Haible  <bruno@clisp.org>
141083         * m4/ptrdiff_max.m4: Remove file.
141085 2006-11-21  Bruno Haible  <bruno@clisp.org>
141087         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
141088         _AC_COMPUTE_INT.
141089         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
141090         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
141091         _AC_COMPUTE_INT.
141092         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
141093         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
141094         _AC_COMPUTE_INT.
141095         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
141097 2006-11-28  Jim Meyering  <jim@meyering.net>
141099         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
141100         warning from "gcc -Wshadow" about shadowing the builtin.
141102 2006-11-27  Bruno Haible  <bruno@clisp.org>
141104         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
141105         _AC_COMPUTE_INT.
141106         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
141108 2006-11-27  Bruno Haible  <bruno@clisp.org>
141109             Paul Eggert  <eggert@cs.ucla.edu>
141111         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
141113 2006-11-26  Bruno Haible  <bruno@clisp.org>
141115         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
141116         noinst_LTLIBRARIES.
141118 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
141119             Bruno Haible  <bruno@clisp.org>
141121         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
141122         if compiling with "gcc -ansi".
141124 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
141126         Fix some incompatibilities with gcc -ansi -pedantic.
141127         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
141128         if compiling pedantically with GCC, unless it's C99 or later.
141129         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
141130         it mishandles gcc -ansi -pedantic as well.
141131         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
141132         if gcc -pedantic.
141133         * lib/regexec.c (check_node_accept_bytes): Don't use auto
141134         initializers for struct if -pedantic, unless it's C99 or later.
141136 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
141138         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
141139         Don't close an fd more than once. Identical atimes indicate
141140         success, not failure.
141142 2006-11-22  Robinson Mittmann  <bob@hoplon.com>  (tiny change)
141144         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
141146 2006-11-23  Jim Meyering  <jim@meyering.net>
141148         * build-aux/announce-gen: New file.  From coreutils.
141150 2006-11-22  Jim Meyering  <jim@meyering.net>
141152         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
141153         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
141154         (fts_read): Use a temporary to narrow the overused st_size member
141155         before using it in a switch statement.  Reported by Matthew Woehlke.
141157         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
141158         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
141160 2006-11-20  Bruno Haible  <bruno@clisp.org>
141162         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
141163         changequote instead of pairs of brackets.
141164         Reported by Andreas Schwab <schwab@suse.de>.
141166 2006-11-21  Jim Meyering  <jim@meyering.net>
141168         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
141169         so as to remain compatible with older compilers.
141170         Patch from Michael Deutschmann.
141172 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
141174         * MODULES.html.sh (File system functions): Add openat.
141176         * lib/openat.h (rpl_fstatat): New macro, if
141177         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
141178         (fstatat): Define to rpl_fstatat under the same conditions,
141179         unless COMPILING_FSTATAT.
141180         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
141181         seems to have the bug.
141182         * lib/fstatat.c: New file.
141183         * modules/openat (Files): Add it.
141185 2006-11-20  Bruno Haible  <bruno@clisp.org>
141187         * Makefile: New file.
141189 2006-11-20  Jim Meyering  <jim@meyering.net>
141191         The beginnings of syntax-related checks for gnulib.
141192         * lib/Makefile: New file.
141193         * lib/t-idcache: New script.  Ensure that the two halves of
141194         idcache.c stay in sync.
141196         * lib/idcache.c: Adjust comments in user- and group- portions to
141197         be more accurate, and to be consistent with one another.
141199 2006-11-20  Jim Meyering  <jim@meyering.net>
141201         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
141202         continue using the flexible array member (thus, this module performs
141203         half as many malloc calls), with the addition that...
141204         (getgroup, getuser): Consistently record a non-match via an empty
141205         "name" string, and map an empty string match to a NULL return value.
141206         * modules/idcache (Depends-on): Re-add flexmember.
141208         * lib/idcache.c (getuser): Remove all uses of the register keyword.
141209         (getuidbyname, getgroup, getgidbyname): Likewise.
141211         Use cleaner syntax: NULL rather than 0.
141212         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
141214 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
141216         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
141217         It mishandled the case where the group was missing.
141218         Problem reported by Greg Schafer.
141219         * modules/idcache: Likewise.
141221 2006-11-18  Jim Meyering  <jim@meyering.net>
141223         * check-module (%exempt_header): Add exception for some
141224         conditionally-included headers.
141226         * modules/i-ring (Depends-on): Add verify.
141227         (License): Change to LGPL.
141229 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
141231         * modules/getaddrinfo (Depends-on): Remove inttostr; add snprintf.
141232         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
141233         and inttostr.h.  Use snprintf rather than uinttostr, so that
141234         LGPLed code doesn't depend on GPLed.
141236 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
141238         * modules/inline (License): Change from GPL to LGPL.
141240 2006-11-17  Jim Meyering  <jim@meyering.net>
141242         * modules/d-type (License): Switch to LGPL.
141244 2006-11-15  Bruno Haible  <bruno@clisp.org>
141246         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
141248 2006-11-15  Eric Blake  <ebb9@byu.net>
141250         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
141251         the module dependency.
141253 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
141254             Bruno Haible  <bruno@clisp.org>
141256         * gnulib-tool (func_create_testdir): Add license consistency check.
141258 2006-11-15  Eric Blake  <ebb9@byu.net>
141260         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
141261         random "(cached)" in configure output.
141263 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141265         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
141266         test for conforming inttypes.h is both announced and cached.
141268         * MODULES.html.sh (seen_modules, seen_files): New variables.
141269         (func_module): Rewrite to use a few less gnulib-tool and sed
141270         invocations.  Avoid a couple of quadratic algorithms for ...
141271         (missed_modules, missed_files): ... these, with ...
141272         (func_append, func_tmpdir): ... these new functions, from
141273         gnulib-tool.  Analogously, install traps for cleanup.
141275         * tests/test-gc.c (main): Remove unused variables.
141276         * tests/test-read-file.c: Include stdlib.h, for 'free'.
141278 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
141280         * modules/inttostr (License): Change to LGPL.
141282 2006-11-14  Eric Blake  <ebb9@byu.net>
141284         * modules/tempname (License): Change to LGPL.
141286 2006-11-14  Eric Blake  <ebb9@byu.net>
141288         * doc/functions.texi (Function Portability): *printf functions on
141289         Cygwin now understand all POSIX size specifiers.
141291 2006-11-14  Bruno Haible  <bruno@clisp.org>
141293         * modules/c-ctype (License): Change to LGPL.
141295 2006-11-12  Bruno Haible  <bruno@clisp.org>
141297         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
141298         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
141299         for GNOME libraries, for which the include files are installed in
141300         subdirectories of $prefix/include.
141302 2006-11-12  Bruno Haible  <bruno@clisp.org>
141304         * m4/lib-link.m4: Require at least autoconf-2.54.
141305         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
141306         name to underscores for the --with option.
141308 2006-11-13  Bruno Haible  <bruno@clisp.org>
141310         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
141311         the tests directory.
141312         Reported by Ralf Wildenhues.
141314 2006-11-13  Bruno Haible  <bruno@clisp.org>
141316         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
141317         (func_emit_initmacro_end): Undo the override here.
141318         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
141319         Works around the famous automake error in coreutils.
141321 2006-11-13  Eric Blake  <ebb9@byu.net>
141323         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
141324         element, not its node.
141326 2006-11-12  Bruno Haible  <bruno@clisp.org>
141328         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
141329         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
141331 2006-11-12  Bruno Haible  <bruno@clisp.org>
141333         * gnulib-tool: New option --local-symlink.
141334         (func_usage): Document it.
141335         (lsymbolic): New variable.
141336         (func_import, func_create_testdir): If --symlink was not specified,
141337         test whether --local-symlink was specified and the file comes from
141338         the local_gnulib_dir.
141340 2006-11-12  Bruno Haible  <bruno@clisp.org>
141342         * gnulib-tool (func_ln): New function.
141343         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
141345 2006-11-12  Bruno Haible  <bruno@clisp.org>
141347         Finish support for source files in subdirectories.
141348         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
141349         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
141350         AUTOMAKE_OPTIONS.
141351         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
141353 2006-11-12  Bruno Haible  <bruno@clisp.org>
141355         * gnulib-tool (func_get_automake_snippet): Synthesize also an
141356         EXTRA_lib_SOURCES augmentation.
141357         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
141359 2006-11-12  Jim Meyering  <jim@meyering.net>
141361         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
141362         file descriptors.  This also averts a failure on systems with
141363         native openat support when a traversed directory lacks "x" access.
141364         * lib/fts_.h: Include "i-ring.h"
141365         (struct FTS) [fts_fd_ring]: New member.
141366         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
141367         (FCHDIR): Add parentheses.
141368         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
141369         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
141370         When descending, rather than simply closing the previous
141371         fts_cwd_fd value, push that file descriptor onto the ring.
141372         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
141373         (fts_open): Initialize the new fd_ring member.
141374         (fts_close): Clear the ring.
141375         (fts_safe_changedir): When possible, use our new fd_ring to skip
141376         the diropen and fstat and dev/ino comparison that would normally
141377         accompany a virtual `chdir ("..")'.
141379         * modules/fts (Depends-on): Add i-ring.
141380         * modules/i-ring: New module.
141381         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
141382         * m4/i-ring.m4: New file.
141384 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141386         * gnulib-tool (func_create_testdir): Fix replacement of
141387         `build-aux' in configure.ac.  Run autotools in gltests
141388         subdirectory.
141389         (func_create_testdir, func_create_megatestdir, test): There is
141390         no need for '--force' in most autotool invocations in a new
141391         tree.  Actually fail the whole test if any of the tools, or the
141392         configure or make stages fail.
141394         Sync from Automake.
141395         * build-aux/gnupload: Revert last change.  Add pointer to upload
141396         instructions of the GNU Maintenance Instructions.
141397         Suggestion by Karl Berry.
141399 2006-11-10  Jim Meyering  <jim@meyering.net>
141401         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
141403 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
141405         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
141406         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
141407         (bind_textdomain_codeset) [! ENABLE_NLS]:
141408         Evaluate all the arguments.  That way, callers get compatible behavior
141409         if the arguments have side effects.  Also, it avoids some GCC
141410         diagnostics in some cases; Joel E. Denny reported problems when Bison
141411         was configured with --enable-gcc-warnigs.
141413 2006-11-10  Jim Meyering  <jim@meyering.net>
141415         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
141416         relevant options in CFLAGS (like -O, -fno-inline) are taken into
141417         account.
141419 2006-11-10  Jim Meyering  <jim@meyering.net>
141421         * modules/inline: New file/module.
141422         * modules/xalloc (Files): Remove m4/inline.m4.
141423         (Depends-on): Add inline, instead.
141424         * modules/oset: Likewise.
141425         * modules/list: Likewise.
141427 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
141429         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
141430         Problem reported by Matthew Woehlke.
141432 2006-11-09  Bruno Haible  <bruno@clisp.org>
141434         * lib/tempname.c (gen_tempname): Remove variant that invokes
141435         __gen_tempname.
141436         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
141437         __gen_tempname.
141439 2006-11-08  Bruno Haible  <bruno@clisp.org>
141441         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
141442         to 'yes' instead of 'cross-compiling'.
141444 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
141446         * lib/quotearg.h (quotearg_free): New decl.
141447         * lib/quotearg.c (quotearg_free): New function.
141448         (slot0, nslots, slotvec0, slotvec):
141449         Now file-scope so that quotearg_free can get at them.
141451 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141453         Sync from Automake.
141454         * build-aux/gnupload: Add missing 'gnu' to example URL.
141455         Report by Karl Berry.
141457 2006-11-08  Bruno Haible  <bruno@clisp.org>
141459         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
141460         Suggested by Paul Eggert.
141462 2006-11-08  Jim Meyering  <jim@meyering.net>
141464         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
141465         It's already included if !_LIBC.
141466         (fts_safe_changedir): Add a comment.
141468 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
141470         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
141471         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
141472         Matthew Woehlke.
141474         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
141475         definitions up, to avoid colliding with change below.
141476         (static_inline) [HAVE_INLINE]: New macro.
141477         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
141478         Provide extern decls when !HAVE_INLINE.  Do not define unless
141479         static_inline is defined, either by us or by xmalloc.c.  Use
141480         static_inline rather than static inline.
141481         (XCALLOC): Optimize sizeof(T) = 1 case.
141482         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
141484 2006-11-07  Bruno Haible  <bruno@clisp.org>
141486         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
141487         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
141488         AC_C_INLINE.
141489         * modules/xalloc (Files): Add m4/inline.m4.
141491 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141493         * README: Fix typo.
141494         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
141495         (Miscellanous Notes): ...from this.
141497 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
141499         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
141500         Mention that offsetof should be used instead of sizeof.
141501         From Bruno Haible.
141503 2006-11-07  Bruno Haible  <bruno@clisp.org>
141505         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
141507 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
141509         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
141510         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
141511         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
141512         (gl_tree_add_before, gl_tree_add_after):
141513         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
141514         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
141515         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
141516         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
141517         (gl_linked_add_after, gl_linked_add_at): Likewise.
141518         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
141519         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
141520         (gl_tree_add_before, gl_tree_add_after): Likewise.
141521         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
141522         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
141523         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
141525 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141527         * lib/gl_oset.h: Use C comment style, not C++ comment style.
141529 2006-11-06  Bruno Haible  <bruno@clisp.org>
141531         * m4/inline.m4: New file.
141532         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
141533         * modules/list (Files): Add m4/inline.m4.
141534         * modules/oset (Files): Likewise.
141536 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
141538         * lib/idcache.c: Include <stddef.h>, for offsetof.
141539         (struct userid.name): Change from char * to a flexible array member.
141540         All uses changed.
141541         * modules/idcache (Depends-on): Add flexmember.
141543         * MODULES.html.sh (Core language properties): New module flexmember.
141544         * modules/flexmember, m4/flexmember.m4: New files.
141546         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
141547         inline functions that are identical with the old xnmalloc_inline,
141548         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
141549         that we can avoid some unnecessary integer multiplications and
141550         divisions in the common case where the element size is known at
141551         compile time.
141552         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
141553         needed.
141554         (xnboundedmalloc): Remove.
141555         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
141556         arguments, for consistency with rest of this header.
141557         (xcharalloc): Rewrite using XNMALLOC.
141558         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
141559         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
141560         versions have been moved to lib/xalloc.h and renamed to be the
141561         non-*_inline versions.
141562         (xmalloc, xrealloc): Implement without reference to the xnmalloc
141563         and xnrealloc functions, since those functions are now inline and
141564         now call us.
141565         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
141566         renaming described above.
141567         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
141568         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
141569         captures the dependency in AC_C_INLINE.
141571         New module canonicalize-lgpl, proposed by Charles Wilson in
141572         <http://lists.gnu.org/r/bug-gnulib/2006-11/msg00020.html>
141573         with a few small changes afterwards.
141574         * MODULES.html.sh (File system functions): New module
141575         canonicalize-lgpl.
141576         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
141577         and canonicalize_file_name.
141578         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
141579         * modules/canonicalize-lgpl: New files.
141581 2006-11-05  Bruno Haible  <bruno@clisp.org>
141583         * gnulib-tool (func_import, func_create_testdir): Create directories
141584         also for files in subdirectories of lib/.
141586 2006-11-05  Bruno Haible  <bruno@clisp.org>
141588         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
141589         ANSI C compliant.
141591 2006-11-03  Bruno Haible  <bruno@clisp.org>
141593         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
141594         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
141595         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
141596         (xnboundedmalloc): New inline function.
141597         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
141598         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
141599         xmalloc.
141600         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
141601         xmalloc.
141602         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
141603         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
141604         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
141605         xmalloc.
141606         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
141607         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
141608         xmalloc.
141609         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
141610         gl_tree_add_after): Use XMALLOC instead of xmalloc.
141611         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
141612         xmalloc.
141613         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
141614         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
141615         gl_tree_add_after): Use XMALLOC instead of xmalloc.
141616         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
141617         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
141618         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
141619         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
141621 2006-11-03  Bruno Haible  <bruno@clisp.org>
141623         * lib/c-ctype.h [C++]: Define functions without name mangling.
141624         * lib/fwriteerror.h [C++]: Likewise.
141625         * lib/gcd.h [C++]: Likewise.
141626         * lib/linebreak.h [C++]: Likewise.
141628 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
141630         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
141631         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
141632         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
141633         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
141634         Check for functions and headers just once.
141635         Check for declaration of canonicalize_file_name.
141636         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
141638 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
141640         * gnulib-tool (func_import): Fix typo in actioncmd.
141642 2006-11-02  Bruno Haible  <bruno@clisp.org>
141644         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
141645         newline sequence in the Makefile.am snippet as a space, like "make"
141646         does.
141647         Reported by Roger Persson <perrog@gmail.com>.
141649 2006-11-01  Bruno Haible  <bruno@clisp.org>
141651         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
141652         already declared in <string.h>.
141653         * lib/strcase.h (strncasecmp): Don't declare it if yes.
141655 2006-11-01  Bruno Haible  <bruno@clisp.org>
141657         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
141658         * lib/strcase.h: Include <string.h>.
141659         (strcasecmp): Define to rpl_strcasecmp here.
141661 2006-11-01  Bruno Haible  <bruno@clisp.org>
141663         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
141665 2006-11-01  Eric Blake  <ebb9@byu.net>
141667         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
141669         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
141671 2006-10-29  Bruno Haible  <bruno@clisp.org>
141673         Make it compile in C++ mode.
141674         * lib/full-write.c (full_rw): Add a cast.
141676 2006-11-01  Bruno Haible  <bruno@clisp.org>
141678         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
141679         be POSIX compliant.
141680         Reported by Roger Persson <perrog@gmail.com>.
141682 2006-11-01  Eric Blake  <ebb9@byu.net>
141684         * lib/getopt_.h: Fix comments.
141686 2006-10-31  Eric Blake  <ebb9@byu.net>
141688         * modules/tmpdir (Depends-on): Add sys_stat.
141689         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
141690         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
141691         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
141692         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
141693         tempname.
141695 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
141697         Avoid some C++ diagnostics reported by Bruno Haible.
141698         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
141699         xmalloc.
141700         (quotearg_alloc): Use xcharalloc rather than xmalloc.
141701         (struct slotvec): Move to top level.
141702         (quotearg_n_options): Rewrite to avoid xmalloc.
141703         * lib/xalloc.h (xcharalloc): New function.
141704         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
141705         [defined __cplusplus]: Add function template that provides result
141706         type propagation.  This part of the change is from Bruno Haible.
141708 2006-10-29  Bruno Haible  <bruno@clisp.org>
141710         Make it compile in C++ mode.
141711         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
141712         * lib/strnlen1.c (strnlen1): Cast memchr result.
141713         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
141714         * lib/clean-temp.c (string_equals, string_hash): Add casts.
141715         (create_temp_dir): Rename local variable 'template'.
141716         (compile_csharp_using_sscli): Add cast.
141717         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
141718         * lib/findprog.c (find_in_path): Likewise.
141719         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
141720         * lib/wait-process.c (register_slave_subprocess): Likewise.
141722 2006-10-22  Bruno Haible  <bruno@clisp.org>
141724         * modules/tsearch: New file.
141725         * lib/tsearch.h: New file.
141726         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
141727         * m4/tsearch.m4: New file.
141728         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
141730 2006-10-29  Eric Blake  <ebb9@byu.net>
141732         * lib/arcfour.c: Assume config.h.
141733         * lib/arctwo.c: Likewise.
141734         * lib/base64.c: Likewise.
141735         * lib/check-version.c: Likewise.
141736         * lib/crc.c: Likewise.
141737         * lib/des.c: Likewise.
141738         * lib/gc-gnulib.c: Likewise.
141739         * lib/gc-libgcrypt.c: Likewise.
141740         * lib/gc-pbkdf2-sha1.c: Likewise.
141741         * lib/getaddrinfo.c: Likewise.
141742         * lib/getdelim.c: Likewise.
141743         * lib/getline.c: Likewise.
141744         * lib/hmac-md5.c: Likewise.
141745         * lib/hmac-sha1.c: Likewise.
141746         * lib/iconvme.c: Likewise.
141747         * lib/md2.c: Likewise.
141748         * lib/md4.c: Likewise.
141749         * lib/memxor.c: Likewise.
141750         * lib/read-file.c: Likewise.
141751         * lib/readline.c: Likewise.
141752         * lib/rijndael-alg-fst.c: Likewise.
141753         * lib/rijndael-api-fst.c: Likewise.
141754         * lib/xgetdomainname.c: Likewise.
141756 2006-10-28  Eric Blake  <ebb9@byu.net>
141758         * lib/xstrndup.c: Assume config.h.
141760 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
141762         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
141763         stat-macros.h is now for our own macros, whereas stat_h is for
141764         macros in the <sys/stat.h> name space.
141765         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
141766         (STAT_MACROS_H): Remove.
141767         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
141768         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
141769         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
141770         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
141771         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
141772         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
141773         Move these macros to ...
141774         * lib/stat_.h: here.  Don't include stat-macros.h.
141775         * lib/canonicalize.c: Don't include stat-macros.h.
141776         * lib/chown.c: Likewise.
141777         * lib/euidaccess.c: Likewise.
141778         * lib/file-type.c: Likewise.
141779         * lib/filemode.c: Likewise.
141780         * lib/glob.c: Likewise.
141781         * lib/isapipe.c: Likewise.
141782         * lib/lchown.c: Likewise.
141783         * lib/lstat.c: Likewise.
141784         * lib/mkdir-p.c: Likewise.
141785         * lib/rmdir.c: Likewise.
141786         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
141787         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
141788         unless mkdir isn't declared, to speed up 'configure'.
141789         Always create sys/stat.h, since it's unlikely any real sys/stat.h
141790         would define all the S_* symbols.
141791         * modules/canonicalize (Depends-on):
141792         Depend on sys_stat, not stat-macros.
141793         * modules/chown: Likewise.
141794         * modules/euidaccess: Likewise.
141795         * modules/filemode: Likewise.
141796         * modules/file-type: Likewise.
141797         * modules/glob: Likewise.
141798         * modules/isapipe: Likewise.
141799         * modules/lchown: Likewise.
141800         * modules/lstat: Likewise.
141801         * modules/mkancesdirs: Likewise.
141802         * modules/rmdir: Likewise.
141803         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
141804         * modules/modechange: Likewise.
141805         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
141806         (configure.ac): Remove gl_STAT_MACROS.
141807         * modules/sys_stat (Depends-on): Remove stat-macros.
141809 2006-10-27  Bruno Haible  <bruno@clisp.org>
141811         * m4/signed.m4: Remove file.
141812         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
141813         invocation.
141814         * modules/vasnprintf (Files): Remove m4/signed.m4.
141816 2006-10-27  Bruno Haible  <bruno@clisp.org>
141818         Update to GNU gettext 0.16.
141819         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
141820         m4/inttypes-h.m4, m4/signed.m4.
141821         * m4/gettext.m4: Update to GNU gettext 0.16.
141822         * m4/intl.m4: New file, from GNU gettext.
141823         * m4/intldir.m4: New file, from GNU gettext.
141824         * config/srclist.txt: Update
141826 2006-10-27  Eric Blake  <ebb9@byu.net>
141828         * MODULES.html.sh: Document tempname.
141829         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
141830         dependencies.
141831         (Files): Move lib/tempname.c...
141832         * modules/tempname: ...to this new module.
141833         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
141834         (gl_PREREQ_TEMPNAME): Move...
141835         * m4/tempname.m4: ...to this new file.
141836         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
141837         * modules/sys_stat (Depends-on): Add stat-macros.
141838         * lib/stat_.h (includes): Pick up stat macros.
141839         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
141840         if stat macros are broken.
141841         * lib/tempname.c (includes): No need to include "stat-macros.h".
141842         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
141843         (direxists, __path_search) [!_LIBC]: Don't compile these in
141844         gnulib; the tmpdir module covers that.
141845         * lib/tempname.h: New file.
141847 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
141849         * COPYING: Explain how gnulib-tool converts licence headers.
141850         Almost all wording by Eric Blake.
141852 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
141854         * lib/mbchar.h (is_basic_table): Make read-only.
141855         * lib/mbchar.c (is_basic_table): Likewise.
141856         Reported by John Darrington.
141858 2006-10-25  Bruno Haible  <bruno@clisp.org>
141860         * lib/progname.h (set_program_name): Undefine before defining.
141862 2006-10-25  Bruno Haible  <bruno@clisp.org>
141864         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
141865         false for non-gcc C++ compilers.
141866         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
141868 2006-10-24  Bruno Haible  <bruno@clisp.org>
141870         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
141871         iconv implementations like Irix iconv.
141873 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
141875         * modules/vararrays: New file.
141876         * m4/vararrays.m4: New file, taken from diffutils.
141877         * MODULES.html.sh: New module vararrays.
141879 2006-10-24  Karl Berry  <karl@gnu.org>
141881         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
141882         Don't call GNU Unix.
141884 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141886         * users.txt: Add Libtool.
141888         Sync from Libtool:
141890         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
141892         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
141893         to gnulib's policy of including config.h unconditionally.
141895 2006-10-24  Bruno Haible  <bruno@clisp.org>
141897         * modules/wcwidth (Files): Add m4/wint_t.m4.
141898         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
141899         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
141901 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
141903         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
141904         to pacify GCC with some -W flags enabled.  Problem reported by
141905         Bruno Haible.
141907 2006-10-24  Jim Meyering  <jim@meyering.net>
141909         * MODULES.html.sh: Remove uinttostr.  It's not a module.
141910         Reported by Karl Berry.
141912 2006-10-23  Bruno Haible  <bruno@clisp.org>
141914         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
141916 2006-10-24  Bruno Haible  <bruno@clisp.org>
141918         * lib/gl_list.h: Use C comment style, not C++ comment style.
141920 2006-10-23  Eric Blake  <ebb9@byu.net>
141922         * lib/getaddrinfo.c (includes): Add missing include.
141924 2006-10-23  Bruno Haible  <bruno@clisp.org>
141925             Paul Eggert  <eggert@cs.ucla.edu>
141927         Ability to rename obstack_free.
141928         * lib/obstack.h (__obstack_free): New macro. Declare instead of
141929         obstack_free.
141930         (obstack_free): Invoke the __obstack_free macro.
141931         * lib/obstack.c (obstack_free): Use __obstack_free macro.
141933 2006-10-23  Bruno Haible  <bruno@clisp.org>
141934             Paul Eggert  <eggert@cs.ucla.edu>
141936         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
141937         __argc, __argv from the declaration. (They are defined as macros on
141938         mingw.)
141940 2006-10-22  Bruno Haible  <bruno@clisp.org>
141942         * doc/gnulib-intro.texi: New file.
141943         * doc/gnulib.texi: Include it.
141945 2006-10-21  Bruno Haible  <bruno@clisp.org>
141947         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
141948         "Introduction", "Miscellanous Notes", "Particular Modules".
141950 2006-10-21  Bruno Haible  <bruno@clisp.org>
141952         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
141953         Change mostlyclean-local rule to avoid sh syntax error from bash
141954         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
141956 2006-10-23  Jim Meyering  <jim@meyering.net>
141958         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
141959         in place of snprintf.
141961         * modules/inttostr (Files): Add lib/uinttostr.c.
141962         * lib/uinttostr.c (inttostr): New file/function.
141963         * lib/inttostr.h (uinttostr): Declare.
141964         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
141965         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
141966         Add uinttostr.
141967         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
141969 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
141971         * lib/canonicalize.c (ELOOP): Define if not already defined.
141972         Problem reported by Bruno Haible in
141973         <http://lists.gnu.org/r/bug-gnulib/2006-10/msg00282.html>.
141975 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
141977         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
141978         Problem reported by Perry Smith and Ville Laurikari.
141980         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
141981         uses.
141983 2006-10-19  Bruno Haible  <bruno@clisp.org>
141985         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
141986         for mingw.
141988 2006-10-19  Bruno Haible  <bruno@clisp.org>
141990         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
141991         Needed for mingw.
141993 2006-10-19  Bruno Haible  <bruno@clisp.org>
141995         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
141997 2006-10-19  Bruno Haible  <bruno@clisp.org>
141999         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
142000         it.
142002 2006-10-19  Bruno Haible  <bruno@clisp.org>
142004         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
142005         invocation.
142007 2006-10-19  Bruno Haible  <bruno@clisp.org>
142009         * gnulib-tool (func_create_testdir): Don't include ftruncate and
142010         mountlist by default.
142012 2006-10-16  Bruno Haible  <bruno@clisp.org>
142014         * lib/c-strstr.c: Include c-strstr.h.
142016 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
142018         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
142019         in a slash.
142021 2006-10-18  Bruno Haible  <bruno@clisp.org>
142023         * lib/lock.h [C++]: Wrap definitions in extern "C".
142025 2006-10-18  Bruno Haible  <bruno@clisp.org>
142027         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
142028         gl_LIBOBJS list.
142030 2006-10-18  Bruno Haible  <bruno@clisp.org>
142032         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
142034 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
142036         * lib/xstrtol.h: Include gettext.h.
142037         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
142038         Problem reported by Eric Blake.
142039         * modules/xstrtol (Depends-on): Add gettext-h.
142041 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
142043         * lib/strftime.c (advance): New macro.
142044         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
142045         incomplete type, so you can't add 0 to it.  Problem and patch
142046         reported by Eelco Dolstra for dietlibc.
142048 2006-10-18  Jim Meyering  <jim@meyering.net>
142050         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
142051         type for a local, and rename it: s/up/user_proc/.
142053 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
142055         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
142056         READ_UTMP_USER_PROCESS.
142057         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
142059 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
142061         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
142062         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
142064 2006-10-17  Eric Blake  <ebb9@byu.net>
142066         * lib/sigprocmask.c (sigprocmask): Fix typo.
142068         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
142070         * modules/clean-temp (Makefile.am): Don't add to make output...
142071         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
142072         config.h.
142074 2006-10-17  Bruno Haible  <bruno@clisp.org>
142076         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
142077         differently if DEFAULT_TEXT_DOMAIN is set.
142079 2006-10-16  Bruno Haible  <bruno@clisp.org>
142081         * lib/clean-temp.c: Include fwriteerror.h.
142083 2006-10-16  Bruno Haible  <bruno@clisp.org>
142085         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
142087 2006-10-16  Bruno Haible  <bruno@clisp.org>
142089         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
142090         * lib/sigprocmask.h: Include <sys/types.h>.
142091         (sigset_t): Use the system's definition if present.
142093 2006-10-17  Eric Blake  <ebb9@byu.net>
142095         * lib/xvasprintf.c (includes): Assume config.h.
142096         * lib/xasprintf.c (includes): Likewise.
142098 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
142100         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
142101         at least as wide as intmax_t.
142103 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
142105         (Imported from Automake.)
142106         * build-aux/gnupload: Update to version 1.1 of directive file.
142108 2006-10-16  Eric Blake  <ebb9@byu.net>
142110         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
142111         match Automake 1.10a.
142113 2006-10-14  Bruno Haible  <bruno@clisp.org>
142115         * modules/sigprocmask: New file.
142116         * lib/sigprocmask.h: New file.
142117         * lib/sigprocmask.c: New file.
142118         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
142119         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
142120         request sigprocmask.o.
142121         (gl_PREREQ_SIGPROCMASK): New macro.
142122         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
142123         (Depends-on): Add sigprocmask.
142124         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
142125         gt_SIGNALBLOCKING. Test for 'raise' only once.
142126         * lib/fatal-signal.c: Include sigprocmask.h.
142127         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
142128         unblock_fatal_signals): Define always.
142129         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
142130         sigprocmask.
142132 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
142134         Sync from Automake.
142135         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
142136         which incorrectly sets the mode of an existing destination
142137         directory.  In some cases the unpatched install-sh could do the
142138         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
142139         system.  We hope this is rare in practice, but it's clearly worth
142140         fixing.  Problem reported by Alex Unleashed in
142141         <http://lists.gnu.org/r/bug-autoconf/2006-10/msg00012.html>.
142142         Also, don't bother to check for -m bugs unless we're using -m;
142143         suggested by Stepan Kasal.
142145 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
142147         Sync from Automake.
142148         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
142149         `-c' flag, so they appear at the same position as in %FASTDEP%
142150         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
142151         which ignores unknown options only after the first non-option.
142152         Bug report against M4 by Nelson H. F. Beebe.
142154 2006-10-13  Jim Meyering  <jim@meyering.net>
142156         Fix a bug in yesterday's change.
142157         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
142158         p->fts_statp->st_dev would be used uninitialized.
142159         Ensures that we always call fts_stat on the very first entry.
142160         Miklos Szeredi reported that find -xdev stopped working.
142162 2006-10-12  Bruno Haible  <bruno@clisp.org>
142164         * gnulib-tool (func_get_automake_snippet): Append an automatically
142165         computed EXTRA_DIST augmentation.
142166         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
142167         * modules/alloca-opt (Makefile.am): Likewise.
142168         * modules/allocsa (Makefile.am): Likewise.
142169         * modules/arcfour (Makefile.am): Likewise.
142170         * modules/arctwo (Makefile.am): Likewise.
142171         * modules/argmatch (Makefile.am): Likewise.
142172         * modules/argz (Makefile.am): Likewise.
142173         * modules/atexit (Makefile.am): Likewise.
142174         * modules/backupfile (Makefile.am): Likewise.
142175         * modules/byteswap (Makefile.am): Likewise.
142176         * modules/c-strtod (Makefile.am): Likewise.
142177         * modules/c-strtold (Makefile.am): Likewise.
142178         * modules/calloc (Makefile.am): Likewise.
142179         * modules/canon-host (Makefile.am): Likewise.
142180         * modules/canonicalize (Makefile.am): Likewise.
142181         * modules/chdir-long (Makefile.am): Likewise.
142182         * modules/chdir-safer (Makefile.am): Likewise.
142183         * modules/check-version (Makefile.am): Likewise.
142184         * modules/chown (Makefile.am): Likewise.
142185         * modules/cloexec (Makefile.am): Likewise.
142186         * modules/close-stream (Makefile.am): Likewise.
142187         * modules/closeout (Makefile.am): Likewise.
142188         * modules/crc (Makefile.am): Likewise.
142189         * modules/csharpexec (Makefile.am): Likewise.
142190         * modules/cycle-check (Makefile.am): Likewise.
142191         * modules/des (Makefile.am): Likewise.
142192         * modules/dev-ino (Makefile.am): Likewise.
142193         * modules/dirfd (Makefile.am): Likewise.
142194         * modules/dirname (Makefile.am): Likewise.
142195         * modules/dup2 (Makefile.am): Likewise.
142196         * modules/eealloc (Makefile.am): Likewise.
142197         * modules/error (Makefile.am): Likewise.
142198         * modules/euidaccess (Makefile.am): Likewise.
142199         * modules/exclude (Makefile.am): Likewise.
142200         * modules/exitfail (Makefile.am): Likewise.
142201         * modules/fcntl-safer (Makefile.am): Likewise.
142202         * modules/fcntl (Makefile.am): Likewise.
142203         * modules/file-type (Makefile.am): Likewise.
142204         * modules/fileblocks (Makefile.am): Likewise.
142205         * modules/filemode (Makefile.am): Likewise.
142206         * modules/filenamecat (Makefile.am): Likewise.
142207         * modules/fnmatch (Makefile.am): Likewise.
142208         * modules/fopen-safer (Makefile.am): Likewise.
142209         * modules/fpending (Makefile.am): Likewise.
142210         * modules/fprintftime (Makefile.am): Likewise.
142211         * modules/free (Makefile.am): Likewise.
142212         * modules/fsusage (Makefile.am): Likewise.
142213         * modules/ftruncate (Makefile.am): Likewise.
142214         * modules/fts (Makefile.am): Likewise.
142215         * modules/gc-arcfour (Makefile.am): Likewise.
142216         * modules/gc-des (Makefile.am): Likewise.
142217         * modules/gc-hmac-md5 (Makefile.am): Likewise.
142218         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
142219         * modules/gc-md4 (Makefile.am): Likewise.
142220         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
142221         * modules/gc-sha1 (Makefile.am): Likewise.
142222         * modules/gc (Makefile.am): Likewise.
142223         * modules/getaddrinfo (Makefile.am): Likewise.
142224         * modules/getcwd (Makefile.am): Likewise.
142225         * modules/getdelim (Makefile.am): Likewise.
142226         * modules/getdomainname (Makefile.am): Likewise.
142227         * modules/getgroups (Makefile.am): Likewise.
142228         * modules/gethostname (Makefile.am): Likewise.
142229         * modules/gethrxtime (Makefile.am): Likewise.
142230         * modules/getline (Makefile.am): Likewise.
142231         * modules/getloadavg (Makefile.am): Likewise.
142232         * modules/getlogin_r (Makefile.am): Likewise.
142233         * modules/getndelim2 (Makefile.am): Likewise.
142234         * modules/getopt (Makefile.am): Likewise.
142235         * modules/getpagesize (Makefile.am): Likewise.
142236         * modules/getpass-gnu (Makefile.am): Likewise.
142237         * modules/getpass (Makefile.am): Likewise.
142238         * modules/getsubopt (Makefile.am): Likewise.
142239         * modules/gettime (Makefile.am): Likewise.
142240         * modules/gettimeofday (Makefile.am): Likewise.
142241         * modules/getugroups (Makefile.am): Likewise.
142242         * modules/getusershell (Makefile.am): Likewise.
142243         * modules/glob (Makefile.am): Likewise.
142244         * modules/group-member (Makefile.am): Likewise.
142245         * modules/hard-locale (Makefile.am): Likewise.
142246         * modules/hash (Makefile.am): Likewise.
142247         * modules/hmac-md5 (Makefile.am): Likewise.
142248         * modules/hmac-sha1 (Makefile.am): Likewise.
142249         * modules/human (Makefile.am): Likewise.
142250         * modules/idcache (Makefile.am): Likewise.
142251         * modules/imaxabs (Makefile.am): Likewise.
142252         * modules/imaxdiv (Makefile.am): Likewise.
142253         * modules/inet_ntop (Makefile.am): Likewise.
142254         * modules/inet_pton (Makefile.am): Likewise.
142255         * modules/intprops (Makefile.am): Likewise.
142256         * modules/inttostr (Makefile.am): Likewise.
142257         * modules/inttypes (Makefile.am): Likewise.
142258         * modules/isapipe (Makefile.am): Likewise.
142259         * modules/javaversion (Makefile.am): Likewise.
142260         * modules/lchmod (Makefile.am): Likewise.
142261         * modules/lchown (Makefile.am): Likewise.
142262         * modules/localcharset (Makefile.am): Likewise.
142263         * modules/long-options (Makefile.am): Likewise.
142264         * modules/lstat (Makefile.am): Likewise.
142265         * modules/malloc (Makefile.am): Likewise.
142266         * modules/mathl (Makefile.am): Likewise.
142267         * modules/mbchar (Makefile.am): Likewise.
142268         * modules/md2 (Makefile.am): Likewise.
142269         * modules/md4 (Makefile.am): Likewise.
142270         * modules/md5 (Makefile.am): Likewise.
142271         * modules/memcasecmp (Makefile.am): Likewise.
142272         * modules/memchr (Makefile.am): Likewise.
142273         * modules/memcmp (Makefile.am): Likewise.
142274         * modules/memcoll (Makefile.am): Likewise.
142275         * modules/memcpy (Makefile.am): Likewise.
142276         * modules/memmem (Makefile.am): Likewise.
142277         * modules/memmove (Makefile.am): Likewise.
142278         * modules/mempcpy (Makefile.am): Likewise.
142279         * modules/memrchr (Makefile.am): Likewise.
142280         * modules/memset (Makefile.am): Likewise.
142281         * modules/memxor (Makefile.am): Likewise.
142282         * modules/mkancesdirs (Makefile.am): Likewise.
142283         * modules/mkdir-p (Makefile.am): Likewise.
142284         * modules/mkdir (Makefile.am): Likewise.
142285         * modules/mkdtemp (Makefile.am): Likewise.
142286         * modules/mkstemp (Makefile.am): Likewise.
142287         * modules/mktime (Makefile.am): Likewise.
142288         * modules/modechange (Makefile.am): Likewise.
142289         * modules/mountlist (Makefile.am): Likewise.
142290         * modules/nanosleep (Makefile.am): Likewise.
142291         * modules/obstack (Makefile.am): Likewise.
142292         * modules/openat (Makefile.am): Likewise.
142293         * modules/pagealign_alloc (Makefile.am): Likewise.
142294         * modules/pathmax (Makefile.am): Likewise.
142295         * modules/physmem (Makefile.am): Likewise.
142296         * modules/poll (Makefile.am): Likewise.
142297         * modules/posixtm (Makefile.am): Likewise.
142298         * modules/posixver (Makefile.am): Likewise.
142299         * modules/putenv (Makefile.am): Likewise.
142300         * modules/quote (Makefile.am): Likewise.
142301         * modules/quotearg (Makefile.am): Likewise.
142302         * modules/raise (Makefile.am): Likewise.
142303         * modules/read-file (Makefile.am): Likewise.
142304         * modules/readline (Makefile.am): Likewise.
142305         * modules/readlink (Makefile.am): Likewise.
142306         * modules/readtokens (Makefile.am): Likewise.
142307         * modules/readutmp (Makefile.am): Likewise.
142308         * modules/realloc (Makefile.am): Likewise.
142309         * modules/regex (Makefile.am): Likewise.
142310         * modules/rename-dest-slash (Makefile.am): Likewise.
142311         * modules/rename (Makefile.am): Likewise.
142312         * modules/rijndael (Makefile.am): Likewise.
142313         * modules/rmdir (Makefile.am): Likewise.
142314         * modules/rpmatch (Makefile.am): Likewise.
142315         * modules/safe-read (Makefile.am): Likewise.
142316         * modules/safe-write (Makefile.am): Likewise.
142317         * modules/same-inode (Makefile.am): Likewise.
142318         * modules/same (Makefile.am): Likewise.
142319         * modules/save-cwd (Makefile.am): Likewise.
142320         * modules/savedir (Makefile.am): Likewise.
142321         * modules/setenv (Makefile.am): Likewise.
142322         * modules/settime (Makefile.am): Likewise.
142323         * modules/sha1 (Makefile.am): Likewise.
142324         * modules/sig2str (Makefile.am): Likewise.
142325         * modules/snprintf (Makefile.am): Likewise.
142326         * modules/stat-macros (Makefile.am): Likewise.
142327         * modules/stat-time (Makefile.am): Likewise.
142328         * modules/stdbool (Makefile.am): Likewise.
142329         * modules/stdint (Makefile.am): Likewise.
142330         * modules/stdlib-safer (Makefile.am): Likewise.
142331         * modules/stpcpy (Makefile.am): Likewise.
142332         * modules/stpncpy (Makefile.am): Likewise.
142333         * modules/strcase (Makefile.am): Likewise.
142334         * modules/strcasestr (Makefile.am): Likewise.
142335         * modules/strchrnul (Makefile.am): Likewise.
142336         * modules/strcspn (Makefile.am): Likewise.
142337         * modules/strdup (Makefile.am): Likewise.
142338         * modules/strerror (Makefile.am): Likewise.
142339         * modules/strftime (Makefile.am): Likewise.
142340         * modules/strndup (Makefile.am): Likewise.
142341         * modules/strnlen (Makefile.am): Likewise.
142342         * modules/strpbrk (Makefile.am): Likewise.
142343         * modules/strsep (Makefile.am): Likewise.
142344         * modules/strstr (Makefile.am): Likewise.
142345         * modules/strtod (Makefile.am): Likewise.
142346         * modules/strtoimax (Makefile.am): Likewise.
142347         * modules/strtok_r (Makefile.am): Likewise.
142348         * modules/strtol (Makefile.am): Likewise.
142349         * modules/strtoll (Makefile.am): Likewise.
142350         * modules/strtoul (Makefile.am): Likewise.
142351         * modules/strtoull (Makefile.am): Likewise.
142352         * modules/strtoumax (Makefile.am): Likewise.
142353         * modules/strverscmp (Makefile.am): Likewise.
142354         * modules/sys_socket (Makefile.am): Likewise.
142355         * modules/sys_stat (Makefile.am): Likewise.
142356         * modules/sysexits (Makefile.am): Likewise.
142357         * modules/time_r (Makefile.am): Likewise.
142358         * modules/timegm (Makefile.am): Likewise.
142359         * modules/timespec (Makefile.am): Likewise.
142360         * modules/tmpfile-safer (Makefile.am): Likewise.
142361         * modules/trim (Makefile.am): Likewise.
142362         * modules/unistd-safer (Makefile.am): Likewise.
142363         * modules/unlinkdir (Makefile.am): Likewise.
142364         * modules/unlocked-io (Makefile.am): Likewise.
142365         * modules/userspec (Makefile.am): Likewise.
142366         * modules/utime (Makefile.am): Likewise.
142367         * modules/utimecmp (Makefile.am): Likewise.
142368         * modules/utimens (Makefile.am): Likewise.
142369         * modules/vasnprintf (Makefile.am): Likewise.
142370         * modules/vasprintf (Makefile.am): Likewise.
142371         * modules/vsnprintf (Makefile.am): Likewise.
142372         * modules/xalloc (Makefile.am): Likewise.
142373         * modules/xgetcwd (Makefile.am): Likewise.
142374         * modules/xnanosleep (Makefile.am): Likewise.
142375         * modules/xreadlink (Makefile.am): Likewise.
142376         * modules/xstrtod (Makefile.am): Likewise.
142377         * modules/xstrtol (Makefile.am): Likewise.
142378         * modules/xstrtold (Makefile.am): Likewise.
142379         * modules/yesno (Makefile.am): Likewise.
142380         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
142382 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
142384         * modules/error (Makefile.am): Distribute files through
142385         EXTRA_DIST, not lib_SOURCES.
142387 2006-10-12  Eric Blake  <ebb9@byu.net>
142389         * modules/error (Makefile.am): Distribute files in /lib.
142390         * modules/obstack (Makefile.am): Likewise.
142392 2006-10-12  Bruno Haible  <bruno@clisp.org>
142394         * modules/acl (Makefile.am): Distribute all files in lib/ through
142395         EXTRA_DIST.
142396         * modules/arcfour (Makefile.am): Likewise.
142397         * modules/arctwo (Makefile.am): Likewise.
142398         * modules/argmatch (Makefile.am): Likewise.
142399         * modules/argz (Makefile.am): Likewise.
142400         * modules/atexit (Makefile.am): Likewise.
142401         * modules/backupfile (Makefile.am): Likewise.
142402         * modules/c-strtod (Makefile.am): Likewise.
142403         * modules/c-strtold (Makefile.am): Likewise.
142404         * modules/calloc (Makefile.am): Likewise.
142405         * modules/canon-host (Makefile.am): Likewise.
142406         * modules/canonicalize (Makefile.am): Likewise.
142407         * modules/chdir-long (Makefile.am): Likewise.
142408         * modules/chdir-safer (Makefile.am): Likewise.
142409         * modules/check-version (Makefile.am): Likewise.
142410         * modules/chown (Makefile.am): Likewise.
142411         * modules/cloexec (Makefile.am): Likewise.
142412         * modules/close-stream (Makefile.am): Likewise.
142413         * modules/closeout (Makefile.am): Likewise.
142414         * modules/crc (Makefile.am): Likewise.
142415         * modules/cycle-check (Makefile.am): Likewise.
142416         * modules/des (Makefile.am): Likewise.
142417         * modules/dirfd (Makefile.am): Likewise.
142418         * modules/dirname (Makefile.am): Likewise.
142419         * modules/dup2 (Makefile.am): Likewise.
142420         * modules/euidaccess (Makefile.am): Likewise.
142421         * modules/exclude (Makefile.am): Likewise.
142422         * modules/exitfail (Makefile.am): Likewise.
142423         * modules/fcntl-safer (Makefile.am): Likewise.
142424         * modules/file-type (Makefile.am): Likewise.
142425         * modules/fileblocks (Makefile.am): Likewise.
142426         * modules/filemode (Makefile.am): Likewise.
142427         * modules/filenamecat (Makefile.am): Likewise.
142428         * modules/fnmatch (Makefile.am): Likewise.
142429         * modules/fopen-safer (Makefile.am): Likewise.
142430         * modules/fpending (Makefile.am): Likewise.
142431         * modules/fprintftime (Makefile.am): Likewise.
142432         * modules/free (Makefile.am): Likewise.
142433         * modules/fsusage (Makefile.am): Likewise.
142434         * modules/ftruncate (Makefile.am): Likewise.
142435         * modules/fts (Makefile.am): Likewise.
142436         * modules/gc (Makefile.am): Likewise.
142437         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
142438         * modules/getaddrinfo (Makefile.am): Likewise.
142439         * modules/getcwd (Makefile.am): Likewise.
142440         * modules/getdelim (Makefile.am): Likewise.
142441         * modules/getdomainname (Makefile.am): Likewise.
142442         * modules/getgroups (Makefile.am): Likewise.
142443         * modules/gethostname (Makefile.am): Likewise.
142444         * modules/gethrxtime (Makefile.am): Likewise.
142445         * modules/getline (Makefile.am): Likewise.
142446         * modules/getloadavg (Makefile.am): Likewise.
142447         * modules/getlogin_r (Makefile.am): Likewise.
142448         * modules/getopt (Makefile.am): Likewise.
142449         * modules/getpass (Makefile.am): Likewise.
142450         * modules/getpass-gnu (Makefile.am): Likewise.
142451         * modules/getsubopt (Makefile.am): Likewise.
142452         * modules/gettime (Makefile.am): Likewise.
142453         * modules/gettimeofday (Makefile.am): Likewise.
142454         * modules/getugroups (Makefile.am): Likewise.
142455         * modules/getusershell (Makefile.am): Likewise.
142456         * modules/glob (Makefile.am): Likewise.
142457         * modules/group-member (Makefile.am): Likewise.
142458         * modules/hard-locale (Makefile.am): Likewise.
142459         * modules/hash (Makefile.am): Likewise.
142460         * modules/hmac-md5 (Makefile.am): Likewise.
142461         * modules/hmac-sha1 (Makefile.am): Likewise.
142462         * modules/human (Makefile.am): Likewise.
142463         * modules/idcache (Makefile.am): Likewise.
142464         * modules/imaxabs (Makefile.am): Likewise.
142465         * modules/imaxdiv (Makefile.am): Likewise.
142466         * modules/inet_ntop (Makefile.am): Likewise.
142467         * modules/inet_pton (Makefile.am): Likewise.
142468         * modules/inttostr (Makefile.am): Likewise.
142469         * modules/isapipe (Makefile.am): Likewise.
142470         * modules/lchown (Makefile.am): Likewise.
142471         * modules/long-options (Makefile.am): Likewise.
142472         * modules/lstat (Makefile.am): Likewise.
142473         * modules/malloc (Makefile.am): Likewise.
142474         * modules/mathl (Makefile.am): Likewise.
142475         * modules/mbchar (Makefile.am): Likewise.
142476         * modules/md2 (Makefile.am): Likewise.
142477         * modules/md4 (Makefile.am): Likewise.
142478         * modules/md5 (Makefile.am): Likewise.
142479         * modules/memcasecmp (Makefile.am): Likewise.
142480         * modules/memchr (Makefile.am): Likewise.
142481         * modules/memcmp (Makefile.am): Likewise.
142482         * modules/memcoll (Makefile.am): Likewise.
142483         * modules/memcpy (Makefile.am): Likewise.
142484         * modules/memmem (Makefile.am): Likewise.
142485         * modules/memmove (Makefile.am): Likewise.
142486         * modules/mempcpy (Makefile.am): Likewise.
142487         * modules/memrchr (Makefile.am): Likewise.
142488         * modules/memset (Makefile.am): Likewise.
142489         * modules/memxor (Makefile.am): Likewise.
142490         * modules/mkancesdirs (Makefile.am): Likewise.
142491         * modules/mkdir (Makefile.am): Likewise.
142492         * modules/mkdir-p (Makefile.am): Likewise.
142493         * modules/mkdtemp (Makefile.am): Likewise.
142494         * modules/mkstemp (Makefile.am): Likewise.
142495         * modules/mktime (Makefile.am): Likewise.
142496         * modules/modechange (Makefile.am): Likewise.
142497         * modules/mountlist (Makefile.am): Likewise.
142498         * modules/nanosleep (Makefile.am): Likewise.
142499         * modules/openat (Makefile.am): Likewise.
142500         * modules/pagealign_alloc (Makefile.am): Likewise.
142501         * modules/physmem (Makefile.am): Likewise.
142502         * modules/poll (Makefile.am): Likewise.
142503         * modules/posixtm (Makefile.am): Likewise.
142504         * modules/posixver (Makefile.am): Likewise.
142505         * modules/putenv (Makefile.am): Likewise.
142506         * modules/quote (Makefile.am): Likewise.
142507         * modules/quotearg (Makefile.am): Likewise.
142508         * modules/raise (Makefile.am): Likewise.
142509         * modules/read-file (Makefile.am): Likewise.
142510         * modules/readline (Makefile.am): Likewise.
142511         * modules/readlink (Makefile.am): Likewise.
142512         * modules/readtokens (Makefile.am): Likewise.
142513         * modules/readutmp (Makefile.am): Likewise.
142514         * modules/realloc (Makefile.am): Likewise.
142515         * modules/regex (Makefile.am): Likewise.
142516         * modules/rename (Makefile.am): Likewise.
142517         * modules/rename-dest-slash (Makefile.am): Likewise.
142518         * modules/rijndael (Makefile.am): Likewise.
142519         * modules/rmdir (Makefile.am): Likewise.
142520         * modules/rpmatch (Makefile.am): Likewise.
142521         * modules/safe-read (Makefile.am): Likewise.
142522         * modules/safe-write (Makefile.am): Likewise.
142523         * modules/same (Makefile.am): Likewise.
142524         * modules/save-cwd (Makefile.am): Likewise.
142525         * modules/savedir (Makefile.am): Likewise.
142526         * modules/setenv (Makefile.am): Likewise.
142527         * modules/settime (Makefile.am): Likewise.
142528         * modules/sha1 (Makefile.am): Likewise.
142529         * modules/sig2str (Makefile.am): Likewise.
142530         * modules/snprintf (Makefile.am): Likewise.
142531         * modules/stdlib-safer (Makefile.am): Likewise.
142532         * modules/stpcpy (Makefile.am): Likewise.
142533         * modules/stpncpy (Makefile.am): Likewise.
142534         * modules/strcase (Makefile.am): Likewise.
142535         * modules/strcasestr (Makefile.am): Likewise.
142536         * modules/strchrnul (Makefile.am): Likewise.
142537         * modules/strcspn (Makefile.am): Likewise.
142538         * modules/strdup (Makefile.am): Likewise.
142539         * modules/strerror (Makefile.am): Likewise.
142540         * modules/strftime (Makefile.am): Likewise.
142541         * modules/strndup (Makefile.am): Likewise.
142542         * modules/strnlen (Makefile.am): Likewise.
142543         * modules/strpbrk (Makefile.am): Likewise.
142544         * modules/strsep (Makefile.am): Likewise.
142545         * modules/strstr (Makefile.am): Likewise.
142546         * modules/strtod (Makefile.am): Likewise.
142547         * modules/strtoimax (Makefile.am): Likewise.
142548         * modules/strtok_r (Makefile.am): Likewise.
142549         * modules/strtol (Makefile.am): Likewise.
142550         * modules/strtoll (Makefile.am): Likewise.
142551         * modules/strtoul (Makefile.am): Likewise.
142552         * modules/strtoull (Makefile.am): Likewise.
142553         * modules/strtoumax (Makefile.am): Likewise.
142554         * modules/strverscmp (Makefile.am): Likewise.
142555         * modules/time_r (Makefile.am): Likewise.
142556         * modules/timegm (Makefile.am): Likewise.
142557         * modules/tmpfile-safer (Makefile.am): Likewise.
142558         * modules/unistd-safer (Makefile.am): Likewise.
142559         * modules/unlinkdir (Makefile.am): Likewise.
142560         * modules/userspec (Makefile.am): Likewise.
142561         * modules/utime (Makefile.am): Likewise.
142562         * modules/utimecmp (Makefile.am): Likewise.
142563         * modules/utimens (Makefile.am): Likewise.
142564         * modules/vasnprintf (Makefile.am): Likewise.
142565         * modules/vasprintf (Makefile.am): Likewise.
142566         * modules/vsnprintf (Makefile.am): Likewise.
142567         * modules/xalloc (Makefile.am): Likewise.
142568         * modules/xgetcwd (Makefile.am): Likewise.
142569         * modules/xnanosleep (Makefile.am): Likewise.
142570         * modules/xreadlink (Makefile.am): Likewise.
142571         * modules/xstrtod (Makefile.am): Likewise.
142572         * modules/xstrtol (Makefile.am): Likewise.
142573         * modules/xstrtold (Makefile.am): Likewise.
142574         * modules/yesno (Makefile.am): Likewise.
142576 2006-10-12  Jim Meyering  <jim@meyering.net>
142578         * m4/getloadavg.m4: Revert the change below.
142580         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
142581         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
142582         fail with a symlink, which is what coreutils' ./bootstrap now
142583         creates by default.
142585 2006-10-12  Bruno Haible  <bruno@clisp.org>
142587         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
142588         mingw.
142589         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
142590         MSVC and mingw explicitly.
142592 2006-10-11  Simon Josefsson  <jas@extundo.com>
142593             Bruno Haible  <bruno@clisp.org>
142595         Add support for multiple gnulib-tool invocations in the scope of a
142596         single configure.ac file.
142597         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
142598         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
142599         with the same contents as the _LIBADD variable.
142600         (func_emit_initmacro_start, func_emit_initmacro_end,
142601         func_emit_initmacro_done): New functions.
142602         (func_import, func_create_testdir): Invoke them. Allow the identifiers
142603         gl_LIBOBJS and gl_LTLIBOBJS.
142605 2006-10-11  Bruno Haible  <bruno@clisp.org>
142607         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
142608         (func_create_testdir): Don't create po/Makefile.am, don't invoke
142609         autoreconf. Instead, invoke autopoint explicitly but move back the
142610         *.m4 files from gnulib.
142612 2006-10-11  Bruno Haible  <bruno@clisp.org>
142614         * gnulib-tool (func_usage): Make module names after --create-testdir
142615         optional.
142616         (func_create_testdir): If no module was specified, use nearly all
142617         modules.
142619 2006-10-12  Jim Meyering  <jim@meyering.net>
142621         Big performance improvement for fts-based tools that use FTS_NOSTAT.
142622         Avoid spurious inode-mismatch problems on non-POSIX file systems.
142623         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
142624         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
142625         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
142626         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
142627         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
142628         (fts_set_stat_required): New function.
142629         (fts_open): Defer the calls to fts_stat, if possible or requested.
142630         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
142631         into fts_stat itself.
142632         (fts_read): Perform any required (deferred) fts_stat call.
142633         (fts_build): Likewise, for the directory we're about to open and read.
142634         In the readdir loop, carefully decide whether each entry will require
142635         an eventual call to fts_stat, using dirent.d_type info if available.
142636         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
142637         a command line argument into this function.  Update all callers.
142638         Map a return value of FTS_DOT to FTS_D for a command line argument.
142639         * modules/fts (Depends-on): Add d-type.  Alphabetize.
142640         Thanks to Miklos Szeredi for his tenacity and for the initial
142641         bug report about "find" failing on a FUSE-based file system.
142643         * lib/fts.c (fts_open): Use consistent indentation.
142645 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
142647         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
142648         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
142649         reported by Jim Meyering.  All uses of cache variables renamed
142650         to match Autoconf's.
142651         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
142652         the other one.
142654         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
142655         Fix misspelling in diagnostic.
142657 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
142659         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
142660         defined.  Problem reported by Matthew Woehlke.
142662         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
142663         Add support for Tandem NonStop R series.
142664         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
142665         Use new macro.
142667         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
142668         (has_trailing_slash): Omit size arg; all callers changed.
142669         Omit 'inline', since it doesn't help performance and we'd
142670         need to configure it.
142671         Don't count //, ///, etc. as having a trailing slash.
142672         As a side effect, this removes a C99ism reported by Matthew Woehlke.
142673         (rpl_rename_dest_slash): On failure, use rename's errno rather
142674         than (in some cases) an incorrect or junk errno.
142675         Simplify code by removing need to compute length; this does
142676         cause it to make two passes instead of one over the file name,
142677         but it's worth it.
142679         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
142680         change, since Autoconf's version may no longer be appropriate now
142681         that we are using CVS Autoconf's version.  Add support for Tandem.
142683 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
142684             Bruno Haible  <bruno@clisp.org>
142686         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
142687         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
142688         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
142689         gl_AC_TYPE_LONG_LONG.
142691         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
142692         instead of HAVE_LONG_LONG.
142693         * lib/printf-args.c (printf_fetchargs): Likewise.
142694         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
142695         * lib/vasnprintf.c (VASNPRINTF): Likewise.
142696         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
142697         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
142698         gl_AC_TYPE_LONG_LONG.
142700 2006-10-11  Bruno Haible  <bruno@clisp.org>
142702         * m4/longlong.m4: Add comments.
142703         * m4/ulonglong.m4: Likewise.
142705 2006-10-10  Bruno Haible  <bruno@clisp.org>
142707         Make it possible to #define stpcpy, strdup to aliases.
142708         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
142709         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
142711 2006-10-10  Bruno Haible  <bruno@clisp.org>
142713         Make it possible to #define gcd to an alias.
142714         * lib/gcd.c: Include config.h.
142716 2006-10-10  Bruno Haible  <bruno@clisp.org>
142718         Make it possible to #define c_isascii to an alias.
142719         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
142720         defined. Undefine the macros before defining them, to avoid gcc
142721         warnings.
142722         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
142723         define NO_C_CTYPE_MACROS early.
142725 2006-10-10  Bruno Haible  <bruno@clisp.org>
142727         Make it possible to #define set_program_name to an alias.
142728         * lib/progname.c: Don't undefine set_program_name; instead, undefine
142729         ENABLE_RELOCATABLE early.
142731 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
142733         Port to Tandem NSK OSS, which has 64-bit signed int but at most
142734         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
142735         http://lists.gnu.org/r/bug-coreutils/2006-10/msg00062.html
142736         More generally, don't assume that 64-bit signed int is available
142737         if unsigned int is, and vice versa.
142738         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
142739         unsigned symbols, not on their signed counterparts.
142740         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
142741         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
142742         (UINT64_C, UINTMAX_C):
142743         Likewise.
142744         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
142745         unsigned counterparts.
142746         (Have_long_long, Unsigned): New macros.
142747         (Int): Renamed from INT.
142748         (strtoimax): Use the new macros.
142749         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
142750         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
142751         * modules/inttypes (inttypes.h): Substitute
142752         HAVE_UNSIGNED_LONG_LONG_INT.
142753         * modules/stdint (stdint.h): Likewise.
142754         (Files): Add m4/ulonglong.m4.
142756 2006-10-10  Bruno Haible  <bruno@clisp.org>
142758         Fix a gcc -Wshadow warning.
142759         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
142760         to 'bucket'.
142761         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
142762         gl_linked_indexof_from_to): Likewise.
142763         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
142764         Likewise.
142765         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
142766         Likewise.
142767         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
142768         Reported by Eric Blake.
142770 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
142772         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
142773         for NetBSD.  Problem reported by Bruno Haible.
142775 2006-10-09  Jim Meyering  <jim@meyering.net>
142777         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
142778         Patch from Bruno Haible.
142780 2006-10-09  Jim Meyering  <jim@meyering.net>
142782         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
142783         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
142784         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
142786 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
142788         Don't include <config.h> twice; this doesn't work in some cases,
142789         e.g., when config.h has "#define intmax_t long long int" and
142790         we include <config.h>, <inttypes.h>, <config.h> in that order.
142791         Problem reported by Matthew Woehlke in:
142792         http://lists.gnu.org/r/bug-coreutils/2006-10/msg00073.html
142793         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
142794         * lib/fts-cycle.c: Don't include config.h.
142795         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
142796         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
142797         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
142798         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
142799         inttypes.h.
142800         * lib/xstrtoumax.c: Likewise.
142801         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
142802         __strtol and the like, so that this module is more like its siblings.
142803         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
142804         Remove; no longer needed now that we assume gnulib inttypes.h.
142806 2006-10-08  Bruno Haible  <bruno@clisp.org>
142808         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
142809         option.
142811 2006-10-07  Jim Meyering  <jim@meyering.net>
142813         * modules/inttypes (inttypes.h): Revert what seems to have been
142814         an inadvertent part of today's change: use "|", not "/" in the
142815         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
142817 2006-10-07  Bruno Haible  <bruno@clisp.org>
142819         * modules/sublist: New file.
142821 2006-10-07  Bruno Haible  <bruno@clisp.org>
142823         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
142824         * modules/argz (argz.h): Likewise.
142825         * modules/arpa_inet (arpa/inet.h): Likewise.
142826         * modules/byteswap (byteswap.h): Likewise.
142827         * modules/configmake (configmake.h): Likewise.
142828         * modules/fcntl (fcntl.h): Likewise.
142829         * modules/fnmatch (fnmatch.h): Likewise.
142830         * modules/getopt (getopt.h): Likewise.
142831         * modules/glob (glob.h): Likewise.
142832         * modules/inttypes (inttypes.h): Likewise.
142833         * modules/netinet_in (netinet/in.h): Likewise.
142834         * modules/poll (poll.h): Likewise.
142835         * modules/stdbool (stdbool.h): Likewise.
142836         * modules/stdint (stdint.h): Likewise.
142837         * modules/sys_select (sys/select.h): Likewise.
142838         * modules/sys_socket (sys/socket.h): Likewise.
142839         * modules/sys_stat (sys/stat.h): Likewise.
142840         * modules/sysexits (sysexits.h): Likewise.
142841         * modules/unistd (unistd.h): Likewise.
142842         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
142843         Add a "DO NOT EDIT" comment to the generated file.
142844         (func_import): Likewise for gnulib-comp.m4.
142846 2006-10-07  Bruno Haible  <bruno@clisp.org>
142848         * lib/gl_sublist.h: New file.
142849         * lib/gl_sublist.c: New file.
142851 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
142853         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
142854         name (relative to the original working directory) and the file
142855         name component (relative to the temporary working directory).  All
142856         callers changed.
142857         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
142858         * lib/mkdir-p.c (make_dir_parents): Likewise.
142859         * lib/mkdir-p.h (make_dir_parents): Likewise.
142861 2006-10-06  Eric Blake  <ebb9@byu.net>
142863         Define several macros for use by the clean-temp module.
142864         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
142865         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
142866         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
142868         * lib/clean-temp.h (close_stream_temp): New declaration.
142869         * lib/clean-temp.c (includes): Pull in headers according to what
142870         other modules are in use.
142871         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
142873 2006-10-06  Bruno Haible  <bruno@clisp.org>
142875         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
142876         instead of fopen, fwriteerror.
142878 2006-10-06  Bruno Haible  <bruno@clisp.org>
142880         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
142881         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
142882         int.
142883         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
142884         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
142885         Return an error indicator.
142886         Suggested by Eric Blake.
142888 2006-10-06  Bruno Haible  <bruno@clisp.org>
142890         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
142891         Reported by Eric Blake.
142893 2006-10-06  Bruno Haible  <bruno@clisp.org>
142895         * modules/closeout (Description): Mention stderr too.
142897 2006-10-06  Bruno Haible  <bruno@clisp.org>
142898         and Paul Eggert  <eggert@cs.ucla.edu>
142900         * lib/closeout.c (close_stdout): Also close stderr.
142901         * lib/closeout.h: Update comment.
142903 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
142905         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
142906         <http://lists.gnu.org/r/bug-coreutils/2006-10/msg00063.html>.
142907         * lib/dirchownmod.c: Include lchown.h.
142908         * lib/lchown.c: Don't include files that lchown.h now includes.
142909         Don't declare chown, since lchown.h now does that.
142910         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
142911         (lchown): Define to rpl_chown if lchown is declared but
142912         does not exist.  Declare using a prototype if lchown is not
142913         declared.  Add a copyright notice.
142914         * lib/mkstemp.h: Include <unistd.h>.
142915         * lib/openat.c: Include lchown.h.
142917         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
142918         we now test for that separately.
142919         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
142920         rather than O_NOFOLLOW, when testing whether it's possible to
142921         avoid a race condition reliably.
142922         * lib/savewd.c (savewd_chdir): Likewise.
142924         Remove macros that are no longer needed now that stdint.h is
142925         reliable.
142926         * lib/fsusage.c (UINTMAX_MAX): Remove.
142927         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
142928         * lib/utimecmp.c (SIZE_MAX): Remove.
142930         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
142932         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
142933         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
142934         O_NOATIME works.
142936 2006-10-05  Bruno Haible  <bruno@clisp.org>
142938         * lib/gl_list.h (gl_sortedlist_search_from_to,
142939         gl_sortedlist_indexof_from_to): New declarations.
142940         (gl_list_implementation): New fields sortedlist_search_from_to,
142941         sortedlist_indexof_from_to.
142942         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
142943         inline functions.
142944         * lib/gl_list.c (gl_sortedlist_search_from_to,
142945         gl_sortedlist_indexof_from_to): New functions.
142946         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
142947         function.
142948         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
142949         (gl_array_sortedlist_search_from_to): New function.
142950         (gl_array_list_implementation): Update.
142951         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
142952         function.
142953         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
142954         (gl_carray_sortedlist_search_from_to): New function.
142955         (gl_carray_list_implementation): Update.
142956         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
142957         gl_linked_sortedlist_indexof_from_to): New functions.
142958         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
142959         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
142960         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
142961         gl_tree_sortedlist_indexof_from_to): New functions.
142962         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
142963         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
142964         Update.
142965         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
142966         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
142967         Update.
142969 2006-10-05  Bruno Haible  <bruno@clisp.org>
142971         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
142972         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
142973         (struct gl_list_implementation): Add fields search_from_to,
142974         indexof_from_to. Remove fields search, indexof.
142975         (gl_list_search): Use the search_from_to method.
142976         (gl_list_search_from, gl_list_search_from_to): New functions.
142977         (gl_list_indexof): Use the indexof_from_to method.
142978         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
142979         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
142980         (gl_list_search_from, gl_list_search_from_to): New functions.
142981         (gl_list_indexof): Use the indexof_from_to method.
142982         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
142983         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
142984         gl_array_indexof. Add start_index, end_index arguments.
142985         (gl_array_search_from_to): Renamed from gl_array_search. Add
142986         start_index, end_index arguments.
142987         (gl_array_remove, gl_array_list_implementation): Update.
142988         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
142989         gl_carray_indexof. Add start_index, end_index arguments.
142990         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
142991         start_index, end_index arguments.
142992         (gl_carray_remove, gl_carray_list_implementation): Update.
142993         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
142994         gl_linked_search. Add start_index, end_index arguments.
142995         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
142996         start_index, end_index arguments.
142997         (gl_linked_remove): Update.
142998         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
142999         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
143000         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
143001         field to 'size_t'.
143002         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
143003         gl_tree_search. Add start_index, end_index arguments.
143004         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
143005         start_index, end_index arguments.
143006         (gl_tree_remove): Update.
143007         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
143008         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
143009         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
143010         function.
143011         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
143012         gl_tree_search. Add start_index, end_index arguments.
143013         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
143014         start_index, end_index arguments.
143015         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
143016         Update.
143017         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
143019 2006-10-05  Bruno Haible  <bruno@clisp.org>
143021         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
143023         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
143024         fwriteerror_temp): New declarations.
143025         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
143026         (descriptors): New variable.
143027         (cleanup): First, close the descriptors.
143028         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
143029         fclose_temp, fwriteerror_temp): New functions.
143031 2006-10-04  Jim Meyering  <jim@meyering.net>
143033         * lib/fts.c (fts_open): Tiny comment change.
143035 2006-10-04  Bruno Haible  <bruno@clisp.org>
143037         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
143038         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
143039         gl_LOCK_BODY.
143040         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
143041         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
143042         gl_LOCK_EARLY_BODY.
143043         (gl_LOCK): Require gl_LOCK_BODY.
143045 2006-10-04  Bruno Haible  <bruno@clisp.org>
143047         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
143048         (gl_oset_search_atleast): New declaration.
143049         (struct gl_oset_implementation): Add field 'search_atleast'.
143050         (gl_oset_search_atleast): New inline function.
143051         * lib/gl_oset.c (gl_oset_search_atleast): New function.
143052         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
143053         (gl_array_oset_implementation): Update.
143054         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
143055         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
143056         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
143058 2006-10-04  Bruno Haible  <bruno@clisp.org>
143060         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
143062 2006-10-03  Bruno Haible  <bruno@clisp.org>
143064         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
143065         from gl_avltreehash_list_implementation.
143067 2006-10-03  Bruno Haible  <bruno@clisp.org>
143069         * lib/gl_oset.c (gl_oset_add): Fix return type.
143071 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
143073         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
143075 2006-10-02  Eric Blake  <ebb9@byu.net>
143077         * modules/strnlen (Depends-on): Add extensions.
143079 2006-10-02  Eric Blake  <ebb9@byu.net>
143081         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
143082         definition in 2.60+.
143084 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
143086         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
143087         checks.
143089 2006-10-02  Bruno Haible  <bruno@clisp.org>
143091         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
143092         to the AUTOMAKE_OPTIONS.
143093         Reported by Jim Meyering.
143095 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
143097         Work around bug in Solaris 10 /proc file system:
143098         /proc/self/fd/NNN/.. isn't the parent directory of
143099         the directory whose file descriptor is NNN.  This needs to
143100         be worked around at run time, not compile time, since a
143101         program might be built on Solaris 8, where things work, and
143102         run on Solaris 10.
143103         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
143104         to use the following interface instead:
143105         (OPENAT_BUFFER_SIZE): New macro.
143106         (openat_proc_name): New function.
143107         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
143108         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
143109         Likewise.
143110         * lib/openat-proc.c: New file.
143111         * modules/openat (Files): Add lib/openat-proc.c.
143112         (Depends-on): Add same-inode, stdbool.
143113         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
143115 2006-09-29  Bruno Haible  <bruno@clisp.org>
143117         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
143118         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
143119         argument. Set stdout_closed before testing for ferror, not after.
143120         (fwriteerror, fwriteerror_no_ebadf): New functions.
143122 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143124         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
143126 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
143128         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
143129         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
143131 2006-09-28  Jim Meyering  <jim@meyering.net>
143133         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
143134         Include <unistd.h>.
143136 2006-09-28  Bruno Haible  <bruno@clisp.org>
143138         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
143139         * modules/linkedhash-list (Depends-on): Likewise.
143140         * modules/rbtreehash-list (Depends-on): Likewise.
143142 2006-09-28  Bruno Haible  <bruno@clisp.org>
143144         * lib/strndup.h: Simplify the redefinition of strndup.
143145         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
143146         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
143148 2006-09-28  Bruno Haible  <bruno@clisp.org>
143150         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
143151         * lib/gl_linkedhash_list.c: Likewise.
143152         * lib/gl_rbtreehash_list.c: Likewise.
143154 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
143156         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
143157         getaddrinfo.
143159         * lib/__fpending.h: Don't include <stdio_ext.h> unless
143160         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
143161         it causes <stdio_ext.h> to cause a compile-time error.
143162         Problem reported by Nelson H. F. Beebe.
143163         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
143164         of HAVE_DECL___PENDING.
143166         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
143167         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
143168         declaration.
143170 2006-09-27  Jim Meyering  <jim@meyering.net>
143172         This file could end up with a definition for a function
143173         named __strndup, rather than rpl_strndup on a system with
143174         incomplete weak_alias support.
143175         * lib/strndup.c (strndup): Rename from __strndup.
143176         Remove #defines that used to map __strndup to strndup.
143177         Don't use K&R prototypes.
143178         Remove LIBC-related code, since this file is not sync'd with glibc.
143179         * lib/strndup.h: Revamp, accordingly.
143180         * m4/strndup.m4: Modernize.
143182 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
143184         * modules/savewd (Depends-on): Add 'raise'.
143185         * lib/savewd.c: Include <signal.h>, for 'raise'.
143187 2006-09-26  Jim Meyering  <jim@meyering.net>
143189         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
143190         when we detect Darwin 8.7.0's acl_get_file bug.
143191         Rearrange to perform the new (below) run-test while $LIBS
143192         contains any acl-related library.  Set USE_ACL at the end.
143193         (gl_ACL_GET_FILE): New function.
143195 2006-09-26  Eric Blake  <ebb9@byu.net>
143197         * lib/verror.c: Include <config.h> unconditionally.
143199 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
143201         * modules/clock-time (Maintainer): Add self.
143202         * modules/getlogin_r (Depends-on): Add extensions.
143204 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143206         * modules/clock-time: New module.
143207         * modules/nanosleep (Depends-on): Add clock-time.
143208         * modules/gethrxtime (Depends-on): Likewise.
143209         * modules/gettime (Depends-on): Likewise.
143210         * modules/settime (Depends-on): Likewise.
143212         * modules/fts-lgpl: Depend on openat.
143213         * modules/mkancesdirs: Depend on savewd.
143214         * modules/mkdir-p: Likewise.
143216 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143218         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
143220         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
143221         `gl_have_arbitrary_file_name_length_limit' to
143222         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
143223         actually works between configure runs.
143225 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143226             Bruno Haible  <bruno@clisp.org>
143228         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
143230 2006-09-25  Jim Meyering  <jim@meyering.net>
143232         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
143233         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
143235 2006-09-25  Eric Blake  <ebb9@byu.net>
143237         * gnulib-tool (func_import, func_create_testdir): Fix typos in
143238         exec's in 2006-09-18 patch when shuffling fds.
143240 2006-09-25  Bruno Haible  <bruno@clisp.org>
143242         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
143243         Reported by Jim Meyering.
143245 2006-09-24  Jim Meyering  <jim@meyering.net>
143247         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
143248         compare a pointer against a literal "0".  That caused failures with
143249         at least HP-UX's hpcc.
143251 2006-09-22  Simon Josefsson  <jas@extundo.com>
143253         * modules/gc-sha1:
143254         * modules/gc-md4:
143255         * modules/gc-hmac-sha1:
143256         * modules/gc-hmac-md5:
143257         * modules/gc-des:
143258         * modules/gc-arcfour: Distribute more files.
143260 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143262         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
143263         (gl_linked_iterator_from_to): Initialize struct completely.
143264         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
143265         (gl_tree_iterator_from_to): Likewise
143266         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
143267         * lib/gl_array_list.c [lint] (gl_array_iterator)
143268         (gl_array_iterator_from_to): Likewise.
143269         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
143270         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
143271         (gl_carray_iterator_from_to): Likewise.
143273         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
143274         * lib/md4.c (md4_process_block): Remove unused variable.
143275         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
143276         parentheses for clarity.
143278 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143280         * modules/bison-i18n (Depends-on): Add gettext.
143282 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143284         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
143285         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
143286         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
143287         also add missing comma that caused broken test.
143288         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
143289         stdlib.h, for `abort'.
143290         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
143291         variables.
143292         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
143293         include unistd.h if present, for `rmdir'.
143294         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
143295         variables.
143296         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
143297         in the process include standard headers for prototypes.
143298         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
143299         gets declared on GNU/Linux.
143300         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
143301         unistd.h, for `rmdir'.
143302         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
143304         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
143305         always true.
143306         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
143308         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
143310 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143312         * gnulib-tool (func_version): Create output all at once.  This
143313         may help avoid triggering unnecessary SIGPIPEs, and at any
143314         rate it doesn't hurt.
143316 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143317             Bruno Haible  <bruno@clisp.org>
143319         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
143320         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
143321         * m4/signed.m4 (bh_C_SIGNED): Likewise.
143323         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
143324         (gl_FUNC_VASPRINTF): Invoke it.
143326 2006-09-22  Bruno Haible  <bruno@clisp.org>
143328         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
143329         getloadavg.c as first argument.
143331 2006-09-22  Bruno Haible  <bruno@clisp.org>
143333         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
143334         at the beginning of the gl_INIT macro.
143335         * modules/getloadavg (configure.ac): Pass $gl_source_base to
143336         gl_GETLOADAVG.
143338 2006-09-22  Bruno Haible  <bruno@clisp.org>
143340         * gnulib-tool (func_create_megatestdir): Don't include the config-h
143341         module.
143342         Suggested by Ralf Wildenhues.
143344 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
143346         Import this patch from libc:
143348         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
143350         * lib/regex_internal.c (re_string_reconstruct): Handle
143351         offset < pstr->valid_raw_len && pstr->offsets_needed case.
143352         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
143353         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
143354         re_string_context_at.
143356         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
143357         now requires it.
143358         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
143359         gl_REGEX now does it for us.
143360         (gl_REGEX): Add test taken from
143361         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
143363         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
143364         Check that large offsets work.  Modernize Autoconf usages.
143365         Prefer "yes" to mean a good thing rather than a bad.
143366         Don't put "#define mkstemp" in config.h, as this might interfere
143367         with standard system headers that "#define mkstemp mkstemp64".
143369         * modules/mkstemp (Depends-on): Add extensions, so that
143370         mkstemp is visible on some platforms.
143371         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
143372         (Include): Change to "mkstemp.h" from <stdlib.h>.
143373         (Files): Add mkstemp.h.
143375         * lib/mkstemp.h: New file, since some standard headers
143376         #define mkstemp.
143377         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
143378         Include "mkstemp.h".
143379         Make the _LIBC code resemble glibc original more,
143380         e.g., use K&R style.
143381         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
143382         (mkstemp): Remove, since mkstemp.h does this for us.
143383         * lib/stdlib--.h: Include mkstemp.h.
143385         Import this patch from libc:
143387         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
143389         * lib/tempname.c (__gen_tempname): Change attempts_min
143390         into a macro.  Use preprocessor to decide how to initialize
143391         attempts [Coverity CID 67].
143393 2006-09-20  Bruno Haible  <bruno@clisp.org>
143395         * lib/mkdtemp.c: Import from libc.
143396         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
143397                 * sysdeps/posix/tempname.c (__gen_tempname): Change
143398                 attempts_min into a macro.  Use preprocessor to decide how to
143399                 initialize attempts [Coverity CID 67].
143400         2001-11-27  Paul Eggert  <eggert@twinsun.com>
143401                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
143402                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
143404 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143406         * gnulib-tool (func_exit): New function, to allow to pass the
143407         exit status portably through the trap.  Use everywhere.
143408         (--help, --version): Signal a write error.
143409         (trap): catch SIGPIPE, for write errors.
143410         Exit at the end of the trap, with the correct exit status.
143412 2006-09-19  Karl Berry  <karl@gnu.org>
143414         * doc/gnulib.texi: note about the license texinfo files.
143416 2006-09-19  Eric Blake  <ebb9@byu.net>
143418         * gnulib-tool: Avoid space-tab.
143420 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
143422         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
143423         that prevented coreutils 6.1 from building.  Problem reported
143424         by Petter Reinholdtsen.
143426 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
143428         * gnulib-tool (avoidlist): Fix typo that broke options like
143429         --avoid=lock that are used by coreutils bootstrap.
143431 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
143433         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
143434         more systematically.
143436 2006-09-18  Jim Meyering  <jim@meyering.net>
143438         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
143440 2006-09-18  Bruno Haible  <bruno@clisp.org>
143442         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
143444 2006-09-18  Bruno Haible  <bruno@clisp.org>
143446         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
143447         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
143448         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
143449         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
143450         * m4/gettext.m4: Require autoconf >= 2.52.
143451         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
143452         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
143453         of gl_cv_header_inttypes_h.
143455 2006-09-18  Bruno Haible  <bruno@clisp.org>
143457         * lib/javaversion.c: Include configmake.h.
143459 2006-09-18  Bruno Haible  <bruno@clisp.org>
143461         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
143462         avoid that the while loops be executed in a subshell.
143464 2006-09-18  Bruno Haible  <bruno@clisp.org>
143466         * MODULES.html.sh (func_module): Break long lines.
143467         Suggested by Bruce Korb <bkorb@gnu.org>.
143469 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143471         Speed up by a factor of 1.12.
143472         * gnulib-tool (nl): New variable.
143473         (func_import): Rewrite include directive extraction to only read each
143474         directive once.
143476 2006-09-17  Bruno Haible  <bruno@clisp.org>
143478         * modules/javaversion (Makefile.am): Remove DEFS setting.
143479         (Depends-on): Add configmake, for PKGDATADIR definition.
143481 2006-09-17  Bruno Haible  <bruno@clisp.org>
143483         * gnulib-tool (func_create_testdir): Rewrite all files at once.
143485 2006-09-17  Bruno Haible  <bruno@clisp.org>
143487         * gnulib-tool (func_append): New function, stolen from libtool.m4.
143488         (func_modules_transitive_closure, func_modules_add_dummy,
143489         func_modules_to_filelist, func_import, func_create_testdir,
143490         func_create_megatestdir, ...): Use it wherever possible.
143491         Suggested by Ralf Wildenhues.
143493 2006-09-16  Karl Berry  <karl@gnu.org>
143495         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
143496         to avoid sectioning errors.
143497         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
143498         [ifinfo]: blank line after @center-ed titles.
143499         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
143500         Spell FSF address consistently with others.
143501         (These changes approved by rms.)
143503 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143505         Speed up by a factor of 1.61.
143506         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
143507         already checked module names again.
143509 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143511         Speed up by a factor of 1.13.
143512         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
143513         for new_files, and the input to func_add_or_update.
143515 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143517         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
143518         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
143520 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
143522         * modules/mkancesdirs (Depends-on): Add fcntl.
143523         * modules/savewd: New file.
143524         * MODULES.html.sh (File system functions): Add savewd.
143526         * modules/configmake (Makefile.am): Add support for the
143527         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
143529 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
143531         * m4/savewd.m4: New file.
143533 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
143535         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
143536         (dirchownmod): New arg FD.  All callers changed.
143537         Use FD rather than opening the directory ourself, as opening is
143538         now the caller's responsibility.
143539         * lib/dirchownmod.h: Likewise.
143540         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
143541         hosts that require <sys/types.h> before <sys/stat.h>.  Include
143542         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
143543         (test_dir): Remove.
143544         (mkancesdirs): Return length of prefix of FILE that has already
143545         been made, or -2 if there is a child doing the work.  Redo
143546         algorithm so that it is O(N) rather than O(N**2).  Optimize away
143547         ".", and treat ".." specially since it might stray back into
143548         already-created areas.  Use a subprocess if necessary.  New arg
143549         WD; all users changed.  MAKE_DIR function should now return 1
143550         if it creates a directory that is not readable.  Return -2 if
143551         a child process is spun off.
143552         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
143553         Adjust signature to match code.
143554         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
143555         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
143556         all users changed.
143557         * lib/savewd.c, lib/savewd.h: New files.
143559 2006-09-15  Jim Meyering  <jim@meyering.net>
143561         * modules/rename-dest-slash: New module.
143562         * MODULES.html.sh (posix_compat): Add it here.
143564         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
143566 2006-09-15  Jim Meyering  <jim@meyering.net>
143568         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
143569         file.
143571         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
143573 2006-09-15  Jim Meyering  <jim@meyering.net>
143575         * lib/rename-dest-slash.c (has_trailing_slash): Use
143576         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
143577         (rpl_rename_dest_slash): Perform the cheaper trailing slash
143578         test before testing whether SRC is a directory.
143579         Suggestions from Bruno Haible.
143581         Avoid a warning about an unused variable.
143582         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
143583         into the #ifdef block where it's used.
143585         * lib/rename-dest-slash.c: New file.
143587 2006-09-14  Bruno Haible  <bruno@clisp.org>
143589         * lib/allocsa.c: Include <config.h> unconditionally.
143590         * lib/asnprintf.c: Likewise.
143591         * lib/asprintf.c: Likewise.
143592         * lib/c-strcasecmp.c: Likewise.
143593         * lib/c-strcasestr.c: Likewise.
143594         * lib/c-strncasecmp.c: Likewise.
143595         * lib/c-strstr.c: Likewise.
143596         * lib/classpath.c: Likewise.
143597         * lib/clean-temp.c: Likewise.
143598         * lib/concatpath.c: Likewise.
143599         * lib/copy-file.c: Likewise.
143600         * lib/csharpcomp.c: Likewise.
143601         * lib/csharpexec.c: Likewise.
143602         * lib/execute.c: Likewise.
143603         * lib/fatal-signal.c: Likewise.
143604         * lib/findprog.c: Likewise.
143605         * lib/fwriteerror.c: Likewise.
143606         * lib/gl_array_list.c: Likewise.
143607         * lib/gl_array_oset.c: Likewise.
143608         * lib/gl_avltree_list.c: Likewise.
143609         * lib/gl_avltree_oset.c: Likewise.
143610         * lib/gl_avltreehash_list.c: Likewise.
143611         * lib/gl_carray_list.c: Likewise.
143612         * lib/gl_linked_list.c: Likewise.
143613         * lib/gl_linkedhash_list.c: Likewise.
143614         * lib/gl_list.c: Likewise.
143615         * lib/gl_oset.c: Likewise.
143616         * lib/gl_rbtree_list.c: Likewise.
143617         * lib/gl_rbtree_oset.c: Likewise.
143618         * lib/gl_rbtreehash_list.c: Likewise.
143619         * lib/imaxabs.c: Likewise.
143620         * lib/imaxdiv.c: Likewise.
143621         * lib/javacomp.c: Likewise.
143622         * lib/javaexec.c: Likewise.
143623         * lib/javaversion.c: Likewise.
143624         * lib/linebreak.c: Likewise.
143625         * lib/localcharset.c: Likewise.
143626         * lib/lock.c: Likewise.
143627         * lib/mbchar.c: Likewise.
143628         * lib/mbswidth.c: Likewise.
143629         * lib/mkdtemp.c: Likewise.
143630         * lib/pipe.c: Likewise.
143631         * lib/printf-args.c: Likewise.
143632         * lib/printf-parse.c: Likewise.
143633         * lib/progname.c: Likewise.
143634         * lib/progreloc.c: Likewise.
143635         * lib/readlink.c: Likewise.
143636         * lib/sh-quote.c: Likewise.
143637         * lib/stpcpy.c: Likewise.
143638         * lib/stpncpy.c: Likewise.
143639         * lib/strcasecmp.c: Likewise.
143640         * lib/strcasestr.c: Likewise.
143641         * lib/strcspn.c: Likewise.
143642         * lib/striconv.c: Likewise.
143643         * lib/strncasecmp.c: Likewise.
143644         * lib/strnlen1.c: Likewise.
143645         * lib/strstr.c: Likewise.
143646         * lib/strtok_r.c: Likewise.
143647         * lib/tls.c: Likewise.
143648         * lib/tmpdir.c: Likewise.
143649         * lib/unicodeio.c: Likewise.
143650         * lib/unsetenv.c: Likewise.
143651         * lib/vasnprintf.c: Likewise.
143652         * lib/vasprintf.c: Likewise.
143653         * lib/wait-process.c: Likewise.
143654         * lib/xallocsa.c: Likewise.
143655         * lib/xsetenv.c: Likewise.
143656         * lib/xstriconv.c: Likewise.
143658 2006-09-13  Simon Josefsson  <jas@extundo.com>
143660         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
143661         that internally, suggested by Ralf Wildenhues
143662         <Ralf.Wildenhues@gmx.de>.
143664 2006-09-13  Simon Josefsson  <jas@extundo.com>
143666         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
143667         @LIBOBJS@.
143668         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
143670 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
143672         * lib/_fpending.c: Include <config.h> unconditionally, since we no
143673         longer worry about uses that don't define HAVE_CONFIG_H.
143674         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
143675         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
143676         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
143677         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
143678         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
143679         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
143680         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
143681         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
143682         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
143683         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
143684         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
143685         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
143686         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
143687         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
143688         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
143689         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
143690         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
143691         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
143692         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
143693         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
143694         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
143695         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
143696         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
143697         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
143698         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
143699         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
143700         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
143701         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
143702         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
143703         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
143704         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
143705         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
143706         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
143707         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
143708         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
143709         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
143710         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
143711         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
143712         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
143713         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
143714         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
143715         Likewise.
143717 2006-09-13  Eric Blake  <ebb9@byu.net>
143719         * lib/getopt.c: Fix typo in last commit.
143721 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
143723         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
143724         dgettext.
143726 2006-09-12  Jim Meyering  <jim@meyering.net>
143728         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
143729         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
143730         Reported by Nelson H. F. Beebe.
143732 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
143734         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
143735         program_invocation_name and program_invocation_short_name are
143736         initialized.
143737         * lib/argp-namefrob.h: Move declarations of program_invocation_name
143738         and program_invocation_short_name to argp.h, so they are visible
143739         to user programs.
143740         * lib/argp.h: Likewise
143742 2006-09-10  Bruno Haible  <bruno@clisp.org>
143744         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
143745         m4/inttypes_h.m4, m4/uintmax_t.m4.
143747 2006-09-10  Bruno Haible  <bruno@clisp.org>
143749         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
143750         gl_AC_TYPE_UINTMAX_T.
143752 2006-09-10  Bruno Haible  <bruno@clisp.org>
143754         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
143756 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
143758         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
143759         convention.  Text proposed by Bruno Haible.
143760         (struct argp_option): Document the use of N_() wrappers.
143762         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
143763         '\v', and translate the two parts separately, instead of feeding
143764         the whole string to gettext.  This allows to exclude
143765         '\v' from the strings visible to the translator by writing doc
143766         strings as N_("..") "\v" N_("..").
143768 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
143770         * config/srclist.txt: Undo latest change; the bug was fixed.
143772 2006-09-09  Bruno Haible  <bruno@clisp.org>
143774         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
143775         assignments if building a library without libtool.
143776         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
143777         in func_emit_lib_Makefile_am.
143778         (func_import): When building a static library libfoo.a, arrange to
143779         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
143780         (func_create_testdir): Likewise.
143781         * modules/gc (configure.ac, Makefile.am): If building statically,
143782         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
143783         * modules/iconvme (configure.ac, Makefile.am): Likewise.
143784         * modules/striconv (configure.ac, Makefile.am): Likewise.
143785         Based on a suggestion by Ralf Wildenhues.
143787 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
143789         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
143790         Check for unistd.h too, since Autoconf doesn't assume POSIX.
143791         Also:
143793         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
143794         Add year_2050_test to catch glibc bug 2821
143795         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
143797         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
143798         Prefer #ifdef to #if.
143800         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
143801         Return from 'main' instead of calling 'exit'.
143803 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
143805         * lib/mktime.c (guess_time_tm): Fix bug where mktime
143806         returned the maximum time_t value rather than (time_t) -1.
143807         Problem originally reported by William Bardwell
143808         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
143810         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
143811         Moved to here ...
143812         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
143813         ... from here.
143815 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
143817         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
143818         2821 is fixed.
143820 2006-09-08  Jim Meyering  <jim@meyering.net>
143822         Don't make generated files read-only.  That would bother too many
143823         people.  However, do retain the ability to work when targets are
143824         read-only: remove the destination and temporary files before writing
143825         them (when generated via sed or echo), or by using the -f option for
143826         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
143827         * modules/alloca-opt, modules/argz, modules/arpa_inet:
143828         * modules/byteswap, modules/configmake, modules/fcntl:
143829         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
143830         * modules/localcharset, modules/netinet_in, modules/poll:
143831         * modules/stdbool, modules/stdint, modules/sys_select:
143832         * modules/sys_socket, modules/sys_stat, modules/sysexits:
143834 2006-09-08  Jim Meyering  <jim@meyering.net>
143836         Avoid new build failure on FreeBSD 6.0.
143837         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
143838         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
143839         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
143841 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143843         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
143845 2006-09-07  Jim Meyering  <jim@meyering.net>
143847         Fix global typo in last change: use chmod u-w, not chmod u-x.
143848         Spotted by Paul Eggert and Bruce Korb.
143849         * modules/alloca-opt, modules/argz, modules/arpa_inet:
143850         * modules/byteswap, modules/configmake, modules/fcntl:
143851         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
143852         * modules/localcharset, modules/netinet_in, modules/poll:
143853         * modules/stdbool, modules/stdint, modules/sys_select:
143854         * modules/sys_socket, modules/sys_stat, modules/sysexits:
143856 2006-09-06  Jim Meyering  <jim@meyering.net>
143858         Make generated files be read-only.
143859         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
143860         Ensure that each generated file is now read-only.
143861         * modules/argz: Likewise.
143862         * modules/arpa_inet: Likewise.
143863         * modules/byteswap: Likewise.
143864         * modules/configmake: Likewise.
143865         * modules/fcntl: Likewise.
143866         * modules/fnmatch: Likewise.
143867         * modules/getopt: Likewise.
143868         * modules/glob: Likewise.
143869         * modules/inttypes: Likewise.
143870         * modules/netinet_in: Likewise.
143871         * modules/poll: Likewise.
143872         * modules/stdbool: Likewise.
143873         * modules/stdint: Likewise.
143874         * modules/sys_select: Likewise.
143875         * modules/sys_socket: Likewise.
143876         * modules/sys_stat: Likewise.
143877         * modules/sysexits: Likewise.
143878         * modules/localcharset: Same as above, but continue using temporary
143879         file named "t-$@" (why different?) rather than the "$@-t" used
143880         everywhere else.
143882         * modules/sysexits (Makefile.am): Replace literal occurrences
143883         of "sysexit.h" more readable, and more consistent, "$@".
143885 2006-09-06  Bruno Haible  <bruno@clisp.org>
143887         * modules/striconv: New file.
143888         * modules/xstriconv: New file.
143889         * MODULES.html.sh (Internationalization functions): Add striconv,
143890         xstriconv.
143892 2006-09-06  Bruno Haible  <bruno@clisp.org>
143894         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
143895         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
143896         not using libtool correctly.
143898 2006-09-06  Bruno Haible  <bruno@clisp.org>
143900         * lib/striconv.h: New file.
143901         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
143902         iconvstring.c.
143903         * lib/xstriconv.h: New file.
143904         * lib/xstriconv.c: New file.
143906 2006-09-06  Bruno Haible  <bruno@clisp.org>
143908         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
143909         lib_..._LDFLAGS.
143911 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143913         * lib/argz_.h: Sync from Libtool.
143915         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
143916                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
143918         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
143920 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
143922         * modules/trim: New file.
143924 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
143926         * lib/trim.h: New file.
143927         * lib/trim.c: New file.
143929 2006-09-05  Bruno Haible  <bruno@clisp.org>
143931         * MODULES.html.sh (String handling): Add trim.
143933 2006-09-04  Karl Berry  <karl@gnu.org>
143935         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
143936         until next release.
143938 2006-09-03  Bruno Haible  <bruno@clisp.org>
143940         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
143941         correctly.
143943 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
143945         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
143946         not gl_GETLOADAVG.  Omit unneeded semicolons.
143947         Problems reported by Ralf Wildenhues in
143948         <http://lists.gnu.org/r/bug-gnulib/2006-09/msg00000.html>.
143949         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
143950         at the end, which is the usual gnulib style.
143952         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
143953         of doing all the work ourselves.
143954         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
143955         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
143957 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
143959         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
143960         Problem reported by Ralf Wildenhues in
143961         <http://lists.gnu.org/r/bug-gnulib/2006-09/msg00000.html>.
143963         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
143964         HAVE_STRUCT_STATFS_F_FSTYPENAME.
143966 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
143968         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
143969         yesterday's patch by changing test -n to test -z.
143971 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
143973         * modules/getloadavg (Files): Add m4/getloadavg.m4.
143974         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
143975         the former is now obsolescent.
143977         * modules/chdir-long (Depends-on): Add fcntl.
143979 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
143981         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
143982         obsolescent, and programs should use gnulib instead.
143983         * m4/getloadavg.m4: New file, with contents taken from Autoconf
143984         but with prefixes changed.
143986 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
143988         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
143989         or stdbool.h, because they might not exist while configuring.
143991         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
143992         Don't include unistd.h or limits.h; not needed, since chdir-long.h
143993         does that for us.
143994         (O_DIRECTORY): Remove.
143996 2006-08-31  Eric Blake  <ebb9@byu.net>
143998         * gnulib-tool: Don't let emacs change spaces to TAB.
144000 2006-08-31  Bruno Haible  <bruno@clisp.org>
144002         * gnulib-tool: When calling func_import more than once, do it in a
144003         subshell.
144004         Reported by Eric Blake <ebb9@byu.net>.
144006 2006-08-31  Bruno Haible  <bruno@clisp.org>
144008         * gnulib-tool (nl): Remove variable.
144009         (sed_transform_lib_file): Use more robust test for config-h module.
144010         (func_import): Fix typo in 2006-08-25 patch.
144012 2006-08-31  Bruno Haible  <bruno@clisp.org>
144014         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
144015         specified, augment Makefile.am variables instead of assigning them.
144017 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
144019         Work around a bug in both the Linux and SunOS 64-bit kernels:
144020         nanosleep mishandles sleeps for longer than 2**31 seconds.
144021         Problem reported by Frank v Waveren in
144022         <http://lists.gnu.org/r/bug-coreutils/2006-08/msg00298.html>.
144023         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
144024         Check for nanosleep bug.
144025         (LIB_NANOSLEEP): Append clock_gettime library if needed.
144027 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
144029         Work around a bug in both the Linux and SunOS 64-bit kernels:
144030         nanosleep mishandles sleeps for longer than 2**31 seconds.
144031         Problem reported by Frank v Waveren in
144032         <http://lists.gnu.org/r/bug-coreutils/2006-08/msg00298.html>.
144033         * lib/nanosleep.c (BILLION): New constant.
144034         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
144035         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
144036         implementation.
144038 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
144040         * modules/nanosleep (Depends-on): Add gettime.
144042 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
144043         and Simon Josefsson  <jas@extundo.com>
144044         and Oskar Liljeblad  <oskar@osk.mine.nu>
144046         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
144047         * gnulib-tool (func_import): New license type 'unmodifiable license
144048         text'.
144049         * modules/fdl: Use it.  Longer description.
144050         * module/gpl, module/lgpl: New files.
144052 2006-08-30  Jim Meyering  <jim@meyering.net>
144054         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
144055         shadowing the parameter.
144057 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
144059         Sync from Libtool:
144061         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
144063         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
144064         sharing with gnulib.  Report by Eric Blake.
144066 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
144068         * modules/isapipe: New file.
144069         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
144071 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
144073         * modules/configmake (Makefile.am): Add a comment, and omit
144074         the CONFIGMAKE_ prefix from generated macro names.  Suggested
144075         by Bruno Haible.
144077 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
144079         * m4/isapipe.m4: New file.
144081 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
144083         * lib/isapipe.c, lib/isapipe.h: New files.
144085 2006-08-29  Jim Meyering  <jim@meyering.net>
144087         * modules/configmake (Makefile.am): Make configmake.h depend on
144088         Makefile.  Otherwise, a stale configmake.h could hang around.
144090 2006-08-29  Eric Blake  <ebb9@byu.net>
144092         * lib/error.c (error_at_line, print_errno_message): Match libc, after
144093         resolution of upstream bug 3044.
144095 2006-08-29  Bruno Haible  <bruno@clisp.org>
144097         * modules/localcharset (Depends-on): Add configmake.
144098         (Makefile.am): Remove setting of LIBDIR through DEFS.
144100 2006-08-29  Bruno Haible  <bruno@clisp.org>
144102         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
144103         defined.
144105 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
144107         * modules/fcntl: New file.
144108         * modules/chdir-safer (Depends-on): Add fcntl.
144109         * modules/fts: Likewise.
144110         * modules/mkdir-p: Likewise.
144112         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
144113         This undoes the most recent change, since we're now addressing the
144114         problem in a different way.
144116         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
144117         into output, since the output might be called Makefile.am even
144118         if $makefile_name is something different.
144119         (func_import): Use $makefile_am rather than
144120         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
144121         empty.
144123         * modules/inttypes (Files): Add m4/inttypes-h.m4.
144125 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
144127         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
144128         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
144129         recent change to stdint.m4, since we're now addressing the problem in a
144130         different way.
144132 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
144134         * m4/fcntl_h.m4: New file.
144136 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
144138         * lib/fcntl_.h: New file.
144139         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
144140         the fcntl module.
144141         * lib/dirchownmod.c: Likewise.
144142         * lib/fts.c: Likewise.
144144         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
144145         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
144146         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
144147         just before including <inttypes.h>, to avoid circular inclusion.
144149 2006-08-28  Jim Meyering  <jim@meyering.net>
144151         * doc/visibility.texi: Actually read and correct the grammar of the
144152         sentence affected by yesterday's change.
144154 2006-08-28  Eric Blake  <ebb9@byu.net>
144156         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
144157         needs wrapper.
144159 2006-08-28  Eric Blake  <ebb9@byu.net>
144161         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
144163 2006-08-28  Eric Blake  <ebb9@byu.net>
144165         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
144167 2006-08-28  Bruno Haible  <bruno@clisp.org>
144169         * modules/c-strstr: New file, from GNU gettext.
144170         * MODULES.html.sh (String handling): Add c-strstr.
144172 2006-08-28  Bruno Haible  <bruno@clisp.org>
144174         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
144175         macros.
144176         Reported by Eric Blake.
144178 2006-08-28  Bruno Haible  <bruno@clisp.org>
144180         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
144181         (VASNPRINTF): Return a string of length > INT_MAX without failing.
144182         * lib/vasprintf.c: Include errno.h, limits.h.
144183         (EOVERFLOW): New fallback definition.
144184         (vasprintf): Test here whether the string length is > INT_MAX.
144185         * lib/vsnprintf.c: Include errno.h, limits.h.
144186         (EOVERFLOW): New fallback definition.
144187         (vsnprintf): Fix bug when generated string was too long for the buffer.
144188         Test here whether the string length is > INT_MAX.
144190 2006-08-28  Bruno Haible  <bruno@clisp.org>
144192         * lib/inttypes_.h (SCNX*): Remove definitions.
144193         Reported by Eric Blake.
144195 2006-08-28  Bruno Haible  <bruno@clisp.org>
144197         * lib/c-strstr.h: New file, from GNU gettext.
144198         * lib/c-strstr.c: New file, from GNU gettext.
144200 2006-08-28  Bruno Haible  <bruno@clisp.org>
144202         * gnulib-tool: Reorder some statements.
144204 2006-08-28  Bruno Haible  <bruno@clisp.org>
144206         * gnulib-tool: New option --makefile-name.
144207         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
144208         $makefile_name.
144209         (func_import): Write $makefile_name to the cache file, and read it from
144210         there unless explicitly specified. Use $makefile_name as file name
144211         instead of Makefile.am. Adjust the recommendations accordingly.
144213 2006-08-28  Bruno Haible  <bruno@clisp.org>
144215         * gnulib-tool (func_verify_module): Check against misapplying patch.
144217 2006-08-28  Bruno Haible  <bruno@clisp.org>
144219         * gnulib-tool (func_relativize, func_relconcat): New functions.
144220         Give an error if --local-dir is given with --update.
144221         Remove trailing slashes from $local_gnulib_dir.
144222         (func_import): Store the relativized $local_gnulib_dir in
144223         gnulib-cache.m4, and read it from there if not specified explicitly.
144225 2006-08-28  Bruno Haible  <bruno@clisp.org>
144227         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
144228         is the current directory. Respect also $local_gnulib_dir.
144230 2006-08-28  Bruno Haible  <bruno@clisp.org>
144231             Simon Josefsson  <jas@extundo.com>
144233         BeOS portability.
144234         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
144236 2006-08-27  Jim Meyering  <jim@meyering.net>
144238         * doc/visibility.texi: Remove duplicate word: "pointer".
144240 2006-08-26  Bruno Haible  <bruno@clisp.org>
144242         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
144243         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
144244         (Makefile.am): Create inttypes.h from inttypes_.h.
144245         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
144247         * modules/imaxabs: New file.
144249         * modules/imaxdiv: New file.
144251 2006-08-26  Bruno Haible  <bruno@clisp.org>
144253         * m4/inttypes.m4: New file.
144254         * m4/_inttypes_h.m4: Remove file.
144255         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
144256         PRI_MACROS_BROKEN.
144257         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
144259         * m4/imaxabs.m4: New file.
144261         * m4/imaxdiv.m4: New file.
144263 2006-08-26  Bruno Haible  <bruno@clisp.org>
144265         * lib/inttypes_.h: New file.
144266         * lib/inttypes.h: Remove file.
144267         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
144269         * lib/imaxabs.c: New file.
144271         * lib/imaxdiv.c: New file.
144273 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
144275         New config-h module, so that "make" output needn't be cluttered
144276         by -DHAVE_CONFIG_H.
144277         * MODULES.html.sh (Support for building libraries and executables):
144278         Add config-h.
144279         * modules/config-h: New file.
144280         * gnulib-tool (nl, sed_transform_lib_file): New vars.
144281         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
144282         the config-h module is used.
144284         New configmake module, so that "make" output needn't be cluttered
144285         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
144286         * MODULES.html.sh (Support for building libraries and executables):
144287         Add configmake.
144288         * modules/configmake: New file.
144290 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
144292         * m4/config-h.m4: New file.
144294 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
144296         * config/srclist.txt: Add elisp-comp.
144298 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
144300         * MODULES.html.sh (Support for building libraries and executables):
144301         Add elisp-comp.
144302         * build-aux/elisp-comp: New file.
144303         * modules/elisp-comp: New file.
144305 2006-08-24  Bruno Haible  <bruno@clisp.org>
144307         * gnulib-tool (func_create_testdir): Use non-default values of
144308         sourcebase and m4base.
144310 2006-08-24  Bruno Haible  <bruno@clisp.org>
144312         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
144313         HTML structure.
144315 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
144317         * modules/openat (Depends-on): Add lchown.
144319 2006-08-23  Bruno Haible  <bruno@clisp.org>
144321         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
144322         of gl_LOCK_EARLY instead of gl_LOCK.
144324 2006-08-23  Bruno Haible  <bruno@clisp.org>
144326         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
144327         on OSF/1 to no.
144328         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
144330 2006-08-23  Bruno Haible  <bruno@clisp.org>
144332         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
144333         as unusable.
144335         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
144336         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
144337         (gl_LOCK): New macro.
144339 2006-08-22  Simon Josefsson  <jas@extundo.com>
144341         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
144342         to md5 module.
144344 2006-08-22  Simon Josefsson  <jas@extundo.com>
144346         * MODULES.html.sh: Add "Support for maintaining and release
144347         projects".
144349         * build-aux/gnupload: New file, from coreutils.
144351 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
144353         Avoid the need for AC_LIBSOURCES in m4 macros.
144354         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
144355         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
144356         * modules/check-version (EXTRA_DIST): Add check-version.h.
144357         * modules/crc (EXTRA_DIST): Add crc.h.
144358         * modules/des (EXTRA_DIST): Add des.h.
144359         * modules/gc (EXTRA_DIST): Add gc.h.
144360         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
144361         * modules/getline (EXTRA_DIST): Add getline.h.
144362         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
144363         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
144364         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
144365         * modules/md2 (EXTRA_DIST): Add md2.h.
144366         * modules/md4 (EXTRA_DIST): Add md4.h.
144367         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
144368         * modules/read-file (EXTRA_DIST): Add read-file.h.
144369         * modules/readline (EXTRA_DIST): Add readline.h.
144370         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
144371         rijndael-api-fst.h.
144373 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
144375         * m4/rijndael.m4 (gl_ARCFOUR):
144376         * m4/arctwo.m4 (gl_ARCTWO):
144377         * m4/check-version.m4 (gl_CHECK_VERSION):
144378         * m4/crc.m4 (gl_CRC):
144379         * m4/des.m4 (gl_DES):
144380         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
144381         * m4/gc.m4 (gl_GC):
144382         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
144383         * m4/getline.m4 (gl_FUNC_GETLINE):
144384         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
144385         * m4/hmac-md5.m4 (gl_HMAC_MD5):
144386         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
144387         * m4/md2.m4 (gl_MD2):
144388         * m4/md4.m4 (gl_MD4):
144389         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
144390         * m4/read-file.m4 (gl_FUNC_READ_FILE):
144391         * m4/readline.m4 (gl_FUNC_READLINE):
144392         * m4/rijndael.m4 (gl_RIJNDAEL):
144393         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
144394         to get the necessary .h files and whatnot.
144396 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
144398         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
144399         gnulib rather than the other way around.
144400         * config/srclistvars.sh (COREUTILS): Remove.
144402 2006-08-22  Jim Meyering  <jim@meyering.net>
144404         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
144406         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
144408 2006-08-22  Eric Blake  <ebb9@byu.net>
144410         * modules/regexprops-generic: New file.
144411         * MODULES.html.sh (Support for building documentation): List it.
144413 2006-08-22  Eric Blake  <ebb9@byu.net>
144415         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
144416         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
144417         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
144418         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
144420 2006-08-22  Bruno Haible  <bruno@clisp.org>
144422         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
144423         and lib_LTLIBRARIES like the other lib_* variables.
144425 2006-08-22  Bruno Haible  <bruno@clisp.org>
144427         * build-aux/x-to-1.in: New file, from GNU gettext.
144429 2006-08-22  Bruno Haible  <bruno@clisp.org>
144431         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
144432         <utmpx.h> exists.
144434 2006-08-22  Bruno Haible  <bruno@clisp.org>
144436         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
144437         <utmpx.h> exists.
144439 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
144441         BeOS portability.
144442         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
144443         exist.
144444         Problem reported by Bruno Haible.
144446 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
144448         Avoid the need for AC_LIBSOURCES in m4 macros.
144449         * modules/acl (EXTRA_DIST): Add acl.h.
144450         * modules/argmatch (Files): Add m4/argmatch.m4.
144451         (configure.ac): Add gl_ARGMATCH.
144452         (EXTRA_DIST): Renamed from lib_SOURCES, for
144453         consistency with the other modules.  Remove argmatch.c.
144454         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
144455         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
144456         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
144457         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
144458         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
144459         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
144460         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
144461         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
144462         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
144463         * modules/closeout (EXTRA_DIST): Add closeout.h.
144464         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
144465         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
144466         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
144467         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
144468         dirname.h; remove basename.c and stripslash.c.
144469         * modules/exclude (EXTRA_DIST): Add exclude.h.
144470         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
144471         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
144472         * modules/file-type (EXTRA_DIST): Add file-type.h.
144473         * modules/filemode (EXTRA_DIST): Add filemode.h.
144474         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
144475         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
144476         * modules/fpending (EXTRA_DIST): Add __fpending.h.
144477         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
144478         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
144479         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
144480         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
144481         * modules/getdate (EXTRA_DIST): Add getdate.c.
144482         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
144483         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
144484         * modules/getpass (EXTRA_DIST): Add getpass.h.
144485         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
144486         * modules/group-member (EXTRA_DIST): Add group-member.h.
144487         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
144488         * modules/hash (EXTRA_DIST): Add hash.h.
144489         * modules/human (EXTRA_DIST): Add human.h.
144490         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
144491         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
144492         * modules/lchown (EXTRA_DIST): Add lchown.h.
144493         * modules/long-options (EXTRA_DIST): Add long-options.h.
144494         * modules/lstat (EXTRA_DIST): Add lstat.h.
144495         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
144496         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
144497         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
144498         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
144499         * modules/memxor (EXTRA_DIST): Add memxor.h.
144500         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
144501         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
144502         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
144503         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
144504         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
144505         * modules/physmem (EXTRA_DIST): Add physmem.h.
144506         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
144507         * modules/posixver (EXTRA_DIST): Add posixver.h.
144508         * modules/quote (EXTRA_DIST): Add quote.h.
144509         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
144510         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
144511         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
144512         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
144513         regex_internal.h regexec.c.
144514         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
144515         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
144516         * modules/same (EXTRA_DIST): Add same.h.
144517         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
144518         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
144519         * modules/savedir (EXTRA_DIST): Add savedir.h.
144520         * modules/sha1 (EXTRA_DIST): Add sha1.h.
144521         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
144522         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
144523         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
144524         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
144525         * modules/strdup (EXTRA_DIST): Add strdup.h.
144526         * modules/strftime (EXTRA_DIST): Add strftime.h.
144527         * modules/strndup (EXTRA_DIST): Add strndup.h.
144528         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
144529         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
144530         * modules/time_r (EXTRA_DIST): Add time_r.h.
144531         * modules/timespec (EXTRA_DIST): Add timespec.h.
144532         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
144533         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
144534         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
144535         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
144536         * modules/userspec (EXTRA_DIST): Add userspec.h.
144537         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
144538         * modules/utimens (EXTRA_DIST): Add utimens.h.
144539         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
144540         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
144541         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
144542         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
144543         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
144544         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
144545         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
144546         * modules/yesno (EXTRA_DIST): Add yesno.h.
144548 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
144550         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
144552         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
144553         * m4/dev-ino.m4, same-inode.m4: Remove.
144555         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
144556         * m4/acl.m4 (AC_FUNC_ACL):
144557         * m4/backupfile.m4 (gl_BACKUPFILE):
144558         * m4/c-strtod.m4 (gl_C99_STRTOLD):
144559         * m4/canon-host.m4 (gl_CANON_HOST):
144560         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
144561         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
144562         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
144563         * m4/cloexec.m4 (gl_CLOEXEC):
144564         * m4/close-stream.m4 (gl_CLOSE_STREAM):
144565         * m4/closeout.m4 (gl_CLOSEOUT):
144566         * m4/dirfd.m4 (gl_FUNC_DIRFD):
144567         * m4/dirname.m4 (gl_DIRNAME):
144568         * m4/exclude.m4 (gl_EXCLUDE):
144569         * m4/exitfail.m4 (gl_EXITFAIL):
144570         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
144571         * m4/file-type.m4 (gl_FILE_TYPE):
144572         * m4/filemode.m4 (gl_FILEMODE):
144573         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
144574         * m4/fpending.m4 (gl_FUNC_FPENDING):
144575         * m4/fprintftime.m4 (gl_FPRINTFTIME):
144576         * m4/fts.m4 (gl_FUNC_FTS):
144577         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
144578         * m4/getdate.m4 (gl_GETDATE):
144579         * m4/gethrxtime.m4 (gl_GETHRXTIME):
144580         * m4/getpagesize.m4 (gl_GETPAGESIZE):
144581         * m4/getpass.m4 (gl_FUNC_GETPASS):
144582         * m4/gettime.m4 (gl_GETTIME):
144583         * m4/getugroups.m4 (gl_GETUGROUPS):
144584         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
144585         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
144586         * m4/hard-locale.m4 (gl_HARD_LOCALE):
144587         * m4/hash.m4 (gl_HASH):
144588         * m4/idcache.m4 (gl_IDCACHE):
144589         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
144590         * m4/lchown.m4 (gl_FUNC_LCHOWN):
144591         * m4/long-options.m4 (gl_LONG_OPTIONS):
144592         * m4/lstat.m4 (gl_FUNC_LSTAT):
144593         * m4/md5.m4 (gl_MD5):
144594         * m4/memcasecmp.m4 (gl_MEMCASECMP):
144595         * m4/memcoll.m4 (gl_MEMCOLL):
144596         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
144597         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
144598         * m4/memxor.m4 (gl_MEMXOR):
144599         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
144600         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
144601         * m4/modechange.m4 (gl_MODECHANGE):
144602         * m4/mountlist.m4 (gl_MOUNTLIST):
144603         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
144604         * m4/openat.m4 (gl_FUNC_OPENAT):
144605         * m4/pathmax.m4 (gl_PATHMAX):
144606         * m4/physmem.m4 (gl_PHYSMEM):
144607         * m4/posixtm.m4 (gl_POSIXTM):
144608         * m4/posixver.m4 (gl_POSIXVER):
144609         * m4/quote.m4 (gl_QUOTE):
144610         * m4/quotearg.m4 (gl_QUOTEARG):
144611         * m4/readtokens.m4 (gl_READTOKENS):
144612         * m4/readutmp.m4 (gl_READUTMP):
144613         * m4/regex.m4 (gl_REGEX):
144614         * m4/safe-read.m4 (gl_SAFE_READ):
144615         * m4/safe-write.m4 (gl_SAFE_WRITE):
144616         * m4/same.m4 (gl_SAME):
144617         * m4/save-cwd.m4 (gl_SAVE_CWD):
144618         * m4/savedir.m4 (gl_SAVEDIR):
144619         * m4/settime.m4 (gl_SETTIME):
144620         * m4/sha1.m4 (gl_SHA1):
144621         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
144622         * m4/stat-macros.m4 (gl_STAT_MACROS):
144623         * m4/stat-time.m4 (gl_STAT_TIME):
144624         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
144625         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
144626         * m4/strdup.m4 (gl_FUNC_STRDUP):
144627         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
144628         * m4/strndup.m4 (gl_FUNC_STRNDUP):
144629         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
144630         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
144631         * m4/time_r.m4 (gl_TIME_R):
144632         * m4/timespec.m4 (gl_TIMESPEC):
144633         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
144634         * m4/unlinkdir.m4 (gl_UNLINKDIR):
144635         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
144636         * m4/userspec.m4 (gl_USERSPEC):
144637         * m4/utimecmp.m4 (gl_UTIMECMP):
144638         * m4/utimens.m4 (gl_UTIMENS):
144639         * m4/xalloc.m4 (gl_XALLOC):
144640         * m4/xgetcwd.m4 (gl_XGETCWD):
144641         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
144642         * m4/xreadlink.m4 (gl_XREADLINK):
144643         * m4/xstrtod.m4 (gl_XSTRTOD):
144644         * m4/yesno.m4 (gl_YESNO):
144645         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
144646         to get the necessary .h files and whatnot.
144648 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
144649             Bruno Haible  <bruno@clisp.org>
144651         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
144652         /bin/sh understanding of '!' conditional negation.
144654 2006-08-21  Jim Meyering  <jim@meyering.net>
144656         * modules/openat (Depends-on): Really alphabetize.
144658         * modules/acl (Depends-on): Add error and quote.
144660         * check-module (find_included_lib_files): Add at-func.c to the
144661         ok-to-include-more-than-once white list.
144663         * modules/openat (Depends-on): Add lstat.  Alphabetize.
144665 2006-08-21  Bruno Haible  <bruno@clisp.org>
144667         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
144668         Emit a pkgdata_DATA variable only if some snippets add contents to it.
144669         Reported by Martin Lambers <marlam@marlam.de>.
144671 2006-08-21  Bruno Haible  <bruno@clisp.org>
144673         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
144674         specify an installation location, don't emit a noinst_LIBRARIES or
144675         noinst_LTLIBRARIES assignment.
144677 2006-08-21  Bruno Haible  <bruno@clisp.org>
144679         BeOS portability.
144680         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
144681         BeOS has mbrtowc() but no <wctype.h>.
144683 2006-08-21  Bruno Haible  <bruno@clisp.org>
144685         BeOS portability.
144686         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
144687         exist.
144689 2006-08-21  Bruno Haible  <bruno@clisp.org>
144691         BeOS portability.
144692         * lib/mbchar.h: Include <wctype.h> only if it exists.
144694 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
144696         Remove files that are no longer needed by their respective modules.
144697         * m4/obstack.m4: Remove.
144698         * m4/strerror_r.m4: Remove.
144699         * m4/uint32_t.m4: Remove.
144700         * m4/uintptr_t.m4: Remove.
144701         * m4/ullong_max.m4: Remove.
144702         * m4/xstrtoimax.m4: Remove.
144703         * m4/xstrtoumax.m4: Remove.
144705         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
144706         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
144707         dependencies now capture this.
144709         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
144710         Do not use AC_LIBSOURCES, since gnulib modules now do this.
144711         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
144712         * m4/human.m4 (gl_HUMAN): Likewise.
144713         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
144714         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
144716         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
144718         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
144719         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
144720         stdint.
144721         * m4/human.m4 (gl_HUMAN): Likewise.
144722         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
144723         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
144724         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
144725         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
144726         * m4/xstrtol (gl_XSTRTOL): Likewise.
144728         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
144729         AC_TYPE_LONG_LONG_INT.
144730         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
144731         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
144732         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
144733         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
144735         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
144736         on stdbool.
144738         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
144739         (gl_PREREQ_XSTRTOUL): Remove.
144741         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
144743         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
144744         mode.
144746 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
144748         Add and change modules to make it easier for coreutils to use
144749         gnulib-tool.
144750         * modules/backupfile (Files): Remove m4/d-ino.m4.
144751         (Depends-on): Add d-ino.
144752         * modules/cycle-check (Depends-on): Add stdint.
144753         (lib_SOURCES): Add cycle-check.h.
144754         * modules/d-ino: New module.
144755         * modules/d-type: New module.
144756         * modules/error (Files): Remove m4/strerror_r.m4.
144757         * modules/filemode (Files): Add m4/st_dm_mode.m4.
144758         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
144759         m4/inttypes_h.m4, m4/uintmax_t.m4.
144760         (Depends-on): Add stdint.
144761         (lib_SOURCES): Add fsusage.h.
144762         * modules/getcwd (Files): Remove d-ino.m4.
144763         (Depends-on): Add d-ino.
144764         * modules/getndelim2 (Depends-on): Add stdint.
144765         * modules/glob (Files): Remove m4/d-type.m4.
144766         (Depends-on): Add d-type.
144767         * modules/host-os: New module.
144768         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
144769         m4/inttypes_h.m4, m4/uintmax_t.m4.
144770         * Depends-on: Add stdint.
144771         (lib_SOURCES): Add human.h.
144772         * modules/inttostr (Files): Remove m4/intmax_t.m4,
144773         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
144774         m4/uintmax_t.m4, m4/ulonglong.m4.
144775         (Depends-on): Add stdint.
144776         (EXTRA_DIST): Add inttostr.h.
144777         * modules/lchmod: New module.
144778         * modules/link-follow: New module.
144779         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
144780         (Depends-on): Add lchmod.
144781         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
144782         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
144783         (Depends-on): Add stdint.
144784         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
144785         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
144786         (Depends-on): Add stdint.
144787         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
144788         * modules/perl: New module.
144789         * modules/regex (Depends-on): Add stdint.
144790         * modules/rmdir-errno: New module.
144791         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
144792         m4/intmax_t.m4.
144793         (Depends-on): Add stdint.
144794         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
144795         m4/uintmax_t.m4.
144796         (Depends-on): Add stdint.
144797         * modules/unlink-busy: New module.
144798         * modules/utimecmp (Depends-on): Add stdint.
144799         * modules/uptime: New module.
144800         * modules/winsz-ioctl: New module.
144801         * modules/winsz-termios: New module.
144802         * modules/xnanosleep (Depends-on): Add nanosleep.
144803         * modules/ullong_max: Remove.
144804         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
144805         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
144806         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
144807         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
144808         (Depends-on): Add inttypes.
144809         (lib_SOURCES): Add xstrtol.h.
144810         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
144811         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
144812         * MODULES.html.sh: Move 'assert' into the assert section.
144813         Move 'dummy' into the linking section.
144814         Remove ullong_max.
144815         Add section for compatibility checks for POSIX:2001 functions,
144816         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
144817         winsz-ioctl, and winsz-termios into it.
144818         Add lchmod.
144819         Add top-level Misc section and put host-os, perl, and uptime
144820         into it.
144822 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
144824         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
144825         now assume the stdint module.  Do not include inttypes.h.
144826         * lib/fsusage.h: Likewise.
144827         * lib/getndelim2.c: Likewise.
144828         * lib/human.h: Likewise.
144829         * lib/inttostr.h: Likewise.
144830         * lib/obstack.c: Likewise.
144831         * lib/regex_internal.h: Likewise.
144832         * lib/tempname.c: Likewise.
144833         * lib/utimecmp.c: Likewise.
144834         * lib/xstrtol.h: Likewise.
144836         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
144838         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
144839         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
144840         * lib/xtime.h: Likewise.
144842 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
144844         * modules/openat (Files): Add lib/fchmodat.c.
144845         Fixes problem reported by Jay Youngman.
144847 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
144849         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
144850         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
144852 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
144853             Bruno Haible  <bruno@clisp.org>
144855         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
144856         and is a script that invokes bison. Tighten the code. Add comments.
144858 2006-08-18  Jim Meyering  <jim@meyering.net>
144860         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
144861         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
144862         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
144863         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
144865 2006-08-18  Bruno Haible  <bruno@clisp.org>
144867         * modules/bison-i18n: New file.
144868         * MODULES.html.sh (Internationalization functions): Add it.
144870 2006-08-18  Bruno Haible  <bruno@clisp.org>
144872         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
144873         sys/statvfs.h. When getmntinfo was found, check its declaration and
144874         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
144876 2006-08-18  Bruno Haible  <bruno@clisp.org>
144878         * m4/bison-i18n.m4: New file, from bison.
144880 2006-08-18  Bruno Haible  <bruno@clisp.org>
144882         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
144883         (ME_DUMMY): Treat "kernfs" as a dummy.
144884         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
144886 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
144888         Update from coreutils.
144890         2006-08-15  Jim Meyering  <jim@meyering.net>
144892         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
144894         2006-01-17  Jim Meyering  <jim@meyering.net>
144896         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
144898         2006-01-11  Jim Meyering  <jim@meyering.net>
144900         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
144901         Check for the lchmod function.
144903 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
144905         Update from coreutils.
144907         * lib/__fpending.h: Add copyright notice.
144908         * lib/fprintftime.h: Likewise.
144909         * lib/savedir.c: Use (C) in copyright notice.
144910         * lib/savedir.h: Likewise.
144912         2006-08-15  Jim Meyering  <jim@meyering.net>
144914         * lib/at-func.c: New file, with the logic of all emulated at-functions.
144915         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
144916         in support of the EXPECTED_ERRNO macro.
144917         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
144918         definitions.  Instead, define the appropriate symbols and include
144919         "at-func.c".
144920         * lib/mkdirat.c (mkdirat): Likewise.
144921         * lib/fchmodat.c (fchmodat): Likewise.
144922         (ENOSYS): Remove definition.
144923         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
144924         it.  Don't include "unistd--.h" -- it wasn't ever used.
144926         2006-01-17  Jim Meyering  <jim@meyering.net>
144928         Rewrite fts.c not to change the current working directory,
144929         by using openat, fstatat, fdopendir, etc..
144931         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
144932         (HAVE_OPENAT_SUPPORT): Define.
144933         [_LIBC] (fchdir): Don't undef or define; no longer used.
144934         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
144935         Now, this `function' always succeeds, and consumes its file descriptor
144936         parameter -- so callers must not close such FDs.  Update callers.
144937         (diropen_fd, opendirat, cwd_advance_fd): New functions.
144938         (diropen): Add parameter, SP.  Adjust all callers.
144939         Implement using diropen_fd, rather than open.
144940         (fts_open): Initialize new member, fts_cwd_fd.
144941         Remove fts_rft-setting code.
144942         (fts_close): Close fts_cwd_fd, if necessary.
144943         (__opendir2): Define in terms of opendir or opendirat,
144944         depending on whether the FST_NOCHDIR flag is set.
144945         (fts_build): Since fts_safe_changedir consumes its FD, and since
144946         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
144947         and close the dup'd file descriptor upon failure.
144948         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
144949         (fts_safe_changedir): Tweak semantics to reflect that this function
144950         now calls cwd_advance_fd and hence consumes its FD argument.
144951         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
144952         [struct FTS] (fts_rft): Remove now-unused member.
144953         [struct FTS] (fts_cycle.state): Improve comment.
144955         * lib/openat.c (openat_needs_fchdir): New function.
144956         * lib/openat.h (openat_needs_fchdir): Declare it.
144958 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
144960         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
144961         Problem and fix reported by Pádraig Brady in
144962         <http://lists.gnu.org/r/bug-coreutils/2006-08/msg00099.html>.
144964 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
144966         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
144968 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
144970         * lib/memcoll.c (memcoll): Optimize for the common case where the
144971         arguments are bytewise equal.
144973 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
144975         * doc/regexprops-generic.texi: Add a copyright notice.
144977 2006-08-15  Bruno Haible  <bruno@clisp.org>
144979         * modules/tmpdir (License): Change to LGPL.
144981 2006-08-15  Bruno Haible  <bruno@clisp.org>
144983         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
144984         module.
144986 2006-08-14  Simon Josefsson  <jas@extundo.com>
144988         * config/srclist.txt: Add gnupload.
144990 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
144992         Change copyright notice from LGPL 2 to GPL 2, since that's the
144993         standard form used in the gnulib repository.
144994         * tests/test-lock.c: Likewise.
144995         * tests/test-stdint.c: Likewise.
144996         * tests/test-tls.c: Likewise.
144998         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
144999         prelude-manager.  User shorter URLs for GNU projects, without '?'.
145000         Add copyright notice.
145002         * check-module: Add copyright notice.  Output a copyright
145003         notice if "--version" is specified.
145004         * modules/COPYING: New file.
145005         * tests/test-getaddrinfo.c: Add copyright notice.
145006         * tests/test-verify.c: Likewise.
145008 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
145010         Change copyright notice from LGPL 2 to GPL 2, since that's the
145011         standard form used in the gnulib repository.
145012         * lib/lock.c: LGPL -> GPL.
145013         * lib/lock.h: Likewise.
145014         * lib/strnlen1.c: Likewise.
145015         * lib/strnlen1.h: Likewise.
145016         * lib/tls.c: Likewise.
145017         * lib/tls.h: Likewise.
145018         * lib/tmpdir.c: Likewise.
145020         * lib/TODO: Remove; this belongs only in coreutils.
145022 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
145024         Add copyright notices to long-enough files that lack them, since
145025         otherwise the files aren't clearly free.  Use the same notice that
145026         getdate.texi already uses.
145027         * doc/alloca-opt.texi: Add copyright notice.
145028         * doc/alloca.texi: Likewise.
145029         * doc/ctime.texi: Likewise.
145030         * doc/functions.texi: Likewise.
145031         * doc/gcd.texi: Likewise.
145032         * doc/gnulib-tool.texi: Likewise.
145033         * doc/inet_ntoa.texi: Likewise.
145034         * doc/visibility.texi: Likewise.
145036         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
145037         * doc/quote.texi: Add copyright notice.
145039         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
145040         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
145041         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
145042         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
145043         is now obsolete, and give a pointer to the Sun list.
145044         Add copyright notice.
145046 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
145048         * config/srclistvars.sh: Add copyright notice.
145050 2006-08-14  Eric Blake  <ebb9@byu.net>
145052         Import the following change from libc:
145054         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
145056         Upstream bug 2997.
145057         * lib/misc/error.c: Add space between program name and message if file
145058         name is missing.
145060 2006-08-12  Karl Berry  <karl@gnu.org>
145062         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
145063         remove, these originate in gnulib now.
145065 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
145067         * doc/Makefile (standards.info standards.html standards.dvi):
145068         Also depend on make-stds.texi.
145070 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
145072         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
145073         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
145075         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
145076         in wchar_t.  Problem reported by Eric Blake.
145078         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
145079         LEN is smaller than SIZE.  Suggested by Bruno Haible.
145080         Also, help the compiler to keep LEN in a register.
145082 2006-08-11  Eric Blake  <ebb9@byu.net>
145084         * users.txt: Sort.  Add tar.
145086 2006-08-11  Bruno Haible  <bruno@clisp.org>
145088         * users.txt: New file.
145090 2006-08-11  Bruno Haible  <bruno@clisp.org>
145092         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
145093         before <wchar.h>. Needed for OSF/1 and BSD/OS.
145095 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
145097         * modules/snprintf (Depends-on): Remove minmax.
145098         (Maintainer): Add self and Bruno.
145100 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
145102         * lib/.cppi-disable: Add snprintf.h, socket_.h.
145103         * lib/snprintf.c: Include <errno.h> and <limits.h>.
145104         (EOVERFLOW): Define if the system does not.
145105         Do not include "minmax.h"; it wasn't used.
145106         (snprintf): Don't assume size_t promotes to an unsigned type.
145107         Fix bug when generated string was too long for the buffer: the
145108         buffer's contents are supposed to be the initial prefix of the
145109         output.  Don't assume vasnprintf returns EOVERFLOW if the size
145110         exceeds INT_MAX; do the check ourselves.
145112         Import the following changes from libc:
145114         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
145116         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
145117         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
145118         set wc to the byte which couldn't be converted.
145119         (re_string_reconstruct): Don't clear valid_raw_len before calling
145120         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
145121         tip_context using re_string_context_at.
145123         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
145125         * lib/posix/regex.h: g++ still cannot handled [restrict].
145127         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
145129         * lib/posix/regex.h: Remove special handling for VMS.
145131 2006-08-10  Jim Meyering  <jim@meyering.net>
145133         * modules/same-inode: New module.
145134         * modules/dev-ino: New module.
145135         * modules/cycle-check: Depend on these modules, rather than simply
145136         including their .h files.
145137         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
145138         required via m4/cycle-check.m4.
145139         * modules/same: Depend on new same-inode module, rather than
145140         including same-inode.h.
145141         * modules/chdir-safer: New file.
145143         * modules/chown (Depends-on): Add stat-macros.
145145 2006-08-10  Jim Meyering  <jim@meyering.net>
145147         * m4/cycle-check.m4: New file.
145148         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
145149         * m4/dev-ino.m4, m4/same-inode.m4: New files.
145151 2006-08-10  Eric Blake  <ebb9@byu.net>
145153         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
145154         in from original proposal.
145156 2006-08-10  Eric Blake  <ebb9@byu.net>
145157         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
145159         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
145160         namespace.
145162 2006-08-10  Bruno Haible  <bruno@clisp.org>
145164         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
145165         as well.
145167 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
145169         Sync from coreutils.
145171         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
145173         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
145174         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
145176 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
145178         * modules/restrict: Remove; no longer needed now that we assume
145179         Autoconf 2.59 or later.
145180         * MODULES.html.sh: Remove 'restrict'.
145181         * modules/argp (Depends-on): Remove 'restrict'.
145182         * modules/base64 (Depends-on): Likewise.
145183         * modules/gc (Depends-on): Likewise.
145184         * modules/getaddrinfo (Depends-on): Likewise.
145185         * modules/glob (Depends-on): Likewise.
145186         * modules/inet_ntop (Depends-on): Likewise.
145187         * modules/inet_pton (Depends-on): Likewise.
145188         * modules/memxor (Depends-on): Likewise.
145189         * modules/regex (Depends-on): Likewise.
145190         * modules/strtok_r (Depends-on): Likewise.
145191         * modules/time_r (Depends-on): Likewise.
145193 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
145195         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
145196         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
145197         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
145198         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
145199         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
145200         * m4/memxor.m4 (gl_MEMXOR): Likewise.
145201         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
145202         gl_C_RESTRICT replaced by AC_C_RESTRICT.
145204         Merge from coreutils.
145205         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
145206         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
145207         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
145208         * m4/time_r.m4 (gl_TIME_R): Likewise.
145210 2006-08-09  Karl Berry  <karl@gnu.org>
145212         * config/srclist.txt: no more gettext-tools, per Bruno.
145214 2006-08-08  Eric Blake  <ebb9@byu.net>
145216         * modules/verror: New module.
145217         * MODULES.html.sh: Document it.
145219 2006-08-08  Eric Blake  <ebb9@byu.net>
145221         * lib/verror.h, lib/verror.c: New files.
145223 2006-08-08  Eric Blake  <ebb9@byu.net>
145225         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
145226         verror_at_line output complies with GNU Coding Standards even when
145227         file is NULL.
145229 2006-08-07  Bruno Haible  <bruno@clisp.org>
145231         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
145232         versions of AIX.
145233         Reported by Ralf Wildenhues.
145235 2006-08-07  Bruno Haible  <bruno@clisp.org>
145237         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
145238         in an AC_DEFUN. Needed so that the autoconf snippets can use
145239         AC_REQUIRE.
145241 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
145243         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
145244         Initialize pkgdata_DATA.
145245         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
145246         overriding it.
145248 2006-08-06  Eric Blake  <ebb9@byu.net>
145250         * lib/error.h: Fold in some upstream changes from glibc.
145251         * lib/error.c: Likewise.
145253 2006-08-04  Bruno Haible  <bruno@clisp.org>
145255         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
145256         Make the mostlyclean-local rule depend on mostlyclean-generic.
145257         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
145259 2006-07-31  Bruno Haible  <bruno@clisp.org>
145261         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
145262         <stdlib.h>, <string.h>.
145264 2006-07-30  Bruno Haible  <bruno@clisp.org>
145266         * modules/readlink (License): Change to LGPL.
145268 2006-07-30  Bruno Haible  <bruno@clisp.org>
145270         * modules/javaversion (Makefile.am): Distribute javaversion.java and
145271         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
145272         set PKGDATADIR to point to it.
145274 2006-07-30  Bruno Haible  <bruno@clisp.org>
145276         * modules/csharpexec (configure.ac): Comment out macro invocation.
145277         * modules/javaexec (configure.ac): Likewise.
145278         * modules/javacomp-script (configure.ac): Likewise.
145280         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
145282 2006-07-30  Bruno Haible  <bruno@clisp.org>
145284         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
145285         linked-list.
145287 2006-07-30  Bruno Haible  <bruno@clisp.org>
145289         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
145291 2006-07-30  Bruno Haible  <bruno@clisp.org>
145293         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
145294         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
145295         get removed.
145297 2006-07-29  Bruno Haible  <bruno@clisp.org>
145299         Make it possible for gnulib-tool to work with locally modified or
145300         augmented gnulib repositories.
145301         * gnulib-tool (func_usage): Document --local-dir option.
145302         (local_gnulib_dir): New variable.
145303         Handle --local-dir option.
145304         (func_lookup_file): New function.
145305         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
145306         (func_get_description, func_get_filelist, func_get_description,
145307         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
145308         func_get_automake_snippet, func_get_include_directive,
145309         func_get_license, func_get_maintainer): Use func_lookup_file.
145310         (func_import, func_create_testdir): Use func_lookup_file.
145312 2006-07-29  Bruno Haible  <bruno@clisp.org>
145314         * modules/setenv (Depends-on): Add unistd.
145316 2006-07-29  Bruno Haible  <bruno@clisp.org>
145318         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
145320 2006-07-29  Bruno Haible  <bruno@clisp.org>
145322         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
145324 2006-07-29  Bruno Haible  <bruno@clisp.org>
145326         * gnulib-tool (import, update): If there is no Makefile.am, look at
145327         aclocal.m4, instead of bailing out.
145329 2006-07-29  Bruno Haible  <bruno@clisp.org>
145331         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
145332         Categorize the options by when they are useful.
145334 2006-07-29  Bruno Haible  <bruno@clisp.org>
145336         * gnulib-tool (func_usage): Document option --no-libtool.
145337         Handle option --no-libtool.
145338         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
145339         for changed semantics of $libtool variable.
145340         (func_import): Likewise. If libtool is not used, show this through
145341         an option --no-libtool.
145342         (func_create_testdir): Update.
145344 2006-07-29  Bruno Haible  <bruno@clisp.org>
145346         * gnulib-tool (func_import): Extend error message about missing
145347         --doc-base.
145349 2006-07-29  Bruno Haible  <bruno@clisp.org>
145351         * gnulib-tool (func_import): Don't create the $docbase directory if
145352         there is no file to store there.
145354 2006-07-29  Bruno Haible  <bruno@clisp.org>
145356         * gnulib-tool (autoconf_minversion): If a --dir option is given and
145357         relevant, look for configure.ac there, not in the current directory.
145358         Also use a simple search for AC_PREREQ, not "autoconf --trace".
145360 2006-07-29  Bruno Haible  <bruno@clisp.org>
145362         * gnulib-tool (SORT): New variable.
145363         (func_usage): Undocument --assume-autoconf option.
145364         Remove --assume-autoconf option handling.
145365         (autoconf_minversion): Determine from the contents of configure.ac.
145366         (func_import): Remove autoconf_minversion handling.
145367         Suggested by Eric Blake.
145369 2006-07-29  Bruno Haible  <bruno@clisp.org>
145371         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
145373 2006-07-29  Bruno Haible  <bruno@clisp.org>
145375         * config/srclist.txt (*setenv.[ch]): Remove rules.
145377 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
145379         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
145381 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
145383         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
145384         arpa/inet.h.
145386 2006-07-28  Simon Josefsson  <jas@extundo.com>
145388         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
145389         * modules/inet_pton (Depends-on): Likewise.
145391 2006-07-28  Simon Josefsson  <jas@extundo.com>
145393         * m4/netinet_in_h.m4: New file.
145395 2006-07-28  Simon Josefsson  <jas@extundo.com>
145397         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
145398         #include's.
145400 2006-07-28  Simon Josefsson  <jas@extundo.com>
145402         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
145403         #include's.
145405 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
145407         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
145408         setgid on directories only if they set these bits.
145409         * lib/modechange.h: Remove obsolete comment about masks.
145411 2006-07-28  Eric Blake  <ebb9@byu.net>
145413         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
145414         macro expansion.
145416 2006-07-28  Bruno Haible  <bruno@clisp.org>
145418         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
145420 2006-07-28  Bruno Haible  <bruno@clisp.org>
145422         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
145424 2006-07-28  Bruno Haible  <bruno@clisp.org>
145426         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
145427         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
145428         Define fallbacks.
145429         Avoids link error on FreeBSD 4.x.
145430         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
145432         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
145433         encoding.
145434         * lib/mbswidth.c (iswcntrl): Likewise.
145436 2006-07-27  Bruno Haible  <bruno@clisp.org>
145438         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
145439         test.
145441 2006-07-27  Bruno Haible  <bruno@clisp.org>
145443         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
145444         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
145445         defined.
145447 2006-07-26  Eric Blake  <ebb9@byu.net>
145449         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
145451 2006-07-26  Eric Blake  <ebb9@byu.net>
145453         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
145454         like mingw that lack mkstemp.
145455         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
145456         avoid compilation warning on mingw.
145458 2006-07-26  Bruno Haible  <bruno@clisp.org>
145460         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
145461         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
145462         INT_FAST*_MIN, INTPTR_MIN.
145464 2006-07-25  Bruno Haible  <bruno@clisp.org>
145466         * modules/version-etc (Depends-on): Add stdarg.
145468 2006-07-25  Bruno Haible  <bruno@clisp.org>
145470         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
145471         complex commands.
145473 2006-07-25  Bruno Haible  <bruno@clisp.org>
145475         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
145476         defined in <stdarg.h> or config.h.
145478 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
145480         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
145481         (gl_STDIO_SAFER): Remove.
145483 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
145485         * MODULES.html.sh (File stream based Input/Output):
145486         Add fopen-safer, tmpfile-safer; remove stdio-safer.
145487         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
145488         * modules/fopen-safer, modules/tmpfile-safer: New files.
145489         * modules/stdio-safer: Remove.
145491 2006-07-24  Bruno Haible  <bruno@clisp.org>
145493         * modules/tmpdir: New file.
145494         * MODULES.html.sh (File system functions): Add it.
145496 2006-07-24  Bruno Haible  <bruno@clisp.org>
145498         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
145499         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
145501 2006-07-24  Bruno Haible  <bruno@clisp.org>
145503         * modules/clean-temp: New file.
145505 2006-07-24  Bruno Haible  <bruno@clisp.org>
145507         * m4/tmpdir.m4: New file, from GNU gettext.
145509 2006-07-24  Bruno Haible  <bruno@clisp.org>
145511         * lib/tmpdir.h: New file, from GNU gettext.
145512         * lib/tmpdir.c: New file, from GNU gettext.
145514 2006-07-24  Bruno Haible  <bruno@clisp.org>
145516         * lib/clean-temp.h: New file, from GNU gettext.
145517         * lib/clean-temp.c: New file, from GNU gettext.
145519 2006-07-23  Eric Blake  <ebb9@byu.net>
145521         * modules/stdio-safer (Files): Add tmpfile-safer.c.
145522         (Depends-on): Add binary-io.
145524 2006-07-23  Eric Blake  <ebb9@byu.net>
145526         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
145528 2006-07-23  Eric Blake  <ebb9@byu.net>
145530         * lib/tmpfile-safer.c: New file.
145531         * lib/stdio-safer.h (fopen_safer): Add prototype.
145532         * lib/stdio--.h (tmpfile): Make safer.
145534 2006-07-23  Bruno Haible  <bruno@clisp.org>
145536         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
145537         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
145538         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
145539         gl_linked_remove_at): Use it.
145541 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
145542         and Simon Josefsson <jas@extundo.com>
145544         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
145546         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
145548 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
145550         * modules/close-stream: New file.
145551         * modules/closeout (Description): Make it clear that it exits
145552         with a diagnostic on error.
145553         (Depends-on): Add close-stream.  Remove fpending, stdbool.
145554         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
145556 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
145558         * m4/close-stream.m4: New file.
145560 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
145562         * lib/close-stream.c, lib/close-stream.h: New files.
145564 2006-07-22  Bruno Haible  <bruno@clisp.org>
145566         Merge from GNU gettext 0.15.
145568         2006-05-01  Bruno Haible  <bruno@clisp.org>
145570                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
145572         2006-07-22  Bruno Haible  <bruno@clisp.org>
145574                 * modules/javaversion: New file.
145575                 * MODULES.html.sh (Java): Add javaversion.
145577         2006-03-12  Bruno Haible  <bruno@clisp.org>
145579                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
145581         2005-12-04  Bruno Haible  <bruno@clisp.org>
145583                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
145584                 (untested).
145586         2006-06-21  Bruno Haible  <bruno@clisp.org>
145588                 Avoid warnings from recent versions of mcs.
145589                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
145590                 -o, -L, -r any more. Use options documented since mcs-1.0
145591                 instead. Similarly for -g.
145593         2005-12-04  Bruno Haible  <bruno@clisp.org>
145595                 * build-aux/csharpcomp.sh.in: Suffix for resources is
145596                 .resources, not .resource.
145598         2005-07-09  Bruno Haible  <bruno@clisp.org>
145600                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
145601                 add a .dll suffix.
145602                 Reported by Mark Junker <mjscod@gmx.de>.
145604         2006-07-22  Bruno Haible  <bruno@clisp.org>
145606                 * modules/gettext: Upgrade to gettext-0.15.
145607                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
145608                 m4/visibility.m4.
145609                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
145611 2006-07-22  Bruno Haible  <bruno@clisp.org>
145613         Merge from GNU gettext 0.15.
145615         2006-03-25  Bruno Haible  <bruno@clisp.org>
145617                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
145619         2006-07-21  Bruno Haible  <bruno@clisp.org>
145621                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
145622                 "1.1".
145624         2006-05-09  Bruno Haible  <bruno@clisp.org>
145626                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
145627                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
145628                 for the conftestver execution.
145630         2006-05-01  Bruno Haible  <bruno@clisp.org>
145632                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
145633                 optional target-version argument. Verify that the compiler
145634                 groks source of the specified source-version, or add -source
145635                 option as necessary. Verify that the compiler produces
145636                 bytecode in the specified target-version, or add -target and
145637                 -source options as necessary. Make the result of the test
145638                 available as variable CONF_JAVAC. Also log error output in
145639                 config.log.
145641         2006-03-11  Bruno Haible  <bruno@clisp.org>
145643                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
145645         2006-05-09  Bruno Haible  <bruno@clisp.org>
145647                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
145648                 CLASSPATH_SEPARATOR to a semicolon.
145650         2006-03-12  Bruno Haible  <bruno@clisp.org>
145652                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
145653                 available as variable CONF_JAVA, for subsequent autoconf
145654                 tests. Also log error output in config.log.
145656         2006-07-19  Bruno Haible  <bruno@clisp.org>
145658                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
145659                 that getline works on glibc2 systems. Needed to avoid trouble
145660                 in relocatable.c.
145661                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
145663         2005-12-04  Bruno Haible  <bruno@clisp.org>
145665                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
145666                 launcher (untested).
145668         2005-12-04  Bruno Haible  <bruno@clisp.org>
145670                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
145672         2006-07-22  Bruno Haible  <bruno@clisp.org>
145674                 * gettext.m4: Update from GNU gettext-0.15.
145675                 * nls.m4: Likewise.
145676                 * po.m4: Likewise.
145677                 * inttypes-pri.m4: Likewise.
145678                 * inttypes-h.m4: Renamed from inttypes.m4.
145679                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
145681 2006-07-22  Bruno Haible  <bruno@clisp.org>
145683         Merge from GNU gettext 0.15.
145685         2005-07-05  Bruno Haible  <bruno@clisp.org>
145687                 * printf-args.c (printf_fetchargs): Work around broken
145688                 definition of wint_t on mingw.
145690         2005-02-12  Bruno Haible  <bruno@clisp.org>
145692                 * xallocsa.h: Add extern "C" for C++.
145694         2006-05-17  Bruno Haible  <bruno@clisp.org>
145696                 Cygwin portability.
145697                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
145699         2006-04-30  Bruno Haible  <bruno@clisp.org>
145701                 * progreloc.c: Include <mach-o/dyld.h> if available.
145702                 (find_executable): Use _NSGetExecutablePath when possible.
145704         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
145706                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
145707                 function.
145709         2005-12-29  Bruno Haible  <bruno@clisp.org>
145711                 * progreloc.c (set_program_name_and_installdir): Fix
145712                 compilation error.
145714         2005-12-04  Bruno Haible  <bruno@clisp.org>
145716                 Cygwin portability.
145717                 * progreloc.c: Include <windows.h> also on Cygwin.
145718                 (find_executable): Add support for Cygwin.
145719                 (set_program_name_and_installdir): Handle also platforms with
145720                 nonempty EXEEXT.
145722         2006-07-11  Bruno Haible  <bruno@clisp.org>
145724                 * javacomp.c: Fix a comment.
145725                 Reported by Jim Meyering.
145727         2006-04-30  Bruno Haible  <bruno@clisp.org>
145729                 * javacomp.h (compile_java_class): Add source_version,
145730                 target_version arguments.
145731                 * javacomp.c: Rewritten to choose only a compiler that
145732                 respects the specified source_version and target_version.
145734         2006-06-27  Bruno Haible  <bruno@clisp.org>
145736                 Assume correct S_ISDIR macro.
145737                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
145739         2006-07-22  Bruno Haible  <bruno@clisp.org>
145741                 * javaversion.h: New file, from GNU gettext.
145742                 * javaversion.c: New file, from GNU gettext.
145743                 * javaversion.java: New file, from GNU gettext.
145744                 * javaversion.class: New file, from GNU gettext.
145746         2006-05-17  Bruno Haible  <bruno@clisp.org>
145748                 Cygwin portability.
145749                 * javaexec.c (execute_java_class): Test for jview program
145750                 also on Cygwin.
145752         2006-04-09  Bruno Haible  <bruno@clisp.org>
145754                 * fatal-signal.c: Don't include string.h.
145755                 (at_fatal_signal): Use a copying loop instead of memcpy.
145757         2005-12-04  Bruno Haible  <bruno@clisp.org>
145759                 * csharpexec.c: Add support for 'clix' launcher (untested).
145760                 (execute_csharp_using_sscli): New function.
145761                 (execute_csharp_program): Call it.
145763         2006-06-21  Bruno Haible  <bruno@clisp.org>
145765                 Avoid warnings from recent versions of mcs.
145766                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
145767                 -o, -L, -r any more. Use options documented since mcs-1.0
145768                 instead. Similarly for -g.
145770         2005-07-09  Bruno Haible  <bruno@clisp.org>
145772                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
145773                 add a .dll suffix.
145774                 Reported by Mark Junker <mjscod@gmx.de>.
145776         2006-06-17  Bruno Haible  <bruno@clisp.org>
145778                 * config.charset: Update for NetBSD 3.0.
145780         2006-05-17  Bruno Haible  <bruno@clisp.org>
145782                 Cygwin portability.
145783                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
145785         2006-05-16  Bruno Haible  <bruno@clisp.org>
145787                 * localcharset.c [CYGWIN]: Include <windows.h>.
145788                 (get_charset_aliases): For Cygwin, return the same CPxxx
145789                 aliases list as under WIN32.
145790                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
145791                 the environment variables. Fall back to GetACP().
145793         2006-04-05  Bruno Haible  <bruno@clisp.org>
145795                 * config.charset: Update Juan Manuel Guerrero's address.
145797         2005-02-12  Bruno Haible  <bruno@clisp.org>
145799                 * allocsa.h: Add extern "C" for C++.
145801         2005-02-10  Bruno Haible  <bruno@clisp.org>
145803                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
145804                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
145806         2006-07-22  Bruno Haible  <bruno@clisp.org>
145808                 * gettext.h: Update to GNU gettext-0.15.
145810 2006-07-22  Bruno Haible  <bruno@clisp.org>
145812         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
145813         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
145814         lib-prefix.m4, longdouble.m4, ssize_t.m4.
145816 2006-07-21  Eric Blake  <ebb9@byu.net>
145818         * modules/stdlib-safer: New file.
145819         * MODULES.html.sh (File stream based Input/Output): Add
145820         stdlib-safer.
145822 2006-07-21  Eric Blake  <ebb9@byu.net>
145824         * lib/stdlib-safer.h: New file from coreutils, required by
145825         stdlib--.h.
145827 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
145829         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
145831 2006-07-20  Bruno Haible  <bruno@clisp.org>
145833         * gnulib-tool: Recognize new option --assume-autoconf.
145834         (autoconf_minversion): New variable.
145835         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
145837 2006-07-20  Bruno Haible  <bruno@clisp.org>
145839         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
145841 2006-07-19  Derek R. Price  <derek@ximbiot.com>
145843         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
145844         Reindent and repaginate.
145846 2006-07-19  Derek Price  <derek@ximbiot.com>
145848         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
145849         Correct grammar.
145851 2006-07-17  Bruno Haible  <bruno@clisp.org>
145853         * modules/list: New file.
145854         * modules/array-list: New file.
145855         * modules/carray-list, modules/carray-list-tests: New files.
145856         * modules/linked-list, modules/linked-list-tests: New files.
145857         * modules/avltree-list, modules/avltree-list-tests: New files.
145858         * modules/rbtree-list, modules/rbtree-list-tests: New files.
145859         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
145860         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
145861         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
145862         * modules/oset: New file.
145863         * modules/array-oset: New file.
145864         * modules/avltree-oset, modules/avltree-oset-tests: New files.
145865         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
145866         * tests/test-carray_list.c: New file.
145867         * tests/test-linked_list.c: New file.
145868         * tests/test-avltree_list.c: New file.
145869         * tests/test-rbtree_list.c: New file.
145870         * tests/test-linkedhash_list.c: New file.
145871         * tests/test-avltreehash_list.c: New file.
145872         * tests/test-rbtreehash_list.c: New file.
145873         * tests/test-avltree_oset.c: New file.
145874         * tests/test-rbtree_oset.c: New file.
145875         * MODULES.html.sh (Container data structures): New section.
145877 2006-07-17  Bruno Haible  <bruno@clisp.org>
145879         * m4/gl_list.m4: New file.
145881 2006-07-17  Bruno Haible  <bruno@clisp.org>
145883         * lib/gl_list.h: New file.
145884         * lib/gl_list.c: New file.
145885         * lib/gl_array_list.h: New file.
145886         * lib/gl_array_list.c: New file.
145887         * lib/gl_carray_list.h: New file.
145888         * lib/gl_carray_list.c: New file.
145889         * lib/gl_linked_list.h: New file.
145890         * lib/gl_linked_list.c: New file.
145891         * lib/gl_anylinked_list1.h: New file.
145892         * lib/gl_anylinked_list2.h: New file.
145893         * lib/gl_avltree_list.h: New file.
145894         * lib/gl_avltree_list.c: New file.
145895         * lib/gl_anyavltree_list1.h: New file.
145896         * lib/gl_anyavltree_list2.h: New file.
145897         * lib/gl_rbtree_list.h: New file.
145898         * lib/gl_rbtree_list.c: New file.
145899         * lib/gl_anyrbtree_list1.h: New file.
145900         * lib/gl_anyrbtree_list2.h: New file.
145901         * lib/gl_anytree_list1.h: New file.
145902         * lib/gl_anytree_list2.h: New file.
145903         * lib/gl_linkedhash_list.h: New file.
145904         * lib/gl_linkedhash_list.c: New file.
145905         * lib/gl_anyhash_list1.h: New file.
145906         * lib/gl_anyhash_list2.h: New file.
145907         * lib/gl_avltreehash_list.h: New file.
145908         * lib/gl_avltreehash_list.c: New file.
145909         * lib/gl_rbtreehash_list.h: New file.
145910         * lib/gl_rbtreehash_list.c: New file.
145911         * lib/gl_anytreehash_list1.h: New file.
145912         * lib/gl_anytreehash_list2.h: New file.
145914         * lib/gl_oset.h: New file.
145915         * lib/gl_oset.c: New file.
145916         * lib/gl_array_oset.h: New file.
145917         * lib/gl_array_oset.c: New file.
145918         * lib/gl_avltree_oset.h: New file.
145919         * lib/gl_avltree_oset.c: New file.
145920         * lib/gl_rbtree_oset.h: New file.
145921         * lib/gl_rbtree_oset.c: New file.
145922         * lib/gl_anytree_oset.h: New file.
145924 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
145926         * m4/mkancesdirs.m4: New file.
145927         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
145928         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
145929         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
145930         it.
145932 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
145934         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
145935         * lib/mkancesdirs.h: New files.
145936         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
145937         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
145938         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
145939         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
145940         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
145941         callers changed.  Revamp internals significantly, by not
145942         attempting to create directories that are temporarily more
145943         permissive than the final results.  Do not attempt to use
145944         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
145945         This removes some race conditions, fixes some bugs, and simplifies
145946         things.  Use new dirchownmod function to do owner and mode changes.
145947         * lib/mkdir-p.h: Likewise.
145948         * lib/modechange.c (octal_to_mode): New function.
145949         (struct mode_change): New member mentioned.
145950         (make_node_op_equals): New arg mentioned.  All callers changed.
145951         (mode_compile): Keep track of which mode bits the user has explicitly
145952         mentioned.
145953         (mode_adjust): New arg DIR, so that we implement the X op correctly.
145954         New arg PMODE_BITS, to keep track of which mode bits the user
145955         mentioned; it treats S_ISUID and S_ISGID speciall.
145956         All callers changed.
145957         * lib/modechange.h: Likewise.
145959 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
145961         * MODULES.html.sh: Add mkancestors.
145962         * modules/mkancesdirs: New module.
145963         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
145964         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
145965         The chdir-safer and afs files are now orphans; I'll remove them
145966         unless someone speaks up.
145967         Add lib/dirchownmod.c, lib/dirchownmod.h.
145968         (Depends-on): Remove alloca, chown, save-cwd, dirname.
145969         Add lchown, mkancesdirs.
145970         (Maintainer): Add self.
145972 2006-07-15  Karl Berry  <karl@gnu.org>
145974         * gnulib-tool: help message wording/arrangement.
145976 2006-07-14  Simon Josefsson  <jas@extundo.com>
145978         * doc/gnulib.texi (Libtool and Windows): New section.
145980 2006-07-12  Simon Josefsson  <jas@extundo.com>
145982         * modules/gendocs (License): Fix license, approved by Karl.
145984 2006-07-12  Eric Blake  <ebb9@byu.net>
145986         * MODULES.html.sh: Add gendocs.
145988 2006-07-11  Eric Blake  <ebb9@byu.net>
145990         * modules/fdl: New module, to install doc/fdl.texi.
145991         * MODULES.html.sh: Add new section for documentation modules.
145992         * gnulib-tool: Avoid space-tab.
145993         (--doc-base): New option, to manage files from doc.
145995 2006-07-11  Eric Blake  <ebb9@byu.net>
145997         * m4/absolute-header.m4: Fix comments to match recent change.
145999 2006-07-11  Eric Blake  <ebb9@byu.net>
146001         * gnulib-tool: List --doc-base before --tests-base.
146003 2006-07-11  Derek R. Price  <derek@ximbiot.com>
146005         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
146007 2006-07-11  Bruno Haible  <bruno@clisp.org>
146009         * README: Mention where to put documentation.
146011 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
146013         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
146015 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
146017         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
146018         to stdint.m4.
146020 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
146022         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
146023         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
146024         "no/such/file/stdint.h" when there is no such file, so that
146025         the resulting C code can be parsed by dodgy compilers.
146026         Problems reported by Bob Proulx.
146028 2006-07-10  Derek R. Price  <derek@ximbiot.com>
146030         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
146031         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
146032         macros into the GNU _D_EXACT_NAMLEN.
146033         * lib/savedir.c:  Likewise.
146034         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
146036 2006-07-10  Derek R. Price  <derek@ximbiot.com>
146037         and Paul Eggert  <eggert@cs.ucla.edu>
146039         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
146040         * m4/savedir.m4:
146041         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
146042         macros into the GNU _D_EXACT_NAMLEN.
146044 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
146046         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
146047         around the absolute name, to work around a problem with the HP-UX
146048         11.23 native C compiler, reported by Bob Proulx.
146050 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
146052         * doc/maintain.texi, make-stds.texi: Sync from
146053         <http://savannah.gnu.org/projects/gnustandards>.
146055 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
146057         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
146059 2006-07-09  Jim Meyering  <jim@meyering.net>
146061         * m4/glob.m4: Remove a doubled word in a comment.
146063 2006-07-09  Jim Meyering  <jim@meyering.net>
146065         * lib/argp-pv.c: Remove a doubled word in a comment.
146066         * lib/check-version.c (check_version): Likewise.
146067         * lib/javacomp.c (compile_java_class): Likewise.
146069 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
146071         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
146072         for the benefit of people using Autoconf 2.60.  If you want to
146073         support older Autoconf versions you can copy m4/onceonly_2_57.m4
146074         (or m4/onceonly.m4, if pre-2.57) manually.
146076 2006-07-08  Jim Meyering  <jim@meyering.net>
146078         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
146079         comment.
146080         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
146081         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
146082         comment.
146084 2006-07-08  Jim Meyering  <jim@meyering.net>
146086         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
146088 2006-07-07  Simon Josefsson  <jas@extundo.com>
146090         * tests/test-crc.c: Change expected crc value, the test vector
146091         were probably computed using the old broken crc.c?
146093 2006-07-06  Simon Josefsson  <jas@extundo.com>
146095         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
146096         now the canonical place for the M4 file).
146098         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
146099         from the sys_socket dependency now.
146101         * modules/inet_pton (Files): Ditto.
146103         * modules/inet_ntop (Files): Ditto.
146105 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
146107         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
146108         not gl_PREREQ_GETUSERSHELL.
146110 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
146112         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
146113         with only one argument, for Autoconf 2.60.
146114         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
146115         expand to nothing, so add a shell command to avoid syntax error.
146116         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
146118 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
146120         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
146122 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
146124         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
146125         no longer needed.  Check for isblank decl.
146126         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
146127         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
146128         of existence.
146130 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
146132         * lib/getloadavg.c: Use __VMS, not VMS.
146133         * lib/getopt.c: Likewise.
146134         * lib/getpagesize.h: Likewise.
146135         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
146136         and probably does not work.
146138 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
146140         * lib/.cppi-disable: Add wcwidth.
146141         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
146142         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
146143         (ISGRAPH): Remove.  All uses changed to isgraph.
146144         (FOLD) [!defined _LIBC]: Remove special case.
146145         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
146146         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
146147         HAVE_ISBLANK.
146148         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
146149         case.
146151 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
146153         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
146154         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
146155         brackets.  Other minor changes to suppress some compiler
146156         warnings.
146158 2006-07-06  Derek R. Price  <derek@ximbiot.com>
146159         and Paul Eggert  <eggert@cs.ucla.edu>
146161         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
146162         of invoking obsolescent AC_HEADER_DIRENT macro.
146163         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
146164         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
146165         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
146166         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
146167         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
146168         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
146169         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
146170         * m4/readdir.m4: Remove; no longer needed.
146172 2006-07-06  Derek R. Price  <derek@ximbiot.com>
146173         and Paul Eggert  <eggert@cs.ucla.edu>
146175         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
146176         Don't worry about this obsolete case any more.
146177         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
146178         directories.
146179         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
146180         worry about this obsolete case any more.
146181         * lib/fts.c: Likewise.
146182         * lib/getcwd.c: Likewise.
146183         * lib/glob.h: Likewise.
146184         * lib/savedir.c: Likewise.
146186 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
146188         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
146189         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
146190         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
146191         needed.
146192         All uses removed.
146193         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
146194         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
146195         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
146196         needed.
146197         * m4/getdate.m4 (gl_GETDATE): Likewise.
146198         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
146199         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
146200         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
146201         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
146202         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
146203         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
146204         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
146205         needed.
146207 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
146209         * lib/memcasecmp.c: Include <limits.h>.
146210         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
146211         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
146212         Don't assume isdigit succeeds only on '0' through '9'.
146214 2006-07-05  Eric Blake  <ebb9@byu.net>
146216         * modules/getaddrinfo (Depends-on): Add snprintf.
146218 2006-07-05  Eric Blake  <ebb9@byu.net>
146220         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
146221         to avoid 'header present but could not be compiled' on cygwin.
146223 2006-07-05  Eric Blake  <ebb9@byu.net>
146225         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
146226         missing from netdb.h.
146227         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
146229 2006-07-05  Derek R. Price  <derek@ximbiot.com>
146231         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
146232         no longer needed.
146233         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
146234         * m4/getdate.m4 (gl_GETDATE): Likewise.
146235         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
146236         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
146237         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
146238         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
146239         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
146241 2006-07-05  Derek R. Price  <derek@ximbiot.com>
146243         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
146244         All uses of is_space replaced by isspace.
146245         * lib/exit.h: Don't talk about STDC_HEADERS.
146246         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
146247         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
146248         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
146249         replaced by isprint etc.
146250         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
146251         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
146252         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
146253         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
146254         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
146255         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
146257 2006-07-05  Bruno Haible  <bruno@clisp.org>
146259         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
146260         the function exists, before testing against AIX.
146261         Reported by Martin Lambers <marlam@marlam.de>.
146263 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
146265         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
146266         From Mark D. Baushke.
146268 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
146270         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
146271         to the absolute name, not just one, to bypass Sun C 5.8's
146272         "warning: #include of /usr/include/... may be non-portable".
146274 2006-07-04  Eric Blake  <ebb9@byu.net>
146276         * modules/dirname-tests: New test module.
146277         * tests/test-dirname.c: New file, replacing dirname.c
146278         TEST_DIRNAME section that was recently deleted.
146280 2006-07-04  Bruno Haible  <bruno@clisp.org>
146282         Assume ANSI C header files and <ctype.h> functions.
146283         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
146284         (mbsnwidth): Use isprint, iscntrl instead.
146286 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
146288         Merge from coreutils.
146289         * MODULES.html.sh: Add xstrtold.
146290         * modules/xstrtold: New file.
146291         * modules/cycle-check (Files): Add lib/same-inode.h.
146292         * modules/dirname (Files): Add m4/double-slash-root.m4.
146293         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
146294         * modules/mkdir-p (Files): Add lib/same-inode.h.
146295         * modules/same (Files): Add lib/same-inode.h.
146297 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
146299         * m4/absolute-header.m4: Renamed from full-header-path.m4.
146300         This is to keep the terminology clean; POSIX talks about
146301         "absolute pathnames", not "full pathnames", but the GNU
146302         Coding Standards say to use "path" for something else;
146303         so use "absolute" to keep both sides happy.
146304         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
146305         Set gl_absolute_header, not gl_full_header_path.
146306         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
146307         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
146308         All uses changed.
146310         Merge from coreutils.
146312         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
146314         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
146315         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
146316         want to require the building of c-strtod.o.
146317         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
146318         needs -lm directly.
146319         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
146321         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
146323         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
146324         --as-needed option if available.  Problem reported by Albert Chin in
146325         <http://lists.gnu.org/r/bug-gnulib/2006-06/msg00114.html>.
146326         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
146327         cc merely issues a bunch of annoying warnings for --as-needed
146328         (this problem was reported by Bob Proulx).  Also, try linking with
146329         -lm to detect a bug in binutils 2.16 (this problem was reported
146330         by Ralf Wildenhues).
146332         2006-06-18  Jim Meyering  <jim@meyering.net>
146334         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
146335         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
146336         macro.
146337         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
146338         also check for glibc-2.4's abort-inducing bug.
146340         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
146341         Low-probability clean-up should be to use rmdir to get rid of
146342         the just-created directory, not unlink.
146344         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
146345         configure fail, and request a bug report to inform us about it.
146346         Add a comment that, barring reports to the contrary, in 2007 we'll
146347         assume ftruncate is universally available.
146349         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
146351         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
146353         2006-03-12  Jim Meyering  <jim@meyering.net>
146355         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
146356         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
146357         * m4/same.m4 (gl_SAME): Likewise.
146358         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
146360         2006-03-11  Eric Blake  <ebb9@byu.net>
146362         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
146363         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
146364         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
146365         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
146367 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
146369         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
146370         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
146371         reported by Mark D. Baushke, one in
146372         <http://lists.gnu.org/r/bug-gnulib/2006-07/msg00015.html>.
146374         Merge from coreutils.
146376         * lib/.cppi-disable: Add stdint_.h.
146377         * lib/.cvsignore: Add stdint.h.
146379         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
146381         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
146382         both double and long double versions.
146383         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
146384         * lib/xstrtold.c: New file.
146385         * lib/xstrtod.h (xstrtold): New decl.
146387         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
146389         * lib/filemode.c (setst): Remove.
146390         (strmode): Rewrite to avoid setst.  This makes the code shorter,
146391         (arguably) clearer, and the generated code is a bit smaller on my
146392         Debian GNU/Linux stable x86 host.
146394         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
146396         * lib/filemode.c: Include "filemode.h" first, to test the interface.
146397         Assume that filemode.h includes sys/types.h and sys/stat.h.
146398         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
146399         (ftypelet): Reorder to put common cases first, for efficiency.
146400         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
146401         to do 'M'.
146402         (strmode): Renamed from mode_string, and now stores 12 bytes instead
146403         of 10, for compatibility with FreeBSD.  All callers changed.
146404         (filemodestring): Now stores 12 bytes instead of 10, and sets file
146405         types that can't be deduced solely from st_mode.  First arg is now a
146406         const pointer.
146407         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
146408         (strmode): Renamed from mode_string.
146409         (filemodestring): New decl.
146410         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
146411         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
146412         needed.
146413         (S_ISPORT, S_ISWHT): New macros, if not already defined.
146415         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
146417         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
146418         fsusage.h now does that.  Include fsusage.h first, to test interface.
146419         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
146420         at most one method (the old code could have generated decls that
146421         didn't conform to C89, not that this was ever exercised).
146422         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
146424         2006-03-19  Jim Meyering  <jim@meyering.net>
146426         Work even in a chroot where d_ino values for entries in "/"
146427         don't match the stat.st_ino values for the same names.
146428         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
146429         number, iterate through all entries again, using lstat instead.
146430         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
146431         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
146433         * lib/getcwd.c (__getcwd): Clarify a comment.
146434         Use memcpy in place of a call to strcpy.
146436         2006-03-12  Jim Meyering  <jim@meyering.net>
146438         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
146439         matches that of the current directory (which we're about to chdir ".."
146440         out of), then save the dev-ino of the parent, instead.
146442         * lib/same-inode.h (SAME_INODE): New file/macro.
146443         * lib/chdir-safer.c (SAME_INODE): Remove definition.
146444         Include "same-inode.h", instead.
146445         * lib/same.c: Likewise.
146446         * lib/cycle-check.h: Include "same-inode.h".
146447         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
146448         * lib/cycle-check.c (SAME_INODE): Remove definition.
146449         * lib/root-dev-ino.h: Include "same-inode.h".
146451         2006-03-11  Eric Blake  <ebb9@byu.net>
146453         * lib/same.c (same_name): s/base_name/last_component/
146454         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
146455         * lib/filenamecat.c (file_name_concat): Likewise.
146457         2006-03-11  Eric Blake  <ebb9@byu.net>,
146458                     Paul Eggert  <eggert@cs.ucla.edu>
146460         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
146461         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
146462         drive prefix.
146463         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
146464         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
146465         (last_component): New method.
146466         * lib/dirname.c (dir_len): Determine when drive letters need a
146467         subsequent slash.  Preserve // when it is special.
146468         (dir_name): Don't append dot when drive letter is absolute.
146469         [TEST_DIRNAME]: Move into a full-blown gnulib test.
146470         * lib/basename.c (base_name): New semantics - malloc the result.
146471         Preserve // when it is special.  Preserve relative files that look
146472         like drive letters.
146473         (base_len): Preserve // when it is special.
146474         (last_component): New method, similar to old base_name semantics.
146475         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
146476         base_name.  Strip redundant slashes from ///.
146478 2006-07-03  Jim Meyering  <jim@meyering.net>
146480         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
146481         macro is used before the first cycle_check call.
146483 2006-07-03  Eric Blake  <ebb9@byu.net>
146485         * modules/dirname (Depends-on): Add xstrndup.
146487 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
146489         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
146490         test cases, so that config.log is a bit easier to follow.
146492 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
146494         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
146495         both are 64 bits, since this seems to be the tradition, and this
146496         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
146497         we ever run into a host that prefers long long to long in this
146498         case, we'll need another configure-time test.  Problem reported by
146499         Jim Meyering.
146501 2006-07-02  Eric Blake  <ebb9@byu.net>
146503         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
146505 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
146507         * modules/inttypes (Depends-on): No longer depends on stdint.
146508         * modules/stdint (Description): Say more about assumptions.
146509         Say that the fast types might differ.  Say macros are used.
146510         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
146511         (Makefile.am): Revise list of substituted symbols to match
146512         new stdint.m4.
146513         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
146514         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
146515         * tests/test-stdint.c (verify_same_types)
146516         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
146517         the code conforms to C99/C89.
146518         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
146519         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
146521 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
146523         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
146524         but fix a bug, by requiring at least 64 bits.
146525         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
146526         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
146527         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
146528         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
146530         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
146531         changes.  Make 2.59 a prerequisite.  Check and substitute for
146532         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
146533         inttypes.h.  Do not use special include files; just use the
146534         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
146535         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
146536         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
146537         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
146538         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
146539         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
146540         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
146541         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
146542         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
146543         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
146544         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
146545         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
146546         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
146547         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
146548         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
146549         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
146550         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
146551         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
146552         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
146553         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
146554         WINT_MAX.  Check for C99 conformance more strictly, by detecting
146555         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
146556         not check for things that C99 does not require, e.g., int8_t.  If
146557         a test isn't needed unless <stdint.h> isn't working, and is
146558         unlikely to be needed for any other reason, then don't do it
146559         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
146560         size_t, since we assume C89 freestanding at least.  Do not check
146561         for sig_atomic_t, wchar_t, or wint_t, since the code now does
146562         the right thing even if the types are not defined.  Instead use:
146563         (gl_STDINT_TYPE_PROPERTIES): New macro.
146564         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
146565         testing whether <sys/types.h> clashes, as Autoconf does this for
146566         us now.  All uses removed.
146567         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
146568         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
146569         (gl_CHECK_TYPE_SAME):
146570         Remove; no longer needed.
146571         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
146572         exists, since we'll return 0 anyway in that case.
146573         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
146575 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
146577         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
146578         possible collision with system files.
146579         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
146580         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
146581         WCHAR_MIN and WCHAR_MAX in this case.
146582         (<stddef.h>): Do not include; no longer needed.
146583         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
146584         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
146585         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
146586         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
146587         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
146588         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
146589         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
146590         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
146591         !defined(__c99))]: Include in this case too, since it's harmless
146592         now.
146593         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
146594         dangerous to do so.
146595         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
146596         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
146597         (_STDINT_MIN, _STDINT_MAX): New macros.
146598         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
146599         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
146600         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
146601         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
146602         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
146603         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
146604         macros, not typedefs; this simplifies things quite a bit.
146605         Use long int for all types narrower than int64_t.
146606         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
146607         Define in terms of long long int or int64_t or long int,
146608         not int64_t or int32_t.  This saves some compile-time testing.
146609         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
146610         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
146611         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
146612         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
146613         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
146614         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
146615         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
146616         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
146617         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
146618         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
146619         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
146620         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
146621         undef any previous version and define our own version, for
146622         simplicity and consistency with the new macros for types.
146623         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
146624         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
146625         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
146626         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
146627         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
146628         @WINT_T_SUFFIX@ to keep things simple here.
146629         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
146630         Simplify by assuming typical 8/16/32/64 host, since we're
146631         already doing that elsewhere anyway.
146632         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
146633         and assume long long int is 64 bits if available.  This
146634         speeds up 'configure'.
146636 2006-07-01  Eric Blake  <ebb9@byu.net>
146638         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
146639         Reported by Andreas Buening.
146641 2006-07-01  Eric Blake  <ebb9@byu.net>
146643         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
146645 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
146647         * lib/getaddrinfo.c: fixed typo
146649 2006-06-29  Jim Meyering  <jim@meyering.net>
146651         * modules/strftime (Maintainer): Add my name, since with the
146652         FPRINTFTIME changes strftime.c has forked from glibc.
146654 2006-06-29  Eric Blake  <ebb9@byu.net>
146656         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
146658 2006-06-29  Eric Blake  <ebb9@byu.net>
146660         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
146662 2006-06-29  Eric Blake  <ebb9@byu.net>
146664         * lib/stat_.h: New file.
146666 2006-06-29  Eric Blake  <ebb9@byu.net>
146668         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
146669         unused static function.
146671 2006-06-29  Eric Blake  <ebb9@byu.net>
146673         * doc/functions.texi (Function Portability): Document missing lstat
146674         on mingw.
146676 2006-06-29  Eric Blake  <ebb9@byu.net>
146678         * MODULES.html.sh: Add sys_stat.
146679         * modules/sys_stat: New module.
146680         * modules/mkstemp (Depends-on): Add sys_stat.
146682 2006-06-29  Derek R. Price  <derek@ximbiot.com>
146684         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
146686 2006-06-29  Derek R. Price  <derek@ximbiot.com>
146688         * m4/c-bs-a.m4: Removed.
146690 2006-06-29  Derek R. Price  <derek@ximbiot.com>
146692         * lib/strftime.c: Assume strftime() exists.
146694 2006-06-29  Derek Price  <derek@ximbiot.com>
146696         * modules/c-bs-a: Removed - \a is C89.
146697         * MODULES.html.sh: Remove c-bs-a.
146699 2006-06-29  Bruno Haible  <bruno@clisp.org>
146701         * modules/wcwidth (License): Change to LGPL.
146703 2006-06-28  Simon Josefsson  <jas@extundo.com>
146705         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
146706         on _WIN32.
146708         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
146709         getnameinfo.
146711 2006-06-28  Simon Josefsson  <jas@extundo.com>
146713         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
146715 2006-06-28  Simon Josefsson  <jas@extundo.com>
146717         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
146718         functions there.  It will succeed on Windows XP, but on Windows
146719         2000 and (presumably) earlier, it will fail, and use the internal
146720         re-implementation.
146721         (use_win32_p): New function.
146722         (getaddrinfo): Use strtoul on servname, to support numeric ports.
146723         Support AI_NUMERICSERV to disable getservbyname.
146724         (getnameinfo): New function, only supports
146725         NI_NUMERICHOST|NI_NUMERICSERV for now.
146727         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
146728         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
146729         getnameinfo.
146731 2006-06-28  Eric Blake  <ebb9@byu.net>
146733         * modules/wcwidth: New file.
146734         * modules/mbchar (Depends-on): Add wcwidth.
146735         * modules/mbswidth (Depends-on): Add wcwidth.
146736         * MODULES.html.sh: Add wcwidth.
146738 2006-06-28  Eric Blake  <ebb9@byu.net>
146740         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
146741         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
146743 2006-06-28  Eric Blake  <ebb9@byu.net>
146745         * lib/xvasprintf.h: Fix comments.
146747 2006-06-28  Eric Blake  <ebb9@byu.net>
146749         * lib/mbchar.h (wcwidth): Include wcwidth.h.
146750         * lib/mbswidth.c (wcwidth): Move from here...
146751         * lib/wcwidth.h: ...to this new file.
146753 2006-06-28  Derek R. Price  <derek@ximbiot.com>
146755         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
146757         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
146758         it's obsolete.
146759         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
146761 2006-06-28  Derek R. Price  <derek@ximbiot.com>
146763         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
146764         Autoconf 2.60 says this stuff was obsolete.
146766 2006-06-28  Bruno Haible  <bruno@clisp.org>
146768         * modules/wcwidth (Files): Add m4/wchar_t.m4.
146770 2006-06-28  Bruno Haible  <bruno@clisp.org>
146772         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
146773         gt_TYPE_WCHAR_T.
146775 2006-06-28  Bruno Haible  <bruno@clisp.org>
146777         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
146778         declaration for wcwidth.
146779         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctype.h>.
146781 2006-06-28  Bruno Haible  <bruno@clisp.org>
146783         * lib/mkdtemp.c [MINGW]: Include <io.h>.
146784         (mkdir): Define using _mkdir.
146786 2006-06-28  Bruno Haible  <bruno@clisp.org>
146788         * lib/getaddrinfo.h: Fix POSIX URL.
146789         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
146790         _WIN32.
146791         (use_win32_p): Make static.
146792         (getaddrinfo): Reject service name if it is empty or does not consist
146793         solely of decimal digits, or if its value is > 65535.
146794         (getnameinfo): Remove useless casts.
146796 2006-06-27  Simon Josefsson  <jas@extundo.com>
146798         * modules/sys_select: New file, suggested by Bruno Haible, Paul
146799         Eggert and Martin Lambers.
146801 2006-06-27  Simon Josefsson  <jas@extundo.com>
146803         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
146804         Eggert and Martin Lambers.
146806 2006-06-27  Bruno Haible  <bruno@clisp.org>
146808         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
146809         result to 0, not to empty.
146810         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
146812 2006-06-27  Bruno Haible  <bruno@clisp.org>
146814         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
146816 2006-06-26  Simon Josefsson  <jas@extundo.com>
146818         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
146819         present.
146821 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
146823         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
146824         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
146825         <http://lists.gnu.org/r/bug-gnulib/2006-06/msg00181.html>.
146827 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
146829         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
146831 2006-06-26  Bruno Haible  <bruno@clisp.org>
146833         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
146835 2006-06-26  Bruno Haible  <bruno@clisp.org>
146837         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
146839 2006-06-26  Bruno Haible  <bruno@clisp.org>
146841         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
146842         SGI C compiler in pre-C99 mode.
146843         Suggested by Mark D. Baushke and Larry Jones.
146845 2006-06-26  Bruno Haible  <bruno@clisp.org>
146847         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
146848         WCHAR_MAX.
146849         Reported by Mark D. Baushke and Larry Jones.
146851 2006-06-26  Bruno Haible  <bruno@clisp.org>
146853         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
146854         in pre-C99 mode.
146855         Suggested by Mark D. Baushke and Larry Jones.
146857 2006-06-23  Simon Josefsson  <jas@extundo.com>
146858             Bruno Haible  <bruno@clisp.org>
146860         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
146861         Emit mostlyclean-local rule.
146862         (func_emit_tests_Makefile_am): Likewise.
146863         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
146865 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
146867         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
146869 2006-06-23  Bruno Haible  <bruno@clisp.org>
146871         * tests/test-stdint.c: Update to match ISO C 99 Technical
146872         Corrigendum 1.
146874 2006-06-23  Bruno Haible  <bruno@clisp.org>
146876         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
146878 2006-06-23  Bruno Haible  <bruno@clisp.org>
146880         * lib/stdint_.h: Treat IRIX like OpenBSD.
146882 2006-06-23  Bruno Haible  <bruno@clisp.org>
146884         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
146885         ISO C 99 Technical Corrigendum 1.
146887 2006-06-22  Simon Josefsson  <jas@extundo.com>
146889         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
146890         MinGW.
146892 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
146894         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
146895         needed.  Some compiler complained about some of them.  Problem reported
146896         by Larry Jones in
146897         <http://lists.gnu.org/r/bug-gnulib/2006-06/msg00172.html>.
146899 2006-06-21  Simon Josefsson  <jas@extundo.com>
146901         * tests/test-getaddrinfo.c: New file.
146903         * modules/getaddrinfo-tests: New file.
146905         * MODULES.html.sh: Add inet_pton.
146907         * modules/inet_pton: New file.
146909 2006-06-21  Simon Josefsson  <jas@extundo.com>
146911         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
146912         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
146913         of using the (limited) gnulib implementation on Windows XP.
146915         * m4/inet_pton.m4: New file.
146917 2006-06-21  Simon Josefsson  <jas@extundo.com>
146919         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
146920         variable.
146922         * lib/socket_.h: Don't define WINVER.
146924         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
146925         slightly modified to work in gnulib.
146927 2006-06-21  Simon Josefsson  <jas@extundo.com>
146929         * doc/gnulib.texi (Windows sockets): Add.
146931 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
146933         * lib/read-file.c (fread_file): Start with buffer allocation of
146934         0 bytes rather than 1 byte; this simplifies the code.
146935         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
146936         code to free buffer and save/restore errno.
146937         (internal_read_file): Remove unused local.
146939 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
146941         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
146942         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
146943         Problem reported by Denis Excoffier in
146944         <http://lists.gnu.org/r/bug-tar/2006-06/msg00023.html>.
146946 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
146948         * modules/sys_socket, modules/socklen: Include sys/types since
146949         FreeBSD 4.x's sys/socket.h needs it.
146951 2006-06-19  Simon Josefsson  <jas@extundo.com>
146953         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
146955 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
146957         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
146959 2006-06-19  Bruno Haible  <bruno@clisp.org>
146961         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
146962         and FULL_PATH_INTTYPES_H in angle brackets.
146963         Reported by Mark D. Baushke <mdb@gnu.org>.
146965 2006-06-17  Eric Blake  <ebb9@byu.net>
146967         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
146968         errno.
146970 2006-06-17  Bruno Haible  <bruno@clisp.org>
146972         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
146973         <sys/inttypes.h>.
146975 2006-06-17  Bruno Haible  <bruno@clisp.org>
146977         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
146978         whether errno is declared. Assume <errno.h> declares errno.
146980 2006-06-17  Bruno Haible  <bruno@clisp.org>
146982         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
146984 2006-06-17  Bruno Haible  <bruno@clisp.org>
146986         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
146987         problem on Solaris 2.5.1.
146989 2006-06-16  Eric Blake  <ebb9@byu.net>
146991         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
146992         * lib/unicodeio.c [!defined errno]: Likewise.
146993         * lib/strtol.c [!defined errno]: Likewise.
146994         * lib/strtod.c [!defined errno]: Likewise.
146996 2006-06-15  Eric Blake  <ebb9@byu.net>
146998         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
147000 2006-06-15  Eric Blake  <ebb9@byu.net>
147002         * config/srclist.txt (ssize_t.m4): Lose sync.
147004 2006-06-15  Bruno Haible  <bruno@clisp.org>
147006         * modules/stdint (Files): Include m4/full-header-path.m4,
147007         m4/size_max.m4, m4/wchar_t.m4.
147008         (Makefile.am): Many more substitutions.
147009         * modules/stdint-tests: New file.
147010         * tests/test-stdint.c: New file.
147012 2006-06-15  Bruno Haible  <bruno@clisp.org>
147014         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
147015         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
147016         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
147017         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
147018         gl_CHECK_TYPE_SAME): New macros.
147020 2006-06-15  Bruno Haible  <bruno@clisp.org>
147022         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
147024 2006-06-15  Bruno Haible  <bruno@clisp.org>
147026         * lib/stdint_.h: Rewritten to be fully auto-configured.
147027         Fixes bug on HP-UX/IA64.
147029 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
147031         * lib/getdate.y (__attribute__): Don't define if already defined.
147032         Problem reported by Larry Jones.
147033         * lib/utimens.c (__attribute__): Likewise.
147035 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
147037         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
147038         reported by Andreas Schwab.
147040 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
147041             Bruno Haible  <bruno@clisp.org>
147043         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
147044         check for the declaration of strnlen and a run test that exposes the
147045         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
147046         rpl_strndup.
147048 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
147049             Bruno Haible  <bruno@clisp.org>
147051         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
147053 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
147055         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
147056         compile test, for Tru64 4.0D.
147058 2006-05-28  Karl Berry  <karl@gnu.org>
147060         * config/srclist.txt (printf-args.c): lose sync.
147062 2006-05-26  Martin Lambers  <marlam@marlam.de>
147064         * lib/getpass.c: Updates the test for the native W32 API, and adds
147065         missing includes, thus fixing compilation warnings.
147067 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
147069         * lib/exclude.c (exclude_fnmatch): New function.
147070         (excluded_file_name): Call exclude_fnmatch.
147071         * lib/exclude.h (excluded_file_name): New prototype
147073 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
147075         * lib/tempname.c (small_open, large_open): New macros.
147076         (__open, __open64) [!_LIBC]: Remove.
147077         (__gen_tempname): Use small_open and large_open instead of __open
147078         and __open64.  This fixes a portability bug on HP-UX 11.11i
147079         reported by Simon Wing-Tang in
147080         <http://lists.gnu.org/r/bug-coreutils/2006-05/msg00114.html>.
147082 2006-05-24  Bruno Haible  <bruno@clisp.org>
147084         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
147085         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
147086         Reported by Thorsten Maerz <torte@netztorte.de> via
147087         Aaron Stone <aaron@serendipity.cx>.
147089 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
147091         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
147092         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
147093         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
147094         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
147095         not really conditional on the cache.
147096         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
147098 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
147100         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
147101         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
147102         (my_usleep): Don't mishandle maximum value.
147104 2006-05-19  Jim Meyering  <jim@meyering.net>
147106         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
147108 2006-05-17  Bruno Haible  <bruno@clisp.org>
147110         Cygwin portability.
147111         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
147113 2006-05-17  Bruno Haible  <bruno@clisp.org>
147115         * lib/stdint_.h: Fix recognition of Cygwin.
147117 2006-05-15  Bruno Haible  <bruno@clisp.org>
147119         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
147120         on libtool patch by Ralf Wildenhues.
147122 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
147124         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
147125         test for C99 conformance; (bool) 0.5 is an integer constant
147126         expression, but (bool) -0.5 is not.  Problem reported by Fedor
147127         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
147129 2006-05-11  Simon Josefsson  <jas@extundo.com>
147131         * m4/xvasprintf.m4: Fix obvious typo.
147133 2006-05-11  Jim Meyering  <jim@meyering.net>
147135         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
147136         James Lemley.
147138 2006-05-10  Simon Josefsson  <jas@extundo.com>
147140         * lib/md4.c: Typo fix, update copyright years.
147141         (K1, K2): Don't use L because it turn computations into 64-bit on
147142         64-bit platforms.
147144 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
147146         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
147147         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
147148         unwanted sign propagation, e.g., on hosts with 64-bit int.
147149         There still are some problems with reeelly weird theoretical hosts
147150         (e.g., 33-bit int) but it's not worth worrying about now.
147151         * lib/sha1.c (rol): Likewise.
147152         (K1, K2, K3, K4): Remove unnecessary L suffix.
147154 2006-05-10  Bruno Haible  <bruno@clisp.org>
147156         * lib/des.c: Cast to avoid warnings.
147158 2006-05-09  Bruno Haible  <bruno@clisp.org>
147160         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
147161         (Depends-on): Depend also on xsize, stdarg.
147162         (configure.ac): Add gl_XVASPRINTF.
147164 2006-05-09  Bruno Haible  <bruno@clisp.org>
147166         * m4/xvasprintf.m4: New file.
147168 2006-05-09  Bruno Haible  <bruno@clisp.org>
147170         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
147171         (EOVERFLOW): Define fallback value.
147172         (xstrcat): New function.
147173         (xvasprintf): Recognize the special case of a string concatenation.
147175 2006-05-08  Eric Blake  <ebb9@byu.net>
147177         * gnulib-tool (func_version): Base copyright year on CVS date.
147178         (func_emit_copyright_notice): New function.
147179         (func_emit_lib_Makefile_am): Use it.
147180         (func_emit_tests_Makefile_am): Likewise.
147181         (func_import): Likewise.
147183 2006-05-08  Bruno Haible  <bruno@clisp.org>
147185         * modules/stdarg: New file.
147186         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
147188 2006-05-08  Bruno Haible  <bruno@clisp.org>
147190         * m4/stdarg.m4: New file, from GNU gettext.
147192 2006-05-08  Bruno Haible  <bruno@clisp.org>
147194         * config/srclist.txt (build-aux/config.rpath): different from latest
147195         release.
147197 2006-05-08  Bruno Haible  <bruno@clisp.org>
147199         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
147201 2006-05-05  Jim Meyering  <jim@meyering.net>
147203         * m4/warning.m4: New file, derived from bison's file by the same name.
147205 2006-05-03  Bruno Haible  <bruno@clisp.org>
147207         * lib/stdint_.h: Shorter URL.
147208         * lib/inttypes.h: Likewise.
147210 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
147212         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
147214 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
147216         * lib/verify.h: Document the internals better.  Most of this change
147217         was written by Bruno Haible.
147219 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
147221         * doc/verify.texi: New file, partly based on a proposal by
147222         Bruno Haible.
147224 2006-05-02  Bruno Haible  <bruno@clisp.org>
147226         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
147227         test from here...
147228         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
147230 2006-04-29  Bruno Haible  <bruno@clisp.org>
147232         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
147233         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
147235 2006-04-29  Bruno Haible  <bruno@clisp.org>
147237         * gnulib-tool: Make --update option actually work.
147239 2006-04-29  Bruno Haible  <bruno@clisp.org>
147241         * doc/gcd.texi: New file.
147242         * doc/gnulib.texi: Include it.
147244 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
147246         * lib/getdate.y (get_date): When adding relative date, start with the
147247         initial time, not with the result of the first mktime call.
147249 2006-04-25  Bruno Haible  <bruno@clisp.org>
147251         * gnulib-tool (func_import): Output the include directives in three
147252         blocks, sorted separately.
147253         Reported by Ben Pfaff <blp@cs.stanford.edu>.
147255 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
147257         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
147258         to define main with arguments, for C++.  Reported by Eric Blake.
147259         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
147260         Prefer 'int main ()' to 'int main (void)', for C++.
147261         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
147262         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
147263         for 'main', for C99 and C++.
147265 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
147267         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
147268         Don't assume that exit status -1 is valid.
147269         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
147270         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
147271         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
147272         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
147273         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
147274         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
147275         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
147276         functions can be used without declaring them, or that you can
147277         exit with status -1.
147278         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
147280 2006-04-24  Karl Berry  <karl@gnu.org>
147282         * config/srclist.txt (longdouble.m4): sync lost.
147284 2006-04-24  Eric Blake  <ebb9@byu.net>
147286         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
147288 2006-04-24  Bruno Haible  <bruno@clisp.org>
147290         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
147291         poll() implementation in AIX.
147292         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
147294 2006-04-24  Bruno Haible  <bruno@clisp.org>
147296         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
147297         assigned exactly once.
147299 2006-04-23  Claudio Fontana  <claudio@gnu.org>
147300             Bruno Haible  <bruno@clisp.org>
147302         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
147303         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
147304         for AM_CPPFLAGS.
147306 2006-04-23  Bruno Haible  <bruno@clisp.org>
147308         * modules/copy-file: Depend on unistd.
147309         * modules/execute: Likewise.
147310         * modules/fatal-signal: Likewise.
147311         * modules/findprog: Likewise.
147312         * modules/mkdtemp : Likewise.
147313         * modules/pipe: Likewise.
147314         * modules/wait-process: Likewise.
147316 2006-04-23  Bruno Haible  <bruno@clisp.org>
147318         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
147319         condition was already detected.
147320         Reported by Ben Pfaff <blp@cs.stanford.edu>.
147322 2006-04-23  Bruno Haible  <bruno@clisp.org>
147324         * lib/copy-file.c: Include <unistd.h> unconditionally.
147325         * lib/execute.c: Likewise.
147326         * lib/fatal-signal.c: Likewise.
147327         * lib/findprog.c: Likewise.
147328         * lib/mkdtemp.c: Likewise.
147329         * lib/pipe.h: Likewise.
147330         * lib/pipe.c: Likewise.
147331         * lib/wait-process.h: Likewise.
147333 2006-04-23  Bruno Haible  <bruno@clisp.org>
147335         * gnulib-tool (func_usage): Fix --import description. Document
147336         --update.
147337         (func_import): Create temporary file in a temporary directory, if
147338         --dry-run is specified. Silence errors from 'grep' when there are no
147339         m4 files in $m4dir.
147340         (func_create_testdir): Silence errors from 'grep' when there are no
147341         m4 files in $m4dir.
147342         Reported by Karl Berry <karl@freefriends.org>.
147344 2006-04-20  Bruno Haible  <bruno@clisp.org>
147346         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
147347         one argument, so that the code will be portable to Autoconf 2.60.
147348         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
147349         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
147350         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
147352 2006-04-19  Derek Price  <derek@ximbiot.com>
147353             Eric Blake  <ebb9@byu.net>
147355         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
147356         rather than "/full/path.h".  Update comment to match.  Shorten &
147357         generalize m4_translit call via AS_TR_CPP.
147359 2006-04-19  Derek Price  <derek@ximbiot.com>
147360             Eric Blake  <ebb9@byu.net>
147362         * lib/inttypes.h: Correct grammar in comment.
147364 2006-04-18  Derek Price  <derek@ximbiot.com>
147365             Paul Eggert  <eggert@cs.ucla.edu>
147367         * modules/inttypes: New file.
147368         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
147370 2006-04-18  Derek Price  <derek@ximbiot.com>
147371             Paul Eggert  <eggert@cs.ucla.edu>
147373         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
147374         New files.
147376 2006-04-18  Derek Price  <derek@ximbiot.com>
147377             Paul Eggert  <eggert@cs.ucla.edu>
147379         * lib/inttypes.h: New file.
147380         * lib/strtoimax.c: Assume <inttypes.h>.
147382 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
147384         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
147385         isn't mounted.  Problem reported by Kir Kolyshkin.
147387 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
147389         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
147390         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
147391         Derek R. Price.
147392         * lib/regex.h (RE_DUP_MAX): Update comment to match current
147393         implementation.
147395 2006-04-12  Eric Blake  <ebb9@byu.net>
147397         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
147398         is now done automatically by the corresponding Autoconf macro.
147400 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
147402         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
147403         time_r.h.
147405 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
147407         Merge regex changes from libc, removing some of our
147408         POSIX-conformance changes that were rejected and redoing them in a
147409         less-intrusive way.
147411         * lib/regcomp.c (re_compile_internal, init_dfa):
147412         Length arg is now size_t, not Idx.  All uses changed.
147413         (peek_token): Forward decl now says internal_function.
147414         (__re_error_msgid, __re_error_msgid_idx):
147415         Now static rather than extern with attribute_hidden.
147416         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
147417         For some reason libc prefers K&R style defns for external functions.
147418         (regerror) [!defined _LIBC]: Likewise.
147419         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
147420         (seek_collating_symbol_entry, lookup_collation_sequence_value):
147421         (build_range_exp, build_collating_symbol):
147422         Use K&R-style defn.
147423         (re_compile_fastmap): Use '\0' to memset, not 0.
147424         (utf8_sb_map): Make the calculations more obvious.
147425         (init_dfa, parse_bracket_exp, build_charclass_op):
147426         Call calloc and cast result, as glibc does.
147427         (init_word_char, fetch_token, peek_token, peek_token_bracket):
147428         (build_range_exp, build_collating_symbol):
147429         Now internal functions.
147431         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
147433         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
147434         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
147435         Don't depend on VMS; depend on __VMS instead, for POSIX
147436         namespace cleanness.
147437         (regoff_t): Define to ssize_t, not long int.
147439         Remove the REG_ macros named below.  Instead, make the old names
147440         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
147441         __USE_GNU_REGEX.
147442         (REG_BACKSLASH_ESCAPE_IN_LISTS):
147443         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
147444         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
147445         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
147446         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
147447         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
147448         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
147449         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
147450         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
147451         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
147452         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
147453         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
147454         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
147455         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
147456         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
147457         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
147458         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
147459         (REG_NREGS):
147460         Remove.  All uses replaced by the old RE_* names.
147461         (RE_BACKSLASH_ESCAPE_IN_LISTS):
147462         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
147463         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
147464         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
147465         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
147466         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
147467         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
147468         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
147469         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
147470         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
147471         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
147472         Don't bother having these macros be independent of each others'
147473         values, since they no longer exist in the POSIX name space.
147475         Rename the following member names back to their old names,
147476         unless !__USE_GNU_REGEX.  All uses changed back.
147477         (buffer): Renamed from re_buffer.
147478         (allocated): Renamed from re_allocated.
147479         (used): Renamed from re_used.
147480         (syntax): Renamed from re_syntax.
147481         (fastmap): Renamed from re_fastmap.
147482         (translate): Renamed from re_translate.
147483         (can_be_null): Renamed from re_can_be_null.
147484         (regs_allocated): Renamed from re_regs_allocated.
147485         (fastmap_accurate): Renamed from re_fastmap_accurate.
147486         (no_sub): Renamed from re_no_sub.
147487         (not_bol): Renamed from re_not_bol.
147488         (not_eol): Renamed from re_not_eol.
147489         (newline_anchor): Renamed from re_newline_anchor.
147490         (num_regs): Renamed from rm_num_regs.
147491         (start): Renamed from rm_start.
147492         (end): Renamed from rm_end.
147494         (free_state): Move up a bit.
147496         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
147497         #define to be empty.
147498         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
147499         when that is what is intended.
147500         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
147501         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
147502         (MAX): New macro.
147503         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
147504         All uses changed back to re_malloc, etc.  It's now the caller's
147505         responsibility to check for overflow; all callers changed.
147506         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
147507         (re_x2nrealloc): Remove.
147508         (free_state): Remove decl.
147510         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
147511         (re_set_registers, re_exec):
147512         Use K&R-style defn.
147514         2006-01-31  Roland McGrath  <roland@redhat.com>
147516         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
147517         Reported by Mike Frysinger <vapier@gentoo.org>.
147519         2006-01-15  Andreas Jaeger  <aj@suse.de>
147521         [BZ #1950]
147522         * lib/regex_internal.c (re_string_reconstruct): Adjust for
147523         build_wcs_upper_buffer change.
147524         (build_wcs_upper_buffer): Change return type.
147526         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
147528         * lib/regex_internal.h: Include <stdint.h> if available.
147530         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
147532         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
147534         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
147536         * lib/regcomp.c: Adjust for changed secondary hash function.
147538         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
147540         * lib/regex.h: Pretty printing.
147541         Clean up namespace a bit.
147543         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
147545         * lib/regexec.c (update_cur_sifted_state, check_arrival,
147546         check_arrival_add_next_nodes): Avoid using uninitialized variable.
147548         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
147549                     Ulrich Drepper  <drepper@redhat.com>
147551         [BZ #1302]
147552         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
147553         changed.
147554         (bitset_word_t): Renamed from bitset_word.  All uses changed.
147556         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
147558         [BZ #281]
147559         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
147560         * lib/regcomp.c: Remove unnecessary uses of
147561         unsigned RE_TRANSLATE_TYPE.
147562         * lib/regex_internal.h: Likewise.
147563         * lib/regex_internal.c: Likewise.
147564         * lib/regexec.c: Likewise.
147565         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
147567         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
147569         * lib/regexec.c (find_recover_state): Remove unnecessary
147570         initialization.
147571         (transit_state_bkref): Make DFA a const pointer.
147572         (get_subexp): Likewise.
147573         (check_arrival): Likewise.
147574         (update_cur_sifted_state): Likewise.
147575         (re_search_internal): Likewise.
147576         (prune_impossible_nodes): Likewise.
147577         (acquire_init_state_context): Likewise.
147578         (proceed_next_node): Likewise.
147579         (set_regs): Likewise.
147580         (free_fail_stack_return): Likewise.
147581         (check_arrival_expand_ecl): Mark DFA parameter as const.
147582         (check_arrival_expand_ecl_sub): Likewise.
147583         (check_subexp_limits): Likewise.
147584         (sub_epsilon_src_nodes):  Likewise.
147585         (add_epsilon_src_nodes):  Likewise.
147586         (merge_state_array): Likewise.
147587         (update_regs): Likewise.
147588         (build_trtable): Likewise.
147589         (sift_states_backward): Mark MCTX parameter as const.
147590         (build_sifted_states): Likewise.
147591         (update_cur_sifted_state): Likewise.
147592         (sift_states_mkref): Likewise.
147593         (check_arrival_expand_ecl): Mark eclosure as const.
147594         (check_dst_limits_calc_pos_1): Likewise.
147595         * lib/regex_internal.h (re_match_context_t): Make dfa a const
147596         pointer.
147598         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
147600         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
147601         (transit_state_sb): Likewise.
147602         (transit_state_mb): Likewise.
147603         (sift_states_iter_mb): Likewise.
147604         (check_arrival_add_next_nodes): Likewise.
147605         (check_node_accept_bytes): Change first parameter to pointer-to-const.
147606         [_LIBC] (re_search_2_stub): Use mempcpy.
147608         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
147609         mbrtowc for very simple UTF-8 case.
147611         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
147612         a pointer-to-const.
147613         (re_acquire_state_context): Likewise.
147614         * lib/regex_internal.h: Adjust prototypes.
147616         * lib/regex.c: Prevent using C++ compilers.
147618         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
147619         (re_acquire_state_context): Likewise.
147621 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
147623         * modules/regex (Depends-on): Add ssize_t.
147625 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
147627         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
147628         translation table.
147630 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
147632         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
147634 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
147635             Bruno Haible  <bruno@clisp.org>
147637         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
147638         <sys/types.h> and <inttypes.h>.
147640 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
147642         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
147643         `__error_t_defined', so argp.h will not typedef the former.
147645 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
147647         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
147648         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
147649         glibc names.  Even if glibc is changed to conform to POSIX, the
147650         traditional names will be available anyway, since regex depends on
147651         the extensions module.  Also, fix a longstanding typo in the
147652         implementation of Spencer ERE test #75 from grep 2.3.  Problems
147653         reported by Emanuele Giaquinta.  Also, change sense of cached
147654         variable, so that the message makes sense.
147656 2006-03-24  Simon Josefsson  <jas@extundo.com>
147658         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
147659         including some doc fixes.
147660         (base64_encode_alloc): Fix +1 bug on allocation failures.
147662 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
147664         * lib/base64.c (base64_encode): Do not read past end of array with
147665         unsanitized input on systems with CHAR_BIT > 8.
147667 2006-03-24  Eric Blake  <ebb9@byu.net>
147669         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
147671 2006-03-22  Karl Berry  <karl@gnu.org>
147673         * config/srclist.txt (*setenv.[ch]): get from coreutils.
147674         * config/srclistvars.sh (COREUTILS): new var.
147676 2006-03-17  Jim Meyering  <jim@meyering.net>
147678         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
147679         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
147681 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
147683         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
147684         no longer needs it.  Instead, check that regoff_t is as least
147685         as wide as ptrdiff_t.
147687         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
147688         so that our regex.h stays compatible with the installed regex.
147689         This is helpful for installers who configure --without-included-regex.
147690         Problem reported by Emanuele Giaquinta.
147692 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
147694         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
147695         Typedef to long int, not to off_, as POSIX will likely change
147696         in that direction.
147698 2006-03-15  Eric Blake  <ebb9@byu.net>
147700         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
147702 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
147704         * lib/argp-help.c (validate_uparams): Fix typo
147705         * lib/argp-parse.c (argp_default_options): Consistently begin help
147706         messages with a lowercase letter.
147708 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
147710         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
147711         overrun buffers and shouldn't be used (much as gets shouldn't be
147712         used).
147713         * lib/time_r.c (asctime_r, ctime_r): Likewise.
147715 2006-03-08  Simon Josefsson  <jas@extundo.com>
147717         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
147718         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
147720 2006-03-08  Simon Josefsson  <jas@extundo.com>
147722         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
147723         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
147725 2006-03-08  Simon Josefsson  <jas@extundo.com>
147727         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
147728         signal that configure disabled the device.
147730 2006-03-08  Simon Josefsson  <jas@extundo.com>
147732         * build-aux/maint.mk: Fix refresh-po, to handle no translated
147733         languages.
147735 2006-03-07  Simon Josefsson  <jas@extundo.com>
147737         * modules/getopt (Depends-on): Add unistd.
147739         * modules/unistd: New file.
147741 2006-03-07  Simon Josefsson  <jas@extundo.com>
147743         * modules/gc-random: New file.
147745 2006-03-07  Simon Josefsson  <jas@extundo.com>
147747         * m4/unistd_h.m4: New file.
147749 2006-03-07  Simon Josefsson  <jas@extundo.com>
147751         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
147752         test to be side-effect free by storing the result in the cache
147753         variable gl_cv_lib_readline, and moving the assignment of
147754         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
147755         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
147757 2006-03-07  Simon Josefsson  <jas@extundo.com>
147759         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
147760         error on missing devices (the functions will return an error).
147762         * m4/gc.m4: Move random stuff to gc-random.m4
147764 2006-03-07  Simon Josefsson  <jas@extundo.com>
147766         * lib/unistd_.h: New file.
147768 2006-03-07  Simon Josefsson  <jas@extundo.com>
147770         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
147772 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
147774         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
147775         Problem reported by Juan Manuel Guerrero.
147777 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
147779         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
147780         the unistd module.
147781         * lib/getlogin_r.c: Likewise.
147782         * lib/getlogin_r.h: Likewise.
147783         * lib/glob.c: Likewise.
147784         * lib/pagealign_alloc.c: Likewise.
147785         * lib/unistd_.h: Remove; no longer needed.
147787 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
147789         * MODULES.html.sh (Support for systems lacking POSIX:2001):
147790         Add unistd.
147791         * modules/c-stack (Depends-on): Add unistd.
147792         * modules/getlogin_r: Likewise.
147793         * modules/glob: Likewise.
147794         * modules/pagealign_alloc: Likewise.
147795         * modules/unistd (Files): Remove lib/unistd_.h.
147796         (EXTRA_DIST): Remove.
147797         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
147798         need unistd_.h.
147799         (MOSTLYCLEANFILES): Remove unistd.h-t.
147801 2006-03-03  Simon Josefsson  <jas@extundo.com>
147803         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
147805 2006-03-03  Simon Josefsson  <jas@extundo.com>
147807         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
147808         libidn and bison.
147810 2006-03-03  Simon Josefsson  <jas@extundo.com>
147812         * build-aux/maint.mk: Add indent target.
147814 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
147816         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
147817         our replacement poll.h in any case, to avoid a differing
147818         declaration from a system header.  Seen on AIX.
147820 2006-03-01  Simon Josefsson  <jas@extundo.com>
147822         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
147823         <kasal@ucw.cz>.
147825 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
147827         * modules/gettime (Depends-on): Add extensions module.
147828         * modules/nanosleep (Depends-on): Likewise.
147829         * modules/settime (Depends-on): Likewise.
147831 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
147833         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
147834         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
147835         pedantically.
147836         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
147837         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
147839         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
147840         not "==".  Reported by Ralf Wildenhues.
147842 2006-03-01  Karl Berry  <karl@gnu.org>
147844         * doc/Copyright/request-*: new files, synced from gnuorg.
147846 2006-03-01  Karl Berry  <karl@gnu.org>
147848         * config/srclist.txt (Copyright/*): new entries.
147850 2006-02-28  Simon Josefsson  <jas@extundo.com>
147852         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
147854 2006-02-27  Simon Josefsson  <jas@extundo.com>
147856         * lib/base64.h: Indent #define's.  From Jim Meyering
147857         <jim@meyering.net>.
147859 2006-02-27  Jim Meyering  <jim@meyering.net>
147861         Revert the change of 2006-02-24, so these files can continue
147862         to be sync'd from gettext.
147863         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
147864         of `config.h'.
147866 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
147868         * modules/intprops: New file.
147869         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
147870         Add intprops.
147871         * modules/getloadavg (Files): Remove lib/intprops.h.
147872         (Depends-on): Add intprops.
147873         * modules/human: Likewise.
147874         * modules/inttostr: Likewise.
147875         * modules/openat: Likewise.
147876         * modules/sig2str: Likewise.
147877         * modules/userspec: Likewise.
147878         * modules/utimecmp: Likewise.
147879         * modules/xnanosleep: Likewise.
147880         * modules/xstrtol: Likewise.
147882 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
147884         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
147885         * modules/lock-tests (TESTS): Use $(EXEEXT).
147886         * modules/tls-tests: Likewise.
147887         * modules/argp-tests: Likewise.
147888         (check_PROGRAMS): New var, replacing...
147889         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
147891 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
147893         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
147894         `config.h'.
147896 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
147898         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
147900 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
147902         Sync from coreutils.
147903         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
147904         gl_CHDIR_SAFER.
147906 2006-02-22  Jim Meyering  <jim@meyering.net>
147908         Sync from coreutils.
147909         * m4/chdir-safer.m4: New file.
147911 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
147913         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
147914         AT_FDCWD exceeds INT_MAX.
147915         * lib/openat.h (AT_FDCWD): Likewise.
147917 2006-02-17  Eric Blake  <address@hidden>
147919         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
147921 2006-02-16  Simon Josefsson  <jas@extundo.com>
147923         * modules/getaddrinfo (Depends-on): Add sys_socket.
147925 2006-02-15  Simon Josefsson  <jas@extundo.com>
147927         * build-aux/maint.mk: Add dsyntax-check rule.
147929 2006-02-15  Eric Blake  <ebb9@byu.net>
147931         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
147932         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
147933         'present but cannot compile' warnings on cygwin.
147934         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
147935         use ws2tcpip.h if sys/socket.h works.
147936         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
147937         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
147939 2006-02-14  Simon Josefsson  <jas@extundo.com>
147941         * modules/maintainer-makefile (Files): Rename.
147943         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
147944         and (the local) Makefile.cfg to maint-cfg.mk.
147946         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
147947         to the latter.
147949         * modules/maintainer-makefile: New module.
147951         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
147952         severaly stripped to make it possible to build it up from scratch
147953         with reliable tests.
147955         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
147956         fixes to permit overriding the default actions when configure and
147957         makefile are not available.
147959 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
147961         Sync from coreutils.
147962         * modules/lstat (Depends-on): Don't depend on xalloc.
147963         (License): Change from GPL to LGPL, since this is now simply a
147964         replacement for a libc function.
147966 2006-02-14  Jim Meyering  <jim@meyering.net>
147968         Sync from coreutils.
147970         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
147971         failure on deficient systems, and simplify gnulib lgpl dependencies.
147972         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
147973         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
147975         * lib/xalloc-die.c: Remove unused definition of N_.
147977 2006-02-14  Jim Meyering  <jim@meyering.net>
147979         Sync from coreutils.
147980         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
147981         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
147982         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
147983         double-quote uses of that variable, to accommodate the rare case in
147984         which getmntent is available in none of the libraries checked.  This
147985         happens at least on FreeBSD 5.0.
147987 2006-02-13  Simon Josefsson  <jas@extundo.com>
147989         * gnulib-tool (Usage): Fix --import, from
147990         karl@freefriends.org (Karl Berry).
147992 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
147994         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
147996 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
147998         * lib/argp-namefrob.h: Restore changes accidentally lost during the
147999         "autoupdate" on 2005-12-12.
148001 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
148003         * modules/closeout (Depends-on): Remove atexit.
148005 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
148007         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
148008         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
148010 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
148012         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
148013         __EXTENSIONS__ if this causes compilation to fail.  Problem
148014         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
148015         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
148017 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
148019         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
148020         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
148021         <http://lists.gnu.org/r/bug-gnulib/2006-01/msg00074.html>.
148022         All uses changed.
148024 2006-01-26  Simon Josefsson  <jas@extundo.com>
148026         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
148027         prototype is visible on mingw32.
148029         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
148030         for mingw32.
148032         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
148033         mingw32).
148035 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
148037         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
148038         attempt to open for write; this always fails, at least on POSIX
148039         hosts.  This reinstates the 2006-01-09 change, which was
148040         inadvertently removed.
148042 2006-01-26  Bruno Haible  <bruno@clisp.org>
148044         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
148045         Reported by Paul Eggert.
148047 2006-01-26  Bruno Haible  <bruno@clisp.org>
148048             Paul Eggert  <eggert@cs.ucla.edu>
148050         * lib/stdbool_.h (_Bool)
148051         [(! (defined __cplusplus || defined __BEOS__)
148052           && !defined __GNUC__
148053           && !(defined __HP_cc || defined __xlc__
148054                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
148055                || defined __sgi))]:
148056         #define to signed char in these cases too; this simplifies
148057         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
148058         etc., separately) and makes it more conservative.
148060 2006-01-25  Simon Josefsson  <jas@extundo.com>
148062         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
148063         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
148064         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
148066 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
148068         * lib/argp-namefrob.h: Bugfix. Remove stray #
148070 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
148072         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
148073         so that we test the test.
148074         Check for yet another HP-UX cc bug involving *bool |= bool.
148076 2006-01-25  Karl Berry  <karl@gnu.org>
148078         * config/srclist.txt (vasnprintf.c): sync lost.
148080 2006-01-25  Jim Meyering  <jim@meyering.net>
148082         Sync from the stable (b5) branch of coreutils:
148084         * lib/fts.c (fts_children): Don't let close() clobber errno from
148085         failed fchdir().
148087         * lib/fts.c (fts_stat): When following a symlink-to-directory,
148088         don't necessarily interpret stat-fails+lstat-succeeds as indicating
148089         a dangling symlink.  That can also happen at least for ELOOP.
148090         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
148091         FYI, this bug predates the inclusion of fts.c in coreutils.
148093         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
148094         in their own block, so pre-c99 compilers don't object.
148096         Avoid the double-free (first in fts_read, second in fts_close) that
148097         would occur when an `active' directory is made inaccessible (e.g.,
148098         via chmod a-x) during a traversal.
148099         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
148100         before returning.  Reproduce this failure by
148101         mkdir -p a/b; cd a; chmod a-x . b
148102         Reported by Stavros Passas.
148104 2006-01-25  Jim Meyering  <jim@meyering.net>
148106         * lib/fileblocks.c: Remove more useless parentheses.
148107         * lib/readutmp.h: Likewise.
148109 2006-01-25  Bruno Haible  <bruno@clisp.org>
148111         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
148112         warnings.
148113         Reported by Paul Eggert.
148115 2006-01-25  Bruno Haible  <bruno@clisp.org>
148117         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
148118         rid of a trap command. For Solaris sh.
148119         Reported by Mark D. Baushke <mdb@gnu.org>.
148121 2006-01-24  Simon Josefsson  <jas@extundo.com>
148123         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
148124         Bruno.
148126 2006-01-24  Karl Berry  <karl@gnu.org>
148128         * config/srclist.txt (argp-namefrob.h): sync lost.
148130 2006-01-24  Jim Meyering  <jim@meyering.net>
148132         * modules/openat (Files): Add lib/intprops.h.
148133         From Mark D. Baushke.
148135 2006-01-24  Jim Meyering  <jim@meyering.net>
148137         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
148138         Reported by Mark D. Baushke.
148140 2006-01-24  Jim Meyering  <jim@meyering.net>
148142         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
148144 2006-01-24  Bruno Haible  <bruno@clisp.org>
148146         * modules/strnlen (Maintainer): Change from glibc to all.
148148 2006-01-24  Bruno Haible  <bruno@clisp.org>
148150         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
148151         Patch by Paul Eggert.
148153 2006-01-24  Bruno Haible  <bruno@clisp.org>
148155         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
148156         already has it.
148157         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
148158         2005-11-26.
148160         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
148161         'signed char' to avoid problems with the built-in _Bool type.
148162         Reported by Paul Eggert on 2005-11-26.
148164 2006-01-24  Bruno Haible  <bruno@clisp.org>
148166         * gnulib-tool (func_import): Avoid constructing complicated sed
148167         expressions inside backquote.
148168         Report and solution by Mark D. Baushke <mdb@gnu.org>.
148170 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
148172         These changes imported from libc.
148173         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
148174         test and two separate function calls.
148175         * lib/strndup.c (__strndup): Add libc_hidden_def.
148177 2006-01-23  Simon Josefsson  <jas@extundo.com>
148179         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
148180         Remove the test_*_SOURCES variable: automake infers it by default.
148181         * modules/tls-tests: Likewise.
148183 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
148185         Work around porting bugs reported by Dieter in
148186         <http://lists.gnu.org/r/bug-bison/2006-01/msg00049.html>.
148187         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
148188         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
148189         Include "getopt.h" first, to check interface.
148190         (getenv): Declare only if defined HAVE_DECL_GETENV &&
148191         !HAVE_DECL_GETENV.
148192         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
148193         (__strndup): Revert to K&R-style function dfns, the glibc style.
148194         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
148195         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
148196         Include strnlen.h first, to get prototype properly.
148197         (strnlen): Renamed from __strnlen.
148198         Remove weak alias.
148200 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
148202         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
148204 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
148206         * config/srclist.txt: Adjust to reflect glibc reorganization.
148207         This affects only comments.
148209 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
148211          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
148212          Reported by Bruce Korb <bkorb@gnu.org>.
148214 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
148216         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
148217         to pacify gcc -Wswitch-default.
148219 2006-01-22  Bruno Haible  <bruno@clisp.org>
148221         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
148222         temporary buffer for sprintf, take into account the precision also
148223         for 'd', 'i', 'u', 'o', 'x', 'X'.
148225 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
148227         * modules/argp-tests: New module
148228         * tests/test-argp.c: New file
148229         * tests/test-argp-2.sh: New file
148231 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
148233         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
148234         (__argp_base_name): Removed
148235         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
148236         typo.
148237         (__argp_base_name): Provide macro definition or extern declaration
148238         depending on the configuration
148240 2006-01-20  Simon Josefsson  <jas@extundo.com>
148242         * modules/inet_ntop (Depends-on): Depend on sys_socket.
148244 2006-01-20  Simon Josefsson  <jas@extundo.com>
148246         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
148248 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
148250         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
148251         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
148252         Suggested by Bruno Haible.
148254 2006-01-20  Karl Berry  <karl@gnu.org>
148256         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
148257         until changes propagate, I guess.
148259 2006-01-19  Simon Josefsson  <jas@extundo.com>
148261         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
148263 2006-01-19  Simon Josefsson  <jas@extundo.com>
148265         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
148267 2006-01-19  Simon Josefsson  <jas@extundo.com>
148269         * gnulib-tool: Set check_PROGRAMS.
148271         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
148272         modules/des-tests, modules/gc-arcfour-tests,
148273         modules/gc-arctwo-tests, modules/gc-des-tests,
148274         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
148275         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
148276         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
148277         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
148278         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
148279         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
148280         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
148281         test_*_SOURCES.
148283 2006-01-18  Simon Josefsson  <jas@extundo.com>
148285         * modules/socklen (Depends-on): Depend on sys_socket.
148287 2006-01-18  Simon Josefsson  <jas@extundo.com>
148289         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
148290         modules/des-tests, modules/gc-arcfour-tests,
148291         modules/gc-arctwo-tests, modules/gc-des-tests,
148292         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
148293         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
148294         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
148295         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
148296         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
148297         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
148298         $(EXEEXT) to automake TESTS variable, for mingw32.
148300 2006-01-17  Simon Josefsson  <jas@extundo.com>
148302         * modules/socklen (Include): Need sys/socket.h.
148304 2006-01-17  Bruno Haible  <bruno@clisp.org>
148306         * modules/ssize_t (Include): Add <sys/types.h>.
148308 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
148310         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
148311         it's not portable and it doesn't work with cross-compiles.
148312         Problem reported by Bruno Haible.  Fix missing-$ typo in
148313         'test "gl_cv_ignore_unused_libraries" ...' that prevented
148314         -zignore from being used with Sun's C compiler.
148316 2006-01-12  Simon Josefsson  <jas@extundo.com>
148318         * lib/base64.c: Fix warning, reported by Bruno Haible
148319         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
148321 2006-01-12  Bruno Haible  <bruno@clisp.org>
148323         * modules/ldd: New file.
148324         * build-aux/ldd.sh.in: New file.
148325         * MODULES.html.sh (Support for building libraries and executables): Add
148326         ldd.
148328 2006-01-12  Bruno Haible  <bruno@clisp.org>
148330         * m4/ldd.m4: New file.
148332 2006-01-12  Bruno Haible  <bruno@clisp.org>
148334         * gnulib-tool (func_import, func_create_testdir): Don't go into an
148335         endless loop while replacing $auxdir with build-aux.
148337 2006-01-11  Simon Josefsson  <jas@extundo.com>
148339         * lib/stdint_.h (SIZE_MAX): Add missing (.
148341 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
148343         Sync from coreutils.
148344         * lib/md5.c: Fix commentary typos.
148345         (alignof, UNALIGNED_P): No need for a GCC-specific version.
148346         * lib/md5.h (__attribute__): Remove; unused.
148347         * lib/sha1.c: Fix commentary to match md5 better.
148348         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
148349         so that we don't need to worry about alignment.  All uses changed.
148350         This merges the 2005-10-28 md5 change into sha1.
148352 2006-01-11  Jim Meyering  <jim@meyering.net>
148354         Sync from coreutils.
148355         * lib/md5.c (OP): Fix spacing.
148357 2006-01-11  Bruno Haible  <bruno@clisp.org>
148359         Ensure automatic ordering between gl_LOCK and gl_ARGP.
148360         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
148361         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
148363 2006-01-11  Bruno Haible  <bruno@clisp.org>
148365         Ensure automatic ordering between gl_LOCK and gl_ARGP.
148366         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
148367         the "early" section as well.
148369 2006-01-11  Bruno Haible  <bruno@clisp.org>
148371         Avoid "ar: no archive members specified" error on MacOS X.
148372         * gnulib-tool (func_modules_add_dummy): New function.
148373         (func_import, func_create_testdir): Invoke it.
148375 2006-01-11  Bruno Haible  <bruno@clisp.org>
148377         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
148378         with $auxdir in AC_CONFIG_FILES statements.
148380 2006-01-11  Bruno Haible  <bruno@clisp.org>
148382         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
148383         Initialize also noinst_HEADERS to empty.
148385 2006-01-11  Bruno Haible  <bruno@clisp.org>
148387         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
148388         variables.
148389         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
148390         autoreconf.
148392 2006-01-11  Bruno Haible  <bruno@clisp.org>
148394         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
148395         overridable by the user.
148396         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
148398 2006-01-10  Simon Josefsson  <jas@extundo.com>
148400         * modules/sys_socket: New file.
148402 2006-01-10  Simon Josefsson  <jas@extundo.com>
148404         * m4/sys_socket_h.m4: New file.
148406 2006-01-10  Simon Josefsson  <jas@extundo.com>
148408         * lib/socket_.h: New file.
148410 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
148412         * modules/readutmp (Maintainer): Add myself.
148414 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
148416         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
148417         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
148418         People who are still concerned with buggy memcmp implementations
148419         can invoke gl_FUNC_MEMCMP themselves.
148421 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
148423         * lib/regex_internal.h (BITSET_WORD_BITS):
148424         Work around a bug in 64-bit PGC (before version 6.1-2), where the
148425         preprocessor mishandles large unsigned values as if they were signed.
148426         Problem reported by Claudio Fontana in
148427         <http://lists.gnu.org/r/bug-gnulib/2005-12/msg00061.html>.
148429 2006-01-10  Jim Meyering  <jim@meyering.net>
148431         Avoid the double-free (first in fts_read, second in fts_close) that
148432         would occur when an `active' directory is made inaccessible (e.g.,
148433         via chmod a-x) during a traversal.
148434         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
148435         before returning.  Reproduce this failure by
148436         mkdir -p a/b; cd a; chmod a-x . b
148437         Reported by Stavros Passas.
148439         Sync from coreutils.
148440         * lib/sha1.c: Tweak grammar in a comment.
148442 2006-01-10  Jim Meyering  <jim@meyering.net>
148444         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
148445         Patch by Joerg Sonnenberger.
148447 2006-01-10  Bruno Haible  <bruno@clisp.org>
148449         * modules/readutmp: Depend on module free.
148450         * modules/strtok_r: Depend on module restrict.
148452 2006-01-10  Bruno Haible  <bruno@clisp.org>
148454         * modules/gettext (configure.ac): Add an invocation of
148455         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
148457 2006-01-10  Bruno Haible  <bruno@clisp.org>
148459         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
148460         Reported by Werner Lemberg <wl@gnu.org>.
148462 2006-01-10  Bruno Haible  <bruno@clisp.org>
148464         * lib/localcharset.c: Update from GNU gettext.
148466 2006-01-10  Bruno Haible  <bruno@clisp.org>
148468         * lib/argp.h (__const): Remove macro. Use const instead.
148469         * lib/argp-fmtstream.h (__const): Likewise.
148470         * lib/glob_.h (__const): Remove macro.
148471         * lib/glob-libc.h: Use const instead of __const.
148473 2006-01-10  Bruno Haible  <bruno@clisp.org>
148475         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
148476         variable.
148477         Needed to avoid an automake error regarding the 'gettext' module.
148479 2006-01-09  Simon Josefsson  <jas@extundo.com>
148481         * modules/inet_ntop (Depends-on): Add restrict.
148483 2006-01-09  Simon Josefsson  <jas@extundo.com>
148485         * modules/gc-rijndael-tests (License): Put under LGPL.
148487         * modules/gc-des-tests (License): Likewise.
148489         * modules/gc-arcfour-tests (License): Likewise.
148491         * modules/gc-arctwo-tests (License): Likewise.
148493         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
148495         * modules/gc-hmac-sha1-tests (Files): Likewise.
148497         * modules/gc-hmac-md5-tests (License): Likewise.
148499         * modules/gc-sha1-tests (License): Likewise.
148501         * modules/gc-md5-tests (License): Likewise.
148503         * modules/gc-md4-tests (License): Likewise.
148505         * modules/gc-md2-tests (License): Likewise.
148507         * modules/gc-tests (License): Likewise.
148509         * modules/des-tests (License): Likewise.
148511         * modules/md4-tests (License): Likewise.
148513         * modules/md2-tests (License): Likewise.
148515 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
148517         Sync from coreutils:
148519         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
148520         * modules/lib-ignore: New file.
148521         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
148522         chdir-safer.m4, lchmod.m4.
148523         * modules/openat: Add mkdirat.c, openat-priv.h.
148525 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
148527         Sync from coreutils.
148528         * m4/lib-ignore.m4: New file.
148529         * m4/lchmod.m4: New file.
148531 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
148533         Sync from coreutils.
148534         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
148535         for write access: POSIX says that must fail.
148536         * lib/fts.c (diropen): Likewise.
148537         * lib/save-cwd.c (save_cwd): Likewise.
148538         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
148539         well, for minor improvements on hosts that lack O_DIRECTORY.
148540         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
148541         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
148542         Fall back on chown if open failed with EACCES.
148544         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
148545         Report an error at compile-time if only a 1-second nominal clock
148546         resolution is found.
148548         * lib/lchmod.h: New file.
148549         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
148550         (make_dir_parents): Use lchown rather than chown, and
148551         lchmod rather than chmod.
148553         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
148554         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
148555         "proc" reported by n0dalus.
148557         * lib/mountlist.c: Include <limits.h>.
148558         (dev_from_mount_options)
148559         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
148560         New function.  It no longer assumes "dev=" has the System V meaning
148561         on Linux (since it doesn't).  It also parses "dev=" more carefully.
148562         (read_file_system_list)
148563         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
148564         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
148565         dev= in that case.
148567         * lib/posixtm.h (PDS_PRE_2000): New macro.
148568         * lib/posixtm.c (year): Arg is now syntax_bits rather than
148569         allow_century.  All usages changed.  Reject dates outside the range
148570         1969-1999 if PDS_PRE_2000 is used.
148572 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
148574         Sync from coreutils.
148575         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
148576         (Time of day items): Mention the possibility of leap seconds.
148577         Problem reported by Dr. David Alan Gilbert.
148579 2006-01-09  Jim Meyering  <jim@meyering.net>
148581         Sync from coreutils.
148583         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
148585         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
148587         * lib/modechange.c (mode_compile): Reject an invalid mode string
148588         that starts with an octal digit.  From Andreas Gruenbacher.
148590         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
148591         and dup to open_safer and dup_safer, respectively.
148592         (openat_permissive): Fix typo in comment.
148594         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
148595         "gettext.h"; either no longer needed or are guaranteed by openat.h.
148596         (_): Remove; no longer needed.
148597         (openat): Renamed from rpl_openat; no need for rpl_openat
148598         since openat.h renames openat for us.
148599         Replace most of the body with a call to openat_permissive,
148600         to avoid duplicate code.
148601         Port to (probably hypothetical) environments were mode_t is
148602         wider than int.
148603         (openat_permissive): Require mode arg, so that we can check
148604         types better.  Put it just after flags.  Change cwd failure
148605         indicator from pointer-to-bool to pointer-to-errno-value.
148606         All callers changed.
148607         Invoke openat_save_fail and/or openat_restore_fail if
148608         cwd_errno is null, so that openat can call us.
148609         (openat_permissive, fdopendir, fstatat, unlinkat):
148610         Simplify errno handling to avoid some duplicate code,
148611         as it's OK to set errno on success.
148612         * lib/openat.h: Revamp code so that function macros depend on
148613         __OPENAT_PREFIX only, not also on AT_FDCWD.
148614         (openat_ro): Remove.  Caller changed to use openat_permissive.
148615         (openat_permissive): Now a macro, if not a function.
148616         (openat_restore_fail, openat_save_fail): Now always functions,
148617         since mkdirat needs them even if __OPENAT_PREFIX is defined.
148619         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
148620         and openat.c.
148621         * lib/mkdirat.c: Include openat-priv.h.
148622         Remove definitions of macros defined therein.
148623         * lib/openat.c: Likewise.
148625         * lib/mkdirat.c (mkdirat): New file and function.
148626         * lib/openat.h (mkdirat): Declare.
148628         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
148630         * lib/openat.h (openat_permissive): Declare.
148631         (openat_ro): Define.
148633         * lib/openat.c (EXPECTED_ERRNO): New macro.
148634         (openat_permissive): New function -- used in remove.c rewrite.
148635         (all functions): Set errno just before returning, only if there
148636         was an actual failure.
148637         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
148639         Emulate openat-family functions using Linux's procfs, if possible.
148640         Idea and some code based on Ulrich Drepper's glibc changes.
148642         * lib/openat.c: (BUILD_PROC_NAME): New macro.
148643         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
148644         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
148645         before falling back on save_cwd and restore_cwd.
148646         (fdopendir, fstatat, unlinkat): Likewise.
148648         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
148649         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
148651         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
148652         as second argument to va_arg.  Otherwise, some versions of gcc
148653         warn that `if this code is reached, the program will abort'.
148655 2006-01-09  Jim Meyering  <jim@meyering.net>
148657         Sync from coreutils.
148658         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
148659         Require openat-priv.h.
148661 2006-01-09  Bruno Haible  <bruno@clisp.org>
148663         * modules/strnlen (Include): Use strnlen.h.
148665 2006-01-09  Bruno Haible  <bruno@clisp.org>
148667         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
148669 2006-01-09  Bruno Haible  <bruno@clisp.org>
148671         * lib/sysexit_.h (EX_OK): New macro.
148672         Suggested by Martin Lambers <marlam@marlam.de>.
148674 2006-01-09  Bruno Haible  <bruno@clisp.org>
148676         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
148677         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
148679 2006-01-09  Bruno Haible  <bruno@clisp.org>
148681         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
148682         numbers.
148684 2006-01-09  Bruno Haible  <bruno@clisp.org>
148686         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
148687         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
148688         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
148689         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
148691 2006-01-09  Bruno Haible  <bruno@clisp.org>
148693         * build-aux/javacomp.sh.in: New file, moved from lib/.
148694         * modules/javacomp-script (Files): Update.
148695         (configure.ac): Add AC_CONFIG_FILES invocation.
148696         (EXTRA_DIST): Remove variable.
148698         * build-aux/javaexec.sh.in: New file, moved from lib/.
148699         * modules/javaexec (Files): Update.
148700         (configure.ac): Add AC_CONFIG_FILES invocation.
148701         (EXTRA_DIST): Remove javaexec.sh.in.
148703         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
148704         * modules/csharpcomp-script (Files): Update.
148705         (configure.ac): Add AC_CONFIG_FILES invocation.
148706         (EXTRA_DIST): Remove variable.
148708         * build-aux/csharpexec.sh.in: New file, moved from lib/.
148709         * modules/csharpexec (Files): Update.
148710         (configure.ac): Add AC_CONFIG_FILES invocation.
148711         (EXTRA_DIST): Remove csharpexec.sh.in.
148713 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
148715         Sync from coreutils.
148717         Add POSIX ACL support
148718         * lib/acl.h (copy_acl, set_acl): Add declarations.
148719         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
148720         systems other than Linux.
148721         (chmod_or_fchmod): New function: use fchmod when possible,
148722         and chmod otherwise.
148723         (file_has_acl): Add a POSIX ACL implementation, with a
148724         Linux-specific subcase.
148725         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
148726         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
148727         acls are unsupported.
148728         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
148729         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
148730         are unsupported.
148732 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
148734         Sync from coreutils.
148735         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
148737 2006-01-07  Bruno Haible  <bruno@clisp.org>
148739         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
148740         gl_EARLY.
148742 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
148744         * lib/strftime.c (tzname): Don't declare if it is already #defined.
148745         Problem reported for Mingw by Mark Junker.
148747 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
148749         * README: Gnulib normally doesn't generate a tarball.
148751 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
148753         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
148754         long int, not int, for nanosecond counts, so that people who are
148755         used to POSIX struct timespec won't be surprised.  Reported by Jim
148756         Meyering.
148758 2005-12-28  Bruno Haible  <bruno@clisp.org>
148760         * build-aux/config.rpath: Update from GNU gettext.
148762 2005-12-16  Jim Meyering  <jim@meyering.net>
148764         * modules/fprintftime: New module.
148765         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
148767 2005-12-16  Jim Meyering  <jim@meyering.net>
148769         * m4/fprintftime.m4: New file.
148771 2005-12-16  Jim Meyering  <jim@meyering.net>
148773         * lib/fprintftime.c, lib/fprintftime.h: New files.
148775 2005-12-15  Simon Josefsson  <jas@extundo.com>
148777         * modules/socklen (configure.ac): Fix M4 macro name, to align with
148778         new m4/socklen.m4.
148780 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
148782         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
148783         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
148785 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
148787         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
148788         * lib/argp-help.c (fill_in_uparams): Check if the constructed
148789         struct uparams is valid. Fall back to the default values if it is
148790         not.
148792 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
148794         * modules/argp (Files): Add argp-pin.c
148795         (Depends-on): dirname
148796         (lib_SOURCES): Add argp-pin.c
148798 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
148800         * m4/argp.m4:  Check if program_invocation_name and
148801         program_invocation_short_name are declared and define appropriate
148802         macros if they are not.
148804 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
148806         * lib/argp-help.c (__argp_base_name): New function
148807         (__argp_short_program_name): Rewrite using __argp_base_name
148808         * lib/argp-namefrob.h: Define program_invocation_name and
148809         program_invocation_short_name if requested
148810         (__argp_base_name): Add prototype
148811         * lib/argp-parse.c (argp_def): Use gettext wrappers
148812         (argp_default_parser): Use __argp_base_name
148813         * lib/argp-pin.c: New file. Defines program_invocation_name and
148814         program_invocation_short_name on systems that lack them.
148816 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
148818         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
148819         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
148820         porting problem reported by Georg Schwarz in
148821         <http://lists.gnu.org/r/bug-coreutils/2005-12/msg00083.html>.
148823 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
148825         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
148826         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
148827         porting problem reported by Georg Schwarz in
148828         <http://lists.gnu.org/r/bug-coreutils/2005-12/msg00083.html>.
148830 2005-12-05  Bruno Haible  <bruno@clisp.org>
148832         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
148833         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
148834         Reported by Mark Junker <mjscod@gmx.de>.
148836 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
148838         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
148839         Use implementation from Albert Chin, with some
148840         comments/corrections by Stepan Kasal and myself.
148842 2005-12-02  Bruno Haible  <bruno@clisp.org>
148844         * gnulib-tool (func_import): Accept GPLed build tool modules when
148845         --lgpl is given.
148846         * modules/csharpcomp-script: New file.
148847         * modules/csharpcomp: Depend on it.
148848         * modules/javacomp-script: New file.
148849         * modules/javacomp: Depend on it.
148850         Suggested by Simon Josefsson.
148852 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
148854         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
148855         statement, to work around an HP-UX 10.20 compiler bug reported by
148856         Peter O'Gorman.
148858 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
148860         * modules/savedir (Depends-on): Add openat.
148862 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
148864         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
148865         (uintmax_t) [defined uintmax_t]: Do not declare.
148866         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
148867         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
148868         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
148869         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
148870         sake of portability to weird hosts that C allows (though we don't
148871         know of any practical examples).
148873         * lib/savedir.h (fdsavedir): New decl.
148874         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
148875         contains most of the former guts of savedir.
148876         (savedir): Use savedirstream.
148877         Include "openat.h".
148879 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
148881         * modules/obstack (Files): Add m4/ulonglong.m4.
148882         Problem reported by Davide Angelocola.
148884 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
148886         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
148887         coreutils no longer futzes with rounding modes.
148889 2005-11-14  Jim Meyering  <jim@meyering.net>
148891         * lib/mkstemp-safer.c: Include <config.h>, required for possible
148892         replacement of mkstemp.
148894 2005-11-10  Simon Josefsson  <jas@extundo.com>
148896         * lib/readline.c: Remove EOL.
148898 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
148900         * modules/gethrxtime (Depends-on): Add gettime.
148902 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
148904         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
148905         or gettimeofday; no longer needed.
148907 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
148909         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
148910         time business.
148911         (gethrxtime) [! (HAVE_NANOUPTIME
148912         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
148913         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
148914         our own approximation.
148916 2005-11-08  Eric Blake  <ebb9@byu.net>
148918         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
148920 2005-11-08  Eric Blake  <ebb9@byu.net>
148922         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
148924 2005-11-04  Bruno Haible  <bruno@clisp.org>
148926         * gnulib-tool: Implement --update mode.
148928 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
148930         Fix porting problem reported by Theodoros V. Kalamatianos.
148931         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
148932         Don't assume that futimes failing means we must fail.
148934 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
148936         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
148937         variables to suggest the intended function of the PATH_MAX check.
148939 2005-10-30  Kean Johnston  <jkj@sco.com>
148941         Trivial changes to support SCO systems.
148942         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
148943         as PATH_MAX.
148944         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
148945         where __ptr is null when no I/O is pending.
148947 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
148949         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
148950         leave errno alone.  Problem reported by Dmitry V. Levin.
148952 2005-10-28  Simon Josefsson  <jas@extundo.com>
148954         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
148955         Test more.
148957         * tests/test-gc-md2.c, tests/test-md2.c: New files.
148959         * modules/md2, modules/md2-tests: New files.
148961 2005-10-28  Simon Josefsson  <jas@extundo.com>
148963         * m4/inet_ntop.m4: More tests.
148965         * m4/gc-md2.m4, md2.m4: New file.
148967 2005-10-28  Simon Josefsson  <jas@extundo.com>
148969         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
148970         "restrict" keywords, as per POSIX.  Protect the function
148971         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
148972         Don't use K&R prototypes.  Check the sprintf return values.
148973         Re-define EAFNOSUPPORT if not present.  Indent.
148975         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
148976         suggested by Bruno Haible <bruno@clisp.org>.
148978         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
148980         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
148982         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
148983         libgcrypt).
148985         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
148987         * lib/md2.h, lib/md2.c: New files.
148989 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
148991         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
148992         errno alone.  Problem reported by Frederic Jolliton.
148994 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
148996         * modules/verify (License): Change from GPL to LGPL.  This is a
148997         tiny module and there are apparently near-equivalents that are
148998         under the BSD license.
149000 2005-10-24  Simon Josefsson  <jas@extundo.com>
149002         * modules/sha1: Relicense to LGPL.
149004 2005-10-24  Simon Josefsson  <jas@extundo.com>
149006         * lib/md4.h: Shrink buffer size, now that we changed the type.
149008 2005-10-23  Simon Josefsson  <jas@extundo.com>
149010         * gnulib-tool (func_import): Fix --tests-base.
149012 2005-10-22  Simon Josefsson  <jas@extundo.com>
149014         * modules/arcfour (Depends-on): Need stdint.
149016 2005-10-22  Simon Josefsson  <jas@extundo.com>
149018         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
149019         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
149021 2005-10-22  Simon Josefsson  <jas@extundo.com>
149023         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
149024         suggested by Bruno Haible <bruno@clisp.org>.
149026 2005-10-22  Simon Josefsson  <jas@extundo.com>
149028         * lib/crc.h: Include stddef.h, for size_t.
149030 2005-10-22  Simon Josefsson  <jas@extundo.com>
149032         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
149033         arcfour_context struct (simplify test vector testing in GNU
149034         Shishi).
149036 2005-10-21  Simon Josefsson  <jas@extundo.com>
149038         * modules/des, modules/des-tests: New files.
149040         * modules/gc-des, modules/gc-des-tests: New files.
149042         * tests/test-des.c, tests/test-gc-des.c: New file.
149044 2005-10-21  Simon Josefsson  <jas@extundo.com>
149046         * modules/arctwo, modules/arctwo-tests: New files.
149048         * tests/test-arctwo.c: New file.
149050         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
149052         * tests/test-gc-arctwo.c: New file.
149054 2005-10-21  Simon Josefsson  <jas@extundo.com>
149056         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
149057         Bruno Haible <bruno@clisp.org>.
149059         * m4/gc-des.m4: New file.
149061 2005-10-21  Simon Josefsson  <jas@extundo.com>
149063         * m4/arctwo.m4: New file.
149065         * m4/gc-arctwo.m4: New file.
149067 2005-10-21  Simon Josefsson  <jas@extundo.com>
149069         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
149070         block.
149072 2005-10-21  Simon Josefsson  <jas@extundo.com>
149074         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
149075         <bruno@clisp.org>.
149077         * lib/hmac-sha1.c (hmac_sha1): Likewise.
149079         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
149080         Bruno Haible <bruno@clisp.org>.
149082         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
149083         <bruno@clisp.org>.
149085 2005-10-21  Simon Josefsson  <jas@extundo.com>
149087         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
149089 2005-10-21  Simon Josefsson  <jas@extundo.com>
149091         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
149093 2005-10-21  Simon Josefsson  <jas@extundo.com>
149095         * lib/des.h, lib/des.c: New files.
149097         * lib/gc-gnulib.c: Support DES.c
149099 2005-10-21  Simon Josefsson  <jas@extundo.com>
149101         * lib/arctwo.h, lib/arctwo.c: New files.
149103         * lib/gc-gnulib.c: Support ARCTWO.
149105 2005-10-21  Simon Josefsson  <jas@extundo.com>
149107         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
149108         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
149110 2005-10-21  Simon Josefsson  <jas@extundo.com>
149112         * gnulib-tool (func_import, func_create_testdir): Define automake
149113         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
149114         Makefile.am snippet),
149115         suggested by Bruno Haible <bruno@clisp.org>.
149117         * modules/gc (Makefile.am): Use it.
149119 2005-10-21  Bruno Haible  <bruno@clisp.org>
149121         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
149122         patch.
149124 2005-10-19  Simon Josefsson  <jas@extundo.com>
149126         * tests/test-gc-rijndael.c: New file.
149128         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
149130 2005-10-19  Simon Josefsson  <jas@extundo.com>
149132         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
149133         interface too.
149135 2005-10-19  Simon Josefsson  <jas@extundo.com>
149137         * tests/test-gc-arcfour.c: New file.
149139         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
149141 2005-10-19  Simon Josefsson  <jas@extundo.com>
149143         * modules/gc-md4, modules/gc-md4-tests: New file.
149145         * tests/test-gc-md4.c: New file.
149147 2005-10-19  Simon Josefsson  <jas@extundo.com>
149149         * m4/gc-md4.m4: New file.
149151 2005-10-19  Simon Josefsson  <jas@extundo.com>
149153         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
149154         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
149155         <kasal@ucw.cz>.
149157 2005-10-19  Simon Josefsson  <jas@extundo.com>
149159         * m4/gc-arcfour.m4: New file.
149161         * m4/gc-rijndael.m4: New file.
149163 2005-10-19  Simon Josefsson  <jas@extundo.com>
149165         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
149167 2005-10-19  Simon Josefsson  <jas@extundo.com>
149169         * lib/gc-gnulib.c: Support ARCFOUR.
149171 2005-10-19  Simon Josefsson  <jas@extundo.com>
149173         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
149174         support.
149176         * lib/gc.h: Add ECB enum type.
149178         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
149180 2005-10-18  Simon Josefsson  <jas@extundo.com>
149182         * tests/test-md5.c: New file.
149184         * modules/md5-tests: New file.
149186 2005-10-18  Simon Josefsson  <jas@extundo.com>
149188         * tests/test-md4.c: New file.
149190         * modules/md4, modules/md4-tests: New files.
149192 2005-10-18  Simon Josefsson  <jas@extundo.com>
149194         * m4/md4.m4: New file.
149196 2005-10-18  Simon Josefsson  <jas@extundo.com>
149198         * lib/md4.h, lib/md4.c: New files, based on md5.?.
149200 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
149202         * gnulib-tool (func_create_testdir): Omit the second check whether
149203         BUILT_SOURCES in nonempty.
149205 2005-10-17  Simon Josefsson  <jas@extundo.com>
149207         * tests/test-rijndael.c: New file.
149209 2005-10-17  Simon Josefsson  <jas@extundo.com>
149211         * modules/sha1: Depend on stdint instead of md5.
149213         * modules/md5: Depend on stdint, remove uint32_t.
149215 2005-10-17  Simon Josefsson  <jas@extundo.com>
149217         * modules/gc-sha1-tests: New file.
149219         * tests/test-gc-sha1.c: New file.
149221 2005-10-17  Simon Josefsson  <jas@extundo.com>
149223         * m4/md5.m4: Remove call to uint32_t.m4.
149225 2005-10-17  Simon Josefsson  <jas@extundo.com>
149227         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
149229         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
149230         md5.h.
149232         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
149234         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
149236 2005-10-17  Simon Josefsson  <jas@extundo.com>
149238         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
149240 2005-10-17  Simon Josefsson  <jas@extundo.com>
149242         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
149244 2005-10-17  Simon Josefsson  <jas@extundo.com>
149246         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
149248         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
149250 2005-10-17  Bruno Haible  <bruno@clisp.org>
149252         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
149253         that it can also be used in a test.
149255 2005-10-16  Bruno Haible  <bruno@clisp.org>
149257         * gnulib-tool (func_emit_tests_Makefile_am): Also define
149258         TESTS_ENVIRONMENT, so that individual tests can augment it.
149260         * gnulib-tool (func_create_testdir): Use an intermediate target for
149261         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
149262         macros, like $(ALLOCA_H), which cannot be passed through the command
149263         line.
149265 2005-10-15  Simon Josefsson  <jas@extundo.com>
149267         * modules/rijndael-tests: New file.
149269         * modules/rijndael: New file.
149271 2005-10-15  Simon Josefsson  <jas@extundo.com>
149273         * m4/rijndael.m4: New file.
149275 2005-10-15  Simon Josefsson  <jas@extundo.com>
149277         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
149279         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
149281 2005-10-14  Simon Josefsson  <jas@extundo.com>
149283         * tests/test-arcfour.c: New file.
149285         * modules/arcfour, modules/arcfour-tests: New files.
149287 2005-10-14  Simon Josefsson  <jas@extundo.com>
149289         * m4/arcfour.m4: New file.
149291 2005-10-14  Simon Josefsson  <jas@extundo.com>
149293         * lib/arcfour.h, lib/arcfour.c: New files.
149295 2005-10-14  Roland McGrath  <roland@redhat.com>
149297         Import from libc.  [BZ #1331]
149298         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
149299         macro argument.
149300         Reported by Matej Vela <vela@debian.org>.
149302 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
149304         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
149305         include <wchar.h>; no longer needed.
149307 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
149309         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
149311 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
149312         and  Ulrich Drepper  <drepper@redhat.com>
149314         Import from libc.
149315         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
149316         instead of inline stream orientation test and two separate
149317         function calls.  Pay no attention to USE_IN_LIBIO.
149319 2005-10-13  Simon Josefsson  <jas@extundo.com>
149321         * modules/gc-hmac-md5-tests: New file.
149323         * tests/test-gc-hmac-sha1.c: New file.
149325         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
149327         * modules/gc-hmac-md5-tests: New file.
149329         * tests/test-gc-md5.c: New file.
149331         * modules/gc-md5-tests: New file.
149333 2005-10-13  Simon Josefsson  <jas@extundo.com>
149335         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
149336         Move memory allocation outside of loop.
149338 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
149340         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
149341         intermediate directory is in a read-only file system.  Problem
149342         reported by Eric Blake.
149344 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
149346         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
149348 2005-10-12  Simon Josefsson  <jas@extundo.com>
149350         * tests/test-hmac-sha1.c: New file.
149352         * modules/hmac-sha1-tests: New file.
149354         * modules/hmac-sha1: New file.
149356 2005-10-12  Simon Josefsson  <jas@extundo.com>
149358         * modules/gc-sha1: New file.
149360 2005-10-12  Simon Josefsson  <jas@extundo.com>
149362         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
149364         * tests/test-gc-pbkdf2-sha1.c: New file.
149366 2005-10-12  Simon Josefsson  <jas@extundo.com>
149368         * modules/gc-md5, modules/gc-hmac-md5: New files.
149370         * modules/gc (Files): Remove md5, memxor and hmac files.
149372 2005-10-12  Simon Josefsson  <jas@extundo.com>
149374         * m4/gc-pbkdf2-sha1.m4: New file.
149376         * m4/gc-hmac-sha1.m4: New file.
149378         * m4/gc-sha1: New file.
149380         * m4/hmac-sha1.m4: New file.
149382 2005-10-12  Simon Josefsson  <jas@extundo.com>
149384         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
149386         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
149388 2005-10-12  Simon Josefsson  <jas@extundo.com>
149390         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
149391         suggested by Bruno Haible <bruno@clisp.org>.
149393 2005-10-12  Simon Josefsson  <jas@extundo.com>
149395         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
149397 2005-10-12  Simon Josefsson  <jas@extundo.com>
149399         * lib/gc-pbkdf2-sha1.c: New file.
149401         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
149403 2005-10-12  Simon Josefsson  <jas@extundo.com>
149405         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
149407         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
149409 2005-10-12  Simon Josefsson  <jas@extundo.com>
149411         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
149412         GC_USE_HMAC_MD5, respectively.
149414         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
149415         (gc_md5): Fix typo.
149417         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
149419         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
149421         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
149423 2005-10-12  Bruno Haible  <bruno@clisp.org>
149425         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
149426         Reported by Stepan Kasal <kasal@ucw.cz>.
149428 2005-10-11  Simon Josefsson  <jas@extundo.com>
149430         * tests/test-crc.c: New file.
149432         * modules/crc, modules/crc-tests: New files.
149434 2005-10-11  Simon Josefsson  <jas@extundo.com>
149436         * m4/crc.m4: New file.
149438 2005-10-11  Simon Josefsson  <jas@extundo.com>
149440         * lib/gc.h: Add gc_hash and gc_hash_buffer.
149442         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
149444         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
149446 2005-10-11  Simon Josefsson  <jas@extundo.com>
149448         * lib/crc.h, lib/crc.c: New files.
149450         * lib/gc.h (gc_hash_buffer): Add doc.
149452 2005-10-11  Bruno Haible  <bruno@clisp.org>
149454         * modules/c-strcasestr: New file.
149455         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
149457 2005-10-11  Bruno Haible  <bruno@clisp.org>
149459         * modules/c-strcase: New file.
149460         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
149462 2005-10-11  Bruno Haible  <bruno@clisp.org>
149464         * lib/strcasecmp.c: Include limits.h.
149465         (strcasecmp): Avoid integer overflow on exotic platforms.
149466         * lib/strncasecmp.c: Include limits.h.
149467         (strncasecmp): Avoid integer overflow on exotic platforms.
149468         Reported by Paul Eggert.
149470 2005-10-11  Bruno Haible  <bruno@clisp.org>
149472         * lib/c-strcasestr.h: New file, from GNU gettext.
149473         * lib/c-strcasestr.c: New file, from GNU gettext.
149475 2005-10-11  Bruno Haible  <bruno@clisp.org>
149477         * lib/c-strcase.h: New file, from GNU gettext.
149478         * lib/c-strcasecmp.c: New file, from GNU gettext.
149479         * lib/c-strncasecmp.c: New file, from GNU gettext.
149481 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
149483         * modules/mempcpy (License): GPL -> LGPL.
149484         * modules/strchrnul (License): Likewise.
149485         * modules/sysexits (License): Likewise.
149487 2005-10-08  Simon Josefsson  <jas@extundo.com>
149489         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
149491 2005-10-07  Simon Josefsson  <jas@extundo.com>
149493         * m4/memxor.m4: Remove gl_C_RESTRICT call.
149495 2005-10-06  Simon Josefsson  <jas@extundo.com>
149497         * tests/test-hmac-md5.c: New file.
149499         * modules/hmac-md5-tests: New file.
149501         * modules/hmac-md5: New file.
149503 2005-10-06  Simon Josefsson  <jas@extundo.com>
149505         * m4/hmac-md5.m4: New file.
149507         * m4/memxor.m4: Require gl_C_RESTRICT.
149509 2005-10-06  Simon Josefsson  <jas@extundo.com>
149511         * lib/memxor.c (memxor): Avoid casts and warnings.
149513 2005-10-06  Simon Josefsson  <jas@extundo.com>
149515         * lib/hmac-md5.c: New file.
149517         * lib/hmac.h: New file.
149519 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
149521         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
149522         promotes to int, not unsigned int, to catch the AIX 5.3
149523         compiler bug.
149525 2005-10-05  Simon Josefsson  <jas@extundo.com>
149527         * modules/memxor: New file.
149529         * modules/iconv (Files): Move config.rpath to havelib, it is used
149530         there.
149532         * modules/havelib (Files): Add config.rpath.
149534 2005-10-05  Simon Josefsson  <jas@extundo.com>
149536         * m4/memxor.m4: New file.
149538 2005-10-05  Simon Josefsson  <jas@extundo.com>
149540         * lib/memxor.c (memxor): Fix compiler error.
149542         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
149543         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
149545         * lib/memxor.h, lib/memxor.c: New files.
149547         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
149548         we assume all systems have it, suggested by Jim Meyering
149549         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
149550         any systems lack sys/socket.h; mingw32 is known to lack it, but we
149551         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
149552         same reasons.
149554 2005-10-05  Simon Josefsson  <jas@extundo.com>
149556         * config/srclist.txt: Add glibc bug 1423 for md5.h.
149558 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
149560         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
149561         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
149562         needed, since the source code now assumes these .h files.
149564 2005-10-05  Derek Price  <derek@ximbiot.com>
149566         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
149568 2005-10-05  Bruno Haible  <bruno@clisp.org>
149570         * modules/stdint (License): Change to LGPL.
149572 2005-10-04  Simon Josefsson  <jas@extundo.com>
149574         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
149575         D. Baushke" <mdb@gnu.org>.
149577 2005-10-04  Bruno Haible  <bruno@clisp.org>
149579         * lib/verify.h (verify_true): Provide alternative definition for C++.
149581 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
149583         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
149584         (SSIZE_MAX): New macro, if not already defined.
149585         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
149586         than 2 GiB.
149588 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
149590         Sync from coreutils.
149591         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
149592         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
149593         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
149594         ULLONG_MAX doesn't work with 2.7.2.1.
149596 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
149598         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
149599         From Ben Pfaff.
149601         * modules/exclude (Depends-on): Depend on verify.
149602         * modules/strtoimax (Depends-on): Likewise.
149603         * modules/utimecmp (Depends-on): Likewise.
149605 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
149607         * lib/exclude.c: Include verify.h.
149608         (verify): Remove.  All callers changed to use verify.h's version.
149609         * lib/strtoimax.c: Likewise.
149610         * lib/utimecmp.c: Likewis.e
149612         Sync from coreutils.
149613         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
149614         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
149615         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
149616         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
149617         bother returning ENOSYS if settimeofday or stime fails; just let
149618         them return whatever errno they want to return.
149619         * lib/utimens.c: Include unistd.h, for dup2.
149620         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
149621         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
149623 2005-10-02  Jim Meyering  <jim@meyering.net>
149625         Sync from coreutils.
149626         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
149627         from glibc-2.2.5 that fails for read-only files.
149629 2005-10-02  Jim Meyering  <jim@meyering.net>
149631         Sync from coreutils.
149632         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
149633         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
149634         `#if HAVE_CONFIG_H'.
149635         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
149636         Remove AT_FDCWD test.
149637         Do not consume the fd unless successful.
149638         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
149639         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
149640         block, so that we don't even try to compile it if settimeofday is
149641         available.  This works around a compilation failure on OSF1 V5.1,
149642         due to stime requiring a `long int*' while tv_sec is `int'.
149644 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
149646         Sync from coreutils.
149647         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
149648         against `yes', rather than just testing for nonempty.
149650 2005-10-01  Simon Josefsson  <jas@extundo.com>
149652         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
149653         and Darwin.
149655         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
149656         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
149657         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
149658         freeaddrinfo and gai_strerror are declared by the POSIX headers.
149659         Check if struct addrinfo is declared.
149661 2005-10-01  Simon Josefsson  <jas@extundo.com>
149663         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
149664         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
149665         AI_* and EAI_* definitions.  Protect function declarations.
149667 2005-10-01  Jim Meyering  <jim@meyering.net>
149669         Sync from coreutils.
149671         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
149672         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
149673         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
149674         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
149675         in the inet and nsl libraries.  Required on Solaris 5.7.
149677 2005-10-01  Jim Meyering  <jim@meyering.net>
149679         Sync from coreutils.
149680         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
149681         in the inet and nsl libraries.  Required on Solaris 5.7.
149683 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
149685         * lib/getdelim.c (getdelim): Remove unused variables.
149687 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
149689         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
149690         so that the code works even with ancient cpp.  Portability problem
149691         with GCC 2.7.2.1 reported by Thomas M.Ott.
149693 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
149695         * modules/regex (Depends-on): Add strcase.
149697         * modules/gethostname (Licence): Change from GPL to LGPL, since
149698         gethostname.c is a trivial implementation of a standard library
149699         function.
149700         * modules/poll (License): Change from GPL to LGPL, since it's
149701         derived from LGPL code.
149703 2005-09-27  Jim Meyering  <jim@meyering.net>
149705         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
149706         HAVE_CONFIG_H.
149708         * lib/intprops.h (signed_type_or_expr__): Define.
149709         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
149710         for unsigned types.
149712 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
149714         * lib/verify.h (verify_expr): Remove, replacing with:
149715         (verify_true): New macro that returns true instead of void.
149716         (verify_type__): Remove.
149717         (verify): Use verify_true rather than verify_type__.
149719 2005-09-26  Bruno Haible  <bruno@clisp.org>
149721         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
149722         is necessary.
149723         (lib_SOURCES): Remove mbchar.c.
149724         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
149725         (Files): Add m4/mbrtowc.m4.
149726         * modules/mbiter: Likewise.
149727         * modules/mbuiter: Likewise.
149729 2005-09-26  Bruno Haible  <bruno@clisp.org>
149731         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
149732         compile mbchar.c if they are not both present.
149733         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
149734         * m4/mbiter.m4 (gl_MBITER): Likewise.
149735         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
149736         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
149737         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
149739 2005-09-25  Jim Meyering  <jim@meyering.net>
149741         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
149742         also uses socklen_t.
149744 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
149746         * lib/utimens.c (ENOSYS): Define if not already defined.
149747         (futimens): Support having a null PATH if the file descriptor
149748         is nonnegative.
149750         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
149751         Remove.
149752         (__attribute): Define to empty unless GCC 3.1 or later.
149753         This works around a core dump on OpenBSD 3.4, which has GCC
149754         2.95.3, which dumps core when given __attribute__(()).  It also
149755         simplifies other tests, since we really don't want to bother with
149756         worrying about which ancient version of GCC supported what.
149757         Original problem reported by Yoann Vandoorselaere, with part of
149758         the fix suggested by Derek Price.
149760 2005-09-24  Jim Meyering  <jim@meyering.net>
149762         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
149763         so we can once again use a positive bitfield width of 1 -- now we
149764         don't have to explain why we were using a bitfield width of 2.
149766 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
149768         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
149769         and similarly for the other external symbols.  Problem reported
149770         by James Gallager.
149772         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
149773         bug reported by Jim Meyering.
149775         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
149776         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
149777         not needed, since socklen is a prerequisite module.
149779 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
149781         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
149782         Problem reported by Eric Blake.
149783         (getaddrinfo): Initialize se so that it's not garbage.
149784         Redo internal storage allocation so that it doesn't make unportable
149785         assumptions about alignment.
149786         Fix a memory leak.
149788         * lib/utimens.c (futimens): Use futimesat if available.
149789         Prefer it to futimes since it doesn't have the futimes bug.
149791         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
149792         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
149793         Instead, declare a function that returns a pointer to an array,
149794         and use verify_type__ to declare the size of the array.
149795         Problem and germ of a solution reported by Bruno Haible.
149796         (verify_type__): Use 2, not 1, for bitfield size, to avoid
149797         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
149799 2005-09-23  Jim Meyering  <jim@meyering.net>
149801         Sync from coreutils.
149802         Correct build failure (socklen_t not defined) on at least
149803         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
149804         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
149806 2005-09-23  Jim Meyering  <jim@meyering.net>
149808         * modules/getaddrinfo (Depends-on): Add socklen.
149810 2005-09-23  Bruno Haible  <bruno@clisp.org>
149812         * tests/test-verify.c: New file.
149814 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
149816         Sync from coreutils.
149818         * modules/argmatch (Depends-on): Add verify.
149819         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
149820         unistd-safer.
149821         * modules/save-cwd (Depends-on): Likewise.
149823         * modules/openat (Files): Add lib/openat-die.c.
149824         (Depends-on): Remove error, exitfail.
149825         Add dirname.
149827         * modules/verify: New file.
149828         * MODULES.html.sh (Diagnostics <assert.h>): New section,
149829         with "verify" module.
149831 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
149833         Sync from coreutils.
149835         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
149836         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
149837         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
149838         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
149839         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
149840         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
149841         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
149842         Don't bother checking for string.h, stdlib.h, unistd.h.
149843         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
149844         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
149845         module's job.
149846         * m4/jm-macros.m4 (gl_MACROS): Likewise.
149847         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
149849         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
149850         (gl_GETDATE): Use it.
149852         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
149854 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
149856         Sync from coreutils.
149858         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
149859         stat-time.h.
149860         * lib/argmatch.h: Include verify.h
149861         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
149862         (ARGMATCH_ASSERT): Remove; unused.
149863         * lib/canonicalize.c: Assume STDC_HEADERS.
149864         * lib/exclude.c: Include "strcase.h".
149865         * lib/regex_internal.h [!defined _LIBC]: Likewise.
149866         * lib/getusershell.c: Include stdio--.h rather than stdio.h
149867         and stdio-safer.h.
149868         (getusershell): Call fopen, not fopen_safer.
149869         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
149870         Do not include unistd-safer.h.
149871         (save_cwd): Don't call fd_safer; no longer needed
149872         now that we include fcntl--.h.
149874         * lib/getdate.y (relative_time): New type.
149875         (RELATIVE_TIME_0): New constant.
149876         (parser_control): Use relative_time instead of doing it ourselves.
149877         (%union): Add new relative_time rel member.
149878         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
149879         Now typeless.
149880         (relunit, relunit_snumber): Now of type rel.
149881         (zone, rel, relunit, get_date): Adjust to above changes.
149883         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
149884         Do not include unistd-safer.h.
149885         (getloadavg): Don't call fd_safer; no longer needed
149886         now that we include fcntl--.h.
149888         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
149889         (make_dir_parents): Treat ENOSYS like EEXIST.
149891         Improve quality of diagnostics on restore_cwd failure.
149892         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
149893         (make_dir_parents): Last arg is now int * (for errno), not bool *.
149894         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
149895         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
149896         each time through the loop.  Do not diagnose restore_cwd failure;
149897         that is the caller's job (and perhaps the caller does not care).
149899         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
149900         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
149901         If the file already exists but is not a directory, don't bother
149902         to try to make its parents.
149903         Close potential file descriptor leak if we can't chdir("/") (!).
149904         Don't always return true if chdir($PWD) fails; return true only
149905         if the requested action was done successfully (except for the
149906         chdir($PWD)).
149907         Don't log final directory unless we actually made it.
149908         Refactor to avoid duplicate code to fix up permissions.
149909         Don't attempt to fix up parent permissions if chdir($PWD) fails.
149911         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
149912         to make it a bit faster and (I hope) clearer.
149913         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
149914         Fix bug in formats like %2N.
149916         * lib/verify.h: New file.
149918 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
149920         Sync from coreutils.
149921         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
149923 2005-09-22  Jim Meyering  <jim@meyering.net>
149925         Sync from coreutils.
149927         * m4/lstat.m4 (gl_FUNC_LSTAT):
149928         Use AC_LIBSOURCES to require lstat.c and lstat.h.
149929         Remove obsolete comment.
149930         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
149931         * m4/xstrtod.m4: Likewise.
149933         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
149935 2005-09-22  Jim Meyering  <jim@meyering.net>
149937         Sync from coreutils.
149939         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
149941         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
149942         the .tm_year member, since otherwise gcc-4.0 would now warn about
149943         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
149945         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
149946         order to avoid an unsuppressible warning from gcc on 64-bit systems.
149948         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
149949         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
149950         when run in a time zone for which daylight savings time is in effect
149951         for the starting date.
149953         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
149954         stop us from restricting permissions of just-created absolute-named
149955         directories.
149956         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
149957         to restore initial working directory.
149958         * lib/mkdir-p.c (make_dir_parents): New parameter:
149959         different_working_dir, to tell caller if/when we change the working
149960         directory and are unable to return to the initial one.
149961         * lib/mkdir-p.h (make_dir_parents): Update prototype.
149962         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
149963         `return false'.  This fixes a bug introduced on 2004-07-30.
149965         * lib/openat.c (fdopendir): Be sure to close the supplied
149966         file descriptor before returning.  This makes our replacement
149967         implementation a little closer to Solaris's, where fdopendir
149968         ties the file descriptor to the returned DIR* pointer.
149969         * lib/openat.c (unlinkat): New function.
149970         * lib/openat.h (unlinkat): Add prototype.
149971         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
149972         (openat_restore_fail): Rename from openat_restore_die.
149973         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
149975         Provide an alternative to exiting immediately upon save_cwd or
149976         restore_cwd failure.  Now, an application can arrange e.g.,
149977         to perform a longjump in that case.
149978         * lib/openat.c: Include dirname.h.
149979         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
149980         (rpl_openat, fdopendir, fstatat): Call openat_save_die
149981         and openat_restore_die rather than calling error directly.
149982         Don't include "error.h" or "exitfail.h"; they're no longer needed.
149984         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
149985         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
149986         define.
149988         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
149989         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
149990                             int utc, int nanoseconds);
149991         Background:
149992         date should not have to allocate a megabyte of virtual memory to
149993         handle a format argument like +%1048575T.  When implemented with
149994         strftime, it must allocate such a buffer, use strftime to fill it
149995         in, print it, then free it.
149996         With fprintftime, it simply prints everything and exits.
149997         With no need for memory allocation, that's one fewer way to fail.
149998         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
149999         optional field width, not before, so we accept %9:z, not %:9z.
150000         (my_strftime): Be sure to use L_('x') for literals.
150002         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
150003         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
150004         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
150005         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
150006         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
150007         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
150008         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
150009         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
150010         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
150011         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
150012         * lib/xgethostname.c, lib/xreadlink.c:
150013         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
150015         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
150016         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
150017         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
150018         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
150019         and don't include <sys/file.h>).
150021 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
150023         Sync from coreutils.
150025         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
150026         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
150027         [!LDAV_DONE]: Avoid unused variable warning.
150029 2005-09-21  Bruno Haible  <bruno@clisp.org>
150031         * lib/unicodeio.h (unicode_to_mb): New declaration.
150033 2005-09-20  Derek Price  <derek@ximbiot.com>
150035         * lib/getaddrinfo.c: Don't include <netdb.h> included from
150036         getaddrinfo.h.
150038 2005-09-20  Bruno Haible  <bruno@clisp.org>
150040         * gnulib-tool: Remove trailing slashes from the values specified for
150041         --source-base, --m4-base, --tests-base, --aux-dir.
150042         Suggested by Simon Josefsson <jas@extundo.com>.
150044 2005-09-20  Bruno Haible  <bruno@clisp.org>
150046         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
150047         func_modules_to_filelist, func_import, func_create_testdir): Make all
150048         sorting results locale-independent, so that gnulib-cache.m4 doesn't
150049         change when gnulib-tool is invoked in a different locale.
150051 2005-09-19  Simon Josefsson  <jas@extundo.com>
150053         * m4/socklen.m4: Fix typo.
150055 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
150057         Use a consistent style for including <config.h>.
150058         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
150059         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
150060         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
150061         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
150062         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
150063         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
150064         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
150065         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
150066         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
150067         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
150068         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
150069         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
150070         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
150071         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
150072         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
150073         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
150074         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
150075         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
150076         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
150077         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
150078         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
150079         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
150080         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
150081         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
150082         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
150083         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
150084         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
150085         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
150086         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
150087         lib/xstrtoumax.c, lib/yesno.c:
150088         Standardize inclusion of config.h.
150089         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
150090         lib/inttostr.h:  Removed inclusion of config.h from header files.
150091         * lib/inttostr.c:  Adjusted in-tree users.
150092         * lib/timespec.h: Remove superfluous warning to include config.h.
150093         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
150094         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
150095         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
150096         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
150097         config.h with HAVE_CONFIG_H.
150099 2005-09-19  Jim Meyering  <jim@meyering.net>
150101         * modules/pathmax (License): Change to LGPL.
150103 2005-09-19  Derek Price  <derek@ximbiot.com>
150105         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
150107 2005-09-19  Bruno Haible  <bruno@clisp.org>
150109         * gnulib-tool (import): Provide default for --tests-base.
150111 2005-09-19  Bruno Haible  <bruno@clisp.org>
150113         * doc/quote.texi: New file, extracted from gnulib.texi.
150114         * doc/ctime.texi: New file, extracted from gnulib.texi.
150115         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
150116         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
150117         * doc/gnulib.texi: Include them.
150119 2005-09-18  Bruno Haible  <bruno@clisp.org>
150121         Portability fix.
150122         * gnulib-tool (func_readlink): New function.
150123         (func_ln_if_changed): Use it.
150125 2005-09-18  Bruno Haible  <bruno@clisp.org>
150127         * gnulib-tool: Support --with-tests also with --import.
150128         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
150129         (func_import): Use variables $testsbase and $inctests. Emit a
150130         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
150131         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
150132         SUBDIRS += $testsdir.
150133         (func_create_testdir): Update.
150135 2005-09-18  Bruno Haible  <bruno@clisp.org>
150137         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
150138         instead of $dry_run.
150139         (func_cp_if_changed, func_mv_if_changed): Remove functions.
150140         (func_ln_if_changed): Don't handle dry-run here.
150141         (func_import): In dry-run mode, detect more precisely which actions
150142         would be performed, and don't use "...ing" verbs.
150144 2005-09-18  Bruno Haible  <bruno@clisp.org>
150146         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
150147         (func_import): Use join on two temporary files instead of three nested
150148         loops, in order to determine which files are new or old.
150150 2005-09-18  Bruno Haible  <bruno@clisp.org>
150152         * gnulib-tool (func_import): Comment out code that spits out the
150153         new files with --dry-run.
150155 2005-09-18  Bruno Haible  <bruno@clisp.org>
150157         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
150159 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
150161         * lib/stat-time.h: New file.
150162         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
150163         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
150164         in a different way.
150165         (timespec_cmp): New function.
150166         * lib/utimecmp.c: Include stat-time.h.
150167         (SYSCALL_RESOLUTION): Depend on whether various struct stat
150168         members exist, not on the obsolescent ST_MTIM_NSEC.
150169         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
150171 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
150173         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
150175 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
150177         * MODULES.html.sh (File system functions): Add stat-time.
150178         * modules/stat-time: New file.
150179         * modules/timespec (Files): Remove m4/st_mtim.m4; this
150180         is now done in a different way, by the stat-time module.
150181         * modules/utimecmp (Depends-on): Add stat-time.
150183 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
150185         * m4/st_mtim.m4: Remove.  Superseded by...
150186         * m4/stat-time.m4: New file.
150187         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
150188         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
150190 2005-09-15  Derek Price  <derek@ximbiot.com>
150192         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
150194 2005-09-15  Derek Price  <derek@ximbiot.com>
150196         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
150197         * lib/regex_internal.c: Ditto, using this...
150198         (__GNUC_PREREQ): ...new macro.
150199         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
150200         using...
150201         (__GNUC_PREREQ): ...this new macro.
150203         * lib/strstr.h: Include string.h. Define strstr as a macro here.
150205 2005-09-15  Derek Price  <derek@ximbiot.com>
150206             Paul Eggert  <eggert@cs.ucla.edu>
150208         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
150209         changes, consolidating in...
150210         * lib/regex_internal.h: ...this file.
150212 2005-09-13  Jim Meyering  <jim@meyering.net>
150214         * lib/canon-host.c: Filter through gnu indent and reword comments
150215         slightly.
150216         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
150218 2005-09-13  Derek Price  <derek@ximbiot.com>
150220         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
150221         failure.
150222         Reported by Jim Meyering  <jim@meyering.net>.
150224 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
150226         * lib/base64.c: Typo.
150227         (base64_encode): Put b64str in initialized data section.
150229 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
150231         Merge glibc and coreutils changes into gnulib, plus a few
150232         extra fixes.
150233         * lib/md5.c: Use #error rather than a string.
150234         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
150235         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
150236         (__attribute__): Define to empty for non recent-GCC.
150237         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
150238         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
150239         Renamed from their non-__ counterparts, with new macros replacing
150240         them if not _LIBC.  Add __THROW attribute.
150241         (rol): Remove.
150242         (struct md5_ctx): Align buffer if using GCC.
150243         * lib/sha1.h (struct sha1_ctx): Likewise.
150244         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
150245         The old name was backwards.
150246         (NOTSWAP): Remove; not used.
150247         (rol): New macro, moved here from md5.h.
150248         (sha1_process_block): Remove a FIXME that doesn't make sense.
150250 2005-09-12  Derek Price  <derek@ximbiot.com>
150252         Return usable errors from canon-host.
150253         * lib/canon-host.h: New file.
150254         * lib/canon-host.c (canon_host): Wrap...
150255         (canon_host_r): ...this new function, which now relies exclusively on
150256         getaddrinfo.
150257         (ch_strerror): New function.
150258         (last_cherror): New global.
150259         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
150260         interface.
150261         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
150262         void *.
150263         (freeaddrinfo): Free ai->ai_canonname when set.
150265 2005-09-12  Derek Price  <derek@ximbiot.com>
150267         Make canon-host require getaddrinfo.
150268         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
150269         AC_LIBSOURCE canon-host.h.  Call...
150270         (gl_PREREQ_CANON_HOST): ...this new function, which requires
150271         gl_GETADDRINFO.
150272         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
150274 2005-09-12  Derek Price  <derek@ximbiot.com>
150276         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
150277         LGPL.
150278         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
150280 2005-09-12  Derek Price  <derek@ximbiot.com>
150282         * lib/gai_strerror.c: Include config.h when available.  Include
150283         getaddrinfo.h before other headers to test interface.
150284         Reported by Larry Jones <lawrence.jones@ugs.com>.
150286 2005-09-12  Derek Price  <derek@ximbiot.com>
150287             Paul Eggert  <eggert@cs.ucla.edu>
150289         * modules/glob (Files): Add glob-libc.h.
150291 2005-09-12  Derek Price  <derek@ximbiot.com>
150292             Paul Eggert  <eggert@cs.ucla.edu>
150294         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
150295         glob_.h, glob-libc.h.
150296         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
150298 2005-09-12  Derek Price  <derek@ximbiot.com>
150299             Paul Eggert  <eggert@cs.ucla.edu>
150301         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
150302         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
150303         protecting things that should be done only in gnulib contexts.
150304         * lib/glob_.h: New file, containing only the glob things needed for
150305         gnulib.
150306         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
150307         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
150308         (glob, globfree, glob_pattern_p): Now defined simply in terms of
150309         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
150310         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
150311         and to respect the namespace rules better.
150313 2005-09-08  Simon Josefsson  <jas@extundo.com>
150315         * modules/socklen: New file.
150317 2005-09-08  Simon Josefsson  <jas@extundo.com>
150319         * m4/socklen.m4: New file.
150321 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
150323         * modules/utimens (Files): Add m4/utimbuf.m4, since
150324         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
150325         Reported by Sergey Poznyakoff.
150327 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
150329         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
150330         definitions, since that's the preferred style in glibc.
150331         Fix a minor spacing issue, and update copyright notice to match
150332         glibc's.
150334 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
150336         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
150338 2005-09-06  Simon Josefsson  <jas@extundo.com>
150340         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
150341         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
150343 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
150345         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
150346         warning.
150348 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
150350         * config/srclist.txt: Add glibc bug 1302.
150352 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
150354         Change bitset word type from unsigned int to unsigned long int,
150355         as this has better performance on typical 64-bit hosts.
150356         Port bitset code to hosts with unusual word sizes.
150357         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
150358         (build_collating_symbol):
150359         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
150360         argument is a bitset.  This is merely a style issue, but it makes
150361         it clearer that an entire array is expected.
150362         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
150363         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
150364         Port to the case where bitset_word is not the same as unsigned int.
150365         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
150366         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
150367         Likewise.
150368         * lib/regexec.c (check_dst_limits_calc_pos_1,
150369         check_subexp_matching_top):
150370         (build_trtable, group_nodes_into_DFAstates):
150371         Likewise.
150372         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
150373         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
150374         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
150375         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
150376         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
150377         * lib/regcomp.c (optimize_subexps, lower_subexp):
150378         Work even if bitset_word has holes in its bitwise representation.
150379         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
150380         * lib/regexec.c (check_dst_limits_calc_pos_1,
150381         check_subexp_matching_top):
150382         Likewise.
150383         * lib/regex_internal.c (re_string_reconstruct):
150384         Don't assume UCHAR_MAX == 255.
150385         * lib/regex_internal.h (bitset_set_all): Likewise.
150386         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
150387         All uses changed.
150388         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
150389         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
150390         All uses changed.
150391         (BITSET_WORD_MAX): New macro.
150392         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
150393         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
150394         (bitset_empty, bitset_copy):
150395         Prefer sizeof (bitset) to multiplying it out ourselves.
150396         (bitset_not_merge): Remove; unused.
150397         (bitset_contain): Return bool, not unsigned int with one bit on.
150398         All callers changed.
150399         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
150400         alignment than re_node_set; do this by defining a new internal
150401         type struct dests_alloc and using it to allocate memory.
150403 2005-09-05  Bruno Haible  <bruno@clisp.org>
150405         * gnulib-tool (func_import): Fix comparison in handling of symbolic
150406         links.
150408 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
150410         * modules/size_max (Makefile.am): Add size_max.h
150412 2005-09-04  Derek Price  <derek@ximbiot.com>
150414         * gnulib-tool (func_import): Fix reversed $symbolic logic.
150416 2005-09-03  Simon Josefsson  <jas@extundo.com>
150418         * gnulib-tool: Fix typo.
150420 2005-09-03  Simon Josefsson  <jas@extundo.com>
150422         * config/srclist.txt: Add glibc bug 1293.
150424 2005-09-03  Derek Price  <derek@ximbiot.com>
150426         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
150427         From Larry Jones <lawrence.jones@ugs.com>.
150429 2005-09-02  Simon Josefsson  <jas@extundo.com>
150431         * modules/socklen: New file.
150433 2005-09-02  Simon Josefsson  <jas@extundo.com>
150435         * modules/havelib: New module.
150437         * modules/gettext, modules/iconv, modules/lock, modules/readline:
150438         Use havelib.
150440 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
150442         Check for arithmetic overflow when calculating sizes, to prevent
150443         some buffer-overflow issues.  These patches are conservative, in the
150444         sense that when I couldn't determine whether an overflow was possible,
150445         I inserted a run-time check.
150446         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
150447         macros.
150448         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
150449         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
150450         (re_xnrealloc, re_x2nrealloc): New inline functions.
150451         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
150452         parse_bracket_exp):
150453         (build_equiv_class, build_charclass): Check for arithmetic overflow
150454         in size expression calculations.
150455         * lib/regex_internal.c (re_string_realloc_buffers):
150456         (build_wcs_upper_buffer, re_node_set_add_intersect):
150457         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
150458         (re_dfa_add_node, register_state): Likewise.
150459         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
150460         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
150461         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
150462         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
150464 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
150466         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
150467         m4/ulonglong.m4.  Problem reported by Martin Lambers.
150469 2005-09-02  Bruno Haible  <bruno@clisp.org>
150471         Support for lib vs. lib64 distinction on biarch platforms.
150472         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
150473         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
150474         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
150476 2005-09-02  Bruno Haible  <bruno@clisp.org>
150478         * gnulib-tool (import): In the other first-use case, provide defaults
150479         as well.
150481 2005-09-02  Bruno Haible  <bruno@clisp.org>
150483         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
150484         patches not yet found in the latest gettext release.
150486 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
150488         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
150489         to avoid a collision with bits/local_lim.h in glibc.
150490         All uses changed.  Problem reported by Dmitry V. Levin in
150491         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
150493         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
150494         bugs in int versus size_t comparisons.
150495         (re_string_context_at): Fix bug where the code assumed that
150496         Idx is signed.
150498         Use bool where appropriate.
150499         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
150500         All callers changed.
150501         (calc_eclosure_iter): Likewise, for ROOT arg.
150502         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
150503         (build_charclass_op): Likewise, for NON_MATCH arg.
150504         * lib/regex_internal.c (re_string_allocate, re_string_construct):
150505         (re_string_construct_common): Likewise, for ICASE arg.
150506         * lib/regexec.c (re_search_2_stub, re_search_stub):
150507         Likewise, for RET_LEN arg.
150508         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
150509         (set_regs): Likewise, for FL_BACKTRACK arg.
150510         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
150511         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
150512         (calc_eclosure_iter, parse_bracket_exp):
150513         Use bool for internal variables that are booleans.
150514         * lib/regexec.c (re_search_internal, check_matching,
150515         proceed_next_node):
150516         (set_regs, build_sifted_states, sift_states_bkref):
150517         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
150518         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
150519         (find_collation_sequence_value):
150520         Likewise.
150521         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
150522         (re_node_set_compare):
150523         Return bool, not int. All callers changed.
150524         * lib/regexec.c (check_halt_node_context, check_dst_limits):
150525         (build_trtable, check_node_accept): Likewise.
150526         * lib/regex_internal.h: Include stdbool.h.
150528         Fix bugs uncovered when converting to bool.
150529         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
150530         failure instead of charging ahead blindly.
150531         * lib/regex_internal.c (register_state): Likewise.
150532         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
150533         for freeing internal storage.
150534         (group_nodes_into_DFA_states): Use unsigned int, not int, for
150535         bitset pieces used as boolean, to avoid undefined behavior
150536         on hosts that do int overflow checking.
150538 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
150540         * config/srclist.txt: Add glibc bugs 1285-1287.
150542 2005-09-01  Jim Meyering  <jim@meyering.net>
150544         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
150545         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
150546         Require gl_STAT_MACROS, too.
150548 2005-09-01  Bruno Haible  <bruno@clisp.org>
150550         * gnulib-tool (import): In the first-use case, provide defaults.
150552 2005-09-01  Bruno Haible  <bruno@clisp.org>
150554         * gnulib-tool (func_import): Remove the .tmp files.
150556 2005-09-01  Bruno Haible  <bruno@clisp.org>
150558         * gnulib-tool (func_import): Fix handling of symbolic links.
150560 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
150562         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
150563         old glibc regex code mishandles strings longer than 2**31 bytes.
150564         This patch fixes this when the regex code is used in gnulib
150565         (i.e., outside glibc).
150567         This patch should not affect the use of the regex code inside
150568         glibc.  No doubt this problem also needs to be handled for glibc
150569         as well, but the result will be an incompatible change to the
150570         glibc ABI, and the old ABI will have to be supported too.  That
150571         can be the subject for another patch.
150573         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
150574         governing whether the rest of this patch is active.  By default,
150575         the macro is disabled and the patch has no effect.
150576         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
150577         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
150578         (struct re_pattern_buffer, re_search, re_search_2, re_match):
150579         (re_match_2, re_set_registers): Use the new types.
150580         * lib/regex_internal.h (Idx, re_hashval_t): New types.
150581         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
150582         New macros.
150583         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
150584         (re_string_context_at, bin_tree_t, re_dfastate_t):
150585         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
150586         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
150587         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
150588         (re_string_char_size_at, re_string_wchar_at):
150589         (re_string_elem_size_at):
150590         Use the new types and macros to port to 64-bit hosts.
150591         Use unsigned types for internal values, so that the code
150592         mostly works even for arrays larger than SSIZE_MAX.
150593         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
150594         (search_duplicated_node, calc_eclosure_iter, fetch_number):
150595         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
150596         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
150597         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
150598         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
150599         (calc_inveclosure, parse_dup_op, build_range_exp):
150600         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
150601         (fetch_number, create_token_tree, mark_opt_subexp):
150602         Likewise.
150603         * lib/regex_internal.c (re_string_construct_common,
150604         create_ci_newstate):
150605         (create_cd_newstate, re_string_allocate, re_string_construct):
150606         (re_string_realloc_buffers, build_wcs_upper_buffer):
150607         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
150608         (re_string_reconstruct, re_string_peek_byte_case):
150609         (re_string_fetch_byte_case, re_string_context_at):
150610         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
150611         (re_node_set_init_copy, re_node_set_add_intersect):
150612         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
150613         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
150614         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
150615         (re_acquire_state, re_acquire_state_context, register_state):
150616         Likewise.
150617         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
150618         search_cur_bkref_entry):
150619         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
150620         (re_search_internal, re_search_2_stub, re_search_stub)
150621         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
150622         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
150623         (update_cur_sifted_state, check_dst_limits):
150624         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
150625         (check_subexp_limits, sift_states_bkref, merge_state_array):
150626         (check_subexp_matching_top, get_subexp, get_subexp_sub):
150627         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
150628         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
150629         (expand_bkref_cache, check_node_accept_bytes):
150630         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
150631         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
150632         (acquire_init_state_context, check_halt_node_context):
150633         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
150634         (sift_states_backward, clean_state_log_if_needed):
150635         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
150636         (find_recover_state, transit_state_sb, transit_state_mb):
150637         (transit_state_bkref, build_trtable, match_ctx_clean):
150638         Likewise.
150639         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
150640         to work around an assumption that REG_MISSING is negative.
150642         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
150643         (seek_collating_symbol_entry) [defined _LIBC]:
150644         (lookup_collation_sequence_value) [defined _LIBC]:
150645         (build_range_exp, build_collating_symbol) [defined _LIBC]:
150646         Use prototypes rather than old-style function definitions.
150647         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
150648         (transit_state_sb) [0]:
150649         (find_collation_sequence_value) [defined _LIBC]: Likewise.
150651         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
150652         rm_eo.
150654         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
150655         (optimize_subexps, lower_subexp):
150656         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
150657         since the signed shift might overflow.  Use 1u<<31 instead.
150658         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
150659         Likewise.
150660         * lib/regexec.c (check_dst_limits_calc_pos_1,
150661         check_subexp_matching_top): Likewise.
150663         * lib/regcomp.c (optimize_subexps, lower_subexp):
150664         Use CHAR_BIT rather than 8, for clarity.
150665         * lib/regexec.c (check_dst_limits_calc_pos_1):
150666         (check_subexp_matching_top): Likewise.
150667         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
150668         have to worry about portability issues when shifting it left.
150669         Remove no-longer-needed test for table_size > 0.
150670         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
150671         in a word, as the resulting behavior is undefined.
150672         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
150673         in one case, a <= should have been an <, and in another case the
150674         whole test was missing.
150675         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
150676         the standard name CHAR_BIT.
150677         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
150678         this is not true on one's complement and signed-magnitude hosts.
150680         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
150681         next_last_offset.
150682         (struct re_dfa_t): Remove unused member states_alloc.
150683         * lib/regcomp.c (init_dfa): Don't initialize unused members.
150685 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
150687         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
150688         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
150689         and large-file glibc and in 32-bit large-file Solaris.
150691 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
150693         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
150694         lengths fit in regoff_t; this isn't true if regoff_t is the same
150695         width as size_t.
150696         * lib/regex.c (re_search_internal): 5th arg is LAST_START
150697         (= START + RANGE) instead of RANGE.  This avoids overflow
150698         problems when regoff_t is the same width as size_t.
150699         All callers changed.
150700         (re_search_2_stub): Check for overflow when adding the
150701         sizes of the two strings.
150702         (re_search_stub): Check for overflow when adding START
150703         to RANGE; if it occurs, substitute the extreme value.
150705 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
150707         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
150709 2005-08-31  Jim Meyering  <jim@meyering.net>
150711         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
150712         a pointer-to-const.
150713         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
150714         (register_state): Likewise.
150715         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
150716         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
150717         (group_nodes_into_DFAstates): Likewise.
150719 2005-08-31  Jim Meyering  <jim@meyering.net>
150721         * check-module: Add a FIXME comment.
150723 2005-08-31  Eric Blake  <ebb9@byu.net>
150725         * modules/unistd-safer (Files): Add unistd--.h.
150726         * modules/stdio-safer (Files): Add stdio--.h.
150728 2005-08-31  Derek Price  <derek@ximbiot.com>
150730         * lib/getdelim.c (getdelim): Return EOF on EOF.
150731         Reported by Larry Jones <lawrence.jones@ugs.com>.
150733 2005-08-31  Bruno Haible  <bruno@clisp.org>
150735         Avoid unnecessary diffs in the generated lib/Makefile.am.
150736         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
150737         the generated files.
150738         (func_import): Don't set cmd.
150740 2005-08-31  Bruno Haible  <bruno@clisp.org>
150742         * lib/strstr.c: Include <stddef.h>, for NULL.
150743         * lib/strcasestr.c: Likewise.
150744         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
150746 2005-08-31  Bruno Haible  <bruno@clisp.org>
150748         * gnulib-tool: New option --macro-prefix.
150749         (func_import): Use macro_prefix.
150750         (import): Handle option --macro-prefix.
150752 2005-08-31  Bruno Haible  <bruno@clisp.org>
150754         * gnulib-tool (import): Rename most ac_* variables to cached_*.
150755         Also use new variables cached_lgpl, cached_libtool.
150757 2005-08-31  Bruno Haible  <bruno@clisp.org>
150759         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
150760         always instantiating them.
150762 2005-08-31  Bruno Haible  <bruno@clisp.org>
150764         * gnulib-tool (func_import): Read the previous cached settings
150765         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
150766         earlier added by gnulib but are now dropped. Warn when a gnulib file
150767         overwrites a non-gnulib file.
150769 2005-08-31  Bruno Haible  <bruno@clisp.org>
150771         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
150772         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
150773         projects that don't keep autogenerated files in CVS. Put into
150774         actioncmd only the specified modules, not the transitive closure.
150776 2005-08-31  Bruno Haible  <bruno@clisp.org>
150778         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
150779         Create directories that shall be filled.
150780         (import): Don't look for gl_* macros in configure.ac. Recurse across
150781         all directories containing a gnulib-cache.m4 files, if meaningful.
150783 2005-08-31  Bruno Haible  <bruno@clisp.org>
150785         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
150786         (import): Set seen_libtool when we see gl_LIBTOOL.
150788 2005-08-31  Bruno Haible  <bruno@clisp.org>
150790         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
150791         declaration macro definitions from generated gnulib.m4.
150793 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
150795         * lib/iconvme.h: Add prototype for iconv_alloc.
150797 2005-08-29  Simon Josefsson  <jas@extundo.com>
150799         * lib/iconvme.c: Fix errno.
150801 2005-08-29  Bruno Haible  <bruno@clisp.org>
150803         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
150804         that it works when the directory contains spaces.
150806 2005-08-29  Bruno Haible  <bruno@clisp.org>
150808         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
150810 2005-08-29  Bruno Haible  <bruno@clisp.org>
150812         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
150813         Emit more advice.
150815 2005-08-29  Bruno Haible  <bruno@clisp.org>
150816         and Stepan Kasal  <kasal@ucw.cz>
150818         * check-module: If more parameters are given, check each of them
150819         separately; add more exceptions, as noted by Jim Meyering.
150820         (check_module): New procedure.
150821         (%exempt_header): Now contains all exceptions.
150823 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
150825         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
150827 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
150829         * lib/iconvme.c: Split iconv_string into iconv_alloc.
150831 2005-08-28  Bruno Haible  <bruno@clisp.org>
150833         * m4/gnulib-tool.m4: New file.
150835 2005-08-27  Jim Meyering  <jim@meyering.net>
150837         * modules/unistd-safer (Files): Add pipe-safer.c.
150838         * modules/fcntl-safer (Files): Add creat-safer.c.
150840 2005-08-27  Jim Meyering  <jim@meyering.net>
150842         * m4/stdlib-safer.m4: New file.  From coreutils.
150843         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
150844         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
150845         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
150846         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
150847         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
150849 2005-08-27  Jim Meyering  <jim@meyering.net>
150851         * lib/fopen-safer.c: Merge minor changes from coreutils.
150852         * lib/dup-safer.c: Likewise.
150853         * lib/fd-safer.c: Likewise.
150855         Merge from coreutils.
150856         * lib/stdio--.h: New file.
150857         * lib/stdlib--.h: New file.
150858         * lib/mkstemp-safer.c: New file.
150860         GNU tar needs these.
150861         * lib/pipe-safer.c: New file.
150862         * lib/creat-safer.c: New file.
150863         * lib/fcntl--.h (creat): Define to creat_safer.
150864         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
150865         * lib/unistd--.h (pipe): Define to pipe_safer.
150866         * lib/unistd-safer.h: Declare pipe_safer.
150868 2005-08-26  Simon Josefsson  <jas@extundo.com>
150870         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
150871         Haible <bruno@clisp.org>.
150873 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
150875         * lib/regex_internal.h: Remove all references to
150876         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
150877         or better.
150878         (bitset_not, bitset_merge, bitset_not_merge):
150879         (bitset_mask, re_string_allocate, re_string_construct):
150880         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
150881         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
150882         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
150883         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
150884         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
150885         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
150886         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
150887         (re_acquire_state_context):
150888         Remove unnecessary forward decls.
150889         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
150890         Put __attribute at function definition,
150891         now that the function decl has been removed.
150892         * lib/regex_internal.c (re_string_peek_byte_case):
150893         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
150894         Likewise.
150896 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
150898         * m4/regex.m4: Add AC_PREREQ(2.50).
150899         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
150901 2005-08-25  Simon Josefsson  <jas@extundo.com>
150903         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
150904         __fsetlocking.
150906 2005-08-25  Simon Josefsson  <jas@extundo.com>
150908         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
150909         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
150910         GLIBC specific code.
150912 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
150914         Make regex safe for g++.  This fixes one real bug (an "err"
150915         that should have been "*err").  g++ problem reported by
150916         Sam Steingold.
150917         * lib/regex_internal.h (re_calloc): New macro, consistent with
150918         re_malloc etc.  All callers of calloc changed to use re_calloc.
150919         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
150920         not int.  All callers changed.
150921         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
150922         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
150923         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
150924         (find_recover_state): Change "err" to "*err"; this fixes what
150925         appears to be a real bug.
150926         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
150927         versus int.
150929 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
150931         * modules/regex (Depends-on): Add malloc, since the code
150932         assumes that !malloc(0) means failure.
150934 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
150936         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
150938         alloca modernization/simplification for regex.
150939         * lib/regex.c: Remove portability cruft for alloca.  This no longer
150940         needs to be at the start of the file, and can be moved into
150941         regex_internal.h and simplified.
150942         * lib/regex_internal.h: Include <alloca.h>.
150943         (__libc_use_alloca) [!defined _LIBC]: New macro.
150944         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
150945         now works outside glibc.
150947 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
150949         * config/srclist.txt: Add glibc bugs 1241, 1245.
150951 2005-08-25  Jim Meyering  <jim@meyering.net>
150953         * lib/open-safer.c: Include <config.h>.
150954         Otherwise, we'd lose LARGEFILE support in any file using
150955         e.g. "fcntl--.h"
150957 2005-08-25  Bruno Haible  <bruno@clisp.org>
150959         * m4/minmax.m4: Require autoconf 2.52.
150960         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
150961         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
150962         alternatives of translit over the alphabet.
150963         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
150965 2005-08-24  Simon Josefsson  <jas@extundo.com>
150967         * tests/test-getpass.c: New file.
150969 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
150971         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
150972         for GNU regex features.
150974 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
150976         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
150977         * lib/regex.h (regerror): Likewise.
150979         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
150980         requires this.  (The code never needed it.)
150982         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
150983         All uses of recently-renamed identifiers changed to use the new,
150984         POSIX-compliant names.  The code will build and run just fine
150985         without these changes, but it's better to eat our own dog food
150986         and use the standard-conforming names.
150988         * lib/regex.h: Fix a multitude of POSIX name space violations.
150989         These changes have an effect only for programs that define
150990         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
150991         do not change anything for programs compiled in the normal way.
150992         Also, there is no effect on the ABI.
150994         (_REGEX_SOURCE): New macro.
150995         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
150996         defined and _GNU_SOURCE is not; this fixes a name space violation.
150998         Rename the following macros to obey POSIX requirements.
150999         The old names are still visible as macros if _REGEX_SOURCE is defined.
151000         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
151001         RE_BACKSLASH_ESCAPE_IN_LISTS.
151002         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
151003         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
151004         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
151005         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
151006         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
151007         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
151008         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
151009         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
151010         (REG_INTERVALS): renamed from RE_INTERVALS.
151011         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
151012         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
151013         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
151014         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
151015         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
151016         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
151017         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
151018         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
151019         RE_UNMATCHED_RIGHT_PAREN_ORD.
151020         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
151021         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
151022         (REG_DEBUG): renamed from RE_DEBUG.
151023         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
151024         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
151025         unusual, since we can't clash with the POSIX REG_ICASE.
151026         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
151027         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
151028         (REG_NO_SUB): renamed from RE_NO_SUB.
151029         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
151030         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
151031         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
151032         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
151033         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
151034         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
151035         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
151036         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
151037         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
151038         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
151039         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
151040         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
151041         RE_SYNTAX_POSIX_MINIMAL_BASIC.
151042         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
151043         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
151044         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
151045         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
151046         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
151047         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
151048         (REG_FIXED): Renamed from REGS_FIXED.
151049         (REG_NREGS): Renamed from RE_NREGS.
151051         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
151052         of other REG_* macros, since POSIX says the user is allowed to
151053         #undef these macros selectively.
151055         (reg_errcode_t): Update comment stating what other tables need
151056         to be consistent.
151058         Rename the following enum values to obey POSIX requirements.
151059         The old names are still visible as macros.
151060         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
151061         is not defined, since GNU is supposed to be a superset of POSIX as
151062         much as possible, and since we want reg_errcode_t to be a signed
151063         type for implementation consistency.
151064         (_REG_NOERROR): Renamed from REG_NOERROR.
151065         (_REG_NOMATCH): Renamed from REG_NOMATCH.
151066         (_REG_BADPAT): Renamed from REG_BADPAT.
151067         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
151068         (_REG_ECTYPE): Renamed from REG_ECTYPE.
151069         (_REG_EESCAPE): Renamed from REG_EESCAPE.
151070         (_REG_ESUBREG): Renamed from REG_ESUBREG.
151071         (_REG_EBRACK): Renamed from REG_EBRACK.
151072         (_REG_EPAREN): Renamed from REG_EPAREN.
151073         (_REG_EBRACE): Renamed from REG_EBRACE.
151074         (_REG_BADBR): Renamed from REG_BADBR.
151075         (_REG_ERANGE): Renamed from REG_ERANGE.
151076         (_REG_ESPACE): Renamed from REG_ESPACE.
151077         (_REG_BADRPT): Renamed from REG_BADRPT.
151078         (_REG_EEND): Renamed from REG_EEND.
151079         (_REG_ESIZE): Renamed from REG_ESIZE.
151080         (_REG_ERPAREN): Renamed from REG_ERPAREN.
151081         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
151082         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
151083         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
151084         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
151086         (_REG_RE_NAME, _REG_RM_NAME): New macros.
151087         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
151088         changed.  But support the old name if the new one is not defined
151089         and if _REGEX_SOURCE.
151091         Change the following member names in struct re_pattern_buffer.
151092         The old names are still supported if !_REGEX_SOURCE.
151093         The new names are always supported, regardless of _REGEX_SOURCE.
151094         (re_buffer): Renamed from buffer.
151095         (re_allocated): Renamed from allocated.
151096         (re_used): Renamed from used.
151097         (re_syntax): Renamed from syntax.
151098         (re_fastmap): Renamed from fastmap.
151099         (re_translate): Renamed from translate.
151100         (re_can_be_null): Renamed from can_be_null.
151101         (re_regs_allocated): Renamed from regs_allocated.
151102         (re_fastmap_accurate): Renamed from fastmap_accurate.
151103         (re_no_sub): Renamed from no_sub.
151104         (re_not_bol): Renamed from not_bol.
151105         (re_not_eol): Renamed from not_eol.
151106         (re_newline_anchor): Renamed from newline_anchor.
151108         Change the following member names in struct re_registers.
151109         The old names are still supported if !_REGEX_SOURCE.
151110         The new names are always supported, regardless of _REGEX_SOURCE.
151111         (rm_num_regs): Renamed from num_regs.
151112         (rm_start): Renamed from start.
151113         (rm_end): Renamed from end.
151115         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
151116         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
151117         Prepend __ to parameter names.
151119         Undo yesterday's changes.
151121 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
151123         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
151124         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
151125         lib/regex.c.
151127 2005-08-24  Jim Meyering  <jim@meyering.net>
151129         Sync from coreutils.
151130         * m4/fcntl-safer.m4: New file.
151132         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
151133         and object files for this module.
151135 2005-08-24  Jim Meyering  <jim@meyering.net>
151137         Sync from coreutils.
151138         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
151140 2005-08-24  Jim Meyering  <jim@meyering.net>
151142         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
151143         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
151145 2005-08-24  Jim Meyering  <jim@meyering.net>
151147         * modules/fcntl-safer: New module.
151148         * modules/fts (Depends-on): Add fcntl-safer.
151149         * MODULES.html.sh (File descriptor based Input/Output):
151150         Add fcntl-safer.
151152 2005-08-24  Bruno Haible  <bruno@clisp.org>
151154         Support for unit test modules.
151155         * modules/README: Mention tests modules.
151156         * modules/TEMPLATE-TESTS: New file.
151157         * gnulib-tool: New options --extract-tests-module, --with-tests and
151158         --tests-base (unused for the moment).
151159         (testsbase, inctests): New variables.
151160         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
151161         (func_verify_module): Exclude TEMPLATE-TESTS.
151162         (func_verify_nontests_module, func_verify_tests_module): New functions.
151163         (func_get_dependencies): Add implicit dependency for tests modules.
151164         (func_get_tests_module): New function.
151165         (func_modules_transitive_closure): When --with-tests was specified,
151166         include the unit tests as well, unless explicitly avoided.
151167         (func_emit_lib_Makefile_am): Ignore the tests modules here.
151168         (func_emit_tests_Makefile_am): New function.
151169         (func_create_testdir): When --with-tests was specified, emit a
151170         tests/ directory.
151171         * MODULES.html.sh (Future developments): Update.
151173 2005-08-24  Bruno Haible  <bruno@clisp.org>
151175         * modules/tls-tests: New file.
151176         * tests/test-tls.c: New file, from GNU gettext.
151178 2005-08-24  Bruno Haible  <bruno@clisp.org>
151180         * modules/lock-tests: New file.
151181         * tests/test-lock.c: New file, from GNU gettext.
151183 2005-08-24  Bruno Haible  <bruno@clisp.org>
151185         * lib/lock.h: Add multiple inclusion guard.
151186         * lib/tls.h: Add multiple inclusion guard.
151188 2005-08-24  Bruno Haible  <bruno@clisp.org>
151190         * gnulib-tool: Add support for the --aux-dir option to
151191         --create-testdir, --create-megatestdir, --test, --megatest.
151192         (func_create_testdir, func_create_megatestdir): Optionally emit a
151193         AC_CONFIG_AUX_DIR directive.
151194         (create-testdir, create-megatestdir, test, megatest): Provide a
151195         default value for $auxdir.
151197 2005-08-24  Bruno Haible  <bruno@clisp.org>
151199         * gnulib-tool (import): Use compound statement instead of subshell
151200         where possible.
151202 2005-08-24  Bruno Haible  <bruno@clisp.org>
151204         * gnulib-tool (import): Change --aux-dir default to "build-aux".
151206 2005-08-24  Bruno Haible  <bruno@clisp.org>
151208         * gnulib-tool (func_version): Update.
151210 2005-08-24  Bruno Haible  <bruno@clisp.org>
151212         * gnulib-tool (func_import, func_create_testdir,
151213         func_create_megatestdir): Quote all autoconf macro arguments.
151215 2005-08-24  Bruno Haible  <bruno@clisp.org>
151217         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
151218         option --force, because --force causes the aclocal.m4 of each
151219         subdirectory to be newer than the corresponding config.h.in.
151221 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
151223         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
151224         All contents moved to gl_REGEX.
151225         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
151226         assume that it does.
151228 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
151230         * lib/regex.h (REG_NOSYS)
151231         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
151232         Define, since POSIX requires it as of 2001.
151233         (_REG_ENOSYS)
151234         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
151235         New private symbol, used to keep the enum signed in all cases.
151236         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
151237         Youngman in
151238         <http://lists.gnu.org/r/bug-gnulib/2005-07/msg00132.html>.
151240         * lib/regex_internal.c (re_string_skip_chars, register_state):
151241         (calc_state_hash):
151242         Remove forward decls; no longer needed now that we use prototypes.
151243         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
151244         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
151245         (clean_state_log_if_needed): Likewise.
151247 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
151249         * config/srclist.txt: Add glibc bugs 1231-1233.
151251 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
151253         Fix problems reported by Sam Steingold in
151254         <http://lists.gnu.org/r/bug-gnulib/2005-08/msg00007.html>.
151255         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
151256         assumed that reg_errcode_t is a signed type, which is not
151257         necessarily true if _XOPEN_SOURCE is not defined.
151258         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
151259         since some compilers warn about it otherwise.
151261 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
151263         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
151264         (init_word_char, create_initial_state, duplicate_node_closure):
151265         (fetch_token, peek_token_bracket, build_range_exp):
151266         (build_collating_symbol): Remove forward decls; no longer needed
151267         now that we use prototypes.
151269         * lib/regcomp.c:
151270         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
151271         (re_compile_fastmap_iter, regcomp, regerror, regfree):
151272         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
151273         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
151274         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
151275         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
151276         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
151277         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
151278         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
151279         (build_range_exp, build_collating_symbol, parse_bracket_exp):
151280         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
151281         (build_charclass, build_charclass_op, fetch_number, create_tree):
151282         (create_token_tree, mark_opt_subexp, duplicate_tree):
151283         Use prototypes rather than old-style definitions.
151285         * lib/regex_internal.c:
151286         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
151287         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
151288         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
151289         (re_string_reconstruct, re_string_peek_byte_case):
151290         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
151291         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
151292         (re_node_set_init_copy, re_node_set_add_intersect):
151293         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
151294         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
151295         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
151296         (re_acquire_state, re_acquire_state_context, register_state):
151297         (create_ci_newstate, create_cd_newstate, free_state):
151298         Likewise.
151299         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
151300         re_search_2):
151301         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
151302         (re_search_internal, prune_impossible_nodes):
151303         (acquire_init_state_context, check_matching, static):
151304         (check_halt_node_context, check_halt_state_context, proceed_next_node):
151305         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
151306         (update_regs, sift_states_backward, build_sifted_states):
151307         (clean_state_log_if_needed, merge_state_array):
151308         (update_cur_sifted_state, add_epsilon_src_nodes):
151309         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
151310         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
151311         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
151312         (find_recover_state, check_subexp_matching_top, transit_state_mb):
151313         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
151314         (check_arrival, check_arrival_add_next_nodes):
151315         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
151316         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
151317         (check_node_accept_bytes, check_node_accept, extend_buffers):
151318         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
151319         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
151320         (sift_ctx_init):
151321         Likewise.
151323         * lib/regex_internal.h:
151324         (re_string_allocate, re_string_construct, re_string_reconstruct):
151325         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
151326         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
151327         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
151328         (re_string_context_at, re_string_peek_byte_case):
151329         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
151330         is defined, since we now use prototypes always.
151332         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
151333         C89 or better.  All uses removed.
151335 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
151337         * config/srclist.txt: Add glibc bugs 1220-1227.
151339 2005-08-20  Jim Meyering  <jim@meyering.net>
151341         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
151342         of unused local, dfa.
151344 2005-08-20  Bruno Haible  <bruno@clisp.org>
151346         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
151348 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
151350         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
151351         (re_node_set_insert_last, re_dfa_add_node):
151352         Rename local variables to avoid GCC shadowing warnings.
151354 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
151356         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
151357         [defined lint]: Suppress bogus uninitialized-variable warnings.
151359         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
151360         and let the caller return REG_ESPACE if out of space.  This
151361         removes an uninitialied-variable warning with GCC 4.0.1, and also
151362         avoids taking the address of a local variable.  All callers
151363         changed.
151365 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
151367         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
151368         $LIBCSRC/posix/regexec.c.
151369         Add glibc bug 1217 for regcomp.c.
151371 2005-08-19  Jim Meyering  <jim@meyering.net>
151373         * lib/regexec.c (proceed_next_node): Redo local variables to
151374         avoid GCC shadowing warnings.
151376 2005-08-18  Bruno Haible  <bruno@clisp.org>
151378         * lib/strstr.c (strstr): Fix return value in multibyte case.
151379         * lib/strcasestr.c (strcasestr): Likewise.
151381 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
151383         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
151385 2005-08-17  Jim Meyering  <jim@meyering.net>
151387         Make the %s format (seconds since the epoch) work for a negative
151388         number and when used with a zero-padded field width, e.g. %015s.
151390         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
151391         label so that it precedes the code to set `digits'.  Otherwise,
151392         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
151393         print `00-22'.  Now, it prints `-0022', as it should.
151395 2005-08-17  Bruno Haible  <bruno@clisp.org>
151397         * modules/strstr (Files): Add m4/mbrtowc.m4.
151398         (Depends-on): Add mbuiter.
151400 2005-08-17  Bruno Haible  <bruno@clisp.org>
151402         * modules/strcasestr: New file.
151403         * MODULES.html.sh (String handling, based on ANSI C 89): Add
151404         strcasestr.
151406 2005-08-17  Bruno Haible  <bruno@clisp.org>
151408         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
151410 2005-08-17  Bruno Haible  <bruno@clisp.org>
151412         * modules/mbuiter: New file.
151413         * MODULES.html.sh (Extended multibyte and wide character utilities):
151414         Add mbuiter.
151416 2005-08-17  Bruno Haible  <bruno@clisp.org>
151418         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
151419         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
151421 2005-08-17  Bruno Haible  <bruno@clisp.org>
151423         * m4/strcasestr.m4: New file.
151425 2005-08-17  Bruno Haible  <bruno@clisp.org>
151427         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
151428         * lib/strstr.c: Completely rewritten, with multibyte locale support.
151430 2005-08-17  Bruno Haible  <bruno@clisp.org>
151432         * lib/strcasestr.h: New file.
151433         * lib/strcasestr.c: New file.
151435 2005-08-17  Bruno Haible  <bruno@clisp.org>
151437         * lib/strcasecmp.c: Use mbuiter.h.
151439 2005-08-17  Bruno Haible  <bruno@clisp.org>
151441         * lib/mbuiter.h: New file.
151443 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
151445         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
151446         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
151447         and gl_GETOPT are both invoked via different paths (as happens
151448         with GNU tar CVS because it uses both argp and getopt), the former
151449         wins.
151451 2005-08-16  Bruno Haible  <bruno@clisp.org>
151453         * modules/tls: New file.
151454         * MODULES.html.sh (Multithreading): Add tls.
151456 2005-08-16  Bruno Haible  <bruno@clisp.org>
151458         * modules/strnlen1: New file.
151459         * MODULES.html.sh (String handling): Add strnlen1.
151461 2005-08-16  Bruno Haible  <bruno@clisp.org>
151463         * modules/strcase (Files): Add m4/mbrtowc.m4.
151464         (Depends-on): Add strnlen1, mbchar.
151466 2005-08-16  Bruno Haible  <bruno@clisp.org>
151468         * modules/mbiter: New file.
151469         * MODULES.html.sh (Extended multibyte and wide character utilities):
151470         Add mbiter.
151472 2005-08-16  Bruno Haible  <bruno@clisp.org>
151474         * modules/mbfile: New file.
151475         * MODULES.html.sh (Extended multibyte and wide character utilities):
151476         Add mbfile.
151478 2005-08-16  Bruno Haible  <bruno@clisp.org>
151480         * modules/mbchar: New file.
151481         * MODULES.html.sh (Extended multibyte and wide character utilities):
151482         New section.
151484 2005-08-16  Bruno Haible  <bruno@clisp.org>
151486         * m4/tls.m4: New file, from GNU gettext.
151488 2005-08-16  Bruno Haible  <bruno@clisp.org>
151490         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
151491         always.
151492         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
151494 2005-08-16  Bruno Haible  <bruno@clisp.org>
151496         * m4/mbiter.m4: New file.
151498 2005-08-16  Bruno Haible  <bruno@clisp.org>
151500         * m4/mbfile.m4: New file.
151502 2005-08-16  Bruno Haible  <bruno@clisp.org>
151504         * m4/mbchar.m4: New file.
151506 2005-08-16  Bruno Haible  <bruno@clisp.org>
151508         * lib/tls.h: New file, from GNU gettext.
151509         * lib/tls.c: New file, from GNU gettext.
151511 2005-08-16  Bruno Haible  <bruno@clisp.org>
151513         * lib/strnlen1.h: New file.
151514         * lib/strnlen1.c: New file.
151516 2005-08-16  Bruno Haible  <bruno@clisp.org>
151518         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
151519         (mbi_init): Update.
151520         (mbi_avail, mbi_advance): Let the iteration end before the terminating
151521         NUL byte, not after it.
151523 2005-08-16  Bruno Haible  <bruno@clisp.org>
151525         * lib/strcase.h (strcasecmp): Add note in comments.
151526         * lib/strncasecmp.c: Use code from strcasecmp.c.
151527         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
151528         (strcasecmp): Work correctly in multibyte locales.
151530 2005-08-16  Bruno Haible  <bruno@clisp.org>
151532         * lib/mbiter.h: New file.
151534 2005-08-16  Bruno Haible  <bruno@clisp.org>
151536         * lib/mbfile.h: New file.
151538 2005-08-16  Bruno Haible  <bruno@clisp.org>
151540         * lib/mbchar.h: New file.
151541         * lib/mbchar.c: New file.
151543 2005-08-16  Bruno Haible  <bruno@clisp.org>
151545         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
151546         the valid ones. Makes the comparison operations transitive:
151547         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
151548         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
151550 2005-08-15  Simon Josefsson  <jas@extundo.com>
151552         * modules/ssize_t (License): Change to 'unlimited'.
151554         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
151556 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
151558         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
151559         Add comments for each pending glibc patch.
151561 2005-08-15  Bruno Haible  <bruno@clisp.org>
151563         * lib/regex.h (__restrict_arr): Don't define to __restrict if
151564         __cplusplus is defined.
151566 2005-08-14  Jim Meyering  <jim@meyering.net>
151568         Sync from coreutils.
151570         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
151571         Use the hash-table-based cycle-detection code not just when
151572         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
151573         Reported by James Youngman in
151574         <http://lists.gnu.org/r/bug-gnulib/2005-08/msg00011.html>.
151575         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
151576         FTS_TIGHT_CYCLE_CHECK.
151577         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
151578         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
151579         once again.
151580         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
151581         * lib/fts.c (fd_safer): Remove decl.
151582         Include fcntl--.h rather than unistd-safer.h
151583         (fts_safe_changedir): Don't call fd_safer; no longer needed
151584         now that we include fcntl--.h.
151586 2005-08-12  Simon Josefsson  <jas@extundo.com>
151588         * modules/getndelim2: Use ssize_t module.
151589         * modules/getnline: Likewise.
151590         * modules/safe-read: Likewise.
151591         * modules/xreadlink: Likewise.
151593         * modules/ssize_t: New file.
151595 2005-08-12  Simon Josefsson  <jas@extundo.com>
151597         * m4/readline.m4: Look for termcap, curses or ncurses if required.
151599 2005-08-12  Simon Josefsson  <jas@extundo.com>
151601         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
151602         ssize_t.
151604 2005-08-12  Simon Josefsson  <jas@extundo.com>
151606         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
151607         readline, getdelim and check_version.
151608         (Support for systems lacking ISO C 99: Sizes of integer types):
151609         Add size_max.
151611 2005-08-12  Bruno Haible  <bruno@clisp.org>
151613         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
151615 2005-08-11  Simon Josefsson  <jas@extundo.com>
151617         * modules/readline: New file.
151619         * modules/strnlen (Files): Add strnlen.h.
151621 2005-08-11  Simon Josefsson  <jas@extundo.com>
151623         * m4/readline.m4: New file.
151625 2005-08-11  Simon Josefsson  <jas@extundo.com>
151627         * lib/readline.h, readline.c: New file.
151629 2005-08-11  Simon Josefsson  <jas@extundo.com>
151631         * doc/gnulib.texi (Initial import, Finishing touches): Mention
151632         gl_AVOID.
151634 2005-08-11  Bruno Haible  <bruno@clisp.org>
151636         * lib/strnlen.h (strnlen): Change parameter name to match comment.
151638 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
151640         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
151642 2005-08-10  Simon Josefsson  <jas@extundo.com>
151644         * tests/test-iconvme.c: New file.
151646 2005-08-10  Simon Josefsson  <jas@extundo.com>
151648         * m4/strnlen.m4: New file.
151650         * m4/strndup.m4: Don't check for strnlen declaration, done in
151651         strnlen.m4.
151653 2005-08-10  Simon Josefsson  <jas@extundo.com>
151655         * lib/strndup.c: Use strnlen.h.
151657         * lib/strnlen.h: New file.
151659 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
151661         * README: Typos.
151663 2005-08-02  Simon Josefsson  <jas@extundo.com>
151665         * modules/readline: New file.
151667 2005-08-02  Simon Josefsson  <jas@extundo.com>
151669         * modules/getdelim: New file.
151671         * modules/getline: Rewrite, don't use getndelim2.
151673 2005-08-02  Simon Josefsson  <jas@extundo.com>
151675         * m4/getline.m4: Separate out getdelim stuff into separate module.
151677         * m4/getdelim.m4: New file.
151679 2005-08-02  Simon Josefsson  <jas@extundo.com>
151681         * lib/getline.h, getline.c: Rewrite.
151683         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
151685 2005-07-31  Bruno Haible  <bruno@clisp.org>
151687         * lib/lock.h (gl_lock_initializer): New macro.
151688         (gl_lock_define_initialized): Use it.
151689         (gl_rwlock_initializer): New macro.
151690         (gl_rwlock_define_initialized): Use it.
151691         (gl_recursive_lock_initializer): New macro.
151692         (gl_recursive_lock_define_initialized): Use it.
151694 2005-07-30  Karl Berry  <karl@gnu.org>
151696         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
151697         Report from Ben Pfaff, regarding getopt.
151699 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
151701         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
151702         normal way.
151703         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
151704         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
151705         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
151706         (gl_GETOPT): Use the new macros.  Most of the implementation
151707         is moved to the new macros.  This is for programs like Emacs
151708         that don't want all the functionality of gl_GETOPT.
151710 2005-07-26  Bruno Haible  <bruno@clisp.org>
151712         * m4/lock.m4: Update from GNU gettext.
151714 2005-07-26  Bruno Haible  <bruno@clisp.org>
151716         * lib/lock.h: Update from GNU gettext.
151717         * lib/lock.c: Update from GNU gettext.
151719 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
151721         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
151722         obsolescent AC_TRY_RUN.  Include the default includes files, for
151723         'exit'.
151725 2005-07-24  Bruno Haible  <bruno@clisp.org>
151727         * modules/visibility: New file.
151728         * MODULES.html.sh (Misc): Add visibility.
151730 2005-07-24  Bruno Haible  <bruno@clisp.org>
151732         * m4/visibility.m4: New file.
151734 2005-07-24  Bruno Haible  <bruno@clisp.org>
151736         * doc/visibility.texi: New file.
151738 2005-07-22  Bruno Haible  <bruno@clisp.org>
151740         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
151741         $(ALLOCA_H), redundant through BUILT_SOURCES.
151742         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
151743         redundant through BUILT_SOURCES.
151744         * modules/byteswap (Makefile.am): Remove explicit dependency on
151745         $(BYTESWAP_H), redundant through BUILT_SOURCES.
151746         * modules/fnmatch (Makefile.am): Remove explicit dependency on
151747         $(FNMATCH_H), redundant through BUILT_SOURCES.
151748         * modules/getopt (Makefile.am): Remove explicit dependency on
151749         $(GETOPT_H), redundant through BUILT_SOURCES.
151750         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
151751         redundant through BUILT_SOURCES.
151752         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
151753         redundant through BUILT_SOURCES.
151754         * modules/stdbool (Makefile.am): Remove explicit dependency on
151755         $(STDBOOL_H), redundant through BUILT_SOURCES.
151756         * modules/stdint (Makefile.am): Remove explicit dependency on
151757         $(STDINT_H), redundant through BUILT_SOURCES.
151758         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
151759         Remove explicit dependency on $(SYSEXITS_H).
151760         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
151762 2005-07-18  Simon Josefsson  <jas@extundo.com>
151764         * lib/check-version.c (check_version): Accept identical versions too.
151766 2005-07-18  Bruno Haible  <bruno@clisp.org>
151768         * modules/lock: New file.
151769         * MODULES.html.sh (Multithreading): New section.
151771 2005-07-18  Bruno Haible  <bruno@clisp.org>
151773         * m4/lock.m4: New file, from GNU gettext.
151775 2005-07-18  Bruno Haible  <bruno@clisp.org>
151777         * lib/lock.h: New file, from GNU gettext.
151778         * lib/lock.c: New file, from GNU gettext.
151780 2005-07-18  Bruno Haible  <bruno@clisp.org>
151782         * lib/lock.h (gl_once_t): New type.
151783         (gl_once_define, gl_once): New macros.
151784         * lib/lock.c (fresh_once): New variable.
151785         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
151786         functions.
151788 2005-07-16  Simon Josefsson  <jas@extundo.com>
151790         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
151791         workaround, suggested by Bruno.
151793 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
151795         * modules/xalloc (Depends-on): Add xalloc-die.
151796         * modules/xvasprintf (Depends-on): Add xalloc-die.
151798 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
151800         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
151801         with a minor change.
151803 2005-07-15  Bruno Haible  <bruno@clisp.org>
151805         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
151806         When using lib/poll.c, define poll as rpl_poll.
151808 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
151810         * modules/argp (Depends-on): Remove unlocked-io.
151812 2005-07-14  Derek Price  <derek@ximbiot.com>
151814         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
151815         for glob symlink bug.
151817 2005-07-14  Bruno Haible  <bruno@clisp.org>
151819         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
151820         Instead, test for *_unlocked function declarations directly.
151822 2005-07-11  Simon Josefsson  <jas@extundo.com>
151824         * modules/size_max: New file.
151826         * modules/xsize: Depend on size_max module for size_max.m4.
151828 2005-07-11  Simon Josefsson  <jas@extundo.com>
151830         * lib/size_max.h: New file.
151832 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
151834         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
151835         copyright symbol and the year.
151836         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
151837         (version_etc_va): Use parameterized copyright notice.
151838         Reword to conform to the current GNU coding standards.
151840 2005-07-11  Karl Berry  <karl@gnu.org>
151842         * doc/gnulib.texi (Quoting): new node.
151843         (Initial import): more info, from Patrice.
151845 2005-07-11  Bruno Haible  <bruno@clisp.org>
151847         * gnulib-tool (func_usage): Document option --avoid.
151848         (Command line options): Handle --avoid.
151849         (func_acceptable): New function.
151850         (func_modules_transitive_closure): Use it.
151852 2005-07-11  Bruno Haible  <bruno@clisp.org>
151854         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
151855         Reported by Jim Meyering.
151857 2005-07-10  Bruno Haible  <bruno@clisp.org>
151859         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
151860         Needed when size_t is smaller than 'unsigned int'.
151861         Reported by Paul Eggert.
151863 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
151865         * modules/argp (Depends-on): Add unlocked-io
151867 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
151869         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
151870         block of defines.
151872 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
151874         * config/srclist.txt: Comment out regcomp.c, since we have a porting
151875         fix now.
151877 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
151878         and Paul Eggert  <eggert@cs.ucla.edu>
151880         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
151881         in wint_t, not wchar_t.  Remove now-unnecessary cast.
151883 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
151885         * modules/regex (Files): Add lib/regex_internal.c,
151886         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
151887         (Depends-on): Add extensions.
151888         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
151890 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
151892         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
151893         pathconf.
151894         * m4/same.m4 (gl_SAME): Likewise.
151895         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
151897         * m4/regex.m4: Adjust to new libc regex implementation.
151898         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
151899         all the .c and .h parts of (the new) regex.
151900         Quote the m4 stuff better.
151901         Check for RE_ICASE bug of old gnulib.
151902         Check for REG_STARTEND of recent libc.
151903         Rename local variables from jm_* to gl_*.
151904         Quote operand of "test -f".
151905         Say "recent enough" version of libc, not "version 2".
151906         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
151907         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
151908         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
151909         Remove check for btowc, isascii.
151910         Require AM_LANGINFO_CODESET.
151912 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
151914         * lib/regex.c, regex.h: Sync from libc.
151915         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
151916         * lib/regexec.c:
151917         New files, synced from libc, except that regex_internal.h
151918         currently has a small porting fix.
151920 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
151922         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
151923         regex_internal.c, regexec.c.
151924         Add regex_internal.h too, but as a comment, since the libc version
151925         is currently broken in gnulib mode.
151927 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
151929         Support programs like Emacs that use gnulib but not gettext.
151930         * MODULES.html.sh (Internationalization functions): Add gettext-h.
151931         * modules/gettext-h: New file.
151932         * modules/gettext (Files): Remove lib/gettext.h.
151933         (Depends-on): Add gettext-h.
151934         (Makefile.am): Remove lib_SOURCES.
151935         * modules/argmatch, modules/c-stack, modules/closeout:
151936         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
151937         * modules/execute, modules/file-type, modules/getaddrinfo:
151938         * modules/getopt, modules/human, modules/javacomp:
151939         * modules/javaexec, modules/mkdir-p, modules/obstack:
151940         * modules/openat, modules/pagealign_alloc, modules/pipe:
151941         * modules/quotearg, modules/regex, modules/rpmatch:
151942         * modules/unicodeio, modules/userspec, modules/version-etc:
151943         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
151944         * modules/xsetenv:
151945         Depend on gettext-h, not gettext.
151947 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
151949         * gnulib-tool (func_import): Add support for 'public domain' license.
151950         * modules/alloca, modules/atexit, modules/memmove:
151951         Now public domain, not GPL.
151952         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
151953         * modules/realloc, modules/strerror, modules/strtod:
151954         Now LGPL, not GPL.
151956 2005-07-05  Bruno Haible  <bruno@clisp.org>
151958         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
151959         autoconf CVS. Needed for mingw.
151961 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
151963         Remove the dependency of the strftime module on the tzset module.
151964         * modules/strftime (Depends-on): Remove dependency on tzset.
151966 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
151968         Remove the dependency of the strftime module on the tzset module.
151969         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
151970         gl_FUNC_TZSET_CLOBBER.
151972 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
151974         Remove the dependency of the strftime module on the tzset module.
151975         * lib/strftime.c (my_strftime)
151976         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
151977         Copy the input structure, to work around some of the bug with
151978         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
151979         Solaris releases, you should also use the tzset module, but we won't
151980         require it as a dependency any more since we don't want LGPLed code
151981         to depend on GPLed code.
151983 2005-07-02  Jim Meyering  <jim@meyering.net>
151985         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
151986         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
151987         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
151988         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
151990 2005-07-02  Jim Meyering  <jim@meyering.net>
151992         * lib/backupfile.c (backup_args): Change a `0' to NULL.
151994 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
151996         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
151997         declares only 'struct timespec;' (!).
151999 2005-07-01  Jim Meyering  <jim@meyering.net>
152001         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
152002         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
152003         * lib/save-cwd.c, tempname.c:
152004         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
152005         and don't include <sys/file.h>).
152007 2005-06-29  Jim Meyering  <jim@meyering.net>
152009         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
152010         type name.  Use the variable name instead.
152011         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
152012         Likewise.
152014 2005-06-28  Simon Josefsson  <jas@extundo.com>
152016         * modules/check-version (Files): Add check-version.m4.
152018 2005-06-28  Simon Josefsson  <jas@extundo.com>
152020         * m4/check-version.m4: New file, suggested by Jim Meyering
152021         <jim@meyering.net>.
152023 2005-06-28  Simon Josefsson  <jas@extundo.com>
152025         * lib/check-version.h, lib/check-version.c: New files.
152027 2005-06-28  Simon Josefsson  <jas@extundo.com>
152029         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
152030         collision with global variable.  Better indentation.  Don't
152031         increment buffer pointer beyond buffer end.  Based on comments
152032         from Paul Eggert <eggert@cs.ucla.edu>.
152034         * lib/base64.h: Indent.
152036 2005-06-28  Simon Josefsson  <jas@extundo.com>
152038         * doc/gnulib.texi (Library version handling): New section.
152040 2005-06-28  Jim Meyering  <jim@meyering.net>
152042         * check-module (find_included_lib_files): Hard-code another
152043         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
152044         but modules/fts-lgpl (correctly) does not list those files.
152046         * modules/canonicalize (Files): Add lib/pathmax.h.
152048 2005-06-25  Simon Josefsson  <jas@extundo.com>
152050         * modules/check-version: New file.
152052 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
152054         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
152055         initializer of struct addrinfo, as an indication that we don't
152056         care how many members the structure has.
152058 2005-06-24  Derek Price  <derek@ximbiot.com>
152059         and Bruno Haible  <bruno@clisp.org>
152061         Remove stat module & update lstat.
152062         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
152063         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
152064         * m4/stat.m4: Remove this file.
152066 2005-06-24  Derek Price  <derek@ximbiot.com>
152067         and Bruno Haible  <bruno@clisp.org>
152069         Remove stat module & update lstat.
152070         * lib/stat.c: Remove this file...
152071         (slash_aware_lstat): ...moving this content and its support...
152072         * lib/lstat.c (rpl_lstat): ...into here.
152073         * lib/lstat.h: New file.
152075 2005-06-24  Derek Price  <derek@ximbiot.com>
152076         and Bruno Haible  <bruno@clisp.org>
152078         Remove stat module & update lstat.
152079         * config/srclist.txt (libc sources): Remove stat.
152081 2005-06-24  Derek Price  <derek@ximbiot.com>
152082         and Bruno Haible  <bruno@clisp.org>
152084         Remove stat module & update lstat.
152085         * MODULES.html.sh (stat): Remove.
152086         * MODULES.html: Regenerated.
152087         * modules/lstat (Description): Correct function name.
152088         (Files): Add "lstat.h".
152089         (Depends-on): Remove stat, add xalloc, stat-macros.
152090         * modules/stat: Remove this file.
152091         (Include): Add "lstat.h", remove <sys/stat.h>.
152093 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
152095         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
152096         (ranged_convert): Don't save conversion in a temporary struct.
152097         This causes a warning with GCC 4.0.0, and anyway in the typical
152098         case it's not worth the extra 100 bytes or so of code.
152099         (ranged_convert, __mktime_internal): When calling a function via a
152100         pointer P, use P () rather than (*P) (), as we now assume C89 or
152101         better.
152103 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
152105         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
152106         "who -r" failed to give output.  Problem reported by Tim Waugh.
152108         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
152109         (xcalloc): Use it to avoid needless tests.
152110         Problem reported by Jim Meyering.
152112 2005-06-20  Derek Price  <derek@ximbiot.com>
152114         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
152115         unnecessary for Autoconfs > 2.59c.
152117 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
152119         * lib/argp.h (__option_is_short): Check upper limit of
152120         __key. Isprint() requires its argument to have the value
152121         of an unsigned char or EOF.
152123 2005-06-16  Jim Meyering  <jim@meyering.net>
152125         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
152126         when either N or S is zero.
152128 2005-06-16  Derek Price  <derek@ximbiot.com>
152130         * m4/bison.m4: Declare YACC & YFLAGS precious.
152132 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
152134         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
152135         multibyte string or pattern, fall back on unibyte matching.
152136         Problem reported by James Youngman.
152138 2005-06-08  Bruno Haible  <bruno@clisp.org>
152140         * modules/csharpcomp: New file.
152141         * MODULES.html.sh (C#): Add csharpcomp.
152143 2005-06-08  Bruno Haible  <bruno@clisp.org>
152145         * m4/csharpcomp.m4: New file, from GNU gettext.
152147 2005-06-08  Bruno Haible  <bruno@clisp.org>
152149         * lib/csharpcomp.h: New file, from GNU gettext.
152150         * lib/csharpcomp.c: New file, from GNU gettext.
152151         * lib/csharpcomp.sh.in: New file, from GNU gettext.
152153 2005-06-08  Bruno Haible  <bruno@clisp.org>
152155         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
152156         warning on mingw.
152158 2005-06-07  Derek Price  <derek@ximbiot.com>
152160         Sync from CVS.
152161         * lib/glob_.h: Indent nested #ifdef.
152163 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
152165         Sync from coreutils.
152166         Use "file name" when talking about file names, instead of "filename"
152167         or "path", as per the GNU coding standards.
152168         * lib/mkdir-p.c: Renamed from makepath.c.
152169         (make_dir_parents): Renamed from make_path.  All callers changed.
152170         * lib/mkdir-p.h: Likewise.  All includers changed.
152171         * lib/filenamecat.c: Renamed from path-concat.c.
152172         (file_name_concat): Renamed from path_concat.  All callers changed.
152173         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
152174         * lib/filenamecat.h: Likewise.  All includers changed.
152175         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
152176         in comments or local variable names.
152177         * lib/basename.c: Likewise.
152178         * lib/canonicalize.c, canonicalize.h: Likewise.
152179         * lib/dirname.c, dirname.h: Likewise.
152180         * lib/euidaccess.c: Likewise.
152181         * lib/exclude.c: Likewise
152182         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
152183         * lib/fsusage.c, fsuage.h: Likewise.
152184         * lib/fts.c, fts_.h: Likewise.
152185         * lib/getcwd.c: Likewise.
152186         * lib/getloadavg.c: Likewise.
152187         * lib/mkstemp.c: Likewise.
152188         * lib/mountlist.c, mountlist.h: Likewise.
152189         * lib/openat.c, openat.h: Likewise.
152190         * lib/readlink-stub.c: Likewise.
152191         * lib/readutmp.c, readutmp.h: Likewise.
152192         * lib/rename.c: Likewise.
152193         * lib/rmdir.c: Likewise.
152194         * lib/same.c: Likewise.
152195         * lib/savedir.c: Likewise.
152196         * lib/stripslash.c: Likewise.
152197         * lib/tempname.c: Likewise.
152198         * lib/xreadlink.c: Likewise.
152199         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
152200         All uses changed.
152201         * lib/exclude.h: Likewise.
152203         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
152204         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
152205         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
152206         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
152207         * lib/pathmax.h: Include <limits.h> unconditionally, since other
152208         files have been getting away with it for years (MORE/BSD 4.3
152209         is extinct now).
152210         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
152211         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
152213         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
152214         Define to 256, not 255, as per modern POSIX.
152216 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
152218         Sync from coreutils.
152219         Use "file name" when talking about file names, instead of "filename"
152220         or "path", as per the GNU coding standards.
152221         * MODULES.html.sh: mkdir-p renamed from makepath.
152222         filenamecat renamed from path-concat.
152223         * modules/filenamecat: Renamed from modules/path-concat.
152224         (Files): filenamecat.h and filenamecat.c renamed from
152225         path-concat.h and path-concat.c.
152226         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
152227         (Include): filenamecat.h, not path-concat.h.
152228         * modules/mkdir-p: Renamed from modules/makepath.
152229         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
152230         makepath.c.
152231         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
152232         (Include): mkdir-p.h, not makepath.h.
152234 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
152236         Sync from coreutils.
152237         * m4/mkdir-p.m4: Renamed from makepath.m4.
152238         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
152239         Rename files from makepath.c to mkdir-p.c, and from
152240         makepath.h to mkdir-p.h.
152241         * m4/filenamecat.m4: Renamed from path-concat.m4.
152242         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
152243         Rename files from path-concat.c to filenamecat.c,
152244         and from path-concat.h to filenamecat.h.
152245         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
152246         "file name" in local variables or comments.
152247         * m4/rename.m4: Likewise.
152249 2005-06-01  Bruno Haible  <bruno@clisp.org>
152251         * modules/csharpexec: New file.
152252         * MODULES.html.sh (C#): New section.
152254 2005-06-01  Bruno Haible  <bruno@clisp.org>
152256         * m4/csharp.m4: New file, from GNU gettext.
152257         * m4/csharpexec.m4: New file, from GNU gettext.
152259 2005-06-01  Bruno Haible  <bruno@clisp.org>
152261         * lib/csharpexec.h: New file, from GNU gettext.
152262         * lib/csharpexec.c: New file, from GNU gettext.
152263         * lib/csharpexec.sh.in: New file, from GNU gettext.
152265 2005-05-31  Derek Price  <derek@ximbiot.com>
152266             Paul Eggert  <eggert@cs.ucla.edu>
152268         Sync from cvs.
152269         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
152271 2005-05-31  Derek Price  <derek@ximbiot.com>
152272             Paul Eggert  <eggert@cs.ucla.edu>
152274         Sync from cvs.
152275         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
152277 2005-05-29  Derek Price  <derek@ximbiot.com>
152279         * config/srclist.txt (glob_.h, glob.c): Add these files.
152281 2005-05-29  Derek Price  <derek@ximbiot.com>
152283         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
152284         * modules/glob: New file.
152285         * modules/getlogin_r: Add link to POSIX spec in description.
152287 2005-05-29  Derek Price  <derek@ximbiot.com>
152288             Paul Eggert  <eggert@cs.ucla.edu>
152290         * m4/glob.m4: New file.
152292 2005-05-29  Derek Price  <derek@ximbiot.com>
152293             Paul Eggert  <eggert@cs.ucla.edu>
152295         * lib/glob_.h, lib/glob.c: New files.
152297 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
152299         * modules/fts (Files): Remove m4/inttypes-pri.m4.
152300         * modules/fts-lgpl (Depends-on): Remove gettext.
152302 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
152304         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
152305         and don't require gt_INTTYPES_PRI.
152307 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
152309         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
152311         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
152312         the configuration hassle isn't worth it.
152313         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
152314         (LONGEST_MODIFIER, PRIuMAX): Remove.
152316 2005-05-27  Bruno Haible  <bruno@clisp.org>
152318         * lib/getlogin_r.h: Remove second include of <stddef.h>.
152320 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
152322         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
152323         _POSIX_PTHREAD_SEMANTICS for Solaris.
152325 2005-05-25  Derek Price  <derek@ximbiot.com>
152327         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
152329 2005-05-25  Derek Price  <derek@ximbiot.com>
152330             Paul Eggert  <eggert@cs.ucla.edu>
152332         * modules/getlogin_r, m4/getlogin_r.m4: New files.
152333         * lib/getlogin_r.c, getlogin_r.h: New files.
152335 2005-05-25  Bruno Haible  <bruno@clisp.org>
152336             Derek Price  <derek@ximbiot.com>
152338         * lib/getlogin_r.h: Simplify API documentation.
152340 2005-05-23  Derek Price  <derek@ximbiot.com>
152342         * modules/minmax (Files): Add m4/minmax.m4.
152343         (configure.ac): Add gl_MINMAX.
152345 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
152347         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
152348         so that unistd-safer.h (GPL'ed code) need not be included.
152350 2005-05-22  Bruno Haible  <bruno@clisp.org>
152352         * m4/minmax.m4: New file.
152353         Based on a patch by Derek Price <derek@ximbiot.com>.
152355 2005-05-22  Bruno Haible  <bruno@clisp.org>
152357         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
152358         (INT64_MIN): Fix definition.
152359         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
152361         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
152362         NEED_SIGNED_INT_TYPES.
152364         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
152365         HAVE_SYSTEM_INTTYPES.
152367 2005-05-22  Bruno Haible  <bruno@clisp.org>
152369         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
152370         Also include <sys/param.h> if it defines MIN, MAX.
152371         Based on a patch by Derek Price <derek@ximbiot.com>.
152373 2005-05-21  Jim Meyering  <jim@meyering.net>
152375         * modules/fts (Files): Add m4/inttypes-pri.m4.
152376         (Depends-on): Add lstat and remove gettext.  Alphabetize.
152378 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
152380         New fts module.
152381         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
152382         (setup_dir, free_dir): New functions.
152383         (enter_dir, leave_dir): Define trivial
152384         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
152385         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
152386         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
152387         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
152388         Move to fts-cycle.c.
152389         (fts_open): Use setup_dir.
152390         (fts_close): Use free_dir.
152391         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
152392         This adds a label and some gotos, but the alternatives were messier.
152393         Check for memory allocation failure when entering a dir.
152394         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
152395         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
152396         (FTS): New member fts_cycle, that is a union that contains the
152397         old active_dir_ht and cycle_state.  All uses changed to mention
152398         fts_cycle.ht and fts_cycle.state.
152399         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
152400         fts.c, with the following changes:
152401         (setup_dir, free_dir): New functions.
152402         (enter_dir): Now returns bool.  Return true if successful, false
152403         if memory exhausted.  All callers changed.
152404         Do not bother partly cleaning up on
152405         memory allocation failure; that is free_dir's job.
152406         However, free ad if hash_insert fails, to avoid memory leak.
152407         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
152408         fts->fts_options to see which union member to use.
152410 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
152412         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
152413         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
152415 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
152417         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
152419 2005-05-20  Jim Meyering  <jim@meyering.net>
152421         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
152422         Now a macro, to pacify GCC.
152424 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
152426         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
152427         of -1.
152429 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
152431         * lib/chown.c (rpl_chown): Return -1 on failure.
152433 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
152435         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
152436         Don't check for stddef.h.
152437         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
152438         don't use its results.
152439         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
152440         since we include them unconditionally.  Don't require
152441         AM_STDBOOL_H, since stdbool is a prerequisite.
152442         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
152443         since we assume C89 or better.
152444         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
152445         as we don't use their results.
152446         Don't check for fchdir, memmove, memset, strrchr, as we use
152447         them unconditionally.
152448         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
152449         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
152451 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
152453         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
152454         Include <stddef.h> unconditionally, since we assume C89 now.
152455         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
152456         * lib/fts.c: Include fts_.h first, to check interface.
152457         Do not include intprops.h; no longer needed.
152458         Include cycle-check.h and hash.h, since fts_.h no longer does.
152459         Remove unnecessary casts of closedir to void.
152460         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
152461         decide whether to decrement nlinks.
152462         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
152463         (FTS): Use struct hash_table * instead of Hash_table, so that
152464         we no longer need to include hash.h here.
152466 2005-05-18  Jim Meyering  <jim@meyering.net>
152468         * modules/dirfd (License): Change to LGPL.  Most of the code
152469         is already in the public domain.
152471 2005-05-18  Jim Meyering  <jim@meyering.net>
152473         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
152474         Reported by Yoann Vandoorselaere.
152476 2005-05-17  Jim Meyering  <jim@meyering.net>
152478         * m4/fts.m4: New file, from coreutils.
152480 2005-05-17  Jim Meyering  <jim@meyering.net>
152482         * lib/fts.c, lib/fts_.h: New files, from coreutils.
152484 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
152486         Sync from coreutils.
152487         * m4/unlinkdir.m4: New file.
152489 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
152491         Sync from coreutils.
152492         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
152493         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
152494         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
152495         White space changes only.
152496         * lib/makepath.c (make_path): Port to hosts where leading "//" is
152497         special.
152498         * lib/yesno.c: Include getline.h, not ctype.h.
152499         (yesno): Don't remove leading white space; POSIX doesn't allow it.
152500         Use getline to remove arbitrary restriction on response length.
152502 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
152504         * config/srclist-update: Spell out "Street" in FSF postal
152505         mail address; this is the style the FSF seems to prefer.
152507         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
152508         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
152509         this updates FSF postal mail address.
152511         Sync from coreutils.
152512         * modules/unlinkdir: New file.
152513         * modules/yesno (Depends-on): Add getline.
152514         * MODULES.html.sh (File system functions): Add unlinkdir.
152516 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
152518         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
152519         lib/strsep.h:
152520         Change the initial comment to refer to GPL, not LGPL.
152521         gnulib-tool will change it to LGPL as needed.
152523         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
152524         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
152525         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
152526         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
152527         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
152528         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
152529         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
152530         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
152531         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
152532         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
152533         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
152534         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
152535         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
152536         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
152537         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
152538         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
152539         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
152540         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
152541         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
152542         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
152543         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
152544         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
152545         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
152546         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
152547         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
152548         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
152549         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
152550         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
152551         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
152552         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
152553         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
152554         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
152555         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
152556         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
152557         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
152558         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
152559         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
152560         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
152561         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
152562         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
152563         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
152564         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
152565         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
152566         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
152567         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
152568         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
152569         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
152570         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
152571         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
152572         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
152573         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
152574         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
152575         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
152576         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
152577         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
152578         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
152579         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
152580         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
152581         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
152582         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
152583         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
152584         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
152585         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
152586         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
152587         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
152588         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
152589         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
152590         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
152591         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
152592         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
152593         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
152594         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
152595         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
152596         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
152597         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
152598         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
152599         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
152600         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
152601         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
152602         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
152603         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
152604         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
152605         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
152606         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
152607         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
152608         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
152609         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
152610         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
152611         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
152612         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
152613         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
152614         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
152615         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
152616         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
152617         lib/yesno.c, lib/yesno.h:
152618         Update FSF postal mail address.
152620 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
152622         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
152623         tests/test-memmem.c, tests/test-stpncpy.c:
152624         Update FSF postal mail address.
152626 2005-05-13  Bruno Haible  <bruno@clisp.org>
152628         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
152629         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
152630         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
152631         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
152632         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
152633         Add support for 64-bit integers in the MSVC compiler.
152635 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
152637         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
152639 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
152641         * gnulib-tool (func_import): Sort and uniquify recommended includes.
152643 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
152645         * doc/getdate.texi (General date syntax): Don't say that date
152646         date --iso-8601=ns generates acceptable dates; it doesn't yet.
152647         Problem reported by Nic Ferrier.
152649 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
152651         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
152652         specified in ai_socktype. Fix invalid ai_protocol
152653         check. ai_protocol is usually set to 0 or depending on
152654         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
152655         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
152656         ai_socktype / ai_protocol in the returned addrinfo structure.
152658 2005-05-10  Simon Josefsson  <jas@extundo.com>
152660         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
152661         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
152663 2005-05-10  Karl Berry  <karl@gnu.org>
152665         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
152666         (from http://www.gnu.org/licenses).
152667         * doc/COPYING.LIB: also rename to COPYING.LESSER.
152668         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
152669         fdl.texi suffices.
152671 2005-05-10  Karl Berry  <karl@gnu.org>
152673         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
152674         (COPYING.DOC): remove.
152676         * config/srclist-update: new FSF address.
152678 2005-05-10  Derek Price  <derek@ximbiot.com>
152680         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
152681         possible.
152683 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
152684             Bruno Haible  <bruno@clisp.org>
152686         * modules/inet_ntop: New file.
152687         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
152688         inet_ntop.
152690 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
152691             Bruno Haible  <bruno@clisp.org>
152693         * m4/inet_ntop.m4: New file.
152695 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
152696             Bruno Haible  <bruno@clisp.org>
152698         * lib/inet_ntop.h: New file.
152699         * lib/inet_ntop.c: New file, from glibc with modifications.
152701 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
152703         * modules/time_r (License): Change to LGPL.
152704         * modules/extensions (License): Change to LGPL.  Actually,
152705         the license is more permissive than that, but currently gnulib-tool
152706         doesn't know how to handle more-permissive licenses.
152708         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
152709         Problem reported by Dave Love.
152711 2005-05-08  Jim Meyering  <jim@meyering.net>
152713         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
152714         blank.
152716 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
152718         * modules/argmatch (Depends-on): Add stdbool.
152719         * modules/backupfile (Depends-on): Likewise.
152720         * modules/chdir-long (Depends-on): Likewise.
152721         * modules/closeout (Depends-on): Likewise.
152722         * modules/cycle-check (Depends-on): Likewise.
152723         * modules/dirname (Depends-on): Likewise.
152724         * modules/fnmatch (Depends-on): Likewise.
152725         * modules/fsusage (Depends-on): Likewise.
152726         * modules/fwriteerror (Depends-on): Likewise.
152727         * modules/getcwd (Depends-on): Likewise.
152728         * modules/getloadavg (Depends-on): Likewise.
152729         * modules/hard-locale (Depends-on): Likewise.
152730         * modules/makepath (Depends-on): Likewise.
152731         * modules/mountlist (Depends-on): Likewise.
152732         * modules/nanosleep (Depends-on): Likewise.
152733         * modules/posixtm (Depends-on): Likewise.
152734         * modules/quotearg (Depends-on): Likewise.
152735         * modules/readtokens (Depends-on): Likewise.
152736         * modules/readtokens0 (Depends-on): Likewise.
152737         * modules/readutmp (Depends-on): Likewise.
152738         * modules/save-cwd (Depends-on): Likewise.
152739         * modules/strftime (Depends-on): Likewise.
152740         * modules/userspec (Depends-on): Likewise.
152741         * modules/utimecmp (Depends-on): Likewise.
152742         * modules/xgetcwd (Depends-on): Likewise.
152743         * modules/xnanosleep (Depends-on): Likewise.
152744         * modules/xstrtod (Depends-on): Likewise.
152745         * modules/yesno (Depends-on): Likewise.
152747 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
152749         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
152750         needless checks.
152752 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
152754         Merge from coreutils.  Among other things,
152755         add bulletproofing for cases where stdin, stdout, or stderr are closed.
152756         * lib/fd-safer.c: New file.
152757         * lib/fcntl-safer.h, open-safer.c: Remove.
152758         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
152759         * lib/dup-safer.c: Include unistd-safer.h first.
152760         Don't include errno.h.
152761         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
152762         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
152763         * lib/file-type.c: Rely on file-type.h change.
152764         * lib/getloadavg.c: Include unistd-safer.h.
152765         (getloadavg): Use safer open.
152766         * lib/getusershell.c: Include "stdio-safer.h".
152767         (getusershell): Use safer fopen.
152768         * lib/long-options.c (long_options): Use NULL rather than 0.
152769         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
152770         'free'.
152771         * lib/modechange.c: Likewise.
152772         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
152773         (MODE_DONE): New constant.
152774         (struct mode_change): Remove 'next' member.
152775         (make_node_op_equals): New function; like the old one of the
152776         same name, except it allocates an array.
152777         (mode_compile, mode_create_from_ref): Use it.
152778         (mode_compile): Allocate result as an array, not a linked list.
152779         Parse octal string ourself, so that we catch mistakes like "+0".
152780         (mode_adjust): Arg is an array, not a linked list.
152781         * lib/modechange.c: Include stat-macros.h, xalloc.h.
152782         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
152783         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
152784         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
152785         Remove.  This is now stat-macros.h's job.
152786         (talloc): Remove.  All callers replaced by xalloc, so that
152787         our invokers don't have to worry about reporting memory failures.
152788         (make_node_op_equals): Remove.
152789         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
152790         New constants.
152791         (struct mode_change): Moved here from modechange.h.
152792         (mode_append_entry): Remove.
152793         (mode_compile): Remove MASKED_OPS arg, since it encouraged
152794         apps to have incorrect behavior.  Use simpler algorithm for head
152795         and tail.  Don't futz with umask; that's now the job of mode_adjust.
152796         Detect more invalid usages rather than having somewhat-random behavior.
152797         Don't insert an "a=" action, as that leads to incorrect behavior.
152798         (mode_compile, mode_create_from_ref): Return NULL on error instead
152799         of an enum, since now there's only one way to have an error.  All
152800         callers changed.
152801         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
152802         at the correct time.  Simplify calculation of "+u" and its ilk.
152803         Don't mishandle "+X".
152804         (mode_free): Remove "register" and localize decls.
152805         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
152806         (struct mode_change): Move to modechange.c; callers don't
152807         need to see this stuff.
152808         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
152809         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
152810         (mode_change, mode_adjust): Reflect the new signatures noted above.
152811         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
152812         that might redefine system include files.
152813         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
152814         (my_usleep): Use NULL rather than (void *) 0.
152815         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
152816         Use siginterrupt to specify that system calls should be interrupted.
152817         (rpl_nanosleep): Move initialization of suspended closer to call of
152818         my_usleep.
152819         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
152820         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
152821         (desirable_utmp_entry): New function.
152822         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
152823         using x2nrealloc, to simplify logic.
152824         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
152825         size calculation.  Do not assume utmp file is a regular file.
152826         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
152827         (READ_UTMP_CHECK_PIDS): New constant.
152828         * lib/save-cwd.c: Include unistd-safer.h.
152829         (save_cwd): Use fd_safer.
152830         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
152831         [!_LIBC] Include "stat-macros.h" instead.
152832         * lib/unistd-safer.h (fd_safer): New decl.
152834 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
152836         * modules/getloadavg (Depends-on): Add unistd-safer.
152837         * modules/getusershell (Depends-on): Add stdio-safer.
152838         * modules/lstat (Depends-on): Remove xalloc.
152839         * modules/mkstemp (Depends-on): Add stat-macros.
152840         * modules/modechange (Depends-on): Remove xstrtol.
152841         Add stat-macros, xalloc.
152842         * modules/save-cwd (Depends-on): Add unistd-safer.
152843         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
152844         * modules/unistd-safer (Files): Add lib/fd-safer.c
152845         (Makefile.am): Remove lib_SOURCES.
152847         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
152848         Remove fcntl-safer; unistd-safer supersedes it.
152850 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
152852         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
152853         AC_HEADER_STAT.
152854         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
152855         (gl_PREREQ_CHOWN): Remove.
152856         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
152857         it.  Don't require AC_HEADER_STAT.
152858         (gl_PREREQ_LSTAT): Remove.
152859         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
152860         Don't require AC_HEADER_STAT.
152861         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
152862         (gl_PREREQ_RMDIR): Remove.
152863         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
152864         mention stat-macros.h or AC_HEADER_STAT, since we'll make
152865         the stat-macros module a prerequisite.
152866         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
152867         * m4/filemode.m4 (gl_FILEMODE): Likewise.
152868         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
152869         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
152870         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
152871         variable names.
152872         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
152873         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
152874         variable prefixes.
152875         * m4/fcntl-safer.m4: Remove.
152876         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
152877         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
152878         Invoke gl_PREREQ_FD_SAFER.
152879         (gl_PREREQ_FD_SAFER): New macro.
152880         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
152881         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
152882         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
152883         Remove duplicate call to AC_LIBOBJ(readutmp).
152884         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
152886         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
152887         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
152889 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
152891         * MODULES.html.sh (Misc): Add byteswap.
152893 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
152895         * modules/getcwd (Depends-on): Add extensions.
152896         * modules/openat (Depends-on): Likewise.
152898 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
152900         * modules/byteswap: New file.
152902 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
152904         * m4/byteswap.m4: New file.
152906 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
152908         * lib/byteswap_.h: New file.
152910 2005-04-25  Karl Berry  <karl@gnu.org>
152912         * m4/gettext.m4: Update from GNU gettext 0.14.4.
152914 2005-04-25  Albert Chin  <china@thewrittenword.com>
152916         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
152917         Toolkit C bug.
152919 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
152921         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
152922         (func_ln_if_changed): Remove forcibly for no error message
152923         in case file does not exist.
152925 2005-04-19  Simon Josefsson  <jas@extundo.com>
152927         * gnulib-tool (Options): Make --symlink mean --symbolic.
152929 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
152931         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
152933 2005-04-16  Simon Josefsson  <jas@extundo.com>
152935         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
152937 2005-04-15  Simon Josefsson  <jas@extundo.com>
152939         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
152941 2005-04-15  Simon Josefsson  <jas@extundo.com>
152943         * gnulib-tool: Rename --symlink to --symbolic.
152945 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
152947         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
152948         symbolic links to files instead of copying/moving.  Add --aux-dir,
152949         specifying directory relative --dir where auxiliary build tools
152950         are placed.
152952 2005-04-14  Bruno Haible  <bruno@clisp.org>
152954         * modules/allocsa (License): Change to LGPL.
152955         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
152957 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
152959         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
152960         that "UTC +1 second" continues to work.  Problem reported
152961         by Dmitry V. Levin.
152962         (relunit_snumber): New rule.
152963         (relunit): Use it.
152965 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
152967         * lib/getdate.y (universal_time_zone_table): New constant.
152968         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
152969         universal_time_zone_table.
152970         (lookup_zone): Prefer universal_time_zone_table to
152971         local_time_zone_table, so that "GMT" time stamps are allowed in
152972         London during the summer.  Problem reported by Ian Abbott.
152974 2005-04-12  Jim Meyering  <jim@meyering.net>
152976         * lib/human.c (humblock): Set *options even when returning due to
152977         xstrtoumax conversion failure.  Thanks to a used-uninitialized
152978         warning from gcc-4.
152980 2005-04-09  Jim Meyering  <jim@meyering.net>
152982         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
152983         -Wuninitialized: initialize tm0.tm_year.
152985 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
152987         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
152988         count, since there's no maximum.  All uses changed.
152989         Add member dsts_seen.
152990         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
152991         not being INT_MAX.
152992         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
152993         Use pc_rels_seen to decide whether a date is absolute.
152995         * lib/getdate.y (number): Don't overwrite year.
152996         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
152997         check.
152999 2005-04-02  Simon Josefsson  <jas@extundo.com>
153001         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
153002         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
153004 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
153006         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
153007         where no absolute path name can be longer than PATH_MAX.
153009 2005-03-27  Jim Meyering  <jim@meyering.net>
153011         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
153013 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
153015         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
153016         "one's complement" -> "ones' complement" in comment, as per Knuth.
153017         "value of type" -> "type or expression" in comment.
153018         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
153020 2005-03-26  Jim Meyering  <jim@meyering.net>
153022         Comment nits.
153023         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
153024         Correct typos: s/or/of/.
153026 2005-03-26  Jim Meyering  <jim@meyering.net>
153028         * modules/check-include-files: Move to ../ and rename to...
153029         * check-module: ...this.
153031 2005-03-25  Jim Meyering  <jim@meyering.net>
153033         * modules/xvasprintf (Files): Add xalloc.h.
153035 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
153037         * modules/gettext (Files): config/config.rpath ->
153038         build-aux/config.rpath
153039         * modules/iconv (Files): Likewise.
153040         Problem reported by Oskar Liljeblad.
153042 2005-03-23  Jim Meyering  <jim@meyering.net>
153044         * modules/check-include-files: New script to check for
153045         missing dependencies, multiple includes, etc.
153047         * modules/c-strtold (Depends-on): Add xalloc.
153048         * modules/c-strtod (Depends-on): Add xalloc.
153049         * modules/hash (Depends-on): Add xalloc.
153050         (Files): Remove lib/xalloc.h.
153052         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
153053         * modules/userspec (Files): Add lib/inttostr.h.
153055 2005-03-23  Jim Meyering  <jim@meyering.net>
153057         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
153059 2005-03-22  Jim Meyering  <jim@meyering.net>
153061         * modules/stat-macros: New module.
153062         * modules/canonicalize, modules/euidaccess, modules/file-type,
153063         * modules/filemode, modules/lchown, modules/makepath,
153064         * modules/rmdir, modules/stat: Depend on new stat-macros module
153065         rather than listing lib/stat-macros.h manually.
153066         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
153068 2005-03-22  Jim Meyering  <jim@meyering.net>
153070         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
153072 2005-03-22  Bruno Haible  <bruno@clisp.org>
153074         * config/srclist.txt: Replace target directory 'config' with
153075         'build-aux'.
153076         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
153077         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
153078         ../build-aux/.
153080 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
153082         * modules/chdir-long (Depends-on): Add mempcpy.
153084         * modules/acl, modules/backupfile, modules/c-strtod,
153085         modules/c-strtold, modules/canon-host, modules/canonicalize,
153086         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
153087         modules/exclude, modules/exitfail, modules/file-type,
153088         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
153089         modules/getdate, modules/getline, modules/getpagesize,
153090         modules/getpass, modules/getugroups, modules/group-member,
153091         modules/hard-locale, modules/hash, modules/human, modules/idcache,
153092         modules/inttostr, modules/long-options, modules/makepath,
153093         modules/md5, modules/memcasecmp, modules/memcoll,
153094         modules/modechange, modules/mountlist, modules/path-concat,
153095         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
153096         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
153097         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
153098         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
153099         modules/strftime, modules/strndup, modules/strverscmp,
153100         modules/timespec, modules/unlocked-io, modules/userspec,
153101         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
153102         modules/yesno:
153103         Remove lib_SOURCES line from Makefile.am section, as this is now
153104         done automatically by the corresponding Autoconf macro.
153106 2005-03-21  Jim Meyering  <jim@meyering.net>
153108         Changes imported from coreutils.
153110         * lib/cycle-check.c: Don't include xalloc.h.
153112         * lib/path-concat.c: Don't include assert.h.
153113         (path_concat): Remove assertion that would have triggered
153114         for ABASE starting with more than one slash.
153115         Reported by Andreas Schwab.
153117         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
153118         properly when ABASE is an absolute file name.
153119         Correct the description of this function.
153120         Include <assert.h>.
153121         Add an assertion and a test driver.
153122         This fixes a bug introduced on 2004-07-02.
153123         Andreas Schwab reported the resulting failure of cp --parents:
153124         http://lists.gnu.org/r/bug-coreutils/2005-01/msg00130.html
153126 2005-03-21  Jim Meyering  <jim@meyering.net>
153128         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
153129         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
153131 2005-03-21  Jim Meyering  <jim@meyering.net>
153132         and  Paul Eggert  <eggert@cs.ucla.edu>
153134         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
153135         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
153136         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
153137         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
153138         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
153139         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
153140         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
153141         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
153142         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
153143         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
153144         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
153145         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
153146         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
153147         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
153148         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
153149         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
153150         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
153151         for these modules.
153153 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
153155         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
153156         (which shouldn't happen), generate nothing instead of returning 0
153157         immediately, so that nstrftime (NULL, ...) doesn't return 0.
153159 2005-03-16  Bruno Haible  <bruno@clisp.org>
153161         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
153162         HAVE_LONGLONG_64BIT.
153164 2005-03-16  Bruno Haible  <bruno@clisp.org>
153166         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
153167         HAVE_LONGLONG_64BIT.
153169 2005-03-16  Bruno Haible  <bruno@clisp.org>
153171         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
153172         HAVE_LONGLONG_64BIT.
153174 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
153176         * lib/strftime.c (my_strftime): Prepend space to format so that we can
153177         reliably distinguish strftime failure from empty output on POSIX
153178         hosts.
153180 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
153182         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
153183         (iconv_string): Don't guess a size-zero buffer, as that might cause
153184         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
153185         result would be 'too large', where 'too large' is (heuristically)
153186         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
153187         overflow concerns.  This will prevent some unwanted malloc failures
153188         when the inputs are very large.
153190 2005-03-15  Karl Berry  <karl@gnu.org>
153192         * config/srclist.txt (config.rpath): from gettext.
153193         * config/config.rpath: update.
153195 2005-03-15  Bruno Haible  <bruno@clisp.org>
153197         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
153198         to 'negate'.
153200         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
153201         variable.
153203         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
153204         results.
153206 2005-03-14  Simon Josefsson  <jas@extundo.com>
153208         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
153209         <fx@gnu.org>.
153211 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
153213         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
153214         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
153215         intprops.h.
153216         * lib/strtol.c: Likewise.
153218 2005-03-14  Jim Meyering  <jim@meyering.net>
153220         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
153221         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
153222         to be nonzero so that we (and caller) can detect the difference
153223         between a valid zero-length expansion and an error return, even
153224         when the underlying strftime fails before writing anything into
153225         that location.
153227 2005-03-14  Bruno Haible  <bruno@clisp.org>
153229         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
153230         Update from GNU gettext 0.14.3.
153232 2005-03-10  Jim Meyering  <jim@meyering.net>
153234         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
153236 2005-03-10  Jim Meyering  <jim@meyering.net>
153238         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
153239         so that this module works on systems without fchdir.
153241 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
153243         Factor int-properties macros into a single file, except for
153244         glibc-related files.
153245         * lib/intprops.h: New file.
153246         * lib/getloadavg.c: Include it instead of limits.h.
153247         (INT_STRLEN_BOUND): Remove.
153248         * lib/human.c: Include intprops.h.
153249         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
153250         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
153251         302/1000.
153252         * lib/inttostr.h: Include intprops.h instead of limits.h.
153253         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
153254         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
153255         for consistency with intprops.h.
153256         (time_t_is_integer, twos_complement_arithmetic): Use them.
153257         * lib/sig2str.h: Include <signal.h>, intprops.h.
153258         (INT_STRLEN_BOUND): Remove.
153259         * lib/strftime.c (TYPE_SIGNED): Remove.
153260         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
153261         * lib/strtol.c: Adjust comments to match intprops.h.
153262         * lib/userspec.c: Include intprops.h.
153263         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
153264         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
153265         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
153266         instead of rolling our own expressions.
153267         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
153269         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
153270         instead of int.
153271         (my_strftime): Do not mishandle years close to INT_MAX, by doing
153272         the right thing even if adding 1900 would overflow.  Similarly
153273         for tm_mon + 1 and tm_yday + 1.
153274         Make %Y always equivalent to %C%y, and similarly for %G and %g.
153275         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
153276         (DO_SIGNED_NUMBER): New macro.
153277         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
153279 2005-03-07  Bruno Haible  <bruno@clisp.org>
153281         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
153283 2005-03-07  Bruno Haible  <bruno@clisp.org>
153285         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
153287 2005-03-04  Derek R. Price  <derek@ximbiot.com>
153289         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
153290         (func_import): Only replace files via --import when they have actually
153291         changed.
153293 2005-03-03  Derek R. Price  <derek@ximbiot.com>
153295         * m4/mmap-anon.m4: New file.
153296         * m4/pagealign_alloc.m4: New file.
153298 2005-03-03  Derek R. Price  <derek@ximbiot.com>
153299             Bruno Haible  <bruno@clisp.org>
153301         * modules/pagealign_alloc: New file.
153302         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
153304 2005-03-03  Derek R. Price  <derek@ximbiot.com>
153305             Bruno Haible  <bruno@clisp.org>
153307         * lib/pagealign_alloc.h: New file.
153308         * lib/pagealign_alloc.c: New file.
153310 2005-03-03  Bruno Haible  <bruno@clisp.org>
153312         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
153313         Use an all-permissive copyright notice, recommended by RMS.
153315 2005-03-02  Bruno Haible  <bruno@clisp.org>
153317         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
153318         of AIX, the replacement has to be done only after <string.h> is
153319         included, therefore not in config.h. stpncpy.h does the replacement,
153320         and stpncpy.c uses it.
153322 2005-03-02  Bruno Haible  <bruno@clisp.org>
153324         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
153325         stpncpy.c uses it.
153327 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
153329         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
153330         The workaround isn't strictly needed for POSIX conformance, and
153331         it's too much of a pain to configure and maintain.  We'll ask
153332         people to fix their kernels instead.
153333         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
153334         (NANOSLEEP_BUG_WORKAROUND): Remove.
153335         (xnanosleep): Remove the workaround.
153337 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
153339         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
153340         Reported by Derek Price.
153341         (Include): Add "timespec.h".
153343         * modules/xnanosleep (Depends-on): Remove gethrxtime.
153345 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
153347         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
153348         to detect nanosleep bug.
153350 2005-03-01  Bruno Haible  <bruno@clisp.org>
153352         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
153354 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
153356         * modules/gethrxtime: New file.
153357         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
153358         (Depends-on): Add gethrxtime.
153359         (configure.ac): Add gl_XNANOSLEEP.
153360         (Makefile.am): Remove lib_SOURCES line.
153362 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
153364         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
153365         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
153367 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
153369         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
153370         * lib/timespec.h (gettime): Return void, since it always
153371         succeeds now.  All uses changed.
153372         * lib/gettime.c (gettime): Likewise.
153373         [HAVE_NANOTIME]: Prefer nanotime.
153374         Assume gettimeofday succeeds, as POSIX requires.
153375         Assime time () succeeds, since other code already does.
153376         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
153377         (timespec_subtract): Remove.
153378         (NANOSLEEP_BUG_WORKAROUND): New constant.
153379         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
153380         things considerably.  Use it only on GNU/Linux hosts, since the
153381         workaround shouldn't be needed elsewhere.
153383 2005-02-24  Bruno Haible  <bruno@clisp.org>
153385         * modules/gettext (Files): Add m4/glibc2.m4.
153387 2005-02-24  Bruno Haible  <bruno@clisp.org>
153389         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
153390         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
153391         * m4/progtest.m4:
153392         Update from GNU gettext 0.14.2.
153393         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
153395 2005-02-24  Bruno Haible  <bruno@clisp.org>
153397         * lib/localcharset.c: Update from GNU gettext 0.14.2.
153398         * lib/config.charset: Update from GNU gettext 0.14.2.
153400 2005-02-24  Bruno Haible  <bruno@clisp.org>
153402         * lib/gettext.h: Update from GNU gettext 0.14.2.
153404 2005-02-23  Simon Josefsson  <jas@extundo.com>
153406         * m4/iconvme.m4: New file.
153408 2005-02-23  Jim Meyering  <jim@meyering.net>
153410         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
153411         change.
153412         Thanks to Bruno Haible for catching it.
153414 2005-02-22  Simon Josefsson  <jas@extundo.com>
153416         * modules/iconvme: New file.
153418         * MODULES.html.sh: Add iconvme.
153420 2005-02-22  Simon Josefsson  <jas@extundo.com>
153422         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
153424 2005-02-22  Simon Josefsson  <jas@extundo.com>
153426         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
153428 2005-02-22  Jim Meyering  <jim@meyering.net>
153430         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
153431         s/ifndef/ifdef/.
153433 2005-02-20  Neil Conway  <neilc@samurai.com>
153435         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
153436         returned by OSX/Darwin if the specified buffer is not large
153437         enough for the hostname.
153439 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
153441         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
153442         pass it to _help, otherwise the latter coredumps trying to
153443         dereference state.root_argp.
153445 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
153447         * modules/chdir-long (Depends-on): Add memrchr.
153448         * modules/memrchr (Files): Add lib/memrchr.h.
153449         (Include): "memrchr.h".
153451 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
153453         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
153455 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
153457         * lib/memrchr.h: New file.
153458         * lib/chdir-long.c: Include it.
153459         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
153460         Don't bother including stddef.h.
153462 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
153464         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
153465         inclusion.
153466         Include <sys/types.h>, for dev_t.
153467         (ME_DUMMY, ME_REMOTE): Move from here....
153468         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
153469         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
153470         Dmitry V. Levin.
153471         Include mountlist.h first, to test the interface.
153473 2005-01-29  Bruno Haible  <bruno@clisp.org>
153475         * lib/progname.c (program_name): Initialize.
153476         Needed when linking statically on MacOS X.
153478 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
153480         Sync from coreutils.
153481         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
153482         (Depends-on): Add c-strtod.
153483         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
153485 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
153487         Sync from coreutils.
153488         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
153490         Remove files that are specific to coreutils.
153491         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
153493 2005-01-28  Bruno Haible  <bruno@clisp.org>
153495         * modules/javacomp: New file.
153496         * MODULES.html.sh (Java): Add javacomp.
153498 2005-01-28  Bruno Haible  <bruno@clisp.org>
153500         * m4/javacomp.m4: New file, from GNU gettext.
153502 2005-01-28  Bruno Haible  <bruno@clisp.org>
153504         * lib/javacomp.sh.in: New file, from GNU gettext.
153505         * lib/javacomp.h: New file, from GNU gettext.
153506         * lib/javacomp.c: New file, from GNU gettext.
153508 2005-01-26  Simon Josefsson  <jas@extundo.com>
153510         * lib/gai_strerror.c: Use GPL in header.
153512 2005-01-26  Bruno Haible  <bruno@clisp.org>
153514         * modules/javaexec: New file.
153515         * MODULES.html.sh (Java): Add javaexec.
153517 2005-01-26  Bruno Haible  <bruno@clisp.org>
153519         * m4/javaexec.m4: New file, from GNU gettext.
153521 2005-01-26  Bruno Haible  <bruno@clisp.org>
153523         * lib/javaexec.sh.in: New file, from GNU gettext.
153524         * lib/javaexec.h: New file, from GNU gettext.
153525         * lib/javaexec.c: New file, from GNU gettext.
153527 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
153529         * modules/lchown (Depends-on): Remove lchown.h
153531 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
153533         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
153534         must be defined if the header file was not found, in order
153535         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
153537 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
153539         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
153540         initializers for struct pentry_state.
153541         (__argp_error): Check return value of __asprintf
153542         (__argp_failure): Translate error message
153544         * lib/argp-parse.c: Removed braces around the expansion of N_()
153546 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
153548         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
153549         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
153550         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
153551         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
153552         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
153553         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
153554         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
153555         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
153556         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
153557         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
153558         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
153559         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
153560         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
153561         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
153562         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
153563         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
153564         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
153565         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
153566         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
153567         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
153568         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
153569         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
153570         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
153571         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
153572         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
153573         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
153574         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
153575         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
153576         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
153577         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
153578         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
153579         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
153580         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
153581         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
153582         xstrtol.m4, xstrtoumax.m4, yesno.m4:
153583         Use an all-permissive copyright notice, recommended by RMS.
153585 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
153587         * modules/chdir-long (Depends-on): Remove mempcpy.
153589 2005-01-21  Jim Meyering  <jim@meyering.net>
153591         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
153592         same value as for Solaris 9.
153594         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
153595         component length.  This included changing the parameter to be
153596         of type `char *' rather than `char const *'.
153597         * lib/chdir-long.h (chdir_long): Update prototype.
153599         * lib/openat.c (fdopendir, fstatat): New functions.
153600         * lib/openat.h: Include headers required for use of DIR and struct
153601         stat.
153602         [AT_SYMLINK_NOFOLLOW]: Define.
153603         (fdopendir, fstatat): Add prototypes.
153605 2005-01-21  Bruno Haible  <bruno@clisp.org>
153607         * modules/classpath: New file.
153608         * MODULES.html.sh (Java): Add classpath.
153610 2005-01-21  Bruno Haible  <bruno@clisp.org>
153612         * lib/classpath.h: New file, from GNU gettext.
153613         * lib/classpath.c: New file, from GNU gettext.
153615 2005-01-20  Simon Josefsson  <jas@extundo.com>
153617         * modules/version-etc-fsf: New file.
153619 2005-01-20  Simon Josefsson  <jas@extundo.com>
153621         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
153622         * lib/version-etc.c: Remove version_etc_copyright.
153623         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
153624         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
153626 2005-01-20  Simon Josefsson  <jas@extundo.com>
153628         * lib/base64.h (isbase64): Add.
153630         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
153631         using a unsigned prototype, don't inline.
153632         (base64_decode): Use it.
153634 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
153636         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
153637         it.
153639 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
153641         * lib/save-cwd.c (save_cwd): Remove code to support the case
153642         where fchdir is missing or flaky.
153644 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
153646         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
153648 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
153650         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
153651         AC_LIBSOURCES now does this.
153652         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
153653         with new ullong_max module.
153655 2005-01-19  Bruno Haible  <bruno@clisp.org>
153657         * modules/sh-quote: New file.
153658         * MODULES.html.sh (Executing programs): Add sh-quote.
153660 2005-01-19  Bruno Haible  <bruno@clisp.org>
153662         * lib/sh-quote.h: New file, from GNU gettext.
153663         * lib/sh-quote.c: New file, from GNU gettext.
153665 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
153667         Merge from coreutils.
153668         * m4/ullong_max.m4: New file.
153669         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
153670         (gl_MACROS): Assume localeconv exists.
153672 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
153674         Merge changes from coreutils, as described below in several
153675         changelogs dated today.
153677         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
153678         (O_DIRECTORY): Remove; not needed here, since "." must be
153679         a directory.  All uses removed.
153680         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
153681         universal on Suns, and we also need to test for IRIX.
153682         Revamp code to use 'if' rather than '#if'.
153683         Avoid unnecessary comparison of cwd->desc to 0.
153685         * lib/utimens.c (futimens): Robustify the previous patch, by checking
153686         for known valid error numbers rather than observed invalid ones.
153688 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
153690         * modules/ullong_max: New file.
153692         * modules/chdir-long, modules/openat: New files.
153693         * modules/save-cwd (Depends-on): Depend on chdir-long.
153694         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
153696 2005-01-18  Jim Meyering  <jim@meyering.net>
153698         Merge from coreutils.
153699         * m4/chdir-long.m4, m4/openat.m4: New files.
153700         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
153701         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
153702         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
153703         is sane and DOES follow symlinks.  Besides, testing 20 different
153704         systems found no broken chown implementations.
153705         Prompted by a change in rsync's copy of this macro.
153706         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
153708         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
153710         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
153711         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
153712         NULL-means-set-to-current-time semantics.
153713         Remove temporary file immediately, rather than waiting
153714         for configure's at-exit trap code to do it.
153716 2005-01-18  Jim Meyering  <jim@meyering.net>
153718         * lib/version-etc.c (version_etc_copyright): Update copyright date.
153720         * lib/utimens.c (futimens): Account for the fact that futimes
153721         can also fail with errno == ENOSYS or errno == ENOENT.
153722         Patch from Dmitry V. Levin.
153724         Change the name of the robust chdir function from chdir to chdir_long.
153725         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
153726         (restore_cwd): Use chdir_long, not chdir.
153727         * lib/chdir-long.c: Renamed from chdir.c.
153728         * lib/chdir-long.h: Renamed from chdir.h.
153729         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
153730         Hurd.
153732 2005-01-18  Bruno Haible  <bruno@clisp.org>
153734         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
153735         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
153736         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
153737         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
153738         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
153739         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
153740         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
153741         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
153742         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
153743         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
153744         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
153745         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
153746         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
153747         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
153748         Use an all-permissive copyright notice, recommended by RMS.
153750 2005-01-18  Bob Proulx  <bob@proulx.com>
153752         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
153753         simplify offsetof() macro construct to avoid compile failure with
153754         native HP-UX 11.0 ANSI C compiler.
153756 2005-01-17  Bruno Haible  <bruno@clisp.org>
153758         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
153759         redundant because stpncpy.m4 takes care of it.
153761 2005-01-17  Bruno Haible  <bruno@clisp.org>
153763         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
153765 2005-01-17  Bruno Haible  <bruno@clisp.org>
153767         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
153768         used.
153770 2005-01-17  Bruno Haible  <bruno@clisp.org>
153772         * lib/fwriteerror.h (fwriteerror): Change specification to include
153773         fclose.
153774         * lib/fwriteerror.c: Include <stdbool.h>.
153775         (fwriteerror): At the end, close the file stream. Record whether
153776         stdout was already closed.
153778 2005-01-17  Bruno Haible  <bruno@clisp.org>
153780         * lib/execute.c (environ): Declare if needed.
153781         * lib/pipe.c (environ): Likewise.
153782         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
153784 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
153786         * modules/argp: Depend on vsnprintf
153788 2005-01-10  Jim Meyering  <jim@meyering.net>
153790         * modules/closeout (Depends-on): Add atexit.
153792 2005-01-06  Bruno Haible  <bruno@clisp.org>
153794         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
153796 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
153798         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
153799         definitions to be after all include files, to avoid collisions.
153800         Problem reported by Bob Proulx.
153802 2005-01-04  Jim Meyering  <jim@meyering.net>
153804         Changes imported from coreutils.
153805         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
153806         as the mkstemp template, use a temporary directory and an
153807         8.3-friendly template to avoid trouble on systems like DJGPP.
153808         Reported by Juan M. Guerrero via Stepan Kasal.
153809         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
153810         close. Remove the temporary directory right away, rather than waiting
153811         for configure's at-exit trap code to do it.
153812         Suggestion from Stepan Kasal.
153814 2005-01-01  Simon Josefsson  <jas@extundo.com>
153816         * gnulib-tool: Print #include directives when --import'ing.
153818 2004-12-28  Simon Josefsson  <jas@extundo.com>
153820         * tests/test-base64.c: Include required header files.  Remove
153821         unused variables.
153823 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
153825         * modules/error (Depends-on): Remove gettext.
153827 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
153829         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
153830         not needed.  This removes a dependency on the gettext module.
153831         [defined _LIBC]: Do not include <libintl.h>; not needed.
153833 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
153835         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
153836         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
153838 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
153840         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
153841         HAVE_DECL_STRTOLD.
153843 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
153845         * modules/getdate (Depends-on): Remove alloca-opt.
153847 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
153849         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
153851 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
153853         * lib/argp-parse.c: Include <stddef.h>.
153854         (alignof, alignto): New macros.
153855         (parser_init): Don't assume that void * is aligned sufficiently
153856         for struct option.
153858         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
153859         need to extend the stack.
153860         (YYINITDEPTH): New macro, so that the initial stack isn't overly
153861         large.
153863 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
153865         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
153867 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
153869         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
153870         (2004-10-24) change.  Apparently this was a false alarm.
153872         * modules/getdate: Depend on alloca-opt, not alloca.
153874 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
153876         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
153877         Remove now-obsolete comment about AIX.
153878         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
153879         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
153880         (YYMAXDEPTH): New macro.
153882 2004-12-18  Simon Josefsson  <jas@extundo.com>
153884         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
153886 2004-12-18  Bruno Haible  <bruno@clisp.org>
153888         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
153890 2004-12-18  Bruno Haible  <bruno@clisp.org>
153892         * lib/fatal-signal.c (fatal_signals): Make non-const.
153893         (init_fatal_signals): New function.
153894         (uninstall_handlers, install_handlers): Ignore signals that were set to
153895         SIG_IGN.
153896         (at_fatal_signal): Call init_fatal_signals.
153897         (init_fatal_signal_set): Likewise. Ignore signals that were set to
153898         SIG_IGN.
153899         Reported by Paul Eggert.
153901 2004-12-18  Bruno Haible  <bruno@clisp.org>
153903         * doc/alloca.texi: New file.
153904         * doc/alloca-opt.texi: New file.
153906 2004-12-17  Jim Meyering  <jim@meyering.net>
153908         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
153909         Otherwise, install-sh could exit with improper exit status when
153910         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
153912 2004-12-16  Simon Josefsson  <jas@extundo.com>
153914         * tests/test-base64.c: Add license.
153916 2004-12-15  Stepan Kasal  <address@hidden>
153918         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
153920 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
153922         * modules/getcwd (Files): Add m4/d-ino.m4.
153923         Suggested by Mark D. Baushke.
153925 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
153927         * lib/getdate.y (textint): New member "negative".
153928         (time_zone_hhmm): New function.
153929         Expect 14 shift-reduce conflicts, not 13.
153930         (o_colon_minutes): New rule.
153931         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
153932         (yylex): Set the "negative" member of signed numbers.
153934 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
153936         * doc/getdate.texi (Time of day items, Time zone items):
153937         Describe new formats +00:00, UTC+00:00.
153939 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
153941         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
153942         spurious "-l"s.  Problem reported by Stepan Kasal.
153944 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
153946         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
153947         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
153949 2004-12-04  Simon Josefsson  <jas@extundo.com>
153951         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
153952         Vandoorselaere <yoann@prelude-ids.org>.
153954 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
153956         Changes imported from coreutils.
153957         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
153958         exist.
153959         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
153961 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
153963         Changes imported from coreutils.
153964         * lib/hard-locale.c: Assume <locale.h> exists.
153965         Include "strdup.h".
153966         (GLIBC_VERSION): New macro.
153967         (hard_locale): Assume setlocale exists.
153968         Rewrite to avoid #ifdef.
153969         Use strdup rather than malloc + strcpy.
153970         * lib/human.c: Assume <locale.h> exists.
153971         (human_readable): Assume localeconv exists.
153973 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
153975         * modules/hard-locale (Depends-on): Add strdup.
153977 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
153979         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
153980         convert T2, not T.  (Imported from libc.)
153982 2004-11-30  Simon Josefsson  <jas@extundo.com>
153984         * modules/restrict (License): Change to LGPL.
153986 2004-11-30  Simon Josefsson  <jas@extundo.com>
153988         * m4/restrict.m4: Add copyright and copying conditions.
153990 2004-11-30  Simon Josefsson  <jas@extundo.com>
153992         * m4/base64.m4: New file.
153994 2004-11-30  Simon Josefsson  <jas@extundo.com>
153996         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
153997         base64.
153999         * tests/test-base64.c: New file.
154001         * modules/base64: New file.
154003 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
154005         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
154006         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
154008         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
154010 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
154012         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
154013         (__getcwd.c): Don't restore errno; glibc doesn't.
154014         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
154015         first, falling back to our code only if its results look suspicious.
154016         Ensure that the resulting buffer is only as large as necessary.
154018         * lib/readutmp.c: Include readutmp.h first.
154019         Include <errno.h>, since readutmp.h no longer does that.
154020         * lib/readutmp.h: Don't include <errno.h>,
154021         <sys/param.h>, <time.h>; not needed to establish interface.
154022         (errno): Remove decl.
154023         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
154024         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
154025         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
154027 2004-11-28  Simon Josefsson  <jas@extundo.com>
154029         * lib/base64.h, base64.c: New file.
154031 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
154033         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
154035 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
154037         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
154038         (Depends-on): Remove pathmax, same.  Add mempcpy.
154039         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
154040         (Makefile.am): Append getcwd.h to lib_SOURCES.
154041         (Include): Add getcwd.h.
154042         (Maintainer): Change from Jim Meyering to "all, glibc",
154043         since getdate now uses intended-for-glibc code.
154044         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
154045         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
154047 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
154049         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
154050         HP's ANSI C compiler.
154051         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
154052         Declaring int functions causes warnings on some modern systems and
154053         shouldn't be needed to compile on ancient ones.
154054         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
154055         defined.
154057         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
154058         with the following changes.
154059         (__set_errno): Parenthesize properly.
154060         Include <stdbool.h>.
154061         (MIN, MAX, MATCHING_INO): New macros.
154062         (__getcwd): Define with prototype, not K&R form.
154063         Use heuristics to allocate default buffer on stack if possible.
154064         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
154065         behavior, and to avoid the PATH_MAX limit when computing
154066         ../../../../...
154067         Use MATCHING_INO to compare inode number to file.
154068         Check for arithmetic overflow in size calculations.
154069         Fix bug in reallocation of dot array that caused getcwd to fail
154070         on directories nested deeper than 75.
154071         Be more careful about saving errno on error.
154072         Do not use realloc; use only free+malloc, as this is a bit
154073         more flexible and avoids a needless copy operation.
154074         Do not inspect st_dev and st_ino for symbolic links; POSIX
154075         doesn't specify the latter.
154076         Check for closedir errors.
154077         Avoid needless casts.
154078         Use "#ifdef weak_alias" around weak_alias, to be like other
154079         glibc code.
154080         The following changes to getcwd.c have effect only when used in
154081         gnulib; they have no effect inside glibc proper.
154082         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
154083         as alloca isn't used.
154084         (alloca, __alloca): Likewise.
154085         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
154086         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
154087         unconditionally, as gnulib assumes C89 or better.
154088         Do not include <sys/param.h>.
154089         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
154090         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
154091         better.
154092         (NULL) [!defined NULL]: Remove; we assume C89 or better.
154093         Include <dirent.h> in a way that is compatible with modern Autoconf.
154094         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
154095         New macros, if not already defined.
154096         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
154097         Use "_LIBC", not "defined _LIBC", for consistency.
154098         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
154099         a mempcpy module.
154100         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
154101         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
154102         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
154103         credit only to Jim Meyering and adjust the copyright dates.
154104         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
154105         <stdlib.h>, <unistd.h>, "pathmax.h".
154106         Instead, include "xgetcwd.h" (first) and "getcwd.h".
154107         (INITIAL_BUFFER_SIZE): Remove.
154108         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
154110 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
154112         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
154113         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
154114         Use the _ONCE methods, for efficiency.
154115         Check for fcntl.h.  In test program, include <errno.h>
154116         and <fcntl.h> if available.  Remove old K&R cruft from
154117         test program.  Check for common errors in GNU/Linux,
154118         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
154119         don't do AC_LIBOBJ, as that's getcwd.m4's job.
154120         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
154121         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
154122         name accordingly.
154123         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
154124         accommodate new getcwd.c.
154125         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
154126         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
154127         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
154128         that's all we need now.
154130 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
154132         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
154133         argp-parse.c depends on getopt internals, that means we should
154134         always use our getopt, to be on the safe side.
154135         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
154136         order not to spoil the result of an eventual previous invocation
154137         of gl_GETOPT_SUBSTITUTE.
154139 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
154141         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
154142         redefinition warnings. To avoid them, include the defines
154143         in `#if !defined __need_getopt ... #endif'. The only place
154144         where __getopt_argv_const is used is in definitions
154145         of getopt_long and getopt_long_only below, which are as well
154146         protected by `#ifndef __need_getopt'.
154147         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
154148         __need_getopt after including <stdio.h> and <unistd.h> These
154149         headers might have defined it.
154151 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
154153         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
154155 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
154157         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
154158         (futimens): New function, which uses futimes if available.
154159         (futimens, utimens): Support timespec==NULL, with same semantics
154160         as utime and utimens.
154161         * lib/utimens.h (futimens): New decl.
154163 2004-11-23  Jim Meyering  <jim@meyering.net>
154165         * lib/getopt_.h: Remove trailing blanks.
154167 2004-11-23  Jim Meyering  <jim@meyering.net>
154169         * lib/__fpending.c: Add comment.
154171 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
154173         * modules/canonicalize (Depends-on): Add xreadlink.
154174         Problem reported by James Youngman.
154176 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
154178         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
154179         New macros.
154180         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
154181         optopt): Use them instead of invoking ## directly; otherwise, the
154182         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
154184 2004-11-19  Bruno Haible  <bruno@clisp.org>
154186         * lib/strtok_r.c: Move comments from here...
154187         * lib/strtok_r.h: ... to here.
154189 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
154191         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
154192         implementations that mishandle size_t overflow.
154194 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
154196         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
154197         might fail.  Problem reported by Yoann Vandoorselaere.
154198         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
154199         implementations that mishandle size_t overflow.
154201 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
154203         * modules/canon-host (Depends-on): Add strdup.
154205 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
154207         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
154209 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
154211         * lib/canon-host.c: Include "strdup.h".
154212         (canon_host): Use getaddrinfo if available, so that IPv6 works.
154213         Use strdup instead of malloc/strcpy to duplicate strings.
154215         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
154216         (human_space_before_unit): New constant.
154217         * lib/human.c (human_readable): Support it.
154219         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
154220         (xgetcwd): Set errno correctly when failing.
154221         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
154222         the failure is actually due to a PATH_MAX problem.
154224         Further getopt changes to make it more likely that glibc will
154225         buy the changes back.
154226         * lib/getopt.c (POSIXLY_CORRECT): New constant.
154227         (getopt): Use it, so to preserve glibc semantic
154228         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
154229         when compiling for libc.
154230         * lib/getopt_.h (__getopt_argv_const): Bring it back.
154231         (getopt_long, getopt_long_only): Use it.
154233         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
154234         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
154235         (getopt): Argv is now char * const *, as per standard.
154236         (_getopt_internal_r, _getopt_internal): Argv is now char **,
154237         not char *__getopt_argv_const *.
154238         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
154239         _getopt_long_only_r): Likewise.
154240         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
154241         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
154242         _getopt_long_r, _getopt_long_only_r): Likewise.
154243         * lib/getopt_.h (__getopt_argv_const): Remove.
154244         (getopt): Argv is now char * const *, as per standard.
154246         * lib/getdate.y (tORDINAL): New token.
154247         (day, relunit): Allow it for relative times.
154248         (relative_time_table): Use tORDINAL for ordinals.
154250 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
154252         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
154253         Document that "second" isn't allowed as an ordinal number.
154255 2004-11-16  Jim Meyering  <jim@meyering.net>
154257         * modules/closeout (Depends-on): Add fpending.
154259 2004-11-15  Jim Meyering  <jim@meyering.net>
154261         * lib/closeout.c: Include "__fpending.h" once again.
154262         Include <stdbool.h>.
154263         (close_stdout): Don't fail just because stdout was closed initially,
154264         since some programs don't write to stdout in the normal course of
154265         operation (other than --version and --help), and we don't want this
154266         function to make e.g. `touch file >&-' fail.
154267         But do fail if it was closed and someone has tried to write to it.
154268         E.g., `printf foo >&-' must fail.
154270 2004-11-13  Jim Meyering  <jim@meyering.net>
154272         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
154274 2004-11-12  Simon Josefsson  <jas@extundo.com>
154276         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
154277         small doc fix is still pending.
154279 2004-11-11  Simon Josefsson  <jas@extundo.com>
154281         * modules/strtok_r: New file.
154283         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
154284         strtok_r.
154286 2004-11-11  Simon Josefsson  <jas@extundo.com>
154288         * m4/strtok_r.m4: New file.
154290         * m4/getopt.m4: Replace opterr.
154292 2004-11-11  Simon Josefsson  <jas@extundo.com>
154294         * lib/strtok_r.h, strtok_r.c: New file.
154296 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
154298         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
154299         of replacing opterr, getopt, etc.  This should handle the
154300         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
154302 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
154304         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
154305         we can stop lying to compilers about the constness of argv when we
154306         are compiled outside glibc.
154307         (getopt, getopt_long, getopt_long_only): Use it.
154308         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
154309         _getopt_internal, getopt): Likewise.
154310         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
154311         _getopt_long_only_r): Likewise.
154312         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
154313         _getopt_long_r, _getopt_long_only_r): Likewise.
154315         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
154316         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
154317         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
154318         the other external symbols.
154319         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
154320         declaration, since the above renaming now works around collisions.
154322 2004-11-11  Jim Meyering  <jim@meyering.net>
154324         * lib/linebreak.c: Remove trailing blanks.
154325         * lib/alloca_.h: Likewise.
154326         * lib/acosl.c: Likewise.
154327         * lib/euidaccess.c: Likewise.
154328         * lib/allocsa.h: Likewise.
154330 2004-11-10  Simon Josefsson  <jas@extundo.com>
154332         * m4/getaddrinfo.m4: New file.
154334 2004-11-10  Simon Josefsson  <jas@extundo.com>
154336         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
154338 2004-11-10  Simon Josefsson  <jas@extundo.com>
154340         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
154341         getaddrinfo.
154343         * modules/getaddrinfo: New file.
154345 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
154347         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
154349 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
154351         * lib/mktime.c (SHR): New macro, which is a portable
154352         substitute for >> that should work even on Crays.
154353         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
154354         Problem reported by Mark D. Baushke in
154355         <http://lists.gnu.org/r/bug-gnulib/2004-11/msg00071.html>.
154356         * lib/getdate.y (SHR): Likewise.
154357         (tm_diff): Use it.
154358         * lib/strftime.c (SHR): Likewise.
154359         (tm_diff): Use it.
154360         * lib/quotearg.c (struct quoting_options): Use unsigned int for
154361         quote_these_too, so that right shifts are well defined.  All uses
154362         changed.
154364 2004-11-10  Jim Meyering  <jim@meyering.net>
154366         Ensure that no close failure goes unreported.
154367         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
154368         return early when it seems there's nothing to flush.
154369         Don't include __fpending.h.
154371 2004-11-10  Jim Meyering  <jim@meyering.net>
154373         * modules/closeout (Depends-on): Remove fpending.
154375 2004-11-10  Jim Meyering  <jim@meyering.net>
154377         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
154379 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
154381         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
154382         gl_FUNC_STRFTIME.
154383         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
154384         and AC_REQUIRE when possible, to avoid duplicate checks.
154385         Check for <wchar.h>.
154387 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
154389         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
154391 2004-11-09  Bruno Haible  <bruno@clisp.org>
154393         * m4/sockpfaf.m4: New file.
154395 2004-11-05  Bruno Haible  <bruno@clisp.org>
154397         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
154398         Reported by Mark D. Baushke <mdb@cvshome.org>.
154400 2004-11-04  Bruno Haible  <bruno@clisp.org>
154402         2004-09-11  Bruno Haible  <bruno@clisp.org>
154403                 * allocsa.valgrind: New file.
154404         2004-02-06  Bruno Haible  <bruno@clisp.org>
154405                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
154406                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
154407                 Reported by Christopher Seip <chris.seip@hp.com>.
154409 2004-11-04  Bruno Haible  <bruno@clisp.org>
154411         * modules/allocsa (Files): Add lib/allocsa.valgrind.
154412         (Makefile.am): Distribute it.
154414 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
154416         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
154417         with errno == ERANGE if the buffer is too small.
154418         Problem reported by Mark D. Baushke.
154420 2004-11-03  Albert Chin  <china@thewrittenword.com>
154421             Paul Eggert  <eggert@cs.ucla.edu>
154423         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
154424         equivalent, substitute $ac_type for equivalent type rather than
154425         blindly using uint32_t *always* which won't work if uint32_t is not
154426         available.  Define _UINT32_T to work around typedef of uint32_t if
154427         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
154428         2.5.1.
154430 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
154432         * m4/jm-macros.m4: Sync from coreutils.
154433         (gl_MACROS): Check for mbrlen, for pathchk.
154434         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
154436 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
154438         * lib/xreadlink.c (MAXSIZE): New macro.
154439         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
154440         size does not exceed MAXSIZE.  Avoid cast.
154441         As suggested by Mark D. Baushke in
154442         <http://lists.gnu.org/r/bug-gnulib/2004-11/msg00009.html>,
154443         if readlink fails with buffer size just under MAXSIZE, try again
154444         with MAXSIZE.
154446 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
154448         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
154450 2004-11-02  Derek R. Price  <derek@ximbiot.com>
154451         and  Paul Eggert  <eggert@cs.ucla.edu>
154453         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
154454         (get_date): Overparenthesize to avoid GCC warning.
154456 2004-11-02  Bruno Haible  <bruno@clisp.org>
154458         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
154459         returns void.
154461 2004-11-02  Bruno Haible  <bruno@clisp.org>
154463         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
154464         function returns void.
154466 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
154468         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
154469         fflush_unlocked, flockfile, funlockfile, funlockfile,
154470         fputs_unlocked, putc_unlocked.
154472 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
154474         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
154475         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
154476         already declared.
154478 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
154480         * modules/getdate (Files): Add doc/getdate.texi.
154481         (Depends-on): Add setenv, xalloc.
154483 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
154485         * lib/getdate.y: Add support for TZ="foo" within a date string.
154486         Fix some bugs near time_t boundaries.  Reject dates with
154487         out-of-range components, e.g., "Sept 31".
154488         Include <stdlib.h>, "setenv.h", "xalloc.h".
154489         (ISDIGIT_LOCALE): Remove; unused.
154490         Note that the TZ and time functions used here are not reentrant.
154491         (mktime_ok, get_tz): New functions.
154492         (TZBUFSIZE): New constant.
154493         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
154494         This requires that we sometimes generate our own TZ="XXX..." setting.
154496 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
154498         * doc/getdate.texi: New file, from coreutils with modifications for
154499         the new TZ parsing.
154501 2004-10-27  Derek R. Price  <derek@ximbiot.com>
154503         * lib/mktime.c (not_equal_tm): Remove redundant check.
154505 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
154507         * modules/regex (lib_SOURCES): Add regex.c.
154508         Reported by James Youngman in
154509         <http://lists.gnu.org/r/bug-gnulib/2004-10/msg00199.html>.
154511 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
154513         * lib/getdate.y: Use Bison 1.875 features, and some minor
154514         code cleanups.  This change does not affect semantics.
154515         Don't include <stdlib.h>; no longer needed.
154516         Don't include unlocked-io.h; only the "#if TEST" code uses
154517         stdio, and performance isn't crucial there.
154518         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
154519         Bison 1.875 features as described below.
154520         All uses of "PC." replaced by "pc->".
154521         (YYSTYPE): Add a forward declaration.
154522         (yylex, yyerror): Use full prototypes in forward decls.
154523         Use "%pure-parser" rather than obsolescent "%pure_parser".
154524         Use %parse-param and %lex-param instead of obsolescent
154525         YYPARSE_PARAM and YYLEX_PARAM.
154526         (meridian_table, month_and_day_table, time_units_table,
154527         relative_time_table, time_zone_table, military_table,
154528         lookup_zone, lookup_word, get_date):
154529         Use NULL instead of 0 where appropriate.
154530         (to_hour): Avoid abort (), to avoid a dependency on
154531         stdlib.h.
154532         (yyerror, yylex): Now accepts parser_control * arg.
154533         (main) [TEST]: Use '\0' rather than 0 for char.
154535 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
154537         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
154539 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
154541         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
154542         It's now the caller's responsibility to handle the case where
154543         !HAVE_GETPAGESIZE && !defined getpagesize.
154545         * lib/mktime.c (leapyear): Arg is long int, not int.
154547 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
154549         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
154551 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
154553         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
154554         missing.  Problem reported by James Youngman.
154556 2004-10-16  Simon Josefsson  <jas@extundo.com>
154558         * gnulib-tool: Fix comments.  Fix parse problem.
154559         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
154561 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
154563         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
154564         implementation of getopt_long.  Problem reported by Alexander Taler in:
154565         http://lists.gnu.org/r/bug-gnulib/2004-10/msg00103.html
154567 2004-10-15  Bruno Haible  <bruno@clisp.org>
154569         * gnulib-tool: Untabify. Initialize supplied_libname.
154570         (func_usage): More homogenous output.
154571         (func_modules_transitive_closure, func_modules_to_filelist,
154572         func_emit_lib_Makefile_am): New functions.
154573         (func_import): New function, extracted from big case statement. Use
154574         func_get_license, func_modules_transitive_closure,
154575         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
154576         opt_lgpl. Don't use test -a, as it's not portable.
154577         (func_create_testdir): Use func_modules_transitive_closure,
154578         func_modules_to_filelist, func_emit_lib_Makefile_am.
154580 2004-10-15  Bruno Haible  <bruno@clisp.org>
154582         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
154584 2004-10-15  Bruno Haible  <bruno@clisp.org>
154586         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
154587         the portions belonging to each module.
154588         Suggested by Derek Robert Price <derek@ximbiot.com>.
154590 2004-10-12  Simon Josefsson  <jas@extundo.com>
154592         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
154593         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
154594         to real functions.
154596 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
154598         * modules/vsnprintf: New file.
154600 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
154602         * m4/vsnprintf.m4: New file.
154604 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
154606         * lib/vsnprintf.h: New file.
154607         * lib/vsnprintf.c: New file.
154609 2004-10-11  Bruno Haible  <bruno@clisp.org>
154611         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
154612         vsnprintf.
154614 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
154616         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
154618 2004-10-07  Bruno Haible  <bruno@clisp.org>
154620         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
154621         fits into the provided buffer.
154623 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
154625         * lib/diacrit.c, diacrit.h: Add GPL notice.
154627         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
154628         notice.
154629         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
154630         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
154631         This avoids a potential constant-folding bug.
154633 2004-10-05  Bruno Haible  <bruno@clisp.org>
154635         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
154636         for the declaration of strsep.
154638 2004-10-05  Bruno Haible  <bruno@clisp.org>
154640         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
154642 2004-10-04  Simon Josefsson  <jas@extundo.com>
154644         * modules/memmem: New file.
154645         * tests/test-memmem.c: New file.
154646         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
154648 2004-10-04  Simon Josefsson  <jas@extundo.com>
154650         * m4/memmem.m4: New file.
154652 2004-10-04  Simon Josefsson  <jas@extundo.com>
154654         * lib/memmem.h: New file.
154655         * lib/memmem.c: New file, taken from glibc.
154657 2004-10-04  Simon Josefsson  <jas@extundo.com>
154659         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
154660         '#ifdef USE_UNLOCKED_IO'.
154662 2004-10-04  Simon Josefsson  <jas@extundo.com>
154664         * config/srclist.txt: Add memmem from glibc.
154666 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
154668         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
154670         * modules/argmatch, modules/argp, modules/closeout, modules/error,
154671         modules/exclude, modules/getdate, modules/getline,
154672         modules/getndelim2, modules/getpass, modules/getpass-gnu,
154673         modules/getusershell, modules/linebuffer, modules/md5,
154674         modules/mountlist, modules/posixtm, modules/readtokens,
154675         modules/readutmp, modules/regex, modules/sha1,
154676         modules/version-etc, modules/yesno:
154677         Remove dependency on unlocked-io.
154679 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
154681         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
154683         * m4/unlocked-io.m4: Add copyright notice.
154684         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
154686 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
154688         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
154689         * lib/xmalloc.c (xmemdup): Likewise.
154690         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
154691         XFREE): Remove these long-obsolescent macros.
154692         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
154693         * lib/xstrdup.c: Remove.
154695         * lib/regex.c (re_comp): Cast gettext return value to char *,
154696         Problem reported by Martin Neitzel via Mark D. Baushke.
154698 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
154700         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
154701         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
154702         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
154703         regex.c, sha1.c, version-etc.c, yesno.c:
154704         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
154705         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
154706         the includer's responsibility.
154708         Sync from coreutils.
154710         * lib/modechange.c (mode_compile): Don't decrement a pointer that
154711         points to the start of a string, as the C Standard says the
154712         resulting behavior is undefined.
154714         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
154715         simple -> simple_backups, numbered_existing ->
154716         numbered_existing_backups, numbered -> numbered_backups
154717         to avoid shadowing problems.  All uses changed.
154718         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
154719         * lib/backupfile.c (check_extension, numbered_backup):
154720         Rename locals to avoid shadowing 'basename'.
154721         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
154722         once.
154724         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
154725         * lib/.cvsignore: Add getopt.h.
154727 2004-10-04  Bruno Haible  <bruno@clisp.org>
154729         * modules/README: New file.
154730         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
154731         not a module.
154733 2004-10-02  Jim Meyering  <jim@meyering.net>
154735         * lib/dirfd.h, getpagesize.h: Add copyright notice.
154737 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
154739         * modules/strsep: New file.
154741 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
154743         * m4/strsep.m4: New file.
154745 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
154747         * lib/strsep.h: New file.
154748         * lib/strsep.c: New file.
154750 2004-10-01  Simon Josefsson  <jas@extundo.com>
154752         * lib/snprintf.c (snprintf): Handle size==0.
154754 2004-10-01  Simon Josefsson  <jas@extundo.com>
154755             Bruno Haible  <bruno@clisp.org>
154757         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
154758         (snprintf): Declare 'args'.
154760 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
154762         * lib/snprintf.c: Remove comments as to why each header is needed.
154764 2004-10-01  Bruno Haible  <bruno@clisp.org>
154766         * MODULES.html.sh: Add strsep.
154768 2004-09-30  Simon Josefsson  <jas@extundo.com>
154770         * modules/snprintf: New file.
154772 2004-09-30  Simon Josefsson  <jas@extundo.com>
154774         * m4/snprintf.m4: New file.
154776 2004-09-30  Simon Josefsson  <jas@extundo.com>
154778         * lib/snprintf.h, lib/snprintf.c: New files.
154780 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
154782         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
154783         (hol_entry_help): Never translate an empty string.
154784         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
154785         * lib/argp.h (OPTION_NO_TRANS): New option.
154787 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
154789         * modules/argp (Maintainer): Replace Simon Josefsson
154790         by Sergey Poznyakoff.
154792 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
154794         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
154795         changes merged back into glibc.
154797 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
154799         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
154801 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
154803         * lib/xvasprintf.c: Include xalloc.h.
154804         (xvasprintf): Use xalloc_die, not xmalloc_die.
154806 2004-09-29  Bruno Haible  <bruno@clisp.org>
154808         * modules/alloca-opt: New file, derived from modules/alloca.
154809         * modules/allocsa: Depend on alloca-opt instead of alloca.
154810         * modules/setenv: Likewise.
154811         * modules/vasnprintf: Likewise.
154812         * MODULES.html.sh: Add alloca-opt.
154814 2004-09-28  Simon Josefsson  <jas@extundo.com>
154816         * gnulib-tool: New parameter --lgpl, to asseert that modules are
154817         LGPL, and to replace license template from GPL to LGPL.
154819 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
154821         * modules/dummy: Change license to LGPL.
154823 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
154825         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
154827 2004-09-24  Simon Josefsson  <jas@extundo.com>
154829         * modules/minmax (License): Change from GPL to LGPL.
154831 2004-09-23  Simon Josefsson  <jas@extundo.com>
154833         * gnulib-tool (--import): Typo.
154835 2004-09-23  Simon Josefsson  <jas@extundo.com>
154837         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
154839 2004-09-22  Bruno Haible  <bruno@clisp.org>
154841         * modules/*: Add 'License' field.
154842         * gnulib-tool: Accept --extract-license option.
154843         (func_get_license): New function.
154845 2004-09-21  Bruno Haible  <bruno@clisp.org>
154847         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
154848         Reported by Simon Josefsson.
154850 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
154852         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
154853         gl_AC_TYPE_LONG_LONG.
154855 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
154857         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
154859 2004-09-18  Simon Josefsson  <jas@extundo.com>
154860         and  Paul Eggert  <eggert@cs.ucla.edu>
154862         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
154863         calls with autoreconf.  Define GL_LIB.
154865 2004-09-14  Karl Berry  <karl@gnu.org>
154867         * config/srclist.txt: unsync setenv.c, sigh.
154869 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
154871         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
154872         Problem reported by Bruno Haible in:
154873         http://lists.gnu.org/r/bug-tar/2004-09/msg00023.html
154875 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
154877         * config/srclist.txt: Comment out argp-pvh.c.
154879 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
154881         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
154882         in case some system header has #define'd it.  Problem reported by
154883         Soeren D. Schulze in
154884         <http://lists.gnu.org/r/bug-gnulib/2004-09/msg00017.html>.
154886 2004-09-09  Karl Berry  <karl@gnu.org>
154888         * regex.[ch]: delete from the root.  These were supposed to be
154889                 synced with emacs cvs, but this has not happened for about
154890                 a year, and anyway nothing else uses emacs regex.[ch].
154891                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
154892                 lib/regex[.ch] is untouched.
154894 2004-09-09  Bruno Haible  <bruno@clisp.org>
154896         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
154898 2004-09-09  Bruno Haible  <bruno@clisp.org>
154900         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
154901         modifications.
154902         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
154904 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
154906         * modules/xvasprintf: New file.
154907         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
154909 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
154911         * lib/xvasprintf.h: New file.
154912         * lib/xvasprintf.c: New file.
154913         * lib/xasprintf.c: New file.
154915 2004-09-08  Bruno Haible  <bruno@clisp.org>
154917         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
154919 2004-09-08  Bruno Haible  <bruno@clisp.org>
154921         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
154922         length is > INT_MAX.
154923         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
154924         more.
154926 2004-09-08  Bruno Haible  <bruno@clisp.org>
154928         * lib/stdint_.h: New file, taken from GNU clisp.
154930 2004-09-08  Bruno Haible  <bruno@clisp.org>
154931             Oskar Liljeblad  <oskar@osk.mine.nu>
154933         * modules/stdint: New file.
154934         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
154936 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
154938         Import from coreutils.
154939         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
154940         strings on unbounded length.  alloca's performance benefits aren't
154941         that important here.
154942         (V_STRDUP): Remove.
154943         (parse_with_separator): New function, with most of the internals
154944         of the old parse_user_spec.  Allow user to omit both user and group,
154945         for compatibility with FreeBSD.
154946         Clone only the user name, not the entire spec.
154947         Do not set *uid, *gid unless entirely successful.
154948         Avoid memory leak in some failing cases.
154949         Fix regression for USER.GROUP reported by Dmitry V. Levin in
154950         <http://lists.gnu.org/r/bug-coreutils/2004-08/msg00102.html>
154951         (parse_user_spec): Rewrite to use parse_with_separator.
154953 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
154955         * modules/userspec: Don't depend on alloca.
154957 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
154959         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
154961 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
154963         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
154964         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
154965         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
154967 2004-08-16  Simon Josefsson  <jas@extundo.com>
154969         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
154970         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
154971         Add --dry-run for --import.
154972         Let user provided command line parameters override configure.ac
154973         settings.
154975 2004-08-12  Simon Josefsson  <jas@extundo.com>
154977         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
154978         as discussed with Paul Eggert in threads rooted at
154979         <http://lists.gnu.org/r/bug-gnulib/2004-06/msg00039.html>
154980         and
154981         <http://lists.gnu.org/r/bug-gnulib/2004-07/msg00001.html>.
154982         Before, the test was empty, and relied on ELIDE_CODE in source
154983         code.)
154984         (gl_PREREQ_GETOPT): New macro.
154985         (gl_GETOPT): Use them.
154987 2004-08-12  Simon Josefsson  <jas@extundo.com>
154989         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
154990         * lib/getopt_.h: Renamed from getopt.h.
154992 2004-08-12  Simon Josefsson  <jas@extundo.com>
154994         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
154995         Change default library name from libfoo to libgnu.
154996         Now, if you have a configure.ac that says:
154997                 gl_SOURCE_BASE(gl)
154998                 gl_M4_BASE(gl/m4)
154999                 gl_MODULES(error getopt etcetera)
155000                 gl_INIT
155001         you can import all you need by running:
155002                 ../gnulib/gnulib-tool --import
155004         * modules/getopt (Files): Rename getopt.h to getopt_.h.
155005         (Makefile.am): Rewrite, use logic from argz.
155006         (Include): Use <getopt.h> instead of "getopt.h".
155008 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
155010         * modules/argp (Files): Add m4/unlocked-io.m4.
155011         (Depends-on): Add extensions.
155013 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
155015         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
155016         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
155017         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
155018         Check for program_invocation_name, program_invocation_short_name,
155019         flockfile, funlockfile, features.h, _getopt_long_only_r.
155021 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
155023         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
155024         its complicated substitute.
155025         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
155026         and program_invocation_name.
155027         (__argp_basename) [!_LIBC]: Remove; the only use was
155028         replaced by its body.
155029         (__argp_short_program_name): Change condition from
155030         !defined __argp_short_program_name to
155031         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
155032         to match argp-namefrob.h.
155033         (__argp_failure): Don't assume strerror_r returns char *.
155034         * lib/argp-parse.c (N_): Define unconditionally.
155035         (argp_default_options): Fill out initializers with 0 to avoid
155036         gcc warnings.
155038 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
155040         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
155041         getopt1.c.
155043 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
155045         Merge from coreutils.
155047         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
155049         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
155050         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
155052 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
155054         Merge from coreutils.
155056         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
155057         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
155058         for Reliant Unix 5.43.
155060         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
155061         (union fooround): Use uintmax_t, not long int.
155062         The rest is a merge from libc:
155063         [defined _LIBC]: Include <shlib-compat.h>.
155064         (_obstack) [defined _LIBC]: Remove after 2.3.4.
155066         * lib/settime.c (settime): Recode to avoid warning with
155067         Sun Forte C 6U2.
155069         * lib/strverscmp.c: Convert to UTF-8.
155071 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
155073         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
155074         m4/uintmax_t.m4.
155076 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
155078         * modules/xalloc-die: New file.
155079         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
155081         * modules/md5 (Files): Add m4/uint32_t.m4.
155082         * modules/sha1: Renamed from modules/sha.
155083         (Files):
155084         Rename lib/sha.h to lib/sha1.h.
155085         Rename lib/sha.c to lib/sha1.c.
155086         Rename m4/sha.m4 to m4/sha1.m4.
155087         (lib_SOURCES): Likewise.
155088         (configure.ac): Rename gl_SHA to gl_SHA1.
155089         (Include): sha.h -> sha1.h.
155091 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
155093         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
155094         * m4/sha1.m4: Renamed from sha.m4.
155095         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
155097 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
155099         * lib/obstack.h (obstack_empty_p):
155100         Don't assume that chunk->contents is suitably aligned.
155101         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
155102         Likewise. Problem reported by Benno in
155103         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
155105         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
155106         readable.  This could be improved further but it'd take some work.
155108 2004-08-08  Simon Josefsson  <jas@extundo.com>
155110         * modules/xgethostname (Depends-on): Remove exit and error (not
155111         used).
155113         * modules/getpass-gnu: Add getpass.h.
155114         (Depends-on): Add stdbool.
155115         * modules/getpass: Add getpass.h.
155117 2004-08-08  Simon Josefsson  <jas@extundo.com>
155119         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
155120         Check getpass declaration.
155122 2004-08-08  Simon Josefsson  <jas@extundo.com>
155124         * lib/xgethostname.c: Don't include error.h (not used).
155126         * lib/getpass.h: Add.
155127         * lib/getpass.c: Include getpass.h first.
155129 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
155131         * lib/xalloc-die.c: New file.
155132         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
155133         All uses removed.
155134         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
155135         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
155136         xalloc-die.c.
155137         (_, N_, xalloc_die): Move to xalloc-die.c.
155138         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
155139         so that we needn't mess with xalloc_msg_memory_exhausted.
155141         * lib/sha1.h: Renamed from sha.h.
155142         (SHA1_H): Renamed from _SHA_H.
155143         (sha1_ctx): Renamed from sha_ctx.
155144         (sha1_init_ctx): Renamed from sha_init_ctx.
155145         (sha1_process_block): Renamed from sha_process_block.
155146         (sha1_process_bytes): Renamed from sha_process_bytes.
155147         (sha1_finish_ctx): Renamed from sha_finish_ctx.
155148         (sha1_read_ctx): Renamed from sha_read_ctx.
155149         (sha1_stream): Renamed from sha_stream.
155150         (sha1_buffer): Renamed from sha_buffer.
155151         * lib/sha1.c: Likewise; renamed from sha.c.
155152         Do not include <sys/types.h>.
155153         Include <stddef.h> rather than <stdlib.h>.
155155 2004-08-08  Bruno Haible  <bruno@clisp.org>
155157         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
155158         FILESYSTEM_PREFIX_LEN.
155159         * lib/progreloc.c: Likewise.
155160         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
155162 2004-08-06  Simon Josefsson  <jas@extundo.com>
155164         * modules/progname (Depends-on): Don't depend on stdbool.
155166 2004-08-06  Simon Josefsson  <jas@extundo.com>
155168         * modules/getsubopt: New file.
155169         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
155170         getsubopt.
155172 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
155174         More merge from coreutils.
155176         * m4/utimens.m4, m4/utimecmp.m4: New files.
155177         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
155178         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
155179         prereq.m4, sha.m4: Import changes from coreutils.
155181 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
155183         More merge from coreutils.
155184         * modules/raise, modules/readtokens0, modules/utimens:
155185         * modules/utimecmp, module/xnanosleep: New files.
155186         * modules/strftime: Add lib/strftime.h.
155187         Change include from <time.h> to "strftime.h".
155188         * modules/yesno: Add lib/yesno.h.
155189         * modules/backupfile: Remove lib/addext.c.
155190         * modules/euidaccess: Add stat-macros.h.
155191         * modules/canonicalize, modules/euidaccess,
155192         modules/filemode, modules/lchown, modules/makepath,
155193         modules/rmdir, modules/stat: Likewise.
155195 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
155197         Merge from tar.
155198         * lib/argp-help.c (make_hol, hol_append): Don't assume that
155199         SIZE_MAX is a valid preprocessor constant.
155200         (__argp_basename): Change from "#ifndef _LIBC"
155201         to "#ifndef __argp_short_program_name", so that
155202         we don't compile these functions for tar.
155204         More merges from coreutils.
155205         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
155206         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
155207         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
155208         * lib/addext.c: Remove; no longer needed.
155209         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
155210         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
155211         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
155212         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
155213         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
155214         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
155215         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
155216         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
155217         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
155218         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
155219         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
155220         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
155221         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
155222         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
155223         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
155224         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
155225         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
155226         Import changes from coreutils.
155228 2004-08-05  Simon Josefsson  <jas@extundo.com>
155230         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
155232 2004-08-05  Simon Josefsson  <jas@extundo.com>
155234         * m4/getsubopt.m4: New file.
155236 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
155238         Merge from coreutils.
155240         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
155241         * m4/getcwd-path-max.m4: New files.
155243         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
155244         FILESYSTEM_PREFIX_LEN ->
155245         FILE_SYSTEM_PREFIX_LEN.
155246         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
155247         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
155248         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
155249         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
155251         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
155252         prerequisite modules now handle the DOS stuff.
155253         Don't check for unistd.h.
155255 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
155257         Merge from coreutils.
155259         * lib/.gdb-history: Remove; this doesn't belong here.
155261         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
155262         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
155263         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
155264         * lib/getcwd.c: New files.
155266         * lib/dirname.h: Include <stdbool.h>.
155267         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
155268         for consistency with POSIX terminology.  All uses changed.
155269         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
155270         (strip_trailing_slashes): Use bool for booleans.
155271         * lib/stripslash.c (strip_trailing_slashes): Likewise.
155273         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
155274         sometimes returns a positive errno value even when it succeeds.
155275         (print_errno_message) [!LIBC]: Fall back on strerror if
155276         __strerror_r fails.
155278         * lib/path-concat.c (mempcpy): Don't define if a system header defines
155279         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
155280         (longest_relative_suffix): New function.
155281         (path_concat): Use it.  Assume first argument is not NULL.
155282         Port to DOS.  Omit redundant separators.
155283         Report an error instead of returning NULL.
155284         Use mempcpy instead of memcpy.
155285         (xpath_concat): Remove: not declared or used.
155287         * lib/same.h: Include <stdbool.h>
155288         (same_name): Return bool, not int.
155289         * lib/same.c (same_name): Likewise.
155290         (errno): Don't declare; we assume C89 or better now.
155292         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
155293         if not already defined.
155295         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
155296         * lib/dup-safer.c (errno): Likewise.
155298 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
155300         Merge from coreutils.
155301         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
155302         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
155303         * modules/path-concat: Don't depend on strdup.
155305 2004-08-03  Simon Josefsson  <jas@extundo.com>
155307         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
155308         * lib/progname.h: Don't include stdbool.h.
155310 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
155312         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
155313         * MODULES.html.sh (func_all_modules): Remove fatal.
155315 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
155317         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
155319 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
155321         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
155322         working.
155324 2004-08-02  Simon Josefsson  <jas@extundo.com>
155326         * lib/getsubopt.h: New file, with comments from Bruno Haible.
155327         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
155328         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
155330 2004-08-01  Simon Josefsson  <jas@extundo.com>
155332         * lib/xgetdomainname.c: Include stdlib.h, for free().
155334 2004-07-19  Bruno Haible  <bruno@clisp.org>
155336         * MODULES.html.sh (func_all_modules): Add dummy.
155338 2004-07-16  Simon Josefsson  <jas@extundo.com>
155340         * modules/dummy: New file.
155342 2004-07-16  Simon Josefsson  <jas@extundo.com>
155344         * lib/dummy.c: New file.
155346 2004-07-16  Bruno Haible  <bruno@clisp.org>
155348         * lib/backupfile.h: Add extern "C" for C++.
155349         * lib/closeout.h: Likewise.
155350         * lib/copy-file.h: Likewise.
155351         * lib/findprog.h: Likewise.
155352         * lib/full-write.h: Likewise.
155353         * lib/pathname.h: Likewise.
155354         * lib/progname.h: Likewise.
155355         * lib/stpcpy.h: Likewise.
155356         * lib/stpncpy.h: Likewise.
155357         * lib/strcase.h: Likewise.
155358         * lib/strstr.h: Likewise.
155359         * lib/xalloc.h: Likewise.
155361         * lib/mbswidth.h: Add extern "C" for C++.
155362         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
155364 2004-07-13  Robert Millan  <robertmh@gnu.org>
155366         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
155368 2004-07-09  Simon Josefsson  <jas@extundo.com>
155370         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
155371         failed without this.)
155373 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
155375         * modules/chown (Files): Add lib/fchown-stub.c, since
155376         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
155378 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
155380         * lib/fchown-stub.c: New file.
155382 2004-06-24  Jim Meyering  <jim@meyering.net>
155384         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
155386 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
155388         * modules/argz: Omit "#include".
155390         * MODULES.html.sh (func_all_modules): Add calloc, to match
155391         2004-06-01 addition of calloc module.
155393 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
155395         * m4/argz.m4: New file, which is autoupdated from libtool.
155397 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
155399         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
155400         libtool.
155402 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
155404         * config/srclist-update: Don't insist on "USA." before the
155405         close-comment, as libtool omits the period and puts the */ on a
155406         separate line.
155407         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
155408         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
155410 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
155412         * modules/argz: New file.
155413         * MODULES.html.sh (func_all_modules): Add argz.
155415 2004-06-12  Jim Meyering  <jim@meyering.net>
155416         and  Paul Eggert  <eggert@cs.ucla.edu>
155418         * modules/hash (Files): Add lib/xalloc.h.
155419         * modules/pipe (Depends-on): Add wait-process.
155420         * modules/stat (Depends-on): Add xalloc.
155421         * modules/userspec (Files): Add lib/userspec.h.
155422         * modules/xstrtol (Depends-on): Add error.
155424 2004-06-10  Jim Meyering  <jim@meyering.net>
155426         * lib/calloc.c: New file.
155428 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
155430         * lib/getdate.y (yylex): Allow space between sign and number.
155431         Problem reported by Dan Jacobson.
155433 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
155435         Merge from coreutils CVS.
155437         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
155438         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
155439         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
155440         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
155441         xstrtol.m4: Fix copyright date and/or serial number.
155443         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
155444         See if we need an fchown replacement.
155445         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
155446         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
155447         and use the replacement function if we detect either defect.
155449         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
155450         gl_UTIMECMP.
155452 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
155453         and  Jim Meyering  <jim@meyering.net>
155455         Merge from coreutils CVS.
155457         * lib/stat-macros.h: New file, with contents from file-type.h
155458         and coreutils' system.h.
155459         * lib/file-type.c: Include "stat-macros.h".
155460         * lib/file-type.h (file_type): Move all macro definitions to new file,
155461         stat-macros.h.
155462         * modules/file-type: Add lib/stat-macros.h.
155464         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
155465         Wrap old code with this conditional.
155466         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
155467         function that does not dereference symlinks.
155468         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
155470         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
155471         dependency problems.
155472         (xreadlink): Accept new arg SIZE, for efficiency.
155473         All decls and uses changed.
155474         * lib/xreadlink.h: Include <stddef.h>, for size_t.
155476         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
155477         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
155479         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
155480         sysexits.h.
155482 2004-06-01  Jim Meyering  <jim@meyering.net>
155484         * m4/calloc.m4: New file.
155485         * modules/calloc: New file.
155487 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
155489         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
155490         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
155491         Also, fix a typo in a diagnostic.
155493 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
155495         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
155496         or AC_FUNC_REALLOC.
155498 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
155500         * modules/hash (Depends-on): Remove malloc, realloc.
155501         * modules/xalloc (Depends-on): Likewise.
155503         * README: Mention that the 'free' module works around the
155504         problem with 'free (0)'.
155505         Mention LIA-1 and C99.
155506         Add a copyright notice.
155508         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
155509         macros to be defined.
155510         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
155511         the allocator returns NULL because the requested size is zero.
155513 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
155515         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
155516         var.  Add comment explaining why libc still defines it.  This
155517         merges the following patch from glibc:
155518         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
155520 2004-05-20  Andreas Schwab  <schwab@suse.de>
155522         * m4/free.m4: Replace free if it not known to work, not the other
155523         way round.
155525 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
155527         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
155528         present in glibc since revision 1.1 of this file.
155529         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
155530         obstack_alignment_mask, obstack_alloc, obstack_base,
155531         obstack_blank, obstack_blank_fast, obstack_chunk_size,
155532         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
155533         obstack_grow0, obstack_init, obstack_int_grow,
155534         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
155535         obstack_next_free, obstack_object_size, obstack_ptr_grow,
155536         obstack_ptr_grow_fast, obstack_room): Remove declarations of
155537         nonexistent functions.
155539 2004-05-18  Karl Berry  <karl@gnu.org>
155541         * config/srclist.txt: break link for vasnprintf.c.
155543 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
155545         Port obstack to the AS/400, where pointers are 16 bytes wide and
155546         you cannot cast an integer to a valid pointer.  This patch is
155547         currently waiting to be integrated into glibc; see
155548         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
155550         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
155551         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
155552         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
155553         (struct obstack): temp member is now a union of a pointer and
155554         an integer, instead of an integer.  All integer uses changed.
155555         This does not affect the physical layout of struct obstack,
155556         except on hosts (like the AS/400) where the size or alignment of
155557         void * is greater than that of ptrdiff_t.
155558         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
155559         __STDC__)]: Store temporary in pointer member of union, not
155560         integer member.
155561         * lib/obstack.c: Include <stddef.h>, for offsetof.
155562         (struct fooalign): Remove; it doesn't need a name.
155563         (union fooround): Change double to long double, and add void *.
155564         (DEFAULT_ALIGNMENT): Use offsetof to compute.
155565         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
155566         not a macro.  Hence the values are always int; so remove all
155567         casts-to-int in uses.
155569 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
155571         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
155572         we can get this patch merged into glibc.
155574 2004-05-17  Derek R. Price  <derek@ximbiot.com>
155575             Paul Eggert  <eggert@cs.ucla.edu>
155577         * m4/argp: Depend on alloca.
155579 2004-05-17  Derek R. Price  <derek@ximbiot.com>
155580             Paul Eggert  <eggert@cs.ucla.edu>
155582         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
155583         freecoding.
155585 2004-05-17  Bruno Haible  <bruno@clisp.org>
155587         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
155588         precision that consists of a '.' followed by an empty digit string.
155589         Patch by Tor Lillqvist <tml@iki.fi>.
155591 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
155593         * modules/getdate: Depend on alloca.
155594         * modules/setenv: Likewise.
155596 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
155598         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
155599         for backward compatibility with older code.  We need our own
155600         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
155601         it under some other name, and our alloca.h will define it.
155603 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
155604             Derek Price  <derek@ximbiot.com>
155606         * lib/alloca.c: Include <alloca.h>, to get our interface.
155607         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
155608         include <alloca.h> first.  Use C89 prototype for alloca; this
155609         requires including <stddef.h> for size_t.  Use extern "C" if C++.
155610         Use #elif for simplicity, since we can assume C89 now.
155611         Don't try to source the system alloca.h since it will not be found
155612         and to prevent recursively including its replacement.
155613         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
155614         * lib/regex.c: Likewise.
155616 2004-05-16  Derek Price  <derek@ximbiot.com>
155617             Paul Eggert  <eggert@cs.ucla.edu>
155619         getline cleanup.  This changes the getndelim2 API: both order of
155620         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
155621         no delimiter).
155623         * lib/getline.c: Don't include stddef.h or stdio.h, since our
155624         interface does that.
155625         (getline): Always use getdelim, so that we don't have two
155626         copies of this code.
155627         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
155628         if available.
155629         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
155630         (GETNDELIM2_MAXIMUM): New macro.
155631         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
155632         instead of the old practice of delim2==0.  All callers changed.
155633         Return -1 on overflow, instead of returning junk.
155634         Do not set *linesize unless allocation succeeds.
155635         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
155636         that we include sys/types.h.
155637         * lib/getnline.h: Likewise.
155638         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
155639         (getndelim2): Reorder arguments.
155640         * lib/getnline.c (getnline, getndelim):
155641         Don't discard the NMAX argument.
155642         (getnline): Invoke getndelim, to avoid code duplication.
155643         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
155644         of (size_t) -1 by callers of the getnline family.
155646 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
155648         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
155649         Check for gettimeofday.
155650         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
155651         Check for settimeofday, stime.
155653 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
155655         * lib/nanosleep.c (suspended): Change its type from int to
155656         sig_atomic_t volatile.
155657         (first_call): Make it private to rpl_nanosleep, and have it
155658         be zero initially as that's a bit faster.
155659         (my_usleep): Round up fractional times instead of truncating them,
155660         as this is the usual meaning for 'sleep'.
155662         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
155663         doesn't work.
155664         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
155665         (ENOSYS): Define if not defined.
155666         (settime): Fall back on stime if it exists and settimeofday fails.
155667         But don't bother with fallbacks if a method fails with errno == EPERM.
155669 2004-05-11  Jim Meyering  <jim@meyering.net>
155671         Prior to this change, the save_cwd caller required read access to the
155672         current directory on most systems (ones with the fchdir function).
155674         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
155675         fails, try write-only, and finally, resort to using xgetcwd.
155677 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
155679         * lib/obstack.c, obstack.h: Import changes from libc.
155681 2004-05-04  Derek Price  <derek@ximbiot.com>
155683         * modules/argp: Remove dependency on alloca.
155685 2004-04-28  Bruno Haible  <bruno@clisp.org>
155687         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
155688         also implicitly appends .exe to executables.
155689         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
155690         accepts Windows pathnames.
155691         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
155692         Treat Cygwin like Windows, since it now accepts Windows pathnames.
155693         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
155694         Treat Cygwin like Windows, since it now accepts Windows pathnames.
155695         Reported by Derek Robert Price <derek@ximbiot.com>.
155697 2004-04-27  Derek Price  <derek@ximbiot.com>
155699         * m4/dos.m4 (gl_AC_DOS): Add Cygwin to list of Windows/DOS
155700         environments that accept backslashes and drive letters in paths.
155702 2004-04-21  Karl Berry  <karl@gnu.org>
155704         * config/srclist.txt (localcharset.c): break sync.
155706 2004-04-20  Paul Eggert  <eggert@twinsun.com>
155708         * m4/host-os.m4: Add a copyright notice.
155710 2004-04-20  Jim Meyering  <jim@meyering.net>
155712         * modules/dirfd: Change UTILS_ macro name prefix to gl_.
155713         * modules/mkstemp: Likewise.
155714         * modules/mkdir: Likewise.
155716         Change UTILS_ to gl_ in AC_DEFINE'd names.
155717         Change utils_- and jm_-prefixed variables, too.
155718         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
155719         UTILS_FUNC_MKDIR_TRAILING_SLASH.
155720         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
155722         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
155723         Don't emit trailing blanks.
155724         Also rename jm_-prefixed variables to have gl_ prefix.
155726         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
155727         Also rename jm_-prefixed variables to have gl_ prefix.
155729         * m4/jm-macros.m4: Reflect the renamings.
155730         * m4/prereq.m4: Likewise.
155732 2004-04-20  Jim Meyering  <jim@meyering.net>
155734         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
155735         memory.
155737 2004-04-20  Jim Meyering  <jim@meyering.net>
155738             Bruno Haible  <bruno@clisp.org>
155740         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
155741         memory when realloc fails.
155743 2004-04-19  Jim Meyering  <jim@meyering.net>
155745         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
155746         now that readutmp.c may call `free (0)'.
155748 2004-04-19  Bruno Haible  <bruno@clisp.org>
155750         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
155751         * m4/inttypes_h.m4: Likewise.
155752         * m4/stdint_h.m4: Likewise.
155753         * m4/intmax_t.m4: Likewise.
155754         * m4/uintmax_t.m4: Likewise.
155756 2004-04-18  Jim Meyering  <jim@meyering.net>
155758         * m4/prereq.m4: Don't forbid jm_ prefix.
155760         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
155761         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
155762         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
155763         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
155764         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
155765         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
155766         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
155767         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
155768         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
155769         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
155770         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
155771         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
155772         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
155773         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
155774         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
155775         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
155776         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
155777         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
155778         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
155780 2004-04-18  Jim Meyering  <jim@meyering.net>
155782         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
155783         failure, don't leak memory and do call END_UTMP_ENT.
155785 2004-04-18  Jim Meyering  <jim@meyering.net>
155787         Change jm_ to gl_ in AC_DEFINE'd names.
155788         * modules/assert, modules/chown, modules/fpending:
155789         * modules/ftruncate, modules/getgroups, modules/group-member:
155790         * modules/lchown, modules/lstat, modules/memcmp:
155791         * modules/nanosleep, modules/putenv, modules/stat:
155792         * modules/strftime, modules/unlocked-io, modules/utime:
155793         * modules/xstrtoimax, modules/xstrtoumax:
155795 2004-04-16  Jim Meyering  <jim@meyering.net>
155797         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
155798         coreutils' stat program.
155799         (gl_PREREQ): Don't require jm_PREREQ_STAT.
155801 2004-04-12  Paul Eggert  <eggert@twinsun.com>
155803         * config/srclist.txt: Restore setenv.c, unsetenv.c from gettext.
155804         Add intmax.m4, printf-posix.m4, sig_atomic_t.m4,
155805         signalblocking.m4, ssize_t.m4.
155806         * lib/unsetenv.c: Regenerate: this subtracts 1 from the
155807         copyright year (!).
155808         * m4/printf-posix.m4: Regenerate.
155810         * modules/inttostr (EXTRA_DIST): Move inttostr.c here....
155811         (lib_SOURCES): from here.
155812         * modules/getopt (lib_SOURCES): Add getopt_int.h.
155814 2004-04-12  Jim Meyering  <jim@meyering.net>
155816         * MODULES.html.sh (func_all_modules): Add cloexec, inttostr, free,
155817         tzset.
155819 2004-04-11  Paul Eggert  <eggert@twinsun.com>
155821         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
155822         C89.
155823         (CHAR_BIT): Remove, since we assume C89.
155824         Include <stdint.h> if available, as per current Autoconf CVS advice.
155826 2004-03-31  Jim Meyering  <jim@meyering.net>
155828         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
155829         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
155830         * m4/xalloc.m4: Likewise.
155832 2004-03-30  Paul Eggert  <eggert@twinsun.com>
155834         Merge from coreutils.
155836         * m4/inttostr.m4: New file.
155837         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
155838         Require AM_STDBOOL_H and gl_TIMESPEC instead.
155839         Require gl_CLOCK_TIME.
155840         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
155842 2004-03-30  Paul Eggert  <eggert@twinsun.com>
155844         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
155845         not bool, to be more consistent with Unix conventions.
155846         Suggested by Bruno Haible.
155848         Merge from coreutils.
155850         * modules/inttostr: New file.
155851         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
155852         * lib/umaxtostr.c: New files.
155854         * modules/getdate: Depend on timespec, stdbool, gettime.
155855         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
155856         the usual <time.h> dance.
155857         (get_date): Change signature to support fractional time stamps.
155858         All callers changed.
155859         * lib/getdate.y: Include "getdate.h" first, as we can now
155860         assume C89 and don't need to worry about 'const'.
155861         Similarly, include "unlocked-io.h" near start, not in middle.
155862         Include <limits.h>.
155863         (textint.value): Use long int rather than int.
155864         (textint.digits): Use size_t rather than int.
155865         (BILLION, LOG10_BILLION): New constants.
155866         (parser_control): New member rel_ns.  Members day_ordinal,
155867         time_zone, month, day, hour, minutes, rel_year, rel_month,
155868         rel_day, rel_hour, rel_minutes, rel_seconds
155869         are now long int, not int.  Member seconds is now struct timespec,
155870         not int.  New member timespec_seen.  Members dates_seen, days_seen,
155871         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
155872         not int.
155873         (%union.intval): Now long int, not int.
155874         New member timespec.
155875         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
155876         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
155877         (spec): Now is a timespec or an item list.
155878         (timespec, items): New nonterminals.
155879         (time, rel, relunit, number, get_date):
155880         Add support for fractional seconds.
155881         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
155882         (gmtime, localtime, mktime): Remove decls; not needed with C89.
155883         (to_hour): First arg is now long int, not int.
155884         (to_year): Returns long int, not int.
155885         Don't treat year -70 like 70.
155886         (tm_diff): Returns long int, not int.
155887         (lookup_word): Use bool instead of int when appropriate.
155888         (yylex): Use size_t for count, not int.
155889         Detect overflow when parsing large integer constants.
155890         Add support for fractions.
155891         (get_date): Make pointers 'const' if possible.
155892         Use more-portable code to detect integer overflow.
155893         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
155894         Don't use ctime; it's not reliable if the year has >4 digits.
155896         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
155897         This is for compatibility with BSD.
155899         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
155900         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
155901         From coreutils' system.h.
155903         * lib/userspec.c: Don't include "posixver.h".
155904         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
155905         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
155906         compatible extension.  Simplify code by removing a boolean int
155907         that was always nonzero if a string was nonnull.
155909 2004-03-30  Jim Meyering  <jim@meyering.net>
155911         Merge from coreutils.
155913         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
155914         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
155915         on some systems one must include <grp.h> before it.
155916         Reported by Christian Krackowizer.
155918 2004-03-30  Jim Meyering  <jim@meyering.net>
155920         Merge from coreutils.
155922         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
155924         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
155925         an empty input stream.
155927         * lib/readtokens.c: Include <stdbool.h>.
155928         (readtoken): Use `size_t' rather than int/long.
155929         All callers adjusted.
155930         Use `bool' rather than `int' where appropriate.
155931         Use memset rather than an explicit loop.
155932         Use x2nrealloc rather than xrealloc.
155933         Allow the use of `\0' as a delimiter.
155934         (readtokens): Likewise.
155935         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
155937 2004-03-30  Jim Meyering  <jim@meyering.net>
155939         * modules/realloc (Files): Remove m4/realloc.m4.
155940         (configure.ac): Depend on AC_FUNC_REALLOC, rather than jm_FUNC_REALLOC.
155941         * modules/malloc (Files): Remove m4/malloc.m4.
155942         (configure.ac): Depend on AC_FUNC_MALLOC, rather than jm_FUNC_MALLOC.
155943         * m4/realloc.m4: Remove file, since now it does no more than
155944         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
155945         the `configure.ac' section of module/realloc.
155946         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
155948 2004-03-30  Bruno Haible  <bruno@clisp.org>
155950         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
155951         nonnull.
155953 2004-03-29  Paul Eggert  <eggert@twinsun.com>
155955         Merge changes to getloadavg.c from coreutils and Emacs.
155957         * modules/getloadvg: Depend on cloexec and xalloc.
155958         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
155959         Define to an expression, not to the empty string.
155960         Include cloexec.h and xalloc.h.
155961         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
155962         Use set_cloexec_flag rather than rolling our own.
155963         * lib/cloexec.c, lib/cloexec.h: New files.
155965 2004-03-29  Paul Eggert  <eggert@twinsun.com>
155967         * m4/cloexec.m4: New file.
155969 2004-03-18  Paul Eggert  <eggert@twinsun.com>
155971         * lib/getopt.h: Sync with libc CVS.
155973 2004-03-18  Paul Eggert  <eggert@twinsun.com>
155974             Bruno Haible  <bruno@clisp.org>
155976         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
155977         mbswidth.
155979 2004-03-18  Paul Eggert  <eggert@twinsun.com>
155980             Bruno Haible  <bruno@clisp.org>
155982         * lib/mbswidth.h: Include <wchar.h> only if
155983         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
155984         <wchar.h>.
155985         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
155987 2004-03-09  Paul Eggert  <eggert@twinsun.com>
155989         * modules/getopt: Add lib/getopt_int.h.
155990         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
155991         Sync with libc CVS.
155992         * lib/getopt_int.h: New file, also synced from libc.
155994 2004-03-09  Paul Eggert  <eggert@twinsun.com>
155996         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
155997         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
155998         Bring back getopt.c, getopt.h, getopt1.c.
156000 2004-03-07  Paul Eggert  <eggert@twinsun.com>
156002         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
156003         All uses changed.  Check for sa_sigaction member; this fixes
156004         a bug first reported by Jason Andrade in
156005         <http://mail.gnu.org/r/bug-textutils/2003-03/msg00027.html>.
156007 2004-03-07  Paul Eggert  <eggert@twinsun.com>
156009         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
156010         '#if' expressions.  Unlike the code it replaces, it does not
156011         depend on (defined _SC_PAGESIZE).  However, it does depend on
156012         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
156013         first reported by Jason Andrade in
156014         <http://mail.gnu.org/r/bug-textutils/2003-03/msg00027.html>.
156016 2004-02-25  Simon Josefsson  <jas@extundo.com>
156018         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
156020 2004-02-25  Simon Josefsson  <jas@extundo.com>
156022         * lib/strdup.h: New file.
156023         * lib/strdup.c: Include it.
156024         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
156025         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
156027 2004-02-23  Karl Berry  <karl@gnu.org>
156029         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
156030         (from fencepost.gnu.org:/gd/gnuorg).
156032 2004-02-23  Karl Berry  <karl@gnu.org>
156034         * config/srclistvars.sh (GNUORG) [karl]: redefine.
156035         * config/srclist.txt: add maintain/standards documents.
156037 2004-02-22  Bruno Haible  <bruno@clisp.org>
156039         * modules/xalloc: Remove dependency on stdbool.
156040         Reported by Derek Robert Price <derek@ximbiot.com>.
156042 2004-02-18  Bruno Haible  <bruno@clisp.org>
156044         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
156045         Reported by Derek Robert Price <derek@ximbiot.com>.
156047 2004-02-16  Karl Berry  <karl@gnu.org>
156049         * config/mkinstalldirs, install-sh: update from automake.
156051 2004-02-06  Karl Berry  <karl@gnu.org>
156053         * m4/po.m4: update from gettext 0.14.1.
156055 2004-02-06  Karl Berry  <karl@gnu.org>
156057         * lib/config.charset: update from gettext 0.14.1.
156059 2004-02-05  Paul Eggert  <eggert@twinsun.com>
156061         Add comments and code, prompted by suggestions from Bruno Haible
156062         for sh-quote.
156063         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
156064         describing the enum quoting_style values.
156065         * lib/quotearg.c (quotearg_alloc): New function.
156066         (quotearg_buffer_restyled): Treat lone { and } as special.
156067         Treat = as special.  Work around bug with older shells
156068         that "see" a '\' that is really the 2nd byte of a multibyte char.
156069         Quote empty string with shell_quoting_style.
156071 2004-02-03  Bruno Haible  <bruno@clisp.org>
156073         * modules/pipe: New file.
156074         * MODULES.html.sh (func_all_modules): Add pipe.
156075         * m4/pipe.m4: New file, from GNU gettext.
156077 2004-02-03  Bruno Haible  <bruno@clisp.org>
156079         * lib/pipe.h: New file, from GNU gettext.
156080         * lib/pipe.c: New file, from GNU gettext.
156082 2004-01-27  Bruno Haible  <bruno@clisp.org>
156084         * modules/execute: New file.
156085         * MODULES.html.sh (func_all_modules): Add execute.
156086         * m4/execute.m4: New file, from GNU gettext.
156088 2004-01-27  Bruno Haible  <bruno@clisp.org>
156090         * lib/execute.h: New file, from GNU gettext.
156091         * lib/execute.c: New file, from GNU gettext.
156092         * lib/w32spawn.h: New file, from GNU gettext.
156094 2004-01-24  Paul Eggert  <eggert@twinsun.com>
156096         Merge from diffutils.
156098         * lib/file-type.c (file_type): Add typed memory objects.
156099         * lib/file-type.h (S_TYPEISTMO): New macro.
156101         * lib/c-stack.h (c_stack_action): Remove argv argument.
156102         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
156103         (die): Don't calculate message unless segv_action returns.
156104         (get_stack_location, min_address_from_argv, max_address_from_argv,
156105         volatile stack_base, volatile_stack_size): Remove.
156106         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
156107         that every segmentation violation is a stack overflow.  (Ouch!)
156108         See Debian bug 136249 (still outstanding) for more info about why
156109         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
156111 2004-01-24  Paul Eggert  <eggert@twinsun.com>
156113         Exit-status fix from coreutils.
156115         Use exit_failure consistently in place of EXIT_FAILURE,
156116         so that program exit statuses are consistent on failure.
156118         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
156119         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
156120         * lib/argmatch.h: Comment fix to match the above.
156121         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
156122         Now a macro referring to exit_failure, instead of a separate
156123         variable.  Include "exitfail.h" to get it.
156124         * lib/xstrtol.h: Include "exitfail.h".
156125         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
156127         * lib/long-options.c (parse_long_options): Use prototype
156128         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
156129         for clarity.
156131 2004-01-23  Paul Eggert  <eggert@twinsun.com>
156133         * modules/argmatch, modules/obstack, modules/xstrtol:
156134         Depend on exitfail.
156136 2004-01-21  Jim Meyering  <jim@meyering.net>
156138         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
156139         so as not to conflict with a different-sized __mktime_internal
156140         function in GNU libc.
156141         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
156142         Problem building statically-linked `ls' reported by Michael Brunnbauer.
156144 2004-01-20  Karl Berry  <karl@gnu.org>
156146         * config/config.guess: update from config.
156148         * config/srclistvars.sh: GNUWWWLICENSES for karl.
156150 2004-01-20  Bruno Haible  <bruno@clisp.org>
156152         Safer stack allocation.
156153         * modules/setenv: Depend on allocsa instead of alloca.
156154         * lib/setenv.c: Include allocsa.h.
156155         (alloca): Remove fallback definition.
156156         (freea): Remove macro.
156157         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
156158         instead of freea.
156160 2004-01-20  Bruno Haible  <bruno@clisp.org>
156162         * m4/eealloc.m4: New file, from GNU gettext.
156164 2004-01-20  Bruno Haible  <bruno@clisp.org>
156166         * m4/allocsa.m4: New file, from GNU gettext.
156168 2004-01-20  Bruno Haible  <bruno@clisp.org>
156170         * modules/xallocsa: New file.
156171         * MODULES.html.sh (func_all_modules): Add xallocsa.
156172         * lib/xallocsa.h: New file, from GNU gettext.
156173         * lib/xallocsa.c: New file, from GNU gettext.
156175 2004-01-20  Bruno Haible  <bruno@clisp.org>
156177         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
156179 2004-01-20  Bruno Haible  <bruno@clisp.org>
156181         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
156182         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
156183         specially.
156185 2004-01-20  Bruno Haible  <bruno@clisp.org>
156187         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
156188         patch.
156190 2004-01-20  Bruno Haible  <bruno@clisp.org>
156192         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
156194 2004-01-20  Bruno Haible  <bruno@clisp.org>
156196         * modules/eealloc: New file.
156197         * MODULES.html.sh (func_all_modules): Add eealloc.
156198         * lib/eealloc.h: New file.
156200 2004-01-20  Bruno Haible  <bruno@clisp.org>
156202         * lib/binary-io.h: Avoid warnings on Cygwin.
156204 2004-01-20  Bruno Haible  <bruno@clisp.org>
156206         * modules/allocsa: New file.
156207         * MODULES.html.sh (func_all_modules): Add allocsa.
156208         * lib/allocsa.h: New file, from GNU gettext.
156209         * lib/allocsa.c: New file, from GNU gettext.
156211 2004-01-18  Karl Berry  <karl@gnu.org>
156213         * doc/gpl.texi, doc/lgpl.texi: new files.
156215 2004-01-18  Karl Berry  <karl@gnu.org>
156217         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
156218         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
156220 2004-01-18  Simon Josefsson  <jas@extundo.com>
156222         * modules/strdup (Files, Makefile.am): Add strdup.h.
156224 2004-01-15  Paul Eggert  <eggert@twinsun.com>
156226         * modules/poll: Add BUILT_SOURCES.
156227         Prefer "$@" to "poll.h" in rule for building poll.h.
156228         All this is for consistency with alloca and fnmatch.
156230         * modules/same: Depend on stdbool.
156232 2004-01-15  Paul Eggert  <eggert@twinsun.com>
156234         Merge from coreutils.
156236         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
156237         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
156238         (gl_DEFAULT_POSIX2_VERSION): Move
156239         the documentation from 'configure' into 'config.hin',
156240         so that 'configure --help' isn't burdened by it and
156241         we don't have to worry about its formatting there.
156242         Reword the documentation so that it's more succinct
156243         and can be run together into a single paragraph.
156244         * m4/same.m4 (gl_SAME): Check for pathconf.
156246 2004-01-15  Paul Eggert  <eggert@twinsun.com>
156248         Merge from coreutils.
156250         * lib/posixver.c: Include posixver.h.
156252         * lib/same.c: Include <stdbool.h>, <limits.h>.
156253         (_POSIX_NAME_MAX): Define if not defined.
156254         (MIN): New macro.
156255         (same_name): If file names are silently truncated, report
156256         that the file names are the same if they are the same after
156257         the silent truncation.
156259         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
156260         conversion function.
156261         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
156262         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
156263         longer needed.
156265 2004-01-15  Jim Meyering  <jim@meyering.net>
156267         Merge from coreutils.
156269         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
156270         if no library is required.
156271         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
156272         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
156273         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
156274         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
156275         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
156276         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
156277         value, $ac_cv_search_crypt, if it's "none required".
156278         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
156279         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
156280         not gl_FUNC_GETLOADAVG.
156281         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
156282         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
156284 2004-01-15  Jim Meyering  <jim@meyering.net>
156286         Merge from coreutils.
156288         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
156289         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
156290         http://mail.gnu.org/r/bug-coreutils/2003-11/msg00144.html
156292         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
156293         optional configure-time default.
156295         * lib/version-etc.c (version_etc_copyright): Update copyright date.
156297         * lib/xreadlink.c (xreadlink): Correct outdated comment.
156299 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
156301         Merge from coreutils.
156303         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
156304         value, $ac_cv_search_nanosleep, if it's "none required".
156306 2004-01-14  Paul Eggert  <eggert@twinsun.com>
156308         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
156309         with like-named macro in fnmatch.c.
156310         (EXT): Use an internal constant instead.
156312         Merge fnmatch patches from glibc.
156313         * lib/fnmatch.c (mbsinit): Remove define.
156314         Add libc_hidden_ver (__fnmatch, fnmatch).
156315         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
156316         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
156318 2004-01-14  Karl Berry  <karl@gnu.org>
156320         * config/install-sh: update from automake.
156322 2004-01-13  Karl Berry  <karl@gnu.org>
156324         * config/install-sh: update from automake.
156326 2004-01-09  Karl Berry  <karl@gnu.org>
156328         * config/install-sh: update from automake.
156330 2004-01-05  Karl Berry  <karl@gnu.org>
156332         * config/config.{sub,guess}: update from config.
156334 2003-12-31  Karl Berry  <karl@gnu.org>
156336         * config/depcomp: update from automake.
156338 2003-12-14  Karl Berry  <karl@gnu.org>
156340         * lib/config.charset: update from gettext-runtime.
156342 2003-12-03  Paul Eggert  <eggert@twinsun.com>
156344         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
156345         Bug reported by Alfred M. Szmidt.
156347 2003-12-03  Bruno Haible  <bruno@clisp.org>
156349         Upgrade from gettext-0.13.
156350         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
156351         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
156352         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
156353         * m4/gettext.m4: Upgrade from gettext-0.13.
156354         * m4/po.m4: Upgrade from gettext-0.13.
156355         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
156356         * m4/intmax.m4: New file, from gettext-0.13.
156357         * m4/printf-posix.m4: New file, from gettext-0.13.
156359 2003-11-29  Karl Berry  <karl@gnu.org>
156361         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
156363 2003-11-25  Paul Eggert  <eggert@twinsun.com>
156364             Bruno Haible  <bruno@clisp.org>
156366         * lib/printf-parse.h: Don't include sys/types.h.
156367         (ARG_NONE): New macro.
156368         (char_directive): Change type of *arg_index fields to size_t.
156369         * lib/printf-parse.c: Don't include sys/types.h.
156370         (SSIZE_MAX): Remove macro.
156371         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
156372         Remove unnecessary overflow check.
156373         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
156374         fields.
156376 2003-11-25  Bruno Haible  <bruno@clisp.org>
156378         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
156380 2003-11-25  Bruno Haible  <bruno@clisp.org>
156382         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
156383         gt_TYPE_SSIZE_T.
156385 2003-11-24  Paul Eggert  <eggert@twinsun.com>
156387         * modules/alloca: Remove dependency on xalloc.
156389 2003-11-24  Paul Eggert  <eggert@twinsun.com>
156391         * lib/alloca.c: Remove dependency on xalloc module.
156392         (xalloc_die): Remove.
156393         (memory_full) [!defined emacs]: New macro.
156394         [!defined emacs]: Don't include xalloc.h.
156395         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
156396         address arithmetic overflows.  Change datatypes a bit to avoid
156397         unnecessary casts.
156399 2003-11-22  Jim Meyering  <jim@meyering.net>
156401         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
156402         s/size/size_t/.
156404 2003-11-21  Karl Berry  <karl@gnu.org>
156406         * config/config.{sub,guess}: update from config.
156408 2003-11-18  Karl Berry  <karl@gnu.org>
156410         * config/config.{sub,guess}: update from config.
156412         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
156414 2003-11-17  Paul Eggert  <eggert@twinsun.com>
156416         * README: Mention that S+T cannot overflow if S is the size of
156417         an existing object and T is sufficiently small.
156419 2003-11-17  Jim Meyering  <jim@meyering.net>
156421         On systems without utime and without a utimes function capable of
156422         dealing with a NULL struct utimbuf* argument, this utime replacement
156423         could -- in unusual circumstances -- leak a file descriptor.
156424         * lib/utime.c: Include <unistd.h> and <errno.h>.
156425         (utime_null): Be sure to close `fd' and to preserve errno.
156426         Reported by Geoff Collyer via Arnold Robbins.
156428 2003-11-17  Bruno Haible  <bruno@clisp.org>
156430         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
156431         (Depends-on): Add xsize.
156433 2003-11-17  Bruno Haible  <bruno@clisp.org>
156435         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
156437 2003-11-17  Bruno Haible  <bruno@clisp.org>
156439         * lib/vasnprintf.c (alloca): Remove fallback definition.
156440         (freea): Remove definition.
156441         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
156442         Reported by Paul Eggert.
156444 2003-11-16  Paul Eggert  <eggert@twinsun.com>
156445             Bruno Haible  <bruno@clisp.org>
156447         Protect against address arithmetic overflow.
156448         * lib/printf-args.h: Include stddef.h.
156449         (arguments): Change type of field 'count' to size_t.
156450         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
156451         'unsigned int' where appropriate.
156452         * lib/printf-parse.h: Include sys/types.h.
156453         (char_directive): Change type of *arg_index fields to ssize_t.
156454         (char_directives): Change type of fields 'count', max_*_length to
156455         size_t.
156456         * lib/printf-parse.c: Include sys/types.h and xsize.h.
156457         (SSIZE_MAX): Define fallback value.
156458         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
156459         instead of 'int' where appropriate. Check a_allocated, d_allocated
156460         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
156461         * lib/vasnprintf.c: Include xsize.h.
156462         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
156463         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
156464         overflow. Avoid wraparound when converting a width or precision from
156465         decimal to binary.
156467 2003-11-16  Bruno Haible  <bruno@clisp.org>
156469         Update from GNU gettext.
156470         * lib/printf-parse.c: Generalize to it can be compiled for wide
156471         strings.
156472         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
156473         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
156474         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
156475         SNPRINTF): New macros.
156476         Don't include <alloca.h> if the file is used inside libintl.
156477         (local_wcslen): New function, for Solaris 2.5.1.
156478         (VASNPRINTF): Use it instead of wcslen.
156480 2003-11-16  Bruno Haible  <bruno@clisp.org>
156482         * lib/xsize.h (xmax): New function.
156483         (xsum, xsum3, xsum4): Declare as "pure" functions.
156485 2003-11-12  Paul Eggert  <eggert@twinsun.com>
156487         * modules/xalloc (Files): Undo latest change, since xalloc.h
156488         no longer needs SIZE_MAX or PTRDIFF_MAX.
156490 2003-11-12  Paul Eggert  <eggert@twinsun.com>
156492         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
156493         gl_PTRDIFF_MAX.
156495 2003-11-12  Paul Eggert  <eggert@twinsun.com>
156497         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
156498         "return", to pacify some unknown compiler.  Problem reported
156499         by Joerg Schilling.
156501 2003-11-12  Paul Eggert  <eggert@twinsun.com>
156503         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
156504         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
156505         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
156506         heuristic is just as accurate as far as we know, and it removes a
156507         dependency on size_max.m4 and ptrdiff_max.m4.
156509 2003-11-11  Bruno Haible  <bruno@clisp.org>
156511         * modules/xsize (Files): Add m4/size_max.m4.
156512         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
156514 2003-11-11  Bruno Haible  <bruno@clisp.org>
156516         * m4/size_max.m4: New file.
156517         * m4/ptrdiff_max.m4: New file.
156518         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
156519         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
156520         (gl_XALLOC): Invoke it.
156522 2003-11-11  Bruno Haible  <bruno@clisp.org>
156524         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
156525         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
156526         defined.
156528 2003-11-10  Paul Eggert  <eggert@twinsun.com>
156530         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
156531         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
156532         rejected some allocations of exactly SIZE_MAX - 2 bytes.
156533         From Bruno Haible.
156534         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
156535         not (size_t) -1, since it's defined here.
156537 2003-11-09  Karl Berry  <karl@gnu.org>
156539         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
156541 2003-11-06  Paul Eggert  <eggert@twinsun.com>
156543         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
156544         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
156545         Reject sizes of exactly SIZE_MAX bytes.
156546         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
156547         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
156549 2003-11-05  Bruno Haible  <bruno@clisp.org>
156551         * lib/xsize.h: Include limits.h, to avoid a possible collision with
156552         SIZE_MAX defined in <limits.h> on Solaris.
156554 2003-11-04  Jim Meyering  <jim@meyering.net>
156556         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
156557         variable names, rather than @VAR@.
156558         * modules/poll: Likewise.
156560 2003-11-04  Bruno Haible  <bruno@clisp.org>
156562         * modules/xsize: New file.
156563         * modules/linebreak: Depend on xsize.
156564         * MODULES.html.sh (func_all_modules): Add xsize.
156566 2003-11-04  Bruno Haible  <bruno@clisp.org>
156568         * m4/xsize.m4: New file.
156570 2003-11-04  Bruno Haible  <bruno@clisp.org>
156572         * lib/xsize.h: New file.
156573         * lib/linebreak.c: Include xsize.h.
156574         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
156575         argument for overflow.
156576         Suggested by Paul Eggert.
156578 2003-11-03  Karl Berry  <karl@gnu.org>
156580         * config/config.{guess,sub}: update from config.
156582 2003-11-03  Jim Meyering  <jim@meyering.net>
156584         * modules/userspec (lib_SOURCES): Add userspec.h.
156585         (Include): Add "userspec.h".
156586         Improve description.
156588 2003-11-03  Jim Meyering  <jim@meyering.net>
156590         * lib/userspec.c: Include "userspec.h".
156591         * lib/userspec.h: New file.
156593 2003-11-03  Bruno Haible  <bruno@clisp.org>
156595         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
156597 2003-11-03  Bruno Haible  <bruno@clisp.org>
156599         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
156600         available, to avoid (extremely rare) race condition.
156601         Suggested by Paul Eggert.
156603 2003-11-02  Karl Berry  <karl@gnu.org>
156605         * config/srclist.txt (vasprintf.c): sync broken, sigh.
156607 2003-10-31  Paul Eggert  <eggert@twinsun.com>
156609         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
156610         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
156611         (read_filesystem_list): Set and use me_type_malloced.
156612         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
156613         whatever the type happens to be), for brevity and consistency.
156614         Check for size calculation overflow on Alphas running OSF/1.
156616 2003-10-31  Jim Meyering  <jim@meyering.net>
156618         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
156620         * lib/linebuffer.c: Include <string.h> for declaration of memset.
156622 2003-10-30  Paul Eggert  <eggert@twinsun.com>
156623             Bruno Haible  <bruno@clisp.org>
156625         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
156626         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
156628 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
156630         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
156631         netbsd*-gnu*.  Suggested by Robert Millan.
156633 2003-10-29  Paul Eggert  <eggert@twinsun.com>
156635         * modules/group-member: Depend on stdbool.
156637 2003-10-29  Paul Eggert  <eggert@twinsun.com>
156639         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
156641 2003-10-29  Paul Eggert  <eggert@twinsun.com>
156643         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
156644         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
156645         after the 'gnu' in these cases.  This fixes some bugs in the
156646         previous change, and is based on suggestions by Robert Millan.
156648 2003-10-29  Paul Eggert  <eggert@twinsun.com>
156650         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
156651         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
156652         no longer needed.
156653         * lib/quotearg.c (quotearg_n_options): Use it.
156654         * lib/group-member.c: Include <stdbool.h>.
156655         (free_group_info): Arg is now const *; don't free arg.
156656         (get_group_info): Now returns bool and accepts struct group_info *,
156657         rather than returning a malloc'ed struct group_info *.
156658         All uses changed.  Check for overflow in internal size calculation.
156660         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
156661         rather than xmalloc/xrealloc.
156662         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
156663         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
156664         conformance bug: the old code used a pointer after freeing the
156665         storage that it addressed.
156666         * lib/hash.c (hash_initialize): Simplify the code by using
156667         xalloc_oversized rather than doing it by hand.
156668         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
156669         the buffer preserved.  Use free and xmalloc instead.
156670         * lib/quotearg.c (quotearg_n_options): Likewise.
156671         Use a simpler test for size overflow.  Don't use xalloc_oversized
156672         because unsigned int might be wider than size_t (!); this suggests
156673         that we should switch from unsigned int to size_t for slot numbers.
156675 2003-10-28  Paul Eggert  <eggert@twinsun.com>
156677         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
156678         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
156679         NetBSD kernels.  Requested by Richard Stallman.
156681 2003-10-27  Paul Eggert  <eggert@twinsun.com>
156683         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
156684         to allocate the returned structure.  Do not allocate a subarray,
156685         as x2nrealloc will do that.
156686         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
156687         instead of xnrealloc.
156688         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
156690 2003-10-27  Bruno Haible  <bruno@clisp.org>
156692         * lib/stdbool_.h: Better support for BeOS.
156694 2003-10-26  Paul Eggert  <eggert@twinsun.com>
156696         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
156697         now uses inline.
156699 2003-10-26  Paul Eggert  <eggert@twinsun.com>
156701         * lib/xalloc.h (xalloc_oversized): New static inline function, for
156702         callers that want to do their own size-overflow checking.  Include
156703         <stdbool.h>, since xalloc_oversized returns bool.
156704         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
156705         to use xalloc_oversized.
156707         Add two functions x2realloc, x2nrealloc, for programs that grow
156708         arrays dynamically by doubling their sizes.
156709         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
156710         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
156711         New functions.
156713         Port to C99 semantics for 'inline' of external functions.
156714         Bug reported by Bruno Haible.
156715         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
156716         with the old contents of xnmalloc.
156717         (xnmalloc, xmalloc): Use it.
156718         (xnrealloc_inline): New static inline function,
156719         with the old contents of xnrealloc.
156720         (xnrealloc, xrealloc): Use it.
156722         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
156723         that.
156725 2003-10-26  Karl Berry  <karl@gnu.org>
156727         * config/srclist.txt (COPYING.DOC): no longer available from
156728         /gd/gnuorg; don't know where the ultimate source is.
156730 2003-10-25  Paul Eggert  <eggert@twinsun.com>
156732         Fix several address-calculation bugs in the hash modules,
156733         plus some minor code cleanup.
156735         * lib/hash.h: Include <stdbool.h>, for bool.
156736         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
156737         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
156738         hash_get_n_entries, hash_get_max_bucket_length,
156739         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
156740         hash_rehash): Use size_t rather than unsigned.
156741         * lib/hash.c (struct hash_table, hash_get_n_buckets,
156742         hash_get_n_buckets_used, hash_get_n_entries,
156743         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
156744         hash_get_entries, hash_do_for_each, hash_string, is_prime,
156745         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
156746         Likewise.
156747         (SIZE_MAX): Define if not defined.
156748         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
156749         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
156750         hash_print):
156751         Use const * when possible.
156752         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
156753         (check_tuning): Fix bug: if tuning parameters were very close to
156754         0 or 1, rounding errors could have caused subscript violations.
156755         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
156756         (hash_initialize): Add 'fail:' label
156757         to free table and return NULL, and use it to simplify code.
156758         Use calloc rather than clearing the storage ourself.
156759         (hash_initialize, hash_rehash): Check for arithmetic overflow in
156760         buffer size calculations.
156761         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
156762         Include <stddef.h>, for size_t.
156763         * lib/hash-pjw.c (hash_pjw): Likewise.
156764         Switch to method described by Bruno Haible.
156765         Include <limits.h>, for CHAR_BIT.
156766         (SIZE_BITS): New macro.
156768 2003-10-23  Paul Eggert  <eggert@twinsun.com>
156770         * m4/getline.m4 (AM_FUNC_GETLINE):
156771         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
156772         hosts.  Problem reported by Derek Robert Price in
156773         <http://mail.gnu.org/r/bug-gnulib/2003-10/msg00092.html>.
156774         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
156775         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
156777 2003-10-21  Paul Eggert  <eggert@twinsun.com>
156779         * lib/getndelim2.c (getndelim2): When size calculation overflows,
156780         ceiling the allocation at NMAX bytes rather than silently
156781         discarding input bytes before NMAX is reached.  This makes
156782         a difference only if NMAX exceeds SIZE_MAX / 2.
156784         * lib/obstack.c: Merge from glibc.
156785         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
156786         Add libc_hidden_def (_obstack_newchunk).
156787         (_obstack_free) [! defined _LIBC]: Remove.
156788         [defined _LIBC]: Make a strong alias from obstack_free, rather than
156789         a clone of the function body.
156790         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
156791         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
156793         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
156794         glibc.
156795         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
156796         arg to memcpy.
156798         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
156799         (obstack_ptr_grow_fast, obstack_int_grow_fast):
156800         Don't use lvalue casts, as GCC plans to remove support for them
156801         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
156802         was also present in the non-GCC version, indicating that this
156803         code had always been buggy and had never been widely used.
156804         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
156805         Use the fast variant of each macro, rather than copying the
156806         definiens of the fast variant; that way, we'll be more likely to
156807         catch future bugs in the fast variants.
156809 2003-10-20  Bruno Haible  <bruno@clisp.org>
156811         * modules/wait-process: New file.
156812         * MODULES.html.sh (func_all_modules): Add wait-process.
156814 2003-10-20  Bruno Haible  <bruno@clisp.org>
156816         * m4/wait-process.m4: New file.
156818 2003-10-20  Bruno Haible  <bruno@clisp.org>
156820         * lib/wait-process.h: New file, from GNU gettext.
156821         * lib/wait-process.c: New file, from GNU gettext.
156823 2003-10-19  Jim Meyering  <jim@meyering.net>
156825         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
156826         HPUX 10.20.
156828 2003-10-18  Karl Berry  <karl@gnu.org>
156830         * config/config.guess: update from config.
156832 2003-10-16  Paul Eggert  <eggert@twinsun.com>
156834         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
156835         (getgroups): First arg is int, not size_t.
156836         Don't let 'free' mangle errno.
156838 2003-10-16  Paul Eggert  <eggert@twinsun.com>
156840         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
156842 2003-10-16  Karl Berry  <karl@gnu.org>
156844         * config/config.{guess,sub}: update from config.
156846 2003-10-16  Jim Meyering  <jim@meyering.net>
156848         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
156849         memcpy.
156851 2003-10-15  Paul Eggert  <eggert@twinsun.com>
156853         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
156854         (SIZE_MAX): Remove.
156855         (new_exclude, add_exclude_file): Initial size no longer needs to
156856         be a power of 2.
156857         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
156858         our own address arithmetic overflow checking.
156860         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
156861         (fnmatch): Do not alloca more than 2000 wide characters;
156862         instead, use malloc for large buffers.
156863         Check for address arithmetic overflow, and return -1
156864         with errno set to ENOMEM in that case.
156865         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
156866         (NEW_PATTERN): Do not alloca more than 8000 bytes;
156867         instead, return -1.  Check for address arithmetic overflow.
156869 2003-10-14  Paul Eggert  <eggert@twinsun.com>
156871         Handle invalid suffixes and overflow independently, so that
156872         callers can treat them independently as needed.  Fix some bugs in
156873         suffix handling, e.g., "100k@" was not diagnosed as an invalid
156874         suffix for a human-readable blocksize.  The major caller-visible
156875         change is the addition of a new
156876         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
156877         that both overflow and suffix chars were found.
156879         * lib/human.c (humblock): Don't check separately for invalid suffix
156880         char; that is xstrtoumax's job (now that its bug is fixed).
156881         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
156882         INTMAX_MAX]: New macros.
156883         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
156884         TYPE_MAXIMUM): New macros.
156885         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
156886         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
156887         if overflow occurs, as it's what __strtol does and it's more useful
156888         in practice.
156889         (__xstrtol): If __strtol reports some error other than ERANGE,
156890         reflect it to the caller as LONGINT_INVALID.  If it reports
156891         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
156892         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
156893         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
156894         value.
156895         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
156896         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
156897         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
156898         [defined UINTMAX_MAX]: New macros.
156900 2003-10-14  Bruno Haible  <bruno@clisp.org>
156902         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
156904 2003-10-14  Bruno Haible  <bruno@clisp.org>
156906         * m4/sig_atomic_t: New file, from GNU gettext.
156907         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
156909 2003-10-14  Bruno Haible  <bruno@clisp.org>
156911         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
156912         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
156913         Also use volatile where needed.
156915 2003-10-12  Paul Eggert  <eggert@twinsun.com>
156917         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
156918         Change maintainer from Bruno Haible to 'all'.
156920 2003-10-12  Paul Eggert  <eggert@twinsun.com>
156922         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
156924 2003-10-12  Paul Eggert  <eggert@twinsun.com>
156926         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
156927         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
156928         and define in terms of the other primitives.
156929         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
156930         (SIZE_MAX): Define if not already defined.
156931         (array_size_overflow): New function.
156932         (xalloc_die): Abort instead of exiting if 'error' returns.
156933         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
156934         (xmalloc, xrealloc): Use them.
156935         (xcalloc): Check for address arithmetic overflow.
156936         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
156937         a bit faster than strcpy.
156939 2003-10-10  Simon Josefsson  <jas@extundo.com>
156941         * modules/argp (Depends-on): Add restrict and strcase.
156943 2003-10-10  Simon Josefsson  <jas@extundo.com>
156945         * m4/argp.m4: Add AC_C_INLINE.
156947 2003-10-08  Paul Eggert  <eggert@twinsun.com>
156949         Merge getpass from libc, plus a few fixes.
156951         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
156952         Include <stdbool.h>.
156953         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
156954         __fsetlocking to empty.
156955         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
156956         do include <bits/libc-lock.h>.
156957         Do not include <fcntl.h>; not needed.
156958         [_LIBC]: Include <wchar.h>.
156959         (NOTCANCEL_MODE): New macro.
156960         (flockfile, funlockfile) [_LIBC]: New macros.
156961         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
156962         [!_LIBC]: New macros.
156963         (call_fclose): New function.
156964         (getpass): Use it.  Save tty stream separately; this simplifies the
156965         code and makes it more reliable if stdin happens to equal stdout.
156966         Invoke __fsetlocking on tty.
156967         Handle thread cancellation if needed.
156968         Namespace cleanup (use __tcgetattr, __getline).
156969         Use bool for Booleans.
156970         [USE_IN_LIBIO]: Handle wide streams.
156971         [!_LIBC]: Unconditionally do the fseek, since we don't know what
156972         stream might go where.
156974         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
156975         doesn't have to include <stdio.h> before us.
156976         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
156977         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
156978         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
156979         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
156980         if not declared, so that we can use getpass.c code from libc without
156981         rewriting it.
156982         (flockfile, ftrylockfile, funlockfile): New macros.
156984 2003-10-08  Paul Eggert  <eggert@twinsun.com>
156986         * modules/getpass: Depend on stdbool.
156988 2003-10-08  Paul Eggert  <eggert@twinsun.com>
156990         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
156992 2003-10-07  Karl Berry  <karl@gnu.org>
156994         * config/config.{guess,sub}: update from config.
156996 2003-10-06  Jim Meyering  <jim@meyering.net>
156997             Bruno Haible  <bruno@clisp.org>
156999         This lets translators provide better translations for the
157000         "Written by ..." part of --version output.
157001         * lib/version-etc.h: Include stdarg.h.
157002         (version_etc_copyright): Declare as readonly.
157003         (version_etc): Make this function variadic with a NULL-terminated list
157004         of author name strings.
157005         (version_etc_va): New declaration.
157006         * lib/version-etc.c: Include stdarg.h, stdlib.h.
157007         (version_etc_copyright): Declare as readonly.
157008         (version_etc_va): New function. Provide a different translatable string
157009         for each possible number of authors < 10. Abbreviate when there are 10
157010         authors or more.
157011         (version_etc): Make this function variadic. Call version_etc_va.
157012         Suggestion from Gary V. Vaughan.
157014         * lib/long-options.h (parse_long_options): Change prototype: the
157015         authors string is moved to the end and becomes variadic.
157016         * lib/long-options.c: Include stdarg.h.
157017         (parse_long_options): Make this function variadic, too.
157018         Call version_etc_va, not version_etc.
157020 2003-10-06  Bruno Haible  <bruno@clisp.org>
157022         * modules/version-etc-2: Remove file.
157023         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
157025 2003-10-06  Bruno Haible  <bruno@clisp.org>
157027         * modules/fatal-signal: New file.
157028         * MODULES.html.sh (func_all_modules): Add fatal-signal.
157030 2003-10-06  Bruno Haible  <bruno@clisp.org>
157032         * m4/fatal-signal.m4: New file.
157033         * m4/signalblocking.m4: New file, from GNU gettext.
157035 2003-10-06  Bruno Haible  <bruno@clisp.org>
157037         * lib/version-etc-2.h: Remove file.
157038         * lib/version-etc-2.c: Remove file.
157040 2003-10-06  Bruno Haible  <bruno@clisp.org>
157042         * lib/fatal-signal.h: New file, from GNU gettext.
157043         * lib/fatal-signal.c: New file, from GNU gettext.
157045 2003-10-05  Paul Eggert  <eggert@twinsun.com>
157047         * README: Rework advice for preventing empty .o files.
157048         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
157049         not <sys/types.h>.
157051 2003-10-04  Karl Berry  <karl@gnu.org>
157053         * lib/argp*: update from libc.
157055 2003-10-04  Karl Berry  <karl@gnu.org>
157057         * config/config.{guess,sub}: update from config.
157059 2003-10-02  Bruno Haible  <bruno@clisp.org>
157061         * modules/lchown (Include): Add lchown.h.
157062         * modules/time_r (Include): Use "..." syntax.
157063         * modules/xgetdomainname (Include): Add xgetdomainname.h.
157065 2003-10-01  Simon Josefsson  <jas@extundo.com>
157067         * MODULES.html.sh (func_all_modules): Move gethostname from section
157068         'based on' to section 'lacking' POSIX:2001.
157070 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
157072         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
157073         to output mode on the same stream.
157075 2003-09-29  Paul Eggert  <eggert@twinsun.com>
157077         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
157078         Fix arg typo in previous patch.
157080 2003-09-28  Jim Meyering  <jim@meyering.net>
157082         * lib/error.c: Correct cpp indentation.
157084 2003-09-27  Paul Eggert  <eggert@twinsun.com>
157086         * modules/free: New file.
157088 2003-09-27  Paul Eggert  <eggert@twinsun.com>
157090         * m4/free.m4: New file.
157092 2003-09-27  Paul Eggert  <eggert@twinsun.com>
157094         * lib/minmax.h (MIN, MAX)
157095         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
157096         Omit the special code that used __typeof__, since we worry that
157097         it could be more trouble than it's worth.  See:
157098         http://mail.gnu.org/r/bug-gnulib/2003-01/msg00090.html
157099         http://mail.gnu.org/r/bug-gnulib/2003-01/msg00095.html
157101         * lib/free.c: New file.
157103 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
157105         Trivial fixes to Makefile.am parts of module listings.
157106         * modules/strstr: Append strstr.h to lib_SOURCES.
157107         * modules/strcase: Likewise, for strcase.h.
157109 2003-09-27  Karl Berry  <karl@gnu.org>
157111         * config/mkinstalldirs: update from automake.
157113 2003-09-26  Paul Eggert  <eggert@twinsun.com>
157115         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
157116         (error_tail): Do not loop, reallocating temporary buffer, since
157117         the output cannot contain more wide characters than the input
157118         contains bytes, the size must be big enough already.  This avoids
157119         one potential size overflow calculation.  Check for size overflow
157120         when calculating temporary buffer size.  Free temporary buffer
157121         when done, if it was allocated with malloc; this plugs a memory
157122         leak.  Remove casts from void * to pointers, that are no longer
157123         needed now that we're assuming C89 or better.
157125         Merge error changes from glibc.
157127         * lib/error.c, error.h: Update copyright notice header to match glibc.
157128         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
157129         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
157130         Disable cancellation while printing error.
157131         * lib/error.h: Prepend __ to parameter names.
157133 2003-09-26  Jim Meyering  <jim@meyering.net>
157135         * lib/error.c (error_tail): Move some declarations
157136         into inner scope where the local variables are used.
157138 2003-09-26  Bruno Haible  <bruno@clisp.org>
157140         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
157141         stpncpy().
157142         Don't define stpncpy through config.h; it's now done through stpncpy.h.
157144 2003-09-26  Bruno Haible  <bruno@clisp.org>
157146         * lib/stpncpy.h (gnu_stpncpy): New declaration.
157147         (stpncpy): Define as alias for gnu_stpncpy.
157148         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
157150 2003-09-25  Simon Josefsson  <jas@extundo.com>
157152         * lib/xgetdomainname.h: New file.
157153         * lib/xgetdomainname.c: New file.
157155 2003-09-25  Simon Josefsson  <jas@extundo.com>
157156             Bruno Haible  <bruno@clisp.org>
157158         * modules/getdomainname: New file.
157159         * modules/xgetdomainname: New file.
157160         * MODULES.html.sh (func_all_modules): Add getdomainname,
157161         xgetdomainname.
157163 2003-09-25  Simon Josefsson  <jas@extundo.com>
157164             Bruno Haible  <bruno@clisp.org>
157166         * m4/getdomainname.m4: New file.
157168 2003-09-25  Simon Josefsson  <jas@extundo.com>
157169             Bruno Haible  <bruno@clisp.org>
157171         * lib/getdomainname.h: New file.
157172         * lib/getdomainname.c: New file.
157174 2003-09-25  Karl Berry  <karl@gnu.org>
157176         * lib/argp-fmtstream.c, argp-help.c: update from libc.
157178 2003-09-25  Karl Berry  <karl@gnu.org>
157180         * config/install-sh: update from automake.
157182 2003-09-25  Bruno Haible  <bruno@clisp.org>
157184         * modules/version-etc-2: New file, from modules/version-etc with
157185         modifications.
157186         * MODULES.html.sh (func_all_modules): Add version-etc-2.
157188 2003-09-25  Bruno Haible  <bruno@clisp.org>
157190         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
157191         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
157193 2003-09-24  Simon Josefsson  <jas@extundo.com>
157195         * modules/xgethostname: Add xgethostname.h.
157197 2003-09-24  Paul Eggert  <eggert@twinsun.com>
157199         * lib/linebuffer.c (freebuffer): Don't free the argument, just
157200         the buffer associated with the argument.  Bug reported by
157201         Simon Josefsson.
157203 2003-09-24  Paul Eggert  <eggert@twinsun.com>
157205         * README: Document assumptions that 'int' is at least 32 bits
157206         wide, that integer arithmetic is 2's complement without overflow,
157207         that there are no holes in integer values, that adding sizes of
157208         two nonoverlapping objects can't overflow, and that all-bits-zero
157209         yields scalar zero.  Fix spelling and capitalization typos.
157211 2003-09-19  Karl Berry  <karl@gnu.org>
157213         * lib/argp.h: update from libc.
157215 2003-09-17  Paul Eggert  <eggert@twinsun.com>
157217         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
157218         to avoid spurious warnings like "AC_RUN_IFELSE was called before
157219         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
157221 2003-09-17  Paul Eggert  <eggert@twinsun.com>
157223         * gnulib-tool: Use "test -h", not "test -L", for portability
157224         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
157225         (tags_regexp): Remove, since \| doesn't conform to POSIX.
157226         (sed_extract_prog): Issue s commands one-by-one, rather than
157227         using \| in one s command.
157229 2003-09-16  Paul Eggert  <eggert@twinsun.com>
157231         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
157232         input error, instead of returning NULL the next time we are called
157233         (and therefore losing track of errno).
157235 2003-09-16  Bruno Haible  <bruno@clisp.org>
157237         * gnulib-tool (func_create_testdir): Warn about duplicated
157238         dependencies.
157240 2003-09-15  Paul Eggert  <eggert@twinsun.com>
157242         * modules/argmatch, modules/fatal, modules/obstack,
157243         modules/xalloc, modules/xgethostname: Sort dependencies by
157244         importance, not alphabetically.
157246 2003-09-15  Paul Eggert  <eggert@twinsun.com>
157248         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
157249         fails, so that the caller gets the proper errno.
157251         * lib/readutmp.c (read_utmp): Likewise.
157252         Check for fstat error.  Close stream and free storage
157253         when failing.
157255 2003-09-14  Karl Berry  <karl@gnu.org>
157257         * config/srclist.txt (strdup.c): disable for c89 changes.
157259 2003-09-14  Jim Meyering  <jim@meyering.net>
157261         * lib/getloadavg.c: Correct cpp indentation.
157262         * lib/strdup.c: Likewise.
157263         * lib/vasnprintf.c: Likewise.
157265 2003-09-14  Bruno Haible  <bruno@clisp.org>
157267         * modules/fwriteerror: New file.
157268         * MODULES.html.sh (func_all_modules): Add fwriteerror.
157270 2003-09-14  Bruno Haible  <bruno@clisp.org>
157272         * lib/fwriteerror.h: New file.
157273         * lib/fwriteerror.c: New file.
157275 2003-09-12  Paul Eggert  <eggert@twinsun.com>
157277         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
157278         modules/xgethostname, modules/xalloc: Depend on exit.
157280 2003-09-12  Paul Eggert  <eggert@twinsun.com>
157282         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
157284         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
157285         and AC_MINIX, too, so that their extensions are available.
157287         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
157288         This macro has been superseded by gl_BACKUPFILE.
157290         More patches to assume C89 or better.
157292         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
157294         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
157295         unconditionally.
157296         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
157297         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
157298         Include <string.h>, <stdlib.h> unconditionally.
157299         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
157300         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
157301         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
157302         headers or for string.h.
157303         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
157304         or strtoul.
157306         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
157307         headers.
157308         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
157309         * m4/userspec.m4 (gl_USERSPEC): Likewise.
157310         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
157311         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
157312         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
157313         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
157314         memcpy, memset.
157315         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
157316         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
157317         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
157318         strtol.
157319         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
157320         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
157321         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
157322         strtoul.
157324 2003-09-12  Paul Eggert  <eggert@twinsun.com>
157326         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
157327         * lib/obstack.c [!defined _LIBC]: Likewise.
157328         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
157329         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
157330         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
157332         More changes to assume C89 or better.
157334         * lib/error.c (error_tail): Assume vprintf.
157336         * lib/argmatch.c (getenv): Remove decl.
157337         * lib/progreloc.c (get_full_program_name): Define via prototype.
157338         * lib/setenv.c (clearenv): Likewise.
157339         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
157340         needed.
157341         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
157342         (malloc, memcpy): Remove decls.
157343         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
157344         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
157345         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
157346         (memcpy): Remove macro.
157347         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
157348         (__P): Remove.  All uses removed.
157349         (PTR): Remove.  All uses changed to void *.
157350         (CHAR_BIT, NULL): Remove.
157351         (spaces, zeros, memset_space, memset_zero)
157352         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
157353         Remove.
157354         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
157355         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
157356         Define with prototype.
157357         Remove now-unnecessary prototype decl.
157358         (extra_args_spec): Assume ANSI C.  All uses changed.
157359         (extra_args_spec_iso): Remove.
157360         (my_strftime, emacs_strftimeu): Define via prototype.
157361         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
157362         unconditionally.
157363         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
157364         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
157365         (strtoul, strtol): Remove decls.
157366         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
157367         LONG_MAX): Remove.
157368         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
157369         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
157370         (LOCALE_PARAM_PROTO): New macro.
157371         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
157372         (INTERNAL (strtol), strtol): Define with a prototype.
157373         (PARAMS): Remove.  All uses removed.
157374         * lib/tempname.c: Include <string.h> unconditionally.
157375         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
157376         * lib/xgethostname.c (main): Define with a prototype.
157377         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
157378         Include <stdlib.h> unconditionally.
157379         (calloc, malloc, realloc, free): Remove decls.
157380         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
157381         Include <stdlib.h> unconditionally.  Sort include file names.
157382         (strtod): Remove.
157383         (xstrtod): Define with a prototype.
157384         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
157385         (strtol, strtoul): Remove decls.
157387 2003-09-11  Paul Eggert  <eggert@twinsun.com>
157389         More patches to assume C89 or better.
157390         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
157391         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
157392         string.h, memchr, STDC_HEADERS.
157394 2003-09-11  Paul Eggert  <eggert@twinsun.com>
157396         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
157397         Include <stdlib.h>, <string.h> unconditionally.
157398         Remove now-unnecessary cast to char *.
157399         * lib/strnlen.c: Include <string.h> unconditionally.
157400         * lib/yesno.c (yesno): Define with a prototype.
157402 2003-09-11  Bruno Haible  <bruno@clisp.org>
157404         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
157406 2003-09-10  Jim Meyering  <jim@meyering.net>
157408         * lib/error.c: Correct indentation of cpp directives.
157410 2003-09-10  Bruno Haible  <bruno@clisp.org>
157412         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
157413         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
157414         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
157415         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
157416         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
157417         <stdlib.h> and <string.h> checks.
157418         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
157419         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
157421 2003-09-10  Bruno Haible  <bruno@clisp.org>
157423         * lib/strcspn.c: Include <string.h> unconditionally.
157424         * lib/strpbrk.c: Include <string.h> unconditionally.
157425         * lib/strstr.c: Include <string.h> unconditionally.
157426         * lib/unicodeio.c: Include <string.h> unconditionally.
157427         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
157428         * lib/unsetenv.c: Likewise.
157429         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
157430         * lib/yesno.c: Include <stdlib.h> unconditionally.
157431         (rpmatch): Add prototype.
157433 2003-09-09  Paul Eggert  <eggert@twinsun.com>
157435         More patches to assume C89 or better.
157436         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
157437         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
157438         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
157439         or for string.h.
157440         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
157441         stdlib.h.
157442         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
157443         C headers.
157444         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
157445         string.h.
157446         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
157447         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
157448         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
157449         or for string.h.
157450         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
157451         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
157452         C headers.
157453         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
157454         memcpy.
157455         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
157456         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
157457         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
157458         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
157459         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
157460         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
157461         string.h, free.
157462         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
157463         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
157464         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
157465         C headers, or for string.h.
157466         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
157467         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
157468         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
157469         headers, memory.h, stdlib.h, string.h, strings.h.
157470         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
157471         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
157472         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
157473         strchr.
157474         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
157475         headers, memory.h, string.h.
157476         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
157477         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
157478         free.
157479         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
157480         headers.
157481         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
157482         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
157483         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
157484         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
157485         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
157487 2003-09-09  Paul Eggert  <eggert@twinsun.com>
157489         More K&R removal.
157491         * lib/acosl.c (main): Use a prototype.
157492         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
157493         tanl.c: Likewise.
157495         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
157497         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
157498         (getopt, etopt_long, getopt_long_only, _getopt_internal)
157499         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
157500         with a prototype.
157501         * lib/getopt.c (const): Remove macro.
157502         Include <string.h> unconditionally.
157503         (my_index): Remove; all uses changed to strchr.
157504         (strlen): Remove decl.
157505         (exchange): Remove forward decl; no longer needed.
157506         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
157507         Define with prototype.
157508         * lib/getopt1.c (const): Remove macro.
157509         (getopt_long, getopt_long_only, main): Define with prototype.
157511         * lib/getugroups.c: Include <string.h> unconditionally.
157513         * lib/getusershell.c: Include <stdlib.h> unconditionally.
157514         (getusershell, setusershell, endusershell, readname, main):
157515         Define with prototypes.
157517         * lib/group-member.c: Include group-member.h first.
157518         Include <stdlib.h> unconditionally.
157520         * lib/hard-locale.c: Include hard-locale.h first.
157521         Include <stdlib.h>, <string.h> unconditionally.
157523         * lib/hash.c (free, malloc): Remove decls.
157524         Include <stdlib.h> unconditionally.
157526         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
157527         (getenv): Do not declare.
157529         * lib/idcache.c: Include <string.h> unconditionally.
157531         * lib/long-options.c: Include long-options.h first, to test interface.
157532         Include <stdlib.h> unconditionally.
157534         * lib/makepath.c: Include makepath.h first, to test interface.
157535         Include <stdlib.h> and <string.h> unconditionally.
157537         * lib/linebuffer.c: Include <stdlib.h>.
157538         (free): Remove decl.
157540         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
157541         stddef.h. rpl_malloc returns void *, not char *.
157542         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
157543         prototype.
157545         * lib/md5.h: Include <limits.h> unconditionally.
157546         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
157547         (__P): Remove; all uses removed.
157548         * lib/md5.c: Include "md5.h" first.
157549         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
157550         md5_buffer, md5_process_bytes, md5_process_block):
157551         Define with prototypes.
157552         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
157553         * lib/sha.c: Include "sha.h" first.
157554         Include <stdlib.h>, <string.h> unconditionally.
157556         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
157557         * lib/memcmp.c (__ptr_t): Likewise.
157558         * lib/memrchr.c (__ptr_t): Likewise.
157559         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
157560         Include <string.h> unconditionally.
157561         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
157562         * lib/memchr.c: Include <stdlib.h> unconditionally.
157563         * lib/memchr.c (LONG_MAX): Remove.
157564         * lib/memrchr.c (LONG_MAX): Likewise.
157565         * lib/memchr.c (__memchr): Define via a prototype.
157566         * lib/memrchr.c (__memrchr): Likewise.
157567         * lib/memcmp.c (__P): Remove, and remove all uses.
157568         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
157569         Remove forward decls; no longer needed.
157570         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
157571         Use types required by C89 in prototype.
157573         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
157574         * lib/savedir.c: Likewise.
157575         * lib/mkdir.c (free): Remove decl.
157576         * lib/rmdir.c (rmdir): Define with a prototype.
157577         * lib/savedir.c: Include savedir.h first, to test interface.
157579         * lib/mktime.c (STDC_HEADERS): Remove.
157580         Include <stdlib.h>, <string.h> unconditionally.
157582         * lib/modechange.c: Include <stdlib.h> unconditionally.
157583         (malloc): Remove decl.
157585         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
157586         (free): Remove decl.
157588         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
157589         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
157590         (This type really should be intptr_t, but that's a C99ism.)
157591         (_obstack_memcpy): Remove: all uses changed to memcpy.
157592         Include <string.h> unconditionally.
157593         (struct obstack): Assume __STDC__ for types of members
157594         chunkfun, freefun, extra_arg.
157595         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
157596         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
157597         obstack_begin, obstack_specify_allocation,
157598         obstack_specify_allocation_with_arg, obstack_chunkfun,
157599         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
157600         Remove unprototyped decls and the macros that use them.
157601         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
157602         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
157603         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
157604         (defined __STDC__ && __STDC__)]:
157605         Remove nonprototyped code.
157606         Include <stdlib.h> unconditionally.
157607         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
157608         _obstack_allocated_p, _obstack_free, obstack_free,
157609         _obstack_memory_used, print_and_abort):
157610         Define using prototypes.
157611         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
157612         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
157613         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
157614         obstack_next_free, obstack_object_size, obstack_room) [0]:
157615         Remove unused, unprototyped code.
157617         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
157619         * lib/physmem.c (physmem_total, physmem_available, main): Define
157620         with prototypes.
157622         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
157623         (main): Define with a prototype.
157625         * lib/posixver.c (getenv): Remove decl.
157627         * lib/putenv.c (malloc): Returns void *, not char *.
157628         Include <string.h> unconditionally.
157629         (strchr, memcpy, NULL): Do not define.
157631         * lib/readtokens.c: Include readtokens.h first, to test interface.
157632         Include <stdlib.h>, <string.h> unconditionally.
157633         (init_tokenbuffer): Define with a prototype.
157635         * lib/regex.c (PARAMS): Remove.  All uses removed.
157636         All uses of _RE_ARGS removed, too.
157637         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
157638         unconditionally.
157639         (bzero): Assume memset exists.
157640         (memcmp, memcpy, NULL): Remove.
157641         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
157642         char, or assignments to local vars of type signed char.
157643         (init_syntax_once, PREFIX(extract_number_and_incr),
157644         PREFIX(print_partial_compiled_pattern),
157645         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
157646         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
157647         PREFIX(regex_grow_registers), PREFIX(regex_compile),
157648         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
157649         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
157650         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
157651         wcs_compile_range, byte_compile_range, truncate_wchar,
157652         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
157653         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
157654         count_mbs_length, wcs_re_match_2_internal,
157655         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
157656         PREFIX(alt_match_null_string_p),
157657         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
157658         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
157659         regfree, PREFIX(extract_number)): Define with prototype.  Remove
157660         now-unnecessary declaration, if any.
157661         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
157662         regcomp, regexec):
157663         Remove now-unnecessary casts among pointer types.
157664         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
157666         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
157667         (free): Remove decl.
157669         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
157671         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
157672         (free): Remove decl.
157674         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
157675         * lib/xgetcwd.c: Likewise.
157677         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
157678         (free): Remove decl.
157680         * lib/strchrnul.c (strchrnul): Define with a prototype.
157681         Fix bug: c_in was not converted to char before searching.
157683         The following changes are not K&R related:
157685         * lib/group-member.h: Include <sys/types.h>, so that this file is
157686         self-contained.
157687         * lib/makepath.h: Likewise.
157689         * lib/getusershell.c (readname, default_index, line_size, readname):
157690         Use size_t, not int, for sizes.
157691         (readname): If the size overflows, report an error instead of
157692         looping forever.
157694 2003-09-09  Paul Eggert  <eggert@twinsun.com>
157696         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
157697         libc.
157699 2003-09-09  Paul Eggert  <eggert@twinsun.com>
157701         * README: New section: portability guidelines.
157703 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
157705         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
157706         C89 spec.
157708 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
157710         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
157712 2003-09-08  Paul Eggert  <eggert@twinsun.com>
157714         Assume C89 or better; remove K&R cruft.
157715         A few of these changes were first proposed by Derek Robert Price
157716         in <http://mail.gnu.org/r/bug-gnulib/2003-07/msg00105.html>.
157718         * lib/addext.c: Include <string.h> unconditionally.
157719         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
157720         Don't declare getenv or malloc.
157722         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
157723         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
157724         (NULL): Remove.
157725         (find_stack_direction, alloca): Use prototypes.
157727         * lib/atexit.c (atexit): Define using a prototype.
157729         * lib/basename.c, dirname.c, stripslash.c:
157730         Include <string.h> unconditionally.
157732         * lib/bcopy.c: Include <stddef.h>.
157733         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
157735         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
157737         * lib/error.h (error, error_at_line, error_print_progname)
157738         [! (defined (__STDC__) && __STDC__)]: Remove decls.
157739         * lib/error.c: Include error.h first, to check interface.
157740         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
157741         (VA_START): Remove; all uses changeed to va_start.
157742         (exit, strerror): Remove decls.
157743         (error_print_progname): Prototype uncondionally.
157744         Don't include <errno.h>; no longer needed.
157745         (private_strerror): Remove.
157746         (error_tail): Always define.
157747         (error, error_at_line): Assume C89 or better; always use prototypes.
157748         * lib/fatal.c: Include "fatal.h" first, to test interface.
157749         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
157750         (VA_START): Remove; all uses changed to va_start.
157751         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
157752         this case.
157753         (exit): Remove decl.
157754         (fatal): Prototype unconditionally.  Assume va_start works.
157755         Abort at end, to pacify gcc.
157757         * lib/euidaccess.c (main): Define with a prototype.
157759         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
157761         * lib/exitfail.c: Include <stdlib.h> unconditionally.
157763         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
157764         prototypes.
157765         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
157766         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
157767         (getenv): Remove decl.
157768         (fnmatch): Define using a prototype.
157769         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
157770         (FCT): Define using a prototype.
157772         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
157774         * lib/gethostname.c: Include <stddef.h>.
157775         (gethostname): Define with prototype.  Length is size_t, not int.
157777 2003-09-08  Paul Eggert  <eggert@twinsun.com>
157779         Assume C89 or better; remove K&R cruft.
157780         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
157781         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
157782         string.h, getenv, malloc.
157783         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
157784         headers.
157785         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
157786         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
157787         do not check for strerror.
157788         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
157789         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
157790         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
157791         do not check for doprnt or vprintf.
157792         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
157793         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
157795 2003-09-08  Paul Eggert  <eggert@twinsun.com>
157797         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
157798         getversion.c should have been removed then, but was accidentally
157799         preserved.
157801         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
157802         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
157804 2003-09-08  Karl Berry  <karl@gnu.org>
157806         * config/config.sub, config.guess, srclistvars.sh: update from savannah
157807                 config, forget about prep.
157809         * config/depcomp, missing: update from automake.
157811 2003-09-07  Paul Eggert  <eggert@twinsun.com>
157813         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
157814         <http://mail.gnu.org/r/bug-gnulib/2003-09/msg00028.html>.
157816 2003-09-07  Paul Eggert  <eggert@twinsun.com>
157818         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
157819         copy_tm_result.  Bug reported by Simon Josefsson in
157820         <http://mail.gnu.org/r/bug-gnulib/2003-09/msg00028.html>.
157822 2003-09-06  Paul Eggert  <eggert@twinsun.com>
157824         * m4/time_r.m4: New file.
157825         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
157826         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
157827         is. Check for timegm declaration.
157828         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
157829         Do not check for gmtime_r.
157830         Replace mktime if __mktime_internal does not exist and if mktime
157831         hasn't been replaced already.
157833 2003-09-06  Paul Eggert  <eggert@twinsun.com>
157835         * lib/time_r.c, lib/time_r.h: New files.
157837         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
157838         __localtime_r.
157839         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
157840         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
157842         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
157843         __gmtime_r.
157844         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
157845         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
157846         Include <time_r.h>.
157848         * lib/timegm.c: Switch to glibc implementation, with the following
157849         changes:
157850         [defined HAVE_CONFIG_H]: Include <config.h>.
157851         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
157852         (__mktime_internal) [!defined _LIBC]: New decl.
157853         (__gmtime_r) [!defined _LIBC]: New macro and function.
157854         (timegm): Use a prototype, since gnulib assumes C89.
157855         Do not bother declaring tmp to be const, as it's not really usefu.
157856         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
157857         (timegm): Declare only if HAVE_DECL_TIMEGM.
157859 2003-09-06  Paul Eggert  <eggert@twinsun.com>
157861         * MODULES.html.sh (func_all_modules): Add time_r.
157862         * modules/time_r: New file.
157863         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
157864         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
157866 2003-09-03  Paul Eggert  <eggert@twinsun.com>
157868         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
157869         Bug reported by Lute Kamstra in
157870         <http://mail.gnu.org/r/bug-gnulib/2003-09/msg00003.html>.
157872         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
157873         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
157874         course with correspondingly smaller numbers for tomorrow and
157875         yesterday.  From Tadayoshi Funaba.  Originally installed into
157876         sh-utils on 1999-08-07, but the patch got lost (I guess during the
157877         coreutils merge?).
157879 2003-08-31  Simon Josefsson  <jas@extundo.com>
157881         * modules/timegm: New file.
157882         * MODULES.html.sh (func_all_modules): Add timegm.
157884 2003-08-31  Simon Josefsson  <jas@extundo.com>
157886         * m4/timegm.m4: New file.
157888 2003-08-31  Simon Josefsson  <jas@extundo.com>
157890         * lib/timegm.h: New file.
157891         * lib/timegm.c: New file.  Based on
157892         wget-1.8.2/src/http.c:mktime_from_utc.
157894 2003-08-31  Karl Berry  <karl@gnu.org>
157896         * lib/argp.h: update from libc.
157898 2003-08-28  Bruno Haible  <bruno@clisp.org>
157900         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
157901         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
157902         followed by '#define fnmatch fnmatch_posix' gives an error.
157904 2003-08-28  Bruno Haible  <bruno@clisp.org>
157906         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
157907         warning on QNX, which defines O_BINARY to 000000.
157909 2003-08-27  Jim Meyering  <jim@meyering.net>
157911         * m4/mkstemp.m4: Require that the system mkstemp be able to create
157912         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
157913         would fail after 32.  Reported by Danny Levinson.  Details here:
157914         http://mail.gnu.org/r/bug-coreutils/2003-08/msg00124.html
157916 2003-08-24  Bruno Haible  <bruno@clisp.org>
157918         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
157919         MSVC7 <stdio.h> is included later.
157921 2003-08-22  Simon Josefsson  <jas@extundo.com>
157923         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
157925 2003-08-20  Karl Berry  <karl@gnu.org>
157927         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
157929 2003-08-20  Bruno Haible  <bruno@clisp.org>
157931         * modules/progname: New file.
157932         * MODULES.html.sh (func_all_modules): Add progname.
157934 2003-08-20  Bruno Haible  <bruno@clisp.org>
157936         * lib/progname.h: New file, from GNU gettext.
157937         * lib/progname.c: New file, from GNU gettext.
157938         * lib/progreloc.c: New file, from GNU gettext.
157940 2003-08-19  Jim Meyering  <jim@meyering.net>
157942         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
157943         http://mail.gnu.org/r/bug-gnulib/2003-08/msg00155.html
157945 2003-08-19  Bruno Haible  <bruno@clisp.org>
157947         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
157948         more.
157950 2003-08-19  Bruno Haible  <bruno@clisp.org>
157952         * lib/xstrdup.c: Assume <string.h> exists.
157954 2003-08-18  Paul Eggert  <eggert@twinsun.com>
157956         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
157957         in makefile rules.
157959 2003-08-18  Jim Meyering  <jim@meyering.net>
157961         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
157962         * m4/lib-ld.m4: Likewise.
157964 2003-08-18  Jim Meyering  <jim@meyering.net>
157966         * lib/setenv.h: Indent nested cpp directive.
157967         * lib/vasnprintf.c: Remove trailing blanks.
157969 2003-08-17  Simon Josefsson  <jas@extundo.com>
157971         * modules/xstrndup: New file.
157972         * MODULES.html.sh (func_all_modules): Add xstrndup.
157974 2003-08-17  Simon Josefsson  <jas@extundo.com>
157976         * modules/argp: Fix autoconf macro name. Add more dependencies.
157978 2003-08-17  Simon Josefsson  <jas@extundo.com>
157980         * m4/xstrndup.m4: New file.
157982 2003-08-17  Simon Josefsson  <jas@extundo.com>
157984         * m4/argp.m4: New file.
157986 2003-08-17  Simon Josefsson  <jas@extundo.com>
157987             Bruno Haible  <bruno@clisp.org>
157989         * lib/xstrndup.h: New file.
157990         * lib/xstrndup.c: New file.
157992 2003-08-17  Bruno Haible  <bruno@clisp.org>
157994         * modules/strndup (Files, Include): Add lib/strndup.h.
157996 2003-08-17  Bruno Haible  <bruno@clisp.org>
157998         * modules/euidaccess (Files): Add lib/euidaccess.h.
158000 2003-08-17  Bruno Haible  <bruno@clisp.org>
158002         * lib/strndup.h: New file.
158004 2003-08-17  Bruno Haible  <bruno@clisp.org>
158006         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
158007         like AC_GNU_SOURCE.
158008         * modules/extensions (configure.ac): Comment out the invocation of
158009         gl_USE_SYSTEM_EXTENSIONS.
158011 2003-08-16  Paul Eggert  <eggert@twinsun.com>
158013         Merges from coreutils, etc.
158014         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
158015         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
158016         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
158017         fixing a typo.
158018         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
158019         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
158021 2003-08-16  Paul Eggert  <eggert@twinsun.com>
158023         Document merge from coreutils.
158024         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
158025         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
158026         * modules/utime: Add m4/utimes-null.m4.
158028 2003-08-16  Paul Eggert  <eggert@twinsun.com>
158030         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
158031         space, undoing this 2003-08-12 change:
158032         <http://mail.gnu.org/r/bug-gnulib/2003-08/msg00080.html>
158034 2003-08-16  Paul Eggert  <eggert@twinsun.com>
158036         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
158037         strtoul.c from libc, undoing this 2003-08-12 change:
158038         <http://mail.gnu.org/r/bug-gnulib/2003-08/msg00080.html>
158040 2003-08-16  Jim Meyering  <jim@meyering.net>
158042         Merges from coreutils.
158043         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
158044         prefix.  Adjust cache variables similarly.  Create 500 rather than
158045         just 300 files, to exercise bug on Darwin6.5, too.
158046         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
158047         $missing_dir.
158048         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
158049         AM_SYS_POSIX_TERMIOS.
158050         Reported by mkc@mathdogs.com.
158051         Also change use of $am_cv_sys_posix_termios
158052         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
158053         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
158054         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
158055         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
158056         in /proc/mounts until it finds one with matching device number.  This
158057         is unnecessary when the FILE argument *is* a mount point.  No stat call
158058         is necessary in that case.  So, disable the statvfs-testing code on
158059         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
158060         as RedHat bug# 84846.
158061         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
158062         to 1MB, so as not to render systems with no stack size limit (e.g.,
158063         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
158064         Include <unistd.h>.  On some systems,
158065         it is required for the definition of _SC_PAGESIZE.
158067 2003-08-16  Jim Meyering  <jim@meyering.net>
158069         Merge from coreutils.
158070         * lib/xstrtoimax.c: #else #if -> #elif.
158071         * lib/xstrtoumax.c: Likewise.
158073 2003-08-16  Jim Meyering  <jim@meyering.net>
158075         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
158076         * m4/utimes.m4: Removed.
158077         * m4/utimes-null.m4: Renamed from utimes.m4.
158079         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
158080         to 1MB, so as not to render systems with no stack size limit (e.g.,
158081         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
158082         Include <unistd.h>.  On some systems,
158083         it is required for the definition of _SC_PAGESIZE.
158085 2003-08-16  Jim Meyering  <jim@meyering.net>
158086         and Paul Eggert  <eggert@cs.ucla.edu>
158088         Merges from coreutils, etc.
158090         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
158091         using the latest version from cvs.  This avoids problems with #line
158092         directives using a vendor (Sun) compiler.
158093         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
158094         Don't set GETGROUPS_LIB here; now it's
158095         done via getgroups.m4's wrapper function.
158096         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
158097         rather than just in sh-util/configure.in, so that the
158098         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
158099         same.
158100         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
158101         AC_FUNC_GETLOADAVG where to find getloadavg.c.
158102         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
158103         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
158104         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
158105         Remove code that is now done by the newly-required macros.
158106         Append $(EXEEXT) to DF_PROG.
158107         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
158108         Do not invoke or require the following here,
158109         since prereq.m4 or some gnulib .m4 now does this for us:
158110         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
158111         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
158112         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
158113         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
158114         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
158115         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
158116         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
158117         AC_FUNC_OBSTACK.
158118         Do not replace the following functions, as this is now the job
158119         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
158120         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
158121         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
158122         atexit getpass, strdup, getpagesize.
158123         Replace 'raise'.
158124         Do not check for the following functions, as this is now the job
158125         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
158126         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
158127         setregid.
158128         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
158129         Check for sys/sysctl.h.
158130         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
158131         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
158132         of checking for ssize_t ourselves.
158134         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
158135         Require every macro that gnulib/modules/* suggests for us.
158136         (jm_PREREQ_ADDEXT): New macro.
158137         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
158138         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
158140         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
158141         (gl_PHYSMEM): Use it.
158142         Also check for `table' function.
158143         Check for new headers and functions.
158144         Add check for sys/sysmp.h.
158145         With suggestions from Kaveh Ghazi.
158146         Ignore headers that are present but cannot be compiled.  This
158147         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
158148         C 5.4.
158150 2003-08-15  Paul Eggert  <eggert@twinsun.com>
158152         Document merge from coreutils.
158153         * modules/userspec: Depend on posixver.
158154         * modules/strftime: Depend on tzset.
158156 2003-08-15  Paul Eggert  <eggert@twinsun.com>
158158         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
158159         rather than tab, after '#' in shell-script copyright notices.
158160         Suggested by Bruno Haible.
158162 2003-08-15  Paul Eggert  <eggert@twinsun.com>
158164         * config/srclist-update: Use three spaces, rather than tab, after '#'
158165         in shell-script copyright notices.  Suggested by Bruno Haible.
158166         Remove unnecessary parenthesization in regular expression.
158168 2003-08-15  Jim Meyering  <jim@meyering.net>
158170         Merge from coreutils.
158171         * lib/xgethostname.c: Include <stdlib.h>.
158172         (xghostname): Don't exit for anything other than memory-related
158173         failure; just return NULL.
158174         * lib/userspec.c: Include "posixver.h".
158175         (parse_user_spec): Accept `.' as a separator only
158176         in pre-POSIX-200112 mode.
158177         * lib/strtoimax.c: Use #elif rather than #else #if.
158178         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
158179         Remove function, now that we can rely on a working tzset function.
158180         [!_LIBC]: Ensure that the required autoconf test has been run.
158181         [!defined _NL_CURRENT && HAVE_STRFTIME]:
158182         Use underlying_strftime for %r.
158183         * lib/sha.c: Merge in some clean-up and optimization changes from
158184         glibc.
158185         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
158186         Ensure that it is a multiple of 64.
158187         Rearrange loop exit tests so as to avoid performing an
158188         additional fread after encountering an error or EOF.
158189         * lib/realloc.c: Update copyright date.
158191 2003-08-15  Jim Meyering  <jim@meyering.net>
158192         and Paul Eggert  <eggert@twinsun.com>
158194         Merge from coreutils.
158195         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
158196         member but strut utmpx does not.  Needed for AIX 4.3.3.
158197         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
158199 2003-08-15  Jim Meyering  <jim@meyering.net>
158200         and Paul Eggert  <eggert@cs.ucla.edu>
158202         Merges from coreutils, etc.
158203         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
158204         Require gl_FUNC_TZSET_CLOBBER.
158205         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
158206         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
158207         members.
158209 2003-08-14  Paul Eggert  <eggert@twinsun.com>
158211         Help the merge from coreutils.
158212         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
158213         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
158214         * m4/tzset.m4: Use it too.
158216 2003-08-14  Paul Eggert  <eggert@twinsun.com>
158218         * modules/tzset: New file.
158220 2003-08-14  Jim Meyering  <jim@meyering.net>
158222         Merges from coreutils.
158223         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
158224         variable names, rather than @FNMATCH_H@.
158225         * modules/alloca: Likewise for $(ALLOCA_H).
158227         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
158228         the three copies of the literal target, `fnmatch.h'.
158229         * modules/alloca (alloca.h): Likewise.
158231 2003-08-14  Jim Meyering  <jim@meyering.net>
158233         Merge from coreutils.
158234         * m4/tzset.m4: New file.
158235         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
158236         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
158237         otherwise, AIX 5.1 systems would end up using the latter.
158238         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
158239         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
158240         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
158241         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
158243 2003-08-14  Jim Meyering  <jim@meyering.net>
158245         Merge from coreutils.
158246         * lib/obstack.h: Whitespace changes.
158247         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
158248         and xcalloc return values.
158249         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
158250         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
158251         hang on OSF/1 5.1 for DIR on both local and remote file systems.
158252         Reported by (and fix confirmed by) Nelson H. F. Beebe.
158253         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
158254         error from mntctl.
158255         Use mntctl's return value to drive the entry-processing loop, since
158256         we can't rely on the value of the vmt_length member in the last
158257         entry.  On some systems doing so could result in exhausting
158258         virtual memory.  Based in part on a patch from Mike Jetzer.
158260 2003-08-14  Jim Meyering  <jim@meyering.net>
158261         and Paul Eggert  <eggert@twinsun.com>
158263         Merges from coreutils, plus other fixes.
158264         * lib/physmem.c: Merge in portability changes from gcc/libiberty
158265         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
158266         for credits and details.  Thanks to Kaveh Ghazi for helping
158267         to keep these files in sync.
158268         (ARRAY_SIZE): Define it.
158269         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
158270         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
158271         (memcasecmp): Don't assume size_t fits in unsigned int.
158272         Remove casts and duplicate code.
158273         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
158274         (memcpy): Remove definition.
158275         Merge in some clean-up and optimization changes from glibc.
158276         [BLOCKSIZE]: Move definition to top of file.
158277         Ensure that it is a multiple of 64.
158278         Rearrange loop exit tests so as to avoid performing an
158279         additional fread after encountering an error or EOF.
158280         * lib/md5.h (md5_uintptr): Define.
158281         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
158282         return to the initial working directory.  Preserve errno
158283         for caller.
158284         * lib/idcache.c: Include "xalloc.h".
158285         (xmalloc, xrealloc): Remove decls.
158286         (getuser): Remove casts no longer required in C89.
158287         * lib/human.c: Include stdio.h, for sprintf.
158288         * lib/group-member.c: Include "xalloc.h".
158289         (xmalloc, xrealloc): Remove decls.
158290         (get_group_info): Remove casts no longer required in C89.
158291         * lib/getusershell.c (readname): Remove casts no longer required in
158292         C89.
158293         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
158294         * lib/getline.c: Whitespace fix, from coreutils.
158296 2003-08-13  Paul Eggert  <eggert@twinsun.com>
158298         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
158299         Check for isascii.
158301         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
158302         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
158303         Undo previous (whitespace-only) change.
158305 2003-08-13  Paul Eggert  <eggert@twinsun.com>
158307         * lib/exclude.c: Include <ctype.h>
158308         (IN_CTYPE_DOMAIN): New macro.
158309         (is_space): New fn.
158310         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
158311         and empty lines.
158313         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
158314         Undo previous (whitespace-only) change.
158316 2003-08-13  Paul Eggert  <eggert@twinsun.com>
158318         * config/srclist-update: Change update back to the old behavior,
158319         leaving whitespace alone.  Use one 'sed' command rather than a
158320         pipeline.
158321         (fixlicense): Now a variable, not a function.
158322         (remove_trailing_blanks): Remove.
158323         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
158324         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
158325         Undo previous (whitespace-only) change.
158327 2003-08-12  Paul Eggert  <eggert@twinsun.com>
158329         Merge from coreutils.
158330         * modules/euidaccess: Add lib_SOURCES, include for new
158331         file euidaccess.h
158333 2003-08-12  Paul Eggert  <eggert@twinsun.com>
158335         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
158336         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
158337         Normalize leading white space and remove trailing white space.
158339         Merge from coreutils
158340         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
158342         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
158343         0.12.1.  These files are now being upgraded automatically by
158344         ../config/srclist-update.
158346 2003-08-12  Paul Eggert  <eggert@twinsun.com>
158348         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
158349         Normalize leading white space and remove trailing white space.
158350         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
158351         notice, as per ../config/srclist-update.
158353         Merge from coreutils.
158354         * lib/euidaccess.h: New file.
158355         * lib/euidaccess.c: Include it.
158356         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
158357         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
158358         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
158360 2003-08-12  Paul Eggert  <eggert@twinsun.com>
158362         * config/srclist-update: Add copyright notice.
158363         (remove_id_lines, remove_trailing_blanks): New constants.
158364         (fixfile): Use them to normalize spacing a bit in copied files.
158365         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
158366         Normalize leading white space and remove trailing white space.
158368         * config/texinfo.tex: Sync with texinfo.
158370         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
158371         strtoul.c from libc, to merge coreutils whitespace changes.
158373         * config/srclist.txt: Get the following m4 files from gettext:
158374         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
158375         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
158376         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
158377         wint_t.m4.
158379 2003-08-12  Karl Berry  <karl@gnu.org>
158381         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
158382         been made.
158384 2003-08-11  Paul Eggert  <eggert@twinsun.com>
158386         * modules/gnu-source, m4/gnu-source.m4:
158387         Remove; we're assuming Autoconf 2.54 or later now.
158388         Suggested by Bruno Haible.
158389         * MODULES.html.sh (func_all_modules): Remove gnu-source.
158391 2003-08-11  Bruno Haible  <bruno@clisp.org>
158393         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
158395 2003-08-11  Bruno Haible  <bruno@clisp.org>
158397         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
158398         (vasnprintf): Use it instead of wcslen.
158400 2003-08-11  Bruno Haible  <bruno@clisp.org>
158402         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
158403         value to ensure that _Bool promotes to int. Use #define for _Bool when
158404         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
158406 2003-08-10  Karl Berry  <karl@gnu.org>
158408         * lib/regex.h: update from libc (whitespace fix).
158410 2003-08-09  Paul Eggert  <eggert@twinsun.com>
158412         Merge some files from coreutils.  These changes were
158413         originally made by Jim Meyering.
158414         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
158415         many older Unixes require this.
158416         * lib/alloca.c (alloca): Remove cast to argument of free;
158417         no longer needed in C89.
158418         * lib/alloca_.h, regex.h: Fix white space to match
158419         what GNU indent does.
158421 2003-08-09  Paul Eggert  <eggert@twinsun.com>
158423         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
158424         apparently Emacs's Unicode mode got confused before my 2003-08-05
158425         checkin.
158427 2003-08-08  Paul Eggert  <eggert@twinsun.com>
158429         * m4/extensions.m4: New file.
158430         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
158431         Require gl_USE_SYSTEM_EXTENSIONS.
158432         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
158433         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
158435 2003-08-08  Paul Eggert  <eggert@twinsun.com>
158437         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
158438         * modules/extensions, modules/gnu-source: New files.
158439         * modules/timespec, modules/unlocked-io: Depend on extensions.
158441 2003-08-07  Paul Eggert  <eggert@twinsun.com>
158443         * modules/restrict: New file.
158444         * MODULES.html.sh (func_all_modules): Add restrict.
158445         * modules/regex: Depend on restrict.
158447 2003-08-07  Paul Eggert  <eggert@twinsun.com>
158449         * m4/restrict.m4: New file.
158450         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
158452 2003-08-07  Bruno Haible  <bruno@clisp.org>
158454         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
158455         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
158457 2003-08-07  Bruno Haible  <bruno@clisp.org>
158459         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
158460         makes the module 'getndelim2' compatible with the module 'getline'.
158462 2003-08-05  Paul Eggert  <eggert@twinsun.com>
158464         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
158465         byte with "\201" to avoid glitches when editing that source file
158466         with multi-gnome-terminal.
158468 2003-08-05  Paul Eggert  <eggert@twinsun.com>
158470         * lib/bumpalloc.h: Remove.
158472 2003-08-05  Paul Eggert  <eggert@twinsun.com>
158474         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
158475         * modules/bumpalloc: Remove.
158477 2003-08-04  Paul Eggert  <eggert@twinsun.com>
158479         * lib/getloadavg.c: Change copyright notice and spacing to conform to
158480         GNU coding style.
158482         Merge from coreutils.
158483         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
158484         1. From glibc.
158485         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
158486         from Karl Berry, implemented by Jim Meyering.
158487         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
158488         from Dmitry V. Levin.
158489         Remove anachronistic cast of xrealloc.
158490         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
158491         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
158492         type. Otherwise, it wouldn't compile with at least /bin/cc on
158493         ymp-cray-unicos9.0.2.X.
158494         Combine two mostly-identical uses of alloca into one.
158495         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
158497 2003-08-04  Dave Love  <d.love@dl.ac.uk>
158499         [From Emacs.]
158501         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
158502         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
158503         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
158504         obsolete NLIST_NAME_UNION.
158505         [__GNU__]: Undef BSD and FSCALE.
158506         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
158508 2003-08-03  Paul Eggert  <eggert@twinsun.com>
158510         * lib/stdbool_.h (_Bool): Make it signed char, instead of
158511         an enum type, so that it's guaranteed to promote to int.  See:
158512         <http://mail.gnu.org/r/bug-gnulib/2003-07/msg00124.html>
158514 2003-08-03  Karl Berry  <karl@gnu.org>
158516         * config/depcomp: update from automake.
158518 2003-07-31  Paul Eggert  <eggert@twinsun.com>
158520         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
158521         (strerror): Don't assume that a printable int fits in 14 bytes.
158523 2003-07-31  Bruno Haible  <bruno@clisp.org>
158525         * modules/getpass-gnu: New file.
158526         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
158528 2003-07-31  Bruno Haible  <bruno@clisp.org>
158530         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
158532 2003-07-24  Karl Berry  <karl@gnu.org>
158534         * config/missing: update from automake.
158536 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
158537             Bruno Haible  <bruno@clisp.org>
158539         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
158540         * lib/getline.c (getline, getdelim): Likewise.
158541         Remove _GNU_SOURCE define; now it's defined in config.h through
158542         m4/getline.m4.
158544 2003-07-23  Karl Berry  <karl@gnu.org>
158546         * config/config.sub: update from prep.
158548 2003-07-22  Paul Eggert  <eggert@twinsun.com>
158550         * modules/xalloc (Depends-on): Add exitfail.
158551         * modules/xmemcoll: Likewise.
158553 2003-07-22  Paul Eggert  <eggert@twinsun.com>
158555         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
158556         over-parenthesization in macros.
158558         Sync with coreutils.
158560         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
158561         required by C99.
158563         Use `exit_failure' for xalloc and xmemcoll instead of their own
158564         private exit-failure variables.
158565         * lib/xalloc.h (xalloc_exit_failure): Remove.
158566         * lib/xmalloc.c: Likewise.  Include exitfail.h.
158567         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
158568         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
158569         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
158570         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
158572 2003-07-20  Jim Meyering  <jim@meyering.net>
158574         * modules/closeout (Depends-on): Add exitfail.
158575         Suggestion from Bruno Haible.
158577 2003-07-19  Karl Berry  <karl@gnu.org>
158579         * config/config.sub: update from prep.
158581 2003-07-18  Paul Eggert  <eggert@twinsun.com>
158583         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
158584         Remove.
158585         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
158586         to test that it can stand by itself.  Include "exitfail.h".
158587         Clients should set exit_failure instead.
158588         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
158590 2003-07-18  Bruno Haible  <bruno@clisp.org>
158592         * modules/getndelim2: New file.
158593         * modules/getline: Share files with module getndelim2.
158594         * modules/getnline: Depend on getndelim2 instead of sharing files with
158595         it. Add getnline.c to lib_SOURCES.
158596         * MODULES.html.sh (func_all_modules): Add getndelim2.
158598 2003-07-18  Bruno Haible  <bruno@clisp.org>
158600         * m4/getndelim2.m4: New file.
158601         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
158602         invoke gl_PREREQ_GETNDELIM2.
158603         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
158604         gl_PREREQ_GETNDELIM2.
158605         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
158606         gl_GETNDELIM2.
158608 2003-07-18  Bruno Haible  <bruno@clisp.org>
158610         * lib/getndelim2.h: New file.
158611         * lib/getndelim2.c: Make into a module of its own. Include config.h,
158612         getndelim2.h.
158613         (getndelim2): Make non-static. Change return type to ssize_t.
158614         * lib/getline.h: Change argument names.
158615         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
158616         * lib/getnline.c: Include getndelim2.h.
158618 2003-07-18  Andreas Schwab  <schwab@suse.de>
158620         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
158622 2003-07-17  Karl Berry  <karl@gnu.org>
158624         * config/config.sub: update from prep.
158626 2003-07-17  Bruno Haible  <bruno@clisp.org>
158628         * modules/getnline: New file.
158629         * modules/getline: Add lib/getndelim2.c to source file list.
158630         * MODULES.html.sh (func_all_modules): Add getnline.
158632 2003-07-17  Bruno Haible  <bruno@clisp.org>
158634         * m4/getnline.m4: New file.
158636 2003-07-17  Bruno Haible  <bruno@clisp.org>
158638         * m4/Makefile.am.in: Remove file.
158639         * m4/Makefile.am: Remove file.
158640         * m4/Makefile.in: Remove file.
158642 2003-07-17  Bruno Haible  <bruno@clisp.org>
158644         * lib/getnline.h: New file.
158645         * lib/getnline.c: New file.
158646         * lib/getndelim2.c: New file, extracted from getline.c.
158647         (getndelim2): Renamed from getdelim2, with added nmax argument.
158648         * lib/getline.c: Include getndelim2.c.
158649         (getdelim2): Moved out to getndelim2.c.
158650         (getline, getdelim): Update.
158652 2003-07-17  Bruno Haible  <bruno@clisp.org>
158654         * lib/Makefile.am: Remove file.
158655         * lib/Makefile.in: Remove file.
158657 2003-07-17  Bruno Haible  <bruno@clisp.org>
158659         * configure.in: Remove file.
158660         * Makefile.in: Remove file.
158662 2003-07-17  Bruno Haible  <bruno@clisp.org>
158664         * MODULES.html.sh: Put the </BODY> right before </HTML>.
158666 2003-07-16  Karl Berry  <karl@gnu.org>
158668         * config/srclist-update: was running fixlicense twice, which caused
158669                 texinfo.tex to be nullified for some reason.  Simplify,
158670                 $gplsrc is no longer needed as far as I can see?
158672 2003-07-16  Jim Meyering  <jim@meyering.net>
158674         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
158676 2003-07-15  Paul Eggert  <eggert@twinsun.com>
158678         * config/srclist.txt: Get the following files from gettext-runtime/intl
158679         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
158680         ref-del.sin.  From Bruno Haible.
158681         * config/srclist-update (fixfile): Change grep pattern again, since the
158682         previous fix didn't work (there was another trailing $).  Use
158683         '[$]' to escape the $s.
158685 2003-07-15  Karl Berry  <karl@gnu.org>
158687         * lib/vasnprintf.c: update from gettext.
158689 2003-07-15  Karl Berry  <karl@gnu.org>
158691         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
158692         gets expanded when surrounded by '$'.
158694 2003-07-15  Jim Meyering  <jim@meyering.net>
158696         * modules/save-cwd: Don't depend on error.  From Derek Price.
158698 2003-07-15  Jim Meyering  <jim@meyering.net>
158700         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
158702 2003-07-14  Simon Josefsson  <jas@extundo.com>
158704         * modules/mempcpy: New file.
158705         * MODULES.html.sh (func_all_modules): Add mempcpy.
158707 2003-07-14  Simon Josefsson  <jas@extundo.com>
158709         * m4/mempcpy.m4: New file.
158711 2003-07-14  Simon Josefsson  <jas@extundo.com>
158713         * lib/mempcpy.h: New file.
158714         * lib/mempcpy.c: New file.
158716 2003-07-14  Paul Eggert  <eggert@twinsun.com>
158718         * modules/getdate, modules/posixtm: Depend on mktime.
158720 2003-07-14  Paul Eggert  <eggert@twinsun.com>
158722         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
158723         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
158724         unicodeio.c, unicodeio.h, unlocked-io.h:
158725         Switch from LGPL to GPL.
158727 2003-07-14  Paul Eggert  <eggert@twinsun.com>
158729         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
158730         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
158731         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
158732         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
158733         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
158734         updated automatically by ../config/srclist-update.  This changes
158735         their license from LPGL to GPL.
158737 2003-07-14  Paul Eggert  <eggert@twinsun.com>
158739         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
158740         assumed to refer to the root of the most recent stable gettext version.
158741         * config/srclistvars.sh: Add defaults for eggert.
158742         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
158743         Match "This program" as well as "The program".  This is needed
158744         for gettext.
158746 2003-07-14  Jim Meyering  <jim@meyering.net>
158748         Don't emit diagnostics.  Let callers do that.
158749         * lib/save-cwd.c: Don't include "error.h".
158750         (save_cwd): Don't call error.  Ensure that errno is valid
158751         when returning nonzero.
158753         * lib/save-cwd.h (restore_cwd): Update prototype.
158754         * lib/save-cwd.c (restore_cwd): Remove two parameters.
158755         Simplify.  Don't call error upon failure.  Let callers do that.
158756         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
158757         when auditing is enabled.  But don't bother updating the #if.
158759 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
158761         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
158762         it breaks C++ compilation.
158763         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
158765 2003-07-10  Simon Josefsson  <jas@extundo.com>
158767         * modules/strchrnul (Makefile.am): Add strchrnul.h.
158769 2003-07-10  Jim Meyering  <jim@meyering.net>
158771         * m4/clock_time.m4: Remove trailing blank.
158772         * m4/intmax_t.m4: Likewise.
158774 2003-07-10  Jim Meyering  <jim@meyering.net>
158776         * lib/vasnprintf.c: Remove trailing blanks.
158777         Make cpp indentation consistent.
158779 2003-07-09  Paul Eggert  <eggert@twinsun.com>
158781         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
158782         posixver.c, strftime.c, strnlen.c, strverscmp.c:
158783         Switch from LGPL to GPL.
158785 2003-07-09  Paul Eggert  <eggert@twinsun.com>
158787         * config/srclist.txt: Sort sublists.  Add
158788         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
158789         that differ from gnulib for one reason or another; we'd like this list
158790         to be smaller but for now let's document what we have.
158792 2003-07-08  Paul Eggert  <eggert@twinsun.com>
158794         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
158795         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
158796         and sweeter "eval x=$x".
158797         * config/srclist.txt: Get lib/argp* from glibc.
158799 2003-07-07  Paul Eggert  <eggert@twinsun.com>
158801         * lib/mktime.c: Fix some boundary cases and remove need for floating
158802         point.
158804         Issue a compile-time diagnostic if time_t is floating point, or if
158805         two's complement arithmetic is not in effect, or if arithmetic
158806         right shift does not propagate the sign.  These assumptions were
158807         all in the original code but they weren't checked.
158809         (TIME_T_MIDPOINT, verify): New macros.
158810         (__isleap): Remove; it has integer overflow problems.
158811         (leapyear): New function, without those problems.
158812         (ydhms_tm_diff): Remove; splitting into two parts.
158813         (ydhms_diff): New function, containing the arithmetic part of
158814         the old ydhms_tm_diff function.  Issue a compile-time
158815         diagnostic if we are not using C99 integer division.
158816         Avoid casts when possible.
158817         (guess_time_tm): New function, containing the checking part of
158818         the old ydhms_tm_diff function.  Return the new value, rather than
158819         the difference between it and the old.  Accept a new argument T
158820         so that *T specifies the old value.  Check for overflow in the result.
158822         (__mktime_internal): Use a time_t offset, not a long int offset.
158823         This undoes the 2003-06-04 change, which is no longer needed now
158824         that we have better overflow checking.
158825         (localtime_offset): Likewise.
158827         (__mktime_internal): Avoid harmful overflow on hosts where time_t
158828         and long are 64-bit but int is only 32-bit.
158829         (ydhms_diff): Use long int to store year1 and yday1.
158830         Issue a compile-time diagnostic if long int is not wide enough.
158832         (__mktime_internal): Use long int to store adjusted year and yday.
158833         Use plain C rather than preprocessor commands, if that doesn't
158834         affect efficiency.
158835         Check for overflow (and try to repair) after each probe
158836         rather than checking only at the very end.  This avoids some bugs
158837         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
158838         does not equal GMT offset at maximum time).
158839         Use integer to check for overflow rather than floating point; this
158840         is more portable to non-IEEE hosts, and is a tad faster.
158841         When we detect that we are oscillating between two values,
158842         don't check whether tm_isdst has the requested value, since
158843         we already know the answer.  When tm_isdst has the wrong value,
158844         use a different heuristic to find the right one, based on the
158845         extreme values actually observed in practice in tz2003a,
158846         rather than the (overly optimistic) "previous 3 calendar quarters".
158848         (not_equal_tm, print_tm, check_result): Use "const T" rather than
158849         "T const" to accommodate glibc style.
158850         (check_result): Use less-confusing report format.  "long" -> "long int.
158851         (main): Likewise.
158852         Don't loop if the iteration overflows time_t.
158853         Allow a negative step in the iteration.
158855 2003-07-06  Karl Berry  <karl@gnu.org>
158857         * config/depcomp: update from automake.
158858         * config/config.sub: update from prep.
158860 2003-07-03  Karl Berry  <karl@gnu.org>
158862         * config/config.guess: update from prep.
158864 2003-07-01  Paul Eggert  <eggert@twinsun.com>
158866         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
158867         xreadlink.c now includes it unconditionally.
158869 2003-07-01  Paul Eggert  <eggert@twinsun.com>
158871         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
158872         having it depend on HAVE_SYS_TYPES_H.
158874 2003-07-01  Bruno Haible  <bruno@clisp.org>
158876         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
158877         <sys/types.h> should be sufficient.
158878         Reported by Paul Eggert.
158880 2003-06-26  Karl Berry  <karl@gnu.org>
158882         * config/depcomp: update from automake.
158884 2003-06-26  Bruno Haible  <bruno@clisp.org>
158886         * modules/human: Depend on module stdbool.
158888 2003-06-25  Bruno Haible  <bruno@clisp.org>
158890         * modules/readlink: New file.
158891         * modules/xreadlink: Depend on it.
158892         * MODULES.html.sh (func_all_modules): Add readlink.
158894 2003-06-25  Bruno Haible  <bruno@clisp.org>
158896         * m4/readlink.m4: New file.
158898 2003-06-25  Bruno Haible  <bruno@clisp.org>
158900         * lib/readlink.c: New file.
158902 2003-06-22  Karl Berry  <karl@gnu.org>
158904         * config/srclist.txt: update mkinstalldirs from automake.
158905         * config/mkinstalldirs: update.
158907 2003-06-22  Bruno Haible  <bruno@clisp.org>
158909         Portability to mingw32.
158910         * m4/ssize_t.m4: New file, from GNU gettext.
158911         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
158912         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
158914 2003-06-22  Bruno Haible  <bruno@clisp.org>
158916         * modules/safe-read: Add m4/ssize_t.m4.
158917         * modules/xreadlink: Add m4/ssize_t.m4.
158919 2003-06-20  Bruno Haible  <bruno@clisp.org>
158921         Assume C89, so PARAMS isn't needed.
158922         * lib/unicodeio.h (PARAMS): Remove.
158923         * lib/unicodeio.c: Don't use PARAMS.
158925 2003-06-18  Karl Berry  <karl@gnu.org>
158927         * config/config.{guess,sub}: update from prep.
158929 2003-06-18  Jim Meyering  <jim@meyering.net>
158931         Merge changes from coreutils.
158932         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
158933         Remove explicit declarations of xmalloc and realloc.
158934         Include xalloc.h.
158935         (read_utmp): Remove anachronistic cast of xmalloc.
158937 2003-06-17  Paul Eggert  <eggert@twinsun.com>
158939         Assume C89, so PARAMS isn't needed.
158940         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
158941         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
158942         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
158943         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
158944         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
158945         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
158946         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
158947         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
158948         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
158949         lib/xstrtod.h, lib/xstrtol.h: Likewise.
158950         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
158951         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
158952         no longer needed. Anyway, config.h should always be included before any
158953         other file.
158955 2003-06-11  Simon Josefsson  <jas@extundo.com>
158957         * modules/sysexits: New file.
158958         * MODULES.html.sh (func_all_modules): Add sysexits.
158960 2003-06-11  Simon Josefsson  <jas@extundo.com>
158962         * lib/sysexit_.h: New file.
158964 2003-06-11  Derek Price  <derek@ximbiot.com>
158966         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
158967         necessary.
158969 2003-06-11  Bruno Haible  <bruno@clisp.org>
158971         * m4/sysexits.m4: New file.
158973 2003-06-10  Simon Josefsson  <jas@extundo.com>
158975         * lib/argp.h: New file, from glibc.
158976         * lib/argp-ba.c: New file, from glibc.
158977         * lib/argp-eexst.c: New file, from glibc.
158978         * lib/argp-fmtstream.c: New file, from glibc.
158979         * lib/argp-fmtstream.h: New file, from glibc.
158980         * lib/argp-fs-xinl.c: New file, from glibc.
158981         * lib/argp-help.c: New file, from glibc.
158982         * lib/argp-namefrob.h: New file, from glibc.
158983         * lib/argp-parse.c: New file, from glibc.
158984         * lib/argp-pv.c: New file, from glibc.
158985         * lib/argp-pvh.c: New file, from glibc.
158986         * lib/argp-xinl.c: New file, from glibc.
158988 2003-06-10  Simon Josefsson  <jas@extundo.com>
158990         * modules/strchrnul: New file.
158992 2003-06-10  Simon Josefsson  <jas@extundo.com>
158994         * modules/argp: New file.
158996 2003-06-10  Simon Josefsson  <jas@extundo.com>
158998         * m4/strchrnul.m4: New file.
159000 2003-06-10  Simon Josefsson  <jas@extundo.com>
159002         * lib/strchrnul.h: New file.
159003         * lib/strchrnul.c: New file.
159005 2003-06-10  Bruno Haible  <bruno@clisp.org>
159007         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
159009 2003-06-07  Karl Berry  <karl@gnu.org>
159011         * config/config.{guess,sub}: update from prep.
159013 2003-06-07  Jim Meyering  <jim@meyering.net>
159015         * modules/strtod: Use $(...) notation, not @...@ for
159016         AC_REPLACE'd variables.
159017         * modules/localcharset: Likewise.
159019 2003-06-07  Jim Meyering  <jim@meyering.net>
159021         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
159022         in place of my name in the copyright comment.
159023         Remove definition and uses of __P.
159025         From coreutils.
159026         * lib/stat.c: Don't declare xmalloc explicitly.
159027         Instead, include "xalloc.h".
159028         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
159029         xrealloc, and xcalloc return values.
159030         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
159031         Improve comment.
159032         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
159034 2003-06-07  Bruno Haible  <bruno@clisp.org>
159036         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
159037         avoid AC_CONFIG_LINKS.
159038         * modules/fnmatch (Makefile.am): Use explicit creation rule for
159039         fnmatch.h, to avoid AC_CONFIG_LINKS.
159040         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
159042 2003-06-07  Bruno Haible  <bruno@clisp.org>
159044         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
159045         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
159046         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
159047         directory.
159048         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
159049         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
159050         directory.
159052 2003-06-06  Jim Meyering  <jim@meyering.net>
159054         Merge from coreutils.
159055         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
159056         Consolidate declarations and initializations of *_base* locals.
159058         Merge from coreutils.
159059         This avoids a core dump on systems without GNU putenv,
159060         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
159061         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
159062         (unsetenv): New static function, from GNU libc.
159063         (rpl_putenv): Use it.
159065         * lib/modechange.c: Remove trailing blanks.
159067         Merge from coreutils.
159068         * lib/fsusage.c: Remove declaration of statfs.
159069         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
159071         * lib/posixtm.c: Include <stdbool.h> unconditionally.
159073 2003-06-06  Jim Meyering  <jim@meyering.net>
159075         * lib/stdbool_.h: Renamed from stdbool.h.in.
159077 2003-06-06  Jim Meyering  <jim@meyering.net>
159078             Bruno Haible  <bruno@clisp.org>
159080         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
159081         Adjust Makefile.am snippet not to redirect directly to target.
159082         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
159084 2003-06-05  Paul Eggert  <eggert@twinsun.com>
159086         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
159087         mismatch, look in future quarters as well as past.  This fixes a
159088         bug when processing fall-backwards gaps immediately after a long
159089         period of daylight-saving time.
159091         * lib/mktime.c: Assume freestanding C89 or better.
159092         (HAVE_LIMITS_H): Remove.  Assume it's 1.
159093         (__P): Remove; not used.
159094         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
159095         (mktime, not_equal_tm, print_tm, check_result,
159096         main): Use prototypes.  Use const * where appropriate.
159097         (main): Fix typo in testing code that uncovered by above changes.
159098         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
159100 2003-06-04  Paul Eggert  <eggert@twinsun.com>
159102         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
159103         locale.h, localeconv.  This merges changes from coreutils.
159105         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
159106         It can be removed after the next Autoconf is released.
159107         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
159108         needed.
159110 2003-06-04  Paul Eggert  <eggert@twinsun.com>
159112         * lib/mktime.c: Fix Debian bug 177940
159113         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
159114         (localtime_offset): Now long int, not time_t, because we want it
159115         to be guaranteed to be signed.  All uses changed.
159116         (__mktime_internal): If overflow would occur when adding offset,
159117         don't add it.
159119         Merge 'human' changes from coreutils.  Rewrite to support
159120         locale-specific notations like thousands separators.
159121         * lib/human.c: Simplify authorship notice.
159122         Include human.h immediately after config.h.
159123         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
159124         <limits.h>: Do not include, since human.h does.
159125         (SIZE_MAX, UINTMAX_MAX): New macros.
159126         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
159127         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
159128         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
159129         (power_letter): Renamed from suffixes.
159130         (generate_suffix_backwards): Remove.
159131         (adjust_value): Now takes int style (because of human.h changes)
159132         and long double value (for greater precision on some platforms).
159133         (group_number): New function.
159134         (human_readable): Use it.  Use integer options, not enum.
159135         Put the options before the sizes in the arg list.
159136         Support all the new options.
159137         The old human_readable function has been removed;
159138         use inttostr.h instead.
159139         (human_readable, default_block_size, humblock):
159140         Use uintmax_t, not int, for block sizes.
159141         (human_readable_inexact, block_size_types): Remove.
159142         (block_size_opts): New constant.
159143         (human_options): Renamed from human_block_size, with new signature
159144         that allows block sizes up to UINTMAX_MAX.  All callers changed.
159145         * lib/human.h: Add copyright and authorship notice.
159146         Include <limits.h> and <stdbool.h> unconditionally.
159147         (PARAMS): Remove.  All uses removed.
159148         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
159149         (enum human_inexact_style): Remove tag; now a nameless enum.
159150         (human_floor, human_ceiling, human_round_to_even): Now have
159151         values 2, 0, 1 rather than -1, 1, 0.
159152         (human_group_digits, human_suppress_point_zero, human_autoscale,
159153         human_base_1024, human_SI, human_B): New constants.
159154         (human_readable_inexact, human_block_size): Remove.
159155         (human_readable): Size args are now uintmax_t, not int.
159156         (human_options): New decl.
159158         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
159159         unnecessary now that we assume C89 or better.  This change
159160         imported from coreutils.
159162         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
159163         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
159164         in the 2003-05-30 sync from glibc.
159166         .h files should stand alone, but we shouldn't include <sys/types.h>
159167         if we can get away with just <stddef.h>.
159169         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
159170         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
159171         rather than <sys/types.h>, as we merely need size_t.
159172         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
159173         to get size_t.
159174         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
159175         Include <stdio.h>, to get FILE.
159176         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
159177         memcasecmp.h has included <stddef.h> and all we need is size_t.
159178         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
159179         our interface, instead of including <sys/types.h>
159181 2003-06-04  Paul Eggert  <eggert@twinsun.com>
159183         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
159184         now, as glibc mktime is buggy on non-glibc systems.
159186 2003-06-03  Karl Berry  <karl@gnu.org>
159188         * config/config.sub: update from prep.
159190 2003-06-02  Paul Eggert  <eggert@twinsun.com>
159192         [from coreutils]
159193         Fix some minor time-related bugs with POSIX time arguments.
159194         Some valid time stamps were being rejected (notably -1, and
159195         time stamps before 1900 on 64-bit hosts).  And some invalid
159196         time stamps were being accepted, e.g. September 31.
159198         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
159199         that we can return (time_t) -1 successfully.
159200         * lib/posixtm.c: Likewise.
159201         [HAVE_STDBOOL_H]: Include <stdbool.h>.
159202         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
159203         (t): Remove static var.
159204         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
159205         of static var.  All uses changed.
159206         (year): Do not reject years before 1900; they can occur with
159207         64-bit time_t.
159208         (posix_time_parse): Do not check for out-of-range components;
159209         that is now the caller's responsibility, since our checks were
159210         only approximations.
159211         (posixtime): Use mktime to check for out-of-range components,
159212         since it knows them exactly.
159213         If mktime returns (time_t) -1, check whether an error actually occurred
159214         by invoking localtime on -1.
159215         (main) [TEST_POSIXTIME]: Check for input data errors, and report
159216         posixtime failures better.
159217         Improve the test data (in comments only).
159219 2003-06-02  Karl Berry  <karl@gnu.org>
159221         * config/mkinstalldirs (version): new variable.
159222         (--version): new option.
159223         (usage): improve message.
159225 2003-05-30  Karl Berry  <karl@gnu.org>
159227         * lib/mktime.c: update from libc.
159229 2003-05-30  Bruno Haible  <bruno@clisp.org>
159231         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
159232         * config/config.rpath: Upgrade to gettext-0.12.1.
159234 2003-05-30  Bruno Haible  <bruno@clisp.org>
159236         * m4/gettext.m4: Upgrade to gettext-0.12.1.
159237         * m4/nls.m4: New file, from gettext-0.12.1.
159238         * m4/po.m4: New file, from gettext-0.12.1.
159239         * m4/progtest.m4: Upgrade to gettext-0.12.1.
159241 2003-05-30  Bruno Haible  <bruno@clisp.org>
159243         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
159244         * lib/localcharset.h: Likewise.
159245         * lib/localcharset.c: Likewise.
159247 2003-05-29  Karl Berry  <karl@gnu.org>
159249         * config/config.rpath: update from gettext.
159251 2003-05-28  Paul Eggert  <eggert@twinsun.com>
159253         Assume the headers required for C89 freestanding compilers.
159254         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
159255         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
159256         * m4/human.m4 (gl_HUMAN): Likewise.
159257         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
159258         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
159259         * m4/userspec.m4 (gl_USERSPEC): Likewise.
159260         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
159261         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
159262         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
159264 2003-05-28  Paul Eggert  <eggert@twinsun.com>
159266         Assume the headers required for C89 freestanding compilers.
159267         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
159268         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
159269         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
159270         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
159271         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
159272         define, since <limits.h> is guaranteed to do that.
159273         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
159274         * lib/exclude.c: Include <stdbool.h> unconditionally.
159275         * lib/tempname.c: Include <stddef.h> unconditionally.
159276         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
159277         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
159278         <stddef.h> does that.
159279         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
159280         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
159281         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
159282         needed.
159283         * lib/xstrtol.c: Likewise.
159284         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
159285         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
159287         * lib/addext.c (addext): Use assignment rather than cast, to avoid
159288         warnings on some platforms.
159290         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
159291         arbitrarily.
159293 2003-05-26  Jim Meyering  <jim@meyering.net>
159295         Merge in a change from coreutils:
159296         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
159297         that is guaranteed to be `no'.  Use `no_such_member' to indicate
159298         that condition, rather than `-1' which is slightly misleading.
159299         Change the name of the cache variable to have the gl_ prefix.
159300         Prompted by a patch from Richard Dawe for DJGPP.
159302 2003-05-24  Karl Berry  <karl@gnu.org>
159304         * config/config.guess: update from prep.
159306 2003-05-22  Karl Berry  <karl@gnu.org>
159308         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
159310 2003-05-20  Karl Berry  <karl@gnu.org>
159312         * config/config.guess: update from prep.
159314 2003-05-18  Karl Berry  <karl@gnu.org>
159316         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
159317         might actually be set by the user.
159319         * config/depcomp, install-sh, mdate-sh: update from automake.
159321 2003-05-17  Bruno Haible  <bruno@clisp.org>
159323         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
159324         invalid expansion for AC_EGREP_CPP.
159325         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
159326         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
159327         Suggested by Akim Demaille <akim@epita.fr> in
159328         http://mail.gnu.org/r/bug-autoconf/2003-05/threads.html
159330 2003-05-12  Jim Meyering  <jim@meyering.net>
159332         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
159333         the space-padded-by-default conversion specifiers, %e, %k, %l.
159335 2003-05-12  Bruno Haible  <bruno@clisp.org>
159337         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
159338         the string is longer than 4 KB.
159340 2003-05-11  Karl Berry  <karl@gnu.org>
159342         * config/config.{guess,sub}: update from prep.
159344 2003-05-09  Bruno Haible  <bruno@clisp.org>
159346         * modules/error: Add m4/strerror_r.m4 to file list.
159348 2003-05-03  Bruno Haible  <bruno@clisp.org>
159350         Upgrade to Unicode-4.0.
159351         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
159352         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
159353         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
159354         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
159355         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
159356         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
159357         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
159358         Change width of U+E0100..U+E01EF from 1 to 0.
159360 2003-04-25  Jim Meyering  <jim@meyering.net>
159362         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
159363         of type size_t, not int.
159365 2003-04-25  Bruno Haible  <bruno@clisp.org>
159367         * lib/copy-file.c: Include <stddef.h>, for size_t.
159369 2003-04-21  Paul Eggert  <eggert@twinsun.com>
159371         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
159372         code which expansion is under static control.  Patch imported from
159373         Akim Demaille's patch to Bison; see
159374         <http://mail.gnu.org/r/bison-patches/2003-03/msg00057.html>.
159376 2003-04-14  Bruno Haible  <bruno@clisp.org>
159378         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
159380 2003-04-11  Jim Meyering  <jim@meyering.net>
159382         Merge changes from Coreutils.
159384         2003-03-22  Jim Meyering  <jim@meyering.net>
159386         * lib/strftime.c (widen): Cast alloca return value to proper type.
159388         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
159390         From GNU libc.
159391         * lib/strftime.c (my_strftime): Handle very large width
159392         specifications for numeric values correctly.  Improve checks for
159393         overflow.
159395         2003-01-19  Jim Meyering  <jim@meyering.net>
159397         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
159398         definitions.
159399         (nl_get_alt_digit) [! defined my_strftime]: Define.
159400         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
159401         _nl_get_alt_digit and _nl_get_walt_digit.
159403         * lib/strftime.c (my_strftime): Merge in locale-related changes from
159404         libc. These changes have no effect outside of _LIBC.
159406 2003-04-10  Bruno Haible  <bruno@clisp.org>
159408         * modules/findprog: New file.
159409         * MODULES.html.sh (func_all_modules): Add it.
159411 2003-04-10  Bruno Haible  <bruno@clisp.org>
159413         * m4/findprog.m4: New file.
159414         * m4/eaccess.m4: New file.
159416 2003-04-10  Bruno Haible  <bruno@clisp.org>
159418         * lib/findprog.h: New file, from GNU gettext.
159419         * lib/findprog.c: New file, from GNU gettext.
159421 2003-04-05  Jim Meyering  <jim@meyering.net>
159423         Merge changes from Coreutils.
159425         * lib/exclude.h (PARAMS): Remove definition and uses.
159426         * lib/exclude.c: Remove uses of `PARAMS'.
159428         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
159429         Add test-cases for DOS filenames. Declare program_name.
159430         (main): Set up program_name.  Patch by Rich Dawe.
159432         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
159433         error from mntctl.
159434         Use mntctl's return value to drive the entry-processing loop, since
159435         we can't rely on the value of the vmt_length member in the last
159436         entry.  On some systems doing so could result in exhausting
159437         virtual memory.  Based in part on a patch from Mike Jetzer.
159439 2003-04-04  Bruno Haible  <bruno@clisp.org>
159441         * modules/linebreak: New file.
159442         * MODULES.html.sh (func_all_modules): Add it.
159444 2003-04-04  Bruno Haible  <bruno@clisp.org>
159446         * m4/linebreak.m4: New file.
159448 2003-04-04  Bruno Haible  <bruno@clisp.org>
159450         * lib/linebreak.h: New file, from GNU gettext.
159451         * lib/linebreak.c: New file, from GNU gettext with slight
159452         modifications.
159453         * lib/lbrkprop.h: New file, from GNU gettext.
159455 2003-04-03  Bruno Haible  <bruno@clisp.org>
159457         * modules/utf8-ucs4: New file.
159458         * modules/utf16-ucs4: New file.
159459         * modules/ucs4-utf8: New file.
159460         * modules/ucs4-utf16: New file.
159461         * MODULES.html.sh (func_all_modules): Add them.
159463 2003-04-03  Bruno Haible  <bruno@clisp.org>
159465         * m4/utf-ucs4.m4: New file.
159466         * m4/ucs4-utf.m4: New file.
159468 2003-04-03  Bruno Haible  <bruno@clisp.org>
159470         * lib/utf8-ucs4.h: New file, from GNU gettext.
159471         * lib/utf16-ucs4.h: New file, from GNU gettext.
159472         * lib/ucs4-utf8.h: New file, from GNU gettext.
159473         * lib/ucs4-utf16.h: New file, from GNU gettext.
159475 2003-04-02  Bruno Haible  <bruno@clisp.org>
159477         * modules/binary-io: New file.
159478         * MODULES.html.sh (func_all_modules): Add it.
159480 2003-04-02  Bruno Haible  <bruno@clisp.org>
159482         * lib/binary-io.h: New file, from GNU gettext.
159484 2003-04-01  Bruno Haible  <bruno@clisp.org>
159486         * modules/pathname: New file.
159487         * MODULES.html.sh (func_all_modules): Add it.
159489 2003-04-01  Bruno Haible  <bruno@clisp.org>
159491         * lib/pathname.h: New file, from GNU gettext.
159492         * lib/concatpath.c: New file, from GNU gettext.
159494 2003-03-30  Bruno Haible  <bruno@clisp.org>
159496         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
159498 2003-03-30  Bruno Haible  <bruno@clisp.org>
159500         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
159501         function chown() doesn't exist.
159503 2003-03-28  Bruno Haible  <bruno@clisp.org>
159505         * modules/copy-file: New file.
159506         * MODULES.html.sh (func_all_modules): Add it.
159508 2003-03-28  Bruno Haible  <bruno@clisp.org>
159510         * m4/copy-file.m4: New file.
159512 2003-03-28  Bruno Haible  <bruno@clisp.org>
159514         * lib/copy-file.h: New file, from GNU gettext.
159515         * lib/copy-file.c: New file, from GNU gettext.
159517 2003-03-18  Jim Meyering  <jim@meyering.net>
159519         * lib/quote.c (quote_n): Fix typo in comment.
159521 2003-03-18  Bruno Haible  <bruno@clisp.org>
159523         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
159524         checking.
159525         * m4/onceonly_2_57.m4: Likewise.
159527 2003-03-17  Bruno Haible  <bruno@clisp.org>
159529         * m4/onceonly.m4: Require autoconf 2.54 or newer.
159530         (m4_quote): Remove macro.
159531         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
159533 2003-03-14  Jim Meyering  <jim@meyering.net>
159535         Merge changes from Coreutils.
159536         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
159537         to be const, in order to avoid warnings.
159538         (obstack_room): Likewise.
159539         (obstack_empty_p): Likewise.
159541 2003-03-14  Bruno Haible  <bruno@clisp.org>
159543         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
159544         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
159546 2003-03-13  Paul Eggert  <eggert@twinsun.com>
159548         Merge changes from Bison.
159549         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
159550         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
159551         when compiling Bison 1.875's `bitset bset = obstack_alloc
159552         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
159553         * lib/hash.c: Include <stdbool.h> unconditionally.
159555 2003-03-13  Paul Eggert  <eggert@twinsun.com>
159557         * m4/onceonly.m4 (m4_quote): New macro.
159558         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
159559         Quote AC_FOREACH variable-expansions properly.
159561 2003-03-13  Paul Eggert  <eggert@twinsun.com>
159563         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
159565 2003-03-09  Paul Eggert  <eggert@twinsun.com>
159567         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
159568         Reported by Bruce Becker; see:
159569         http://mail.gnu.org/r/bug-bison/2003-03/msg00017.html
159571 2003-03-03  Paul Eggert  <eggert@twinsun.com>
159572             Bruno Haible  <bruno@clisp.org>
159574         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
159575         Reported by John Hughes, see
159576         http://mail.gnu.org/r/bug-bison/2003-02/msg00030.html
159578 2003-02-20  Bruno Haible  <bruno@clisp.org>
159580         * MODULES.html.sh (func_all_modules): Add poll.
159582 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
159584         * modules/poll: New file.
159586 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
159588         * lib/poll_.h: New file.
159589         * lib/poll.c: New file.
159591 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
159593         * m4/poll.m4: New file.
159595 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
159597         * modules/mathl: New file.
159599 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
159601         * lib/mathl.h: New file.
159602         * lib/acosl.c: New file.
159603         * lib/asinl.c: New file.
159604         * lib/atanl.c: New file.
159605         * lib/ceill.c: New file.
159606         * lib/cosl.c: New file.
159607         * lib/expl.c: New file.
159608         * lib/floorl.c: New file.
159609         * lib/frexpl.c: New file.
159610         * lib/ldexpl.c: New file.
159611         * lib/logl.c: New file.
159612         * lib/sincosl.c: New file.
159613         * lib/sinl.c: New file.
159614         * lib/sqrtl.c: New file.
159615         * lib/tanl.c: New file.
159616         * lib/trigl.c: New file.
159617         * lib/trigl.h: New file.
159619 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
159621         * m4/mathl.m4: New file.
159623 2003-02-18  Bruno Haible  <bruno@clisp.org>
159625         * MODULES.html.sh (func_all_modules): Add mathl.
159627 2003-02-17  Bruno Haible  <bruno@clisp.org>
159629         * modules/mkdtemp: New module.
159630         * MODULES.html.sh (func_all_modules): Add it.
159632 2003-02-17  Bruno Haible  <bruno@clisp.org>
159634         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
159636 2003-02-17  Bruno Haible  <bruno@clisp.org>
159638         * lib/mkdtemp.h: New file, from GNU gettext.
159639         * lib/mkdtemp.c: New file, from GNU gettext.
159641 2003-02-02  Jim Meyering  <jim@meyering.net>
159643         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
159644         e.g. glibc-2.2.93.
159646 2003-01-31  Bruno Haible  <bruno@clisp.org>
159648         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
159649         'rpl_rename'.
159650         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
159651         'rpl_strnlen'.
159652         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
159653         'rpl_strtod'.
159654         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
159655         'rpl_utime'.
159657 2003-01-31  Bruno Haible  <bruno@clisp.org>
159659         * lib/rename.c: #undef rename before defining rpl_rename.
159660         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
159662 2003-01-30  Bruno Haible  <bruno@clisp.org>
159664         * modules/vasnprintf, modules/vasprintf: New modules.
159665         * MODULES.html.sh (func_all_modules): Add them.
159667 2003-01-30  Bruno Haible  <bruno@clisp.org>
159669         * m4/signed.m4: New file, from GNU gettext.
159670         * m4/longdouble.m4: New file, from GNU gettext.
159671         * m4/wchar_t.m4: New file, from GNU gettext.
159672         * m4/wint_t.m4: New file, from GNU gettext.
159673         * m4/vasnprintf.m4: New file.
159674         * m4/vasprintf.m4: New file.
159676 2003-01-30  Bruno Haible  <bruno@clisp.org>
159678         * lib/printf-args.h: New file, from GNU gettext.
159679         * lib/printf-args.c: New file, from GNU gettext.
159680         * lib/printf-parse.h: New file, from GNU gettext.
159681         * lib/printf-parse.c: New file, from GNU gettext.
159682         * lib/vasnprintf.h: New file, from GNU gettext.
159683         * lib/vasnprintf.c: New file, from GNU gettext.
159684         * lib/asnprintf.c: New file, from GNU gettext.
159685         * lib/vasprintf.h: New file, from GNU gettext with modifications.
159686         * lib/vasprintf.c: New file, from GNU gettext.
159687         * lib/asprintf.c: New file, from GNU gettext.
159689 2003-01-29  Bruno Haible  <bruno@clisp.org>
159691         * modules/stpncpy: New module.
159692         * MODULES.html.sh (func_all_modules): Add it.
159694 2003-01-29  Bruno Haible  <bruno@clisp.org>
159696         * m4/stpncpy.m4: New file.
159698 2003-01-29  Bruno Haible  <bruno@clisp.org>
159700         * lib/stpncpy.h: New file, from GNU gettext with modifications.
159701         * lib/stpncpy.c: New file, from GNU gettext with modifications.
159703 2003-01-28  Bruno Haible  <bruno@clisp.org>
159705         * modules/c-ctype: New module.
159706         * MODULES.html.sh (func_all_modules): Add it.
159708 2003-01-28  Bruno Haible  <bruno@clisp.org>
159710         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
159711         Paul Eggert.
159712         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
159713         Paul Eggert.
159715 2003-01-27  Bruno Haible  <bruno@clisp.org>
159717         * modules/xsetenv: New module.
159718         * MODULES.html.sh (func_all_modules): Add it.
159720 2003-01-27  Bruno Haible  <bruno@clisp.org>
159722         * lib/xsetenv.h: New file, from GNU gettext.
159723         * lib/xsetenv.c: New file, from GNU gettext.
159725 2003-01-23  Jim Meyering  <jim@meyering.net>
159727         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
159728         from working on systems without dirfd (at least Irix and OSF1/Tru64).
159730 2003-01-23  Bruno Haible  <bruno@clisp.org>
159732         * modules/minmax: New module.
159733         * MODULES.html.sh (func_all_modules): Add it.
159735 2003-01-23  Bruno Haible  <bruno@clisp.org>
159737         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
159738         Eggert.
159740 2003-01-22  Bruno Haible  <bruno@clisp.org>
159742         * modules/exit: New module.
159743         * MODULES.html.sh (func_all_modules): Add it.
159745 2003-01-22  Bruno Haible  <bruno@clisp.org>
159747         * lib/exit.h: New file, from GNU gettext.
159749 2003-01-19  Bruno Haible  <bruno@clisp.org>
159751         * gnulib-tool: Recognize option --extract-maintainer.
159752         (func_get_maintainer): New function.
159753         * modules/*: Add Maintainer entry.
159755 2003-01-16  Jim Meyering  <jim@meyering.net>
159757         * m4/regex.m4: The `regex' struct is both input and output.
159758         Initialize it before each use.  Patch by Tim Waugh.
159760 2003-01-16  Bruno Haible  <bruno@clisp.org>
159762         * MODULES.html.sh: Add a table of contents. Add the module name as
159763         leftmost column. Add hyperlinks.
159765 2003-01-15  Bruno Haible  <bruno@clisp.org>
159767         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
159769 2003-01-15  Bruno Haible  <bruno@clisp.org>
159771         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
159772         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
159773         suffix.
159775 2003-01-15  Bruno Haible  <bruno@clisp.org>
159777         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
159779 2003-01-15  Bruno Haible  <bruno@clisp.org>
159781         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
159782         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
159784 2003-01-14  Jim Meyering  <jim@meyering.net>
159786         * lib/same.c (same_name): Tweak a comment.
159788 2003-01-14  Bruno Haible  <bruno@clisp.org>
159790         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
159791         when a string comparison is sufficient.
159793 2003-01-14  Bruno Haible  <bruno@clisp.org>
159795         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
159796         'unsigned int'.
159798 2003-01-14  Bruno Haible  <bruno@clisp.org>
159800         * lib/hash-pjw.c: Add comment about low quality of this function.
159802 2003-01-13  Bruno Haible  <bruno@clisp.org>
159804         * modules/stpcpy: Distribute lib/stpcpy.h.
159805         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
159807 2003-01-13  Bruno Haible  <bruno@clisp.org>
159809         * modules/*: Add a description.
159810         * modules/strpbrk: Fix Makefile.am snippet.
159811         * modules/strtoimax: Fix dependencies.
159812         * modules/strtoumax: Likewise.
159814 2003-01-13  Bruno Haible  <bruno@clisp.org>
159816         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
159817         * modules/alloca (Makefile.am): All object files depend on alloca.h.
159818         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
159820 2003-01-13  Bruno Haible  <bruno@clisp.org>
159822         * gnulib-tool (func_create_testdir): Store config/* files in the main
159823         directory.
159824         * config.rpath: Move to ...
159825         * config/config.rpath: ... here.
159826         * modules/gettext: Contains config/config.rpath, not config.rpath.
159827         * modules/iconv: Likewise.
159829 2003-01-12  Paul Eggert  <eggert@twinsun.com>
159831         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
159832         to avoid collisions with libcurses and libreadline.
159834         * m4/getstr.m4: Remove.
159835         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
159837 2003-01-12  Paul Eggert  <eggert@twinsun.com>
159839         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
159840         to avoid collisions with libcurses and libreadline.
159842         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
159843         * lib/getstr.h, getstr.c: Remove.
159844         * lib/getline.c: Include "getline.h", to check interface.
159845         Move body of old getstr.c here: this defines MIN_CHUNK and
159846         declares getdelim2, which is renamed from getstr.
159847         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
159849         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
159850         All uses changed.
159851         * lib/linebuffer.h: Likewise.
159852         (readline): Remove backward-compatibility macro.
159854 2003-01-12  Paul Eggert  <eggert@twinsun.com>
159856         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
159857         to avoid collisions with libcurses and libreadline.
159858         * getstr: Remove.
159859         * MODULES.html.sh: Remove getstr.
159860         * modules/getline: Depend on unlocked-io, not getstr.
159862 2003-01-12  Jim Meyering  <jim@meyering.net>
159864         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
159866 2003-01-10  Bruno Haible  <bruno@clisp.org>
159868         * modules/alloca: Change Makefile.am requirements. Simplify Include
159869         requirements. Add lib/alloca_.h to file list.
159871 2003-01-10  Bruno Haible  <bruno@clisp.org>
159873         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
159875 2003-01-10  Bruno Haible  <bruno@clisp.org>
159877         * lib/alloca_.h: New file.
159878         * lib/getdate.y: Unconditionally include alloca.h.
159879         * lib/makepath.c: Likewise.
159880         * lib/setenv.c: Likewise.
159881         * lib/userspec.c: Likewise.
159883 2003-01-09  Karl Berry  <karl@gnu.org>
159885         * MODULES.html.sh: include `dirname $0` in PATH, to find
159886         gnulib-tool.
159888 2003-01-09  Bruno Haible  <bruno@clisp.org>
159890         * modules/stdbool: Change configure.ac, Makefile.am requirements.
159891         Simplify Include requirements. Add lib/stdbool.h.in to file list.
159893 2003-01-09  Bruno Haible  <bruno@clisp.org>
159895         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
159897 2003-01-09  Bruno Haible  <bruno@clisp.org>
159899         * lib/stdbool.h.in: New file.
159901 2003-01-09  Bruno Haible  <bruno@clisp.org>
159903         * gnulib-tool (func_all_modules): Ignore files ending in ~.
159904         * MODULES.html.sh: Likewise.
159906 2003-01-08  Jim Meyering  <jim@meyering.net>
159908         * lib/full-write.c: Undefine and define-away `const' after inclusion
159909         of errno.h, not before.  Suggestion from Bruno Haible.
159911 2003-01-08  Bruno Haible  <bruno@clisp.org>
159913         * modules/full-read: Depend on full-write.
159915 2003-01-08  Bruno Haible  <bruno@clisp.org>
159917         * lib/safe-read.c: Include specification header first, to ensure its
159918         selfcontainedness.
159919         * lib/full-write.c: Likewise.
159921 2003-01-07  Jim Meyering  <jim@meyering.net>
159923         * lib/full-write.c: Rework so that it may serve to define full_read,
159924         too.
159925         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
159927 2003-01-07  Bruno Haible  <bruno@clisp.org>
159929         * lib/strtoimax.c: Include <stdint.h> as an alternative to
159930         <inttypes.h>.
159931         * lib/xstrtol.h: Likewise.
159932         * lib/xstrtoimax.c: Likewise.
159933         * lib/xstrtoumax.c: Likewise.
159934         * lib/human.h: Likewise.
159936         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
159937         on systems that have <inttypes.h> but not <stdint.h>.
159939 2003-01-07  Bruno Haible  <bruno@clisp.org>
159941         * MODULES.html.sh: Add copyright notice.
159942         (missed_files): Omit CVS directory entries.
159943         (func_module): Make it work with sed-3.02.
159944         * MODULES.txt: Remove file.
159946 2003-01-06  Jim Meyering  <jim@meyering.net>
159948         * lib/version-etc.c: Update year in translatable copyright string.
159950 2003-01-03  Karl Berry  <karl@gnu.org>
159952         * config/config.{guess,sub}: update from prep.
159954 2003-01-02  Karl Berry  <karl@gnu.org>
159956         * doc/COPYING.DOC: belatedly updated to 1.2.
159958 2003-01-01  Karl Berry  <karl@gnu.org>
159960         * gnulib-tool (func_verify_module): report module name $module in
159961         error message, not $1.
159962         * gnulib-tool (create-testdir): don't complain if destdir couldn't
159963         be created, only if it doesn't exist.
159964         * gnulib-tool (last_checkin_date): don't expand the $Date here.
159966 2002-12-31  Paul Eggert  <eggert@twinsun.com>
159968         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
159970 2002-12-31  Paul Eggert  <eggert@twinsun.com>
159972         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
159973         memcmp if strcoll doesn't work.
159975 2002-12-31  Bruno Haible  <bruno@clisp.org>
159977         * lib/utime.c (utime_null): No need to call ftruncate if the file was
159978         nonempty.
159980 2002-12-31  Bruno Haible  <bruno@clisp.org>
159982         * lib/memcoll.c (STRCOLL): New macro.
159983         (memcoll): Use it.
159985 2002-12-31  Bruno Haible  <bruno@clisp.org>
159987         * lib/localcharset.h: New file.
159988         * lib/localcharset.c: Include it.
159989         * lib/unicodeio.c: Likewise.
159991 2002-12-31  Bruno Haible  <bruno@clisp.org>
159993         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
159994         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
159996 2002-12-31  Bruno Haible  <bruno@clisp.org>
159998         * lib/getline.h: Include <stddef.h>, for size_t.
160000         * lib/unicodeio.h: Include <stddef.h>, for size_t.
160001         * lib/unicodeio.c: Don't include <stddef.h>.
160003 2002-12-31  Bruno Haible  <bruno@clisp.org>
160005         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
160006         HAVE_TM_ZONE.
160008 2002-12-24  Karl Berry  <karl@gnu.org>
160010         * config/config.guess: update from prep.
160012 2002-12-24  Bruno Haible  <bruno@clisp.org>
160014         General infrasructure.
160015         * m4/README: Rewritten.
160016         * m4/onceonly.m4: New file.
160017         * m4/onceonly_2_57.m4: New file.
160019         Module atexit.
160020         * m4/atexit.m4: New file.
160022         Module strtod.
160023         * m4/strtod.m4: New file.
160025         Module strtol.
160026         * m4/strtol.m4: New file.
160028         Module strtoul.
160029         * m4/strtoul.m4: New file.
160031         Module memchr.
160032         * m4/memchr.m4: New file.
160034         Module memcmp.
160035         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
160036         (jm_FUNC_MEMCMP): Invoke it.
160038         Module memcpy.
160039         * m4/memcpy.m4: New file.
160041         Module memmove.
160042         * m4/memmove.m4: New file.
160044         Module memset.
160045         * m4/memset.m4: New file.
160047         Module strcspn.
160048         * m4/strcspn.m4: New file.
160050         Module strpbrk.
160051         * m4/strpbrk.m4: New file.
160053         Module strstr.
160054         * m4/strstr.m4: New file.
160056         Module strerror.
160057         * m4/strerror.m4: New file.
160059         Module mktime.
160060         * m4/mktime.m4: Renamed from jm-mktime.m4.
160061         (gl_PREREQ_MKTIME): New macro.
160062         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
160064         Module malloc.
160065         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
160066         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
160067         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
160069         Module realloc.
160070         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
160071         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
160072         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
160074         Module strftime.
160075         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
160076         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
160077         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
160078         gl_TM_GMTOFF.
160079         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
160081         Module xalloc.
160082         * m4/xalloc.m4: New file.
160084         Module alloca.
160085         * m4/alloca.m4: New file.
160087         Module putenv.
160088         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
160089         (jm_FUNC_PUTENV): Invoke it.
160091         Module setenv.
160092         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
160093         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
160094         when invoked twice.
160095         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
160096         gt_FUNC_SETENV.
160098         Module memrchr.
160099         * m4/memrchr.m4: New file.
160101         Module stpcpy.
160102         * m4/stpcpy.m4: New file.
160104         Module strcase.
160105         * m4/strcase.m4: New file.
160107         Module strdup.
160108         * m4/strdup.m4: New file.
160110         Module strnlen.
160111         * m4/strnlen.m4: New file.
160113         Module strndup.
160114         * m4/strndup.m4: New file.
160116         Module xstrtod.
160117         * m4/xstrtod.m4: New file.
160119         Module xstrtol.
160120         * m4/xstrtol.m4: New file.
160122         Module getdate.
160123         * m4/getdate.m4: New file.
160125         Module unlocked-io.
160126         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
160127         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
160128         * m4/jm-glibc-io.m4n: Remove file.
160130         Module long-options.
160131         * m4/long-options.m4: New file.
160133         Module md5.
160134         * m4/md5.m4: New file.
160136         Module sha.
160137         * m4/sha.m4: New file.
160139         Module getstr.
160140         * m4/getstr.m4: New file.
160142         Module getline.
160143         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
160144         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
160145         <sys/types.h>, for size_t. Use the function name gnu_getline, not
160146         simply getline. Infoke gl_PREREQ_GETLINE.
160148         Module obstack.
160149         * m4/obstack.m4: New file.
160151         Module hash.
160152         * m4/hash.m4: New file.
160154         Module readtokens.
160155         * m4/readtokens.m4: New file.
160157         Module strverscmp.
160158         * m4/strverscmp.m4: New file.
160160         Module stdbool.
160161         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
160162         OSF/1.
160164         Module strtoll.
160165         * m4/strtoll.m4: New file.
160167         Module strtoull.
160168         * m4/strtoull.m4: New file.
160170         Module strtoimax.
160171         * m4/strtoimax.m4: New file.
160173         Module strtoumax.
160174         * m4/strtoumax.m4: New file.
160176         Module xstrtoimax.
160177         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
160178         jm_AC_PREREQ_XSTRTOIMAX.
160179         Moved the strtol prerequisites to strtol.m4.
160180         Moved the strtoll prerequisites to strtoll.m4.
160181         Moved the strtoimax prerequisites to strtoimax.m4.
160183         Module xstrtoumax.
160184         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
160185         jm_AC_PREREQ_XSTRTOUMAX.
160186         Moved the strtoul prerequisites to strtoul.m4.
160187         Moved the strtoull prerequisites to strtoull.m4.
160188         Moved the strtoumax prerequisites to strtoumax.m4.
160190         Module chown.
160191         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
160192         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
160194         Module dup2.
160195         * m4/dup2.m4: New file.
160197         Module ftruncate.
160198         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
160199         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
160201         Module getgroups.
160202         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
160203         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
160205         Module gettimeofday.
160206         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
160207         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
160208         gl_PREREQ_GETTIMEOFDAY.
160210         Module mkdir.
160211         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
160212         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
160214         Module mkstemp.
160215         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
160216         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
160217         jm_AC_TYPE_UINTMAX_T.
160218         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
160220         Module stat.
160221         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
160222         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
160224         Module lstat.
160225         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
160226         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
160228         Module timespec.
160229         * m4/timespec.m4 (gl_TIMESPEC): New macro.
160230         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
160231         * m4/st_mtim.m4: Indentation.
160233         Module nanosleep.
160234         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
160235         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
160236         gl_PREREQ_NANOSLEEP.
160238         Module regex.
160239         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
160240         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
160241         (gl_REGEX): New macro.
160243         Module rename.
160244         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
160245         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
160247         Module rmdir.
160248         * m4/rmdir.m4: New file.
160250         Module utime.
160251         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
160252         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
160253         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
160255         Module dirname.
160256         * m4/dirname.m4: New file.
160258         Module getopt.
160259         * m4/getopt.m4: New file.
160261         Module unistd-safer.
160262         * m4/unistd-safer.m4: New file.
160264         Module fnmatch.
160265         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
160266         declaration.
160267         (gl_PREREQ_FNMATCH_EXTRA): New macro.
160268         (gl_FUNC_FNMATCH_POSIX): New macro.
160269         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
160270         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
160271         simply fnmatch.
160273         Module exclude.
160274         * m4/exclude.m4: New file.
160276         Module human.
160277         * m4/human.m4: New file.
160279         Module acl.
160280         * m4/acl.m4: Nop.
160282         Module backupfile.
160283         * m4/backupfile.m4: New file.
160284         * m4/d-ino.m4: Indentation.
160286         Module fsusage.
160287         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
160288         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
160289         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
160291         Module dirfd.
160292         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
160293         requirements.
160295         Module euidaccess.
160296         * m4/euidaccess.m4: New file.
160298         Module file-type.
160299         * m4/file-type.m4: New file.
160301         Module fileblocks.
160302         * m4/fileblocks.m4: New file.
160304         Module filemode.
160305         * m4/filemode.m4: New file.
160307         Module isdir.
160308         * m4/isdir.m4: New file.
160310         Module lchown.
160311         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
160312         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
160314         Module makepath.
160315         * m4/makepath.m4: New file.
160317         Module modechange.
160318         * m4/modechange.m4: New file.
160320         Module mountlist.
160321         * m4/mountlist.m4: New file.
160322         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
160323         Indentation.
160325         Module path-concat.
160326         * m4/path-concat.m4: New file.
160328         Module pathmax.
160329         * m4/pathmax.m4: New file.
160331         Module same.
160332         * m4/same.m4: New file.
160334         Module save-cwd.
160335         * m4/save-cwd.m4: New file.
160337         Module savedir.
160338         * m4/savedir.m4: New file.
160340         Module xgetcwd.
160341         * m4/xgetcwd.m4: New file.
160342         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
160344         Module xreadlink.
160345         * m4/xreadlink.m4: New file.
160347         Module safe-read.
160348         * m4/safe-read.m4: New file.
160350         Module safe-write.
160351         * m4/safe-write.m4: New file.
160353         Module closeout.
160354         * m4/closeout.m4: New file.
160356         Module stdio-safer.
160357         * m4/stdio-safer.m4: New file.
160359         Module getpass.
160360         * m4/getpass.m4: New file.
160362         Module getugroups.
160363         * m4/getugroups.m4: New file.
160365         Module group-member.
160366         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
160367         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
160369         Module idcache.
160370         * m4/idcache.m4: New file.
160372         Module userspec.
160373         * m4/userspec.m4: New file.
160375         Module gettime.
160376         * m4/clock_time.m4: New file.
160377         * m4/gettime.m4: New file.
160379         Module settime.
160380         * m4/settime.m4: New file.
160382         Module posixtm.
160383         * m4/posixtm.m4: New file.
160385         Module gethostname.
160386         * m4/gethostname.m4: New file.
160388         Module canon-host.
160389         * m4/canon-host.m4: New file.
160391         Module gettext.
160392         * m4/codeset.m4: New file, from gettext-0.11.5.
160393         * m4/gettext.m4: New file, from gettext-0.11.5.
160394         * m4/glibc21.m4: New file, from gettext-0.11.5.
160395         * m4/iconv.m4: New file, from gettext-0.11.5.
160396         * m4/intdiv0.m4: New file, from gettext-0.11.5.
160397         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
160398         * m4/inttypes.m4: New file, from gettext-0.11.5.
160399         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
160400         * m4/isc-posix.m4: New file, from gettext-0.11.5.
160401         * m4/lcmessage.m4: New file, from gettext-0.11.5.
160402         * m4/lib-ld.m4: New file, from gettext-0.11.5.
160403         * m4/lib-link.m4: New file, from gettext-0.11.5.
160404         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
160405         * m4/progtest.m4: New file, from gettext-0.11.5.
160406         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
160407         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
160408         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
160410         Module localcharset.
160411         * m4/localcharset.m4: New file.
160413         Module hard-locale.
160414         * m4/hard-locale.m4: New file.
160416         Module mbswidth.
160417         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
160418         onceonly macros.
160419         * m4/mbrtowc.m4: Add comment.
160421         Module memcasecmp.
160422         * m4/memcasecmp.m4: New file.
160424         Module memcoll.
160425         * m4/memcoll.m4: New file.
160427         Module unicodeio.
160428         * m4/unicodeio.m4: New file.
160430         Module rpmatch.
160431         * m4/rpmatch.m4: New file.
160433         Module yesno.
160434         * m4/yesno.m4: New file.
160436         Module exitfail.
160437         * m4/exitfail.m4: New file.
160439         Module c-stack.
160440         * m4/c-stack.m4 (gl_C_STACK): New macro.
160441         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
160443         Module error.
160444         * m4/error.m4 (gl_ERROR): New macro.
160445         (jm_PREREQ_ERROR): Use onceonly macros.
160447         Module fatal.
160448         * m4/fatal.m4: New file.
160450         Module getloadavg.
160451         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
160452         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
160454         Module getpagesize.
160455         * m4/getpagesize.m4: New file.
160457         Module getusershell.
160458         * m4/getusershell.m4: New file.
160460         Module physmem.
160461         * m4/physmem.m4: New file.
160463         Module posixver.
160464         * m4/posixver.m4: New file.
160466         Module quotearg.
160467         * m4/quotearg.m4: New file.
160469         Module quote.
160470         * m4/quote.m4: New file.
160472         Module readutmp.
160473         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
160475         Module sig2str.
160476         * m4/sig2str.m4: New file.
160478         Other.
160479         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
160480         ulonglong.m4.
160481         * m4/intmax_t.m4: New file.
160482         * m4/d-type.m4: Indentation.
160483         * m4/jm-macros.m4: Update.
160484         * m4/prereq.m4 (jm_PREREQ): Update.
160485         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
160486         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
160487         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
160488         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
160489         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
160490         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
160491         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
160492         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
160493         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
160494         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
160495         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
160496         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
160497         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
160498         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
160499         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
160500         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
160501         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
160502         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
160503         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
160505 2002-12-24  Bruno Haible  <bruno@clisp.org>
160507         * MODULES.txt: Update according to m4/ changes.
160509         Module gettext.
160510         * config.rpath: New file, from gettext-0.11.5.
160512         * modules/*: New module descriptions.
160513         * gnulib-tool: New file.
160514         * MODULES.html.sh: New file.
160516 2002-12-21  Karl Berry  <karl@gnu.org>
160518         * doc/fdl.texi: update to version 1.2.
160520 2002-12-19  Karl Berry  <karl@gnu.org>
160522         * config/config.guess: update from prep.
160524 2002-12-18  Bruno Haible  <bruno@clisp.org>
160526         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
160527         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
160529 2002-12-17  Bruno Haible  <bruno@clisp.org>
160531         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
160532         stdlib.h, string.h.
160534 2002-12-17  Bruno Haible  <bruno@clisp.org>
160536         * lib/canon-host.c (strdup): Remove unused declaration.
160538         * lib/fsusage.c: Include full_read.h.
160539         (get_fs_usage): Use full_read instead of safe_read.
160541         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
160543 2002-12-12  Karl Berry  <karl@gnu.org>
160545         * config/config.guess: update from prep.
160547 2002-12-11  Bruno Haible  <bruno@clisp.org>
160549         * m4/setenv.m4: New file, from gettext-0.11.5.
160551 2002-12-11  Bruno Haible  <bruno@clisp.org>
160553         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
160554         not unsetenv().
160555         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
160556         modifications:
160558         2002-12-11  Bruno Haible  <bruno@clisp.org>
160560                 * setenv.c (alloca): Fall back to malloc.
160561                 (freea): New macro.
160562                 (setenv): Use freea() to free memory allocated with alloca().
160564         2002-11-13  Bruno Haible  <bruno@clisp.org>
160566                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
160567                 function declarations.
160568                 * unsetenv.c (unsetenv): Likewise.
160570         2002-03-04  Bruno Haible  <bruno@clisp.org>
160572                 Portability to AIX 4.3.3.
160573                 * unsetenv.c: New file, extracted from setenv.c.
160574                 * setenv.c: Move the unsetenv() function to unsetenv.c.
160576         2001-12-20  Bruno Haible  <bruno@clisp.org>
160578                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
160579                 use malloc instead. For SunOS 4.
160581         2001-12-11  Bruno Haible  <bruno@clisp.org>
160583                 * setenv.c: Declare alloca.
160584                 (compar_fn_t): New typedef.
160585                 (KNOWN_VALUE, STORE_VALUE): Use it.
160587         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
160588         setenv.h.
160590 2002-12-10  Paul Eggert  <eggert@twinsun.com>
160592         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
160593         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
160594         Choose values that are less likely to collide with system fnmatch
160595         options.
160596         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
160597         defined (e.g., a pure POSIX system).
160598         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
160599         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
160601 2002-12-06  Paul Eggert  <eggert@twinsun.com>
160603         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
160604         a pain in practice to deal with generated m4 files.  This change
160605         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
160607         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
160608         and jm-glibc-io.m4, as they are no longer a special case.
160609         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
160610         kludge and the auto-generation stuff.  Check only whether the
160611         functions are declared, not whether they exist, since older hosts
160612         that don't declare the functions can't use the optimization anyway.
160614 2002-12-06  Jim Meyering  <jim@meyering.net>
160616         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
160618         Merge in changes from libc's misc/error.c, in preparation
160619         for the merge of gnulib's changes back into libc.
160621         * lib/error.c (_): Define only if not already defined.
160622         Move definition to follow all #include directives.
160623         Include unlocked-io.h only if !_LIBC.
160624         [_LIBC]: Include <libio/libioP.h>.
160625         [USE_IN_LIBIO]: Include <libio/iolibio.h>
160626         (fflush): Tweak definition to use INTUSE.
160627         (putc): Define.
160629 2002-12-05  Paul Eggert  <eggert@twinsun.com>
160631         * lib/alloca.c [defined emacs]: Include "lisp.h".
160632         (xalloc_die) [defined emacs]: New macro.
160633         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
160634         [! defined emacs]: Include <xalloc.h>.
160635         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
160636         (pointer): Typedef to POINTER_TYPE *.
160637         (malloc): Remove decl; we now always use xmalloc.
160638         (alloca): Use old-style definition, since Emacs needs this.
160639         Check for arithmetic overflow when computing combined size.
160641 2002-12-04  Paul Eggert  <eggert@twinsun.com>
160643         Do not generate unlocked-io.h automatically, since it's easier to
160644         maintain it by hand.
160646         * lib/unlocked-io.h: New file, from GNU diffutils,
160647         but with proper copyright notice and attribution.
160648         * lib/gen-uio: Remove.
160649         * lib/Makefile.am: Add copyright notice.
160650         (libfetish_a_SOURCES): Add unlocked-io.h.
160651         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
160652         (DISTCLEANFILES, io_functions): Remove macros.
160653         (EXTRA_DIST): Remove gen_uio.
160654         (unlocked-io.h): Remove rule.
160656 2002-12-04  Jim Meyering  <jim@meyering.net>
160658         Reflect the fact that stat.c and lstat.c are no longer generated.
160659         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
160660         (DISTCLEANFILES): Likewise.
160661         (EXTRA_DIST): Likewise.
160662         (all_local): Don't depend on stat.c or lstat.c.
160663         (stat.c, lstat.c): Remove rules.
160664         (EXTRA_DIST): Remove xstat.in.
160666         * lib/xstat.in: Remove file.  Contents moved into stat.c.
160667         * lib/stat.c: New file.  Contents mostly from xstat.in.
160668         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
160669         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
160671         * lib/safe-read.c: Rework so that it may serve to define safe_write,
160672         too.
160673         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
160675 2002-12-03  Jim Meyering  <jim@meyering.net>
160677         * lib/safe-read.c, safe-write.c: Change variable names and comments,
160678         but not semantics, to minimize the differences between these two files.
160679         (safe_read): Change comment to mention SAFE_READ_ERROR.
160681         * lib/safe-read.c (IS_EINTR): Define.
160682         (safe_read): Use IS_EINTR in place of in-function cpp directives.
160684 2002-12-02  Jim Meyering  <jim@meyering.net>
160686         * lib/safe-read.c (EINTR): Define.
160687         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
160688         (INT_MAX): Provide fallback.
160689         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
160691         * lib/safe-read.h (SAFE_READ_ERROR): Define.
160693 2002-12-02  Bruno Haible  <bruno@clisp.org>
160695         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
160696         Define, taken from safe-read.c.
160697         (INT_MAX): Provide fallback.
160698         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
160699         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
160701         * lib/safe-read.c (EINTR): Remove definition.
160702         (safe_read): Don't use EINTR if it is absent.
160704 2002-12-01  Jim Meyering  <jim@meyering.net>
160706         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
160707         zero.
160708         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
160710 2002-11-27  Paul Eggert  <eggert@twinsun.com>
160712         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
160713         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
160714         with `if (! (value < limit)) abort ();', for readability.
160716 2002-11-26  Karl Berry  <karl@gnu.org>
160718         * lib/strdup.c: copy from libc again, with jim's ok.
160719         * lib/.cppi-disable: re-add strdup.c
160721 2002-11-25  Karl Berry  <karl@gnu.org>
160723         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
160724         instead of "strtol.c".
160726 2002-11-25  Karl Berry  <karl@gnu.org>
160728         * config/install-sh: update from automake for variable quoting, $0 in
160729         error msgs, etc.
160731         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
160732         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
160733         entry.
160735 2002-11-25  Jim Meyering  <jim@meyering.net>
160737         * lib/mktime.c: Sync from libc, now that it has the latest fix.
160739 2002-11-24  Karl Berry  <karl@gnu.org>
160741         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
160742         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
160744 2002-11-24  Jim Meyering  <jim@meyering.net>
160746         Update from coreutils:
160748         * lib/mktime.c: Merge in changes from libc.
160750         Avoid a link-time failure on some Linux systems.
160751         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
160752         (otherwise).
160753         (__mon_yday): Declare with the STATIC attribute.
160754         (__mktime_internal): Likewise.
160755         Based on a report from Greg Schafer.
160757 2002-11-23  Jim Meyering  <jim@meyering.net>
160759         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
160760         Use `unsigned', not `int', as type of index.
160762         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
160764         * lib/fsusage.c: Remove unneeded parentheses around operands of
160765         `defined'.
160767 2002-11-22  Paul Eggert  <eggert@twinsun.com>
160769         * lib/quotearg.h: Allow multiple inclusion by surrounding with
160770         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
160771         so that we can be included first.
160772         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
160773         * lib/quotearg.c: Include quotearg.h immediately after config.h.
160774         No need to include stddef.h or sys/types.h any more.
160775         Surround local include files with "", not "<>".
160776         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
160777         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
160778         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
160779         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
160780         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
160781         (ISPRINT): Remove; no longer needed now that we assume C89.
160783         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
160784         Preserve errno.
160786         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
160787         quotearg_char): Use SIZE_MAX rather than
160788         (size_t) -1 when we are talking about "infinity".
160790         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
160792 2002-11-22  Paul Eggert  <eggert@twinsun.com>
160794         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
160795         hint that one should use `if (! x) abort ();' rather than `assert
160796         (x);', and anyway it's one less thing to worry about configuring.
160797         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
160798         hash_rehash, hash_insert): Use abort rather than assert.
160800 2002-11-22  Bruno Haible  <bruno@clisp.org>
160802         * lib/safe-read.h: Assume C89. Add comments.
160803         (safe_read): Change return type to size_t.
160804         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
160805         byte counts > SSIZE_MAX correctly.
160806         * lib/safe-write.h: New file.
160807         * lib/safe-write.c: New file.
160808         * lib/full-read.h: New file.
160809         * lib/full-read.c: New file.
160810         * lib/full-write.h: Assume C89. Add comments.
160811         * lib/full-write.c: Include safe-write.h.
160812         (full_write): Rewritten to use safe_write.
160813         Suggested by Jim Meyering and Paul Eggert.
160815 2002-11-21  Jim Meyering  <jim@meyering.net>
160817         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
160819         Merge in changes from the coreutils.
160821         2002-09-25  Paul Eggert  <eggert@twinsun.com>
160822         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
160823         <stdint.h>.
160824         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
160825         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
160826         int.  Work more efficiently if X is the same width as uintmax_t.
160827         Do not compare X to -1, to avoid bogus compiler warning.
160828         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
160829         Don't assume that f_frsize and f_bsize are the same type.
160831         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
160832         warning on FreeBSD.
160834         * lib/makepath.c (make_path): Restore umask *before* creating the final
160835         component.
160836         (make_path): Minor reformatting.
160838         * lib/xmalloc.c: Adjust to work with new autoconf macros,
160839         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
160840         HAVE_MALLOC/HAVE_REALLOC.
160842         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
160843         dummy ones.  At least on GNU/Linux systems, `auto' means something
160844         else.
160845         From Michael Stone.
160847 2002-11-21  Bruno Haible  <bruno@clisp.org>
160849         Remove case insensitive option matching.
160850         * lib/argmatch.h (argcasematch): Remove declaration.
160851         (ARGCASEMATCH): Remove macro.
160852         (__xargmatch_internal): Remove case_sensitive argument.
160853         (XARGMATCH): Update.
160854         (XARGCASEMATCH): Remove macro.
160855         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
160856         case_sensitive argument.
160857         (argcasematch): Remove function.
160858         (__xargmatch_internal): Remove case_sensitive argument.
160859         (main): Use XARGMATCH instead of XARGCASEMATCH.
160861         * lib/xmalloc.c: Change compile-time error message. Add comment about
160862         required autoconf version.
160864 2002-11-20  Paul Eggert  <eggert@twinsun.com>
160866         Merge argmatch cleanups from Bison.  Assume C89.
160868         * lib/argmatch.c: Include config.h here, not in argmatch.h.
160869         Include stdlib.h, for EXIT_FAILURE.
160870         Always include <string.h>, since we assume C89.
160871         (EXIT_FAILURE): Remove pre-C89 bug workaround.
160872         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
160873         Include <stddef.h> instead, since it's all we need for size_t.
160874         (PARAMS): Remove.  All uses removed.
160875         (ARRAY_CARDINALITY): Do not bother to #undef.
160876         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
160877         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
160878         Remove unnecessary parentheses.
160879         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
160880         Insert necessary parentheses.
160881         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
160882         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
160884 2002-11-19  Bruno Haible  <bruno@clisp.org>
160886         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
160887         * lib/mbswidth.h: Include <stddef.h>, for size_t.
160889         * lib/mbswidth.h (PARAMS): Remove macro.
160890         (mbswidth, mbsnwidth): Use ANSI C function declarations.
160891         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
160893         * lib/gcd.h (PARAMS): Remove macro.
160894         (gcd): Use ANSI C function declarations.
160895         * lib/gcd.c (gcd): Likewise.
160897 2002-11-15  Bruno Haible  <bruno@clisp.org>
160899         * lib/strcspn.c: Include <stddef.h>.
160900         (strcspn): Use ANSI C function declaration. Change return type to
160901         size_t. Use NULL.
160902         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
160903         (strpbrk): Use NULL.
160904         * lib/strpbrk.h (PARAMS): Remove macro.
160905         (strpbrk): Use ANSI C function declaration.
160906         * lib/strstr.c: Don't include <sys/types.h>.
160907         * lib/strstr.h (PARAMS): Remove macro.
160908         (strstr): Use ANSI C function declarations.
160910 2002-11-14  Karl Berry  <karl@gnu.org>
160912         * config/mkinstalldirs: `do' on separate line, instead of
160913         `for var; do'.
160915 2002-11-06  Bruno Haible  <bruno@clisp.org>
160917         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
160918         * lib/gcd.c (gcd): Likewise.
160920 2002-11-05  Bruno Haible  <bruno@clisp.org>
160922         * lib/gcd.h: New file, from gettext-0.11.5.
160923         * lib/gcd.c: New file, from gettext-0.11.5.
160925 2002-11-05  Bruno Haible  <bruno@clisp.org>
160927         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
160928         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
160929         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
160930         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
160932         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
160933         <libintl.h>.
160934         * lib/makepath.c: Include gettext.h instead of <locale.h> and
160935         <libintl.h>.
160937         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
160938         * lib/human.c: Include gettext.h instead of <libintl.h>.
160939         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
160940         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
160941         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
160942         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
160943         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
160944         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
160945         (textdomain): Remove definition.
160946         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
160948         * lib/long-options.c: Remove include of <libintl.h> and definition of
160949         _.
160950         * lib/same.c: Remove include of <libintl.h> and definition of _.
160952 2002-11-04  Owen Taylor  <otaylor@redhat.com>
160954         * lib/config.charset: A few additions for Solaris.
160956 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
160958         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
160959         * lib/localcharset.c (locale_charset): Declare as extern "C".
160961 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
160963         * lib/config.charset: msdos in uk_UA uses CP1125.
160965 2002-11-04  Bruno Haible  <bruno@clisp.org>
160967         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
160968         * lib/strcase.h: New file, from GNU gettext-0.11.5.
160969         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
160970         * lib/strstr.h: New file, from GNU gettext-0.11.5.
160971         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
160973 2002-11-04  Bruno Haible  <bruno@clisp.org>
160975         * lib/localcharset.c (locale_charset): Don't return an empty string.
160977 2002-11-04  Bruno Haible  <bruno@clisp.org>
160979         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
160980         aliases.
160982 2002-11-04  Bruno Haible  <bruno@clisp.org>
160984         * lib/config.charset: Update for newest glibc. Add canonical names
160985         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
160987 2002-11-04  Bruno Haible  <bruno@clisp.org>
160989         * lib/config.charset: Add support for NetBSD.
160991 2002-11-04  Bruno Haible  <bruno@clisp.org>
160993         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
160995 2002-11-01  Bruno Haible  <bruno@clisp.org>
160997         * configure.in: Add AC_CONFIG_AUX_DIR call.
160998         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
160999         test/Makefile.
161000         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
161002 2002-09-28  Karl Berry  <karl@gnu.org>
161004         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
161005         installed automake until the next release, since changes have been
161006         made.
161008 2002-09-25  Karl Berry  <karl@gnu.org>
161010         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
161011         * lib/getopt*: copy from libc/posix.
161012         * lib/gettext.h: copy from gettext.
161013         * lib/.cppi-disable: add strdup.c, gettext.h.
161015 2002-09-25  Karl Berry  <karl@gnu.org>
161017         * config/srclist.txt: enable gettext.h check.
161018         * config/config.{guess,sub}: update from prep.
161019         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
161020                 from automake 1.6.3.
161021         See srclist*.
161023 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
161025         * regex.c (PATFETCH): Remove the translating fetch.
161026         (PATFETCH_RAW): Rename to PATFETCH.
161027         (set_image_of_range): New fun.
161028         (SET_RANGE_TABLE_WORK_AREA): Use it.
161029         (regex_compile): Don't translate the pattern chars so eagerly.
161030         Only do it when inserting an `exactn' bytecode or when handling
161031         a char-range.
161032         (mutually_exclusive_p): Avoid empty statement.
161034 2002-07-06  Jim Meyering  <meyering@lucent.com>
161036         * m4/README: Don't mention Makefile.am.in.
161037         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
161039 2002-07-01  Jim Meyering  <meyering@lucent.com>
161041         * lib/c-stack.c: Include sys/time.h.
161042         From Volker Borchert.
161044 2002-06-26  Paul Eggert  <eggert@twinsun.com>
161046         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
161048 2002-06-26  Paul Eggert  <eggert@twinsun.com>
161050         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
161051         New macro.  Use it uniformly instead of
161052         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
161053         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
161054         reported by Vin Shelton.
161056 2002-06-22  Paul Eggert  <eggert@twinsun.com>
161058         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
161059         Do not assume SA_SIGINFO behavior.
161060         Bug reported by Jim Meyering on NetBSD 1.5.2.
161062 2002-06-22  Jim Meyering  <meyering@lucent.com>
161064         * m4/c-stack.m4: New file, from diffutils-2.8.2.
161065         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
161067         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
161068         now that configure.ac uses AC_GNU_SOURCE.
161069         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
161070         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
161072         Update to latest tools.  Suggestions from Paul Eggert.
161073         * m4/stdbool.m4: New file, from diffutils-2.8.2.
161074         * m4/gnu-source.m4: Update from diffutils-2.8.2.
161075         * m4/fnmatch.m4: Likewise.
161076         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
161077         to AC_HEADER_STDBOOL
161079 2002-06-22  Jim Meyering  <meyering@lucent.com>
161081         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
161082         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
161084 2002-06-22  Jim Meyering  <meyering@lucent.com>
161086         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
161088         * lib/exitfail.c, exitfail.h: Likewise.
161089         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
161091         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
161092         of fnmatch.h.
161093         (EXTRA_DIST): Add fnmatch_loop.c.
161094         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
161096         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
161097         * lib/fnmatch.c: Update from diffutils-2.8.2.
161098         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
161099         * lib/fnmatch.h: Remove file.
161101 2002-06-21  Jim Meyering  <meyering@lucent.com>
161103         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
161104         * m4/mbrtowc.m4: Likewise.
161106         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
161107         * m4/mbswidth.m4: Reflect name change:
161108         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
161109         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
161111         * m4/lib-link.m4: Update from gettext-0.11.2.
161112         * m4/gettext.m4: Likewise.
161114         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
161115         From Alfred M. Szmidt.
161117 2002-06-18  Paul Eggert  <eggert@twinsun.com>
161119         * lib/file-type.h: Report an error if neither S_ISREG nor
161120         S_IFREG is defined, instead of using a test specific to glibc
161121         2.2.  This should be safe, since POSIX requires S_ISREG and
161122         Unix Version 7 had S_IFREG.  We don't need to check for
161123         <sys/types.h> since we don't use any symbols that it defines.
161125 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
161127         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
161128         $@-t, so that each temporary file name is unique and valid in the first
161129         8 characters, for operation under DOS.
161131 2002-06-15  Paul Eggert  <eggert@twinsun.com>
161133         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
161135 2002-06-15  Jim Meyering  <meyering@lucent.com>
161137         Work even with DJGPP 2.03, which lacks support for symlinks.
161138         From Richard Dawe.
161139         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
161140         is defined.
161141         * lib/lchown.c (S_ISLNK): Likewise.
161143 2002-06-15  Jim Meyering  <meyering@lucent.com>
161145         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
161146         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
161147         have been included before this file.
161149 2002-06-14  Jim Meyering  <meyering@lucent.com>
161151         * lib/file-type.h: Use the version from diffutils-2.8.2.
161152         * lib/file-type.c: Likewise.
161154 2002-06-07  Jim Meyering  <meyering@lucent.com>
161156         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
161157         They're needed at least for NetBSD 1.5.2.
161158         ($statxfs_includes): Include those same headers.
161159         ($statxfs_includes): Include sys/vfs.h if available.
161160         ($statxfs_includes): Likewise for sys/statvfs.h.
161161         Check for the following members in both structs statfs and statvfs:
161162         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
161164 2002-06-01  Jim Meyering  <meyering@lucent.com>
161166         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
161167         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
161169 2002-05-28  Jim Meyering  <meyering@lucent.com>
161171         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
161172         Reported by Volker Borchert.
161174 2002-05-27  Jim Meyering  <meyering@lucent.com>
161176         Fix a problem seen only on nonconforming systems whereby ls.c's
161177         use of localtime, and then of gettimeofday would cause trouble:
161178         the localtime call used to initialize rpl_gettimeofday's save
161179         mechanism would clobber ls's current local time information so
161180         that in any long listing the first file would always be listed
161181         with date 1970-01-01.  Analysis by Volker Borchert.
161183         * lib/gettimeofday.c (localtime): Undefine.
161184         (rpl_localtime): New function.
161186 2002-05-27  Jim Meyering  <meyering@lucent.com>
161188         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
161189         localtime.
161191         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
161192         use the replacement function; it wouldn't resolve at link time.
161193         Reported by Volker Borchert.
161195 2002-05-22  Jim Meyering  <meyering@lucent.com>
161197         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
161198         file-type.h.
161199         * lib/file-type.h: New file.
161200         * lib/file-type.c (file_type): New file/function.  Extracted from
161201         diffutils.
161203 2002-04-30  Jim Meyering  <meyering@lucent.com>
161205         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
161207 2002-04-29  Paul Eggert  <eggert@twinsun.com>
161209         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
161211 2002-04-29  Paul Eggert  <eggert@twinsun.com>
161213         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
161214         Do not check for alloca.h (no longer used) or stdbool.h (was never
161215         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
161217 2002-04-29  Paul Eggert  <eggert@twinsun.com>
161219         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
161221 2002-04-29  Jim Meyering  <meyering@lucent.com>
161223         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
161224         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
161225         Use AC_FUNC_STRNLEN here instead.
161227         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
161228         With autoconf-2.53a, it's part of AC_PROG_CC.
161230 2002-04-28  Paul Eggert  <eggert@twinsun.com>
161232         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
161233         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
161235 2002-04-28  Paul Eggert  <eggert@twinsun.com>
161237         * lib/sig2str.h, lib/sig2str.c: New files.
161238         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
161240 2002-04-28  Paul Eggert  <eggert@twinsun.com>
161242         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
161243         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
161244         of 127, since 64 is the largest conceivable number for ancient
161245         nonstandard hosts.
161246         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
161248 2002-04-28  Jim Meyering  <meyering@lucent.com>
161250         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
161252 2002-04-24  Jim Meyering  <meyering@lucent.com>
161254         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
161255         (jm_PREREQ): Use it.
161257         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
161258         mach/mach.h fcntl.h.
161259         Check for this function: setlocale.
161261 2002-04-24  Jim Meyering  <meyering@lucent.com>
161263         * lib/gettext.h: New file, from Gettext.
161264         * lib/Makefile.am (INCLUDES): Remove -I../intl.
161265         (libfetish_a_SOURCES): Add gettext.h.
161267 2002-04-16  Jim Meyering  <meyering@lucent.com>
161269         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
161270         ut_pid, ut_id, ut_exit.
161272 2002-04-16  Jim Meyering  <meyering@lucent.com>
161274         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
161275         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
161276         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
161278 2002-04-12  Jim Meyering  <meyering@lucent.com>
161280         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
161281         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
161282         existence of the getmntinfo function.  Needed for Darwin 5.3.
161284         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
161285         This is necessary at least on Darwin 5.3.
161287         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
161288         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
161289         strnlen.o in the library, and that makes some versions of ranlib
161290         object.
161292 2002-04-12  Jim Meyering  <meyering@lucent.com>
161294         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
161296 2002-04-09  Jim Meyering  <meyering@lucent.com>
161298         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
161299         to be more precise.  Rather than saying we're checking whether the
161300         function `works', say what we're testing.
161301         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
161302         Reported by Bruno Haible.
161304 2002-03-10  Jim Meyering  <meyering@lucent.com>
161306         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
161307         Suggestion from Santiago Vila.
161309 2002-03-08  Jim Meyering  <meyering@lucent.com>
161311         * lib/rename.c: Mention that this wrapper is needed also on
161312         mips-dec-ultrix4.4 systems.
161314 2002-03-02  Jim Meyering  <meyering@lucent.com>
161316         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
161317         not HAVE_CLOCK_SETTIME.
161319 2002-02-27  Paul Eggert  <eggert@twinsun.com>
161321         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
161322         Check for clock_settime.
161324 2002-02-27  Paul Eggert  <eggert@twinsun.com>
161326         * lib/nanosleep.h: Rename to....
161327         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
161329         * lib/gettime.c: New file.
161330         * lib/settime.c: New file.
161331         * lib/stime.c: Remove.
161333         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
161334         timespec.h.  Remove nanosleep.h.
161336 2002-02-25  Paul Eggert  <eggert@twinsun.com>
161338         * m4/acl.m4: New file.
161339         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
161340         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
161342 2002-02-25  Paul Eggert  <eggert@twinsun.com>
161344         * lib/acl.c, lib/acl.h: New files.
161345         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
161347 2002-02-24  Jim Meyering  <meyering@lucent.com>
161349         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
161350         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
161351         cause trouble.  Reported by Nelson Beebe.
161353 2002-02-23  Paul Eggert  <eggert@twinsun.com>
161355         * lib/path-concat.c (xpath_concat): Reorder code to pacify
161356         compilers that don't know that xalloc_die never returns.
161358 2002-02-20  Jim Meyering  <meyering@lucent.com>
161360         * lib/getdate.c: Regenerate using bison-1.33.
161362 2002-02-17  Jim Meyering  <meyering@lucent.com>
161364         * config/config.guess (main): Don't use `head -1'; it's no longer
161365         portable. Use `sed 1q' instead.
161367 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
161369         * m4/codeset.m4: Upgrade to gettext-0.11.
161370         * m4/gettext.m4: Upgrade to gettext-0.11.
161371         * m4/glibc21.m4: Upgrade to gettext-0.11.
161372         * m4/iconv.m4: Upgrade to gettext-0.11.
161373         * m4/isc-posix.m4: Upgrade to gettext-0.11.
161374         * m4/lcmessage.m4: Upgrade to gettext-0.11.
161375         * m4/lib-ld.m4: New file, from gettext-0.11.
161376         * m4/lib-link.m4: New file, from gettext-0.11.
161377         * m4/lib-prefix.m4: New file, from gettext-0.11.
161378         * m4/progtest.m4: Upgrade to gettext-0.11.
161380 2002-02-15  Paul Eggert  <eggert@twinsun.com>
161382         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
161383         (jm_PREREQ): Use it.
161385 2002-02-15  Paul Eggert  <eggert@twinsun.com>
161387         * lib/posixver.c, lib/posixver.h: New files.
161388         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
161390 2002-02-02  Paul Eggert  <eggert@twinsun.com>
161391             Bruno Haible  <bruno@clisp.org>
161393         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
161394         (fwrite_success_callback): New declaration.
161395         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
161396         print_unicode_char. Call failure callback instead of error.
161397         (fwrite_success_callback): New function.
161398         (exit_failure_callback): New function.
161399         (fallback_failure_callback): New function.
161400         (print_unicode_char): Call unicode_to_mb.
161402 2002-01-26  Jim Meyering  <meyering@lucent.com>
161404         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
161405         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
161407 2002-01-26  Jim Meyering  <meyering@lucent.com>
161409         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
161411 2002-01-22  Paul Eggert  <eggert@twinsun.com>
161413         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
161415 2002-01-22  Jim Meyering  <meyering@lucent.com>
161417         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
161418         Otherwise, some versions of automake would omit the rule that makes
161419         Makefile from Makefile.in.
161421 2002-01-21  Paul Eggert  <eggert@twinsun.com>
161423         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
161424         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
161425         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
161426         (memcoll): Set errno to zero if there is no error.
161428         * lib/quotearg.c (quotearg_buffer_restyled):
161429         Fix bug with quoting buffers containing NUL when backslashing escapes.
161430         This bug was exposed by the other changes in this patch.
161431         (quotearg_n_options): New arg ARGSIZE.
161432         All callers changed.
161433         (quoting_options_from_style): New function.
161434         (quotearg_n_style): Use it.
161435         (quotearg_n_style_mem): New function.
161437         * lib/quotearg.h (quotearg_n_style_mem): New function.
161439 2002-01-19  Jim Meyering  <meyering@lucent.com>
161441         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
161442         Remove useless quotes: DF_PROG="df".
161443         * m4/strnlen.m4: New file.
161445 2002-01-16  Paul Eggert  <eggert@twinsun.com>
161447         * lib/backupfile.c (ISDIGIT): Comment fix.
161448         * lib/getdate.y (ISDIGIT): Likewise.
161449         * lib/posixtm.c (ISDIGIT, year): Likewise.
161450         * lib/strverscmp.c (ISDIGIT): Likewise.
161451         * lib/userspec.c (ISDIGIT): Likewise.
161453 2002-01-16  Jim Meyering  <meyering@lucent.com>
161455         * lib/getdate.y: Add three semicolons, each just before a closing
161456         brace. Bison (as of version 1.31) no longer papers over that mistake.
161458 2002-01-05  Jim Meyering  <meyering@lucent.com>
161460         * lib/version-etc.c (version_etc_copyright): Update copyright year.
161462 2001-12-19  Paul Eggert  <eggert@twinsun.com>
161464         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
161465         not silently exit merely because the output buffer happens to
161466         have nothing pending.
161468 2001-12-18  Paul Eggert  <eggert@twinsun.com>
161470         See the big note in ../ChangeLog.
161471         * lib/human.c (suffixes): Prefer K to k for 1024.
161472         (generate_suffix_backwards): New function.
161473         (human_readable_inexact): Use it.
161474         * lib/xstrtol.c (__xstrtol): If there is no number but there
161475         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
161476         Accept 'K' as well as 'k'.
161478 2001-12-15  Jim Meyering  <meyering@lucent.com>
161480         * lib/regex.h (__restrict_arr): Update from libc.
161482         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
161483         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
161484         (STREQ): Define.
161486 2001-12-14  Jim Meyering  <meyering@lucent.com>
161488         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
161489         Suggestion from Bruno Haible.
161491 2001-12-10  Jim Meyering  <meyering@lucent.com>
161493         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
161494         xrealloc, Instead, include "xalloc.h".
161495         (initbuffer): Don't cast xmalloc return value to char*.
161496         (readline): Reword comment.
161497         Don't cast xrealloc return value to char*
161498         Return NULL, not 0.
161500 2001-12-09  Jim Meyering  <meyering@lucent.com>
161502         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
161503         about `signed and unsigned type in conditional expression'.
161504         * lib/posixtm.c (posix_time_parse): Likewise.
161506         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
161508         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
161509         to avoid a pedantic warning.
161511         * lib/getstr.c: Don't include assert.h.
161512         (getstr): Remove warning-evoking assertions.
161513         Return -1 if offset parameter is out of bounds.
161514         Change the type of a local from int to size_t.
161516         * lib/strftime.c (my_strftime_localtime_r): Include this function
161517         definition in the `#if ! HAVE_TM_GMTOFF' block.
161519         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
161520         Include xalloc.h instead.
161522 2001-12-02  Jim Meyering  <meyering@lucent.com>
161524         * lib/tempname.c: Don't declare getenv, thus reverting the change of
161525         2001-11-18.  It's no longer necessary, now that stdlib.h is always
161526         included.
161528         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
161529         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
161531 2001-11-30  Akim Demaille  <akim@epita.fr>
161533         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
161534         before being defined.
161536 2001-11-27  Paul Eggert  <eggert@twinsun.com>
161538         * lib/quotearg.h (quotearg_n, quotearg_n_style):
161539         First arg is int, not unsigned.
161540         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
161541         (SIZE_MAX, UINT_MAX): New macros.
161542         (quotearg_n_options): Abort if N is negative.
161543         Avoid overflow check on hosts where size_t is 64 bits and int
161544         is 32 bits, as overflow is impossible there.
161545         Fix off-by-one typo that caused unnecessary reallocation.
161547 2001-11-27  Jim Meyering  <meyering@lucent.com>
161549         * lib/tempname.c: Merge with version from libc.
161550         * lib/regex.c: Likewise.
161552         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
161553         systems for which STDC_HEADERS is 0, it was not included, resulting in
161554         a warning about an integer-to-pointer conversion problem with getenv.
161555         Reported by Volker Borchert.
161557 2001-11-26  Jim Meyering  <meyering@lucent.com>
161559         * lib/gtod.h: Remove file.
161560         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
161561         * lib/gettimeofday.c: Don't include gtod.h.
161562         (GTOD_init): Remove function.
161563         (rpl_gettimeofday): Do its job here instead, rather than aborting.
161564         Suggestion from Volker Borchert.
161566 2001-11-23  Jim Meyering  <meyering@lucent.com>
161568         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
161569         it.
161570         * lib/hash.c (struct hash_table): Define it here instead.
161572 2001-11-22  Jim Meyering  <meyering@lucent.com>
161574         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
161576 2001-11-20  Jim Meyering  <meyering@lucent.com>
161578         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
161579         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
161581 2001-11-19  Jim Meyering  <meyering@lucent.com>
161583         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
161584         directory.  Use "conftestXXXXXX" as the template.
161585         Suggestion from Paul Eggert.
161587         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
161588         immediately, so the test doesn't mistakenly hit the max-open-files
161589         limit.
161591 2001-11-18  Paul Eggert  <eggert@twinsun.com>
161593         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
161594         (TEMPORARIES): New macro.
161595         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
161596         removes an artificial limitation (e.g. HP-UX 10.20, where
161597         TMP_MAX is 17576).
161599 2001-11-18  Jim Meyering  <meyering@lucent.com>
161601         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
161603 2001-11-18  Jim Meyering  <meyering@lucent.com>
161605         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
161606         on SunOS 4.
161608         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
161609         files will be created before anything else.
161611 2001-11-17  Paul Eggert  <eggert@twinsun.com>
161613         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
161614         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
161616 2001-11-17  Jim Meyering  <meyering@lucent.com>
161618         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
161619         Prompted by a report from Bob Proulx.
161621         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
161622         Instead, require UTILS_FUNC_MKSTEMP.
161624 2001-11-17  Jim Meyering  <meyering@lucent.com>
161626         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
161627         Now, that's done as part of AC_FUNC_STRTOD.
161629 2001-11-17  Jim Meyering  <meyering@lucent.com>
161631         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
161632         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
161633         rather than group writable.  Patch by Juan F. Codagnone.
161635         * lib/readtokens.c: Remove explicit declarations of xmalloc and
161636         xrealloc, Instead, include "xalloc.h".
161638         * lib/mountlist.c: Include unlocked-io.h after all system headers.
161639         Remove explicit declarations of xmalloc, xrealloc,
161640         and xstrdup.  Instead, include "xalloc.h".
161642         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
161643         unlocked-io.h.
161644         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
161645         Likewise.
161646         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
161648         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
161649         Reported by Padraig Brady.
161651         * lib/mkstemp.c: #undef mkstemp.
161652         Include config.h.
161653         (rpl_mkstemp): Rename from mkstemp.
161654         Protoize.
161656 2001-11-16  Jim Meyering  <meyering@lucent.com>
161658         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
161659         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
161660         determine the amount of total physical memory, use pstat_getstatic.
161661         HPUX-11 doesn't define _SC_PHYS_PAGES.
161662         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
161663         If sysconf couldn't be used to determine the amount of available
161664         physical memory, use both pstat_getstatic and pstat_getdynamic.
161665         Based on a patch from Bob Proulx.
161667 2001-11-10  Jim Meyering  <meyering@lucent.com>
161669         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
161670         (jm_PREREQ): Use it.
161672 2001-11-09  Jim Meyering  <meyering@lucent.com>
161674         * m4/jm-macros.m4: Require autoconf-2.52f.
161675         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
161676         Use these AC_-prefixed names, not the AM_-prefixed ones.
161678         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
161680 2001-11-05  Jim Meyering  <meyering@lucent.com>
161682         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
161684 2001-11-04  Jim Meyering  <meyering@lucent.com>
161686         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
161687         $DEFS.
161689 2001-11-03  Jim Meyering  <meyering@lucent.com>
161691         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
161692         of AC_DEFUN.
161694         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
161695         know the name of the variable in the macro definition.
161697 2001-11-03  Jim Meyering  <meyering@lucent.com>
161699         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
161700         in argmatch_to_argument call.
161702         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
161703         argument.
161705         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
161706         e.g., a fault due to an attempt to free a NULL pointer.
161708 2001-11-01  Jim Meyering  <meyering@lucent.com>
161710         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
161711         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
161713 2001-11-01  Jim Meyering  <meyering@lucent.com>
161715         * lib/dirfd.c, lib/dirfd.h: New files.
161716         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
161718         * lib/hash.c (hash_print) [TESTING]: Clean up.
161720 2001-10-22  Paul Eggert  <eggert@twinsun.com>
161722         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
161723         to avoid a warning if -Wall.
161725 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
161727         * README: New file
161728         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
161729         (per RMS's instructions, this is now the canonical source)
161730         * lgpl/, gpl/: New directories.
161732 2001-10-21  Paul Eggert  <eggert@twinsun.com>
161734         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
161736 2001-10-21  Jim Meyering  <meyering@lucent.com>
161738         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
161739         this code would end up calling gettext even in packages built
161740         with --disable-nls.
161741         * lib/getopt.c (_): Likewise.
161742         * lib/regex.c (_): Likewise.
161744 2001-10-20  Paul Eggert  <eggert@twinsun.com>
161746         * m4/error.m4 (jm_PREREQ_ERROR):
161747         Do not invoke AC_CHECK_FUNCS with strerror_r, as
161748         AC_FUNC_STRERROR_R does that.
161749         Check for strerror declaration.
161751         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
161752         are supposed to have them these days.
161753         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
161754         Merge changes from latest Autoconf CVS.
161755         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
161756         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
161757         POSIX decided to standardize on the int flavor of strerror_r.
161759 2001-10-20  Paul Eggert  <eggert@twinsun.com>
161761         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
161762         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
161763         Use strerror_r that is only a macro, even if it is not a function.
161764         (strerror): Check for HAVE_DECL_STRERROR before declaring.
161765         (private_strerror): Use prototypes, not old-style function definition.
161766         (print_errno_message): New function.
161767         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
161768         char*-flavored one.
161769         (error_tail, error, error_at_line): Use it.
161771 2001-10-11  Jim Meyering  <meyering@lucent.com>
161773         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
161774         and quote_n (1, ... to avoid clobbering a buffer.
161776 2001-10-05  Jim Meyering  <meyering@lucent.com>
161778         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
161779         hash-pjw.h.
161780         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
161781         * lib/hash-pjw.h: New file.
161783 2001-09-30  Jim Meyering  <meyering@lucent.com>
161785         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
161786         `struct fsstat' has the `f_fstypename' member.
161787         Use that to define FS_TYPE, which is now used to make
161788         the getfsstat link test tighter.
161790 2001-09-30  Jim Meyering  <meyering@lucent.com>
161792         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
161793         Include <sys/ucred.h>, for Apple Darwin.
161794         Include sys/mount.h and sys/fs_types.h only if available.
161795         (FS_TYPE): Define.
161796         (read_filesystem_list): Use FS_TYPE.
161798 2001-09-29  Paul Eggert  <eggert@twinsun.com>
161800         * lib/exclude.c (excluded_filename): 0 -> false, since it's
161801         a boolean context.
161803 2001-09-29  Jim Meyering  <meyering@lucent.com>
161805         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
161806         [one-argument getmntent function]): Include stdio.h before mntent.h.
161807         SunOS 4.1.x needs it for the declaration of `FILE'.
161808         Patch by Volker Borchert.
161810         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
161811         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
161812         sys/fs_types.h, and make the link-test for getfsstat guard #include
161813         directives with appropriate #if HAVE_*_H tests so that we can
161814         detect getfsstat on Apple Darwin1.3.7 systems.
161815         Reported by Nelson Beebe.
161816         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
161818 2001-09-28  Paul Eggert  <eggert@twinsun.com>
161820         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
161821         #defines strtoimax.  Also treat the other strto* functions
161822         like strtoimax.
161824         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
161825         Check for strtoul and strtoumax,
161826         as those declarations are made even in the signed case.
161827         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
161828         Likewise, for strtol and strtoimax.
161830 2001-09-28  Paul Eggert  <eggert@twinsun.com>
161832         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
161833         #defines strtoimax.  Also treat the other strto* functions
161834         like strtoimax.
161836         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
161837         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
161838         (strtoimax, strtoumax): Do not declare if already defined as a macro.
161840 2001-09-26  Jim Meyering  <meyering@lucent.com>
161842         Most macros in unlocked-io.h had the wrong number of arguments.
161843         * lib/gen-uio: New script.
161844         (USE_UNLOCKED_IO): Define to 1 if not already defined.
161845         * lib/unlocked-io.hin: Remove file.
161846         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
161847         rather than trying to embed it here.
161848         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
161849         Reported by Padraig Brady.
161851 2001-09-25  Volker Borchert  <bt@teknon.de>
161853         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
161854         `result'.
161856 2001-09-24  Jim Meyering  <meyering@lucent.com>
161858         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
161860 2001-09-23  Jim Meyering  <meyering@lucent.com>
161862         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
161863         instead of the mere test for existence of mntent.h.  The latter
161864         would get a false-positive on AIX 3.4 systems.
161865         In the outer getmntent if-block, don't die if neither of the getmntent
161866         tests succeeds.  Instead, just fall through and continue with the
161867         remaining tests.
161869 2001-09-23  Jim Meyering  <meyering@lucent.com>
161871         * lib/mountlist.c: Remove useless parentheses in #if directives.
161872         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
161873         the deprecated MOUNTED symbol is no longer defined in mntent.h.
161875 2001-09-22  Jim Meyering  <meyering@lucent.com>
161877         * m4/gettext.m4: New file.  From gettext.
161878         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
161879         * m4/progtest.m4: Likewise
161880         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
161881         * m4/glibc21.m4: Likewise.
161883         * m4/libintl.m4: Remove.  No longer used.
161885 2001-09-22  Jim Meyering  <meyering@lucent.com>
161887         * lib/localcharset.c: Update from latest gettext.
161888         * lib/config.charset: Likewise.
161890 2001-09-20  Jim Meyering  <meyering@lucent.com>
161892         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
161893         strtoimax.
161894         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
161895         strtoumax.
161897 2001-09-20  Jim Meyering  <meyering@lucent.com>
161899         * lib/xstrtol.c (strtoimax): Guard declaration with
161900         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
161901         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
161902         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
161903         (strtoumax): Likewise, for completeness (it wasn't necessary).
161905 2001-09-17  Paul Eggert  <eggert@twinsun.com>
161907         * lib/strtoimax.c (HAVE_LONG_LONG):
161908         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
161909         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
161910         to work around bug in IBM C compiler.
161912 2001-09-17  Jim Meyering  <meyering@lucent.com>
161914         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
161915         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
161916         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
161917         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
161918         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
161919         whenever the right hand side need not be expanded by the shell.
161921 2001-09-16  Paul Eggert  <eggert@twinsun.com>
161923         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
161924         library.  It's not correct, as some older glibcs are buggy.
161925         fnmatch wasn't fixed until glibc 2.2.
161927         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
161928         special shell magic here.
161930 2001-09-16  Jim Meyering  <meyering@lucent.com>
161932         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
161933         * m4/jm-macros.m4: Require it.
161935 2001-09-16  Jim Meyering  <meyering@lucent.com>
161937         * lib/mkdir.c: New file.
161939 2001-09-15  Jim Meyering  <meyering@lucent.com>
161941         * m4/jm-macros.m4: Check for help2man.
161943 2001-09-11  Jim Meyering  <meyering@lucent.com>
161945         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
161946         The body, by Paul Eggert, was moved here from configure.in.
161947         * m4/jm-macros.m4: Require UTILS_HOST_OS.
161949 2001-09-04  Paul Eggert  <eggert@twinsun.com>
161951         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
161952         (jm_PREREQ): Use it.
161954 2001-09-04  Paul Eggert  <eggert@twinsun.com>
161956         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
161957         Use ssize_t, not int, to store result of readlink.
161958         Check for ssize_t overflow as well as size_t overflow,
161959         as POSIX says the result of readlink is implementation-defined
161960         when ssize_t overflows.
161961         Remove unnecessary cast to char*.
161962         Use free+malloc instead of realloc, as the storage doesn't need
161963         to be preserved and it's clearer and can be more efficient that way.
161964         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
161965         * lib/xreadlink.h (xreadlink): Update prototype.
161967 2001-09-04  Paul Eggert  <eggert@twinsun.com>
161969         * lib/xgetcwd.c: Revert some of the previous change; intead,
161970         fix the HAVE_GETCWD_NULL code to behave more like the
161971         !HAVE_GETCWD_NULL code used to.
161973         Include "xalloc.h".
161974         (xgetcwd): Do not return NULL when memory is exhausted; instead,
161975         invoke xalloc_die.
161977 2001-09-03  Paul Eggert  <eggert@twinsun.com>
161979         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
161980         sys/param.h, as pathmax.h includes them.
161982 2001-09-03  Paul Eggert  <eggert@twinsun.com>
161984         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
161985         (jm_PREREQ_XGETCWD): New macro.
161987         * m4/getcwd.m4: New file.
161989 2001-09-03  Paul Eggert  <eggert@twinsun.com>
161991         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
161992         like the HAVE_GETCWD_NULL code.
161993         Include pathmax.h if not HAVE_GETCWD.
161994         Do not include xalloc.h.
161995         (INITIAL_BUFFER_SIZE): New symbol.
161996         Do not use xmalloc / xrealloc, since the caller is responsible for
161997         handling errors.  Preserve errno around `free' during failure.
161998         Do not overrun buffer when using getwd.
162000 2001-09-03  Paul Eggert  <eggert@twinsun.com>
162002         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
162003         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
162004         getcwd (NULL, 0).
162006 2001-09-03  Paul Eggert  <eggert@twinsun.com>
162008         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
162009         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
162010         spotted by Jim Meyering.
162012 2001-09-03  Jim Meyering  <meyering@lucent.com>
162014         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
162015         failure.
162017 2001-09-02  Jim Meyering  <meyering@lucent.com>
162019         * lib/error.c: Update from GNU libc.
162021 2001-09-01  Jim Meyering  <meyering@lucent.com>
162023         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
162024         Used by df.
162026 2001-09-01  Jim Meyering  <meyering@lucent.com>
162028         * lib/xreadlink.c: New file.
162029         * lib/xreadlink.h: New file.
162030         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
162031         xreadlink.h.
162033         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
162034         doesn't conflict with sparc Solaris 7's definition in
162035         /usr/include/sys/int_types.h.
162037         * lib/exclude.c: Use `""', not `<>' to #include non-system header
162038         files.
162039         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
162040         and strncasecmp as r-values.  Unixware didn't have declarations.
162042 2001-08-31  Paul Eggert  <eggert@twinsun.com>
162044         * lib/xstrtol.h: Add copyright notice.
162045         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
162046         LONGINT_INVALID_SUFFIX_CHAR.
162048 2001-08-31  Paul Eggert  <eggert@twinsun.com>
162050         * lib/xstrtol.c (strtoimax): New decl.
162052 2001-08-31  Paul Eggert  <eggert@twinsun.com>
162054         * lib/xgetcwd.c: Don't include pathmax.h.
162055         Include stdlib.h and unistd.h if available.
162056         Include xalloc.h.
162057         (xmalloc, xstrdup, free): Remove decls.
162058         (xgetcwd): Don't assume sizes fit in unsigned.
162059         Check for overflow when computing sizes.
162060         Simplify reallocation code.
162062 2001-08-31  Paul Eggert  <eggert@twinsun.com>
162064         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
162065         a directory's st_size can have an arbitrary value, so the old
162066         usage could waste an arbitrary amount of memory.  All uses
162067         changed.
162068         * lib/savedir.h: Update prototype.
162070 2001-08-31  Paul Eggert  <eggert@twinsun.com>
162072         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
162074         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
162075         old strtoimax.c.
162077         Also, make the following further changes to make this file's
162078         configuration more similar to that of strtol.c:
162079         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
162080         (strtoumax, uintmax_t, strtoull, strtol): Remove.
162081         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
162082         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
162083         changed to signed values.
162085         And make the following changes as well:
162086         Fix copyright notice, as 1999 was missing.
162087         (verify): New macro.
162088         (strtoimax): Check sizes at compile-time, not run-time.
162089         Prefer strtol to strtoll if both work.
162090         (main): Remove; it was not that useful and was a pain to maintain.
162092         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
162094 2001-08-31  Jim Meyering  <meyering@lucent.com>
162096         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
162097         Use an initial, malloc'd, buffer of length 128 rather than
162098         a statically allocated one of length 1024.
162100 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162102         Simplify code, partly by assuming autoconf 2.52 semantics.
162104         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
162106         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
162107         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
162108         All uses removed.
162109         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
162110         Move AC_REQUIRE to next-to-top level, to avoid confusion.
162111         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
162112         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
162113         jm_AC_HEADER_INTTYPES_H.
162114         * m4/jm-macros.m4 (jm_MACROS): Likewise.
162116         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
162118         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
162119         Quote first arg of AC_DEFUN.
162120         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
162121         since they are needed to parse the include file even if we need
162122         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
162123         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
162124         but with opposite signedness.
162126 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162128         Merge 'exclude' changes from tar 1.13.22.
162129         This fixes one or two unlikely storage allocation overflow bugs,
162130         but doesn't change user-visible behavior otherwise.
162132 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162134         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
162135         (jm_PREREQ_EXCLUDE): New macro.
162137 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162139         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
162140         tm to be declared.
162142 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162144         * lib/hash.c: Remove '2001' from copyright notice.
162146 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162148         * lib/full-write.h: New file.
162149         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
162150         * lib/full-write.c: Correct credits, as cccp.c no longer
162151         exists and anyway it was so heavily changed from the old cccp
162152         code as to be unrecognizable.  Include full-write.h.
162153         (full_write): Return size_t, with short writes meaning failure.
162154         All callers changed.  This fixes a bug with large buffers
162155         on 64-bit hosts.
162156         * lib/utime.c: Include full-write.h.
162158 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162160         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
162161         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
162162         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
162163         Include if available.
162164         (<xalloc.h>): Include
162165         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
162166         (verify): New macro.  Use it to verify that EXCLUDE macros do not
162167         collide with FNM macros.
162168         (struct patopts): New struct.
162169         (struct exclude): Use it, as exclude patterns now come with options.
162170         (new_exclude): Support above changes.
162171         (new_exclude, add_exclude_file):
162172         Initial size must now be a power of two to simplify overflow checking.
162173         (free_exclude, fnmatch_no_wildcards): New function.
162174         (excluded_filename): No longer requires options arg, as the options
162175         are determined by add_exclude.  Now returns bool, not int.
162176         (excluded_filename, add_exclude):
162177         Add support for the fancy new exclusion options.
162178         (add_exclude, add_exclude_file): Now takes int options arg.
162179         Check for arithmetic overflow when computing sizes.
162180         (add_exclude_file): xrealloc might modify errno, so don't
162181         realloc until after errno might be used.
162183         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
162184         New macros.
162185         (free_exclude): New decl.
162186         (add_exclude, add_exclude_file): Now takes int options arg.
162187         (excluded_filename): No longer requires options arg, as the options
162188         are determined by add_exclude.  Now returns bool, not int.
162190 2001-08-30  Paul Eggert  <eggert@twinsun.com>
162192         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
162194 2001-08-27  Jim Meyering  <meyering@lucent.com>
162196         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
162198         * lib/version-etc.c (N_): Remove definition.
162199         Revert most of last change.
162200         Instead, simply don't mark the `Copyright...' string for translation.
162201         Based on advice from Paul Eggert.
162203         * lib/strtoxmax.c: Tweak comment.
162205 2001-08-26  Jim Meyering  <meyering@lucent.com>
162207         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
162209         * m4/xstrtoimax.m4: New file.
162210         * m4/xstrtoumax.m4: Add comments explaining why we
162211         AC_REPLACE_FUNCS(strtol).
162213 2001-08-26  Jim Meyering  <meyering@lucent.com>
162215         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
162216         of copyright with `%s' so translators don't get an untranslated
162217         message in 2002.
162218         (COPYRIGHT_YEAR): Define.
162219         (version_etc): Use fprintf rather than fputs.
162220         Suggestion from Ulrich Drepper.
162222         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
162224         * lib/strtoll.c: New file, from GNU libc.
162225         * lib/xstrtoimax.c: New file.
162227         * lib/xstrtol.h: Add xstrtoimax.
162228         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
162229         * lib/strtoimax.c: New file.  Likewise, but first define
162230         STRTOUXMAX_SIGNED.
162232         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
162233         ...
162234         * lib/strtoxmax.c: ... then renamed to this.
162236 2001-08-18  Paul Eggert  <eggert@twinsun.com>
162238         * m4/inttypes.m4: Add AC_PREREQ(2.13).
162239         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
162240         (jm_AC_TYPE_INTMAX_T): New macro.
162241         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
162243         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
162245         * m4/longlong.m4: Renamed from ulonglong.m4.
162246         * m4/inttypes.m4: Renamed from inttypes_h.m4.
162247         * m4/uintmax_t.m4: Removed.
162249 2001-08-13  Paul Eggert  <eggert@twinsun.com>
162251         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
162252         Port to Solaris 8, where 'sed' requires a space after the 'r'
162253         command, and where sh dislikes "$/".  Clean up the spacing a bit.
162254         Redirect output to $tmp just once.
162256 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
162258         * lib/addext.c (<errno.h>): Include.
162259         (errno): Declare if not defined.
162260         (addext): Work correctly when pathconf returns -1 and leaves
162261         errno alone because there is no limit.  Also, work even if
162262         pathconf returns a value greater than SIZE_MAX.
162264 2001-08-12  Jim Meyering  <meyering@lucent.com>
162266         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
162267         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
162268         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
162269         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
162270         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
162271         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
162272         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
162273         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
162274         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
162275         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
162276         utime.m4, utimes.m4, xstrtoumax.m4:
162277         Quote the first argument in each use of AC_DEFUN.
162279 2001-08-12  Jim Meyering  <meyering@lucent.com>
162281         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
162282         Simply `return getcwd (NULL, 0);'.
162283         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
162284         Use 1300 as initial value for length, not PATH_MAX.
162286         * lib/pathmax.h: Clean up cpp syntax.
162288 2001-08-12  Jim Meyering  <meyering@lucent.com>
162290         * lib/gettimeofday.c: New file.
162291         * lib/gtod.h: New file.
162292         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
162294 2001-08-05  Jim Meyering  <meyering@lucent.com>
162296         * m4/jm-macros.m4: Require autoconf-2.52.
162298 2001-08-04  Jim Meyering  <meyering@lucent.com>
162300         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
162301         stmt, to get in sync with glibc.
162303 2001-08-03  Paul Eggert  <eggert@twinsun.com>
162305         The following changes are from gettext 0.10.39 as maintained by
162306         Bruno Haible.
162308         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
162309         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
162310         with inverted sense.  All uses changed.
162312         * lib/mbswidth.c: Don't include <limits.h>.
162313         Include <stdlib.h> and <string.h> unconditionally.
162314         (iswcntrl, mbsinit, ISCNTRL): New macros.
162315         (mbsnwidth): Use K&R style function declarations.
162316         Don't bother checking for MB_LEN_MAX == 1, since the compiler
162317         can optimize it when MB_CUR_MAX == 1.
162318         The width of control characters is zero, not 1.
162320 2001-08-03  Paul Eggert  <eggert@twinsun.com>
162322         The following changes are from gettext 0.10.39 as maintained by
162323         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
162325         * m4/codeset.m4: Upgrade to serial AM1.
162326         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
162327         all uses changed.  Quote first arg of AC_DEFUN.
162328         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
162330         * m4/iconv.m4: Upgrade to serial AM2.
162331         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
162332         Add --with-libconv-prefix.
162333         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
162334         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
162335         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
162336         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
162337         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
162339         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
162340         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
162341         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
162342         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
162343         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
162344         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
162345         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
162346         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
162347         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
162349         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
162350         string.h any more.
162352         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
162353         not the default value.
162355         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
162356         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
162357         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
162358         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
162359         Also check for iswcntrl, used for wcwidth fallback.
162360         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
162361         to Autoconf 2.13.
162363 2001-08-03  Jim Meyering  <meyering@lucent.com>
162365         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
162366         as it was in the original.  Reported by Paul Eggert.
162368 2001-07-16  Jim Meyering  <meyering@lucent.com>
162370         * m4/gettimeofday.m4: New file.
162371         Prompted by a report from Bernhard Baehr.
162373 2001-07-15  Jim Meyering  <meyering@lucent.com>
162375         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
162376         stuff. Now it's in ../Makefile.cfg.
162378 2001-07-15  Jim Meyering  <meyering@lucent.com>
162380         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
162381         (BUILT_SOURCES): Add unlocked-io.h.
162382         (io_functions): Define.
162383         (unlocked-io.h): New rule.
162384         (DISTCLEANFILES): Add unlocked-io.h.
162385         (all-local): Depend on unlocked-io.h, to ensure it is created.
162387         * lib/unlocked-io.hin: New file
162389         * lib/regex.c: Update from glibc.
162391 2001-07-05  Jim Meyering  <meyering@lucent.com>
162393         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
162394         recommendation.
162395         (libfetish_a_SOURCES): Put all .h files here instead.
162396         Remove a thus-exposed (better checks in automake) duplicate and
162397         two unnecessary .h files.
162399 2001-07-04  Jim Meyering  <meyering@lucent.com>
162401         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
162402         that generates jm-glibc-io.m4 so that it doesn't trigger any make
162403         distcheck failure.
162405 2001-07-02  Jim Meyering  <meyering@lucent.com>
162407         The following changes were prompted by suggestions from Bruno Haible.
162409         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
162410         is now generated.
162411         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
162412         definition of EXTRA_DIST.
162413         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
162414         ensure that the generated file is created/updated whenever the list
162415         of $(unlocked_functions) is changed.
162416         (jm-glibc-io.m4): New rule.
162417         (unlocked-io.h): New rule -- currently unused.
162419 2001-06-24  Jim Meyering  <meyering@lucent.com>
162421         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
162422         unmatched right bracket, rather than kludging it with an extra,
162423         falsely-matching quote in a comment.  Patch by Akim Demaille.
162425 2001-06-11  Jim Meyering  <meyering@lucent.com>
162427         * lib/regex.c: Update from GNU libc.
162429 2001-05-27  Jim Meyering  <meyering@lucent.com>
162431         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
162432         Check for ut_type in struct utmp.
162434 2001-05-27  Jim Meyering  <meyering@lucent.com>
162436         * lib/readutmp.h (UT_TYPE): Define.
162438 2001-05-24  Jim Meyering  <meyering@lucent.com>
162440         * lib/argmatch.c: Include "quote.h".
162441         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
162442         quote function.  Reported by Göran Uddeborg.
162444 2001-05-22  Jim Meyering  <meyering@lucent.com>
162446         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
162447         now that we use the package-supplied version unconditionally.
162448         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
162450 2001-05-21  Jim Meyering  <meyering@lucent.com>
162452         * m4/regex.m4: Change a couple backticks to single quotes to avoid
162453         shell syntax errors.
162455 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
162457         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
162459 2001-05-20  Paul Eggert  <eggert@twinsun.com>
162461         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
162462         Don't bother to check library strftime, since
162463         we'll be using our own my_strftime function anyway.
162464         Define my_strftime instead of strftime.
162466 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
162468         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
162469         which is not yet declared.
162471 2001-05-15  Jim Meyering  <meyering@lucent.com>
162473         * m4/regex.m4: Use proper quoting so brackets appear in the test
162474         program.
162475         Reported by, and with help from, Bruno Haible.
162477 2001-05-13  Jim Meyering  <meyering@lucent.com>
162479         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
162480         undefined.
162482 2001-05-11  Paul Eggert  <eggert@twinsun.com>
162484         dirname code cleanup.  base_name now behaves more compatibly
162485         with POSIX basename when given file names that have trailing
162486         slashes, and similarly for dir_name.  Add new primitives
162487         base_len and dir_len.  Put the directory-name-related decls
162488         into dirname.h.
162490         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
162491         * lib/backupfile.c (base_name): Likewise.
162492         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
162493         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
162494         * lib/makepath.c (strip_trailing_slashes): Likewise.
162495         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
162496         ISSLASH): Likewise.
162497         * lib/rename.c (strip_trailing_slashes): Likewise.
162498         * lib/same.c (base_name): Likewise.
162499         * lib/stripslash.c (ISSLASH): Likewise.
162501         * lib/addext.c: Include <dirname.h> after size_t is defined.
162502         * lib/backupfile.c: Likewise.
162504         * lib/addext.c (addext): Use base_len to trim redundant
162505         trailing slashes instead of doing it ourselves.
162506         But do not trim the last slash if it is not redundant.
162508         * lib/backupfile.c (find_backup_file_name,
162509         max_backup_version): Use base_len instead of rolling it ourselves.
162510         Handle the case of "" and (on DOS) "C:" correctly.
162512         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
162513         needed. Include <string.h>, <dirname.h>.
162514         (base_name): Allow file names ending in slashes, other than names
162515         that are all slashes.  In this case, return the basename followed
162516         by the slashes.  This is more general, and can be used in places
162517         where the original base_name purposely had an assertion failure.
162518         (base_len): New function.
162520         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
162521         Do not include <assert.h>; no longer needed.
162522         Include xalloc.h.
162523         (memrchr): Remove decl.
162524         (dir_name_r): Remove.
162525         (dir_len): Renamed from dirlen.  All callers changed.
162526         Rewrite in terms of base_name, for simplicity and consistency.
162527         (dir_name): Never return NULL.  All callers changed.
162528         Do not include <stdlib.h> in test program; no longer needed.
162529         return 0; is fine for test program.
162531         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
162532         New macros.
162533         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
162535         * lib/path-concat.c (path_concat): Use base_len to compute
162536         base length, not strlen; this means we cannot rely on memcpy
162537         to null-terminate.
162539         * lib/same.c (STREQ): Remove.
162540         (same_name): Handle the case where the basename ends in trailing '/'.
162542         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
162543         a slash was stripped.  Do not strip the last slash after a
162544         file system prefix.
162546 2001-05-11  Paul Eggert  <eggert@twinsun.com>
162548         * lib/Makefile.am (libfetish_a_SOURCES):
162549         Add strftime.c, since we now compile it on all hosts.
162551         * lib/strftime.c (my_strftime):
162552         Define to nstrftime if emacs, but only if my_strftime is not defined.
162553         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
162554         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
162555         Add one more extra argument: a nanoseconds value.
162556         All uses changed.
162557         (ns): New macro.
162558         (my_strftime function): Add %N format.
162559         (emacs_strftimeu): Renamed from emacs_strftime,
162560         with extra ut argument.
162562 2001-05-09  Paul Eggert  <eggert@twinsun.com>
162564         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
162566 2001-04-21  Jim Meyering  <meyering@lucent.com>
162568         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
162569         doesn't interfere.
162571 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
162573         * m4/ftruncate.m4: Check for chsize.
162574         Link with ftruncate.o unconditionally if ftruncate is missing.
162575         This was required when cross-compiling to i586-mingw32msvc.
162577 2001-04-08  Jim Meyering  <meyering@lucent.com>
162579         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
162580         recomputed; that's necessary when the offset spans a DST transition.
162581         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
162583 2001-04-02  Jim Meyering  <meyering@lucent.com>
162585         * lib/regex.h, regex.c: Update from GNU libc.
162587 2001-03-24  Jim Meyering  <meyering@lucent.com>
162589         * m4/jm-macros.m4: Require autoconf-2.49d.
162591 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
162593         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
162595 2001-03-19  Paul Eggert  <eggert@twinsun.com>
162597         * lib/version-etc.c (version_etc_copyright): Update to 2001.
162599 2001-03-17  Jim Meyering  <meyering@lucent.com>
162601         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
162602         now that the version in autoconf is equivalent.
162603         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
162605         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
162606         Suggestion from Akim Demaille.
162608         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
162609         (jm_PREREQ_TEMPNAME): New function.
162611 2001-03-16  Paul Eggert  <eggert@twinsun.com>
162613         * lib/tempname.c (uint64_t): Define to uintmax_t if
162614         not defined, and if UINT64_MAX is not defined.
162615         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
162616         Reported by John David Anglin.
162618 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
162620         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
162621         resolve alias if codeset is empty.
162622         * lib/config.charset (BeOS): Use wildcard syntax.
162624 2001-03-13  Jim Meyering  <meyering@lucent.com>
162626         * lib/path-concat.c (path_concat)
162627         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
162628         concatenating e.g., `C:' and `foo'.
162629         From Bruno Haible.
162631 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
162633         * lib/localcharset.c (locale_charset): Don't use
162634         setlocale(LC_CTYPE,NULL). Don't return NULL.
162635         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
162637 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
162639         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
162640         support for DOS/DJGPP.
162642 2001-03-01  Paul Eggert  <eggert@twinsun.com>
162644         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
162645         lacks mkstemp.  Compile our own tempname.c if we compile our own
162646         mkstemp.c, as mkstemp relies on tempname.
162648 2001-03-01  Jim Meyering  <meyering@lucent.com>
162650         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
162651         AH_VERBATIM really does output its argument verbatim.
162653 2001-02-28  Paul Eggert  <eggert@twinsun.com>
162655         * lib/Makefile.am (libfetish_a_SOURCES):
162656         Add dup-safer.c, fopen-safer.c.
162657         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
162659         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
162660         * lib/unistd-safer.h: New files.
162662 2001-02-25  Paul Eggert  <eggert@twinsun.com>
162664         The mkstemp replacement is taken from glibc 2.2.2, with some
162665         portability fixes for use outside glibc, as follows:
162667         * lib/tempname.c (struct_stat64): New macro.
162668         (direxists, __gen_tempname): Use it.
162669         This avoids a portability problem with Solaris 8.
162671         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
162672         (<stddef.h>, <stdint.h>, <string.h>):
162673         Include only if STDC_HEADERS || _LIBC.
162674         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
162675         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
162676         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
162677         (__set_errno): Define this macro if <errno.h> doesn't.
162678         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
162679         Define these macros if <stdio.h> doesn't.
162680         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
162681         Define these macros if <sys/stat.h>
162682         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
162683         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
162684         __xstat64): Define if not _LIBC.
162685         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
162686         (__gen_tempname): Invoke gettimeofday only if
162687         HAVE_GETTIMEOFDAY || _LIBC;
162688         otherwise, fall back on plain "time".
162689         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
162691         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
162693         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
162695 2001-02-18  Paul Eggert  <eggert@twinsun.com>
162697         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
162699 2001-02-17  Paul Eggert  <eggert@twinsun.com>
162701         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
162702         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
162703         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
162704         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
162706 2001-02-17  Paul Eggert  <eggert@twinsun.com>
162708         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
162709         Remove workaround macros for hosts that have mbrtowc but not
162710         mbstate_t, as we now insist on proper declarations for both
162711         before using mbrtowc.
162713 2001-02-17  Jim Meyering  <meyering@lucent.com>
162715         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
162716         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
162717         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
162718         UnixWare 7.1.1.
162720         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
162721         rather than AC_CACHE_VAL.
162723 2001-02-17  Jim Meyering  <meyering@lucent.com>
162725         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
162726         around included file name.
162728         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
162730         * lib/strftime.c: Update from GNU libc (the only changes were to
162731         comments).
162733 2001-02-17  Jim Meyering  <meyering@lucent.com>
162735         * lib/regex.c: Update from libc.
162737 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
162739         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
162740         clash.
162742 2001-02-16  Paul Eggert  <eggert@twinsun.com>
162744         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
162745         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
162746         Reported by Mark Hounschell via Paul Eggert.
162748 2001-02-07  Jim Meyering  <meyering@lucent.com>
162750         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
162752 2001-02-05  Jim Meyering  <meyering@lucent.com>
162754         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
162755         it includes the patch required for `large file' support with at least
162756         HP-UX's 10.20 /bin/cc.
162758 2001-02-03  Jim Meyering  <meyering@lucent.com>
162760         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
162761         AS_IF, now that it works once again (mysteriously).
162762         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
162764 2001-01-30  Jim Meyering  <meyering@lucent.com>
162766         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
162767         * m4/chown.m4: Rename conftestchown to conftest.chown.
162768         * m4/rename.m4: s/conftestdir/conftest.d1/ and
162769         s/conftestdir2/conftest.d2/.
162770         * m4/utimes.m4: s/conftestdata/conftest.data/
162771         Inspired by Pavel Roskin's change in autoconf.
162773 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
162775         * lib/config.charset: Update for FreeBSD 4.2.
162777 2001-01-27  Jim Meyering  <meyering@lucent.com>
162779         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
162780         a use of AS_IF.
162781         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
162783 2001-01-26  Jim Meyering  <meyering@lucent.com>
162785         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
162786         quotearg.c includes it.
162788 2001-01-26  Jim Meyering  <meyering@lucent.com>
162790         * lib/quotearg.c: Include stddef.h.
162791         * lib/quote.c: Include stddef.h.
162792         Reported by Axel Kittenberger.
162794         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
162795         line in double quotes so that it evokes a better diagnostic.
162796         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
162797         Reported by Axel Kittenberger.
162799 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
162801         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
162802         as if it was a `charset'.
162804 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
162806         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
162807         has const.
162809 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
162811         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
162812         to avoid a warning.  Add back 'const' to inptr.
162814 2001-01-20  Jim Meyering  <meyering@lucent.com>
162816         Be sure that headers are checked before used in code compiled
162817         for the type checks.
162818         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
162819         In place of that, invoke jm_CHECK_ALL_TYPES.
162820         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
162821         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
162822         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
162823         The check for ssize_t was mistakenly run before the test for unistd.h.
162825         The configure-time check for stdbool.h was missing.
162826         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
162827         (jm_PREREQ_HASH): New function.
162829 2001-01-17  Jim Meyering  <meyering@lucent.com>
162831         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
162832         for autoconf-2.49c.
162833         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
162835 2001-01-16  Jim Meyering  <meyering@lucent.com>
162837         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
162838         From Bruno Haible.
162840 2001-01-14  Jim Meyering  <meyering@lucent.com>
162842         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
162843         foo and bar.  Create conftestdir/ in the script, not in the C code.
162844         Remove directories in the script, not in the C code.
162845         Remove conftestdir{,2} before trying to create the directory.
162846         Make the entire configure script fail if the mkdir fails.
162848 2001-01-14  Jim Meyering  <meyering@lucent.com>
162850         * lib/rename.c: New file.  From Volker Borchert.
162851         Include stdlib.h, string.h or strings.h, and xalloc.h.
162852         Use strip_trailing_slashes rather than open-coding it.
162854 2001-01-03  Paul Eggert  <eggert@twinsun.com>
162856         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
162858 2001-01-03  Jim Meyering  <meyering@lucent.com>
162860         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
162861         of local `inptr' to avoid warning with some system declarations of
162862         iconv.
162864 2001-01-02  Volker Borchert  <bt@teknon.de>
162866         * m4/rename.m4: New file.
162867         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
162869 2001-01-01  Jim Meyering  <meyering@lucent.com>
162871         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
162872         even on systems with utmpx.h.  It's necessary for the declaration of
162873         utmp's ut_user member.  Reported by Andreas Jaeger.
162875         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
162876         available. They are required for the declarations of getgrgid and
162877         getpwuid resp.
162878         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
162879         Reported by Andreas Jaeger.
162881 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
162883         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
162884         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
162885         so `make install' also works in VPATH builds.
162887 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
162889         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
162890         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
162891         can be used in subdirectories.
162893 2000-12-29  Paul Eggert  <eggert@twinsun.com>
162895         * lib/modechange.c: Do not assume that mode_t uses the
162896         traditional octal encoding.  E.g. "chmod 1 FOO" should set
162897         the other-execute bit of FOO even if S_IXOTH != 1.
162899         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
162900         WOTH, XOTH, ALLM): New macros.
162901         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
162902          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
162903         Use them.
162904         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
162905         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
162906         (mode_compile):
162907         No need to use uintmax_t; unsigned long is long enough.
162908         Don't bother to get suffix since we don't use it.
162910 2000-12-26  Jim Meyering  <meyering@lucent.com>
162912         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
162913         better with autoheader.
162915 2000-12-24  Jim Meyering  <meyering@lucent.com>
162917         * lib/hash.c (is_prime): Return explicit boolean values.
162918         (hash_get_first): Return NULL to appease Irix5.6's 89.
162919         Reported by Nelson Beebe.
162921 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
162923         * lib/localcharset.c (locale_charset): Add support for Win32.
162925 2000-12-18  Paul Eggert  <eggert@twinsun.com>
162927         * lib/physmem.h, lib/physmem.c: New files.
162929         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
162930         (noinst_HEADERS): Add physmem.h.
162932         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
162933         't' for compatibility with Solaris 8 sort.
162935 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
162937         * lib/config.charset: Add support for BeOS.
162939 2000-12-17  Jim Meyering  <meyering@lucent.com>
162941         * m4/dos.m4 (jm_AC_DOS): New file and macro.
162942         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
162944 2000-12-16  Jim Meyering  <meyering@lucent.com>
162946         This bug had a serious impact on chown: `chown N:M FILE' (for integer
162947         N and M) would have treated it like `chown N:N FILE'.
162949         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
162951 2000-12-16  Jim Meyering  <meyering@lucent.com>
162953         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
162954         SHELLS_FILE to a file name that's useful on djgpp systems.
162955         Include stdlib.h.
162956         (ADDITIONAL_DEFAULT_SHELLS): Define.
162957         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
162958         Based mostly on a patch from Prashant TR.
162960 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
162962         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
162963         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
162964         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
162966 2000-12-08  Andreas Schwab  <schwab@suse.de>
162968         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
162969         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
162971 2000-12-07  Jim Meyering  <meyering@lucent.com>
162973         * lib/stripslash.c (ISSLASH): Define.
162974         (strip_trailing_slashes): Use ISSLASH rather than comparing against
162975         `/'.
162976         From Prashant TR.
162978         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
162979         (dir_name_r): Declare this function as static.
162980         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
162981         manifest itself on a name containing a mix of slashes and
162982         backslashes.
162983         Make this function work with names starting with a DOS-style
162984         drive letter and colon prefix.
162985         (dir_name): Append `.' if necessary.
162986         Based mostly on patches from Prashant TR and Eli Zaretskii.
162988         * lib/dirname.h (dir_name_r): Remove prototype.
162990 2000-12-06  Paul Eggert  <eggert@twinsun.com>
162992         * m4/off_t-format.m4: Remove this file.
162993         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
162995 2000-12-06  Jim Meyering  <meyering@lucent.com>
162997         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
162998         replacement strtoull, we may well need the replacement strtoul, too.
162999         Check for declarations of strtoul and strtoull.
163000         Check for strtol.  Mainly as a cue to cause automake to include
163001         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
163002         Check for limits.h -- strtol.c needs it.
163004 2000-12-05  Jim Meyering  <meyering@lucent.com>
163006         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
163008 2000-12-04  Jim Meyering  <meyering@lucent.com>
163010         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
163011         Also include memory.h, stdlib.h, unistd.h if appropriate.
163012         Reported by Andreas Jaeger (conflicting declaration of malloc).
163014 2000-12-02  Jim Meyering  <meyering@lucent.com>
163016         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
163017         * m4/jm-macros.m4 (jm_MACROS): require it.
163019 2000-12-02  Jim Meyering  <meyering@lucent.com>
163021         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
163023 2000-12-01  Paul Eggert  <eggert@twinsun.com>
163025         * lib/memrchr.c: Include <config.h> before any system include file.
163027 2000-11-30  Jim Meyering  <meyering@lucent.com>
163029         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
163031 2000-11-30  Jim Meyering  <meyering@lucent.com>
163033         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
163035 2000-11-29  Paul Eggert  <eggert@twinsun.com>
163037         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
163039 2000-11-26  Jim Meyering  <meyering@lucent.com>
163041         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
163043 2000-11-22  Paul Eggert  <eggert@twinsun.com>
163045         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
163046         size of (size_t) -1; it's not portable.
163048 2000-11-17  Jim Meyering  <meyering@lucent.com>
163050         * lib/strstr.c: Update from GNU libc.
163052 2000-11-17  Akim Demaille  <akim@epita.fr>
163054         * lib/obstack.h: Formatting changes.
163055         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
163056         prevent type checking.
163057         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
163058         cast the value to (void *): assigning a `foo *' to a `void *'
163059         variable is valid.
163060         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
163062 2000-11-16  Jim Meyering  <meyering@lucent.com>
163064         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
163066 2000-11-11  Jim Meyering  <meyering@lucent.com>
163068         * lib/error.c: Add a couple #includes, merging from GNU libc version.
163070 2000-11-10  Jim Meyering  <meyering@lucent.com>
163072         * lib/obstack.h: Update from GNU libc.
163073         * lib/obstack.c: Likewise.
163075 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
163077         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
163079 2000-11-06  Paul Eggert  <eggert@twinsun.com>
163081         * lib/getusershell.c (setusershell): Use rewind rather than
163082         fseek/fseeko, to avoid configuration hassles with fseeko.
163083         Don't bother opening SHELLS_FILE if shellstream is NULL;
163084         it's not necessary.
163086 2000-11-05  Jim Meyering  <meyering@lucent.com>
163088         * lib/makepath.h (make_dir): Declare.
163089         * lib/makepath.c (make_dir): Remove `static' attribute.
163090         Tweak a comment.
163092 2000-11-04  Jim Meyering  <meyering@lucent.com>
163094         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
163096 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
163098         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
163099         last one in a bucket, advance to the next bucket.
163101 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
163103         * lib/fnmatch.c: Do not comment out all the code if we are using
163104         the GNU C library, because in some cases we are replacing buggy
163105         code in the GNU C library itself.
163107 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
163109         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
163110         (regex_compile): Catch bogus \(\1\).
163112 2000-10-30  Paul Eggert  <eggert@twinsun.com>
163114         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
163115         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
163116         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
163118 2000-10-30  Paul Eggert  <eggert@twinsun.com>
163120         * lib/error.h, getline.h, modechange.h:
163121         Remove "2000" from Copyright line, as the file hasn't been
163122         changed this year other than in the copyright notice.
163124         * lib/xalloc.h: Add "2000" to Copyright line, as this file
163125         was changed this year.
163127 2000-10-29  Jim Meyering  <meyering@lucent.com>
163129         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
163130         renaming.
163131         * m4/ls-mntd-fs.m4: Likewise
163133 2000-10-29  Jim Meyering  <meyering@lucent.com>
163135         * lib/xstat.in: Fix grammar in comment.
163137 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
163139         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
163140         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
163141         doesn't define __restrict_arr.
163143 2000-10-28  Jim Meyering  <meyering@lucent.com>
163145         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
163146         (jm_PREREQ_MEMCHR): New function.
163148 2000-10-28  Jim Meyering  <meyering@lucent.com>
163150         * lib/memchr.c: Update from libc.
163151         Adjust for portability:
163152         [HAVE_STDLIB_H]: Include stdlib.h.
163153         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
163154         Undef __memchr, too.
163155         [!weak_alias]: Define __memchr to memchr.
163157         * lib/regex.c: Update from libc.
163158         * lib/regex.h: Likewise.
163159         * lib/getopt1.c: Likewise.
163160         * lib/memcmp.c: Likewise.
163162         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
163163         Avoid using fseek, when possible -- it's broken by design.
163164         Patch by Ulrich Drepper.
163166 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
163168         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
163169         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
163170         Giving in to popular pressure to shut up the compiler with casts.
163172 2000-10-26  Jim Meyering  <meyering@lucent.com>
163174         * lib/strftime.c: Update from libc.
163176 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
163178         * regex.c: More `unsigned char' -> `re_char' changes.
163179         Also change several `int' into `re_wchar_t'.
163180         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
163181         (PUSH_FAILURE_POINTER): Don't cast any more.
163182         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
163183         We want GCC to complain, since this piece of code makes
163184         re_match non-reentrant, which *should* be fixed.
163185         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
163186         (EXTEND_BUFFER): Use RETALLOC.
163187         (SET_LIST_BIT): Don't cast.
163188         (re_wchar_t): New type.
163189         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
163190         that those two functions will always properly return.
163191         (IMMEDIATE_QUIT_CHECK): Cast to void.
163192         (analyse_first): Use recursion rather than an explicit stack.
163193         (re_compile_fastmap): Can't fail anymore.
163194         (re_search_2): Don't check re_compile_fastmap for failure.
163195         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
163196         Now also sets the new value (passed in a new argument).
163197         (re_match_2_internal): Use it.
163198         Also, use a new var `reg' of type size_t when looping through regs
163199         rather than reuse the inappropriate `mcnt'.
163201 2000-10-25  Jim Meyering  <meyering@lucent.com>
163203         * lib/obstack.c: Update from libc.
163205 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
163207         * regex.c (regex_compile): Change the way of handling a range from
163208         a char less than 256 to a char not less than 256.
163210 2000-10-24  Andrew Innes  <andrewi@gnu.org>
163212         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
163213         NT-Emacs only.
163214         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
163215         so that re_search functions only quit when callers expect them to.
163217 2000-10-23  Jim Meyering  <meyering@lucent.com>
163219         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
163220         wrong.  That set_locale call must not have any side effects.
163221         From Paul Eggert.
163223 2000-10-22  Jim Meyering  <meyering@lucent.com>
163225         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
163226         [CYCLIC]: Remove now-unused definition.
163228         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
163229         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
163230         Suggestion from Ulrich Drepper.
163232 2000-10-21  Jim Meyering  <meyering@lucent.com>
163234         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
163235         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
163236         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
163238 2000-10-21  Jim Meyering  <meyering@lucent.com>
163240         * lib/dirname.c (memrchr): Declare if necessary.
163241         (dir_name): Remove the restriction that there be no
163242         trailing slashes.  Now, this code skips past them, effectively
163243         ignoring them.
163244         [TEST_DIRNAME] (main): New unit tests.
163246         * lib/memrchr.c: New file from GNU libc.
163247         Undef __memrchr, too.
163248         [!weak_alias]: Define __memrchr to memrchr.
163249         Guard weak_alias use with `#ifdef weak_alias'.
163251 2000-10-21  Jim Meyering  <meyering@lucent.com>
163253         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
163254         (dir_name): Use dir_name_r.
163255         * lib/dirname.h (dir_name_r): Declare it.
163257 2000-10-17  Jim Meyering  <meyering@lucent.com>
163259         * lib/quote.h (PARAMS): Define and use.
163260         Reported by Akim Demaille.
163262         * lib/getopt.c: Update from libc.
163264 2000-10-16  Jim Meyering  <meyering@lucent.com>
163266         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
163267         setlocale.
163268         From Jan Fedak.
163270 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
163272         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
163274 2000-09-25  Jim Meyering  <meyering@lucent.com>
163276         * lib/md5.h (rol): Define (from GnuPG).
163278         * lib/sha.c: Give credit (GnuPG) where due.
163279         (M): Use rol rather than open-coding it.
163280         Add a FIXME comment.
163282 2000-09-21  Jim Meyering  <meyering@lucent.com>
163284         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
163285         Reported by Michael Stone.
163287 2000-09-20  Jim Meyering  <meyering@lucent.com>
163289         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
163290         (noinst_HEADERS): Add sha.h.
163291         Based on code from Scott G. Miller and from GnuPG.
163293 2000-09-18  Jim Meyering  <meyering@lucent.com>
163295         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
163296         LIBS. Otherwise, everyone ends up linking with -lelf for some
163297         configurations.
163298         Reported by Mike Stone.
163300 2000-09-15  Jim Meyering  <meyering@lucent.com>
163302         * lib/regex.c: Update from libc.
163304 2000-09-10  Jim Meyering  <meyering@lucent.com>
163306         * lib/getopt.c (_getopt_internal): Update from glibc.
163308 2000-09-09  Jim Meyering  <meyering@lucent.com>
163310         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
163311         think it should be used as a general replacement for isascii.
163312         * lib/fnmatch.c: Likewise.
163313         * lib/mbswidth.c: Likewise
163314         * lib/regex.c: Likewise.
163316         Don't use atoi.
163317         * lib/userspec.c: Include sys/param.h and limits.h.
163318         Include xstrtol.h.
163319         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
163320         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
163321         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
163322         UID, GID.  Check range.
163324 2000-09-06  Jim Meyering  <meyering@lucent.com>
163326         * lib/getopt.c (_getopt_internal): Update from glibc.
163328 2000-08-30  Jim Meyering  <meyering@lucent.com>
163330         * lib/strftime.c: Merge in changes from GNU libc.
163332 2000-08-26  Jim Meyering  <meyering@lucent.com>
163334         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
163335         * m4/fpending.m4: New file.
163337 2000-08-26  Jim Meyering  <meyering@lucent.com>
163339         * lib/closeout.c: Include "__fpending.h".
163340         (close_stdout_status): Return right away if there's nothing to flush.
163342         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
163343         * lib/__fpending.c: New file.
163344         * lib/__fpending.h: New file.
163346 2000-08-20  Jim Meyering  <meyering@lucent.com>
163348         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
163349         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
163350         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
163352 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
163354         Improve fileutils installation on systems where running
163355         programs (like install) can't be unlinked.
163356         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
163357         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
163359 2000-08-07  Paul Eggert  <eggert@twinsun.com>
163361         Standardize on "memory exhausted" instead of "Memory exhausted"
163362         or "virtual memory exhausted".
163363         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
163364         "virtual memory exhausted".
163365         * lib/same.c (same_name): Invoke xalloc_die instead of printing
163366         our own message.
163367         * lib/userspec.c (parse_user_spec): Likewise.
163368         * lib/bumpalloc.h: comment fix
163369         * lib/same.c, userspec.c: Include xalloc.h.
163371         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
163372         not char *const and pointing to a constant array.
163373         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
163374         (xrealloc): Comment fix.
163376         * lib/userspec.c (parse_user_spec):
163377         Don't translate a message until just before returning,
163378         to avoid unnecessary translation.
163380 2000-08-07  Jim Meyering  <meyering@lucent.com>
163382         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
163383         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
163384         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
163385         getgroups.c, gethostname.c, getopt.h, group-member.c,
163386         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
163387         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
163388         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
163389         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
163390         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
163391         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
163392         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
163393         yesno.c: Back out Copyright date changes for each file with no change
163394         this year.  This eases coordination with other programs using the same
163395         source code modules.  From Paul Eggert.
163397 2000-08-06  Paul Eggert  <eggert@twinsun.com>
163399         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
163400         not char, for compatibility with glibc 2.1.3 strftime.c.
163402 2000-08-03  Greg McGary  <greg@mcgary.org>
163404         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
163405         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
163406         (EXTEND_BUFFER): Use them.
163408 2000-08-01  Jim Meyering  <meyering@lucent.com>
163410         * lib/dirname.c (ISSLASH): Define.
163411         (BACKSLASH_IS_PATH_SEPARATOR): Define.
163412         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
163413         both `\' and `/' may be use as path separators.
163414         Based on a patch from Prashant TR.
163416 2000-07-31  Paul Eggert  <eggert@twinsun.com>
163418         * lib/quotearg.c (quotearg_n_options): Don't make the initial
163419         slot vector a constant, since it might get modified.
163421 2000-07-31  Jim Meyering  <meyering@lucent.com>
163423         * lib/xmalloc.c: Use `virtual memory exhausted', not
163424         `Memory exhausted'.
163425         * lib/obstack.c (print_and_abort): Likewise.
163427 2000-07-30  Paul Eggert  <eggert@twinsun.com>
163429         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
163430         buffer, so that the caller can always quote one small
163431         component of a "memory exhausted" message in slot 0.
163432         From a suggestion by Jim Meyering.
163434 2000-07-30  Jim Meyering  <meyering@lucent.com>
163436         * lib/makepath.c (make_path): Quote the other instance, too.
163438         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
163439         (STATIC_BUF_SIZE): Define.
163440         (quotearg_n_options): Use only statically allocated storage when
163441         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
163442         than STATIC_BUF_SIZE.
163444 2000-07-29  Jim Meyering  <meyering@lucent.com>
163446         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
163447         * lib/dirname.c (dir_name): Likewise.
163449         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
163450         `/'.
163452         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
163453         (dir_name): Assert that there are no trailing slashes.
163455 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
163457         * lib/mbswidth.h (mbswidth): Add a flags argument.
163458         (mbswidth): New declaration.
163459         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
163460         * lib/mbswidth.c (mbswidth): Add a flags argument.
163461         (mbsnwidth): New function.
163463 2000-07-24  Jim Meyering  <meyering@lucent.com>
163465         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
163467 2000-07-23  Paul Eggert  <eggert@twinsun.com>
163469         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
163471 2000-07-23  Paul Eggert  <eggert@twinsun.com>
163473         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
163474         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
163475         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
163476         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
163477         invoke multibyte primitives.
163479 2000-07-23  Paul Eggert  <eggert@twinsun.com>
163481         * lib/quotearg.c:
163482         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
163483         so that mbstate_t is always defined.
163485         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
163486         be 1 in at least one GCC installation, and this configuration
163487         error is likely to be common.  Ignoring MB_LEN_MAX hurts
163488         performance on hosts that have mbrtowc but have only unibyte
163489         locales, but I assume these hosts are rare.
163491 2000-07-23  Paul Eggert  <eggert@twinsun.com>
163493         * lib/mbswidth.c (_XOPEN_SOURCE):
163494         Don't define; this causes problems on Solaris 7.
163495         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
163497 2000-07-23  Jim Meyering  <meyering@lucent.com>
163499         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
163500         too: getgrgid, getpwuid, getuid.
163502 2000-07-23  Jim Meyering  <meyering@lucent.com>
163504         * lib/basename.c (base_name): Add an assertion.
163506 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
163508         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
163509         shadow its mbsinit function.
163511 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
163513         * lib/mbswidth.h: New file.
163514         * lib/mbswidth.c: New file.
163515         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
163516         (noinst_HEADERS): Add mbswidth.h.
163518 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
163520         * lib/config.charset: Add support for FreeBSD. Improve support for
163521         HP-UX and IRIX 6.
163523 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
163525         * m4/mbswidth.m4: New file.
163526         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
163528 2000-07-15  Jim Meyering  <meyering@lucent.com>
163530         * lib/makepath.c: Include quote.h.
163531         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
163532         corresponding argument in a `quote (...)' call.
163533         Give better diagnostics.
163535         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
163536         (noinst_HEADERS): Add quote.h.
163538         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
163539         from tar's src/misc.c.
163540         * lib/quote.h: New file.  Prototypes for same.
163542 2000-07-14  Paul Eggert  <eggert@twinsun.com>
163544         From a suggestion by Bruno Haible.
163545         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
163546         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
163547         to decide whether to define the BeOS workaround macro;
163548         this adjusts to the change to AC_MBSTATE_T.
163550 2000-07-14  Jim Meyering  <meyering@lucent.com>
163552         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
163553         jm_AC_TYPE_UINTMAX_T.
163555 2000-07-13  Paul Eggert  <eggert@twinsun.com>
163557         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
163559         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
163560         quotearg_buffer_restyled): Add support for
163561         clocale_quoting_style.  Undo previous change to
163562         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
163563         and "{RIGHT QUOTATION MARK}" msgids.
163565 2000-07-10  Paul Eggert  <eggert@twinsun.com>
163567         From a suggestion by Bruno Haible.
163568         * m4/mbstate_t.m4 (AC_MBSTATE_T):
163569         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
163570         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
163571         and mbstate_t, to a single-part test that simply defines mbstate_t.
163572         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
163573         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
163575 2000-07-10  Jim Meyering  <meyering@lucent.com>
163577         * m4/strerror_r.m4: Mirror the correction made in autoconf.
163579         * m4/gnu-source.m4: Output to confdefs.h directly.
163580         Suggestion from Akim Demaille.
163582 2000-07-09  Paul Eggert  <eggert@twinsun.com>
163584         The old behavior of quoting `like this' doesn't look good with
163585         newer, ISO-style fonts.  See:
163586         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
163588         Instead, quote "like this" by default.  Let the translator
163589         tailor the locale-specific quoting behavior by providing
163590         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
163592         * lib/quotearg.c (N_): New macro.
163593         (gettext_default): New function.
163594         (quotearg_buffer_restyled): Use
163595         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
163596         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
163598 2000-07-09  Jim Meyering  <meyering@lucent.com>
163600         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
163601         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
163603         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
163604         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
163606 2000-07-09  Jim Meyering  <meyering@lucent.com>
163608         * lib/Most files: Update copyright dates to include 2000.
163610 2000-07-08  Jim Meyering  <meyering@lucent.com>
163612         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
163613         if not defined.
163614         (xgethostname): Remove now-unnecessary #ifdef.
163615         Move declaration of `err' into loop where it's used.
163617 2000-07-05  Paul Eggert  <eggert@twinsun.com>
163618         and Bruno Haible  <haible@clisp.cons.org>
163620         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
163621         only if the test for an object-type mbstate_t fails.  This
163622         prevents us from mistakenly reporting that mbstate_t is a
163623         system object type after we "#define mbstate_t int" to work
163624         around its lack.
163626 2000-07-05  Paul Eggert  <eggert@twinsun.com>
163627         and Bruno Haible  <haible@clisp.cons.org>
163629         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
163631 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
163633         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
163634         to strerror_r.
163635         Include <ctype.h> for use of isalpha.
163637 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
163639         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
163640         by allocating a larger buffer. Test the gethostname return value for
163641         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
163642         returns an error and ENAMETOOLONG isn't defined.
163644 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
163646         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
163647         dimension.
163649 2000-07-04  Jim Meyering  <meyering@lucent.com>
163651         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
163652         of the deprecated AC_CHECKING.
163654 2000-07-04  Jim Meyering  <meyering@lucent.com>
163656         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
163657         Reported by Bruno Haible.
163659 2000-07-04  Jim Meyering  <meyering@lucent.com>
163661         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
163662         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
163663         lacks mbrtowc.
163665 2000-07-03  Paul Eggert  <eggert@twinsun.com>
163667         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
163668         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
163670 2000-07-03  Paul Eggert  <eggert@twinsun.com>
163671         and Bruno Haible  <haible@clisp.cons.org>
163673         * lib/quotearg.c (mbrtowc):
163674         Assign to *pwc, and return 1 only if result is nonzero.
163675         (iswprint): Use ISPRINT when substituting our own mbrtowc.
163677 2000-07-03  Jim Meyering  <meyering@lucent.com>
163679         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
163681 2000-07-03  Jim Meyering  <meyering@lucent.com>
163683         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
163684         This is necessary to get a definition of e.g., UTMP_FILE on
163685         HP-UX 10.20.
163686         From Bob Proulx.
163688 2000-07-02  Jim Meyering  <meyering@lucent.com>
163690         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
163692         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
163693         AC_LIBOBJ(function_name).
163694         * m4/chown.m4: Likewise.
163695         * m4/fnmatch.m4: Likewise.
163696         * m4/ftruncate.m4: Likewise.
163697         * m4/getgroups.m4: Likewise.
163698         * m4/getline.m4: Likewise.
163699         * m4/group-member.m4: Likewise.
163700         * m4/jm-macros.m4: Likewise.
163701         * m4/lstat.m4: Likewise.
163702         * m4/malloc.m4: Likewise.
163703         * m4/memcmp.m4: Likewise.
163704         * m4/nanosleep.m4: Likewise.
163705         * m4/putenv.m4: Likewise.
163706         * m4/realloc.m4: Likewise.
163707         * m4/regex.m4: Likewise.
163708         * m4/stat.m4: Likewise.
163709         * m4/strftime.m4: Likewise.
163711 2000-07-02  Jim Meyering  <meyering@lucent.com>
163713         * lib/quotearg.c (mbstate_t): Don't define here.
163715 2000-07-02  Jim Meyering  <meyering@lucent.com>
163717         * lib/nanosleep.c (SIGCONT): Define if not already defined.
163719 2000-07-01  Jim Meyering  <meyering@lucent.com>
163721         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
163723 2000-07-01  Jim Meyering  <meyering@lucent.com>
163725         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
163726         problem.
163728 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
163730         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
163731         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
163733 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
163735         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
163736         per change in ../m4/ls-mntd-fs.m4.
163737         (read_filesystem_list): Ignore symbolic links.
163739 2000-06-29  Jim Meyering  <meyering@lucent.com>
163741         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
163742         for declaration of strcmp.
163744         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
163746         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
163747         Avoid warning by casting result to `char *' to remove `const'.
163749 2000-06-28  Jim Meyering  <meyering@lucent.com>
163751         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
163752         included by quotearg.c, for which we perform this test.  From
163753         Bruno Haible.
163755 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
163757         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
163758         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
163759         <utmpx.h> exists, put readutmp.o into LIBOBJS.
163761 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
163763         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
163765 2000-06-26  Paul Eggert  <eggert@twinsun.com>
163767         savedir now sets errno on failure and invokes xmalloc to get memory.
163768         Fix a couple of other minor bugs while we're at it.
163770         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
163771         (NAMLEN): Remove macro.
163772         (malloc, realloc): Remove decls.
163773         (stpcpy): Likewise.
163774         ("xalloc.h"): Include.
163775         (NAME_SIZE_DEFAULT): New macro.
163776         (savedir): Use xmalloc / xrealloc to allocate memory.
163777         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
163778         Skip "" directory entries.
163779         Use strlen to calculate directory entry length, since the old method
163780         is rarely used these days and isn't worth supporting.
163781         Don't use a pointer after freeing it.
163782         Check for integer overflow when calculating allocation size.
163783         Use memcpy to copy entries, instead of stpcpy.
163784         Set errno properly when returning NULL.
163785         Check for readdir error.
163787 2000-06-26  Jim Meyering  <meyering@lucent.com>
163789         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
163791 2000-06-25  Jim Meyering  <meyering@lucent.com>
163793         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
163794         Linux header bug when _XOPEN_SOURCE is defined to 500.
163796 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
163798         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
163799         deficiency.
163801 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
163803         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
163804         Include xalloc.h.
163805         Don't include <stdlib.h>.  Don't declare malloc, realloc.
163807 2000-06-24  Jim Meyering  <meyering@lucent.com>
163809         * m4/strerror_r.m4: Revive this file -- to try out an experimental
163810         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
163811         for which strerror does return char*, but which lacks a conveniently
163812         accessible declaration of the function.  If the compile-test says
163813         strerror_r doesn't work, then resort to a `run'-test that works on
163814         BeOS and segfaults on DEC Unix.
163816 2000-06-24  Jim Meyering  <meyering@lucent.com>
163818         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
163820 2000-06-23  Paul Eggert  <eggert@twinsun.com>
163822         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
163823         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
163825 2000-06-23  Paul Eggert  <eggert@twinsun.com>
163827         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
163828         (mbrtowc, mbstate_t): Define substitutes if
163829         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
163830         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
163831         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
163833 2000-06-23  Jim Meyering  <meyering@lucent.com>
163835         * m4/afs.m4: Add missing AC_MSG_RESULT.
163836         Reported by Bruno Haible.
163838         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
163839         Suggestion from Bruno Haible.
163841 2000-06-23  Jim Meyering  <meyering@lucent.com>
163843         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
163845 2000-06-21  Jim Meyering  <meyering@lucent.com>
163847         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
163849 2000-06-21  Jim Meyering  <meyering@lucent.com>
163851         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
163852         (noinst_HEADERS): Add getstr.h.
163854         * lib/getline.c (getstr): Move into a separate file.
163855         * lib/getstr.c (getstr): New file, extracted from getline.c, with
163856         the following changes: new parameter, delim2; both delim[12]
163857         parameters have type `int', not `char'.  The latter would lose
163858         with 8-bit delimiters.
163859         * lib/getstr.h: New file.
163861 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
163863         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
163864         than 1024, return a memory chunk of least possible size, instead
163865         of size PATH_MAX + 2. In the loop, increment the size proportionally.
163866         Use free/xmalloc instead of xrealloc to avoid copying for very long
163867         paths.
163869 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
163871         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
163872         the empty string.
163874 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
163876         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
163877         address, not strdup.  Include <stdlib.h> and don't declare free().
163879 2000-06-19  Jim Meyering  <meyering@lucent.com>
163881         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
163883 2000-06-18  Jim Meyering  <meyering@lucent.com>
163885         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
163887         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
163888         `checking whether...' message to be consistent with that of the
163889         lstat test.
163891 2000-06-18  Jim Meyering  <meyering@lucent.com>
163893         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
163894         Besides, these days every porting target provides a mkdir function.
163896         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
163897         needed. (this snippet comes from src/system.h).
163899 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
163901         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
163903 2000-06-15  Paul Eggert  <eggert@twinsun.com>
163905         * lib/human.c (adjust_value): New function.
163906         (human_readable_inexact): Apply rounding style even when
163907         printing approximate values.
163909 2000-06-14  Paul Eggert  <eggert@twinsun.com>
163911         * lib/human.c (human_readable_inexact): Allow an input block
163912         size that is not a multiple of the output block size, and vice versa.
163913         Reported by Piergiorgio Sartor.
163915 2000-06-14  Paul Eggert  <eggert@twinsun.com>
163917         * lib/getdate.y (get_date): Apply relative times after time
163918         zone indicator, not before.  Reported by Todd A. Jacobs.
163920 2000-06-13  Jim Meyering  <meyering@lucent.com>
163922         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
163924         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
163926 2000-06-12  Paul Eggert  <eggert@twinsun.com>
163928         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
163930 2000-06-12  Jim Meyering  <meyering@lucent.com>
163932         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
163933         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
163934         optional argument.
163935         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
163936         the optional argument, `lib'.
163938 2000-06-08  Jim Meyering  <meyering@lucent.com>
163940         * m4/largefile.m4: Remove file (now that it's part of autoconf).
163942 2000-06-04  Paul Eggert  <eggert@twinsun.com>
163944         Rewrite largefile configuration so that we don't need to run
163945         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
163946         AC_CANONICAL_HOST in configure.in -- jmm]
163948         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
163949         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
163950         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
163951         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
163952         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
163953         All uses changed.
163954         Instead of inspecting the output of getconf, try to compile the
163955         test program without and with the macro definition.
163956         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
163957         for getconf.  Instead, check for the needed flags by compiling
163958         test programs.
163960 2000-06-04  Paul Eggert  <eggert@twinsun.com>
163962         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
163964 2000-06-04  Jim Meyering  <meyering@lucent.com>
163966         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
163967         SunOS 4.1.4 for which gid_t is an unsigned type.
163969 2000-06-03  Jim Meyering  <meyering@lucent.com>
163971         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
163972         now that autoconf requires that.
163974         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
163975         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
163976         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
163978 2000-06-03  Jim Meyering  <meyering@lucent.com>
163980         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
163982 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
163984         * m4/glibc21.m4: New file.
163985         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
163987 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
163989         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
163990         newer, don't install charset.alias.
163991         * lib/config.charset: Change the Linux/glibc rules so they become empty
163992         on glibc-2.1 or newer.
163994 2000-06-02  Jim Meyering  <meyering@lucent.com>
163996         * lib/mountlist.c: Back out last change.  Instead, do this...
163997         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
163998         me_dummy member using the same `ignore'-testing code.
163999         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
164000         fs_type strings.
164001         From Mark D. Roth.
164003 2000-05-29  Jim Meyering  <meyering@lucent.com>
164005         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
164006         mounts with the `ignore' attribute.  Based on a patch from
164007         Mark D. Roth.
164009 2000-05-28  Jim Meyering  <meyering@lucent.com>
164011         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
164012         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
164013         * m4/stat.m4: Likewise.
164014         * m4/lstat.m4: Likewise.
164015         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
164017         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
164018         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
164020 2000-05-26  Jim Meyering  <meyering@lucent.com>
164022         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
164024 2000-05-24  Jim Meyering  <meyering@lucent.com>
164026         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
164027         autoconf requires that.
164028         * m4/lib-check.m4: Likewise.
164029         * m4/jm-macros.m4: Likewise.
164030         * m4/strftime.m4: Likewise.
164032         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
164033         AC_CHECK_DECLS, now that autoconf requires that.
164035 2000-05-22  Jim Meyering  <meyering@lucent.com>
164037         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
164038         * m4/lstat.m4: Likewise.
164040 2000-05-22  Jim Meyering  <meyering@lucent.com>
164042         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
164044 2000-05-20  Jim Meyering  <meyering@lucent.com>
164046         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
164047         (jm_PREREQ): Use it.
164049 2000-05-18  Jim Meyering  <meyering@lucent.com>
164051         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
164052         back, too, since it may have been modified by allocate_entry.
164053         (hash_delete): Rewrite to use neither the assignment operator
164054         nor the comma operator in an if-expression.
164056 2000-05-15  Paul Eggert  <eggert@twinsun.com>
164058         * lib/closeout.c:
164059         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
164060         Remove; no longer needed.
164061         "quotearg.h": Add include.
164062         (file_name): Do not bother to explicitly initialize to NULL; it's less
164063         efficient on some hosts.
164064         (close_stdout_status): Remove test as to whether stdout was already
164065         closed; it breaks for the case "echo x | sort >&-".
164066         Quote file name colons.
164067         Do not assume that _("write error") lacks format strings.
164069 2000-05-15  Jim Meyering  <meyering@lucent.com>
164071         * lib/version-etc.c (version_etc_copyright): Update the copyright
164072         string used in all --version output.
164074 2000-05-14  Jim Meyering  <meyering@lucent.com>
164076         * lib/closeout.c (close_stdout_set_file_name): New function.
164077         (close_stdout_status): Use new file-scoped global.
164078         Return right away if fstat says the stdout file descriptor is invalid.
164079         * lib/closeout.h (close_stdout_set_file_name): Declare.
164081 2000-05-10  Jim Meyering  <meyering@lucent.com>
164083         * lib/closeout.c [default_exit_status]: New file-scoped variable.
164084         (close_stdout_set_status): New function.
164085         * lib/closeout.h (close_stdout_set_status): Declare.
164087 2000-05-09  Jim Meyering  <meyering@lucent.com>
164089         * m4/gettext.m4: Rename this...
164090         * m4/libintl.m4: ...to this.
164092 2000-05-08  Jim Meyering  <meyering@lucent.com>
164094         * lib/long-options.c: Don't include closeout.h.
164095         (parse_long_options): Don't call close_stdout for --version.
164097 2000-05-06  Paul Eggert  <eggert@twinsun.com>
164099         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
164100         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
164101         2.1.3 bug.  This avoids a clash when files like regex.c define
164102         _GNU_SOURCE.
164104 2000-05-06  Jim Meyering  <meyering@lucent.com>
164106         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
164107         (AC_REPLACE_FUNCS): Add strnlen.
164109         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
164110         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
164112         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
164113         AC_SEARCH_LIBS call for nanosleep.
164114         (LIB_NANOSLEEP): Set and AC_SUBST.
164116 2000-05-06  Jim Meyering  <meyering@lucent.com>
164118         * lib/strnlen.c: Undefine __strnlen and strnlen.
164119         [!weak_alias]: Define __strnlen to strnlen.
164121         * lib/atexit.c: New file, from libiberty.
164123 2000-05-06  Jim Meyering  <meyering@lucent.com>
164125         * lib/closeout.c (close_stdout_status): Also check for errors on the
164126         stderr stream.
164128 2000-05-05  Jim Meyering  <meyering@lucent.com>
164130         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
164131         AC_SEARCH_LIBS call for clock_gettime.
164132         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
164134         * m4/search-libs.m4: Update from autoconf.
164136         su doesn't work on Solaris 2.6.
164137         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
164138         <shadow.h>.  Reported by Dragos Harabor.
164140 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
164142         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
164143         memcpy instead of xmalloc, xrealloc, path_concat.
164144         (locale_charset): Treat empty environment variables as absent.
164145         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
164147 2000-05-04  Jim Meyering  <meyering@lucent.com>
164149         * lib/getopt.c: Update from glibc.
164150         * lib/obstack.c: Likewise.
164151         * lib/obstack.h: Likewise.
164152         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
164153         file
164155         * lib/regex.h: Likewise.
164156         * lib/strndup.c: Likewise.
164157         * lib/strnlen.c: New file, from glibc.
164159 2000-05-03  Jim Meyering  <meyering@lucent.com>
164161         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
164163 2000-05-02  Paul Eggert  <eggert@twinsun.com>
164165         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
164166         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
164167         compile-time test, rather than inspecting host and OS, to
164168         decide whether to define _LARGEFILE_SOURCE.
164170 2000-05-01  Jim Meyering  <meyering@lucent.com>
164172         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
164174         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
164175         Based on a patch from Bruno Haible.
164177 2000-05-01  Jim Meyering  <meyering@lucent.com>
164179         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
164181 2000-04-29  Jim Meyering  <meyering@lucent.com>
164183         * lib/path-concat.c: Declare strdup only if it's not defined.
164184         * lib/canon-host.c: Likewise.
164186 2000-04-28  Jim Meyering  <meyering@lucent.com>
164188         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
164189         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
164190         is included first, then limits.h is included by locale.h by libintl.h.
164191         From John David Anglin.
164193 2000-04-25  Jim Meyering  <meyering@lucent.com>
164195         * lib/makepath.c (S_IRWXUGO): Define.
164196         (make_path): Always perform explicit chmod if MODE specifies any
164197         of the `special' permission bits.  Prompted by a bug report against
164198         install from Mate Wierdl and Joost van Baal.
164200 2000-04-18  Jim Meyering  <meyering@lucent.com>
164202         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
164203         (jm_PREREQ): Use it.
164205 2000-04-18  Jim Meyering  <meyering@lucent.com>
164207         * lib/README: New file.
164209         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
164210         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
164212 2000-04-17  Jim Meyering  <meyering@lucent.com>
164214         Get it right :-)
164215         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
164216         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
164217         Suggestion from Akim Demaille.
164219 2000-04-17  Jim Meyering  <meyering@lucent.com>
164221         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
164222         the definition of it to rpl_strftime also defined-away the system's
164223         declaration.
164225 2000-04-15  Jim Meyering  <meyering@lucent.com>
164227         Use `C' to denote so-called `contiguous' files, the same way
164228         that tar does.
164229         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
164230         (ftypelet): Use S_ISCTG.
164231         From Michael Deutschmann.
164233 2000-04-14  Jim Meyering  <meyering@lucent.com>
164235         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
164236         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
164237         clobbered.
164239 2000-04-14  Jim Meyering  <meyering@lucent.com>
164241         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
164243 2000-04-13  Jim Meyering  <meyering@lucent.com>
164245         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
164246         AH_VERBATIM to insert required #ifndef into config.h.in.
164247         Suggestion from Akim Demaille.
164249 2000-04-12  Jim Meyering  <meyering@lucent.com>
164251         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
164252         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
164253         Christian Krackowizer.
164255         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
164256         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
164257         (AC_SYS_LARGEFILE): Require.
164258         (AM_C_PROTOTYPES): Require.
164260 2000-04-08  Jim Meyering  <meyering@lucent.com>
164262         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
164263         names don't conflict.  Reported by Eli Zaretskii.
164265 2000-04-07  Jim Meyering  <meyering@lucent.com>
164267         * lib/putenv.c: Move inclusion of errno.h so it follows that of
164268         sys/types.h, to work around system header problems on AIX 3.2.5.
164269         From Bruno Haible.
164271 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
164273         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
164274         bug.  Deal with the different error behavior of Irix iconv.
164276 2000-04-05  Paul Eggert  <eggert@twinsun.com>
164278         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
164279         IRIX if the installer said otherwise.
164281 2000-04-05  Jim Meyering  <meyering@lucent.com>
164283         Portability tweaks required for ultrix4.3.
164284         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
164285         (jm_CHECK_DECLS): Add getutent to the list of functions.
164286         (_jm_DECL_HEADERS): Add utmpx.h.
164287         From John David Anglin.
164289         * m4/strftime.m4: Back out the 2000-04-02 change.
164290         Instead of that change, simply undefine putenv in the test program.
164292 2000-04-05  Jim Meyering  <meyering@lucent.com>
164294         Portability tweaks required for ultrix4.3.
164295         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
164296         getutent.
164297         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
164298         * lib/canon-host.c: Declare strdup.
164299         * lib/path-concat.c: Likewise.
164300         From John David Anglin.
164302 2000-04-04  Jim Meyering  <meyering@lucent.com>
164304         Be more DOS 8.3-friendly.
164305         * lib/ref-add.sin: Renamed from ref-add.sed.in.
164306         * lib/ref-del.sin: Renamed from ref-del.sed.in.
164307         * lib/Makefile.am: Reflect renaming.
164308         Reported by Eli Zaretskii.
164310         Use a temporary file name that won't clash with `charset.alias'
164311         in the DOS 8.3 name space.
164312         * lib/Makefile.am (charset_tmp): Define.
164313         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
164314         (uninstall-local): Likewise.
164315         Reported by Eli Zaretskii.
164317 2000-04-03  Jim Meyering  <meyering@lucent.com>
164319         * m4/gettext.m4: Fix typo in comment.
164321         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
164322         textutils/configure.in).  Suggestion from Paul Eggert.
164323         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
164325 2000-04-02  Paul Eggert  <eggert@twinsun.com>
164327         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
164328         variable in the shell rather than using putenv, which isn't
164329         portable.  This avoids the configure-time inter-test dependency
164330         on the potentially-renamed putenv function.
164332 2000-03-30  Paul Eggert  <eggert@twinsun.com>
164334         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
164335         before checking struct stat.st_blksize, so that
164336         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
164338 2000-03-29  Paul Eggert  <eggert@twinsun.com>
164340         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
164341         since strftime.c uses HAVE_STRFTIME to decide whether to use
164342         the underlying strftime.
164344 2000-03-29  Paul Eggert  <eggert@twinsun.com>
164346         * lib/time/strftime.c (my_strftime): Make sure we call the system
164347         strftime, not ourselves, when invoking the underlying strftime.
164349 2000-03-24  Jim Meyering  <meyering@lucent.com>
164351         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
164352         (charset_alias): Define.
164353         (install-exec-local): Factor out common code.
164354         (uninstall-local): Split lines longer than 80.
164355         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
164356         (SUFFIXES): Define.
164357         (.sed.in.sed): New rule.  Don't redirect directly to $@.
164358         (CLEANFILES): Add ref-add.sed and ref-del.sed.
164360 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
164362         * lib/config.charset: Output a line containing "Packages using this
164363         file".
164364         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
164365         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
164366         ref-del.sed): New rules.
164368 2000-03-17  Jim Meyering  <meyering@lucent.com>
164370         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
164371         Otherwise, include <strings.h>
164373 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
164375         * lib/unicodeio.c (utf8_wctomb): New function.
164376         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
164377         format instead of in UCS-4 with platform dependent endianness.
164379 2000-03-10  Jim Meyering  <meyering@lucent.com>
164381         * m4/lib-check.m4: Look for getspnam in -lgen, too.
164382         From Marco Franzen.
164384 2000-03-07  Paul Eggert  <eggert@twinsun.com>
164386         * lib/savedir.c (savedir): Work even if directory size is
164387         negative; this can happen with some screwy NFS configurations.
164389 2000-03-06  Jim Meyering  <meyering@lucent.com>
164391         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
164392         if it's NULL (because we ran out of memory).  From Bruno Haible.
164394 2000-03-05  Jim Meyering  <meyering@lucent.com>
164396         * lib/localcharset.c ("path-concat.h"): Include.
164397         (get_charset_aliases): Use path_concat instead of ANSI string
164398         concatenation.
164400         * lib/unicodeio.h (PARAMS): Define.
164401         Use it to guard prototype.
164403 2000-03-04  Jim Meyering  <meyering@lucent.com>
164405         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
164406         for lib/localcharset.c.
164408 2000-03-04  Jim Meyering  <meyering@lucent.com>
164410         * lib/Makefile.am (install-exec-local): Create $(libdir) before
164411         installing into it.
164412         (uninstall-local): Uncomment this rule so `make distcheck' works
164413         once again.
164415         * lib/unicodeio.c (<errno.h>): Include it.
164416         (errno): Declare if not defined.
164418         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
164420         * lib/config.charset: New version, incorporating remarks from a linux
164421         i18n mailing list.  From Bruno Haible.
164423 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
164425         * m4/codeset.m4: New file.
164426         * m4/iconv.m4: New file.
164427         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
164429 2000-03-03  Jim Meyering  <meyering@lucent.com>
164431         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
164433 2000-03-02  Jim Meyering  <meyering@lucent.com>
164435         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
164436         the messages come out on separate lines.
164438         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
164439         rather than jm_CHECK_DECLARATIONS.
164440         * m4/decl.m4: Remove now-unused file.
164442         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
164443         geteuid.
164445 2000-03-02  Jim Meyering  <meyering@lucent.com>
164447         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
164449 2000-03-01  Jim Meyering  <meyering@lucent.com>
164451         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
164452         * lib/unicodeio.c: Likewise.
164454 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
164456         * lib/config.charset: New file.
164457         * lib/localcharset.c: New file.
164458         * lib/unicodeio.h, lib/unicodeio.c: New files.
164459         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
164460         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
164461         (noinst_HEADERS): Add unicodeio.h.
164462         (all-local, install-exec-local, charset.alias): New targets.
164464 2000-02-28  Paul Eggert  <eggert@twinsun.com>
164466         * lib/quotearg.c (ALERT_CHAR): New macro.
164467         (quotearg_buffer_restyled): Use it.
164469 2000-02-27  Jim Meyering  <meyering@lucent.com>
164471         * m4/check-decl.m4: Add getenv to the list.
164473 2000-02-27  Jim Meyering  <meyering@lucent.com>
164475         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
164476         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
164478         * lib/backupfile.c: Guard inclusion of stdlib.h with
164479         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
164480         Declare malloc if needed.
164482         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
164483         `#ifndef HAVE_DECL..'
164484         now that autoconf always defines the HAVE_DECL_ symbols.
164485         * lib/human.c: Likewise.
164486         * lib/same.c: Likewise.
164487         * lib/strtoumax.c: Likewise.
164489         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
164490         declaration check was not run.
164491         * lib/hash.c: Likewise.
164492         * lib/human.c: Likewise.
164493         * lib/same.c: Likewise.
164494         * lib/strtoumax.c: Likewise.
164496         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
164497         `.', then first look up the entire `.'-containing string as a login
164498         name.
164500 2000-02-23  Jim Meyering  <meyering@lucent.com>
164502         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
164503         in place of my hack.
164505 2000-02-18  Paul Eggert  <eggert@twinsun.com>
164507         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
164508         (textint): New typedef.
164509         (parser_control): Member year changed from int to textint.
164510         All uses changed.
164511         (YYSTYPE): Removed; replaced by %union with int and textint members.
164512         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
164513         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
164514         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
164515         (tSNUMBER, tUNUMBER): Now of type <textintval>.
164516         (date, number, to_year): Use width of number in digits, not its value,
164517         to determine whether it's a 2-digit year, or a 2-digit time.
164518         (yylex): Store number of digits of numeric tokens.
164519         Reported by John Kendall.
164521         (parser_control): Changed from struct parser_control to typedef (for
164522         consistency).  All uses changed.
164524         (tID): Removed; not used.
164525         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
164527 2000-02-14  Paul Eggert  <eggert@twinsun.com>
164529         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
164530         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
164532 2000-02-12  Jim Meyering  <meyering@lucent.com>
164534         * lib/userspec.c (ISDIGIT): Define it.
164535         (isdigit): Remove definition.
164536         (is_number): Use ISDIGIT, not isdigit.
164537         <libintl.h>: Include.
164538         (_ and N_): Define.
164539         (parse_user_spec): Mark translatable strings.
164541 2000-02-10  Jim Meyering  <meyering@lucent.com>
164543         With these changes, nanosleep.[ch] are finally enough like the other
164544         lib/* replacement files to compile on a few more losing systems.
164546         * lib/nanosleep.h: Don't include config.h.
164547         Remove prototype from declaration of nanosleep.
164548         (PARAMS): Remove now-unneeded definition.
164549         * lib/nanosleep.c: #undef nanosleep.
164550         (rpl_nanosleep): Rename from nanosleep.
164552 2000-02-10  Jim Meyering  <meyering@lucent.com>
164554         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
164555         gnu_nanosleep to rpl_nanosleep.
164557 2000-02-09  Jim Meyering  <meyering@lucent.com>
164559         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
164560         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
164562 2000-02-08  Akim Demaille  <akim@epita.fr>
164564         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
164565         `[' and `]' and remove uses of `changequote'.
164566         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
164567         (AC_SYS_LARGEFILE): Likewise.
164568         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
164569         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
164570         of changequote.
164571         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
164572         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
164573         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
164574         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
164576 2000-02-05  Jim Meyering  <meyering@lucent.com>
164578         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
164579         Remove explicit use of AC_HEADER_TIME.  It is required by
164580         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
164581         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
164582         in autoconf whereby the expansion of the latter ended up preceding
164583         the expansion of its prerequisite, AC_HEADER_TIME.
164584         Reported by Volker Borchert.
164586 2000-02-03  Jim Meyering  <meyering@lucent.com>
164588         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
164590 2000-02-03  Jim Meyering  <meyering@lucent.com>
164592         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
164593         rather than with `#if HAVE_UTMPNAME'.
164595 2000-02-02  Jim Meyering  <meyering@lucent.com>
164597         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
164598         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
164599         Reported by Eli Zaretskii.
164601 2000-02-01  Jim Meyering  <meyering@lucent.com>
164603         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
164605 2000-01-31  Jim Meyering  <meyering@lucent.com>
164607         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
164608         functions.  Add the time.h and sys/time.h headers along with the
164609         AC_REQUIRE'ment of AC_HEADER_TIME.
164611 2000-01-31  Jim Meyering  <meyering@lucent.com>
164613         * lib/nanosleep.h (nanosleep): Guard declaration with
164614         `#if ! HAVE_DECL_NANOSLEEP'.
164615         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
164616         the declaration in that vendor's sys/timers.h.
164617         Reported by Christian Krackowizer.
164619         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
164620         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
164621         (ISPRINT): Likewise.
164622         Reported by Tom Tromey.
164624 2000-01-30  Jim Meyering  <meyering@lucent.com>
164626         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
164628         * m4/prereq.m4 (utmp_includes): Define.
164629         Check for ut_user and ut_name members in both struct utmpx
164630         and struct utmp.
164632 2000-01-30  Jim Meyering  <meyering@lucent.com>
164634         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
164635         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
164636         header files where only utmpx.ut_user is declared.
164638         * lib/readutmp.h (UT_USER): Define.
164640 2000-01-29  Jim Meyering  <meyering@lucent.com>
164642         * m4/lib-check.m4: New file containing library-related checks from
164643         fileutils and sh-utils (textutils had none).
164645 2000-01-28  Jim Meyering  <meyering@lucent.com>
164647         * m4/perl.m4: Change format of warning message to look more like that
164648         from the missing script.  Suggestion from François Pinard.
164650 2000-01-25  Jim Meyering  <meyering@lucent.com>
164652         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
164653         well as time.h in the compile check.
164654         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
164655         Fix typo in cross-compiling case: s/yes/no/.
164657 2000-01-23  Jim Meyering  <meyering@lucent.com>
164659         * m4/jm-macros.m4: Move df-related tests here from
164660         fileutils/configure.in
164662         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
164663         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
164665         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
164666         s/space/ac_fsusage_space/.
164667         (jm_FILE_SYSTEM_USAGE): Take two parameters.
164669         * m4/ftruncate.m4: New file (derived from part of
164670         fileutils/configure.in).
164671         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
164672         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
164674         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
164675         AC_SUBST these here, rather than just in sh-util/configure.in, so
164676         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
164677         all the same.
164678         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
164679         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
164680         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
164681         (AC_SUBST(POW_LIBM)): Likewise.
164682         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
164684 2000-01-23  Jim Meyering  <meyering@lucent.com>
164686         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
164687         obstack.c.
164689 2000-01-22  Jim Meyering  <meyering@lucent.com>
164691         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
164693         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
164695         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
164696         configure.in
164697         (AC_CHECK_HEADERS): Likewise for sh-utils.
164698         (AC_CHECK_HEADERS): Likewise for textutils.
164699         Merge the three lists of headers.
164701         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
164702         from fileutils' configure.in.
164704         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
164705         code. Moved tests into their own function (_jm_DECL_HEADERS) in
164706         check-decl.m4.
164708         * m4/check-decl.m4: Use #if rather than #ifdef.
164709         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
164710         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
164711         (_jm_DECL_HEADERS): Define new function.
164712         (jm_CHECK_DECLARATIONS): Require it.
164714 2000-01-22  Jim Meyering  <meyering@lucent.com>
164716         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
164717         [! HAVE_DECL_STRTOULL]: Declare strtoull.
164718         Required for some AIX systems.  Reported by Christian Krackowizer.
164719         [TESTING] (main): New function.
164721         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
164722         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
164723         letters.
164725         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
164726         iswprint.
164728         * lib/strverscmp.c (ISDIGIT): Define.
164729         (strverscmp): Use ISDIGIT, not isdigit.
164731 2000-01-19  Jim Meyering  <meyering@lucent.com>
164733         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
164734         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
164735         defines `struct timespec' in <sys/time.h>
164737         * m4/c-bs-a.m4: Remove uses of changequote altogether.
164738         Thanks to Akim for explaining.
164740 2000-01-17  Paul Eggert  <eggert@twinsun.com>
164742         * lib/nanosleep.c (nanosleep):
164743         Don't use SA_INTERRUPT to decide whether to call sigaction, as
164744         POSIX.1 doesn't require SA_INTERRUPT and some systems
164745         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
164746         it's been part of POSIX.1 since day 1 (in 1988).
164748 2000-01-17  Jim Meyering  <meyering@lucent.com>
164750         * lib/interlock: Remove unused file.  Reported by François Pinard.
164752 2000-01-16  Paul Eggert  <eggert@twinsun.com>
164754         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
164755         alert, backslash, formfeed, and vertical tab unnecessarily in
164756         shell quoting style.
164758 2000-01-16  Jim Meyering  <meyering@lucent.com>
164760         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
164761         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
164762         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
164763         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
164765 2000-01-16  Jim Meyering  <meyering@lucent.com>
164767         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
164768         because the latter didn't work.
164770 2000-01-15  Jim Meyering  <meyering@lucent.com>
164772         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
164773         (AC_REPLACE_FUNCS): Add memcpy and memset.
164774         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
164775         Add strpbrk.
164776         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
164778 2000-01-12  Jim Meyering  <meyering@lucent.com>
164780         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
164781         (jm_PREREQ): Use it.
164782         (jm_PREREQ_READUTMP): New macro.
164783         (jm_PREREQ): Use it.
164785 2000-01-11  Paul Eggert  <eggert@twinsun.com>
164787         Quote multibyte characters correctly.
164788         * m4/c-bs-a.m4: New file.
164789         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
164790         (jm_PREREQ): Use it.
164792 2000-01-11  Paul Eggert  <eggert@twinsun.com>
164794         * m4/uintmax_t.m4: Port to autoconf 2.13.
164796 2000-01-08  Jim Meyering  <meyering@ascend.com>
164798         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
164799         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
164801 2000-01-04  Jim Meyering  <meyering@ascend.com>
164803         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
164804         jm_STRUCT_DIRENT_D_TYPE.
164805         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
164806         jm_STRUCT_DIRENT_D_INO.
164807         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
164808         jm_STRUCT_UTIMBUF.
164809         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
164810         renamings.
164811         * m4/utime.m4: Likewise.
164813         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
164814         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
164816 2000-01-03  Paul Eggert  <eggert@twinsun.com>
164818         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
164819         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
164821 2000-01-02  Jim Meyering  <meyering@ascend.com>
164823         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
164824         remember if this is necessary.
164826 1999-12-26  Jim Meyering  <meyering@ascend.com>
164828         * m4/jm-macros.m4: Use it here.
164829         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
164831 1999-12-23  Jim Meyering  <meyering@ascend.com>
164833         * m4/jm-macros.m4: Check for clock_gettime (moved from
164834         fileutils/configure.in)
164835         Check for gettimeofday.
164837 1999-12-20  Jim Meyering  <meyering@ascend.com>
164839         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
164840         autoconf-2.14a-1999-12-20.
164842 1999-12-19  Jim Meyering  <meyering@ascend.com>
164844         * m4/lstat-slash.m4: New file.
164845         * m4/jm-macros.m4: Use the new macro:
164846         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
164848 1999-12-07  Jim Meyering  <meyering@ascend.com>
164850         * m4/perl.m4: Require that File::Compare be available, too.
164851         Too many systems seem to lack it.
164853         * m4/strftime.m4: Add checks for most of the cpp macros tested in
164854         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
164856 1999-11-18  Paul Eggert  <eggert@twinsun.com>
164858         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
164859         problem with the QNX 4.25 shell, which doesn't propagate exit
164860         status of failed commands inside shell assignments.
164862 1999-11-17  Jim Meyering  <meyering@ascend.com>
164864         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
164866 1999-11-07  Jim Meyering  <meyering@ascend.com>
164868         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
164870 1999-11-06  Jim Meyering  <meyering@ascend.com>
164872         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
164873         * m4/jm-macros.m4 (jm_MACROS): Use it here.
164875 1999-11-05  Jim Meyering  <meyering@ascend.com>
164877         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
164878         configure.in of textutils, fileutils, and sh-utils into this one
164879         (shared between those packages) file.
164880         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
164881         AC_STRUCT_ST_BLKSIZE.
164883 1999-11-03  Jim Meyering  <meyering@ascend.com>
164885         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
164886         of AC_CHECK_TYPE checks includes unistd.h.
164887         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
164888         Suggestion from Akim Demaille.
164890 1999-10-30  Jim Meyering  <meyering@ascend.com>
164892         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
164893         m4-quoted string.
164894         * m4/ls-mntd-fs.m4: Likewise.
164895         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
164896         * m4/jm-winsz1.m4: Likewise.
164898         * m4/const.m4: Remove file, since the fix made it into the experimental
164899         version of autoconf.
164900         * m4/mktime.m4: Likewise.
164902         * m4/check-type.m4: Remove file, now that the latest version of
164903         AC_CHECK_TYPE takes a third arg to specify additional #includes.
164905         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
164906         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
164907         AC_CHECK_TYPE.
164909 1999-10-04  Jim Meyering  <meyering@ascend.com>
164911         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
164913 1999-09-22  Paul Eggert  <eggert@twinsun.com>
164915         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
164916         2.95.1 bug with HP-UX 10.20.
164918 1999-09-17  Jim Meyering  <meyering@ascend.com>
164920         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
164921         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
164922         due to missing strdup (against sh-utils-2.0).
164924 1999-08-29  Jim Meyering  <meyering@ascend.com>
164926         * m4/jm-macros.m4: Require jm_BISON.
164927         * m4/bison.m4: New file.
164929 1999-08-17  Paul Eggert  <eggert@twinsun.com>
164931         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
164932         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
164934 1999-08-05  Jim Meyering  <meyering@ascend.com>
164936         * m4/getline.m4: Rename test file from conftestdata to conftest.data
164937         to avoid conflicts with `conftest' on 8+3 filesystems.
164938         Suggestion from Eli Zaretskii.
164940 1999-08-04  Jim Meyering  <meyering@ascend.com>
164942         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
164943         fileutils and sh-utils (textutils's getline test was inadequate).
164944         (AM_FUNC_GETLINE): Run this test.
164945         (AC_CHECK_FUNCS): Check for getdelim.
164946         Reported by Bob Proulx.
164948 1999-08-02  Jim Meyering  <meyering@ascend.com>
164950         * m4/jm-macros.m4: Add a comment.
164952 1999-08-01  Paul Eggert  <eggert@twinsun.com>
164954         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
164955         <inttypes.h> defines strtoumax as a macro (and not as a
164956         function).
164958 1999-08-01  Paul Eggert  <eggert@twinsun.com>
164960         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
164961         that we can shift, multiply and divide unsigned long long
164962         values; Ultrix cc can't do it.
164964 1999-08-01  Paul Eggert  <eggert@twinsun.com>
164966         * m4/mktime.m4: New file, which is a preview of what should appear
164967         in the next public autoconf release.
164969 1999-08-01  Paul Eggert  <eggert@twinsun.com>
164971         * m4/lfs.m4: Remove this file.
164972         * m4/largefile.m4: New file.  It contains the old contents of
164973         lfs.m4, except that all names with prefix AC_LFS have been
164974         changed to use the prefix AC_SYS_LARGEFILE instead, to be
164975         compatible with future autoconf versions.  Also, some minor m4
164976         quoting problems have been fixed.
164978 1999-08-01  Paul Eggert  <eggert@twinsun.com>
164980         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
164981         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
164982         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
164983         and simplify the shell code.
164985 1999-08-01  Jim Meyering  <meyering@ascend.com>
164987         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
164988         m4.
164990 1999-07-20  Jim Meyering  <meyering@ascend.com>
164992         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
164994 1999-07-15  Jim Meyering  <meyering@ascend.com>
164996         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
164998 1999-05-22  Jim Meyering  <meyering@ascend.com>
165000         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
165002 1999-05-20  Jim Meyering  <meyering@ascend.com>
165004         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
165005         Add a colon after each `then' in case $4 is empty.
165007 1999-05-16  Jim Meyering  <meyering@ascend.com>
165009         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
165011 1999-05-10  Jim Meyering  <meyering@ascend.com>
165013         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
165015         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
165016         AC_FUNC_MKTIME.
165018 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
165020         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
165022 1999-05-04  Paul Eggert  <eggert@twinsun.com>
165024         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
165025         not CPPFLAGS, so that linking works correctly in IRIX.
165027 1999-04-30  Paul Eggert  <eggert@twinsun.com>
165029         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
165031 1999-04-20  Paul Eggert  <eggert@twinsun.com>
165033         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
165034         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
165035         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
165036         jm_AC_TYPE_UNSIGNED_LONG_LONG.
165037         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
165039         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
165041 1999-04-20  Jim Meyering  <meyering@ascend.com>
165043         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
165044         AC_REPLACE xstroull if necessary.  From Paul Eggert.
165045         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
165047 1999-04-18  Jim Meyering  <meyering@ascend.com>
165049         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
165050         * m4/jm-macros.m4: Use it.
165052 1999-04-06  Jim Meyering  <meyering@ascend.com>
165054         * m4/strftime.m4: Remove test for %f.
165056 1999-03-29  Jim Meyering  <meyering@ascend.com>
165058         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
165059         superset of the AC_TYPE_* checks in the textutils, fileutils,
165060         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
165061         AC_TYPE_PID_T.
165063 1999-03-28  Jim Meyering  <meyering@ascend.com>
165065         * m4/jm-macros.m4: Define GNU_PACKAGE here.
165066         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
165067         replaced e.g., in the *.sh files of the sh-utils.
165069 1999-03-20  Jim Meyering  <meyering@ascend.com>
165071         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
165072         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
165073         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
165075 1999-03-19  Jim Meyering  <meyering@ascend.com>
165077         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
165079 1999-03-12  Jim Meyering  <meyering@ascend.com>
165081         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
165083 1999-03-07  Jim Meyering  <meyering@ascend.com>
165085         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
165086         declared.
165088 1999-02-17  Jim Meyering  <meyering@ascend.com>
165090         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
165091         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
165093 1999-02-07  Jim Meyering  <meyering@ascend.com>
165095         * m4/group-member.m4: New file -- extracted from sh-utils'
165096         configure.in.
165098         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
165099         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
165101 1999-02-06  Jim Meyering  <meyering@ascend.com>
165103         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
165104         * m4/fnmatch.m4: Likewise.
165105         * m4/getgroups.m4: Likewise.
165106         * m4/lstat.m4: Likewise.
165107         * m4/malloc.m4: Likewise.
165108         * m4/putenv.m4: Likewise.
165109         * m4/realloc.m4: Likewise.
165110         * m4/regex.m4: Likewise.
165111         * m4/stat.m4: Likewise.
165112         * m4/strftime.m4: Likewise.
165113         Suggestion from Alain Magloire.
165115         * m4/chown.m4: Use `.$ac_objext', not `.o'.
165116         * m4/fnmatch.m4: Likewise.
165117         * m4/getgroups.m4: Likewise.
165118         * m4/getline.m4: Likewise.
165119         * m4/lstat.m4: Likewise.
165120         * m4/malloc.m4: Likewise.
165121         * m4/memcmp.m4: Likewise.
165122         * m4/putenv.m4: Likewise.
165123         * m4/realloc.m4: Likewise.
165124         * m4/regex.m4: Likewise.
165125         * m4/stat.m4: Likewise.
165126         * m4/strftime.m4: Likewise.
165127         Suggestion from Alain Magloire.
165129         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
165130         an argument.
165132         * m4/regex.m4: Add a run-time Test for proper operation of
165133         re_compile_pattern.
165135 1999-01-31  Jim Meyering  <meyering@ascend.com>
165137         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
165139 1999-01-30  Jim Meyering  <meyering@ascend.com>
165141         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
165143         * m4/jm-mktime.m4: Make this a wrapper around the official
165144         AM_FUNC_MKTIME rather than my private copy, now that the official one
165145         is up to date.
165146         * m4/mktime.m4: Remove file.
165148         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
165149         * m4/uptime.m4: Likewise.
165150         * m4/uintmax_t.m4: Likewise.
165152 1999-01-28  Jim Meyering  <meyering@ascend.com>
165154         * m4/jm-macros.m4: Use jm_AFS.
165155         * m4/afs.m4: New file (from fileutils' configure.in).
165157         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
165158         * m4/chown.m4: Likewise.
165159         * m4/d-ino.m4: Likewise.
165160         * m4/d-type.m4: Likewise.
165161         * m4/fnmatch.m4: Likewise.
165162         * m4/getgroups.m4: Likewise.
165163         * m4/gettext.m4: Likewise.
165164         * m4/jm-mktime.m4: Likewise.
165165         * m4/jm-winsz2.m4: Likewise.
165166         * m4/lcmessage.m4: Likewise.
165167         * m4/ls-mntd-fs.m4: Likewise.
165168         * m4/malloc.m4: Likewise.
165169         * m4/memcmp.m4: Likewise.
165170         * m4/putenv.m4: Likewise.
165171         * m4/realloc.m4: Likewise.
165172         * m4/st_mtim.m4: Likewise.
165173         * m4/strftime.m4: Likewise.
165175 1999-01-16  Jim Meyering  <meyering@ascend.com>
165177         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
165178         (ARGMATCH_DIE_DECL): Define.
165180 1999-01-12  Jim Meyering  <meyering@ascend.com>
165182         * m4/Makefile.am.in: Rewrite to avoid using fmt.
165183         Reported by Lars Hecking.
165185 1999-01-10  Jim Meyering  <meyering@ascend.com>
165187         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
165188         gross kludge.
165189         * m4/inttypes_h.m4: Likewise.
165190         * m4/lstat.m4: Likewise.
165191         * m4/malloc.m4: Likewise.
165192         * m4/readdir.m4: Likewise.
165193         * m4/realloc.m4: Likewise.
165194         * m4/st_dm_mode.m4: Likewise.
165195         * m4/stat.m4: Likewise.
165196         * m4/utimbuf.m4: Likewise.
165197         * m4/utimes.m4: Likewise.
165199         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
165200         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
165201         comments in config.h.in are meaningful.
165203         * m4/jm-macros.m4: Require autoconf-2.13 here.
165205         * m4/regex.m4: By default, don't use the included regex.c on systems
165206         with glibc 2.  Suggestion from Uli Drepper.
165208 1999-01-02  Jim Meyering  <meyering@ascend.com>
165210         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
165212 1998-12-18  Jim Meyering  <meyering@ascend.com>
165214         * m4/Makefile.am.in (Makefile.am): Simplify rule.
165215         Based on a suggestion from Lars Hecking.
165217 1998-11-16  Paul Eggert  <eggert@twinsun.com>
165219         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
165221 1998-11-16  Jim Meyering  <meyering@ascend.com>
165223         * m4/lfs.m4: Double-quote the `uname...` expression.
165225 1998-11-14  Jim Meyering  <meyering@ascend.com>
165227         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
165228         * m4/stat.m4: Likewise.
165230 1998-11-03  Jim Meyering  <meyering@ascend.com>
165232         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
165233         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
165235 1998-10-18  Jim Meyering  <meyering@ascend.com>
165237         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
165239 1998-10-17  Jim Meyering  <meyering@ascend.com>
165241         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
165242         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
165243         calls for those previously hard-coded headers.  Instead, take a new
165244         parameter.
165245         (jm_CHECK_DECLARATIONS): Reflect interface change.
165246         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
165247         (jm_CHECK_DECL_LOCALTIME_R): New macro.
165249         * m4/mktime.m4: Test for spring-forward gap before long-running test.
165251 1998-10-14  Jim Meyering  <meyering@ascend.com>
165253         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
165254         instead of "TZ=America/Vancouver".  From Paul Eggert.
165256 1998-10-11  Jim Meyering  <meyering@ascend.com>
165258         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
165259         This adds a test for a recently added compatibility fix for mktime.c.
165260         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
165262 1998-09-27  Jim Meyering  <meyering@ascend.com>
165264         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
165266         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
165267         ../configure.in, including a change from Gordon Matzigkeit to allow
165268         cross-compiling for the Hurd.
165270         * m4/glibc.m4: New file/macro to test for the GNU C Library
165271         versions 1 and 2.  From Gordon Matzigkeit.
165272         Indent.
165274 1998-09-21  Jim Meyering  <meyering@ascend.com>
165276         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
165278 1998-08-18  Paul Eggert  <eggert@twinsun.com>
165280         Port nanosecond-resolution times to UnixWare 2.1.2 and
165281         pedantic Solaris 2.6.
165283         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
165284         AC_STRUCT_ST_MTIM.
165285         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
165286         Generate name of ns member, instead of just 1 or undef.
165287         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
165289 1998-08-15  Jim Meyering  <meyering@ascend.com>
165291         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
165292         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
165293         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
165294         instead of jm_TYPE_SSIZE_T.
165296 1998-08-12  Jim Meyering  <meyering@ascend.com>
165298         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
165300 1998-08-02  Jim Meyering  <meyering@ascend.com>
165302         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
165303         in acconfig.h manually.
165305 1998-07-31  Paul Eggert  <eggert@twinsun.com>
165307         * m4/st_mtim.m4: New file.
165309 1998-07-28  Jim Meyering  <meyering@ascend.com>
165311         * m4/utimes.m4: Undef stat.
165313 1998-07-25  Jim Meyering  <meyering@ascend.com>
165315         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
165316         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
165318 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
165320         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
165321         uid and gid actually remain unchanged.
165323 1998-07-07  Jim Meyering  <meyering@ascend.com>
165325         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
165327 1998-07-04  Jim Meyering  <meyering@ascend.com>
165329         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
165330         to prove that this macro can be used in packages without regex.c.
165332 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
165334         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
165335         is to be used.
165337 1998-07-03  Jim Meyering  <meyering@ascend.com>
165339         * m4/gettext.m4: Add -lintl if it's found to be necessary.
165341         * m4/gettext.m4: New file -- from gettext-0.10.35.
165342         * m4/lcmessage.m4: Likewise.
165343         * m4/progtest.m4: Likewise.
165345         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
165346         * m4/jm-macros.m4: Require the new macro.
165348 1998-06-29  Jim Meyering  <meyering@ascend.com>
165350         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
165351         for the definition of NGROUPS (used in a system header included
165352         by sys/mount.h).
165354 1998-06-28  Jim Meyering  <meyering@ascend.com>
165356         * m4/ls-mntd-fs.m4: New file.
165357         * m4/fstypename.m4: New file.
165359         * m4/jm-macros.m4: Require the new macro.
165360         * m4/jm-glibc-io.m4: New file.
165362 1998-05-19  Jim Meyering  <meyering@ascend.com>
165364         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
165365         * m4/lchown.m4: New file.
165367         * m4/Makefile.am.in: New file.
165368         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
165370 1998-05-14  Jim Meyering  <meyering@ascend.com>
165372         * m4/Makefile.am (EXTRA_DIST): Add them.
165373         * m4/jm-macros.m4: New file.
165374         * m4/utimbuf.m4: New file.
165376 1998-05-12  Jim Meyering  <meyering@ascend.com>
165378         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
165380 1998-05-11  Jim Meyering  <meyering@ascend.com>
165382         * m4/isc-posix.m4: New file.
165384 1998-05-10  Jim Meyering  <meyering@ascend.com>
165386         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
165388 1998-05-09  Jim Meyering  <meyering@ascend.com>
165390         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
165391         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
165392         with automake.
165394         * m4/ssize_t.m4: New file.
165395         * m4/mktime.m4: Remove file -- the new automake has this now.
165397 1998-04-26  Jim Meyering  <meyering@ascend.com>
165399         * m4/assert.m4: New file.
165400         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
165402 1998-04-05  Jim Meyering  <meyering@ascend.com>
165404         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
165405         (jm_PREREQ): Use it here.
165407 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
165409         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
165410         in acconfig.h.
165412 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
165414         * m4/prereq.m4: New file.
165415         * m4/error.m4: New file.
165416         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
165418 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
165420         * m4/getline.m4: Don't set am_cv_func_working_getline before the
165421         cache-check for the same variable -- that defeated the purpose of
165422         the test; the test program was never run.  This was a problem only
165423         on systems with losing getline functions -- HP-UX 10.20 is one.
165424         Reported by Bjorn Helgaas.
165426 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
165428         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
165430 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
165432         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
165434         * m4/const.m4: New file.  Use an initializer in this declaration
165435         typedef int charset[2]; const charset x;
165436         Reported by Bob Glickstein.
165438 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
165440         * m4/chown.m4: Fix reversed types on -1 args to chown.
165441         From Kaveh Ghazi.
165443 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
165445         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
165446         Add lseek and memchr.
165448         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
165449         T.E.Dickey <dickey@clark.net> said that some older preprocessors
165450         have a 20-character limit on names.
165452 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
165454         * m4/inttypes_h.m4: New file.
165455         * m4/uintmax_t.m4: New file.
165456         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
165459         -----
165461         Local Variables:
165462         coding: utf-8
165463         End:
165465         Copyright (C) 1997-2024 Free Software Foundation, Inc.
165467         Copying and distribution of this file, with or without
165468         modification, are permitted provided the copyright notice
165469         and this notice are preserved.